16 #include <linux/module.h>
17 #include <linux/slab.h>
19 #include <linux/pci.h>
22 #include <asm/pgalloc.h>
23 #include <asm/addrspace.h>
24 #include <asm/cacheflush.h>
25 #include <asm/tlbflush.h>
42 unsigned long offset, last_addr,
addr, orig_addr;
46 last_addr = phys_addr + size - 1;
47 if (!size || last_addr < phys_addr)
61 if (mapped && !IS_ERR(mapped))
78 orig_addr = addr = (
unsigned long)area->
addr;
85 return (
void __iomem *)(offset + (
char *)orig_addr);
92 static inline int iomapping_nontranslatable(
unsigned long offset)
99 if (PXSEG(offset) <
P3SEG || offset >= P3_ADDR_MAX)
114 if (iomapping_nontranslatable(vaddr))