mux.c (92a19f9cec9a80ad93c06e115822deb729e2c6ad) mux.c (2e124b4a390ca85325fae75764bef92f0547fa25)
1/*
2** mux.c:
3** serial driver for the Mux console found in some PA-RISC servers.
4**
5** (c) Copyright 2002 Ryan Bradetich
6** (c) Copyright 2002 Hewlett-Packard Company
7**
8** This program is free software; you can redistribute it and/or modify

--- 230 unchanged lines hidden (view full) ---

239 *
240 * This reads all available data from the mux's fifo and pushes
241 * the data to the tty layer.
242 */
243static void mux_read(struct uart_port *port)
244{
245 struct tty_port *tport = &port->state->port;
246 int data;
1/*
2** mux.c:
3** serial driver for the Mux console found in some PA-RISC servers.
4**
5** (c) Copyright 2002 Ryan Bradetich
6** (c) Copyright 2002 Hewlett-Packard Company
7**
8** This program is free software; you can redistribute it and/or modify

--- 230 unchanged lines hidden (view full) ---

239 *
240 * This reads all available data from the mux's fifo and pushes
241 * the data to the tty layer.
242 */
243static void mux_read(struct uart_port *port)
244{
245 struct tty_port *tport = &port->state->port;
246 int data;
247 struct tty_struct *tty = tport->tty;
248 __u32 start_count = port->icount.rx;
249
250 while(1) {
251 data = __raw_readl(port->membase + IO_DATA_REG_OFFSET);
252
253 if (MUX_STATUS(data))
254 continue;
255

--- 9 unchanged lines hidden (view full) ---

265 }
266
267 if (uart_handle_sysrq_char(port, data & 0xffu))
268 continue;
269
270 tty_insert_flip_char(tport, data & 0xFF, TTY_NORMAL);
271 }
272
247 __u32 start_count = port->icount.rx;
248
249 while(1) {
250 data = __raw_readl(port->membase + IO_DATA_REG_OFFSET);
251
252 if (MUX_STATUS(data))
253 continue;
254

--- 9 unchanged lines hidden (view full) ---

264 }
265
266 if (uart_handle_sysrq_char(port, data & 0xffu))
267 continue;
268
269 tty_insert_flip_char(tport, data & 0xFF, TTY_NORMAL);
270 }
271
273 if (start_count != port->icount.rx) {
274 tty_flip_buffer_push(tty);
275 }
272 if (start_count != port->icount.rx)
273 tty_flip_buffer_push(tport);
276}
277
278/**
279 * mux_startup - Initialize the port.
280 * @port: Ptr to the uart_port.
281 *
282 * Grab any resources needed for this port and start the
283 * mux timer.

--- 352 unchanged lines hidden ---
274}
275
276/**
277 * mux_startup - Initialize the port.
278 * @port: Ptr to the uart_port.
279 *
280 * Grab any resources needed for this port and start the
281 * mux timer.

--- 352 unchanged lines hidden ---