summaryrefslogtreecommitdiff
path: root/xpp/card_fxo.c
diff options
context:
space:
mode:
Diffstat (limited to 'xpp/card_fxo.c')
-rw-r--r--xpp/card_fxo.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/xpp/card_fxo.c b/xpp/card_fxo.c
index ff87120..ad8e438 100644
--- a/xpp/card_fxo.c
+++ b/xpp/card_fxo.c
@@ -33,9 +33,9 @@
static const char rcsid[] = "$Id$";
-DEF_PARM(int, print_dbg, 0, 0600, "Print DBG statements");
-DEF_PARM(uint, poll_battery_interval, 100, 0600, "Poll battery interval in milliseconds (0 - disable)");
-DEF_PARM(int, ring_debounce, 50, 0600, "Number of ticks to debounce a false RING indication");
+DEF_PARM(int, print_dbg, 0, 0644, "Print DBG statements");
+DEF_PARM(uint, poll_battery_interval, 500, 0644, "Poll battery interval in milliseconds (0 - disable)");
+DEF_PARM(int, ring_debounce, 50, 0644, "Number of ticks to debounce a false RING indication");
/* Signaling is opposite (fxs signalling for fxo card) */
#if 1
@@ -684,6 +684,7 @@ static void update_battery_status(xpd_t *xpd, byte data_low, lineno_t chipsel)
BIT_CLR(priv->polarity, chipsel);
priv->polarity_counter[chipsel] = 0;
/* Inform Zaptel */
+ DBG("%s/%s/%d: Send ZT_EVENT_POLARITY\n", xpd->xbus->busname, xpd->xpdname, chipsel);
zt_qevent_lock(&xpd->chans[chipsel], ZT_EVENT_POLARITY);
#if 0
/*
@@ -710,6 +711,7 @@ static void update_power_denial(xpd_t *xpd, byte data_low, lineno_t chipsel)
if (IS_SET(xpd->offhook, chipsel) && data_low < 3) {
priv->current_counter[chipsel]++;
if (priv->current_counter[chipsel] >= 10) {
+ DBG("%s/%s/%d: Power Denial Hangup\n", xpd->xbus->busname, xpd->xpdname, chipsel);
priv->current_counter[chipsel] = 0;
do_sethook(xpd, chipsel, 0);
update_line_status(xpd, chipsel, 0);
@@ -833,6 +835,10 @@ static int proc_fxo_info_read(char *page, char **start, off_t off, int count, in
for_each_line(xpd, i) {
len += sprintf(page + len, "%2d ", IS_SET(priv->battery, i));
}
+ len += sprintf(page + len, "\n\t%-17s: ", "polarity");
+ for_each_line(xpd, i) {
+ len += sprintf(page + len, "%2d ", IS_SET(priv->polarity, i));
+ }
len += sprintf(page + len, "\n");
spin_unlock_irqrestore(&xpd->lock, flags);
if (len <= off+count)