aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video
diff options
context:
space:
mode:
authorKnut Petersen <Knut_Petersen@t-online.de>2006-01-09 23:53:36 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-01-10 11:01:50 -0500
commit244ab72d84a04d40bd270da604161e02af73fb11 (patch)
tree7a5c97cdcbf0bf6a56a05839ee233a250d4c9eea /drivers/video
parent3f08ff4a4dab1ebef06d154050fb80ce2c13fc9c (diff)
[PATCH] fbcon: disable ywrap if not supported by fbcon scrolling code
updatescrollmode() must not select ywrap scrolling if divides(vc->vc_font.height, yres) is not true as this is not supported by the actual ywrap scrolling code. The bug is triggered with e.g. mode 800x600, vxres 1024, vyres 8192, bpp 8, font dimensions 8x16, 8Mb video ram and FBINFO_HWACCEL_YWRAP set. If those conditions are met, scrolling is broken and garbage is permanently displayed at the bottom of the screen. No regression, no possible side effects. Definitely needed by cyblafb and probably needed by amifb. Signed-off-by: Knut Petersen <Knut_Petersen@t-online.de> Acked-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/video')
-rw-r--r--drivers/video/console/fbcon.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c
index f05afc02de2a..4f6fc785e95f 100644
--- a/drivers/video/console/fbcon.c
+++ b/drivers/video/console/fbcon.c
@@ -1965,7 +1965,8 @@ static __inline__ void updatescrollmode(struct display *p,
1965 divides(ypan, vc->vc_font.height) && vyres > yres; 1965 divides(ypan, vc->vc_font.height) && vyres > yres;
1966 int good_wrap = (cap & FBINFO_HWACCEL_YWRAP) && 1966 int good_wrap = (cap & FBINFO_HWACCEL_YWRAP) &&
1967 divides(ywrap, vc->vc_font.height) && 1967 divides(ywrap, vc->vc_font.height) &&
1968 divides(vc->vc_font.height, vyres); 1968 divides(vc->vc_font.height, vyres) &&
1969 divides(vc->vc_font.height, yres);
1969 int reading_fast = cap & FBINFO_READS_FAST; 1970 int reading_fast = cap & FBINFO_READS_FAST;
1970 int fast_copyarea = (cap & FBINFO_HWACCEL_COPYAREA) && 1971 int fast_copyarea = (cap & FBINFO_HWACCEL_COPYAREA) &&
1971 !(cap & FBINFO_HWACCEL_DISABLED); 1972 !(cap & FBINFO_HWACCEL_DISABLED);