]> git.proxmox.com Git - mirror_edk2.git/blob - IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/ComponentName.h
Import IsaSerialDxe in IntelFrameworkModulePkg.
[mirror_edk2.git] / IntelFrameworkModulePkg / Bus / Isa / IsaSerialDxe / ComponentName.h
1 /*++
2
3 Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.
4 This software and associated documentation (if any) is furnished
5 under a license and may only be used or copied in accordance
6 with the terms of the license. Except as permitted by such
7 license, no part of this software or documentation may be
8 reproduced, stored in a retrieval system, or transmitted in any
9 form or by any means without the express written consent of
10 Intel Corporation.
11
12
13 Module Name:
14
15 ComponentName.h
16
17 Abstract:
18
19
20 Revision History:
21
22 --*/
23
24 #ifndef _SERIAL_COMPONENT_NAME_H
25 #define _SERIAL_COMPONENT_NAME_H
26
27 #define SERIAL_PORT_NAME "ISA Serial Port # "
28 #define ADD_SERIAL_NAME(x, y) AddName ((x), (y))
29
30 extern EFI_COMPONENT_NAME_PROTOCOL gIsaSerialComponentName;
31
32 //
33 // EFI Component Name Functions
34 //
35 EFI_STATUS
36 EFIAPI
37 IsaSerialComponentNameGetDriverName (
38 IN EFI_COMPONENT_NAME_PROTOCOL *This,
39 IN CHAR8 *Language,
40 OUT CHAR16 **DriverName
41 )
42 /*++
43
44 Routine Description:
45
46 Retrieves a Unicode string that is the user readable name of the EFI Driver.
47
48 Arguments:
49
50 This - A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.
51 Language - A pointer to a three character ISO 639-2 language identifier.
52 This is the language of the driver name that that the caller
53 is requesting, and it must match one of the languages specified
54 in SupportedLanguages. The number of languages supported by a
55 driver is up to the driver writer.
56 DriverName - A pointer to the Unicode string to return. This Unicode string
57 is the name of the driver specified by This in the language
58 specified by Language.
59
60 Returns:
61
62 EFI_SUCCESS - The Unicode string for the Driver specified by This
63 and the language specified by Language was returned
64 in DriverName.
65 EFI_INVALID_PARAMETER - Language is NULL.
66 EFI_INVALID_PARAMETER - DriverName is NULL.
67 EFI_UNSUPPORTED - The driver specified by This does not support the
68 language specified by Language.
69
70 --*/
71 ;
72
73 EFI_STATUS
74 EFIAPI
75 IsaSerialComponentNameGetControllerName (
76 IN EFI_COMPONENT_NAME_PROTOCOL *This,
77 IN EFI_HANDLE ControllerHandle,
78 IN EFI_HANDLE ChildHandle OPTIONAL,
79 IN CHAR8 *Language,
80 OUT CHAR16 **ControllerName
81 )
82 /*++
83
84 Routine Description:
85
86 Retrieves a Unicode string that is the user readable name of the controller
87 that is being managed by an EFI Driver.
88
89 Arguments:
90
91 This - A pointer to the EFI_COMPONENT_NAME_PROTOCOL instance.
92 ControllerHandle - The handle of a controller that the driver specified by
93 This is managing. This handle specifies the controller
94 whose name is to be returned.
95 ChildHandle - The handle of the child controller to retrieve the name
96 of. This is an optional parameter that may be NULL. It
97 will be NULL for device drivers. It will also be NULL
98 for a bus drivers that wish to retrieve the name of the
99 bus controller. It will not be NULL for a bus driver
100 that wishes to retrieve the name of a child controller.
101 Language - A pointer to a three character ISO 639-2 language
102 identifier. This is the language of the controller name
103 that that the caller is requesting, and it must match one
104 of the languages specified in SupportedLanguages. The
105 number of languages supported by a driver is up to the
106 driver writer.
107 ControllerName - A pointer to the Unicode string to return. This Unicode
108 string is the name of the controller specified by
109 ControllerHandle and ChildHandle in the language
110 specified by Language from the point of view of the
111 driver specified by This.
112
113 Returns:
114
115 EFI_SUCCESS - The Unicode string for the user readable name in the
116 language specified by Language for the driver
117 specified by This was returned in DriverName.
118 EFI_INVALID_PARAMETER - ControllerHandle is not a valid EFI_HANDLE.
119 EFI_INVALID_PARAMETER - ChildHandle is not NULL and it is not a valid
120 EFI_HANDLE.
121 EFI_INVALID_PARAMETER - Language is NULL.
122 EFI_INVALID_PARAMETER - ControllerName is NULL.
123 EFI_UNSUPPORTED - The driver specified by This is not currently
124 managing the controller specified by
125 ControllerHandle and ChildHandle.
126 EFI_UNSUPPORTED - The driver specified by This does not support the
127 language specified by Language.
128
129 --*/
130 ;
131
132 VOID
133 AddName (
134 IN SERIAL_DEV *SerialDevice,
135 IN EFI_ISA_IO_PROTOCOL *IsaIo
136 )
137 /*++
138
139 Routine Description:
140
141 Add the component name for the serial io device
142
143 Arguments:
144
145 SerialDevice - A pointer to the SERIAL_DEV instance.
146 IsaIo - A pointer to the EFI_ISA_IO_PROTOCOL instance.
147
148 Returns:
149
150 None
151
152 --*/
153 ;
154
155 #endif