]> jspc29.x-matter.uni-frankfurt.de Git - trbnettools.git/commitdiff
bugfix in selectMdcFlashRom
authorhadaq <hadaq>
Mon, 7 Sep 2009 20:13:05 +0000 (20:13 +0000)
committerhadaq <hadaq>
Mon, 7 Sep 2009 20:13:05 +0000 (20:13 +0000)
trbrich/trbflash.c

index f8042dc5289432f12319faf7d4a1ba72b528601e..9234b42c64fadd8cd6b9476b663e63511dbffe6c 100644 (file)
@@ -63,7 +63,7 @@ static const char FlashTypeStr[][16] = {"INVALID", "ADCM1", "ADCM2", "MDC"};
 
 static FlashType flashType = FLASH_INVALID; 
 
-static const char trbflash_version[] = "$Revision: 2.03 $"; 
+static const char trbflash_version[] = "$Revision: 2.04 $"; 
 
 static uint32_t mdcFlashSelect = 1;
 
@@ -871,6 +871,8 @@ static int selectMdcFlashRom(uint16_t trb_address, uint8_t number) {
             trb_strerror(trb_errno));
     return -1;
   }
+  
+  return 0;
 }
 
 /* ------ MAIN ---------------------------------------------------------- */
@@ -1221,19 +1223,19 @@ int main(int argc, char ** argv)
       fprintf(stderr, "Invalid ManId(s), aborting\n");
       exit(EXIT_FAILURE);
     }
-    
+
     /* In case of MDC: select FlashRom */
     if (flashType == FLASH_MDC) {
       if (selectMdcFlashRom(trb_address, mdcFlashSelect) == -1) {
         exit(EXIT_FAILURE);
       }
     }
-    
+
     if ((status = readPage(trb_address, pageNumber, 256)) == -1) {
       fprintf(stderr, "Error reading Page, aborting\n");
       exit(EXIT_FAILURE);
     }
-    
+
     for (i = 0; i < status; i++) {
       char text[32] = "";
       char cc[2] = " \0";