stm32/sdcard: Fully reset SDMMC periph before calling HAL DMA functions.
stm32/sdcard: Fully reset SDMMC periph before calling HAL DMA functions.

The HAL DMA functions enable SDMMC interrupts before fully resetting the
peripheral, and this can lead to a DTIMEOUT IRQ during the initialisation
of the DMA transfer, which then clears out the DMA state and leads to the
read/write not working at all.  The DTIMEOUT is there from previous SDMMC
DMA transfers, even those that succeeded, and is of duration ~180 seconds,
which is 0xffffffff / 24MHz (default DTIMER value, and clock of
peripheral).

To work around this issue, fully reset the SDMMC peripheral before calling
the HAL SD DMA functions.

Fixes issue #4110.

tobbad/micropython,kerneltask/micropython,kerneltask/micropython,pramasoul/micropython,tobbad/micropython,MrSurly/micropython,pozetroninc/micropython,MrSurly/micropython,tobbad/micropython,adafruit/circuitpython,selste/micropython,bvernoux/micropython,selste/micropython,kerneltask/micropython,pramasoul/micropython,henriknelson/micropython,henriknelson/micropython,trezor/micropython,bvernoux/micropython,pfalcon/micropython,adafruit/circuitpython,bvernoux/micropython,pfalcon/micropython,selste/micropython,MrSurly/micropython,kerneltask/micropython,henriknelson/micropython,henriknelson/micropython,trezor/micropython,adafruit/circuitpython,trezor/micropython,pozetroninc/micropython,adafruit/circuitpython,MrSurly/micropython,pozetroninc/micropython,henriknelson/micropython,pramasoul/micropython,trezor/micropython,pozetroninc/micropython,pramasoul/micropython,pramasoul/micropython,adafruit/circuitpython,MrSurly/micropython,pfalcon/micropython,selste/micropython,tobbad/micropython,tobbad/micropython,selste/micropython,kerneltask/micropython,bvernoux/micropython,bvernoux/micropython,pozetroninc/micropython,trezor/micropython,adafruit/circuitpython,pfalcon/micropython,pfalcon/micropython