{
struct edgeport_port *edge_port = usb_get_serial_port_data(port);
unsigned int mcr;
+ unsigned long flags;
dbg("%s - port %d", __FUNCTION__, port->number);
+ spin_lock_irqsave(&edge_port->ep_lock, flags);
mcr = edge_port->shadow_mcr;
if (set & TIOCM_RTS)
mcr |= MCR_RTS;
mcr &= ~MCR_LOOPBACK;
edge_port->shadow_mcr = mcr;
+ spin_unlock_irqrestore(&edge_port->ep_lock, flags);
TIRestoreMCR (edge_port, mcr);
unsigned int result = 0;
unsigned int msr;
unsigned int mcr;
+ unsigned long flags;
dbg("%s - port %d", __FUNCTION__, port->number);
+ spin_lock_irqsave(&edge_port->ep_lock, flags);
+
msr = edge_port->shadow_msr;
mcr = edge_port->shadow_mcr;
result = ((mcr & MCR_DTR) ? TIOCM_DTR: 0) /* 0x002 */
dbg("%s -- %x", __FUNCTION__, result);
+ spin_unlock_irqrestore(&edge_port->ep_lock, flags);
return result;
}