summaryrefslogtreecommitdiffstats
path: root/arch/hexagon/include/asm/page.h
diff options
context:
space:
mode:
Diffstat (limited to 'arch/hexagon/include/asm/page.h')
-rw-r--r--arch/hexagon/include/asm/page.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/hexagon/include/asm/page.h b/arch/hexagon/include/asm/page.h
index f3b26f14a7c7..93f5669b4aa1 100644
--- a/arch/hexagon/include/asm/page.h
+++ b/arch/hexagon/include/asm/page.h
@@ -140,6 +140,11 @@ static inline void clear_page(void *page)
*/
#define page_to_phys(page) (page_to_pfn(page) << PAGE_SHIFT)
+#define virt_to_pfn(kaddr) (__pa(kaddr) >> PAGE_SHIFT)
+#define pfn_to_virt(pfn) __va((pfn) << PAGE_SHIFT)
+
+#define page_to_virt(page) __va(page_to_phys(page))
+
/*
* For port to Hexagon Virtual Machine, MAYBE we check for attempts
* to reference reserved HVM space, but in any case, the VM will be
OpenPOWER on IntegriCloud