scsi: myrb: Mark expected switch fall-throughs
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Wed, 28 Nov 2018 04:32:52 +0000 (22:32 -0600)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 21 Dec 2018 00:51:39 +0000 (19:51 -0500)
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where
we are expecting to fall through.

Addresses-Coverity-ID: 1465234 ("Missing break in switch")
Addresses-Coverity-ID: 1465238 ("Missing break in switch")
Addresses-Coverity-ID: 1465242 ("Missing break in switch")
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/myrb.c

index aeb282f..1c8956c 100644 (file)
@@ -1527,6 +1527,7 @@ static int myrb_ldev_queuecommand(struct Scsi_Host *shost,
                        scmd->scsi_done(scmd);
                        return 0;
                }
+               /* fall through */
        case WRITE_6:
                lba = (((scmd->cmnd[1] & 0x1F) << 16) |
                       (scmd->cmnd[2] << 8) |
@@ -1543,6 +1544,7 @@ static int myrb_ldev_queuecommand(struct Scsi_Host *shost,
                        scmd->scsi_done(scmd);
                        return 0;
                }
+               /* fall through */
        case WRITE_10:
        case VERIFY:            /* 0x2F */
        case WRITE_VERIFY:      /* 0x2E */
@@ -1559,6 +1561,7 @@ static int myrb_ldev_queuecommand(struct Scsi_Host *shost,
                        scmd->scsi_done(scmd);
                        return 0;
                }
+               /* fall through */
        case WRITE_12:
        case VERIFY_12: /* 0xAF */
        case WRITE_VERIFY_12:   /* 0xAE */