ASoC: qcom: Set card->owner to avoid warnings
Subsystems (3)
PATCH 1/1 ASoC: qcom: Set card->owner to avoid warnings
On Linux 5.9-rc1 I get the following warning with apq8016-sbc:
WARNING: CPU: 2 PID: 69 at sound/core/init.c:207 snd_card_new+0x36c/0x3b0 [snd] CPU: 2 PID: 69 Comm: kworker/2:1 Not tainted 5.9.0-rc1 #1 Workqueue: events deferred_probe_work_func pc : snd_card_new+0x36c/0x3b0 [snd] lr : snd_card_new+0xf4/0x3b0 [snd] Call trace: snd_card_new+0x36c/0x3b0 [snd] snd_soc_bind_card+0x340/0x9a0 [snd_soc_core] snd_soc_register_card+0xf4/0x110 [snd_soc_core] devm_snd_soc_register_card+0x44/0xa0 [snd_soc_core] apq8016_sbc_platform_probe+0x11c/0x140 [snd_soc_apq8016_sbc]
This warning was introduced in
commit 81033c6b584b ("ALSA: core: Warn on empty module"). It looks like we are supposed to set card->owner to THIS_MODULE.
Fix this for all the qcom ASoC drivers.
--- sound/soc/qcom/apq8016_sbc.c | 1 + sound/soc/qcom/apq8096.c | 1 + sound/soc/qcom/sdm845.c | 1 + sound/soc/qcom/storm.c | 1 + 4 files changed, 4 insertions(+)
sound/soc/qcom/apq8016_sbc.c +1 -0
@@ -143,6 +143,7 @@ static int apq8016_sbc_platform_probe(struct platform_device *pdev) card = &data->card; card->dev = dev; + card->owner =THIS_MODULE ; card->dapm_widgets = apq8016_sbc_dapm_widgets; card->num_dapm_widgets =ARRAY_SIZE (apq8016_sbc_dapm_widgets);
sound/soc/qcom/apq8096.c +1 -0
@@ -114,6 +114,7 @@ static int apq8096_platform_probe(struct platform_device *pdev)return -ENOMEM ; card->dev = dev; + card->owner =THIS_MODULE ;dev_set_drvdata (dev, card); ret =qcom_snd_parse_of (card);if (ret)
sound/soc/qcom/sdm845.c +1 -0
@@ -555,6 +555,7 @@ static int sdm845_snd_platform_probe(struct platform_device *pdev) card->dapm_widgets = sdm845_snd_widgets; card->num_dapm_widgets =ARRAY_SIZE (sdm845_snd_widgets); card->dev = dev; + card->owner =THIS_MODULE ;dev_set_drvdata (dev, card); ret =qcom_snd_parse_of (card);if (ret)
sound/soc/qcom/storm.c +1 -0
@@ -96,6 +96,7 @@ static int storm_platform_probe(struct platform_device *pdev)return -ENOMEM ; card->dev = &pdev->dev; + card->owner =THIS_MODULE ; ret =snd_soc_of_parse_card_name (card,"qcom,model" );if (ret) {
Signature · 1 line
2.28.0
Mark Brown
maintainerQuoted 14 lines · Stephan Gerhold
On Linux 5.9-rc1 I get the following warning with apq8016-sbc:
WARNING: CPU: 2 PID: 69 at sound/core/init.c:207 snd_card_new+0x36c/0x3b0 [snd] CPU: 2 PID: 69 Comm: kworker/2:1 Not tainted 5.9.0-rc1 #1 Workqueue: events deferred_probe_work_func pc : snd_card_new+0x36c/0x3b0 [snd] lr : snd_card_new+0xf4/0x3b0 [snd] Call trace: snd_card_new+0x36c/0x3b0 [snd] snd_soc_bind_card+0x340/0x9a0 [snd_soc_core] snd_soc_register_card+0xf4/0x110 [snd_soc_core] devm_snd_soc_register_card+0x44/0xa0 [snd_soc_core] apq8016_sbc_platform_probe+0x11c/0x140 [snd_soc_apq8016_sbc]
Quoted 1 line
[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/1] ASoC: qcom: Set card->owner to avoid warnings
commit: 3c27ea23ffb43262da6c64964163895951aaed4e
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