diff options
author | Aaron Ma <aaron.ma@canonical.com> | 2018-09-13 02:00:08 +0800 |
---|---|---|
committer | Ard Biesheuvel <ard.biesheuvel@linaro.org> | 2018-09-26 12:14:58 +0200 |
commit | b8b39bff3c7c07a5a8c85ebfd25d5b3ab3b3e2a1 (patch) | |
tree | 2d7a2dc0968ba53daea12b007d139db52b7f60b2 /arch/x86/platform | |
parent | 4eda11175fd9241908efb523b7f6e8a7c15afdb7 (diff) | |
download | linux-b8b39bff3c7c07a5a8c85ebfd25d5b3ab3b3e2a1.tar.gz linux-b8b39bff3c7c07a5a8c85ebfd25d5b3ab3b3e2a1.tar.bz2 linux-b8b39bff3c7c07a5a8c85ebfd25d5b3ab3b3e2a1.zip |
efi/x86: earlyprintk - Add 64bit efi fb address support
EFI GOP uses 64-bit frame buffer address in some BIOS.
Add 64bit address support in efi earlyprintk.
Signed-off-by: Aaron Ma <aaron.ma@canonical.com>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Diffstat (limited to 'arch/x86/platform')
-rw-r--r-- | arch/x86/platform/efi/early_printk.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/x86/platform/efi/early_printk.c b/arch/x86/platform/efi/early_printk.c index 5fdacb322ceb..7476b3b097e1 100644 --- a/arch/x86/platform/efi/early_printk.c +++ b/arch/x86/platform/efi/early_printk.c @@ -26,12 +26,14 @@ static bool early_efi_keep; */ static __init int early_efi_map_fb(void) { - unsigned long base, size; + u64 base, size; if (!early_efi_keep) return 0; base = boot_params.screen_info.lfb_base; + if (boot_params.screen_info.capabilities & VIDEO_CAPABILITY_64BIT_BASE) + base |= (u64)boot_params.screen_info.ext_lfb_base << 32; size = boot_params.screen_info.lfb_size; efi_fb = ioremap(base, size); @@ -46,9 +48,11 @@ early_initcall(early_efi_map_fb); */ static __ref void *early_efi_map(unsigned long start, unsigned long len) { - unsigned long base; + u64 base; base = boot_params.screen_info.lfb_base; + if (boot_params.screen_info.capabilities & VIDEO_CAPABILITY_64BIT_BASE) + base |= (u64)boot_params.screen_info.ext_lfb_base << 32; if (efi_fb) return (efi_fb + start); |