| From | John Ogness <> | Subject | [PATCH printk v2 06/38] tty: nfcon: use console_is_enabled() | Date | Wed, 19 Oct 2022 17:01:28 +0206 |
| |
Replace (console->flags & CON_ENABLED) usage with console_is_enabled().
Signed-off-by: John Ogness <john.ogness@linutronix.de> --- arch/m68k/emu/nfcon.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/m68k/emu/nfcon.c b/arch/m68k/emu/nfcon.c index 557d60867f98..c542fc2b121f 100644 --- a/arch/m68k/emu/nfcon.c +++ b/arch/m68k/emu/nfcon.c @@ -49,7 +49,7 @@ static void nfcon_write(struct console *con, const char *str, static struct tty_driver *nfcon_device(struct console *con, int *index) { *index = 0; - return (con->flags & CON_ENABLED) ? nfcon_tty_driver : NULL; + return console_is_enabled(con) ? nfcon_tty_driver : NULL; } static struct console nf_console = { @@ -151,7 +151,7 @@ static int __init nfcon_init(void) nfcon_tty_driver = driver; - if (!(nf_console.flags & CON_ENABLED)) + if (!console_is_enabled(&nf_console)) register_console(&nf_console); return 0; -- 2.30.2
|