pcmcia: db1xxx_ss: Mark expected switch fall-throughs
PATCH 1/1 pcmcia: db1xxx_ss: Mark expected switch fall-throughs
Mark switch cases where we are expecting to fall through.
This patch fixes the following warnings (Building: db1xxx_defconfig mips):
drivers/pcmcia/db1xxx_ss.c:257:3: warning: this statement may fall through [-Wimplicit-fallthrough=] drivers/pcmcia/db1xxx_ss.c:269:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
Signed-off-by Gustavo A. R. Silva <[email protected]>
--- drivers/pcmcia/db1xxx_ss.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/pcmcia/db1xxx_ss.c +4 -0
@@ -255,8 +255,10 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,switch (state->Vcc) {case 50 : ++v; +/* fall through */ case 33 : ++v; +/* fall through */ case 0 :break ;default :
@@ -267,9 +269,11 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,switch (state->Vpp) {case 12 : ++p; +/* fall through */ case 33 :case 50 : ++p; +/* fall through */ case 0 :break ;default :
Signature · 1 line
2.22.0
Quoted 8 lines · Gustavo A. R. Silva
Mark switch cases where we are expecting to fall through.
This patch fixes the following warnings (Building:
db1xxx_defconfigmips):
drivers/pcmcia/db1xxx_ss.c:257:3: warning: this statement may fall through [-Wimplicit-fallthrough=]drivers/pcmcia/db1xxx_ss.c:269:3: warning: this statement may fall through [-Wimplicit-fallthrough=]Signed-off-by Gustavo A. R. Silva <[email protected]>
Reviewed-by Kees Cook <[email protected]>
-Kees
Quoted 34 lines
--- drivers/pcmcia/db1xxx_ss.c | 4 ++++ 1 file changed, 4 insertions(+)drivers/pcmcia/db1xxx_ss.c +4
-0@@ -255,8 +255,10 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,switch (state->Vcc) {case 50 : ++v; +/* fall through */ case 33 : ++v; +/* fall through */ case 0 :break ;default :@@ -267,9 +269,11 @@ static int db1x_pcmcia_configure(struct pcmcia_socket *skt,switch (state->Vpp) {case 12 : ++p; +/* fall through */ case 33 :case 50 : ++p; +/* fall through */ case 0 :break ;default :Signature · 1 line
2.22.0
Signature · 1 line
Kees Cook