Skip to content

Commit f1d1853

Browse files
nivedita76ardbiesheuvel
authored andcommitted
efi/gop: Use helper macros for populating lfb_base
Use the lower/upper_32_bits macros from kernel.h to initialize si->lfb_base and si->ext_lfb_base. Signed-off-by: Arvind Sankar <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Ard Biesheuvel <[email protected]>
1 parent e484c59 commit f1d1853

File tree

1 file changed

+2
-2
lines changed
  • drivers/firmware/efi/libstub

1 file changed

+2
-2
lines changed

drivers/firmware/efi/libstub/gop.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,8 @@ static efi_status_t setup_gop(struct screen_info *si, efi_guid_t *proto,
158158
si->lfb_height = info->vertical_resolution;
159159

160160
fb_base = efi_table_attr(mode, frame_buffer_base);
161-
si->lfb_base = fb_base;
162-
si->ext_lfb_base = (u64)(unsigned long)fb_base >> 32;
161+
si->lfb_base = lower_32_bits(fb_base);
162+
si->ext_lfb_base = upper_32_bits(fb_base);
163163
if (si->ext_lfb_base)
164164
si->capabilities |= VIDEO_CAPABILITY_64BIT_BASE;
165165

0 commit comments

Comments
 (0)