summaryrefslogtreecommitdiff
path: root/src/flash/davinci_nand.c
diff options
context:
space:
mode:
authorZachary T Welch <zw@superlucidity.net>2009-11-15 08:15:59 -0800
committerZachary T Welch <zw@superlucidity.net>2009-11-17 11:38:07 -0800
commit23402315ce01071f30d7ec0c5ca7563ce41f1cc6 (patch)
tree2b1cad0044d857844f7d6b35b5ffadd390594c9b /src/flash/davinci_nand.c
parent7bf1a86e473a12882bf6f71cb4d0d416394b69d4 (diff)
downloadopenocd+libswd-23402315ce01071f30d7ec0c5ca7563ce41f1cc6.tar.gz
openocd+libswd-23402315ce01071f30d7ec0c5ca7563ce41f1cc6.tar.bz2
openocd+libswd-23402315ce01071f30d7ec0c5ca7563ce41f1cc6.tar.xz
openocd+libswd-23402315ce01071f30d7ec0c5ca7563ce41f1cc6.zip
command_handler: change 'args' to CMD_ARGV
This patch converts all instances of 'args' in COMMAND_HANDLER routines to use CMD_ARGV macro.
Diffstat (limited to 'src/flash/davinci_nand.c')
-rw-r--r--src/flash/davinci_nand.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/flash/davinci_nand.c b/src/flash/davinci_nand.c
index 7c68be70..ebd9ba8d 100644
--- a/src/flash/davinci_nand.c
+++ b/src/flash/davinci_nand.c
@@ -648,36 +648,36 @@ NAND_DEVICE_COMMAND_HANDLER(davinci_nand_device_command)
if (CMD_ARGC < 5) {
LOG_ERROR("parameters: %s target "
"chip_addr hwecc_mode aemif_addr",
- args[0]);
+ CMD_ARGV[0]);
goto fail;
}
- target = get_target(args[1]);
+ target = get_target(CMD_ARGV[1]);
if (!target) {
- LOG_ERROR("invalid target %s", args[1]);
+ LOG_ERROR("invalid target %s", CMD_ARGV[1]);
goto fail;
}
- COMMAND_PARSE_NUMBER(ulong, args[2], chip);
+ COMMAND_PARSE_NUMBER(ulong, CMD_ARGV[2], chip);
if (chip == 0) {
- LOG_ERROR("Invalid NAND chip address %s", args[2]);
+ LOG_ERROR("Invalid NAND chip address %s", CMD_ARGV[2]);
goto fail;
}
- if (strcmp(args[3], "hwecc1") == 0)
+ if (strcmp(CMD_ARGV[3], "hwecc1") == 0)
eccmode = HWECC1;
- else if (strcmp(args[3], "hwecc4") == 0)
+ else if (strcmp(CMD_ARGV[3], "hwecc4") == 0)
eccmode = HWECC4;
- else if (strcmp(args[3], "hwecc4_infix") == 0)
+ else if (strcmp(CMD_ARGV[3], "hwecc4_infix") == 0)
eccmode = HWECC4_INFIX;
else {
- LOG_ERROR("Invalid ecc mode %s", args[3]);
+ LOG_ERROR("Invalid ecc mode %s", CMD_ARGV[3]);
goto fail;
}
- COMMAND_PARSE_NUMBER(ulong, args[4], aemif);
+ COMMAND_PARSE_NUMBER(ulong, CMD_ARGV[4], aemif);
if (aemif == 0) {
- LOG_ERROR("Invalid AEMIF controller address %s", args[4]);
+ LOG_ERROR("Invalid AEMIF controller address %s", CMD_ARGV[4]);
goto fail;
}