public inbox for linux-gpio@vger.kernel.org
 help / color / mirror / Atom feed
* [linusw-gpio:b4/descriptors-wireless 2/2] drivers/gpio/gpio-ath79.c:264:1: warning: no return statement in function returning non-void
@ 2026-03-16 12:22 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-03-16 12:22 UTC (permalink / raw)
  To: Linus Walleij; +Cc: oe-kbuild-all, linux-gpio, Andy Shevchenko

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio.git b4/descriptors-wireless
head:   f498eb811e7dd7b968743a9bba20710a5070c0be
commit: f498eb811e7dd7b968743a9bba20710a5070c0be [2/2] wifi: ath9k: Obtain system GPIOS from descriptors
config: s390-allyesconfig (https://download.01.org/0day-ci/archive/20260316/202603162011.BYf9zG1R-lkp@intel.com/config)
compiler: s390-linux-gcc (GCC) 15.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260316/202603162011.BYf9zG1R-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202603162011.BYf9zG1R-lkp@intel.com/

All warnings (new ones prefixed by >>):

   drivers/gpio/gpio-ath79.c: In function 'ath79_gpio_register_wifi_descriptors':
>> drivers/gpio/gpio-ath79.c:264:1: warning: no return statement in function returning non-void [-Wreturn-type]
     264 | }
         | ^


vim +264 drivers/gpio/gpio-ath79.c

   217	
   218	#if IS_ENABLED(CONFIG_ATH9K_AHB)
   219	/*
   220	 * This registers all of the ath79k GPIOs as descriptors to be picked
   221	 * directly from the ATH79K wifi driver if the two are jitted together
   222	 * in the same SoC.
   223	 */
   224	#define ATH79K_WIFI_DESCS 32
   225	static int ath79_gpio_register_wifi_descriptors(struct device *dev,
   226							const char *label)
   227	{
   228		struct gpiod_lookup_table *lookup;
   229		int i;
   230	
   231		/* Create a gpiod lookup using gpiochip-local offsets + 1 for NULL */
   232		lookup = devm_kzalloc(dev,
   233				      struct_size(lookup, table, ATH79K_WIFI_DESCS + 1),
   234				      GFP_KERNEL);
   235		if (!lookup)
   236			return -ENOMEM;
   237	
   238		/*
   239		 * Ugly system-wide lookup for the NULL device: we know this
   240		 * is already NULL but explicitly assign it here for people to
   241		 * know what is going on. (Yes this is an ugly legacy hack, live
   242		 * with it.)
   243		 */
   244		lookup->dev_id = NULL;
   245	
   246		for (i = 0; i < ATH79K_WIFI_DESCS; i++) {
   247			lookup->table[i] =
   248				/*
   249				 * Set the HW offset on the chip and the lookup
   250				 * index to the same value, so looking up index 0
   251				 * will get HW offset 0, index 1 HW offset 1 etc.
   252				 */
   253				GPIO_LOOKUP_IDX(label, i, "ath9k", i, GPIO_ACTIVE_HIGH);
   254		}
   255	
   256		gpiod_add_lookup_table(lookup);
   257	
   258		return 0;
   259	}
   260	#else
   261	static int ath79_gpio_register_wifi_descriptors(struct device *dev,
   262							const char *label)
   263	{
 > 264	}
   265	#endif
   266	

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

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

only message in thread, other threads:[~2026-03-16 12:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-16 12:22 [linusw-gpio:b4/descriptors-wireless 2/2] drivers/gpio/gpio-ath79.c:264:1: warning: no return statement in function returning non-void kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox