From: Liam Girdwood <lrg@ti.com>
To: Lars-Peter Clausen <lars@metafoo.de>
Cc: alsa-devel@alsa-project.org,
Mark Brown <broonie@opensource.wolfsonmicro.com>,
device-drivers-devel@blackfin.uclinux.org
Subject: Re: [PATCH] ASoC: ssm2602: Do not dereference codec->control_data
Date: Tue, 20 Sep 2011 12:20:34 +0100 [thread overview]
Message-ID: <1316517634.8314.3.camel@odin> (raw)
In-Reply-To: <1316499598-31539-1-git-send-email-lars@metafoo.de>
On Tue, 2011-09-20 at 08:19 +0200, Lars-Peter Clausen wrote:
> The driver assumes that control_data points to the drivers i2c_client struct,
> but this is no longer the case since the ASoC core has switched to regmap.
>
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> ---
> sound/soc/codecs/ssm2602.c | 3 +--
> 1 files changed, 1 insertions(+), 2 deletions(-)
>
> diff --git a/sound/soc/codecs/ssm2602.c b/sound/soc/codecs/ssm2602.c
> index 84f4ad5..cceb002 100644
> --- a/sound/soc/codecs/ssm2602.c
> +++ b/sound/soc/codecs/ssm2602.c
> @@ -294,7 +294,6 @@ static int ssm2602_startup(struct snd_pcm_substream *substream,
> struct snd_soc_pcm_runtime *rtd = substream->private_data;
> struct snd_soc_codec *codec = rtd->codec;
> struct ssm2602_priv *ssm2602 = snd_soc_codec_get_drvdata(codec);
> - struct i2c_client *i2c = codec->control_data;
> struct snd_pcm_runtime *master_runtime;
>
> /* The DAI has shared clocks so if we already have a playback or
> @@ -303,7 +302,7 @@ static int ssm2602_startup(struct snd_pcm_substream *substream,
> */
> if (ssm2602->master_substream) {
> master_runtime = ssm2602->master_substream->runtime;
> - dev_dbg(&i2c->dev, "Constraining to %d bits at %dHz\n",
> + dev_dbg(codec->dev, "Constraining to %d bits at %dHz\n",
> master_runtime->sample_bits,
> master_runtime->rate);
>
Acked-by: Liam Girdwood <lrg@ti.com>
next prev parent reply other threads:[~2011-09-20 11:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-20 6:19 [PATCH] ASoC: ssm2602: Do not dereference codec->control_data Lars-Peter Clausen
2011-09-20 11:20 ` Liam Girdwood [this message]
2011-09-20 12:04 ` Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1316517634.8314.3.camel@odin \
--to=lrg@ti.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@opensource.wolfsonmicro.com \
--cc=device-drivers-devel@blackfin.uclinux.org \
--cc=lars@metafoo.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox