Просмотр исходного кода

[PATCH] Initialize the .owner field the tty_ldisc structure.

If .owner isn't set the module can be unloaded even while still active.

Signed-off-by: Ralf Baechle DL5RB <ralf@linux-mips.org>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Ralf Baechle 20 лет назад
Родитель
Сommit
74cfe03f80
1 измененных файлов с 1 добавлено и 0 удалено
  1. 1 0
      drivers/net/hamradio/mkiss.c

+ 1 - 0
drivers/net/hamradio/mkiss.c

@@ -977,6 +977,7 @@ static void mkiss_write_wakeup(struct tty_struct *tty)
 }
 
 static struct tty_ldisc ax_ldisc = {
+	.owner		= THIS_MODULE,
 	.magic		= TTY_LDISC_MAGIC,
 	.name		= "mkiss",
 	.open		= mkiss_open,