+ panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5
has been added to the -mm tree.  Its filename is
     panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Feng Tang <feng.tang@xxxxxxxxx>
Subject: panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5

Use logbuf lock to protect the console log index changing, suggested by
Petr Mladek.

Link: http://lkml.kernel.org/r/1556269868-22654-1-git-send-email-feng.tang@xxxxxxxxx
Signed-off-by: Feng Tang <feng.tang@xxxxxxxxx>
Reviewed-by: Petr Mladek <pmladek@xxxxxxxx>
Cc: Aaro Koskinen <aaro.koskinen@xxxxxxxxx>
Cc: Petr Mladek <pmladek@xxxxxxxx>
Cc: Steven Rostedt <rostedt@xxxxxxxxxxx>
Cc: Sergey Senozhatsky <sergey.senozhatsky.work@xxxxxxxxx>
Cc: Kees Cook <keescook@xxxxxxxxxxxx>
Cc: Borislav Petkov <bp@xxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 kernel/printk/printk.c |    4 ++++
 1 file changed, 4 insertions(+)

--- a/kernel/printk/printk.c~panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5
+++ a/kernel/printk/printk.c
@@ -2552,8 +2552,12 @@ void console_flush_on_panic(enum con_flu
 	console_may_schedule = 0;
 
 	if (mode == CONSOLE_REPLAY_ALL) {
+		unsigned long flags;
+
+		logbuf_lock_irqsave(flags);
 		console_seq = log_first_seq;
 		console_idx = log_first_idx;
+		logbuf_unlock_irqrestore(flags);
 	}
 	console_unlock();
 }
_

Patches currently in -mm which might be from feng.tang@xxxxxxxxx are

panic-avoid-the-extra-noise-dmesg.patch
panic-add-an-option-to-replay-all-the-printk-message-in-buffer.patch
panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v4.patch
panic-add-an-option-to-replay-all-the-printk-message-in-buffer-v5.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux