ASoC: loongson: make loongson-i2s.o a separate module
Subsystems (3)
PATCH 1/1 ASoC: loongson: make loongson-i2s.o a separate module
From: Arnd Bergmann <[email protected]>
An object file should not be linked into multiple modules and/or vmlinux:
scripts/Makefile.build:221: /home/arnd/arm-soc/sound/soc/loongson/Makefile: loongson_i2s.o is added to multiple modules: snd-soc-loongson-i2s-pci snd-soc-loongson-i2s-plat
Change this one to make it a library module with two exported symbols that will work in any configuration.
--- sound/soc/loongson/Makefile | 10 ++++++---- sound/soc/loongson/loongson_i2s.c | 5 +++++ 2 files changed, 11 insertions(+), 4 deletions(-)
sound/soc/loongson/Makefile +6 -4
@@ -1,10 +1,12 @@ # SPDX-License-Identifier: GPL-2.0 #Platform Support -snd-soc-loongson-i2s-pci-y := loongson_i2s_pci.o loongson_i2s.o loongson_dma.o -obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PCI) += snd-soc-loongson-i2s-pci.o +snd-soc-loongson-i2s-pci-y := loongson_i2s_pci.o loongson_dma.o +obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PCI) += snd-soc-loongson-i2s-pci.o snd-soc-loongson-i2s.o -snd-soc-loongson-i2s-plat-y := loongson_i2s_plat.o loongson_i2s.o -obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PLATFORM) += snd-soc-loongson-i2s-plat.o +snd-soc-loongson-i2s-plat-y := loongson_i2s_plat.o +obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PLATFORM) += snd-soc-loongson-i2s-plat.o snd-soc-loongson-i2s.o + +snd-soc-loongson-i2s-y := loongson_i2s.o #Machine Support snd-soc-loongson-card-y := loongson_card.o
sound/soc/loongson/loongson_i2s.c +5 -0
@@ -246,6 +246,7 @@ struct snd_soc_dai_driver loongson_i2s_dai = { .ops = &loongson_i2s_dai_ops, .symmetric_rate = 1, }; +EXPORT_SYMBOL_GPL (loongson_i2s_dai);static int i2s_suspend (struct device *dev) {
@@ -268,3 +269,7 @@ static int i2s_resume(struct device *dev)const struct dev_pm_ops loongson_i2s_pm = {SYSTEM_SLEEP_PM_OPS (i2s_suspend, i2s_resume) }; +EXPORT_SYMBOL_GPL (loongson_i2s_pm); + +MODULE_LICENSE ("GPL" ); +MODULE_DESCRIPTION ("Common functions for loongson I2S controller driver" );
Signature · 1 line
2.39.5
周彬彬
maintainerHi Arnd:
Thanks for your patch.
Quoted 7 lines
-----Original Messages-----
From: "Arnd Bergmann" <[email protected]>
Send time:Tuesday, 10/15/2024 23:09:54
To: "Liam Girdwood" <[email protected]>, "Mark Brown" <[email protected]>, "Jaroslav Kysela" <[email protected]>, "Takashi Iwai" <[email protected]>, "Binbin Zhou" <[email protected]>
Cc: "Arnd Bergmann" <[email protected]>, tangbin <[email protected]>, [email protected], [email protected]
Subject: [PATCH] ASoC: loongson: make loongson-i2s.o a separate module
Quoted 6 lines
From: Arnd Bergmann <[email protected]>
An object file should not be linked into multiple modules and/or vmlinux:
scripts/Makefile.build:221:/home/arnd/arm-soc/sound/soc/loongson/Makefile: loongson_i2s.o is added to multiple modules: snd-soc-loongson-i2s-pci snd-soc-loongson-i2s-plat
I would like to ask for some advice.
I didn't notice this warning before when I submitted the patch, is there some specific compilation option that needs to be turned on?
#
# SoC Audio for Loongson CPUs
#CONFIG_SND_SOC_LOONGSON_CARD=mCONFIG_SND_SOC_LOONGSON_I2S_PCI=mCONFIG_SND_SOC_LOONGSON_I2S_PLATFORM=m
# end of SoC Audio for Loongson CPUs
Thanks.
Binbin
Quoted 54 lines
Change this one to make it a library module with two exported symbols that will work in any configuration.
Fixes ba4c5fad598c ("ASoC: loongson: Add I2S controller driver as platform device")Signed-off-by Arnd Bergmann <[email protected]>--- sound/soc/loongson/Makefile | 10 ++++++---- sound/soc/loongson/loongson_i2s.c | 5 +++++ 2 files changed, 11 insertions(+), 4 deletions(-)sound/soc/loongson/Makefile +6
-4@@ -1,10 +1,12 @@ # SPDX-License-Identifier: GPL-2.0 #Platform Support -snd-soc-loongson-i2s-pci-y := loongson_i2s_pci.o loongson_i2s.o loongson_dma.o -obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PCI) += snd-soc-loongson-i2s-pci.o +snd-soc-loongson-i2s-pci-y := loongson_i2s_pci.o loongson_dma.o +obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PCI) += snd-soc-loongson-i2s-pci.o snd-soc-loongson-i2s.o -snd-soc-loongson-i2s-plat-y := loongson_i2s_plat.o loongson_i2s.o -obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PLATFORM) += snd-soc-loongson-i2s-plat.o +snd-soc-loongson-i2s-plat-y := loongson_i2s_plat.o +obj-$(CONFIG_SND_SOC_LOONGSON_I2S_PLATFORM) += snd-soc-loongson-i2s-plat.o snd-soc-loongson-i2s.o + +snd-soc-loongson-i2s-y := loongson_i2s.o #Machine Support snd-soc-loongson-card-y := loongson_card.osound/soc/loongson/loongson_i2s.c +5
-0@@ -246,6 +246,7 @@ struct snd_soc_dai_driver loongson_i2s_dai = { .ops = &loongson_i2s_dai_ops, .symmetric_rate = 1, }; +EXPORT_SYMBOL_GPL (loongson_i2s_dai);static int i2s_suspend (struct device *dev) {@@ -268,3 +269,7 @@ static int i2s_resume(struct device *dev)const struct dev_pm_ops loongson_i2s_pm = {SYSTEM_SLEEP_PM_OPS (i2s_suspend, i2s_resume) }; +EXPORT_SYMBOL_GPL (loongson_i2s_pm); + +MODULE_LICENSE ("GPL" ); +MODULE_DESCRIPTION ("Common functions for loongson I2S controller driver" );Signature · 1 line
2.39.5
本邮件及其附件含有龙芯中科的商业秘密信息,仅限于发送给上面地址中列出的个人或群组。禁止任何其他人以任何形式使用(包括但不限于全部或部分地泄露、复制或散发)本邮件及其附件中的信息。如果您错收本邮件,请您立即电话或邮件通知发件人并删除本邮件。
This email and its attachments contain confidential information from Loongson Technology , which is intended only for the person or entity whose address is listed above. Any use of the information contained herein in any way (including, but not limited to, total or partial disclosure, reproduction or dissemination) by persons other than the intended recipient(s) is prohibited. If you receive this email in error, please notify the sender by phone or email immediately and delete it.
Quoted 9 lines · 周彬彬
Quoted 9 lines
-----Original Messages-----
From: "Arnd Bergmann" <[email protected]>
Send time:Tuesday, 10/15/2024 23:09:54
To: "Liam Girdwood" <[email protected]>, "Mark Brown" <[email protected]>, "Jaroslav Kysela" <[email protected]>, "Takashi Iwai" <[email protected]>, "Binbin Zhou" <[email protected]>
Cc: "Arnd Bergmann" <[email protected]>, tangbin <[email protected]>, [email protected], [email protected]
Subject: [PATCH] ASoC: loongson: make loongson-i2s.o a separate moduleFrom: Arnd Bergmann <[email protected]>
Quoted 8 lines
Quoted 4 lines
An object file should not be linked into multiple modules and/or vmlinux:
scripts/Makefile.build:221:/home/arnd/arm-soc/sound/soc/loongson/Makefile: loongson_i2s.o is added to multiple modules: snd-soc-loongson-i2s-pci snd-soc-loongson-i2s-platI would like to ask for some advice.
I didn't notice this warning before when I submitted the patch, is there some specific compilation option that needs to be turned on?
I think this is one of the warnings that are currently only enabled when building with "make W=1". I have this enabled by default as I hope to make it a default warning soon.
In general, I would recommend to build new driver code with W=1 before submitting.
Arnd
Quoted 20 lines · Arnd Bergmann
Quoted 9 lines · 周彬彬
Quoted 9 lines
-----Original Messages-----
From: "Arnd Bergmann" <[email protected]>
Send time:Tuesday, 10/15/2024 23:09:54
To: "Liam Girdwood" <[email protected]>, "Mark Brown" <[email protected]>, "Jaroslav Kysela" <[email protected]>, "Takashi Iwai" <[email protected]>, "Binbin Zhou" <[email protected]>
Cc: "Arnd Bergmann" <[email protected]>, tangbin <[email protected]>, [email protected], [email protected]
Subject: [PATCH] ASoC: loongson: make loongson-i2s.o a separate moduleFrom: Arnd Bergmann <[email protected]>
Quoted 8 lines
Quoted 4 lines
An object file should not be linked into multiple modules and/or vmlinux:
scripts/Makefile.build:221:/home/arnd/arm-soc/sound/soc/loongson/Makefile: loongson_i2s.o is added to multiple modules: snd-soc-loongson-i2s-pci snd-soc-loongson-i2s-platI would like to ask for some advice.
I didn't notice this warning before when I submitted the patch, is there some specific compilation option that needs to be turned on?
Quoted 7 lines
I think this is one of the warnings that are currently only enabled when building with "make W=1". I have this enabled by default as I hope to make it a default warning soon.
In general, I would recommend to build new driver code with W=1 before submitting.
Okay, thanks for the advice.
I'll pay special attention to it when submitting code in the future.
Thanks.
Binbin
Quoted 1 line
Arnd
Mark Brown
maintainerQuoted 9 lines · Arnd Bergmann
An object file should not be linked into multiple modules and/or vmlinux:
scripts/Makefile.build:221:/home/arnd/arm-soc/sound/soc/loongson/Makefile: loongson_i2s.o is added to multiple modules: snd-soc-loongson-i2s-pci snd-soc-loongson-i2s-platChange this one to make it a library module with two exported symbols that will work in any configuration.
[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/1] ASoC: loongson: make loongson-i2s.o a separate module
commit: 43916d9288460bd76d47128898fdf5972dfdb87f
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark