Message ID | 20200615151353.88194-2-andriy.shevchenko@linux.intel.com |
---|---|
State | New |
Headers | show |
Series | pinctrl: intel: Reuse for_each_requested_gpio*() macros | expand |
Hi Andy, I love your patch! Yet something to improve: [auto build test ERROR on pinctrl/devel] [also build test ERROR on v5.8-rc1 next-20200615] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Andy-Shevchenko/pinctrl-intel-Reuse-for_each_requested_gpio-macros/20200615-231832 base: https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl.git devel config: x86_64-rhel-7.6 (attached as .config) compiler: gcc-9 (Debian 9.3.0-13) 9.3.0 reproduce (this is a W=1 build): # save the attached .config to linux build tree make W=1 ARCH=x86_64 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 >>, old ones prefixed by <<): drivers/pinctrl/intel/pinctrl-intel.c: In function 'intel_restore_hostown': >> drivers/pinctrl/intel/pinctrl-intel.c:1601:2: error: implicit declaration of function 'for_each_requested_gpio_in_range' [-Werror=implicit-function-declaration] 1601 | for_each_requested_gpio_in_range(&pctrl->chip, i, padgrp->gpio_base, padgrp->size, dummy) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >> drivers/pinctrl/intel/pinctrl-intel.c:1601:91: error: expected ';' before 'requested' 1601 | for_each_requested_gpio_in_range(&pctrl->chip, i, padgrp->gpio_base, padgrp->size, dummy) | ^ | ; 1602 | requested |= BIT(i); | ~~~~~~~~~ cc1: some warnings being treated as errors vim +/for_each_requested_gpio_in_range +1601 drivers/pinctrl/intel/pinctrl-intel.c 1587 1588 static void intel_restore_hostown(struct intel_pinctrl *pctrl, unsigned int c, 1589 void __iomem *base, unsigned int gpp, u32 saved) 1590 { 1591 const struct intel_community *community = &pctrl->communities[c]; 1592 const struct intel_padgroup *padgrp = &community->gpps[gpp]; 1593 struct device *dev = pctrl->dev; 1594 const char *dummy; 1595 u32 requested = 0; 1596 unsigned int i; 1597 1598 if (padgrp->gpio_base == INTEL_GPIO_BASE_NOMAP) 1599 return; 1600 > 1601 for_each_requested_gpio_in_range(&pctrl->chip, i, padgrp->gpio_base, padgrp->size, dummy) 1602 requested |= BIT(i); 1603 1604 if (!intel_gpio_update_reg(base + gpp * 4, requested, saved)) 1605 return; 1606 1607 dev_dbg(dev, "restored hostown %u/%u %#08x\n", c, gpp, readl(base + gpp * 4)); 1608 } 1609 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
On Tue, Jun 16, 2020 at 4:18 AM kernel test robot <lkp@intel.com> wrote: > > Hi Andy, > > I love your patch! Yet something to improve: > > [auto build test ERROR on pinctrl/devel] > [also build test ERROR on v5.8-rc1 next-20200615] > [if your patch is applied to the wrong git tree, please drop us a note to help > improve the system. BTW, we also suggest to use '--base' option to specify the > base tree in git format-patch, please see https://stackoverflow.com/a/37406982] Is there a way to tell kbuild bot to use another patch series (by link to lore?) that should be used as a base? In any case this series has such links in a cover letter. Can kbuild bot parse it (perhaps some special tag, like BaseLink: is needed)?
On Tue, Jun 16, 2020 at 08:36:11AM +0300, Andy Shevchenko wrote: > On Tue, Jun 16, 2020 at 4:18 AM kernel test robot <lkp@intel.com> wrote: > > > > Hi Andy, > > > > I love your patch! Yet something to improve: > > > > [auto build test ERROR on pinctrl/devel] > > [also build test ERROR on v5.8-rc1 next-20200615] > > [if your patch is applied to the wrong git tree, please drop us a note to help > > improve the system. BTW, we also suggest to use '--base' option to specify the > > base tree in git format-patch, please see https://stackoverflow.com/a/37406982] > > Is there a way to tell kbuild bot to use another patch series (by link > to lore?) that should be used as a base? Hi Andy, currently we recommend to use --base option to deduce the base commit, and bot will read this information to find a better tree as base that contains the base commit. > In any case this series has such links in a cover letter. Can kbuild > bot parse it (perhaps some special tag, like BaseLink: is needed)? We haven't support other way yet. With --base option, we will parse the extra information added by --base. > > > -- > With Best Regards, > Andy Shevchenko > _______________________________________________ > kbuild-all mailing list -- kbuild-all@lists.01.org > To unsubscribe send an email to kbuild-all-leave@lists.01.org
diff --git a/drivers/pinctrl/intel/pinctrl-intel.c b/drivers/pinctrl/intel/pinctrl-intel.c index 35c88fcb75a2..b64997b303e0 100644 --- a/drivers/pinctrl/intel/pinctrl-intel.c +++ b/drivers/pinctrl/intel/pinctrl-intel.c @@ -1628,19 +1628,6 @@ static void intel_gpio_irq_init(struct intel_pinctrl *pctrl) } } -static u32 -intel_gpio_is_requested(struct gpio_chip *chip, int base, unsigned int size) -{ - u32 requested = 0; - unsigned int i; - - for (i = 0; i < size; i++) - if (gpiochip_is_requested(chip, base + i)) - requested |= BIT(i); - - return requested; -} - static bool intel_gpio_update_reg(void __iomem *reg, u32 mask, u32 value) { u32 curr, updated; @@ -1661,12 +1648,16 @@ static void intel_restore_hostown(struct intel_pinctrl *pctrl, unsigned int c, const struct intel_community *community = &pctrl->communities[c]; const struct intel_padgroup *padgrp = &community->gpps[gpp]; struct device *dev = pctrl->dev; - u32 requested; + const char *dummy; + u32 requested = 0; + unsigned int i; if (padgrp->gpio_base == INTEL_GPIO_BASE_NOMAP) return; - requested = intel_gpio_is_requested(&pctrl->chip, padgrp->gpio_base, padgrp->size); + for_each_requested_gpio_in_range(&pctrl->chip, i, padgrp->gpio_base, padgrp->size, dummy) + requested |= BIT(i); + if (!intel_gpio_update_reg(base + gpp * 4, requested, saved)) return;
Make use of for_each_requested_gpio_in_range() instead of home grown analogue. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> --- drivers/pinctrl/intel/pinctrl-intel.c | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-)