🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: muc.lists.freebsd.bugs
3 messages
3 total messages Started by bugzilla-noreply Tue, 03 Nov 2026 18:35
[Bug 300487] crash on resume if microcode update is configured and applicable
#341
Author: bugzilla-noreply
Date: Tue, 03 Nov 2026 18:35
87 lines
5285 bytes
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=300487

            Bug ID: 300487
           Summary: crash on resume if microcode update is configured and
                    applicable
           Product: Base System
           Version: 15.1-STABLE
          Hardware: amd64
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: kern
          Assignee: bugs@FreeBSD.org
          Reporter: avg@FreeBSD.org

The affected system runs on AMD processor and is configured to apply microcode
updates via preloaded image:

cpu_microcode_load="YES"
cpu_microcode_name="/boot/firmware/amd-ucode.bin"

Typically, I do not suspend the system, but it "happened".
On resume, the system crashed.

Thanks to serial console the crash got logged.

Fatal trap 9: general protection fault while in kernel mode^M
cpuid = 0; apic id = 00^M
instruction pointer     = 0x20:0xffffffff80d8736f^M
stack pointer           = 0x28:0xfffffe03172ce9c0^M
frame pointer           = 0x28:0xfffffe03172ce9f0^M
processor eflags        = resume, IOPL = 0^M
current thread          = 77297/552357 (acpiconf/acpiconf)^M
rdi: ffffffff820a35d6 rsi: 0000000000000001 rdx: 00000000ffffffff^M
rcx: 00000000c0010020  r8: ffffffff80f5d9bf  r9: ffffffff80fae827^M
rax: 00000000820a35d6 rbx: ffffffff820a35d6 rbp: fffffe03172ce9f0^M
r10: 0000000000000070 r11: ffffffff80efdb07 r12: 0000000000000000^M
r13: 000000000a201016 r14: 0000000000000000 r15: 0000000000000000^M
^M
^M
Fatal trap 9: general protection fault while in kernel mode^M
cpuid = 0; apic id = 00^M
instruction pointer     = 0x20:0xffffffff80dd993c^M
stack pointer           = 0x28:0xfffffe03172ce390^M
frame pointer           = 0x28:0xfffffe03172ce390^M
processor eflags        = resume, IOPL = 0^M
current thread          = 77297/552357 (acpiconf/acpiconf)^M
rdi: 0000000000004400 rsi: 0000000000000001 rdx: 0000000000000001^M
rcx: 0000000000000830  r8: 0000000000004401  r9: 0000000000000001^M
rax: 0000000000004400 rbx: 0000000000000000 rbp: fffffe03172ce390^M
r10: 0000000000000002 r11: fffffe03172ce341 r12: 000000000000fffc^M
r13: 0000000080000000 r14: 0000000000000001 r15: fffffe03172ce400^M

The second block repeated about 10 times after which the system just hung.

The first reported instruction pointer, 0xffffffff80d8736f, is in
ucode_amd_load:
   0xffffffff80d87361 <+65>:    mov    %rbx,%rdx
   0xffffffff80d87364 <+68>:    shr    $0x20,%rdx
   0xffffffff80d87368 <+72>:    mov    %ebx,%eax
   0xffffffff80d8736a <+74>:    mov    $0xc0010020,%ecx
   0xffffffff80d8736f <+79>:    wrmsr

It seems that the resume code applies microcode updates just like the boot code
does.
But it looks like the microcode image gets freed, via ucode_release(), after it
is used during the boot.
That was not a problem before commit base 16f21c5af350 (bug 294630) because the
image was copied into its own buffer, but now ucode_data and early_ucode_data
are left pointing to the released memory.

debug.ucode.release=0 can be used as a workaround.

-- 
You are receiving this mail because:
You are the assignee for the bug.

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-admin@muc.de
[Bug 300487] crash on resume if microcode update is configured and applicable
#370
Author: bugzilla-noreply
Date: Tue, 03 Nov 2026 18:41
20 lines
2734 bytes
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=300487

--- Comment #1 from Andriy Gapon <avg@FreeBSD.org> ---
Just in case, the secondary traps were in wrmsr as well, but in lapic_ipi_raw
(maybe when trying to IPI other logical CPUs):

   0xffffffff80dd9932 <+114>:   mfence
   0xffffffff80dd9935 <+117>:   mov    %edi,%eax
   0xffffffff80dd9937 <+119>:   mov    $0x830,%ecx
   0xffffffff80dd993c <+124>:   wrmsr

-- 
You are receiving this mail because:
You are the assignee for the bug.

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-admin@muc.de
[Bug 300487] crash on resume if microcode update is configured and applicable
#343
Author: bugzilla-noreply
Date: Tue, 03 Nov 2026 19:12
16 lines
2602 bytes
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=300487

Mark Linimon <linimon@FreeBSD.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |crash

-- 
You are receiving this mail because:
You are the assignee for the bug.

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-admin@muc.de
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads