#define PROTOCOL_CBI0 0\r
#define PROTOCOL_CBI1 1\r
\r
-#define USBFLOPPY 1\r
-#define USBFLOPPY2 2 // for those that use ReadCapacity(0x25) command to retrieve media capacity\r
+#define USBFLOPPY 1 // for those that use ReadCapacity(0x25) command to retrieve media capacity\r
+#define USBFLOPPY2 2 // for those that use ReadFormatCapacity(0x23) command to retrieve media capacity\r
#define USBCDROM 3\r
\r
#define USB_FLOPPY_DEV_SIGNATURE EFI_SIGNATURE_32 ('u', 'f', 'l', 'p')\r
Status = USBFloppyReadCapacity (UsbFloppyDevice);\r
break;\r
\r
- case USBFLOPPY:\r
+ case USBFLOPPY2:\r
UsbMassStorageModeSense (UsbFloppyDevice);\r
Status = USBFloppyReadFormatCapacity (UsbFloppyDevice);\r
if (EFI_ERROR (Status) || !UsbFloppyDevice->BlkMedia.MediaPresent) {\r
//\r
// retry the ReadCapacity command\r
//\r
- UsbFloppyDevice->DeviceType = USBFLOPPY2;\r
+ UsbFloppyDevice->DeviceType = USBFLOPPY;\r
Status = EFI_DEVICE_ERROR;\r
}\r
break;\r
\r
- case USBFLOPPY2:\r
+ case USBFLOPPY:\r
UsbMassStorageModeSense (UsbFloppyDevice);\r
Status = USBFloppyReadCapacity (UsbFloppyDevice);\r
if (EFI_ERROR (Status)) {\r
//\r
// retry the ReadFormatCapacity command\r
//\r
- UsbFloppyDevice->DeviceType = USBFLOPPY;\r
+ UsbFloppyDevice->DeviceType = USBFLOPPY2;\r
}\r
//\r
// force the BlockSize to be 0x200.\r