Skip to content

Commit

Permalink
ASoC: Improve diagnostics for AT91SAM9G20-EK probe
Browse files Browse the repository at this point in the history
We should display an error by default if we fail to register.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Mark Brown committed Feb 18, 2009
1 parent 22d22ee commit d694354
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions sound/soc/atmel/sam9g20_wm8731.c
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,7 @@ static int __init at91sam9g20ek_init(void)
*/
ssc = ssc_request(0);
if (IS_ERR(ssc)) {
printk(KERN_ERR "ASoC: Failed to request SSC 0\n");
ret = PTR_ERR(ssc);
ssc = NULL;
goto err_ssc;
Expand All @@ -281,8 +282,7 @@ static int __init at91sam9g20ek_init(void)

at91sam9g20ek_snd_device = platform_device_alloc("soc-audio", -1);
if (!at91sam9g20ek_snd_device) {
printk(KERN_DEBUG
"platform device allocation failed\n");
printk(KERN_ERR "ASoC: Platform device allocation failed\n");
ret = -ENOMEM;
}

Expand All @@ -292,8 +292,7 @@ static int __init at91sam9g20ek_init(void)

ret = platform_device_add(at91sam9g20ek_snd_device);
if (ret) {
printk(KERN_DEBUG
"platform device allocation failed\n");
printk(KERN_ERR "ASoC: Platform device allocation failed\n");
platform_device_put(at91sam9g20ek_snd_device);
}

Expand Down

0 comments on commit d694354

Please sign in to comment.