]> git.baikalelectronics.ru Git - kernel.git/commitdiff
kdb: remove redundant assignment to pointer bp
authorColin Ian King <colin.king@canonical.com>
Thu, 28 Nov 2019 13:07:53 +0000 (13:07 +0000)
committerDaniel Thompson <daniel.thompson@linaro.org>
Fri, 31 Jan 2020 17:34:06 +0000 (17:34 +0000)
The point bp is assigned a value that is never read, it is being
re-assigned later to bp = &kdb_breakpoints[lowbp] in a for-loop.
Remove the redundant assignment.

Addresses-Coverity ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20191128130753.181246-1-colin.king@canonical.com
Signed-off-by: Daniel Thompson <daniel.thompson@linaro.org>
kernel/debug/kdb/kdb_bp.c

index 62c301ad07735c8b5713aebe8980f8c61d44a83b..d7ebb2c79cb867793bc0aa6832142c401e71917a 100644 (file)
@@ -412,7 +412,6 @@ static int kdb_bc(int argc, const char **argv)
                 * assume that the breakpoint number is desired.
                 */
                if (addr < KDB_MAXBPT) {
-                       bp = &kdb_breakpoints[addr];
                        lowbp = highbp = addr;
                        highbp++;
                } else {