tty: synclink_gt: rename a conflicting function name
'set_signals()' in synclink_gt.c conflicts with an exported symbol
in arch/um/, so change set_signals() to set_gtsignals(). Keep
the function names similar by also changing get_signals() to
get_gtsignals().
../drivers/tty/synclink_gt.c:442:13: error: conflicting types for ‘set_signals’
static void set_signals(struct slgt_info *info);
^~~~~~~~~~~
In file included from ../include/linux/irqflags.h:16:0,
from ../include/linux/spinlock.h:58,
from ../include/linux/mm_types.h:9,
from ../include/linux/buildid.h:5,
from ../include/linux/module.h:14,
from ../drivers/tty/synclink_gt.c:46:
../arch/um/include/asm/irqflags.h:6:5: note: previous declaration of ‘set_signals’ was here
int set_signals(int enable);
^~~~~~~~~~~
Fixes: 705b6c7b34
("[PATCH] new driver synclink_gt")
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jiri Slaby <jirislaby@kernel.org>
Cc: Paul Fulghum <paulkf@microgate.com>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Link: https://lore.kernel.org/r/20210902003806.17054-1-rdunlap@infradead.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Родитель
74e1eb3b4a
Коммит
06e49073df
|
@ -438,8 +438,8 @@ static void reset_tbufs(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 void get_signals(struct slgt_info *info);
|
||||
static void set_signals(struct slgt_info *info);
|
||||
static void get_gtsignals(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 bh_transmit(struct slgt_info *info);
|
||||
|
@ -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)) {
|
||||
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
}
|
||||
|
||||
|
@ -730,7 +730,7 @@ static void set_termios(struct tty_struct *tty, struct ktermios *old_termios)
|
|||
if (!C_CRTSCTS(tty) || !tty_throttled(tty))
|
||||
info->signals |= SerialSignal_RTS;
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
}
|
||||
|
||||
|
@ -1181,7 +1181,7 @@ static inline void line_info(struct seq_file *m, struct slgt_info *info)
|
|||
|
||||
/* output current serial signal states */
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
get_signals(info);
|
||||
get_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
|
||||
stat_buf[0] = 0;
|
||||
|
@ -1281,7 +1281,7 @@ static void throttle(struct tty_struct * tty)
|
|||
if (C_CRTSCTS(tty)) {
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
info->signals &= ~SerialSignal_RTS;
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
}
|
||||
}
|
||||
|
@ -1306,7 +1306,7 @@ static void unthrottle(struct tty_struct * tty)
|
|||
if (C_CRTSCTS(tty)) {
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
info->signals |= SerialSignal_RTS;
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
}
|
||||
}
|
||||
|
@ -1477,7 +1477,7 @@ static int hdlcdev_open(struct net_device *dev)
|
|||
|
||||
/* inform generic HDLC layer of current DCD status */
|
||||
spin_lock_irqsave(&info->lock, flags);
|
||||
get_signals(info);
|
||||
get_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock, flags);
|
||||
if (info->signals & SerialSignal_DCD)
|
||||
netif_carrier_on(dev);
|
||||
|
@ -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) {
|
||||
info->signals &= ~SerialSignal_RTS;
|
||||
info->drop_rts_on_tx_done = false;
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
}
|
||||
|
||||
#if SYNCLINK_GENERIC_HDLC
|
||||
|
@ -2394,7 +2394,7 @@ static void shutdown(struct slgt_info *info)
|
|||
|
||||
if (!info->port.tty || info->port.tty->termios.c_cflag & HUPCL) {
|
||||
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
}
|
||||
|
||||
flush_cond_wait(&info->gpio_wait_q);
|
||||
|
@ -2422,7 +2422,7 @@ static void program_hw(struct slgt_info *info)
|
|||
else
|
||||
async_mode(info);
|
||||
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
|
||||
info->dcd_chkcount = 0;
|
||||
info->cts_chkcount = 0;
|
||||
|
@ -2430,7 +2430,7 @@ static void program_hw(struct slgt_info *info)
|
|||
info->dsr_chkcount = 0;
|
||||
|
||||
slgt_irq_on(info, IRQ_DCD | IRQ_CTS | IRQ_DSR | IRQ_RI);
|
||||
get_signals(info);
|
||||
get_gtsignals(info);
|
||||
|
||||
if (info->netcount ||
|
||||
(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)
|
|||
spin_lock_irqsave(&info->lock,flags);
|
||||
|
||||
/* return immediately if state matches requested events */
|
||||
get_signals(info);
|
||||
get_gtsignals(info);
|
||||
s = info->signals;
|
||||
|
||||
events = mask &
|
||||
|
@ -3085,7 +3085,7 @@ static int tiocmget(struct tty_struct *tty)
|
|||
unsigned long flags;
|
||||
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
get_signals(info);
|
||||
get_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
|
||||
result = ((info->signals & SerialSignal_RTS) ? TIOCM_RTS:0) +
|
||||
|
@ -3124,7 +3124,7 @@ static int tiocmset(struct tty_struct *tty,
|
|||
info->signals &= ~SerialSignal_DTR;
|
||||
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
return 0;
|
||||
}
|
||||
|
@ -3135,7 +3135,7 @@ static int carrier_raised(struct tty_port *port)
|
|||
struct slgt_info *info = container_of(port, struct slgt_info, port);
|
||||
|
||||
spin_lock_irqsave(&info->lock,flags);
|
||||
get_signals(info);
|
||||
get_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
return (info->signals & SerialSignal_DCD) ? 1 : 0;
|
||||
}
|
||||
|
@ -3150,7 +3150,7 @@ static void dtr_rts(struct tty_port *port, int on)
|
|||
info->signals |= SerialSignal_RTS | SerialSignal_DTR;
|
||||
else
|
||||
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
spin_unlock_irqrestore(&info->lock,flags);
|
||||
}
|
||||
|
||||
|
@ -3948,10 +3948,10 @@ static void tx_start(struct slgt_info *info)
|
|||
|
||||
if (info->params.mode != MGSL_MODE_ASYNC) {
|
||||
if (info->params.flags & HDLC_FLAG_AUTO_RTS) {
|
||||
get_signals(info);
|
||||
get_gtsignals(info);
|
||||
if (!(info->signals & SerialSignal_RTS)) {
|
||||
info->signals |= SerialSignal_RTS;
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
info->drop_rts_on_tx_done = true;
|
||||
}
|
||||
}
|
||||
|
@ -4005,7 +4005,7 @@ static void reset_port(struct slgt_info *info)
|
|||
rx_stop(info);
|
||||
|
||||
info->signals &= ~(SerialSignal_RTS | SerialSignal_DTR);
|
||||
set_signals(info);
|
||||
set_gtsignals(info);
|
||||
|
||||
slgt_irq_off(info, IRQ_ALL | IRQ_MASTER);
|
||||
}
|
||||
|
@ -4427,7 +4427,7 @@ static void tx_set_idle(struct slgt_info *info)
|
|||
/*
|
||||
* 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);
|
||||
|
||||
|
@ -4489,7 +4489,7 @@ static void msc_set_vcr(struct slgt_info *info)
|
|||
/*
|
||||
* 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);
|
||||
if (info->signals & SerialSignal_DTR)
|
||||
|
|
Загрузка…
Ссылка в новой задаче