drivers/net/ethernet/chelsio/cxgb4/sge.c:2396:13: warning: stack frame size of 1168 bytes in function 'ethofld_xmit'
From: kernel test robot
Date: Tue Mar 23 2021 - 02:38:31 EST
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 84196390620ac0e5070ae36af84c137c6216a7dc
commit: 97e4910232fa1f81e806aa60c25a0450276d99a2 linux/compiler-clang.h: define HAVE_BUILTIN_BSWAP*
date: 9 days ago
config: mips-randconfig-r023-20210322 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 78a65cd945d006ff02f9d24d9cc20a302ed93b08)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=97e4910232fa1f81e806aa60c25a0450276d99a2
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 97e4910232fa1f81e806aa60c25a0450276d99a2
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=mips
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>
All warnings (new ones prefixed by >>):
drivers/net/ethernet/chelsio/cxgb4/sge.c:814:28: warning: unused function 'calc_tx_descs' [-Wunused-function]
static inline unsigned int calc_tx_descs(const struct sk_buff *skb,
^
>> drivers/net/ethernet/chelsio/cxgb4/sge.c:2396:13: warning: stack frame size of 1168 bytes in function 'ethofld_xmit' [-Wframe-larger-than=]
static void ethofld_xmit(struct net_device *dev, struct sge_eosw_txq *eosw_txq)
^
2 warnings generated.
vim +/ethofld_xmit +2396 drivers/net/ethernet/chelsio/cxgb4/sge.c
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2395
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 @2396 static void ethofld_xmit(struct net_device *dev, struct sge_eosw_txq *eosw_txq)
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2397 {
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2398 struct sk_buff *skb;
4f1d97262d58e0 Rahul Lakkireddy 2020-05-15 2399 int pktcount, ret;
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2400
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2401 switch (eosw_txq->state) {
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2402 case CXGB4_EO_STATE_ACTIVE:
0e395b3cb1fb82 Rahul Lakkireddy 2019-11-07 2403 case CXGB4_EO_STATE_FLOWC_OPEN_SEND:
0e395b3cb1fb82 Rahul Lakkireddy 2019-11-07 2404 case CXGB4_EO_STATE_FLOWC_CLOSE_SEND:
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2405 pktcount = eosw_txq->pidx - eosw_txq->last_pidx;
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2406 if (pktcount < 0)
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2407 pktcount += eosw_txq->ndesc;
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2408 break;
0e395b3cb1fb82 Rahul Lakkireddy 2019-11-07 2409 case CXGB4_EO_STATE_FLOWC_OPEN_REPLY:
0e395b3cb1fb82 Rahul Lakkireddy 2019-11-07 2410 case CXGB4_EO_STATE_FLOWC_CLOSE_REPLY:
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2411 case CXGB4_EO_STATE_CLOSED:
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2412 default:
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2413 return;
272630feb4c0d2 Rahul Lakkireddy 2019-11-19 2414 }
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2415
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2416 while (pktcount--) {
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2417 skb = eosw_txq_peek(eosw_txq);
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2418 if (!skb) {
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2419 eosw_txq_advance_index(&eosw_txq->last_pidx, 1,
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2420 eosw_txq->ndesc);
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2421 continue;
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2422 }
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2423
4f1d97262d58e0 Rahul Lakkireddy 2020-05-15 2424 ret = ethofld_hard_xmit(dev, eosw_txq);
4f1d97262d58e0 Rahul Lakkireddy 2020-05-15 2425 if (ret)
4f1d97262d58e0 Rahul Lakkireddy 2020-05-15 2426 break;
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2427 }
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2428 }
4846d5330dafc8 Rahul Lakkireddy 2019-11-07 2429
:::::: The code at line 2396 was first introduced by commit
:::::: 4846d5330dafc82990be7ffe1d1b383157268bd9 cxgb4: add Tx and Rx path for ETHOFLD traffic
:::::: TO: Rahul Lakkireddy <rahul.lakkireddy@xxxxxxxxxxx>
:::::: CC: David S. Miller <davem@xxxxxxxxxxxxx>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx
Attachment:
.config.gz
Description: application/gzip