[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202505071739.xTGCCtUx-lkp@intel.com>
Date: Wed, 7 May 2025 18:03:45 +0800
From: kernel test robot <lkp@...el.com>
To: Tanmay Jagdale <tanmay@...vell.com>, bbrezillon@...nel.org,
arno@...isbad.org, schalla@...vell.com, herbert@...dor.apana.org.au,
davem@...emloft.net, sgoutham@...vell.com, lcherian@...vell.com,
gakula@...vell.com, jerinj@...vell.com, hkelam@...vell.com,
sbhatta@...vell.com, andrew+netdev@...n.ch, edumazet@...gle.com,
kuba@...nel.org, pabeni@...hat.com, bbhushan2@...vell.com,
bhelgaas@...gle.com, pstanner@...hat.com,
gregkh@...uxfoundation.org, peterz@...radead.org, linux@...blig.org,
krzysztof.kozlowski@...aro.org, giovanni.cabiddu@...el.com
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
linux-crypto@...r.kernel.org, linux-kernel@...r.kernel.org,
netdev@...r.kernel.org, rkannoth@...vell.com, sumang@...vell.com,
gcherian@...vell.com, Tanmay Jagdale <tanmay@...vell.com>
Subject: Re: [net-next PATCH v1 10/15] octeontx2-pf: ipsec: Setup NIX HW
resources for inbound flows
Hi Tanmay,
kernel test robot noticed the following build warnings:
[auto build test WARNING on net-next/main]
url: https://github.com/intel-lab-lkp/linux/commits/Tanmay-Jagdale/crypto-octeontx2-Share-engine-group-info-with-AF-driver/20250502-213203
base: net-next/main
patch link: https://lore.kernel.org/r/20250502132005.611698-11-tanmay%40marvell.com
patch subject: [net-next PATCH v1 10/15] octeontx2-pf: ipsec: Setup NIX HW resources for inbound flows
config: x86_64-allyesconfig (https://download.01.org/0day-ci/archive/20250507/202505071739.xTGCCtUx-lkp@intel.com/config)
compiler: clang version 20.1.2 (https://github.com/llvm/llvm-project 58df0ef89dd64126512e4ee27b4ac3fd8ddf6247)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250507/202505071739.xTGCCtUx-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202505071739.xTGCCtUx-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c:488:6: warning: variable 'pool' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
488 | if (err)
| ^~~
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c:512:23: note: uninitialized use occurs here
512 | qmem_free(pfvf->dev, pool->stack);
| ^~~~
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c:488:2: note: remove the 'if' if its condition is always false
488 | if (err)
| ^~~~~~~~
489 | goto pool_fail;
| ~~~~~~~~~~~~~~
drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c:466:24: note: initialize the variable 'pool' to silence this warning
466 | struct otx2_pool *pool;
| ^
| = NULL
1 warning generated.
vim +488 drivers/net/ethernet/marvell/octeontx2/nic/cn10k_ipsec.c
461
462 static int cn10k_ipsec_setup_nix_rx_hw_resources(struct otx2_nic *pfvf)
463 {
464 struct otx2_hw *hw = &pfvf->hw;
465 int stack_pages, pool_id;
466 struct otx2_pool *pool;
467 int err, ptr, num_ptrs;
468 dma_addr_t bufptr;
469
470 num_ptrs = 256;
471 pool_id = pfvf->ipsec.inb_ipsec_pool;
472 stack_pages = (num_ptrs + hw->stack_pg_ptrs - 1) / hw->stack_pg_ptrs;
473
474 mutex_lock(&pfvf->mbox.lock);
475
476 /* Initialize aura context */
477 err = cn10k_ipsec_ingress_aura_init(pfvf, pool_id, pool_id, num_ptrs);
478 if (err)
479 goto fail;
480
481 /* Initialize pool */
482 err = otx2_pool_init(pfvf, pool_id, stack_pages, num_ptrs, pfvf->rbsize, AURA_NIX_RQ);
483 if (err)
484 goto fail;
485
486 /* Flush accumulated messages */
487 err = otx2_sync_mbox_msg(&pfvf->mbox);
> 488 if (err)
489 goto pool_fail;
490
491 /* Allocate pointers and free them to aura/pool */
492 pool = &pfvf->qset.pool[pool_id];
493 for (ptr = 0; ptr < num_ptrs; ptr++) {
494 err = otx2_alloc_rbuf(pfvf, pool, &bufptr, pool_id, ptr);
495 if (err) {
496 err = -ENOMEM;
497 goto pool_fail;
498 }
499 pfvf->hw_ops->aura_freeptr(pfvf, pool_id, bufptr + OTX2_HEAD_ROOM);
500 }
501
502 /* Initialize RQ and map buffers from pool_id */
503 err = cn10k_ipsec_ingress_rq_init(pfvf, pfvf->ipsec.inb_ipsec_rq, pool_id);
504 if (err)
505 goto pool_fail;
506
507 mutex_unlock(&pfvf->mbox.lock);
508 return 0;
509
510 pool_fail:
511 mutex_unlock(&pfvf->mbox.lock);
512 qmem_free(pfvf->dev, pool->stack);
513 qmem_free(pfvf->dev, pool->fc_addr);
514 page_pool_destroy(pool->page_pool);
515 devm_kfree(pfvf->dev, pool->xdp);
516 pool->xsk_pool = NULL;
517 fail:
518 otx2_mbox_reset(&pfvf->mbox.mbox, 0);
519 return err;
520 }
521
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists