All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH v2 1/3] gpio: gpio-hisi: Add HiSilicon GPIO support
Date: Mon, 14 Dec 2020 20:57:36 +0800	[thread overview]
Message-ID: <202012142009.OOPQPgsN-lkp@intel.com> (raw)
In-Reply-To: <1607934255-52544-2-git-send-email-luojiaxing@huawei.com>

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

Hi Luo,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on gpio/for-next]
[also build test WARNING on arm64/for-next/core linus/master v5.10 next-20201211]
[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]

url:    https://github.com/0day-ci/linux/commits/Luo-Jiaxing/gpio-gpio-hisi-Add-HiSilicon-GPIO-support/20201214-163229
base:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio.git for-next
config: ia64-allyesconfig (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
        # https://github.com/0day-ci/linux/commit/a5a4b0b963f551e72877f5a6ed97657ebf074449
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Luo-Jiaxing/gpio-gpio-hisi-Add-HiSilicon-GPIO-support/20201214-163229
        git checkout a5a4b0b963f551e72877f5a6ed97657ebf074449
        # 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/gpio/gpio-hisi.c: In function 'hisi_gpio_probe':
>> drivers/gpio/gpio-hisi.c:257:28: warning: variable 'clr' set but not used [-Wunused-but-set-variable]
     257 |  void __iomem *dat, *set, *clr;
         |                            ^~~
>> drivers/gpio/gpio-hisi.c:257:22: warning: variable 'set' set but not used [-Wunused-but-set-variable]
     257 |  void __iomem *dat, *set, *clr;
         |                      ^~~
>> drivers/gpio/gpio-hisi.c:257:16: warning: variable 'dat' set but not used [-Wunused-but-set-variable]
     257 |  void __iomem *dat, *set, *clr;
         |                ^~~

vim +/clr +257 drivers/gpio/gpio-hisi.c

   253	
   254	static int hisi_gpio_probe(struct platform_device *pdev)
   255	{
   256		struct device *dev = &pdev->dev;
 > 257		void __iomem *dat, *set, *clr;
   258		struct hisi_gpio *hisi_gpio;
   259		int port_num;
   260		int ret;
   261	
   262		/*
   263		 * One GPIO controller own one port currently,
   264		 * if we get more from ACPI table, return error.
   265		 */
   266		port_num = device_get_child_node_count(dev);
   267		if (WARN_ON(port_num != 1))
   268			return -ENODEV;
   269	
   270		hisi_gpio = devm_kzalloc(dev, sizeof(*hisi_gpio), GFP_KERNEL);
   271		if (!hisi_gpio)
   272			return -ENOMEM;
   273	
   274		hisi_gpio->reg_base = devm_platform_ioremap_resource(pdev, 0);
   275		if (IS_ERR(hisi_gpio->reg_base))
   276			return PTR_ERR(hisi_gpio->reg_base);
   277	
   278		hisi_gpio_get_pdata(dev, hisi_gpio);
   279	
   280		hisi_gpio->dev = dev;
   281	
   282		dat = hisi_gpio->reg_base + HISI_GPIO_EXT_PORT_WX;
   283		set = hisi_gpio->reg_base + HISI_GPIO_SWPORT_DR_SET_WX;
   284		clr = hisi_gpio->reg_base + HISI_GPIO_SWPORT_DR_CLR_WX;
   285	
   286		ret = bgpio_init(&hisi_gpio->chip, hisi_gpio->dev, 0x4,
   287				 hisi_gpio->reg_base + HISI_GPIO_EXT_PORT_WX,
   288				 hisi_gpio->reg_base + HISI_GPIO_SWPORT_DR_SET_WX,
   289				 hisi_gpio->reg_base + HISI_GPIO_SWPORT_DR_CLR_WX,
   290				 hisi_gpio->reg_base + HISI_GPIO_SWPORT_DDR_SET_WX,
   291				 hisi_gpio->reg_base + HISI_GPIO_SWPORT_DDR_CLR_WX,
   292				 BGPIOF_NO_SET_ON_INPUT);
   293		if (ret) {
   294			dev_err(dev, "failed to init, ret = %d\n", ret);
   295			return ret;
   296		}
   297	
   298		hisi_gpio->chip.set_config = hisi_gpio_set_config;
   299		hisi_gpio->chip.ngpio = hisi_gpio->line_num;
   300		hisi_gpio->chip.bgpio_dir_unreadable = 1;
   301		hisi_gpio->chip.base = -1;
   302	
   303		if (hisi_gpio->irq > 0)
   304			hisi_gpio_init_irq(hisi_gpio);
   305	
   306		ret = devm_gpiochip_add_data(dev, &hisi_gpio->chip, hisi_gpio);
   307		if (ret) {
   308			dev_err(dev, "failed to register gpiochip, ret = %d\n", ret);
   309			return ret;
   310		}
   311	
   312		return 0;
   313	}
   314	

---
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: 67918 bytes --]

  parent reply	other threads:[~2020-12-14 12:57 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-14  8:24 [PATCH v2 0/3] gpio: gpio-hisi: Add HiSilicon GPIO support Luo Jiaxing
2020-12-14  8:24 ` [PATCH v2 1/3] " Luo Jiaxing
2020-12-14  9:11   ` Linus Walleij
2020-12-14 16:58     ` Andy Shevchenko
2020-12-14 22:37       ` Linus Walleij
2020-12-15  9:49         ` Andy Shevchenko
2020-12-14 12:57   ` kernel test robot [this message]
2020-12-14  8:24 ` [PATCH v2 2/3] MAINTAINERS: Add maintainer for HiSilicon GPIO driver Luo Jiaxing
2020-12-14  9:11   ` Linus Walleij
2020-12-14  8:24 ` [PATCH v2 3/3] arm64: defconfig: enable GPIO_HISI Luo Jiaxing
2020-12-14  9:12   ` Linus Walleij

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202012142009.OOPQPgsN-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.