Lines Matching refs:serial
50 static int is_irda(struct usb_serial *serial) in is_irda() argument
52 struct usb_device *dev = serial->dev; in is_irda()
77 static int ark3116_write_reg(struct usb_serial *serial, in ark3116_write_reg() argument
82 result = usb_control_msg(serial->dev, in ark3116_write_reg()
83 usb_sndctrlpipe(serial->dev, 0), in ark3116_write_reg()
92 static int ark3116_read_reg(struct usb_serial *serial, in ark3116_read_reg() argument
97 result = usb_control_msg(serial->dev, in ark3116_read_reg()
98 usb_rcvctrlpipe(serial->dev, 0), in ark3116_read_reg()
102 dev_err(&serial->interface->dev, in ark3116_read_reg()
126 struct usb_serial *serial = port->serial; in ark3116_port_probe() local
136 priv->irda = is_irda(serial); in ark3116_port_probe()
141 ark3116_write_reg(serial, UART_IER, 0); in ark3116_port_probe()
143 ark3116_write_reg(serial, UART_FCR, 0); in ark3116_port_probe()
146 ark3116_write_reg(serial, 0x8 , 0); in ark3116_port_probe()
149 ark3116_write_reg(serial, UART_MCR, 0); in ark3116_port_probe()
152 ark3116_write_reg(serial, 0xb , 0); in ark3116_port_probe()
154 ark3116_write_reg(serial, 0xb , 1); in ark3116_port_probe()
155 ark3116_write_reg(serial, 0xc , 0); in ark3116_port_probe()
156 ark3116_write_reg(serial, 0xd , 0x41); in ark3116_port_probe()
157 ark3116_write_reg(serial, 0xa , 1); in ark3116_port_probe()
161 ark3116_write_reg(serial, UART_LCR, UART_LCR_DLAB); in ark3116_port_probe()
165 ark3116_write_reg(serial, UART_DLL, priv->quot & 0xff); in ark3116_port_probe()
166 ark3116_write_reg(serial, UART_DLM, (priv->quot>>8) & 0xff); in ark3116_port_probe()
169 ark3116_write_reg(serial, UART_LCR, UART_LCR_WLEN8); in ark3116_port_probe()
171 ark3116_write_reg(serial, 0xe, 0); in ark3116_port_probe()
174 ark3116_write_reg(serial, 0x9, 0); in ark3116_port_probe()
196 struct usb_serial *serial = port->serial; in ark3116_set_termios() local
267 ark3116_write_reg(serial, 0x8, hcr); in ark3116_set_termios()
278 ark3116_write_reg(serial, UART_FCR, 0); in ark3116_set_termios()
280 ark3116_write_reg(serial, UART_LCR, in ark3116_set_termios()
282 ark3116_write_reg(serial, UART_DLL, quot & 0xff); in ark3116_set_termios()
283 ark3116_write_reg(serial, UART_DLM, (quot>>8) & 0xff); in ark3116_set_termios()
286 ark3116_write_reg(serial, UART_LCR, lcr); in ark3116_set_termios()
290 ark3116_write_reg(serial, 0xe, eval); in ark3116_set_termios()
293 ark3116_write_reg(serial, UART_FCR, UART_FCR_DMA_SELECT); in ark3116_set_termios()
296 ark3116_write_reg(serial, UART_LCR, lcr); in ark3116_set_termios()
314 struct usb_serial *serial = port->serial; in ark3116_close() local
317 ark3116_write_reg(serial, UART_FCR, 0); in ark3116_close()
320 ark3116_write_reg(serial, UART_IER, 0); in ark3116_close()
330 struct usb_serial *serial = port->serial; in ark3116_open() local
347 ark3116_read_reg(serial, UART_RX, buf); in ark3116_open()
350 result = ark3116_read_reg(serial, UART_MSR, buf); in ark3116_open()
356 result = ark3116_read_reg(serial, UART_LSR, buf); in ark3116_open()
369 ark3116_write_reg(port->serial, UART_IER, UART_IER_MSI|UART_IER_RLSI); in ark3116_open()
372 ark3116_write_reg(port->serial, UART_FCR, UART_FCR_DMA_SELECT); in ark3116_open()
457 ark3116_write_reg(port->serial, UART_MCR, priv->mcr); in ark3116_tiocmset()
477 ark3116_write_reg(port->serial, UART_LCR, priv->lcr); in ark3116_break_ctl()