Messages in this thread Patch in this message | | | From | Al Viro <> | Subject | [POC][PATCH 62/83] m68k: switch pte_alloc_one_kernel() to get_free_page() | Date | Mon, 21 Dec 2015 23:47:35 +0000 |
| |
From: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> --- arch/m68k/include/asm/mcf_pgalloc.h | 6 +++--- arch/m68k/include/asm/sun3_pgalloc.h | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/arch/m68k/include/asm/mcf_pgalloc.h b/arch/m68k/include/asm/mcf_pgalloc.h index 04ffc22..e08cac3 100644 --- a/arch/m68k/include/asm/mcf_pgalloc.h +++ b/arch/m68k/include/asm/mcf_pgalloc.h @@ -14,13 +14,13 @@ extern const char bad_pmd_string[]; extern inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm, unsigned long address) { - unsigned long page = __get_free_page(GFP_DMA|__GFP_REPEAT); + pte_t *page = get_free_page(GFP_DMA|__GFP_REPEAT); if (!page) return NULL; - memset((void *)page, 0, PAGE_SIZE); - return (pte_t *) (page); + memset(page, 0, PAGE_SIZE); + return page; } extern inline pmd_t *pmd_alloc_kernel(pgd_t *pgd, unsigned long address) diff --git a/arch/m68k/include/asm/sun3_pgalloc.h b/arch/m68k/include/asm/sun3_pgalloc.h index ab0fd5c..9140b29 100644 --- a/arch/m68k/include/asm/sun3_pgalloc.h +++ b/arch/m68k/include/asm/sun3_pgalloc.h @@ -37,13 +37,13 @@ do { \ static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm, unsigned long address) { - unsigned long page = __get_free_page(GFP_KERNEL|__GFP_REPEAT); + pte_t *page = get_free_page(GFP_KERNEL|__GFP_REPEAT); if (!page) return NULL; - memset((void *)page, 0, PAGE_SIZE); - return (pte_t *) (page); + memset(page, 0, PAGE_SIZE); + return page; } static inline pgtable_t pte_alloc_one(struct mm_struct *mm, -- 2.1.4
| |