From: Timo Ketola Date: Tue, 17 Jan 2012 08:47:11 +0000 (+0200) Subject: NAND: Misleading report of erased blocks X-Git-Tag: v0.6.0-rc1~284 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=f50ca7c184bf1c02ed6102cfffcc2ca7b4ef4116;p=openocd NAND: Misleading report of erased blocks For example, when blocks 2 and 3 were erased, openocd reported "erased blocks 2 to 4". That should be "2 to 3", I think. Change-Id: Icece63dedd3dd931b70fa73616819a19572e39de Signed-off-by: Timo Ketola Reviewed-on: http://openocd.zylin.com/385 Tested-by: jenkins Reviewed-by: Spencer Oliver --- diff --git a/src/flash/nand/tcl.c b/src/flash/nand/tcl.c index 63893779..c52c347f 100644 --- a/src/flash/nand/tcl.c +++ b/src/flash/nand/tcl.c @@ -196,7 +196,7 @@ COMMAND_HANDLER(handle_nand_erase_command) { command_print(CMD_CTX, "erased blocks %lu to %lu " "on NAND flash device #%s '%s'", - offset, offset + length, + offset, offset + length - 1, CMD_ARGV[0], p->device->name); }