ARM: socfpga: Set reset-names property for &mmc
PATCH 1/1 ARM: socfpga: Set reset-names property for &mmc
Since commit 90bdf1e5d1e4 ("mci: dw_mmc: match against StarFive MMC compatibles"), the dw_mmc driver requires a reset line called "reset". The slightly earlier commit a3cf324593ea ("mci: dw_mmc: add optional reset line") introduced the reset line support, but made it optional.
The device tree node for SoCFPGA's MMC device has the "resets" property, but is missing the "reset-names" property, so MMC no longer works. Barebox produces the error message:
ERROR: dw_mmc [email protected]: probe failed: Invalid argument
Add the missing "reset-names" property to the "&mmc" node in "arch/arm/dts/socfpga.dtsi". It probably needs fixing in the upstream Linux device tree sources too!
--- arch/arm/dts/socfpga.dtsi | 4 ++++ 1 file changed, 4 insertions(+)
arch/arm/dts/socfpga.dtsi +4 -0
@@ -4,6 +4,10 @@ }; }; +&mmc { + reset-names = "reset"; +}; + &watchdog0 { resets = <&rst L4WD0_RESET>; };
Signature · 7 lines
2.33.0 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Hello Ian,
Quoted 4 lines · Ian Abbott
Since commit
90bdf1e5d1e4("mci:dw_mmc: match against StarFive MMC compatibles"), thedw_mmcdriver requires a reset line called "reset". The slightly earlier commita3cf324593ea("mci:dw_mmc: add optional reset line") introduced the reset line support, but made it optional.
Ouch. That doesn't look intended. Perhaps it's an artifact of a rebase. :/ I've sent out a partial revert. We can still apply this patch here to actually use the reset, but forcing platforms to specify a reset was not my intention as described in the first commit you referenced.
Quoted 22 lines
The device tree node for SoCFPGA's MMC device has the "resets" property, but is missing the "reset-names" property, so MMC no longer works. Barebox produces the error message:
ERROR:
dw_mmc[email protected]: probe failed: Invalid argumentAdd the missing "reset-names" property to the "&mmc" node in "
arch/arm/dts/socfpga.dtsi". It probably needs fixing in the upstream Linux device tree sources too!Cc Ahmad Fatoum <[email protected]>Cc Steffen Trumtrar <[email protected]>Signed-off-by Ian Abbott <[email protected]>--- arch/arm/dts/socfpga.dtsi | 4 ++++ 1 file changed, 4 insertions(+)arch/arm/dts/socfpga.dtsi +0
-0
arch/arm/dts/socfpga.dtsi line 8
Quoted 5 lines
arch/arm/dts/socfpga.dtsi +2
-0@@ -4,6 +4,10 @@ }; }; +&mmc { + reset-names = "reset";
FWIW, this now adheres to the synopsys-dw-mshc-common binding:
Quoted 6 lines
arch/arm/dts/socfpga.dtsi +2
-0+}; + &watchdog0 { resets = <&rst L4WD0_RESET>; };
Signature · 9 lines
Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Quoted 10 lines · Ahmad Fatoum
Quoted 8 lines
Add the missing "reset-names" property to the "&mmc" node in "
arch/arm/dts/socfpga.dtsi". It probably needs fixing in the upstream Linux device tree sources too!+&mmc {
+ reset-names = "reset";FWIW, this now adheres to the synopsys-dw-mshc-common binding:
reset-names, when there is just one reset type supported, is supposed to be optional.
_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
Quoted 9 lines · Ian Abbott
Since commit
90bdf1e5d1e4("mci:dw_mmc: match against StarFive MMC compatibles"), thedw_mmcdriver requires a reset line called "reset". The slightly earlier commita3cf324593ea("mci:dw_mmc: add optional reset line") introduced the reset line support, but made it optional.The device tree node for SoCFPGA's MMC device has the "resets" property, but is missing the "reset-names" property, so MMC no longer works. Barebox produces the error message:
Quoted 5 lines
ERROR:
dw_mmc[email protected]: probe failed: Invalid argumentAdd the missing "reset-names" property to the "&mmc" node in "
arch/arm/dts/socfpga.dtsi". It probably needs fixing in the upstream Linux device tree sources too!
The reset binding lists reset-names as an optional property, so it seems our reset code needs fixing and not the dtsi file.
Sascha
Signature · 9 lines
Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Quoted 10 lines · Sascha Hauer
Quoted 9 lines · Ian Abbott
Since commit
90bdf1e5d1e4("mci:dw_mmc: match against StarFive MMC compatibles"), thedw_mmcdriver requires a reset line called "reset". The slightly earlier commita3cf324593ea("mci:dw_mmc: add optional reset line") introduced the reset line support, but made it optional.The device tree node for SoCFPGA's MMC device has the "resets" property, but is missing the "reset-names" property, so MMC no longer works. Barebox produces the error message:
Quoted 8 lines
Quoted 5 lines
ERROR:
dw_mmc[email protected]: probe failed: Invalid argumentAdd the missing "reset-names" property to the "&mmc" node in "
arch/arm/dts/socfpga.dtsi". It probably needs fixing in the upstream Linux device tree sources too!The reset binding lists reset-names as an optional property, so it seems our reset code needs fixing and not the dtsi file.
I'll resubmit the patch later with a different commit message once things have been settled, since it seems like a good idea for the reset line in the socfpga.dtsi to be made use of, and it doesn't seem to do any harm!
Signature · 9 lines
-=( Ian Abbott <[email protected]> || MEV Ltd. is a company )=- -=( registered in England & Wales. Regd. number: 02862268. )=- -=( Regd. addr.: S11 & 12 Building 67, Europa Business Park, )=- -=( Bird Hall Lane, STOCKPORT, SK3 0XA, UK. || www.mev.co.uk )=- _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
PATCH v2 1/1 ARM: socfpga: Set reset-names property for &mmc
In reply to Ian AbbottThe device tree node for SoCFPGA's MMC device has the resets = property, but is missing the reset-names = "reset"; property. This causes the "dw_mmc" driver to output a warning:
WARNING: dw_mmc [email protected]: error claiming reset: Invalid argument
Add the missing reset-names property to the &mmc node in "arch/arm/dts/socfpga.dtsi". It probably needs fixing in the upstream Linux device tree sources too!
---
v2: Updated commit message because it no longer fails to initialize the MMC device since commit 724512bbac14 ("mci: dw_mmc: make reset control optional again").
arch/arm/dts/socfpga.dtsi | 4 ++++ 1 file changed, 4 insertions(+)
arch/arm/dts/socfpga.dtsi +4 -0
@@ -4,6 +4,10 @@ }; }; +&mmc { + reset-names = "reset"; +}; + &watchdog0 { resets = <&rst L4WD0_RESET>; };
Signature · 7 lines
2.33.0 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Sascha Hauer
AppliedQuoted 13 lines · Ian Abbott
The device tree node for SoCFPGA's MMC device has the
resets =property, but is missing thereset-names = "reset";property. This causes the "dw_mmc" driver to output a warning:WARNING:
dw_mmc[email protected]: error claiming reset: Invalid argumentAdd the missing
reset-namesproperty to the&mmcnode in "arch/arm/dts/socfpga.dtsi". It probably needs fixing in the upstream Linux device tree sources too!Cc Ahmad Fatoum <[email protected]>Cc Steffen Trumtrar <[email protected]>Signed-off-by Ian Abbott <[email protected]>
Quoted 7 lines
---
v2: Updated commit message because it no longer fails to initialize the MMC device since commit724512bbac14("mci:dw_mmc: make reset control optional again").arch/arm/dts/socfpga.dtsi | 4 ++++ 1 file changed, 4 insertions(+)
Applied, thanks
Sascha
Signature · 9 lines
Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox