]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMass.h
MdeModulePkg/UsbMassStorage: Add 16 byte SCSI cmds support if the last LBA can not...
[mirror_edk2.git] / MdeModulePkg / Bus / Usb / UsbMassStorageDxe / UsbMass.h
index e5347e9c30a42391f39616ab59e94708c8f57fb3..291cc13b61406878c0a41b40886e57f413719fd7 100644 (file)
@@ -2,7 +2,7 @@
   Definition of USB Mass Storage Class and its value, USB Mass Transport Protocol, \r
   and other common definitions.\r
 \r
-Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
@@ -18,11 +18,11 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 \r
 \r
 #include <Uefi.h>\r
-\r
+#include <IndustryStandard/Scsi.h>\r
 #include <Protocol/BlockIo.h>\r
 #include <Protocol/UsbIo.h>\r
 #include <Protocol/DevicePath.h>\r
-\r
+#include <Protocol/DiskInfo.h>\r
 #include <Library/BaseLib.h>\r
 #include <Library/DebugLib.h>\r
 #include <Library/BaseMemoryLib.h>\r
@@ -32,6 +32,15 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #include <Library/MemoryAllocationLib.h>\r
 #include <Library/DevicePathLib.h>\r
 \r
+typedef struct _USB_MASS_TRANSPORT USB_MASS_TRANSPORT;\r
+typedef struct _USB_MASS_DEVICE    USB_MASS_DEVICE;\r
+\r
+#include "UsbMassBot.h"\r
+#include "UsbMassCbi.h"\r
+#include "UsbMassBoot.h"\r
+#include "UsbMassDiskInfo.h"\r
+#include "UsbMassImpl.h"\r
+\r
 #define USB_IS_IN_ENDPOINT(EndPointAddr)      (((EndPointAddr) & BIT7) == BIT7)\r
 #define USB_IS_OUT_ENDPOINT(EndPointAddr)     (((EndPointAddr) & BIT7) == 0)\r
 #define USB_IS_BULK_ENDPOINT(Attribute)       (((Attribute) & (BIT0 | BIT1)) == USB_ENDPOINT_BULK)\r
@@ -177,16 +186,16 @@ EFI_STATUS
 /// structure so that the CBI protocol can be easily removed when\r
 /// it is no longer necessary.\r
 ///\r
-typedef struct {\r
+struct _USB_MASS_TRANSPORT {\r
   UINT8                   Protocol;\r
   USB_MASS_INIT_TRANSPORT Init;        ///< Initialize the mass storage transport protocol\r
   USB_MASS_EXEC_COMMAND   ExecCommand; ///< Transport command to the device then get result\r
   USB_MASS_RESET          Reset;       ///< Reset the device\r
   USB_MASS_GET_MAX_LUN    GetMaxLun;   ///< Get max lun, only for bot\r
   USB_MASS_CLEAN_UP       CleanUp;     ///< Clean up the resources.\r
-} USB_MASS_TRANSPORT;\r
+};\r
 \r
-typedef struct {\r
+struct _USB_MASS_DEVICE {\r
   UINT32                    Signature;\r
   EFI_HANDLE                Controller;\r
   EFI_USB_IO_PROTOCOL       *UsbIo;\r
@@ -197,7 +206,10 @@ typedef struct {
   UINT8                     Lun;          ///< Logical Unit Number\r
   UINT8                     Pdt;          ///< Peripheral Device Type\r
   USB_MASS_TRANSPORT        *Transport;   ///< USB mass storage transport protocol\r
-  VOID                      *Context;     \r
-} USB_MASS_DEVICE;\r
+  VOID                      *Context;\r
+  EFI_DISK_INFO_PROTOCOL    DiskInfo;\r
+  USB_BOOT_INQUIRY_DATA     InquiryData;\r
+  BOOLEAN                   Cdb16Byte;\r
+};\r
 \r
 #endif\r