Skip to content

Commit 19d8e91

Browse files
jiribohackees
authored andcommitted
pstore: Fix typo in compression option name
Both pstore_compress() and decompress_record() use a mistyped config option name ("PSTORE_COMPRESSION" instead of "PSTORE_COMPRESS"). As a result compression and decompression of pstore records was always disabled. Use the correct config option name. Signed-off-by: Jiri Bohac <jbohac@suse.cz> Fixes: fd49e03 ("pstore: Fix linking when crypto API disabled") Acked-by: Matteo Croce <mcroce@microsoft.com> Signed-off-by: Kees Cook <keescook@chromium.org> Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20210218111547.johvp5klpv3xrpnn@dwarf.suse.cz
1 parent f40ddce commit 19d8e91

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

fs/pstore/platform.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ static int pstore_compress(const void *in, void *out,
269269
{
270270
int ret;
271271

272-
if (!IS_ENABLED(CONFIG_PSTORE_COMPRESSION))
272+
if (!IS_ENABLED(CONFIG_PSTORE_COMPRESS))
273273
return -EINVAL;
274274

275275
ret = crypto_comp_compress(tfm, in, inlen, out, &outlen);
@@ -671,7 +671,7 @@ static void decompress_record(struct pstore_record *record)
671671
int unzipped_len;
672672
char *unzipped, *workspace;
673673

674-
if (!IS_ENABLED(CONFIG_PSTORE_COMPRESSION) || !record->compressed)
674+
if (!IS_ENABLED(CONFIG_PSTORE_COMPRESS) || !record->compressed)
675675
return;
676676

677677
/* Only PSTORE_TYPE_DMESG support compression. */

0 commit comments

Comments
 (0)