]> localhost Git - SCSI2SD-V6.git/commitdiff
Disable direct read code over 128 sectors as it's not reliable
authorMichael McMaster <michael@codesrc.com>
Tue, 22 Feb 2022 06:10:02 +0000 (16:10 +1000)
committerMichael McMaster <michael@codesrc.com>
Tue, 22 Feb 2022 06:10:02 +0000 (16:10 +1000)
src/firmware/disk.c

index a9d9169391a316f0e42f7f518b6e857d4ced912b..7a4cb8a7dd5841e66265ad4d86af1fbbd69386dd 100755 (executable)
@@ -830,7 +830,8 @@ static void diskDataIn()
 \r
 #ifdef STM32F4xx\r
     // Direct mode requires hardware flow control to be working on the SD peripheral\r
-    if (bytesPerSector == SD_SECTOR_SIZE)\r
+    // Code isn't currently working above 128 sectors. TODO investigate\r
+    if (totalSDSectors < 128 && bytesPerSector == SD_SECTOR_SIZE)\r
     {\r
         diskDataInDirect(totalSDSectors, sdLBA, useSlowDataCount, &phaseChangeDelayNs);\r
     }\r