From: Arnd Bergmann Date: Tue, 1 Jun 2010 20:53:03 +0000 (+0200) Subject: tty: fix console_sem lock order X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=83ceb67d7dfe6aedf0e47dd6887b7b3c753542b2;p=linux-beck.git tty: fix console_sem lock order vgacon_do_font_op releases and reacquires the BTM while holding console_sem. This violates the rule that BTM has to be the outer lock whenever we hold both. There does not seem to be any reason to give up the BTM here, so just stop doing that. Signed-off-by: Arnd Bergmann Cc: Alan Cox Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/video/console/vgacon.c b/drivers/video/console/vgacon.c index 71970057c118..54e32c513610 100644 --- a/drivers/video/console/vgacon.c +++ b/drivers/video/console/vgacon.c @@ -1108,7 +1108,6 @@ static int vgacon_do_font_op(struct vgastate *state,char *arg,int set,int ch512) charmap += 4 * cmapsz; #endif - tty_unlock(); spin_lock_irq(&vga_lock); /* First, the Sequencer */ vga_wseq(state->vgabase, VGA_SEQ_RESET, 0x1); @@ -1192,7 +1191,6 @@ static int vgacon_do_font_op(struct vgastate *state,char *arg,int set,int ch512) vga_wattr(state->vgabase, VGA_AR_ENABLE_DISPLAY, 0); } spin_unlock_irq(&vga_lock); - tty_lock(); return 0; }