Re: [PATCH 2/2] pinctrl: Use new GPIO_LINE_DIRECTION

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

 



Hi Matti,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on 70d97e099bb426ecb3ad4bf31e88dbf2ef4b2e4c]

url:    https://github.com/0day-ci/linux/commits/Matti-Vaittinen/pinctrl-rza1-remove-unnecerssary-static-inline-function/20191113-114104
base:    70d97e099bb426ecb3ad4bf31e88dbf2ef4b2e4c
config: arm-allmodconfig (attached as .config)
compiler: arm-linux-gnueabi-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
        # save the attached .config to linux build tree
        GCC_VERSION=7.4.0 make.cross ARCH=arm 

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

All warnings (new ones prefixed by >>):

   In file included from drivers/pinctrl/vt8500/pinctrl-wmt.c:9:0:
   drivers/pinctrl/vt8500/pinctrl-wmt.c: In function 'wmt_gpio_get_direction':
   include/linux/gpio/driver.h:26:33: warning: statement with no effect [-Wunused-value]
    #define GPIO_LINE_DIRECTION_OUT 0
                                    ^
>> drivers/pinctrl/vt8500/pinctrl-wmt.c:490:3: note: in expansion of macro 'GPIO_LINE_DIRECTION_OUT'
      GPIO_LINE_DIRECTION_OUT;
      ^~~~~~~~~~~~~~~~~~~~~~~

vim +/GPIO_LINE_DIRECTION_OUT +490 drivers/pinctrl/vt8500/pinctrl-wmt.c

   479	
   480	static int wmt_gpio_get_direction(struct gpio_chip *chip, unsigned offset)
   481	{
   482		struct wmt_pinctrl_data *data = gpiochip_get_data(chip);
   483		u32 bank = WMT_BANK_FROM_PIN(offset);
   484		u32 bit = WMT_BIT_FROM_PIN(offset);
   485		u32 reg_dir = data->banks[bank].reg_dir;
   486		u32 val;
   487	
   488		val = readl_relaxed(data->base + reg_dir);
   489		if (val & BIT(bit))
 > 490			GPIO_LINE_DIRECTION_OUT;
   491	
   492		return GPIO_LINE_DIRECTION_IN;
   493	}
   494	

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

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux