[svn-commits] rmeyerriecks: linux/trunk r10364 - /linux/trunk/drivers/dahdi/wct4xxp/base.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Fri Dec 2 16:48:43 CST 2011


Author: rmeyerriecks
Date: Fri Dec  2 16:48:39 2011
New Revision: 10364

URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=10364
Log:
wct4xxp: Handle incorrect vpm module/card pairings

Signed-off-by: Russ Meyerriecks <rmeyerriecks at digium.com>
Acked-by: Shaun Ruffell <sruffell at digium.com>

Modified:
    linux/trunk/drivers/dahdi/wct4xxp/base.c

Modified: linux/trunk/drivers/dahdi/wct4xxp/base.c
URL: http://svnview.digium.com/svn/dahdi/linux/trunk/drivers/dahdi/wct4xxp/base.c?view=diff&rev=10364&r1=10363&r2=10364
==============================================================================
--- linux/trunk/drivers/dahdi/wct4xxp/base.c (original)
+++ linux/trunk/drivers/dahdi/wct4xxp/base.c Fri Dec  2 16:48:39 2011
@@ -4185,7 +4185,15 @@
 			laws[x] = 1;
 	}
 
-	switch ((vpm_capacity = get_vpm450m_capacity(wc))) {
+	vpm_capacity = get_vpm450m_capacity(wc);
+	if (vpm_capacity != wc->numspans * 32) {
+		dev_info(&wc->dev->dev, "Disabling VPMOCT%03d. TE%dXXP"\
+				" requires a VPMOCT%03d", vpm_capacity,
+				wc->numspans, wc->numspans*32);
+		return;
+	}
+
+	switch (vpm_capacity) {
 	case 64:
 #if defined(HOTPLUG_FIRMWARE)
 		if ((request_firmware(&firmware, oct064_firmware, &wc->dev->dev) != 0) ||




More information about the svn-commits mailing list