drivers/edac/altera_edac.c:662:37: warning: unused variable 'altr_edac_a10_device_inject2_fops'

From: kernel test robot
Date: Sat Jun 19 2021 - 14:23:46 EST


Hi Krzysztof,

First bad commit (maybe != root cause):

tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: d9403d307dba1a71ee6462b22300c2d3be773b1c
commit: 4a9a1a5602d82c079325bf37466af0b67d6c0b9e arm64: socfpga: merge Agilex and N5X into ARCH_INTEL_SOCFPGA
date: 3 months ago
config: arm64-randconfig-r036-20210620 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project d1baf2895467735ab14f4b3415fce204c0cc8e7f)
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 arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=4a9a1a5602d82c079325bf37466af0b67d6c0b9e
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 4a9a1a5602d82c079325bf37466af0b67d6c0b9e
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm64

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/edac/altera_edac.c:541:42: warning: unused variable 'ocramecc_data' [-Wunused-const-variable]
static const struct edac_device_prv_data ocramecc_data;
^
drivers/edac/altera_edac.c:542:42: warning: unused variable 'l2ecc_data' [-Wunused-const-variable]
static const struct edac_device_prv_data l2ecc_data;
^
drivers/edac/altera_edac.c:543:42: warning: unused variable 'a10_ocramecc_data' [-Wunused-const-variable]
static const struct edac_device_prv_data a10_ocramecc_data;
^
drivers/edac/altera_edac.c:544:42: warning: unused variable 'a10_l2ecc_data' [-Wunused-const-variable]
static const struct edac_device_prv_data a10_l2ecc_data;
^
drivers/edac/altera_edac.c:642:37: warning: unused variable 'altr_edac_device_inject_fops' [-Wunused-const-variable]
static const struct file_operations altr_edac_device_inject_fops = {
^
>> drivers/edac/altera_edac.c:662:37: warning: unused variable 'altr_edac_a10_device_inject2_fops' [-Wunused-const-variable]
static const struct file_operations altr_edac_a10_device_inject2_fops = {
^
6 warnings generated.


vim +/altr_edac_a10_device_inject2_fops +662 drivers/edac/altera_edac.c

c7b4be8db8bc33 Thor Thayer 2016-04-06 657
064acbd4f4ab50 Thor Thayer 2018-09-25 658 static ssize_t altr_edac_a10_device_trig2(struct file *file,
064acbd4f4ab50 Thor Thayer 2018-09-25 659 const char __user *user_buf,
064acbd4f4ab50 Thor Thayer 2018-09-25 660 size_t count, loff_t *ppos);
064acbd4f4ab50 Thor Thayer 2018-09-25 661
064acbd4f4ab50 Thor Thayer 2018-09-25 @662 static const struct file_operations altr_edac_a10_device_inject2_fops = {
064acbd4f4ab50 Thor Thayer 2018-09-25 663 .open = simple_open,
064acbd4f4ab50 Thor Thayer 2018-09-25 664 .write = altr_edac_a10_device_trig2,
064acbd4f4ab50 Thor Thayer 2018-09-25 665 .llseek = generic_file_llseek,
064acbd4f4ab50 Thor Thayer 2018-09-25 666 };
064acbd4f4ab50 Thor Thayer 2018-09-25 667

:::::: The code at line 662 was first introduced by commit
:::::: 064acbd4f4ab509dd3f31e1a2d1e04a43d5b1009 EDAC, altera: Add Stratix10 peripheral support

:::::: TO: Thor Thayer <thor.thayer@xxxxxxxxxxxxxxx>
:::::: CC: Borislav Petkov <bp@xxxxxxx>

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

Attachment: .config.gz
Description: application/gzip