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:   Wed, 3 Feb 2021 00:45:31 +0800
From:   kernel test robot <lkp@...el.com>
To:     Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:     kbuild-all@...ts.01.org, clang-built-linux@...glegroups.com,
        "Rafael J. Wysocki" <rafael@...nel.org>,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        Felipe Balbi <balbi@...nel.org>,
        Mathias Nyman <mathias.nyman@...el.com>,
        linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org
Subject: Re: [PATCH 3/6] usb: dwc3: haps: Constify the software node

Hi Heikki,

I love your patch! Yet something to improve:

[auto build test ERROR on usb/usb-testing]
[also build test ERROR on next-20210125]
[cannot apply to balbi-usb/testing/next char-misc/char-misc-testing v5.11-rc6]
[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]

url:    https://github.com/0day-ci/linux/commits/Heikki-Krogerus/usb-Handle-device-properties-with-software-node-API/20210202-205900
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing
config: x86_64-randconfig-a006-20210202 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 275c6af7d7f1ed63a03d05b4484413e447133269)
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
        # install x86_64 cross compiling tool for clang build
        # apt-get install binutils-x86-64-linux-gnu
        # https://github.com/0day-ci/linux/commit/399031fcde9483395785bd0eec474c584bd1e9fd
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Heikki-Krogerus/usb-Handle-device-properties-with-software-node-API/20210202-205900
        git checkout 399031fcde9483395785bd0eec474c584bd1e9fd
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 

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

All errors (new ones prefixed by >>):

>> drivers/usb/dwc3/dwc3-haps.c:84:50: error: passing 'const struct software_node' to parameter of incompatible type 'const struct software_node *'; take the address with &
           ret = device_add_software_node(&dwc->dwc3->dev, dwc3_haps_swnode);
                                                           ^~~~~~~~~~~~~~~~
                                                           &
   include/linux/property.h:491:78: note: passing argument to parameter 'swnode' here
   int device_add_software_node(struct device *dev, const struct software_node *swnode);
                                                                                ^
   1 error generated.


vim +84 drivers/usb/dwc3/dwc3-haps.c

    39	
    40	static int dwc3_haps_probe(struct pci_dev *pci,
    41				   const struct pci_device_id *id)
    42	{
    43		struct dwc3_haps	*dwc;
    44		struct device		*dev = &pci->dev;
    45		struct resource		res[2];
    46		int			ret;
    47	
    48		ret = pcim_enable_device(pci);
    49		if (ret) {
    50			dev_err(dev, "failed to enable pci device\n");
    51			return -ENODEV;
    52		}
    53	
    54		pci_set_master(pci);
    55	
    56		dwc = devm_kzalloc(dev, sizeof(*dwc), GFP_KERNEL);
    57		if (!dwc)
    58			return -ENOMEM;
    59	
    60		dwc->dwc3 = platform_device_alloc("dwc3", PLATFORM_DEVID_AUTO);
    61		if (!dwc->dwc3)
    62			return -ENOMEM;
    63	
    64		memset(res, 0x00, sizeof(struct resource) * ARRAY_SIZE(res));
    65	
    66		res[0].start	= pci_resource_start(pci, 0);
    67		res[0].end	= pci_resource_end(pci, 0);
    68		res[0].name	= "dwc_usb3";
    69		res[0].flags	= IORESOURCE_MEM;
    70	
    71		res[1].start	= pci->irq;
    72		res[1].name	= "dwc_usb3";
    73		res[1].flags	= IORESOURCE_IRQ;
    74	
    75		ret = platform_device_add_resources(dwc->dwc3, res, ARRAY_SIZE(res));
    76		if (ret) {
    77			dev_err(dev, "couldn't add resources to dwc3 device\n");
    78			goto err;
    79		}
    80	
    81		dwc->pci = pci;
    82		dwc->dwc3->dev.parent = dev;
    83	
  > 84		ret = device_add_software_node(&dwc->dwc3->dev, dwc3_haps_swnode);
    85		if (ret)
    86			goto err;
    87	
    88		ret = platform_device_add(dwc->dwc3);
    89		if (ret) {
    90			dev_err(dev, "failed to register dwc3 device\n");
    91			goto err;
    92		}
    93	
    94		pci_set_drvdata(pci, dwc);
    95	
    96		return 0;
    97	err:
    98		device_remove_software_node(&dwc->dwc3->dev);
    99		platform_device_put(dwc->dwc3);
   100		return ret;
   101	}
   102	

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

Download attachment ".config.gz" of type "application/gzip" (39814 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ