From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtpout-02.galae.net (smtpout-02.galae.net [185.246.84.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 272E7211A28 for ; Mon, 6 Jul 2026 14:22:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.246.84.56 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783347733; cv=none; b=TvsfSnQMqF8Okmz/Bgqdx87+DaTpqtZJxEFdfYL0uojRRk6xAR2CcwrgQ8Oa8YOJFFGOYwH2ego9lj5QE664qws3/ruh+qr7wPsPB4wdU9xORcB/gYuLBWlMZc0He+nKLrU/4IJECLc3tzXiwBl6SfB7eJdAuDYS0cHW4cWRmoE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783347733; c=relaxed/simple; bh=GctlaiONMyPzkPEnY3f3nOA5vXG751dF7MKGrq8wdoI=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=IwgcLEqiPPQkLATJ8oZp9c8smIQLfR6oMfEHo52H8jl+vLRa6FEVcKLQLY1bXVtU5i5TLjjumiXP3WUX4nCr0OQcaajAD9Few5/1LjlKZ2XqZVSjOt8wgeBhbV41GpDHHNoJDfwXqxJaEllBrrjBvMPYs4q9FTBKiwcBt2evMTI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=EabktF70; arc=none smtp.client-ip=185.246.84.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="EabktF70" Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-02.galae.net (Postfix) with ESMTPS id C477B1A0E8C; Mon, 6 Jul 2026 14:22:09 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 92BA0601A2; Mon, 6 Jul 2026 14:22:09 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id B5D4011BBA0E1; Mon, 6 Jul 2026 16:22:05 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1783347729; h=from:subject:date:message-id:to:cc:mime-version:content-type: in-reply-to:references; bh=hMvLtsm7HJEGV9CA9lPIbySySQBIuRWoc748T8Npwe4=; b=EabktF70DxXXfLpoD9d/2XOT81WvUIfoRFrtkP21b7Ls1yiRxQrERfDr7HTaZkiXyp0YA2 slEW+AhrjKb5bxds9lskQUU0m05bZ/srxZuLO1j5yVuMWLnYe/VFPBdVbfxMxwPwP5ePIA gIiNTObgi+gbMhTPTO2CZyitkXpY9HZbE6p0vefEjAPmvEfDH4xutzNQLx0wQGh2HJxqdB es1k3k15Qe3xXHFPbRPenmTwfc9bjyv75RVGcIQhqb9LC30mAn276Ogi8GPdjkCxCrEeuz IXwRK8OEUNpdV1d6hXUofj65/LDVfniBQy85+GYMOeykZJoUnv7V5AbpHRKiAg== From: Miquel Raynal To: Michael Walle Cc: Pratyush Yadav , Takahiro Kuwano , Richard Weinberger , Vignesh Raghavendra , Tudor Ambarus , linux-mtd@lists.infradead.org, Cheng Ming Lin , linux-kernel@vger.kernel.org Subject: Re: [PATCH v1 7/8] mtd: spi-nor: push the rollback mechanism into the sfdp module In-Reply-To: <20260703143003.1809579-8-mwalle@kernel.org> (Michael Walle's message of "Fri, 3 Jul 2026 16:29:18 +0200") References: <20260703143003.1809579-1-mwalle@kernel.org> <20260703143003.1809579-8-mwalle@kernel.org> User-Agent: mu4e 1.12.7; emacs 30.2 Date: Mon, 06 Jul 2026 16:22:05 +0200 Message-ID: <874iickxki.fsf@bootlin.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain X-Last-TLS-Session-Version: TLSv1.3 On 03/07/2026 at 16:29:18 +02, Michael Walle wrote: > Right now, the core is handling the rollback of the parameters. But it > doesn't have the knowledge what has to be rolled back. And in fact, > havent rolled back everything. Push it down to the called function and > make it mandatory, that this function has no side effects if it fails. > > Funny enough, there is a comment in the SFDP table handing code that handling? ^ > each table parser is responsible to roll back any changes. But none of > them did. So while add it, expand the logic to that and roll it back for > them. There is one simple rule though: > > SFDP parsing and fixups may only modify the spi_nor_flash_parameters. Ok. Reviewed-by: Miquel Raynal