lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202210280111.BGgDManp-lkp@intel.com>
Date:   Fri, 28 Oct 2022 01:56:14 +0800
From:   kernel test robot <lkp@...el.com>
To:     Ajit Khaparde <ajit.khaparde@...adcom.com>
Cc:     oe-kbuild-all@...ts.linux.dev, andrew.gospodarek@...adcom.com,
        davem@...emloft.net, edumazet@...gle.com, jgg@...pe.ca,
        kuba@...nel.org, leon@...nel.org, linux-kernel@...r.kernel.org,
        linux-rdma@...r.kernel.org, michael.chan@...adcom.com,
        netdev@...r.kernel.org, pabeni@...hat.com,
        selvin.xavier@...adcom.com, Leon Romanovsky <leonro@...dia.com>
Subject: Re: [PATCH v2 4/6] bnxt_en: Use direct API instead of indirection

Hi Ajit,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linus/master]
[also build test WARNING on v6.1-rc2 next-20221027]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Ajit-Khaparde/bnxt_en-Add-auxiliary-driver-support/20221026-023141
patch link:    https://lore.kernel.org/r/20221025173110.33192-5-ajit.khaparde%40broadcom.com
patch subject: [PATCH v2 4/6] bnxt_en: Use direct API instead of indirection
config: alpha-randconfig-s043-20221027
compiler: alpha-linux-gcc (GCC) 12.1.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.4-39-gce1a6720-dirty
        # https://github.com/intel-lab-lkp/linux/commit/8a686d1e144cadf339178010e72fa69287954a6a
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Ajit-Khaparde/bnxt_en-Add-auxiliary-driver-support/20221026-023141
        git checkout 8a686d1e144cadf339178010e72fa69287954a6a
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=alpha SHELL=/bin/bash drivers/net/ethernet/broadcom/bnxt/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>

sparse warnings: (new ones prefixed by >>)
>> drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:51:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
>> drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:51:9: sparse:    struct bnxt_ulp_ops [noderef] __rcu *
>> drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:51:9: sparse:    struct bnxt_ulp_ops *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:282:15: sparse: sparse: incompatible types in comparison expression (different address spaces):
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:282:15: sparse:    struct bnxt_ulp_ops [noderef] __rcu *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:282:15: sparse:    struct bnxt_ulp_ops *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:303:15: sparse: sparse: incompatible types in comparison expression (different address spaces):
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:303:15: sparse:    struct bnxt_ulp_ops [noderef] __rcu *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:303:15: sparse:    struct bnxt_ulp_ops *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:318:15: sparse: sparse: incompatible types in comparison expression (different address spaces):
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:318:15: sparse:    struct bnxt_ulp_ops [noderef] __rcu *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:318:15: sparse:    struct bnxt_ulp_ops *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:341:23: sparse: sparse: incompatible types in comparison expression (different address spaces):
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:341:23: sparse:    struct bnxt_ulp_ops [noderef] __rcu *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:341:23: sparse:    struct bnxt_ulp_ops *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:363:23: sparse: sparse: incompatible types in comparison expression (different address spaces):
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:363:23: sparse:    struct bnxt_ulp_ops [noderef] __rcu *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:363:23: sparse:    struct bnxt_ulp_ops *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:391:15: sparse: sparse: incompatible types in comparison expression (different address spaces):
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:391:15: sparse:    struct bnxt_ulp_ops [noderef] __rcu *
   drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c:391:15: sparse:    struct bnxt_ulp_ops *

vim +51 drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c

ad26653f2a74a0 Ajit Khaparde 2022-10-25  30  
8a686d1e144cad Ajit Khaparde 2022-10-25  31  int bnxt_register_dev(struct bnxt_en_dev *edev,
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  32  		      struct bnxt_ulp_ops *ulp_ops,
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  33  		      void *handle)
a588e4580a7ecb Michael Chan  2016-12-07  34  {
a588e4580a7ecb Michael Chan  2016-12-07  35  	struct net_device *dev = edev->net;
a588e4580a7ecb Michael Chan  2016-12-07  36  	struct bnxt *bp = netdev_priv(dev);
a588e4580a7ecb Michael Chan  2016-12-07  37  	unsigned int max_stat_ctxs;
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  38  	struct bnxt_ulp *ulp;
a588e4580a7ecb Michael Chan  2016-12-07  39  
a588e4580a7ecb Michael Chan  2016-12-07  40  	max_stat_ctxs = bnxt_get_max_func_stat_ctxs(bp);
a588e4580a7ecb Michael Chan  2016-12-07  41  	if (max_stat_ctxs <= BNXT_MIN_ROCE_STAT_CTXS ||
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  42  	    bp->cp_nr_rings == max_stat_ctxs)
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  43  		return -ENOMEM;
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  44  
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  45  	ulp = kzalloc(sizeof(*ulp), GFP_KERNEL);
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  46  	if (!ulp)
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  47  		return -ENOMEM;
a588e4580a7ecb Michael Chan  2016-12-07  48  
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  49  	edev->ulp_tbl = ulp;
a588e4580a7ecb Michael Chan  2016-12-07  50  	ulp->handle = handle;
a588e4580a7ecb Michael Chan  2016-12-07 @51  	rcu_assign_pointer(ulp->ulp_ops, ulp_ops);
a588e4580a7ecb Michael Chan  2016-12-07  52  
a588e4580a7ecb Michael Chan  2016-12-07  53  	if (test_bit(BNXT_STATE_OPEN, &bp->state))
a588e4580a7ecb Michael Chan  2016-12-07  54  		bnxt_hwrm_vnic_cfg(bp, 0);
a588e4580a7ecb Michael Chan  2016-12-07  55  
92c7d0e64af8a4 Ajit Khaparde 2022-10-25  56  	return 0;
a588e4580a7ecb Michael Chan  2016-12-07  57  }
8a686d1e144cad Ajit Khaparde 2022-10-25  58  EXPORT_SYMBOL(bnxt_register_dev);
a588e4580a7ecb Michael Chan  2016-12-07  59  

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

View attachment "config" of type "text/plain" (130840 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ