summaryrefslogtreecommitdiff
path: root/drivers/dahdi
diff options
context:
space:
mode:
authorShaun Ruffell <sruffell@digium.com>2010-09-14 02:20:58 +0000
committerShaun Ruffell <sruffell@digium.com>2010-09-14 02:20:58 +0000
commitf3856c132b314f13b5eab6d272fb160520a1fa50 (patch)
tree5523e5cb25b8eb15aa03043c41e01f71a760d371 /drivers/dahdi
parent6bb8b05c128e7748d2b818afa1680c1b46929f07 (diff)
dahdi: Remove unused functions __buf_munge and __buf_cpush.
These functions were only defined if BUF_MUNGE was defined, but even if that symbol is defined there is not anyplace in the driver where these functions were then called. This has been in the code since rev 87 so this is most likely stale debugging code. Feel free to revert if this is actually used somewhere that is not apparent. Here is where the functions were originally added to the drivers: http://svnview.digium.com/svn/zaptel?view=revision&revision=87 Signed-off-by: Shaun Ruffell <sruffell@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9322 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'drivers/dahdi')
-rw-r--r--drivers/dahdi/dahdi-base.c29
1 files changed, 0 insertions, 29 deletions
diff --git a/drivers/dahdi/dahdi-base.c b/drivers/dahdi/dahdi-base.c
index 95dfe4d..9ed0bc2 100644
--- a/drivers/dahdi/dahdi-base.c
+++ b/drivers/dahdi/dahdi-base.c
@@ -58,8 +58,6 @@
#define module_printk(level, fmt, args...) printk(level "%s: " fmt, THIS_MODULE->name, ## args)
-/* #define BUF_MUNGE */
-
#include <dahdi/version.h>
/* Grab fasthdlc with tables */
#define FAST_HDLC_NEED_TABLES
@@ -1145,33 +1143,6 @@ static u_char *__buf_peek(struct confq *q)
return q->buf[q->outbuf];
}
-#ifdef BUF_MUNGE
-static u_char *__buf_cpush(struct confq *q)
-{
- int pos;
- /* If we have no space, return where the
- last space that we *did* have was */
- if (q->inbuf > -1)
- return NULL;
- pos = q->outbuf - 1;
- if (pos < 0)
- pos += DAHDI_CB_SIZE;
- return q->buf[pos];
-}
-
-static void __buf_munge(struct dahdi_chan *chan, u_char *old, u_char *new)
-{
- /* Run a weighted average of the old and new, in order to
- mask a missing sample */
- int x;
- int val;
- for (x=0;x<DAHDI_CHUNKSIZE;x++) {
- val = x * DAHDI_XLAW(new[x], chan) + (DAHDI_CHUNKSIZE - x - 1) * DAHDI_XLAW(old[x], chan);
- val = val / (DAHDI_CHUNKSIZE - 1);
- old[x] = DAHDI_LIN2X(val, chan);
- }
-}
-#endif
/* Push something onto the queue, or assume what
is there is valid if data is NULL */
static int __buf_push(struct confq *q, u_char *data)