usb_clear_halt(serial->dev, port->read_urb->pipe);
port0->open_ports++;
- result = qt_get_device(serial, &port0->DeviceData);
+ result = qt_get_device(serial, &port0->device_data);
/* Port specific setups */
- result = qt_open_channel(serial, port->port_number, &ChannelData);
- result = qt_open_channel(serial, port->number, &channel_data);
++ result = qt_open_channel(serial, port->port_number, &channel_data);
if (result < 0) {
dev_dbg(&port->dev, "qt_open_channel failed\n");
return result;
/* Now determine flow control */
if (cflag & CRTSCTS) {
- dev_dbg(&port->dev, "%s - Enabling HW flow control port %d\n",
- __func__, port->number);
+ dev_dbg(&port->dev, "%s - Enabling HW flow control\n", __func__);
/* Enable RTS/CTS flow control */
- status = BoxSetHW_FlowCtrl(port->serial, index, 1);
+ status = box_set_hw_flow_ctrl(port->serial, index, 1);
if (status < 0) {
- dev_dbg(&port->dev, "BoxSetHW_FlowCtrl failed\n");
+ dev_dbg(&port->dev, "box_set_hw_flow_ctrl failed\n");
return;
}
} else {
/* Disable RTS/CTS flow control */
dev_dbg(&port->dev,
- "%s - disabling HW flow control port %d\n",
- __func__, port->number);
+ "%s - disabling HW flow control\n", __func__);
- status = BoxSetHW_FlowCtrl(port->serial, index, 0);
+ status = box_set_hw_flow_ctrl(port->serial, index, 0);
if (status < 0) {
- dev_dbg(&port->dev, "BoxSetHW_FlowCtrl failed\n");
+ dev_dbg(&port->dev, "box_set_hw_flow_ctrl failed\n");
return;
}
int status;
unsigned int index;
- index = tty->index - serial->minor;
+ index = port->port_number;
status =
- BoxGetRegister(port->serial, index, MODEM_CONTROL_REGISTER, &mcr);
+ box_get_register(port->serial, index, MODEM_CONTROL_REGISTER, &mcr);
if (status >= 0) {
status =
- BoxGetRegister(port->serial, index,
+ box_get_register(port->serial, index,
MODEM_STATUS_REGISTER, &msr);
}
int status;
unsigned int index;
- index = tty->index - serial->minor;
+ index = port->port_number;
status =
- BoxGetRegister(port->serial, index, MODEM_CONTROL_REGISTER, &mcr);
+ box_get_register(port->serial, index, MODEM_CONTROL_REGISTER, &mcr);
if (status < 0)
return -ESPIPE;