]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Include/Protocol/DiskInfo.h
Add PcdSupportFullConfigRoutingProtocol and gEfiDiskInfoAhciInterfaceGuid.
[mirror_edk2.git] / MdeModulePkg / Include / Protocol / DiskInfo.h
CommitLineData
1e354c03 1/** @file\r
2 Disk Info protocol is used to export Inquiry Data for a drive.\r
3 Its needed to support low level formating of drives in a mannor\r
4 thats DOS compatible.\r
88f20127 5\r
1e354c03 6Copyright (c) 2006 - 2008, Intel Corporation. <BR>\r
88f20127 7All rights reserved. This program and the accompanying materials\r
8are licensed and made available under the terms and conditions of the BSD License\r
9which accompanies this distribution. The full text of the license may be found at\r
10http://opensource.org/licenses/bsd-license.php\r
11\r
12THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
13WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
14\r
1e354c03 15**/\r
88f20127 16\r
17#ifndef __DISK_INFO_H__\r
18#define __DISK_INFO_H__\r
19\r
20#define EFI_DISK_INFO_PROTOCOL_GUID \\r
21 { \\r
22 0xd432a67f, 0x14dc, 0x484b, {0xb3, 0xbb, 0x3f, 0x2, 0x91, 0x84, 0x93, 0x27 } \\r
23 }\r
24\r
25//\r
26// Forward reference for pure ANSI compatability\r
27//\r
28typedef struct _EFI_DISK_INFO_PROTOCOL EFI_DISK_INFO_PROTOCOL;\r
29\r
1e354c03 30/**\r
31 Return the results of the Inquiry command to a drive in InquiryData.\r
32 Data format of Inquiry data is defined by the Interface GUID.\r
33\r
34 @param This Protocol instance pointer. \r
35 @param InquiryData Results of Inquiry command to device \r
36 @param InquiryDataSize Size of InquiryData in bytes. \r
37\r
38 @retval EFI_SUCCESS InquiryData valid \r
39 @retval EFI_NOT_FOUND Device does not support this data class \r
40 @retval EFI_DEVICE_ERROR Error reading InquiryData from device \r
41 @retval EFI_BUFFER_TOO_SMALL IntquiryDataSize not big enough \r
42\r
43**/\r
88f20127 44typedef\r
45EFI_STATUS\r
46(EFIAPI *EFI_DISK_INFO_INQUIRY) (\r
47 IN EFI_DISK_INFO_PROTOCOL * This,\r
48 IN OUT VOID *InquiryData,\r
49 IN OUT UINT32 *IntquiryDataSize\r
50 )\r
1e354c03 51;\r
88f20127 52\r
88f20127 53\r
1e354c03 54/**\r
55 Return the results of the Identify command to a drive in IdentifyData.\r
56 Data format of Identify data is defined by the Interface GUID.\r
88f20127 57\r
1e354c03 58 @param This Protocol instance pointer. \r
59 @param IdentifyData Results of Identify command to device \r
60 @param IdentifyDataSize Size of IdentifyData in bytes. \r
88f20127 61\r
1e354c03 62 @retval EFI_SUCCESS IdentifyData valid \r
63 @retval EFI_NOT_FOUND Device does not support this data class \r
64 @retval EFI_DEVICE_ERROR Error reading IdentifyData from device \r
65 @retval EFI_BUFFER_TOO_SMALL IdentifyDataSize not big enough \r
88f20127 66\r
1e354c03 67**/\r
88f20127 68typedef\r
69EFI_STATUS\r
70(EFIAPI *EFI_DISK_INFO_IDENTIFY) (\r
71 IN EFI_DISK_INFO_PROTOCOL * This,\r
72 IN OUT VOID *IdentifyData,\r
73 IN OUT UINT32 *IdentifyDataSize\r
74 )\r
1e354c03 75;\r
88f20127 76\r
88f20127 77\r
1e354c03 78/**\r
79 Return the results of the Request Sense command to a drive in SenseData.\r
80 Data format of Sense data is defined by the Interface GUID.\r
88f20127 81\r
1e354c03 82 @param This Protocol instance pointer. \r
83 @param SenseData Results of Request Sense command to device \r
84 @param SenseDataSize Size of SenseData in bytes. \r
85 @param SenseDataNumber Type of SenseData \r
88f20127 86\r
1e354c03 87 @retval EFI_SUCCESS InquiryData valid \r
88 @retval EFI_NOT_FOUND Device does not support this data class \r
89 @retval EFI_DEVICE_ERROR Error reading InquiryData from device \r
90 @retval EFI_BUFFER_TOO_SMALL SenseDataSize not big enough \r
88f20127 91\r
1e354c03 92**/\r
88f20127 93typedef\r
94EFI_STATUS\r
95(EFIAPI *EFI_DISK_INFO_SENSE_DATA) (\r
96 IN EFI_DISK_INFO_PROTOCOL * This,\r
97 IN OUT VOID *SenseData,\r
98 IN OUT UINT32 *SenseDataSize,\r
99 OUT UINT8 *SenseDataNumber\r
100 )\r
1e354c03 101;\r
88f20127 102\r
1e354c03 103/**\r
104 Return the results of the Request Sense command to a drive in SenseData.\r
105 Data format of Sense data is defined by the Interface GUID.\r
88f20127 106\r
1e354c03 107 @param This Protocol instance pointer. \r
108 @param IdeChannel Primary or Secondary \r
109 @param IdeDevice Master or Slave \r
88f20127 110\r
1e354c03 111 @retval EFI_SUCCESS IdeChannel and IdeDevice are valid \r
112 @retval EFI_UNSUPPORTED This is not an IDE device \r
88f20127 113\r
1e354c03 114**/\r
88f20127 115typedef\r
116EFI_STATUS\r
117(EFIAPI *EFI_DISK_INFO_WHICH_IDE) (\r
118 IN EFI_DISK_INFO_PROTOCOL * This,\r
119 OUT UINT32 *IdeChannel,\r
120 OUT UINT32 *IdeDevice\r
121 )\r
88f20127 122;\r
123\r
124//\r
125// GUIDs for EFI_DISK_INFO_PROTOCOL.Interface. Defines the format of the\r
126// buffers returned by member functions\r
127//\r
128#define EFI_DISK_INFO_IDE_INTERFACE_GUID \\r
129 { \\r
130 0x5e948fe3, 0x26d3, 0x42b5, {0xaf, 0x17, 0x61, 0x2, 0x87, 0x18, 0x8d, 0xec } \\r
131 }\r
132extern EFI_GUID gEfiDiskInfoIdeInterfaceGuid;\r
133\r
134#define EFI_DISK_INFO_SCSI_INTERFACE_GUID \\r
135 { \\r
136 0x8f74baa, 0xea36, 0x41d9, {0x95, 0x21, 0x21, 0xa7, 0xf, 0x87, 0x80, 0xbc } \\r
137 }\r
138extern EFI_GUID gEfiDiskInfoScsiInterfaceGuid;\r
139\r
140#define EFI_DISK_INFO_USB_INTERFACE_GUID \\r
141 { \\r
142 0xcb871572, 0xc11a, 0x47b5, {0xb4, 0x92, 0x67, 0x5e, 0xaf, 0xa7, 0x77, 0x27 } \\r
143 }\r
144extern EFI_GUID gEfiDiskInfoUsbInterfaceGuid;\r
145\r
aa103f48 146#define EFI_DISK_INFO_AHCI_INTERFACE_GUID \\r
147 { \\r
148 0x9e498932, 0x4abc, 0x45af, {0xa3, 0x4d, 0x2, 0x47, 0x78, 0x7b, 0xe7, 0xc6} \\r
149 }\r
150extern EFI_GUID gEfiDiskInfoAhciInterfaceGuid;\r
151\r
88f20127 152struct _EFI_DISK_INFO_PROTOCOL {\r
153 EFI_GUID Interface;\r
154 EFI_DISK_INFO_INQUIRY Inquiry;\r
155 EFI_DISK_INFO_IDENTIFY Identify;\r
156 EFI_DISK_INFO_SENSE_DATA SenseData;\r
157 EFI_DISK_INFO_WHICH_IDE WhichIde;\r
158};\r
159\r
160extern EFI_GUID gEfiDiskInfoProtocolGuid;\r
161\r
162#endif\r
163\r
164\r