From: Michal Januszewski Date: Tue, 8 May 2007 07:38:07 +0000 (-0700) Subject: fbcon: don't draw cursor when it's disabled X-Git-Tag: v2.6.22-rc1~439 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d1e2306681ad3cbbe63a2bfcc37ac22a21b0f0eb;p=linux-2.6 fbcon: don't draw cursor when it's disabled When the cursor and echo are disabled on the current console, pressing a key will cause a black rectangle to be painted in the cursor's position. Fix this by not touching the framebuffer in fbcon_cursor() when the cursor is off. Signed-off-by: Michal Januszewski Cc: "Antonino A. Daplas" Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c index bd131d472e..f1e3e3c00b 100644 --- a/drivers/video/console/fbcon.c +++ b/drivers/video/console/fbcon.c @@ -1310,7 +1310,7 @@ static void fbcon_cursor(struct vc_data *vc, int mode) int y; int c = scr_readw((u16 *) vc->vc_pos); - if (fbcon_is_inactive(vc, info)) + if (fbcon_is_inactive(vc, info) || vc->vc_deccm != 1) return; ops->cursor_flash = (mode == CM_ERASE) ? 0 : 1;