From e9f66d9b9ce03f74a52894cebedf12b67f65dd24 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Tue, 24 Apr 2012 12:25:00 +0200 Subject: ALSA: pci: clean up using module_pci_driver() Signed-off-by: Takashi Iwai --- sound/pci/rme9652/hdsp.c | 15 ++------------- sound/pci/rme9652/hdspm.c | 16 ++-------------- sound/pci/rme9652/rme9652.c | 15 ++------------- 3 files changed, 6 insertions(+), 40 deletions(-) (limited to 'sound/pci/rme9652') diff --git a/sound/pci/rme9652/hdsp.c b/sound/pci/rme9652/hdsp.c index b68cdec03b9e..5cc31a400810 100644 --- a/sound/pci/rme9652/hdsp.c +++ b/sound/pci/rme9652/hdsp.c @@ -5635,22 +5635,11 @@ static void __devexit snd_hdsp_remove(struct pci_dev *pci) pci_set_drvdata(pci, NULL); } -static struct pci_driver driver = { +static struct pci_driver hdsp_driver = { .name = KBUILD_MODNAME, .id_table = snd_hdsp_ids, .probe = snd_hdsp_probe, .remove = __devexit_p(snd_hdsp_remove), }; -static int __init alsa_card_hdsp_init(void) -{ - return pci_register_driver(&driver); -} - -static void __exit alsa_card_hdsp_exit(void) -{ - pci_unregister_driver(&driver); -} - -module_init(alsa_card_hdsp_init) -module_exit(alsa_card_hdsp_exit) +module_pci_driver(hdsp_driver); diff --git a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c index bc030a2088da..0a5027b94714 100644 --- a/sound/pci/rme9652/hdspm.c +++ b/sound/pci/rme9652/hdspm.c @@ -6918,23 +6918,11 @@ static void __devexit snd_hdspm_remove(struct pci_dev *pci) pci_set_drvdata(pci, NULL); } -static struct pci_driver driver = { +static struct pci_driver hdspm_driver = { .name = KBUILD_MODNAME, .id_table = snd_hdspm_ids, .probe = snd_hdspm_probe, .remove = __devexit_p(snd_hdspm_remove), }; - -static int __init alsa_card_hdspm_init(void) -{ - return pci_register_driver(&driver); -} - -static void __exit alsa_card_hdspm_exit(void) -{ - pci_unregister_driver(&driver); -} - -module_init(alsa_card_hdspm_init) -module_exit(alsa_card_hdspm_exit) +module_pci_driver(hdspm_driver); diff --git a/sound/pci/rme9652/rme9652.c b/sound/pci/rme9652/rme9652.c index b737d1619cc7..a15fc100ab0c 100644 --- a/sound/pci/rme9652/rme9652.c +++ b/sound/pci/rme9652/rme9652.c @@ -2631,22 +2631,11 @@ static void __devexit snd_rme9652_remove(struct pci_dev *pci) pci_set_drvdata(pci, NULL); } -static struct pci_driver driver = { +static struct pci_driver rme9652_driver = { .name = KBUILD_MODNAME, .id_table = snd_rme9652_ids, .probe = snd_rme9652_probe, .remove = __devexit_p(snd_rme9652_remove), }; -static int __init alsa_card_hammerfall_init(void) -{ - return pci_register_driver(&driver); -} - -static void __exit alsa_card_hammerfall_exit(void) -{ - pci_unregister_driver(&driver); -} - -module_init(alsa_card_hammerfall_init) -module_exit(alsa_card_hammerfall_exit) +module_pci_driver(rme9652_driver); -- cgit v1.2.3