From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pg1-f179.google.com (mail-pg1-f179.google.com [209.85.215.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 45B6635CB97 for ; Wed, 11 Feb 2026 10:07:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.215.179 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770804441; cv=none; b=l+7YjGVUUN4zshjOB/enYBWuLHdYiOhPWNz4RbM6BL02xMbg8LVlsKIGHsW/fX9vPI9uamBp03SaIQm7w+Gpb3BOdnuZvsUN6/uOb75gTDMawhkGouRlT8S1PHrzLWYjAnlMBvkufuDFfAKijf3EyGYaTwikuxA/LwDz52qptUY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770804441; c=relaxed/simple; bh=sl3bc39oUMTf6PWwUN3zYrRwTc0cZh6qh/s+nUMt8ec=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=d0zzVutpH0yP6ajkBdfQSpqpgtJObIv5ERKNU2qCo38kvEz+HEOyLG965hAb5EXP/mWIc+kvfxE7Nl0c6IfxLKhHQOmQIp5+Y5lZKJj837iq7VVHLZJjNUgXJZcGcrFK9UJoUVUapdrmgWVCEYE6ca0cj51CxIGj94k3x5araQo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=LvzESxE3; arc=none smtp.client-ip=209.85.215.179 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="LvzESxE3" Received: by mail-pg1-f179.google.com with SMTP id 41be03b00d2f7-c6788f3db37so683500a12.1 for ; Wed, 11 Feb 2026 02:07:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1770804439; x=1771409239; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=sn/Y69Rs16zIbCUr1d6TW/gMLK4puZ79zycPXpVzP0A=; b=LvzESxE3kt68ii/YZXpEc7bA8CMgRqc2+7W1UeyJLIaoAjnpEiO/cgpHc3OAzgQf8Y yAeKmDRZr+weW9Qr6QrNwI8nitN6G69EqkH8yZY+IpLLVGVUYCYV24sZEjVcRtTBJrIQ ztGFzY+F2MyG8GZAXXZX8mv3dS3tRZ3jlES8XILHTXIYQxgr8H+7DkHcqDaybQFfbRh0 Qhg4j7KyMF1uQFDzvCbVArJdIVX7vOm+n0cdBuTnHIyMQxo+QmcnlhkGWt/3GXDEOJzT 4n5SPuWyvTsMX3SHcjFp/nJwi0OKxRRNHyJecO1bzZmmr8seQOBpmJNWUon5LYWz8Fb0 JO9A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1770804439; x=1771409239; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=sn/Y69Rs16zIbCUr1d6TW/gMLK4puZ79zycPXpVzP0A=; b=bKeQXh2rGTVoXWwclx1UKWlxJnSZUZWvqTCGABq/dO9jJ1KqXTwFIMhERM+m7i2SDY jmD7CnGNDJ8P39rNVZBs3TQMMLxpYbYo+ZyAbz5hfaqP2tcHetmqUZ9DPg76PgL8HlmX Gz/+y6dL8hg3malIbrDhqIrNIVV4xlWFCCuIW9uY3Wtu06wZf86F0+4b45RBkKu2IqiP nsbNtYxYOaXrYQPFK6L1du/yCyC4yhpgLPuXtPD5qmv4lUrURVbB3chKmVGxxpqybV8Y 2sotcB4vyV0YWBRJhjHqBGF5pmRanRTWCRFnnpM7ejpGzi6zPxRX/wTi7TCsq03yeYXo Y+5g== X-Forwarded-Encrypted: i=1; AJvYcCXQ56bTYZIBiOYRfhKiltFkuKSK9aYHdamhtS1Nbg0z9kHMpkXftoLKs/nbWd801porgWUeGdDY6FWP4kU=@vger.kernel.org X-Gm-Message-State: AOJu0YzC0PgKNhOlQ6S9GHBXf2SLZhLY447Kibb44CryjkSxE/QMH347 HC4iIkorAfe3LfN/X8aKEWiHHjXJo6KIA70gPKqzJ8fLGQZvZWnjqah9ws5gEw== X-Gm-Gg: AZuq6aK5IGvj9hT8wn8zEFuI12WUg6MA1SofmYNIA72/Z5zyxQ307p1iP6NYTEj+ZJc MTh1jyVvX83SIMIe1gojJfPmPwKNMtOaOuajQro7r280Kk/n2ctY5kt+usCMsZKFZfRvgiYuoZ9 xXupNE04VdJ+E0W94ox5gPKYvIKqy3Q/bOuYgMLWbOEyfgyHRl/kjZ2tDJ/+92ieHeMosb+fg8X 1PgeCmQZcHeA83byh4Sd1iz8XyvZf3f9PBtrVT23+sHEStTdtLjCqDrBehAoqdTL2ovn8PFA10E KyzOSVQuIRfopU3x+D56X5RrqeEaoL4ddwyeilW0FOatLf7GPpM2Aoq81t4NCyYUYBnF949J1up /f/MOwXRmuQ1gV6LXMaDObwM7Rb1r/JB7FPqoobve+VVrnLkQpileM6t+f7uCka4VYL4x5xxMmZ CN15psWNt3sPlc/UtMMOxqdF8fYBn9PRuU0IVkhvnFL+z+RQ== X-Received: by 2002:a17:90b:4a08:b0:354:b2f6:b4e4 with SMTP id 98e67ed59e1d1-354b39da597mr13513502a91.0.1770804439383; Wed, 11 Feb 2026 02:07:19 -0800 (PST) Received: from twhmp6px (mxsmtp211.mxic.com.tw. [211.75.127.162]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-3567e9fb4bfsm1632089a91.8.2026.02.11.02.07.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 11 Feb 2026 02:07:19 -0800 (PST) Received: from hqs-appsw-a2o.mp600.macronix.com (unknown [172.17.236.67]) by twhmp6px (Postfix) with ESMTPS id E8D704136074; Wed, 11 Feb 2026 18:07:16 +0800 (CST) From: Cheng Ming Lin To: Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: Tudor Ambarus , Mikhail Kshevetskiy , Pablo Martin-Gomez , Tianling Shen , Pratyush Yadav , linux-mtd@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, alvinzhou@mxic.com.tw, Cheng Ming Lin Subject: [PATCH v5 1/3] dt-bindings: mtd: spinand: Add randomizer enable/disable properties Date: Wed, 11 Feb 2026 18:05:51 +0800 Message-Id: <20260211100553.907585-2-linchengming884@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20260211100553.907585-1-linchengming884@gmail.com> References: <20260211100553.907585-1-linchengming884@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Cheng Ming Lin Add "nand-randomizer-enable" and "nand-randomizer-disable" boolean properties. These properties allow enabling or disabling the randomizer feature via the device tree. According to JEDEC standard JESD22-A117E, no single data pattern represents a universal worst-case for all NAND flash failure mechanisms. Different patterns, such as fully programmed, checkerboard, or mostly erased, can disproportionately stress specific cells (e.g., programmed, erased, or those influenced by adjacent states). Given that no fixed pattern can cover all scenarios, the use of a randomized data pattern is a practical and effective mitigation strategy. Our hardware implements a randomizer feature that scrambles user data before it is written to the flash and restores the original data upon read. This ensures the data stored on the media is more evenly distributed, thus reducing pattern-dependent degradation. This is especially crucial for preventing errors caused by unbalanced data (e.g., all zeros or all ones) in blocks with high program/erase (P/E) cycle counts. Ultimately, the randomizer improves the long-term reliability and endurance of the flash device. Please refer to the following link for randomizer feature: Link: https://www.mxic.com.tw/Lists/ApplicationNote/Attachments/2151/AN1051V1-The%20Introduction%20of%20Randomizer%20Feature%20on%20MX30xFxG28AD_MX35xFxG24AD. Signed-off-by: Cheng Ming Lin --- Documentation/devicetree/bindings/mtd/nand-chip.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Documentation/devicetree/bindings/mtd/nand-chip.yaml b/Documentation/devicetree/bindings/mtd/nand-chip.yaml index 609d4a4ddd80..2fcbc4b73e95 100644 --- a/Documentation/devicetree/bindings/mtd/nand-chip.yaml +++ b/Documentation/devicetree/bindings/mtd/nand-chip.yaml @@ -67,6 +67,14 @@ properties: the secure regions present. $ref: /schemas/types.yaml#/definitions/uint64-matrix + nand-randomizer-enable: + description: Enable the randomizer feature. + type: boolean + + nand-randomizer-disable: + description: Disable the randomizer feature. + type: boolean + required: - reg -- 2.25.1