aboutsummaryrefslogtreecommitdiff
path: root/src/drivers/intel/gma/gma-gfx_init.ads
diff options
context:
space:
mode:
authorPatrick Rudolph <patrick.rudolph@9elements.com>2020-02-19 12:54:06 +0100
committerPatrick Rudolph <siro@das-labor.org>2020-12-14 08:21:22 +0000
commit92106b166671a315a2b1e8f5cc467f2fa0823301 (patch)
treecafe3140a79757b87133b1e12f2420c43e02618c /src/drivers/intel/gma/gma-gfx_init.ads
parenta3495c0d7b249ce5cf53335d2036e31f1a86739c (diff)
drivers: Replace multiple fill_lb_framebuffer with single instance
Currently it's not possible to add multiple graphics drivers into one coreboot image. This patch series will fix this issue by providing a single API that multiple graphics drivers can use. This is required for platforms that have two graphic cards, but different graphic drivers, like Intel+Aspeed on server platforms or Intel+Nvidia on consumer notebooks. The goal is to remove duplicated fill_fb_framebuffer(), the advertisment of multiple independent framebuffers in coreboot tables, and better runtime/build time graphic configuration options. Replace all duplications of fill_fb_framebuffer and provide a single one in edid_fill_fb.c. Should not change the current behaviour as still only one graphic driver can be active at time. Change-Id: Ife507f7e7beaf59854e533551b4b87ea6980c1f4 Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/39003 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: Frans Hendriks <fhendriks@eltan.com> Reviewed-by: Christian Walter <christian.walter@9elements.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/drivers/intel/gma/gma-gfx_init.ads')
-rw-r--r--src/drivers/intel/gma/gma-gfx_init.ads32
1 files changed, 9 insertions, 23 deletions
diff --git a/src/drivers/intel/gma/gma-gfx_init.ads b/src/drivers/intel/gma/gma-gfx_init.ads
index 84c4a5b6db..4998d3312e 100644
--- a/src/drivers/intel/gma/gma-gfx_init.ads
+++ b/src/drivers/intel/gma/gma-gfx_init.ads
@@ -13,28 +13,14 @@ is
----------------------------------------------------------------------------
- type lb_framebuffer is record
- tag : word32;
- size : word32;
-
- physical_address : word64;
- x_resolution : word32;
- y_resolution : word32;
- bytes_per_line : word32;
- bits_per_pixel : word8;
- red_mask_pos : word8;
- red_mask_size : word8;
- green_mask_pos : word8;
- green_mask_size : word8;
- blue_mask_pos : word8;
- blue_mask_size : word8;
- reserved_mask_pos : word8;
- reserved_mask_size : word8;
- end record;
-
- function fill_lb_framebuffer
- (framebuffer : in out lb_framebuffer)
- return Interfaces.C.int;
- pragma Export (C, fill_lb_framebuffer, "fill_lb_framebuffer");
+ function c_fb_add_framebuffer_info
+ (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;
+
+ pragma import (C, c_fb_add_framebuffer_info, "fb_add_framebuffer_info");
end GMA.GFX_Init;