Lines Matching refs:port_priv
641 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_read_reg_block() local
647 port_priv->bInterfaceNumber, buf, bufsize, in cp210x_read_reg_block()
695 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_write_u16_reg() local
700 port_priv->bInterfaceNumber, NULL, 0, in cp210x_write_u16_reg()
718 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_write_reg_block() local
723 port_priv->bInterfaceNumber, buf, bufsize, in cp210x_write_reg_block()
772 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_open() local
792 port_priv->event_mode = false; in cp210x_open()
799 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_close() local
809 port_priv->event_mode = false; in cp210x_close()
833 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_process_char() local
835 switch (port_priv->event_state) { in cp210x_process_char()
838 port_priv->event_state = ES_ESCAPE; in cp210x_process_char()
847 port_priv->event_state = ES_DATA; in cp210x_process_char()
850 port_priv->event_state = ES_LSR_DATA_0; in cp210x_process_char()
853 port_priv->event_state = ES_LSR; in cp210x_process_char()
856 port_priv->event_state = ES_MSR; in cp210x_process_char()
860 port_priv->event_state = ES_DATA; in cp210x_process_char()
865 port_priv->lsr = *ch; in cp210x_process_char()
866 port_priv->event_state = ES_LSR_DATA_1; in cp210x_process_char()
870 __func__, port_priv->lsr, *ch); in cp210x_process_char()
871 cp210x_process_lsr(port, port_priv->lsr, flag); in cp210x_process_char()
872 port_priv->event_state = ES_DATA; in cp210x_process_char()
876 port_priv->lsr = *ch; in cp210x_process_char()
877 cp210x_process_lsr(port, port_priv->lsr, flag); in cp210x_process_char()
878 port_priv->event_state = ES_DATA; in cp210x_process_char()
883 port_priv->event_state = ES_DATA; in cp210x_process_char()
893 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_process_read_urb() local
901 if (port_priv->event_mode) { in cp210x_process_read_urb()
923 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_get_tx_queue_byte_count() local
929 port_priv->bInterfaceNumber, &sts, sizeof(sts), in cp210x_get_tx_queue_byte_count()
1081 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_enable_event_mode() local
1084 if (port_priv->event_mode) in cp210x_enable_event_mode()
1090 port_priv->event_state = ES_DATA; in cp210x_enable_event_mode()
1091 port_priv->event_mode = true; in cp210x_enable_event_mode()
1096 port_priv->event_mode = false; in cp210x_enable_event_mode()
1102 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_disable_event_mode() local
1105 if (!port_priv->event_mode) in cp210x_disable_event_mode()
1114 port_priv->event_mode = false; in cp210x_disable_event_mode()
1133 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_set_flow_control() local
1173 mutex_lock(&port_priv->mutex); in cp210x_set_flow_control()
1187 if (port_priv->dtr) in cp210x_set_flow_control()
1195 if (port_priv->rts) in cp210x_set_flow_control()
1202 if (port_priv->rts) in cp210x_set_flow_control()
1234 port_priv->crtscts = crtscts; in cp210x_set_flow_control()
1236 mutex_unlock(&port_priv->mutex); in cp210x_set_flow_control()
1322 struct cp210x_port_private *port_priv = usb_get_serial_port_data(port); in cp210x_tiocmset_port() local
1328 mutex_lock(&port_priv->mutex); in cp210x_tiocmset_port()
1331 port_priv->rts = true; in cp210x_tiocmset_port()
1336 port_priv->dtr = true; in cp210x_tiocmset_port()
1341 port_priv->rts = false; in cp210x_tiocmset_port()
1346 port_priv->dtr = false; in cp210x_tiocmset_port()
1355 if (port_priv->crtscts && control & CONTROL_WRITE_RTS) { in cp210x_tiocmset_port()
1365 if (port_priv->dtr) in cp210x_tiocmset_port()
1371 if (port_priv->rts) in cp210x_tiocmset_port()
1390 mutex_unlock(&port_priv->mutex); in cp210x_tiocmset_port()
1980 struct cp210x_port_private *port_priv; in cp210x_port_probe() local
1982 port_priv = kzalloc(sizeof(*port_priv), GFP_KERNEL); in cp210x_port_probe()
1983 if (!port_priv) in cp210x_port_probe()
1986 port_priv->bInterfaceNumber = cp210x_interface_num(serial); in cp210x_port_probe()
1987 mutex_init(&port_priv->mutex); in cp210x_port_probe()
1989 usb_set_serial_port_data(port, port_priv); in cp210x_port_probe()
1996 struct cp210x_port_private *port_priv; in cp210x_port_remove() local
1998 port_priv = usb_get_serial_port_data(port); in cp210x_port_remove()
1999 kfree(port_priv); in cp210x_port_remove()