Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 3050827E07A for ; Sun, 1 Mar 2026 01:24:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772328278; cv=none; b=BOugRmNIhESsrEtrt9EY+U5QHsCRNffO97DWHz/vZ5onwOGYFIXp7EYL8H2axCa/GdZwbMy5RxkI4uqSF+SDHA1DGH3GvY2YqhacJViJk4O+CIQGgHWalxQC07+t0vBkZ4u0Nmy+5KJq6L/SvtclYoH8qfZvg0E8LppWDu1G39M= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772328278; c=relaxed/simple; bh=UZtwMz5sW1+hrbJWun+5atmQ1Rt3jEw+JR/O8wl6ogo=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=O9++bJPe5ZoVx8uVdYBJHTrvOT+a1ciDVvchawseQKuMeBGJ4gwhO4CgUdO6OUHC7WIgN30+0Y55Iz7dfOBNMVbvgc4WkOhIIrrCI3QprFlyQ+aRB0dZKVHPXpVNLJFTCAB/60eb8Fc/vnh+MJpR85Otwih4NWus3jg9G/Fe9Kg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=NnDdYycJ; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="NnDdYycJ" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 68288C19421; Sun, 1 Mar 2026 01:24:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1772328278; bh=UZtwMz5sW1+hrbJWun+5atmQ1Rt3jEw+JR/O8wl6ogo=; h=From:To:Cc:Subject:Date:From; b=NnDdYycJ/yJpxOgBPT0QLaRGfMTLhoJNvRM3RzVNqBKEYmN9+O3BQEFaJp8q6rWcY Y0UvAnQl/LZfpJsBt3ySIREucVzn8z9XkIuPlx/T3Iq7XzON6g71PmE9M3DEZNfj4R DZTWxbqJ/gs+dIAlcNWHSC5/Z3Ce5s6N9jxobGsLHOwMujcjf5MoDwM++AcMc824yx xUzA5ZE7N2rixd6OKWY5K4NwCKElRRuJaanKOihEEjECGCIpBeeaLimS1R+B4ktm+k aSfc9xBuSf01ncRr8h7nPpo++GzApmQfValnA6+nS8SEplqN6lNnP4ne0aIJfVYS/b nfsoevsIhlGVQ== From: Sasha Levin To: stable@vger.kernel.org, dalaport@amazon.com Cc: Gunnar Kudrjavets , Mikhail Kshevetskiy , Miquel Raynal , linux-mtd@lists.infradead.org Subject: FAILED: Patch "mtd: spinand: Disable continuous read during probe" failed to apply to 6.12-stable tree Date: Sat, 28 Feb 2026 20:24:35 -0500 Message-ID: <20260301012436.1681493-1-sashal@kernel.org> X-Mailer: git-send-email 2.51.0 Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Patchwork-Hint: ignore X-stable: review Content-Transfer-Encoding: 8bit The patch below does not apply to the 6.12-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . Thanks, Sasha ------------------ original commit in Linus's tree ------------------ From b4af7d194dc879353829f3c56988a68fbba1fbdd Mon Sep 17 00:00:00 2001 From: David LaPorte Date: Thu, 29 Jan 2026 17:33:22 -0800 Subject: [PATCH] mtd: spinand: Disable continuous read during probe Macronix serial NAND devices with continuous read support do not clear the configuration register on soft reset and lack a hardware reset pin. When continuous read is interrupted (e.g., during reboot), the feature remains enabled at the device level. With continuous read enabled, the OOB area becomes inaccessible and all reads are instead directed to the main area. As a result, during partition allocation as part of MTD device registration, the first two bytes of the main area for the master block are read and indicate that the block is bad. This process repeats for every subsequent block for the partition. All reads and writes that reference the BBT find no good blocks and fail. The only paths for recovery from this state are triggering the continuous read feature by way of raw MTD reads or through a NAND device power drain. Disable continuous read explicitly during spinand probe to ensure quiescent feature state. Fixes: 631cfdd0520d ("mtd: spi-nand: Add continuous read support") Cc: stable@vger.kernel.org Signed-off-by: David LaPorte Reviewed-by: Gunnar Kudrjavets Reviewed-by: Mikhail Kshevetskiy Signed-off-by: Miquel Raynal --- drivers/mtd/nand/spi/core.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/mtd/nand/spi/core.c b/drivers/mtd/nand/spi/core.c index 21a980e626eb2..514f653f27f3e 100644 --- a/drivers/mtd/nand/spi/core.c +++ b/drivers/mtd/nand/spi/core.c @@ -940,6 +940,14 @@ static void spinand_cont_read_init(struct spinand_device *spinand) (engine_type == NAND_ECC_ENGINE_TYPE_ON_DIE || engine_type == NAND_ECC_ENGINE_TYPE_NONE)) { spinand->cont_read_possible = true; + + /* + * Ensure continuous read is disabled on probe. + * Some devices retain this state across soft reset, + * which leaves the OOB area inaccessible and results + * in false positive returns from spinand_isbad(). + */ + spinand_cont_read_enable(spinand, false); } } -- 2.51.0