[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <lsq.1438473757.968265153@decadent.org.uk>
Date: Sun, 02 Aug 2015 01:02:37 +0100
From: Ben Hutchings <ben@...adent.org.uk>
To: linux-kernel@...r.kernel.org, stable@...r.kernel.org
CC: akpm@...ux-foundation.org,
"Mark Brown" <broonie@...nsource.wolfsonmicro.com>,
"David Woodhouse" <dwmw2@...radead.org>,
"Nicolas Iooss" <nicolas.iooss_linux@....org>,
"Linus Torvalds" <torvalds@...ux-foundation.org>
Subject: [PATCH 3.2 047/164] firmware/ihex2fw.c: restore missing default
in switch statement
3.2.70-rc1 review patch. If anyone has any objections, please let me know.
------------------
From: Nicolas Iooss <nicolas.iooss_linux@....org>
commit d43698e8abb58a6ac47d16e0f47bb55f452e4fc4 upstream.
Commit 2473238eac95 ("ihex: add support for CS:IP/EIP records") removes
the "default:" statement in the switch block, making the "return
usage();" line dead code and ihex2fw silently ignoring unknown options.
Restore this statement.
This bug was found by building with HOSTCC=clang and adding
-Wunreachable-code-return to HOSTCFLAGS.
Fixes: 2473238eac95 ("ihex: add support for CS:IP/EIP records")
Signed-off-by: Nicolas Iooss <nicolas.iooss_linux@....org>
Cc: Mark Brown <broonie@...nsource.wolfsonmicro.com>
Cc: David Woodhouse <dwmw2@...radead.org>
Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@...ux-foundation.org>
Signed-off-by: Ben Hutchings <ben@...adent.org.uk>
---
firmware/ihex2fw.c | 1 +
1 file changed, 1 insertion(+)
--- a/firmware/ihex2fw.c
+++ b/firmware/ihex2fw.c
@@ -86,6 +86,7 @@ int main(int argc, char **argv)
case 'j':
include_jump = 1;
break;
+ default:
return usage();
}
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists