[ARM] remove bogus #ifdef CONFIG_HIGHMEM in show_pte()
The restriction on !CONFIG_HIGHMEM is unneeded since page tables are currently never allocated with highmem pages, and actually disable PTE dump whenever highmem is configured. Let's have a dynamic test to better describe the current limitation instead. Signed-off-by: Nicolas Pitre <nico@marvell.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
This commit is contained in:
committed by
Russell King
parent
9210807cb5
commit
252d4c276d
@@ -14,6 +14,7 @@
|
|||||||
#include <linux/init.h>
|
#include <linux/init.h>
|
||||||
#include <linux/kprobes.h>
|
#include <linux/kprobes.h>
|
||||||
#include <linux/uaccess.h>
|
#include <linux/uaccess.h>
|
||||||
|
#include <linux/page-flags.h>
|
||||||
|
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
#include <asm/pgtable.h>
|
#include <asm/pgtable.h>
|
||||||
@@ -83,13 +84,14 @@ void show_pte(struct mm_struct *mm, unsigned long addr)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef CONFIG_HIGHMEM
|
|
||||||
/* We must not map this if we have highmem enabled */
|
/* We must not map this if we have highmem enabled */
|
||||||
|
if (PageHighMem(pfn_to_page(pmd_val(*pmd) >> PAGE_SHIFT)))
|
||||||
|
break;
|
||||||
|
|
||||||
pte = pte_offset_map(pmd, addr);
|
pte = pte_offset_map(pmd, addr);
|
||||||
printk(", *pte=%08lx", pte_val(*pte));
|
printk(", *pte=%08lx", pte_val(*pte));
|
||||||
printk(", *ppte=%08lx", pte_val(pte[-PTRS_PER_PTE]));
|
printk(", *ppte=%08lx", pte_val(pte[-PTRS_PER_PTE]));
|
||||||
pte_unmap(pte);
|
pte_unmap(pte);
|
||||||
#endif
|
|
||||||
} while(0);
|
} while(0);
|
||||||
|
|
||||||
printk("\n");
|
printk("\n");
|
||||||
|
Reference in New Issue
Block a user