Skip to content

Bring the omacom integration work into aurora-wip, reviewed and regression-tested - #783

Merged
RyanTheTide merged 134 commits into
aurora-wipfrom
omacom-sync/all
Nov 1, 2026
Merged

RyanTheTide merged 134 commits into
aurora-wipfrom
omacom-sync/all

Conversation

@RyanTheTide

@RyanTheTide RyanTheTide commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

This brings the work from the omacom linux-aurora integration branch into our tree in one PR, so aurora-wip carries everything worth having from it. Nothing goes the other way.

We compared all 2738 omacom commits that are not in our history:

verdict count
already in our tree, patch-identical 2460
already in our tree, adapted during a rebase 111
ported here 96, plus the two-commit Wi-Fi roam series
superseded by our own code 6
rejected (27 CI, CODEOWNERS and vouch infra commits, 7 after review) 34
held, not safe or not provable yet 31

Every commit has a written verdict, and none are left unexplained. We treated each ported commit as untrusted and read its diff in full. The fixes we made on top:

  • The G15 performance-buffer and stamp commits didn't build on 7.3, and one was gated on a Kconfig symbol we don't have, which would have broken the J616s build. Their 8 new module parameters became fixed values.
  • The soft-DPMS change would have dropped every panel except H17P, so we narrowed it. DP and HDMI audio on by default added an error per Neo DCP and new ALSA cards on the M1 Pro. It's reverted here and left as a separate decision.
  • The SPI HID report check would also have hit the MTP actuators on the Neo, J616s and M2, and it reported success for a mode switch it never sent.
  • The mt7932 radar port never probes radar channels on the Neo, and it leaves on CSA or ECSA.
  • The amdgpu and TTM changes only take effect behind a real non-posted BAR, so normal hosts run identical code.
  • The Wi-Fi roam series gained follow-ups. A cancel keeps its reason, and a refused move is reported once, which fixes a double-disconnect race. A deferred regulatory relaxation now holds across a move. The series also gains a KUnit suite and host-harness cases.

Held and not in this PR: the M3 Air (T8122) GPU runtime, until its 34 module parameters become identity-selected constants and it boots on a J613 or J615. Also held: the SEP first-setup window, the mesa-m3 handoff scripts, ISP T8122 commits without their author's sign-off, the CT720 colour channels, a PCI prefetchable-window write that needs tunnel boots on T6001 and T8112, and DJ's G17-only memory-limit policy.

The branch is merged up to aurora-wip 9957153 (the last merge commit's title names 97526d9, its parent at the time). Two later merges had conflicts. In drivers/pmdomain/apple/pmp-report.c and its host-test copy, the T6030 sleep release meets the new soc-device DVFS request, and both sides were kept. In drivers/dma/apple-sio.c, the protocol-9 shared-memory setup from #792 is kept, with the descriptor bitmap allocated as a real bitmap (the 2-byte allocation for a 64-bit bitmap is one of the fixes this PR brings). The full per-commit table is kept with our sync report.

Testing

Build and host tests, on 2efadb4, 127aefc and the final head ffa4d1a:

  • Fleet build rc 0, with the same 7 modpost description warnings as the base. 5875 modules, 0 asahi.config mismatches, distro gate ok.
  • run-host-tests 161/161 and apple-dcp 85/85 on each head. mt7932 KUnit 78/78 plus the new move suite. apple-sio KUnit 17 pass, 1 skip, on the final head.

Hardware: each test kernel was one-shot booted and compared with the machine's own stock boot.

machine kernel result
Neo (J700) omsync on fleet14c, then omsync2 on this head kernel -p3 0, aurora-diag 309 pass / 0 fail against a fresh stock snapshot, lspci and module params identical, no DCP audio card. AVE encode 110/101/55+55/30/29/27 fps (same as fleet14c), v4l2-compliance 48/48, ISP 7/7, glmark2 6813 (6832 on fleet14c), suspend and resume, Touch ID, 0 DART faults, 0 page-flip failures
Neo Wi-Fi roam omsync and omsync2 iwd SAE with PMF required between two APs on one SSID: ROAM_MOVE 0 both ways, no disconnect seen by iwd, 0% ping loss. NetworkManager and wpa_supplicant Roam() SAE: both ways, 0% ping loss, same DHCP lease
M2 (T8112) omsync2 kernel and all -p3 0, aurora-diag 345 pass / 0 fail against stock, ANE 20/20 bit-exact (0.180 ms), camera 30 frames, Touch ID, glmark2 6833 (6779 on fleet14d), pm_test the same as fleet14d, no DP audio card, asahi_stats present
M1 Pro (T6000) omsync (before the audio revert), then omsync2 kernel -p3 0, ANE 20/20, camera, Touch ID, glmark2 10241 (fleet14d 10190), Wi-Fi country accepted. One of two omsync2 boots logged the SPI HID status mismatch with a get-report timeout at probe. The same three lines appear in fleet14b and older baseline boots, so it isn't new
J616s (T6041) omsync2 k/all -p3 0, aurora-diag 290 pass / 0 fail against a fleet14d snapshot, lspci identical, no DCP audio card, glmark2 7171 (fleet14d 7046), Touch ID, motion sensors, Wi-Fi 400 Mbit/s, dock LAN, BT, 3 DCPs bound. rtcwake is the same as fleet14d. HDMI audio was not tested (not approved)
Neo omsync3 (127aefc, before the apple-sio merge) -p3 0, aurora-diag 310 / 0 fail, AVE 108.7/101.2 fps 1080p and 30.2/28.7 fps 4K, glmark2 6840, ISP 7/7, suspend ok

🤖 Generated with Claude Code

erykwieliczko and others added 30 commits November 1, 2026 10:52
Return success when a VM BO has no mappings instead of returning an
uninitialized stack value. Deferred-close cleanup can reach this case;
a garbage error return marks cleanup failed and blocks the VM.

Signed-off-by: Eryk Wieliczko <[email protected]>
(cherry picked from commit 2151a34)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Allow immediate-mode drivers to remove selected mappings of one GEM
without allocating an operation list.

Signed-off-by: Eryk Wieliczko <[email protected]>
(cherry picked from commit a8f459d)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A dma-buf reimport can return the same GEM while cleanup for a closed
handle is queued. Stamp each binding and remove only mappings covered by
the close-time sequence, preserving later maps instead of unmapping them.

Keep the indexed BO path when no newer binding exists. A map step that
takes its sequence after the close snapshot survives deferred cleanup.

[ryan: the VmBoData initialisers follow our SG lease and
prepare_sgt_segments() setup; drop_mappings_before() gains the SAFETY
comment its exec_lock() call carries elsewhere]

Signed-off-by: Eryk Wieliczko <[email protected]>
(cherry picked from commit 13c3371)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
On the J516C the 120 Hz panel presented at 60 fps: the 14.7 swap record
is sent with its timestamps zeroed, and the firmware then completes at
most one swap per 16.7 ms. Counter values (1 GHz on T6031) in the
timestamp slots make the firmware time out on the first swap. Write the
constant 120 in timestamp slots 0, 1 and 6 instead, a time that is never
in the future, after the swap record is encoded.

Add a swap_timestamps flag to the 14.x board records, set only in the
J516C record, and stamp a swap only for the internal panel of such a
record. The J514C (untested), the T6030 (J514S, J516S) and T8122 panels
and the external processors, which have no board record, send zero
timestamps, byte for byte as before. The counter timestamps of the
IOMFB template path (VRR modes on a main display) are not used by the
native 14.7 path and are unchanged.

Measured on the J516C on this branch: kmscube (atomic) presents at
120 fps (120.03 on two boots) on the panel's 120 Hz mode, 3456x2160
with the 74 notch rows hidden, and the first swaps of a boot complete
in 2.9 to 8.1 ms instead of 16.7 ms.

KUnit (apple-dcp-v14-board): the J516C record stamps its internal
panel's swaps; the external role, the J514C, T6030 and J613 records and
no record do not; a stamped swap holds 120 in slots 0, 1 and 6 and
is otherwise the encoded record, with and without a surface.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Naeem Malik <[email protected]>
[ryan: the J516C base EDID (d77c556) is not carried, so the board record and header gain only swap_timestamps]
(cherry picked from commit e3f69b7)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Port the SF 44fe00e5eb58 panel-level implementation and its 4b318c41
fixture-lifetime correction onto PR177's current shared backlight API.
Keep panel_nits on the T6030 board record, with separate immutable root
machine admission for J514S and J516S. Other 14.7 boards and external pipes
keep their existing level encoding and policy behavior.

Register the requested default without sending it. Keep the loader's
unknown level until userspace requests brightness, and report actual
brightness as unknown until a successful present carries a level. Preserve
the H17P fade/default behavior and its soft-DPMS dispatch; the 14.7 panel
uses its own known-level-only blank and restore hooks.

Use the existing v14 RPC lock to serialize a swap with publication of its
active framebuffer and copied surface. Brightness work holds that lock
and the active framebuffer reference throughout its present. Close the
queue gate under that lock, then cancel outside it. Permanent teardown
also publishes quiescing, drains shared registration/update work, and
unregisters the class device while its CRTC is still valid.

Retain the original KUnit suite and add actual present/publication thread
interleavings, running-work suspend, real DPMS dispatch, failed-submit
actual-level checks, and shared registration/unbind controls. Static stubs
replace only the RPC boundary and a one-shot publication pause; the latter
continues through the real publication body.

Based-on: 44fe00e5eb58d54baf1cc9ad607293e774bfed44
Based-on: 4b318c4140e83e44033168836fe8cf4f76e16d80
Based-on: omacom/linux-aurora PR148 commit 0252453 (DjDeveloperr)
Generated-by: LLM
Signed-off-by: Chris Kearney <[email protected]>
[ryan: resolved onto the 7.3 shared backlight: the T8132 (iomfb_is_m4) panel stays active, configurable and registrable as before, the desktop 26.x readback is kept, and soft DPMS excludes only the 14.7 panel (which has its own hooks) instead of every non-H17P panel; the swap keeps the J516C timestamps before the level block]
(cherry picked from commit 378d88c)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Give the framebuffer fixtures real private GEM objects on a GEM-capable
DRM device. Release their initial references after the framebuffer and
active-scanout references, with the matching public object release.
Initialize the mode-state spinlock used by the actual unbind path.

Set the fixture panel dimensions so real DPMS dispatch also detects a
regression that routes this panel through H17P soft DPMS. Exercise the
J514S admission branch as well as J516S and the other-machine refusal.
Production code is unchanged.

Generated-by: LLM
Signed-off-by: Chris Kearney <[email protected]>
(cherry picked from commit fb8f91b)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Wrap and align the new declarations and calls, describe the gate spinlock,
and remove an extra blank line. Split two fixture field assignments and
write its null-callback assertion as a boolean expectation. Document that
resume reopens admission and leaves a pending level for the next normal
CRTC restore present.

The production C token stream is unchanged after removing comments and
whitespace. Keep the qualified encoder's constant-only layout assertions;
their checkpatch comparison warning does not indicate an operand-order
bug. New files are already covered by the Apple DRM maintainer path.

Generated-by: LLM
Signed-off-by: Chris Kearney <[email protected]>
(cherry picked from commit 964323e)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
After the running brightness present and suspend have completed, leave a
new level pending and invoke the real callback as a previously queued
callback could arrive. It must refuse the level without another RPC even
though the framebuffer is still pinned. This separately checks callback
admission as well as the queue-side gate.

Generated-by: LLM
Signed-off-by: Chris Kearney <[email protected]>
(cherry picked from commit f4ef473)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A refused internal swap latches the panel failure state. Do not queue a
brightness retry that cannot be admitted after that failure; exercise the
real refused swap and subsequent work admission in the lifecycle test.

Declare the KUnit-visible registration worker in the shared internal
header so its definition has a prototype in KUnit builds. Replace the
nonexistent variant-tree reference with the public source commit.

Keep fbdev unblank notifications from sending the advertised default
before a level is known. Exercise the registered class operations before
and after a real present, and take the DPMS and suspend controls through
the restore present and its encoded level.

Generated-by: LLM
Signed-off-by: Chris Kearney <[email protected]>
[ryan: dropped the Link: trailer to the review on the omacom tree]
(cherry picked from commit 40eb318)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A late class kick may queue a worker even after the panel failure is
latched; the worker refuses to send the swap. Drain that asynchronous
callback before checking that no work remains, and keep the submit-count
assertion on both the queued and directly invoked callback paths.

Generated-by: LLM
Signed-off-by: Chris Kearney <[email protected]>
(cherry picked from commit fa224e8)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
EDID invalidation clears display_info after the panel's startup dimensions
were set. Without an EDID, later probes leave a 0x0 mm connector and KWin
falls back to 1x scaling.

Restore the internal panel's dimensions after publishing its modes. Cover
repeated EDID clears, firmware sizes, DT fallback and external EDID sizes
with the production get_modes path under ASan/UBSan.

Generated-by: LLM
Signed-off-by: Eryk Wieliczko <[email protected]>
(cherry picked from commit b7c75a9)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Type-C connectors have no DCP until a pipeline is routed. With
DRM_APPLE_DEBUG enabled, registering one dereferences the null platform
device. Skip the pipeline debug directory until a DCP is available.

Fixes: 2314090 ("drm: apple: route Type-C displays through a shared DCP fabric")
Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit c92eb39)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Check the published instance before Prepare and after its reply. Record the
link owner only after the firmware accepts it.

Fixes: f627d77 ("drm/apple: av: carry a Terminate's instance through its whole disconnect")
Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
[ryan: the 7.3 test runs every case on the 14.7 and desktop 26.6 roles and answers link status through its link_status field, so the new cases are parameterised and use it; the reply status check was already inside the open lock here]
(cherry picked from commit c806e16)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A disconnected PCM can still own a prepared firmware link. Complete that
link before closing its client, including when sync_stop wins the race
against the deferred owner release.

Fixes: 3fe0ef0 ("drm: apple: Add the DCP 14.7 external role's HDMI audio")
Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit d00568e)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
The 64-slot descriptor bitmap is only allocated two bytes. Use the bitmap
allocator so unsigned-long bitmap operations have enough storage.

Fixes: 5fdca02 ("dmaengine: apple-sio: Add Apple SIO driver")
Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit 69e431f)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
The sink behind the J514S HDMI port (PS190 converter, TV) mutes the
audio of a link stopped and started again with an unchanged format,
until the DP link trains again. macOS never does that: it starts the
link once and, between streams, keeps it running on a cleared buffer
until the display sleeps or the format changes.

Do the same for stereo on the HDMI port: the stopped stream's DMA is
replaced by silence and the link is held. The mute was measured behind
the HDMI port only, so a Type-C output keeps one link per stream unless
hold_link=2; hold_link=0 restores one link per stream everywhere.

While links are held, a link is not started in the first 1.5 s after the
sink connects: once, at boot, a link started 0.2 s after the display
came on was not heard, and holding it kept it silent. A link prepared at
START configures the SIO channel first, as the PCM's prepare does.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit 459ba24)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Link the Type-C DisplayPort processor (dcpext1) to DPA2 on SIO channel
0x68, as the ADT links dcpext1 to dp-audio2, so a display on a USB-C
port gets an audio device too.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
[ryan: the DPA2 audio controller sits at the root, as this tree places DPA1 in t603x-j514s-j516s-hdmi.dtsi (neither has AP-side registers, so neither is a simple-bus child)]
(cherry picked from commit 5ab5f59)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
PipeWire changes the device rate to follow its streams: 44.1 kHz music,
48 kHz video. A held link of another rate or sample size was replaced at
START by one with the same channel layout, which the J514S sink mutes like
a same-format restart. After 48 kHz then 44.1 kHz streams, every stream
was silent until a replug.

macOS runs the link at one nominal rate and format and converts streams to
it. While links are held, the PCM now offers one rate (48 kHz, else 44.1
or 32 kHz) and one sample size (24 bits, else 16), taken from one element
that offers them together in stereo, and userspace resamples. The pair
covers every channel layout: userspace sets the format before the channel
count, so a pair applied only to stereo let it rule stereo out. Channel
layouts stay free: a layout change is heard.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit 0ec6112)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A DP audio sink behind the J514S HDMI port mutes for good when its
samples stop for 20 ms or more, until the DP link trains again. Swapping
one cyclic transfer for another stops the channel with TERMINATE and
starts the next one after its acknowledgment: usually short enough,
sometimes not.

Let a client set an idle transfer (struct apple_sio_idle, passed as
peripheral_config in a slave config call of its own). The channel issues
it while no other transfer runs. Terminating a transfer then hands over
to it after the issued descriptors, with no TERMINATE, and a transfer
issued later follows its issued descriptors the same way.

From its first idle transfer until it is quiet again, a channel accounts
for its issued descriptors in a ring, seeded with what it has in flight:
reports complete them in issue order, so each is charged to the transfer
that issued it, and one ISSUE is outstanding at a time.
dmaengine_synchronize() waits for an ended transfer's descriptors. If
they do not complete within 500 ms, it stops the channel with TERMINATE
and waits for their reports again, and resets the ring if they never
come. Removing the idle transfer does the same, and fails if the channel
cannot be confirmed stopped.

A channel that never had an idle transfer keeps the old accounting
unchanged: the DP audio of M1 and M2 Macs sets none.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit f4dd5a2)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
The held link's silence replaced a stopped stream's DMA and was replaced
by the next stream's with a SIO TERMINATE in between, and closing the PCM
terminated it once more. A gap of 20 ms in the samples mutes the J514S
sink until the DP link trains again, as a link restart does: with a gap
forced to 20 ms, every later stream was silent, and Chromium resuming
after a 30 s pause was silent in 2 of 7 runs without one.

Make the silence the SIO channel's idle transfer while the link is held.
A stream's DMA follows it and hands back to it in descriptor order, and
the PCM's terminate at close leaves it running. Its periods shrink to
4 KiB, so a stream starts at most about 85 ms after its START.

A stream that ends into the silence leaves up to four periods issued,
which dmaengine_synchronize() waits for, 500 ms at most: on a port that
holds links, stream periods are kept to 50 ms. A silence whose channel
could not be stopped is not freed.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit c0b3d14)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
An acknowledged DISPEXT request keeps the PMP's external display state
up while no display is shown. The requests are asserted once at probe
(apple,always-on) and never withdrawn, so they also hold through
suspend-to-idle.

Give report entries marked apple,release-for-sleep noirq sleep
callbacks: by then every display processor has suspended, with its
displays off and its links released or idle. Withdraw such a request if
it is acknowledged, with one replacement write of the request entry as
macOS releases its display requests, and assert it again in
resume_noirq, before the processors resume. Without the request the
external display stays dark until reboot, so a re-assert the PMP does
not acknowledge in time is written again, three times at most. The
T6030 display gate marks the DISPEXT requests of the processors it
enables.

The PMP graph host test runs the new callbacks against its fake PMP:
an acknowledged request is withdrawn and asserted again, an
unacknowledged or unmarked one is left alone, and a re-assert
acknowledged late is written again.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
[ryan: the gate hunk goes to drivers/soc/apple/display-gate.c (the renamed T6030 gate, still marking only apple,t6030-dcpext processors); the PMP graph test keeps this tree DRAM metadata cases and IRQ-safe entries beside the new sleep cases]
(cherry picked from commit b28cb3a)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
The DCPs take their HDMI ("dp-xbar") and Type-C ("typecN-dpinM") route
mux controls from mux-apple-display-crossbar. Nothing tells userspace
about that dependency, so mkinitcpio puts appledrm in the initramfs but
not the crossbar. The crossbar then loads only from the root filesystem.

With an encrypted root the passphrase prompt can outlast the deferred
probe timeout. On an M3 Pro (J514S) both external DCPs gave up their
routes 12 s into boot, and the crossbar bound at 44 s, after unlock:

  apple-dcp 2d2c00000.dcp: deferred probe timeout, ignoring dependency
  apple-dcp 2d2c00000.dcp: HDMI output unusable (dp-xbar: -110); USB-C displays are not affected
  apple-dcp 2d2c00000.dcp: Type-C display routes unusable: -110; USB-C ports go on without this processor
  apple-dcp 2d2c00000.dcp: external display processor unusable: its Type-C display routes did not register
  apple-dcp 2d6c00000.dcp: external display processor unusable: its Type-C display routes did not register
  [   44.078721] apple-display-crossbar 70304c000.mux: dpphy: T602X route -2, clocks disabled

No external display worked until reboot. Adding the crossbar (together
with the sn201202x PD driver) to the initramfs fixed it on the next boot.
The routes only take mux controls from the crossbar, so the crossbar is
the dependency to declare here.

Declare MODULE_SOFTDEP("pre: mux-apple-display-crossbar"). mkinitcpio
adds soft dependencies to the image, and modprobe loads the crossbar
first. Soft dependencies are optional, so a kernel with the crossbar
built in or disabled is unaffected.

Signed-off-by: Jeppe Bylov <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 12c1012)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
The J516C runs the J516S panel, and its own 14.7 DCP image takes the same
level block in the swap (present byte +0x354, binary64 nits +0x35c, at most
500 nits): the e272b67 path presented brightness that way on this machine.
Set panel_nits on its board record and admit apple,j516c.

Generated-by: LLM
Signed-off-by: Samuel Carreño <[email protected]>
(cherry picked from commit a91ccf0)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
On a tree where an occupied display pipeline is reported as -ENOSPC on
every SoC, cd321x_display_taken() takes only the return code, and
-EBUSY means a transient mux or PHY failure. The probe controls still
call the two-argument form and no longer build there, and the
disconnect scenario injects -EBUSY as an occupied display, which such a
tree retries instead.

When the tree has the one-argument helper, check its contract in the
probe controls (-ENOSPC is taken; -EBUSY, -EAGAIN, -ETIMEDOUT, -EIO and
0 are not). In the disconnect scenario, let the mode stub classify its
error through the real helper, inject -ENOSPC as the occupied display,
and add a transient -EBUSY case that must retry before the USB role is
switched. A tree with the two-argument helper runs the old checks
unchanged.

The probe control also zero-initializes its cd321x_pm_state:
cd321x_pm_init() does not set setup_pending, which cd321x_pm_ready()
reads.

Signed-off-by: Chris Kearney <[email protected]>
Generated-by: LLM
[ryan: kept the desktop 26.6 connect stub of this tree beside the new block; on this tree cd321x_display_taken() still takes two arguments, so only the zero-initialised cd321x_pm_state takes effect]
(cherry picked from commit dbb6bcc)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
An external mode is set with the display powered down, and the display
is powered up after it. For a mode that needs DSC (3840x2160 at 100 and
120 Hz on the J514S HDMI and Type-C ports) the firmware refuses that mode
set ("Modeset done, but pipe not enabled") and resets DSC, and the
power-on only configures DSC: the timings start in a mode set the
firmware makes on its own, after a hotplug notification it sends itself.
A swap that reaches it before then is dropped ("swallowed swap ID 1 as
timings are not enabled") and never completed, so A407 times out after
5 s and the display stays dark until a reboot. A fresh attach lost that
race 3 times out of 3. Without DSC, the power-on starts the timings
itself.

Set the mode once more after the power-on, with the pipe enabled. The
firmware then starts the timings before that call returns, before the
first swap; its own mode set finds them running. KUnit cases check
the calls of an attach and of a mode change.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit 7ef3bc1)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A stereo audio link is held between streams so that the sink does not
mute it on a restart with the same format. The hold_link parameter
limited that to the HDMI port by default (hold_link=1) until the Type-C
ports had been tested with it; hold_link=2 extended it to them and 0
turned it off.

On the J514S, a TV on a Type-C port behaves as it does on the HDMI port:
without the hold, every stream starts a new link with an unchanged
format, the TV mutes it, and USB-C audio stays silent after the first
stream. With hold_link=2 it played across Chromium stop/start, pw-play
runs and a PipeWire restart, and held links survived 90 s idle and
sleep.

Hold the link on every port and drop the parameter. Nothing needs to
turn the hold off, and a parameter that only makes audio go silent is
not worth keeping. Streams of more than two channels still get a link
of their own, as before.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
(cherry picked from commit 653176d)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
avep_init() checks the DCP firmware before it looks in the device tree
for the audio device linked from port@0. With hdmi_audio set, every
processor that starts through the IOMFB template path gets there,
including the H17P ones of the J700, whose firmware has no audio service
here and whose device tree links no audio device: each logs "Audio not
supported for firmware" as an error and dcp_start() then warns that the
AV endpoint failed. Processors of the other firmware without an audio
device (the internal panels) allocate the audio service state for
nothing and log "No audio support".

Look for the audio device first and return quietly without one, leaving
the processor exactly as it is with hdmi_audio off: no audio service
state, no AV endpoint. Processors that link an audio device go on as
before.

This matters once DP/HDMI audio is on by default, which the next commit
does.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
DP/HDMI audio through the display coprocessor has been off unless
appledrm.hdmi_audio=1 was set, so a distribution that wants it has to
ship that option in a modprobe.d file.

Make it the default and keep the parameter as the way to turn it off:
appledrm.hdmi_audio=0 on the kernel command line, or
"options appledrm hdmi_audio=0" in modprobe.d before the driver loads.
The default applies to every machine the driver supports, M1 and M2
included.

Signed-off-by: Eryk Wieliczko <[email protected]>
Assisted-by: Claude:claude-opus-5-5
[ryan: the dcpext_probe and t6030_show_notch parameters of the conflicting context are not in this tree; the previous commit keeps processors without an audio device (the J700 H17P ones) quiet once this is on]
(cherry picked from commit c9e5b25)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
The J613 board record does not admit panel nits, so the working 14.7
display session never registers a backlight device. Admit the J613 to
the existing nits path and keep the firmware UUID and display handoff
checks. J615 and J514C remain excluded.

Run the existing swap-level KUnit case for J613 as well as T6030. Expose
the existing completion and refusal counters in debugfs so a requested
level can be distinguished from one the firmware accepted.

On a 13-inch M3 MacBook Air with 23J220 DCP firmware, the driver registered
apple-panel-bl and completed requests for 100, 250, 400, 1, 500 and 140
nits with no refusals or display failures. The user confirmed visible
brightness changes in person.

Assisted-by: OpenAI Codex (gpt-6.1-sol)
Signed-off-by: DjDeveloperr <[email protected]>
(cherry picked from commit eec6458)
Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
…rowth ledger

The PB ledger only knows the posted count. For backing that is
allocated after a reply instead of before it, the ledger also has to
know how many blocks are backed, grant a request only from those, and
start over at a re-initialization without forgetting the backing.

Add `backed` to the ledger. `accept()` now returns an answer:
- a grant, clipped to the backed blocks above the posted count;
- a refusal at the maximum (the refusal bound is unchanged);
- a wait when no backed block is left: the request keeps its
  counter and can be accepted again once more is backed.

`reinit()` returns the posted count to the initial size and keeps the
backing; Pools::init() uses it instead of a new ledger.

The growth chunks that back_pb() allocates before an answer are now
128 blocks (16 MiB) instead of 32. answer_request() copies the backed
count into the ledger after back_pb(), so no request waits yet.

Host tests (pools/growth.rs, run by the asahi-g15 selftest): the
clamps and the producer bound over the constructor's boundary values
with the heap backed, growth to the maximum and re-initialization, and
grants clipped to the backing, with waits that keep the counter.

The ledger is shared by the T6030 and the T6031; this is untested on
the T6030. The
growth harness follows the chunk size and the ledger reset.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Naeem Malik <[email protected]>
(cherry picked from commit 9414805)

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
mt_retire_connection() reads roam_moving with READ_ONCE() without
response_lock, to decide whether to keep the carrier, while the three
writers store it plainly under the lock. Use WRITE_ONCE() at the writes,
as roam_landed already does, and say in the header how both fields are
protected.

No change in behaviour.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A regulatory change that only relaxes the applied domain is kept from
the firmware while associated and applied when the connection ends,
because the pass would end the connection. A move to another AP broke
that in two ways.

The disconnect worker applies the deferral when it retires a connection,
including the old AP of a move. That sets reg_pending, so mt_rf_allowed()
fails at the admission check in mt_connect() and the move turns into a
disconnect. A relaxation that arrives during the move was not deferred
at all, since connected is false by then, and its pass cancelled the
join.

Treat a move like the connection it carries on. The disconnect worker
leaves a deferral alone while roam_moving is set, and the notifier
defers a relaxation while a move is under way. The deferral is applied
once the move has a result and has ended the connection, that is when
mt_connect() refuses to start it or when the connect worker reports
that it failed or was cancelled. A move that lands keeps the deferral
for the end of the new connection. A change that tightens the domain is
never deferred and still cancels a move, as it ends a connection.

The connect result harness compiles the worker report path, so give it
a stub for mt_reg_apply_deferred_locked().

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
When mt_connect() starts a move it marks roam_moving under
response_lock, drops the lock and then calls mt_disconnect(). Two things
can end the old connection in that window, and each led to a second
disconnect report.

An RF failure clears connected and reports the disconnect straight away,
because roam_moving only holds back the report in the disconnect worker.
mt_connect() then finds link_failed at its admission check and reports
the end of the move as well. cfg80211 does not guard against that, so
userspace saw two NL80211_CMD_DISCONNECT events and the keys were
deleted twice. Leave the report to mt_connect() while a move is marked.
It always reaches the admission check once roam_moving is set, and it
joins a connect worker that is still publishing before it reports, so
the order stays connect result then disconnect.

If the host starts stopping, mt_disconnect() returns early and leaves
connected set. mt_connect() reports the refused move, and mt_stop_host()
later reported the same connection's end again. Clear connected where
mt_connect() reports it.

Add a KUnit case for the RF failure at the start of a move, with and
without a worker still publishing.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
A connection that a move made reports its later disconnects as from the
AP. That is for iwd 3.12, whose netdev_reassociate() sets in_reassoc and
clears it only in netdev_associate_event(), for NL80211_CMD_ASSOCIATE.
cfg80211 never sends that for a driver that reports through
cfg80211_connect_done(), so the mark stays for the life of the
connection and iwd drops every local disconnect.

Write that down next to mt_report_disconnected(), together with its cost
(every nl80211 listener sees the changed flag, and wpa_supplicant treats
an AP disconnect differently) and when roam_landed can go.

No change in behaviour.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Which events the connect worker sends for an attempt decides whether
cfg80211, the supplicant and the firmware agree after a move. A move
that lands reports one connect result and takes over the connection. A
move that fails or is cancelled reports its failed connect result,
which iwd's reassociation waits for, and then a disconnect, because
cfg80211 keeps the replaced connection after a failed result. A
cancelled ordinary connect reports only the disconnect. Nothing uses
cfg80211_roamed().

Move that decision into mt7932_connect_report() and the from-AP choice
into mt7932_disconnect_local(), and report through them. The events
sent are the same as before. The worker's disconnects now all go
through mt_report_disconnected(), which keeps them local, since only a
landed move marks the connection and neither disconnect follows one.

Add an mt7932-move KUnit suite that checks the rules for ordinary
connects, moves that land, fail, are cancelled or are ended by a
regulatory pass, that every outcome reports something and at most one
disconnect, and the from-AP choice.

The connect result harness compiled the move state but never set it.
It now takes the helpers from mt7932.h and runs a landed, a failed and
a cancelled move through the real report path, checking the events,
the reasons, the carrier, roam_landed and that a deferred regulatory
pass is applied only when a move has ended the connection, plus a
cancelled ordinary connect and an ordinary connect after a move.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
The connect worker's comment said its cfg80211 calls are made after
response_lock is dropped. The connect_lost report already called
cfg80211_disconnected() under the lock, and the move support added the
same call in mt_connect() for a refused move. Say which reports happen
outside the lock and why, and that cfg80211_disconnected() with
GFP_ATOMIC is the one made under it.

Also note in mt_connect() that a move started during a scan waits for
the scan in mt_scan_quiesce(), about 7 s at most, and ends as a
disconnect if the scan is still running, after which iwd connects
again.

No change in behaviour.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
…otifier

The Neo stability test compiles mt_regulatory_notify() from startup.c
against its own model of struct mt7932. The notifier now also defers a
relaxation while a move to another AP is under way and reads
roam_moving, so the model no longer built and all nine runs of the test
failed.

Add roam_moving to the model, and check that a relaxation which arrives
while a move is under way, with connected already cleared, is deferred
like one that arrives while connected.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
This reverts commit 94ea410 (omacom c9e5b25).

On the M1 Pro regression boot of the combined up-port kernel, audio on by
default registers two apple_dcp DisplayPort cards on a headless machine
with nothing attached. They take card numbers 0 and 1, so the internal
macaudio card moves from card 1 to card 3, and alsa-lib logs four
"failed to import hw:N use case configuration" errors because there is no
UCM profile for the DCP cards. Baseline fleet14c logs none of this.

Keep DP/HDMI audio opt-in through appledrm.hdmi_audio=1 until the UCM
side exists and the held-link path has passed on the J616s and M2. The
rest of the audio series stays: it only acts once audio is enabled, and
the device tree check before the firmware check keeps the Neo quiet either
way.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
@RyanTheTide
RyanTheTide merged commit 49b58bc into aurora-wip Nov 1, 2026
@RyanTheTide
RyanTheTide deleted the omacom-sync/all branch November 1, 2026 14:10
notmysegv pushed a commit to notmysegv/linux that referenced this pull request Nov 4, 2026
…tion/aurora

Bring integration/aurora up to aurora-wip 52f0a6b, the source of
7.3.0-aurora-fleet14h, promoted on all four machines on 2026-11-02.
The range also covers the fleet14g source b35adc7. It adds aurora-silicon#792,
aurora-silicon#750, aurora-silicon#783, aurora-silicon#784, aurora-silicon#793, aurora-silicon#774, aurora-silicon#794, aurora-silicon#796, aurora-silicon#798, aurora-silicon#800, aurora-silicon#802 and aurora-silicon#801.
No conflicts.

Assisted-by: LLM
Signed-off-by: Ryan Murray <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.