3 Copyright (c) 2004, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
18 Disk Info protocol is used to export Inquiry Data for a drive.
19 Its needed to support low level formating of drives in a mannor
24 #ifndef __DISK_INFO_H__
25 #define __DISK_INFO_H__
27 #define EFI_DISK_INFO_PROTOCOL_GUID \
29 0xd432a67f, 0x14dc, 0x484b, {0xb3, 0xbb, 0x3f, 0x2, 0x91, 0x84, 0x93, 0x27} \
32 EFI_FORWARD_DECLARATION (EFI_DISK_INFO_PROTOCOL
);
36 (EFIAPI
*EFI_DISK_INFO_INQUIRY
) (
37 IN EFI_DISK_INFO_PROTOCOL
* This
,
38 IN OUT VOID
*InquiryData
,
39 IN OUT UINT32
*IntquiryDataSize
44 Return the results of the Inquiry command to a drive in InquiryData.
45 Data format of Inquiry data is defined by the Interface GUID.
48 This - Protocol instance pointer.
49 InquiryData - Results of Inquiry command to device
50 InquiryDataSize - Size of InquiryData in bytes.
53 EFI_SUCCESS - InquiryData valid
54 EFI_NOT_FOUND - Device does not support this data class
55 EFI_DEVICE_ERROR - Error reading InquiryData from device
56 EFI_BUFFER_TOO_SMALL - IntquiryDataSize not big enough
63 (EFIAPI
*EFI_DISK_INFO_IDENTIFY
) (
64 IN EFI_DISK_INFO_PROTOCOL
* This
,
65 IN OUT VOID
*IdentifyData
,
66 IN OUT UINT32
*IdentifyDataSize
71 Return the results of the Identify command to a drive in IdentifyData.
72 Data format of Identify data is defined by the Interface GUID.
75 This - Protocol instance pointer.
76 IdentifyData - Results of Identify command to device
77 IdentifyDataSize - Size of IdentifyData in bytes.
80 EFI_SUCCESS - IdentifyData valid
81 EFI_NOT_FOUND - Device does not support this data class
82 EFI_DEVICE_ERROR - Error reading IdentifyData from device
83 EFI_BUFFER_TOO_SMALL - IdentifyDataSize not big enough
90 (EFIAPI
*EFI_DISK_INFO_SENSE_DATA
) (
91 IN EFI_DISK_INFO_PROTOCOL
* This
,
92 IN OUT VOID
*SenseData
,
93 IN OUT UINT32
*SenseDataSize
,
94 OUT UINT8
*SenseDataNumber
99 Return the results of the Request Sense command to a drive in SenseData.
100 Data format of Sense data is defined by the Interface GUID.
103 This - Protocol instance pointer.
104 SenseData - Results of Request Sense command to device
105 SenseDataSize - Size of SenseData in bytes.
106 SenseDataNumber - Type of SenseData
109 EFI_SUCCESS - InquiryData valid
110 EFI_NOT_FOUND - Device does not support this data class
111 EFI_DEVICE_ERROR - Error reading InquiryData from device
112 EFI_BUFFER_TOO_SMALL - SenseDataSize not big enough
119 (EFIAPI
*EFI_DISK_INFO_WHICH_IDE
) (
120 IN EFI_DISK_INFO_PROTOCOL
* This
,
121 OUT UINT32
*IdeChannel
,
122 OUT UINT32
*IdeDevice
127 Return the results of the Request Sense command to a drive in SenseData.
128 Data format of Sense data is defined by the Interface GUID.
131 This - Protocol instance pointer.
132 IdeChannel - Primary or Secondary
133 IdeDevice - Master or Slave
136 EFI_SUCCESS - IdeChannel and IdeDevice are valid
137 EFI_UNSUPPORTED - This is not an IDE device
143 // GUIDs for EFI_DISK_INFO_PROTOCOL.Interface. Defines the format of the
144 // buffers returned by member functions
146 #define EFI_DISK_INFO_IDE_INTERFACE_GUID \
148 0x5e948fe3, 0x26d3, 0x42b5, {0xaf, 0x17, 0x61, 0x2, 0x87, 0x18, 0x8d, 0xec} \
150 extern EFI_GUID gEfiDiskInfoIdeInterfaceGuid
;
152 #define EFI_DISK_INFO_SCSI_INTERFACE_GUID \
154 0x8f74baa, 0xea36, 0x41d9, {0x95, 0x21, 0x21, 0xa7, 0xf, 0x87, 0x80, 0xbc} \
156 extern EFI_GUID gEfiDiskInfoScsiInterfaceGuid
;
158 #define EFI_DISK_INFO_USB_INTERFACE_GUID \
160 0xcb871572, 0xc11a, 0x47b5, {0xb4, 0x92, 0x67, 0x5e, 0xaf, 0xa7, 0x77, 0x27} \
162 extern EFI_GUID gEfiDiskInfoUsbInterfaceGuid
;
164 #define EFI_DISK_INFO_AHCI_INTERFACE_GUID \
166 0x9e498932, 0x4abc, 0x45af, {0xa3, 0x4d, 0x2, 0x47, 0x78, 0x7b, 0xe7, 0xc6} \
168 extern EFI_GUID gEfiDiskInfoAhciInterfaceGuid
;
170 struct _EFI_DISK_INFO_PROTOCOL
{
172 EFI_DISK_INFO_INQUIRY Inquiry
;
173 EFI_DISK_INFO_IDENTIFY Identify
;
174 EFI_DISK_INFO_SENSE_DATA SenseData
;
175 EFI_DISK_INFO_WHICH_IDE WhichIde
;
178 extern EFI_GUID gEfiDiskInfoProtocolGuid
;