arm64: dts: qcom: sdm845-cheza: Add cr50 spi node
PATCH 1/1 arm64: dts: qcom: sdm845-cheza: Add cr50 spi node
Add the cr50 device to the spi controller it is attached to. This enables /dev/tpm0 and some login things on Cheza.
--- arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi | 14 ++++++++++++++ 1 file changed, 14 insertions(+)
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi +14 -0
@@ -651,6 +651,20 @@ &spi0 { status = "okay"; }; +&spi5 { + status = "okay"; + + cr50@0 { + compatible = "google,cr50"; + reg = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&h1_ap_int_odl>; + spi-max-frequency = <800000>; + interrupt-parent = <&tlmm>; + interrupts = <129 IRQ_TYPE_EDGE_RISING>; + }; +}; + &spi10 { status = "okay";
Signature · 1 line
Sent by a computer, using git, on the internet
Hi,
Quoted 15 lines · Stephen Boyd
Add the cr50 device to the spi controller it is attached to. This enables
/dev/tpm0and some login things on Cheza.Cc Douglas Anderson <[email protected]>Signed-off-by Stephen Boyd <[email protected]>--- arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi | 14 ++++++++++++++ 1 file changed, 14 insertions(+)arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi +0
-0
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi &spi0 { · line 657
Quoted 7 lines
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi +4
-0@@ -651,6 +651,20 @@ &spi0 { status = "okay"; }; +&spi5 { + status = "okay"; + + cr50@0 {
Between v2 and v3 of your upstream bindings you changed this from "cr50@0" to "tpm@0" in the example. I'm going to assume you did that for some reason and you should be matching the binding example here. ...or you should change the binding example to be cr50@.
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi &spi0 { · line 664
Quoted 7 lines
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi +7
-0+ compatible = "google,cr50"; + reg = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&h1_ap_int_odl>; + spi-max-frequency = <800000>; + interrupt-parent = <&tlmm>; + interrupts = <129 IRQ_TYPE_EDGE_RISING>;
Certainly we need an interrupt, but I don't see it in the bindings. Any idea why it isn't there?
-Doug
Quoting Doug Anderson (2019-12-16 14:53:22)
Quoted 21 lines
Hi,
Quoted 18 lines · Stephen Boyd
Add the cr50 device to the spi controller it is attached to. This enables
/dev/tpm0and some login things on Cheza.Cc Douglas Anderson <[email protected]>Signed-off-by Stephen Boyd <[email protected]>--- arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi | 14 ++++++++++++++ 1 file changed, 14 insertions(+)arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi +0
-0@@ -651,6 +651,20 @@ &spi0 { status = "okay"; };
Quoted 10 lines
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi &spi0 { · line 657
Quoted 4 lines
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi +4
-0+&spi5 { + status = "okay"; + + cr50@0 {Between v2 and v3 of your upstream bindings you changed this from "cr50@0" to "tpm@0" in the example. I'm going to assume you did that for some reason and you should be matching the binding example here. ...or you should change the binding example to be cr50@.
Oh yeha, will fix and resend.
Quoted 9 lines
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi &spi0 { · line 664
Quoted 8 lines
arch/arm64/boot/dts/qcom/sdm845-cheza.dtsi +7
-0+ compatible = "google,cr50"; + reg = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&h1_ap_int_odl>; + spi-max-frequency = <800000>; + interrupt-parent = <&tlmm>; + interrupts = <129 IRQ_TYPE_EDGE_RISING>;
Quoted 3 lines
Certainly we need an interrupt, but I don't see it in the bindings. Any idea why it isn't there?
I just forward ported the binding and didn't look back. I'm converting it to YAML so I'll roll that fix in. Thanks.