]> git.proxmox.com Git - mirror_edk2.git/blame - MdePkg/Include/Protocol/ComponentName.h
MdePkg/ProcessorBind: add defines for page allocation granularity
[mirror_edk2.git] / MdePkg / Include / Protocol / ComponentName.h
CommitLineData
d1f95000 1/** @file\r
4ca9b6c4 2 EFI Component Name Protocol as defined in the EFI 1.1 specification.\r
f754f721 3 This protocol is used to retrieve user readable names of EFI Drivers \r
4ca9b6c4 4 and controllers managed by EFI Drivers.\r
d1f95000 5\r
18bd7e85 6Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>\r
af2dc6a7 7This program and the accompanying materials are licensed and made available under \r
8the terms and conditions of the BSD License that accompanies this distribution. \r
9The 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
d1f95000 14\r
d1f95000 15**/\r
16\r
17#ifndef __EFI_COMPONENT_NAME_H__\r
18#define __EFI_COMPONENT_NAME_H__\r
19\r
99e8ed21 20///\r
af2dc6a7 21/// The global ID for the Component Name Protocol.\r
99e8ed21 22///\r
d1f95000 23#define EFI_COMPONENT_NAME_PROTOCOL_GUID \\r
24 { \\r
25 0x107a772c, 0xd5e1, 0x11d4, {0x9a, 0x46, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d } \\r
26 }\r
27\r
28typedef struct _EFI_COMPONENT_NAME_PROTOCOL EFI_COMPONENT_NAME_PROTOCOL;\r
29\r
30\r
31/**\r
af2dc6a7 32 Retrieves a Unicode string that is the user-readable name of the EFI Driver.\r
d1f95000 33\r
34 @param This A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.\r
af2dc6a7 35 @param Language A pointer to a three-character ISO 639-2 language identifier.\r
d1f95000 36 This is the language of the driver name that that the caller\r
37 is requesting, and it must match one of the languages specified\r
38 in SupportedLanguages. The number of languages supported by a\r
39 driver is up to the driver writer.\r
40 @param DriverName A pointer to the Unicode string to return. This Unicode string\r
41 is the name of the driver specified by This in the language\r
42 specified by Language.\r
43\r
44 @retval EFI_SUCCESS The Unicode string for the Driver specified by This\r
45 and the language specified by Language was returned\r
46 in DriverName.\r
47 @retval EFI_INVALID_PARAMETER Language is NULL.\r
48 @retval EFI_INVALID_PARAMETER DriverName is NULL.\r
49 @retval EFI_UNSUPPORTED The driver specified by This does not support the\r
50 language specified by Language.\r
51\r
52**/\r
53typedef\r
54EFI_STATUS\r
8b13229b 55(EFIAPI *EFI_COMPONENT_NAME_GET_DRIVER_NAME)(\r
d1f95000 56 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
57 IN CHAR8 *Language,\r
58 OUT CHAR16 **DriverName\r
59 );\r
60\r
61\r
62/**\r
63 Retrieves a Unicode string that is the user readable name of the controller\r
64 that is being managed by an EFI Driver.\r
65\r
66 @param This A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.\r
67 @param ControllerHandle The handle of a controller that the driver specified by\r
68 This is managing. This handle specifies the controller\r
69 whose name is to be returned.\r
70 @param ChildHandle The handle of the child controller to retrieve the name\r
71 of. This is an optional parameter that may be NULL. It\r
72 will be NULL for device drivers. It will also be NULL\r
73 for a bus drivers that wish to retrieve the name of the\r
74 bus controller. It will not be NULL for a bus driver\r
75 that wishes to retrieve the name of a child controller.\r
76 @param Language A pointer to a three character ISO 639-2 language\r
77 identifier. This is the language of the controller name\r
af2dc6a7 78 that the caller is requesting, and it must match one\r
d1f95000 79 of the languages specified in SupportedLanguages. The\r
80 number of languages supported by a driver is up to the\r
81 driver writer.\r
82 @param ControllerName A pointer to the Unicode string to return. This Unicode\r
83 string is the name of the controller specified by\r
84 ControllerHandle and ChildHandle in the language specified\r
af2dc6a7 85 by Language, from the point of view of the driver specified\r
d1f95000 86 by This.\r
87\r
af2dc6a7 88 @retval EFI_SUCCESS The Unicode string for the user-readable name in the\r
d1f95000 89 language specified by Language for the driver\r
90 specified by This was returned in DriverName.\r
18bd7e85 91 @retval EFI_INVALID_PARAMETER ControllerHandle is NULL.\r
d1f95000 92 @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid EFI_HANDLE.\r
93 @retval EFI_INVALID_PARAMETER Language is NULL.\r
94 @retval EFI_INVALID_PARAMETER ControllerName is NULL.\r
95 @retval EFI_UNSUPPORTED The driver specified by This is not currently managing\r
96 the controller specified by ControllerHandle and\r
97 ChildHandle.\r
98 @retval EFI_UNSUPPORTED The driver specified by This does not support the\r
99 language specified by Language.\r
100\r
101**/\r
102typedef\r
103EFI_STATUS\r
8b13229b 104(EFIAPI *EFI_COMPONENT_NAME_GET_CONTROLLER_NAME)(\r
d1f95000 105 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
106 IN EFI_HANDLE ControllerHandle,\r
107 IN EFI_HANDLE ChildHandle OPTIONAL,\r
108 IN CHAR8 *Language,\r
109 OUT CHAR16 **ControllerName\r
110 );\r
111\r
44717a39 112///\r
113/// This protocol is used to retrieve user readable names of drivers \r
114/// and controllers managed by UEFI Drivers.\r
115///\r
d1f95000 116struct _EFI_COMPONENT_NAME_PROTOCOL {\r
117 EFI_COMPONENT_NAME_GET_DRIVER_NAME GetDriverName;\r
118 EFI_COMPONENT_NAME_GET_CONTROLLER_NAME GetControllerName;\r
8b6c989b 119 ///\r
120 /// A Null-terminated ASCII string that contains one or more\r
121 /// ISO 639-2 language codes. This is the list of language codes\r
122 /// that this protocol supports. \r
123 ///\r
d1f95000 124 CHAR8 *SupportedLanguages;\r
125};\r
126\r
127extern EFI_GUID gEfiComponentNameProtocolGuid;\r
128\r
129#endif\r