Page MenuHomeFreeBSD

Log a message if we successfully update microcode during boot.
ClosedPublic

Authored by markj on Sep 12 2018, 4:40 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Jul 11, 7:07 PM
Unknown Object (File)
Sun, Jul 6, 11:43 AM
Unknown Object (File)
Mon, Jun 30, 7:05 PM
Unknown Object (File)
Mon, Jun 30, 8:03 AM
Unknown Object (File)
Mon, Jun 30, 3:43 AM
Unknown Object (File)
Sun, Jun 29, 12:23 AM
Unknown Object (File)
Thu, Jun 26, 2:01 PM
Unknown Object (File)
Wed, Jun 25, 6:39 PM
Subscribers

Details

Summary

The early ucode code runs before we can print anything to the console,
so we use a static buffer to store a message which gets printed during
mi_startup(). This was previously only used for errors, but it's also
useful for confirming that an update was loaded.

Test Plan
real memory  = 34359738368 (32768 MB)
avail memory = 33219350528 (31680 MB)
Microcode: updated from revision 0x2a to 0x3d
Event timer "LAPIC" quality 600
ACPI APIC Table: <ALASKA A M I >
FreeBSD/SMP: Multiprocessor System Detected: 32 CPUs
FreeBSD/SMP: 2 package(s) x 8 core(s) x 2 hardware threads

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 19549
Build 19135: arc lint + arc unit

Event Timeline

markj added reviewers: emaste, kib, jhb.

I cannot rationally explain my dislike of the single-purpose msg buffer, but it is.

This revision is now accepted and ready to land.Sep 12 2018, 6:24 PM
sys/x86/x86/ucode.c
94

Maybe "CPU microcode:" ?

In D17135#365409, @kib wrote:

I cannot rationally explain my dislike of the single-purpose msg buffer, but it is.

I don't really like it either. If you have a suggestion, I can change the mechanism.

Prefix messages with "CPU microcode:"

This revision now requires review to proceed.Sep 12 2018, 6:35 PM
In D17135#365409, @kib wrote:

I cannot rationally explain my dislike of the single-purpose msg buffer, but it is.

I don't really like it either. If you have a suggestion, I can change the mechanism.

I would say that it is good enough to store pre- and post-update ucode version and show it to user. If an error occured, store -1 or -errno. Then log these two numbers when the console is functional.

  • Change the logging mechanism per discussion.
This revision is now accepted and ready to land.Sep 14 2018, 4:28 PM
This revision was automatically updated to reflect the committed changes.