return snd_card_register(card);
}
-static int __init snd_es18xx_nonpnp_probe1(int dev, struct platform_device *devptr)
+static int __devinit snd_es18xx_nonpnp_probe1(int dev, struct platform_device *devptr)
{
struct snd_card *card;
int err;
return 0;
}
-static int __init snd_es18xx_nonpnp_probe(struct platform_device *pdev)
+static int __devinit snd_es18xx_nonpnp_probe(struct platform_device *pdev)
{
int dev = pdev->id;
int err;
#ifdef CONFIG_PNP
+static unsigned int __devinitdata es18xx_pnp_devices;
+
static int __devinit snd_audiodrive_pnp_detect(struct pnp_card_link *pcard,
const struct pnp_card_device_id *pid)
{
pnp_set_card_drvdata(pcard, card);
dev++;
+ es18xx_pnp_devices++;
return 0;
}
}
#ifdef CONFIG_PNP
- i = pnp_register_card_driver(&es18xx_pnpc_driver);
- if (i >= 0) {
+ err = pnp_register_card_driver(&es18xx_pnpc_driver);
+ if (!err) {
pnp_registered = 1;
- cards += i;
+ cards += es18xx_pnp_devices;
}
#endif