Kexec Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] makedumpfile: harden parsing of old prink buffer
@ 2022-03-07 17:23 Philipp Rudo
  2022-03-07 17:23 ` [PATCH 1/3] makedumpfile: add generic cycle detection Philipp Rudo
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Philipp Rudo @ 2022-03-07 17:23 UTC (permalink / raw)
  To: kexec

Hi,

dumping the dmesg can cause an endless loop for the old prink mechanism (>
v3.5.0 and < v5.10.0) when the log_buf got corrupted. This series fixes those
cases by adding a cycle detection. The cycle detection is implemented in a
generic way so that it can be reused in other parts of makedumpfile.

Thanks
Philipp

Philipp Rudo (3):
  makedumpfile: add generic cycle detection
  makedumpfile: use pointer arithmetics for dump_dmesg
  makedumpfile: use cycle detection when parsing the prink log_buf

 Makefile       |  2 +-
 detect_cycle.c | 99 ++++++++++++++++++++++++++++++++++++++++++++++++++
 detect_cycle.h | 40 ++++++++++++++++++++
 makedumpfile.c | 65 +++++++++++++++++++++++++--------
 4 files changed, 190 insertions(+), 16 deletions(-)
 create mode 100644 detect_cycle.c
 create mode 100644 detect_cycle.h

-- 
2.35.1



^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2022-03-11 12:28 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-03-07 17:23 [PATCH 0/3] makedumpfile: harden parsing of old prink buffer Philipp Rudo
2022-03-07 17:23 ` [PATCH 1/3] makedumpfile: add generic cycle detection Philipp Rudo
2022-03-07 17:23 ` [PATCH 2/3] makedumpfile: use pointer arithmetics for dump_dmesg Philipp Rudo
2022-03-09  8:25   ` David Wysochanski
2022-03-07 17:23 ` [PATCH 3/3] makedumpfile: use cycle detection when parsing the prink log_buf Philipp Rudo
2022-03-09  8:48   ` David Wysochanski
2022-03-10 14:33     ` Philipp Rudo
2022-03-11  7:59       ` HAGIO KAZUHITO =?unknown-8bit?b?6JCp5bC+IOS4gOS7gQ==?=
2022-03-11 12:28         ` Philipp Rudo
2022-03-08 17:16 ` [PATCH 0/3] makedumpfile: harden parsing of old prink buffer David Wysochanski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox