From: Randy Dunlap Date: Tue, 13 Sep 2005 08:25:50 +0000 (-0700) Subject: [PATCH] feature removal of io_remap_page_range() X-Git-Tag: v2.6.14-rc2~54 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=33bf56106d9be272696b73d9179da4e56b277472;p=linux-2.6 [PATCH] feature removal of io_remap_page_range() As written in Documentation/feature-removal-schedule.txt, remove the io_remap_page_range() kernel API. Signed-off-by: Randy Dunlap Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt index 784e08c1c8..b67189a8d8 100644 --- a/Documentation/feature-removal-schedule.txt +++ b/Documentation/feature-removal-schedule.txt @@ -17,15 +17,6 @@ Who: Greg Kroah-Hartman --------------------------- -What: io_remap_page_range() (macro or function) -When: September 2005 -Why: Replaced by io_remap_pfn_range() which allows more memory space - addressabilty (by using a pfn) and supports sparc & sparc64 - iospace as part of the pfn. -Who: Randy Dunlap - ---------------------------- - What: RAW driver (CONFIG_RAW_DRIVER) When: December 2005 Why: declared obsolete since kernel 2.6.3 diff --git a/include/asm-alpha/pgtable.h b/include/asm-alpha/pgtable.h index 22b53e369f..8393bf374b 100644 --- a/include/asm-alpha/pgtable.h +++ b/include/asm-alpha/pgtable.h @@ -339,13 +339,6 @@ extern inline pte_t mk_swap_pte(unsigned long type, unsigned long offset) #define kern_addr_valid(addr) (1) #endif -#define io_remap_page_range(vma, start, busaddr, size, prot) \ -({ \ - void *va = (void __force *)ioremap(busaddr, size); \ - unsigned long pfn = virt_to_phys(va) >> PAGE_SHIFT; \ - remap_pfn_range(vma, start, pfn, size, prot); \ -}) - #define io_remap_pfn_range(vma, start, pfn, size, prot) \ remap_pfn_range(vma, start, pfn, size, prot) diff --git a/include/asm-arm/pgtable.h b/include/asm-arm/pgtable.h index 478c49b56e..366bafbdfb 100644 --- a/include/asm-arm/pgtable.h +++ b/include/asm-arm/pgtable.h @@ -445,12 +445,9 @@ extern pgd_t swapper_pg_dir[PTRS_PER_PGD]; #define HAVE_ARCH_UNMAPPED_AREA /* - * remap a physical address `phys' of size `size' with page protection `prot' + * remap a physical page `pfn' of size `size' with page protection `prot' * into virtual address `from' */ -#define io_remap_page_range(vma,from,phys,size,prot) \ - remap_pfn_range(vma, from, (phys) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma,from,pfn,size,prot) \ remap_pfn_range(vma, from, pfn, size, prot) diff --git a/include/asm-arm26/pgtable.h b/include/asm-arm26/pgtable.h index 4a0a00da42..f602cf5724 100644 --- a/include/asm-arm26/pgtable.h +++ b/include/asm-arm26/pgtable.h @@ -294,12 +294,9 @@ static inline pte_t mk_pte_phys(unsigned long physpage, pgprot_t pgprot) #include /* - * remap a physical address `phys' of size `size' with page protection `prot' + * remap a physical page `pfn' of size `size' with page protection `prot' * into virtual address `from' */ -#define io_remap_page_range(vma,from,phys,size,prot) \ - remap_pfn_range(vma, from, (phys) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma,from,pfn,size,prot) \ remap_pfn_range(vma, from, pfn, size, prot) diff --git a/include/asm-frv/pgtable.h b/include/asm-frv/pgtable.h index d0a9c2f9c1..473fb4bb63 100644 --- a/include/asm-frv/pgtable.h +++ b/include/asm-frv/pgtable.h @@ -500,9 +500,6 @@ static inline int pte_file(pte_t pte) #define PageSkip(page) (0) #define kern_addr_valid(addr) (1) -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-h8300/pgtable.h b/include/asm-h8300/pgtable.h index 69076eb314..f6e296fc12 100644 --- a/include/asm-h8300/pgtable.h +++ b/include/asm-h8300/pgtable.h @@ -52,8 +52,6 @@ extern int is_in_rom(unsigned long); * No page table caches to initialise */ #define pgtable_cache_init() do { } while (0) -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-i386/pgtable.h b/include/asm-i386/pgtable.h index 47bc1ffa3d..d101ac414f 100644 --- a/include/asm-i386/pgtable.h +++ b/include/asm-i386/pgtable.h @@ -431,9 +431,6 @@ extern void noexec_setup(const char *str); #define kern_addr_valid(addr) (1) #endif /* CONFIG_FLATMEM */ -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-ia64/pgtable.h b/include/asm-ia64/pgtable.h index 2e34c06e67..3339c7b55a 100644 --- a/include/asm-ia64/pgtable.h +++ b/include/asm-ia64/pgtable.h @@ -443,10 +443,6 @@ extern void paging_init (void); #define pte_to_pgoff(pte) ((pte_val(pte) << 1) >> 3) #define pgoff_to_pte(off) ((pte_t) { ((off) << 2) | _PAGE_FILE }) -/* XXX is this right? */ -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-m32r/pgtable.h b/include/asm-m32r/pgtable.h index da805e9708..388e5ee9fa 100644 --- a/include/asm-m32r/pgtable.h +++ b/include/asm-m32r/pgtable.h @@ -378,9 +378,6 @@ static inline void pmd_set(pmd_t * pmdp, pte_t * ptep) /* Needs to be defined here and not in linux/mm.h, as it is arch dependent */ #define kern_addr_valid(addr) (1) -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-m68k/pgtable.h b/include/asm-m68k/pgtable.h index 0c87fc84f7..add129e93f 100644 --- a/include/asm-m68k/pgtable.h +++ b/include/asm-m68k/pgtable.h @@ -141,9 +141,6 @@ static inline void update_mmu_cache(struct vm_area_struct *vma, #define kern_addr_valid(addr) (1) -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-m68knommu/pgtable.h b/include/asm-m68knommu/pgtable.h index e2a69fffa3..00893055e6 100644 --- a/include/asm-m68knommu/pgtable.h +++ b/include/asm-m68knommu/pgtable.h @@ -56,8 +56,6 @@ extern int is_in_rom(unsigned long); * No page table caches to initialise. */ #define pgtable_cache_init() do { } while (0) -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-mips/pgtable.h b/include/asm-mips/pgtable.h index dbe13da0bd..cbd1672c94 100644 --- a/include/asm-mips/pgtable.h +++ b/include/asm-mips/pgtable.h @@ -358,16 +358,6 @@ static inline void update_mmu_cache(struct vm_area_struct *vma, extern phys_t fixup_bigphys_addr(phys_t phys_addr, phys_t size); extern int remap_pfn_range(struct vm_area_struct *vma, unsigned long from, unsigned long pfn, unsigned long size, pgprot_t prot); -static inline int io_remap_page_range(struct vm_area_struct *vma, - unsigned long vaddr, - unsigned long paddr, - unsigned long size, - pgprot_t prot) -{ - phys_t phys_addr_high = fixup_bigphys_addr(paddr, size); - return remap_pfn_range(vma, vaddr, phys_addr_high >> PAGE_SHIFT, size, prot); -} - static inline int io_remap_pfn_range(struct vm_area_struct *vma, unsigned long vaddr, unsigned long pfn, @@ -378,8 +368,6 @@ static inline int io_remap_pfn_range(struct vm_area_struct *vma, return remap_pfn_range(vma, vaddr, pfn, size, prot); } #else -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) #endif diff --git a/include/asm-parisc/pgtable.h b/include/asm-parisc/pgtable.h index f001bb01e3..820c6e712c 100644 --- a/include/asm-parisc/pgtable.h +++ b/include/asm-parisc/pgtable.h @@ -498,9 +498,6 @@ static inline void ptep_set_wrprotect(struct mm_struct *mm, unsigned long addr, #endif /* !__ASSEMBLY__ */ -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-ppc/pgtable.h b/include/asm-ppc/pgtable.h index 92f30b28b2..eee601bb9a 100644 --- a/include/asm-ppc/pgtable.h +++ b/include/asm-ppc/pgtable.h @@ -812,15 +812,6 @@ extern void kernel_set_cachemode (unsigned long address, unsigned long size, #ifdef CONFIG_PHYS_64BIT extern int remap_pfn_range(struct vm_area_struct *vma, unsigned long from, unsigned long paddr, unsigned long size, pgprot_t prot); -static inline int io_remap_page_range(struct vm_area_struct *vma, - unsigned long vaddr, - unsigned long paddr, - unsigned long size, - pgprot_t prot) -{ - phys_addr_t paddr64 = fixup_bigphys_addr(paddr, size); - return remap_pfn_range(vma, vaddr, paddr64 >> PAGE_SHIFT, size, prot); -} static inline int io_remap_pfn_range(struct vm_area_struct *vma, unsigned long vaddr, @@ -832,8 +823,6 @@ static inline int io_remap_pfn_range(struct vm_area_struct *vma, return remap_pfn_range(vma, vaddr, paddr64 >> PAGE_SHIFT, size, prot); } #else -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) #endif diff --git a/include/asm-sh/pgtable.h b/include/asm-sh/pgtable.h index ecb909572d..0f4bcaae61 100644 --- a/include/asm-sh/pgtable.h +++ b/include/asm-sh/pgtable.h @@ -277,9 +277,6 @@ typedef pte_t *pte_addr_t; #define kern_addr_valid(addr) (1) -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-sh64/pgtable.h b/include/asm-sh64/pgtable.h index 78ac6be2d9..51db4307bf 100644 --- a/include/asm-sh64/pgtable.h +++ b/include/asm-sh64/pgtable.h @@ -482,9 +482,6 @@ extern void update_mmu_cache(struct vm_area_struct * vma, #define PageSkip(page) (0) #define kern_addr_valid(addr) (1) -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-x86_64/pgtable.h b/include/asm-x86_64/pgtable.h index 1dc110ba82..2cb4835164 100644 --- a/include/asm-x86_64/pgtable.h +++ b/include/asm-x86_64/pgtable.h @@ -421,9 +421,6 @@ static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) extern int kern_addr_valid(unsigned long addr); -#define io_remap_page_range(vma, vaddr, paddr, size, prot) \ - remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot) - #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \ remap_pfn_range(vma, vaddr, pfn, size, prot) diff --git a/include/asm-xtensa/pgtable.h b/include/asm-xtensa/pgtable.h index 883ebc2d75..987e3b8023 100644 --- a/include/asm-xtensa/pgtable.h +++ b/include/asm-xtensa/pgtable.h @@ -441,11 +441,11 @@ extern void update_mmu_cache(struct vm_area_struct * vma, unsigned long address, pte_t pte); /* - * remap a physical address `phys' of size `size' with page protection `prot' + * remap a physical page `pfn' of size `size' with page protection `prot' * into virtual address `from' */ -#define io_remap_page_range(vma,from,phys,size,prot) \ - remap_pfn_range(vma, from, (phys) >> PAGE_SHIFT, size, prot) +#define io_remap_pfn_range(vma,from,pfn,size,prot) \ + remap_pfn_range(vma, from, pfn, size, prot) /* No page table caches to init */