]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Ppi/BlockIo.h
MdePkg: Clean up source files
[mirror_edk2.git] / MdePkg / Include / Ppi / BlockIo.h
index a69419e284708c802fb0f9b7180656573f59a143..b65c464545e75c6b62994cea234038434efcda70 100644 (file)
@@ -1,26 +1,26 @@
 /** @file\r
-  Provides the services required to access a block I/O device during PEI recovery \r
+  Provides the services required to access a block I/O device during PEI recovery\r
   boot mode.\r
 \r
-  The Recovery Module PPI and the Device Recovery Module PPI are device neutral. \r
-  This PPI is device specific and addresses the most common form of recovery \r
+  The Recovery Module PPI and the Device Recovery Module PPI are device neutral.\r
+  This PPI is device specific and addresses the most common form of recovery\r
   media-block I/O devices such as legacy floppy, CD-ROM, or IDE devices.\r
 \r
-  The Recovery Block I/O PPI is used to access block devices. Because the Recovery \r
-  Block I/O PPIs that are provided by the PEI ATAPI driver and PEI legacy floppy \r
+  The Recovery Block I/O PPI is used to access block devices. Because the Recovery\r
+  Block I/O PPIs that are provided by the PEI ATAPI driver and PEI legacy floppy\r
   driver are the same, here we define a set of general PPIs for both drivers to use.\r
-  \r
-Copyright (c) 2007 - 2015, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials are licensed and made available under \r
-the terms and conditions of the BSD License that accompanies this distribution.  \r
+\r
+Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>\r
+This program and the accompanying materials are licensed and made available under\r
+the terms and conditions of the BSD License that accompanies this distribution.\r
 The full text of the license may be found at\r
-http://opensource.org/licenses/bsd-license.php.                                            \r
+http://opensource.org/licenses/bsd-license.php.\r
 \r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
   @par Revision Reference:\r
-  This PPI is defined in UEFI Platform Initialization Specification 1.2 Volume 1: \r
+  This PPI is defined in UEFI Platform Initialization Specification 1.2 Volume 1:\r
   Pre-EFI Initalization Core Interface.\r
 \r
 **/\r
@@ -50,7 +50,7 @@ typedef UINT64  EFI_PEI_LBA;
 /// EFI_PEI_BLOCK_DEVICE_TYPE\r
 ///\r
 typedef enum {\r
-  LegacyFloppy  = 0,   ///< The recovery device is a floppy. \r
+  LegacyFloppy  = 0,   ///< The recovery device is a floppy.\r
   IdeCDROM      = 1,   ///< The recovery device is an IDE CD-ROM\r
   IdeLS120      = 2,   ///< The recovery device is an IDE LS-120\r
   UsbMassStorage= 3,   ///< The recovery device is a USB Mass Storage device\r
@@ -61,22 +61,22 @@ typedef enum {
 } EFI_PEI_BLOCK_DEVICE_TYPE;\r
 \r
 ///\r
-/// Specification inconsistency here: \r
+/// Specification inconsistency here:\r
 /// PEI_BLOCK_IO_MEDIA has been changed to EFI_PEI_BLOCK_IO_MEDIA.\r
-/// Inconsistency exists in UEFI Platform Initialization Specification 1.2 \r
-/// Volume 1: Pre-EFI Initalization Core Interface, where all referrences to \r
-/// this structure name are with the "EFI_" prefix, except for the definition \r
-/// which is without "EFI_".  So the name of PEI_BLOCK_IO_MEDIA is taken as the \r
-/// exception, and EFI_PEI_BLOCK_IO_MEDIA is used to comply with most of \r
+/// Inconsistency exists in UEFI Platform Initialization Specification 1.2\r
+/// Volume 1: Pre-EFI Initalization Core Interface, where all referrences to\r
+/// this structure name are with the "EFI_" prefix, except for the definition\r
+/// which is without "EFI_".  So the name of PEI_BLOCK_IO_MEDIA is taken as the\r
+/// exception, and EFI_PEI_BLOCK_IO_MEDIA is used to comply with most of\r
 /// the specification.\r
 ///\r
 typedef struct {\r
   ///\r
-  /// The type of media device being referenced by DeviceIndex. \r
+  /// The type of media device being referenced by DeviceIndex.\r
   ///\r
   EFI_PEI_BLOCK_DEVICE_TYPE  DeviceType;\r
   ///\r
-  /// A flag that indicates if media is present. This flag is always set for \r
+  /// A flag that indicates if media is present. This flag is always set for\r
   /// nonremovable media devices.\r
   ///\r
   BOOLEAN                    MediaPresent;\r
@@ -93,16 +93,16 @@ typedef struct {
 /**\r
   Gets the count of block I/O devices that one specific block driver detects.\r
 \r
-  This function is used for getting the count of block I/O devices that one \r
+  This function is used for getting the count of block I/O devices that one\r
   specific block driver detects.  To the PEI ATAPI driver, it returns the number\r
-  of all the detected ATAPI devices it detects during the enumeration process. \r
-  To the PEI legacy floppy driver, it returns the number of all the legacy \r
-  devices it finds during its enumeration process. If no device is detected, \r
-  then the function will return zero.  \r
-  \r
-  @param[in]  PeiServices          General-purpose services that are available \r
+  of all the detected ATAPI devices it detects during the enumeration process.\r
+  To the PEI legacy floppy driver, it returns the number of all the legacy\r
+  devices it finds during its enumeration process. If no device is detected,\r
+  then the function will return zero.\r
+\r
+  @param[in]  PeiServices          General-purpose services that are available\r
                                    to every PEIM.\r
-  @param[in]  This                 Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI \r
+  @param[in]  This                 Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI\r
                                    instance.\r
   @param[out] NumberBlockDevices   The number of block I/O devices discovered.\r
 \r
@@ -120,41 +120,41 @@ EFI_STATUS
 /**\r
   Gets a block device's media information.\r
 \r
-  This function will provide the caller with the specified block device's media \r
-  information. If the media changes, calling this function will update the media \r
+  This function will provide the caller with the specified block device's media\r
+  information. If the media changes, calling this function will update the media\r
   information accordingly.\r
 \r
   @param[in]  PeiServices   General-purpose services that are available to every\r
                             PEIM\r
   @param[in]  This          Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI instance.\r
-  @param[in]  DeviceIndex   Specifies the block device to which the function wants \r
-                            to talk. Because the driver that implements Block I/O \r
-                            PPIs will manage multiple block devices, the PPIs that \r
-                            want to talk to a single device must specify the \r
+  @param[in]  DeviceIndex   Specifies the block device to which the function wants\r
+                            to talk. Because the driver that implements Block I/O\r
+                            PPIs will manage multiple block devices, the PPIs that\r
+                            want to talk to a single device must specify the\r
                             device index that was assigned during the enumeration\r
-                            process. This index is a number from one to \r
+                            process. This index is a number from one to\r
                             NumberBlockDevices.\r
-  @param[out] MediaInfo     The media information of the specified block media.  \r
-                            The caller is responsible for the ownership of this \r
+  @param[out] MediaInfo     The media information of the specified block media.\r
+                            The caller is responsible for the ownership of this\r
                             data structure.\r
 \r
-  @par Note: \r
-      The MediaInfo structure describes an enumeration of possible block device \r
-      types.  This enumeration exists because no device paths are actually passed \r
-      across interfaces that describe the type or class of hardware that is publishing \r
+  @par Note:\r
+      The MediaInfo structure describes an enumeration of possible block device\r
+      types.  This enumeration exists because no device paths are actually passed\r
+      across interfaces that describe the type or class of hardware that is publishing\r
       the block I/O interface. This enumeration will allow for policy decisions\r
-      in the Recovery PEIM, such as "Try to recover from legacy floppy first, \r
-      LS-120 second, CD-ROM third." If there are multiple partitions abstracted \r
-      by a given device type, they should be reported in ascending order; this \r
-      order also applies to nested partitions, such as legacy MBR, where the \r
-      outermost partitions would have precedence in the reporting order. The \r
-      same logic applies to systems such as IDE that have precedence relationships \r
-      like "Master/Slave" or "Primary/Secondary". The master device should be \r
+      in the Recovery PEIM, such as "Try to recover from legacy floppy first,\r
+      LS-120 second, CD-ROM third." If there are multiple partitions abstracted\r
+      by a given device type, they should be reported in ascending order; this\r
+      order also applies to nested partitions, such as legacy MBR, where the\r
+      outermost partitions would have precedence in the reporting order. The\r
+      same logic applies to systems such as IDE that have precedence relationships\r
+      like "Master/Slave" or "Primary/Secondary". The master device should be\r
       reported first, the slave second.\r
-  \r
-  @retval EFI_SUCCESS        Media information about the specified block device \r
+\r
+  @retval EFI_SUCCESS        Media information about the specified block device\r
                              was obtained successfully.\r
-  @retval EFI_DEVICE_ERROR   Cannot get the media information due to a hardware \r
+  @retval EFI_DEVICE_ERROR   Cannot get the media information due to a hardware\r
                              error.\r
 \r
 **/\r
@@ -170,31 +170,31 @@ EFI_STATUS
 /**\r
   Reads the requested number of blocks from the specified block device.\r
 \r
-  The function reads the requested number of blocks from the device. All the \r
+  The function reads the requested number of blocks from the device. All the\r
   blocks are read, or an error is returned. If there is no media in the device,\r
   the function returns EFI_NO_MEDIA.\r
 \r
-  @param[in]  PeiServices   General-purpose services that are available to \r
+  @param[in]  PeiServices   General-purpose services that are available to\r
                             every PEIM.\r
   @param[in]  This          Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI instance.\r
-  @param[in]  DeviceIndex   Specifies the block device to which the function wants \r
-                            to talk. Because the driver that implements Block I/O \r
-                            PPIs will manage multiple block devices, PPIs that \r
-                            want to talk to a single device must specify the device \r
-                            index that was assigned during the enumeration process. \r
+  @param[in]  DeviceIndex   Specifies the block device to which the function wants\r
+                            to talk. Because the driver that implements Block I/O\r
+                            PPIs will manage multiple block devices, PPIs that\r
+                            want to talk to a single device must specify the device\r
+                            index that was assigned during the enumeration process.\r
                             This index is a number from one to NumberBlockDevices.\r
   @param[in]  StartLBA      The starting logical block address (LBA) to read from\r
                             on the device\r
   @param[in]  BufferSize    The size of the Buffer in bytes. This number must be\r
                             a multiple of the intrinsic block size of the device.\r
   @param[out] Buffer        A pointer to the destination buffer for the data.\r
-                            The caller is responsible for the ownership of the \r
+                            The caller is responsible for the ownership of the\r
                             buffer.\r
-                         \r
+\r
   @retval EFI_SUCCESS             The data was read correctly from the device.\r
-  @retval EFI_DEVICE_ERROR        The device reported an error while attempting \r
+  @retval EFI_DEVICE_ERROR        The device reported an error while attempting\r
                                   to perform the read operation.\r
-  @retval EFI_INVALID_PARAMETER   The read request contains LBAs that are not \r
+  @retval EFI_INVALID_PARAMETER   The read request contains LBAs that are not\r
                                   valid, or the buffer is not properly aligned.\r
   @retval EFI_NO_MEDIA            There is no media in the device.\r
   @retval EFI_BAD_BUFFER_SIZE     The BufferSize parameter is not a multiple of\r
@@ -221,12 +221,12 @@ struct _EFI_PEI_RECOVERY_BLOCK_IO_PPI {
   /// Gets the number of block I/O devices that the specific block driver manages.\r
   ///\r
   EFI_PEI_GET_NUMBER_BLOCK_DEVICES      GetNumberOfBlockDevices;\r
-  \r
+\r
   ///\r
   /// Gets the specified media information.\r
   ///\r
   EFI_PEI_GET_DEVICE_MEDIA_INFORMATION  GetBlockDeviceMediaInfo;\r
-  \r
+\r
   ///\r
   /// Reads the requested number of blocks from the specified block device.\r
   ///\r