mtd: spi-nor: mark desirable switch case fall through

gcc 7 with -Wimplicit-fallthrough raises:

drivers/mtd/spi-nor/spi-nor.c: In function ‘set_4byte’:
drivers/mtd/spi-nor/spi-nor.c:289:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
   need_wren = true;
   ~~~~~~~~~~^~~~~~
drivers/mtd/spi-nor/spi-nor.c:290:2: note: here
  case SNOR_MFR_MACRONIX:
  ^~~~

Quiet the warning by marking the expected switch fall through.

Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
This commit is contained in:
Tudor.Ambarus@microchip.com 2018-11-09 17:40:21 +00:00 committed by Boris Brezillon
parent 8155417137
commit f66734ae2d
1 changed files with 1 additions and 0 deletions

View File

@ -287,6 +287,7 @@ static inline int set_4byte(struct spi_nor *nor, const struct flash_info *info,
case SNOR_MFR_MICRON:
/* Some Micron need WREN command; all will accept it */
need_wren = true;
/* fall through */
case SNOR_MFR_MACRONIX:
case SNOR_MFR_WINBOND:
if (need_wren)