mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/
synced 2026-04-17 22:23:45 -04:00
This reverts commit 557a28811c.
This commit introduced an init sequence from downstream DT [1] in the
driver. As mentioned by the comment above the HSPHY_INIT_CFG macro for
this sequence:
/*
* The macro is used to define an initialization sequence. Each tuple
* is meant to program 'value' into phy register at 'offset' with 'delay'
* in us followed.
*/
Instead of corresponding to offsets into the phy register, the sequence
read by the downstream driver [2] is passed into ulpi_write [3] which
crafts the address-value pair into a new value and writes it into the
same register at USB_ULPI_VIEWPORT [4]. In other words, this init
sequence is programmed into the hardware in a totally different way than
downstream and is unlikely to achieve the desired result, if the hsphy
is working at all.
An alternative method needs to be found to write these init values at
the desired location. Fortunately mdm9607 did not land upstream yet [5]
and should have its compatible revised to use the generic one, instead
of a compatible that writes wrong data to the wrong registers.
[1]: https://android.googlesource.com/kernel/msm/+/android-7.1.0_r0.2/arch/arm/boot/dts/qcom/mdm9607.dtsi#585
[2]: https://android.googlesource.com/kernel/msm/+/android-7.1.0_r0.2/drivers/usb/phy/phy-msm-usb.c#4183
[3]: https://android.googlesource.com/kernel/msm/+/android-7.1.0_r0.2/drivers/usb/phy/phy-msm-usb.c#468
[4]: https://android.googlesource.com/kernel/msm/+/android-7.1.0_r0.2/drivers/usb/phy/phy-msm-usb.c#418
[5]: https://lore.kernel.org/linux-arm-msm/20210805222812.40731-1-konrad.dybcio@somainline.org/
Reported-by: Michael Srba <Michael.Srba@seznam.cz>
Signed-off-by: Marijn Suijten <marijn.suijten@somainline.org>
Reviewed-by: Stephan Gerhold <stephan@gerhold.net>
Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Link: https://lore.kernel.org/r/20221214223733.648167-1-marijn.suijten@somainline.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>
91 lines
2.0 KiB
YAML
91 lines
2.0 KiB
YAML
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
|
|
%YAML 1.2
|
|
---
|
|
$id: "http://devicetree.org/schemas/phy/qcom,usb-hs-28nm.yaml#"
|
|
$schema: "http://devicetree.org/meta-schemas/core.yaml#"
|
|
|
|
title: Qualcomm Synopsys DesignWare Core 28nm High-Speed PHY
|
|
|
|
maintainers:
|
|
- Bryan O'Donoghue <bryan.odonoghue@linaro.org>
|
|
|
|
description: |
|
|
Qualcomm Low-Speed, Full-Speed, Hi-Speed 28nm USB PHY
|
|
|
|
properties:
|
|
compatible:
|
|
enum:
|
|
- qcom,usb-hs-28nm-femtophy
|
|
|
|
reg:
|
|
maxItems: 1
|
|
|
|
"#phy-cells":
|
|
const: 0
|
|
|
|
clocks:
|
|
items:
|
|
- description: rpmcc ref clock
|
|
- description: PHY AHB clock
|
|
- description: Rentention clock
|
|
|
|
clock-names:
|
|
items:
|
|
- const: ref
|
|
- const: ahb
|
|
- const: sleep
|
|
|
|
resets:
|
|
items:
|
|
- description: PHY core reset
|
|
- description: POR reset
|
|
|
|
reset-names:
|
|
items:
|
|
- const: phy
|
|
- const: por
|
|
|
|
vdd-supply:
|
|
description: phandle to the regulator VDD supply node.
|
|
|
|
vdda1p8-supply:
|
|
description: phandle to the regulator 1.8V supply node.
|
|
|
|
vdda3p3-supply:
|
|
description: phandle to the regulator 3.3V supply node.
|
|
|
|
required:
|
|
- compatible
|
|
- reg
|
|
- "#phy-cells"
|
|
- clocks
|
|
- clock-names
|
|
- resets
|
|
- reset-names
|
|
- vdd-supply
|
|
- vdda1p8-supply
|
|
- vdda3p3-supply
|
|
|
|
additionalProperties: false
|
|
|
|
examples:
|
|
- |
|
|
#include <dt-bindings/clock/qcom,gcc-qcs404.h>
|
|
#include <dt-bindings/clock/qcom,rpmcc.h>
|
|
usb2_phy_prim: phy@7a000 {
|
|
compatible = "qcom,usb-hs-28nm-femtophy";
|
|
reg = <0x0007a000 0x200>;
|
|
#phy-cells = <0>;
|
|
clocks = <&rpmcc RPM_SMD_LN_BB_CLK>,
|
|
<&gcc GCC_USB_HS_PHY_CFG_AHB_CLK>,
|
|
<&gcc GCC_USB2A_PHY_SLEEP_CLK>;
|
|
clock-names = "ref", "ahb", "sleep";
|
|
resets = <&gcc GCC_USB_HS_PHY_CFG_AHB_BCR>,
|
|
<&gcc GCC_USB2A_PHY_BCR>;
|
|
reset-names = "phy", "por";
|
|
vdd-supply = <&vreg_l4_1p2>;
|
|
vdda1p8-supply = <&vreg_l5_1p8>;
|
|
vdda3p3-supply = <&vreg_l12_3p3>;
|
|
};
|
|
...
|