From 8f5a0b9dffeb3cb94f2b0622b6fe0717512ef54b Mon Sep 17 00:00:00 2001 From: Richard Kuo Date: Fri, 22 Mar 2013 16:05:40 -0500 Subject: Hexagon: add support for ARCH_PFN_OFFSET Add support for loading the kernel at a physical offset. The offset should still be 4M aligned. Signed-off-by: Richard Kuo --- arch/hexagon/include/asm/page.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'arch/hexagon/include/asm/page.h') diff --git a/arch/hexagon/include/asm/page.h b/arch/hexagon/include/asm/page.h index 692adc213429..de1b2871d09c 100644 --- a/arch/hexagon/include/asm/page.h +++ b/arch/hexagon/include/asm/page.h @@ -96,8 +96,8 @@ typedef struct page *pgtable_t; * MIPS says they're only used during mem_init. * also, check if we need a PHYS_OFFSET. */ -#define __pa(x) ((unsigned long)(x) - PAGE_OFFSET) -#define __va(x) ((void *)((unsigned long)(x) + PAGE_OFFSET)) +#define __pa(x) ((unsigned long)(x) - PAGE_OFFSET + PHYS_OFFSET) +#define __va(x) ((void *)((unsigned long)(x) - PHYS_OFFSET + PAGE_OFFSET)) /* The "page frame" descriptor is defined in linux/mm.h */ struct page; @@ -147,6 +147,7 @@ static inline void clear_page(void *page) */ #define kern_addr_valid(addr) (1) +#include #include /* XXX Todo: implement assembly-optimized version of getorder. */ #include -- cgit v1.2.1