DriverDev-Devel Archive on lore.kernel.org
 help / color / Atom feed
* [driver-core:device_h_splitup 34/35] drivers/net//ethernet/hisilicon/hns/hns_dsaf_misc.c:762:54: error: passing argument 2 of 'bus_find_device_by_fwnode' from incompatible pointer type
@ 2019-11-03 18:54 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2019-11-03 18:54 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: devel, kbuild-all

[-- Attachment #1: Type: text/plain, Size: 4060 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git device_h_splitup
head:   8ac09706c581716b3ca938773ad29e50854fa674
commit: bfe8e3fa1f0d3946158a6526aefccc5160b51cb9 [34/35] device.h: move 'struct bus' stuff out to device/bus.h
config: sh-allyesconfig (attached as .config)
compiler: sh4-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
        git checkout bfe8e3fa1f0d3946158a6526aefccc5160b51cb9
        # save the attached .config to linux build tree
        GCC_VERSION=7.4.0 make.cross ARCH=sh 

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

All errors (new ones prefixed by >>):

   In file included from include/linux/device.h:29:0,
                    from include/linux/dma-mapping.h:7,
                    from include/linux/skbuff.h:31,
                    from include/linux/if_ether.h:19,
                    from include/uapi/linux/ethtool.h:19,
                    from include/linux/ethtool.h:18,
                    from include/linux/netdevice.h:37,
                    from include/linux/if_vlan.h:10,
                    from drivers/net//ethernet/hisilicon/hns/hns_dsaf_mac.h:9,
                    from drivers/net//ethernet/hisilicon/hns/hns_dsaf_misc.c:6:
   include/linux/device/bus.h:193:62: warning: 'struct fwnode_handle' declared inside parameter list will not be visible outside of this definition or declaration
    bus_find_device_by_fwnode(struct bus_type *bus, const struct fwnode_handle *fwnode)
                                                                 ^~~~~~~~~~~~~
   drivers/net//ethernet/hisilicon/hns/hns_dsaf_misc.c: In function 'hns_dsaf_find_platform_device':
>> drivers/net//ethernet/hisilicon/hns/hns_dsaf_misc.c:762:54: error: passing argument 2 of 'bus_find_device_by_fwnode' from incompatible pointer type [-Werror=incompatible-pointer-types]
     dev = bus_find_device_by_fwnode(&platform_bus_type, fwnode);
                                                         ^~~~~~
   In file included from include/linux/device.h:29:0,
                    from include/linux/dma-mapping.h:7,
                    from include/linux/skbuff.h:31,
                    from include/linux/if_ether.h:19,
                    from include/uapi/linux/ethtool.h:19,
                    from include/linux/ethtool.h:18,
                    from include/linux/netdevice.h:37,
                    from include/linux/if_vlan.h:10,
                    from drivers/net//ethernet/hisilicon/hns/hns_dsaf_mac.h:9,
                    from drivers/net//ethernet/hisilicon/hns/hns_dsaf_misc.c:6:
   include/linux/device/bus.h:193:1: note: expected 'const struct fwnode_handle *' but argument is of type 'struct fwnode_handle *'
    bus_find_device_by_fwnode(struct bus_type *bus, const struct fwnode_handle *fwnode)
    ^~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors

vim +/bus_find_device_by_fwnode +762 drivers/net//ethernet/hisilicon/hns/hns_dsaf_misc.c

d605916b765934 Salil            2016-08-24  756  
d605916b765934 Salil            2016-08-24  757  struct
d605916b765934 Salil            2016-08-24  758  platform_device *hns_dsaf_find_platform_device(struct fwnode_handle *fwnode)
d605916b765934 Salil            2016-08-24  759  {
d605916b765934 Salil            2016-08-24  760  	struct device *dev;
d605916b765934 Salil            2016-08-24  761  
67843bbaf36eb0 Suzuki K Poulose 2019-07-23 @762  	dev = bus_find_device_by_fwnode(&platform_bus_type, fwnode);

:::::: The code at line 762 was first introduced by commit
:::::: 67843bbaf36eb087714f40e783ee78e99e9e4b86 drivers: Introduce device lookup variants by fwnode

:::::: TO: Suzuki K Poulose <suzuki.poulose@arm.com>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 52523 bytes --]

[-- Attachment #3: Type: text/plain, Size: 169 bytes --]

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, back to index

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-03 18:54 [driver-core:device_h_splitup 34/35] drivers/net//ethernet/hisilicon/hns/hns_dsaf_misc.c:762:54: error: passing argument 2 of 'bus_find_device_by_fwnode' from incompatible pointer type kbuild test robot

DriverDev-Devel Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/driverdev-devel/0 driverdev-devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 driverdev-devel driverdev-devel/ https://lore.kernel.org/driverdev-devel \
		driverdev-devel@linuxdriverproject.org devel@driverdev.osuosl.org
	public-inbox-index driverdev-devel

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.linuxdriverproject.driverdev-devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git