OvmfPkg/VirtioGpuDxe: ignore display resolutions smaller than 640x480

GraphicsConsoleDxe will assert in case the resolution is too small.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
Gerd Hoffmann 2024-08-23 14:35:53 +02:00 committed by mergify[bot]
parent 6a7be5a841
commit 58035e8b5e

View File

@ -265,7 +265,8 @@ GopInitialize (
// query host for display resolution
//
GopNativeResolution (VgpuGop, &XRes, &YRes);
if ((XRes == 0) || (YRes == 0)) {
if ((XRes < 640) || (YRes < 480)) {
/* ignore hint, GraphicsConsoleDxe needs 640x480 or larger */
return;
}