Re: [RFC 5/6] pstore: donot treat empty buffers as valid

2018-10-26 Thread Joel Fernandes
On Fri, Oct 26, 2018 at 08:39:13PM +0100, Kees Cook wrote: > On Fri, Oct 26, 2018 at 7:00 PM, Joel Fernandes (Google) > wrote: > > pstore currently calls persistent_ram_save_old even if a buffer is > > empty. While this appears to work, it is simply not the right thing to > > do and could lead to

Re: [RFC 5/6] pstore: donot treat empty buffers as valid

2018-10-26 Thread Kees Cook
On Fri, Oct 26, 2018 at 7:00 PM, Joel Fernandes (Google) wrote: > pstore currently calls persistent_ram_save_old even if a buffer is > empty. While this appears to work, it is simply not the right thing to > do and could lead to bugs so lets avoid that. It also prevent misleading > prints in the l

[RFC 5/6] pstore: donot treat empty buffers as valid

2018-10-26 Thread Joel Fernandes (Google)
pstore currently calls persistent_ram_save_old even if a buffer is empty. While this appears to work, it is simply not the right thing to do and could lead to bugs so lets avoid that. It also prevent misleading prints in the logs which claim the buffer is valid. Signed-off-by: Joel Fernandes (Goog