All of lore.kernel.org
 help / color / mirror / Atom feed
From: Adrian Bunk <bunk@stusta.de>
To: linux-kernel@vger.kernel.org
Subject: [2.6 patch] drivers/char/tty_io.c: remove console_use_vt
Date: Mon, 31 Jan 2005 18:41:05 +0100	[thread overview]
Message-ID: <20050131174105.GW18316@stusta.de> (raw)

The global variable console_use_vt never changed its' value.

Signed-off-by: Adrian Bunk <bunk@stusta.de>

---

 drivers/char/tty_io.c |   24 ++++++++++--------------
 1 files changed, 10 insertions(+), 14 deletions(-)

--- linux-2.6.11-rc2-mm2-full/drivers/char/tty_io.c.old	2005-01-31 15:45:20.000000000 +0100
+++ linux-2.6.11-rc2-mm2-full/drivers/char/tty_io.c	2005-01-31 15:45:56.000000000 +0100
@@ -131,8 +131,6 @@
    vt.c for deeply disgusting hack reasons */
 DECLARE_MUTEX(tty_sem);
 
-int console_use_vt = 1;
-
 #ifdef CONFIG_UNIX98_PTYS
 extern struct tty_driver *ptm_driver;	/* Unix98 pty masters; for /dev/ptmx */
 extern int pty_limit;		/* Config limit on Unix98 ptys */
@@ -2962,19 +2960,17 @@
 #endif
 
 #ifdef CONFIG_VT
-	if (console_use_vt) {
-		cdev_init(&vc0_cdev, &console_fops);
-		if (cdev_add(&vc0_cdev, MKDEV(TTY_MAJOR, 0), 1) ||
-		    register_chrdev_region(MKDEV(TTY_MAJOR, 0), 1,
-					   "/dev/vc/0") < 0)
-			panic("Couldn't register /dev/tty0 driver\n");
-		devfs_mk_cdev(MKDEV(TTY_MAJOR, 0), S_IFCHR|S_IRUSR|S_IWUSR,
-			      "vc/0");
-		class_simple_device_add(tty_class, MKDEV(TTY_MAJOR, 0), NULL,
-					"tty0");
+	cdev_init(&vc0_cdev, &console_fops);
+	if (cdev_add(&vc0_cdev, MKDEV(TTY_MAJOR, 0), 1) ||
+	    register_chrdev_region(MKDEV(TTY_MAJOR, 0), 1,
+				   "/dev/vc/0") < 0)
+		panic("Couldn't register /dev/tty0 driver\n");
+	devfs_mk_cdev(MKDEV(TTY_MAJOR, 0), S_IFCHR|S_IRUSR|S_IWUSR,
+		      "vc/0");
+	class_simple_device_add(tty_class, MKDEV(TTY_MAJOR, 0), NULL,
+				"tty0");
 
-		vty_init();
-	}
+	vty_init();
 #endif
 	return 0;
 }


             reply	other threads:[~2005-01-31 17:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-01-31 17:41 Adrian Bunk [this message]
2005-01-31 19:05 ` [2.6 patch] drivers/char/tty_io.c: remove console_use_vt Olaf Hering
2005-01-31 19:14   ` Adrian Bunk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050131174105.GW18316@stusta.de \
    --to=bunk@stusta.de \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.