diff options
author | Rene Herman <rene.herman@keyaccess.nl> | 2006-04-13 14:57:11 +0400 |
---|---|---|
committer | Jaroslav Kysela <perex@suse.cz> | 2006-04-27 23:10:08 +0400 |
commit | a182ee9876c7826d0b8f7789cb5c38c5bfbec441 (patch) | |
tree | 68862b25d3e70a8c294ec248d3473e30fb2aae94 /sound/drivers/dummy.c | |
parent | 5c59e09d7e51f5781439aa6f1963076568fd1f4f (diff) | |
download | linux-a182ee9876c7826d0b8f7789cb5c38c5bfbec441.tar.xz |
[ALSA] continue on IS_ERR from platform device registration
I previously only concerned myself with sound/isa. When I now checked
for more platform_device_register_simple() usages in ALSA I found a
couple more drivers that needed the same patches as already submitted
for all the ISA drivers.
This first one is the continue-on-iserr patch for sound/drivers. This
gets them all.
Signed-off-by: Rene Herman <rene.herman@keyaccess.nl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/drivers/dummy.c')
-rw-r--r-- | sound/drivers/dummy.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/sound/drivers/dummy.c b/sound/drivers/dummy.c index e35fd5779a9d..ae0df549fac7 100644 --- a/sound/drivers/dummy.c +++ b/sound/drivers/dummy.c @@ -675,10 +675,8 @@ static int __init alsa_card_dummy_init(void) continue; device = platform_device_register_simple(SND_DUMMY_DRIVER, i, NULL, 0); - if (IS_ERR(device)) { - err = PTR_ERR(device); - goto errout; - } + if (IS_ERR(device)) + continue; devices[i] = device; cards++; } @@ -686,14 +684,10 @@ static int __init alsa_card_dummy_init(void) #ifdef MODULE printk(KERN_ERR "Dummy soundcard not found or device busy\n"); #endif - err = -ENODEV; - goto errout; + snd_dummy_unregister_all(); + return -ENODEV; } return 0; - - errout: - snd_dummy_unregister_all(); - return err; } static void __exit alsa_card_dummy_exit(void) |