Update EUD series to v4#1142
Conversation
shashim-quic
left a comment
There was a problem hiding this comment.
Revert "FROMLIST: arm64: dts: qcom: Map USB connector to EUD for kodiak boards"
This reverts commit 8c7f91d.
Mention why in commit log as well so it is clear from git log history. In your case it is for revsiing with latest version.
…ak boards" This reverts commit 8c7f91d. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
…nnection" This reverts commit 53c87be. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
This reverts commit 84bffcd. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
This reverts commit edf1452. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
…t handling" This reverts commit cbc24a4. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
This reverts commit a43abda. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
This reverts commit 0987b89. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
…ntrol" This reverts commit 5f52379. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
…election" This reverts commit 5c70d70. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
…ort configuration" This reverts commit 94d8ce6. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
…andle" This reverts commit e8d6ecf. Revert EUD v3 changes to align with the EUD v4 patch series posted upstream. Signed-off-by: Elson Roy Serrao <elson.serrao@oss.qualcomm.com>
…TMI routing The Qualcomm Embedded USB Debugger (EUD) can intercept one or two independent High-Speed UTMI paths, depending on the SoC configuration. Each path is distinct, with its own connector/controller connection and role-dependent UTMI routing. Because the EUD sits between the USB connector and the USB controller, it must relay role changes across the UTMI path. In device role, the EUD inserts its internal hub into the path to enable debug functionality. In host role, the path remains directly connected between the PHY and the USB controller, bypassing the EUD hub. These hardware constraints require per-path role awareness, as UTMI path roles may differ. The existing binding models only a single UTMI path and assumes a uniform routing model. While sufficient for simple device-role-only configurations, this representation does not accurately describe EUD hardware when role switching and/or multiple UTMI paths are involved. To address this limitation, per-path child nodes are introduced to describe individual UTMI paths through the EUD. Each path includes its own ports description, allowing controller and connector associations, as well as role-aware routing. Link: https://lore.kernel.org/all/20260501170635.2641748-2-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com>
EUD can be mapped to either the primary USB port or the secondary USB port depending on the value of the EUD_PORT_SEL register. Add a 'port' sysfs attribute to allow userspace to select which port EUD should operate on and update the ABI documentation. This is needed for systems with dual USB ports where EUD needs to be accessible on either port depending on the system configuration and use case. Link: https://lore.kernel.org/all/20260501170635.2641748-3-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com>
EUD hardware can support multiple High-Speed USB paths, each routed through its own PHY. The active path is selected in hardware via the EUD_PORT_SEL register. As a High-Speed hub, EUD requires access to the High-Speed PHY associated with the active path. To support this multi-path capability, the driver must manage PHY resources on a per-path basis, ensuring that the PHY for the currently selected path is properly initialized and powered. This patch restructures the driver to implement per-path PHY management. The driver now powers the appropriate PHY based on the selected and enabled UTMI path, ensuring correct operation when EUD is enabled. Historically, EUD appeared to work on single-path systems because the USB controller kept the PHY initialized. However, EUD is designed to operate independently of the USB controller and therefore requires explicit PHY control for proper operation. Link: https://lore.kernel.org/all/20260501170635.2641748-4-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com>
The EUD hardware can support multiple High-Speed USB paths, each connected to different USB controllers. The current implementation uses a single chip-level role switch, which cannot properly handle multi-path configurations where each path needs independent role management. Since EUD is physically present between the USB connector and the controller, it should also relay the role change requests from the connector. Restructure the driver to support per-path role switches and remove the chip-level role switch. Additionally, as EUD need not modify the USB role upon enabling, remove the unnecessary role switch call from enable_eud(). Link: https://lore.kernel.org/all/20260501170635.2641748-5-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com>
Currently enable_store() allows operations irrespective of the EUD state, which can result in redundant operations. Avoid this by adding duplicate state checks to skip requests when EUD is already in the desired state. Additionally, improve error handling with explicit logging to provide better feedback. Link: https://lore.kernel.org/all/20260501170635.2641748-6-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com> Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
EUD functions by presenting itself as a USB device to the host PC for debugging, making it incompatible with USB host mode configurations. Enabling EUD while in host mode can also cause the USB controller to misbehave, as the EUD hub supports only a single upstream-facing port. Handle the following scenarios to prevent these conflicts: 1. Prevent the user from enabling EUD via sysfs when the USB port is in host mode. 2. Automatically disable EUD when the USB port switches to host mode, and re-enable it when exiting host mode. This ensures consistent state management without creating conflicts between the EUD debug hub and the USB controller. Link: https://lore.kernel.org/all/20260501170635.2641748-7-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com>
EUD provides virtual USB attach/detach events to simulate cable plug/unplug while maintaining the physical debug connection. However, the current implementation incorrectly sets the USB role to HOST on virtual detach, which doesn't represent the disconnected state. Fix the virtual detach handling by setting the USB role to NONE instead of HOST, correctly representing the disconnected state. Link: https://lore.kernel.org/all/20260501170635.2641748-8-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com> Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
…d node The existing EUD description uses a legacy single-path representation that assumes uniform UTMI routing. This was sufficient for minimal configurations where the USB port operated only in device mode and role switching was not considered. Update the description to explicitly model the topology using eud path child node and add a role-switch declaration to reflect role-dependent UTMI routing. Also on this SoC, the EUD hardware intercepts only the primary UTMI path. So remove the USB endpoint mapping to the secondary controller and associate it with the primary controller. With the UTMI path now accurately described, enable the EUD by default. The connector side of the path is left unspecified, allowing board-level DTS files to describe the physical connector mapping. Link: https://lore.kernel.org/all/20260501170635.2641748-9-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com>
On Kodiak-based boards, the primary USB connector is connected through the EUD on the High-Speed path. Update the board-level descriptions to map the USB connector endpoint to EUD, reflecting the intended hardware topology. Link: https://lore.kernel.org/all/20260501170635.2641748-10-elson.serrao@oss.qualcomm.com/ Signed-off-by: Elson Serrao <elson.serrao@oss.qualcomm.com>
426ffb8 to
5fc0400
Compare
Done |
PR #1142 — validate-patchPR: #1142
|
PR #1142 — checker-log-analyzerPR: #1142
Detailed report: Full report
|
Update EUD series to v4 and revert v3 changes.
Link to v4: https://lore.kernel.org/all/20260501170635.2641748-1-elson.serrao@oss.qualcomm.com/