lkml.org 
[lkml]   [2023]   [Apr]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] firmware/sysfb: Fix wrong stride when bits-per-pixel is calculated
Date
"Pierre Asselin" <pa@panix.com> writes:

>> The commit f35cd3fa7729 ("firmware/sysfb: Fix EFI/VESA format selection")
>> fixed format selection, by calculating the bits-per-pixel instead of just
>> using the reported color depth.
>>
>> But unfortunately this broke some modes because the stride is always set
>> to the reported line length (in bytes), which could not match the actual
>> stride if the calculated bits-per-pixel doesn't match the reported depth.
>>
>> Fixes: f35cd3fa7729 ("firmware/sysfb: Fix EFI/VESA format selection")
>> Reported-by: Pierre Asselin <pa@panix.com>
>> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
>> ---
>>
>> drivers/firmware/sysfb_simplefb.c | 9 +++++++--
>> 1 file changed, 7 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/firmware/sysfb_simplefb.c
>> b/drivers/firmware/sysfb_simplefb.c
>> index 82c64cb9f531..5dc23e57089f 100644
>> --- a/drivers/firmware/sysfb_simplefb.c
>> +++ b/drivers/firmware/sysfb_simplefb.c
>>
>> [patch elided]
>
> NOOOOOO ! The 1024x768x32 screen is all garbled.
> (gfxpayload=keep, gfxpayload=1024x768x32 or vga=0x318).
>

That's suprising... I tested the patch with vga=ask and picked
1024x768x15, 1024x768x16, 1024x768x24 and 1024x768x32. For all
cases the bits-per-pixel and line length values were correct.

But I don't have a machine with legacy BIOS so I testee using QEMU and
SeaBIOS.

> The other modes work as before (but the dmesg has less information;
> I'll investigate.)
>

Interesting. So you don't have the simplefb output that you had before ?

--
Best regards,

Javier Martinez Canillas
Core Platforms
Red Hat

\
 
 \ /
  Last update: 2023-04-12 19:32    [W:0.058 / U:0.384 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site