ASoC: wm8974: fix a memory leak if another WM8974 is registered
authorAxel Lin <axel.lin@gmail.com>
Fri, 23 Jul 2010 05:53:52 +0000 (05:53 +0000)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 3 Aug 2010 06:46:07 +0000 (07:46 +0100)
commit4eaac50552395f693b8c428872e8b5311c3dab60
treea3211849d447486cdd2051890b12ab3c1fea3d1b
parent6b5d071e8ba7d802f3123e7b7a37ea13650a98bf
ASoC: wm8974: fix a memory leak if another WM8974 is registered

wm8974 is allocated in wm8974_i2c_probe() but is not freed if wm8974_register()
return -EINVAL (if another WM8974 is registered).

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/codecs/wm8974.c