Re: [PATCH for-next] RDMA/core: Assign the name of device when allocating ib_device

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Weihang,

I love your patch! Yet something to improve:

[auto build test ERROR on rdma/for-next]
[also build test ERROR on linus/master v5.7-rc3 next-20200424]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Weihang-Li/RDMA-core-Assign-the-name-of-device-when-allocating-ib_device/20200428-022647
base:   https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git for-next
config: sh-allmodconfig (attached as .config)
compiler: sh4-linux-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=sh 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

   drivers/infiniband/sw/siw/siw_main.c: In function 'siw_device_register':
>> drivers/infiniband/sw/siw/siw_main.c:70:7: error: too many arguments to function 'ib_register_device'
      70 |  rv = ib_register_device(base_dev, name);
         |       ^~~~~~~~~~~~~~~~~~
   In file included from drivers/infiniband/sw/siw/siw_main.c:20:
   include/rdma/ib_verbs.h:2781:5: note: declared here
    2781 | int ib_register_device(struct ib_device *device);
         |     ^~~~~~~~~~~~~~~~~~
   drivers/infiniband/sw/siw/siw_main.c: In function 'siw_device_create':
>> drivers/infiniband/sw/siw/siw_main.c:326:45: error: macro "ib_alloc_device" requires 3 arguments, but only 2 given
     326 |  sdev = ib_alloc_device(siw_device, base_dev);
         |                                             ^
   In file included from drivers/infiniband/sw/siw/siw_main.c:20:
   include/rdma/ib_verbs.h:2771: note: macro "ib_alloc_device" defined here
    2771 | #define ib_alloc_device(drv_struct, member, name)                              \
         | 
>> drivers/infiniband/sw/siw/siw_main.c:326:9: error: 'ib_alloc_device' undeclared (first use in this function); did you mean '_ib_alloc_device'?
     326 |  sdev = ib_alloc_device(siw_device, base_dev);
         |         ^~~~~~~~~~~~~~~
         |         _ib_alloc_device
   drivers/infiniband/sw/siw/siw_main.c:326:9: note: each undeclared identifier is reported only once for each function it appears in

vim +/ib_register_device +70 drivers/infiniband/sw/siw/siw_main.c

bdcf26bf9b3acb Bernard Metzler 2019-06-20  63  
bdcf26bf9b3acb Bernard Metzler 2019-06-20  64  static int siw_device_register(struct siw_device *sdev, const char *name)
bdcf26bf9b3acb Bernard Metzler 2019-06-20  65  {
bdcf26bf9b3acb Bernard Metzler 2019-06-20  66  	struct ib_device *base_dev = &sdev->base_dev;
bdcf26bf9b3acb Bernard Metzler 2019-06-20  67  	static int dev_id = 1;
bdcf26bf9b3acb Bernard Metzler 2019-06-20  68  	int rv;
bdcf26bf9b3acb Bernard Metzler 2019-06-20  69  
bdcf26bf9b3acb Bernard Metzler 2019-06-20 @70  	rv = ib_register_device(base_dev, name);
bdcf26bf9b3acb Bernard Metzler 2019-06-20  71  	if (rv) {
bdcf26bf9b3acb Bernard Metzler 2019-06-20  72  		pr_warn("siw: device registration error %d\n", rv);
bdcf26bf9b3acb Bernard Metzler 2019-06-20  73  		return rv;
bdcf26bf9b3acb Bernard Metzler 2019-06-20  74  	}
bdcf26bf9b3acb Bernard Metzler 2019-06-20  75  	sdev->vendor_part_id = dev_id++;
bdcf26bf9b3acb Bernard Metzler 2019-06-20  76  
bdcf26bf9b3acb Bernard Metzler 2019-06-20  77  	siw_dbg(base_dev, "HWaddr=%pM\n", sdev->netdev->dev_addr);
bdcf26bf9b3acb Bernard Metzler 2019-06-20  78  
bdcf26bf9b3acb Bernard Metzler 2019-06-20  79  	return 0;
bdcf26bf9b3acb Bernard Metzler 2019-06-20  80  }
bdcf26bf9b3acb Bernard Metzler 2019-06-20  81  

:::::: The code at line 70 was first introduced by commit
:::::: bdcf26bf9b3acb03c8f90387cfc6474fc8ac5521 rdma/siw: network and RDMA core interface

:::::: TO: Bernard Metzler <bmt@xxxxxxxxxxxxxx>
:::::: CC: Jason Gunthorpe <jgg@xxxxxxxxxxxx>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux