提交 469d6d06 编写于 作者: P Peter Hurley 提交者: Greg Kroah-Hartman

tty: Remove unused drop() method from tty_port interface

Although originally conceived as a hook for port drivers to know
when a port reference is dropped, no driver uses this method.
Signed-off-by: NPeter Hurley <peter@hurleysoftware.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 e3bfea23
...@@ -484,8 +484,6 @@ int tty_port_close_start(struct tty_port *port, ...@@ -484,8 +484,6 @@ int tty_port_close_start(struct tty_port *port,
if (port->count) { if (port->count) {
spin_unlock_irqrestore(&port->lock, flags); spin_unlock_irqrestore(&port->lock, flags);
if (port->ops->drop)
port->ops->drop(port);
return 0; return 0;
} }
set_bit(ASYNCB_CLOSING, &port->flags); set_bit(ASYNCB_CLOSING, &port->flags);
...@@ -504,9 +502,7 @@ int tty_port_close_start(struct tty_port *port, ...@@ -504,9 +502,7 @@ int tty_port_close_start(struct tty_port *port,
/* Flush the ldisc buffering */ /* Flush the ldisc buffering */
tty_ldisc_flush(tty); tty_ldisc_flush(tty);
/* Don't call port->drop for the last reference. Callers will want /* Report to caller this is the last port reference */
to drop the last active reference in ->shutdown() or the tty
shutdown path */
return 1; return 1;
} }
EXPORT_SYMBOL(tty_port_close_start); EXPORT_SYMBOL(tty_port_close_start);
......
...@@ -180,7 +180,6 @@ struct tty_port_operations { ...@@ -180,7 +180,6 @@ struct tty_port_operations {
IFF the port was initialized. Do not use to free resources. Called IFF the port was initialized. Do not use to free resources. Called
under the port mutex to serialize against activate/shutdowns */ under the port mutex to serialize against activate/shutdowns */
void (*shutdown)(struct tty_port *port); void (*shutdown)(struct tty_port *port);
void (*drop)(struct tty_port *port);
/* Called under the port mutex from tty_port_open, serialized using /* Called under the port mutex from tty_port_open, serialized using
the port mutex */ the port mutex */
/* FIXME: long term getting the tty argument *out* of this would be /* FIXME: long term getting the tty argument *out* of this would be
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册