From a4f601f1dacb43a41d03621e5e4f8a3e0c11ee07 Mon Sep 17 00:00:00 2001 From: Shaun Ruffell Date: Mon, 26 Jul 2010 00:30:36 +0000 Subject: wcte12xp, wctdm24xxp: Add shutdown handlers. Make the drivers a little more kexec friendly. git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@8979 a0bf4364-ded3-4de4-8d8a-66a801d63aff --- drivers/dahdi/wcte12xp/base.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'drivers/dahdi/wcte12xp') diff --git a/drivers/dahdi/wcte12xp/base.c b/drivers/dahdi/wcte12xp/base.c index ea39884..a09f6d8 100644 --- a/drivers/dahdi/wcte12xp/base.c +++ b/drivers/dahdi/wcte12xp/base.c @@ -2314,12 +2314,23 @@ static struct pci_device_id te12xp_pci_tbl[] = { { 0 } }; +#if LINUX_KERNEL_VERSION >= KERNEL_VERSION(2, 6, 12) +static void te12xp_shutdown(struct pci_dev *pdev) +{ + struct t1 *wc = pci_get_drvdata(pdev); + voicebus_stop(&wc->vb); +} +#endif + MODULE_DEVICE_TABLE(pci, te12xp_pci_tbl); static struct pci_driver te12xp_driver = { .name = "wcte12xp", .probe = te12xp_init_one, .remove = __devexit_p(te12xp_remove_one), +#if LINUX_KERNEL_VERSION >= KERNEL_VERSION(2, 6, 12) + .shutdown = te12xp_shutdown, +#endif .id_table = te12xp_pci_tbl, }; -- cgit v1.2.3