]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Bus/Usb/UsbMassStorageDxe/UsbMass.h
Improve coding style in MdeModulePkg.
[mirror_edk2.git] / MdeModulePkg / Bus / Usb / UsbMassStorageDxe / UsbMass.h
index 33b23816215e3c56f6f6f5eb9fab04f565ca9006..b89014a8129989b0960f0241bbf3b0396a754f84 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 - 2008, Intel Corporation\r
+Copyright (c) 2007 - 2010, Intel Corporation\r
 All rights reserved. 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
@@ -38,36 +38,34 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #define USB_IS_INTERRUPT_ENDPOINT(Attribute)  (((Attribute) & (BIT0 | BIT1)) == USB_ENDPOINT_INTERRUPT)\r
 #define USB_IS_ERROR(Result, Error)           (((Result) & (Error)) != 0)\r
 \r
-typedef enum {\r
-  //\r
-  // Usb mass storage class code\r
-  //\r
-  USB_MASS_STORE_CLASS    = 0x08,\r
-\r
-  //\r
-  // Usb mass storage subclass code, specify the command set used.\r
-  //\r
-  USB_MASS_STORE_RBC      = 0x01, ///< Reduced Block Commands\r
-  USB_MASS_STORE_8020I    = 0x02, ///< SFF-8020i, typically a CD/DVD device\r
-  USB_MASS_STORE_QIC      = 0x03, ///< Typically a tape device\r
-  USB_MASS_STORE_UFI      = 0x04, ///< Typically a floppy disk driver device\r
-  USB_MASS_STORE_8070I    = 0x05, ///< SFF-8070i, typically a floppy disk driver device.\r
-  USB_MASS_STORE_SCSI     = 0x06, ///< SCSI transparent command set\r
-\r
-  //\r
-  // Usb mass storage protocol code, specify the transport protocol\r
-  //\r
-  USB_MASS_STORE_CBI0     = 0x00, ///< CBI protocol with command completion interrupt\r
-  USB_MASS_STORE_CBI1     = 0x01, ///< CBI protocol without command completion interrupt\r
-  USB_MASS_STORE_BOT      = 0x50, ///< Bulk-Only Transport\r
-\r
-  USB_MASS_1_MILLISECOND  = 1000,\r
-  USB_MASS_1_SECOND       = 1000 * USB_MASS_1_MILLISECOND,\r
-\r
-  USB_MASS_CMD_SUCCESS    = 0,\r
-  USB_MASS_CMD_FAIL,\r
-  USB_MASS_CMD_PERSISTENT\r
-} USB_MASS_DEV_CLASS_AND_VALUE;\r
+//\r
+// Usb mass storage class code\r
+//\r
+#define USB_MASS_STORE_CLASS    0x08\r
+\r
+//\r
+// Usb mass storage subclass code, specify the command set used.\r
+//\r
+#define USB_MASS_STORE_RBC      0x01 ///< Reduced Block Commands\r
+#define USB_MASS_STORE_8020I    0x02 ///< SFF-8020i, typically a CD/DVD device\r
+#define USB_MASS_STORE_QIC      0x03 ///< Typically a tape device\r
+#define USB_MASS_STORE_UFI      0x04 ///< Typically a floppy disk driver device\r
+#define USB_MASS_STORE_8070I    0x05 ///< SFF-8070i, typically a floppy disk driver device.\r
+#define USB_MASS_STORE_SCSI     0x06 ///< SCSI transparent command set\r
+\r
+//\r
+// Usb mass storage protocol code, specify the transport protocol\r
+//\r
+#define USB_MASS_STORE_CBI0     0x00 ///< CBI protocol with command completion interrupt\r
+#define USB_MASS_STORE_CBI1     0x01 ///< CBI protocol without command completion interrupt\r
+#define USB_MASS_STORE_BOT      0x50 ///< Bulk-Only Transport\r
+\r
+#define USB_MASS_1_MILLISECOND  1000\r
+#define USB_MASS_1_SECOND       (1000 * USB_MASS_1_MILLISECOND)\r
+\r
+#define USB_MASS_CMD_SUCCESS    0\r
+#define USB_MASS_CMD_FAIL       1\r
+#define USB_MASS_CMD_PERSISTENT 2\r
 \r
 /**\r
   Initializes USB transport protocol.\r