- Replace 'for(' with 'for ('.
[openocd.git] / src / target / xscale.c
index 058e8d75f4471bcfc9c9a2dfe9f88ad17fd37979..e9c1d544468e9610ba080ce7818ddce6cd1973f3 100644 (file)
@@ -1783,7 +1783,7 @@ int xscale_full_context(target_t *target)
         * we can't enter User mode on an XScale (unpredictable),
         * but User shares registers with SYS
         */
-       for(i = 1; i < 7; i++)
+       for (i = 1; i < 7; i++)
        {
                int valid = 1;
 
@@ -1855,7 +1855,7 @@ int xscale_restore_context(target_t *target)
        * we can't enter User mode on an XScale (unpredictable),
        * but User shares registers with SYS
        */
-       for(i = 1; i < 7; i++)
+       for (i = 1; i < 7; i++)
        {
                int dirty = 0;
 
@@ -2189,12 +2189,12 @@ int xscale_set_breakpoint(struct target_s *target, breakpoint_t *breakpoint)
                if (breakpoint->length == 4)
                {
                        /* keep the original instruction in target endianness */
-                       if((retval = target_read_memory(target, breakpoint->address, 4, 1, breakpoint->orig_instr)) != ERROR_OK)
+                       if ((retval = target_read_memory(target, breakpoint->address, 4, 1, breakpoint->orig_instr)) != ERROR_OK)
                        {
                                return retval;
                        }
                        /* write the original instruction in target endianness (arm7_9->arm_bkpt is host endian) */
-                       if((retval = target_write_u32(target, breakpoint->address, xscale->arm_bkpt)) != ERROR_OK)
+                       if ((retval = target_write_u32(target, breakpoint->address, xscale->arm_bkpt)) != ERROR_OK)
                        {
                                return retval;
                        }
@@ -2202,12 +2202,12 @@ int xscale_set_breakpoint(struct target_s *target, breakpoint_t *breakpoint)
                else
                {
                        /* keep the original instruction in target endianness */
-                       if((retval = target_read_memory(target, breakpoint->address, 2, 1, breakpoint->orig_instr)) != ERROR_OK)
+                       if ((retval = target_read_memory(target, breakpoint->address, 2, 1, breakpoint->orig_instr)) != ERROR_OK)
                        {
                                return retval;
                        }
                        /* write the original instruction in target endianness (arm7_9->arm_bkpt is host endian) */
-                       if((retval = target_write_u32(target, breakpoint->address, xscale->thumb_bkpt)) != ERROR_OK)
+                       if ((retval = target_write_u32(target, breakpoint->address, xscale->thumb_bkpt)) != ERROR_OK)
                        {
                                return retval;
                        }
@@ -2286,14 +2286,14 @@ int xscale_unset_breakpoint(struct target_s *target, breakpoint_t *breakpoint)
                /* restore original instruction (kept in target endianness) */
                if (breakpoint->length == 4)
                {
-                       if((retval = target_write_memory(target, breakpoint->address, 4, 1, breakpoint->orig_instr)) != ERROR_OK)
+                       if ((retval = target_write_memory(target, breakpoint->address, 4, 1, breakpoint->orig_instr)) != ERROR_OK)
                        {
                                return retval;
                        }
                }
                else
                {
-                       if((retval = target_write_memory(target, breakpoint->address, 2, 1, breakpoint->orig_instr)) != ERROR_OK)
+                       if ((retval = target_write_memory(target, breakpoint->address, 2, 1, breakpoint->orig_instr)) != ERROR_OK)
                        {
                                return retval;
                        }
@@ -3606,11 +3606,11 @@ int xscale_handle_cp15(command_context_t *cmd_ctx, char *cmd, char **args, int a
        }
        uint32_t reg_no = 0;
        reg_t *reg = NULL;
-       if(argc > 0)
+       if (argc > 0)
        {
                reg_no = strtoul(args[0], NULL, 0);
                /*translate from xscale cp15 register no to openocd register*/
-               switch(reg_no)
+               switch (reg_no)
                {
                case 0:
                        reg_no = XSCALE_MAINID;
@@ -3643,7 +3643,7 @@ int xscale_handle_cp15(command_context_t *cmd_ctx, char *cmd, char **args, int a
                reg = &xscale->reg_cache->reg_list[reg_no];
 
        }
-       if(argc == 1)
+       if (argc == 1)
        {
                uint32_t value;
 
@@ -3652,7 +3652,7 @@ int xscale_handle_cp15(command_context_t *cmd_ctx, char *cmd, char **args, int a
                value = buf_get_u32(reg->value, 0, 32);
                command_print(cmd_ctx, "%s (/%i): 0x%" PRIx32 "", reg->name, (int)(reg->size), value);
        }
-       else if(argc == 2)
+       else if (argc == 2)
        {
 
                uint32_t value = strtoul(args[1], NULL, 0);

Linking to existing account procedure

If you already have an account and want to add another login method you MUST first sign in with your existing account and then change URL to read https://review.openocd.org/login/?link to get to this page again but this time it'll work for linking. Thank you.

SSH host keys fingerprints

1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=..              |
|+o..   .         |
|*.o   . .        |
|+B . . .         |
|Bo. = o S        |
|Oo.+ + =         |
|oB=.* = . o      |
| =+=.+   + E     |
|. .=o   . o      |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)