Re: [PATCH 2/5] net: stmmac: Split devicetree parse

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

 



Hi Jiaxun,

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]
[also build test ERROR on v5.4-rc5 next-20191031]
[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/Jiaxun-Yang/PCI-Devices-for-Loongson-PCH/20191102-045600
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git 52340b82cf1a9c8d466b6e36a0881bc44174b969
config: mips-allmodconfig (attached as .config)
compiler: mips-linux-gcc (GCC) 7.4.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
        GCC_VERSION=7.4.0 make.cross ARCH=mips 

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

All errors (new ones prefixed by >>):

   drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c: In function 'stmmac_parse_config_dt':
   drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c:401:3: error: 'mac' undeclared (first use in this function); did you mean 'max'?
     *mac = of_get_mac_address(np);
      ^~~
      max
   drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c:401:3: note: each undeclared identifier is reported only once for each function it appears in
   In file included from include/linux/platform_device.h:13:0,
                    from drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c:11:
   drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c:445:13: error: 'pdev' undeclared (first use in this function); did you mean 'cdev'?
      dev_warn(&pdev->dev, "snps,phy-addr property is deprecated\n");
                ^
   include/linux/device.h:1743:12: note: in definition of macro 'dev_warn'
     _dev_warn(dev, dev_fmt(fmt), ##__VA_ARGS__)
               ^~~
   drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c: In function 'stmmac_probe_config_dt':
>> drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c:633:3: error: implicit declaration of function 'free'; did you mean 'kfree'? [-Werror=implicit-function-declaration]
      free(plat);
      ^~~~
      kfree
   cc1: some warnings being treated as errors

vim +633 drivers/net//ethernet/stmicro/stmmac/stmmac_platform.c

   610	
   611	/**
   612	 * stmmac_probe_config_dt - probe and setup stmmac platform data by devicetree
   613	 * @pdev: platform_device structure
   614	 * @mac: MAC address to use
   615	 * Description:
   616	 * this function is to set up plat_stmmacenet_data  private structure
   617	 * for platform drivers.
   618	 */
   619	struct plat_stmmacenet_data *
   620	stmmac_probe_config_dt(struct platform_device *pdev, const char **mac)
   621	{
   622		struct device_node *np = pdev->dev.of_node;
   623		struct plat_stmmacenet_data *plat;
   624		int rc;
   625	
   626		plat = devm_kzalloc(&pdev->dev, sizeof(*plat), GFP_KERNEL);
   627		if (!plat)
   628			return ERR_PTR(-ENOMEM);
   629	
   630		rc = stmmac_parse_config_dt(np, plat);
   631	
   632		if (rc) {
 > 633			free(plat);
   634			return ERR_PTR(rc);
   635		}
   636	
   637		return plat;
   638	}
   639	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux