Repository navigation
usb: typec: tipd: sn201202x: skip liquid detection where the port has none - #1685
Merged
Merged
Conversation
The MagSafe 3 port's PD controller has no liquid detection and
corrosion mitigation (LDCM). The ADT lists its features as <3>
("Power In"), where the USB-C ports' controllers have <1 2 3>
("TRM", "LDCM", "Power In"). Describe that with a boolean property.
Signed-off-by: Diljit Singh <[email protected]>
… none Every SN201202x gets the LDCM liquid-detection and mitigation commands, including the MagSafe 3 port's controller, which has no such feature: macOS enables only "Power In" on that port. Install the contaminant ops only for a controller without apple,no-liquid-detection, and make an LDCM update a no-op without them, so the probe, sleep and resume paths send such a controller no LDCM command. Controllers without the property, every USB-C port's, are unchanged. Signed-off-by: Diljit Singh <[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.
Every SN201202x (ACE3) controller gets tipd's LDCM liquid-detection and mitigation commands: an
LDCMcommand at probe, and again around system sleep. That includes the MagSafe 3 port's controller, which has no such feature.features-supported = <1 2 3>for the USB-C ports' controllers (hpm0, hpm1, hpm2) and<3>for the MagSafe controller (hpm5).This adds a boolean
apple,no-liquid-detectionto the binding. The driver then:LDCMcommand;contaminantattribute.No in-tree DT sets the property yet, so nothing changes on any board until a board marks a controller. The J714s MagSafe node that uses it is the stacked PR.
Tested on the M5 Pro (J714s), 7.3.0-m5-intg4
This build of
sn201202x.ko(only this change on intg4's tipd) was installed inupdates/over SSH, then removed afterwards. The stock module and its module index were checked back.1-0ahpm1,2-0chpm2) bind and keep theircontaminantattribute (none), as with the stock module.apple,no-liquid-detection):1-08binds. Its Type-C port is a USB PD sink with nocontaminantattribute, and its power supply is online.contaminant: none.🤖 Generated with Claude Code