drivers/intel: Add support for configurable footer logo bottom margin
Introduces logo_bottom_margin to soc_intel_common_config to allow adjusting the vertical (or horizontal, based on orientation) offset of the footer logo from the screen edge. This provides flexibility for OEM branding placement. BUG=b:423591644 TEST=Able to show OEM splash screen on google/fatcat. Change-Id: Ie3942d9eee07091286118ac488d1cc85ecc96c4c Signed-off-by: Subrata Banik <subratabanik@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/88163 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Kapil Porwal <kapilporwal@google.com>
This commit is contained in:
parent
3e0d8a2f2c
commit
97f92d5c69
2 changed files with 11 additions and 0 deletions
|
|
@ -185,6 +185,15 @@ static int render_logo_to_framebuffer(uintptr_t framebuffer_base, uint32_t bytes
|
|||
logo_coords = calculate_logo_coordinates(horizontal_resolution,
|
||||
vertical_resolution, logo_width, logo_height, valignment, halignment);
|
||||
|
||||
/* Adjust the logo axis for rendering footer bootsplash if any override is available */
|
||||
if (logo_type == BOOTSPLASH_FOOTER && config->logo_bottom_margin) {
|
||||
if (config->panel_orientation == LB_FB_ORIENTATION_BOTTOM_UP ||
|
||||
config->panel_orientation == LB_FB_ORIENTATION_NORMAL)
|
||||
logo_coords.y -= config->logo_bottom_margin;
|
||||
else
|
||||
logo_coords.x -= config->logo_bottom_margin;
|
||||
}
|
||||
|
||||
copy_logo_to_framebuffer(framebuffer_base, bytes_per_scanline, blt_buffer_addr,
|
||||
logo_width, logo_height, logo_coords.x, logo_coords.y);
|
||||
|
||||
|
|
|
|||
|
|
@ -127,6 +127,8 @@ struct soc_intel_common_config {
|
|||
struct mmc_dll_params emmc_dll;
|
||||
enum lb_fb_orientation panel_orientation;
|
||||
enum fw_splash_vertical_alignment logo_valignment;
|
||||
/* Implies spacing from an edge for rendering footer logo */
|
||||
uint8_t logo_bottom_margin;
|
||||
};
|
||||
|
||||
/* This function to retrieve soc config structure required by common code */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue