summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2008-08-23 08:38:20 +0000
committerqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2008-08-23 08:38:20 +0000
commit8e35b68162a77c580917b6f636f84b74dc4aed22 (patch)
tree25ed022fcb94dc400c3fc96b7c50307244420d99
parenta926396d1836f4e7589ac71715ec86f2c3145595 (diff)
downloadedk2-platforms-8e35b68162a77c580917b6f636f84b74dc4aed22.tar.xz
1) Make EfiCpuVersion.c pass ICC and GCC tool-chain
2) Add in CpuIA32Lib_Edk2.inf. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5717 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/CpuIA32Lib_Edk2.inf3
-rw-r--r--EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/EfiCpuVersion.c4
2 files changed, 4 insertions, 3 deletions
diff --git a/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/CpuIA32Lib_Edk2.inf b/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/CpuIA32Lib_Edk2.inf
index 163f8505ec..3f40822e6f 100644
--- a/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/CpuIA32Lib_Edk2.inf
+++ b/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/CpuIA32Lib_Edk2.inf
@@ -29,11 +29,12 @@ COMPONENT_TYPE = LIBRARY
[sources.ia32]
IA32/CpuIA32.c | MSFT
IA32/CpuIA32.asm | INTEL
+ IA32/CpuIA32.S | GCC
[sources.x64]
x64/Cpu.asm | MSFT
x64/Cpu.asm | INTEL
-
+
[includes.common]
$(EDK_SOURCE)/Foundation/Efi
$(EDK_SOURCE)/Foundation/Efi/Include
diff --git a/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/EfiCpuVersion.c b/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/EfiCpuVersion.c
index 192469fecf..7c8cf07093 100644
--- a/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/EfiCpuVersion.c
+++ b/EdkCompatibilityPkg/Foundation/Cpu/Pentium/CpuIA32Lib/EfiCpuVersion.c
@@ -59,14 +59,14 @@ Arguments:
if (Model != NULL) {
*Model = (UINT8) ((Register.RegEax >> 4) & 0xF);
if (TempFamilyId == 0x6 || TempFamilyId == 0xF) {
- *Model |= (Register.RegEax >> 12) & 0xF0;
+ *Model = (UINT8) (*Model | ((Register.RegEax >> 12) & 0xF0));
}
}
if (FamilyId != NULL) {
*FamilyId = TempFamilyId;
if (TempFamilyId == 0xF) {
- *FamilyId = *FamilyId + (UINT16) ((Register.RegEax >> 20) & 0xFF);
+ *FamilyId = (UINT8 ) (*FamilyId + (UINT16) ((Register.RegEax >> 20) & 0xFF));
}
}
}