summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorerictian <erictian@6f19259b-4bc3-4df7-8a09-765794883524>2010-03-17 11:06:21 +0000
committererictian <erictian@6f19259b-4bc3-4df7-8a09-765794883524>2010-03-17 11:06:21 +0000
commitc61f936286cd8b929835dce81424a19fbcebba95 (patch)
tree2745a4473bcbeecd9485841492b9513b691c3431
parentc0d69d10f6f09bdecba70f5750c46b29795e8287 (diff)
downloadedk2-platforms-c61f936286cd8b929835dce81424a19fbcebba95.tar.xz
fix ia32 build error.
With IA32 tool chain, we can not use a 64bit data to divide a 32 bit data. MS tool chain may introduce an intrinsic function. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10267 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c b/MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c
index d11ebd9df0..b10a7a7842 100644
--- a/MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c
+++ b/MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c
@@ -304,8 +304,8 @@ IdentifyAtaDevice (
// Check lowest alignment of logical blocks within physical block
//
if ((IdentifyData->alignment_logic_in_phy_blocks & (BIT14 | BIT15)) == BIT14) {
- BlockMedia->LowestAlignedLba = (EFI_LBA) (BlockMedia->LogicalBlocksPerPhysicalBlock - (IdentifyData->alignment_logic_in_phy_blocks & 0x3fff)) %
- BlockMedia->LogicalBlocksPerPhysicalBlock;
+ BlockMedia->LowestAlignedLba = (EFI_LBA) ((BlockMedia->LogicalBlocksPerPhysicalBlock - ((UINT32)IdentifyData->alignment_logic_in_phy_blocks & 0x3fff)) %
+ BlockMedia->LogicalBlocksPerPhysicalBlock);
}
}
//