aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-avr32/io.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-avr32/io.h')
-rw-r--r--include/asm-avr32/io.h23
1 files changed, 17 insertions, 6 deletions
diff --git a/include/asm-avr32/io.h b/include/asm-avr32/io.h
index eec47500fa66..c08e81048393 100644
--- a/include/asm-avr32/io.h
+++ b/include/asm-avr32/io.h
@@ -28,13 +28,13 @@ static __inline__ void * phys_to_virt(unsigned long address)
28 * Generic IO read/write. These perform native-endian accesses. Note 28 * Generic IO read/write. These perform native-endian accesses. Note
29 * that some architectures will want to re-define __raw_{read,write}w. 29 * that some architectures will want to re-define __raw_{read,write}w.
30 */ 30 */
31extern void __raw_writesb(unsigned int addr, const void *data, int bytelen); 31extern void __raw_writesb(void __iomem *addr, const void *data, int bytelen);
32extern void __raw_writesw(unsigned int addr, const void *data, int wordlen); 32extern void __raw_writesw(void __iomem *addr, const void *data, int wordlen);
33extern void __raw_writesl(unsigned int addr, const void *data, int longlen); 33extern void __raw_writesl(void __iomem *addr, const void *data, int longlen);
34 34
35extern void __raw_readsb(unsigned int addr, void *data, int bytelen); 35extern void __raw_readsb(const void __iomem *addr, void *data, int bytelen);
36extern void __raw_readsw(unsigned int addr, void *data, int wordlen); 36extern void __raw_readsw(const void __iomem *addr, void *data, int wordlen);
37extern void __raw_readsl(unsigned int addr, void *data, int longlen); 37extern void __raw_readsl(const void __iomem *addr, void *data, int longlen);
38 38
39static inline void writeb(unsigned char b, volatile void __iomem *addr) 39static inline void writeb(unsigned char b, volatile void __iomem *addr)
40{ 40{
@@ -252,6 +252,9 @@ extern void __iounmap(void __iomem *addr);
252#define ioremap(offset, size) \ 252#define ioremap(offset, size) \
253 __ioremap((offset), (size), 0) 253 __ioremap((offset), (size), 0)
254 254
255#define ioremap_nocache(offset, size) \
256 __ioremap((offset), (size), 0)
257
255#define iounmap(addr) \ 258#define iounmap(addr) \
256 __iounmap(addr) 259 __iounmap(addr)
257 260
@@ -263,6 +266,14 @@ extern void __iounmap(void __iomem *addr);
263#define page_to_bus page_to_phys 266#define page_to_bus page_to_phys
264#define bus_to_page phys_to_page 267#define bus_to_page phys_to_page
265 268
269/*
270 * Create a virtual mapping cookie for an IO port range. There exists
271 * no such thing as port-based I/O on AVR32, so a regular ioremap()
272 * should do what we need.
273 */
274#define ioport_map(port, nr) ioremap(port, nr)
275#define ioport_unmap(port) iounmap(port)
276
266#define dma_cache_wback_inv(_start, _size) \ 277#define dma_cache_wback_inv(_start, _size) \
267 flush_dcache_region(_start, _size) 278 flush_dcache_region(_start, _size)
268#define dma_cache_inv(_start, _size) \ 279#define dma_cache_inv(_start, _size) \