[dahdi-commits] sruffell: linux/trunk r7534 - /linux/trunk/drivers/dahdi/wct4xxp/base.c
SVN commits to the DAHDI project
dahdi-commits at lists.digium.com
Mon Nov 9 12:02:45 CST 2009
Author: sruffell
Date: Mon Nov 9 12:02:40 2009
New Revision: 7534
URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=7534
Log:
wct4xxp: Only print the new debounce messages when debug is set.
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=7534&r1=7533&r2=7534
==============================================================================
--- linux/trunk/drivers/dahdi/wct4xxp/base.c (original)
+++ linux/trunk/drivers/dahdi/wct4xxp/base.c Mon Nov 9 12:02:40 2009
@@ -2562,10 +2562,12 @@
if (ts->alarmcount >= alarmdebounce)
alarms |= DAHDI_ALARM_RED;
else {
- if (!ts->alarmcount) /* starting to debounce LOF/LFA */
+ if (unlikely(debug && !ts->alarmcount)) {
+ /* starting to debounce LOF/LFA */
printk(KERN_INFO "wct%dxxp: LOF/LFA detected "
"on span %d but debouncing for %d ms\n",
wc->numspans, span + 1, alarmdebounce);
+ }
ts->alarmcount++;
}
} else
@@ -2575,10 +2577,12 @@
if (ts->losalarmcount >= losalarmdebounce)
alarms |= DAHDI_ALARM_RED;
else {
- if (!ts->losalarmcount) /* starting to debounce LOS */
+ if (unlikely(debug && !ts->losalarmcount)) {
+ /* starting to debounce LOS */
printk(KERN_INFO "wct%dxxp: LOS detected on "
"span %d but debouncing for %d ms\n",
wc->numspans, span + 1, losalarmdebounce);
+ }
ts->losalarmcount++;
}
} else
@@ -2588,10 +2592,12 @@
if (ts->aisalarmcount >= aisalarmdebounce)
alarms |= DAHDI_ALARM_BLUE;
else {
- if (!ts->aisalarmcount) /* starting to debounce AIS */
+ if (unlikely(debug && !ts->aisalarmcount)) {
+ /* starting to debounce AIS */
printk(KERN_INFO "wct%dxxp: AIS detected on "
"span %d but debouncing for %d ms\n",
wc->numspans, span + 1, aisalarmdebounce);
+ }
ts->aisalarmcount++;
}
} else
@@ -2637,12 +2643,14 @@
if (ts->yelalarmcount >= yelalarmdebounce)
alarms |= DAHDI_ALARM_YELLOW;
else {
- if (!ts->yelalarmcount) /* starting to debounce AIS */
+ if (unlikely(debug && !ts->yelalarmcount)) {
+ /* starting to debounce AIS */
printk(KERN_INFO "wct%dxxp: yelllow (RAI) "
"detected on span %d but debouncing "
"for %d ms\n",
wc->numspans, span + 1,
yelalarmdebounce);
+ }
ts->yelalarmcount++;
}
} else
More information about the dahdi-commits
mailing list