summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/devices
diff options
context:
space:
mode:
authorGustavo A. R. Silva2018-08-09 18:05:13 +0200
committerBoris Brezillon2018-11-09 20:32:43 +0100
commit98473f5acc0070624746f30a8d6012dc70487740 (patch)
tree4063ee53bf4036416798759e3d61af274250cb77 /drivers/mtd/devices
parentmtd: Kconfig: fix spelling mistake "partions" -> "partition" (diff)
downloadkernel-qcow2-linux-98473f5acc0070624746f30a8d6012dc70487740.tar.gz
kernel-qcow2-linux-98473f5acc0070624746f30a8d6012dc70487740.tar.xz
kernel-qcow2-linux-98473f5acc0070624746f30a8d6012dc70487740.zip
mtd: block2mtd: mark expected switch fall-throughs
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 402015 ("Missing break in switch") Addresses-Coverity-ID: 402016 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com> Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Diffstat (limited to 'drivers/mtd/devices')
-rw-r--r--drivers/mtd/devices/block2mtd.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/mtd/devices/block2mtd.c b/drivers/mtd/devices/block2mtd.c
index c9e424993e37..410a321682e6 100644
--- a/drivers/mtd/devices/block2mtd.c
+++ b/drivers/mtd/devices/block2mtd.c
@@ -329,8 +329,10 @@ static int ustrtoul(const char *cp, char **endp, unsigned int base)
switch (**endp) {
case 'G' :
result *= 1024;
+ /* fall through */
case 'M':
result *= 1024;
+ /* fall through */
case 'K':
case 'k':
result *= 1024;