Repository navigation
selftests: apple-dcp: Follow the tipd lost-IRQ recovery helpers - #341
Merged
Merged
Conversation
The host runner fails 5 of 55 cases since the tipd lost-IRQ recovery because the typec-probe, probe-mux-pm-dispatch, physical-disconnect, fast-replug-bounce and dropped-swap-teardown units no longer compile. They inline cd321x-pm.h, which now includes <linux/minmax.h> for the acknowledgment retry backoff, and the probe units do not extract the new cd321x_init_work() called by cd321x_register_port(). Inline the header through one shared helper that provides a host clamp() in place of minmax.h, and extract the actual cd321x_init_work() for both probe units. Check in typec-probe that a lost event reopens even a stale port with a full budget, that a failed acknowledgment keeps the budget with a backoff capped at CD321X_ACK_RETRY_MAX_MS, and that sleep and removal leave lost events to the resume read. The dispatch unit drops these helpers like the other ones it does not exercise. Retain the strict compiler and sanitizer settings and all 55 runner cases. The full buildbox run improves from 50 pass / 5 fail to 55 pass / 0 fail. No production driver changes are needed. Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
RyanTheTide
added a commit
that referenced
this pull request
Oct 17, 2026
Bring the 7.2.10 assembly to the tree of the canonical top-up #5 assembly 1c824ed, stacked on top-up #4 5043778 so that it is a fast-forward of the published branch. The second parent is that canonical assembly; the tree is identical to it. Ported from aurora-wip, each with cherry-pick -x and its original author: - #338 tipd lost IRQ (5): never leave CD321x interrupt events unacknowledged, recover from a failed partner identity read, keep SN201202x events unhandled while it sleeps and wake it when suspend fails, and the KUnit race fix of the IRQ test (170-usb). - #339 Touch ID verify retry (2): say why the sensor status after registration was unusable, and retry a failed sensor bring-up before a verify (100-sep). - #340 USB and Bluetooth wake v4.1 (30): AIC wake (010-soc); xHCI, DWC3 and hub suspend-to-idle wake with their KUnit tests (170-usb); MT7932 Bluetooth wake and MSI wake for Apple PCIe (080-radio); the apple-dcp DWC3 wake model (200-dcp); the tools/aurora-wake regression tools (900-config-tooling). - #341 apple-dcp selftests for the tipd lost-IRQ helpers (200-dcp). - batch1 backlog: rust-clippy (4; 070-audio, 210-gpu), boot-warnings (3; 200-dcp), and the 4 harden-all commits not yet carried (010-soc qspi resume, 070-audio AOP wrapped-entry test, 200-dcp start completion). kunit-parsers, spi-apple-cs and the other 34 harden-all commits were already in the topics, including the AOP ring fix that top-up #4 brought; it is not duplicated. Not ported: 3132675, superseded on 7.2.10 by b69728b ("selftests: apple-dcp: Follow the 7.2.10 driver boundaries"). Adaptations, each with a [ryan: ...] note in its commit: - the new tipd KUnit tests take the CD321x and SN201202x data from the exported tipd_hw_variants[] table of 7.2.10; - the #341 lifecycle.py import also keeps ATC_POST_TUNABLE; - drm/asahi statistics style without the driver.rs part, which 7.2.10 already has; - the Rust doc example refresh only for KVec and Drain: iosys_map.rs, the old IoMem example and declare_flags_type!() are gone in 7.2.10; - "Do not arm the core interrupt for wakeup" split between 170-usb and 200-dcp. New: 11e0ce6 ("usb: typec: tipd: cd321x: Don't race the resume read in the sleep retry test"). Assisted-by: LLM Signed-off-by: Ryan Murray <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The tipd lost-IRQ fix (#338) left the apple-dcp host selftests at 50/55 on aurora-wip. Five units no longer compile on the host:
typec-probe,probe-mux-pm-dispatch,physical-disconnect,fast-replug-bounceanddropped-swap-teardown;cd321x-pm.h, which now includes<linux/minmax.h>;cd321x_init_work().This is one selftest-only commit:
clamp()in place ofminmax.h.cd321x_init_work()is extracted for both probe units.typec-probegains checks for usb: typec: tipd: keep a CD321x/SN201202x port from going deaf after s2idle (lost event IRQ) #338's behaviour:CD321X_ACK_RETRY_MAX_MS;Testing
b659856eb659856e+ this commitb659856e+ #340 (USB/BT wake), without this commit2fa9722c+ this commit-Wall -Werrorand ASan/UBSan are unchanged.drivers/tree is identical at base and head.git diff --checkis clean, andcheckpatch --strictgives 0 errors.run.pyruns on the merged tree as a merge gate for changes to tipd, atc, dwc3, drm/apple or AFK.🤖 Generated with Claude Code