Commit c981cdf
mmc: sdhci: Fix voltage switch delay
Commit 20b92a3 ("mmc: sdhci: update signal voltage switch code")
removed voltage switch delays from sdhci because mmc core had been
enhanced to support them. However that assumed that sdhci_set_ios()
did a single clock change, which it did not, and so the delays in mmc
core, which should have come after the first clock change, were not
effective.
Fix by avoiding re-configuring UHS and preset settings when the clock
is turning on and the settings have not changed. That then also avoids
the associated clock changes, so that then sdhci_set_ios() does a single
clock change when voltage switching, and the mmc core delays become
effective.
To do that has meant keeping track of driver strength (host->drv_type),
and cases of reinitialization (host->reinit_uhs).
Note also, the 'turning_on_clk' restriction should not be necessary
but is done to minimize the impact of the change on stable kernels.
Fixes: 20b92a3 ("mmc: sdhci: update signal voltage switch code")
Cc: [email protected]
Signed-off-by: Adrian Hunter <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Ulf Hansson <[email protected]>1 parent c61bfb1 commit c981cdf
2 files changed
+56
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
373 | 373 | | |
374 | 374 | | |
375 | 375 | | |
| 376 | + | |
376 | 377 | | |
377 | 378 | | |
378 | 379 | | |
| |||
2293 | 2294 | | |
2294 | 2295 | | |
2295 | 2296 | | |
| 2297 | + | |
| 2298 | + | |
| 2299 | + | |
| 2300 | + | |
| 2301 | + | |
| 2302 | + | |
| 2303 | + | |
| 2304 | + | |
| 2305 | + | |
| 2306 | + | |
| 2307 | + | |
| 2308 | + | |
| 2309 | + | |
| 2310 | + | |
| 2311 | + | |
| 2312 | + | |
| 2313 | + | |
| 2314 | + | |
| 2315 | + | |
| 2316 | + | |
| 2317 | + | |
| 2318 | + | |
| 2319 | + | |
| 2320 | + | |
| 2321 | + | |
| 2322 | + | |
| 2323 | + | |
| 2324 | + | |
| 2325 | + | |
| 2326 | + | |
| 2327 | + | |
2296 | 2328 | | |
2297 | 2329 | | |
2298 | 2330 | | |
| 2331 | + | |
| 2332 | + | |
2299 | 2333 | | |
2300 | 2334 | | |
| 2335 | + | |
| 2336 | + | |
2301 | 2337 | | |
2302 | 2338 | | |
2303 | 2339 | | |
| |||
2323 | 2359 | | |
2324 | 2360 | | |
2325 | 2361 | | |
| 2362 | + | |
| 2363 | + | |
2326 | 2364 | | |
2327 | 2365 | | |
2328 | 2366 | | |
| |||
2349 | 2387 | | |
2350 | 2388 | | |
2351 | 2389 | | |
| 2390 | + | |
| 2391 | + | |
| 2392 | + | |
| 2393 | + | |
| 2394 | + | |
| 2395 | + | |
| 2396 | + | |
| 2397 | + | |
| 2398 | + | |
| 2399 | + | |
| 2400 | + | |
2352 | 2401 | | |
2353 | 2402 | | |
2354 | 2403 | | |
| |||
2392 | 2441 | | |
2393 | 2442 | | |
2394 | 2443 | | |
| 2444 | + | |
2395 | 2445 | | |
2396 | 2446 | | |
2397 | 2447 | | |
| |||
2419 | 2469 | | |
2420 | 2470 | | |
2421 | 2471 | | |
2422 | | - | |
2423 | | - | |
2424 | | - | |
2425 | | - | |
2426 | | - | |
2427 | | - | |
2428 | | - | |
| 2472 | + | |
2429 | 2473 | | |
2430 | 2474 | | |
2431 | 2475 | | |
2432 | 2476 | | |
2433 | 2477 | | |
2434 | 2478 | | |
| 2479 | + | |
2435 | 2480 | | |
2436 | 2481 | | |
2437 | 2482 | | |
| |||
3768 | 3813 | | |
3769 | 3814 | | |
3770 | 3815 | | |
| 3816 | + | |
3771 | 3817 | | |
3772 | 3818 | | |
3773 | 3819 | | |
| |||
3830 | 3876 | | |
3831 | 3877 | | |
3832 | 3878 | | |
| 3879 | + | |
3833 | 3880 | | |
3834 | 3881 | | |
3835 | 3882 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
524 | 524 | | |
525 | 525 | | |
526 | 526 | | |
| 527 | + | |
| 528 | + | |
527 | 529 | | |
528 | 530 | | |
529 | 531 | | |
| |||
0 commit comments