Fix sd-as3525.c build for non-multidrive targets
authorranma <ranma@a1c6a512-1295-4272-9138-f99709370657>
Thu, 24 Jun 2010 19:12:14 +0000 (24 19:12 +0000)
committerranma <ranma@a1c6a512-1295-4272-9138-f99709370657>
Thu, 24 Jun 2010 19:12:14 +0000 (24 19:12 +0000)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27114 a1c6a512-1295-4272-9138-f99709370657

firmware/target/arm/as3525/sd-as3525.c

index 55e12af..1fd10bf 100644 (file)
@@ -904,10 +904,10 @@ int sd_write_sectors(IF_MD2(int drive,) unsigned long start, int count,
         if(transfer > UNALIGNED_NUM_SECTORS)
             transfer = UNALIGNED_NUM_SECTORS;
 
-        sd_transfer_sectors(drive, start, transfer, aligned_buffer, false);
+        sd_transfer_sectors(IF_MD2(drive,) start, transfer, aligned_buffer, false);
         if (memcmp(buf, aligned_buffer, transfer * 512) != 0) {
             /* try the write again in the hope to repair the damage */
-            sd_transfer_sectors(drive, saved_start, saved_count, saved_buf, true);
+            sd_transfer_sectors(IF_MD2(drive,) saved_start, saved_count, saved_buf, true);
             panicf("sd: verify failed: sec=%ld n=%d!", start, transfer);
         }