riscv: Add machine name to kernel boot log and stack dump output
[ Upstream commit 46ad48e8a28da7cc37a16c7e7fc632ecf906e4bf ] Add the machine name to kernel boot-up log, and install the machine name to stack dump for DT boot mode. Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Reviewed-by: Atish Patra <atish.patra@wdc.com> Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com> Stable-dep-of: 10f6913c548b ("riscv: always honor the CONFIG_CMDLINE_FORCE when parsing dtb") Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
7fba4a389d
commit
0e4c06ae7c
@ -54,8 +54,15 @@ static DEFINE_PER_CPU(struct cpu, cpu_devices);
|
||||
static void __init parse_dtb(void)
|
||||
{
|
||||
/* Early scan of device tree from init memory */
|
||||
if (early_init_dt_scan(dtb_early_va))
|
||||
if (early_init_dt_scan(dtb_early_va)) {
|
||||
const char *name = of_flat_dt_get_machine_name();
|
||||
|
||||
if (name) {
|
||||
pr_info("Machine model: %s\n", name);
|
||||
dump_stack_set_arch_desc("%s (DT)", name);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
pr_err("No DTB passed to the kernel\n");
|
||||
#ifdef CONFIG_CMDLINE_FORCE
|
||||
|
Loading…
Reference in New Issue
Block a user