Skip to content

drm/apple: enable static-frame idle caching on firmware 27 panels - #3289

Open
erikwb wants to merge 12 commits into
mainfrom
feat/dcp-v27-idle-cache
Open

erikwb wants to merge 12 commits into
mainfrom
feat/dcp-v27-idle-cache

Conversation

@erikwb

@erikwb erikwb commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor

What: Enable static-frame idle caching ("replay") on verified firmware 27 internal-panel hardware profiles (apple_dcp_hw_t8132_v27 via hw.v27_idle_cache = true) so DCP serves static desktop frames from a reusable cache surface after 1 second of idle output (cutting idle battery power by ~88–89 mW on J713), keeping unverified profiles (and apple_dcp_hw_t6050, where firmware stops at setup with zero replays) off by default, including dcp_v27_idle_cache_supported() in dcp_caches_scanout() so replay-capable firmware 27 scanout gets drm_gem_fb_create_with_dirty() (DIRTYFB and shadowed fbdev updates trigger atomic commits to refresh scanout and exit replay instead of returning -ENOSYS) while non-caching interfaces keep headless client framebuffers on apple_drm_client_fb_funcs, initializing channels_idle_wq inside iomfb_queue_init() so IOMFB KUnit fixtures never dereference an uninitialized wait queue after the main merge, and adding KUnit coverage for failed swap_submit unwind, session-retention rollback, default-off unverified profiles, fbdev exclusion, and DIRTYFB dirty-commit routing.
Tested: Host and KUnit checks at 4a6030e3598b (forward merge of origin/main 19ee1b5bc9d5 over df01a6cd9b2e, only merging iomfb_v27_test.c to keep both v27_rt_bw_* and v27_idle_* cases, so driver code is identical to df01a6cd9b2e), plus J713 standalone and J716c composite trial kernels at df01a6cd9b2e (prior live hardware rows at 31e21a4ae8f4 and earlier c85087653bd4/f7e6fb162951 runs and the historical c05e2a268684 J713 -89.3/-87.6 mW coulomb-counter A/B are in Evidence):

  • Host checks (4a6030e3598b): apple-dcp-v27 KUnit 12/12, topology.kunitconfig 221/222 (1 skipped, 0 failed), display.kunitconfig 188/189 (1 skipped, 0 failed), tests/.kunitconfig 117/117, dcpext26-{queue,startup}-tests.py pass, run-host-tests.py --only apple-dcp 87/101 (14 pre-existing host-compiler failures unrelated to #3289; ok 72 - stale-crtc-poweroff and ok 73 - dropped-swap-teardown pass), checkpatch.pl --strict (a4d28a5a72b7..df01a6cd9b2e) 0/0/0, LLVM=1 ARCH=arm64 W=1 build of drivers/gpu/drm/apple/ 0 warnings.
  • J713 (df01a6cd9b2e, M4 Air, T8132, firmware 27.2, standalone main + df01a6cd9b2e build; 4a6030e3598b only merged iomfb_v27_test.c with main): v27 idle cache active (mem=49151616 host=1) 8.3 s after boot; 4x DPMS off/on (4 -> 0 / 0 -> 1 -> 2 -> 4, replays 1 -> 5); s2idle (rtcwake -m freeze -s 20: 4 -> 0 then 0 -> 1 -> 2 -> 4, replays 9 -> 10, fail 0); fbcon chvt 3 dropped 4 -> 0 and stayed at 0 for 12 s including 3 writes to /dev/tty3, then re-armed on chvt 1 (0 -> 1 -> 2 -> 4, replays 8 -> 9; visual redraw not observed remotely); DIRTYFB from state 4 not exercised (DRM_IOCTL_MODE_DIRTYFB from a second root client returned EACCES (13) while the compositor held DRM master, and fbcon never arms the cache); live apple-dcp unbind from state 4 returned 0 (4 -> 0, G16: fail-stop (ENODEV), retaining live DCP DMA resources after unbind; reboot required, 0 Oops/WARN/BUG/refcount/hung-task/call-trace, clean reboot); smoke clean (eDP-1 enabled, 0 failed units, 0 AppArmor denials, 0 oops/WARN; err = baseline 3 + 2 unprobed external DCP -ENODEV lines).
  • J716c (df01a6cd9b2e, M5 Max, T6050, firmware 27.2, composite trial kernel over main 429e7e15f122): default-off confirmed (0 idle-cache/replay lines in dmesg, 0 DCP swap/commit/poweroff error lines), 4x eDP-1 DPMS off/on (3456x2234@120 restored, 0 new err/warn lines), smoke clean (MTP keyboard/trackpad/lid, wlan0 0% loss, AppleJ716 PCMs, Borealis Apple M5 Max (G17C B1) vkcube, 0 LSM denials, 1 baseline failed unit aurora-peripherals.service, 0 GPU/MMU faults or Oops/WARN).
    Risk: two-way door · T8132 firmware-27 internal panels (apple_dcp_hw_t8132_v27); iomfb_queue_init() wait-queue initialization across DCP interfaces; unverified profiles and T6050 remain off by default
    Revert: git revert restores default-off behavior across all profiles, dcp_caches_scanout() M4-only scope, and channels_idle_wq initialization in dcp_platform_probe_pipe() with no persistent on-disk, DT, or firmware state (apple-dcp live unbind after replay registration retains DMA until reboot, as with any adopted live DCP session).
    Not yet:
  • On J713 (T8132, firmware 27.2): a state-4 DIRTYFB front-buffer update issued by the DRM master / compositor (a non-master root client returned EACCES (13) and fbcon never arms the cache), on-site visual observation of fbcon live-console redraw, and a refreshed unplugged battery coulomb-counter A/B (earlier A/B on historical test build c05e2a268684 measured -89.3 mW at bl=5 and -87.6 mW at bl=150), plus post-merge confirmation at 4a6030e3598b (4a6030e3598b only merged iomfb_v27_test.c with main, so driver code is unchanged from df01a6cd9b2e).
  • Refreshed J313 (M1 Air, T8103: boot smoke, DPMS off/on, deep S2R) at 4a6030e3598b (prior row ran at 31e21a4ae8f4) and post-merge J716c confirmation at 4a6030e3598b (identical driver code verified on J716c at df01a6cd9b2e).
  • Active replay on firmware-27 internal panels not yet tested in this lab (T6041, T8122, T8142 / J813 / J815), which stay disabled by default (hw.v27_idle_cache = false) until verified.
  • Hosted Apple build and KUnit CI completion at 4a6030e3598b.
Details
  • dcp_v27_idle_cache_supported() checks fw_compat == DCP_FIRMWARE_V_27_0 && dcp->hw.v27_idle_cache && dcp->main_display && dcp_has_panel(dcp). Unverified firmware-27 internal-panel profiles keep hw.v27_idle_cache = false by default, and .v27_idle_cache = true is enabled on the shared apple_dcp_hw_t8132_v27 profile where active state-4 replay and display power savings are verified.
  • Why hw.v27_idle_cache is gated on verified profiles (including keeping apple_dcp_hw_t6050 off): J716c runs at ed0e9648f90c and f7e6fb162951 showed T6050 firmware accepts applyProperty(138, 2) (status=0) and swap_intent = 8 (ret=0), enters setup state 2 with periodic 2 -> 6 -> 2 refreshes, and never transitions to active state 4 (replays=0). No static DT/ADT property or pre-submit firmware query distinguishes setup-only firmware from J713's state-4 firmware beforehand, and submitting swap_intent = 8 once already allocates the DMA cache surface and commits dcp_retain_live_session_commit() (retain_dma = true); conversely, a runtime setup-count latch cannot distinguish setup attempts interrupted by normal display activity on a capable panel from setup-only firmware. Defaulting unverified profiles to off prevents pinning DMA and live-session retention without obtaining replay.
  • In dcp.c and apple_drv.c, dcp_caches_scanout() returns true for iomfb_is_m4(dcp) || dcp_v27_idle_cache_supported(dcp). On replay-capable firmware 27 panels (apple_dcp_hw_t8132_v27), apple_fb_create() returns drm_gem_fb_create_with_dirty(), giving userspace DIRTYFB callers and shadowed fbdev clients drm_atomic_helper_dirtyfb() so front-buffer drawing triggers an atomic commit and refreshes/exits replay instead of returning -ENOSYS. On non-caching interfaces (including apple_dcp_hw_t6050 and unverified firmware 27 profiles), headless in-kernel DRM client opens (!file || !file->filp, such as fbdev/fbcon) without a dirty callback are tagged with immutable apple_drm_client_fb_funcs, while userspace KMS opens (file->filp != NULL) keep drm_gem_fb_create(). In iomfb_flush(), iomfb_v27_idle_cache_fb_eligible() checks fb->funcs (fb->funcs->dirty eligible; fb->funcs == &apple_drm_client_fb_funcs ineligible) without ever reading or dereferencing fb->dev->fb_helper, avoiding any teardown race with drm_fb_helper_fini() during DRM unplug.
  • After an eligible primary-plane KMS swap completes as displayed (shown == true and retire == true) and remains static past a 1-second deadline tracked under v27_idle_lock, a delayed worker runs two-phase setup:
    1. Negotiate first (applyProperty(138, 2) on A352): runs as a negotiate-only transaction before any GEM allocation or live-session retention. If firmware refuses, the driver latches v27_idle_unavailable and leaves the panel fully rebindable.
    2. Allocate & register replay swap (swap_intent = 8 at offset 0x17c, surf_ids[0] = 2): validates full surface/plane/compression span (iomfb_v27_idle_surface_span()), allocates/reuses a DMA GEM cache surface (reallocating only once firmware releases the prior buffer via D581), pre-acquires live-session retention references in process context (dcp_retain_live_session_prepare()), and commits permanent retention under v27_idle_lock only after swap_submit publishes cleanly over the mailbox (dcp_send_message_checked()).
  • Handles firmware idle-cache callbacks (D116 state transitions, D579/D580 fence lifecycle, D581 surface release), filters replay swap completions and aborts (D594/D597) without disturbing KMS retirement, invalidates queued replay and restarts the 1 s idle interval on non-plane-0 flushes and standalone brightness/EDR presents, closes admission with an iomfb.lock barrier on DPMS off / suspend / unbind, unwinds unsent idle-cache command entries on transient mailbox errors without affecting existing dcp_push() callers, and resets replay state in dcp_v27_warm_restart() before mailbox RX re-enables.
  • Commits 125129d93ae9, f7e6fb162951, c85087653bd4, 31e21a4ae8f4, and df01a6cd9b2e add CONFIG_DRM_APPLE_KUNIT_TEST-scoped hooks and five idle-cache KUnit tests in drivers/gpu/drm/apple/iomfb_v27_test.c covering injected -EAGAIN swap_submit unwind, outer callback and prior DMA pin preservation, default-off unverified profiles, headless fbdev exclusion, and DIRTYFB atomic-commit routing on replay-capable framebuffers.
  • Commit 962249cdc60f moves init_waitqueue_head(&dcp->channels_idle_wq) from dcp_platform_probe_pipe() into iomfb_queue_init(), which runs earlier in probe and is shared by KUnit fixtures that call iomfb_recv_msg(), preventing iomfb_channels_idle_wake() from dereferencing a zeroed wait_queue_head_t after a4d28a5a merged f085a8dda674 from main.
  • Commit df01a6cd9b2e includes dcp_v27_idle_cache_supported(dcp) in dcp_caches_scanout() so replay-capable firmware 27 panels use drm_gem_fb_create_with_dirty() and route DIRTYFB front-buffer updates through the atomic commit path instead of returning -ENOSYS.
Evidence

Build, style, KUnit, and host tests at 4a6030e3598b

  • Merged origin/main (19ee1b5bc9d5) at 4a6030e3598b (resolving the v27_cases[] conflict in drivers/gpu/drm/apple/iomfb_v27_test.c to keep both v27_rt_bw_* and v27_idle_* tests).
  • ./scripts/checkpatch.pl --strict --git a4d28a5a72b7..df01a6cd9b2e: 0 errors, 0 warnings, 0 checks (14 lines checked in 962249cdc60f; 451 lines checked in df01a6cd9b2e); git diff --check origin/main...4a6030e3598b clean.
  • ./tools/testing/kunit/kunit.py run --arch=arm64 --make_options LLVM=1 --build_dir=_kunit_topo --kunitconfig=drivers/gpu/drm/apple/tests/topology.kunitconfig --jobs="$BUILD_SLOT_JOBS" (apple-dcp-v27 subset 12/12 passed): 221 passed, 1 skipped (apple_g17_rx_util_min_test, needs CONFIG_UCLAMP_TASK), 0 failed (222 total).
  • ./tools/testing/kunit/kunit.py run --arch=arm64 --make_options LLVM=1 --build_dir=_kunit_disp --kunitconfig=drivers/gpu/drm/apple/tests/display.kunitconfig --jobs="$BUILD_SLOT_JOBS": 188 passed, 1 skipped (apple_g17_rx_util_min_test), 0 failed (189 total).
  • ./tools/testing/kunit/kunit.py run --arch=arm64 --make_options LLVM=1 --build_dir=_kunit_tests --kunitconfig=drivers/gpu/drm/apple/tests/.kunitconfig --jobs="$BUILD_SLOT_JOBS": 117 passed, 0 failed (117 total).
  • make O=_build_w1 LLVM=1 ARCH=arm64 W=1 -j"$BUILD_SLOT_JOBS" drivers/gpu/drm/apple/ (defconfig + asahi.config, CONFIG_RUST=n, CONFIG_DRM_FBDEV_EMULATION=y): 0 errors, 0 warnings.
  • python3 -I tools/asahi/dcpext26-queue-tests.py and python3 -I tools/asahi/dcpext26-startup-tests.py: both pass.
  • HOSTCC="clang -Wno-unused-but-set-global" python3 -I tools/asahi/run-host-tests.py --only apple-dcp: 87/101 passed (14 pre-existing Clang 23 -Wunused-but-set-global failures unrelated to #3289; ok 72 - stale-crtc-poweroff, ok 73 - dropped-swap-teardown pass).
  • Prior kb run -p linux-j713 at df01a6cd9b2e (before the 4a6030e3598b main merge): full J713 kernel build passed.

Live hardware at df01a6cd9b2e (same driver code as 4a6030e3598b, which only merged iomfb_v27_test.c with origin/main 19ee1b5bc9d5)

  • J713 (M4 MacBook Air, T8132, firmware 27.2, on battery, default cmdline, one-shot Stage 2 with t8132-j713.dtb): standalone main + df01a6cd9b2e build (external display processors unprobed on main, +2 err):
    • Boot: apple-dcp 30ae00000.dcp: v27 idle cache active (mem=49151616 host=1) 8.3 s after boot.
    • DPMS off/on ×4 (hl.dsp.dpms, dynamic debug on iomfb_v27.c): every off 4 -> 0, every on 0 -> 1 -> 2 -> 4, replays 1 -> 5.
    • s2idle (rtcwake -m freeze -s 20): 4 -> 0 at suspend entry, 0 -> 1 -> 2 -> 4 after resume (replays 9 -> 10), suspend_stats fail 0.
    • fbcon (/proc/fb appledrmfb): chvt 3 took the cache 4 -> 0; it stayed at 0 for the 12 s on tty3 (also with three writes to /dev/tty3: no 0 -> 1); chvt 1 re-armed it (0 -> 1 -> 2 -> 4, replays 8 -> 9). A re-arm while on the text console was not seen; visual redraw of the console was not observed remotely.
    • DIRTYFB from state 4: not exercised (DRM_IOCTL_MODE_DIRTYFB returned EACCES (13) from a second client even as root, because the compositor holds DRM master, and the console never arms the cache, so there is no state-4 front buffer to dirty from the text console).
    • Live apple-dcp unbind from state 4 (echo 30ae00000.dcp > .../apple-dcp/unbind): returned 0, 4 -> 0, G16: fail-stop (ENODEV) for the GPU, retaining live DCP DMA resources after unbind; reboot required, 0 Oops/WARN/BUG/refcount/hung-task/call-trace lines; the reboot afterwards was clean.
    • Smoke: 0 failed units, 0 AppArmor denials, 0 oops/WARN, eDP-1 enabled; err lines = baseline 3 (AFK[ep:20], unsupported DFB layout 2560x1664, apple_sep) + 2 external display processor lines (286e00000.dcp / 48ae00000.dcp: -ENODEV, "no IOMMU domain").
    • Not run: unplugged battery coulomb-counter A/B.
  • J716c (16-inch M5 Max, T6050, firmware 27.2, AC 100%, default cmdline, default Stage 2 b0a2f222b5a9): one-shot composite trial kernel (Linux 7.3.0, main 429e7e15f122 + #3409, #3560, #3651, #3717, #3359, and #3289 df01a6cd9b2e merged cleanly with zero conflicts):
    • Default-off confirmed: 0 idle cache / replay / v27 idle-cache lines in dmesg (apple_dcp_hw_t6050 has no hw.v27_idle_cache), 0 DCP swap/commit/poweroff error lines.
    • 4x eDP-1 DPMS off/on (hl.dsp.dpms, hyprctl monitors dpmsStatus False then True): each restored 3456x2234@120, connector connected/enabled, 0 new dmesg err/warn lines.
    • Smoke: Apple MTP keyboard/trackpad and lid devices enumerated, wlan0 0% loss over 3 pings, AppleJ716 PCMs present, Borealis Apple M5 Max (G17C B1) vkcube --c 240 --wsi wayland clean, 0 LSM denials (capability, landlock, yama), 1 baseline failed system unit (aurora-peripherals.service, also on default), 0 failed user units, 0 GPU/MMU faults / Oops / BUG / WARN / SError lines (4 kernel err+ lines from base: systemd-gpt-auto-generator pair, aurora ... gpu: M5 bare-metal bootstrap failed at session: EPROBE_DEFER, avd missing-firmware probe -2). fbcon chvt / DIRTYFB replay paths not run (no replay on T6050).

Prior-head live hardware at 31e21a4ae8f4 (2026-11-28, before e50de028/a4d28a5a merges and 962249cdc60f)

  • J713 (M4 MacBook Air, T8132, firmware 27.2): batched kernel 76649338a1bc (J713 default kernel source 8dbfa2895b93 + PRs; default cmdline + panic=10), kernel image SHA-256 e8e9fd2813dd6347176d0e4a55a70d1c694bdab75817c3ab83c441c203140491, one-shot Stage 2 SHA-256 f7d4e2f7ebbfb423bd71f233f1aef7af0a39091b288a749d25f9250eb80adbfa, DTB ceacf1d413c651396f4c1dfd9fa27b15c710dd849e46c2753fcff0a23a6681c6. Parity: 31e21a4ae8f4 is an ancestor; 3/12 files blob-identical (2/10 runtime), 8 drivers/gpu/drm/apple/* files + dcp-internal.h carry all added lines with no removed line remaining (iomfb.c reconciled with daily dcp_push_try(), keeping both blocks).
    • apple-dcp 30ae00000.dcp: v27 idle cache active (mem=51117696 host=1) 22 s after boot (dynamic debug on iomfb_v27.c).
    • DPMS off/on ×4: every off logged state 4 -> 0, every on re-armed 0 -> 1 -> 2 -> 4 (replays 9 -> 16). s2idle: 4 -> 0, then 0 -> 1 -> 2 -> 4 after resume.
    • fbcon exclusion (addresses the J313 console-only fbcon freeze report): chvt 3 for 12 s dropped the cache 4 -> 0 at 199.99 s with no re-arm until chvt 1 at ~213 s (0 -> 1 -> 2 -> 4, replays 14 -> 15); vtcon1 bound, /proc/fb appledrmfb. Visual redraw not observed remotely.
    • Live apple-dcp unbind (echo 30ae00000.dcp > .../apple-dcp/unbind, last step of boot) returned 0 from state 4 (4 -> 0, retaining live DCP DMA resources after unbind; reboot required for 30ae00000/48ae00000/286e00000; GPU fail-stop G16: fail-stop (ENODEV) as expected) with 0 Oops/WARN/BUG/refcount/hung-task/call-trace lines; rebooted afterwards.
    • Smoke: eDP-1 2560x1664@60 enabled, MTP input enumerated, wlan0 0% loss, speakerguardd-v2 protected tone rc 0, Borealis glmark2 5,099, 0 failed units, 0 AppArmor denials; 4 err+ lines: 3 baseline (AFK[ep:20], unsupported DFB layout 2560x1664, apple_sep notice) plus 1 brcmfmac ring line also observed on the default kernel boot.
  • J716c (16-inch M5 Max, T6050, firmware 27.2): batched kernel 3545ebecb76f (origin/main b897ccb4e71c + 18 PRs, CONFIG_ARM_APPLE_SOC_CPUFREQ=m, AC power, default cmdline), Image.gz SHA-256 d56efde4c7232208bd29d5c4e5890319e0050595dd4f4b1c3844df6656a08312, t6050-j716c.dtb d2f0db7a5026ae9cc4e1cff61dca38b4d1b363d47e5bad696ef65c7d715517e0, modules 9d5782bcf02ea60a225278c9319431f902b495f6beb485d79d127c0fb2fccc92, one-shot Stage 2 b7d99286395ddd7dadccc6d9593f4bd55391d9e787af97c18b45f58688d9885d. Parity: 31e21a4ae8f4 is an ancestor; 4/12 files blob-identical, 8/12 hunks-present (dcp-internal.h reconciled with #3410 keeping both field blocks; iomfb.c reconciled with #3410 keeping iomfb_test_push_context and adapting dcp_push_try() to dcp_push_context(..., unwind_on_err = false), and with #3399 keeping dcp_crtc_prepare_hdr()/vrr_only alongside iomfb_v27_idle_cache_invalidate() before dcp_mode_begin()).
    • Default-off confirmed: 0 v27 idle-cache lines in dmesg for the whole boot; eDP-1 3456x2234@120 enabled, 3× DPMS off/on (0 new err/warn lines, 3 DCP firmware IOAVVideoInterface open failed syslog lines on DPMS-on vs 0 kernel DCP warnings/errors), 2× freeze + 2× mem pm_test=devices and 2× pm_test=platform clean, 0 DCP warnings/errors; 6-item smoke pass (0 failed user units, 0 LSM denials, aurora-peripherals.service warm-reboot baseline failure also on default/control; 40 err+ lines all pre-existing vs 55-line default boot except PM: suspend debug and the 3 DPMS syslog lines).
  • J313 (M1 MacBook Air, T8103): batched Group A (main + 9 PRs, undocked on battery, all PR changed files parity-identical against main), kernel SHA-256 888c041944da96032a9252504c4d5543b906fd98717234eca5e091150af85798, one-shot Stage 2 SHA-256 949dc089ed390b7535dd5ef2a6e99975c3026658e58dbd9d17e9b20d2bbb7d71:
    • Boot smoke pass (eDP-1 enabled, keyboard/trackpad, wlan0, audio enumerated, Borealis Apple M1 (G13G B1) compute/render OK), 0 AVC denials, 1 baseline failed unit (speakerguardd-v2-switchtest.service also on baseline main ee36fbdcd1c8 SHA-256 f750b04aebd30c439edbd3b995c17b3fd9ad805a4561dadc7ecbf78040c89289), 3× DPMS off/on pass, 2× deep S2R (rtcwake -d rtc1 -m mem -s 30) pass (0 Oops/BUG/WARN; post-S2R ISP capture failed after the 1st deep resume in Group A with apple-isp firmware boot -19 / DART translation fault vs passed after the 1st deep resume on baseline main, unisolated, tracked under #3329).

Earlier-head live hardware at c85087653bd4 (default command line)

  • J713 (M4 MacBook Air, T8132, firmware 27.2):
    • v27 idle cache activated: v27 idle cache active (mem=51117696 host=1).
    • 3× DPMS off/on cycles: every off transitioned 4 -> 0, every on transitioned 0 -> 1 -> 2 -> 4, replays advanced 2 -> 3 -> 4 -> 5.
    • 3× s2idle cycles: every suspend transitioned 4 -> 0, every resume transitioned 0 -> 1 -> 2 -> 4, replays advanced 6 -> 9, 0 DCP errors.
    • fbcon (appledrmfb) exclusion: after stopping the compositor and switching to tty3, cache dropped 4 -> 0 with 0 0 -> 1 re-arms over ~10 s (replays held at 12); re-armed after compositor restart (replays 13). Visual redraw was not observed remotely.
    • Live apple-dcp unbind in state 4 returned 0 (4 -> 0, DCP firmware powered off, retaining live DCP DMA resources after unbind; reboot required) with 0 Oops/WARN/BUG/refcount/hung-task/call-trace lines (as logged, live unbind tears down /dev/dri and requires a hard reset on reboot).
  • J716c (M5 Max 16" MacBook Pro, T6050):
    • Idle cache disabled: 0 v27 idle-cache admission/negotiation messages.
    • eDP-1 3456x2234@120 connected; 2× appledrmfb DPMS blank/unblank cycles (Off -> On, 3456x2234 restored) and 2× pm_test=devices cycles clean; 0 DCP/DRM warnings or errors.
  • J313 (M1 MacBook Air, T8103):
    • eDP-1 2560x1600@60 connected (appledrmfb fb1), 4× DPMS off/on cycles clean, survived 5× s2idle + 5× deep sleeps with dpms=On, 0 kernel WARN/Oops/DRM errors.

Earlier-head live hardware at f7e6fb162951 (batched candidates, default command line)

  • J713 (M4 MacBook Air, T8132, firmware 27.2), candidate b3dbf237542b over main 9e38a276dcb4, Linux 7.3.0, default Stage 2: clean boot, 0 failed systemd units, 0 panics/Oops/BUG/SErrors/DART faults/LSM denials; eDP-1 2560x1664@60; Borealis Apple M4 (G16G B0). 30ae00000.dcp: v27 idle cache active (mem=51117696 host=1). With eDP-1 active the cache transitioned 0 -> 1 -> 2 -> 4 across 3x real DPMS off/on cycles (dpmsStatus 0 -> 1 x3; 4 -> 0 on DPMS off, re-entering 0 -> 1 -> 2 -> 4 on DPMS on, replays=12..18), reaching replays=21..24 through 3x s2idle (rtcwake -d /dev/rtc1 -m freeze -s 5, 3/3 PASS, dpmsStatus=1 on every wake). 0 DCP/IOMFB errors.
  • J716c (16-inch M5 Max, T6050), candidate c3da8eed6f72 over main 9af21b007425, Linux 7.3.0, default Stage 2, AC 100%: single boot ID, 0 panics/Oops/BUG/SErrors/DART faults/GPU faults/LSM denials, eDP-1 3456x2234@120. 48ae00000 negotiated and went 0 -> 1 -> 2 (observed with dynamic debug dev_dbg), returned to 0 on DPMS off and re-entered 1 -> 2 on DPMS on with 0 v27 idle-cache ... failed/refused warnings, replays=0, and state 4 never reached (now disabled via default-off hw.v27_idle_cache).

Earlier-head unplugged hardware coulomb-counter A/B on J713 (macsmc-battery/charge_counter, BAAC, 1 mC/count)

Measured back-to-back on J713 M4 MacBook Air (macsmc-ac/online=0, discharging, 60 s settled after 20 s post-boot settle + 10 s per-step settle, kbd=0, wifi_ps=off, P_coulomb = |dCC| * V_avg / dt; voltage sampled every 10 s; measured on historical test build c05e2a268684, which differed from ba76eb6e18f7 in mailbox error handling and DMA-retention timing, with state-4 replay runtime re-verified on 71d4331a4fb5 and ba76eb6e18f7):

Condition Baseline (859e8a29796c) With idle cache (v27 state 4 active) Delta
Display ON, bl=5 1,913.2 mW (-8,757 mC, 13.1089 V) 1,823.9 mW (-8,323 mC, 13.1483 V; repeat 1,827.0 mW) -89.3 mW (-4.7%)
Display ON, bl=150 3,663.9 mW (-16,808 mC, 13.0791 V) 3,576.3 mW (-16,358 mC, 13.1177 V; repeat 3,578.7 mW) -87.6 mW (-2.4%)
DPMS OFF (control) 748.3 mW (-3,420 mC, 13.1279 V) 752.6 mW (-3,424 mC, 13.1876 V) +4.3 mW (noise)

Earlier-head kernel log excerpt (J713 firmware 27.2, default cmdline, ba76eb6e18f7)

[    3.644492] apple-dcp 30ae00000.dcp: v27 idle cache active (mem=51117696 host=1)
[   21.985163] apple-dcp 30ae00000.dcp: v27 idle cache state 0 -> 1 (mem=51117696 host=1 replays=2)
[   21.985317] apple-dcp 30ae00000.dcp: v27 idle cache state 1 -> 2 (mem=51117696 host=1 replays=2)
[   22.013682] apple-dcp 30ae00000.dcp: v27 idle cache state 2 -> 4 (mem=51117696 host=1 replays=3)

Wire up static-frame idle caching for firmware 27 internal panels. After a
normal KMS swap completes as displayed and remains static for 1 second,
allocate a reusable DMA cache surface sized for the active scanout layout,
negotiate replay via applyProperty(138, 2) on A352 (latching unavailable
if firmware refuses), and submit a replay swap (swap_intent = 8) so the
display controller services scanout from local cache while idle.

Handle firmware idle-cache callbacks (D116 state transitions, D579/D580
fence lifecycle, D581 surface release), validate surface layout and buffer
size on every registration (reallocating only after release), guard
against stale templates with a monotonic generation checked under IOMFB
serialization, close replay admission before draining work while keeping
outstanding replay swap IDs filtered until consumed or reset, and preserve
the cache DMA allocation across retained-DMA shutdown/unbind paths.

Signed-off-by: Erik Bourget <[email protected]>
@erikwb
erikwb requested review from a team as code owners November 26, 2026 18:07
@erikwb
erikwb requested review from LiamRay11 and maralcbr November 26, 2026 18:07
@github-actions github-actions Bot added area:display Area from CODEOWNERS (bot) blast:m4 Macs affected, from Merge risk (bot) blast:m5 Macs affected, from Merge risk (bot) door:two-way Revertible or not, from Merge risk (bot) needs-review No approving review from Core or Omarchy Mac yet (bot) labels Nov 26, 2026
@github-actions

github-actions Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Merge readiness at 4a6030e3: not ready yet

Check Detail
CI at head no failing: host-tests
Review ok approved by DjDeveloperr
Requested changes ok none
Hardware row at head ok in the PR body at 4a6030e3
Conflicts no merge conflicts with main: merge it in (no force push)
PR text ok Risk: two-way · T8132 firmware-27 internal panels (appledcphwt8132v27); iomfbqueueinit() wait-queue initialization across DCP interfaces; unverified profiles and T6050 remain off by default Revert: git revert restores default-off behavior across all profiles, dcp_caches_scanout() M4-only scope, and channels_idle_wq initialization in dcp_platform_probe_pipe() with no persistent on-disk, DT, or firmware state (apple-dcp live unbind after replay registration retains DMA until reboot, as with any adopted live DCP session).

Areas: area:display, area:gpu

Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels.

dcp_push_context() now calls dcp_send_message_checked() so idle-cache
callers can unwind unsent mailbox commands on send error. Provide the
matching stub in the dcpext26-startup-tests transport fixture.

Signed-off-by: Erik Bourget <[email protected]>
@erikwb
erikwb requested a review from DjDeveloperr as a code owner November 26, 2026 19:15
@github-actions github-actions Bot added area:gpu Area from CODEOWNERS (bot) needs-hw-row No hardware row at the PR head (bot) labels Nov 26, 2026
@erikwb

erikwb commented Nov 26, 2026 •

Copy link
Copy Markdown
Contributor Author

Hardware check on J716c (16" M5 Max, T6050) at ed0e9648f90c (tested unchanged in batched trial kernel with #3288 + #3289, default command line): PASS (with one state-reporting note below).

  • Clean boot (eDP-1 3456x2234@120 + paired DP-1 3840x2160@240 + paired DP-4 3840x2160@240, 0 new kernel errors, 0 blanking or corruption).
  • 48ae00000.dcp negotiates applyProperty(138, 2) (status=0), registers the replay swap (mem=92648064, host=1), and transitions v27 idle cache state 0 -> 1 -> 2 after 1 s of static output, with periodic 2 -> 6 -> 2 cache refreshes granting D579 fences.
  • Survived 3× full DPMS OFF/ON cycles across internal + paired external displays, cleanly dropping 2 -> 0 and re-entering 0 -> 1 -> 2 after each wake.
  • Note for H17G / J716c: Firmware settles in state 2 (never transitioning to state 4), so v27_idle_replays stays 0 and the one-shot dev_info("v27 idle cache active ...") (gated on state == DCP_V27_IDLE_STATE_ACTIVE == 4) never logs at info level — state transitions were verified via dynamic_debug (iomfb_v27.c).

@github-actions github-actions Bot added merge-conflict Conflicts with the base branch (bot) and removed needs-hw-row No hardware row at the PR head (bot) labels Nov 26, 2026
@github-actions github-actions Bot added needs-hw-row No hardware row at the PR head (bot) merge-conflict Conflicts with the base branch (bot) and removed merge-conflict Conflicts with the base branch (bot) labels Nov 27, 2026

@aurora-silicon-review aurora-silicon-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: Changes requested at 021728a98ebd.

The M5 Max row reaches setup state 2 but never reaches active replay, and records zero replays. That demonstrates setup and DPMS recovery on the earlier integration, but leaves the behavior advertised for M5 unverified. Please attach a current-head M5 row with a real replay and teardown, or gate admission on a demonstrated replay capability. Also include an injected failed submit after IOVA preparation to show the new channel unwind and session release preserve callback and DMA ownership. Hosted CI is green.

Add KUnit test coverage in apple-dcp-v27 for an injected mailbox send
failure on swap_submit after the idle-cache DMA surface (IOVA) and
live-session retention references have been prepared.

Verify that dcp_push_context() unwinds the failed command slot, leaves
outer channel callbacks and cookies intact, preserves subsequent command
callback delivery, clears pending idle-cache swap state without filtering
a normal swap ID, aborts the uncommitted session retention references, and
preserves a prior DMA pin while allowing unpinned DMA surface release on
unbind.

Signed-off-by: Erik Bourget <[email protected]>
Avoid scheduling an asynchronous ack work item for the manual-ack
sentinel command in v27_idle_failed_submit_unwind_test() so the
pending depth check and explicit iomfb_recv_msg() ack do not race.

Release iomfb.lock and clear iomfb.owner before evaluating the fatal
KUNIT_ASSERT_EQ() checks in
v27_idle_unwind_preserves_outer_callback_and_pin_test() so a failing
assertion cannot abort while holding the lock taken by cleanup.

Signed-off-by: Erik Bourget <[email protected]>
@sithglan

Copy link
Copy Markdown
Contributor

Tested on J313 (M1 MacBook Air, T8103, firmware 27.2.1) via ewb/j313-daily (786ad8d1e498, which merges 021728a98ebd / ba76eb6e18f7) on a console-only (fbcon) Debian setup (no Wayland compositor running):

Issue: fbcon freezes after 1 second

  • At t=9.978s (1 s after fbcon takes over), 231c00000.dcp logs v27 idle cache active (mem=49151616 host=0) and switches scanout to the replay cache surface.
  • Because apple_drv.c uses drm_gem_fb_create (without drm/apple: turn framebuffer damage into a commit #2797's fbdev damage commits), fbcon draws directly into its single DMA framebuffer in place without issuing KMS page-flips. Once DCP enters replay, the display freezes permanently on that 1-second snapshot (verified keyboard input was still arriving in /dev/vcs1 underneath, and toggling /sys/class/graphics/fb0/blank 1 -> 0 only unfroze it for 1 second before replay re-engaged).

Secondary note

  • appledrm.idle_cache_ms only controls iomfb_m4.c; iomfb.c hardcodes DCP_V27_IDLE_CACHE_DELAY_MS = 1000U, so setting appledrm.idle_cache_ms=0 does not disable v27 idle caching on this path.

Workaround / suggested fix

Skipping idle-cache admission in iomfb_v27_idle_cache_on_present() when the active primary FB is the fbdev framebuffer (fb == fb->dev->fb_helper->fb) keeps fbcon live while leaving replay caching intact for KMS compositors (or gating on #2797 if fbdev damage commits are intended to exit replay). Wiring a runtime disable/delay parameter similar to iomfb_m4.c would also be useful for debugging.

@erikwb

erikwb commented Nov 27, 2026

Copy link
Copy Markdown
Contributor Author

Added KUnit coverage for the injected failed-submit unwind and session-release paths in 125129d93ae9 and f7e6fb162951 (drivers/gpu/drm/apple/iomfb_v27_test.c):

  • Failed swap_submit after IOVA and session preparation (v27_idle_failed_submit_unwind_test): Exercises iomfb_v27_idle_cache_work() -> A352 negotiation -> drm_gem_dma_create() + dcp_retain_live_session_prepare() -> A406 swap_start -> iomfb_v27_idle_swap_started(), then injects -EAGAIN from dcp_send_message_checked() (via a CONFIG_DRM_APPLE_KUNIT_TEST-only test_send hook) after A408 swap_submit arms ch_cmd with surf_iova[0] prepared. Verifies dcp_push_context() unwinds ch_cmd.depth and clears slot 0 (callbacks, cookies, output, end), clears v27_idle_submitting/v27_idle_swap_pending/v27_idle_swap_id without swallowing normal swap completions, aborts the uncommitted session retention (dcp->retain_dma == false, dcp_test_session_retained() false, device kref back to baseline), preserves subsequent dcp_push() callback delivery on ch_cmd (with a manual-ack sentinel and single explicit iomfb_recv_msg() completion), and releases v27_idle_obj cleanly on iomfb_v27_idle_cache_release_obj().
  • Outer slot callback & prior DMA pin preservation (v27_idle_unwind_preserves_outer_callback_and_pin_test): Injects -EAGAIN at ch_cmd.depth == 1 (iomfb_test_push_context()) with iomfb.lock / iomfb.owner released before fatal assertions, and verifies slot 0's callback and cookie stay intact and fire on ack; also verifies a prior v27_idle_dma_pinned owner survives a failed re-submit while a clean swap_submit commits dcp->retain_dma and iomfb_v27_idle_cache_release_obj() preserves the retained v27_idle_obj object (keeping full unbind verification in the hardware row).
  • Verification at f7e6fb162951: apple-dcp-v27 KUnit 5/5 passed, topology.kunitconfig 210 passed / 1 skipped, display.kunitconfig 167 passed / 1 skipped, dcpext26-queue-tests.py and dcpext26-startup-tests.py passed, scripts/checkpatch.pl --strict --git 021728a98ebd..HEAD clean (0 errors, 0 warnings, 0 checks), and LLVM=1 ARCH=arm64 W=1 drivers/gpu/drm/apple/ compiled with 0 warnings.

Regarding the M5 Max row: the earlier J716c test at ed0e9648f90c ran with paired DP-1 and DP-4 active and stayed in state 2 (2 -> 6 -> 2 refreshes, 0 replays). Current-head hardware at f7e6fb162951 (default command line): J713 (firmware 27.2, batched candidate b3dbf237542b) logged v27 idle cache active (mem=51117696 host=1) and went 0 -> 1 -> 2 -> 4 after each of 3x DPMS off/on cycles and through 3x s2idle (replays=21..24) with 0 DCP/IOMFB errors. J716c (batched candidate c3da8eed6f72, standalone eDP-1) negotiated and went 0 -> 1 -> 2, returned to 0 on DPMS off and re-entered 1 -> 2 on DPMS on with no refusal warnings, but still replays=0 and never reached state 4, so active replay is not yet verified on T6050; if it stays at setup state 2, admission will be gated on a demonstrated replay capability.

@aurora-silicon-review aurora-silicon-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new KUnit cases address the failed-submit unwind and retained-owner checks. J713 demonstrates replay at this head. J716c still stops at setup with zero replays, even with the internal panel alone. Please demonstrate active replay there or restrict admission using a verified replay capability. Also record the live-session unbind result once that path is tested.

@github-actions github-actions Bot added merge-conflict Conflicts with the base branch (bot) and removed blast:m5 Macs affected, from Merge risk (bot) labels Nov 29, 2026
Resolve the conflict in drivers/gpu/drm/apple/apple_drv.c with main's
scanout-caching fb_create: devices whose backend caches scanout keep the
dirty-hook framebuffers from main, and on the other devices headless
in-kernel client framebuffers still get apple_drm_client_fb_funcs, so
the firmware 27 idle cache keeps excluding unshadowed fbdev.

Signed-off-by: Erik Bourget <[email protected]>
@RyanTheTide

Copy link
Copy Markdown
Contributor

Merge-train note: this conflicts with main after today's DCP merges. Please merge main in (normal push). It's otherwise queued (App approved, J713 row, T8132-only enable justified in the PR).

@aurora-silicon-review aurora-silicon-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: MERGE at e50de02

Checked: The merge keeps main's dirty-hook framebuffer handling for backends that cache scanout, and preserves the distinct in-kernel framebuffer funcs for the remaining clients. Unverified idle-cache profiles remain disabled.

Remaining validation: Keep exact-head hosted CI and confirm the J713 replay evidence covers the merged framebuffer routing.

@github-actions github-actions Bot added needs-hw-row No hardware row at the PR head (bot) ci-failing A check failed at the PR head (bot) merge-conflict Conflicts with the base branch (bot) and removed ci-failing A check failed at the PR head (bot) merge-conflict Conflicts with the base branch (bot) labels Nov 29, 2026
@RyanTheTide

Copy link
Copy Markdown
Contributor

Merging under the 6-point rule (Ryan 09:29, permanent), at e50de028. (1) The review App approved at this head. (2) Full CI is green. (3/4) Rows: J713;T8132-only-justified-gate;fwd-merge. (5) There's no blocking review. (6) Dj was pinged here 1260 min ago with no objection. Revert: git revert -m 1 <merge>.

Conflicts:
	drivers/gpu/drm/apple/iomfb.c

iomfb_reset_transport() keeps both tails: the branch's
iomfb_v27_idle_cache_reset() and main's iomfb_channels_idle_wake(),
in that order.

Signed-off-by: Erik Bourget <[email protected]>
@github-actions github-actions Bot removed ci-failing A check failed at the PR head (bot) merge-conflict Conflicts with the base branch (bot) labels Nov 30, 2026

@aurora-silicon-review aurora-silicon-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: HOLD at a4d28a5a

Blockers:

  1. CI workflows are still queued at a4d28a5a. Apple DRM KUnit, Host tests, and Apple build and KUnit are queued after the a4d28a5a merge with main (pr-text and pr-readiness passed).

Checked:

  • Forward merge a4d28a5a (MERGEABLE against main, 12 files, +1650/-31), cleanly rebasing previously approved e50de028 (J713 power savings + T8132-only enable + KUnit coverage).
Evidence
  • Ready for re-approval once queued Apple DRM KUnit, Host tests, and Apple build and KUnit complete green at a4d28a5a.

erikwb added a commit that referenced this pull request Dec 1, 2026
…idle-off

Take #3289 so the two merge cleanly in order. Both extend struct apple_dcp: keep the internal panel's idle cache state and the external idle-off state. #3289 gives dcp_push_context() an unwind_on_err argument and a KUnit wrapper: keep the wrapper, and have dcp_push_try() pass false, as dcp_push() did.

Signed-off-by: Erik Bourget <[email protected]>
@github-actions github-actions Bot added the ci-failing A check failed at the PR head (bot) label Dec 1, 2026

@aurora-silicon-review aurora-silicon-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: MERGE at a4d28a5a72b7

Converts this App's earlier review at the same head to an approval under the 12-01 merge bar (better than before and doesn't break; block only on a shown failure). No code blocker was found in it. The merge gate (a row on one Mac at this head + fast CI) is tracked by pr-readiness, not held here.

Checked: - Forward merge a4d28a5a (MERGEABLE against main, 12 files, +1650/-31), cleanly rebasing previously approved e50de028 (J713 power savings + T8132-only enable + KUnit coverage).

Follow-ups (not blocking): Previously approved code; follow-ups: queued KUnit/host/build CI

Commit f085a8d ("drm: apple: Wait for the firmware channels to go
idle on an event") added iomfb_channels_idle_wake() calls to
iomfb_recv_msg(), dcp_ack(), and iomfb_reset_transport(), but initialized
dcp->channels_idle_wq only in dcp_platform_probe_pipe(). KUnit suites
that initialize an apple_dcp via iomfb_queue_init() without running
platform probe (including apple-dcp-v27 after the main merge) left
channels_idle_wq zero-initialized, causing wq_has_sleeper() and
wake_up_all() to dereference a NULL list head on the first
iomfb_recv_msg().

Move init_waitqueue_head(&dcp->channels_idle_wq) into
iomfb_queue_init(), which already runs earlier in
dcp_platform_probe_pipe() and is shared by every IOMFB queue KUnit
fixture.

Signed-off-by: Erik Bourget <[email protected]>
dcp_caches_scanout() previously reported only iomfb_is_m4(), so devices
running firmware 27 static-frame idle caching
(dcp_v27_idle_cache_supported()) still received plain
drm_gem_fb_create() framebuffers whose DIRTYFB ioctls return -ENOSYS.
Once firmware 27 replay started, front-buffer drawing stayed frozen
until another flip.

Include dcp_v27_idle_cache_supported(dcp) in dcp_caches_scanout() so
apple_fb_create() attaches drm_gem_fb_create_with_dirty() on
replay-capable firmware 27 panels, routing DIRTYFB and shadowed fbdev
damage through the atomic commit path to refresh scanout and exit
replay, while keeping non-caching profiles on plain GEM and headless
apple_drm_client_fb_funcs framebuffers.

Add KUnit coverage in apple-dcp-v27 verifying that userspace
framebuffers on replay-capable scanout receive the dirty hook and commit
through the atomic pipeline instead of failing with -ENOSYS, while
non-caching profiles keep plain and client ops.

Signed-off-by: Erik Bourget <[email protected]>
@github-actions github-actions Bot added the merge-conflict Conflicts with the base branch (bot) label Dec 1, 2026
@erikwb

erikwb commented Dec 1, 2026

Copy link
Copy Markdown
Contributor Author

Updated feat/dcp-v27-idle-cache through 4a6030e3598b:

  • KUnit wait-queue init (962249cdc60f, drivers/gpu/drm/apple/dcp.c, drivers/gpu/drm/apple/iomfb.c): Moved init_waitqueue_head(&dcp->channels_idle_wq) into iomfb_queue_init() (which runs earlier in dcp_platform_probe_pipe() and is shared by every IOMFB queue KUnit fixture), fixing the NULL wait-queue dereference in iomfb_channels_idle_wake() introduced by the main merge at a4d28a5a72b7.
  • Replay-capable DIRTYFB commit path (df01a6cd9b2e, drivers/gpu/drm/apple/dcp.c, drivers/gpu/drm/apple/apple_drv.c, drivers/gpu/drm/apple/iomfb_v27.h, drivers/gpu/drm/apple/iomfb_v27_test.c): Included dcp_v27_idle_cache_supported(dcp) in dcp_caches_scanout() so apple_fb_create() attaches drm_gem_fb_create_with_dirty() on replay-capable firmware 27 panels, routing DIRTYFB front-buffer updates (and shadowed fbdev updates) through the atomic commit path to refresh scanout and exit replay instead of returning -ENOSYS, while non-caching profiles keep plain GEM and headless apple_drm_client_fb_funcs framebuffers. Added v27_idle_dirtyfb_commits_on_replay_capable_fb_test in apple-dcp-v27.
  • Forward merge of origin/main (4a6030e3598b, 19ee1b5bc9d5): Resolved the v27_cases[] conflict in drivers/gpu/drm/apple/iomfb_v27_test.c to keep both main's 4 v27_rt_bw_* cases and #3289's 5 v27_idle_* cases (4a6030e3598b only merged iomfb_v27_test.c with main, so driver code is identical to df01a6cd9b2e).
  • Checks at 4a6030e3598b:
    • apple-dcp-v27 KUnit: 12/12 passed (0 failed).
    • topology.kunitconfig: 221 passed, 1 skipped, 0 failed (222 total).
    • display.kunitconfig: 188 passed, 1 skipped, 0 failed (189 total).
    • drivers/gpu/drm/apple/tests/.kunitconfig: 117 passed, 0 failed (117 total).
    • make O=_build_w1 LLVM=1 ARCH=arm64 W=1 drivers/gpu/drm/apple/ (defconfig + asahi.config, CONFIG_RUST=n): 0 errors, 0 warnings.
    • tools/asahi/dcpext26-queue-tests.py and tools/asahi/dcpext26-startup-tests.py: both pass.
    • HOSTCC="clang -Wno-unused-but-set-global" python3 -I tools/asahi/run-host-tests.py --only apple-dcp: 87/101 passed (14 pre-existing host-compiler failures unrelated to #3289; stale-crtc-poweroff and dropped-swap-teardown pass).
    • ./scripts/checkpatch.pl --strict --git a4d28a5a72b7..df01a6cd9b2e: 0 errors, 0 warnings, 0 checks; git diff --check origin/main...4a6030e3598b clean.
    • Prior kb run -p linux-j713 at df01a6cd9b2e passed.
  • J713 live hardware row at df01a6cd9b2e (standalone main + df01a6cd9b2e, M4 Air, T8132, firmware 27.2; 4a6030e3598b only merged iomfb_v27_test.c with main):
    • Boot: apple-dcp 30ae00000.dcp: v27 idle cache active (mem=49151616 host=1) 8.3 s after boot.
    • DPMS off/on ×4 (hl.dsp.dpms, dynamic debug on iomfb_v27.c): every off 4 -> 0, every on 0 -> 1 -> 2 -> 4, replays 1 -> 5.
    • s2idle (rtcwake -m freeze -s 20): 4 -> 0 at suspend entry, 0 -> 1 -> 2 -> 4 after resume (replays 9 -> 10), suspend_stats fail 0.
    • fbcon (/proc/fb appledrmfb): chvt 3 dropped 4 -> 0 and stayed at 0 for 12 s (including three writes to /dev/tty3, no 0 -> 1); chvt 1 re-armed (0 -> 1 -> 2 -> 4, replays 8 -> 9; visual redraw not observed remotely).
    • DIRTYFB from state 4: not exercised; DRM_IOCTL_MODE_DIRTYFB returned EACCES (13) from a second client even as root because the compositor holds DRM master, and fbcon never arms the cache.
    • Live apple-dcp unbind from state 4: returned 0, 4 -> 0, G16: fail-stop (ENODEV), retaining live DCP DMA resources after unbind; reboot required, 0 Oops/WARN/BUG/refcount/hung-task/call-trace lines; clean reboot afterwards.
    • Smoke: 0 failed units, 0 AppArmor denials, 0 oops/WARN, eDP-1 enabled; err = baseline 3 + 2 unprobed external DCP -ENODEV lines.
  • J716c live hardware row at df01a6cd9b2e (same driver code, composite trial kernel over main 429e7e15f122): Default-off confirmed (0 idle-cache/replay lines in dmesg, 0 DCP swap/commit/poweroff error lines), 4x eDP-1 DPMS off/on (3456x2234@120 restored, 0 new err/warn lines), and smoke checks clean (MTP keyboard/trackpad/lid, wlan0 0% loss, AppleJ716 PCMs, Borealis Apple M5 Max (G17C B1) vkcube, 0 LSM denials, 1 baseline failed unit aurora-peripherals.service, 0 GPU/MMU faults or Oops/WARN).
  • Remaining: Direct DRM-master state-4 DIRTYFB front-buffer update and on-site visual fbcon redraw observation + refreshed unplugged battery coulomb-counter A/B on J713 (T8132), refreshed J313 (T8103) smoke/DPMS/S2R row, post-merge confirmation at 4a6030e3598b (4a6030e3598b only merged iomfb_v27_test.c with main), and hosted Apple build and KUnit CI completion.

@github-actions github-actions Bot removed merge-conflict Conflicts with the base branch (bot) needs-hw-row No hardware row at the PR head (bot) ci-failing A check failed at the PR head (bot) labels Dec 1, 2026

@DjDeveloperr DjDeveloperr left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed replay admission, swap completion filtering, and firmware ownership of the cache GEM object through release and teardown. The J713 hardware run covers the production code carried by the current head. The exact-head Apple build and DCP KUnit are pending.

@github-actions github-actions Bot added ci-failing A check failed at the PR head (bot) merge-conflict Conflicts with the base branch (bot) and removed needs-review No approving review from Core or Omarchy Mac yet (bot) labels Dec 1, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:display Area from CODEOWNERS (bot) area:gpu Area from CODEOWNERS (bot) blast:all Macs affected, from Merge risk (bot) ci-failing A check failed at the PR head (bot) door:two-way Revertible or not, from Merge risk (bot) merge-conflict Conflicts with the base branch (bot)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants