diff mbox

ASoC: fsl: imx-spdif: Set the card owner field

Message ID 1421260755-7445-1-git-send-email-festevam@gmail.com (mailing list archive)
State Accepted
Commit 7a3a907022439524704caecb717639aea2f1ef9c
Headers show

Commit Message

Fabio Estevam Jan. 14, 2015, 6:39 p.m. UTC
From: Fabio Estevam <fabio.estevam@freescale.com>

Set the card owner field to avoid getting a kernel crash when the imx-spdif
is unloaded while the playback is active.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
Build-tested only.

 sound/soc/fsl/imx-spdif.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Mark Brown Jan. 14, 2015, 6:49 p.m. UTC | #1
On Wed, Jan 14, 2015 at 04:39:15PM -0200, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Set the card owner field to avoid getting a kernel crash when the imx-spdif
> is unloaded while the playback is active.

Applied, thanks.
diff mbox

Patch

diff --git a/sound/soc/fsl/imx-spdif.c b/sound/soc/fsl/imx-spdif.c
index e94704f..33da26a 100644
--- a/sound/soc/fsl/imx-spdif.c
+++ b/sound/soc/fsl/imx-spdif.c
@@ -60,6 +60,7 @@  static int imx_spdif_audio_probe(struct platform_device *pdev)
 	data->card.dev = &pdev->dev;
 	data->card.dai_link = &data->dai;
 	data->card.num_links = 1;
+	data->card.owner = THIS_MODULE;
 
 	ret = snd_soc_of_parse_card_name(&data->card, "model");
 	if (ret)