From e3429f060d5d3443f1b65c654fad2f145b88a10b Mon Sep 17 00:00:00 2001 From: Tzafrir Cohen Date: Thu, 16 Apr 2009 19:08:53 +0000 Subject: xpp fxs: Notify the user just one about wrong VMWI config From xpp rev. 6974. git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@6386 a0bf4364-ded3-4de4-8d8a-66a801d63aff --- drivers/dahdi/xpp/card_fxs.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/dahdi/xpp/card_fxs.c b/drivers/dahdi/xpp/card_fxs.c index 3673d8b..56fe89e 100644 --- a/drivers/dahdi/xpp/card_fxs.c +++ b/drivers/dahdi/xpp/card_fxs.c @@ -872,7 +872,11 @@ static int FXS_card_ioctl(xpd_t *xpd, int pos, unsigned int cmd, unsigned long a if (get_user(val, (int __user *)arg)) return -EFAULT; if(!vmwi_ioctl) { - LINE_NOTICE(xpd, pos, "Got DAHDI_VMWI notification but vmwi_ioctl parameter is off. Ignoring.\n"); + static bool notified = 0; + + if(!notified++) + LINE_NOTICE(xpd, pos, + "Got DAHDI_VMWI notification but vmwi_ioctl parameter is off. Ignoring.\n"); return 0; } /* Digital inputs/outputs don't have VM leds */ -- cgit v1.2.3