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, Dec 13, 9:59 AM
Unknown Object (File)
Tue, Dec 10, 6:29 PM
Unknown Object (File)
Nov 18 2024, 8:20 PM
Unknown Object (File)
Nov 18 2024, 7:10 PM
Unknown Object (File)
Nov 17 2024, 4:45 PM
Unknown Object (File)
Nov 11 2024, 11:28 AM
Unknown Object (File)
Nov 5 2024, 4:01 AM
Unknown Object (File)
Nov 5 2024, 3:56 AM
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

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

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 ↗(On Diff #47957)

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.