diff --git a/sys/kern/subr_devmap.c b/sys/kern/subr_devmap.c --- a/sys/kern/subr_devmap.c +++ b/sys/kern/subr_devmap.c @@ -37,6 +37,10 @@ #include #include +#ifdef __arm__ +#include +#endif + static const struct devmap_entry *devmap_table; static boolean_t devmap_bootstrap_done = false; @@ -139,7 +143,7 @@ * also align the virtual address to the next-lower 1MB boundary so that * we end with a nice efficient section mapping. */ - if ((pa & 0x000fffff) == 0 && (sz & 0x000fffff) == 0) { + if ((pa & L1_S_OFFSET) == 0 && (sz & L1_S_OFFSET) == 0) { akva_devmap_vaddr = trunc_1mpage(akva_devmap_vaddr - sz); } else #endif