[edk2-devel] Graphic Output on qemu

Michael Brown mcb30 at ipxe.org
Wed Feb 8 09:06:05 UTC 2023


On 08/02/2023 08:03, Alireza Banejad wrote:
> Below is how I use the HandleProtocol function:
> 
>    Status = gBS->HandleProtocol (
>                    gST->ConsoleOutHandle,
>                    &gEfiGraphicsOutputProtocolGuid,
>                    (VOID **)&GraphicsOutput
>                    );

You are querying only the ConsoleOutHandle, which is not necessarily 
where the GOP will be installed.

Use LocateProtocol() to find the protocol instance instead:


   Status = gBS->LocateProtocol(&gEfiGraphicsOutputProtocolGuid, NULL,
                                (VOID **)&GraphicsOutput);

HTH,

Michael



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#99790): https://edk2.groups.io/g/devel/message/99790
Mute This Topic: https://groups.io/mt/96810830/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-




More information about the edk2-devel-archive mailing list