diff options
author | Gustavo A. R. Silva <garsilva@embeddedor.com> | 2017-11-10 13:23:14 -0500 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2017-11-10 13:29:54 -0500 |
commit | 005161c864e1d0aedbbdac13ce75696b954d4e44 (patch) | |
tree | 804d2be1c929592c0180702135a276a7a7d07bbb | |
parent | 781f2dd0a5eb8e660c0a5dbb11a69aed72f26657 (diff) |
Input: spaceball - mark expected switch fall-throughs
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.
Addresses-Coverity-ID: 114767
Addresses-Coverity-ID: 114768
Addresses-Coverity-ID: 114769
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
-rw-r--r-- | drivers/input/joystick/spaceball.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/input/joystick/spaceball.c b/drivers/input/joystick/spaceball.c index e9712a1b7cad..bb3faeff8cac 100644 --- a/drivers/input/joystick/spaceball.c +++ b/drivers/input/joystick/spaceball.c | |||
@@ -162,6 +162,7 @@ static irqreturn_t spaceball_interrupt(struct serio *serio, | |||
162 | break; | 162 | break; |
163 | } | 163 | } |
164 | spaceball->escape = 0; | 164 | spaceball->escape = 0; |
165 | /* fall through */ | ||
165 | case 'M': | 166 | case 'M': |
166 | case 'Q': | 167 | case 'Q': |
167 | case 'S': | 168 | case 'S': |
@@ -169,6 +170,7 @@ static irqreturn_t spaceball_interrupt(struct serio *serio, | |||
169 | spaceball->escape = 0; | 170 | spaceball->escape = 0; |
170 | data &= 0x1f; | 171 | data &= 0x1f; |
171 | } | 172 | } |
173 | /* fall through */ | ||
172 | default: | 174 | default: |
173 | if (spaceball->escape) | 175 | if (spaceball->escape) |
174 | spaceball->escape = 0; | 176 | spaceball->escape = 0; |
@@ -234,11 +236,13 @@ static int spaceball_connect(struct serio *serio, struct serio_driver *drv) | |||
234 | input_dev->keybit[BIT_WORD(BTN_A)] |= BIT_MASK(BTN_A) | | 236 | input_dev->keybit[BIT_WORD(BTN_A)] |= BIT_MASK(BTN_A) | |
235 | BIT_MASK(BTN_B) | BIT_MASK(BTN_C) | | 237 | BIT_MASK(BTN_B) | BIT_MASK(BTN_C) | |
236 | BIT_MASK(BTN_MODE); | 238 | BIT_MASK(BTN_MODE); |
239 | /* fall through */ | ||
237 | default: | 240 | default: |
238 | input_dev->keybit[BIT_WORD(BTN_0)] |= BIT_MASK(BTN_2) | | 241 | input_dev->keybit[BIT_WORD(BTN_0)] |= BIT_MASK(BTN_2) | |
239 | BIT_MASK(BTN_3) | BIT_MASK(BTN_4) | | 242 | BIT_MASK(BTN_3) | BIT_MASK(BTN_4) | |
240 | BIT_MASK(BTN_5) | BIT_MASK(BTN_6) | | 243 | BIT_MASK(BTN_5) | BIT_MASK(BTN_6) | |
241 | BIT_MASK(BTN_7) | BIT_MASK(BTN_8); | 244 | BIT_MASK(BTN_7) | BIT_MASK(BTN_8); |
245 | /* fall through */ | ||
242 | case SPACEBALL_3003C: | 246 | case SPACEBALL_3003C: |
243 | input_dev->keybit[BIT_WORD(BTN_0)] |= BIT_MASK(BTN_1) | | 247 | input_dev->keybit[BIT_WORD(BTN_0)] |= BIT_MASK(BTN_1) | |
244 | BIT_MASK(BTN_8); | 248 | BIT_MASK(BTN_8); |