phy: qcom: qmp-combo: keep the Type-C callbacks off unclocked registers
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest2 patches 4 repliesIn review
- v22 patches 0 repliesSuperseded
- v11 patch 1 replySuperseded
Changes in v3 from the cover letter
- Patch 2: on a failed bringup restore the previously cached mode and clear the cached orientation, so the next Type-C event retries instead of being short-circuited as already configured (Sashiko review on v2). The commit message now also says plainly that a consumer's later phy_power_off() still reaches an unclocked PHY until that retry; that is pre-existing and not addressed by this series.
- Patch 1: unchanged.
- Link to v2: https://lore.kernel.org/all/[email protected]/
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | phy: qcom: qmp-combo: hold a runtime PM reference in the typec callbacksdrivers/ | +5 | 1 reply | |
| 2/2 | phy: qcom: qmp-combo: check qmp_combo_com_init() in the typec callbacksdrivers/ | +15 | 3 replies |
Reviews trailers per patch
1 of 2 patches has a Reviewed-by or Acked-by.
| Patch | Konrad Dybcio |
|---|---|
| 1/2 | R-b |
| 2/2 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v3 0/2] phy: qcom: qmp-combo: keep the Type-C callbacks off unclocked registers
The typec_switch and typec_mux callbacks of the QMP combo PHY tear the common block down and bring it back up with force=true on every USB-C orientation or altmode change. Two things go wrong on that path.
Patch 1: the callbacks hold no runtime PM reference, so releasing the clocks during the teardown can drop the device's last reference and re-enter qmp_combo_runtime_suspend() from clk_core_unprepare(), which then disables clocks that are already being torn down. Seen as "gcc_usb3_prim_phy_pipe_clk already disabled" warnings from the pmic_glink_altmode_worker on a Lenovo Yoga Slim 7x Gen 11 (Snapdragon X2 Elite) once runtime PM is allowed from userspace.
Patch 2: the result of the forced qmp_combo_com_init() is discarded, so a failed bringup is followed by register writes with the clocks off. Found by inspection; it needs the bringup to fail.
Tested on next-20260915 on the Yoga Slim 7x Gen 11 with a USB-C DisplayPort
display: plug, unplug and orientation changes, no clock warnings.
Changes in v3:
- Patch 2: on a failed bringup restore the previously cached mode and clear the cached orientation, so the next Type-C event retries instead of being short-circuited as already configured (Sashiko review on v2). The commit message now also says plainly that a consumer's later phy_power_off() still reaches an unclocked PHY until that retry; that is pre-existing and not addressed by this series.
- Patch 1: unchanged.
- Link to v2: https://lore.kernel.org/all/[email protected]/
Changes in v2:
- Rebased on next-20260915, where "phy: qualcomm: qmp-combo: Add
preliminary USB4 support" moved the mux callback's teardown and bringup into qmp_combo_reconfigure_phy(). The runtime PM reference is now
taken in both callbacks before that helper runs; the com_init() check moved into the helper, so qmp_combo_usb4_init(), which already checks
the helper's return value, sees the failure too.
- Both patches carry a Fixes: tag for the commit that introduced the
forced re-init path.
- Link to patch 1 v1: https://lore.kernel.org/all/[email protected]/
- Link to patch 2 v1: https://lore.kernel.org/all/[email protected]/
Oleg Keri (2):
phy: qcom: qmp-combo: hold a runtime PM reference in the typec
callbacks
phy: qcom: qmp-combo: check qmp_combo_com_init() in the typec
callbacks
drivers/phy/qualcomm/phy-qcom-qmp-combo.c | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-)
Signature · 8 lines
2.55.0 base-commit: a7728f5e1fc3d472a314acdabca6039f71ec3a9d -- linux-phy mailing list [email protected] https://lists.infradead.org/mailman/listinfo/linux-phy