target/nds32: use lowercase for C variables
[openocd.git] / src / target / nds32_cmd.c
index 246dbd0344c0c4235a3646351565a75ef1ce34aa..3931707be888e595b3fe83df88cfee93e7f92885 100644 (file)
 extern struct nds32_edm_operation nds32_edm_ops[NDS32_EDM_OPERATION_MAX_NUM];
 extern uint32_t nds32_edm_ops_num;
 
-static const char *const NDS_MEMORY_ACCESS_NAME[] = {
+static const char *const nds_memory_access_name[] = {
        "BUS",
        "CPU",
 };
 
-static const char *const NDS_MEMORY_SELECT_NAME[] = {
+static const char *const nds_memory_select_name[] = {
        "AUTO",
        "MEM",
        "ILM",
@@ -84,13 +84,13 @@ COMMAND_HANDLER(handle_nds32_memory_access_command)
                        memory->access_channel = NDS_MEMORY_ACC_CPU;
 
                LOG_DEBUG("memory access channel is changed to %s",
-                               NDS_MEMORY_ACCESS_NAME[memory->access_channel]);
+                               nds_memory_access_name[memory->access_channel]);
 
                aice_memory_access(aice, memory->access_channel);
        } else {
                command_print(CMD, "%s: memory access channel: %s",
                                target_name(target),
-                               NDS_MEMORY_ACCESS_NAME[memory->access_channel]);
+                               nds_memory_access_name[memory->access_channel]);
        }
 
        return ERROR_OK;
@@ -147,7 +147,7 @@ COMMAND_HANDLER(handle_nds32_memory_mode_command)
 
        command_print(CMD, "%s: memory mode: %s",
                        target_name(target),
-                       NDS_MEMORY_SELECT_NAME[nds32->memory.mode]);
+                       nds_memory_select_name[nds32->memory.mode]);
 
        return ERROR_OK;
 }
@@ -681,8 +681,8 @@ static int jim_nds32_bulk_write(Jim_Interp *interp, int argc, Jim_Obj * const *a
 {
        const char *cmd_name = Jim_GetString(argv[0], NULL);
 
-       Jim_GetOptInfo goi;
-       Jim_GetOpt_Setup(&goi, interp, argc - 1, argv + 1);
+       struct jim_getopt_info goi;
+       jim_getopt_setup(&goi, interp, argc - 1, argv + 1);
 
        if (goi.argc < 3) {
                Jim_SetResultFormatted(goi.interp,
@@ -692,12 +692,12 @@ static int jim_nds32_bulk_write(Jim_Interp *interp, int argc, Jim_Obj * const *a
 
        int e;
        jim_wide address;
-       e = Jim_GetOpt_Wide(&goi, &address);
+       e = jim_getopt_wide(&goi, &address);
        if (e != JIM_OK)
                return e;
 
        jim_wide count;
-       e = Jim_GetOpt_Wide(&goi, &count);
+       e = jim_getopt_wide(&goi, &count);
        if (e != JIM_OK)
                return e;
 
@@ -708,7 +708,7 @@ static int jim_nds32_bulk_write(Jim_Interp *interp, int argc, Jim_Obj * const *a
        jim_wide i;
        for (i = 0; i < count; i++) {
                jim_wide tmp;
-               e = Jim_GetOpt_Wide(&goi, &tmp);
+               e = jim_getopt_wide(&goi, &tmp);
                if (e != JIM_OK) {
                        free(data);
                        return e;
@@ -738,8 +738,8 @@ static int jim_nds32_multi_write(Jim_Interp *interp, int argc, Jim_Obj * const *
 {
        const char *cmd_name = Jim_GetString(argv[0], NULL);
 
-       Jim_GetOptInfo goi;
-       Jim_GetOpt_Setup(&goi, interp, argc - 1, argv + 1);
+       struct jim_getopt_info goi;
+       jim_getopt_setup(&goi, interp, argc - 1, argv + 1);
 
        if (goi.argc < 3) {
                Jim_SetResultFormatted(goi.interp,
@@ -749,7 +749,7 @@ static int jim_nds32_multi_write(Jim_Interp *interp, int argc, Jim_Obj * const *
 
        int e;
        jim_wide num_of_pairs;
-       e = Jim_GetOpt_Wide(&goi, &num_of_pairs);
+       e = jim_getopt_wide(&goi, &num_of_pairs);
        if (e != JIM_OK)
                return e;
 
@@ -765,12 +765,12 @@ static int jim_nds32_multi_write(Jim_Interp *interp, int argc, Jim_Obj * const *
        aice_set_command_mode(aice, AICE_COMMAND_MODE_PACK);
        for (i = 0; i < num_of_pairs; i++) {
                jim_wide tmp;
-               e = Jim_GetOpt_Wide(&goi, &tmp);
+               e = jim_getopt_wide(&goi, &tmp);
                if (e != JIM_OK)
                        break;
                address = (uint32_t)tmp;
 
-               e = Jim_GetOpt_Wide(&goi, &tmp);
+               e = jim_getopt_wide(&goi, &tmp);
                if (e != JIM_OK)
                        break;
                data = (uint32_t)tmp;
@@ -792,8 +792,8 @@ static int jim_nds32_bulk_read(Jim_Interp *interp, int argc, Jim_Obj * const *ar
 {
        const char *cmd_name = Jim_GetString(argv[0], NULL);
 
-       Jim_GetOptInfo goi;
-       Jim_GetOpt_Setup(&goi, interp, argc - 1, argv + 1);
+       struct jim_getopt_info goi;
+       jim_getopt_setup(&goi, interp, argc - 1, argv + 1);
 
        if (goi.argc < 2) {
                Jim_SetResultFormatted(goi.interp,
@@ -803,12 +803,12 @@ static int jim_nds32_bulk_read(Jim_Interp *interp, int argc, Jim_Obj * const *ar
 
        int e;
        jim_wide address;
-       e = Jim_GetOpt_Wide(&goi, &address);
+       e = jim_getopt_wide(&goi, &address);
        if (e != JIM_OK)
                return e;
 
        jim_wide count;
-       e = Jim_GetOpt_Wide(&goi, &count);
+       e = jim_getopt_wide(&goi, &count);
        if (e != JIM_OK)
                return e;
 
@@ -840,8 +840,8 @@ static int jim_nds32_read_edm_sr(Jim_Interp *interp, int argc, Jim_Obj * const *
 {
        const char *cmd_name = Jim_GetString(argv[0], NULL);
 
-       Jim_GetOptInfo goi;
-       Jim_GetOpt_Setup(&goi, interp, argc - 1, argv + 1);
+       struct jim_getopt_info goi;
+       jim_getopt_setup(&goi, interp, argc - 1, argv + 1);
 
        if (goi.argc < 1) {
                Jim_SetResultFormatted(goi.interp,
@@ -852,7 +852,7 @@ static int jim_nds32_read_edm_sr(Jim_Interp *interp, int argc, Jim_Obj * const *
        int e;
        const char *edm_sr_name;
        int edm_sr_name_len;
-       e = Jim_GetOpt_String(&goi, &edm_sr_name, &edm_sr_name_len);
+       e = jim_getopt_string(&goi, &edm_sr_name, &edm_sr_name_len);
        if (e != JIM_OK)
                return e;
 
@@ -888,8 +888,8 @@ static int jim_nds32_write_edm_sr(Jim_Interp *interp, int argc, Jim_Obj * const
 {
        const char *cmd_name = Jim_GetString(argv[0], NULL);
 
-       Jim_GetOptInfo goi;
-       Jim_GetOpt_Setup(&goi, interp, argc - 1, argv + 1);
+       struct jim_getopt_info goi;
+       jim_getopt_setup(&goi, interp, argc - 1, argv + 1);
 
        if (goi.argc < 2) {
                Jim_SetResultFormatted(goi.interp,
@@ -900,12 +900,12 @@ static int jim_nds32_write_edm_sr(Jim_Interp *interp, int argc, Jim_Obj * const
        int e;
        const char *edm_sr_name;
        int edm_sr_name_len;
-       e = Jim_GetOpt_String(&goi, &edm_sr_name, &edm_sr_name_len);
+       e = jim_getopt_string(&goi, &edm_sr_name, &edm_sr_name_len);
        if (e != JIM_OK)
                return e;
 
        jim_wide value;
-       e = Jim_GetOpt_Wide(&goi, &value);
+       e = jim_getopt_wide(&goi, &value);
        if (e != JIM_OK)
                return e;
 

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)