From c61f936286cd8b929835dce81424a19fbcebba95 Mon Sep 17 00:00:00 2001 From: erictian Date: Wed, 17 Mar 2010 11:06:21 +0000 Subject: 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 --- MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'MdeModulePkg/Bus/Ata') diff --git a/MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c b/MdeModulePkg/Bus/Ata/AtaBusDxe/AtaPassThruExecute.c index d11ebd9..b10a7a7 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); } } // -- cgit v1.1