Commit a23e18ea authored by Leandro Lupori's avatar Leandro Lupori
Browse files

powerpc64: tell kernel when radix is not available

If CAS detects that radix is not supported, set radix_mmu to 0
to avoid the kernel trying to use it and panic.

MFC after:	2 weeks
Sponsored by:	Instituto de Pesquisas Eldorado (eldorado.org.br)
parent d7acbe48
......@@ -234,9 +234,15 @@ ppc64_cas(void)
}
}
if ((var = getenv("radix_mmu")) != NULL && var[0] == '0')
if (!radix_mmu)
/*
* If radix is not supported, set radix_mmu to 0 to avoid
* the kernel trying to use it and panic.
*/
setenv("radix_mmu", "0", 1);
else if ((var = getenv("radix_mmu")) != NULL && var[0] == '0')
radix_mmu = 0;
if (radix_mmu)
else
ov5[OV5_MMU_INDEX] = OV5_MMU_RADIX;
inst = OF_open("/");
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment