/** @file\r
UEFI Component Name(2) protocol implementation for ConSplitter driver.\r
\r
-Copyright (c) 2006 - 2008, Intel Corporation. <BR>\r
+Copyright (c) 2006 - 2010, Intel Corporation. <BR>\r
All rights reserved. This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
which accompanies this distribution. The full text of the license may be found at\r
Status = ConSplitterTestControllerHandles (\r
ControllerHandle,\r
gConSplitterConInDriverBinding.DriverBindingHandle,\r
- &gEfiSimpleTextInProtocolGuid,\r
+ &gEfiConsoleInDeviceGuid,\r
ChildHandle,\r
&gEfiConsoleInDeviceGuid\r
);\r
Status = ConSplitterTestControllerHandles (\r
ControllerHandle,\r
gConSplitterConOutDriverBinding.DriverBindingHandle,\r
- &gEfiSimpleTextOutProtocolGuid,\r
+ &gEfiConsoleOutDeviceGuid,\r
ChildHandle,\r
&gEfiConsoleOutDeviceGuid\r
);\r
Status = ConSplitterTestControllerHandles (\r
ControllerHandle,\r
gConSplitterStdErrDriverBinding.DriverBindingHandle,\r
- &gEfiSimpleTextOutProtocolGuid,\r
+ &gEfiStandardErrorDeviceGuid,\r
ChildHandle,\r
&gEfiStandardErrorDeviceGuid\r
);\r
never removed. Such design ensures sytem function well during none console\r
device situation.\r
\r
-Copyright (c) 2006 - 2009, Intel Corporation. <BR>\r
+Copyright (c) 2006 - 2010, Intel Corporation. <BR>\r
All rights reserved. This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
which accompanies this distribution. The full text of the license may be found at\r
}\r
\r
//\r
- // Create virtual handle and open DeviceGuid on the virtul handle.\r
+ // Open the Parent Handle for the child.\r
//\r
Status = gBS->OpenProtocol (\r
ControllerHandle,\r
// Construct console output devices' private data\r
//\r
Status = ConSplitterTextOutConstructor (&mStdErr);\r
+ if (!EFI_ERROR (Status)) {\r
+ //\r
+ // Create virtual device handle for StdErr Splitter\r
+ //\r
+ Status = gBS->InstallMultipleProtocolInterfaces (\r
+ &mStdErr.VirtualHandle,\r
+ &gEfiSimpleTextOutProtocolGuid,\r
+ &mStdErr.TextOut,\r
+ NULL\r
+ );\r
+ }\r
if (EFI_ERROR (Status)) {\r
return Status;\r
}\r
}\r
\r
if (mStdErr.CurrentNumberOfConsoles == 1) {\r
- //\r
- // Create virtual device handle for StdErr Splitter\r
- //\r
- Status = gBS->InstallMultipleProtocolInterfaces (\r
- &mStdErr.VirtualHandle,\r
- &gEfiSimpleTextOutProtocolGuid,\r
- &mStdErr.TextOut,\r
- NULL\r
- );\r
- if (EFI_ERROR (Status)) {\r
- return Status;\r
- }\r
-\r
gST->StandardErrorHandle = mStdErr.VirtualHandle;\r
gST->StdErr = &mStdErr.TextOut;\r
//\r
}\r
\r
if (mStdErr.CurrentNumberOfConsoles == 0) {\r
+ mStdErr.VirtualHandle = NULL;\r
+\r
gST->StandardErrorHandle = NULL;\r
gST->StdErr = NULL;\r
//\r
CurrentGraphicsOutputMode->SizeOfInfo = GraphicsOutput->Mode->SizeOfInfo;\r
CurrentGraphicsOutputMode->FrameBufferBase = GraphicsOutput->Mode->FrameBufferBase;\r
CurrentGraphicsOutputMode->FrameBufferSize = GraphicsOutput->Mode->FrameBufferSize;\r
- \r
+\r
//\r
// Allocate resource for the private mode buffer\r
//\r
//\r
Status = TextOut->SetMode (TextOut, BaseMode);\r
ASSERT(!EFI_ERROR(Status));\r
- \r
+\r
PcdSet32 (PcdConOutColumn, 80);\r
PcdSet32 (PcdConOutRow, 25);\r
}\r
// if GetMode is successfully and UGA device hasn't been set, set it\r
//\r
Status = ConSplitterUgaDrawSetMode (\r
- &Private->UgaDraw, \r
- UgaHorizontalResolution, \r
- UgaVerticalResolution, \r
- UgaColorDepth, \r
+ &Private->UgaDraw,\r
+ UgaHorizontalResolution,\r
+ UgaVerticalResolution,\r
+ UgaColorDepth,\r
UgaRefreshRate\r
);\r
}\r
//\r
if(EFI_ERROR (Status)) {\r
Status = ConSplitterUgaDrawSetMode (\r
- &Private->UgaDraw, \r
- 800, \r
- 600, \r
- 32, \r
+ &Private->UgaDraw,\r
+ 800,\r
+ 600,\r
+ 32,\r
60\r
);\r
}\r
\r
if (((TEXT_IN_EX_SPLITTER_NOTIFY *) NotificationHandle)->Signature != TEXT_IN_EX_SPLITTER_NOTIFY_SIGNATURE) {\r
return EFI_INVALID_PARAMETER;\r
- } \r
- \r
+ }\r
+\r
Private = TEXT_IN_EX_SPLITTER_PRIVATE_DATA_FROM_THIS (This);\r
\r
//\r