summaryrefslogtreecommitdiff
path: root/drivers/dahdi/wcb4xxp/base.c
diff options
context:
space:
mode:
authorShaun Ruffell <sruffell@digium.com>2009-06-30 15:45:06 +0000
committerShaun Ruffell <sruffell@digium.com>2009-06-30 15:45:06 +0000
commit03827d00f9bb85bbb721db1c8f5293fc973f4a92 (patch)
treeff0b5aca8a0c37df01561d40b37f5d28c452620a /drivers/dahdi/wcb4xxp/base.c
parenta39a7eb229d831921d42201b2cb548b81bb91c63 (diff)
wcb4xxp: Start the first span with default settings on load.
One of the spans of the B410P is now started at driver load time in order to allow it to provide early timing to asterisk, before the card has been properly configured. git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@6799 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'drivers/dahdi/wcb4xxp/base.c')
-rw-r--r--drivers/dahdi/wcb4xxp/base.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/drivers/dahdi/wcb4xxp/base.c b/drivers/dahdi/wcb4xxp/base.c
index 71e8255..a26d439 100644
--- a/drivers/dahdi/wcb4xxp/base.c
+++ b/drivers/dahdi/wcb4xxp/base.c
@@ -2,7 +2,7 @@
* WCB410P Quad-BRI PCI Driver
* Written by Andrew Kohlsmith <akohlsmith@mixdown.ca>
*
- * Copyright (C) 2008 Digium, Inc.
+ * Copyright (C) 2009 Digium, Inc.
* All rights reserved.
*
*/
@@ -2481,6 +2481,11 @@ static int b4xxp_proc_read(char *buf, char **start, off_t offset, int count, int
}
#endif /* CREATE_WCB4XXP_PROCFS_ENTRY */
+static int b4xxp_startdefaultspan(struct b4xxp *b4)
+{
+ struct dahdi_lineconfig lc = {0,};
+ return b4xxp_spanconfig(&b4->spans[0].span, &lc);
+}
static int __devinit b4xx_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
{
@@ -2594,6 +2599,7 @@ static int __devinit b4xx_probe(struct pci_dev *pdev, const struct pci_device_id
}
+
#if 0
/* Launch cards as appropriate */
for (;;) {
@@ -2616,6 +2622,10 @@ static int __devinit b4xx_probe(struct pci_dev *pdev, const struct pci_device_id
dev_info(b4->dev, "Did not do the highestorder stuff\n");
#endif
+ ret = b4xxp_startdefaultspan(b4);
+ if (ret)
+ goto err_out_unreg_spans;
+
ret = 0;
return ret;