* [PATCH 1/1] arm64: dts: rockchip: Wait after SD card power-off on NanoPi R2S [not found] <20261130174550.2304-1-tobias@merkens.bayern> @ 2026-11-30 17:46 ` Tobias Merkens 2026-12-01 9:49 ` Heiko Stübner 0 siblings, 1 reply; 4+ messages in thread From: Tobias Merkens @ 2026-11-30 17:46 UTC (permalink / raw) To: Heiko Stuebner Cc: linux-rockchip, linux-arm-kernel, devicetree, Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-mmc, Tobias Merkens On a NanoPi R2S with a UHS-I SD card in SDR104 mode, the board hangs after a reboot until the power is removed. After the reboot only the SYS LED lights up, and the board does not answer on the network. The cause is not confirmed, but the likely explanation is that the card is still in 1.8V signalling when the SoC is reset. The boot ROM and U-Boot then cannot read the card, because they communicate with it at 3.3V. Commit 3c6f98b6e64e ("mmc: core: Add power-off-delay-us support") makes the delay after switching off the card supply configurable, and its default is 1 ms. Set the delay to 10 ms so that the card has time to discharge before the SoC is reset. This keeps the UHS modes of the card enabled. On one board with one card, every reboot hangs with the default delay, but every tested reboot succeeds with a delay of 1.5 ms or longer. The 10 ms is about seven times the shortest setting that worked. The devicetree change and this changelog were written with an AI assistant (Claude, claude-sonnet-5-5). The submitter reviewed both. Signed-off-by: Tobias Merkens <tobias@merkens.bayern> --- arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi index 308e526..cc53a3f 100644 --- a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi @@ -27,3 +27,7 @@ }; }; }; + +&sdmmc { + power-off-delay-us = <10000>; +}; -- 2.50.1.windows.1 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] arm64: dts: rockchip: Wait after SD card power-off on NanoPi R2S 2026-11-30 17:46 ` [PATCH 1/1] arm64: dts: rockchip: Wait after SD card power-off on NanoPi R2S Tobias Merkens @ 2026-12-01 9:49 ` Heiko Stübner 2026-12-01 10:55 ` Tobias Merkens 0 siblings, 1 reply; 4+ messages in thread From: Heiko Stübner @ 2026-12-01 9:49 UTC (permalink / raw) To: Tobias Merkens Cc: linux-rockchip, linux-arm-kernel, devicetree, Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-mmc, Tobias Merkens Hi Tobias, Am Montag, 30. November 2026, 18:46:20 Mitteleuropäische Normalzeit schrieb Tobias Merkens: > On a NanoPi R2S with a UHS-I SD card in SDR104 mode, the board hangs > after a reboot until the power is removed. After the reboot only the SYS > LED lights up, and the board does not answer on the network. > > The cause is not confirmed, but the likely explanation is that the card > is still in 1.8V signalling when the SoC is reset. The boot ROM and > U-Boot then cannot read the card, because they communicate with it at > 3.3V. > > Commit 3c6f98b6e64e ("mmc: core: Add power-off-delay-us support") makes > the delay after switching off the card supply configurable, and its > default is 1 ms. Set the delay to 10 ms so that the card has time to > discharge before the SoC is reset. This keeps the UHS modes of the card > enabled. > > On one board with one card, every reboot hangs with the default delay, > but every tested reboot succeeds with a delay of 1.5 ms or longer. The > 10 ms is about seven times the shortest setting that worked. > > The devicetree change and this changelog were written with an AI > assistant (Claude, claude-sonnet-5-5). The submitter reviewed both. > > Signed-off-by: Tobias Merkens <tobias@merkens.bayern> For that bit of changeset, this commit message is way too long. Please try to write this yourself - way much shorter. Also your mailer mangles message-ids, breaking threading and one-patch messages don't need a cover-letter. > --- > arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi > index 308e526..cc53a3f 100644 > --- a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi > +++ b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi > @@ -27,3 +27,7 @@ > }; > }; > }; > + > +&sdmmc { > + power-off-delay-us = <10000>; > +}; > if this is needed to discharge cards to survive reboots, somehow part of me things if that is more a property for the rk3328.dtsi, instead of later having dozens of of patches for each board, after more people actually discover the issue and possible fix. Afterall most boards follow the reference design and 10ms on reboot (probably) don't really matter that much. Heiko ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] arm64: dts: rockchip: Wait after SD card power-off on NanoPi R2S 2026-12-01 9:49 ` Heiko Stübner @ 2026-12-01 10:55 ` Tobias Merkens 2026-12-01 12:27 ` Heiko Stübner 0 siblings, 1 reply; 4+ messages in thread From: Tobias Merkens @ 2026-12-01 10:55 UTC (permalink / raw) To: Heiko Stübner Cc: linux-rockchip, linux-arm-kernel, devicetree, Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-mmc Hey Heiko, Thanks for the quick response. I have a look at my mailer and also trying to get a shorter commit Message by my self. Then i would submit a patch again but for the rk3328.dtsi sorry for the inconvenience, first time getting all thinks together. Tobias > Am 01.12.2026 um 10:49 schrieb Heiko Stübner <heiko@sntech.de>: > > Hi Tobias, > > Am Montag, 30. November 2026, 18:46:20 Mitteleuropäische Normalzeit schrieb Tobias Merkens: >> On a NanoPi R2S with a UHS-I SD card in SDR104 mode, the board hangs >> after a reboot until the power is removed. After the reboot only the SYS >> LED lights up, and the board does not answer on the network. >> >> The cause is not confirmed, but the likely explanation is that the card >> is still in 1.8V signalling when the SoC is reset. The boot ROM and >> U-Boot then cannot read the card, because they communicate with it at >> 3.3V. >> >> Commit 3c6f98b6e64e ("mmc: core: Add power-off-delay-us support") makes >> the delay after switching off the card supply configurable, and its >> default is 1 ms. Set the delay to 10 ms so that the card has time to >> discharge before the SoC is reset. This keeps the UHS modes of the card >> enabled. >> >> On one board with one card, every reboot hangs with the default delay, >> but every tested reboot succeeds with a delay of 1.5 ms or longer. The >> 10 ms is about seven times the shortest setting that worked. >> >> The devicetree change and this changelog were written with an AI >> assistant (Claude, claude-sonnet-5-5). The submitter reviewed both. >> >> Signed-off-by: Tobias Merkens <tobias@merkens.bayern> > > For that bit of changeset, this commit message is way too long. > Please try to write this yourself - way much shorter. > > Also your mailer mangles message-ids, breaking threading and one-patch > messages don't need a cover-letter. > >> --- >> arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi | 4 ++++ >> 1 file changed, 4 insertions(+) >> >> diff --git a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi >> index 308e526..cc53a3f 100644 >> --- a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi >> +++ b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dtsi >> @@ -27,3 +27,7 @@ >> }; >> }; >> }; >> + >> +&sdmmc { >> + power-off-delay-us = <10000>; >> +}; >> > > if this is needed to discharge cards to survive reboots, somehow part of > me things if that is more a property for the rk3328.dtsi, instead of later > having dozens of of patches for each board, after more people actually > discover the issue and possible fix. > > Afterall most boards follow the reference design and 10ms on reboot > (probably) don't really matter that much. > > > Heiko > > ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] arm64: dts: rockchip: Wait after SD card power-off on NanoPi R2S 2026-12-01 10:55 ` Tobias Merkens @ 2026-12-01 12:27 ` Heiko Stübner 0 siblings, 0 replies; 4+ messages in thread From: Heiko Stübner @ 2026-12-01 12:27 UTC (permalink / raw) To: Tobias Merkens Cc: linux-rockchip, linux-arm-kernel, devicetree, Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-mmc Hey Tobias, Am Dienstag, 1. Dezember 2026, 11:55:29 Mitteleuropäische Normalzeit schrieb Tobias Merkens: > Hey Heiko, > > Thanks for the quick response. > I have a look at my mailer and also trying to get a shorter commit Message by my self. > Then i would submit a patch again but for the rk3328.dtsi > > sorry for the inconvenience, first time getting all thinks together. no worries, everybody started somewhere - the learning is the important part :-) . The mailer problem is due to the amazon mailer mangling message-ids. I.e. this patch itself says (probably correctly) In-Reply-To: <20261130174550.2304-1-tobias@merkens.bayern> while amazon mangled the message-id of the cover-letter to: Message-ID: <010201a22d90cdae-7d210d26-ef8c-4326-b6a3-c1b9db5e53b3-000000@eu-west-1.amazonses.com> hence threading breaks. b4 [0] has a web-submission thingy, which prevents that mangling altogether. Heiko [0] https://b4.docs.kernel.org/en/latest/contributor/send.html ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-12-01 12:27 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20261130174550.2304-1-tobias@merkens.bayern>
2026-11-30 17:46 ` [PATCH 1/1] arm64: dts: rockchip: Wait after SD card power-off on NanoPi R2S Tobias Merkens
2026-12-01 9:49 ` Heiko Stübner
2026-12-01 10:55 ` Tobias Merkens
2026-12-01 12:27 ` Heiko Stübner
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox