pstore: Enable compression on normal path (again)
authorNamhyung Kim <namhyung@kernel.org>
Wed, 18 May 2016 12:00:05 +0000 (21:00 +0900)
committerKees Cook <keescook@chromium.org>
Tue, 31 May 2016 19:36:44 +0000 (12:36 -0700)
commit98e44fda2ea19c0e8b0a2e0e4dcd3461251f09ea
treee467d0b5acdc426d6c1aa4354f12644fb5f453f8
parenta1db8060f5c85e33ed810038036f409eed15decc
pstore: Enable compression on normal path (again)

The commit f0e2efcfd2717 ("pstore: do not use message compression
without lock") added a check to 'is_locked' to avoid breakage in
concurrent accesses.  But it has a side-effect of disabling compression
on normal path since 'is_locked' variable is not set.  As normal path
always takes the lock, it should be initialized to 1.

This also makes the unlock code a bit simpler.

Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
fs/pstore/platform.c