tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: c1649ec55708ae42091a2f1bca1ab49ecd722d55
commit: a575207583676298f3999d41d86d81f7172fe950 pinctrl: at91: move gpio suspend/resume calls to driver's context
date: 5 months ago
config: arm-randconfig-r046-20230118 (https://download.01.org/0day-ci/archive/20230119/[email protected]/config)
compiler: clang version 16.0.0 (https://github.com/llvm/llvm-project 4196ca3278f78c6e19246e54ab0ecb364e37d66a)
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
# install arm cross compiling tool for clang build
# apt-get install binutils-arm-linux-gnueabi
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=a575207583676298f3999d41d86d81f7172fe950
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout a575207583676298f3999d41d86d81f7172fe950
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash drivers/pinctrl/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <[email protected]>
All warnings (new ones prefixed by >>):
>> drivers/pinctrl/pinctrl-at91.c:1650:12: warning: unused function 'at91_gpio_suspend' [-Wunused-function]
static int at91_gpio_suspend(struct device *dev)
^
>> drivers/pinctrl/pinctrl-at91.c:1668:12: warning: unused function 'at91_gpio_resume' [-Wunused-function]
static int at91_gpio_resume(struct device *dev)
^
2 warnings generated.
Please check if the functions need to be guarded with a config.
vim +/at91_gpio_suspend +1650 drivers/pinctrl/pinctrl-at91.c
647f8d94a4e69d Ludovic Desroches 2013-03-08 1649
a5752075836762 Claudiu Beznea 2022-08-31 @1650 static int at91_gpio_suspend(struct device *dev)
647f8d94a4e69d Ludovic Desroches 2013-03-08 1651 {
a5752075836762 Claudiu Beznea 2022-08-31 1652 struct at91_gpio_chip *at91_chip = dev_get_drvdata(dev);
a5752075836762 Claudiu Beznea 2022-08-31 1653 void __iomem *pio = at91_chip->regbase;
647f8d94a4e69d Ludovic Desroches 2013-03-08 1654
a5752075836762 Claudiu Beznea 2022-08-31 1655 at91_chip->backups = readl_relaxed(pio + PIO_IMR);
a5752075836762 Claudiu Beznea 2022-08-31 1656 writel_relaxed(at91_chip->backups, pio + PIO_IDR);
a5752075836762 Claudiu Beznea 2022-08-31 1657 writel_relaxed(at91_chip->wakeups, pio + PIO_IER);
647f8d94a4e69d Ludovic Desroches 2013-03-08 1658
a5752075836762 Claudiu Beznea 2022-08-31 1659 if (!at91_chip->wakeups)
a5752075836762 Claudiu Beznea 2022-08-31 1660 clk_disable_unprepare(at91_chip->clock);
795f9953eaccf9 Boris Brezillon 2013-12-15 1661 else
647f8d94a4e69d Ludovic Desroches 2013-03-08 1662 printk(KERN_DEBUG "GPIO-%c may wake for %08x\n",
a5752075836762 Claudiu Beznea 2022-08-31 1663 'A' + at91_chip->id, at91_chip->wakeups);
a5752075836762 Claudiu Beznea 2022-08-31 1664
a5752075836762 Claudiu Beznea 2022-08-31 1665 return 0;
647f8d94a4e69d Ludovic Desroches 2013-03-08 1666 }
647f8d94a4e69d Ludovic Desroches 2013-03-08 1667
a5752075836762 Claudiu Beznea 2022-08-31 @1668 static int at91_gpio_resume(struct device *dev)
647f8d94a4e69d Ludovic Desroches 2013-03-08 1669 {
a5752075836762 Claudiu Beznea 2022-08-31 1670 struct at91_gpio_chip *at91_chip = dev_get_drvdata(dev);
a5752075836762 Claudiu Beznea 2022-08-31 1671 void __iomem *pio = at91_chip->regbase;
647f8d94a4e69d Ludovic Desroches 2013-03-08 1672
a5752075836762 Claudiu Beznea 2022-08-31 1673 if (!at91_chip->wakeups)
a5752075836762 Claudiu Beznea 2022-08-31 1674 clk_prepare_enable(at91_chip->clock);
647f8d94a4e69d Ludovic Desroches 2013-03-08 1675
a5752075836762 Claudiu Beznea 2022-08-31 1676 writel_relaxed(at91_chip->wakeups, pio + PIO_IDR);
a5752075836762 Claudiu Beznea 2022-08-31 1677 writel_relaxed(at91_chip->backups, pio + PIO_IER);
647f8d94a4e69d Ludovic Desroches 2013-03-08 1678
a5752075836762 Claudiu Beznea 2022-08-31 1679 return 0;
647f8d94a4e69d Ludovic Desroches 2013-03-08 1680 }
647f8d94a4e69d Ludovic Desroches 2013-03-08 1681
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests