lkml.org 
[lkml]   [2022]   [Oct]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH printk v2 08/38] efi: earlycon: use console_is_enabled()
On Wed, 19 Oct 2022 at 16:56, John Ogness <john.ogness@linutronix.de> wrote:
>
> Replace (console->flags & CON_ENABLED) usage with console_is_enabled().
>
> Signed-off-by: John Ogness <john.ogness@linutronix.de>

Acked-by: Ard BIesheuvel <ardb@kernel.org>

> ---
> drivers/firmware/efi/earlycon.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/firmware/efi/earlycon.c b/drivers/firmware/efi/earlycon.c
> index a52236e11e5f..8c27eb941d8e 100644
> --- a/drivers/firmware/efi/earlycon.c
> +++ b/drivers/firmware/efi/earlycon.c
> @@ -30,7 +30,7 @@ static void *efi_fb;
> static int __init efi_earlycon_remap_fb(void)
> {
> /* bail if there is no bootconsole or it has been disabled already */
> - if (!earlycon_console || !(earlycon_console->flags & CON_ENABLED))
> + if (!earlycon_console || !console_is_enabled(earlycon_console))
> return 0;
>
> efi_fb = memremap(fb_base, screen_info.lfb_size,
> @@ -43,7 +43,7 @@ early_initcall(efi_earlycon_remap_fb);
> static int __init efi_earlycon_unmap_fb(void)
> {
> /* unmap the bootconsole fb unless keep_bootcon has left it enabled */
> - if (efi_fb && !(earlycon_console->flags & CON_ENABLED))
> + if (efi_fb && !console_is_enabled(earlycon_console))
> memunmap(efi_fb);
> return 0;
> }
> --
> 2.30.2
>

\
 
 \ /
  Last update: 2022-10-19 17:39    [W:0.538 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site