summaryrefslogtreecommitdiff
path: root/include/asm-blackfin/bitops.h
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2008-02-15 00:06:18 +0100
committerWolfgang Denk <wd@denx.de>2008-02-15 00:06:18 +0100
commit6f99eec3dc2285abfb93631003f7e5cadf2eab0f (patch)
tree1eaaa31eb768d8bfa68e9ff41eef53d37b64f21c /include/asm-blackfin/bitops.h
parentf6921e3dc331293c873ec4d109fd5517a42a90b3 (diff)
parent30942b18b66f35f2ceedab39af10e9eccaa943cc (diff)
downloadu-boot-imx-6f99eec3dc2285abfb93631003f7e5cadf2eab0f.zip
u-boot-imx-6f99eec3dc2285abfb93631003f7e5cadf2eab0f.tar.gz
u-boot-imx-6f99eec3dc2285abfb93631003f7e5cadf2eab0f.tar.bz2
Merge branch 'master' of git://www.denx.de/git/u-boot-blackfin
Conflicts: Makefile doc/README.standalone Signed-off-by: Wolfgang Denk <wd@denx.de>
Diffstat (limited to 'include/asm-blackfin/bitops.h')
-rw-r--r--include/asm-blackfin/bitops.h32
1 files changed, 16 insertions, 16 deletions
diff --git a/include/asm-blackfin/bitops.h b/include/asm-blackfin/bitops.h
index 438e50b..2e55b6a 100644
--- a/include/asm-blackfin/bitops.h
+++ b/include/asm-blackfin/bitops.h
@@ -65,9 +65,9 @@ static __inline__ void set_bit(int nr, volatile void *addr)
a += nr >> 5;
mask = 1 << (nr & 0x1f);
- save_and_cli(flags);
+ local_irq_save(flags);
*a |= mask;
- restore_flags(flags);
+ local_irq_restore(flags);
}
static __inline__ void __set_bit(int nr, volatile void *addr)
@@ -94,9 +94,9 @@ static __inline__ void clear_bit(int nr, volatile void *addr)
a += nr >> 5;
mask = 1 << (nr & 0x1f);
- save_and_cli(flags);
+ local_irq_save(flags);
*a &= ~mask;
- restore_flags(flags);
+ local_irq_restore(flags);
}
static __inline__ void change_bit(int nr, volatile void *addr)
@@ -106,9 +106,9 @@ static __inline__ void change_bit(int nr, volatile void *addr)
ADDR += nr >> 5;
mask = 1 << (nr & 31);
- save_and_cli(flags);
+ local_irq_save(flags);
*ADDR ^= mask;
- restore_flags(flags);
+ local_irq_restore(flags);
}
static __inline__ void __change_bit(int nr, volatile void *addr)
@@ -129,10 +129,10 @@ static __inline__ int test_and_set_bit(int nr, volatile void *addr)
a += nr >> 5;
mask = 1 << (nr & 0x1f);
- save_and_cli(flags);
+ local_irq_save(flags);
retval = (mask & *a) != 0;
*a |= mask;
- restore_flags(flags);
+ local_irq_restore(flags);
return retval;
}
@@ -157,10 +157,10 @@ static __inline__ int test_and_clear_bit(int nr, volatile void *addr)
a += nr >> 5;
mask = 1 << (nr & 0x1f);
- save_and_cli(flags);
+ local_irq_save(flags);
retval = (mask & *a) != 0;
*a &= ~mask;
- restore_flags(flags);
+ local_irq_restore(flags);
return retval;
}
@@ -185,10 +185,10 @@ static __inline__ int test_and_change_bit(int nr, volatile void *addr)
a += nr >> 5;
mask = 1 << (nr & 0x1f);
- save_and_cli(flags);
+ local_irq_save(flags);
retval = (mask & *a) != 0;
*a ^= mask;
- restore_flags(flags);
+ local_irq_restore(flags);
return retval;
}
@@ -293,10 +293,10 @@ static __inline__ int ext2_set_bit(int nr, volatile void *addr)
ADDR += nr >> 3;
mask = 1 << (nr & 0x07);
- save_and_cli(flags);
+ local_irq_save(flags);
retval = (mask & *ADDR) != 0;
*ADDR |= mask;
- restore_flags(flags);
+ local_irq_restore(flags);
return retval;
}
@@ -308,10 +308,10 @@ static __inline__ int ext2_clear_bit(int nr, volatile void *addr)
ADDR += nr >> 3;
mask = 1 << (nr & 0x07);
- save_and_cli(flags);
+ local_irq_save(flags);
retval = (mask & *ADDR) != 0;
*ADDR &= ~mask;
- restore_flags(flags);
+ local_irq_restore(flags);
return retval;
}