Commit 9859f0c7 authored by Aneesh Kumar K.V's avatar Aneesh Kumar K.V Committed by Michael Ellerman

powerpc/mm: Remove the debug hugepd_ok check

We don't do this for other page table entries. So lets keep this simple
and always return false for hugepd check on a 64K page size config.
Signed-off-by: default avatarAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
parent 7a308bb3
...@@ -35,10 +35,6 @@ static inline int pgd_huge(pgd_t pgd) ...@@ -35,10 +35,6 @@ static inline int pgd_huge(pgd_t pgd)
} }
#define pgd_huge pgd_huge #define pgd_huge pgd_huge
#ifdef CONFIG_DEBUG_VM
extern int hugepd_ok(hugepd_t hpd);
#define is_hugepd(hpd) (hugepd_ok(hpd))
#else
/* /*
* With 64k page size, we have hugepage ptes in the pgd and pmd entries. We don't * With 64k page size, we have hugepage ptes in the pgd and pmd entries. We don't
* need to setup hugepage directory for them. Our pte and page directory format * need to setup hugepage directory for them. Our pte and page directory format
...@@ -49,7 +45,6 @@ static inline int hugepd_ok(hugepd_t hpd) ...@@ -49,7 +45,6 @@ static inline int hugepd_ok(hugepd_t hpd)
return 0; return 0;
} }
#define is_hugepd(pdep) 0 #define is_hugepd(pdep) 0
#endif /* CONFIG_DEBUG_VM */
#endif /* CONFIG_HUGETLB_PAGE */ #endif /* CONFIG_HUGETLB_PAGE */
......
...@@ -116,24 +116,3 @@ int __hash_page_huge(unsigned long ea, unsigned long access, unsigned long vsid, ...@@ -116,24 +116,3 @@ int __hash_page_huge(unsigned long ea, unsigned long access, unsigned long vsid,
*ptep = __pte(new_pte & ~H_PAGE_BUSY); *ptep = __pte(new_pte & ~H_PAGE_BUSY);
return 0; return 0;
} }
#if defined(CONFIG_PPC_64K_PAGES) && defined(CONFIG_DEBUG_VM)
/*
* This enables us to catch the wrong page directory format
* Moved here so that we can use WARN() in the call.
*/
int hugepd_ok(hugepd_t hpd)
{
bool is_hugepd;
unsigned long hpdval;
hpdval = hpd_val(hpd);
/*
* We should not find this format in page directory, warn otherwise.
*/
is_hugepd = (((hpdval & 0x3) == 0x0) && ((hpdval & HUGEPD_SHIFT_MASK) != 0));
WARN(is_hugepd, "Found wrong page directory format\n");
return 0;
}
#endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment