]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: core: Don't set "(null)" as a driver name
authorJarkko Nikula <jhnikula@gmail.com>
Fri, 20 May 2011 12:47:40 +0000 (15:47 +0300)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Sun, 22 May 2011 02:31:11 +0000 (10:31 +0800)
commit1ddc0b9a3a8ce4379d5da1b77ab4ecc4fb43d433
tree0b4e42916a78e943a6ff15fc414f108fd9b1bfb5
parent267533d9383d8f6cf0cf850ce6d83c207961ba12
ASoC: core: Don't set "(null)" as a driver name

Commit 220a77f ("ASoC: core - allow ASoC more flexible machine name")
writes "(null)" to driver name string in struct snd_card if card->driver_name
is NULL. This causes segmentation faults with some user space ALSA utilities
like aplay and arecord.

Fix this by using the card->name if no driver name is specified.

Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/soc-core.c