Lines Matching refs:port

87 static int  whiteheat_port_probe(struct usb_serial_port *port);
88 static int whiteheat_port_remove(struct usb_serial_port *port);
90 struct usb_serial_port *port);
91 static void whiteheat_close(struct usb_serial_port *port);
95 struct usb_serial_port *port, struct ktermios *old);
162 static int firm_send_command(struct usb_serial_port *port, __u8 command,
164 static int firm_open(struct usb_serial_port *port);
165 static int firm_close(struct usb_serial_port *port);
167 static int firm_set_rts(struct usb_serial_port *port, __u8 onoff);
168 static int firm_set_dtr(struct usb_serial_port *port, __u8 onoff);
169 static int firm_set_break(struct usb_serial_port *port, __u8 onoff);
170 static int firm_purge(struct usb_serial_port *port, __u8 rxtx);
171 static int firm_get_dtr_rts(struct usb_serial_port *port);
172 static int firm_report_tx_done(struct usb_serial_port *port);
262 command_port = serial->port[COMMAND_PORT]; in whiteheat_attach()
363 command_port = serial->port[COMMAND_PORT]; in whiteheat_release()
367 static int whiteheat_port_probe(struct usb_serial_port *port) in whiteheat_port_probe() argument
375 usb_set_serial_port_data(port, info); in whiteheat_port_probe()
380 static int whiteheat_port_remove(struct usb_serial_port *port) in whiteheat_port_remove() argument
384 info = usb_get_serial_port_data(port); in whiteheat_port_remove()
390 static int whiteheat_open(struct tty_struct *tty, struct usb_serial_port *port) in whiteheat_open() argument
394 retval = start_command_port(port->serial); in whiteheat_open()
399 retval = firm_open(port); in whiteheat_open()
401 stop_command_port(port->serial); in whiteheat_open()
405 retval = firm_purge(port, WHITEHEAT_PURGE_RX | WHITEHEAT_PURGE_TX); in whiteheat_open()
407 firm_close(port); in whiteheat_open()
408 stop_command_port(port->serial); in whiteheat_open()
416 usb_clear_halt(port->serial->dev, port->read_urb->pipe); in whiteheat_open()
417 usb_clear_halt(port->serial->dev, port->write_urb->pipe); in whiteheat_open()
419 retval = usb_serial_generic_open(tty, port); in whiteheat_open()
421 firm_close(port); in whiteheat_open()
422 stop_command_port(port->serial); in whiteheat_open()
430 static void whiteheat_close(struct usb_serial_port *port) in whiteheat_close() argument
432 firm_report_tx_done(port); in whiteheat_close()
433 firm_close(port); in whiteheat_close()
435 usb_serial_generic_close(port); in whiteheat_close()
437 stop_command_port(port->serial); in whiteheat_close()
442 struct usb_serial_port *port = tty->driver_data; in whiteheat_tiocmget() local
443 struct whiteheat_private *info = usb_get_serial_port_data(port); in whiteheat_tiocmget()
446 firm_get_dtr_rts(port); in whiteheat_tiocmget()
458 struct usb_serial_port *port = tty->driver_data; in whiteheat_tiocmset() local
459 struct whiteheat_private *info = usb_get_serial_port_data(port); in whiteheat_tiocmset()
471 firm_set_dtr(port, info->mcr & UART_MCR_DTR); in whiteheat_tiocmset()
472 firm_set_rts(port, info->mcr & UART_MCR_RTS); in whiteheat_tiocmset()
480 struct usb_serial_port *port = tty->driver_data; in whiteheat_ioctl() local
488 serstruct.line = port->minor; in whiteheat_ioctl()
489 serstruct.port = port->port_number; in whiteheat_ioctl()
491 serstruct.xmit_fifo_size = kfifo_size(&port->write_fifo); in whiteheat_ioctl()
509 struct usb_serial_port *port, struct ktermios *old_termios) in whiteheat_set_termios() argument
516 struct usb_serial_port *port = tty->driver_data; in whiteheat_break_ctl() local
517 firm_set_break(port, break_state); in whiteheat_break_ctl()
592 static int firm_send_command(struct usb_serial_port *port, __u8 command, in firm_send_command() argument
598 struct device *dev = &port->dev; in firm_send_command()
605 command_port = port->serial->port[COMMAND_PORT]; in firm_send_command()
642 info = usb_get_serial_port_data(port); in firm_send_command()
654 static int firm_open(struct usb_serial_port *port) in firm_open() argument
658 open_command.port = port->port_number + 1; in firm_open()
659 return firm_send_command(port, WHITEHEAT_OPEN, in firm_open()
664 static int firm_close(struct usb_serial_port *port) in firm_close() argument
668 close_command.port = port->port_number + 1; in firm_close()
669 return firm_send_command(port, WHITEHEAT_CLOSE, in firm_close()
676 struct usb_serial_port *port = tty->driver_data; in firm_setup_port() local
677 struct device *dev = &port->dev; in firm_setup_port()
681 port_settings.port = port->port_number + 1; in firm_setup_port()
749 firm_send_command(port, WHITEHEAT_SETUP_PORT, in firm_setup_port()
754 static int firm_set_rts(struct usb_serial_port *port, __u8 onoff) in firm_set_rts() argument
758 rts_command.port = port->port_number + 1; in firm_set_rts()
760 return firm_send_command(port, WHITEHEAT_SET_RTS, in firm_set_rts()
765 static int firm_set_dtr(struct usb_serial_port *port, __u8 onoff) in firm_set_dtr() argument
769 dtr_command.port = port->port_number + 1; in firm_set_dtr()
771 return firm_send_command(port, WHITEHEAT_SET_DTR, in firm_set_dtr()
776 static int firm_set_break(struct usb_serial_port *port, __u8 onoff) in firm_set_break() argument
780 break_command.port = port->port_number + 1; in firm_set_break()
782 return firm_send_command(port, WHITEHEAT_SET_BREAK, in firm_set_break()
787 static int firm_purge(struct usb_serial_port *port, __u8 rxtx) in firm_purge() argument
791 purge_command.port = port->port_number + 1; in firm_purge()
793 return firm_send_command(port, WHITEHEAT_PURGE, in firm_purge()
798 static int firm_get_dtr_rts(struct usb_serial_port *port) in firm_get_dtr_rts() argument
802 get_dr_command.port = port->port_number + 1; in firm_get_dtr_rts()
803 return firm_send_command(port, WHITEHEAT_GET_DTR_RTS, in firm_get_dtr_rts()
808 static int firm_report_tx_done(struct usb_serial_port *port) in firm_report_tx_done() argument
812 close_command.port = port->port_number + 1; in firm_report_tx_done()
813 return firm_send_command(port, WHITEHEAT_REPORT_TX_DONE, in firm_report_tx_done()
827 command_port = serial->port[COMMAND_PORT]; in start_command_port()
855 command_port = serial->port[COMMAND_PORT]; in stop_command_port()