From e8c7b14da07172bb0739cc3a6d4afb3e326e8e3c Mon Sep 17 00:00:00 2001 From: Ajan Zhong Date: Tue, 24 Dec 2024 09:53:14 +0800 Subject: UefiPayloadPkg: Set PixelsPerScanLine property in GraphicInfo HOB PixelsPerScanLine is required in some UEFI capable OS distribution. To align with simple-framebuffer definition in kernel Documentation: devicetree/bindings/display/simple-framebuffer.txt, no property node will be introduced for PixelsPerScanLine. Set value of PixelsPerScanLine to HorizontalResolution, as they are identical in most cases. Signed-off-by: Ajan Zhong --- UefiPayloadPkg/Library/FdtParserLib/FdtParserLib.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/UefiPayloadPkg/Library/FdtParserLib/FdtParserLib.c b/UefiPayloadPkg/Library/FdtParserLib/FdtParserLib.c index ab669569a1..372ca07765 100644 --- a/UefiPayloadPkg/Library/FdtParserLib/FdtParserLib.c +++ b/UefiPayloadPkg/Library/FdtParserLib/FdtParserLib.c @@ -378,6 +378,9 @@ ParseFrameBuffer ( GmaStr++; DEBUG ((DEBUG_INFO, " display (%s)", GmaStr)); } + + // In most case, PixelsPerScanLine is identical to HorizontalResolution + GraphicsInfo->GraphicsMode.PixelsPerScanLine = GraphicsInfo->GraphicsMode.HorizontalResolution; } return GmaStr; -- cgit