[dahdi-commits] russell: linux/trunk r4685 - in /linux/trunk/drivers/dahdi: ./ hpec/ wct4xxp/...

SVN commits to the DAHDI project dahdi-commits at lists.digium.com
Sun Aug 3 11:47:47 CDT 2008


Author: russell
Date: Sun Aug  3 11:47:46 2008
New Revision: 4685

URL: http://svn.digium.com/view/dahdi?view=rev&rev=4685
Log:
Change all instances of printk in DAHDI to include a priority

(closes issue #11504)
Reported by: tzafrir
Patches:
      20080717__issue11504_dahdi_printk_without_priority.diff uploaded by bbryant (license 36)

Modified:
    linux/trunk/drivers/dahdi/dahdi-base.c
    linux/trunk/drivers/dahdi/dahdi_dummy.c
    linux/trunk/drivers/dahdi/dahdi_dynamic.c
    linux/trunk/drivers/dahdi/dahdi_dynamic_eth.c
    linux/trunk/drivers/dahdi/dahdi_dynamic_loc.c
    linux/trunk/drivers/dahdi/dahdi_echocan_kb1.c
    linux/trunk/drivers/dahdi/dahdi_echocan_mg2.c
    linux/trunk/drivers/dahdi/dahdi_echocan_sec.c
    linux/trunk/drivers/dahdi/dahdi_echocan_sec2.c
    linux/trunk/drivers/dahdi/dahdi_transcode.c
    linux/trunk/drivers/dahdi/hpec/dahdi_echocan_hpec.c
    linux/trunk/drivers/dahdi/pciradio.c
    linux/trunk/drivers/dahdi/tor2.c
    linux/trunk/drivers/dahdi/voicebus.c
    linux/trunk/drivers/dahdi/wcfxo.c
    linux/trunk/drivers/dahdi/wct1xxp.c
    linux/trunk/drivers/dahdi/wct4xxp/base.c
    linux/trunk/drivers/dahdi/wct4xxp/vpm450m.c
    linux/trunk/drivers/dahdi/wctc4xxp/base.c
    linux/trunk/drivers/dahdi/wctdm.c
    linux/trunk/drivers/dahdi/wctdm24xxp/GpakApi.c
    linux/trunk/drivers/dahdi/wctdm24xxp/GpakCust.c
    linux/trunk/drivers/dahdi/wctdm24xxp/base.c
    linux/trunk/drivers/dahdi/wcte11xp.c
    linux/trunk/drivers/dahdi/wcte12xp/base.c
    linux/trunk/drivers/dahdi/wcte12xp/vpmadt032.c
    linux/trunk/drivers/dahdi/wcte12xp/wcte12xp.h
    linux/trunk/drivers/dahdi/xpp/card_fxs.c
    linux/trunk/drivers/dahdi/xpp/xpp_dahdi.c
    linux/trunk/drivers/dahdi/xpp/xproto.c

Modified: linux/trunk/drivers/dahdi/dahdi-base.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi-base.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi-base.c (original)
+++ linux/trunk/drivers/dahdi/dahdi-base.c Sun Aug  3 11:47:46 2008
@@ -1677,8 +1677,8 @@
 #ifdef CONFIG_DAHDI_DEBUG
 		module_printk(KERN_NOTICE, "Buffered %d bytes to go out in buffer %d\n", ss->writen[oldbuf], oldbuf);
 		for (x=0;x<ss->writen[oldbuf];x++)
-		     printk("%02x ", ss->writebuf[oldbuf][x]);
-		printk("\n");
+		     module_printk(KERN_DEBUG,"%02x ", ss->writebuf[oldbuf][x]);
+		module_printk(KERN_DEBUG "\n");
 #endif
 		retval = 0;
 		/* Free the SKB */
@@ -1778,8 +1778,8 @@
 #ifdef CONFIG_DAHDI_DEBUG
 		module_printk(KERN_NOTICE, "Buffered %d bytes (skblen = %d) to go out in buffer %d\n", ss->writen[oldbuf], skb->len, oldbuf);
 		for (x=0;x<ss->writen[oldbuf];x++)
-		     printk("%02x ", ss->writebuf[oldbuf][x]);
-		printk("\n");
+		     module_printk(KERN_DEBUG, "%02x ", ss->writebuf[oldbuf][x]);
+		module_printk(KERN_DEBUG, "\n");
 #endif
 		retval = 1;
 	}
@@ -1906,8 +1906,8 @@
 			myamnt = chan->readn[res];
 		module_printk(KERN_NOTICE, "dahdi_chan_read(unit: %d, inwritebuf: %d, outwritebuf: %d amnt: %d\n", 
 			      unit, chan->inwritebuf, chan->outwritebuf, myamnt);
-		printk("\t("); for (x = 0; x < myamnt; x++) printk((x ? " %02x" : "%02x"), (unsigned char)usrbuf[x]);
-		printk(")\n");
+		module_printk(KERN_DEBUG, "\t("); for (x = 0; x < myamnt; x++) module_printk((KERN_DEBUG, x ? " %02x" : "%02x"), (unsigned char)usrbuf[x]);
+		module_printk(KERN_DEBUG, ")\n");
 	}
 #endif
 /* end addition */
@@ -2019,8 +2019,8 @@
  		int x;
  		module_printk(KERN_NOTICE, "dahdi_chan_write/in(unit: %d, res: %d, outwritebuf: %d amnt: %d, txdisable: %d)\n",
 			      unit, res, chan->outwritebuf, amnt, chan->txdisable);
- 		printk("\t("); for (x = 0; x < amnt; x++) printk((x ? " %02x" : "%02x"), (unsigned char)usrbuf[x]);
- 		printk(")\n");
+ 		module_printk(KERN_DEBUG, "\t("); for (x = 0; x < amnt; x++) module_printk(KERN_DEBUG, (x ? " %02x" : "%02x"), (unsigned char)usrbuf[x]);
+ 		module_printk(KERN_DEBUG, ")\n");
  	}
 #endif
 

Modified: linux/trunk/drivers/dahdi/dahdi_dummy.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_dummy.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_dummy.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_dummy.c Sun Aug  3 11:47:46 2008
@@ -321,7 +321,7 @@
 	dahdi_unregister(&ztd->span);
 	kfree(ztd);
 	if (debug)
-		printk("ztdummy: cleanup() finished\n");
+		printk(KERN_DEBUG "ztdummy: cleanup() finished\n");
 }
 
 

Modified: linux/trunk/drivers/dahdi/dahdi_dynamic.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_dynamic.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_dynamic.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_dynamic.c Sun Aug  3 11:47:46 2008
@@ -157,9 +157,9 @@
 		master->master = 1;
 	spin_unlock_irqrestore(&dlock, flags);
 	if (master)
-		printk("TDMoX: New master: %s\n", master->span.name);
+		printk(KERN_INFO "TDMoX: New master: %s\n", master->span.name);
 	else
-		printk("TDMoX: No master.\n");
+		printk(KERN_INFO "TDMoX: No master.\n");
 }
 
 static void ztd_sendmessage(struct dahdi_dynamic *z)
@@ -291,7 +291,7 @@
 		spin_unlock_irqrestore(&dlock, flags);
 		newerr = ERR_LEN;
 		if (newerr != ztd->err) {
-			printk("Span %s: Insufficient samples for header (only %d)\n", span->name, msglen);
+			printk(KERN_NOTICE "Span %s: Insufficient samples for header (only %d)\n", span->name, msglen);
 		}
 		ztd->err = newerr;
 		return;
@@ -302,7 +302,7 @@
 		spin_unlock_irqrestore(&dlock, flags);
 		newerr = ERR_NSAMP | msg[0];
 		if (newerr != 	ztd->err) {
-			printk("Span %s: Expected %d samples, but receiving %d\n", span->name, DAHDI_CHUNKSIZE, msg[0]);
+			printk(KERN_NOTICE "Span %s: Expected %d samples, but receiving %d\n", span->name, DAHDI_CHUNKSIZE, msg[0]);
 		}
 		ztd->err = newerr;
 		return;
@@ -320,7 +320,7 @@
 		spin_unlock_irqrestore(&dlock, flags);
 		newerr = ERR_NCHAN | nchans;
 		if (newerr != ztd->err) {
-			printk("Span %s: Expected %d channels, but receiving %d\n", span->name, span->channels, nchans);
+			printk(KERN_NOTICE "Span %s: Expected %d channels, but receiving %d\n", span->name, span->channels, nchans);
 		}
 		ztd->err = newerr;
 		return;
@@ -345,7 +345,7 @@
 		spin_unlock_irqrestore(&dlock, flags);
 		newerr = ERR_LEN | xlen;
 		if (newerr != ztd->err) {
-			printk("Span %s: Expected message size %d, but was %d instead\n", span->name, xlen, msglen);
+			printk(KERN_NOTICE "Span %s: Expected message size %d, but was %d instead\n", span->name, xlen, msglen);
 		}
 		ztd->err = newerr;
 		return;
@@ -402,7 +402,7 @@
 
 	/* note if we had a missing packet */
 	if (rxpos != rxcnt)
-		printk("Span %s: Expected seq no %d, but received %d instead\n", span->name, rxcnt, rxpos);
+		printk(KERN_NOTICE "Span %s: Expected seq no %d, but received %d instead\n", span->name, rxcnt, rxpos);
 
 	/* If this is our master span, then run everything */
 	if (master)
@@ -472,7 +472,7 @@
 	/* Don't destroy span until it is in use */
 	if (z->usecount) {
 		spin_unlock_irqrestore(&dlock, flags);
-		printk("Attempt to destroy dynamic span while it is in use\n");
+		printk(KERN_NOTICE "Attempt to destroy dynamic span while it is in use\n");
 		return -EBUSY;
 	}
 	/* Unlink it */
@@ -512,7 +512,7 @@
 		z->usecount++;
 	}
 	if(!try_module_get(THIS_MODULE))
-		printk("TDMoX: Unable to increment module use count\n");
+		printk(KERN_NOTICE "TDMoX: Unable to increment module use count\n");
 	return 0;
 }
 
@@ -542,11 +542,11 @@
 	int bufsize;
 
 	if (zds->numchans < 1) {
-		printk("Can't be less than 1 channel (%d)!\n", zds->numchans);
+		printk(KERN_NOTICE "Can't be less than 1 channel (%d)!\n", zds->numchans);
 		return -EINVAL;
 	}
 	if (zds->numchans >= DAHDI_DYNAMIC_MAX_CHANS) {
-		printk("Can't create dynamic span with greater than %d channels.  See ztdynamic.c and increase DAHDI_DYNAMIC_MAX_CHANS\n", zds->numchans);
+		printk(KERN_NOTICE "Can't create dynamic span with greater than %d channels.  See ztdynamic.c and increase DAHDI_DYNAMIC_MAX_CHANS\n", zds->numchans);
 		return -EINVAL;
 	}
 
@@ -636,7 +636,7 @@
 	/* Another race -- should let the module get unloaded while we
 	   have it here */
 	if (!ztd) {
-		printk("No such driver '%s' for dynamic span\n", zds->driver);
+		printk(KERN_NOTICE "No such driver '%s' for dynamic span\n", zds->driver);
 		dynamic_destroy(z);
 		return -EINVAL;
 	}
@@ -644,7 +644,7 @@
 	/* Create the stuff */
 	z->pvt = ztd->create(&z->span, z->addr);
 	if (!z->pvt) {
-		printk("Driver '%s' (%s) rejected address '%s'\n", ztd->name, ztd->desc, z->addr);
+		printk(KERN_NOTICE "Driver '%s' (%s) rejected address '%s'\n", ztd->name, ztd->desc, z->addr);
 		/* Creation failed */
 		return -EINVAL;
 	}
@@ -654,7 +654,7 @@
 
 	/* Whee!  We're created.  Now register the span */
 	if (dahdi_register(&z->span, 0)) {
-		printk("Unable to register span '%s'\n", z->span.name);
+		printk(KERN_NOTICE "Unable to register span '%s'\n", z->span.name);
 		dynamic_destroy(z);
 		return -EINVAL;
 	}
@@ -700,7 +700,7 @@
 		if (copy_from_user(&zds, (struct dahdi_dynamic_span *)data, sizeof(zds)))
 			return -EFAULT;
 		if (debug)
-			printk("Dynamic Create\n");
+			printk(KERN_DEBUG "Dynamic Create\n");
 		res = create_dynamic(&zds);
 		if (res < 0)
 			return res;
@@ -713,7 +713,7 @@
 		if (copy_from_user(&zds, (struct dahdi_dynamic_span *)data, sizeof(zds)))
 			return -EFAULT;
 		if (debug)
-			printk("Dynamic Destroy\n");
+			printk(KERN_DEBUG "Dynamic Destroy\n");
 		return destroy_dynamic(&zds);
 	}
 
@@ -822,7 +822,7 @@
 #ifdef ENABLE_TASKLETS
 	tasklet_init(&ztd_tlet, ztd_tasklet, 0);
 #endif
-	printk("DAHDI Dynamic Span support LOADED\n");
+	printk(KERN_INFO "DAHDI Dynamic Span support LOADED\n");
 	return 0;
 }
 
@@ -836,7 +836,7 @@
 #endif
 	dahdi_set_dynamic_ioctl(NULL);
 	del_timer(&alarmcheck);
-	printk("DAHDI Dynamic Span support unloaded\n");
+	printk(KERN_INFO "DAHDI Dynamic Span support unloaded\n");
 }
 
 module_param(debug, int, 0600);

Modified: linux/trunk/drivers/dahdi/dahdi_dynamic_eth.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_dynamic_eth.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_dynamic_eth.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_dynamic_eth.c Sun Aug  3 11:47:46 2008
@@ -290,7 +290,7 @@
 	}
 	spin_unlock_irqrestore(&zlock, flags);
 	if (cur == z) {	/* Successfully removed */
-		printk("TDMoE: Removed interface for %s\n", z->span->name);
+		printk(KERN_INFO "TDMoE: Removed interface for %s\n", z->span->name);
 		kfree(z);
 		module_put(THIS_MODULE);
 	}
@@ -317,7 +317,7 @@
 			tmp2++;
 			dahdi_copy_string(z->ethdev, tmp, sizeof(z->ethdev));
 		} else {
-			printk("Invalid TDMoE address (no device) '%s'\n", addr);
+			printk(KERN_NOTICE "Invalid TDMoE address (no device) '%s'\n", addr);
 			kfree(z);
 			return NULL;
 		}
@@ -345,12 +345,12 @@
 					tmp3 = strchr(tmp2, ':');
 			}
 			if (x != 6) {
-				printk("TDMoE: Invalid MAC address in: %s\n", addr);
+				printk(KERN_NOTICE "TDMoE: Invalid MAC address in: %s\n", addr);
 				kfree(z);
 				return NULL;
 			}
 		} else {
-			printk("TDMoE: Missing MAC address\n");
+			printk(KERN_NOTICE "TDMoE: Missing MAC address\n");
 			kfree(z);
 			return NULL;
 		}
@@ -364,7 +364,7 @@
 				if (*tmp3 >= '0' && *tmp3 <= '9') {
 					sub += (*tmp3 - '0') * mul;
 				} else {
-					printk("TDMoE: Invalid subaddress\n");
+					printk(KERN_NOTICE "TDMoE: Invalid subaddress\n");
 					kfree(z);
 					return NULL;
 				}
@@ -379,7 +379,7 @@
 #endif
 				z->ethdev);
 		if (!z->dev) {
-			printk("TDMoE: Invalid device '%s'\n", z->ethdev);
+			printk(KERN_NOTICE "TDMoE: Invalid device '%s'\n", z->ethdev);
 			kfree(z);
 			return NULL;
 		}
@@ -388,14 +388,14 @@
 		for (x=0;x<5;x++)
 			sprintf(src + strlen(src), "%02x:", z->dev->dev_addr[x]);
 		sprintf(src + strlen(src), "%02x", z->dev->dev_addr[5]);
-		printk("TDMoE: Added new interface for %s at %s (addr=%s, src=%s, subaddr=%d)\n", span->name, z->dev->name, addr, src, ntohs(z->subaddr));
+		printk(KERN_INFO "TDMoE: Added new interface for %s at %s (addr=%s, src=%s, subaddr=%d)\n", span->name, z->dev->name, addr, src, ntohs(z->subaddr));
 
 		spin_lock_irqsave(&zlock, flags);
 		z->next = zdevs;
 		zdevs = z;
 		spin_unlock_irqrestore(&zlock, flags);
 		if(!try_module_get(THIS_MODULE))
-			printk("TDMoE: Unable to increment module use count\n");
+			printk(KERN_DEBUG "TDMoE: Unable to increment module use count\n");
 	}
 	return z;
 }

Modified: linux/trunk/drivers/dahdi/dahdi_dynamic_loc.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_dynamic_loc.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_dynamic_loc.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_dynamic_loc.c Sun Aug  3 11:47:46 2008
@@ -152,7 +152,7 @@
 	}
 	spin_unlock_irqrestore(&zlock, flags);
 	if (cur == z) {
-		printk("TDMoL: Removed interface for %s, key %d id %d\n", z->span->name, z->key, z->id);
+		printk(KERN_INFO "TDMoL: Removed interface for %s, key %d id %d\n", z->span->name, z->key, z->id);
 		module_put(THIS_MODULE);
 		kfree(z);
 	}
@@ -194,12 +194,12 @@
 		for (l = zdevs; l; l = l->next)
 			if (l->key == z->key) {
 				if (l->id == z->id) {
-					printk ("TDMoL: Duplicate id (%d) for key %d\n", z->id, z->key);
+					printk(KERN_DEBUG "TDMoL: Duplicate id (%d) for key %d\n", z->id, z->key);
 					goto CLEAR_AND_DEL_FROM_PEERS;
 				}
 				if (monitor == -1) {
 					if (l->peer) {
-						printk ("TDMoL: Span with key %d and id %d already has a R/W peer\n", z->key, z->id);
+						printk(KERN_DEBUG "TDMoL: Span with key %d and id %d already has a R/W peer\n", z->key, z->id);
 						goto CLEAR_AND_DEL_FROM_PEERS;
 					} else {
 						l->peer = z;
@@ -208,7 +208,7 @@
 				}
 				if (monitor == l->id) {
 					if (l->monitor_rx_peer) {
-						printk ("TDMoL: Span with key %d and id %d already has a monitoring peer\n", z->key, z->id);
+						printk(KERN_DEBUG "TDMoL: Span with key %d and id %d already has a monitoring peer\n", z->key, z->id);
 						goto CLEAR_AND_DEL_FROM_PEERS;
 					} else {
 						l->monitor_rx_peer = z;
@@ -219,9 +219,9 @@
 		zdevs = z;
 		spin_unlock_irqrestore(&zlock, flags);
 		if(!try_module_get(THIS_MODULE))
-			printk("TDMoL: Unable to increment module use count\n");
-
-		printk("TDMoL: Added new interface for %s, key %d id %d\n", span->name, z->key, z->id);
+			printk(KERN_DEBUG "TDMoL: Unable to increment module use count\n");
+
+		printk(KERN_INFO "TDMoL: Added new interface for %s, key %d id %d\n", span->name, z->key, z->id);
 	}
 	return z;
 
@@ -236,7 +236,7 @@
 	return NULL;
 	
 INVALID_ADDRESS:
-	printk ("TDMoL: Invalid address %s\n", address);
+	printk (KERN_NOTICE "TDMoL: Invalid address %s\n", address);
 	return NULL;
 }
 

Modified: linux/trunk/drivers/dahdi/dahdi_echocan_kb1.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_echocan_kb1.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_echocan_kb1.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_echocan_kb1.c Sun Aug  3 11:47:46 2008
@@ -37,7 +37,7 @@
 static int aggressive;
 
 #define module_printk(level, fmt, args...) printk(level "%s: " fmt, THIS_MODULE->name, ## args)
-#define debug_printk(level, fmt, args...) if (debug >= level) printk("%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
+#define debug_printk(level, fmt, args...) if (debug >= level) printk(KERN_DEBUG "%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
 
 /* Uncomment to provide summary statistics for overall echo can performance every 4000 samples */ 
 /* #define MEC2_STATS 4000 */

Modified: linux/trunk/drivers/dahdi/dahdi_echocan_mg2.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_echocan_mg2.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_echocan_mg2.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_echocan_mg2.c Sun Aug  3 11:47:46 2008
@@ -344,7 +344,7 @@
 static void echo_can_free(struct echo_can_state *ec)
 {
 #if defined(DC_NORMALIZE) && defined(MEC2_DCBIAS_MESSAGE)
-	printk("EC: DC bias calculated: %d V\n", ec->dc_estimate >> 15);
+	printk(KERN_INFO "EC: DC bias calculated: %d V\n", ec->dc_estimate >> 15);
 #endif
 	kfree(ec);
 }

Modified: linux/trunk/drivers/dahdi/dahdi_echocan_sec.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_echocan_sec.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_echocan_sec.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_echocan_sec.c Sun Aug  3 11:47:46 2008
@@ -50,7 +50,7 @@
 static int debug;
 
 #define module_printk(level, fmt, args...) printk(level "%s: " fmt, THIS_MODULE->name, ## args)
-#define debug_printk(level, fmt, args...) if (debug >= level) printk("%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
+#define debug_printk(level, fmt, args...) if (debug >= level) printk(KERN_DEBUG "%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
 
 #include "arith.h"
 

Modified: linux/trunk/drivers/dahdi/dahdi_echocan_sec2.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_echocan_sec2.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_echocan_sec2.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_echocan_sec2.c Sun Aug  3 11:47:46 2008
@@ -49,7 +49,7 @@
 static int debug;
 
 #define module_printk(level, fmt, args...) printk(level "%s: " fmt, THIS_MODULE->name, ## args)
-#define debug_printk(level, fmt, args...) if (debug >= level) printk("%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
+#define debug_printk(level, fmt, args...) if (debug >= level) printk(KERN_DEBUG "%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
 
 #include "fir.h"
 

Modified: linux/trunk/drivers/dahdi/dahdi_transcode.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi_transcode.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi_transcode.c (original)
+++ linux/trunk/drivers/dahdi/dahdi_transcode.c Sun Aug  3 11:47:46 2008
@@ -113,7 +113,7 @@
 
 	tc->next = trans;
 	trans = tc;
-	printk("Registered codec translator '%s' with %d transcoders (srcs=%08x, dsts=%08x)\n", 
+	printk(KERN_INFO "Registered codec translator '%s' with %d transcoders (srcs=%08x, dsts=%08x)\n", 
 	       tc->name, tc->numchannels, tc->srcfmts, tc->dstfmts);
 	res = 0;
 	spin_unlock(&translock);
@@ -143,7 +143,7 @@
 	else
 		trans = tc->next;
 	tc->next = NULL;
-	printk("Unregistered codec translator '%s' with %d transcoders (srcs=%08x, dsts=%08x)\n", 
+	printk(KERN_INFO "Unregistered codec translator '%s' with %d transcoders (srcs=%08x, dsts=%08x)\n", 
 	       tc->name, tc->numchannels, tc->srcfmts, tc->dstfmts);
 	res = 0;
 	spin_unlock(&translock);
@@ -155,7 +155,7 @@
 int dahdi_transcoder_alert(struct dahdi_transcoder_channel *ztc)
 {
 	if (debug)
-		printk("DAHDI Transcoder Alert!\n");
+		printk(KERN_DEBUG "DAHDI Transcoder Alert!\n");
 	if (ztc->tch)
 		ztc->tch->status &= ~DAHDI_TC_FLAG_BUSY;
 	wake_up_interruptible(&ztc->ready);
@@ -182,7 +182,7 @@
 	ztc->flags = DAHDI_TC_FLAG_TRANSIENT | DAHDI_TC_FLAG_BUSY;
 	ztc->tch = zth;
 	if (debug)
-		printk("Allocated Transcoder Channel, header is at %p!\n", zth);
+		printk(KERN_DEBUG "Allocated Transcoder Channel, header is at %p!\n", zth);
 	zth->magic = DAHDI_TRANSCODE_MAGIC;
 	file->private_data = ztc;
 	for (page = virt_to_page(zth);
@@ -216,7 +216,7 @@
 	if (ztc->flags & DAHDI_TC_FLAG_TRANSIENT)
 		kfree(ztc);
 	if (debug)
-		printk("Released Transcoder!\n");
+		printk(KERN_DEBUG "Released Transcoder!\n");
 }
 
 static int dahdi_tc_release(struct inode *inode, struct file *file)
@@ -327,7 +327,7 @@
 		return -EFAULT;
 
 	if (debug)
-		printk("DAHDI Transcode ioctl op = %d!\n", op);
+		printk(KERN_DEBUG "DAHDI Transcode ioctl op = %d!\n", op);
 
 	switch(op) {
 	case DAHDI_TCOP_GETINFO:
@@ -377,13 +377,13 @@
 	/* Do not allow an offset */
 	if (vma->vm_pgoff) {
 		if (debug)
-			printk("zttranscode: Attempted to mmap with offset!\n");
+			printk(KERN_DEBUG "zttranscode: Attempted to mmap with offset!\n");
 		return -EINVAL;
 	}
 
 	if ((vma->vm_end - vma->vm_start) != sizeof(struct dahdi_transcode_header)) {
 		if (debug)
-			printk("zttranscode: Attempted to mmap with size %d != %zd!\n", (int) (vma->vm_end - vma->vm_start), sizeof(struct dahdi_transcode_header));
+			printk(KERN_DEBUG "zttranscode: Attempted to mmap with size %d != %zd!\n", (int) (vma->vm_end - vma->vm_start), sizeof(struct dahdi_transcode_header));
 		return -EINVAL;
 	}
 
@@ -399,12 +399,12 @@
 #endif
 	if (res) {
 		if (debug)
-			printk("zttranscode: remap failed!\n");
+			printk(KERN_DEBUG "zttranscode: remap failed!\n");
 		return -EAGAIN;
 	}
 
 	if (debug)
-		printk("zttranscode: successfully mapped transcoder!\n");
+		printk(KERN_DEBUG "zttranscode: successfully mapped transcoder!\n");
 
 	return 0;
 }
@@ -445,7 +445,7 @@
 	int res;
 
 	if (dahdi_transcode_fops) {
-		printk("Whoa, dahdi_transcode_fops already set?!\n");
+		printk(KERN_NOTICE "Whoa, dahdi_transcode_fops already set?!\n");
 		return -EBUSY;
 	}
 
@@ -454,7 +454,7 @@
 	if ((res = dahdi_register_chardev(&transcode_chardev)))
 		return res;
 
-	printk("DAHDI Transcoder support loaded\n");
+	printk(KERN_INFO "DAHDI Transcoder support loaded\n");
 
 	return 0;
 }
@@ -465,7 +465,7 @@
 
 	dahdi_transcode_fops = NULL;
 
-	printk("DAHDI Transcoder support unloaded\n");
+	printk(KERN_INFO "DAHDI Transcoder support unloaded\n");
 }
 
 module_param(debug, int, S_IRUGO | S_IWUSR);

Modified: linux/trunk/drivers/dahdi/hpec/dahdi_echocan_hpec.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/hpec/dahdi_echocan_hpec.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/hpec/dahdi_echocan_hpec.c (original)
+++ linux/trunk/drivers/dahdi/hpec/dahdi_echocan_hpec.c Sun Aug  3 11:47:46 2008
@@ -31,7 +31,7 @@
 static int debug;
 
 #define module_printk(level, fmt, args...) printk(level "%s: " fmt, THIS_MODULE->name, ## args)
-#define debug_printk(level, fmt, args...) if (debug >= level) printk("%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
+#define debug_printk(level, fmt, args...) if (debug >= level) printk(KERN_DEBUG "%s (%s): " fmt, THIS_MODULE->name, __FUNCTION__, ## args)
 
 #include "hpec_user.h"
 #include "hpec.h"
@@ -51,7 +51,7 @@
 	va_start(args, format);
 	res = vsnprintf(buf, sizeof(buf), format, args);
 	va_end(args);
-	printk(buf);
+	printk(KERN_INFO "%s" buf);
 #endif
 
 	return res;

Modified: linux/trunk/drivers/dahdi/pciradio.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/pciradio.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/pciradio.c (original)
+++ linux/trunk/drivers/dahdi/pciradio.c Sun Aug  3 11:47:46 2008
@@ -745,13 +745,13 @@
 
 	if (ints & 0x10) {
 		/* Stop DMA, wait for watchdog */
-		printk("RADIO PCI Master abort\n");
+		printk(KERN_INFO "RADIO PCI Master abort\n");
 		pciradio_stop_dma(rad);
 		return IRQ_RETVAL(1);
 	}
 	
 	if (ints & 0x20) {
-		printk("RADIO PCI Target abort\n");
+		printk(KERN_INFO "RADIO PCI Target abort\n");
 		return IRQ_RETVAL(1);
 	}
 
@@ -906,14 +906,14 @@
 						    if (debug)
 							{
 								if (rad->present_code[x])
-								    printk("Chan %d got rx (ctcss code %d)\n",x + 1,
+								    printk(KERN_DEBUG "Chan %d got rx (ctcss code %d)\n",x + 1,
 									cttable_rx[rad->rxcode[x][rad->present_code[x]]].code);
 								else
-								    printk("Chan %d got rx\n",x + 1);
+								    printk(KERN_DEBUG "Chan %d got rx\n",x + 1);
 							}
 						    dahdi_hooksig(&rad->chans[x],DAHDI_RXSIG_OFFHOOK);
 						} else {
-						    if (debug) printk("Chan %d lost rx\n",x + 1);
+						    if (debug) printk(KERN_DEBUG "Chan %d lost rx\n",x + 1);
 						    dahdi_hooksig(&rad->chans[x],DAHDI_RXSIG_ONHOOK);
 						}
 						rad->encdec.req[x] = 1; 
@@ -1426,7 +1426,7 @@
 
 static int pciradio_watchdog(struct dahdi_span *span, int event)
 {
-	printk("PCI RADIO: Restarting DMA\n");
+	printk(KERN_INFO "PCI RADIO: Restarting DMA\n");
 	pciradio_restart_dma(span->pvt);
 	return 0;
 }
@@ -1454,11 +1454,11 @@
 		rad->gottx[chan->chanpos - 1] = 0;
 		break;
 	default:
-		printk("pciradio: Can't set tx state to %d\n", txsig);
+		printk(KERN_DEBUG "pciradio: Can't set tx state to %d\n", txsig);
 		break;
 	}
 	if (debug) 
-		printk("pciradio: Setting Radio hook state to %d on chan %d\n", txsig, chan->chanpos);
+		printk(KERN_DEBUG "pciradio: Setting Radio hook state to %d on chan %d\n", txsig, chan->chanpos);
 	return 0;
 }
 
@@ -1491,7 +1491,7 @@
 
 	rad->span.pvt = rad;
 	if (dahdi_register(&rad->span, 0)) {
-		printk("Unable to register span with DAHDI\n");
+		printk(KERN_NOTICE "Unable to register span with DAHDI\n");
 		return -1;
 	}
 	return 0;
@@ -1539,10 +1539,10 @@
 	endjif = jiffies + 10;
 	while (inb(rad->ioaddr + RAD_AUXR) & (XINIT | XDONE) && (jiffies <= endjif));
 	if (endjif < jiffies) {
-		printk("Timeout waiting for INIT and DONE to go low\n");
+		printk(KERN_DEBUG "Timeout waiting for INIT and DONE to go low\n");
 		return -1;
 	}
-	if (debug) printk("fwload: Init and done gone to low\n");
+	if (debug) printk(KERN_DEBUG "fwload: Init and done gone to low\n");
 	/* De-assert PGM */
 	rad->ios |= XPGM;
 	outb(rad->ios, rad->ioaddr + RAD_AUXD);
@@ -1550,10 +1550,10 @@
 	endjif = jiffies + 10;
 	while (!(inb(rad->ioaddr + RAD_AUXR) & XINIT) && (jiffies <= endjif));
 	if (endjif < jiffies) {
-		printk("Timeout waiting for INIT to go high\n");
+		printk(KERN_DEBUG "Timeout waiting for INIT to go high\n");
 		return -1;
 	}
-	if (debug) printk("fwload: Init went high (clearing done)\nNow loading...\n");
+	if (debug) printk(KERN_DEBUG "fwload: Init went high (clearing done)\nNow loading...\n");
 	/* Assert CS+Write */
 	rad->ios &= ~XCS;
 	outb(rad->ios, rad->ioaddr + RAD_AUXD);
@@ -1566,33 +1566,33 @@
 		  /* if INIT drops, we're screwed, exit */
 		if (!(inb(rad->ioaddr + RAD_AUXR) & XINIT)) break;
 	   }
-	if (debug) printk("fwload: Transferred %d bytes into chip\n",x);
+	if (debug) printk(KERN_DEBUG "fwload: Transferred %d bytes into chip\n",x);
 	/* Wait for FIFO to clear */
 	endjif = jiffies + 2;
 	while (jiffies < endjif); /* wait */
-	printk("Transfered %d bytes into chip\n",x);
+	printk(KERN_DEBUG "Transfered %d bytes into chip\n",x);
 	/* De-assert CS+Write */
 	rad->ios |= XCS;
 	outb(rad->ios, rad->ioaddr + RAD_AUXD);
-	if (debug) printk("fwload: Loading done!\n");	
+	if (debug) printk(KERN_INFO "fwload: Loading done!\n");	
 	/* Wait for FIFO to clear */
 	endjif = jiffies + 2;
 	while (jiffies < endjif); /* wait */
 	if (!(inb(rad->ioaddr + RAD_AUXR) & XINIT))
 	   {
-		printk("Drove Init low!! CRC Error!!!\n");
+		printk(KERN_NOTICE "Drove Init low!! CRC Error!!!\n");
 		return -1;
 	   }
 	if (!(inb(rad->ioaddr + RAD_AUXR) & XDONE))
 	   {
-		printk("Did not get DONE signal. Short file maybe??\n");
+		printk(KERN_INFO "Did not get DONE signal. Short file maybe??\n");
 		return -1;
 	   }
 	wait_just_a_bit(2);
 	/* get the thingy started */
 	outb(0,rad->ioaddr + RAD_REGBASE);
 	outb(0,rad->ioaddr + RAD_REGBASE);
-	printk("Xilinx Chip successfully loaded, configured and started!!\n");
+	printk(KERN_INFO "Xilinx Chip successfully loaded, configured and started!!\n");
 
 	wait_just_a_bit(HZ/4);
 
@@ -1706,7 +1706,7 @@
 	for (x=0;x<RAD_MAX_IFACES;x++)
 		if (!ifaces[x]) break;
 	if (x >= RAD_MAX_IFACES) {
-		printk("Too many interfaces\n");
+		printk(KERN_NOTICE "Too many interfaces\n");
 		return -EIO;
 	}
 	
@@ -1734,7 +1734,7 @@
 			   32 bits.  Allocate an extra set just for control too */
 			rad->writechunk = pci_alloc_consistent(pdev, DAHDI_MAX_CHUNKSIZE * 2 * 2 * 2 * 4, &rad->writedma);
 			if (!rad->writechunk) {
-				printk("pciradio: Unable to allocate DMA-able memory\n");
+				printk(KERN_NOTICE "pciradio: Unable to allocate DMA-able memory\n");
 				if (rad->freeregion)
 					release_region(rad->ioaddr, 0xff);
 				return -ENOMEM;
@@ -1744,7 +1744,7 @@
 			rad->readdma = rad->writedma + DAHDI_MAX_CHUNKSIZE * 8;		/* in bytes */
 
 			if (pciradio_initialize(rad)) {
-				printk("pciradio: Unable to intialize\n");
+				printk(KERN_INFO "pciradio: Unable to intialize\n");
 				/* Set Reset Low */
 				x=inb(rad->ioaddr + RAD_CNTL);
 				outb((~0x1)&x, rad->ioaddr + RAD_CNTL);
@@ -1788,7 +1788,7 @@
 			}
 
 			if (request_irq(pdev->irq, pciradio_interrupt, DAHDI_IRQ_SHARED, "pciradio", rad)) {
-				printk("pciradio: Unable to request IRQ %d\n", pdev->irq);
+				printk(KERN_NOTICE "pciradio: Unable to request IRQ %d\n", pdev->irq);
 				if (rad->freeregion)
 					release_region(rad->ioaddr, 0xff);
 				pci_free_consistent(pdev, DAHDI_MAX_CHUNKSIZE * 2 * 2 * 2 * 4, (void *)rad->writechunk, rad->writedma);
@@ -1804,7 +1804,7 @@
 
 			/* Start DMA */
 			pciradio_start_dma(rad);
-			printk("Found a PCI Radio Card\n");
+			printk(KERN_INFO "Found a PCI Radio Card\n");
 			res = 0;
 		} else
 			res = -ENOMEM;
@@ -1818,7 +1818,7 @@
 	if (rad->freeregion)
 		release_region(rad->ioaddr, 0xff);
 	kfree(rad);
-	printk("Freed a PCI RADIO card\n");
+	printk(KERN_INFO "Freed a PCI RADIO card\n");
 }
 
 static void __devexit pciradio_remove_one(struct pci_dev *pdev)

Modified: linux/trunk/drivers/dahdi/tor2.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/tor2.c?view=diff&rev=4685&r1=4684&r2=4685
==============================================================================
--- linux/trunk/drivers/dahdi/tor2.c (original)
+++ linux/trunk/drivers/dahdi/tor2.c Sun Aug  3 11:47:46 2008
@@ -200,7 +200,7 @@
 	struct tor2_span *p = span->pvt;
 
 	if (debug)
-		printk("Tor2: Configuring span %d\n", span->spanno);
+		printk(KERN_INFO "Tor2: Configuring span %d\n", span->spanno);
 
 	span->syncsrc = p->tor->syncsrc;
 	
@@ -233,9 +233,9 @@
 	alreadyrunning = chan->span->flags & DAHDI_FLAG_RUNNING;
 	if (debug) {
 		if (alreadyrunning)
-			printk("Tor2: Reconfigured channel %d (%s) sigtype %d\n", chan->channo, chan->name, sigtype);
+			printk(KERN_INFO "Tor2: Reconfigured channel %d (%s) sigtype %d\n", chan->channo, chan->name, sigtype);
 		else
-			printk("Tor2: Configured channel %d (%s) sigtype %d\n", chan->channo, chan->name, sigtype);
+			printk(KERN_INFO "Tor2: Configured channel %d (%s) sigtype %d\n", chan->channo, chan->name, sigtype);
 	}		
 	/* nothing more to do if an E1 */
 	if (p->tor->cardtype == TYPE_E1) return 0;
@@ -312,7 +312,7 @@
 {
 	if (tor->spans[0].flags & DAHDI_FLAG_REGISTERED)
 		return 0;
-	printk("Tor2: Launching card: %d\n", tor->order);
+	printk(KERN_INFO "Tor2: Launching card: %d\n", tor->order);
 	if (dahdi_register(&tor->spans[0], 0)) {
 		printk(KERN_ERR "Unable to register span %s\n", tor->spans[0].name);
 		return -1;
@@ -424,14 +424,14 @@
 		goto err_out_release_plx_region;
 	}
 	pci_set_drvdata(pdev, tor);
-	printk("Detected %s at 0x%lx/0x%lx irq %d\n", tor->type, 
+	printk(KERN_INFO "Detected %s at 0x%lx/0x%lx irq %d\n", tor->type, 
 		tor->xilinx32_region, tor->xilinx8_region,tor->irq);
 
 	for (x = 0; x < MAX_TOR_CARDS; x++) {
 		if (!cards[x]) break;
 	}
 	if (x >= MAX_TOR_CARDS) {
-		printk("No cards[] slot available!!\n");
+		printk(KERN_DEBUG "No cards[] slot available!!\n");
 		goto err_out_release_all;
 	}
 	tor->num = x;
@@ -452,21 +452,21 @@
 	while (le32_to_cpu(*gpdata_io) & (GPIO_INIT | GPIO_DONE) && (jiffies <= endjif));
 
 	if (endjif < jiffies) {
-		printk("Timeout waiting for INIT and DONE to go low\n");
+		printk(KERN_DEBUG "Timeout waiting for INIT and DONE to go low\n");
 		goto err_out_release_all;
 	}
-	if (debug) printk("fwload: Init and done gone to low\n");
+	if (debug) printk(KERN_DEBUG "fwload: Init and done gone to low\n");
 	gpdata |= GPIO_PROGRAM;
 	*gpdata_io = cpu_to_le32(gpdata);  /* de-activate the PROGRAM signal */
 	/* wait for INIT to go high (clearing done */
 	endjif = jiffies + 10;
 	while (!(le32_to_cpu(*gpdata_io) & GPIO_INIT) && (jiffies <= endjif));
 	if (endjif < jiffies) {
-		printk("Timeout waiting for INIT to go high\n");
+		printk(KERN_DEBUG "Timeout waiting for INIT to go high\n");
 		goto err_out_release_all;
 	}
 
-	if (debug) printk("fwload: Init went high (clearing done)\nNow loading...\n");
+	if (debug) printk(KERN_DEBUG "fwload: Init went high (clearing done)\nNow loading...\n");
 	/* assert WRITE signal */
 	gpdata &= ~GPIO_WRITE;
 	*gpdata_io = cpu_to_le32(gpdata);
@@ -479,29 +479,29 @@
 		  /* if INIT drops, we're screwed, exit */
 		if (!(le32_to_cpu(*gpdata_io) & GPIO_INIT)) break;
 	   }
-	if (debug) printk("fwload: Transferred %d bytes into chip\n",x);
+	if (debug) printk(KERN_DEBUG "fwload: Transferred %d bytes into chip\n",x);
 	/* Wait for FIFO to clear */
 	endjif = jiffies + 2;
 	while (jiffies < endjif); /* wait */
 	  /* de-assert write signal */
 	gpdata |= GPIO_WRITE;
 	*gpdata_io = cpu_to_le32(gpdata);
-	if (debug) printk("fwload: Loading done!\n");	
+	if (debug) printk(KERN_DEBUG "fwload: Loading done!\n");	
 
 	/* Wait for FIFO to clear */
 	endjif = jiffies + 2;
 	while (jiffies < endjif); /* wait */
 	if (!(le32_to_cpu(*gpdata_io) & GPIO_INIT))
 	   {
-		printk("Drove Init low!! CRC Error!!!\n");
+		printk(KERN_NOTICE "Drove Init low!! CRC Error!!!\n");
 		goto err_out_release_all;
 	   }
 	if (!(le32_to_cpu(*gpdata_io) & GPIO_DONE))
 	   {
-		printk("Did not get DONE signal. Short file maybe??\n");
+		printk(KERN_DEBUG "Did not get DONE signal. Short file maybe??\n");
 		goto err_out_release_all;
 	   }
-	printk("Xilinx Chip successfully loaded, configured and started!!\n");
+	printk(KERN_INFO "Xilinx Chip successfully loaded, configured and started!!\n");
 
 	tor->mem8[SYNCREG] = 0;
 	tor->mem8[CTLREG] = 0;
@@ -537,11 +537,11 @@
 	}
 
 	if (t1in(tor,1,0xf) & 0x80) {
-		printk("Tormenta 2 Quad E1/PRA Card\n");
+		printk(KERN_INFO "Tormenta 2 Quad E1/PRA Card\n");
 		tor->cardtype = TYPE_E1;
 		tor->datxlt = datxlt_e1;
 	} else {
-		printk("Tormenta 2 Quad T1/PRI Card\n");
+		printk(KERN_INFO "Tormenta 2 Quad T1/PRI Card\n");
 		tor->cardtype = TYPE_T1;
 		tor->datxlt = datxlt_t1;
 	}
@@ -558,7 +558,7 @@
 	init_spans(tor); 
 
 	tor->order = tor->mem8[SWREG];
-	printk("Detected Card number: %d\n", tor->order);
+	printk(KERN_INFO "Detected Card number: %d\n", tor->order);
 
 	/* Launch cards as appropriate */
 	x = 0;
@@ -640,13 +640,13 @@
 static int __init tor2_init(void) {
 	int res;
 	res = dahdi_pci_module(&tor2_driver);
-	printk("Registered Tormenta2 PCI\n");
+	printk(KERN_INFO "Registered Tormenta2 PCI\n");
 	return res;
 }
 
 static void __exit tor2_cleanup(void) {
 	pci_unregister_driver(&tor2_driver);
-	printk("Unregistered Tormenta2\n");
+	printk(KERN_INFO "Unregistered Tormenta2\n");
 }
 
 static void set_clear(struct tor2 *tor)
@@ -661,7 +661,7 @@
 
 			if ((i % 8)==7) {
 #if 0
-				printk("Putting %d in register %02x on span %d\n",
+				printk(KERN_DEBUG "Putting %d in register %02x on span %d\n",
 				       val, 0x39 + j, 1 + s);
 #endif
 				t1out(tor,1 + s, 0x39 + j, val);
@@ -680,7 +680,7 @@
 	struct tor2_chan *p = chan->pvt;
 	unsigned long flags;
 #if 0
-	printk("Setting bits to %d on channel %s\n", bits, chan->name);
+	printk(KERN_DEBUG "Setting bits to %d on channel %s\n", bits, chan->name);
 #endif	
 	if (p->tor->cardtype == TYPE_E1) { /* do it E1 way */
 		if (chan->chanpos == 16) return 0;
@@ -752,7 +752,7 @@
 
 	tspan = p->span + 1;
 	if (tspan < 0) {
-		printk("Tor2: Span '%d' isn't us?\n", span->spanno);
+		printk(KERN_DEBUG "Tor2: Span '%d' isn't us?\n", span->spanno);
 		return -1;
 	}
 
@@ -778,7 +778,7 @@
 		/* No longer in use, disable interrupts */
 		p->tor->mem8[CTLREG] = 0;
 	if (debug)
-		printk("Span %d (%s) shutdown\n", span->spanno, span->name);
+		printk(KERN_DEBUG"Span %d (%s) shutdown\n", span->spanno, span->name);
 	return 0;
 }
 
@@ -797,7 +797,7 @@
 
 	tspan = p->span + 1;
 	if (tspan < 0) {
-		printk("Tor2: Span '%d' isn't us?\n", span->spanno);
+		printk(KERN_DEBUG "Tor2: Span '%d' isn't us?\n", span->spanno);
 		return -1;
 	}
 
@@ -895,9 +895,9 @@
 
 		if (debug) {
 			if (alreadyrunning) 
-				printk("Tor2: Reconfigured span %d (%s/%s%s) 120 Ohms\n", span->spanno, coding, framing, crcing);
+				printk(KERN_INFO "Tor2: Reconfigured span %d (%s/%s%s) 120 Ohms\n", span->spanno, coding, framing, crcing);
 			else
-				printk("Tor2: Startup span %d (%s/%s%s) 120 Ohms\n", span->spanno, coding, framing, crcing);
+				printk(KERN_INFO "Tor2: Startup span %d (%s/%s%s) 120 Ohms\n", span->spanno, coding, framing, crcing);
 		}
 	} else { /* is a T1 card */
 
@@ -982,15 +982,15 @@
 
 		if (debug) {
 			if (alreadyrunning) 
-				printk("Tor2: Reconfigured span %d (%s/%s) LBO: %s\n", span->spanno, coding, framing, dahdi_lboname(span->txlevel));
+				printk(KERN_INFO "Tor2: Reconfigured span %d (%s/%s) LBO: %s\n", span->spanno, coding, framing, dahdi_lboname(span->txlevel));
 			else
-				printk("Tor2: Startup span %d (%s/%s) LBO: %s\n", span->spanno, coding, framing, dahdi_lboname(span->txlevel));
-		}
-	}
-	if (p->tor->syncs[0] == span->spanno) printk("SPAN %d: Primary Sync Source\n",span->spanno);
-	if (p->tor->syncs[1] == span->spanno) printk("SPAN %d: Secondary Sync Source\n",span->spanno);
-	if (p->tor->syncs[2] == span->spanno) printk("SPAN %d: Tertiary Sync Source\n",span->spanno);
-	if (p->tor->syncs[3] == span->spanno) printk("SPAN %d: Quaternary Sync Source\n",span->spanno);
+				printk(KERN_INFO "Tor2: Startup span %d (%s/%s) LBO: %s\n", span->spanno, coding, framing, dahdi_lboname(span->txlevel));
+		}
+	}
+	if (p->tor->syncs[0] == span->spanno) printk(KERN_INFO "SPAN %d: Primary Sync Source\n",span->spanno);
+	if (p->tor->syncs[1] == span->spanno) printk(KERN_INFO "SPAN %d: Secondary Sync Source\n",span->spanno);
+	if (p->tor->syncs[2] == span->spanno) printk(KERN_INFO "SPAN %d: Tertiary Sync Source\n",span->spanno);
+	if (p->tor->syncs[3] == span->spanno) printk(KERN_INFO "SPAN %d: Quaternary Sync Source\n",span->spanno);
 	return 0;
 }
 
@@ -1017,7 +1017,7 @@
 		    case DAHDI_MAINT_LOOPSTOP:
 			return -ENOSYS;
 		    default:
-			printk("Tor2: Unknown maint command: %d\n", cmd);
+			printk(KERN_NOTICE "Tor2: Unknown maint command: %d\n", cmd);
 			break;
 		}
 		return 0;
@@ -1049,7 +1049,7 @@
 	t1out(p->tor,tspan,0x30,0);	/* stop sending loopup code */
 	break;
     default:
-	printk("Tor2: Unknown maint command: %d\n", cmd);
+	printk(KERN_NOTICE "Tor2: Unknown maint command: %d\n", cmd);
 	break;
    }
     return 0;
@@ -1149,7 +1149,7 @@
 			syncnum = newsyncnum;
 			syncsrc = newsyncsrc;
 			syncspan = newsyncspan;
-			if (debug) printk("New syncnum: %d, syncsrc: %d, syncspan: %d\n", syncnum, syncsrc, syncspan);
+			if (debug) printk(KERN_DEBUG "New syncnum: %d, syncsrc: %d, syncspan: %d\n", syncnum, syncsrc, syncspan);
 		}
 	}
 #endif	
@@ -1165,7 +1165,7 @@
 			/* actually set the sync register */
 			tor->mem8[SYNCREG] = syncspan;
 #endif			
-			if (debug) printk("Card %d, using sync span %d, master\n", tor->num, syncspan);
+			if (debug) printk(KERN_DEBUG "Card %d, using sync span %d, master\n", tor->num, syncspan);
 			tor->master = MASTER;	
 		} else {
 #if 1
@@ -1173,7 +1173,7 @@
 			tor->mem8[SYNCREG] = SYNCEXTERN;

[... 4742 lines stripped ...]



More information about the dahdi-commits mailing list