sdm32h7: enable sdmmc hardware flow control

rockbox-gerrit-noreply--- via rockbox-cvs <[email protected]>
Newsgroups gmane.comp.systems.archos.rockbox.cvs
Message-ID <[email protected]>
commit a74ee4c04fa62810976ba73fdaf492fd080f4199
Author: Aidan MacDonald <[email protected]>
Date:   Wed Jan 21 13:54:30 2026 +0000

    sdm32h7: enable sdmmc hardware flow control
    
    Hardware flow control prevents FIFO underruns/overruns
    by stopping the bus clock if one would occur. This can
    slow down transfers, but that's better than having data
    transfer fail due to AXI/AHB bus contention.
    
    Change-Id: I8696d3aff78c17dbbe85907160fa37fd4ee11e85

diff --git a/firmware/target/arm/stm32/sdmmc-stm32h7.c b/firmware/target/arm/stm32/sdmmc-stm32h7.c
index 0bb0c323f9..8ec64a7d1d 100644
--- a/firmware/target/arm/stm32/sdmmc-stm32h7.c
+++ b/firmware/target/arm/stm32/sdmmc-stm32h7.c
@@ -121,7 +121,7 @@ void stm32h7_sdmmc_set_power_enabled(void *controller, bool enabled)
         udelay(200);
 
         /* Automatically stop clock when bus is not in use */
-        reg_writelf(ctl->regs, SDMMC_CLKCR, PWRSAV(1));
+        reg_writelf(ctl->regs, SDMMC_CLKCR, PWRSAV(1), HWFC_EN(1));
     }
     else
     {
-- 
rockbox-cvs mailing list
[email protected]
https://lists.haxx.se/mailman/listinfo/rockbox-cvs
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.