Re: [PATCH v4 12/18] usb: typec: qcom: Add Qualcomm PMIC TCPM support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 23/03/2023 14:36, Jianhua Lu wrote:
+	/* Poll waiting for transition to required vSafe5V or vSafe0V */
+	ret = regmap_read_poll_timeout(pmic_typec->regmap,
+				       pmic_typec->base + TYPEC_SM_STATUS_REG,
+				       sm_stat, sm_stat & val,
+				       100, 250000);
This statement isn't very useful and will case a error,
After I remove it, usb-c works well. What's about dropping this statement?

[   63.030672] xhci-hcd xhci-hcd.1.auto: xHCI Host Controller
[   63.030702] xhci-hcd xhci-hcd.1.auto: new USB bus registered, assigned bus number 1
[   63.030895] xhci-hcd xhci-hcd.1.auto: hcc params 0x0230ffe5 hci version 0x110 quirks 0x0000000000010010
[   63.030926] xhci-hcd xhci-hcd.1.auto: irq 168, io mem 0x0a600000
[   63.031043] xhci-hcd xhci-hcd.1.auto: xHCI Host Controller
[   63.031054] xhci-hcd xhci-hcd.1.auto: new USB bus registered, assigned bus number 2
[   63.031063] xhci-hcd xhci-hcd.1.auto: Host supports USB 3.1 Enhanced SuperSpeed
[   63.031835] hub 1-0:1.0: USB hub found
[   63.031863] hub 1-0:1.0: 1 port detected
[   63.032151] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[   63.032690] hub 2-0:1.0: USB hub found
[   63.032713] hub 2-0:1.0: 1 port detected
[   63.168912] qcom,pmic-typec c440000.spmi:pmic@2:typec@1500: vbus vsafe5v fail
[   63.169185] xhci-hcd xhci-hcd.1.auto: remove, state 1
[   63.169195] usb usb2: USB disconnect, device number 1
[   63.178808] xhci-hcd xhci-hcd.1.auto: USB bus 2 deregistered
[   63.178825] xhci-hcd xhci-hcd.1.auto: remove, state 1
[   63.178832] usb usb1: USB disconnect, device number 1
[   63.182114] hub 1-0:1.0: activate --> -19
[   63.182791] xhci-hcd xhci-hcd.1.auto: USB bus 1 deregistered

Interesting.

What's your hardware configuration ? Could it be you don't have the VBUS regulator pointed to the correct place ?

&pm8150b_vbus {
	regulator-min-microamp = <500000>;
	regulator-max-microamp = <3000000>;
	status = "okay";
};

&pm8150b_typec {
	vdd-vbus-supply = <&pm8150b_vbus>;
};

i.e. something else on your board supplies VBUS ?

vSafe5V should indicate to the controller that you have successfully switched on vBus, so what this indicates to me is that on your hardware VBUS either hasn't been asserted or hasn't been detected.

Can you show the printout of *(pmic_typec->base + TYPEC_SM_STATUS_REG) ? And can you check your schematics and verify VBUS is supplied by pm8150b_vbus and not say by an external IC ?

---
bod



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux