Commit f65e67c7 authored by Jonathan Neuschäfer's avatar Jonathan Neuschäfer Committed by Michael Ellerman

powerpc/mm: Use memblock API for PPC32 page_is_ram

To support accurate checking for different blocks of memory on PPC32,
use the same memblock-based approach that's already used on PPC64 also
on PPC32.
Signed-off-by: default avatarJonathan Neuschäfer <j.neuschaefer@gmx.net>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
parent 2615c93e
......@@ -82,11 +82,7 @@ static inline pte_t *virt_to_kpte(unsigned long vaddr)
int page_is_ram(unsigned long pfn)
{
#ifndef CONFIG_PPC64 /* XXX for now */
return pfn < max_pfn;
#else
return memblock_is_memory(__pfn_to_phys(pfn));
#endif
}
pgprot_t phys_mem_access_prot(struct file *file, unsigned long pfn,
......
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