Skip to content

Commit

Permalink
ASoC: mc13783: Provide codec->control_data
Browse files Browse the repository at this point in the history
If codec->control_data is not provided, the following crash happens:

Unable to handle kernel NULL pointer dereference at virtual address 00000078
pgd = 80004000
[00000078] *pgd=00000000
Internal error: Oops: 5 [#1] SMP ARM
Modules linked in:
CPU: 0    Tainted: G        W     (3.5.0-next-20120725+ #1263)
PC is at regmap_read+0x18/0x64
LR is at hw_read+0x50/0x98
pc : [<802bcd90>]    lr : [<803cad18>]    psr: 60000013
...

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Fabio Estevam authored and Mark Brown committed Jul 26, 2012
1 parent aa50fe5 commit e13ab2a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sound/soc/codecs/mc13783.c
Original file line number Diff line number Diff line change
Expand Up @@ -581,6 +581,8 @@ static int mc13783_probe(struct snd_soc_codec *codec)
{
struct mc13783_priv *priv = snd_soc_codec_get_drvdata(codec);

codec->control_data = priv->mc13xxx;

mc13xxx_lock(priv->mc13xxx);

/* these are the reset values */
Expand Down

0 comments on commit e13ab2a

Please sign in to comment.