Repository navigation
feat(drivers): added a virtio-gpu driver so aarch64 QEMU runs the desktop at 1920x1080 - #341
Merged
Merged
Conversation
FlareCoding
added this pull request to stack #342
October 6, 2026 06:09
FlareCoding
force-pushed
the
pr/virtio-gpu
branch
from
October 6, 2026 06:27
21806be to
786d7a4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/dev/gfxfb, stlxdm flushes what it presents when the display asks for it, andmake run ARCH=aarch64uses a 1920x1080 virtio GPU.Note
Medium Risk
New kernel graphics driver and QEMU display switch affect boot/display on aarch64; virtio MSI-X routing changes can fail attach on devices that reject vectors but avoid prior unsafe reset/panic paths.
Overview
Adds a virtio-GPU path for AArch64 QEMU so the desktop can run at 1920×1080 instead of being stuck on firmware-limited ramfb (~1024×768).
make run/ debug QEMU targets swap-device ramfbforvirtio-gpu-pciviaQEMU_AARCH64_DISPLAY.A new
virtio_gpuPCI driver implements 2D scanout over the virtio GPU control queue: query display mode, create a B8G8R8X8 backing, register with gfxfb, andflush()dirty rects with batchedTRANSFER_TO_HOST_2D+RESOURCE_FLUSH(MSI-X completions when available, otherwise polling with timeout).stlxdm reads
GFXFB_INFO_NEEDS_FLUSHfrom/dev/gfxfband issuesGFXFB_FLUSHafter copying damage when the display requires it, with full-screen retry after a failed flush.Virtio transport hardening (shared with net/GPU): MSI-X routing functions return errors when the device rejects a vector; virtio-net fails attach on bad routing;
reset_device()is a no-op until common config is mapped; virtqueue exposesfree_count()for batching; modern GPU device ID usesVIRTIO_DEV_MODERN_BASE.Reviewed by Cursor Bugbot for commit 786d7a4. Bugbot is set up for automated code reviews on this repo. Configure here.