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