]> jspc29.x-matter.uni-frankfurt.de Git - trbnettools.git/commitdiff
bugfix, erase failed
authorhadaq <hadaq>
Thu, 19 Jan 2012 16:44:49 +0000 (16:44 +0000)
committerhadaq <hadaq>
Thu, 19 Jan 2012 16:44:49 +0000 (16:44 +0000)
libtrbnet/trbflash.c

index 043a217df83c49ec2f41423c942aabd31e3f1e9e..ed5f3e80ee6aa4136d93dc63845a223d71b3b64e 100644 (file)
@@ -117,7 +117,7 @@ typedef struct {
 } FlashParam;
 
 static FlashParam flashParamRef;
-static const char trbflash_version[] = "$Revision: 2.37 $";
+static const char trbflash_version[] = "$Revision: 2.38 $";
 
 static uint32_t mdcFlashSelect = 1;
 
@@ -852,18 +852,6 @@ static int programImageBuffer(uint16_t trb_address,
         return -1;
       }
       
-      if ((flashParamRef.manId == 0x00461f) ||
-          (flashParamRef.manId == 0x00471f)) {
-        /* Unprotect sector */
-        if (sendCommand(trb_address, 0x39 << 24 | (BLOCK_SIZE * block), 3)
-            == -1) {
-          fprintf(stderr,
-                  "\nError > program: unprotect sector #%d, aborting\n",
-                  block);
-          return -1;
-        }
-      }
-      
       /* Erase block */
       fprintf(stdout, "E\b");
       fflush(stdout);