]> git.proxmox.com Git - mirror_edk2.git/commit
MdeModulePkg/GraphicsConsoleDxe: Initialize the output mode
authorZhichao Gao <zhichao.gao@intel.com>
Tue, 30 Apr 2019 06:51:34 +0000 (14:51 +0800)
committerHao A Wu <hao.a.wu@intel.com>
Thu, 13 Jun 2019 06:53:40 +0000 (14:53 +0800)
commit0a35997643972d3b76a67547cbffeaa8a3d708c3
tree4725088fefeba811ce1bbaa3c2f3da8d4fa41cb0
parent297495f410228bed151dc767dfbbf5617323e378
MdeModulePkg/GraphicsConsoleDxe: Initialize the output mode

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1412

Original logic:
Connect the graphics device -> connect it as graphics consoles
and initialize its parameters(Mode = -1, invalid) -> connect it
as console spliter and add the device to the list(use SetMode to
set mode to the user defined mode or the best mode the devices
supported if the mode is invalid. *clear the screen at this phase*)

Changed logic:
Connect the graphics device -> connect it as graphics consoles
and initialize its parameters(initialize the mode to the user
defined mode or the best mode. *directly set the mode value without
using SetMode, that would not clear the screen) -> connect it as
console spliter and add the device to the list(use SetMode to set
mode to the user defined mode or the best mode the devices supported
if the mode is invalid. *now the mode is already set, so it would
not clear the screen*).

Also remove the section of SetMode for debug version.

Impact: as the text mode may not be an invalid value, the SetMode
may have no chance to be called during reconnect the graphics device.
That means the screen may not be cleaned after finishing reconnect
operation. There is one common condition: shell command "recoonect -r".

Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Hao Wu <hao.a.wu@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Sean Brogan <sean.brogan@microsoft.com>
Cc: Michael Turner <Michael.Turner@microsoft.com>
Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com>
Acked-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsole.c
MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf