linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Knut Petersen <Knut_Petersen@t-online.de>
To: Andrew Morton <akpm@osdl.org>
Cc: "Antonino A. Daplas" <adaplas@gmail.com>,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	linux-fbdev-devel@lists.sourceforge.net
Subject: [PATCH 1/1: 2.6.15-rc5-git3] Disable ywrap if not supported by fbcon scrolling code
Date: Tue, 13 Dec 2005 14:26:00 +0100	[thread overview]
Message-ID: <439ECBE8.5090002@t-online.de> (raw)

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>

diff -uprN -X linux/Documentation/dontdiff -x '*.bak' -x '*.ctx' linuxorig/drivers/video/console/fbcon.c linux/drivers/video/console/fbcon.c
--- linuxorig/drivers/video/console/fbcon.c	2005-12-13 13:09:56.000000000 +0100
+++ linux/drivers/video/console/fbcon.c	2005-12-13 13:55:20.000000000 +0100
@@ -1968,7 +1968,8 @@ static __inline__ void updatescrollmode(
 		divides(ypan, vc->vc_font.height) && vyres > yres;
 	int good_wrap = (cap & FBINFO_HWACCEL_YWRAP) &&
 		divides(ywrap, vc->vc_font.height) &&
-		divides(vc->vc_font.height, vyres);
+		divides(vc->vc_font.height, vyres) &&
+		divides(vc->vc_font.height, yres);
 	int reading_fast = cap & FBINFO_READS_FAST;
 	int fast_copyarea = (cap & FBINFO_HWACCEL_COPYAREA) &&
 		!(cap & FBINFO_HWACCEL_DISABLED);




-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click

             reply	other threads:[~2005-12-13 13:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-13 13:26 Knut Petersen [this message]
2005-12-13 15:43 ` [PATCH 1/1: 2.6.15-rc5-git3] Disable ywrap if not supported by fbcon scrolling code Antonino A. Daplas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=439ECBE8.5090002@t-online.de \
    --to=knut_petersen@t-online.de \
    --cc=adaplas@gmail.com \
    --cc=akpm@osdl.org \
    --cc=geert@linux-m68k.org \
    --cc=linux-fbdev-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).