diff options
author | Matthew Wilcox <willy@linux.intel.com> | 2014-08-27 15:04:29 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2014-09-01 04:15:31 -0400 |
commit | bb693f13a0a535715034ce42405515ac3318c0e3 (patch) | |
tree | b608766e8c65aa74dbcc0d88c8daf95a8830501c | |
parent | 69e273c0b0a3c337a521d083374c918dc52c666f (diff) |
x86: Remove set_pmd_pfn
The last user of set_pmd_pfn() went away in commit f03574f2d5b2, so this
has been dead code for over a year.
Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
arch/x86/include/asm/pgtable_32.h | 3 ---
arch/x86/mm/pgtable_32.c | 35 -----------------------------------
2 files changed, 38 deletions(-)
-rw-r--r-- | arch/x86/include/asm/pgtable_32.h | 3 | ||||
-rw-r--r-- | arch/x86/mm/pgtable_32.c | 35 |
2 files changed, 0 insertions, 38 deletions
diff --git a/arch/x86/include/asm/pgtable_32.h b/arch/x86/include/asm/pgtable_32.h index 9ee322103c6d..b6c0b404898a 100644 --- a/arch/x86/include/asm/pgtable_32.h +++ b/arch/x86/include/asm/pgtable_32.h | |||
@@ -32,9 +32,6 @@ static inline void pgtable_cache_init(void) { } | |||
32 | static inline void check_pgt_cache(void) { } | 32 | static inline void check_pgt_cache(void) { } |
33 | void paging_init(void); | 33 | void paging_init(void); |
34 | 34 | ||
35 | extern void set_pmd_pfn(unsigned long, unsigned long, pgprot_t); | ||
36 | |||
37 | |||
38 | /* | 35 | /* |
39 | * Define this if things work differently on an i386 and an i486: | 36 | * Define this if things work differently on an i386 and an i486: |
40 | * it will (on an i486) warn about kernel memory accesses that are | 37 | * it will (on an i486) warn about kernel memory accesses that are |
diff --git a/arch/x86/mm/pgtable_32.c b/arch/x86/mm/pgtable_32.c index 4dd8cf652579..75cc0978d45d 100644 --- a/arch/x86/mm/pgtable_32.c +++ b/arch/x86/mm/pgtable_32.c | |||
@@ -59,41 +59,6 @@ void set_pte_vaddr(unsigned long vaddr, pte_t pteval) | |||
59 | __flush_tlb_one(vaddr); | 59 | __flush_tlb_one(vaddr); |
60 | } | 60 | } |
61 | 61 | ||
62 | /* | ||
63 | * Associate a large virtual page frame with a given physical page frame | ||
64 | * and protection flags for that frame. pfn is for the base of the page, | ||
65 | * vaddr is what the page gets mapped to - both must be properly aligned. | ||
66 | * The pmd must already be instantiated. Assumes PAE mode. | ||
67 | */ | ||
68 | void set_pmd_pfn(unsigned long vaddr, unsigned long pfn, pgprot_t flags) | ||
69 | { | ||
70 | pgd_t *pgd; | ||
71 | pud_t *pud; | ||
72 | pmd_t *pmd; | ||
73 | |||
74 | if (vaddr & (PMD_SIZE-1)) { /* vaddr is misaligned */ | ||
75 | printk(KERN_WARNING "set_pmd_pfn: vaddr misaligned\n"); | ||
76 | return; /* BUG(); */ | ||
77 | } | ||
78 | if (pfn & (PTRS_PER_PTE-1)) { /* pfn is misaligned */ | ||
79 | printk(KERN_WARNING "set_pmd_pfn: pfn misaligned\n"); | ||
80 | return; /* BUG(); */ | ||
81 | } | ||
82 | pgd = swapper_pg_dir + pgd_index(vaddr); | ||
83 | if (pgd_none(*pgd)) { | ||
84 | printk(KERN_WARNING "set_pmd_pfn: pgd_none\n"); | ||
85 | return; /* BUG(); */ | ||
86 | } | ||
87 | pud = pud_offset(pgd, vaddr); | ||
88 | pmd = pmd_offset(pud, vaddr); | ||
89 | set_pmd(pmd, pfn_pmd(pfn, flags)); | ||
90 | /* | ||
91 | * It's enough to flush this one mapping. | ||
92 | * (PGE mappings get flushed as well) | ||
93 | */ | ||
94 | __flush_tlb_one(vaddr); | ||
95 | } | ||
96 | |||
97 | unsigned long __FIXADDR_TOP = 0xfffff000; | 62 | unsigned long __FIXADDR_TOP = 0xfffff000; |
98 | EXPORT_SYMBOL(__FIXADDR_TOP); | 63 | EXPORT_SYMBOL(__FIXADDR_TOP); |
99 | 64 | ||