Messages in this thread | | | Date | Wed, 21 Dec 2016 03:16:22 +0800 | From | kbuild test robot <> | Subject | drivers/mtd/nand/xway_nand.c:235:1: error: type defaults to 'int' in declaration of 'MODULE_DEVICE_TABLE' |
| |
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: e93b1cc8a8965da137ffea0b88e5f62fa1d2a9e6 commit: d47529b2e9fe0ec2eb1f072afad8849f52e385c4 gpio: don't include module.h in shared driver header date: 3 months ago config: mips-xway_defconfig (attached as .config) compiler: mips-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705 reproduce: wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross git checkout d47529b2e9fe0ec2eb1f072afad8849f52e385c4 # save the attached .config to linux build tree make.cross ARCH=mips
All error/warnings (new ones prefixed by >>):
>> drivers/mtd/nand/xway_nand.c:235:1: warning: data definition has no type or storage class MODULE_DEVICE_TABLE(of, xway_nand_match); ^~~~~~~~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:235:1: error: type defaults to 'int' in declaration of 'MODULE_DEVICE_TABLE' [-Werror=implicit-int] >> drivers/mtd/nand/xway_nand.c:235:1: warning: parameter names (without types) in function declaration In file included from include/linux/mtd/mtd.h:26:0, from include/linux/mtd/nand.h:23, from drivers/mtd/nand/xway_nand.c:10: include/linux/device.h:1350:1: warning: data definition has no type or storage class module_init(__driver##_init); \ ^ include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:246:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(xway_nand_driver); ^~~~~~~~~~~~~~~~~~~~~~ include/linux/device.h:1350:1: error: type defaults to 'int' in declaration of 'module_init' [-Werror=implicit-int] module_init(__driver##_init); \ ^ include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:246:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(xway_nand_driver); ^~~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:6:0, from include/linux/kernel.h:6, from include/linux/list.h:8, from include/linux/wait.h:6, from include/linux/mtd/nand.h:21, from drivers/mtd/nand/xway_nand.c:10: include/linux/export.h:36:30: warning: parameter names (without types) in function declaration #define THIS_MODULE ((struct module *)0) ^ include/linux/platform_device.h:198:34: note: in expansion of macro 'THIS_MODULE' __platform_driver_register(drv, THIS_MODULE) ^~~~~~~~~~~ include/linux/device.h:1348:9: note: in expansion of macro 'platform_driver_register' return __register(&(__driver) , ##__VA_ARGS__); \ ^~~~~~~~~~ include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:246:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(xway_nand_driver); ^~~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/mtd/mtd.h:26:0, from include/linux/mtd/nand.h:23, from drivers/mtd/nand/xway_nand.c:10: include/linux/device.h:1355:1: warning: data definition has no type or storage class module_exit(__driver##_exit); ^ include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:246:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(xway_nand_driver); ^~~~~~~~~~~~~~~~~~~~~~ include/linux/device.h:1355:1: error: type defaults to 'int' in declaration of 'module_exit' [-Werror=implicit-int] module_exit(__driver##_exit); ^ include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:246:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(xway_nand_driver); ^~~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:6:0, from include/linux/kernel.h:6, from include/linux/list.h:8, from include/linux/wait.h:6, from include/linux/mtd/nand.h:21, from drivers/mtd/nand/xway_nand.c:10: include/linux/export.h:36:30: warning: parameter names (without types) in function declaration #define THIS_MODULE ((struct module *)0) ^ include/linux/platform_device.h:198:34: note: in expansion of macro 'THIS_MODULE' __platform_driver_register(drv, THIS_MODULE) ^~~~~~~~~~~ include/linux/device.h:1348:9: note: in expansion of macro 'platform_driver_register' return __register(&(__driver) , ##__VA_ARGS__); \ ^~~~~~~~~~ include/linux/platform_device.h:228:2: note: in expansion of macro 'module_driver' module_driver(__platform_driver, platform_driver_register, \ ^~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:246:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(xway_nand_driver); ^~~~~~~~~~~~~~~~~~~~~~ >> drivers/mtd/nand/xway_nand.c:248:16: error: expected declaration specifiers or '...' before string constant MODULE_LICENSE("GPL"); ^~~~~ In file included from include/linux/mtd/mtd.h:26:0, from include/linux/mtd/nand.h:23, from drivers/mtd/nand/xway_nand.c:10: drivers/mtd/nand/xway_nand.c:246:24: warning: 'xway_nand_driver_init' defined but not used [-Wunused-function] module_platform_driver(xway_nand_driver); ^ include/linux/device.h:1346:19: note: in definition of macro 'module_driver' static int __init __driver##_init(void) \ ^~~~~~~~ >> drivers/mtd/nand/xway_nand.c:246:1: note: in expansion of macro 'module_platform_driver' module_platform_driver(xway_nand_driver); ^~~~~~~~~~~~~~~~~~~~~~ cc1: some warnings being treated as errors
vim +235 drivers/mtd/nand/xway_nand.c
99f2b107 John Crispin 2012-08-23 229 } 99f2b107 John Crispin 2012-08-23 230 02436675 Hauke Mehrtens 2016-06-20 231 static const struct of_device_id xway_nand_match[] = { 02436675 Hauke Mehrtens 2016-06-20 232 { .compatible = "lantiq,nand-xway" }, 02436675 Hauke Mehrtens 2016-06-20 233 {}, 02436675 Hauke Mehrtens 2016-06-20 234 }; 02436675 Hauke Mehrtens 2016-06-20 @235 MODULE_DEVICE_TABLE(of, xway_nand_match); 02436675 Hauke Mehrtens 2016-06-20 236 02436675 Hauke Mehrtens 2016-06-20 237 static struct platform_driver xway_nand_driver = { 02436675 Hauke Mehrtens 2016-06-20 238 .probe = xway_nand_probe, 02436675 Hauke Mehrtens 2016-06-20 239 .remove = xway_nand_remove, 02436675 Hauke Mehrtens 2016-06-20 240 .driver = { 02436675 Hauke Mehrtens 2016-06-20 241 .name = "lantiq,nand-xway", 02436675 Hauke Mehrtens 2016-06-20 242 .of_match_table = xway_nand_match, 02436675 Hauke Mehrtens 2016-06-20 243 }, 02436675 Hauke Mehrtens 2016-06-20 244 }; 02436675 Hauke Mehrtens 2016-06-20 245 02436675 Hauke Mehrtens 2016-06-20 @246 module_platform_driver(xway_nand_driver); 02436675 Hauke Mehrtens 2016-06-20 247 02436675 Hauke Mehrtens 2016-06-20 @248 MODULE_LICENSE("GPL");
:::::: The code at line 235 was first introduced by commit :::::: 024366750c2e04fdcda8bca685194ef0196b35fe mtd: nand: xway: convert to normal platform driver
:::::: TO: Hauke Mehrtens <hauke@hauke-m.de> :::::: CC: Boris Brezillon <boris.brezillon@free-electrons.com>
--- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation [unhandled content-type:application/gzip] | |