Explorar o código

Allowing for custom block sizes

Addressing issue: https://github.com/ZuluSCSI/ZuluSCSI-firmware/issues/338

Allowing block sizes from 8 bytes to 64kB
Morio hai 1 ano
pai
achega
04673bcbfe
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      src/ZuluSCSI.cpp

+ 2 - 2
src/ZuluSCSI.cpp

@@ -461,10 +461,10 @@ bool findHDDImages()
         if (blksize)
         {
           int blktmp = strtoul(blksize + 1, NULL, 10);
-          if (blktmp == 256 || blktmp == 512 || blktmp == 1024 ||
-              blktmp == 2048 || blktmp == 4096 || blktmp == 8192)
+          if (8 <= blktmp && blktmp <= 64 * 1024)
           {
             blk = blktmp;
+            logmsg("-- Using custom block size, ",(int) blk," from filename: ", name);
           }
         }