summaryrefslogtreecommitdiff
path: root/xhfc/base.c
diff options
context:
space:
mode:
Diffstat (limited to 'xhfc/base.c')
-rw-r--r--xhfc/base.c37
1 files changed, 30 insertions, 7 deletions
diff --git a/xhfc/base.c b/xhfc/base.c
index 900d78b..e3d10b9 100644
--- a/xhfc/base.c
+++ b/xhfc/base.c
@@ -784,23 +784,46 @@ static inline u8 byte_replace_bit(u8 byte, int nr, bool value)
static void configure_ntte(struct xhfc_span *xhfc_span, int nt)
{
struct xhfc *xhfc = xhfc_span->xhfc;
- u8 newb;
- newb = byte_replace_bit(xhfc->pi->soft_conf_byte,
+ u8 soft_conf = xhfc->pi->soft_conf_byte;
+
+ if (DBG_REGS)
+ printk(KERN_INFO "NTTE %d %d before %02x\n",
+ xhfc_span->port, nt,
+ soft_conf);
+
+ soft_conf = byte_replace_bit(soft_conf,
lebcs1_bit_nt(xhfc_span->port),
!!nt);
- xhfc->pi->soft_conf_byte = newb;
- write_xhfc_soft_conf(xhfc, newb);
+
+ xhfc->pi->soft_conf_byte = soft_conf;
+ write_xhfc_soft_conf(xhfc, soft_conf);
+
+ if (DBG_REGS)
+ printk(KERN_INFO "NTTE %d %d after %02x\n",
+ xhfc_span->port, nt,
+ soft_conf);
}
static void configure_term(struct xhfc_span *xhfc_span, int lineterm)
{
struct xhfc *xhfc = xhfc_span->xhfc;
- u8 newb;
- newb = byte_replace_bit(xhfc->pi->soft_conf_byte,
+ u8 soft_conf = xhfc->pi->soft_conf_byte;
+
+ if (DBG_REGS)
+ printk(KERN_INFO "TERM %d %d before %02x\n",
+ xhfc_span->port, lineterm,
+ soft_conf);
+
+ soft_conf = byte_replace_bit(xhfc->pi->soft_conf_byte,
lebcs1_bit_term(xhfc_span->port),
!!lineterm);
- xhfc->pi->soft_conf_byte = newb;
+ xhfc->pi->soft_conf_byte = soft_conf;
write_xhfc_soft_conf(xhfc, xhfc->pi->soft_conf_byte);
+
+ if (DBG_REGS)
+ printk(KERN_INFO "TERM %d %d after %02x\n",
+ xhfc_span->port, lineterm,
+ soft_conf);
}
static void __devinit