From df84987e6d38b78a16fc4130693e8ca48297bce7 Mon Sep 17 00:00:00 2001 From: Dylan Neve Date: Fri, 23 Oct 2026 12:20:30 +0100 Subject: [PATCH] 1303: virtio-gpu says whether its control queue has interrupts or is polled Co-Authored-By: Claude Opus 5.5 --- xnu/patches/1303-virtio-gpu-say-interrupts.patch | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 xnu/patches/1303-virtio-gpu-say-interrupts.patch diff --git a/xnu/patches/1303-virtio-gpu-say-interrupts.patch b/xnu/patches/1303-virtio-gpu-say-interrupts.patch new file mode 100644 index 000000000..0ab3bf04d --- /dev/null +++ b/xnu/patches/1303-virtio-gpu-say-interrupts.patch @@ -0,0 +1,16 @@ +diff --git a/bsd/dev/redwood_vgpu.c b/bsd/dev/redwood_vgpu.c +index 0c805f7..81f6852 100644 +--- a/bsd/dev/redwood_vgpu.c ++++ b/bsd/dev/redwood_vgpu.c +@@ -126,8 +126,10 @@ vgpu_setup(void) + return ENOMEM; + } + vio_queue_intr(vg.ctrlq, true); +- vio_intr_enable(d); /* (or polled) */ ++ int intr = vio_intr_enable(d); /* (or polled) */ + vio_driver_ok(d); ++ printf("virtio-gpu: %s: %s\n", vio_name(d), intr == 0 && vio_intr_active(d) ? "interrupts" : ++ intr == ENOTSUP ? "polled (virtio_poll=1)" : "polled: no interrupt line"); + vg.dev = d; + vg.state = 1; + printf("virtio-gpu: %s, features 0x%llx%s%s\n", vio_name(d), vg.features,