From a7297d28c5ae5d83802e707fc2149618d12ee72f Mon Sep 17 00:00:00 2001 From: kpfleming Date: Tue, 15 Nov 2005 14:28:44 +0000 Subject: port API call update from HEAD git-svn-id: http://svn.digium.com/svn/zaptel/branches/v1-0@817 5390a7c7-147a-4af0-8ec9-7488f05a26cb --- ChangeLog | 1 + tor2.c | 2 +- wcfxo.c | 2 +- wcfxs.c | 2 +- wct1xxp.c | 2 +- wcte11xp.c | 2 +- zaptel.h | 6 ++++++ 7 files changed, 12 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 387f1e8..4e87ac1 100755 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,5 @@ -- support DACS w/RBS on single-span cards + -- use newer API call on 2.6.10+ kernels zaptel 1.0.9.2 -- fix build issues for Linux 2.6.13 -- fixed tor2 to work on 64-bit architectures diff --git a/tor2.c b/tor2.c index 7ee9f81..642b496 100755 --- a/tor2.c +++ b/tor2.c @@ -628,7 +628,7 @@ static struct pci_driver tor2_driver = { static int __init tor2_init(void) { int res; - res = pci_module_init(&tor2_driver); + res = zap_pci_module(&tor2_driver); printk("Registered Tormenta2 PCI\n"); return res; } diff --git a/wcfxo.c b/wcfxo.c index 098b9f4..4ddfea2 100755 --- a/wcfxo.c +++ b/wcfxo.c @@ -1007,7 +1007,7 @@ static int __init wcfxo_init(void) printk("%d: %s\n", x, fxo_modes[x].name); return -ENODEV; } - res = pci_module_init(&wcfxo_driver); + res = zap_pci_module(&wcfxo_driver); if (res) return -ENODEV; return 0; diff --git a/wcfxs.c b/wcfxs.c index c59858f..5539402 100755 --- a/wcfxs.c +++ b/wcfxs.c @@ -2206,7 +2206,7 @@ static int __init wcfxs_init(void) return -ENODEV; } - res = pci_module_init(&wcfxs_driver); + res = zap_pci_module(&wcfxs_driver); if (res) return -ENODEV; return 0; diff --git a/wct1xxp.c b/wct1xxp.c index 1a46043..3c163dd 100755 --- a/wct1xxp.c +++ b/wct1xxp.c @@ -1390,7 +1390,7 @@ static struct pci_driver t1xxp_driver = { static int __init t1xxp_init(void) { int res; - res = pci_module_init(&t1xxp_driver); + res = zap_pci_module(&t1xxp_driver); if (res) return -ENODEV; return 0; diff --git a/wcte11xp.c b/wcte11xp.c index 6d22a12..9d33b56 100755 --- a/wcte11xp.c +++ b/wcte11xp.c @@ -1554,7 +1554,7 @@ static struct pci_driver t1xxp_driver = { static int __init t1xxp_init(void) { int res; - res = pci_module_init(&t1xxp_driver); + res = zap_pci_module(&t1xxp_driver); if (res) return -ENODEV; return 0; diff --git a/zaptel.h b/zaptel.h index 8146b63..07cbfdf 100755 --- a/zaptel.h +++ b/zaptel.h @@ -48,6 +48,12 @@ #define LINUX26 #endif +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,10) +#define zap_pci_module pci_register_driver +#else +#define zap_pci_module pci_module_init +#endif + #include "ecdis.h" #include "fasthdlc.h" #endif -- cgit v1.2.3