Commit f9d4be25 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'tty-5.15-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty

Pull tty/serial fixes from Greg KH:
 "Here are four small tty/serial driver fixes for 5.15-rc3. They
  include:

   - remove an export now that no one is using it anymore

   - mvebu-uart tx_empty callback fix

   - 8250_omap bugfix

   - synclink_gt build fix

  All of these have been in linux-next for a while with no reported
  issues"

* tag 'tty-5.15-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
  tty: unexport tty_ldisc_release
  tty: synclink_gt: rename a conflicting function name
  serial: mvebu-uart: fix driver's tx_empty callback
  serial: 8250: 8250_omap: Fix RX_LVL register offset
parents 2c4e969c 7049d853
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
#define UART_OMAP_EFR2_TIMEOUT_BEHAVE BIT(6) #define UART_OMAP_EFR2_TIMEOUT_BEHAVE BIT(6)
/* RX FIFO occupancy indicator */ /* RX FIFO occupancy indicator */
#define UART_OMAP_RX_LVL 0x64 #define UART_OMAP_RX_LVL 0x19
struct omap8250_priv { struct omap8250_priv {
int line; int line;
......
...@@ -163,7 +163,7 @@ static unsigned int mvebu_uart_tx_empty(struct uart_port *port) ...@@ -163,7 +163,7 @@ static unsigned int mvebu_uart_tx_empty(struct uart_port *port)
st = readl(port->membase + UART_STAT); st = readl(port->membase + UART_STAT);
spin_unlock_irqrestore(&port->lock, flags); spin_unlock_irqrestore(&port->lock, flags);
return (st & STAT_TX_FIFO_EMP) ? TIOCSER_TEMT : 0; return (st & STAT_TX_EMP) ? TIOCSER_TEMT : 0;
} }
static unsigned int mvebu_uart_get_mctrl(struct uart_port *port) static unsigned int mvebu_uart_get_mctrl(struct uart_port *port)
......
...@@ -438,8 +438,8 @@ static void reset_tbufs(struct slgt_info *info); ...@@ -438,8 +438,8 @@ static void reset_tbufs(struct slgt_info *info);
static void tdma_reset(struct slgt_info *info); static void tdma_reset(struct slgt_info *info);
static bool tx_load(struct slgt_info *info, const char *buf, unsigned int count); static bool tx_load(struct slgt_info *info, const char *buf, unsigned int count);
static void get_signals(struct slgt_info *info); static void get_gtsignals(struct slgt_info *info);
static void set_signals(struct slgt_info *info); static void set_gtsignals(struct slgt_info *info);
static void set_rate(struct slgt_info *info, u32 data_rate); static void set_rate(struct slgt_info *info, u32 data_rate);
static void bh_transmit(struct slgt_info *info); static void bh_transmit(struct slgt_info *info);
...@@ -720,7 +720,7 @@ static void set_termios(struct tty_struct *tty, struct ktermios *old_termios) ...@@ -720,7 +720,7 @@ static void set_termios(struct tty_struct *tty, struct ktermios *old_termios)
if ((old_termios->c_cflag & CBAUD) && !C_BAUD(tty)) { if ((old_termios->c_cflag & CBAUD) && !C_BAUD(tty)) {
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR); info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
set_signals(info); set_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
} }
...@@ -730,7 +730,7 @@ static void set_termios(struct tty_struct *tty, struct ktermios *old_termios) ...@@ -730,7 +730,7 @@ static void set_termios(struct tty_struct *tty, struct ktermios *old_termios)
if (!C_CRTSCTS(tty) || !tty_throttled(tty)) if (!C_CRTSCTS(tty) || !tty_throttled(tty))
info->signals |= SerialSignal_RTS; info->signals |= SerialSignal_RTS;
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
set_signals(info); set_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
} }
...@@ -1181,7 +1181,7 @@ static inline void line_info(struct seq_file *m, struct slgt_info *info) ...@@ -1181,7 +1181,7 @@ static inline void line_info(struct seq_file *m, struct slgt_info *info)
/* output current serial signal states */ /* output current serial signal states */
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
get_signals(info); get_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
stat_buf[0] = 0; stat_buf[0] = 0;
...@@ -1281,7 +1281,7 @@ static void throttle(struct tty_struct * tty) ...@@ -1281,7 +1281,7 @@ static void throttle(struct tty_struct * tty)
if (C_CRTSCTS(tty)) { if (C_CRTSCTS(tty)) {
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
info->signals &= ~SerialSignal_RTS; info->signals &= ~SerialSignal_RTS;
set_signals(info); set_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
} }
} }
...@@ -1306,7 +1306,7 @@ static void unthrottle(struct tty_struct * tty) ...@@ -1306,7 +1306,7 @@ static void unthrottle(struct tty_struct * tty)
if (C_CRTSCTS(tty)) { if (C_CRTSCTS(tty)) {
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
info->signals |= SerialSignal_RTS; info->signals |= SerialSignal_RTS;
set_signals(info); set_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
} }
} }
...@@ -1477,7 +1477,7 @@ static int hdlcdev_open(struct net_device *dev) ...@@ -1477,7 +1477,7 @@ static int hdlcdev_open(struct net_device *dev)
/* inform generic HDLC layer of current DCD status */ /* inform generic HDLC layer of current DCD status */
spin_lock_irqsave(&info->lock, flags); spin_lock_irqsave(&info->lock, flags);
get_signals(info); get_gtsignals(info);
spin_unlock_irqrestore(&info->lock, flags); spin_unlock_irqrestore(&info->lock, flags);
if (info->signals & SerialSignal_DCD) if (info->signals & SerialSignal_DCD)
netif_carrier_on(dev); netif_carrier_on(dev);
...@@ -2229,7 +2229,7 @@ static void isr_txeom(struct slgt_info *info, unsigned short status) ...@@ -2229,7 +2229,7 @@ static void isr_txeom(struct slgt_info *info, unsigned short status)
if (info->params.mode != MGSL_MODE_ASYNC && info->drop_rts_on_tx_done) { if (info->params.mode != MGSL_MODE_ASYNC && info->drop_rts_on_tx_done) {
info->signals &= ~SerialSignal_RTS; info->signals &= ~SerialSignal_RTS;
info->drop_rts_on_tx_done = false; info->drop_rts_on_tx_done = false;
set_signals(info); set_gtsignals(info);
} }
#if SYNCLINK_GENERIC_HDLC #if SYNCLINK_GENERIC_HDLC
...@@ -2394,7 +2394,7 @@ static void shutdown(struct slgt_info *info) ...@@ -2394,7 +2394,7 @@ static void shutdown(struct slgt_info *info)
if (!info->port.tty || info->port.tty->termios.c_cflag & HUPCL) { if (!info->port.tty || info->port.tty->termios.c_cflag & HUPCL) {
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR); info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
set_signals(info); set_gtsignals(info);
} }
flush_cond_wait(&info->gpio_wait_q); flush_cond_wait(&info->gpio_wait_q);
...@@ -2422,7 +2422,7 @@ static void program_hw(struct slgt_info *info) ...@@ -2422,7 +2422,7 @@ static void program_hw(struct slgt_info *info)
else else
async_mode(info); async_mode(info);
set_signals(info); set_gtsignals(info);
info->dcd_chkcount = 0; info->dcd_chkcount = 0;
info->cts_chkcount = 0; info->cts_chkcount = 0;
...@@ -2430,7 +2430,7 @@ static void program_hw(struct slgt_info *info) ...@@ -2430,7 +2430,7 @@ static void program_hw(struct slgt_info *info)
info->dsr_chkcount = 0; info->dsr_chkcount = 0;
slgt_irq_on(info, IRQ_DCD | IRQ_CTS | IRQ_DSR | IRQ_RI); slgt_irq_on(info, IRQ_DCD | IRQ_CTS | IRQ_DSR | IRQ_RI);
get_signals(info); get_gtsignals(info);
if (info->netcount || if (info->netcount ||
(info->port.tty && info->port.tty->termios.c_cflag & CREAD)) (info->port.tty && info->port.tty->termios.c_cflag & CREAD))
...@@ -2667,7 +2667,7 @@ static int wait_mgsl_event(struct slgt_info *info, int __user *mask_ptr) ...@@ -2667,7 +2667,7 @@ static int wait_mgsl_event(struct slgt_info *info, int __user *mask_ptr)
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
/* return immediately if state matches requested events */ /* return immediately if state matches requested events */
get_signals(info); get_gtsignals(info);
s = info->signals; s = info->signals;
events = mask & events = mask &
...@@ -3085,7 +3085,7 @@ static int tiocmget(struct tty_struct *tty) ...@@ -3085,7 +3085,7 @@ static int tiocmget(struct tty_struct *tty)
unsigned long flags; unsigned long flags;
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
get_signals(info); get_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
result = ((info->signals & SerialSignal_RTS) ? TIOCM_RTS:0) + result = ((info->signals & SerialSignal_RTS) ? TIOCM_RTS:0) +
...@@ -3124,7 +3124,7 @@ static int tiocmset(struct tty_struct *tty, ...@@ -3124,7 +3124,7 @@ static int tiocmset(struct tty_struct *tty,
info->signals &= ~SerialSignal_DTR; info->signals &= ~SerialSignal_DTR;
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
set_signals(info); set_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
return 0; return 0;
} }
...@@ -3135,7 +3135,7 @@ static int carrier_raised(struct tty_port *port) ...@@ -3135,7 +3135,7 @@ static int carrier_raised(struct tty_port *port)
struct slgt_info *info = container_of(port, struct slgt_info, port); struct slgt_info *info = container_of(port, struct slgt_info, port);
spin_lock_irqsave(&info->lock,flags); spin_lock_irqsave(&info->lock,flags);
get_signals(info); get_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
return (info->signals & SerialSignal_DCD) ? 1 : 0; return (info->signals & SerialSignal_DCD) ? 1 : 0;
} }
...@@ -3150,7 +3150,7 @@ static void dtr_rts(struct tty_port *port, int on) ...@@ -3150,7 +3150,7 @@ static void dtr_rts(struct tty_port *port, int on)
info->signals |= SerialSignal_RTS | SerialSignal_DTR; info->signals |= SerialSignal_RTS | SerialSignal_DTR;
else else
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR); info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
set_signals(info); set_gtsignals(info);
spin_unlock_irqrestore(&info->lock,flags); spin_unlock_irqrestore(&info->lock,flags);
} }
...@@ -3948,10 +3948,10 @@ static void tx_start(struct slgt_info *info) ...@@ -3948,10 +3948,10 @@ static void tx_start(struct slgt_info *info)
if (info->params.mode != MGSL_MODE_ASYNC) { if (info->params.mode != MGSL_MODE_ASYNC) {
if (info->params.flags & HDLC_FLAG_AUTO_RTS) { if (info->params.flags & HDLC_FLAG_AUTO_RTS) {
get_signals(info); get_gtsignals(info);
if (!(info->signals & SerialSignal_RTS)) { if (!(info->signals & SerialSignal_RTS)) {
info->signals |= SerialSignal_RTS; info->signals |= SerialSignal_RTS;
set_signals(info); set_gtsignals(info);
info->drop_rts_on_tx_done = true; info->drop_rts_on_tx_done = true;
} }
} }
...@@ -4005,7 +4005,7 @@ static void reset_port(struct slgt_info *info) ...@@ -4005,7 +4005,7 @@ static void reset_port(struct slgt_info *info)
rx_stop(info); rx_stop(info);
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR); info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
set_signals(info); set_gtsignals(info);
slgt_irq_off(info, IRQ_ALL | IRQ_MASTER); slgt_irq_off(info, IRQ_ALL | IRQ_MASTER);
} }
...@@ -4427,7 +4427,7 @@ static void tx_set_idle(struct slgt_info *info) ...@@ -4427,7 +4427,7 @@ static void tx_set_idle(struct slgt_info *info)
/* /*
* get state of V24 status (input) signals * get state of V24 status (input) signals
*/ */
static void get_signals(struct slgt_info *info) static void get_gtsignals(struct slgt_info *info)
{ {
unsigned short status = rd_reg16(info, SSR); unsigned short status = rd_reg16(info, SSR);
...@@ -4489,7 +4489,7 @@ static void msc_set_vcr(struct slgt_info *info) ...@@ -4489,7 +4489,7 @@ static void msc_set_vcr(struct slgt_info *info)
/* /*
* set state of V24 control (output) signals * set state of V24 control (output) signals
*/ */
static void set_signals(struct slgt_info *info) static void set_gtsignals(struct slgt_info *info)
{ {
unsigned char val = rd_reg8(info, VCR); unsigned char val = rd_reg8(info, VCR);
if (info->signals & SerialSignal_DTR) if (info->signals & SerialSignal_DTR)
......
...@@ -812,7 +812,6 @@ void tty_ldisc_release(struct tty_struct *tty) ...@@ -812,7 +812,6 @@ void tty_ldisc_release(struct tty_struct *tty)
tty_ldisc_debug(tty, "released\n"); tty_ldisc_debug(tty, "released\n");
} }
EXPORT_SYMBOL_GPL(tty_ldisc_release);
/** /**
* tty_ldisc_init - ldisc setup for new tty * tty_ldisc_init - ldisc setup for new tty
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment