linux_old1/drivers/nfc/st21nfca
Gustavo A. R. Silva a01bcfd699 NFC: st21nfca: Fix fall-through warnings
In preparation to enabling -Wimplicit-fallthrough, mark switch
cases where we are expecting to fall through.

This patch fixes the following warnings by adding a missing break
and a fall-through annotation:

drivers/nfc/st21nfca/dep.c: In function ‘st21nfca_tm_event_send_data’:
drivers/nfc/st21nfca/dep.c:391:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
   switch (cmd1) {
   ^~~~~~
drivers/nfc/st21nfca/dep.c:404:2: note: here
  default:
  ^~~~~~~
In file included from ./include/linux/kernel.h:15,
                 from ./include/linux/skbuff.h:17,
                 from ./include/net/nfc/hci.h:21,
                 from drivers/nfc/st21nfca/dep.c:17:
drivers/nfc/st21nfca/dep.c: In function ‘st21nfca_im_recv_dep_res_cb’:
./include/linux/printk.h:303:2: warning: this statement may fall through [-Wimplicit-fallthrough=]
  printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/nfc/st21nfca/dep.c:622:4: note: in expansion of macro ‘pr_err’
    pr_err("Received a ACK/NACK PDU\n");
    ^~~~~~
drivers/nfc/st21nfca/dep.c:623:3: note: here
   case ST21NFCA_NFC_DEP_PFB_I_PDU:
   ^~~~

Warning level 3 was used: -Wimplicit-fallthrough=3

This patch is part of the ongoing efforts to enable
-Wimplicit-fallthrough.

Reviewed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
2019-04-09 12:08:27 -05:00
..
Kconfig NFC: st21nfca: Auto-select core module 2015-12-29 19:06:19 +01:00
Makefile NFC: st21nfca: Add support for proprietary commands 2015-10-27 04:00:24 +01:00
core.c networking: make skb_push & __skb_push return void pointers 2017-06-16 11:48:40 -04:00
dep.c NFC: st21nfca: Fix fall-through warnings 2019-04-09 12:08:27 -05:00
i2c.c nfc: st21nfca: constify i2c_device_id 2017-11-06 00:56:56 +01:00
se.c treewide: setup_timer() -> timer_setup() (2 field) 2017-11-21 15:57:09 -08:00
st21nfca.h NFC: st21nfca: Add support for proprietary commands 2015-10-27 04:00:24 +01:00
vendor_cmds.c NFC: st21nfca: Add support for proprietary commands 2015-10-27 04:00:24 +01:00