HIGHMEM fix for r24k
For all you guys working on HIGMEM.
I found a bug that was keeping HIGHMEM from working on mips 24k processors starting at 2.6.26.
2008-04-28 Chris Dearman [MIPS] Allow setting of the cache attribute at run ...
This commit introduces the variable _page_cachable_default, which defaults to zero.
arch/mips/mm/cache.c:
unsigned long _page_cachable_default;
The variable is used to create the prototype PTE for __kmap_atomic in arch/mips/mm/init.c:kmap_init.
The variable is initialized in arch/mips/mm/c-r4k.c:coherency_setup.
Unfortunately, the variable is used before it is initialized properly. As a result, all kmap_atomic PTE have the cache coherency algorithm mode set to 0. Mode 0 is "cacheable, nocoherent, write-through, no write allocate". This is not valid on my r24k and my not be on any r24k.
The result is that writes to kmap_atomic pages get corrupted. This was confirmed using a jtag probe, examining uncached memory, the D cache itself, and cached memory.
I've changed the variable declaration to be:
unsigned long _page_cachable_default = _CACHE_CACHABLE_NONCOHERENT;
My highmem kernel now works. This is w/o discontiguous or sparsemem set. I do have two discontiguous banks of memory.
I'm not sure of the best fix. Simple reordering of the the init code to set the variable before it gets used breaks other initialization.
My kernel tree is a big mess right now and I'm back at 2.6.26 where the bug was introduce. As soon as I have 2.6.28 or 29 working, I'll post any more changes.
Jon Fraser
Broadcom
Quoted 20 lines · Jon Fraser
For all you guys working on HIGMEM.
I found a bug that was keeping HIGHMEM from working on mips 24k processors starting at 2.6.26.
2008-04-28 Chris Dearman [MIPS] Allow setting of the cache attribute at run ...
This commit introduces the variable
_page_cachable_default, which defaults to zero.
arch/mips/mm/cache.c:unsigned long _page_cachable_default;The variable is used to create the prototype PTE for
__kmap_atomicin arch/mips/mm/init.c:kmap_init.The variable is initialized in arch/mips/mm/c-r4k.c:coherency_setup.
Quoted 7 lines
Unfortunately, the variable is used before it is initialized properly. As a result, all
kmap_atomicPTE have the cache coherency algorithm mode set to 0. Mode 0 is "cacheable, nocoherent, write-through, no write allocate". This is not valid on my r24k and my not be on any r24k.The result is that writes to
kmap_atomicpages get corrupted. This was confirmed using a jtag probe, examining uncached memory, the D cache itself, and cached memory.
Ouch, sounds like a nasty bit of work finding this...thanks!
Quoted 2 lines
Jon Fraser
Broadcom
David VomLehn
Quoted 25 lines · Jon Fraser
For all you guys working on HIGMEM.
I found a bug that was keeping HIGHMEM from working on mips 24k processors starting at 2.6.26.
2008-04-28 Chris Dearman [MIPS] Allow setting of the cache attribute at run ...
This commit introduces the variable
_page_cachable_default, which defaults to zero.
arch/mips/mm/cache.c:unsigned long _page_cachable_default;The variable is used to create the prototype PTE for
__kmap_atomicin arch/mips/mm/init.c:kmap_init.The variable is initialized in arch/mips/mm/c-r4k.c:coherency_setup.
Unfortunately, the variable is used before it is initialized properly. As a result, all
kmap_atomicPTE have the cache coherency algorithm mode set to 0. Mode 0 is "cacheable, nocoherent, write-through, no write allocate". This is not valid on my r24k and my not be on any r24k.
Quoted 5 lines
The result is that writes to
kmap_atomicpages get corrupted. This was confirmed using a jtag probe, examining uncached memory, the D cache itself, and cached memory.I've changed the variable declaration to be:
unsigned long_page_cachable_default=_CACHE_CACHABLE_NONCOHERENT;
There is no safe value of _page_cachable_default; it's all processor and even platform dependent. What you found is essentially an ordering bug so let's fix the ordering!
Ralf
Quoted 30 lines · Ralf Baechle
Quoted 28 lines · Jon Fraser
For all you guys working on HIGMEM.
I found a bug that was keeping HIGHMEM from working on mips 24k processors starting at 2.6.26.
2008-04-28 Chris Dearman [MIPS] Allow setting of the cache attribute at run ...
This commit introduces the variable
_page_cachable_default, which defaults to zero.
arch/mips/mm/cache.c:unsigned long _page_cachable_default;The variable is used to create the prototype PTE for
__kmap_atomicin arch/mips/mm/init.c:kmap_init.The variable is initialized in arch/mips/mm/c-r4k.c:coherency_setup.
Unfortunately, the variable is used before it is initialized properly. As a result, all
kmap_atomicPTE have the cache coherency algorithm mode set to 0. Mode 0 is "cacheable, nocoherent, write-through, no write allocate". This is not valid on my r24k and my not be on any r24k.The result is that writes to
kmap_atomicpages get corrupted. This was confirmed using a jtag probe, examining uncached memory, the D cache itself, and cached memory.
Quoted 9 lines
Quoted 2 lines
I've changed the variable declaration to be:
unsigned long_page_cachable_default=_CACHE_CACHABLE_NONCOHERENT;There is no safe value of
_page_cachable_default; it's all processor and even platform dependent. What you found is essentially an ordering bug so let's fix the ordering!Ralf
That's why I haven't proposed a fix yet. But there are other people dealing with the same HIGHMEM issues and I wanted them to know about the problem.
Jon
Quoted 3 lines · Jon Fraser
That's why I haven't proposed a fix yet. But there are other people dealing with the same HIGHMEM issues and I wanted them to know about the problem.
Can you test below fix? Thanks,
Ralf
arch/mips/include/asm/fixmap.h | 3 +++ arch/mips/include/asm/highmem.h | 6 ++++-- arch/mips/mm/highmem.c | 25 +++++++++++++++++++------ arch/mips/mm/init.c | 26 -------------------------- 4 files changed, 26 insertions(+), 34 deletions(-)
arch/mips/include/asm/fixmap.h +3 -0
@@ -108,6 +108,9 @@ static inline unsigned long virt_to_fix(const unsigned long vaddr)return __virt_to_fix (vaddr); } +#define kmap_get_fixmap_pte (vaddr) \ + pte_offset_kernel(pmd_offset(pud_offset(pgd_offset_k(vaddr), (vaddr)), (vaddr)), (vaddr)) +/* * Called from pgtable_init() */
arch/mips/include/asm/highmem.h +4 -2
@@ -30,8 +30,6 @@/* declarations for highmem.c */ extern unsigned long highstart_pfn, highend_pfn; -extern pte_t *kmap_pte; -extern pgprot_t kmap_prot;extern pte_t *pkmap_page_table;/*
@@ -62,6 +60,10 @@ extern struct page *__kmap_atomic_to_page(void *ptr);#define flush_cache_kmaps () flush_cache_all() +extern void kmap_init (void ); + +#define kmap_prot PAGE_KERNEL +#endif /* __KERNEL__ */ #endif /* _ASM_HIGHMEM_H */
arch/mips/mm/highmem.c +19 -6
@@ -1,7 +1,12 @@#include <linux/module.h> #include <linux/highmem.h> +#include <asm/fixmap.h> #include <asm/tlbflush.h> +static pte_t *kmap_pte; + +unsigned long highstart_pfn, highend_pfn; +void *__kmap (struct page *page) {void *addr;
@@ -14,6 +19,7 @@ void *__kmap(struct page *page)return addr; } +EXPORT_SYMBOL (__kmap);void __kunmap (struct page *page) {
@@ -22,6 +28,7 @@ void __kunmap(struct page *page)return ;kunmap_high (page); } +EXPORT_SYMBOL (__kunmap);/* * kmap_atomic/kunmap_atomic is significantly faster than kmap/kunmap because
@@ -48,11 +55,12 @@ void *__kmap_atomic(struct page *page, enum km_type type)#ifdef CONFIG_DEBUG_HIGHMEM BUG_ON (!pte_none (*(kmap_pte - idx)));#endif -set_pte (kmap_pte-idx,mk_pte (page, kmap_prot)); +set_pte (kmap_pte-idx,mk_pte (page,PAGE_KERNEL ));local_flush_tlb_one ((unsigned long )vaddr);return (void *) vaddr; } +EXPORT_SYMBOL (__kmap_atomic);void __kunmap_atomic (void *kvaddr,enum km_type type) {
@@ -77,6 +85,7 @@ void __kunmap_atomic(void *kvaddr, enum km_type type)pagefault_enable (); } +EXPORT_SYMBOL (__kunmap_atomic);/* * This is the same as kmap_atomic() but can map memory that doesn't
@@ -92,7 +101,7 @@ void *kmap_atomic_pfn(unsigned long pfn, enum km_type type)debug_kmap_atomic (type); idx = type +KM_TYPE_NR *smp_processor_id (); vaddr =__fix_to_virt (FIX_KMAP_BEGIN + idx); -set_pte (kmap_pte-idx,pfn_pte (pfn, kmap_prot)); +set_pte (kmap_pte-idx,pfn_pte (pfn,PAGE_KERNEL ));flush_tlb_one (vaddr);return (void *) vaddr;
@@ -111,7 +120,11 @@ struct page *__kmap_atomic_to_page(void *ptr)return pte_page (*pte); } -EXPORT_SYMBOL (__kmap); -EXPORT_SYMBOL (__kunmap); -EXPORT_SYMBOL (__kmap_atomic); -EXPORT_SYMBOL (__kunmap_atomic); +void __init kmap_init (void ) +{ +unsigned long kmap_vstart; + +/* cache the first kmap pte */ + kmap_vstart =__fix_to_virt (FIX_KMAP_BEGIN ); + kmap_pte =kmap_get_fixmap_pte (kmap_vstart); +}
arch/mips/mm/init.c +0 -26
@@ -104,14 +104,6 @@ unsigned long setup_zero_pages(void)return 1UL << order; } -/* -* These are almost like kmap_atomic / kunmap_atmic except they take an -* additional address argument as the hint. -*/ - -#define kmap_get_fixmap_pte (vaddr) \ - pte_offset_kernel(pmd_offset(pud_offset(pgd_offset_k(vaddr), (vaddr)), (vaddr)), (vaddr)) -#ifdef CONFIG_MIPS_MT_SMTC static pte_t *kmap_coherent_pte;static void __init kmap_coherent_init (void )
@@ -264,24 +256,6 @@ void copy_from_user_page(struct vm_area_struct *vma, } } -#ifdef CONFIG_HIGHMEM -unsigned long highstart_pfn, highend_pfn; - -pte_t *kmap_pte; -pgprot_t kmap_prot; - -static void __init kmap_init (void ) -{ -unsigned long kmap_vstart; - -/* cache the first kmap pte */ - kmap_vstart =__fix_to_virt (FIX_KMAP_BEGIN ); - kmap_pte =kmap_get_fixmap_pte (kmap_vstart); - - kmap_prot =PAGE_KERNEL ; -} -#endif /* CONFIG_HIGHMEM */ -void __init fixrange_init (unsigned long start,unsigned long end,pgd_t *pgd_base) {
Hi Ralf,
Just wanted to acknowledge your email. I've been playing catch
up for the last week after spending a large amount of unscheduled time finding the root cause of this bug. I should be able to get to applying this patch this week. Were these against HOT or 2.6.29?
Jon
Quoted 181 lines · Ralf Baechle
Quoted 3 lines · Jon Fraser
That's why I haven't proposed a fix yet. But there are other people dealing with the same HIGHMEM issues and I wanted them to know about the problem.
Can you test below fix? Thanks,
Ralf
Signed-off-by Ralf Baechle <[email protected]>arch/mips/include/asm/fixmap.h | 3 +++ arch/mips/include/asm/highmem.h | 6 ++++-- arch/mips/mm/highmem.c | 25 +++++++++++++++++++------ arch/mips/mm/init.c | 26 -------------------------- 4 files changed, 26 insertions(+), 34 deletions(-)arch/mips/include/asm/fixmap.h +3
-0@@ -108,6 +108,9 @@ static inline unsigned long virt_to_fix(const unsigned long vaddr)return __virt_to_fix (vaddr); } +#define kmap_get_fixmap_pte (vaddr) \ + pte_offset_kernel(pmd_offset(pud_offset(pgd_offset_k(vaddr), (vaddr)), (vaddr)), (vaddr)) +/* * Called from pgtable_init() */ arch/mips/include/asm/highmem.h +4
-2@@ -30,8 +30,6 @@/* declarations for highmem.c */ extern unsigned long highstart_pfn, highend_pfn; -extern pte_t *kmap_pte; -extern pgprot_t kmap_prot;extern pte_t *pkmap_page_table;/* @@ -62,6 +60,10 @@ extern struct page *__kmap_atomic_to_page(void *ptr);#define flush_cache_kmaps () flush_cache_all() +extern void kmap_init (void ); + +#define kmap_prot PAGE_KERNEL +#endif /* __KERNEL__ */ #endif /* _ASM_HIGHMEM_H */ arch/mips/mm/highmem.c +19
-6@@ -1,7 +1,12 @@#include <linux/module.h> #include <linux/highmem.h> +#include <asm/fixmap.h> #include <asm/tlbflush.h> +static pte_t *kmap_pte; + +unsigned long highstart_pfn, highend_pfn; +void *__kmap (struct page *page) {void *addr;@@ -14,6 +19,7 @@ void *__kmap(struct page *page)return addr; } +EXPORT_SYMBOL (__kmap);void __kunmap (struct page *page) {@@ -22,6 +28,7 @@ void __kunmap(struct page *page)return ;kunmap_high (page); } +EXPORT_SYMBOL (__kunmap);/* * kmap_atomic/kunmap_atomic is significantly faster than kmap/kunmap because @@ -48,11 +55,12 @@ void *__kmap_atomic(struct page *page, enum km_type type)#ifdef CONFIG_DEBUG_HIGHMEM BUG_ON (!pte_none (*(kmap_pte - idx)));#endif -set_pte (kmap_pte-idx,mk_pte (page, kmap_prot)); +set_pte (kmap_pte-idx,mk_pte (page,PAGE_KERNEL ));local_flush_tlb_one ((unsigned long )vaddr);return (void *) vaddr; } +EXPORT_SYMBOL (__kmap_atomic);void __kunmap_atomic (void *kvaddr,enum km_type type) {@@ -77,6 +85,7 @@ void __kunmap_atomic(void *kvaddr, enum km_type type)pagefault_enable (); } +EXPORT_SYMBOL (__kunmap_atomic);/* * This is the same as kmap_atomic() but can map memory that doesn't @@ -92,7 +101,7 @@ void *kmap_atomic_pfn(unsigned long pfn, enum km_type type)debug_kmap_atomic (type); idx = type +KM_TYPE_NR *smp_processor_id (); vaddr =__fix_to_virt (FIX_KMAP_BEGIN + idx); -set_pte (kmap_pte-idx,pfn_pte (pfn, kmap_prot)); +set_pte (kmap_pte-idx,pfn_pte (pfn,PAGE_KERNEL ));flush_tlb_one (vaddr);return (void *) vaddr;@@ -111,7 +120,11 @@ struct page *__kmap_atomic_to_page(void *ptr)return pte_page (*pte); } -EXPORT_SYMBOL (__kmap); -EXPORT_SYMBOL (__kunmap); -EXPORT_SYMBOL (__kmap_atomic); -EXPORT_SYMBOL (__kunmap_atomic); +void __init kmap_init (void ) +{ +unsigned long kmap_vstart; + +/* cache the first kmap pte */ + kmap_vstart =__fix_to_virt (FIX_KMAP_BEGIN ); + kmap_pte =kmap_get_fixmap_pte (kmap_vstart); +}arch/mips/mm/init.c +0
-26@@ -104,14 +104,6 @@ unsigned long setup_zero_pages(void)return 1UL << order; } -/* -* These are almost like kmap_atomic / kunmap_atmic except they take an -* additional address argument as the hint. -*/ - -#define kmap_get_fixmap_pte (vaddr) \ - pte_offset_kernel(pmd_offset(pud_offset(pgd_offset_k(vaddr), (vaddr)), (vaddr)), (vaddr)) -#ifdef CONFIG_MIPS_MT_SMTC static pte_t *kmap_coherent_pte;static void __init kmap_coherent_init (void )@@ -264,24 +256,6 @@ void copy_from_user_page(struct vm_area_struct *vma, } } -#ifdef CONFIG_HIGHMEM -unsigned long highstart_pfn, highend_pfn; - -pte_t *kmap_pte; -pgprot_t kmap_prot; - -static void __init kmap_init (void ) -{ -unsigned long kmap_vstart; - -/* cache the first kmap pte */ - kmap_vstart =__fix_to_virt (FIX_KMAP_BEGIN ); - kmap_pte =kmap_get_fixmap_pte (kmap_vstart); - - kmap_prot =PAGE_KERNEL ; -} -#endif /* CONFIG_HIGHMEM */ -void __init fixrange_init (unsigned long start,unsigned long end,pgd_t *pgd_base) {
I applied it against the head of tree, but it didn't work. I've been too tied up with other things, though, so I haven't been able to dig into it. It is entirely possible that there is nothing wrong with the patch.
Quoted 225 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Jon Fraser
Sent: Monday, May 04, 2009 7:50 AM
To: Ralf Baechle
Cc: [email protected]; [email protected]
Subject: Re: HIGHMEM fix for r24kHi Ralf,
Just wanted to acknowledge your email. I've been
playing catch
up for the last week after spending a large amount of unscheduled time finding the root cause of this bug. I should be able to get to applying
this patch this week. Were these against HOT or 2.6.29?Jon
Quoted 3 lines · Ralf Baechle
Quoted 1 line · Jon Fraser
That's why I haven't proposed a fix yet. But there are
other people
Quoted 1 line
Quoted 1 line
dealing with the same HIGHMEM issues and I wanted them to
know about the
Quoted 8 lines
Quoted 1 line
problem.
Can you test below fix? Thanks,
Ralf
Signed-off-by Ralf Baechle <[email protected]>Review
Quoted 7 lines
arch/mips/include/asm/fixmap.h | 3 +++ arch/mips/include/asm/highmem.h | 6 ++++-- arch/mips/mm/highmem.c | 25 +++++++++++++++++++------ arch/mips/mm/init.c | 26 -------------------------- 4 files changed, 26 insertions(+), 34 deletions(-)(quoted diff) +0
-0
b/arch/mips/include/asm/fixmap.harch/mips/include/asm/fixmap.h static inline unsigned long
Quoted 4 lines
index 9cc8522..0f5caa1 100644
arch/mips/include/asm/fixmap.h +0
-0@@ -108,6 +108,9 @@ static inline unsigned long
virt_to_fix(const unsigned long vaddr)arch/mips/include/asm/fixmap.h static inline unsigned long virt_to_fix(const unsigned long vaddr)
Quoted 4 lines
arch/mips/include/asm/fixmap.h +1
-0return __virt_to_fix (vaddr); } +#define kmap_get_fixmap_pte (vaddr)\arch/mips/include/asm/fixmap.h static inline unsigned long · line 112
Quoted 1 line
arch/mips/include/asm/fixmap.h +1
-0+
pte_offset_kernel(pmd_offset(pud_offset(pgd_offset_k(vaddr), (vaddr)), (vaddr)), (vaddr))Review
Quoted 5 lines
arch/mips/include/asm/fixmap.h +1
-0+/* * Called from pgtable_init() */ (quoted diff) +0
-0
b/arch/mips/include/asm/highmem.harch/mips/include/asm/highmem.h extern struct page
Quoted 13 lines
index 4374ab2..25adfb0 100644
arch/mips/include/asm/highmem.h +0
-2@@ -30,8 +30,6 @@/* declarations for highmem.c */ extern unsigned long highstart_pfn, highend_pfn; -extern pte_t *kmap_pte; -extern pgprot_t kmap_prot;extern pte_t *pkmap_page_table;/* @@ -62,6 +60,10 @@ extern struct page*__kmap_atomic_to_page(void *ptr);
Quoted 36 lines
arch/mips/include/asm/highmem.h +4
-0#define flush_cache_kmaps () flush_cache_all() +extern void kmap_init (void ); + +#define kmap_prot PAGE_KERNEL +#endif /* __KERNEL__ */ #endif /* _ASM_HIGHMEM_H */ arch/mips/mm/highmem.c +6
-0@@ -1,7 +1,12 @@#include <linux/module.h> #include <linux/highmem.h> +#include <asm/fixmap.h> #include <asm/tlbflush.h> +static pte_t *kmap_pte; + +unsigned long highstart_pfn, highend_pfn; +void *__kmap (struct page *page) {void *addr;@@ -14,6 +19,7 @@ void *__kmap(struct page *page)return addr; } +EXPORT_SYMBOL (__kmap);void __kunmap (struct page *page) {arch/mips/mm/highmem.c void __kunmap(struct page *page) · line 34
Quoted 7 lines
arch/mips/mm/highmem.c +1
-0@@ -22,6 +28,7 @@ void __kunmap(struct page *page)return ;kunmap_high (page); } +EXPORT_SYMBOL (__kunmap);/* * kmap_atomic/kunmap_atomic is significantly faster than kmap/kunmap because
arch/mips/mm/highmem.c void *__kmap_atomic(struct page *page,
Quoted 1 line
arch/mips/mm/highmem.c +0
-0@@ -48,11 +55,12 @@ void *__kmap_atomic(struct page *page,enum
km_typetype)arch/mips/mm/highmem.c void __kunmap_atomic(void *kvaddr, enum
Quoted 14 lines
arch/mips/mm/highmem.c +2
-1#ifdef CONFIG_DEBUG_HIGHMEM BUG_ON (!pte_none (*(kmap_pte - idx)));#endif -set_pte (kmap_pte-idx,mk_pte (page, kmap_prot)); +set_pte (kmap_pte-idx,mk_pte (page,PAGE_KERNEL ));local_flush_tlb_one ((unsigned long )vaddr);return (void *) vaddr; } +EXPORT_SYMBOL (__kmap_atomic);void __kunmap_atomic (void *kvaddr,enum km_type type) {@@ -77,6 +85,7 @@ void __kunmap_atomic(void *kvaddr, enum
km_typetype)arch/mips/mm/highmem.c void __kunmap_atomic(void *kvaddr, enum km_type type)
Quoted 7 lines
arch/mips/mm/highmem.c +1
-0pagefault_enable (); } +EXPORT_SYMBOL (__kunmap_atomic);/* * This is the same as kmap_atomic() but can map memory that doesn't
arch/mips/mm/highmem.c void *kmap_atomic_pfn(unsigned long pfn,
Quoted 1 line
arch/mips/mm/highmem.c +0
-0@@ -92,7 +101,7 @@ void *kmap_atomic_pfn(unsigned long pfn,enum
km_typetype)Quoted 29 lines
arch/mips/mm/highmem.c +9
-5debug_kmap_atomic (type); idx = type +KM_TYPE_NR *smp_processor_id (); vaddr =__fix_to_virt (FIX_KMAP_BEGIN + idx); -set_pte (kmap_pte-idx,pfn_pte (pfn, kmap_prot)); +set_pte (kmap_pte-idx,pfn_pte (pfn,PAGE_KERNEL ));flush_tlb_one (vaddr);return (void *) vaddr;@@ -111,7 +120,11 @@ struct page *__kmap_atomic_to_page(void *ptr)return pte_page (*pte); } -EXPORT_SYMBOL (__kmap); -EXPORT_SYMBOL (__kunmap); -EXPORT_SYMBOL (__kmap_atomic); -EXPORT_SYMBOL (__kunmap_atomic); +void __init kmap_init (void ) +{ +unsigned long kmap_vstart; + +/* cache the first kmap pte */ + kmap_vstart =__fix_to_virt (FIX_KMAP_BEGIN ); + kmap_pte =kmap_get_fixmap_pte (kmap_vstart); +}arch/mips/mm/init.c +0
-0arch/mips/mm/init.c unsigned long setup_zero_pages(void) · line 108
Quoted 5 lines
arch/mips/mm/init.c +0
-2@@ -104,14 +104,6 @@ unsigned long setup_zero_pages(void)return 1UL << order; } -/* -* These are almost like kmap_atomic / kunmap_atmic except they take an
arch/mips/mm/init.c unsigned long setup_zero_pages(void)
Quoted 4 lines
arch/mips/mm/init.c +0
-4-* additional address argument as the hint. -*/ - -#define kmap_get_fixmap_pte (vaddr)\arch/mips/mm/init.c unsigned long setup_zero_pages(void) · line 113
Quoted 1 line
arch/mips/mm/init.c +0
-1-
pte_offset_kernel(pmd_offset(pud_offset(pgd_offset_k(vaddr), (vaddr)), (vaddr)), (vaddr))arch/mips/mm/init.c void copy_from_user_page(struct
Quoted 5 lines
arch/mips/mm/init.c +0
-1-#ifdef CONFIG_MIPS_MT_SMTC static pte_t *kmap_coherent_pte;static void __init kmap_coherent_init (void )@@ -264,24 +256,6 @@ void copy_from_user_page(struct
vm_area_struct*vma,Quoted 25 lines
arch/mips/mm/init.c +0
-18} } -#ifdef CONFIG_HIGHMEM -unsigned long highstart_pfn, highend_pfn; - -pte_t *kmap_pte; -pgprot_t kmap_prot; - -static void __init kmap_init (void ) -{ -unsigned long kmap_vstart; - -/* cache the first kmap pte */ - kmap_vstart =__fix_to_virt (FIX_KMAP_BEGIN ); - kmap_pte =kmap_get_fixmap_pte (kmap_vstart); - - kmap_prot =PAGE_KERNEL ; -} -#endif /* CONFIG_HIGHMEM */ -void __init fixrange_init (unsigned long start,unsigned long end,pgd_t *pgd_base) {