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

SVN commits to the DAHDI project dahdi-commits at lists.digium.com
Fri Dec 20 14:24:38 CST 2013


branch "2.7.y" has been updated
       via  71cc29a7fd68b2eff1d99e8958a08b1720a2fe11 (commit)
      from  c1d867b8b751cd2a68575ce35d32e78fdf113933 (commit)

Summary of changes:
 drivers/dahdi/wctdm24xxp/base.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)


- Log -----------------------------------------------------------------
commit 71cc29a7fd68b2eff1d99e8958a08b1720a2fe11
Author: Shaun Ruffell <sruffell at digium.com>
Date:   Fri Dec 20 13:54:19 2013 -0600

    wctdm24xxp: Reset module specific type information on probe.
    
    This fixes an issue that affects TDM410 modules when there is not a module
    installed in the first port, but there is an FXO module installed in the third
    port.
    
    When scaning for QRV modules in the first port, the 3rd port will have the
    'hook' struct.qrv set to 0xff. When a QRV module is  not detected, that value
    will be left, which then maps to an invalid state for both fxo.ring_state and
    fxo.battery_state.
    
    The result would be that FXO ports would fail to run the ring detector state
    machine since it did not know what the current state was.
    
    Now we'll just reset all the values in struct fxo or struct fxs to the expected
    init state.
    
    Internal-Issue-ID: DAHLIN-332
    Signed-off-by: Shaun Ruffell <sruffell at digium.com>
    (cherry picked from commit 3933ffd3505374ce8850fee067ad3949dc552d49)

diff --git a/drivers/dahdi/wctdm24xxp/base.c b/drivers/dahdi/wctdm24xxp/base.c
index 20e417d..59ecdf0 100644
--- a/drivers/dahdi/wctdm24xxp/base.c
+++ b/drivers/dahdi/wctdm24xxp/base.c
@@ -3100,6 +3100,8 @@ wctdm_init_voicedaa(struct wctdm *wc, struct wctdm_module *mod,
 	spin_unlock_irqrestore(&wc->reglock, flags);
 	msleep(20);
 
+	memset(&mod->mod.fxo, 0, sizeof(mod->mod.fxo));
+
 	if (!sane && wctdm_voicedaa_insane(wc, mod))
 		return -2;
 
@@ -3244,8 +3246,7 @@ wctdm_init_proslic(struct wctdm *wc, struct wctdm_module *const mod,
 		return -2;
 
 	/* Initialize VMWI settings */
-	memset(&(fxs->vmwisetting), 0, sizeof(fxs->vmwisetting));
-	fxs->vmwi_linereverse = 0;
+	memset(fxs, 0, sizeof(*fxs));
 
 	/* By default, don't send on hook */
 	if (!reversepolarity != !fxs->reversepolarity)

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


-- 
dahdi/linux.git



More information about the dahdi-commits mailing list