[dahdi-commits] rmeyerriecks: branch linux/mspiceland/dahdi-qfalc31 r7775 - in /linux/team/ms...

SVN commits to the DAHDI project dahdi-commits at lists.digium.com
Wed Jan 6 15:22:25 CST 2010


Author: rmeyerriecks
Date: Wed Jan  6 15:22:21 2010
New Revision: 7775

URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=7775
Log:
Merged revisions 7681-7682,7690-7691,7702,7708,7711,7722,7731-7732,7753,7768-7769 via svnmerge from 
https://origsvn.digium.com/svn/dahdi/linux/trunk

........
  r7681 | sruffell | 2009-12-11 17:20:02 -0600 (Fri, 11 Dec 2009) | 6 lines
  
  dahdi-base: Reduce the max allocation size in dahdi_reallocbufs.
  
  Lower the maximum contiguous chunk that DAHDI asks for from
  DAHDI_MAX_BUFFER_SIZE*2 to DAHDI_MAX_BUFFER_SIZE. With 4K pages, this can allow
  the kernel to try a little harder to find the memory it needs since the request
  goes from order 4 to order 3.
........
  r7682 | sruffell | 2009-12-11 17:20:03 -0600 (Fri, 11 Dec 2009) | 5 lines
  
  dahdi-base: Do not wait for impulse when echotraining.
  
  Waiting here for the impulse on the transmit can cause the echotraining logic to
  stick the channel into muted state.  This is especially apparent on systems
  that regularly do not service the interrupts every millisecond. DAHDI-387.
........
  r7690 | tzafrir | 2009-12-14 14:41:18 -0600 (Mon, 14 Dec 2009) | 7 lines
  
  xpp: replace i with j to avoid overriding
  
  Fix a place where an inner declaration of a local 'i' shadows the
  declaration of an outer one. Just rename the inner one to 'j'.
  
  Reported by sparse.
........
  r7691 | tzafrir | 2009-12-14 14:50:59 -0600 (Mon, 14 Dec 2009) | 10 lines
  
  DAHDI_AUDIO_NOTIFY: Also pass DAHDI_AUDIOMODE to channel driver
  
  Adds a new compile-time option DAHDI_AUDIO_NOTIFY. With it there's a new
  span hook, audio_notify, that gets called (if not NULL) whenever the
  ioctl DAHDI_AUDIOMODE is called for a channel.
  
  This can be useful to tell (in most cases) if an ISDN channel is active
  or not and thus allow the low-level driver to optimize traffic when
  channels are not active.
........
  r7702 | tzafrir | 2009-12-16 12:58:46 -0600 (Wed, 16 Dec 2009) | 8 lines
  
  kernel-cp: a local wrapper to the kernel's checkpatch script.
  
  checkpatch.pl is a script intended to check style of code (normally:
  before submitting kernel patches).
  
  As using this script simplifies testing new code for coding style,
  this commit officially closes issue #16191 .
........
  r7708 | tzafrir | 2009-12-18 17:20:17 -0600 (Fri, 18 Dec 2009) | 2 lines
  
  A standard license header for the firmware Makefile.
........
  r7711 | tzafrir | 2009-12-20 10:16:33 -0600 (Sun, 20 Dec 2009) | 5 lines
  
  Another dump of documentation.
  
  Extended the documentation of the "Internals" section. Hopefully it is
  correct.
........
  r7722 | sruffell | 2009-12-22 11:50:25 -0600 (Tue, 22 Dec 2009) | 5 lines
  
  voicebus, wcte12xp: Only define SLAB_STORE_USER when CONFIG_SLUB is defined.
  
  On 2.6.22, there is was a bug in the SLUB allocator that required defining
  SLAB_STORE_USER, however this setting is only valid when CONFIG_SLUB is defined
  and not when using the previous slab allocator. DAHDI-424.
........
  r7731 | tzafrir | 2009-12-28 12:33:51 -0600 (Mon, 28 Dec 2009) | 4 lines
  
  xpp: Fix a typo in card_fxo.
  
  xpp rev: 7595
........
  r7732 | tzafrir | 2009-12-28 12:49:21 -0600 (Mon, 28 Dec 2009) | 6 lines
  
  autoconf.h is inlcuded by Kbuild at the command-line.
  No need to explicitly include it.
  
  Also note that <linux/autoconf.h> is invalid as of 2.6.33 . It is now
  <generated/autoconf.h> (but anyway, should not be #include-d directly).
........
  r7753 | tzafrir | 2010-01-04 11:01:34 -0600 (Mon, 04 Jan 2010) | 14 lines
  
  Fix udev rules to work with more recent kernels.
  
  Note that this change will not work on most older systems (e.g.:
  Centos5, with its udev 0.95) if the matching change of xpp_fxloader in
  tools (r7752) is not applied.
  
  * Replace deprecated 'BUS' with 'SUBSYSTEM'
  * Sysfs{} should be replaced with ATTR{}. Sadly the former is not
    supported in recent udev, and the latter is not supported in udev
    0.95. Workaround: use PRODUCT from the environment.
  * Use a single rule.
  * While we're at it, add the missing comma to the astribank_hook line
    (which surprisingly worked without it).
........
  r7768 | tzafrir | 2010-01-06 13:02:17 -0600 (Wed, 06 Jan 2010) | 7 lines
  
  Remove some unused 'struct inode *' function parameters.
  
  Patch 0001 from issue #14808 (initial cleanup)
  
  0001-dahdi-base-Remove-some-unused-struct-inode-function-.patch uploaded
  by sruffell (license 456)
........
  r7769 | tzafrir | 2010-01-06 13:16:52 -0600 (Wed, 06 Jan 2010) | 16 lines
  
  Use unlocked_ioctl and compat_ioctl instead of ioctl.
  
  * dahdi-base needs compat_ioctl in order to allow 32-bit userspace
    applications to call the DAHDI ioctls in a 64-bit kernel.
  * add a separate dahdi_ioctl_compat() to handle functions whose parameters
    will need some tweaks (currently: only reject DAHDI_SFCONFIG).
  
  (closes issue #14808)
  
  * 0002-dahdi-base-Use-unlocked_ioctl-and-compat_ioctl-inste.patch uploaded
    by sruffell (license 456)
  * 0003-add-a-separate-dahdi_ioctl_compat.patch uploaded by tzafrir
    (license 46)
  
  Tested by: sruffell, tzafrir
........

Added:
    linux/team/mspiceland/dahdi-qfalc31/build_tools/kernel-cp
      - copied unchanged from r7769, linux/trunk/build_tools/kernel-cp
Modified:
    linux/team/mspiceland/dahdi-qfalc31/   (props changed)
    linux/team/mspiceland/dahdi-qfalc31/README
    linux/team/mspiceland/dahdi-qfalc31/build_tools/   (props changed)
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/dahdi-base.c
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/firmware/Makefile
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/voicebus/voicebus.c
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcb4xxp/base.c
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wct4xxp/vpm450m.c
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcte12xp/base.c
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_fxo.c
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_pri.c
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/xpp.rules
    linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/xpp_dahdi.c
    linux/team/mspiceland/dahdi-qfalc31/include/dahdi/dahdi_config.h
    linux/team/mspiceland/dahdi-qfalc31/include/dahdi/kernel.h

Propchange: linux/team/mspiceland/dahdi-qfalc31/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Wed Jan  6 15:22:21 2010
@@ -1,1 +1,1 @@
-/linux/trunk:1-7661
+/linux/trunk:1-7774

Modified: linux/team/mspiceland/dahdi-qfalc31/README
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/README?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/README (original)
+++ linux/team/mspiceland/dahdi-qfalc31/README Wed Jan  6 15:22:21 2010
@@ -416,7 +416,7 @@
 Internals
 ---------
 DAHDI Device Files
-~~~~~~~~~~~~~~~~~~~
+~~~~~~~~~~~~~~~~~~
 Userspace programs will usually interact with DAHDI through device
 files under the /dev/dahdi directory (pedantically: character device files 
 with major number 196) . Those device files can be generated statically
@@ -440,7 +440,7 @@
 
 
 DAHDI Timing
-~~~~~~~~~~~~~
+~~~~~~~~~~~~
 A PBX system should generally have a single clock. If you are connected to a
 telephony provider via a digital interface (e.g: E1, T1) you should also
 typically use the provider's clock (as you get through the interface). Hence
@@ -490,6 +490,47 @@
 with 1). The number of the channel is the lowest unused one when it is
 generated, and ditto for spans.
 
+There are up to 128 spans and 1024 channels. This is a hard-wired limit
+(see dahdi/user.h . Several places throuout the code assume a channel
+number fits in a 16 bits number). Channel and span numbers start at 1.
+
+
+Dynamic Spans
+~~~~~~~~~~~~~
+Dynamic spans are spans that are not represented by real hardware.
+Currently there are two types of them:
+
+tdmoe::
+  TDM over Ethernet. A remote span is identified by an ethernet (MAC)
+  address.
+
+local::
+  Generates a span that is actually a loopback to a different local
+  span.
+
+Modules that support the dynamic spans are typically loaded at the time
+the ioctl DAHDI_DYNAMIC_CREATE is called. This is typically called by
+dahdi_cfg when it has a line such as:
+
+  dynamic,somename,params
+
+in /etc/dahdi/system.conf . In that case it will typically try to load
+(through modprobe) the modules dahdi_dynamic and
+dahdi_dynamic_'somename'. It will then pass 'params' to it.
+
+Dynamic spans are known to be tricky and are some of the least-tested
+parts of DAHDI.
+
+
+Echo Cancellers
+~~~~~~~~~~~~~~~
+(To be documented later)
+
+
+Tone Zones
+~~~~~~~~~~
+(To be documented later)
+
 
 PROCFS Interface: /proc/dahdi
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -525,6 +566,218 @@
 see an extra '(In use)':
 
            2 XPP_FXS/0/0/1 FXOLS (In use)
+
+
+User-space Interface
+~~~~~~~~~~~~~~~~~~~~
+User-space programs can only work with DAHDI channels. The basic
+operation is 'read()' to read audio from the device and write() to write
+audio to it. Audio can be encoded as either alaw (G.711a) or (m)ulaw
+(G.711u). See the ioctl DAHDI_SETLAW.
+
+While it is technically possible to use /dev/dahdi/NUMBER directly, this
+will only work for channel numbers up to 249. Generally you should use:
+
+  int channo = CHAN_NUMBER_TO_OPEN;
+  int rc;
+  int fd = open("/dev/dahdi/channel", O_RDRW, 0600);
+  // Make sure fd >= 0
+  rc = ioctl(fd, DAHDI_SPECIFY, &channo) < 0);
+  // Make sure this rc >= 0
+
+FIXME: there's more to tell about the user-space interface.
+
+
+Configuration
+~~~~~~~~~~~~~
+Most of the configuration is applied from userspace using the tool
+'dahdi_cfg' in the package dahdi_tools. This section will not cover the
+specifics of that file. Rather it will cover the way configuration from
+this file is applied. Also note that there are other methods to
+configure DAHDI drivers: there are <<_module_parameters,Module
+Parameters>>. The xpp driver have their own separate initialization
+scripts and xpp.conf that arecovered in README.Astribank.
+
+When a span is registered, it is considered "unconfigured". Only after
+dahdi_cfg has been run to apply configuration, the span is ready to run.
+The only exception to that is 'dahdi_dummy', which does not need any
+configuration.
+
+Some of the configuration is handled by the DAHDI core. Some of it is
+handled by callbacks, which are function pointers in the `struct
+dahdi_span': 'spanconfig', 'chanconfig' and (in a way) 'startup'.
+
+Dahdi_cfg starts by reading the configuration from the configuration
+file ('/etc/dahdi/system.conf', by default), and creating a local
+configuration to apply. If you use -v, at this stage it will pront the
+configuration that is "about to be configured". Then it will start to
+actually apply the configuration.
+
+Before actually applying configuration, it destroys any existing
+<<_dynamic_spans,dynamic spans>> and generates new ones (if so
+configured. FIXME: what about running DAHDI_SPANCONFIG for new dynamic
+spans?).
+
+Next thing it will do is apply the parameters from *span* lines using
+the ioctl DAHDI_SPANCONFIG. Some generic processing of parameters passed
+in DAHDI_SPANCONFIG is done in the DAHDI core, in the callback function
+spanconfig in , but most of it is left to 'spanconfig' callback of the
+span (if it exists. This one typically does not exists on analog cards).
+
+Now dahdi_cfg will ask each existing channel for its existing
+configuration and apply configuration if configuration changes are
+needed. Configuration is applied to the channels using the ioctl call
+DAHDI_CHANCONFIG ioctl. As in the case of the span configuration, part
+of it is applied by the DAHDI core, and then it is handed over to the
+span's chanconfig callback. Typically all spans will have such a
+callback.
+
+<<_echo_cancellers,Echo cancellers>> and <<_tone_zones,tone-zones>> are
+handled separately later. 
+
+Once everything is done, the ioctl DAHDI_STARTUP is called for every
+span. This is also translated to a call to the optional span callback
+'startup'.
+
+Finally the ioctl DAHDI_HDLC_RATE is called for every channel (that is:
+if '56k' is not set for the channel, it will be explicitly set to the
+standard HDLC rate of 64k).
+
+
+Low-Level Drivers
+~~~~~~~~~~~~~~~~~
+Low-level drivers create spans ('struct dahdi_span'). They register the
+spans with the DAHDI core using 'dahdi_register()'.
+
+'struct dahdi_span' has a number of informative members that are updated
+solely by the low-level driver:
+
+name::
+  A concise span name. E.g.: Foo/1
+desc::
+  A slightly longer span name.
+spantype::
+  Span type in text form.
+manufacturer::
+  Span's device manufacturer
+devicetype::
+  Span's device type
+location::
+  span device's location in system
+irq::
+  IRQ for this span's hardware
+irqmisses::
+  Interrupt misses
+timingslips::
+  Clock slips
+
+There are various function pointers in the struct 'dahdi_span' which are
+used by the DAHDI core to call the low-level driver. Most of them are
+optional.
+
+The following apply to a span:
+
+setchunksize::
+  FIXME: seems to be unused.
+
+spanconfig::
+  Basic span configuration (called from dahdi_cfg).
+	
+startup::
+  Last minute initialization after the configuration was applied.
+	
+shutdown::
+  Explicit shutdown (e.g. for dynamic spans). Normally not needed.
+	
+maint::
+  Enable/disable maintinance mode (FIXME: document).
+
+sync_tick::
+  Get notified that the master span has ticked.
+
+The following apply to a single channel.
+
+chanconfig::
+  Configure the channel (called from dahdi_cfg).
+
+open::
+  Channel was opened for read/write from user-space.
+
+close::
+  Channel was closed by user-space.
+
+ioctl::
+  Handle extra ioctls. Should return -ENOTTY if ioctl is not known to
+  the channel
+
+echocan_create::
+  Create a custom echo canceller. Normally used for providing a hardware
+  echo canceller. If NULL, the standard DAHDI echo canceller modules
+  will be used.
+
+rbsbits::
+  Copy signalling bits to device. See below on signalling.
+
+hooksig::
+  Implement RBS-like signalling-handling. See below on signalling.
+
+sethook::
+  Handle signalling yourself. See below on signalling.
+
+hdlc_hard_xmit::
+  Used to tell an onboard HDLC controller that there is data ready to
+  transmit.
+
+audio_notify::
+  (if DAHDI_AUDIO_NOTIFY is set) - be notified when the channel is (or
+  isn't) in audio mode. Which may mean (for an ISDN B-channel) that its
+  data need not be sent.
+
+There are several alternative methods for a span to use for
+signalling. One of them should be used.
+
+Signalling: rbsbits
+^^^^^^^^^^^^^^^^^^^
+If the device is a CAS interface, the driver should copy the signalling
+bits to and from the other side, and DAHDI will handle the signalling.
+The driver just need to provide a 'rbsbits' and set DAHDI_FLAG_RBS in
+the span->flags.
+
+Note that 'rbs' (Robed Bits Signalling) here merely refers to the (up
+to) 4 signalling bits of the channel. In T1 they are transmitted by
+"robbing" bits from the channels and hence the name. In E1 they are
+transmitted in a timeframe of their own.
+
+The driver should then signal a change in the signalling bits in a
+channel using dahdi_rbsbits().
+
+
+Signalling: hooksig
+^^^^^^^^^^^^^^^^^^^
+If the device does not know about signalling bits, but has their
+equivalents (i.e. can disconnect battery, detect off hook, generate
+ring, etc directly) then the driver can specify a 'sethook' function and
+set DAHDI_FLAG_RBS in span->flags. In that case DAHDI will call that
+function whenever the signalling state changes.
+
+The hooksig function is only used if the rbsbits function is not set.
+
+The span should notify DAHDI of a change of signalling in a channel using
+dahdi_hooksig().
+
+
+Signalling: sethook
+^^^^^^^^^^^^^^^^^^^
+Alternatively, if DAHDI_FLAG_RBS is not set in the flags of the span (to
+use either rbsbits or hooksig), the DAHDI core will try to call the
+'sethook' function of the span (if it exists) to handle individual hook
+states.
+
+The span should then notify DAHDI of a change in the signalling state
+using dahdi_sethook().
+
+FIXME: anybody using this one?
+
 
 ABI Compatibility
 ~~~~~~~~~~~~~~~~~

Propchange: linux/team/mspiceland/dahdi-qfalc31/build_tools/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Wed Jan  6 15:22:21 2010
@@ -1,3 +1,4 @@
 menuselect-deps
 make_firmware_object
 git_test.conf
+checkpatch.pl

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/dahdi-base.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/dahdi-base.c?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/dahdi-base.c (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/dahdi-base.c Wed Jan  6 15:22:21 2010
@@ -48,6 +48,10 @@
 #include <linux/sched.h>
 #include <linux/list.h>
 
+#ifdef HAVE_UNLOCKED_IOCTL
+#include <linux/smp_lock.h>
+#endif
+
 #include <linux/ppp_defs.h>
 
 #include <asm/atomic.h>
@@ -304,7 +308,7 @@
 	.mfr2_tonelen = DEFAULT_MFR2_LENGTH,
 };
 
-static int dahdi_chan_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long data, int unit);
+static int dahdi_chan_ioctl(struct file *file, unsigned int cmd, unsigned long data, int unit);
 
 #if defined(CONFIG_DAHDI_MMX) || defined(ECHO_CAN_FP)
 #if (defined(CONFIG_X86) && !defined(CONFIG_X86_64)) || defined(CONFIG_I386)
@@ -946,9 +950,12 @@
 	data[len - 1] = (fcs >> 8) & 0xff;
 }
 
-static int dahdi_reallocbufs(struct dahdi_chan *ss, int j, int numbufs)
-{
-	unsigned char *newbuf, *oldbuf;
+static int dahdi_reallocbufs(struct dahdi_chan *ss, int blocksize, int numbufs)
+{
+	unsigned char *newtxbuf = NULL;
+	unsigned char *newrxbuf = NULL;
+	unsigned char *oldtxbuf = NULL;
+	unsigned char *oldrxbuf = NULL;
 	unsigned long flags;
 	int x;
 
@@ -960,25 +967,32 @@
 		numbufs = DAHDI_MAX_NUM_BUFS;
 
 	/* We need to allocate our buffers now */
-	if (j) {
-		if (!(newbuf = kcalloc(j * 2, numbufs, GFP_KERNEL)))
+	if (blocksize) {
+		newtxbuf = kzalloc(blocksize * numbufs, GFP_KERNEL);
+		if (NULL == newtxbuf)
 			return -ENOMEM;
-	} else
-		newbuf = NULL;
-
-	/* Now that we've allocated our new buffer, we can safely
+		newrxbuf = kzalloc(blocksize * numbufs, GFP_KERNEL);
+		if (NULL == newrxbuf) {
+			kfree(newtxbuf);
+			return -ENOMEM;
+		}
+	}
+
+	/* Now that we've allocated our new buffers, we can safely
  	   move things around... */
 
 	spin_lock_irqsave(&ss->lock, flags);
 
-	ss->blocksize = j; /* set the blocksize */
-	oldbuf = ss->readbuf[0]; /* Keep track of the old buffer */
+	ss->blocksize = blocksize; /* set the blocksize */
+	oldrxbuf = ss->readbuf[0]; /* Keep track of the old buffer */
+	oldtxbuf = ss->writebuf[0];
 	ss->readbuf[0] = NULL;
 
-	if (newbuf) {
+	if (newrxbuf) {
+		BUG_ON(NULL == newtxbuf);
 		for (x = 0; x < numbufs; x++) {
-			ss->readbuf[x] = newbuf + x * j;
-			ss->writebuf[x] = newbuf + (numbufs + x) * j;
+			ss->readbuf[x] = newrxbuf + x * blocksize;
+			ss->writebuf[x] = newtxbuf + x * blocksize;
 		}
 	} else {
 		for (x = 0; x < numbufs; x++) {
@@ -997,7 +1011,7 @@
 
 	/* Keep track of where our data goes (if it goes
 	   anywhere at all) */
-	if (newbuf) {
+	if (newrxbuf) {
 		ss->inreadbuf = 0;
 		ss->inwritebuf = 0;
 	} else {
@@ -1021,8 +1035,8 @@
 
 	spin_unlock_irqrestore(&ss->lock, flags);
 
-	if (oldbuf)
-		kfree(oldbuf);
+	kfree(oldtxbuf);
+	kfree(oldrxbuf);
 
 	return 0;
 }
@@ -2238,25 +2252,25 @@
 	return amnt;
 }
 
-static int dahdi_ctl_open(struct inode *inode, struct file *file)
+static int dahdi_ctl_open(struct file *file)
 {
 	/* Nothing to do, really */
 	return 0;
 }
 
-static int dahdi_chan_open(struct inode *inode, struct file *file)
+static int dahdi_chan_open(struct file *file)
 {
 	/* Nothing to do here for now either */
 	return 0;
 }
 
-static int dahdi_ctl_release(struct inode *inode, struct file *file)
+static int dahdi_ctl_release(struct file *file)
 {
 	/* Nothing to do */
 	return 0;
 }
 
-static int dahdi_chan_release(struct inode *inode, struct file *file)
+static int dahdi_chan_release(struct file *file)
 {
 	/* Nothing to do for now */
 	return 0;
@@ -2616,7 +2630,7 @@
 	return 0;
 }
 
-static int dahdi_timing_open(struct inode *inode, struct file *file)
+static int dahdi_timing_open(struct file *file)
 {
 	struct dahdi_timer *t;
 	unsigned long flags;
@@ -2635,7 +2649,7 @@
 	return 0;
 }
 
-static int dahdi_timer_release(struct inode *inode, struct file *file)
+static int dahdi_timer_release(struct file *file)
 {
 	struct dahdi_timer *t, *cur, *next;
 	unsigned long flags;
@@ -2664,7 +2678,7 @@
 	return 0;
 }
 
-static int dahdi_specchan_open(struct inode *inode, struct file *file, int unit)
+static int dahdi_specchan_open(struct file *file, int unit)
 {
 	int res = 0;
 	struct dahdi_chan *const chan = chans[unit];
@@ -2710,7 +2724,7 @@
 	return res;
 }
 
-static int dahdi_specchan_release(struct inode *node, struct file *file, int unit)
+static int dahdi_specchan_release(struct file *file, int unit)
 {
 	int res=0;
 	unsigned long flags;
@@ -2787,7 +2801,7 @@
 	struct dahdi_chan *chan;
 	/* Minor 0: Special "control" descriptor */
 	if (!unit)
-		return dahdi_ctl_open(inode, file);
+		return dahdi_ctl_open(file);
 	if (unit == 250) {
 		if (!dahdi_transcode_fops) {
 			if (request_module("dahdi_transcode")) {
@@ -2812,32 +2826,32 @@
 	}
 	if (unit == 253) {
 		if (can_open_timer()) {
-			return dahdi_timing_open(inode, file);
+			return dahdi_timing_open(file);
 		} else {
 			return -ENXIO;
 		}
 	}
 	if (unit == 254)
-		return dahdi_chan_open(inode, file);
+		return dahdi_chan_open(file);
 	if (unit == 255) {
 		chan = dahdi_alloc_pseudo();
 		if (chan) {
 			file->private_data = chan;
-			return dahdi_specchan_open(inode, file, chan->channo);
+			return dahdi_specchan_open(file, chan->channo);
 		} else {
 			return -ENXIO;
 		}
 	}
-	return dahdi_specchan_open(inode, file, unit);
+	return dahdi_specchan_open(file, unit);
 }
 
 #if 0
-static int dahdi_open(struct inode *inode, struct file *file)
+static int dahdi_open(struct file *file)
 {
 	int res;
 	unsigned long flags;
 	spin_lock_irqsave(&bigzaplock, flags);
-	res = __dahdi_open(inode, file);
+	res = __dahdi_open(file);
 	spin_unlock_irqrestore(&bigzaplock, flags);
 	return res;
 }
@@ -3359,9 +3373,9 @@
 	struct dahdi_chan *chan;
 
 	if (!unit)
-		return dahdi_ctl_release(inode, file);
+		return dahdi_ctl_release(file);
 	if (unit == 253) {
-		return dahdi_timer_release(inode, file);
+		return dahdi_timer_release(file);
 	}
 	if (unit == 250) {
 		/* We should not be here because the dahdi_transcode.ko module
@@ -3373,14 +3387,14 @@
 	if (unit == 254) {
 		chan = file->private_data;
 		if (!chan)
-			return dahdi_chan_release(inode, file);
+			return dahdi_chan_release(file);
 		else
-			return dahdi_specchan_release(inode, file, chan->channo);
+			return dahdi_specchan_release(file, chan->channo);
 	}
 	if (unit == 255) {
 		chan = file->private_data;
 		if (chan) {
-			res = dahdi_specchan_release(inode, file, chan->channo);
+			res = dahdi_specchan_release(file, chan->channo);
 			dahdi_free_pseudo(chan);
 		} else {
 			module_printk(KERN_NOTICE, "Pseudo release and no private data??\n");
@@ -3388,7 +3402,7 @@
 		}
 		return res;
 	}
-	return dahdi_specchan_release(inode, file, unit);
+	return dahdi_specchan_release(file, unit);
 }
 
 #if 0
@@ -3398,7 +3412,7 @@
 	unsigned long flags;
 	int res;
 	spin_lock_irqsave(&bigzaplock, flags);
-	res = __dahdi_release(inode, file);
+	res = __dahdi_release(file);
 	spin_unlock_irqrestore(&bigzaplock, flags);
 	return res;
 }
@@ -3484,7 +3498,7 @@
 		return -ENXIO; \
 } while(0)
 
-static int dahdi_timer_ioctl(struct inode *node, struct file *file, unsigned int cmd, unsigned long data, struct dahdi_timer *timer)
+static int dahdi_timer_ioctl(struct file *file, unsigned int cmd, unsigned long data, struct dahdi_timer *timer)
 {
 	int j;
 	unsigned long flags;
@@ -3533,7 +3547,7 @@
 	return 0;
 }
 
-static int dahdi_ioctl_getgains(struct inode *node, struct file *file,
+static int dahdi_ioctl_getgains(struct file *file,
 				unsigned int cmd, unsigned long data, int unit)
 {
 	int res = 0;
@@ -3578,7 +3592,7 @@
 	return res;
 }
 
-static int dahdi_ioctl_setgains(struct inode *node, struct file *file,
+static int dahdi_ioctl_setgains(struct file *file,
 				unsigned int cmd, unsigned long data, int unit)
 {
 	int res = 0;
@@ -3655,7 +3669,7 @@
 	return res;
 }
 
-static int dahdi_common_ioctl(struct inode *node, struct file *file, unsigned int cmd, unsigned long data, int unit)
+static int dahdi_common_ioctl(struct file *file, unsigned int cmd, unsigned long data, int unit)
 {
 	union {
 		struct dahdi_spaninfo spaninfo;
@@ -3788,9 +3802,9 @@
 		break;
 	case DAHDI_GETGAINS_V1: /* Intentional drop through. */
 	case DAHDI_GETGAINS:  /* get gain stuff */
-		return dahdi_ioctl_getgains(node, file, cmd, data, unit);
+		return dahdi_ioctl_getgains(file, cmd, data, unit);
 	case DAHDI_SETGAINS:  /* set gain stuff */
-		return dahdi_ioctl_setgains(node, file, cmd, data, unit);
+		return dahdi_ioctl_setgains(file, cmd, data, unit);
 	case DAHDI_SPANSTAT:
 		size_to_copy = sizeof(struct dahdi_spaninfo);
 		if (copy_from_user(&stack.spaninfo, (struct dahdi_spaninfo *) data, size_to_copy))
@@ -3955,7 +3969,7 @@
 #endif
 }
 
-static int dahdi_ctl_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long data)
+static int dahdi_ctl_ioctl(struct file *file, unsigned int cmd, unsigned long data)
 {
 	/* I/O CTL's for control interface */
 	int i,j;
@@ -3973,7 +3987,7 @@
 		if (copy_from_user(&ind, (struct dahdi_indirect_data *)data, sizeof(ind)))
 			return -EFAULT;
 		VALID_CHANNEL(ind.chan);
-		return dahdi_chan_ioctl(inode, file, ind.op, (unsigned long) ind.data, ind.chan);
+		return dahdi_chan_ioctl(file, ind.op, (unsigned long) ind.data, ind.chan);
 	}
 	case DAHDI_SPANCONFIG:
 	{
@@ -4449,7 +4463,7 @@
 		}
 		return -ENOSYS;
 	default:
-		return dahdi_common_ioctl(inode, file, cmd, data, 0);
+		return dahdi_common_ioctl(file, cmd, data, 0);
 	}
 	return 0;
 }
@@ -4511,7 +4525,7 @@
 	return rv;
 }
 
-static int dahdi_chanandpseudo_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long data, int unit)
+static int dahdi_chanandpseudo_ioctl(struct file *file, unsigned int cmd, unsigned long data, int unit)
 {
 	struct dahdi_chan *chan = chans[unit];
 	union {
@@ -4997,7 +5011,7 @@
 		break;
 	default:
 		/* Check for common ioctl's and private ones */
-		rv = dahdi_common_ioctl(inode, file, cmd, data, unit);
+		rv = dahdi_common_ioctl(file, cmd, data, unit);
 		/* if no span, just return with value */
 		if (!chan->span) return rv;
 		if ((rv == -ENOTTY) && chan->span->ioctl)
@@ -5203,7 +5217,7 @@
 	}
 }
 
-static int dahdi_chan_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long data, int unit)
+static int dahdi_chan_ioctl(struct file *file, unsigned int cmd, unsigned long data, int unit)
 {
 	struct dahdi_chan *chan = chans[unit];
 	unsigned long flags;
@@ -5291,6 +5305,10 @@
 				kfree(rxgain);
 			if (oldconf) dahdi_check_conf(oldconf);
 		}
+#ifdef	DAHDI_AUDIO_NOTIFY
+		if (chan->span->audio_notify)
+			chan->span->audio_notify(chan, j);
+#endif
 		break;
 	case DAHDI_HDLCPPP:
 #ifdef CONFIG_DAHDI_PPP
@@ -5578,12 +5596,12 @@
 		break;
 #endif
 	default:
-		return dahdi_chanandpseudo_ioctl(inode, file, cmd, data, unit);
+		return dahdi_chanandpseudo_ioctl(file, cmd, data, unit);
 	}
 	return 0;
 }
 
-static int dahdi_prechan_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long data, int unit)
+static int dahdi_prechan_ioctl(struct file *file, unsigned int cmd, unsigned long data, int unit)
 {
 	struct dahdi_chan *chan = file->private_data;
 	int channo;
@@ -5599,7 +5617,7 @@
 			return -EINVAL;
 		if (channo > DAHDI_MAX_CHANNELS)
 			return -EINVAL;
-		res = dahdi_specchan_open(inode, file, channo);
+		res = dahdi_specchan_open(file, channo);
 		if (!res) {
 			/* Setup the pointer for future stuff */
 			chan = chans[channo];
@@ -5614,47 +5632,80 @@
 	return 0;
 }
 
-static int dahdi_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long data)
+#ifdef HAVE_UNLOCKED_IOCTL
+static long dahdi_ioctl(struct file *file, unsigned int cmd, unsigned long data)
+#else
+static int dahdi_ioctl(struct inode *inode, struct file *file,
+		unsigned int cmd, unsigned long data)
+#endif
 {
 	int unit = UNIT(file);
 	struct dahdi_chan *chan;
 	struct dahdi_timer *timer;
-
-	if (!unit)
-		return dahdi_ctl_ioctl(inode, file, cmd, data);
+	int ret;
+
+#ifdef HAVE_UNLOCKED_IOCTL
+	lock_kernel();
+#endif
+
+	if (!unit) {
+		ret = dahdi_ctl_ioctl(file, cmd, data);
+		goto unlock_exit;
+	}
 
 	if (unit == 250) {
 		/* dahdi_transcode should have updated the file_operations on
 		 * this file object on open, so we shouldn't be here. */
 		WARN_ON(1);
-		return -EFAULT;
+		ret = -EFAULT;
+		goto unlock_exit;
 	}
 
 	if (unit == 253) {
 		timer = file->private_data;
 		if (timer)
-			return dahdi_timer_ioctl(inode, file, cmd, data, timer);
+			ret = dahdi_timer_ioctl(file, cmd, data, timer);
 		else
-			return -EINVAL;
+			ret = -EINVAL;
+		goto unlock_exit;
 	}
 	if (unit == 254) {
 		chan = file->private_data;
 		if (chan)
-			return dahdi_chan_ioctl(inode, file, cmd, data, chan->channo);
+			ret = dahdi_chan_ioctl(file, cmd, data, chan->channo);
 		else
-			return dahdi_prechan_ioctl(inode, file, cmd, data, unit);
+			ret = dahdi_prechan_ioctl(file, cmd, data, unit);
+		goto unlock_exit;
 	}
 	if (unit == 255) {
 		chan = file->private_data;
 		if (!chan) {
 			module_printk(KERN_NOTICE, "No pseudo channel structure to read?\n");
-			return -EINVAL;
-		}
-		return dahdi_chanandpseudo_ioctl(inode, file, cmd, data, chan->channo);
-	}
-	return dahdi_chan_ioctl(inode, file, cmd, data, unit);
-}
-
+			ret = -EINVAL;
+			goto unlock_exit;
+		}
+		ret = dahdi_chanandpseudo_ioctl(file, cmd, data, chan->channo);
+		goto unlock_exit;
+	}
+	ret = dahdi_chan_ioctl(file, cmd, data, unit);
+
+unlock_exit:
+#ifdef HAVE_UNLOCKED_IOCTL
+	unlock_kernel();
+#endif
+	return ret;
+}
+
+#ifdef HAVE_COMPAT_IOCTL
+static long dahdi_ioctl_compat(struct file *file, unsigned int cmd,
+		unsigned long data)
+{
+	if (cmd == DAHDI_SFCONFIG)
+		return -ENOTTY; /* Not supported yet */
+
+	return dahdi_ioctl(file, cmd, data);
+}
+#endif
 
 /**
  * dahdi_register() - unregister a new DAHDI span
@@ -6877,7 +6928,7 @@
 						ss->ec_state->status.mode = ECHO_MODE_STARTTRAINING;
 					}
 				}
-				if ((ss->ec_state->status.mode == ECHO_MODE_AWAITINGECHO) && (txlin > 8000)) {
+				if (ss->ec_state->status.mode == ECHO_MODE_AWAITINGECHO) {
 					ss->ec_state->status.last_train_tap = 0;
 					ss->ec_state->status.mode = ECHO_MODE_TRAINING;
 				}
@@ -8320,17 +8371,20 @@
 
 static struct file_operations dahdi_fops = {
 	.owner   = THIS_MODULE,
-	.llseek  = NULL,
 	.open    = dahdi_open,
 	.release = dahdi_release,
+#ifdef HAVE_UNLOCKED_IOCTL
+	.unlocked_ioctl  = dahdi_ioctl,
+#ifdef HAVE_COMPAT_IOCTL
+	.compat_ioctl = dahdi_ioctl_compat,
+#endif
+#else
 	.ioctl   = dahdi_ioctl,
+#endif
 	.read    = dahdi_read,
 	.write   = dahdi_write,
 	.poll    = dahdi_poll,
 	.mmap    = dahdi_mmap,
-	.flush   = NULL,
-	.fsync   = NULL,
-	.fasync  = NULL,
 };
 
 #ifdef CONFIG_DAHDI_WATCHDOG

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/firmware/Makefile
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/firmware/Makefile?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/firmware/Makefile (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/firmware/Makefile Wed Jan  6 15:22:21 2010
@@ -7,8 +7,17 @@
 #
 # Joshua Colp <jcolp at digium.com>
 #
+#
+# See http://www.asterisk.org for more information about
+# the Asterisk project. Please do not directly contact
+# any of the maintainers of this project for assistance;
+# the project provides a web site, mailing lists and IRC
+# channels for your use.
+#
 # This program is free software, distributed under the terms of
-# the GNU General Public License
+# the GNU General Public License Version 2 as published by the
+# Free Software Foundation. See the LICENSE file included with
+# this program for more details.
 #
 
 .PHONY: dist-clean clean all uninstall have_download install object-build hotplug-install hotplug-dirs hotplug-uninstall make_firmware_object firmware-loaders

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/voicebus/voicebus.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/voicebus/voicebus.c?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/voicebus/voicebus.c (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/voicebus/voicebus.c Wed Jan  6 15:22:21 2010
@@ -1733,7 +1733,7 @@
 	 * this driver. */
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 23)
 	vb->buffer_cache = kmem_cache_create(board_name, vb->framesize, 0,
-#if LINUX_VERSION_CODE == KERNEL_VERSION(2, 6, 22)
+#if defined(CONFIG_SLUB) && (LINUX_VERSION_CODE == KERNEL_VERSION(2, 6, 22))
 				SLAB_HWCACHE_ALIGN | SLAB_STORE_USER, NULL, NULL);
 #else
 				SLAB_HWCACHE_ALIGN, NULL, NULL);

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcb4xxp/base.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcb4xxp/base.c?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcb4xxp/base.c (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcb4xxp/base.c Wed Jan  6 15:22:21 2010
@@ -20,7 +20,6 @@
  * this program for more details.
  */
 
-#include <linux/autoconf.h>
 #include <linux/init.h>
 
 #include <linux/kernel.h>	/* printk() */

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wct4xxp/vpm450m.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wct4xxp/vpm450m.c?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wct4xxp/vpm450m.c (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wct4xxp/vpm450m.c Wed Jan  6 15:22:21 2010
@@ -30,8 +30,6 @@
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18)
 #include <linux/config.h>
-#else
-#include <linux/autoconf.h>
 #endif
 
 /* API for Octasic access */

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcte12xp/base.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcte12xp/base.c?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcte12xp/base.c (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/wcte12xp/base.c Wed Jan  6 15:22:21 2010
@@ -1883,7 +1883,7 @@
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 23)
 	cmd_cache = kmem_cache_create(THIS_MODULE->name, sizeof(struct command), 0,
-#if LINUX_VERSION_CODE == KERNEL_VERSION(2, 6, 22)
+#if defined(CONFIG_SLUB) && (LINUX_VERSION_CODE == KERNEL_VERSION(2, 6, 22))
 				SLAB_HWCACHE_ALIGN | SLAB_STORE_USER, NULL, NULL);
 #else
 				SLAB_HWCACHE_ALIGN, NULL, NULL);

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_fxo.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_fxo.c?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_fxo.c (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_fxo.c Wed Jan  6 15:22:21 2010
@@ -170,7 +170,7 @@
 static const char *power2str(enum power_state pw)
 {
 	switch(pw) {
-		case POWER_UNKNOWN:	return "UNKOWN";
+		case POWER_UNKNOWN:	return "UNKNOWN";
 		case POWER_OFF:		return "OFF";
 		case POWER_ON:		return "ON";
 	}

Modified: linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_pri.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_pri.c?view=diff&rev=7775&r1=7774&r2=7775
==============================================================================
--- linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_pri.c (original)
+++ linux/team/mspiceland/dahdi-qfalc31/drivers/dahdi/xpp/card_pri.c Wed Jan  6 15:22:21 2010
@@ -551,25 +551,44 @@
 	return 1;
 }
 
-static void pri_pcm_update(xpd_t *xpd)
-{
-	struct PRI_priv_data	*priv;
-	int			channels = xpd->channels;
-	xpp_line_t		mask = BITMASK(xpd->channels);
+static void PRI_card_pcm_recompute(xbus_t *xbus, xpd_t *xpd,
+		xpp_line_t pcm_mask)
+{
+	struct PRI_priv_data	*priv;
+	int			i;
+	int			line_count = 0;
+	unsigned long		flags;
 	uint			pcm_len;
-	unsigned long		flags;
-
-	priv = xpd->priv;
+
+	BUG_ON(!xpd);
+	priv = xpd->priv;
+	spin_lock_irqsave(&xpd->lock_recompute_pcm, flags);
+	//XPD_DBG(SIGNAL, xpd, "pcm_mask=0x%X\n", pcm_mask);
+	/* Add/remove all the trivial cases */
+	pcm_mask |= xpd->offhook_state;
+	for_each_line(xpd, i)
+		if (IS_SET(pcm_mask, i))
+			line_count++;
 	if(priv->is_cas) {
 		if(priv->pri_protocol == PRI_PROTO_E1) {
 			/* CAS: Don't send PCM to D-Channel */
-			channels--;
-			mask &= ~BIT(PRI_DCHAN_IDX(priv));
-		}
-	}
-	pcm_len = RPACKET_HEADERSIZE + sizeof(xpp_line_t)  +  channels * DAHDI_CHUNKSIZE;
-	spin_lock_irqsave(&xpd->lock_recompute_pcm, flags);
-	update_wanted_pcm_mask(xpd, mask, pcm_len);
+			line_count--;
+			pcm_mask &= ~BIT(PRI_DCHAN_IDX(priv));
+		}
+	}
+	/*
+	 * FIXME: Workaround a bug in sync code of the Astribank.
+	 *        Send dummy PCM for sync.
+	 */
+	if (xpd->addr.unit == 0 && pcm_mask == 0) {
+		pcm_mask = BIT(0);
+		line_count = 1;
+	}
+	pcm_len = (line_count)
+		? RPACKET_HEADERSIZE + sizeof(xpp_line_t) +
+			line_count * DAHDI_CHUNKSIZE
+		: 0L;
+	update_wanted_pcm_mask(xpd, pcm_mask, pcm_len);
 	spin_unlock_irqrestore(&xpd->lock_recompute_pcm, flags);
 }
 
@@ -631,7 +650,8 @@
 	priv->pri_protocol = set_proto;
 	priv->is_cas = -1;
 	xpd->channels = pri_num_channels(set_proto);
-	pri_pcm_update(xpd);
+	xpd->offhook_state = BITMASK(xpd->channels);
+	CALL_XMETHOD(card_pcm_recompute, xpd->xbus, xpd, 0);
 	priv->deflaw = deflaw;
 	priv->dchan_num = dchan_num;
 	priv->local_loopback = 0;
@@ -1016,7 +1036,7 @@
 		force_cas = 1;
 		set_mode_cas(xpd, 1);
 	}
-	pri_pcm_update(xpd);
+	CALL_XMETHOD(card_pcm_recompute, xpd->xbus, xpd, 0);
 	/*
 	 * E1's can enable CRC checking
 	 * CRC4 is legal only for E1, and it is checked by pri_linecompat()
@@ -1238,6 +1258,19 @@
 	return 0;
 }
 
+#ifdef	DAHDI_AUDIO_NOTIFY
+static int pri_audio_notify(struct dahdi_chan *chan, int on)
+{
+	xpd_t		*xpd = chan->pvt;
+	int		pos = chan->chanpos - 1;
+
+	BUG_ON(!xpd);
+	LINE_DBG(SIGNAL, xpd, pos, "PRI-AUDIO: %s\n", (on) ? "on" : "off");
+	mark_offhook(xpd, pos, on);
+	return 0;
+}
+#endif
+
 static int PRI_card_dahdi_preregistration(xpd_t *xpd, bool on)
 {
 	xbus_t			*xbus;
@@ -1279,12 +1312,14 @@
 	}
 	if(!priv->is_cas)
 		clear_bit(DAHDI_FLAGBIT_RBS, &xpd->span.flags);
-	xpd->offhook_state = xpd->wanted_pcm_mask;
 	xpd->span.spanconfig = pri_spanconfig;
 	xpd->span.chanconfig = pri_chanconfig;

[... 150 lines stripped ...]



More information about the dahdi-commits mailing list