linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ASoC: qcom: apq8096: set card as device drvdata
@ 2018-06-06  8:55 Rohit kumar
  2018-06-06  9:16 ` Srinivas Kandagatla
  2018-06-18 12:00 ` Applied "ASoC: qcom: apq8096: set card as device drvdata" to the asoc tree Mark Brown
  0 siblings, 2 replies; 3+ messages in thread
From: Rohit kumar @ 2018-06-06  8:55 UTC (permalink / raw)
  To: plai, bgoswami, srinivas.kandagatla, rohkumar, lgirdwood,
	broonie, perex, tiwai, alsa-devel, linux-kernel
  Cc: Rohit kumar

snd_soc_card is retrieved as device drvdata during unbind().
Set it as drvdata during bind() to avoid memory corruption during
unbind().

Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
---
 sound/soc/qcom/apq8096.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/qcom/apq8096.c b/sound/soc/qcom/apq8096.c
index 561cd42..239b8cb 100644
--- a/sound/soc/qcom/apq8096.c
+++ b/sound/soc/qcom/apq8096.c
@@ -140,6 +140,7 @@ static int apq8096_bind(struct device *dev)
 
 	component_bind_all(dev, card);
 	card->dev = dev;
+	dev_set_drvdata(dev, card);
 	ret = apq8096_sbc_parse_of(card);
 	if (ret) {
 		dev_err(dev, "Error parsing OF data\n");
-- 
Qualcomm India Private Limited, on behalf of Qualcomm Innovation Center, Inc.,
is a member of Code Aurora Forum, a Linux Foundation Collaborative Project.

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ASoC: qcom: apq8096: set card as device drvdata
  2018-06-06  8:55 [PATCH] ASoC: qcom: apq8096: set card as device drvdata Rohit kumar
@ 2018-06-06  9:16 ` Srinivas Kandagatla
  2018-06-18 12:00 ` Applied "ASoC: qcom: apq8096: set card as device drvdata" to the asoc tree Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Srinivas Kandagatla @ 2018-06-06  9:16 UTC (permalink / raw)
  To: Rohit kumar, plai, bgoswami, rohkumar, lgirdwood, broonie, perex,
	tiwai, alsa-devel, linux-kernel



On 06/06/18 09:55, Rohit kumar wrote:
> snd_soc_card is retrieved as device drvdata during unbind().
> Set it as drvdata during bind() to avoid memory corruption during
> unbind().
> 
> Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Thanks for the patch,

Acked-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>


> ---
>   sound/soc/qcom/apq8096.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/sound/soc/qcom/apq8096.c b/sound/soc/qcom/apq8096.c
> index 561cd42..239b8cb 100644
> --- a/sound/soc/qcom/apq8096.c
> +++ b/sound/soc/qcom/apq8096.c
> @@ -140,6 +140,7 @@ static int apq8096_bind(struct device *dev)
>   
>   	component_bind_all(dev, card);
>   	card->dev = dev;
> +	dev_set_drvdata(dev, card);
>   	ret = apq8096_sbc_parse_of(card);
>   	if (ret) {
>   		dev_err(dev, "Error parsing OF data\n");
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Applied "ASoC: qcom: apq8096: set card as device drvdata" to the asoc tree
  2018-06-06  8:55 [PATCH] ASoC: qcom: apq8096: set card as device drvdata Rohit kumar
  2018-06-06  9:16 ` Srinivas Kandagatla
@ 2018-06-18 12:00 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2018-06-18 12:00 UTC (permalink / raw)
  To: Rohit Kumar
  Cc: Rohit kumar, Srinivas Kandagatla, Mark Brown, plai, bgoswami,
	srinivas.kandagatla, rohkumar, lgirdwood, broonie, perex, tiwai,
	alsa-devel, linux-kernel, Rohit kumar, alsa-devel

The patch

   ASoC: qcom: apq8096: set card as device drvdata

has been applied to the asoc tree at

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git 

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

From d5c4e972d512ae0b59108ca92b9b35bc5cf5c14e Mon Sep 17 00:00:00 2001
From: Rohit Kumar <rohitkr@codeaurora.org>
Date: Wed, 6 Jun 2018 14:25:24 +0530
Subject: [PATCH] ASoC: qcom: apq8096: set card as device drvdata

snd_soc_card is retrieved as device drvdata during unbind().
Set it as drvdata during bind() to avoid memory corruption during
unbind().

Signed-off-by: Rohit kumar <rohitkr@codeaurora.org>
Acked-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/qcom/apq8096.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/soc/qcom/apq8096.c b/sound/soc/qcom/apq8096.c
index 561cd429e6f2..239b8cb77bdb 100644
--- a/sound/soc/qcom/apq8096.c
+++ b/sound/soc/qcom/apq8096.c
@@ -140,6 +140,7 @@ static int apq8096_bind(struct device *dev)
 
 	component_bind_all(dev, card);
 	card->dev = dev;
+	dev_set_drvdata(dev, card);
 	ret = apq8096_sbc_parse_of(card);
 	if (ret) {
 		dev_err(dev, "Error parsing OF data\n");
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-06-18 12:03 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-06  8:55 [PATCH] ASoC: qcom: apq8096: set card as device drvdata Rohit kumar
2018-06-06  9:16 ` Srinivas Kandagatla
2018-06-18 12:00 ` Applied "ASoC: qcom: apq8096: set card as device drvdata" to the asoc tree Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).