summaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2017-01-11 19:09:50 +0300
committerBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>2017-01-11 19:09:50 +0300
commit8aac7f34369726d1a158788ae8aff3002d5eb528 (patch)
tree597a33c2e8227145369e3eca3b10ccae29619812 /security
parentdc312120b771fe6e4c4e753a73fd61e10de6d7b3 (diff)
downloadlinux-8aac7f34369726d1a158788ae8aff3002d5eb528.tar.xz
fbcon: Fix vc attr at deinit
fbcon can deal with vc_hi_font_mask (the upper 256 chars) and adjust the vc attrs dynamically when vc_hi_font_mask is changed at fbcon_init(). When the vc_hi_font_mask is set, it remaps the attrs in the existing console buffer with one bit shift up (for 9 bits), while it remaps with one bit shift down (for 8 bits) when the value is cleared. It works fine as long as the font gets updated after fbcon was initialized. However, we hit a bizarre problem when the console is switched to another fb driver (typically from vesafb or efifb to drmfb). At switching to the new fb driver, we temporarily rebind the console to the dummy console, then rebind to the new driver. During the switching, we leave the modified attrs as is. Thus, the new fbcon takes over the old buffer as if it were to contain 8 bits chars (although the attrs are still shifted for 9 bits), and effectively this results in the yellow color texts instead of the original white color, as found in the bugzilla entry below. An easy fix for this is to re-adjust the attrs before leaving the fbcon at con_deinit callback. Since the code to adjust the attrs is already present in the current fbcon code, in this patch, we simply factor out the relevant code, and call it from fbcon_deinit(). Bugzilla: https://bugzilla.suse.com/show_bug.cgi?id=1000619 Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Diffstat (limited to 'security')
0 files changed, 0 insertions, 0 deletions