]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Universal/Console/ConPlatformDxe/ComponentName.c
Add VFR compiler Path for x64 & IPF arch.
[mirror_edk2.git] / MdeModulePkg / Universal / Console / ConPlatformDxe / ComponentName.c
CommitLineData
95276127 1/*++\r
2\r
3Copyright (c) 2006, Intel Corporation \r
4All rights reserved. This program and the accompanying materials \r
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 ComponentName.c\r
15\r
16Abstract:\r
17\r
18--*/\r
19\r
20//\r
21// Include common header file for this module.\r
22//\r
23\r
24\r
25#include "ConPlatform.h"\r
26#include "ComponentName.h"\r
27\r
28//\r
29// EFI Component Name Protocol\r
30//\r
31EFI_COMPONENT_NAME_PROTOCOL gConPlatformComponentName = {\r
32 ConPlatformComponentNameGetDriverName,\r
33 ConPlatformComponentNameGetControllerName,\r
34 "eng"\r
35};\r
36\r
37STATIC EFI_UNICODE_STRING_TABLE mConPlatformDriverNameTable[] = {\r
38 {\r
39 "eng",\r
40 L"Platform Console Management Driver"\r
41 },\r
42 {\r
43 NULL,\r
44 NULL\r
45 }\r
46};\r
47\r
48EFI_STATUS\r
49EFIAPI\r
50ConPlatformComponentNameGetDriverName (\r
51 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
52 IN CHAR8 *Language,\r
53 OUT CHAR16 **DriverName\r
54 )\r
55/*++\r
56\r
57 Routine Description:\r
58 Retrieves a Unicode string that is the user readable name of the EFI Driver.\r
59\r
60 Arguments:\r
61 This - A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.\r
62 Language - A pointer to a three character ISO 639-2 language identifier.\r
63 This is the language of the driver name that that the caller \r
64 is requesting, and it must match one of the languages specified\r
65 in SupportedLanguages. The number of languages supported by a \r
66 driver is up to the driver writer.\r
67 DriverName - A pointer to the Unicode string to return. This Unicode string\r
68 is the name of the driver specified by This in the language \r
69 specified by Language.\r
70\r
71 Returns:\r
72 EFI_SUCCESS - The Unicode string for the Driver specified by This\r
73 and the language specified by Language was returned \r
74 in DriverName.\r
75 EFI_INVALID_PARAMETER - Language is NULL.\r
76 EFI_INVALID_PARAMETER - DriverName is NULL.\r
77 EFI_UNSUPPORTED - The driver specified by This does not support the \r
78 language specified by Language.\r
79\r
80--*/\r
81{\r
82 return LookupUnicodeString (\r
83 Language,\r
84 gConPlatformComponentName.SupportedLanguages,\r
85 mConPlatformDriverNameTable,\r
86 DriverName\r
87 );\r
88}\r
89\r
90EFI_STATUS\r
91EFIAPI\r
92ConPlatformComponentNameGetControllerName (\r
93 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
94 IN EFI_HANDLE ControllerHandle,\r
95 IN EFI_HANDLE ChildHandle OPTIONAL,\r
96 IN CHAR8 *Language,\r
97 OUT CHAR16 **ControllerName\r
98 )\r
99/*++\r
100\r
101 Routine Description:\r
102 Retrieves a Unicode string that is the user readable name of the controller\r
103 that is being managed by an EFI Driver.\r
104\r
105 Arguments:\r
106 This - A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.\r
107 ControllerHandle - The handle of a controller that the driver specified by \r
108 This is managing. This handle specifies the controller \r
109 whose name is to be returned.\r
110 ChildHandle - The handle of the child controller to retrieve the name \r
111 of. This is an optional parameter that may be NULL. It \r
112 will be NULL for device drivers. It will also be NULL \r
113 for a bus drivers that wish to retrieve the name of the \r
114 bus controller. It will not be NULL for a bus driver \r
115 that wishes to retrieve the name of a child controller.\r
116 Language - A pointer to a three character ISO 639-2 language \r
117 identifier. This is the language of the controller name \r
118 that that the caller is requesting, and it must match one\r
119 of the languages specified in SupportedLanguages. The \r
120 number of languages supported by a driver is up to the \r
121 driver writer.\r
122 ControllerName - A pointer to the Unicode string to return. This Unicode\r
123 string is the name of the controller specified by \r
124 ControllerHandle and ChildHandle in the language \r
125 specified by Language from the point of view of the \r
126 driver specified by This. \r
127\r
128 Returns:\r
129 EFI_SUCCESS - The Unicode string for the user readable name in the\r
130 language specified by Language for the driver \r
131 specified by This was returned in DriverName.\r
132 EFI_INVALID_PARAMETER - ControllerHandle is not a valid EFI_HANDLE.\r
133 EFI_INVALID_PARAMETER - ChildHandle is not NULL and it is not a valid \r
134 EFI_HANDLE.\r
135 EFI_INVALID_PARAMETER - Language is NULL.\r
136 EFI_INVALID_PARAMETER - ControllerName is NULL.\r
137 EFI_UNSUPPORTED - The driver specified by This is not currently \r
138 managing the controller specified by \r
139 ControllerHandle and ChildHandle.\r
140 EFI_UNSUPPORTED - The driver specified by This does not support the \r
141 language specified by Language.\r
142\r
143--*/\r
144{\r
145 return EFI_UNSUPPORTED;\r
146}\r