diff options
Diffstat (limited to 'include/asm-arm/arch-orion/io.h')
-rw-r--r-- | include/asm-arm/arch-orion/io.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/include/asm-arm/arch-orion/io.h b/include/asm-arm/arch-orion/io.h index e0b8c39b9167..42abd297ae5f 100644 --- a/include/asm-arm/arch-orion/io.h +++ b/include/asm-arm/arch-orion/io.h | |||
@@ -24,4 +24,19 @@ static inline void __iomem *__io(unsigned long addr) | |||
24 | #define __io(a) __io(a) | 24 | #define __io(a) __io(a) |
25 | #define __mem_pci(a) (a) | 25 | #define __mem_pci(a) (a) |
26 | 26 | ||
27 | |||
28 | /***************************************************************************** | ||
29 | * Helpers to access Orion registers | ||
30 | ****************************************************************************/ | ||
31 | #define orion_read(r) __raw_readl(r) | ||
32 | #define orion_write(r, val) __raw_writel(val, r) | ||
33 | |||
34 | /* | ||
35 | * These are not preempt-safe. Locks, if needed, must be taken | ||
36 | * care of by the caller. | ||
37 | */ | ||
38 | #define orion_setbits(r, mask) orion_write((r), orion_read(r) | (mask)) | ||
39 | #define orion_clrbits(r, mask) orion_write((r), orion_read(r) & ~(mask)) | ||
40 | |||
41 | |||
27 | #endif | 42 | #endif |