X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2Ftarget%2Ftarget.c;h=68f93210a5e400f6122b2147f70f34f641db08f1;hb=2a3b709aa5d1ab83faed1dc7c296ffc117022d62;hp=1ca6c8e53c1d73eac7879d5a289f4ca751a8be97;hpb=d04254196e383965627d4eab805f9b1b93240e69;p=openocd.git diff --git a/src/target/target.c b/src/target/target.c index 1ca6c8e53c..68f93210a5 100644 --- a/src/target/target.c +++ b/src/target/target.c @@ -107,6 +107,7 @@ extern struct target_type or1k_target; extern struct target_type quark_x10xx_target; extern struct target_type quark_d20xx_target; extern struct target_type stm8_target; +extern struct target_type riscv_target; static struct target_type *target_types[] = { &arm7tdmi_target, @@ -139,6 +140,7 @@ static struct target_type *target_types[] = { &quark_x10xx_target, &quark_d20xx_target, &stm8_target, + &riscv_target, #if BUILD_TARGET64 &aarch64_target, #endif @@ -4131,8 +4133,9 @@ static int target_mem2array(Jim_Interp *interp, struct target *target, int argc, * argv[3] = memory address * argv[4] = count of times to read */ + if (argc < 4 || argc > 5) { - Jim_WrongNumArgs(interp, 1, argv, "varname width addr nelems [phys]"); + Jim_WrongNumArgs(interp, 0, argv, "varname width addr nelems [phys]"); return JIM_ERR; } varname = Jim_GetString(argv[0], &len);