diff options
-rw-r--r-- | kexec/arch/arm64/kexec-arm64.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/kexec/arch/arm64/kexec-arm64.c b/kexec/arch/arm64/kexec-arm64.c index 7a12479..b143e86 100644 --- a/kexec/arch/arm64/kexec-arm64.c +++ b/kexec/arch/arm64/kexec-arm64.c @@ -492,10 +492,21 @@ static int setup_2nd_dtb(struct dtb *dtb, char *command_line, int on_crash) GRND_NONBLOCK); if(result == -1) { - dbgprintf("%s: Reading random bytes failed.\n", + fprintf(stderr, "%s: Reading random bytes failed.\n", + __func__); + + /* Currently on some arm64 platforms this + * 'getrandom' system call fails while booting + * the platform. + * + * In case, this happens at best we can set + * the 'kaslr_seed' as 0, indicating that the + * 2nd kernel will be booted with a 'nokaslr' + * like behaviour. + */ + fdt_val64 = 0UL; + dbgprintf("%s: Disabling KASLR in secondary kernel.\n", __func__); - result = -EINVAL; - goto on_error; } nodeoffset = fdt_path_offset(new_buf, "/chosen"); |