usb: typec: hd3ss3220: Fix VBUS regulator reference handling - #972
Conversation
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
1 similar comment
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
|
Dmitry Baryshkov (@lumag) yijiyang jingyiwang42 The VBUS regulator warning was observed in the log attached to #472, but it is This PR only fixes the independent Could you please advise the appropriate CR to reference for this fix, or the |
3a1bdcc to
1186be0
Compare
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
2 similar comments
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
1186be0 to
12aa1d7
Compare
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
1 similar comment
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
12aa1d7 to
c6512aa
Compare
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
PR #972 — validate-patchPR: #972
Final Summary
|
PR #972 — checker-log-analyzerPR: #972
Detailed report: Full report
|
c6512aa to
4aeb258
Compare
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
|
Note: the qlijarvis reports above were generated before the latest force-push and refer to the old commits. The current PR head is |
PR #972 — validate-patchPR: #972
Final Summary
|
PR #972 — checker-log-analyzerPR: #972
Detailed report: Full report
|
PR #972 — validate-patchPR: #972
Final Summary
|
PR #972 — checker-log-analyzerPR: #972
Detailed report: Full report
|
PR #972 — validate-patchPR: #972
Final Summary
|
PR #972 — checker-log-analyzerPR: #972
Detailed report: Full report
|
4aeb258 to
c9fd758
Compare
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
|
Upstream status update: The second patch has been accepted into Greg Kroah-Hartman's I updated its prefix from The remaining CR-number check requires maintainer guidance because I am an |
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
c9fd758 to
661cbcc
Compare
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
hd3ss3220_regulator_control() enables the VBUS regulator when @on is true and disables it when @on is false. However, its error message uses the opposite operation name, so an enable failure is reported as a disable failure and vice versa. Print the operation that was actually attempted. Reporting the opposite regulator operation on failures can mislead debugging of VBUS problems. Fixes: 09fa276 ("FROMLIST: usb: typec: hd3ss3220: Enable VBUS based on role state") Cc: stable@vger.kernel.org Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Signed-off-by: Xu Rao <raoxu@uniontech.com> Link: https://lore.kernel.org/r/7A42A287B2B588D0+20260812094632.348581-1-raoxu@uniontech.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
regulator_is_enabled() reports the aggregate regulator state, not whether this consumer holds an enable reference. If another consumer enables VBUS first, the driver can skip its own regulator_enable() call and later attempt to drop a reference it never acquired, triggering an unbalanced regulator disable warning. Track successful enable and disable calls locally. Keep the state unchanged when an operation fails so a later role or ID notification retries the operation while this consumer keeps balanced references. Fixes: 09fa276 ("FROMLIST: usb: typec: hd3ss3220: Enable VBUS based on role state") Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20260819152027.90994-1-kunjinkao.jp@gmail.com Signed-off-by: Chang Wu <kunjinkao.jp@gmail.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Tested-by: Jan Remmet <j.remmet@phytec.de> Reviewed-by: Krishna Kurapati <krishna.kurapati@oss.qualcomm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
661cbcc to
217c696
Compare
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
|
Updated the commits and retriggered CI. |
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
1 similar comment
|
Merge Check Failed: No CR Numbers Found Error: No Change Request numbers were found. Please add Change Request numbers to your pull request description in the format CRs-Fixed: 12345 or link GitHub issues that are associated with Change Requests. |
Test Matrix
|
LAVA Failed Case Triage SummaryPR: #972 Job 228521 | SoC hamoa-evkLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228521 Failed test cases in LAVA job 228521 (SoC: hamoa-evk).
Job 228522 | SoC qcs9100-rideLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228522 Failed test cases in LAVA job 228522 (SoC: qcs9100-ride).
Job 228523 | SoC qcs6490-rb3gen2LAVA job: https://lava-oss.qualcomm.com/scheduler/job/228523 Failed test cases in LAVA job 228523 (SoC: qcs6490-rb3gen2).
Job 228524 | SoC qcs615-rideLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228524 Failed test cases in LAVA job 228524 (SoC: qcs615-ride).
Job 228525 | SoC purwa-evkLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228525 Failed test cases in LAVA job 228525 (SoC: purwa-evk).
Job 228526 | SoC shikra-iqs-evkLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228526 Failed test cases in LAVA job 228526 (SoC: shikra-iqs-evk).
Job 228527 | SoC lemans-evkLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228527 Failed test cases in LAVA job 228527 (SoC: lemans-evk).
Job 228528 | SoC monaco-evkLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228528 Failed test cases in LAVA job 228528 (SoC: monaco-evk).
Job 228529 | SoC qcs8300-rideLAVA job: https://lava-oss.qualcomm.com/scheduler/job/228529 Failed test cases in LAVA job 228529 (SoC: qcs8300-ride).
|
Test Matrix
|
|
Kriskura176767 please take care of CR, i am proceeding to merge this change |
|
Merge Check Failed: CR Not Eligible for Merge CR 4676785 is not eligible for merge. The parent software image for kernel.qli.2.0 is not development complete. Entity: Please ensure the CR passes both CCT (ComponentChangeTasks) and ICT (Integration Change Tasks) validations. |
923a0c5
into
qualcomm-linux:qcom-6.18.y
|
Dev Completion validation failed CR: 4676785 The change task for this CR could not be moved to Dev Complete because of the error above. Please resolve the issue in Orbit and re-run the failed Orbit check. |
The HD3SS3220 driver uses regulator_is_enabled() to determine whether VBUS
needs to be enabled or disabled. However, regulator_is_enabled() reports the
aggregate regulator state and does not indicate whether this consumer holds
an enable reference.
If another consumer enables VBUS first, the driver may skip its own
regulator_enable() call and later issue an unbalanced regulator_disable()
call.
Track the VBUS enable state locally so that regulator enable and disable
references remain balanced for this consumer. Update the state only after a
successful regulator operation.
This PR contains two upstream commits:
https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git/commit/?id=c9a48db776d7184981630ecc01a3ad30a8f7dc24
https://lore.kernel.org/r/20260819152027.90994-1-kunjinkao.jp@gmail.com
Fixes: 09fa276 ("FROMLIST: usb: typec: hd3ss3220: Enable VBUS based on role state")
Testing:
I am an external contributor and do not have access to Qualcomm's internal
CR system. Maintainer guidance on the appropriate CR association would be
appreciated.
CRs-Fixed: 4676785