Project

General

Profile

Bug #2546

Support new AMD microcode format, update bundled AMD microcode patch file

Added by Hans Rosenfeld over 8 years ago. Updated over 8 years ago.

Status:
Resolved
Priority:
Normal
Category:
kernel
Start date:
2012-03-27
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
needs-triage
Gerrit CR:

Description

The format of the AMD microcode patches has changed for family 0x14 and 0x15, patches for those families are now encrypted. The microcode patch loader uses too strict consistency checks that fail on the new patch file, and the boot-time microcode patch loader truncates the new patches, which can cause panics.

To fix this, the consistency checks need to be relaxed to support the new format, and the structure holding a single microcode patch needs to be extended to support the bigger patches for family 0x14 and 0x15. Similar changes have been made to Linux, NetBSD and Xen.

Also, AMD has released new microcode in January, see http://www.amd64.org/support/microcode.html
Therefore, the AMD microcode patch file bundled with Illumos should be updated.

History

#1

Updated by Hans Rosenfeld over 8 years ago

Webrev: http://cr.illumos.org/view/ytr0djc9/illumos-2546-webrev/

- updated AMD microcode patch file (webrev seems to have trouble with binary files)
- relaxed consistency check in ucode_validate_amd()
- increased size of ucode_file_amd_t to support the bigger encrypted patches for family 0x15
- limited the check for patches containing x86 code to patches for families before 0x14
- wrapped the wrmsr() calls in on_trap()/no_trap() to avoid panics with broken patch files
- make ucode_force_update work in the AMD-specific code paths

#2

Updated by Hans Rosenfeld over 8 years ago

  • % Done changed from 0 to 100
#3

Updated by Rich Lowe over 8 years ago

  • Status changed from New to Resolved

Resolved in r13650 commit:8f838b3f28d2

Also available in: Atom PDF