drivers/net/dsa/microchip/ksz8795_spi.c:81:34: warning: unused variable 'ksz8795_dt_ids'

From: kernel test robot
Date: Sat Jul 25 2020 - 16:14:42 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 23ee3e4e5bd27bdbc0f1785eef7209ce872794c7
commit: e66f840c08a237acfbb981592047b53e7411012f net: dsa: ksz: Add Microchip KSZ8795 DSA driver
date: 12 months ago
config: x86_64-randconfig-a004-20200726 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 8bf4c1f4fb257774f66c8cda07adc6c5e8668326)
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 x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
git checkout e66f840c08a237acfbb981592047b53e7411012f
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All warnings (new ones prefixed by >>):

>> drivers/net/dsa/microchip/ksz8795_spi.c:81:34: warning: unused variable 'ksz8795_dt_ids' [-Wunused-const-variable]
static const struct of_device_id ksz8795_dt_ids[] = {
^
1 warning generated.

vim +/ksz8795_dt_ids +81 drivers/net/dsa/microchip/ksz8795_spi.c

80
> 81 static const struct of_device_id ksz8795_dt_ids[] = {
82 { .compatible = "microchip,ksz8765" },
83 { .compatible = "microchip,ksz8794" },
84 { .compatible = "microchip,ksz8795" },
85 {},
86 };
87 MODULE_DEVICE_TABLE(of, ksz8795_dt_ids);
88

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip