]> git.proxmox.com Git - mirror_edk2.git/blame - EdkCompatibilityPkg/Foundation/Efi/Protocol/DriverConfiguration/DriverConfiguration.h
Update the copyright notice format
[mirror_edk2.git] / EdkCompatibilityPkg / Foundation / Efi / Protocol / DriverConfiguration / DriverConfiguration.h
CommitLineData
3eb9473e 1/*++\r
2\r
f57387d5
HT
3Copyright (c) 2004, Intel Corporation. All rights reserved.<BR>\r
4This program and the accompanying materials \r
3eb9473e 5are licensed and made available under the terms and conditions of the BSD License \r
6which accompanies this distribution. The full text of the license may be found at \r
7http://opensource.org/licenses/bsd-license.php \r
8 \r
9THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
10WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
11\r
12Module Name:\r
13\r
14 DriverConfiguration.h\r
15 \r
16Abstract:\r
17\r
18 EFI Driver Configuration Protocol\r
19\r
20Revision History\r
21\r
22--*/\r
23\r
24#ifndef _EFI_DRIVER_CONFIGURATION_H_\r
25#define _EFI_DRIVER_CONFIGURATION_H_\r
26\r
27//\r
28// Global ID for the Driver Configuration Protocol\r
29//\r
30#define EFI_DRIVER_CONFIGURATION_PROTOCOL_GUID \\r
31 { \\r
7ccf38a3 32 0x107a772b, 0xd5e1, 0x11d4, {0x9a, 0x46, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d} \\r
3eb9473e 33 }\r
34\r
35EFI_FORWARD_DECLARATION (EFI_DRIVER_CONFIGURATION_PROTOCOL);\r
36\r
37typedef enum {\r
38 EfiDriverConfigurationActionNone = 0,\r
39 EfiDriverConfigurationActionStopController = 1,\r
40 EfiDriverConfigurationActionRestartController = 2,\r
41 EfiDriverConfigurationActionRestartPlatform = 3,\r
42 EfiDriverConfigurationActionMaximum\r
43} EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED;\r
44\r
45#define EFI_DRIVER_CONFIGURATION_SAFE_DEFAULTS 0x00000000\r
46#define EFI_DRIVER_CONFIGURATION_MANUFACTURING_DEFAULTS 0x00000001\r
47#define EFI_DRIVER_CONFIGURATION_CUSTOM_DEFAULTS 0x00000002\r
48#define EFI_DRIVER_CONFIGURATION_PERORMANCE_DEFAULTS 0x00000003\r
49\r
50typedef\r
51EFI_STATUS\r
52(EFIAPI *EFI_DRIVER_CONFIGURATION_SET_OPTIONS) (\r
53 IN EFI_DRIVER_CONFIGURATION_PROTOCOL * This,\r
54 IN EFI_HANDLE ControllerHandle,\r
55 IN EFI_HANDLE ChildHandle OPTIONAL,\r
56 IN CHAR8 *Language,\r
57 OUT EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED * ActionRequired\r
58 );\r
59\r
60/*++\r
61\r
62 Routine Description:\r
63 Allows the user to set controller specific options for a controller that a \r
64 driver is currently managing.\r
65\r
66 Arguments:\r
67 This - A pointer to the EFI_DRIVER_CONFIGURATION_ PROTOCOL instance.\r
68 ControllerHandle - The handle of the controller to set options on.\r
69 ChildHandle - The handle of the child controller to set options on. This\r
70 is an optional parameter that may be NULL. It will be NULL \r
71 for device drivers, and for a bus drivers that wish to set \r
72 options for the bus controller. It will not be NULL for a \r
73 bus driver that wishes to set options for one of its child \r
74 controllers.\r
75 Language - A pointer to a three character ISO 639-2 language identifier.\r
76 This is the language of the user interface that should be \r
77 presented to the user, and it must match one of the languages \r
78 specified in SupportedLanguages. The number of languages \r
79 supported by a driver is up to the driver writer.\r
80 ActionRequired - A pointer to the action that the calling agent is required \r
81 to perform when this function returns. See "Related \r
82 Definitions" for a list of the actions that the calling \r
83 agent is required to perform prior to accessing \r
84 ControllerHandle again.\r
85\r
86 Returns:\r
87 EFI_SUCCESS - The driver specified by This successfully set the \r
88 configuration options for the controller specified \r
89 by ControllerHandle..\r
90 EFI_INVALID_PARAMETER - ControllerHandle is not a valid EFI_HANDLE.\r
91 EFI_INVALID_PARAMETER - ChildHandle is not NULL and it is not a valid EFI_HANDLE.\r
92 EFI_INVALID_PARAMETER - ActionRequired is NULL.\r
93 EFI_UNSUPPORTED - The driver specified by This does not support setting \r
94 configuration options for the controller specified by \r
95 ControllerHandle and ChildHandle.\r
96 EFI_UNSUPPORTED - The driver specified by This does not support the \r
97 language specified by Language.\r
98 EFI_DEVICE_ERROR - A device error occurred while attempt to set the \r
99 configuration options for the controller specified \r
100 by ControllerHandle and ChildHandle.\r
101 EFI_OUT_RESOURCES - There are not enough resources available to set the \r
102 configuration options for the controller specified \r
103 by ControllerHandle and ChildHandle.\r
104\r
105--*/\r
106typedef\r
107EFI_STATUS\r
108(EFIAPI *EFI_DRIVER_CONFIGURATION_OPTIONS_VALID) (\r
109 IN EFI_DRIVER_CONFIGURATION_PROTOCOL * This,\r
110 IN EFI_HANDLE ControllerHandle,\r
111 IN EFI_HANDLE ChildHandle OPTIONAL\r
112 );\r
113\r
114/*++\r
115\r
116 Routine Description:\r
117 Tests to see if a controller's current configuration options are valid.\r
118\r
119 Arguments:\r
120 This - A pointer to the EFI_DRIVER_CONFIGURATION_PROTOCOL instance.\r
121 ControllerHandle - The handle of the controller to test if it's current \r
122 configuration options are valid.\r
123 ChildHandle - The handle of the child controller to test if it's current\r
124 configuration options are valid. This is an optional \r
125 parameter that may be NULL. It will be NULL for device \r
126 drivers. It will also be NULL for a bus drivers that wish\r
127 to test the configuration options for the bus controller.\r
128 It will not be NULL for a bus driver that wishes to test \r
129 configuration options for one of its child controllers.\r
130\r
131 Returns:\r
132 EFI_SUCCESS - The controller specified by ControllerHandle and \r
133 ChildHandle that is being managed by the driver \r
134 specified by This has a valid set of configuration\r
135 options.\r
136 EFI_INVALID_PARAMETER - ControllerHandle is not a valid EFI_HANDLE.\r
137 EFI_INVALID_PARAMETER - ChildHandle is not NULL and it is not a valid EFI_HANDLE.\r
138 EFI_UNSUPPORTED - The driver specified by This is not currently \r
139 managing the controller specified by ControllerHandle \r
140 and ChildHandle.\r
141 EFI_DEVICE_ERROR - The controller specified by ControllerHandle and \r
142 ChildHandle that is being managed by the driver \r
143 specified by This has an invalid set of configuration \r
144 options.\r
145\r
146--*/\r
147typedef\r
148EFI_STATUS\r
149(EFIAPI *EFI_DRIVER_CONFIGURATION_FORCE_DEFAULTS) (\r
150 IN EFI_DRIVER_CONFIGURATION_PROTOCOL * This,\r
151 IN EFI_HANDLE ControllerHandle,\r
152 IN EFI_HANDLE ChildHandle OPTIONAL,\r
153 IN UINT32 DefaultType,\r
154 OUT EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED * ActionRequired\r
155 );\r
156\r
157/*++\r
158\r
159 Routine Description:\r
160 Forces a driver to set the default configuration options for a controller.\r
161\r
162 Arguments:\r
163 This - A pointer to the EFI_DRIVER_CONFIGURATION_ PROTOCOL instance.\r
164 ControllerHandle - The handle of the controller to force default configuration options on.\r
165 ChildHandle - The handle of the child controller to force default configuration options on This is an optional parameter that may be NULL. It will be NULL for device drivers. It will also be NULL for a bus drivers that wish to force default configuration options for the bus controller. It will not be NULL for a bus driver that wishes to force default configuration options for one of its child controllers.\r
166 DefaultType - The type of default configuration options to force on the controller specified by ControllerHandle and ChildHandle. See Table 9-1 for legal values. A DefaultType of 0x00000000 must be supported by this protocol.\r
167 ActionRequired - A pointer to the action that the calling agent is required to perform when this function returns. See "Related Definitions" in Section 9.1for a list of the actions that the calling agent is required to perform prior to accessing ControllerHandle again.\r
168\r
169 Returns:\r
170 EFI_SUCCESS - The driver specified by This successfully forced the default configuration options on the controller specified by ControllerHandle and ChildHandle.\r
171 EFI_INVALID_PARAMETER - ControllerHandle is not a valid EFI_HANDLE.\r
172 EFI_INVALID_PARAMETER - ChildHandle is not NULL and it is not a valid EFI_HANDLE.\r
173 EFI_INVALID_PARAMETER - ActionRequired is NULL.\r
174 EFI_UNSUPPORTED - The driver specified by This does not support forcing the default configuration options on the controller specified by ControllerHandle and ChildHandle.\r
175 EFI_UNSUPPORTED - The driver specified by This does not support the configuration type specified by DefaultType.\r
176 EFI_DEVICE_ERROR - A device error occurred while attempt to force the default configuration options on the controller specified by ControllerHandle and ChildHandle.\r
177 EFI_OUT_RESOURCES - There are not enough resources available to force the default configuration options on the controller specified by ControllerHandle and ChildHandle.\r
178\r
179--*/\r
180\r
181//\r
182// Interface structure for the Driver Configuration Protocol\r
183//\r
e5bce275 184struct _EFI_DRIVER_CONFIGURATION_PROTOCOL {\r
3eb9473e 185 EFI_DRIVER_CONFIGURATION_SET_OPTIONS SetOptions;\r
186 EFI_DRIVER_CONFIGURATION_OPTIONS_VALID OptionsValid;\r
187 EFI_DRIVER_CONFIGURATION_FORCE_DEFAULTS ForceDefaults;\r
188 CHAR8 *SupportedLanguages;\r
e5bce275 189};\r
3eb9473e 190\r
191/*++\r
192\r
193 Protocol Description:\r
194 Used to set configuration options for a controller that an EFI Driver is managing.\r
195\r
196 Parameters:\r
197 SetOptions - Allows the use to set drivers specific configuration \r
198 options for a controller that the driver is currently \r
199 managing.\r
200 OptionsValid - Tests to see if a controller's current configuration \r
201 options are valid. \r
202 ForceDefaults - Forces a driver to set the default configuration options \r
203 for a controller.\r
204 SupportedLanguages - A Null-terminated ASCII string that contains one or more \r
205 ISO 639-2 language codes. This is the list of language \r
206 codes that this protocol supports.\r
207\r
208--*/\r
209extern EFI_GUID gEfiDriverConfigurationProtocolGuid;\r
210\r
211#endif\r