pstore/ram_core: Proper checking for post_init errors (e.g. improper ECC size)
authorAnton Vorontsov <anton.vorontsov@linaro.org>
Tue, 19 Jun 2012 02:15:52 +0000 (19:15 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 20 Jun 2012 23:15:22 +0000 (16:15 -0700)
commitbeeb94321a7a6d493b4a06ff0cd771f09f41c35e
treeae276de7228bf62512d5a9ce3b65c76017a6def0
parent90b58d96907e0a45555429c0d3a79c85cea4b9fc
pstore/ram_core: Proper checking for post_init errors (e.g. improper ECC size)

We will implement variable-sized ECC buffers soon, so post_init routine
might fail much more likely, so we'd better check for its errors.

To make error handling simple, modify persistent_ram_free() to it be safe
at all times.

Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
Acked-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/pstore/ram_core.c