summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFeng Tian <feng.tian@intel.com>2013-10-29 01:31:02 +0000
committererictian <erictian@6f19259b-4bc3-4df7-8a09-765794883524>2013-10-29 01:31:02 +0000
commit2f34e065a3e649550fcb0dc89786cb26197510dd (patch)
treea90f76da2948ea3ed34ae680278c0423d2fe6698
parentaafc4dcf01716ee87abc007e8826a5e057a291d8 (diff)
downloadedk2-platforms-2f34e065a3e649550fcb0dc89786cb26197510dd.tar.xz
MdeModulePkg/NvmExpressDxe: Correct the calculation of LbaFmtIdx of Identify name space to follow NVME spec
Signed-off-by: Feng Tian <feng.tian@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14805 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpress.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpress.c b/MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpress.c
index ed1c4bf391..4f187e3abb 100644
--- a/MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpress.c
+++ b/MdeModulePkg/Bus/Pci/NvmExpressDxe/NvmExpress.c
@@ -129,7 +129,7 @@ EnumerateNvmeDevNamespace (
Device->Media.WriteCaching = FALSE;
Flbas = NamespaceData->Flbas;
- LbaFmtIdx = Flbas & 3;
+ LbaFmtIdx = Flbas & 0xF;
Lbads = NamespaceData->LbaFormat[LbaFmtIdx].Lbads;
Device->Media.BlockSize = (UINT32)1 << Lbads;