tty: drop obsolete termios_locked comments
authorJohan Hovold <johan@kernel.org>
Thu, 30 Mar 2017 13:39:35 +0000 (15:39 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 31 Mar 2017 09:37:13 +0000 (11:37 +0200)
Drop comments about tty-driver termios_locked structures, which have
been outdated since commit fe6e29fdb1a7 ("tty: simplify ktermios
allocation").

Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/tty_io.c

index 8e9651579d50c506befb43d2bce370a0ac5fc07e..5f834dcb0b15a5de5607c2b1a5ddd33433760216 100644 (file)
@@ -1520,7 +1520,7 @@ struct tty_struct *tty_init_dev(struct tty_driver *driver, int idx)
         * This code guarantees that either everything succeeds and the
         * TTY is ready for operation, or else the table slots are vacated
         * and the allocated memory released.  (Except that the termios
-        * and locked termios may be retained.)
+        * may be retained.)
         */
 
        if (!try_module_get(driver->owner))
@@ -3441,11 +3441,6 @@ static void destruct_tty_driver(struct kref *kref)
        struct ktermios *tp;
 
        if (driver->flags & TTY_DRIVER_INSTALLED) {
-               /*
-                * Free the termios and termios_locked structures because
-                * we don't want to get memory leaks when modular tty
-                * drivers are removed from the kernel.
-                */
                for (i = 0; i < driver->num; i++) {
                        tp = driver->termios[i];
                        if (tp) {