[svn-commits] tzafrir: linux/trunk r6967 - /linux/trunk/drivers/dahdi/xpp/xpp_dahdi.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Aug 11 23:49:51 CDT 2009


Author: tzafrir
Date: Tue Aug 11 23:49:47 2009
New Revision: 6967

URL: http://svn.asterisk.org/svn-view/dahdi?view=rev&rev=6967
Log:
xpp: Don't check for the 'owner' field too soon

The owner field should only tested after the low-level driver 
pre-registration method is called.

xpp rev: 7287

Modified:
    linux/trunk/drivers/dahdi/xpp/xpp_dahdi.c

Modified: linux/trunk/drivers/dahdi/xpp/xpp_dahdi.c
URL: http://svn.asterisk.org/svn-view/dahdi/linux/trunk/drivers/dahdi/xpp/xpp_dahdi.c?view=diff&rev=6967&r1=6966&r2=6967
==============================================================================
--- linux/trunk/drivers/dahdi/xpp/xpp_dahdi.c (original)
+++ linux/trunk/drivers/dahdi/xpp/xpp_dahdi.c Tue Aug 11 23:49:47 2009
@@ -1056,7 +1056,6 @@
 	const xops_t	*xops;
 
 	BUG_ON(!xpd);
-	WARN_ON(!xpd->span.owner);
 
 	xops = xpd->xops;
 	xbus = xpd->xbus;
@@ -1129,6 +1128,10 @@
 			xbus->num, xpd->addr.unit, xpd->addr.subunit, xpd->type_name);
 	XPD_DBG(GENERAL, xpd, "Registering span '%s'\n", xpd->span.desc);
 	xpd->xops->card_dahdi_preregistration(xpd, 1);
+	if(!xpd->span.owner) {
+		XPD_ERR(xpd, "NO span.owner field -- bug in low-level driver\n");
+		WARN_ON(!xpd->span.owner);
+	}
 	if(dahdi_register(&xpd->span, prefmaster)) {
 		XPD_ERR(xpd, "Failed to dahdi_register span\n");
 		return -ENODEV;




More information about the svn-commits mailing list