Page MenuHomeFreeBSD

riscv: Use global mimpid in identify_cpu()
ClosedPublic

Authored by nick on Aug 17 2020, 9:20 PM.
Tags
Referenced Files
F153767619: D26092.id75910.diff
Thu, Apr 23, 1:53 PM
Unknown Object (File)
Wed, Apr 22, 7:05 PM
Unknown Object (File)
Wed, Apr 22, 8:30 AM
Unknown Object (File)
Mon, Apr 20, 12:41 AM
Unknown Object (File)
Sun, Apr 19, 9:10 PM
Unknown Object (File)
Thu, Apr 16, 2:22 PM
Unknown Object (File)
Wed, Apr 15, 12:11 AM
Unknown Object (File)
Tue, Apr 14, 12:25 PM
Subscribers

Details

Summary

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

Sponsored by: Axiado

Test Plan

I've tested this on internal hardware and Qemu (with some Qemu hacks as RISCV Qemu returns 0 by default)

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

nick requested review of this revision.Aug 17 2020, 9:20 PM

Looks good to me.

Would be nice if sbi_init() could also give us misa. ;-)

This revision is now accepted and ready to land.Aug 18 2020, 1:49 AM

Approved by: philip, kp (mentors)

Go ahead and commit this.

This revision was automatically updated to reflect the committed changes.