Skip to content

Commit

Permalink
powerpc: ARCH_PFN_OFFSET should be unsigned long
Browse files Browse the repository at this point in the history
pfns are unsigned long, but MEMORY_START is phys_addr_t.  This leads
to page_to_pfn() returning phys_addr_t, and thus type mismatches in a few
print statements.

Signed-off-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
  • Loading branch information
Scott Wood authored and Benjamin Herrenschmidt committed Mar 29, 2011
1 parent 6090912 commit 67eb549
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/powerpc/include/asm/page.h
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ extern phys_addr_t kernstart_addr;
#endif

#ifdef CONFIG_FLATMEM
#define ARCH_PFN_OFFSET (MEMORY_START >> PAGE_SHIFT)
#define ARCH_PFN_OFFSET ((unsigned long)(MEMORY_START >> PAGE_SHIFT))
#define pfn_valid(pfn) ((pfn) >= ARCH_PFN_OFFSET && (pfn) < max_mapnr)
#endif

Expand Down

0 comments on commit 67eb549

Please sign in to comment.