]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
pstore: skip zero size persistent ram buffer in traverse
authorLiu ShuoX <shuox.liu@intel.com>
Mon, 17 Mar 2014 00:24:49 +0000 (11:24 +1100)
committerJiri Slaby <jslaby@suse.cz>
Sun, 8 Feb 2015 19:02:06 +0000 (20:02 +0100)
commit013d52e2500f66563ff14c74f43b68ab16cef9f1
treef652282d3664da9dc83f7b45dc2da3bfa83d264e
parent42ecc20bee44d55eb266116e9101bca9f7d6637a
pstore: skip zero size persistent ram buffer in traverse

commit aa9a4a1edfbd3d223af01db833da2f07850bc655 upstream.

In ramoops_pstore_read, a valid prz pointer with zero size buffer will
break traverse of all persistent ram buffers.  The latter buffer might be
lost.

Signed-off-by: Liu ShuoX <shuox.liu@intel.com>
Cc: "Zhang, Yanmin" <yanmin_zhang@linux.intel.com>
Cc: Colin Cross <ccross@android.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Cc: HuKeping <hukeping@huawei.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
fs/pstore/ram.c