]>
Commit | Line | Data |
---|---|---|
a3bcde70 HT |
1 | /** @file\r |
2 | The driver binding and service binding protocol for IP6 driver.\r | |
3 | \r | |
75dce340 | 4 | Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>\r |
a3bcde70 HT |
5 | \r |
6 | This program and the accompanying materials\r | |
7 | are licensed and made available under the terms and conditions of the BSD License\r | |
8 | which accompanies this distribution. The full text of the license may be found at\r | |
9 | http://opensource.org/licenses/bsd-license.php.\r | |
10 | \r | |
11 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
12 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
13 | \r | |
14 | **/\r | |
15 | \r | |
16 | #ifndef __EFI_IP6_DRIVER_H__\r | |
17 | #define __EFI_IP6_DRIVER_H__\r | |
18 | \r | |
19 | extern EFI_DRIVER_BINDING_PROTOCOL gIp6DriverBinding;\r | |
20 | extern EFI_COMPONENT_NAME_PROTOCOL gIp6ComponentName;\r | |
21 | extern EFI_COMPONENT_NAME2_PROTOCOL gIp6ComponentName2;\r | |
22 | \r | |
23 | /**\r | |
24 | Clean up an IP6 service binding instance. It releases all\r | |
25 | the resource allocated by the instance. The instance may be\r | |
26 | partly initialized, or partly destroyed. If a resource is\r | |
75dce340 | 27 | destroyed, it is marked as that in case the destroy failed and\r |
a3bcde70 HT |
28 | being called again later.\r |
29 | \r | |
30 | @param[in] IpSb The IP6 service binding instance to clean up.\r | |
31 | \r | |
32 | @retval EFI_SUCCESS The resource used by the instance are cleaned up.\r | |
33 | @retval Others Failed to clean up some of the resources.\r | |
34 | \r | |
35 | **/\r | |
36 | EFI_STATUS\r | |
37 | Ip6CleanService (\r | |
38 | IN IP6_SERVICE *IpSb\r | |
39 | );\r | |
40 | \r | |
41 | //\r | |
42 | // Function prototype for the driver's entry point\r | |
43 | //\r | |
44 | \r | |
45 | /**\r | |
46 | This is the declaration of an EFI image entry point. This entry point is\r | |
47 | the same for UEFI Applications, UEFI OS Loaders, and UEFI Drivers including\r | |
48 | both device drivers and bus drivers.\r | |
49 | \r | |
50 | The entry point for IP6 driver which installs the driver\r | |
51 | binding and component name protocol on its image.\r | |
52 | \r | |
53 | @param[in] ImageHandle The firmware allocated handle for the UEFI image.\r | |
54 | @param[in] SystemTable A pointer to the EFI System Table.\r | |
55 | \r | |
56 | @retval EFI_SUCCESS The operation completed successfully.\r | |
57 | @retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.\r | |
58 | \r | |
59 | **/\r | |
60 | EFI_STATUS\r | |
61 | EFIAPI\r | |
62 | Ip6DriverEntryPoint (\r | |
63 | IN EFI_HANDLE ImageHandle,\r | |
64 | IN EFI_SYSTEM_TABLE *SystemTable\r | |
65 | );\r | |
66 | \r | |
67 | //\r | |
68 | // Function prototypes for the Drivr Binding Protocol\r | |
69 | //\r | |
70 | \r | |
71 | /**\r | |
72 | Test to see if this driver supports ControllerHandle.\r | |
73 | \r | |
74 | @param[in] This Protocol instance pointer.\r | |
75 | @param[in] ControllerHandle Handle of device to test.\r | |
76 | @param[in] RemainingDevicePath Optional parameter use to pick a specific child\r | |
77 | device to start.\r | |
78 | \r | |
79 | @retval EFI_SUCCESS This driver supports this device.\r | |
80 | @retval EFI_ALREADY_STARTED This driver is already running on this device.\r | |
81 | @retval other This driver does not support this device.\r | |
82 | \r | |
83 | **/\r | |
84 | EFI_STATUS\r | |
85 | EFIAPI\r | |
86 | Ip6DriverBindingSupported (\r | |
87 | IN EFI_DRIVER_BINDING_PROTOCOL *This,\r | |
88 | IN EFI_HANDLE ControllerHandle,\r | |
89 | IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath OPTIONAL\r | |
90 | );\r | |
91 | \r | |
92 | /**\r | |
93 | Start this driver on ControllerHandle.\r | |
94 | \r | |
95 | @param[in] This Protocol instance pointer.\r | |
96 | @param[in] ControllerHandle Handle of device to bind driver to.\r | |
97 | @param[in] RemainingDevicePath Optional parameter used to pick a specific child\r | |
98 | device to start.\r | |
99 | \r | |
100 | @retval EFI_SUCCES This driver is added to ControllerHandle.\r | |
101 | @retval EFI_ALREADY_STARTED This driver is already running on ControllerHandle.\r | |
102 | @retval other This driver does not support this device.\r | |
103 | \r | |
104 | **/\r | |
105 | EFI_STATUS\r | |
106 | EFIAPI\r | |
107 | Ip6DriverBindingStart (\r | |
108 | IN EFI_DRIVER_BINDING_PROTOCOL *This,\r | |
109 | IN EFI_HANDLE ControllerHandle,\r | |
110 | IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath OPTIONAL\r | |
111 | );\r | |
112 | \r | |
113 | /**\r | |
114 | Stop this driver on ControllerHandle.\r | |
115 | \r | |
116 | @param[in] This Protocol instance pointer.\r | |
117 | @param[in] ControllerHandle Handle of device to stop driver on.\r | |
118 | @param[in] NumberOfChildren Number of Handles in ChildHandleBuffer. If number\r | |
119 | of children is zero, stop the entire bus driver.\r | |
120 | @param[in] ChildHandleBuffer An array of child handles to be freed. May be NULL\r | |
121 | if NumberOfChildren is 0.\r | |
122 | \r | |
123 | @retval EFI_SUCCESS The device was stopped.\r | |
124 | @retval EFI_DEVICE_ERROR The device could not be stopped due to a device error.\r | |
125 | \r | |
126 | **/\r | |
127 | EFI_STATUS\r | |
128 | EFIAPI\r | |
129 | Ip6DriverBindingStop (\r | |
130 | IN EFI_DRIVER_BINDING_PROTOCOL *This,\r | |
131 | IN EFI_HANDLE ControllerHandle,\r | |
132 | IN UINTN NumberOfChildren,\r | |
133 | IN EFI_HANDLE *ChildHandleBuffer OPTIONAL\r | |
134 | );\r | |
135 | \r | |
136 | //\r | |
137 | // Function ptototypes for the ServiceBinding Prococol\r | |
138 | //\r | |
139 | \r | |
140 | /**\r | |
141 | Creates a child handle with a set of I/O services.\r | |
142 | \r | |
143 | @param[in] This Protocol instance pointer.\r | |
144 | @param[in] ChildHandle Pointer to the handle of the child to create. If\r | |
145 | it is NULL, then a new handle is created. If it\r | |
146 | is not NULL, then the I/O services are added to\r | |
147 | the existing child handle.\r | |
148 | \r | |
149 | @retval EFI_SUCCES The child handle was created with the I/O services.\r | |
150 | @retval EFI_OUT_OF_RESOURCES There are not enough resources availabe to create\r | |
151 | the child.\r | |
152 | @retval other The child handle was not created.\r | |
153 | \r | |
154 | **/\r | |
155 | EFI_STATUS\r | |
156 | EFIAPI\r | |
157 | Ip6ServiceBindingCreateChild (\r | |
158 | IN EFI_SERVICE_BINDING_PROTOCOL *This,\r | |
159 | IN EFI_HANDLE *ChildHandle\r | |
160 | );\r | |
161 | \r | |
162 | /**\r | |
163 | Destroys a child handle with a set of I/O services.\r | |
164 | \r | |
165 | @param[in] This Protocol instance pointer.\r | |
166 | @param[in] ChildHandle Handle of the child to destroy.\r | |
167 | \r | |
168 | @retval EFI_SUCCES The I/O services were removed from the child\r | |
169 | handle.\r | |
170 | @retval EFI_UNSUPPORTED The child handle does not support the I/O services\r | |
171 | that are being removed.\r | |
15ee13fc | 172 | @retval EFI_INVALID_PARAMETER Child handle is NULL.\r |
a3bcde70 HT |
173 | @retval EFI_ACCESS_DENIED The child handle could not be destroyed because\r |
174 | its I/O services are being used.\r | |
175 | @retval other The child handle was not destroyed.\r | |
176 | \r | |
177 | **/\r | |
178 | EFI_STATUS\r | |
179 | EFIAPI\r | |
180 | Ip6ServiceBindingDestroyChild (\r | |
181 | IN EFI_SERVICE_BINDING_PROTOCOL *This,\r | |
182 | IN EFI_HANDLE ChildHandle\r | |
183 | );\r | |
184 | \r | |
185 | #endif\r |