All of lore.kernel.org
 help / color / mirror / Atom feed
* [ljones-mfd:for-mfd-next 56/66] drivers/mfd/mfd-core.c:168:1: warning: no return statement in function returning non-void
@ 2020-07-18 15:09 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2020-07-18 15:09 UTC (permalink / raw)
  To: kbuild-all

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git for-mfd-next
head:   c23452e6a319bc607b54a1cce9c74c9033565af3
commit: c509ed7e7d376a7bc3aeb17133c0d117a887916a [56/66] mfd: core: Make a best effort attempt to match devices with the correct of_nodes
config: ia64-randconfig-r024-20200717 (attached as .config)
compiler: ia64-linux-gcc (GCC) 9.3.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
        git checkout c509ed7e7d376a7bc3aeb17133c0d117a887916a
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64 

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

All warnings (new ones prefixed by >>):

   drivers/mfd/mfd-core.c: In function 'mfd_match_of_node_to_dev':
>> drivers/mfd/mfd-core.c:168:1: warning: no return statement in function returning non-void [-Wreturn-type]
     168 | }
         | ^

vim +168 drivers/mfd/mfd-core.c

   119	
   120	static int mfd_match_of_node_to_dev(struct platform_device *pdev,
   121					    struct device_node *np,
   122					    const struct mfd_cell *cell)
   123	{
   124	#if IS_ENABLED(CONFIG_OF)
   125		struct mfd_of_node_entry *of_entry;
   126		const __be32 *reg;
   127		u64 of_node_addr;
   128	
   129		/* Skip devices 'disabled' by Device Tree */
   130		if (!of_device_is_available(np))
   131			return -ENODEV;
   132	
   133		/* Skip if OF node has previously been allocated to a device */
   134		list_for_each_entry(of_entry, &mfd_of_node_list, list)
   135			if (of_entry->np == np)
   136				return -EAGAIN;
   137	
   138		if (!cell->use_of_reg)
   139			/* No of_reg defined - allocate first free compatible match */
   140			goto allocate_of_node;
   141	
   142		/* We only care about each node's first defined address */
   143		reg = of_get_address(np, 0, NULL, NULL);
   144		if (!reg)
   145			/* OF node does not contatin a 'reg' property to match to */
   146			return -EAGAIN;
   147	
   148		of_node_addr = of_read_number(reg, of_n_addr_cells(np));
   149	
   150		if (cell->of_reg != of_node_addr)
   151			/* No match */
   152			return -EAGAIN;
   153	
   154	allocate_of_node:
   155		of_entry = kzalloc(sizeof(*of_entry), GFP_KERNEL);
   156		if (!of_entry)
   157			return -ENOMEM;
   158	
   159		of_entry->dev = &pdev->dev;
   160		of_entry->np = np;
   161		list_add_tail(&of_entry->list, &mfd_of_node_list);
   162	
   163		pdev->dev.of_node = np;
   164		pdev->dev.fwnode = &np->fwnode;
   165	
   166		return 0;
   167	#endif
 > 168	}
   169	

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

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

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

only message in thread, other threads:[~2020-07-18 15:09 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-18 15:09 [ljones-mfd:for-mfd-next 56/66] drivers/mfd/mfd-core.c:168:1: warning: no return statement in function returning non-void kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.