OpenCloudOS-Kernel/drivers/net/ethernet/cavium/thunder
Arnd Bergmann c41626ce31 net: thunder_bgx: avoid format string overflow warning
gcc warns that the temporary buffer might be too small here:

drivers/net/ethernet/cavium/thunder/thunder_bgx.c: In function 'bgx_probe':
drivers/net/ethernet/cavium/thunder/thunder_bgx.c:1020:16: error: '%d' directive writing between 1 and 10 bytes into a region of size between 9 and 11 [-Werror=format-overflow=]
sprintf(str, "BGX%d LMAC%d mode", bgx->bgx_id, lmacid);
             ^~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/cavium/thunder/thunder_bgx.c:1020:16: note: directive argument in the range [0, 2147483647]
drivers/net/ethernet/cavium/thunder/thunder_bgx.c:1020:3: note: 'sprintf' output between 16 and 27 bytes into a destination of size 20

This probably can't happen, but it can't hurt to make it long
enough for the theoretical limit.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-07-14 09:03:11 -07:00
..
Makefile net: thunderx: Add RGMII interface type support 2016-08-13 11:59:31 -07:00
nic.h net: thunderx: Add basic XDP support 2017-05-02 15:41:21 -04:00
nic_main.c net: thunderx: Switch to pci_alloc_irq_vectors 2017-04-11 11:16:03 -04:00
nic_reg.h net: thunderx: Program LMAC credits based on MTU 2016-11-16 13:28:33 -05:00
nicvf_ethtool.c net: thunderx: Add basic XDP support 2017-05-02 15:41:21 -04:00
nicvf_main.c cavium: thunder: Remove duplicate "netdev->name" logging output 2017-06-29 12:25:33 -04:00
nicvf_queues.c cavium: thunder: Remove duplicate "netdev->name" logging output 2017-06-29 12:25:33 -04:00
nicvf_queues.h net: thunderx: Optimize page recycling for XDP 2017-05-02 15:41:22 -04:00
q_struct.h net: thunderx: Optimize RBDR descriptor handling 2017-05-02 15:41:20 -04:00
thunder_bgx.c net: thunder_bgx: avoid format string overflow warning 2017-07-14 09:03:11 -07:00
thunder_bgx.h net: thunderx: Fix set_max_bgx_per_node for 81xx rgx 2017-04-17 13:03:48 -04:00
thunder_xcv.c net: thunderx: avoid dereferencing xcv when NULL 2017-01-31 13:07:40 -05:00