Message ID | 20221004211412.182940-1-colin.i.king@gmail.com |
---|---|
State | Changes Requested |
Headers | show |
Series | mtd: dataflash: Remove duplicated id table | expand |
Hi Colin,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on mtd/mtd/next]
[also build test WARNING on mtd/mtd/fixes linus/master v6.0 next-20221004]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Colin-Ian-King/mtd-dataflash-Remove-duplicated-id-table/20221005-051450
base: https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next
config: x86_64-allyesconfig
compiler: gcc-11 (Debian 11.3.0-5) 11.3.0
reproduce (this is a W=1 build):
# https://github.com/intel-lab-lkp/linux/commit/26720a1a9258db8e7258181bbce5ff3767fbeed0
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Colin-Ian-King/mtd-dataflash-Remove-duplicated-id-table/20221005-051450
git checkout 26720a1a9258db8e7258181bbce5ff3767fbeed0
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/mtd/devices/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> drivers/mtd/devices/mtd_dataflash.c:99:35: warning: 'dataflash_dev_ids' defined but not used [-Wunused-const-variable=]
99 | static const struct spi_device_id dataflash_dev_ids[] = {
| ^~~~~~~~~~~~~~~~~
vim +/dataflash_dev_ids +99 drivers/mtd/devices/mtd_dataflash.c
1d6432fe10c3e7 David Brownell 2006-01-08 98
27a030e8729255 Jon Hunter 2021-11-30 @99 static const struct spi_device_id dataflash_dev_ids[] = {
27a030e8729255 Jon Hunter 2021-11-30 100 { "at45" },
27a030e8729255 Jon Hunter 2021-11-30 101 { "dataflash" },
27a030e8729255 Jon Hunter 2021-11-30 102 { },
27a030e8729255 Jon Hunter 2021-11-30 103 };
27a030e8729255 Jon Hunter 2021-11-30 104 MODULE_DEVICE_TABLE(spi, dataflash_dev_ids);
27a030e8729255 Jon Hunter 2021-11-30 105
Hi Colin,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on mtd/mtd/next]
[also build test WARNING on mtd/mtd/fixes linus/master v6.0 next-20221004]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Colin-Ian-King/mtd-dataflash-Remove-duplicated-id-table/20221005-051450
base: https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next
config: hexagon-randconfig-r023-20221002
compiler: clang version 16.0.0 (https://github.com/llvm/llvm-project 791a7ae1ba3efd6bca96338e10ffde557ba83920)
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
# https://github.com/intel-lab-lkp/linux/commit/26720a1a9258db8e7258181bbce5ff3767fbeed0
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Colin-Ian-King/mtd-dataflash-Remove-duplicated-id-table/20221005-051450
git checkout 26720a1a9258db8e7258181bbce5ff3767fbeed0
# 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=hexagon SHELL=/bin/bash drivers/mtd/devices/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> drivers/mtd/devices/mtd_dataflash.c:99:35: warning: unused variable 'dataflash_dev_ids' [-Wunused-const-variable]
static const struct spi_device_id dataflash_dev_ids[] = {
^
1 warning generated.
vim +/dataflash_dev_ids +99 drivers/mtd/devices/mtd_dataflash.c
1d6432fe10c3e7 David Brownell 2006-01-08 98
27a030e8729255 Jon Hunter 2021-11-30 @99 static const struct spi_device_id dataflash_dev_ids[] = {
27a030e8729255 Jon Hunter 2021-11-30 100 { "at45" },
27a030e8729255 Jon Hunter 2021-11-30 101 { "dataflash" },
27a030e8729255 Jon Hunter 2021-11-30 102 { },
27a030e8729255 Jon Hunter 2021-11-30 103 };
27a030e8729255 Jon Hunter 2021-11-30 104 MODULE_DEVICE_TABLE(spi, dataflash_dev_ids);
27a030e8729255 Jon Hunter 2021-11-30 105
diff --git a/drivers/mtd/devices/mtd_dataflash.c b/drivers/mtd/devices/mtd_dataflash.c index 25bad4318305..c6d25331e00c 100644 --- a/drivers/mtd/devices/mtd_dataflash.c +++ b/drivers/mtd/devices/mtd_dataflash.c @@ -939,7 +939,6 @@ static struct spi_driver dataflash_driver = { .name = "mtd_dataflash", .of_match_table = of_match_ptr(dataflash_dt_ids), }, - .id_table = dataflash_dev_ids, .probe = dataflash_probe, .remove = dataflash_remove,
A previous change added a new id table but failed to remove the original assignment to .id_table. Remove the original to clean up a clang scan build warning: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides] Fixes: ac4f83482afb ("mtd: dataflash: Add SPI ID table") Signed-off-by: Colin Ian King <colin.i.king@gmail.com> --- drivers/mtd/devices/mtd_dataflash.c | 1 - 1 file changed, 1 deletion(-)