Skip to contentSkip to conversation

Fix for magic sysrq when CONFIG_VT=n]

[email protected]: Crutcher Dunnavant 1 participant 1 message Aug 12, 2002 Char and misc drivers

lore
Share & tools
lore
#0 lore raw

Trivial patch for SysRQ.

----- Forwarded message from Rusty Trivial Russell <[email protected]> -----

Date: Mon, 12 Aug 2002 16:26:27 +1000
To: [email protected], [email protected]
From: Rusty Trivial Russell <[email protected]>
Subject: [TRIVIAL] Fix for magic sysrq when CONFIG_VT=n

From: David Gibson <[email protected]>

The "unRaw" option for the magic sysrq key fails to compile if CONFIG_VT is false. This patch fixes that:

drivers/char/sysrq.c renamed from drivers/char/sysrq.c.orig +6 -2
@@ -76,7 +76,7 @@
 };
 #endif
 
-
+#ifdef CONFIG_VT
 /* unraw sysrq handler */
 static void sysrq_handle_unraw(int key, struct pt_regs *pt_regs,
 			       struct tty_struct *tty) 
@@ -91,7 +91,7 @@
 	help_msg:	"unRaw",
 	action_msg:	"Keyboard mode set to XLATE",
 };
-
+#endif /* CONFIG_VT */
 
 /* reboot sysrq handler */
 static void sysrq_handle_reboot(int key, struct pt_regs *pt_regs,
@@ -371,7 +371,11 @@
 		 as 'Off' at init time */
 /* p */	&sysrq_showregs_op,
 /* q */	NULL,
+#ifdef CONFIG_VT
 /* r */	&sysrq_unraw_op,
+#else
+/* r */ NULL,
+#endif
 /* s */	&sysrq_sync_op,
 /* t */	&sysrq_showstate_op,
 /* u */	&sysrq_mountro_op,
Signature · 8 lines
  Don't blame me: the Monkey is driving
  File: David Gibson <[email protected]>: [TRIVIAL] Fix for magic sysrq when CONFIG_VT=n

----- End forwarded message -----

-- 
Crutcher Dunnavant <[email protected]>
ECSS System Hacker / UA COE CS Senior