aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/pci/bt87x.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/sound/pci/bt87x.c b/sound/pci/bt87x.c
index cdd100dae855..9febe5509748 100644
--- a/sound/pci/bt87x.c
+++ b/sound/pci/bt87x.c
@@ -836,6 +836,8 @@ static struct {
836 {0x7063, 0x2000}, /* pcHDTV HD-2000 TV */ 836 {0x7063, 0x2000}, /* pcHDTV HD-2000 TV */
837}; 837};
838 838
839static struct pci_driver driver;
840
839/* return the id of the card, or a negative value if it's blacklisted */ 841/* return the id of the card, or a negative value if it's blacklisted */
840static int snd_bt87x_detect_card(struct pci_dev *pci) 842static int snd_bt87x_detect_card(struct pci_dev *pci)
841{ 843{
@@ -962,11 +964,24 @@ static DEFINE_PCI_DEVICE_TABLE(snd_bt87x_default_ids) = {
962 { } 964 { }
963}; 965};
964 966
965static struct pci_driver bt87x_driver = { 967static struct pci_driver driver = {
966 .name = KBUILD_MODNAME, 968 .name = KBUILD_MODNAME,
967 .id_table = snd_bt87x_ids, 969 .id_table = snd_bt87x_ids,
968 .probe = snd_bt87x_probe, 970 .probe = snd_bt87x_probe,
969 .remove = snd_bt87x_remove, 971 .remove = snd_bt87x_remove,
970}; 972};
971 973
972module_pci_driver(bt87x_driver); 974static int __init alsa_card_bt87x_init(void)
975{
976 if (load_all)
977 driver.id_table = snd_bt87x_default_ids;
978 return pci_register_driver(&driver);
979}
980
981static void __exit alsa_card_bt87x_exit(void)
982{
983 pci_unregister_driver(&driver);
984}
985
986module_init(alsa_card_bt87x_init)
987module_exit(alsa_card_bt87x_exit)