Commit e8857288 authored by Sumit Garg's avatar Sumit Garg Committed by Daniel Thompson

kdb: Check status of console prior to invoking handlers

Check if a console is enabled prior to invoking corresponding write
handler.
Suggested-by: default avatarSergey Senozhatsky <sergey.senozhatsky@gmail.com>
Signed-off-by: default avatarSumit Garg <sumit.garg@linaro.org>
Reviewed-by: default avatarDaniel Thompson <daniel.thompson@linaro.org>
Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
Reviewed-by: default avatarPetr Mladek <pmladek@suse.com>
Link: https://lore.kernel.org/r/1591264879-25920-3-git-send-email-sumit.garg@linaro.orgSigned-off-by: default avatarDaniel Thompson <daniel.thompson@linaro.org>
parent 9d71b344
......@@ -560,6 +560,8 @@ static void kdb_msg_write(const char *msg, int msg_len)
}
for_each_console(c) {
if (!(c->flags & CON_ENABLED))
continue;
c->write(c, msg, msg_len);
touch_nmi_watchdog();
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment