tty: remove flags from struct tty_ldisc_ops
authorJiri Slaby <jslaby@suse.cz>
Tue, 14 Sep 2021 09:11:20 +0000 (11:11 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Sep 2021 14:59:13 +0000 (16:59 +0200)
The last user was apparently removed by commit a352def21a64 (tty: Ldisc
revamp) in 2008. So remove the field completely, the only setter
(n_tty_inherit_ops) and also its only possible value
(LDISC_FLAG_DEFINED).

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Link: https://lore.kernel.org/r/20210914091134.17426-2-jslaby@suse.cz
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/n_tty.c
include/linux/tty_ldisc.h

index 0ec93f1a61f5da63999f3498d1cd313fe574a68d..797af5d46cbe9107e9f2fcfc8ab49a73f2c802cd 100644 (file)
@@ -2450,7 +2450,6 @@ void n_tty_inherit_ops(struct tty_ldisc_ops *ops)
 {
        *ops = n_tty_ops;
        ops->owner = NULL;
-       ops->flags = 0;
 }
 EXPORT_SYMBOL_GPL(n_tty_inherit_ops);
 
index b1d812e902aad607113c85d461bc7701df4bd458..1f37184eee633e79c0b2bc534a0cfc2ccb191427 100644 (file)
@@ -180,7 +180,6 @@ extern int ldsem_down_write_nested(struct ld_semaphore *sem, int subclass,
 struct tty_ldisc_ops {
        char    *name;
        int     num;
-       int     flags;
 
        /*
         * The following routines are called from above.
@@ -220,8 +219,6 @@ struct tty_ldisc {
        struct tty_struct *tty;
 };
 
-#define LDISC_FLAG_DEFINED     0x00000001
-
 #define MODULE_ALIAS_LDISC(ldisc) \
        MODULE_ALIAS("tty-ldisc-" __stringify(ldisc))