diff options
author | Antonino A. Daplas <adaplas@pol.net> | 2005-12-12 22:17:15 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-12-12 22:31:17 -0800 |
commit | 56f0d64de80733bda54d1cfa7ac0c736ab2de33b (patch) | |
tree | c708c7d2375295d0e5e7884771c2dd8275b5e89c /drivers/video/console/fbcon.c | |
parent | 2f6331faf58a4727a9f1138cd6db30d05b124220 (diff) | |
download | lwn-56f0d64de80733bda54d1cfa7ac0c736ab2de33b.tar.gz lwn-56f0d64de80733bda54d1cfa7ac0c736ab2de33b.zip |
[PATCH] fbcon: fix complement_mask() with 512 character map
There is a bug in the complement_mask when you have a 512-character map.
Linux boots to a default 256-character map and most probably your login
profile is loading a 512-character map which results in a bad gpm cursor.
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/video/console/fbcon.c')
-rw-r--r-- | drivers/video/console/fbcon.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c index bcea87c3cc06..c024ffd0266d 100644 --- a/drivers/video/console/fbcon.c +++ b/drivers/video/console/fbcon.c @@ -2048,7 +2048,7 @@ static int fbcon_switch(struct vc_data *vc) struct fbcon_ops *ops; struct display *p = &fb_display[vc->vc_num]; struct fb_var_screeninfo var; - int i, prev_console; + int i, prev_console, charcnt = 256; info = registered_fb[con2fb_map[vc->vc_num]]; ops = info->fbcon_par; @@ -2120,6 +2120,13 @@ static int fbcon_switch(struct vc_data *vc) vc->vc_can_do_color = (fb_get_color_depth(&info->var, &info->fix)!=1); vc->vc_complement_mask = vc->vc_can_do_color ? 0x7700 : 0x0800; + + if (p->userfont) + charcnt = FNTCHARCNT(vc->vc_font.data); + + if (charcnt > 256) + vc->vc_complement_mask <<= 1; + updatescrollmode(p, info, vc); switch (p->scrollmode) { |