summaryrefslogtreecommitdiffstats
path: root/drivers/dma/bestcomm/bcom_fec_rx_task.c
diff options
context:
space:
mode:
authorArnd Bergmann2016-12-08 22:57:04 +0100
committerDavid S. Miller2016-12-09 03:30:54 +0100
commitdece303fa3aaaf1dbaf4ddd95e8af1c16ceb7bb1 (patch)
tree8182fdc31878ed2137be7619dadb91110e9892ed /drivers/dma/bestcomm/bcom_fec_rx_task.c
parentnet/mlx5e: use %pad format string for dma_addr_t (diff)
downloadkernel-qcow2-linux-dece303fa3aaaf1dbaf4ddd95e8af1c16ceb7bb1.tar.gz
kernel-qcow2-linux-dece303fa3aaaf1dbaf4ddd95e8af1c16ceb7bb1.tar.xz
kernel-qcow2-linux-dece303fa3aaaf1dbaf4ddd95e8af1c16ceb7bb1.zip
net: xgene: move xgene_cle_ptree_ewdn data off stack
The array for initializing the cle is set up on the stack with almost entirely constant data and then passed to a function that converts it into HW specific bit patterns. With the latest addition, the size of this array has grown to the point that we get a warning about potential stack overflow in allmodconfig builds: xgene_enet_cle.c: In function ‘xgene_enet_cle_init’: xgene_enet_cle.c:836:1: error: the frame size of 1032 bytes is larger than 1024 bytes [-Werror=frame-larger-than=] Looking a bit deeper at the usage, I noticed that the only modification of the data is in dead code, as we don't even use the cle module for phy_mode other than PHY_INTERFACE_MODE_XGMII. This means we can simply mark the structure constant and access it directly rather than passing the pointer down through another structure, making the code more efficient at the same time as avoiding the warning. Fixes: a809701fed15 ("drivers: net: xgene: fix: RSS for non-TCP/UDP") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/dma/bestcomm/bcom_fec_rx_task.c')
0 files changed, 0 insertions, 0 deletions