-
Notifications
You must be signed in to change notification settings - Fork 5.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mmc: Speed up reboot with an absent card #6747
base: rpi-6.12.y
Are you sure you want to change the base?
Conversation
N.B.:
|
Testing with cm5 during startup still getting stuck on systemd-journald.socket for 30-60 seconds and dtparam=sd=off is not detected. seems to be unsuccessfully halting/rebooting without sd card present. still gets stuck for amount a minute. And twice encountering a error like this: Problem could have occured from the system being unstable and hanging often even when using simple commands like dmesg. |
On devices with no card detect mechanism, the host ends up polling for the insertion of a card. This polling happens at multiple frequencies and with many steps (SDIO, SD, MMC), some of which involve timeouts. If a reboot is requested during one of those scans, it will stall, pointlessly, for up to a minute while it completes. Attempt to short circuit the rescan if the MMC interface is being removed. Signed-off-by: Phil Elwell <[email protected]>
Reduce the maximum time it takes to get to reboot by decreasing the default SDHCI timeout to 5 seconds. Signed-off-by: Phil Elwell <[email protected]>
Two days into running a reboot test over the weekend, the SDHCI driver hit a NULL pointer in sdhci_needs_reset. It's not clear how that has been added by the changes for a faster reboot, but guard against it explicitly. Signed-off-by: Phil Elwell <[email protected]>
That looks like a new crash - I've added a fix for that and another one to this PR, as well as hopefully reducing the maximum stall to 5 seconds. Wait another 40 minutes before trying to update. |
still stalling on systemd-journal.socket when booting ssh takes about 30 seconds to connect. however when booted stalls are less than 5 seconds for commands and halting and when actually halting/rebooting no stalls still sometimes small hangs with commands for 2 seconds during halt/shutdown for example trigger happy when pressing power button |
On devices with no card detect mechanism, the host ends up polling for the insertion of a card. This polling happens at multiple frequencies and with many steps (SDIO, SD, MMC), some of which involve timeouts. If a reboot is requested during one of those scans, it will stall, pointlessly, for up to a minute while it completes.
Attempt to short circuit the rescan if the MMC interface is being removed.
See: #6647