diff options
Diffstat (limited to 'arch/microblaze/include/asm/io.h')
-rw-r--r-- | arch/microblaze/include/asm/io.h | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/arch/microblaze/include/asm/io.h b/arch/microblaze/include/asm/io.h index 267c7c779e53..32d621a56aee 100644 --- a/arch/microblaze/include/asm/io.h +++ b/arch/microblaze/include/asm/io.h | |||
@@ -15,7 +15,23 @@ | |||
15 | #include <asm/page.h> | 15 | #include <asm/page.h> |
16 | #include <linux/types.h> | 16 | #include <linux/types.h> |
17 | #include <linux/mm.h> /* Get struct page {...} */ | 17 | #include <linux/mm.h> /* Get struct page {...} */ |
18 | #include <asm-generic/iomap.h> | ||
18 | 19 | ||
20 | #ifndef CONFIG_PCI | ||
21 | #define _IO_BASE 0 | ||
22 | #define _ISA_MEM_BASE 0 | ||
23 | #define PCI_DRAM_OFFSET 0 | ||
24 | #else | ||
25 | #define _IO_BASE isa_io_base | ||
26 | #define _ISA_MEM_BASE isa_mem_base | ||
27 | #define PCI_DRAM_OFFSET pci_dram_offset | ||
28 | #endif | ||
29 | |||
30 | extern unsigned long isa_io_base; | ||
31 | extern unsigned long pci_io_base; | ||
32 | extern unsigned long pci_dram_offset; | ||
33 | |||
34 | extern resource_size_t isa_mem_base; | ||
19 | 35 | ||
20 | #define IO_SPACE_LIMIT (0xFFFFFFFF) | 36 | #define IO_SPACE_LIMIT (0xFFFFFFFF) |
21 | 37 | ||
@@ -124,9 +140,6 @@ static inline void writel(unsigned int v, volatile void __iomem *addr) | |||
124 | #define virt_to_phys(addr) ((unsigned long)__virt_to_phys(addr)) | 140 | #define virt_to_phys(addr) ((unsigned long)__virt_to_phys(addr)) |
125 | #define virt_to_bus(addr) ((unsigned long)__virt_to_phys(addr)) | 141 | #define virt_to_bus(addr) ((unsigned long)__virt_to_phys(addr)) |
126 | 142 | ||
127 | #define __page_address(page) \ | ||
128 | (PAGE_OFFSET + (((page) - mem_map) << PAGE_SHIFT)) | ||
129 | #define page_to_phys(page) virt_to_phys((void *)__page_address(page)) | ||
130 | #define page_to_bus(page) (page_to_phys(page)) | 143 | #define page_to_bus(page) (page_to_phys(page)) |
131 | #define bus_to_virt(addr) (phys_to_virt(addr)) | 144 | #define bus_to_virt(addr) (phys_to_virt(addr)) |
132 | 145 | ||
@@ -227,15 +240,7 @@ static inline void __iomem *__ioremap(phys_addr_t address, unsigned long size, | |||
227 | #define out_8(a, v) __raw_writeb((v), (a)) | 240 | #define out_8(a, v) __raw_writeb((v), (a)) |
228 | #define in_8(a) __raw_readb(a) | 241 | #define in_8(a) __raw_readb(a) |
229 | 242 | ||
230 | /* FIXME */ | 243 | #define ioport_map(port, nr) ((void __iomem *)(port)) |
231 | static inline void __iomem *ioport_map(unsigned long port, unsigned int len) | 244 | #define ioport_unmap(addr) |
232 | { | ||
233 | return (void __iomem *) (port); | ||
234 | } | ||
235 | |||
236 | static inline void ioport_unmap(void __iomem *addr) | ||
237 | { | ||
238 | /* Nothing to do */ | ||
239 | } | ||
240 | 245 | ||
241 | #endif /* _ASM_MICROBLAZE_IO_H */ | 246 | #endif /* _ASM_MICROBLAZE_IO_H */ |