Re: [PATCH 1/5] pstore/ram: Consolidate kfree() paths

From: Guilherme G. Piccoli
Date: Wed Oct 12 2022 - 15:44:24 EST


On 11/10/2022 17:01, Kees Cook wrote:
> There's no reason to keep separate kfree() paths: either all allocations
> succeeded, or not. Everything is torn down in the case of failure, so
> adjust the callers to reflect this.
>
> Cc: Anton Vorontsov <anton@xxxxxxxxxx>
> Cc: Colin Cross <ccross@xxxxxxxxxxx>
> Cc: Tony Luck <tony.luck@xxxxxxxxx>
> Signed-off-by: Kees Cook <keescook@xxxxxxxxxxxx>
> ---
> fs/pstore/ram.c | 22 +++++++++++-----------
> 1 file changed, 11 insertions(+), 11 deletions(-)
>

Reviewed-and-tested-by: Guilherme G. Piccoli <gpiccoli@xxxxxxxxxx>

Tested by building / booting and triggering crashes with efi and ramoops
backends.
Cheers,


Guilherme