riscv: Use global mimpid in identify_cpu()

sbi_init() sets mimpid, we can use that value.

Reviewed by: philip (mentor), kp (mentor)
Approved by: philip (mentor), kp (mentor)
Sponsored by: Axiado
Differential Revision: https://reviews.freebsd.org/D26092
This commit is contained in:
nick 2020-08-18 16:51:04 +00:00
parent 8a79d22436
commit 7add20c45f

View File

@ -186,15 +186,13 @@ identify_cpu(void)
const struct cpu_parts *cpu_partsp;
uint32_t part_id;
uint32_t impl_id;
uint64_t mimpid;
uint64_t misa;
u_int cpu;
size_t i;
cpu_partsp = NULL;
/* TODO: can we get mimpid and misa somewhere ? */
mimpid = 0;
/* TODO: can we get misa somewhere ? */
misa = 0;
cpu = PCPU_GET(cpuid);