arm64: Direct access to Mckernel memory from Linux.

Change-Id: I1a096aa5232c56382ae19d8c4e4f41d4e3e9f660
This commit is contained in:
Shiratori, Takehiro
2019-02-26 17:17:46 +09:00
committed by Dominique Martinet
parent 20d5900c35
commit aa3c5e91db
9 changed files with 32 additions and 28 deletions

View File

@@ -55,13 +55,14 @@ uintptr_t virt_to_phys(uintptr_t va)
{
extern uintptr_t kernel_base;
if (va >= MAP_ST) {
return (va - MAP_ST);
}
if (va >= MAP_KERNEL) {
return (va - MAP_KERNEL + kernel_base);
}
if (va >= MAP_ST) {
return (va - MAP_ST);
}
return NOPHYS;
} /* virt_to_phys() */
#endif /* POSTK_DEBUG_ARCH_DEP_34 */