diff options
author | Feng Tian <feng.tian@intel.com> | 2015-01-27 03:07:01 +0000 |
---|---|---|
committer | erictian <erictian@Edk2> | 2015-01-27 03:07:01 +0000 |
commit | c45bc17996455365e43d791870ba0d5af49aa0e3 (patch) | |
tree | e3a2cc6c6c8f7585ee6a38584d5b14528baf63ad /MdeModulePkg/Bus/Usb | |
parent | 24e11fd8f80e15bb2ec435b8bed2492da8fc3e5d (diff) | |
download | edk2-platforms-c45bc17996455365e43d791870ba0d5af49aa0e3.tar.xz |
MdeModulePkg/UsbBotPei: Correct wrong media type detection logic in UsbBotPei
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Chao Zhang <chao.zhang@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16661 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Bus/Usb')
-rw-r--r-- | MdeModulePkg/Bus/Usb/UsbBotPei/UsbBotPeim.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/MdeModulePkg/Bus/Usb/UsbBotPei/UsbBotPeim.c b/MdeModulePkg/Bus/Usb/UsbBotPei/UsbBotPeim.c index b04bd42cff..c436ed7a69 100644 --- a/MdeModulePkg/Bus/Usb/UsbBotPei/UsbBotPeim.c +++ b/MdeModulePkg/Bus/Usb/UsbBotPei/UsbBotPeim.c @@ -1,6 +1,6 @@ /** @file
-Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions
@@ -656,10 +656,12 @@ PeiBotDetectMedia ( PeiServices,
PeiBotDev
);
- //
- // retry the ReadFormatCapacity command
- //
- PeiBotDev->DeviceType = USBFLOPPY2;
+ if (EFI_ERROR (Status)) {
+ //
+ // retry the ReadFormatCapacity command
+ //
+ PeiBotDev->DeviceType = USBFLOPPY2;
+ }
break;
default:
|