Re: [PATCH] power: snapshot: Remove unnecessary ‘0’ values from error
From: Rafael J. Wysocki
Date: Mon Dec 11 2023 - 16:04:06 EST
On Fri, Oct 20, 2023 at 10:51 AM Wang chaodong <chaodong@xxxxxxxxxxxx> wrote:
>
> error is assigned first, so it does not need to initialize the assignment.
>
> Signed-off-by: Wang chaodong <chaodong@xxxxxxxxxxxx>
> ---
> kernel/power/snapshot.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/power/snapshot.c b/kernel/power/snapshot.c
> index 87e9f7e2bdc05..9acdc4458a36d 100644
> --- a/kernel/power/snapshot.c
> +++ b/kernel/power/snapshot.c
> @@ -1119,7 +1119,7 @@ static void mark_nosave_pages(struct memory_bitmap *bm)
> int create_basic_memory_bitmaps(void)
> {
> struct memory_bitmap *bm1, *bm2;
> - int error = 0;
> + int error;
>
> if (forbidden_pages_map && free_pages_map)
> return 0;
> --
Applied as 6.8 material with rewritten subject and changelog.
Thanks!