Unverified Commit 94746abe authored by Jan Procházka's avatar Jan Procházka Committed by GitHub

fix(sd): AquireSPI lock in sdcard_uninit (#9469)

parent 7d911b99
...@@ -712,6 +712,7 @@ uint8_t sdcard_uninit(uint8_t pdrv) ...@@ -712,6 +712,7 @@ uint8_t sdcard_uninit(uint8_t pdrv)
if (pdrv >= FF_VOLUMES || card == NULL) { if (pdrv >= FF_VOLUMES || card == NULL) {
return 1; return 1;
} }
AcquireSPI lock(card);
sdTransaction(pdrv, GO_IDLE_STATE, 0, NULL); sdTransaction(pdrv, GO_IDLE_STATE, 0, NULL);
ff_diskio_register(pdrv, NULL); ff_diskio_register(pdrv, NULL);
s_cards[pdrv] = NULL; s_cards[pdrv] = NULL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment