]> git.proxmox.com Git - mirror_edk2.git/blob - EdkCompatibilityPkg/Foundation/Efi/Protocol/ComponentName2/ComponentName2.h
Update the copyright notice format
[mirror_edk2.git] / EdkCompatibilityPkg / Foundation / Efi / Protocol / ComponentName2 / ComponentName2.h
1 /*++
2
3 Copyright (c) 2004, Intel Corporation. All rights reserved.<BR>
4 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 ComponentName.h
15
16 Abstract:
17
18 EFI Component Name Protocol
19
20 Revision History
21
22 --*/
23
24 #ifndef _EFI_COMPONENT_NAME2_H_
25 #define _EFI_COMPONENT_NAME2_H_
26
27 //
28 // Global ID for the Component Name Protocol
29 //
30
31 #define EFI_COMPONENT_NAME2_PROTOCOL_GUID \
32 { \
33 0x6a7a5cff, 0xe8d9, 0x4f70, {0xba, 0xda, 0x75, 0xab, 0x30, 0x25, 0xce, 0x14} \
34 }
35
36 EFI_FORWARD_DECLARATION (EFI_COMPONENT_NAME2_PROTOCOL);
37
38
39 typedef
40 EFI_STATUS
41 (EFIAPI *EFI_COMPONENT_NAME2_GET_DRIVER_NAME) (
42 IN EFI_COMPONENT_NAME2_PROTOCOL * This,
43 IN CHAR8 *Language,
44 OUT CHAR16 **DriverName
45 );
46
47 /*++
48
49 Routine Description:
50 Retrieves a Unicode string that is the user readable name of the EFI Driver.
51
52 Arguments:
53 This - A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.
54 Language - A pointer to a three character ISO 639-2 language identifier.
55 This is the language of the driver name that that the caller
56 is requesting, and it must match one of the languages specified
57 in SupportedLanguages. The number of languages supported by a
58 driver is up to the driver writer.
59 DriverName - A pointer to the Unicode string to return. This Unicode string
60 is the name of the driver specified by This in the language
61 specified by Language.
62
63 Returns:
64 EFI_SUCCESS - The Unicode string for the Driver specified by This
65 and the language specified by Language was returned
66 in DriverName.
67 EFI_INVALID_PARAMETER - Language is NULL or DriverName is NULL.
68 EFI_UNSUPPORTED - The driver specified by This does not support the
69 language specified by Language.
70
71 --*/
72 typedef
73 EFI_STATUS
74 (EFIAPI *EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME) (
75 IN EFI_COMPONENT_NAME2_PROTOCOL * This,
76 IN EFI_HANDLE ControllerHandle,
77 IN EFI_HANDLE ChildHandle OPTIONAL,
78 IN CHAR8 *Language,
79 OUT CHAR16 **ControllerName
80 );
81
82 /*++
83
84 Routine Description:
85 Retrieves a Unicode string that is the user readable name of the controller
86 that is being managed by an EFI Driver.
87
88 Arguments:
89 This - A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.
90 ControllerHandle - The handle of a controller that the driver specified by
91 This is managing. This handle specifies the controller
92 whose name is to be returned.
93 ChildHandle - The handle of the child controller to retrieve the name
94 of. This is an optional parameter that may be NULL. It
95 will be NULL for device drivers. It will also be NULL
96 for a bus drivers that wish to retrieve the name of the
97 bus controller. It will not be NULL for a bus driver
98 that wishes to retrieve the name of a child controller.
99 Language - A pointer to a three character ISO 639-2 language
100 identifier. This is the language of the controller name
101 that that the caller is requesting, and it must match one
102 of the languages specified in SupportedLanguages. The
103 number of languages supported by a driver is up to the
104 driver writer.
105 ControllerName - A pointer to the Unicode string to return. This Unicode
106 string is the name of the controller specified by
107 ControllerHandle and ChildHandle in the language specified
108 by Language from the point of view of the driver specified
109 by This.
110
111 Returns:
112 EFI_SUCCESS - The Unicode string for the user readable name in the
113 language specified by Language for the driver
114 specified by This was returned in DriverName.
115 EFI_INVALID_PARAMETER - ControllerHandle is not a valid EFI_HANDLE; ChildHandle
116 is not NULL and it is not a valid EFI_HANDLE;Language
117 is NULL;ControllerName is NULL.
118 EFI_UNSUPPORTED - The driver specified by This is not currently managing
119 the controller specified by ControllerHandle and
120 ChildHandle;The driver specified by This does not support the
121 language specified by Language.
122
123 --*/
124
125 //
126 // Interface structure for the Component Name Protocol
127 //
128 struct _EFI_COMPONENT_NAME2_PROTOCOL {
129 EFI_COMPONENT_NAME2_GET_DRIVER_NAME GetDriverName;
130 EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME GetControllerName;
131 CHAR8 *SupportedLanguages;
132 };
133
134 extern EFI_GUID gEfiComponentName2ProtocolGuid;
135
136 #endif