From: kernel test robot <lkp@intel.com>
To: Shreeya Patel <shreeya.patel@collabora.com>,
linus.walleij@linaro.org, bgolaszewski@baylibre.com,
wsa@kernel.org, krisman@collabora.com,
sebastian.reichel@collabora.com
Cc: kbuild-all@lists.01.org, kernel@collabora.com,
linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-i2c@vger.kernel.org,
Shreeya Patel <shreeya.patel@collabora.com>
Subject: Re: [PATCH v2] gpio: Return EPROBE_DEFER if gc->to_irq is NULL
Date: Wed, 10 Nov 2021 17:15:59 +0800 [thread overview]
Message-ID: <202111101719.VzKfSYAQ-lkp@intel.com> (raw)
In-Reply-To: <20211018220504.8301-1-shreeya.patel@collabora.com>
[-- Attachment #1: Type: text/plain, Size: 3430 bytes --]
Hi Shreeya,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on linusw-gpio/for-next]
[also build test ERROR on v5.15 next-20211110]
[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/Shreeya-Patel/gpio-Return-EPROBE_DEFER-if-gc-to_irq-is-NULL/20211019-060640
base: https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio.git for-next
config: sh-rsk7269_defconfig (attached as .config)
compiler: sh4-linux-gcc (GCC) 11.2.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/e807153b3cae5acb6d78393087c28e4004cb9856
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Shreeya-Patel/gpio-Return-EPROBE_DEFER-if-gc-to_irq-is-NULL/20211019-060640
git checkout e807153b3cae5acb6d78393087c28e4004cb9856
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=sh SHELL=/bin/bash drivers/gpio/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
cc1: warning: arch/sh/include/mach-rsk: No such file or directory [-Wmissing-include-dirs]
cc1: warning: arch/sh/include/mach-rsk: No such file or directory [-Wmissing-include-dirs]
drivers/gpio/gpiolib.c: In function 'gpiod_to_irq':
>> drivers/gpio/gpiolib.c:3068:15: error: 'struct gpio_chip' has no member named 'irq'
3068 | if (gc->irq.chip) {
| ^~
vim +3068 drivers/gpio/gpiolib.c
3036
3037 /**
3038 * gpiod_to_irq() - return the IRQ corresponding to a GPIO
3039 * @desc: gpio whose IRQ will be returned (already requested)
3040 *
3041 * Return the IRQ corresponding to the passed GPIO, or an error code in case of
3042 * error.
3043 */
3044 int gpiod_to_irq(const struct gpio_desc *desc)
3045 {
3046 struct gpio_chip *gc;
3047 int offset;
3048
3049 /*
3050 * Cannot VALIDATE_DESC() here as gpiod_to_irq() consumer semantics
3051 * requires this function to not return zero on an invalid descriptor
3052 * but rather a negative error number.
3053 */
3054 if (!desc || IS_ERR(desc) || !desc->gdev || !desc->gdev->chip)
3055 return -EINVAL;
3056
3057 gc = desc->gdev->chip;
3058 offset = gpio_chip_hwgpio(desc);
3059 if (gc->to_irq) {
3060 int retirq = gc->to_irq(gc, offset);
3061
3062 /* Zero means NO_IRQ */
3063 if (!retirq)
3064 return -ENXIO;
3065
3066 return retirq;
3067 }
> 3068 if (gc->irq.chip) {
3069 /* avoid race condition with other code, which tries to lookup
3070 * an IRQ before the irqchip has been properly registered
3071 * (i.e. while gpiochip is still being brought up).
3072 */
3073 return -EPROBE_DEFER;
3074 }
3075
3076 return -ENXIO;
3077 }
3078 EXPORT_SYMBOL_GPL(gpiod_to_irq);
3079
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 11712 bytes --]
next prev parent reply other threads:[~2021-11-10 9:16 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-18 22:05 Shreeya Patel
2021-10-24 21:49 ` Linus Walleij
2021-11-10 9:15 ` kernel test robot [this message]
2021-11-11 20:40 ` Linus Walleij
2021-11-11 20:58 ` Andy Shevchenko
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=202111101719.VzKfSYAQ-lkp@intel.com \
--to=lkp@intel.com \
--cc=bgolaszewski@baylibre.com \
--cc=kbuild-all@lists.01.org \
--cc=kernel@collabora.com \
--cc=krisman@collabora.com \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sebastian.reichel@collabora.com \
--cc=shreeya.patel@collabora.com \
--cc=wsa@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome