From 9744d1a547847dea89277b00606fe4c837c1b4ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Danis?= Date: Fri, 20 Mar 2020 10:59:22 +0100 Subject: cmd: Add command to display or save Linux PStore dumps MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch adds a new pstore command allowing to display or save ramoops logs (oops, panic, console, ftrace and user) generated by a previous kernel crash. PStore parameters can be set in U-Boot configuration file, or at run-time using "pstore set" command. Records size should be the same as the ones used by kernel, and should be a power of 2. This command allows: - to display uncompressed logs - to save compressed or uncompressed logs, compressed logs are saved as a compressed stream, it may need some work to be able to decompress it, e.g. adding a fake header: "printf "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\x00" | cat - dmesg-ramoops-0.enc.z | gzip -dc" - ECC part is not used to check memory corruption - only 1st FTrace log is displayed or saved Signed-off-by: Frédéric Danis [trini: Minor updates for current design, correct spacing in rST] Signed-off-by: Tom Rini Cc: Heinrich Schuchardt Cc: Wolfgang Denk Cc: Heiko Schocher --- cmd/Makefile | 1 + 1 file changed, 1 insertion(+) (limited to 'cmd/Makefile') diff --git a/cmd/Makefile b/cmd/Makefile index 015b837..19a8916 100644 --- a/cmd/Makefile +++ b/cmd/Makefile @@ -116,6 +116,7 @@ obj-$(CONFIG_CMD_PCI) += pci.o endif obj-$(CONFIG_CMD_PINMUX) += pinmux.o obj-$(CONFIG_CMD_PMC) += pmc.o +obj-$(CONFIG_CMD_PSTORE) += pstore.o obj-$(CONFIG_CMD_PXE) += pxe.o pxe_utils.o obj-$(CONFIG_CMD_WOL) += wol.o obj-$(CONFIG_CMD_QFW) += qfw.o -- cgit v1.1