diff --git a/arch/sh/include/asm/fixmap.h b/arch/sh/include/asm/fixmap.h index bd7e79a1265345691caf54cc4e1d21198e7e0adf..5f1ca55bcec8bba7f196ddf6eb02fc9a80302b29 100644 --- a/arch/sh/include/asm/fixmap.h +++ b/arch/sh/include/asm/fixmap.h @@ -94,7 +94,7 @@ extern void __clear_fixmap(enum fixed_addresses idx, pgprot_t flags); * at the top of mem.. */ #ifdef CONFIG_SUPERH32 -#define FIXADDR_TOP (P4SEG - PAGE_SIZE) +#define FIXADDR_TOP (P3_ADDR_MAX - PAGE_SIZE) #else #define FIXADDR_TOP (0xff000000 - PAGE_SIZE) #endif diff --git a/arch/sh/mm/fault_32.c b/arch/sh/mm/fault_32.c index a469b95e88fba8af16dc1d572c63b4e88aa7fbb4..39e291c6b352007231f2408f3446c4cb85acb426 100644 --- a/arch/sh/mm/fault_32.c +++ b/arch/sh/mm/fault_32.c @@ -168,8 +168,8 @@ static noinline int vmalloc_fault(unsigned long address) pmd_t *pmd_k; pte_t *pte_k; - /* Make sure we are in vmalloc/module/P3 area: */ - if (!(address >= P3SEG && address < P3_ADDR_MAX)) + /* Make sure we are in vmalloc/module area: */ + if (!is_vmalloc_addr((void *)address)) return -1; /*