From: "Ville Syrjälä" <syrjala@sci.fi>
To: Mikulas Patocka <mpatocka@redhat.com>
Cc: linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org,
Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Subject: Re: [PATCH] mach64: fix console corruption in 24bpp mode
Date: Sun, 19 Aug 2018 10:26:28 +0000 [thread overview]
Message-ID: <20180819102628.GA11867@sci.fi> (raw)
In-Reply-To: <alpine.LRH.2.02.1808171514010.31883@file01.intranet.prod.int.rdu2.redhat.com>
On Fri, Aug 17, 2018 at 03:15:52PM -0400, Mikulas Patocka wrote:
> There's console font corruption when using the mach64 driver in 24bpp
> mode.
>
> In 24bpp mode, the mach64 accelerator is set up for 8-bpp mode (with
> horizontal width and stride multiplied by 3). In this mode, the
> accelerator can't even possibly support color expansion. Consquently, we
> have to use an unaccelerated function cfb_imageblit for color expansion.
Hmm. I would think it should work just fine since we feed in each bit
three times and the hw 24bpp rotate thing should take care of selecting
the right component.
- if (M64_HAS(HW_TRIPLE) && image->width % 8 = 0)
+ if (M64_HAS(HW_TRIPLE) && width % 8 = 0)
pix_width |= DP_HOST_TRIPLE_EN;
perhaps?
> Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
> Cc: stable@vger.kernel.org
>
> ---
> drivers/video/fbdev/aty/mach64_accel.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> Index: linux-stable/drivers/video/fbdev/aty/mach64_accel.c
> =================================> --- linux-stable.orig/drivers/video/fbdev/aty/mach64_accel.c 2018-04-20 18:11:01.000000000 +0200
> +++ linux-stable/drivers/video/fbdev/aty/mach64_accel.c 2018-08-13 17:37:04.000000000 +0200
> @@ -291,7 +291,8 @@ void atyfb_imageblit(struct fb_info *inf
> if (!image->width || !image->height)
> return;
> if (!par->accel_flags ||
> - (image->depth != 1 && info->var.bits_per_pixel != image->depth)) {
> + (image->depth != 1 && info->var.bits_per_pixel != image->depth) ||
> + (image->depth = 1 && info->var.bits_per_pixel = 24)) {
> cfb_imageblit(info, image);
> return;
> }
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
--
Ville Syrjälä
syrjala@sci.fi
http://www.sci.fi/~syrjala/
next prev parent reply other threads:[~2018-08-19 10:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-17 19:15 [PATCH] mach64: fix console corruption in 24bpp mode Mikulas Patocka
2018-08-19 10:26 ` Ville Syrjälä [this message]
2018-08-25 19:48 ` Mikulas Patocka
2018-08-25 19:55 ` Mikulas Patocka
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=20180819102628.GA11867@sci.fi \
--to=syrjala@sci.fi \
--cc=b.zolnierkie@samsung.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-fbdev@vger.kernel.org \
--cc=mpatocka@redhat.com \
/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).