drivers/mux/mmio.c:29:34: warning: 'mux_mmio_dt_ids' defined but not used

From: kernel test robot
Date: Sat May 27 2023 - 07:07:15 EST


Hi Aswath,

First bad commit (maybe != root cause):

tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 49572d5361298711207ab387a6c318407deb963a
commit: e4d4371253029528c02bfb43a46c252e1c3d035f phy: phy-can-transceiver: Add support for setting mux
date: 1 year, 2 months ago
config: i386-buildonly-randconfig-r006-20230526 (https://download.01.org/0day-ci/archive/20230527/202305271837.P7wi3WCR-lkp@xxxxxxxxx/config)
compiler: gcc-11 (Debian 11.3.0-12) 11.3.0
reproduce (this is a W=1 build):
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e4d4371253029528c02bfb43a46c252e1c3d035f
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout e4d4371253029528c02bfb43a46c252e1c3d035f
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=i386 olddefconfig
make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash drivers/mux/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202305271837.P7wi3WCR-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

>> drivers/mux/mmio.c:29:34: warning: 'mux_mmio_dt_ids' defined but not used [-Wunused-const-variable=]
29 | static const struct of_device_id mux_mmio_dt_ids[] = {
| ^~~~~~~~~~~~~~~


vim +/mux_mmio_dt_ids +29 drivers/mux/mmio.c

73726380a26fa1 drivers/mux/mux-mmio.c Philipp Zabel 2017-05-14 28
73726380a26fa1 drivers/mux/mux-mmio.c Philipp Zabel 2017-05-14 @29 static const struct of_device_id mux_mmio_dt_ids[] = {
73726380a26fa1 drivers/mux/mux-mmio.c Philipp Zabel 2017-05-14 30 { .compatible = "mmio-mux", },
8ecfaca7926f4b drivers/mux/mmio.c Pankaj Bansal 2019-06-12 31 { .compatible = "reg-mux", },
73726380a26fa1 drivers/mux/mux-mmio.c Philipp Zabel 2017-05-14 32 { /* sentinel */ }
73726380a26fa1 drivers/mux/mux-mmio.c Philipp Zabel 2017-05-14 33 };
73726380a26fa1 drivers/mux/mux-mmio.c Philipp Zabel 2017-05-14 34 MODULE_DEVICE_TABLE(of, mux_mmio_dt_ids);
73726380a26fa1 drivers/mux/mux-mmio.c Philipp Zabel 2017-05-14 35

:::::: The code at line 29 was first introduced by commit
:::::: 73726380a26fa1ed490f30fccee10ed9da28dc0c mux: mmio-based syscon mux controller

:::::: TO: Philipp Zabel <p.zabel@xxxxxxxxxxxxxx>
:::::: CC: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki