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>
This commit is contained in:
Rohit Kumar 2018-06-06 14:25:24 +05:30 committed by Mark Brown
parent a0d847c380
commit d5c4e972d5
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0

View File

@ -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");