diff mbox

[1/5] bfq: Annotate fall-through in a switch statement

Message ID 20170830184211.12471-2-bart.vanassche@wdc.com (mailing list archive)
State New, archived
Headers show

Commit Message

Bart Van Assche Aug. 30, 2017, 6:42 p.m. UTC
This patch avoids that gcc 7 issues a warning about fall-through
when building with W=1.

Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
Cc: Paolo Valente <paolo.valente@linaro.org>
---
 block/bfq-iosched.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Paolo Valente Sept. 1, 2017, 5:14 p.m. UTC | #1
> Il giorno 30 ago 2017, alle ore 20:42, Bart Van Assche <bart.vanassche@wdc.com> ha scritto:
> 
> This patch avoids that gcc 7 issues a warning about fall-through
> when building with W=1.
> 
> Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
> Cc: Paolo Valente <paolo.valente@linaro.org>

Acked-by: Paolo Valente <paolo.valente@linaro.org>

> ---
> block/bfq-iosched.c | 1 +
> 1 file changed, 1 insertion(+)
> 
> diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c
> index 6a7a26b6cec1..8c11c2e827a5 100644
> --- a/block/bfq-iosched.c
> +++ b/block/bfq-iosched.c
> @@ -3780,6 +3780,7 @@ bfq_set_next_ioprio_data(struct bfq_queue *bfqq, struct bfq_io_cq *bic)
> 	default:
> 		dev_err(bfqq->bfqd->queue->backing_dev_info->dev,
> 			"bfq: bad prio class %d\n", ioprio_class);
> +		/* fall through */
> 	case IOPRIO_CLASS_NONE:
> 		/*
> 		 * No prio set, inherit CPU scheduling settings.
> -- 
> 2.14.1
>
diff mbox

Patch

diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c
index 6a7a26b6cec1..8c11c2e827a5 100644
--- a/block/bfq-iosched.c
+++ b/block/bfq-iosched.c
@@ -3780,6 +3780,7 @@  bfq_set_next_ioprio_data(struct bfq_queue *bfqq, struct bfq_io_cq *bic)
 	default:
 		dev_err(bfqq->bfqd->queue->backing_dev_info->dev,
 			"bfq: bad prio class %d\n", ioprio_class);
+		/* fall through */
 	case IOPRIO_CLASS_NONE:
 		/*
 		 * No prio set, inherit CPU scheduling settings.