drivers/intel/gma: Fix mismatching types for fb_add_framebuffer_info

GCC LTO found this.

Change-Id: I2d5a9a86dbb91a5505891a30c6e9072b1b4dfc92
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84056
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Arthur Heymans 2024-08-23 11:24:21 +02:00 committed by Felix Held
commit 070561a295
4 changed files with 15 additions and 5 deletions

View file

@ -16,14 +16,14 @@ is
----------------------------------------------------------------------------
function c_fb_add_framebuffer_info
function C_Fb_Add_Framebuffer_Info_Simple
(fb_addr: Interfaces.C.size_t;
x_resolution : word32;
y_resolution : word32;
bytes_per_line : word32;
bits_per_pixel : word8)
return Interfaces.C.size_t;
return Interfaces.C.int;
pragma import (C, c_fb_add_framebuffer_info, "fb_add_framebuffer_info");
pragma import (C, C_Fb_Add_Framebuffer_Info_Simple, "fb_add_framebuffer_info_simple");
end GMA.GFX_Init;

View file

@ -27,6 +27,7 @@ is
use type word64;
use type word32;
use type Interfaces.C.size_t;
use type Interfaces.C.int;
ports : Port_List;
@ -39,7 +40,7 @@ is
min_h : pos32 := Config.LINEAR_FRAMEBUFFER_MAX_WIDTH;
min_v : pos32 := Config.LINEAR_FRAMEBUFFER_MAX_HEIGHT;
fbinfo : Interfaces.C.size_t;
fbinfo : Interfaces.C.int;
begin
lightup_ok := 0;
@ -82,7 +83,7 @@ is
HW.GFX.GMA.Map_Linear_FB (linear_fb_addr, fb);
if linear_fb_addr /= 0 then
fbinfo := c_fb_add_framebuffer_info
fbinfo := C_Fb_Add_Framebuffer_Info_Simple
(fb_addr => Interfaces.C.size_t (linear_fb_addr),
x_resolution => word32 (fb.Width),
y_resolution => word32 (fb.Height),