From 7bc6629f400c03970614420366edddecbd0dabcb Mon Sep 17 00:00:00 2001 From: VarshitPandya Date: Wed, 1 Jul 2026 11:15:20 +0100 Subject: [PATCH] ShellPkg: Fix smbiosview Type 26 location/status decode The smbiosview Type 26 Voltage Probe decoder uses the low 5 bits of LocationAndStatus as the probe location and the high 3 bits as the probe status. However, the Type 26 lookup tables were swapped: VPLocationTable contained status strings and VPStatusTable contained location strings. This caused valid records to be displayed as, for example: Voltage Probe - Location: OK Voltage Probe - Status: Processor Swap the table contents so Type 26 output matches the SMBIOS LocationAndStatus bit layout. Signed-off-by: VarshitPandya --- .../SmbiosView/QueryTable.c | 54 +++++++++---------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c index 4dce68dccf..9d3219b6eb 100644 --- a/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c +++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/QueryTable.c @@ -3236,33 +3236,6 @@ TABLE_ITEM PBDeviceChemistryTable[] = { }; TABLE_ITEM VPLocationTable[] = { - { - 0x01, - L" Other " - }, - { - 0x02, - L" Unknown " - }, - { - 0x03, - L" OK " - }, - { - 0x04, - L" Non-critical " - }, - { - 0x05, - L" Critical " - }, - { - 0x06, - L" Non-recoverable " - }, -}; - -TABLE_ITEM VPStatusTable[] = { { 0x01, L" Other " @@ -3309,6 +3282,33 @@ TABLE_ITEM VPStatusTable[] = { }, }; +TABLE_ITEM VPStatusTable[] = { + { + 0x01, + L" Other " + }, + { + 0x02, + L" Unknown " + }, + { + 0x03, + L" OK " + }, + { + 0x04, + L" Non-critical " + }, + { + 0x05, + L" Critical " + }, + { + 0x06, + L" Non-recoverable " + }, +}; + TABLE_ITEM CoolingDeviceStatusTable[] = { { 0x01,