kernel: print log messages directly to the console if log_buffer is full
This commit is contained in:
@@ -63,6 +63,10 @@ int printk(const char *format, ...)
|
||||
msg[len] = '\n';
|
||||
msg[len + 1] = '\0';
|
||||
|
||||
if (log_buffer_writep == LOG_BUFFER_SIZE - 1) {
|
||||
console_write(early_console, msg, len + 1);
|
||||
}
|
||||
|
||||
unsigned long flags;
|
||||
spin_lock_irqsave(&log_buffer_lock, &flags);
|
||||
save_log_message(msg);
|
||||
|
||||
Reference in New Issue
Block a user