summaryrefslogtreecommitdiffstats
path: root/MdeModulePkg
diff options
context:
space:
mode:
authorHaojian Zhuang <haojian.zhuang@linaro.org>2017-01-16 20:22:56 +0800
committerFeng Tian <feng.tian@intel.com>2017-01-20 09:11:24 +0800
commita68093d5d0eb9f5b8dce1ef03749463e6f0dae93 (patch)
tree3a9c0e748b9b51469b3aac633735bb50072fd1c8 /MdeModulePkg
parent13fca387b30824ac9458abe2620cc12d9fa80dbc (diff)
downloadedk2-a68093d5d0eb9f5b8dce1ef03749463e6f0dae93.tar.gz
edk2-a68093d5d0eb9f5b8dce1ef03749463e6f0dae93.tar.bz2
edk2-a68093d5d0eb9f5b8dce1ef03749463e6f0dae93.zip
MdeModulePkg/UfsBlockIoPei: fix the bit in UFS_HC_UTRLDBR_OFFSET reg
When UPIU packet is sent, (BIT0 << Slot) should be set according to context. But BIT0 is used without Slot when UfsWaitMemSet () is invoked. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Haojian Zhuang <haojian.zhuang@linaro.org> Reviewed-by: Feng Tian <feng.tian@intel.com>
Diffstat (limited to 'MdeModulePkg')
-rw-r--r--MdeModulePkg/Bus/Ufs/UfsBlockIoPei/UfsHci.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/MdeModulePkg/Bus/Ufs/UfsBlockIoPei/UfsHci.c b/MdeModulePkg/Bus/Ufs/UfsBlockIoPei/UfsHci.c
index 7e90ecf8e0..cccacce334 100644
--- a/MdeModulePkg/Bus/Ufs/UfsBlockIoPei/UfsHci.c
+++ b/MdeModulePkg/Bus/Ufs/UfsBlockIoPei/UfsHci.c
@@ -842,7 +842,7 @@ UfsRwDeviceDesc (
// Wait for the completion of the transfer request.
//
Address = Private->UfsHcBase + UFS_HC_UTRLDBR_OFFSET;
- Status = UfsWaitMemSet (Address, BIT0, 0, Packet.Timeout);
+ Status = UfsWaitMemSet (Address, BIT0 << Slot, 0, Packet.Timeout);
if (EFI_ERROR (Status)) {
goto Exit;
}
@@ -956,7 +956,7 @@ UfsRwAttributes (
// Wait for the completion of the transfer request.
//
Address = Private->UfsHcBase + UFS_HC_UTRLDBR_OFFSET;
- Status = UfsWaitMemSet (Address, BIT0, 0, Packet.Timeout);
+ Status = UfsWaitMemSet (Address, BIT0 << Slot, 0, Packet.Timeout);
if (EFI_ERROR (Status)) {
goto Exit;
}
@@ -1070,7 +1070,7 @@ UfsRwFlags (
// Wait for the completion of the transfer request.
//
Address = Private->UfsHcBase + UFS_HC_UTRLDBR_OFFSET;
- Status = UfsWaitMemSet (Address, BIT0, 0, Packet.Timeout);
+ Status = UfsWaitMemSet (Address, BIT0 << Slot, 0, Packet.Timeout);
if (EFI_ERROR (Status)) {
goto Exit;
}
@@ -1228,7 +1228,7 @@ UfsExecNopCmds (
// Wait for the completion of the transfer request.
//
Address = Private->UfsHcBase + UFS_HC_UTRLDBR_OFFSET;
- Status = UfsWaitMemSet (Address, BIT0, 0, UFS_TIMEOUT);
+ Status = UfsWaitMemSet (Address, BIT0 << Slot, 0, UFS_TIMEOUT);
if (EFI_ERROR (Status)) {
goto Exit;
}
@@ -1312,7 +1312,7 @@ UfsExecScsiCmds (
// Wait for the completion of the transfer request.
//
Address = Private->UfsHcBase + UFS_HC_UTRLDBR_OFFSET;
- Status = UfsWaitMemSet (Address, BIT0, 0, Packet->Timeout);
+ Status = UfsWaitMemSet (Address, BIT0 << Slot, 0, Packet->Timeout);
if (EFI_ERROR (Status)) {
goto Exit;
}