[svn-commits] rmeyerriecks: branch linux/rmeyerriecks/dahdi-linux-maintmodes r8049 - in /li...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Thu Feb 18 18:05:30 CST 2010


Author: rmeyerriecks
Date: Thu Feb 18 18:05:26 2010
New Revision: 8049

URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=8049
Log:
Cleaned up and standardized the looping instrumentation

Modified:
    linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wct4xxp/base.c
    linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wcte12xp/base.c

Modified: linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wct4xxp/base.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wct4xxp/base.c?view=diff&rev=8049&r1=8048&r2=8049
==============================================================================
--- linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wct4xxp/base.c (original)
+++ linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wct4xxp/base.c Thu Feb 18 18:05:26 2010
@@ -1393,7 +1393,7 @@
 	} else {
 		switch(cmd) {
 		case DAHDI_MAINT_NONE:
-			printk(KERN_NOTICE "XXX Turn off local and remote loops T1 XXX\n");
+			dev_info(&wc->dev->dev, "Turning off all looping\n");
 
 			reg = t4_framer_in(wc, span->offset, LIM0_T);
 			t4_framer_out(wc, span->offset, LIM0_T, (reg & ~LIM0_LL));
@@ -1410,27 +1410,30 @@
 			span->mainttimer = 0;
 			break;
 		case DAHDI_MAINT_LOCALLOOP:
-			printk(KERN_NOTICE "XXX Turn on Host Loopback and no remote loop XXX\n");
+			dev_info(&wc->dev->dev, "Turning on local loopback\n");
 			reg = t4_framer_in(wc, span->offset, LIM0_T);
 			t4_framer_out(wc, span->offset, LIM0_T, (reg | LIM0_LL));
 			break;
 		case DAHDI_MAINT_NETWORKLINELOOP:
-			printk(KERN_NOTICE "XXX Turn on Network Line Loopup XXX\n");
+			dev_info(&wc->dev->dev, "Turning on network line loopback\n");
 			reg = t4_framer_in(wc, span->offset, LIM1_T);
 			t4_framer_out(wc, span->offset, LIM1_T, (reg | LIM1_RL));
 			break;
 		case DAHDI_MAINT_NETWORKPAYLOADLOOP:
-			printk(KERN_NOTICE "XXX Turn on Network Payload Loopup XXX\n");
+			dev_info(&wc->dev->dev, "Turning on network payload loopback\n");
 			reg = t4_framer_in(wc, span->offset, FMR2_T);
 			t4_framer_out(wc, span->offset, FMR2_T, (reg | FMR2_PLB));
 			break;
 		case DAHDI_MAINT_LOOPUP:
+			dev_info(&wc->dev->dev, "Transmitting loopup code\n");
 			t4_framer_out(wc, span->offset, 0x21, 0x50);	/* FMR5: Nothing but RBS mode */
 			break;
 		case DAHDI_MAINT_LOOPDOWN:
+			dev_info(&wc->dev->dev, "Transmitting loopdown code\n");
 			t4_framer_out(wc, span->offset, 0x21, 0x60);	/* FMR5: Nothing but RBS mode */
 			break;
 		case DAHDI_MAINT_LOOPSTOP:
+			dev_info(&wc->dev->dev, "Transmitting loopstop code\n");
 			t4_framer_out(wc, span->offset, 0x21, 0x40);	/* FMR5: Nothing but RBS mode */
 			break;
 		case DAHDI_MAINT_FAS_DEFECT:
@@ -1452,6 +1455,8 @@
 			t4_framer_out(wc, span->offset, IERR_T, IBV);
 			break;
 		case DAHDI_MAINT_PRBS:
+			dev_info(&wc->dev->dev, "PRBS not supported\n");
+#if 0
 			printk(KERN_NOTICE "Enabling PRBS!\n");
 			span->mainttimer = 1;
 			// Enable PRBS monitor
@@ -1466,12 +1471,14 @@
 			reg &= ~LLBP;
 			reg &= ~FLLB;
 			t4_framer_out(wc, span->offset, LCR1_T, reg);
+#endif
 			break;
 		case DAHDI_RESET_COUNTERS:
 			t4_reset_counters(span);
 			break;
 		default:
-			printk(KERN_NOTICE "TE%dXXP: Unknown T1 maint command: %d\n", wc->numspans, cmd);
+			dev_info(&wc->dev->dev,"Unknown T1 maint command: %d\n",
+				       					cmd);
 			break;
 	   }
     }

Modified: linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wcte12xp/base.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wcte12xp/base.c?view=diff&rev=8049&r1=8048&r2=8049
==============================================================================
--- linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wcte12xp/base.c (original)
+++ linux/team/rmeyerriecks/dahdi-linux-maintmodes/drivers/dahdi/wcte12xp/base.c Thu Feb 18 18:05:26 2010
@@ -1098,7 +1098,7 @@
 	} else {
 		switch (cmd) {
 		case DAHDI_MAINT_NONE:
-			module_printk("XXX Turn off all looping T1 XXX\n");
+			module_printk("Turning off all looping\n");
 
 			// Turn off local loop
 			reg = t1_getreg(wc, LIM0);
@@ -1109,27 +1109,30 @@
 			t1_setreg(wc, LIM1, reg & ~(LIM1_RL | LIM1_JATT));
 			break;
 		case DAHDI_MAINT_LOCALLOOP:
-			module_printk("XXX Turn on local loop XXX\n");
+			module_printk("Turning on local loopback\n");
 			reg = t1_getreg(wc, LIM0);
 			t1_setreg(wc, LIM0, reg | LIM0_LL);
 			break;
 		case DAHDI_MAINT_NETWORKLINELOOP:
-			module_printk("XXX Turn on network line loop XXX\n");
+			module_printk("Turning on network line loopback\n");
 			reg = t1_getreg(wc, LIM1);
 			t1_setreg(wc, LIM1, reg | LIM1_RL);
 			break;
 		case DAHDI_MAINT_NETWORKPAYLOADLOOP:
-			module_printk("XXX Turn on network payload loop XXX\n");
+			module_printk("Turning on network payload loopback\n");
 			reg = t1_getreg(wc, LIM1);
 			t1_setreg(wc, LIM1, reg | (LIM1_RL | LIM1_JATT));
 			break;
 		case DAHDI_MAINT_LOOPUP:
+			module_printk("Transmitting loopup code\n");
 			t1_setreg(wc, 0x21, 0x50);	/* FMR5: Nothing but RBS mode */
 			break;
 		case DAHDI_MAINT_LOOPDOWN:
+			module_printk("Transmitting loopdown code\n");
 			t1_setreg(wc, 0x21, 0x60);	/* FMR5: Nothing but RBS mode */
 			break;
 		case DAHDI_MAINT_LOOPSTOP:
+			module_printk("Transmitting loopstop code\n");
 			t1_setreg(wc, 0x21, 0x40);	/* FMR5: Nothing but RBS mode */
 			break;
 		default:




More information about the svn-commits mailing list