]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Universal/PlatformDriverOverride/PlatformDriOverrideDxe/PlatformDriOverride.h
31f2077be9b09272d4eb00a4f3c859b291ae7868
[mirror_edk2.git] / MdeModulePkg / Universal / PlatformDriverOverride / PlatformDriOverrideDxe / PlatformDriOverride.h
1 /** @file
2
3 Copyright (c) 2007, 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
8
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.
11
12 Module Name:
13
14 PlatformDriOverride.h
15
16 Abstract:
17
18
19 **/
20
21 #ifndef _PLATFORM_DRI_OVERRIDE_H_
22 #define _PLATFORM_DRI_OVERRIDE_H_
23
24 #include <Uefi.h>
25
26 #include <Library/DebugLib.h>
27 #include <Library/UefiDriverEntryPoint.h>
28 #include <Library/BaseLib.h>
29 #include <Library/PlatDriOverLib.h>
30
31 /**
32 Retrieves the image handle of the platform override driver for a controller in the system.
33
34 @param This A pointer to the
35 EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL instance.
36 @param ControllerHandle The device handle of the controller to check if a
37 driver override exists.
38 @param DriverImageHandle On input, a pointer to the previous driver image
39 handle returned by GetDriver(). On output, a
40 pointer to the next driver image handle. Passing
41 in a NULL, will return the first driver image
42 handle for ControllerHandle.
43
44 @retval EFI_SUCCESS The driver override for ControllerHandle was
45 returned in DriverImageHandle.
46 @retval EFI_NOT_FOUND A driver override for ControllerHandle was not
47 found.
48 @retval EFI_INVALID_PARAMETER The handle specified by ControllerHandle is not a
49 valid handle. DriverImageHandle is not a handle
50 that was returned on a previous call to
51 GetDriver().
52
53 **/
54 EFI_STATUS
55 EFIAPI
56 GetDriver (
57 IN EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL * This,
58 IN EFI_HANDLE ControllerHandle,
59 IN OUT EFI_HANDLE * DriverImageHandle
60 );
61
62 /**
63 For the use of the ControllerHandle parameter in the GetDriverPath()
64 But this API is very difficult to use, so not support.
65
66 @param This A pointer to the
67 EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL instance.
68 @param ControllerHandle The device handle of the controller to check if a
69 driver override exists.
70 @param DriverImagePath The device path for this Image.
71
72 @retval EFI_UNSUPPORTED
73 **/
74 EFI_STATUS
75 EFIAPI
76 GetDriverPath (
77 IN EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL * This,
78 IN EFI_HANDLE ControllerHandle,
79 IN OUT EFI_DEVICE_PATH_PROTOCOL **DriverImagePath
80 );
81
82 /**
83 For the use of the ControllerHandle parameter in the DriverLoaded()
84 But this API is very difficult to use, so not support.
85
86 @param This A pointer to the
87 EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL instance.
88 @param ControllerHandle The device handle of the controller to check if a
89 driver override exists.
90 @param DriverImagePath The device path for this Image.
91 @param DriverImageHandle On input, a pointer to the previous driver image
92 handle returned by GetDriver(). On output, a
93 pointer to the next driver image handle. Passing
94 in a NULL, will return the first driver image
95 handle for ControllerHandle.
96
97 @retval EFI_UNSUPPORTED
98 **/
99 EFI_STATUS
100 EFIAPI
101 DriverLoaded (
102 IN EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL * This,
103 IN EFI_HANDLE ControllerHandle,
104 IN EFI_DEVICE_PATH_PROTOCOL * DriverImagePath,
105 IN EFI_HANDLE DriverImageHandle
106 );
107 #endif