Commit d290e096 authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Linus Walleij

pinctrl: lpc18xx: mark expected switch fall-throughs

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

Addresses-Coverity-ID: 1292308 ("Missing break in switch")
Addresses-Coverity-ID: 1292309 ("Missing break in switch")
Addresses-Coverity-ID: 1309546 ("Missing break in switch")
Addresses-Coverity-ID: 1357369 ("Missing break in switch")
Addresses-Coverity-ID: 1357389 ("Missing break in switch")
Reviewed-by: default avatarVladimir Zapolskiy <vz@mleia.com>
Signed-off-by: default avatarGustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 375fef59
...@@ -844,8 +844,11 @@ static int lpc18xx_pconf_get_pin(struct pinctrl_dev *pctldev, unsigned param, ...@@ -844,8 +844,11 @@ static int lpc18xx_pconf_get_pin(struct pinctrl_dev *pctldev, unsigned param,
*arg = (reg & LPC18XX_SCU_PIN_EHD_MASK) >> LPC18XX_SCU_PIN_EHD_POS; *arg = (reg & LPC18XX_SCU_PIN_EHD_MASK) >> LPC18XX_SCU_PIN_EHD_POS;
switch (*arg) { switch (*arg) {
case 3: *arg += 5; case 3: *arg += 5;
/* fall through */
case 2: *arg += 5; case 2: *arg += 5;
/* fall through */
case 1: *arg += 3; case 1: *arg += 3;
/* fall through */
case 0: *arg += 4; case 0: *arg += 4;
} }
break; break;
...@@ -1060,8 +1063,11 @@ static int lpc18xx_pconf_set_pin(struct pinctrl_dev *pctldev, unsigned param, ...@@ -1060,8 +1063,11 @@ static int lpc18xx_pconf_set_pin(struct pinctrl_dev *pctldev, unsigned param,
switch (param_val) { switch (param_val) {
case 20: param_val -= 5; case 20: param_val -= 5;
/* fall through */
case 14: param_val -= 5; case 14: param_val -= 5;
/* fall through */
case 8: param_val -= 3; case 8: param_val -= 3;
/* fall through */
case 4: param_val -= 4; case 4: param_val -= 4;
break; break;
default: default:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment