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]
Date:   Thu, 16 Mar 2023 05:56:59 +0800
From:   kernel test robot <lkp@...el.com>
To:     mengyuanlou <mengyuanlou@...-swift.com>, netdev@...r.kernel.org
Cc:     oe-kbuild-all@...ts.linux.dev, jiawenwu@...stnetic.com,
        mengyuanlou <mengyuanlou@...-swift.com>
Subject: Re: [PATCH net-next] net: wangxun: Remove macro that is redefined

Hi mengyuanlou,

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]

url:    https://github.com/intel-lab-lkp/linux/commits/mengyuanlou/net-wangxun-Remove-macro-that-is-redefined/20230315-172033
patch link:    https://lore.kernel.org/r/20230315091846.17314-1-mengyuanlou%40net-swift.com
patch subject: [PATCH net-next] net: wangxun: Remove macro that is redefined
config: loongarch-allmodconfig (https://download.01.org/0day-ci/archive/20230316/202303160530.zDOH600Q-lkp@intel.com/config)
compiler: loongarch64-linux-gcc (GCC) 12.1.0
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
        # https://github.com/intel-lab-lkp/linux/commit/189cd0016c7fb0ad7ae6b2bc58f2247d40885a97
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review mengyuanlou/net-wangxun-Remove-macro-that-is-redefined/20230315-172033
        git checkout 189cd0016c7fb0ad7ae6b2bc58f2247d40885a97
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=loongarch olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=loongarch SHELL=/bin/bash drivers/net/ethernet/wangxun/libwx/ drivers/net/ethernet/wangxun/txgbe/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202303160530.zDOH600Q-lkp@intel.com/

All errors (new ones prefixed by >>):

   drivers/net/ethernet/wangxun/libwx/wx_hw.c: In function 'wx_sw_init':
>> drivers/net/ethernet/wangxun/libwx/wx_hw.c:1688:29: error: 'PCI_VENDOR_ID_WANGXUN' undeclared (first use in this function); did you mean 'PCI_VENDOR_ID_SAMSUNG'?
    1688 |         if (wx->oem_svid == PCI_VENDOR_ID_WANGXUN) {
         |                             ^~~~~~~~~~~~~~~~~~~~~
         |                             PCI_VENDOR_ID_SAMSUNG
   drivers/net/ethernet/wangxun/libwx/wx_hw.c:1688:29: note: each undeclared identifier is reported only once for each function it appears in
--
   In file included from drivers/net/ethernet/wangxun/txgbe/txgbe_main.c:6:
>> include/linux/pci.h:1018:19: error: 'PCI_VENDOR_ID_WANGXUN' undeclared here (not in a function); did you mean 'PCI_VENDOR_ID_SAMSUNG'?
    1018 |         .vendor = PCI_VENDOR_ID_##vend, .device = (dev), \
         |                   ^~~~~~~~~~~~~~
   drivers/net/ethernet/wangxun/txgbe/txgbe_main.c:31:11: note: in expansion of macro 'PCI_VDEVICE'
      31 |         { PCI_VDEVICE(WANGXUN, TXGBE_DEV_ID_SP1000), 0},
         |           ^~~~~~~~~~~


vim +1688 drivers/net/ethernet/wangxun/libwx/wx_hw.c

02338c484ab6250 Mengyuan Lou 2022-10-31  1673  
9607a3e62645c25 Jiawen Wu    2023-01-06  1674  int wx_sw_init(struct wx *wx)
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1675  {
9607a3e62645c25 Jiawen Wu    2023-01-06  1676  	struct pci_dev *pdev = wx->pdev;
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1677  	u32 ssid = 0;
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1678  	int err = 0;
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1679  
9607a3e62645c25 Jiawen Wu    2023-01-06  1680  	wx->vendor_id = pdev->vendor;
9607a3e62645c25 Jiawen Wu    2023-01-06  1681  	wx->device_id = pdev->device;
9607a3e62645c25 Jiawen Wu    2023-01-06  1682  	wx->revision_id = pdev->revision;
9607a3e62645c25 Jiawen Wu    2023-01-06  1683  	wx->oem_svid = pdev->subsystem_vendor;
9607a3e62645c25 Jiawen Wu    2023-01-06  1684  	wx->oem_ssid = pdev->subsystem_device;
9607a3e62645c25 Jiawen Wu    2023-01-06  1685  	wx->bus.device = PCI_SLOT(pdev->devfn);
9607a3e62645c25 Jiawen Wu    2023-01-06  1686  	wx->bus.func = PCI_FUNC(pdev->devfn);
9607a3e62645c25 Jiawen Wu    2023-01-06  1687  
9607a3e62645c25 Jiawen Wu    2023-01-06 @1688  	if (wx->oem_svid == PCI_VENDOR_ID_WANGXUN) {
9607a3e62645c25 Jiawen Wu    2023-01-06  1689  		wx->subsystem_vendor_id = pdev->subsystem_vendor;
9607a3e62645c25 Jiawen Wu    2023-01-06  1690  		wx->subsystem_device_id = pdev->subsystem_device;
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1691  	} else {
9607a3e62645c25 Jiawen Wu    2023-01-06  1692  		err = wx_flash_read_dword(wx, 0xfffdc, &ssid);
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1693  		if (!err)
9607a3e62645c25 Jiawen Wu    2023-01-06  1694  			wx->subsystem_device_id = swab16((u16)ssid);
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1695  
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1696  		return err;
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1697  	}
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1698  
9607a3e62645c25 Jiawen Wu    2023-01-06  1699  	wx->mac_table = kcalloc(wx->mac.num_rar_entries,
79625f45ca73ef3 Jiawen Wu    2023-01-06  1700  				sizeof(struct wx_mac_addr),
79625f45ca73ef3 Jiawen Wu    2023-01-06  1701  				GFP_KERNEL);
9607a3e62645c25 Jiawen Wu    2023-01-06  1702  	if (!wx->mac_table) {
9607a3e62645c25 Jiawen Wu    2023-01-06  1703  		wx_err(wx, "mac_table allocation failed\n");
79625f45ca73ef3 Jiawen Wu    2023-01-06  1704  		return -ENOMEM;
79625f45ca73ef3 Jiawen Wu    2023-01-06  1705  	}
79625f45ca73ef3 Jiawen Wu    2023-01-06  1706  
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1707  	return 0;
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1708  }
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1709  EXPORT_SYMBOL(wx_sw_init);
a34b3e6ed8fbf66 Jiawen Wu    2022-10-27  1710  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ