2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-16 09:13:55 +08:00
linux-next/fs/pstore
Ankit Kumar 4a16d1cb24 pstore: Don't warn if data is uncompressed and type is not PSTORE_TYPE_DMESG
commit 9abdcccc3d ("pstore: Extract common arguments into structure")
moved record decompression to function. decompress_record() gets
called without checking type and compressed flag. Warning will be
reported if data is uncompressed. Pstore type PSTORE_TYPE_PPC_OPAL,
PSTORE_TYPE_PPC_COMMON doesn't contain compressed data and warning get
printed part of dmesg.

Partial dmesg log:
[   35.848914] pstore: ignored compressed record type 6
[   35.848927] pstore: ignored compressed record type 8

Above warning should not get printed as it is known that data won't be
compressed for above type and it is valid condition.

This patch returns if data is not compressed and print warning only if
data is compressed and type is not PSTORE_TYPE_DMESG.

Reported-by: Anton Blanchard <anton@au1.ibm.com>
Signed-off-by: Ankit Kumar <ankit@linux.vnet.ibm.com>
Reviewed-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
Fixes: 9abdcccc3d ("pstore: Extract common arguments into structure")
Cc: stable@vger.kernel.org
2017-05-31 10:09:32 -07:00
..
ftrace.c pstore: Remove write_buf() callback 2017-03-07 14:01:02 -08:00
inode.c pstore: Solve lockdep warning by moving inode locks 2017-04-27 20:35:34 -07:00
internal.h pstore: Solve lockdep warning by moving inode locks 2017-04-27 20:35:34 -07:00
Kconfig docs: fix locations of several documents that got moved 2016-10-24 08:12:35 -02:00
Makefile pstore: add pstore unregister 2015-10-22 08:59:18 -07:00
platform.c pstore: Don't warn if data is uncompressed and type is not PSTORE_TYPE_DMESG 2017-05-31 10:09:32 -07:00
pmsg.c pstore: Remove unused vmalloc.h in pmsg 2017-04-27 14:48:59 -07:00
ram_core.c pstore: Use dynamic spinlock initializer 2017-03-07 08:21:38 -08:00
ram.c Annotation of module parameters that specify device settings 2017-05-10 19:13:03 -07:00