diff options
Diffstat (limited to 'sound/drivers/virmidi.c')
-rw-r--r-- | sound/drivers/virmidi.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sound/drivers/virmidi.c b/sound/drivers/virmidi.c index 4258723de2ab..a3ee306239c9 100644 --- a/sound/drivers/virmidi.c +++ b/sound/drivers/virmidi.c | |||
@@ -163,8 +163,10 @@ static int __init alsa_card_virmidi_init(void) | |||
163 | return err; | 163 | return err; |
164 | 164 | ||
165 | cards = 0; | 165 | cards = 0; |
166 | for (i = 0; i < SNDRV_CARDS && enable[i]; i++) { | 166 | for (i = 0; i < SNDRV_CARDS; i++) { |
167 | struct platform_device *device; | 167 | struct platform_device *device; |
168 | if (! enable[i]) | ||
169 | continue; | ||
168 | device = platform_device_register_simple(SND_VIRMIDI_DRIVER, | 170 | device = platform_device_register_simple(SND_VIRMIDI_DRIVER, |
169 | i, NULL, 0); | 171 | i, NULL, 0); |
170 | if (IS_ERR(device)) { | 172 | if (IS_ERR(device)) { |