[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20211026093141.64be4e38@xps13>
Date: Tue, 26 Oct 2021 09:31:41 +0200
From: Miquel Raynal <miquel.raynal@...tlin.com>
To: Andreas Oetken <ennoerlangen@...il.com>
Cc: Richard Weinberger <richard@....at>,
Vignesh Raghavendra <vigneshr@...com>,
linux-mtd@...ts.infradead.org, linux-kernel@...r.kernel.org,
Andreas Oetken <andreas.oetken@...mens-energy.com>
Subject: Re: [PATCH] drivers: mtd: Fixed breaking list in
__mtd_del_partition.
Hi Andreas,
ennoerlangen@...il.com wrote on Mon, 25 Oct 2021 22:57:24 +0200:
> Not the child partition should be removed from the partition list
> but the partition itself. Otherwise the partition list gets broken
> and any subsequent remove operations leads to a kernel panic.
>
Can you please Add a couple of Fixes: + Cc: stable tags?
> Signed-off-by: Andreas Oetken <andreas.oetken@...mens-energy.com>
> ---
> drivers/mtd/mtdpart.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mtd/mtdpart.c b/drivers/mtd/mtdpart.c
> index 95d47422bbf20..5725818fa199f 100644
> --- a/drivers/mtd/mtdpart.c
> +++ b/drivers/mtd/mtdpart.c
> @@ -313,7 +313,7 @@ static int __mtd_del_partition(struct mtd_info *mtd)
> if (err)
> return err;
>
> - list_del(&child->part.node);
> + list_del(&mtd->part.node);
> free_partition(mtd);
>
> return 0;
Thanks,
Miquèl
Powered by blists - more mailing lists