Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 24348
b: refs/heads/master
c: 8c59c4a
h: refs/heads/master
v: v3
  • Loading branch information
Bjorn Helgaas authored and Linus Torvalds committed Mar 27, 2006
1 parent ace20a9 commit 711f79b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ed7cb1913168fdce6d084f2f5cd6818851313383
refs/heads/master: 8c59c4a2216583cf79eaaaf71ef1dd5757e12854
17 changes: 8 additions & 9 deletions trunk/sound/isa/opl3sa2.c
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ static struct platform_device *platform_devices[SNDRV_CARDS];
static int pnp_registered;
static int pnpc_registered;
#endif
static unsigned int snd_opl3sa2_devices;

/* control ports */
#define OPL3SA2_PM_CTRL 0x01
Expand Down Expand Up @@ -760,6 +761,7 @@ static int __devinit snd_opl3sa2_pnp_detect(struct pnp_dev *pdev,
}
pnp_set_drvdata(pdev, card);
dev++;
snd_opl3sa2_devices++;
return 0;
}

Expand Down Expand Up @@ -826,6 +828,7 @@ static int __devinit snd_opl3sa2_pnp_cdetect(struct pnp_card_link *pcard,
}
pnp_set_card_drvdata(pcard, card);
dev++;
snd_opl3sa2_devices++;
return 0;
}

Expand Down Expand Up @@ -944,7 +947,7 @@ static void __init_or_module snd_opl3sa2_unregister_all(void)

static int __init alsa_card_opl3sa2_init(void)
{
int i, err, cards = 0;
int i, err;

if ((err = platform_driver_register(&snd_opl3sa2_nonpnp_driver)) < 0)
return err;
Expand All @@ -964,23 +967,19 @@ static int __init alsa_card_opl3sa2_init(void)
goto errout;
}
platform_devices[i] = device;
cards++;
snd_opl3sa2_devices++;
}

#ifdef CONFIG_PNP
err = pnp_register_driver(&opl3sa2_pnp_driver);
if (err >= 0) {
if (!err)
pnp_registered = 1;
cards += err;
}
err = pnp_register_card_driver(&opl3sa2_pnpc_driver);
if (err >= 0) {
if (!err)
pnpc_registered = 1;
cards += err;
}
#endif

if (!cards) {
if (!snd_opl3sa2_devices) {
#ifdef MODULE
snd_printk(KERN_ERR "Yamaha OPL3-SA soundcard not found or device busy\n");
#endif
Expand Down

0 comments on commit 711f79b

Please sign in to comment.