[alsa-devel] [PATCH 14/19] ASoC: wm8741: Convert to module_i2c/spi_driver()
kbuild test robot
lkp at intel.com
Tue Nov 15 18:51:52 CET 2016
Hi Kuninori,
[auto build test WARNING on v4.9-rc5]
[cannot apply to asoc/for-next next-20161115]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Kuninori-Morimoto/ASoC-Convert-to-module_i2c-spi_driver/20161116-005820
config: i386-randconfig-x008-201646 (attached as .config)
compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
All warnings (new ones prefixed by >>):
In file included from sound/soc/codecs/wm8741.c:14:0:
include/linux/module.h:130:27: error: redefinition of '__inittest'
static inline initcall_t __inittest(void) \
^
include/linux/device.h:1353:1: note: in expansion of macro 'module_init'
module_init(__driver##_init); \
^~~~~~~~~~~
include/linux/spi/spi.h:290:2: note: in expansion of macro 'module_driver'
module_driver(__spi_driver, spi_register_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:668:1: note: in expansion of macro 'module_spi_driver'
module_spi_driver(wm8741_spi_driver);
^~~~~~~~~~~~~~~~~
include/linux/module.h:130:27: note: previous definition of '__inittest' was here
static inline initcall_t __inittest(void) \
^
include/linux/device.h:1353:1: note: in expansion of macro 'module_init'
module_init(__driver##_init); \
^~~~~~~~~~~
include/linux/i2c.h:751:2: note: in expansion of macro 'module_driver'
module_driver(__i2c_driver, i2c_add_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:610:1: note: in expansion of macro 'module_i2c_driver'
module_i2c_driver(wm8741_i2c_driver);
^~~~~~~~~~~~~~~~~
include/linux/module.h:132:6: error: redefinition of 'init_module'
int init_module(void) __attribute__((alias(#initfn)));
^
include/linux/device.h:1353:1: note: in expansion of macro 'module_init'
module_init(__driver##_init); \
^~~~~~~~~~~
include/linux/spi/spi.h:290:2: note: in expansion of macro 'module_driver'
module_driver(__spi_driver, spi_register_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:668:1: note: in expansion of macro 'module_spi_driver'
module_spi_driver(wm8741_spi_driver);
^~~~~~~~~~~~~~~~~
include/linux/module.h:132:6: note: previous definition of 'init_module' was here
int init_module(void) __attribute__((alias(#initfn)));
^
include/linux/device.h:1353:1: note: in expansion of macro 'module_init'
module_init(__driver##_init); \
^~~~~~~~~~~
include/linux/i2c.h:751:2: note: in expansion of macro 'module_driver'
module_driver(__i2c_driver, i2c_add_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:610:1: note: in expansion of macro 'module_i2c_driver'
module_i2c_driver(wm8741_i2c_driver);
^~~~~~~~~~~~~~~~~
include/linux/module.h:136:27: error: redefinition of '__exittest'
static inline exitcall_t __exittest(void) \
^
include/linux/device.h:1358:1: note: in expansion of macro 'module_exit'
module_exit(__driver##_exit);
^~~~~~~~~~~
include/linux/spi/spi.h:290:2: note: in expansion of macro 'module_driver'
module_driver(__spi_driver, spi_register_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:668:1: note: in expansion of macro 'module_spi_driver'
module_spi_driver(wm8741_spi_driver);
^~~~~~~~~~~~~~~~~
include/linux/module.h:136:27: note: previous definition of '__exittest' was here
static inline exitcall_t __exittest(void) \
^
include/linux/device.h:1358:1: note: in expansion of macro 'module_exit'
module_exit(__driver##_exit);
^~~~~~~~~~~
include/linux/i2c.h:751:2: note: in expansion of macro 'module_driver'
module_driver(__i2c_driver, i2c_add_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:610:1: note: in expansion of macro 'module_i2c_driver'
module_i2c_driver(wm8741_i2c_driver);
^~~~~~~~~~~~~~~~~
include/linux/module.h:138:7: error: redefinition of 'cleanup_module'
void cleanup_module(void) __attribute__((alias(#exitfn)));
^
include/linux/device.h:1358:1: note: in expansion of macro 'module_exit'
module_exit(__driver##_exit);
^~~~~~~~~~~
include/linux/spi/spi.h:290:2: note: in expansion of macro 'module_driver'
module_driver(__spi_driver, spi_register_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:668:1: note: in expansion of macro 'module_spi_driver'
module_spi_driver(wm8741_spi_driver);
^~~~~~~~~~~~~~~~~
include/linux/module.h:138:7: note: previous definition of 'cleanup_module' was here
void cleanup_module(void) __attribute__((alias(#exitfn)));
^
include/linux/device.h:1358:1: note: in expansion of macro 'module_exit'
module_exit(__driver##_exit);
^~~~~~~~~~~
include/linux/i2c.h:751:2: note: in expansion of macro 'module_driver'
module_driver(__i2c_driver, i2c_add_driver, \
^~~~~~~~~~~~~
>> sound/soc/codecs/wm8741.c:610:1: note: in expansion of macro 'module_i2c_driver'
module_i2c_driver(wm8741_i2c_driver);
^~~~~~~~~~~~~~~~~
vim +/module_spi_driver +668 sound/soc/codecs/wm8741.c
604 .of_match_table = wm8741_of_match,
605 },
606 .probe = wm8741_i2c_probe,
607 .remove = wm8741_i2c_remove,
608 .id_table = wm8741_i2c_id,
609 };
> 610 module_i2c_driver(wm8741_i2c_driver);
611 #endif
612
613 #if defined(CONFIG_SPI_MASTER)
614 static int wm8741_spi_probe(struct spi_device *spi)
615 {
616 struct wm8741_priv *wm8741;
617 int ret, i;
618
619 wm8741 = devm_kzalloc(&spi->dev, sizeof(struct wm8741_priv),
620 GFP_KERNEL);
621 if (wm8741 == NULL)
622 return -ENOMEM;
623
624 for (i = 0; i < ARRAY_SIZE(wm8741->supplies); i++)
625 wm8741->supplies[i].supply = wm8741_supply_names[i];
626
627 ret = devm_regulator_bulk_get(&spi->dev, ARRAY_SIZE(wm8741->supplies),
628 wm8741->supplies);
629 if (ret != 0) {
630 dev_err(&spi->dev, "Failed to request supplies: %d\n", ret);
631 return ret;
632 }
633
634 wm8741->regmap = devm_regmap_init_spi(spi, &wm8741_regmap);
635 if (IS_ERR(wm8741->regmap)) {
636 ret = PTR_ERR(wm8741->regmap);
637 dev_err(&spi->dev, "Failed to init regmap: %d\n", ret);
638 return ret;
639 }
640
641 ret = wm8741_set_pdata(&spi->dev, wm8741);
642 if (ret != 0) {
643 dev_err(&spi->dev, "Failed to set pdata: %d\n", ret);
644 return ret;
645 }
646
647 spi_set_drvdata(spi, wm8741);
648
649 ret = snd_soc_register_codec(&spi->dev,
650 &soc_codec_dev_wm8741, &wm8741_dai, 1);
651 return ret;
652 }
653
654 static int wm8741_spi_remove(struct spi_device *spi)
655 {
656 snd_soc_unregister_codec(&spi->dev);
657 return 0;
658 }
659
660 static struct spi_driver wm8741_spi_driver = {
661 .driver = {
662 .name = "wm8741",
663 .of_match_table = wm8741_of_match,
664 },
665 .probe = wm8741_spi_probe,
666 .remove = wm8741_spi_remove,
667 };
> 668 module_spi_driver(wm8741_spi_driver);
669 #endif /* CONFIG_SPI_MASTER */
670
671 MODULE_DESCRIPTION("ASoC WM8741 driver");
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 29570 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20161116/e06ba329/attachment-0001.bin>
More information about the Alsa-devel
mailing list