summaryrefslogtreecommitdiff
path: root/cmd/mtdparts.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2017-12-04 13:48:21 -0700
committerTom Rini <trini@konsulko.com>2017-12-07 15:17:00 -0500
commit95b41b80d77b8418dac3393784b2a9cbb7abef64 (patch)
treed652ee6938ca786c6ccc4ad3a8587556eb6b3f57 /cmd/mtdparts.c
parent0e98b0a65092d6573eb17d07e04455f9cf545b21 (diff)
mtdparts: Correct use of debug()
The debug() macro now evaluates its expression so does not need #ifdef protection. In fact the current code causes a warning with the new log implementation. Adjust the code to fix this. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'cmd/mtdparts.c')
-rw-r--r--cmd/mtdparts.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/cmd/mtdparts.c b/cmd/mtdparts.c
index 3169c33265..9bc977450c 100644
--- a/cmd/mtdparts.c
+++ b/cmd/mtdparts.c
@@ -873,15 +873,12 @@ static int device_parse(const char *const mtd_dev, const char **ret, struct mtd_
return 1;
}
-#ifdef DEBUG
pend = strchr(p, ';');
-#endif
debug("dev type = %d (%s), dev num = %d, mtd-id = %s\n",
id->type, MTD_DEV_TYPE(id->type),
id->num, id->mtd_id);
debug("parsing partitions %.*s\n", (int)(pend ? pend - p : strlen(p)), p);
-
/* parse partitions */
num_parts = 0;