watchthelight labs

Import FreeBSD LinuxKPI fixes for Meteor Lake and Arc (drm-kmod #315, #418, #468) #4

opengood first issuekernel
watchthelight 2026-10-21

FreeBSD found and fixed LinuxKPI fidelity bugs that bite i915 on newer parts: cancel_delayed_work_sync return semantics (GuC 'Bad context sched_state'), sg_dma_len aliasing, fictitious page registration for LMEM, vmap_pfn, the MTL GTT mmap path. Check which apply to our drm-kmod revision (c16de0f) and the XNU shim, and carry them over. References: freebsd/drm-kmod#315 freebsd/drm-kmod#418 freebsd/drm-kmod#468

watchthelight 2026-10-22

Upstream scout, 2026-10-22, two LinuxKPI lessons from the same stack on other machines:

  • Lost wake-up. VedCloud's Meteor Lake port saw false GuC TLB-invalidation timeouts; the cause was their LinuxKPI woken callback not keeping TASK_WAKING under the sleep-channel lock. Worth checking our wait/wake path for the same window before blaming GuC. README, implementation section
  • Pageable GEM backing. FreeBSD drm-kmod #527: an i915 GPU hang on drm-612-kmod 6.12.110 (the base we build on) when shmem backing pages got swapped out; turning swap off avoids it. On XNU the GEM backing should stay wired.

Their i915/DRM patches are GPL-2.0 and LinuxKPI ones BSD-2 (per their LICENSE), so the fixes can be compared directly. Write-up: https://github.com/watchthelight-labs/research/blob/main/scout/xe/2026-10-22.md

Reply on GitHub