Skip to contentSkip to conversation

block/loop: mark expected switch fall-through

PATCH Applied Gustavo A. R. Silva 2 participants 2 messages Jul 2, 2018 Block layer

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 block/loop: mark expected switch fall-through

In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through.

---
 drivers/block/loop.c | 1 +
 1 file changed, 1 insertion(+)
drivers/block/loop.c +1 -0
index d6b6f43..ac47c23 100644
@@ -1611,6 +1611,7 @@ static int lo_compat_ioctl(struct block_device *bdev, fmode_t mode,
 	case LOOP_GET_STATUS64:
 	case LOOP_SET_STATUS64:
 		arg = (unsigned long) compat_ptr(arg);
+		/* fall through */
 	case LOOP_SET_FD:
 	case LOOP_CHANGE_FD:
 		err = lo_ioctl(bdev, mode, cmd, arg);
Signature · 1 line
2.7.4
maintainer Applied
#1 lore raw
Quoted 2 lines · Gustavo A. R. Silva

In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through.

Applied, thanks.

Signature · 1 line
Jens Axboe