Corrects the AcpiProcessorUid for Multi socket/package.

The ProcessorInfoBuffer.Location.Package holds the stale entry
of the last processor. In multi-socket system it holds
the Socket/Package number of last socket/package, resulting
wrong AcpiProcessorUid assignment for socket 0 processors.

Hence do the bit shift on stored SocketNum.

Cc: Chasel Chiu <chasel.c...@intel.com>
Cc: Nate DeSimone <nathaniel.l.desim...@intel.com>
Cc: Liming Gao <gaolim...@byosoft.com.cn>
Cc: Eric Dong <eric.d...@intel.com>
Signed-off-by: Abdul Lateef Attar <abdat...@amd.com>
---
 Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c 
b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
index 032903029a95..785cf4c2f911 100644
--- a/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
+++ b/Platform/Intel/MinPlatformPkg/Acpi/AcpiTables/AcpiPlatform.c
@@ -287,7 +287,7 @@ SortCpuLocalApicInTable (
   for (Socket = 0; Socket < FixedPcdGet32 (PcdMaxCpuSocketCount); Socket++) {

     for (CurrProcessor = 0, Index = 0; CurrProcessor < mNumberOfCpus; 
CurrProcessor++) {

       if (mCpuApicIdOrderTable[CurrProcessor].Flags && 
(mCpuApicIdOrderTable[CurrProcessor].SocketNum == Socket)) {

-        mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorUid = 
(ProcessorInfoBuffer.Location.Package << mNumOfBitShift) + Index;

+        mCpuApicIdOrderTable[CurrProcessor].AcpiProcessorUid = 
(mCpuApicIdOrderTable[CurrProcessor].SocketNum << mNumOfBitShift) + Index;

         Index++;

       }

     }

-- 
2.25.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#82526): https://edk2.groups.io/g/devel/message/82526
Mute This Topic: https://groups.io/mt/86515675/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to