diff options
author | Scott Wood <scottwood@freescale.com> | 2015-04-17 16:17:14 -0500 |
---|---|---|
committer | Scott Wood <scottwood@freescale.com> | 2015-06-02 21:37:23 -0500 |
commit | 6c0cc62715bfd0b26f7d1a79e6e8143085950ca7 (patch) | |
tree | ff32cd626c2c2a198eae6f6336d4a63c800004c0 | |
parent | 86c3b16e9f330c94062c40302ab266f0d932057e (diff) | |
download | op-kernel-dev-6c0cc62715bfd0b26f7d1a79e6e8143085950ca7.zip op-kernel-dev-6c0cc62715bfd0b26f7d1a79e6e8143085950ca7.tar.gz |
powerpc/mm: Use PFN_PHYS() in devmem_is_allowed()
This function can run on systems where physical addresses don't
fit in unsigned long, so make sure to use the macro that contains the
proper cast.
Signed-off-by: Scott Wood <scottwood@freescale.com>
-rw-r--r-- | arch/powerpc/mm/mem.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c index 45fda71..0f11819 100644 --- a/arch/powerpc/mm/mem.c +++ b/arch/powerpc/mm/mem.c @@ -560,7 +560,7 @@ subsys_initcall(add_system_ram_resources); */ int devmem_is_allowed(unsigned long pfn) { - if (iomem_is_exclusive(pfn << PAGE_SHIFT)) + if (iomem_is_exclusive(PFN_PHYS(pfn))) return 0; if (!page_is_ram(pfn)) return 1; |