]> git.sur5r.net Git - openocd/commitdiff
- Fixes '[+]=' whitespace
authorzwelch <zwelch@b42882b7-edfa-0310-969c-e2dbd0fdcd60>
Tue, 23 Jun 2009 22:39:18 +0000 (22:39 +0000)
committerzwelch <zwelch@b42882b7-edfa-0310-969c-e2dbd0fdcd60>
Tue, 23 Jun 2009 22:39:18 +0000 (22:39 +0000)
- Replace '\(\w\)\([+]=\)(' with '\1 \2 ('.
- Replace '\(\w\)\([+]=\)\(\w\)' with '\1 \2 \3'.

git-svn-id: svn://svn.berlios.de/openocd/trunk@2364 b42882b7-edfa-0310-969c-e2dbd0fdcd60

14 files changed:
src/flash/cfi.c
src/flash/ecos.c
src/flash/mflash.c
src/flash/ocl/at91sam7x/main.c
src/flash/ocl/at91sam7x/samflash.c
src/helper/log.c
src/helper/time_support.c
src/jtag/tcl.c
src/jtag/zy1000/zy1000.c
src/server/gdb_server.c
src/target/arm7_9_common.c
src/target/image.c
src/target/mips32_pracc.c
src/target/target.c

index f6ddead30c6c47ca2a0c9e3758b5667a9324fa4e..1d4ae537d809dcbf04750245a8485b05249d3547 100644 (file)
@@ -1014,7 +1014,7 @@ static void cfi_fix_code_endian(target_t *target, uint8_t *dest, const uint32_t
        for (i=0; i< count; i++)
        {
                target_buffer_set_u32(target, dest, *src);
-               dest+=4;
+               dest += 4;
                src++;
        }
 }
index 5d1badd61563892e9593f3a62d7df71ed9ec4fa2..ec3b3c13edfcdaa747541304afe175b6f5d6eba1 100644 (file)
@@ -319,7 +319,7 @@ static int eCosBoard_flash(ecosflash_flash_bank_t *info, void *data, uint32_t ad
 
 
        uint32_t i;
-       for (i=0; i<len; i+=chunk)
+       for (i=0; i<len; i += chunk)
        {
                int t=len-i;
                if (t>chunk)
index 8518df196e0d2fdb2cd64d75614dbd2e98be0121..b26e62b78cbe5468706d379d9818e6aa3e99fcaf 100644 (file)
@@ -278,7 +278,7 @@ static int mg_dsk_wait(mg_io_type_wait wait, uint32_t time)
                duration_stop_measure(&duration, NULL);
 
                t=duration.duration.tv_usec/1000;
-               t+=duration.duration.tv_sec*1000;
+               t += duration.duration.tv_sec*1000;
 
                if (t > time)
                        break;
index 3d88d91a2061cbd158af524ad14a4de83c61fab0..6ecbf35a83aacaf9b415f60954e3c569876c398d 100644 (file)
@@ -64,7 +64,7 @@ void cmd_flash(uint32 cmd)
 
        result=0;
        pagenum=adr/flash_page_size;
-       for (bi=0; bi<bi_end; bi+=flash_page_size/4) {
+       for (bi=0; bi<bi_end; bi += flash_page_size/4) {
                result=flash_page_program(buffer+bi, pagenum++);
                if (result) break;
        }
index 81c1801d8108d2d2abc23f4c87a848f2de82c1bb..d7c21f72fa2344b96f30c3f17eceac89893b784b 100644 (file)
@@ -146,7 +146,7 @@ int flash_erase_plane(int efc_ofs)
                        if ((inr(MC_FSR+efc_ofs)&MC_LOCKE)) return FLASH_STAT_LOCKE;
 
                }
-               if ((page_num+=flash_lock_pages)>flash_page_count) break;
+               if ((page_num += flash_lock_pages)>flash_page_count) break;
                lockbits>>=1;
        }
 
index b596075fbafc065b6a62e1f67ff838a185df718f..0e04af6f6bb88b7151e75b96dcdadb88344521e1 100644 (file)
@@ -429,7 +429,7 @@ void alive_sleep(int ms)
 {
        int i;
        int napTime=10;
-       for (i=0; i<ms; i+=napTime)
+       for (i=0; i<ms; i += napTime)
        {
                int sleep_a_bit=ms-i;
                if (sleep_a_bit>napTime)
index 7a9a80010533a173231a70c15896ee3eac727b8a..922d411d7561f8671645c3310468f105da953133 100644 (file)
@@ -100,7 +100,7 @@ int duration_stop_measure(duration_t *duration, char **text)
        {
                float t;
                t=duration->duration.tv_sec;
-               t+=(float)duration->duration.tv_usec/1000000.0;
+               t += (float)duration->duration.tv_usec/1000000.0;
                *text = malloc(100);
                snprintf(*text, 100, "%fs", t);
        }
@@ -114,8 +114,8 @@ long long timeval_ms()
        long long t=0;
        gettimeofday(&now, NULL);
        
-       t+=now.tv_usec/1000;
-       t+=now.tv_sec*1000;
+       t += now.tv_usec/1000;
+       t += now.tv_sec*1000;
        
        return t;
 }
index 2be7f87b6c47cadf1e35ee8071f2c3dfa9c02b72..24870ab2154cc6cafc1fdb5a914beb7cf7f49360 100644 (file)
@@ -1274,7 +1274,7 @@ static int Jim_Command_drscan(Jim_Interp *interp, int argc, Jim_Obj *const *args
 
        /* validate arguments as numbers */
        e = JIM_OK;
-       for (i = 2; i < argc; i+=2)
+       for (i = 2; i < argc; i += 2)
        {
                long bits;
                const char *cp;
@@ -1333,7 +1333,7 @@ static int Jim_Command_drscan(Jim_Interp *interp, int argc, Jim_Obj *const *args
 
        num_fields=(argc-2)/2;
        fields = malloc(sizeof(scan_field_t) * num_fields);
-       for (i = 2; i < argc; i+=2)
+       for (i = 2; i < argc; i += 2)
        {
                long bits;
                int len;
@@ -1361,7 +1361,7 @@ static int Jim_Command_drscan(Jim_Interp *interp, int argc, Jim_Obj *const *args
 
        field_count=0;
        Jim_Obj *list = Jim_NewListObj(interp, NULL, 0);
-       for (i = 2; i < argc; i+=2)
+       for (i = 2; i < argc; i += 2)
        {
                long bits;
                char *str;
index d31b433660397405898300ff82055bfe33ac7074..5e4bda0f19ffb98b31064efad6671e9c4b52ff94 100644 (file)
@@ -455,7 +455,7 @@ static __inline void scanFields(int num_fields, const scan_field_t *fields, tap_
                        value=0;
                        if (fields[i].out_value != NULL)
                        {
-                               for (l=0; l<k; l+=8)
+                               for (l=0; l<k; l += 8)
                                {
                                        value|=fields[i].out_value[(j+l)/8]<<l;
                                }
@@ -472,12 +472,12 @@ static __inline void scanFields(int num_fields, const scan_field_t *fields, tap_
                                // we're shifting in data to MSB, shift data to be aligned for returning the value
                                value >>= 32-k;
 
-                               for (l=0; l<k; l+=8)
+                               for (l=0; l<k; l += 8)
                                {
                                        inBuffer[(j+l)/8]=(value>>l)&0xff;
                                }
                        }
-                       j+=k;
+                       j += k;
                }
        }
 }
@@ -634,7 +634,7 @@ static int zy1000_jtag_add_clocks(int num_cycles, tap_state_t state, tap_state_t
 
        /* execute num_cycles, 32 at the time. */
        int i;
-       for (i=0; i<num_cycles; i+=32)
+       for (i=0; i<num_cycles; i += 32)
        {
                int num;
                num=32;
@@ -742,7 +742,7 @@ void embeddedice_write_dcc(jtag_tap_t *tap, int reg_addr, uint8_t *buffer, int l
                        {
                                shiftValueInner(TAP_DRSHIFT, TAP_DRSHIFT, 32, fast_target_buffer_get_u32(buffer, 1));
                                shiftValueInner(TAP_DRSHIFT, end_state, 6, reg_addr|(1<<5));
-                               buffer+=4;
+                               buffer += 4;
                        }
                } else
                {
@@ -751,7 +751,7 @@ void embeddedice_write_dcc(jtag_tap_t *tap, int reg_addr, uint8_t *buffer, int l
                        {
                                shiftValueInner(TAP_DRSHIFT, TAP_DRSHIFT, 32, fast_target_buffer_get_u32(buffer, 0));
                                shiftValueInner(TAP_DRSHIFT, end_state, 6, reg_addr|(1<<5));
-                               buffer+=4;
+                               buffer += 4;
                        }
                }
        }
index a13f215f0a6443def0471ac345c25a3257120c8c..e6a1ce5596342515a43f9c8e3d11bdd780a0b6b5 100644 (file)
@@ -923,7 +923,7 @@ void gdb_target_to_reg(target_t *target, char *tstr, int str_len, uint8_t *bin)
        }
 
        int i;
-       for (i = 0; i < str_len; i+=2)
+       for (i = 0; i < str_len; i += 2)
        {
                uint8_t t = hextoint(tstr[i])<<4;
                t |= hextoint(tstr[i+1]);
index 50b6d6a894689f9a8fd23d77ad0875b650f7ee48..474f94678b6fcef61a7d3b3d557b27be6f75d24e 100644 (file)
@@ -2587,7 +2587,7 @@ static int arm7_9_dcc_completion(struct target_s *target, uint32_t exit_point, i
                /* Handle first & last using standard embeddedice_write_reg and the middle ones w/the
                 * core function repeated. */
                embeddedice_write_reg(&arm7_9->eice_cache->reg_list[EICE_COMMS_DATA], fast_target_buffer_get_u32(buffer, little));
-               buffer+=4;
+               buffer += 4;
 
                embeddedice_reg_t *ice_reg = arm7_9->eice_cache->reg_list[EICE_COMMS_DATA].arch_info;
                uint8_t reg_addr = ice_reg->addr & 0x1f;
index 66bcc95f376a7dccdcfda443f3b7ccb4dabddde7..45107b4854860e7abccc20d3359cf68ec22e5f39 100644 (file)
@@ -764,7 +764,7 @@ int image_open(image_t *image, char *url, char *type_string)
                int section;
                for (section=0; section < image->num_sections; section++)
                {
-                       image->sections[section].base_address+=image->base_address;
+                       image->sections[section].base_address += image->base_address;
                }
                /* we're done relocating. The two statements below are mainly
                 * for documenation purposes: stop anyone from empirically
index 4e032f65588bbe1f45239cd7bbc331c2556bfa36..06e852baaa5a8feaf6f6c37559fa7cdd048d1dd3 100644 (file)
@@ -314,8 +314,8 @@ int mips32_pracc_read_mem32(mips_ejtag_t *ejtag_info, uint32_t addr, int count,
                MIPS32_SW(8,0,11),                                                                      /* sw $8,0($11) */
                
                MIPS32_ADDI(10,10,NEG16(1)),                                            /* $10-- */
-               MIPS32_ADDI(9,9,4),                                                             /* $1+=4 */
-               MIPS32_ADDI(11,11,4),                                                           /* $11+=4 */
+               MIPS32_ADDI(9,9,4),                                                             /* $1 += 4 */
+               MIPS32_ADDI(11,11,4),                                                           /* $11 += 4 */
                
                MIPS32_NOP,
                MIPS32_B(NEG16(9)),                                                                     /* b loop */
@@ -422,8 +422,8 @@ int mips32_pracc_read_mem16(mips_ejtag_t *ejtag_info, uint32_t addr, int count,
                MIPS32_SW(8,0,11),                                                                      /* sw $8,0($11) */
                
                MIPS32_ADDI(10,10,NEG16(1)),                                            /* $10-- */
-               MIPS32_ADDI(9,9,2),                                                             /* $9+=2 */
-               MIPS32_ADDI(11,11,4),                                                           /* $11+=4 */
+               MIPS32_ADDI(9,9,2),                                                             /* $9 += 2 */
+               MIPS32_ADDI(11,11,4),                                                           /* $11 += 4 */
                MIPS32_NOP,
                MIPS32_B(NEG16(9)),                                                                     /* b loop */
                MIPS32_NOP,
@@ -501,8 +501,8 @@ int mips32_pracc_read_mem8(mips_ejtag_t *ejtag_info, uint32_t addr, int count, u
                MIPS32_SW(8,0,11),                                                                      /* sw $8,0($11) */
                
                MIPS32_ADDI(10,10,NEG16(1)),                                            /* $10-- */
-               MIPS32_ADDI(9,9,1),                                                             /* $9+=1 */
-               MIPS32_ADDI(11,11,4),                                                           /* $11+=4 */
+               MIPS32_ADDI(9,9,1),                                                             /* $9 += 1 */
+               MIPS32_ADDI(11,11,4),                                                           /* $11 += 4 */
                MIPS32_NOP,
                MIPS32_B(NEG16(9)),                                                                     /* b loop */
                MIPS32_NOP,
@@ -588,15 +588,15 @@ int mips32_pracc_write_mem32(mips_ejtag_t *ejtag_info, uint32_t addr, int count,
                MIPS32_ADDI(8,15,NEG16(MIPS32_PRACC_STACK-MIPS32_PRACC_PARAM_IN)),  //$8= MIPS32_PRACC_PARAM_IN
                MIPS32_LW(9,0,8),                                                                       /* Load write addr to $9 */
                MIPS32_LW(10,4,8),      //last address                                                                  /* Load write count to $10 */
-               MIPS32_ADDI(8,8,8),     // $8+=8 beginning of data
+               MIPS32_ADDI(8,8,8),     // $8 += 8 beginning of data
 
 //loop:
                MIPS32_LW(11,0,8),                                                                      /* lw $11,0($8), Load $11 with the word @mem[$8] */
                MIPS32_SW(11,0,9),                                                                      /* sw $11,0($9) */
                
-               MIPS32_ADDI(9,9,4),                                                             /* $9+=4 */
+               MIPS32_ADDI(9,9,4),                                                             /* $9 += 4 */
                MIPS32_BNE(10,9,NEG16(4)),  //was 9 BNE $10, 9, loop                                                                    /* b loop */
-               MIPS32_ADDI(8,8,4),  //this instruction is part of the loop (one delay slot)!   /* $8+=4 */
+               MIPS32_ADDI(8,8,4),  //this instruction is part of the loop (one delay slot)!   /* $8 += 4 */
                                                                                                                        /* end: */
                MIPS32_LW(11,0,15),                                                             /* lw $11,($15) */
                MIPS32_LW(10,0,15),                                                             /* lw $10,($15) */
@@ -669,7 +669,7 @@ int mips32_pracc_write_mem16(mips_ejtag_t *ejtag_info, uint32_t addr, int count,
                MIPS32_ORI(8,8,LOWER16(MIPS32_PRACC_PARAM_IN)),
                MIPS32_LW(9,0,8),                                                                       /* Load write addr to $9 */
                MIPS32_LW(10,4,8),                                                                      /* Load write count to $10 */
-               MIPS32_ADDI(8,8,8),                                                             /* $8+=8 */
+               MIPS32_ADDI(8,8,8),                                                             /* $8 += 8 */
                MIPS32_NOP,
                                                                                                                        /* loop: */
                MIPS32_BEQ(0,10,9),                                                                     /* beq $0, $10, end */
@@ -679,8 +679,8 @@ int mips32_pracc_write_mem16(mips_ejtag_t *ejtag_info, uint32_t addr, int count,
                MIPS32_SH(11,0,9),                                                                      /* sh $11,0($9) */
                
                MIPS32_ADDI(10,10,NEG16(1)),                                            /* $10-- */
-               MIPS32_ADDI(9,9,2),                                                             /* $9+=2 */
-               MIPS32_ADDI(8,8,4),                                                             /* $8+=4 */
+               MIPS32_ADDI(9,9,2),                                                             /* $9 += 2 */
+               MIPS32_ADDI(8,8,4),                                                             /* $8 += 4 */
                
                MIPS32_NOP,
                MIPS32_B(NEG16(9)),                                                                     /* b loop */
@@ -729,7 +729,7 @@ int mips32_pracc_write_mem8(mips_ejtag_t *ejtag_info, uint32_t addr, int count,
                MIPS32_ORI(8,8,LOWER16(MIPS32_PRACC_PARAM_IN)),
                MIPS32_LW(9,0,8),                                                                       /* Load write addr to $9 */
                MIPS32_LW(10,4,8),                                                                      /* Load write count to $10 */
-               MIPS32_ADDI(8,8,8),                                                             /* $8+=8 */
+               MIPS32_ADDI(8,8,8),                                                             /* $8 += 8 */
                MIPS32_NOP,
                                                                                                                        /* loop: */
                MIPS32_BEQ(0,10,9),                                                                     /* beq $0, $10, end */
@@ -739,8 +739,8 @@ int mips32_pracc_write_mem8(mips_ejtag_t *ejtag_info, uint32_t addr, int count,
                MIPS32_SB(11,0,9),                                                                      /* sb $11,0($9) */
                
                MIPS32_ADDI(10,10,NEG16(1)),                                            /* $10-- */
-               MIPS32_ADDI(9,9,1),                                                             /* $9+=1 */
-               MIPS32_ADDI(8,8,4),                                                             /* $8+=4 */
+               MIPS32_ADDI(9,9,1),                                                             /* $9 += 1 */
+               MIPS32_ADDI(8,8,4),                                                             /* $8 += 4 */
                
                MIPS32_NOP,
                MIPS32_B(NEG16(9)),                                                                     /* b loop */
index 5ff223242e21c323e362d0a2ffd93e6ab1f5f40d..56bcdf05de2bf58b563d37fa7255bb47e3d1f268 100644 (file)
@@ -2285,7 +2285,7 @@ static int handle_load_image_command(struct command_context_s *cmd_ctx, char *cm
                        if (image.sections[i].base_address<min_address)
                        {
                                /* clip addresses below */
-                               offset+=min_address-image.sections[i].base_address;
+                               offset += min_address-image.sections[i].base_address;
                                length -= offset;
                        }
 
@@ -4466,7 +4466,7 @@ static int handle_fast_load_image_command(struct command_context_s *cmd_ctx, cha
                        if (image.sections[i].base_address<min_address)
                        {
                                /* clip addresses below */
-                               offset+=min_address-image.sections[i].base_address;
+                               offset += min_address-image.sections[i].base_address;
                                length -= offset;
                        }
 
@@ -4535,7 +4535,7 @@ static int handle_fast_load_command(struct command_context_s *cmd_ctx, char *cmd
                {
                        retval = target_write_buffer(target, fastload[i].address, fastload[i].length, fastload[i].data);
                }
-               size+=fastload[i].length;
+               size += fastload[i].length;
        }
        int after=timeval_ms();
        command_print(cmd_ctx, "Loaded image %f kBytes/s", (float)(size/1024.0)/((float)(after-ms)/1000.0));