lkml.org 
[lkml]   [2022]   [Mar]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 3/5] drm: ssd130x: Fix rectangle updates
From
On 3/15/22 12:07, Geert Uytterhoeven wrote:
> The rectangle update functions ssd130x_fb_blit_rect() and
> ssd130x_update_rect() do not behave correctly when x1 != 0 or y1 !=
> 0, or when y1 or y2 are not aligned to display page boundaries.
> E.g. when used as a text console, only the first line of text is shown
> on the display.
>
> 1. The buffer passed by ssd130x_fb_blit_rect() points to the first
> byte of monochrome bitmap data, and thus has its origin at (x1,
> y1), while ssd130x_update_rect() assumes it is at (0, 0).
> Fix ssd130x_update_rect() by changing the vertical and horizontal
> loop ranges, and adding the offsets only when needed.
>
> 2. In ssd130x_fb_blit_rect(), align y1 and y2 to the display page
> boundaries before doing the color conversion, so the full page
> is converted and updated.
> Remove the correction for an unaligned y1 from
> ssd130x_update_rect(), and add a check to make sure y1 is aligned.
>
> Fixes: a61732e808672cfa ("drm: Add driver for Solomon SSD130x OLED displays")
> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
> ---

Thanks for fixing this too.

Acked-by: Javier Martinez Canillas <javierm@redhat.com>

--
Best regards,

Javier Martinez Canillas
Linux Engineering
Red Hat

\
 
 \ /
  Last update: 2022-03-15 13:29    [W:0.113 / U:1.748 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site