From 61aacaa291e09842c8c379fefc600d54b938e006 Mon Sep 17 00:00:00 2001 From: Andi Kleen Date: Fri, 19 Apr 2002 20:06:43 -0700 Subject: [PATCH] [PATCH] Fix console initialization deadlock for x86-64 When vt_init happens to run before the keyboard is initialized (the order is random because they're both different initcalls) then set_leds raises an not yet enabled tasklet. This causes an endless loop on the first schedule() call because the tasklet handling cannot handle raised but disabled tasklets. This patch just does not do set_leds in virtual terminal initialization to avoid that. It is done later anyways. --- drivers/char/console.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/char/console.c b/drivers/char/console.c index aa6bfa2547ba..a726cc3d10ce 100644 --- a/drivers/char/console.c +++ b/drivers/char/console.c @@ -1420,7 +1420,8 @@ static void reset_terminal(int currcons, int do_clear) kbd_table[currcons].slockstate = 0; kbd_table[currcons].ledmode = LED_SHOW_FLAGS; kbd_table[currcons].ledflagstate = kbd_table[currcons].default_ledflagstate; - set_leds(); + /* do not do set_leds here because this causes an endless tasklet loop + when the keyboard hasn't been initialized yet */ cursor_type = CUR_DEFAULT; complement_mask = s_complement_mask; -- 2.39.5