wctdm24xxp: Do not read extra register when test for FXO module fails.

In commit r9968 "wctdm24xxp: Allow more than one outstanding read at a
time" I introduced a regression where the transmit FIFO on the data
channel of a B400M could get locked up. The result would be constant
HDLC overflows when writing to the data channel.

This regression did not make it into any releases and did not exhibit
itself when crossing spans on a single B400M module. This is a partial
revert of commit r9968.

Signed-off-by: Shaun Ruffell <sruffell@digium.com>

git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9977 a0bf4364-ded3-4de4-8d8a-66a801d63aff
This commit is contained in:
Shaun Ruffell
2011-06-11 01:58:43 +00:00
parent fb942bbd11
commit 90e504dc25

View File

@@ -2233,13 +2233,14 @@ static void handle_hx8_transmit(struct voicebus *vb, struct list_head *buffers)
static int wctdm_voicedaa_insane(struct wctdm *wc, struct wctdm_module *mod)
{
int blah[] = {2, 11};
wctdm_getregs(wc, mod, blah, ARRAY_SIZE(blah));
if (blah[0] != 0x3)
int blah;
blah = wctdm_getreg(wc, mod, 2);
if (blah != 0x3)
return -2;
blah = wctdm_getreg(wc, mod, 11);
if (debug & DEBUG_CARD) {
dev_info(&wc->vb.pdev->dev,
"VoiceDAA System: %02x\n", blah[1] & 0xf);
"VoiceDAA System: %02x\n", blah & 0xf);
}
return 0;
}