Re: [PATCH v6 3/3] gpio: nuvoton: Add Nuvoton NPCM sgpio driver

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

 



Hi Jim,

kernel test robot noticed the following build warnings:

[auto build test WARNING on brgl/gpio/for-next]
[also build test WARNING on robh/for-next linus/master v6.6-rc7 next-20231024]
[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#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Jim-Liu/dt-bindings-gpio-add-NPCM-sgpio-driver-bindings/20231024-170835
base:   https://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux.git gpio/for-next
patch link:    https://lore.kernel.org/r/20231024090631.3359592-4-jim.t90615%40gmail.com
patch subject: [PATCH v6 3/3] gpio: nuvoton: Add Nuvoton NPCM sgpio driver
config: sparc-allyesconfig (https://download.01.org/0day-ci/archive/20231025/202310250031.1SKs6CHt-lkp@xxxxxxxxx/config)
compiler: sparc64-linux-gcc (GCC) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231025/202310250031.1SKs6CHt-lkp@xxxxxxxxx/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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202310250031.1SKs6CHt-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

   drivers/gpio/gpio-npcm-sgpio.c: In function 'bank_reg':
>> drivers/gpio/gpio-npcm-sgpio.c:150:24: warning: returning 'int' from a function with return type 'void *' makes pointer from integer without a cast [-Wint-conversion]
     150 |                 return -EINVAL;
         |                        ^
   drivers/gpio/gpio-npcm-sgpio.c: In function 'npcm_sgpio_setup_irqs':
>> drivers/gpio/gpio-npcm-sgpio.c:506:19: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
     506 |         irq->chip = &sgpio_irq_chip;
         |                   ^
   drivers/gpio/gpio-npcm-sgpio.c: In function 'npcm_sgpio_probe':
>> drivers/gpio/gpio-npcm-sgpio.c:559:36: warning: unused variable 'sgpio_freq' [-Wunused-variable]
     559 |         u32 nin_gpios, nout_gpios, sgpio_freq;
         |                                    ^~~~~~~~~~


vim +150 drivers/gpio/gpio-npcm-sgpio.c

   133	
   134	static void __iomem *bank_reg(struct npcm_sgpio *gpio,
   135				      const struct npcm_sgpio_bank *bank,
   136					const enum npcm_sgpio_reg reg)
   137	{
   138		switch (reg) {
   139		case READ_DATA:
   140			return gpio->base + bank->rdata_reg;
   141		case WRITE_DATA:
   142			return gpio->base + bank->wdata_reg;
   143		case EVENT_CFG:
   144			return gpio->base + bank->event_config;
   145		case EVENT_STS:
   146			return gpio->base + bank->event_status;
   147		default:
   148			/* actually if code runs to here, it's an error case */
   149			WARN(true, "Getting here is an error condition");
 > 150			return -EINVAL;
   151		}
   152	}
   153	

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




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux