]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitter.h
Fix the comments to follow UEFI Spec regarding how to check an EFI_HANDLE is valid...
[mirror_edk2.git] / MdeModulePkg / Universal / Console / ConSplitterDxe / ConSplitter.h
CommitLineData
a4d608d1 1/** @file\r
95276127 2 Private data structures for the Console Splitter driver\r
3\r
9de33db4 4Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>\r
e5eed7d3 5This program and the accompanying materials\r
95276127 6are licensed and made available under the terms and conditions of the BSD License\r
7which accompanies this distribution. The full text of the license may be found at\r
8http://opensource.org/licenses/bsd-license.php\r
9\r
10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
12\r
13**/\r
14\r
15#ifndef _CON_SPLITTER_H_\r
16#define _CON_SPLITTER_H_\r
17\r
60c93673 18#include <Uefi.h>\r
fc753d3b 19\r
20#include <Protocol/DevicePath.h>\r
21#include <Protocol/ComponentName.h>\r
22#include <Protocol/DriverBinding.h>\r
97a079ed 23#include <Protocol/SimplePointer.h>\r
8ae0b360 24#include <Protocol/AbsolutePointer.h>\r
97a079ed 25#include <Protocol/SimpleTextOut.h>\r
97a079ed 26#include <Protocol/SimpleTextIn.h>\r
66aa04e4 27#include <Protocol/SimpleTextInEx.h>\r
fc753d3b 28#include <Protocol/GraphicsOutput.h>\r
29#include <Protocol/UgaDraw.h>\r
30\r
fc753d3b 31#include <Guid/ConsoleInDevice.h>\r
97a079ed
A
32#include <Guid/StandardErrorDevice.h>\r
33#include <Guid/ConsoleOutDevice.h>\r
fc753d3b 34\r
d0c64728 35#include <Library/PcdLib.h>\r
97a079ed
A
36#include <Library/DebugLib.h>\r
37#include <Library/UefiDriverEntryPoint.h>\r
38#include <Library/UefiLib.h>\r
39#include <Library/BaseLib.h>\r
40#include <Library/BaseMemoryLib.h>\r
41#include <Library/MemoryAllocationLib.h>\r
42#include <Library/UefiBootServicesTableLib.h>\r
189eac21 43#include <Library/UefiRuntimeServicesTableLib.h>\r
44\r
97a079ed 45\r
95276127 46//\r
97a079ed 47// Driver Binding Externs\r
95276127 48//\r
5bca971e 49extern EFI_DRIVER_BINDING_PROTOCOL gConSplitterConInDriverBinding;\r
50extern EFI_COMPONENT_NAME_PROTOCOL gConSplitterConInComponentName;\r
51extern EFI_COMPONENT_NAME2_PROTOCOL gConSplitterConInComponentName2;\r
52extern EFI_DRIVER_BINDING_PROTOCOL gConSplitterSimplePointerDriverBinding;\r
53extern EFI_COMPONENT_NAME_PROTOCOL gConSplitterSimplePointerComponentName;\r
54extern EFI_COMPONENT_NAME2_PROTOCOL gConSplitterSimplePointerComponentName2;\r
b71f6b3c 55extern EFI_DRIVER_BINDING_PROTOCOL gConSplitterAbsolutePointerDriverBinding;\r
8ae0b360 56extern EFI_COMPONENT_NAME_PROTOCOL gConSplitterAbsolutePointerComponentName;\r
57extern EFI_COMPONENT_NAME2_PROTOCOL gConSplitterAbsolutePointerComponentName2;\r
5bca971e 58extern EFI_DRIVER_BINDING_PROTOCOL gConSplitterConOutDriverBinding;\r
59extern EFI_COMPONENT_NAME_PROTOCOL gConSplitterConOutComponentName;\r
60extern EFI_COMPONENT_NAME2_PROTOCOL gConSplitterConOutComponentName2;\r
61extern EFI_DRIVER_BINDING_PROTOCOL gConSplitterStdErrDriverBinding;\r
62extern EFI_COMPONENT_NAME_PROTOCOL gConSplitterStdErrComponentName;\r
63extern EFI_COMPONENT_NAME2_PROTOCOL gConSplitterStdErrComponentName2;\r
97a079ed 64\r
66aa04e4 65\r
fc753d3b 66//\r
97a079ed
A
67// These definitions were in the old Hii protocol, but are not in the new UEFI\r
68// version. So they are defined locally.\r
fc753d3b 69//\r
97a079ed 70#define UNICODE_NARROW_CHAR 0xFFF0\r
d0c64728 71#define UNICODE_WIDE_CHAR 0xFFF1\r
97a079ed 72\r
95276127 73\r
74//\r
75// Private Data Structures\r
76//\r
77#define CONSOLE_SPLITTER_CONSOLES_ALLOC_UNIT 32\r
78#define CONSOLE_SPLITTER_MODES_ALLOC_UNIT 32\r
95276127 79\r
189eac21 80\r
81typedef struct {\r
82 UINTN Column;\r
83 UINTN Row;\r
84} CONSOLE_OUT_MODE;\r
85\r
95276127 86typedef struct {\r
2da292f6 87 UINTN Columns;\r
88 UINTN Rows;\r
95276127 89} TEXT_OUT_SPLITTER_QUERY_DATA;\r
90\r
95276127 91\r
fc753d3b 92#define TEXT_IN_EX_SPLITTER_NOTIFY_SIGNATURE SIGNATURE_32 ('T', 'i', 'S', 'n')\r
66aa04e4 93\r
fc753d3b 94//\r
95// Private data for Text In Ex Splitter Notify\r
96//\r
66aa04e4 97typedef struct _TEXT_IN_EX_SPLITTER_NOTIFY {\r
98 UINTN Signature;\r
99 EFI_HANDLE *NotifyHandleList;\r
100 EFI_HANDLE NotifyHandle;\r
101 EFI_KEY_DATA KeyData;\r
102 EFI_KEY_NOTIFY_FUNCTION KeyNotificationFn;\r
103 LIST_ENTRY NotifyEntry;\r
104} TEXT_IN_EX_SPLITTER_NOTIFY;\r
8ae0b360 105\r
fc753d3b 106#define TEXT_IN_EX_SPLITTER_NOTIFY_FROM_THIS(a) \\r
107 CR ((a), \\r
108 TEXT_IN_EX_SPLITTER_NOTIFY, \\r
109 NotifyEntry, \\r
110 TEXT_IN_EX_SPLITTER_NOTIFY_SIGNATURE \\r
111 )\r
112\r
113#define TEXT_IN_SPLITTER_PRIVATE_DATA_SIGNATURE SIGNATURE_32 ('T', 'i', 'S', 'p')\r
114\r
115//\r
116// Private data for the Console In splitter\r
117//\r
95276127 118typedef struct {\r
db9d722d 119 UINT64 Signature;\r
120 EFI_HANDLE VirtualHandle;\r
121\r
122 EFI_SIMPLE_TEXT_INPUT_PROTOCOL TextIn;\r
123 UINTN CurrentNumberOfConsoles;\r
124 EFI_SIMPLE_TEXT_INPUT_PROTOCOL **TextInList;\r
125 UINTN TextInListCount;\r
126\r
127 EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL TextInEx;\r
128 UINTN CurrentNumberOfExConsoles;\r
129 EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL **TextInExList;\r
130 UINTN TextInExListCount;\r
aec072ad 131 LIST_ENTRY NotifyList;\r
db9d722d 132\r
133\r
134 EFI_SIMPLE_POINTER_PROTOCOL SimplePointer;\r
135 EFI_SIMPLE_POINTER_MODE SimplePointerMode;\r
136 UINTN CurrentNumberOfPointers;\r
137 EFI_SIMPLE_POINTER_PROTOCOL **PointerList;\r
138 UINTN PointerListCount;\r
139\r
140 EFI_ABSOLUTE_POINTER_PROTOCOL AbsolutePointer;\r
141 EFI_ABSOLUTE_POINTER_MODE AbsolutePointerMode;\r
142 UINTN CurrentNumberOfAbsolutePointers;\r
143 EFI_ABSOLUTE_POINTER_PROTOCOL **AbsolutePointerList;\r
144 UINTN AbsolutePointerListCount;\r
aec072ad 145 BOOLEAN AbsoluteInputEventSignalState;\r
db9d722d 146\r
db9d722d 147 BOOLEAN KeyEventSignalState;\r
148 BOOLEAN InputEventSignalState;\r
95276127 149} TEXT_IN_SPLITTER_PRIVATE_DATA;\r
150\r
151#define TEXT_IN_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \\r
fc753d3b 152 CR ((a), \\r
95276127 153 TEXT_IN_SPLITTER_PRIVATE_DATA, \\r
154 TextIn, \\r
155 TEXT_IN_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
156 )\r
157\r
158#define TEXT_IN_SPLITTER_PRIVATE_DATA_FROM_SIMPLE_POINTER_THIS(a) \\r
fc753d3b 159 CR ((a), \\r
95276127 160 TEXT_IN_SPLITTER_PRIVATE_DATA, \\r
161 SimplePointer, \\r
162 TEXT_IN_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
163 )\r
66aa04e4 164#define TEXT_IN_EX_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \\r
fc753d3b 165 CR (a, \\r
166 TEXT_IN_SPLITTER_PRIVATE_DATA, \\r
167 TextInEx, \\r
168 TEXT_IN_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
66aa04e4 169 )\r
170\r
171#define TEXT_IN_SPLITTER_PRIVATE_DATA_FROM_ABSOLUTE_POINTER_THIS(a) \\r
fc753d3b 172 CR (a, \\r
173 TEXT_IN_SPLITTER_PRIVATE_DATA, \\r
174 AbsolutePointer, \\r
175 TEXT_IN_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
66aa04e4 176 )\r
95276127 177\r
fc753d3b 178\r
f3f2e05d 179#define TEXT_OUT_SPLITTER_PRIVATE_DATA_SIGNATURE SIGNATURE_32 ('T', 'o', 'S', 'p')\r
95276127 180\r
181typedef struct {\r
182 EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput;\r
183 EFI_UGA_DRAW_PROTOCOL *UgaDraw;\r
184 EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut;\r
95276127 185} TEXT_OUT_AND_GOP_DATA;\r
186\r
fc753d3b 187//\r
188// Private data for the Console Out splitter\r
189//\r
95276127 190typedef struct {\r
4b5c4fba 191 UINT64 Signature;\r
192 EFI_HANDLE VirtualHandle;\r
193 EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL TextOut;\r
194 EFI_SIMPLE_TEXT_OUTPUT_MODE TextOutMode;\r
ed055f1b 195\r
4b5c4fba 196 EFI_UGA_DRAW_PROTOCOL UgaDraw;\r
197 UINT32 UgaHorizontalResolution;\r
198 UINT32 UgaVerticalResolution;\r
199 UINT32 UgaColorDepth;\r
200 UINT32 UgaRefreshRate;\r
ed055f1b 201\r
4b5c4fba 202 EFI_GRAPHICS_OUTPUT_PROTOCOL GraphicsOutput;\r
aec072ad 203 EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *GraphicsOutputModeBuffer;\r
4b5c4fba 204 UINTN CurrentNumberOfGraphicsOutput;\r
205 UINTN CurrentNumberOfUgaDraw;\r
ed055f1b 206\r
4b5c4fba 207 UINTN CurrentNumberOfConsoles;\r
208 TEXT_OUT_AND_GOP_DATA *TextOutList;\r
209 UINTN TextOutListCount;\r
210 TEXT_OUT_SPLITTER_QUERY_DATA *TextOutQueryData;\r
211 UINTN TextOutQueryDataCount;\r
212 INT32 *TextOutModeMap;\r
ed055f1b 213\r
95276127 214} TEXT_OUT_SPLITTER_PRIVATE_DATA;\r
215\r
216#define TEXT_OUT_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \\r
fc753d3b 217 CR ((a), \\r
95276127 218 TEXT_OUT_SPLITTER_PRIVATE_DATA, \\r
219 TextOut, \\r
220 TEXT_OUT_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
221 )\r
222\r
223#define GRAPHICS_OUTPUT_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \\r
fc753d3b 224 CR ((a), \\r
95276127 225 TEXT_OUT_SPLITTER_PRIVATE_DATA, \\r
226 GraphicsOutput, \\r
227 TEXT_OUT_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
228 )\r
229\r
230#define UGA_DRAW_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \\r
fc753d3b 231 CR ((a), \\r
95276127 232 TEXT_OUT_SPLITTER_PRIVATE_DATA, \\r
233 UgaDraw, \\r
234 TEXT_OUT_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
235 )\r
236\r
237#define CONSOLE_CONTROL_SPLITTER_PRIVATE_DATA_FROM_THIS(a) \\r
fc753d3b 238 CR ((a), \\r
95276127 239 TEXT_OUT_SPLITTER_PRIVATE_DATA, \\r
240 ConsoleControl, \\r
241 TEXT_OUT_SPLITTER_PRIVATE_DATA_SIGNATURE \\r
242 )\r
243\r
244//\r
245// Function Prototypes\r
246//\r
415df2a3 247\r
248/**\r
249 The user Entry Point for module ConSplitter. The user code starts with this function.\r
250\r
251 Installs driver module protocols and. Creates virtual device handles for ConIn,\r
252 ConOut, and StdErr. Installs Simple Text In protocol, Simple Text In Ex protocol,\r
ed055f1b 253 Simple Pointer protocol, Absolute Pointer protocol on those virtual handlers.\r
415df2a3 254 Installs Graphics Output protocol and/or UGA Draw protocol if needed.\r
255\r
256 @param[in] ImageHandle The firmware allocated handle for the EFI image.\r
257 @param[in] SystemTable A pointer to the EFI System Table.\r
258\r
259 @retval EFI_SUCCESS The entry point is executed successfully.\r
260 @retval other Some error occurs when executing this entry point.\r
261\r
262**/\r
95276127 263EFI_STATUS\r
264EFIAPI\r
265ConSplitterDriverEntry (\r
266 IN EFI_HANDLE ImageHandle,\r
267 IN EFI_SYSTEM_TABLE *SystemTable\r
ed66e1bc 268 );\r
95276127 269\r
a4d608d1 270/**\r
4b5c4fba 271 Construct console input devices' private data.\r
a4d608d1 272\r
273 @param ConInPrivate A pointer to the TEXT_IN_SPLITTER_PRIVATE_DATA\r
274 structure.\r
275\r
276 @retval EFI_OUT_OF_RESOURCES Out of resources.\r
fc753d3b 277 @retval EFI_SUCCESS Text Input Devcie's private data has been constructed.\r
4b5c4fba 278 @retval other Failed to construct private data.\r
a4d608d1 279\r
280**/\r
95276127 281EFI_STATUS\r
282ConSplitterTextInConstructor (\r
fc753d3b 283 TEXT_IN_SPLITTER_PRIVATE_DATA *ConInPrivate\r
ed66e1bc 284 );\r
95276127 285\r
415df2a3 286/**\r
287 Construct console output devices' private data.\r
288\r
fc753d3b 289 @param ConOutPrivate A pointer to the TEXT_OUT_SPLITTER_PRIVATE_DATA\r
415df2a3 290 structure.\r
291\r
292 @retval EFI_OUT_OF_RESOURCES Out of resources.\r
4b5c4fba 293 @retval EFI_SUCCESS Text Input Devcie's private data has been constructed.\r
415df2a3 294\r
295**/\r
95276127 296EFI_STATUS\r
297ConSplitterTextOutConstructor (\r
fc753d3b 298 TEXT_OUT_SPLITTER_PRIVATE_DATA *ConOutPrivate\r
ed66e1bc 299 );\r
95276127 300\r
a4d608d1 301\r
302/**\r
ed055f1b 303 Test to see if Console In Device could be supported on the Controller.\r
a4d608d1 304\r
fc753d3b 305 @param This Driver Binding protocol instance pointer.\r
4b5c4fba 306 @param ControllerHandle Handle of device to test.\r
307 @param RemainingDevicePath Optional parameter use to pick a specific child\r
308 device to start.\r
a4d608d1 309\r
4b5c4fba 310 @retval EFI_SUCCESS This driver supports this device.\r
311 @retval other This driver does not support this device.\r
a4d608d1 312\r
313**/\r
95276127 314EFI_STATUS\r
315EFIAPI\r
316ConSplitterConInDriverBindingSupported (\r
317 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
318 IN EFI_HANDLE ControllerHandle,\r
319 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 320 );\r
95276127 321\r
a4d608d1 322/**\r
ed055f1b 323 Test to see if Simple Pointer protocol could be supported on the Controller.\r
a4d608d1 324\r
fc753d3b 325 @param This Driver Binding protocol instance pointer.\r
4b5c4fba 326 @param ControllerHandle Handle of device to test.\r
327 @param RemainingDevicePath Optional parameter use to pick a specific child\r
328 device to start.\r
a4d608d1 329\r
4b5c4fba 330 @retval EFI_SUCCESS This driver supports this device.\r
331 @retval other This driver does not support this device.\r
a4d608d1 332\r
333**/\r
95276127 334EFI_STATUS\r
335EFIAPI\r
336ConSplitterSimplePointerDriverBindingSupported (\r
337 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
338 IN EFI_HANDLE ControllerHandle,\r
339 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 340 );\r
95276127 341\r
a4d608d1 342/**\r
ed055f1b 343 Test to see if Console Out Device could be supported on the Controller.\r
a4d608d1 344\r
fc753d3b 345 @param This Driver Binding protocol instance pointer.\r
4b5c4fba 346 @param ControllerHandle Handle of device to test.\r
347 @param RemainingDevicePath Optional parameter use to pick a specific child\r
348 device to start.\r
a4d608d1 349\r
4b5c4fba 350 @retval EFI_SUCCESS This driver supports this device.\r
351 @retval other This driver does not support this device.\r
a4d608d1 352\r
353**/\r
95276127 354EFI_STATUS\r
355EFIAPI\r
356ConSplitterConOutDriverBindingSupported (\r
357 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
358 IN EFI_HANDLE ControllerHandle,\r
359 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 360 );\r
95276127 361\r
a4d608d1 362/**\r
ed055f1b 363 Test to see if Standard Error Device could be supported on the Controller.\r
a4d608d1 364\r
fc753d3b 365 @param This Driver Binding protocol instance pointer.\r
4b5c4fba 366 @param ControllerHandle Handle of device to test.\r
367 @param RemainingDevicePath Optional parameter use to pick a specific child\r
368 device to start.\r
a4d608d1 369\r
4b5c4fba 370 @retval EFI_SUCCESS This driver supports this device.\r
371 @retval other This driver does not support this device.\r
a4d608d1 372\r
373**/\r
95276127 374EFI_STATUS\r
375EFIAPI\r
376ConSplitterStdErrDriverBindingSupported (\r
377 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
378 IN EFI_HANDLE ControllerHandle,\r
379 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 380 );\r
95276127 381\r
415df2a3 382/**\r
ed055f1b 383 Start Console In Consplitter on device handle.\r
384\r
fc753d3b 385 @param This Driver Binding protocol instance pointer.\r
415df2a3 386 @param ControllerHandle Handle of device to bind driver to.\r
387 @param RemainingDevicePath Optional parameter use to pick a specific child\r
388 device to start.\r
389\r
390 @retval EFI_SUCCESS Console In Consplitter is added to ControllerHandle.\r
391 @retval other Console In Consplitter does not support this device.\r
392\r
393**/\r
95276127 394EFI_STATUS\r
395EFIAPI\r
396ConSplitterConInDriverBindingStart (\r
397 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
398 IN EFI_HANDLE ControllerHandle,\r
399 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 400 );\r
95276127 401\r
415df2a3 402/**\r
ed055f1b 403 Start Simple Pointer Consplitter on device handle.\r
404\r
fc753d3b 405 @param This Driver Binding protocol instance pointer.\r
415df2a3 406 @param ControllerHandle Handle of device to bind driver to.\r
407 @param RemainingDevicePath Optional parameter use to pick a specific child\r
408 device to start.\r
409\r
410 @retval EFI_SUCCESS Simple Pointer Consplitter is added to ControllerHandle.\r
411 @retval other Simple Pointer Consplitter does not support this device.\r
412\r
413**/\r
95276127 414EFI_STATUS\r
415EFIAPI\r
416ConSplitterSimplePointerDriverBindingStart (\r
417 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
418 IN EFI_HANDLE ControllerHandle,\r
419 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 420 );\r
95276127 421\r
415df2a3 422/**\r
ed055f1b 423 Start Console Out Consplitter on device handle.\r
424\r
fc753d3b 425 @param This Driver Binding protocol instance pointer.\r
415df2a3 426 @param ControllerHandle Handle of device to bind driver to.\r
427 @param RemainingDevicePath Optional parameter use to pick a specific child\r
428 device to start.\r
429\r
430 @retval EFI_SUCCESS Console Out Consplitter is added to ControllerHandle.\r
431 @retval other Console Out Consplitter does not support this device.\r
432\r
433**/\r
95276127 434EFI_STATUS\r
435EFIAPI\r
436ConSplitterConOutDriverBindingStart (\r
437 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
438 IN EFI_HANDLE ControllerHandle,\r
439 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 440 );\r
95276127 441\r
415df2a3 442/**\r
ed055f1b 443 Start Standard Error Consplitter on device handle.\r
444\r
fc753d3b 445 @param This Driver Binding protocol instance pointer.\r
415df2a3 446 @param ControllerHandle Handle of device to bind driver to.\r
447 @param RemainingDevicePath Optional parameter use to pick a specific child\r
448 device to start.\r
449\r
450 @retval EFI_SUCCESS Standard Error Consplitter is added to ControllerHandle.\r
451 @retval other Standard Error Consplitter does not support this device.\r
452\r
453**/\r
95276127 454EFI_STATUS\r
455EFIAPI\r
456ConSplitterStdErrDriverBindingStart (\r
457 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
458 IN EFI_HANDLE ControllerHandle,\r
459 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 460 );\r
95276127 461\r
415df2a3 462/**\r
463 Stop Console In ConSplitter on ControllerHandle by closing Console In Devcice GUID.\r
464\r
fc753d3b 465 @param This Driver Binding protocol instance pointer.\r
415df2a3 466 @param ControllerHandle Handle of device to stop driver on\r
467 @param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of\r
468 children is zero stop the entire bus driver.\r
469 @param ChildHandleBuffer List of Child Handles to Stop.\r
470\r
471 @retval EFI_SUCCESS This driver is removed ControllerHandle\r
472 @retval other This driver was not removed from this device\r
473\r
474**/\r
95276127 475EFI_STATUS\r
476EFIAPI\r
477ConSplitterConInDriverBindingStop (\r
478 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
479 IN EFI_HANDLE ControllerHandle,\r
480 IN UINTN NumberOfChildren,\r
481 IN EFI_HANDLE *ChildHandleBuffer\r
ed66e1bc 482 );\r
95276127 483\r
415df2a3 484/**\r
485 Stop Simple Pointer protocol ConSplitter on ControllerHandle by closing\r
486 Simple Pointer protocol.\r
487\r
fc753d3b 488 @param This Driver Binding protocol instance pointer.\r
415df2a3 489 @param ControllerHandle Handle of device to stop driver on\r
490 @param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of\r
491 children is zero stop the entire bus driver.\r
492 @param ChildHandleBuffer List of Child Handles to Stop.\r
493\r
494 @retval EFI_SUCCESS This driver is removed ControllerHandle\r
495 @retval other This driver was not removed from this device\r
496\r
497**/\r
95276127 498EFI_STATUS\r
499EFIAPI\r
500ConSplitterSimplePointerDriverBindingStop (\r
501 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
502 IN EFI_HANDLE ControllerHandle,\r
503 IN UINTN NumberOfChildren,\r
504 IN EFI_HANDLE *ChildHandleBuffer\r
ed66e1bc 505 );\r
95276127 506\r
415df2a3 507/**\r
fc753d3b 508 Stop Console Out ConSplitter on device handle by closing Console Out Devcice GUID.\r
415df2a3 509\r
fc753d3b 510 @param This Driver Binding protocol instance pointer.\r
415df2a3 511 @param ControllerHandle Handle of device to stop driver on\r
512 @param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of\r
513 children is zero stop the entire bus driver.\r
514 @param ChildHandleBuffer List of Child Handles to Stop.\r
515\r
516 @retval EFI_SUCCESS This driver is removed ControllerHandle\r
517 @retval other This driver was not removed from this device\r
518\r
519**/\r
95276127 520EFI_STATUS\r
521EFIAPI\r
522ConSplitterConOutDriverBindingStop (\r
523 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
524 IN EFI_HANDLE ControllerHandle,\r
525 IN UINTN NumberOfChildren,\r
526 IN EFI_HANDLE *ChildHandleBuffer\r
ed66e1bc 527 );\r
95276127 528\r
415df2a3 529/**\r
530 Stop Standard Error ConSplitter on ControllerHandle by closing Standard Error GUID.\r
531\r
fc753d3b 532 @param This Driver Binding protocol instance pointer.\r
415df2a3 533 @param ControllerHandle Handle of device to stop driver on\r
534 @param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of\r
535 children is zero stop the entire bus driver.\r
536 @param ChildHandleBuffer List of Child Handles to Stop.\r
537\r
538 @retval EFI_SUCCESS This driver is removed ControllerHandle\r
539 @retval other This driver was not removed from this device\r
540\r
541**/\r
95276127 542EFI_STATUS\r
543EFIAPI\r
544ConSplitterStdErrDriverBindingStop (\r
545 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
546 IN EFI_HANDLE ControllerHandle,\r
547 IN UINTN NumberOfChildren,\r
548 IN EFI_HANDLE *ChildHandleBuffer\r
ed66e1bc 549 );\r
95276127 550\r
8ae0b360 551\r
415df2a3 552/**\r
ed055f1b 553 Test to see if Absolute Pointer protocol could be supported on the Controller.\r
415df2a3 554\r
fc753d3b 555 @param This Driver Binding protocol instance pointer.\r
415df2a3 556 @param ControllerHandle Handle of device to test.\r
557 @param RemainingDevicePath Optional parameter use to pick a specific child\r
558 device to start.\r
559\r
4b5c4fba 560 @retval EFI_SUCCESS This driver supports this device.\r
561 @retval other This driver does not support this device.\r
415df2a3 562\r
563**/\r
8ae0b360 564EFI_STATUS\r
565EFIAPI\r
566ConSplitterAbsolutePointerDriverBindingSupported (\r
567 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
568 IN EFI_HANDLE ControllerHandle,\r
569 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 570 );\r
8ae0b360 571\r
415df2a3 572/**\r
ed055f1b 573 Start Absolute Pointer Consplitter on device handle.\r
574\r
fc753d3b 575 @param This Driver Binding protocol instance pointer.\r
415df2a3 576 @param ControllerHandle Handle of device to bind driver to.\r
577 @param RemainingDevicePath Optional parameter use to pick a specific child\r
578 device to start.\r
579\r
580 @retval EFI_SUCCESS Absolute Pointer Consplitter is added to ControllerHandle.\r
581 @retval other Absolute Pointer Consplitter does not support this device.\r
582\r
583**/\r
8ae0b360 584EFI_STATUS\r
585EFIAPI\r
586ConSplitterAbsolutePointerDriverBindingStart (\r
587 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
588 IN EFI_HANDLE ControllerHandle,\r
589 IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath\r
ed66e1bc 590 );\r
8ae0b360 591\r
415df2a3 592/**\r
593 Stop Absolute Pointer protocol ConSplitter on ControllerHandle by closing\r
594 Absolute Pointer protocol.\r
595\r
fc753d3b 596 @param This Driver Binding protocol instance pointer.\r
415df2a3 597 @param ControllerHandle Handle of device to stop driver on\r
598 @param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of\r
599 children is zero stop the entire bus driver.\r
600 @param ChildHandleBuffer List of Child Handles to Stop.\r
601\r
602 @retval EFI_SUCCESS This driver is removed ControllerHandle\r
603 @retval other This driver was not removed from this device\r
604\r
605**/\r
8ae0b360 606EFI_STATUS\r
607EFIAPI\r
608ConSplitterAbsolutePointerDriverBindingStop (\r
609 IN EFI_DRIVER_BINDING_PROTOCOL *This,\r
610 IN EFI_HANDLE ControllerHandle,\r
611 IN UINTN NumberOfChildren,\r
612 IN EFI_HANDLE *ChildHandleBuffer\r
ed66e1bc 613 );\r
8ae0b360 614\r
415df2a3 615/**\r
616 Add Absolute Pointer Device in Consplitter Absolute Pointer list.\r
617\r
618 @param Private Text In Splitter pointer.\r
619 @param AbsolutePointer Absolute Pointer protocol pointer.\r
620\r
621 @retval EFI_SUCCESS Absolute Pointer Device added successfully.\r
622 @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size.\r
623\r
624**/\r
8ae0b360 625EFI_STATUS\r
626ConSplitterAbsolutePointerAddDevice (\r
627 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
628 IN EFI_ABSOLUTE_POINTER_PROTOCOL *AbsolutePointer\r
ed66e1bc 629 );\r
8ae0b360 630\r
415df2a3 631/**\r
fc753d3b 632 Remove Absolute Pointer Device from Consplitter Absolute Pointer list.\r
415df2a3 633\r
634 @param Private Text In Splitter pointer.\r
635 @param AbsolutePointer Absolute Pointer protocol pointer.\r
636\r
637 @retval EFI_SUCCESS Absolute Pointer Device removed successfully.\r
638 @retval EFI_NOT_FOUND No Absolute Pointer Device found.\r
639\r
640**/\r
8ae0b360 641EFI_STATUS\r
642ConSplitterAbsolutePointerDeleteDevice (\r
643 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
644 IN EFI_ABSOLUTE_POINTER_PROTOCOL *AbsolutePointer\r
ed66e1bc 645 );\r
8ae0b360 646\r
647//\r
648// Absolute Pointer protocol interfaces\r
649//\r
650\r
a4d608d1 651\r
652/**\r
653 Resets the pointer device hardware.\r
654\r
655 @param This Protocol instance pointer.\r
656 @param ExtendedVerification Driver may perform diagnostics on reset.\r
657\r
658 @retval EFI_SUCCESS The device was reset.\r
659 @retval EFI_DEVICE_ERROR The device is not functioning correctly and\r
660 could not be reset.\r
661\r
662**/\r
8ae0b360 663EFI_STATUS\r
664EFIAPI\r
665ConSplitterAbsolutePointerReset (\r
666 IN EFI_ABSOLUTE_POINTER_PROTOCOL *This,\r
667 IN BOOLEAN ExtendedVerification\r
ed66e1bc 668 );\r
8ae0b360 669\r
8ae0b360 670\r
a4d608d1 671/**\r
672 Retrieves the current state of a pointer device.\r
8ae0b360 673\r
a4d608d1 674 @param This Protocol instance pointer.\r
675 @param State A pointer to the state information on the\r
676 pointer device.\r
aec072ad 677\r
a4d608d1 678 @retval EFI_SUCCESS The state of the pointer device was returned in\r
679 State..\r
680 @retval EFI_NOT_READY The state of the pointer device has not changed\r
681 since the last call to GetState().\r
682 @retval EFI_DEVICE_ERROR A device error occurred while attempting to\r
683 retrieve the pointer device's current state.\r
8ae0b360 684\r
a4d608d1 685**/\r
8ae0b360 686EFI_STATUS\r
aec072ad 687EFIAPI\r
8ae0b360 688ConSplitterAbsolutePointerGetState (\r
689 IN EFI_ABSOLUTE_POINTER_PROTOCOL *This,\r
690 IN OUT EFI_ABSOLUTE_POINTER_STATE *State\r
ed66e1bc 691 );\r
8ae0b360 692\r
415df2a3 693/**\r
694 This event agregates all the events of the pointer devices in the splitter.\r
9937b365 695\r
415df2a3 696 If any events of physical pointer devices are signaled, signal the pointer\r
697 splitter event. This will cause the calling code to call\r
698 ConSplitterAbsolutePointerGetState ().\r
699\r
700 @param Event The Event assoicated with callback.\r
701 @param Context Context registered when Event was created.\r
702\r
415df2a3 703**/\r
8ae0b360 704VOID\r
705EFIAPI\r
706ConSplitterAbsolutePointerWaitForInput (\r
707 IN EFI_EVENT Event,\r
708 IN VOID *Context\r
ed66e1bc 709 );\r
8ae0b360 710\r
5bca971e 711/**\r
712 Retrieves a Unicode string that is the user readable name of the driver.\r
713\r
714 This function retrieves the user readable name of a driver in the form of a\r
715 Unicode string. If the driver specified by This has a user readable name in\r
716 the language specified by Language, then a pointer to the driver name is\r
717 returned in DriverName, and EFI_SUCCESS is returned. If the driver specified\r
718 by This does not support the language specified by Language,\r
719 then EFI_UNSUPPORTED is returned.\r
720\r
721 @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or\r
722 EFI_COMPONENT_NAME_PROTOCOL instance.\r
723\r
724 @param Language[in] A pointer to a Null-terminated ASCII string\r
725 array indicating the language. This is the\r
726 language of the driver name that the caller is\r
727 requesting, and it must match one of the\r
728 languages specified in SupportedLanguages. The\r
729 number of languages supported by a driver is up\r
730 to the driver writer. Language is specified\r
0254efc0 731 in RFC 4646 or ISO 639-2 language code format.\r
5bca971e 732\r
733 @param DriverName[out] A pointer to the Unicode string to return.\r
734 This Unicode string is the name of the\r
735 driver specified by This in the language\r
736 specified by Language.\r
737\r
738 @retval EFI_SUCCESS The Unicode string for the Driver specified by\r
739 This and the language specified by Language was\r
740 returned in DriverName.\r
741\r
742 @retval EFI_INVALID_PARAMETER Language is NULL.\r
743\r
744 @retval EFI_INVALID_PARAMETER DriverName is NULL.\r
745\r
746 @retval EFI_UNSUPPORTED The driver specified by This does not support\r
747 the language specified by Language.\r
748\r
749**/\r
95276127 750EFI_STATUS\r
751EFIAPI\r
752ConSplitterComponentNameGetDriverName (\r
753 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
754 IN CHAR8 *Language,\r
755 OUT CHAR16 **DriverName\r
756 );\r
757\r
5bca971e 758\r
759/**\r
760 Retrieves a Unicode string that is the user readable name of the controller\r
761 that is being managed by a driver.\r
762\r
763 This function retrieves the user readable name of the controller specified by\r
764 ControllerHandle and ChildHandle in the form of a Unicode string. If the\r
765 driver specified by This has a user readable name in the language specified by\r
766 Language, then a pointer to the controller name is returned in ControllerName,\r
767 and EFI_SUCCESS is returned. If the driver specified by This is not currently\r
768 managing the controller specified by ControllerHandle and ChildHandle,\r
769 then EFI_UNSUPPORTED is returned. If the driver specified by This does not\r
770 support the language specified by Language, then EFI_UNSUPPORTED is returned.\r
771\r
772 @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or\r
773 EFI_COMPONENT_NAME_PROTOCOL instance.\r
774\r
775 @param ControllerHandle[in] The handle of a controller that the driver\r
776 specified by This is managing. This handle\r
777 specifies the controller whose name is to be\r
778 returned.\r
779\r
780 @param ChildHandle[in] The handle of the child controller to retrieve\r
781 the name of. This is an optional parameter that\r
782 may be NULL. It will be NULL for device\r
783 drivers. It will also be NULL for a bus drivers\r
784 that wish to retrieve the name of the bus\r
785 controller. It will not be NULL for a bus\r
786 driver that wishes to retrieve the name of a\r
787 child controller.\r
788\r
789 @param Language[in] A pointer to a Null-terminated ASCII string\r
790 array indicating the language. This is the\r
791 language of the driver name that the caller is\r
792 requesting, and it must match one of the\r
793 languages specified in SupportedLanguages. The\r
794 number of languages supported by a driver is up\r
795 to the driver writer. Language is specified in\r
0254efc0 796 RFC 4646 or ISO 639-2 language code format.\r
5bca971e 797\r
798 @param ControllerName[out] A pointer to the Unicode string to return.\r
799 This Unicode string is the name of the\r
800 controller specified by ControllerHandle and\r
801 ChildHandle in the language specified by\r
802 Language from the point of view of the driver\r
803 specified by This.\r
804\r
805 @retval EFI_SUCCESS The Unicode string for the user readable name in\r
806 the language specified by Language for the\r
807 driver specified by This was returned in\r
808 DriverName.\r
809\r
284ee2e8 810 @retval EFI_INVALID_PARAMETER ControllerHandle is NULL.\r
5bca971e 811\r
812 @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid\r
813 EFI_HANDLE.\r
814\r
815 @retval EFI_INVALID_PARAMETER Language is NULL.\r
816\r
817 @retval EFI_INVALID_PARAMETER ControllerName is NULL.\r
818\r
819 @retval EFI_UNSUPPORTED The driver specified by This is not currently\r
820 managing the controller specified by\r
821 ControllerHandle and ChildHandle.\r
822\r
823 @retval EFI_UNSUPPORTED The driver specified by This does not support\r
824 the language specified by Language.\r
825\r
826**/\r
95276127 827EFI_STATUS\r
828EFIAPI\r
829ConSplitterConInComponentNameGetControllerName (\r
830 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
831 IN EFI_HANDLE ControllerHandle,\r
832 IN EFI_HANDLE ChildHandle OPTIONAL,\r
833 IN CHAR8 *Language,\r
834 OUT CHAR16 **ControllerName\r
835 );\r
836\r
5bca971e 837\r
838/**\r
839 Retrieves a Unicode string that is the user readable name of the controller\r
840 that is being managed by a driver.\r
841\r
842 This function retrieves the user readable name of the controller specified by\r
843 ControllerHandle and ChildHandle in the form of a Unicode string. If the\r
844 driver specified by This has a user readable name in the language specified by\r
845 Language, then a pointer to the controller name is returned in ControllerName,\r
846 and EFI_SUCCESS is returned. If the driver specified by This is not currently\r
847 managing the controller specified by ControllerHandle and ChildHandle,\r
848 then EFI_UNSUPPORTED is returned. If the driver specified by This does not\r
849 support the language specified by Language, then EFI_UNSUPPORTED is returned.\r
850\r
851 @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or\r
852 EFI_COMPONENT_NAME_PROTOCOL instance.\r
853\r
854 @param ControllerHandle[in] The handle of a controller that the driver\r
855 specified by This is managing. This handle\r
856 specifies the controller whose name is to be\r
857 returned.\r
858\r
859 @param ChildHandle[in] The handle of the child controller to retrieve\r
860 the name of. This is an optional parameter that\r
861 may be NULL. It will be NULL for device\r
862 drivers. It will also be NULL for a bus drivers\r
863 that wish to retrieve the name of the bus\r
864 controller. It will not be NULL for a bus\r
865 driver that wishes to retrieve the name of a\r
866 child controller.\r
867\r
868 @param Language[in] A pointer to a Null-terminated ASCII string\r
869 array indicating the language. This is the\r
870 language of the driver name that the caller is\r
871 requesting, and it must match one of the\r
872 languages specified in SupportedLanguages. The\r
873 number of languages supported by a driver is up\r
874 to the driver writer. Language is specified in\r
0254efc0 875 RFC 4646 or ISO 639-2 language code format.\r
5bca971e 876\r
877 @param ControllerName[out] A pointer to the Unicode string to return.\r
878 This Unicode string is the name of the\r
879 controller specified by ControllerHandle and\r
880 ChildHandle in the language specified by\r
881 Language from the point of view of the driver\r
882 specified by This.\r
883\r
884 @retval EFI_SUCCESS The Unicode string for the user readable name in\r
885 the language specified by Language for the\r
886 driver specified by This was returned in\r
887 DriverName.\r
888\r
284ee2e8 889 @retval EFI_INVALID_PARAMETER ControllerHandle is NULL.\r
5bca971e 890\r
891 @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid\r
892 EFI_HANDLE.\r
893\r
894 @retval EFI_INVALID_PARAMETER Language is NULL.\r
895\r
896 @retval EFI_INVALID_PARAMETER ControllerName is NULL.\r
897\r
898 @retval EFI_UNSUPPORTED The driver specified by This is not currently\r
899 managing the controller specified by\r
900 ControllerHandle and ChildHandle.\r
901\r
902 @retval EFI_UNSUPPORTED The driver specified by This does not support\r
903 the language specified by Language.\r
904\r
905**/\r
95276127 906EFI_STATUS\r
907EFIAPI\r
908ConSplitterSimplePointerComponentNameGetControllerName (\r
909 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
910 IN EFI_HANDLE ControllerHandle,\r
911 IN EFI_HANDLE ChildHandle OPTIONAL,\r
912 IN CHAR8 *Language,\r
913 OUT CHAR16 **ControllerName\r
914 );\r
915\r
415df2a3 916/**\r
917 Retrieves a Unicode string that is the user readable name of the controller\r
918 that is being managed by an EFI Driver.\r
919\r
920 @param This A pointer to the EFI_COMPONENT_NAME_PROTOCOL\r
921 instance.\r
922 @param ControllerHandle The handle of a controller that the driver\r
923 specified by This is managing. This handle\r
924 specifies the controller whose name is to be\r
925 returned.\r
926 @param ChildHandle The handle of the child controller to retrieve the\r
927 name of. This is an optional parameter that may\r
928 be NULL. It will be NULL for device drivers. It\r
929 will also be NULL for a bus drivers that wish to\r
930 retrieve the name of the bus controller. It will\r
931 not be NULL for a bus driver that wishes to\r
932 retrieve the name of a child controller.\r
0254efc0 933 @param Language A pointer to RFC4646 language identifier. This is\r
415df2a3 934 the language of the controller name that that the\r
935 caller is requesting, and it must match one of the\r
936 languages specified in SupportedLanguages. The\r
937 number of languages supported by a driver is up to\r
938 the driver writer.\r
939 @param ControllerName A pointer to the Unicode string to return. This\r
940 Unicode string is the name of the controller\r
941 specified by ControllerHandle and ChildHandle in\r
942 the language specified by Language from the point\r
943 of view of the driver specified by This.\r
944\r
945 @retval EFI_SUCCESS The Unicode string for the user readable name in\r
946 the language specified by Language for the driver\r
947 specified by This was returned in DriverName.\r
284ee2e8 948 @retval EFI_INVALID_PARAMETER ControllerHandle is NULL.\r
415df2a3 949 @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid\r
950 EFI_HANDLE.\r
951 @retval EFI_INVALID_PARAMETER Language is NULL.\r
952 @retval EFI_INVALID_PARAMETER ControllerName is NULL.\r
953 @retval EFI_UNSUPPORTED The driver specified by This is not currently\r
954 managing the controller specified by\r
955 ControllerHandle and ChildHandle.\r
956 @retval EFI_UNSUPPORTED The driver specified by This does not support the\r
957 language specified by Language.\r
958\r
959**/\r
8ae0b360 960EFI_STATUS\r
961EFIAPI\r
962ConSplitterAbsolutePointerComponentNameGetControllerName (\r
963 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
964 IN EFI_HANDLE ControllerHandle,\r
965 IN EFI_HANDLE ChildHandle OPTIONAL,\r
966 IN CHAR8 *Language,\r
967 OUT CHAR16 **ControllerName\r
ed66e1bc 968 );\r
5bca971e 969\r
970/**\r
971 Retrieves a Unicode string that is the user readable name of the controller\r
972 that is being managed by a driver.\r
973\r
974 This function retrieves the user readable name of the controller specified by\r
975 ControllerHandle and ChildHandle in the form of a Unicode string. If the\r
976 driver specified by This has a user readable name in the language specified by\r
977 Language, then a pointer to the controller name is returned in ControllerName,\r
978 and EFI_SUCCESS is returned. If the driver specified by This is not currently\r
979 managing the controller specified by ControllerHandle and ChildHandle,\r
980 then EFI_UNSUPPORTED is returned. If the driver specified by This does not\r
981 support the language specified by Language, then EFI_UNSUPPORTED is returned.\r
982\r
983 @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or\r
984 EFI_COMPONENT_NAME_PROTOCOL instance.\r
985\r
986 @param ControllerHandle[in] The handle of a controller that the driver\r
987 specified by This is managing. This handle\r
988 specifies the controller whose name is to be\r
989 returned.\r
990\r
991 @param ChildHandle[in] The handle of the child controller to retrieve\r
992 the name of. This is an optional parameter that\r
993 may be NULL. It will be NULL for device\r
994 drivers. It will also be NULL for a bus drivers\r
995 that wish to retrieve the name of the bus\r
996 controller. It will not be NULL for a bus\r
997 driver that wishes to retrieve the name of a\r
998 child controller.\r
999\r
1000 @param Language[in] A pointer to a Null-terminated ASCII string\r
1001 array indicating the language. This is the\r
1002 language of the driver name that the caller is\r
1003 requesting, and it must match one of the\r
1004 languages specified in SupportedLanguages. The\r
1005 number of languages supported by a driver is up\r
1006 to the driver writer. Language is specified in\r
0254efc0 1007 RFC 4646 or ISO 639-2 language code format.\r
5bca971e 1008\r
1009 @param ControllerName[out] A pointer to the Unicode string to return.\r
1010 This Unicode string is the name of the\r
1011 controller specified by ControllerHandle and\r
1012 ChildHandle in the language specified by\r
1013 Language from the point of view of the driver\r
1014 specified by This.\r
1015\r
1016 @retval EFI_SUCCESS The Unicode string for the user readable name in\r
1017 the language specified by Language for the\r
1018 driver specified by This was returned in\r
1019 DriverName.\r
1020\r
284ee2e8 1021 @retval EFI_INVALID_PARAMETER ControllerHandle is NULL.\r
5bca971e 1022\r
1023 @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid\r
1024 EFI_HANDLE.\r
1025\r
1026 @retval EFI_INVALID_PARAMETER Language is NULL.\r
1027\r
1028 @retval EFI_INVALID_PARAMETER ControllerName is NULL.\r
1029\r
1030 @retval EFI_UNSUPPORTED The driver specified by This is not currently\r
1031 managing the controller specified by\r
1032 ControllerHandle and ChildHandle.\r
1033\r
1034 @retval EFI_UNSUPPORTED The driver specified by This does not support\r
1035 the language specified by Language.\r
1036\r
1037**/\r
95276127 1038EFI_STATUS\r
1039EFIAPI\r
1040ConSplitterConOutComponentNameGetControllerName (\r
1041 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
1042 IN EFI_HANDLE ControllerHandle,\r
1043 IN EFI_HANDLE ChildHandle OPTIONAL,\r
1044 IN CHAR8 *Language,\r
1045 OUT CHAR16 **ControllerName\r
1046 );\r
1047\r
5bca971e 1048\r
1049/**\r
1050 Retrieves a Unicode string that is the user readable name of the controller\r
1051 that is being managed by a driver.\r
1052\r
1053 This function retrieves the user readable name of the controller specified by\r
1054 ControllerHandle and ChildHandle in the form of a Unicode string. If the\r
1055 driver specified by This has a user readable name in the language specified by\r
1056 Language, then a pointer to the controller name is returned in ControllerName,\r
1057 and EFI_SUCCESS is returned. If the driver specified by This is not currently\r
1058 managing the controller specified by ControllerHandle and ChildHandle,\r
1059 then EFI_UNSUPPORTED is returned. If the driver specified by This does not\r
1060 support the language specified by Language, then EFI_UNSUPPORTED is returned.\r
1061\r
1062 @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or\r
1063 EFI_COMPONENT_NAME_PROTOCOL instance.\r
1064\r
1065 @param ControllerHandle[in] The handle of a controller that the driver\r
1066 specified by This is managing. This handle\r
1067 specifies the controller whose name is to be\r
1068 returned.\r
1069\r
1070 @param ChildHandle[in] The handle of the child controller to retrieve\r
1071 the name of. This is an optional parameter that\r
1072 may be NULL. It will be NULL for device\r
1073 drivers. It will also be NULL for a bus drivers\r
1074 that wish to retrieve the name of the bus\r
1075 controller. It will not be NULL for a bus\r
1076 driver that wishes to retrieve the name of a\r
1077 child controller.\r
1078\r
1079 @param Language[in] A pointer to a Null-terminated ASCII string\r
1080 array indicating the language. This is the\r
1081 language of the driver name that the caller is\r
1082 requesting, and it must match one of the\r
1083 languages specified in SupportedLanguages. The\r
1084 number of languages supported by a driver is up\r
1085 to the driver writer. Language is specified in\r
0254efc0 1086 RFC 4646 or ISO 639-2 language code format.\r
5bca971e 1087\r
1088 @param ControllerName[out] A pointer to the Unicode string to return.\r
1089 This Unicode string is the name of the\r
1090 controller specified by ControllerHandle and\r
1091 ChildHandle in the language specified by\r
1092 Language from the point of view of the driver\r
1093 specified by This.\r
1094\r
1095 @retval EFI_SUCCESS The Unicode string for the user readable name in\r
1096 the language specified by Language for the\r
1097 driver specified by This was returned in\r
1098 DriverName.\r
1099\r
284ee2e8 1100 @retval EFI_INVALID_PARAMETER ControllerHandle is NULL.\r
5bca971e 1101\r
1102 @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid\r
1103 EFI_HANDLE.\r
1104\r
1105 @retval EFI_INVALID_PARAMETER Language is NULL.\r
1106\r
1107 @retval EFI_INVALID_PARAMETER ControllerName is NULL.\r
1108\r
1109 @retval EFI_UNSUPPORTED The driver specified by This is not currently\r
1110 managing the controller specified by\r
1111 ControllerHandle and ChildHandle.\r
1112\r
1113 @retval EFI_UNSUPPORTED The driver specified by This does not support\r
1114 the language specified by Language.\r
1115\r
1116**/\r
95276127 1117EFI_STATUS\r
1118EFIAPI\r
1119ConSplitterStdErrComponentNameGetControllerName (\r
1120 IN EFI_COMPONENT_NAME_PROTOCOL *This,\r
1121 IN EFI_HANDLE ControllerHandle,\r
1122 IN EFI_HANDLE ChildHandle OPTIONAL,\r
1123 IN CHAR8 *Language,\r
1124 OUT CHAR16 **ControllerName\r
1125 );\r
1126\r
5bca971e 1127\r
95276127 1128//\r
1129// TextIn Constructor/Destructor functions\r
1130//\r
415df2a3 1131\r
1132/**\r
1133 Add Text Input Device in Consplitter Text Input list.\r
1134\r
1135 @param Private Text In Splitter pointer.\r
1136 @param TextIn Simple Text Input protocol pointer.\r
1137\r
1138 @retval EFI_SUCCESS Text Input Device added successfully.\r
1139 @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size.\r
1140\r
1141**/\r
95276127 1142EFI_STATUS\r
1143ConSplitterTextInAddDevice (\r
fc753d3b 1144 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
1145 IN EFI_SIMPLE_TEXT_INPUT_PROTOCOL *TextIn\r
ed66e1bc 1146 );\r
95276127 1147\r
415df2a3 1148/**\r
fc753d3b 1149 Remove Text Input Device from Consplitter Text Input list.\r
415df2a3 1150\r
1151 @param Private Text In Splitter pointer.\r
1152 @param TextIn Simple Text protocol pointer.\r
1153\r
1154 @retval EFI_SUCCESS Simple Text Device removed successfully.\r
1155 @retval EFI_NOT_FOUND No Simple Text Device found.\r
1156\r
1157**/\r
95276127 1158EFI_STATUS\r
1159ConSplitterTextInDeleteDevice (\r
fc753d3b 1160 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
1161 IN EFI_SIMPLE_TEXT_INPUT_PROTOCOL *TextIn\r
ed66e1bc 1162 );\r
95276127 1163\r
1164//\r
1165// SimplePointer Constuctor/Destructor functions\r
1166//\r
415df2a3 1167\r
1168/**\r
1169 Add Simple Pointer Device in Consplitter Simple Pointer list.\r
1170\r
1171 @param Private Text In Splitter pointer.\r
1172 @param SimplePointer Simple Pointer protocol pointer.\r
1173\r
1174 @retval EFI_SUCCESS Simple Pointer Device added successfully.\r
1175 @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size.\r
1176\r
1177**/\r
95276127 1178EFI_STATUS\r
1179ConSplitterSimplePointerAddDevice (\r
1180 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
1181 IN EFI_SIMPLE_POINTER_PROTOCOL *SimplePointer\r
ed66e1bc 1182 );\r
95276127 1183\r
415df2a3 1184/**\r
fc753d3b 1185 Remove Simple Pointer Device from Consplitter Simple Pointer list.\r
415df2a3 1186\r
1187 @param Private Text In Splitter pointer.\r
1188 @param SimplePointer Simple Pointer protocol pointer.\r
1189\r
1190 @retval EFI_SUCCESS Simple Pointer Device removed successfully.\r
1191 @retval EFI_NOT_FOUND No Simple Pointer Device found.\r
1192\r
1193**/\r
95276127 1194EFI_STATUS\r
1195ConSplitterSimplePointerDeleteDevice (\r
1196 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
1197 IN EFI_SIMPLE_POINTER_PROTOCOL *SimplePointer\r
ed66e1bc 1198 );\r
95276127 1199\r
1200//\r
1201// TextOut Constuctor/Destructor functions\r
1202//\r
415df2a3 1203\r
1204/**\r
1205 Add Text Output Device in Consplitter Text Output list.\r
1206\r
1207 @param Private Text Out Splitter pointer.\r
1208 @param TextOut Simple Text Output protocol pointer.\r
1209 @param GraphicsOutput Graphics Output protocol pointer.\r
1210 @param UgaDraw UGA Draw protocol pointer.\r
1211\r
1212 @retval EFI_SUCCESS Text Output Device added successfully.\r
1213 @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size.\r
1214\r
1215**/\r
95276127 1216EFI_STATUS\r
1217ConSplitterTextOutAddDevice (\r
1218 IN TEXT_OUT_SPLITTER_PRIVATE_DATA *Private,\r
1219 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut,\r
1220 IN EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput,\r
1221 IN EFI_UGA_DRAW_PROTOCOL *UgaDraw\r
ed66e1bc 1222 );\r
95276127 1223\r
415df2a3 1224/**\r
1225 Remove Text Out Device in Consplitter Text Out list.\r
1226\r
1227 @param Private Text Out Splitter pointer.\r
1228 @param TextOut Simple Text Output Pointer protocol pointer.\r
1229\r
1230 @retval EFI_SUCCESS Text Out Device removed successfully.\r
1231 @retval EFI_NOT_FOUND No Text Out Device found.\r
1232\r
1233**/\r
95276127 1234EFI_STATUS\r
1235ConSplitterTextOutDeleteDevice (\r
1236 IN TEXT_OUT_SPLITTER_PRIVATE_DATA *Private,\r
1237 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut\r
ed66e1bc 1238 );\r
95276127 1239\r
1240//\r
1241// TextIn I/O Functions\r
1242//\r
415df2a3 1243\r
1244/**\r
1245 Reset the input device and optionaly run diagnostics\r
1246\r
1247 @param This Protocol instance pointer.\r
1248 @param ExtendedVerification Driver may perform diagnostics on reset.\r
1249\r
1250 @retval EFI_SUCCESS The device was reset.\r
1251 @retval EFI_DEVICE_ERROR The device is not functioning properly and could\r
1252 not be reset.\r
1253\r
1254**/\r
95276127 1255EFI_STATUS\r
1256EFIAPI\r
1257ConSplitterTextInReset (\r
fc753d3b 1258 IN EFI_SIMPLE_TEXT_INPUT_PROTOCOL *This,\r
1259 IN BOOLEAN ExtendedVerification\r
ed66e1bc 1260 );\r
95276127 1261\r
415df2a3 1262/**\r
1263 Reads the next keystroke from the input device. The WaitForKey Event can\r
1264 be used to test for existance of a keystroke via WaitForEvent () call.\r
415df2a3 1265\r
1266 @param This Protocol instance pointer.\r
1267 @param Key Driver may perform diagnostics on reset.\r
1268\r
1269 @retval EFI_SUCCESS The keystroke information was returned.\r
1270 @retval EFI_NOT_READY There was no keystroke data availiable.\r
1271 @retval EFI_DEVICE_ERROR The keydtroke information was not returned due\r
1272 to hardware errors.\r
1273\r
1274**/\r
95276127 1275EFI_STATUS\r
1276EFIAPI\r
1277ConSplitterTextInReadKeyStroke (\r
fc753d3b 1278 IN EFI_SIMPLE_TEXT_INPUT_PROTOCOL *This,\r
1279 OUT EFI_INPUT_KEY *Key\r
ed66e1bc 1280 );\r
415df2a3 1281\r
1282/**\r
1283 Add Text Input Ex Device in Consplitter Text Input Ex list.\r
1284\r
1285 @param Private Text In Splitter pointer.\r
fc753d3b 1286 @param TextInEx Simple Text Input Ex Input protocol pointer.\r
415df2a3 1287\r
1288 @retval EFI_SUCCESS Text Input Ex Device added successfully.\r
1289 @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size.\r
1290\r
1291**/\r
66aa04e4 1292EFI_STATUS\r
1293ConSplitterTextInExAddDevice (\r
1294 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
1295 IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *TextInEx\r
ed66e1bc 1296 );\r
66aa04e4 1297\r
415df2a3 1298/**\r
fc753d3b 1299 Remove Text Ex Device from Consplitter Text Input Ex list.\r
415df2a3 1300\r
1301 @param Private Text In Splitter pointer.\r
1302 @param TextInEx Simple Text Ex protocol pointer.\r
1303\r
fc753d3b 1304 @retval EFI_SUCCESS Simple Text Input Ex Device removed successfully.\r
1305 @retval EFI_NOT_FOUND No Simple Text Input Ex Device found.\r
415df2a3 1306\r
1307**/\r
66aa04e4 1308EFI_STATUS\r
1309ConSplitterTextInExDeleteDevice (\r
1310 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
1311 IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *TextInEx\r
ed66e1bc 1312 );\r
66aa04e4 1313\r
1314//\r
1315// Simple Text Input Ex protocol function prototypes\r
1316//\r
1317\r
a4d608d1 1318/**\r
1319 Reset the input device and optionaly run diagnostics\r
1320\r
1321 @param This Protocol instance pointer.\r
1322 @param ExtendedVerification Driver may perform diagnostics on reset.\r
1323\r
1324 @retval EFI_SUCCESS The device was reset.\r
1325 @retval EFI_DEVICE_ERROR The device is not functioning properly and could\r
1326 not be reset.\r
1327\r
1328**/\r
66aa04e4 1329EFI_STATUS\r
1330EFIAPI\r
1331ConSplitterTextInResetEx (\r
1332 IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,\r
1333 IN BOOLEAN ExtendedVerification\r
ed66e1bc 1334 );\r
66aa04e4 1335\r
66aa04e4 1336\r
a4d608d1 1337/**\r
1338 Reads the next keystroke from the input device. The WaitForKey Event can\r
1339 be used to test for existance of a keystroke via WaitForEvent () call.\r
66aa04e4 1340\r
a4d608d1 1341 @param This Protocol instance pointer.\r
1342 @param KeyData A pointer to a buffer that is filled in with the\r
1343 keystroke state data for the key that was\r
1344 pressed.\r
66aa04e4 1345\r
a4d608d1 1346 @retval EFI_SUCCESS The keystroke information was returned.\r
1347 @retval EFI_NOT_READY There was no keystroke data availiable.\r
1348 @retval EFI_DEVICE_ERROR The keystroke information was not returned due\r
1349 to hardware errors.\r
1350 @retval EFI_INVALID_PARAMETER KeyData is NULL.\r
66aa04e4 1351\r
a4d608d1 1352**/\r
66aa04e4 1353EFI_STATUS\r
1354EFIAPI\r
1355ConSplitterTextInReadKeyStrokeEx (\r
1356 IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,\r
1357 OUT EFI_KEY_DATA *KeyData\r
ed66e1bc 1358 );\r
66aa04e4 1359\r
66aa04e4 1360\r
a4d608d1 1361/**\r
1362 Set certain state for the input device.\r
66aa04e4 1363\r
a4d608d1 1364 @param This Protocol instance pointer.\r
1365 @param KeyToggleState A pointer to the EFI_KEY_TOGGLE_STATE to set the\r
1366 state for the input device.\r
66aa04e4 1367\r
a4d608d1 1368 @retval EFI_SUCCESS The device state was set successfully.\r
1369 @retval EFI_DEVICE_ERROR The device is not functioning correctly and\r
1370 could not have the setting adjusted.\r
1371 @retval EFI_UNSUPPORTED The device does not have the ability to set its\r
1372 state.\r
1373 @retval EFI_INVALID_PARAMETER KeyToggleState is NULL.\r
66aa04e4 1374\r
a4d608d1 1375**/\r
66aa04e4 1376EFI_STATUS\r
1377EFIAPI\r
1378ConSplitterTextInSetState (\r
1379 IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,\r
1380 IN EFI_KEY_TOGGLE_STATE *KeyToggleState\r
ed66e1bc 1381 );\r
aec072ad 1382\r
66aa04e4 1383\r
a4d608d1 1384/**\r
1385 Register a notification function for a particular keystroke for the input device.\r
1386\r
1387 @param This Protocol instance pointer.\r
1388 @param KeyData A pointer to a buffer that is filled in with the\r
1389 keystroke information data for the key that was\r
1390 pressed.\r
1391 @param KeyNotificationFunction Points to the function to be called when the key\r
1392 sequence is typed specified by KeyData.\r
1393 @param NotifyHandle Points to the unique handle assigned to the\r
1394 registered notification.\r
1395\r
1396 @retval EFI_SUCCESS The notification function was registered\r
1397 successfully.\r
1398 @retval EFI_OUT_OF_RESOURCES Unable to allocate resources for necesssary data\r
1399 structures.\r
f890b1e0 1400 @retval EFI_INVALID_PARAMETER KeyData or KeyNotificationFunction or NotifyHandle is NULL.\r
95276127 1401\r
a4d608d1 1402**/\r
66aa04e4 1403EFI_STATUS\r
1404EFIAPI\r
1405ConSplitterTextInRegisterKeyNotify (\r
1406 IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,\r
1407 IN EFI_KEY_DATA *KeyData,\r
1408 IN EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction,\r
1409 OUT EFI_HANDLE *NotifyHandle\r
ed66e1bc 1410 );\r
66aa04e4 1411\r
66aa04e4 1412\r
a4d608d1 1413/**\r
1414 Remove a registered notification function from a particular keystroke.\r
66aa04e4 1415\r
a4d608d1 1416 @param This Protocol instance pointer.\r
1417 @param NotificationHandle The handle of the notification function being\r
1418 unregistered.\r
aec072ad 1419\r
a4d608d1 1420 @retval EFI_SUCCESS The notification function was unregistered\r
1421 successfully.\r
1422 @retval EFI_INVALID_PARAMETER The NotificationHandle is invalid.\r
1423 @retval EFI_NOT_FOUND Can not find the matching entry in database.\r
66aa04e4 1424\r
a4d608d1 1425**/\r
66aa04e4 1426EFI_STATUS\r
1427EFIAPI\r
1428ConSplitterTextInUnregisterKeyNotify (\r
1429 IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,\r
1430 IN EFI_HANDLE NotificationHandle\r
ed66e1bc 1431 );\r
415df2a3 1432\r
1433/**\r
f890b1e0 1434 This event aggregates all the events of the ConIn devices in the spliter.\r
1435\r
415df2a3 1436 If any events of physical ConIn devices are signaled, signal the ConIn\r
1437 spliter event. This will cause the calling code to call\r
1438 ConSplitterTextInReadKeyStroke ().\r
1439\r
1440 @param Event The Event assoicated with callback.\r
1441 @param Context Context registered when Event was created.\r
1442\r
415df2a3 1443**/\r
95276127 1444VOID\r
1445EFIAPI\r
1446ConSplitterTextInWaitForKey (\r
1447 IN EFI_EVENT Event,\r
1448 IN VOID *Context\r
ed66e1bc 1449 );\r
ed055f1b 1450\r
95276127 1451\r
415df2a3 1452/**\r
1453 Reads the next keystroke from the input device. The WaitForKey Event can\r
1454 be used to test for existance of a keystroke via WaitForEvent () call.\r
1455\r
33019a71 1456 @param Private Protocol instance pointer.\r
415df2a3 1457 @param Key Driver may perform diagnostics on reset.\r
1458\r
1459 @retval EFI_SUCCESS The keystroke information was returned.\r
1460 @retval EFI_NOT_READY There was no keystroke data availiable.\r
1461 @retval EFI_DEVICE_ERROR The keydtroke information was not returned due\r
1462 to hardware errors.\r
1463\r
1464**/\r
95276127 1465EFI_STATUS\r
1466EFIAPI\r
1467ConSplitterTextInPrivateReadKeyStroke (\r
1468 IN TEXT_IN_SPLITTER_PRIVATE_DATA *Private,\r
1469 OUT EFI_INPUT_KEY *Key\r
ed66e1bc 1470 );\r
95276127 1471\r
415df2a3 1472/**\r
1473 Reset the input device and optionaly run diagnostics\r
1474\r
1475 @param This Protocol instance pointer.\r
1476 @param ExtendedVerification Driver may perform diagnostics on reset.\r
1477\r
1478 @retval EFI_SUCCESS The device was reset.\r
1479 @retval EFI_DEVICE_ERROR The device is not functioning properly and could\r
1480 not be reset.\r
1481\r
1482**/\r
95276127 1483EFI_STATUS\r
1484EFIAPI\r
1485ConSplitterSimplePointerReset (\r
1486 IN EFI_SIMPLE_POINTER_PROTOCOL *This,\r
1487 IN BOOLEAN ExtendedVerification\r
ed66e1bc 1488 );\r
95276127 1489\r
415df2a3 1490/**\r
1491 Reads the next keystroke from the input device. The WaitForKey Event can\r
1492 be used to test for existance of a keystroke via WaitForEvent () call.\r
415df2a3 1493\r
1494 @param This A pointer to protocol instance.\r
1495 @param State A pointer to state information on the pointer device\r
1496\r
1497 @retval EFI_SUCCESS The keystroke information was returned in State.\r
1498 @retval EFI_NOT_READY There was no keystroke data availiable.\r
1499 @retval EFI_DEVICE_ERROR The keydtroke information was not returned due\r
1500 to hardware errors.\r
1501\r
1502**/\r
95276127 1503EFI_STATUS\r
1504EFIAPI\r
1505ConSplitterSimplePointerGetState (\r
1506 IN EFI_SIMPLE_POINTER_PROTOCOL *This,\r
1507 IN OUT EFI_SIMPLE_POINTER_STATE *State\r
ed66e1bc 1508 );\r
95276127 1509\r
a4d608d1 1510/**\r
1511 This event agregates all the events of the ConIn devices in the spliter.\r
a4d608d1 1512 If any events of physical ConIn devices are signaled, signal the ConIn\r
1513 spliter event. This will cause the calling code to call\r
1514 ConSplitterTextInReadKeyStroke ().\r
1515\r
1516 @param Event The Event assoicated with callback.\r
1517 @param Context Context registered when Event was created.\r
1518\r
a4d608d1 1519**/\r
95276127 1520VOID\r
1521EFIAPI\r
1522ConSplitterSimplePointerWaitForInput (\r
1523 IN EFI_EVENT Event,\r
1524 IN VOID *Context\r
ed66e1bc 1525 );\r
95276127 1526\r
1527//\r
1528// TextOut I/O Functions\r
1529//\r
95276127 1530\r
415df2a3 1531/**\r
1532 Reset the text output device hardware and optionaly run diagnostics\r
1533\r
1534 @param This Protocol instance pointer.\r
1535 @param ExtendedVerification Driver may perform more exhaustive verfication\r
1536 operation of the device during reset.\r
1537\r
1538 @retval EFI_SUCCESS The text output device was reset.\r
1539 @retval EFI_DEVICE_ERROR The text output device is not functioning\r
1540 correctly and could not be reset.\r
1541\r
1542**/\r
95276127 1543EFI_STATUS\r
1544EFIAPI\r
1545ConSplitterTextOutReset (\r
1546 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1547 IN BOOLEAN ExtendedVerification\r
ed66e1bc 1548 );\r
95276127 1549\r
415df2a3 1550/**\r
1551 Write a Unicode string to the output device.\r
1552\r
1553 @param This Protocol instance pointer.\r
33019a71 1554 @param WString The NULL-terminated Unicode string to be\r
415df2a3 1555 displayed on the output device(s). All output\r
1556 devices must also support the Unicode drawing\r
1557 defined in this file.\r
1558\r
1559 @retval EFI_SUCCESS The string was output to the device.\r
1560 @retval EFI_DEVICE_ERROR The device reported an error while attempting to\r
1561 output the text.\r
1562 @retval EFI_UNSUPPORTED The output device's mode is not currently in a\r
1563 defined text mode.\r
1564 @retval EFI_WARN_UNKNOWN_GLYPH This warning code indicates that some of the\r
1565 characters in the Unicode string could not be\r
1566 rendered and were skipped.\r
1567\r
1568**/\r
95276127 1569EFI_STATUS\r
1570EFIAPI\r
1571ConSplitterTextOutOutputString (\r
1572 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1573 IN CHAR16 *WString\r
ed66e1bc 1574 );\r
95276127 1575\r
415df2a3 1576/**\r
1577 Verifies that all characters in a Unicode string can be output to the\r
1578 target device.\r
1579\r
1580 @param This Protocol instance pointer.\r
33019a71 1581 @param WString The NULL-terminated Unicode string to be\r
415df2a3 1582 examined for the output device(s).\r
1583\r
1584 @retval EFI_SUCCESS The device(s) are capable of rendering the\r
1585 output string.\r
1586 @retval EFI_UNSUPPORTED Some of the characters in the Unicode string\r
1587 cannot be rendered by one or more of the output\r
1588 devices mapped by the EFI handle.\r
1589\r
1590**/\r
95276127 1591EFI_STATUS\r
1592EFIAPI\r
1593ConSplitterTextOutTestString (\r
1594 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1595 IN CHAR16 *WString\r
ed66e1bc 1596 );\r
95276127 1597\r
415df2a3 1598/**\r
1599 Returns information for an available text mode that the output device(s)\r
1600 supports.\r
1601\r
1602 @param This Protocol instance pointer.\r
1603 @param ModeNumber The mode number to return information on.\r
33019a71 1604 @param Columns Returns the columns of the text output device\r
1605 for the requested ModeNumber.\r
1606 @param Rows Returns the rows of the text output device\r
415df2a3 1607 for the requested ModeNumber.\r
1608\r
1609 @retval EFI_SUCCESS The requested mode information was returned.\r
1610 @retval EFI_DEVICE_ERROR The device had an error and could not complete\r
1611 the request.\r
1612 @retval EFI_UNSUPPORTED The mode number was not valid.\r
1613\r
1614**/\r
95276127 1615EFI_STATUS\r
1616EFIAPI\r
1617ConSplitterTextOutQueryMode (\r
1618 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1619 IN UINTN ModeNumber,\r
1620 OUT UINTN *Columns,\r
1621 OUT UINTN *Rows\r
ed66e1bc 1622 );\r
95276127 1623\r
415df2a3 1624/**\r
1625 Sets the output device(s) to a specified mode.\r
1626\r
1627 @param This Protocol instance pointer.\r
1628 @param ModeNumber The mode number to set.\r
1629\r
1630 @retval EFI_SUCCESS The requested text mode was set.\r
1631 @retval EFI_DEVICE_ERROR The device had an error and could not complete\r
1632 the request.\r
1633 @retval EFI_UNSUPPORTED The mode number was not valid.\r
1634\r
1635**/\r
95276127 1636EFI_STATUS\r
1637EFIAPI\r
1638ConSplitterTextOutSetMode (\r
1639 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1640 IN UINTN ModeNumber\r
ed66e1bc 1641 );\r
95276127 1642\r
415df2a3 1643/**\r
1644 Sets the background and foreground colors for the OutputString () and\r
1645 ClearScreen () functions.\r
1646\r
1647 @param This Protocol instance pointer.\r
1648 @param Attribute The attribute to set. Bits 0..3 are the\r
1649 foreground color, and bits 4..6 are the\r
1650 background color. All other bits are undefined\r
1651 and must be zero. The valid Attributes are\r
1652 defined in this file.\r
1653\r
1654 @retval EFI_SUCCESS The attribute was set.\r
1655 @retval EFI_DEVICE_ERROR The device had an error and could not complete\r
1656 the request.\r
1657 @retval EFI_UNSUPPORTED The attribute requested is not defined.\r
1658\r
1659**/\r
95276127 1660EFI_STATUS\r
1661EFIAPI\r
1662ConSplitterTextOutSetAttribute (\r
1663 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1664 IN UINTN Attribute\r
ed66e1bc 1665 );\r
95276127 1666\r
415df2a3 1667/**\r
1668 Clears the output device(s) display to the currently selected background\r
1669 color.\r
1670\r
1671 @param This Protocol instance pointer.\r
1672\r
1673 @retval EFI_SUCCESS The operation completed successfully.\r
1674 @retval EFI_DEVICE_ERROR The device had an error and could not complete\r
1675 the request.\r
1676 @retval EFI_UNSUPPORTED The output device is not in a valid text mode.\r
1677\r
1678**/\r
95276127 1679EFI_STATUS\r
1680EFIAPI\r
1681ConSplitterTextOutClearScreen (\r
1682 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This\r
ed66e1bc 1683 );\r
95276127 1684\r
415df2a3 1685/**\r
1686 Sets the current coordinates of the cursor position\r
1687\r
1688 @param This Protocol instance pointer.\r
33019a71 1689 @param Column The column position to set the cursor to. Must be\r
415df2a3 1690 greater than or equal to zero and less than the\r
33019a71 1691 number of columns by QueryMode ().\r
1692 @param Row The row position to set the cursor to. Must be\r
1693 greater than or equal to zero and less than the\r
1694 number of rows by QueryMode ().\r
415df2a3 1695\r
1696 @retval EFI_SUCCESS The operation completed successfully.\r
1697 @retval EFI_DEVICE_ERROR The device had an error and could not complete\r
1698 the request.\r
1699 @retval EFI_UNSUPPORTED The output device is not in a valid text mode,\r
1700 or the cursor position is invalid for the\r
1701 current mode.\r
1702\r
1703**/\r
95276127 1704EFI_STATUS\r
1705EFIAPI\r
1706ConSplitterTextOutSetCursorPosition (\r
1707 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1708 IN UINTN Column,\r
1709 IN UINTN Row\r
ed66e1bc 1710 );\r
95276127 1711\r
415df2a3 1712\r
1713/**\r
1714 Makes the cursor visible or invisible\r
1715\r
1716 @param This Protocol instance pointer.\r
1717 @param Visible If TRUE, the cursor is set to be visible. If\r
1718 FALSE, the cursor is set to be invisible.\r
1719\r
1720 @retval EFI_SUCCESS The operation completed successfully.\r
1721 @retval EFI_DEVICE_ERROR The device had an error and could not complete\r
1722 the request, or the device does not support\r
1723 changing the cursor mode.\r
1724 @retval EFI_UNSUPPORTED The output device is not in a valid text mode.\r
1725\r
1726**/\r
95276127 1727EFI_STATUS\r
1728EFIAPI\r
1729ConSplitterTextOutEnableCursor (\r
1730 IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This,\r
1731 IN BOOLEAN Visible\r
ed66e1bc 1732 );\r
95276127 1733\r
415df2a3 1734/**\r
1735 Take the passed in Buffer of size SizeOfCount and grow the buffer\r
1736 by MAX (CONSOLE_SPLITTER_CONSOLES_ALLOC_UNIT, MaxGrow) * SizeOfCount\r
1737 bytes. Copy the current data in Buffer to the new version of Buffer\r
1738 and free the old version of buffer.\r
1739\r
fc753d3b 1740 @param SizeOfCount Size of element in array.\r
1741 @param Count Current number of elements in array.\r
415df2a3 1742 @param Buffer Bigger version of passed in Buffer with all the\r
fc753d3b 1743 data.\r
415df2a3 1744\r
fc753d3b 1745 @retval EFI_SUCCESS Buffer size has grown.\r
415df2a3 1746 @retval EFI_OUT_OF_RESOURCES Could not grow the buffer size.\r
1747\r
1748**/\r
95276127 1749EFI_STATUS\r
1750ConSplitterGrowBuffer (\r
406ddad3 1751 IN UINTN SizeOfCount,\r
1752 IN OUT UINTN *Count,\r
95276127 1753 IN OUT VOID **Buffer\r
ed66e1bc 1754 );\r
95276127 1755\r
415df2a3 1756/**\r
2da292f6 1757 Returns information for an available graphics mode that the graphics device\r
1758 and the set of active video output devices supports.\r
415df2a3 1759\r
2da292f6 1760 @param This The EFI_GRAPHICS_OUTPUT_PROTOCOL instance.\r
1761 @param ModeNumber The mode number to return information on.\r
1762 @param SizeOfInfo A pointer to the size, in bytes, of the Info buffer.\r
1763 @param Info A pointer to callee allocated buffer that returns information about ModeNumber.\r
415df2a3 1764\r
2da292f6 1765 @retval EFI_SUCCESS Mode information returned.\r
1766 @retval EFI_BUFFER_TOO_SMALL The Info buffer was too small.\r
1767 @retval EFI_DEVICE_ERROR A hardware error occurred trying to retrieve the video mode.\r
2da292f6 1768 @retval EFI_INVALID_PARAMETER One of the input args was NULL.\r
1769 @retval EFI_OUT_OF_RESOURCES No resource available.\r
415df2a3 1770\r
1771**/\r
95276127 1772EFI_STATUS\r
1773EFIAPI\r
d6e11f22 1774ConSplitterGraphicsOutputQueryMode (\r
fc753d3b 1775 IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This,\r
1776 IN UINT32 ModeNumber,\r
1777 OUT UINTN *SizeOfInfo,\r
66aa04e4 1778 OUT EFI_GRAPHICS_OUTPUT_MODE_INFORMATION **Info\r
ed66e1bc 1779 );\r
95276127 1780\r
415df2a3 1781/**\r
ed055f1b 1782 Set the video device into the specified mode and clears the visible portions of\r
2da292f6 1783 the output display to black.\r
415df2a3 1784\r
2da292f6 1785 @param This The EFI_GRAPHICS_OUTPUT_PROTOCOL instance.\r
1786 @param ModeNumber Abstraction that defines the current video mode.\r
415df2a3 1787\r
2da292f6 1788 @retval EFI_SUCCESS The graphics mode specified by ModeNumber was selected.\r
1789 @retval EFI_DEVICE_ERROR The device had an error and could not complete the request.\r
1790 @retval EFI_UNSUPPORTED ModeNumber is not supported by this device.\r
1791 @retval EFI_OUT_OF_RESOURCES No resource available.\r
415df2a3 1792\r
1793**/\r
95276127 1794EFI_STATUS\r
1795EFIAPI\r
d6e11f22 1796ConSplitterGraphicsOutputSetMode (\r
95276127 1797 IN EFI_GRAPHICS_OUTPUT_PROTOCOL * This,\r
1798 IN UINT32 ModeNumber\r
ed66e1bc 1799 );\r
95276127 1800\r
415df2a3 1801/**\r
1802 The following table defines actions for BltOperations.\r
1803\r
1804 EfiBltVideoFill - Write data from the BltBuffer pixel (SourceX, SourceY)\r
1805 directly to every pixel of the video display rectangle\r
1806 (DestinationX, DestinationY)\r
1807 (DestinationX + Width, DestinationY + Height).\r
1808 Only one pixel will be used from the BltBuffer. Delta is NOT used.\r
1809 EfiBltVideoToBltBuffer - Read data from the video display rectangle\r
1810 (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it in\r
1811 the BltBuffer rectangle (DestinationX, DestinationY )\r
1812 (DestinationX + Width, DestinationY + Height). If DestinationX or\r
1813 DestinationY is not zero then Delta must be set to the length in bytes\r
1814 of a row in the BltBuffer.\r
1815 EfiBltBufferToVideo - Write data from the BltBuffer rectangle\r
1816 (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to the\r
1817 video display rectangle (DestinationX, DestinationY)\r
1818 (DestinationX + Width, DestinationY + Height). If SourceX or SourceY is\r
1819 not zero then Delta must be set to the length in bytes of a row in the\r
1820 BltBuffer.\r
1821 EfiBltVideoToVideo - Copy from the video display rectangle\r
1822 (SourceX, SourceY) (SourceX + Width, SourceY + Height) .\r
1823 to the video display rectangle (DestinationX, DestinationY)\r
1824 (DestinationX + Width, DestinationY + Height).\r
1825 The BltBuffer and Delta are not used in this mode.\r
1826\r
1827 @param This Protocol instance pointer.\r
1828 @param BltBuffer Buffer containing data to blit into video buffer.\r
1829 This buffer has a size of\r
1830 Width*Height*sizeof(EFI_GRAPHICS_OUTPUT_BLT_PIXEL)\r
1831 @param BltOperation Operation to perform on BlitBuffer and video\r
1832 memory\r
1833 @param SourceX X coordinate of source for the BltBuffer.\r
1834 @param SourceY Y coordinate of source for the BltBuffer.\r
1835 @param DestinationX X coordinate of destination for the BltBuffer.\r
1836 @param DestinationY Y coordinate of destination for the BltBuffer.\r
1837 @param Width Width of rectangle in BltBuffer in pixels.\r
ed055f1b 1838 @param Height Hight of rectangle in BltBuffer in pixels.\r
33019a71 1839 @param Delta OPTIONAL.\r
415df2a3 1840\r
1841 @retval EFI_SUCCESS The Blt operation completed.\r
1842 @retval EFI_INVALID_PARAMETER BltOperation is not valid.\r
1843 @retval EFI_DEVICE_ERROR A hardware error occured writting to the video\r
1844 buffer.\r
1845\r
1846**/\r
95276127 1847EFI_STATUS\r
1848EFIAPI\r
d6e11f22 1849ConSplitterGraphicsOutputBlt (\r
95276127 1850 IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This,\r
1851 IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer, OPTIONAL\r
1852 IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation,\r
1853 IN UINTN SourceX,\r
1854 IN UINTN SourceY,\r
1855 IN UINTN DestinationX,\r
1856 IN UINTN DestinationY,\r
1857 IN UINTN Width,\r
1858 IN UINTN Height,\r
1859 IN UINTN Delta OPTIONAL\r
ed66e1bc 1860 );\r
95276127 1861\r
95276127 1862\r
415df2a3 1863/**\r
1864 Return the current video mode information.\r
1865\r
2da292f6 1866 @param This The EFI_UGA_DRAW_PROTOCOL instance.\r
1867 @param HorizontalResolution The size of video screen in pixels in the X dimension.\r
1868 @param VerticalResolution The size of video screen in pixels in the Y dimension.\r
1869 @param ColorDepth Number of bits per pixel, currently defined to be 32.\r
1870 @param RefreshRate The refresh rate of the monitor in Hertz.\r
415df2a3 1871\r
2da292f6 1872 @retval EFI_SUCCESS Mode information returned.\r
1873 @retval EFI_NOT_STARTED Video display is not initialized. Call SetMode ()\r
1874 @retval EFI_INVALID_PARAMETER One of the input args was NULL.\r
415df2a3 1875\r
1876**/\r
d0c64728 1877EFI_STATUS\r
1878EFIAPI\r
d6e11f22 1879ConSplitterUgaDrawGetMode (\r
d0c64728 1880 IN EFI_UGA_DRAW_PROTOCOL *This,\r
1881 OUT UINT32 *HorizontalResolution,\r
1882 OUT UINT32 *VerticalResolution,\r
1883 OUT UINT32 *ColorDepth,\r
1884 OUT UINT32 *RefreshRate\r
ed66e1bc 1885 );\r
d0c64728 1886\r
415df2a3 1887/**\r
2da292f6 1888 Set the current video mode information.\r
415df2a3 1889\r
2da292f6 1890 @param This The EFI_UGA_DRAW_PROTOCOL instance.\r
1891 @param HorizontalResolution The size of video screen in pixels in the X dimension.\r
1892 @param VerticalResolution The size of video screen in pixels in the Y dimension.\r
1893 @param ColorDepth Number of bits per pixel, currently defined to be 32.\r
1894 @param RefreshRate The refresh rate of the monitor in Hertz.\r
415df2a3 1895\r
2da292f6 1896 @retval EFI_SUCCESS Mode information returned.\r
1897 @retval EFI_NOT_STARTED Video display is not initialized. Call SetMode ()\r
1898 @retval EFI_OUT_OF_RESOURCES Out of resources.\r
415df2a3 1899\r
1900**/\r
d0c64728 1901EFI_STATUS\r
1902EFIAPI\r
d6e11f22 1903ConSplitterUgaDrawSetMode (\r
d0c64728 1904 IN EFI_UGA_DRAW_PROTOCOL *This,\r
1905 IN UINT32 HorizontalResolution,\r
1906 IN UINT32 VerticalResolution,\r
1907 IN UINT32 ColorDepth,\r
1908 IN UINT32 RefreshRate\r
ed66e1bc 1909 );\r
d0c64728 1910\r
415df2a3 1911/**\r
2da292f6 1912 Blt a rectangle of pixels on the graphics screen.\r
415df2a3 1913\r
2da292f6 1914 The following table defines actions for BltOperations.\r
415df2a3 1915\r
2da292f6 1916 EfiUgaVideoFill:\r
1917 Write data from the BltBuffer pixel (SourceX, SourceY)\r
1918 directly to every pixel of the video display rectangle\r
1919 (DestinationX, DestinationY)\r
1920 (DestinationX + Width, DestinationY + Height).\r
1921 Only one pixel will be used from the BltBuffer. Delta is NOT used.\r
ed055f1b 1922 EfiUgaVideoToBltBuffer:\r
2da292f6 1923 Read data from the video display rectangle\r
1924 (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it in\r
1925 the BltBuffer rectangle (DestinationX, DestinationY )\r
1926 (DestinationX + Width, DestinationY + Height). If DestinationX or\r
1927 DestinationY is not zero then Delta must be set to the length in bytes\r
1928 of a row in the BltBuffer.\r
1929 EfiUgaBltBufferToVideo:\r
1930 Write data from the BltBuffer rectangle\r
1931 (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to the\r
1932 video display rectangle (DestinationX, DestinationY)\r
1933 (DestinationX + Width, DestinationY + Height). If SourceX or SourceY is\r
1934 not zero then Delta must be set to the length in bytes of a row in the\r
1935 BltBuffer.\r
1936 EfiUgaVideoToVideo:\r
1937 Copy from the video display rectangle\r
1938 (SourceX, SourceY) (SourceX + Width, SourceY + Height) .\r
1939 to the video display rectangle (DestinationX, DestinationY)\r
1940 (DestinationX + Width, DestinationY + Height).\r
1941 The BltBuffer and Delta are not used in this mode.\r
1942\r
1943 @param This Protocol instance pointer.\r
1944 @param BltBuffer Buffer containing data to blit into video buffer. This\r
1945 buffer has a size of Width*Height*sizeof(EFI_UGA_PIXEL)\r
1946 @param BltOperation Operation to perform on BlitBuffer and video memory\r
1947 @param SourceX X coordinate of source for the BltBuffer.\r
1948 @param SourceY Y coordinate of source for the BltBuffer.\r
1949 @param DestinationX X coordinate of destination for the BltBuffer.\r
1950 @param DestinationY Y coordinate of destination for the BltBuffer.\r
1951 @param Width Width of rectangle in BltBuffer in pixels.\r
1952 @param Height Hight of rectangle in BltBuffer in pixels.\r
1953 @param Delta OPTIONAL\r
1954\r
1955 @retval EFI_SUCCESS The Blt operation completed.\r
1956 @retval EFI_INVALID_PARAMETER BltOperation is not valid.\r
1957 @retval EFI_DEVICE_ERROR A hardware error occured writting to the video buffer.\r
415df2a3 1958\r
1959**/\r
d0c64728 1960EFI_STATUS\r
1961EFIAPI\r
d6e11f22 1962ConSplitterUgaDrawBlt (\r
d0c64728 1963 IN EFI_UGA_DRAW_PROTOCOL *This,\r
1964 IN EFI_UGA_PIXEL *BltBuffer, OPTIONAL\r
1965 IN EFI_UGA_BLT_OPERATION BltOperation,\r
1966 IN UINTN SourceX,\r
1967 IN UINTN SourceY,\r
1968 IN UINTN DestinationX,\r
1969 IN UINTN DestinationY,\r
1970 IN UINTN Width,\r
1971 IN UINTN Height,\r
1972 IN UINTN Delta OPTIONAL\r
ed66e1bc 1973 );\r
d0c64728 1974\r
415df2a3 1975/**\r
1976 Sets the output device(s) to a specified mode.\r
1977\r
2da292f6 1978 @param Private Text Out Splitter pointer.\r
415df2a3 1979 @param ModeNumber The mode number to set.\r
1980\r
415df2a3 1981**/\r
9937b365 1982VOID\r
1983TextOutSetMode (\r
95276127 1984 IN TEXT_OUT_SPLITTER_PRIVATE_DATA *Private,\r
1985 IN UINTN ModeNumber\r
ed66e1bc 1986 );\r
95276127 1987\r
95276127 1988\r
1989#endif\r