[dahdi-commits] dahdi/linux.git branch "master" updated.

SVN commits to the DAHDI project dahdi-commits at lists.digium.com
Mon Dec 2 15:51:40 CST 2013


branch "master" has been updated
       via  f5d3b35d7bd8cad3b01eefeb1e46252cd19c072f (commit)
       via  6bcc70a421ab521231eeb35dbac0c32b95233e92 (commit)
       via  d389f9f74391fa6d4f982a4aba8d96b23300ebfd (commit)
       via  0faac26dded4e70830ab9a99ea26efa6cc6d4e66 (commit)
      from  d803fad133e882e29bc2069bde906f081ed8e34b (commit)

Summary of changes:
 drivers/dahdi/dahdi-sysfs.c     |   14 +++++++++++++-
 drivers/dahdi/firmware/Makefile |    2 +-
 drivers/dahdi/wcaxx-base.c      |    4 ++++
 drivers/dahdi/wcte43x-base.c    |    2 +-
 drivers/dahdi/wcxb_spi.c        |    8 ++++++--
 5 files changed, 25 insertions(+), 5 deletions(-)


- Log -----------------------------------------------------------------
commit f5d3b35d7bd8cad3b01eefeb1e46252cd19c072f
Author: Shaun Ruffell <sruffell at digium.com>
Date:   Sun Dec 1 23:10:15 2013 -0600

    dahdi: Replace drv_attr with drv_groups on kernels > 3.12.
    
    drv_attrs was fully removed from the bus structure in upstream commit
    e18945b159a1cdbc031f1d3b0b7e515a33bdcbf7 which was merged into 3.13.
    
    This is necessary to compile dahdi against linux version 3.13.
    
    Signed-off-by: Shaun Ruffell <sruffell at digium.com>

diff --git a/drivers/dahdi/dahdi-sysfs.c b/drivers/dahdi/dahdi-sysfs.c
index 9583e63..322a496 100644
--- a/drivers/dahdi/dahdi-sysfs.c
+++ b/drivers/dahdi/dahdi-sysfs.c
@@ -251,19 +251,31 @@ static ssize_t master_span_store(struct device_driver *driver, const char *buf,
 	return count;
 }
 
-
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
 static struct driver_attribute dahdi_attrs[] = {
 	__ATTR(master_span, S_IRUGO | S_IWUSR, master_span_show,
 			master_span_store),
 	__ATTR_NULL,
 };
+#else
+static DRIVER_ATTR_RW(master_span);
+static struct attribute *dahdi_attrs[] = {
+	&driver_attr_master_span.attr,
+	NULL,
+};
+ATTRIBUTE_GROUPS(dahdi);
+#endif
 
 static struct bus_type spans_bus_type = {
 	.name           = "dahdi_spans",
 	.match          = span_match,
 	.uevent         = span_uevent,
 	.dev_attrs	= span_dev_attrs,
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
 	.drv_attrs	= dahdi_attrs,
+#else
+	.drv_groups 	= dahdi_groups,
+#endif
 };
 
 static int span_probe(struct device *dev)

commit 6bcc70a421ab521231eeb35dbac0c32b95233e92
Author: Shaun Ruffell <sruffell at digium.com>
Date:   Mon Dec 2 14:55:12 2013 -0600

    wcte43x: Update firmware to version e0017.
    
    This resolves issues where, when using internal timing, the first channel of
    span 3 has occassional corrupted data in transmit stream.
    
    Signed-off-by: Shaun Ruffell <sruffell at digium.com>

diff --git a/drivers/dahdi/firmware/Makefile b/drivers/dahdi/firmware/Makefile
index 06385dd..e2d7ca6 100644
--- a/drivers/dahdi/firmware/Makefile
+++ b/drivers/dahdi/firmware/Makefile
@@ -33,7 +33,7 @@ VPMOCT032_VERSION:=1.12.0
 WCT820_VERSION:=1.76
 TE133_VERSION:=6f0017
 TE134_VERSION:=6f0017
-TE435_VERSION:=d0017
+TE435_VERSION:=e0017
 A8A_VERSION:=1d0017
 A8B_VERSION:=1d0017
 A4A_VERSION:=a0017
diff --git a/drivers/dahdi/wcte43x-base.c b/drivers/dahdi/wcte43x-base.c
index 55d1803..6752d5d 100644
--- a/drivers/dahdi/wcte43x-base.c
+++ b/drivers/dahdi/wcte43x-base.c
@@ -52,7 +52,7 @@
 #include "wcxb_flash.h"
 
 static const char *TE435_FW_FILENAME = "dahdi-fw-te435.bin";
-static const u32 TE435_VERSION = 0xd0017;
+static const u32 TE435_VERSION = 0xe0017;
 
 /* #define RPC_RCLK */
 #define VPM_SUPPORT

commit d389f9f74391fa6d4f982a4aba8d96b23300ebfd
Author: Shaun Ruffell <sruffell at digium.com>
Date:   Mon Dec 2 14:43:46 2013 -0600

    wcaxx: Add extra dummy read when checking for single fxs modules.
    
    This extra read eliminates some problems with detecting certain S100M modules.
    It is unclear at this time why it is necessary.
    
    Signed-off-by: Shaun Ruffell <sruffell at digium.com>

diff --git a/drivers/dahdi/wcaxx-base.c b/drivers/dahdi/wcaxx-base.c
index 97bd00b..6fe67ce 100644
--- a/drivers/dahdi/wcaxx-base.c
+++ b/drivers/dahdi/wcaxx-base.c
@@ -3610,6 +3610,10 @@ static bool check_for_single_fxs(struct wcaxx *wc, unsigned int port)
 	result = wcaxx_init_fxs_port(wc, mod);
 	if (!result)
 		mod->type = NONE;
+
+	/* It is currently unclear why this read is necessary for some of the
+	 * S100M modules to properly function. */
+	wcaxx_getreg(wc, mod, 0x00);
 	return result;
 }
 

commit 0faac26dded4e70830ab9a99ea26efa6cc6d4e66
Author: Shaun Ruffell <sruffell at digium.com>
Date:   Mon Dec 2 13:36:59 2013 -0600

    wcxb: Do not access cur_transfer/cur_msg outside of lock.
    
    The spi master cur_transfer and cur_msg should only be changed under the
    spin_lock for the master. The result is that if running user space tools, like
    fxstest, that check registers on the modules, it's possible to have a message
    that was not yet complete flagged as completed which would result in a bad read.
    
    This does not affect "normal" operation of the wcaxx driver since interrupts are
    not enabled during module detection, and during normal operation all access to
    the resgisters is done in the context of the interrupt handler. This would only
    be an issue if the interrupt handler was running and register accesses are tried
    in user space context on an SMP system.
    
    Signed-off-by: Shaun Ruffell <sruffell at digium.com>

diff --git a/drivers/dahdi/wcxb_spi.c b/drivers/dahdi/wcxb_spi.c
index aad262e..d7313c6 100644
--- a/drivers/dahdi/wcxb_spi.c
+++ b/drivers/dahdi/wcxb_spi.c
@@ -291,14 +291,18 @@ _wcxb_spi_next_transfer(struct wcxb_spi_transfer *t)
  */
 void wcxb_spi_handle_interrupt(struct wcxb_spi_master *master)
 {
-	struct wcxb_spi_message *msg = master->cur_msg;
-	struct wcxb_spi_transfer *t = master->cur_transfer;
+	struct wcxb_spi_message *msg;
+	struct wcxb_spi_transfer *t;
 	void (*complete)(void *arg) = NULL;
 	unsigned long flags;
 
 	/* Check if we're not in the middle of a transfer, or not finished with
 	 * a part of one. */
 	spin_lock_irqsave(&master->lock, flags);
+
+	t = master->cur_transfer;
+	msg = master->cur_msg;
+
 	if (!msg || !is_txfifo_empty(master))
 		goto done;
 

-----------------------------------------------------------------------


-- 
dahdi/linux.git



More information about the dahdi-commits mailing list