ASoC: Only deregister AC97 dev if it's name was not "AC97"
authorAtsushi Nemoto <anemo@mba.ocn.ne.jp>
Mon, 16 Mar 2009 14:26:20 +0000 (23:26 +0900)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 17 Mar 2009 13:59:47 +0000 (13:59 +0000)
commitd2314e0e27566f8830ebed3587cc049e07e6a4ee
tree14f27f22f0725f123c8882fe463db414cb3e5fda
parent852fd9e50f62b4ea7afe26eee0710464de4801b8
ASoC: Only deregister AC97 dev if it's name was not "AC97"

The commit 14fa43f53ff3a9c3d8b9662574b7369812a31a97 ("ASoC: Only
register AC97 bus if it's not done already") added a condition for
calling of soc_ac97_dev_register() but not added for calling of
soc_ac97_dev_unregister().  This patch adds same condition for
soc_ac97_dev_unregister().  Without this fix, kernel crashes when
unloading an asoc driver.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/soc-core.c