]> git.ipfire.org Git - thirdparty/linux.git/commit
mtd: spinand: macronix: Enable randomizer support
authorCheng Ming Lin <chengminglin@mxic.com.tw>
Tue, 5 May 2026 01:34:53 +0000 (09:34 +0800)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Wed, 27 May 2026 09:07:10 +0000 (11:07 +0200)
commit8ac45f4ff182586bb06fd9b2dfa0dff2af0734a1
tree3616a7c2ea418e521630a9cd43610c497d05b965
parent54e1bc80af0c993afc6a2283722f8d4535b10d40
mtd: spinand: macronix: Enable randomizer support

Implement the 'set_randomizer' callback for Macronix SPI NAND chips.
The randomizer is enabled by setting bit 1 of the Configuration Register
(address 0x10).

This patch adds support for the following chips:
  - MX35LFxG24AD series
  - MX35UFxG24AD series

When the randomizer is enabled, data is scrambled internally during
program operations and automatically descrambled during read operations.
This helps reduce bit errors caused by program disturbance.

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.pdf
Signed-off-by: Cheng Ming Lin <chengminglin@mxic.com.tw>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
drivers/mtd/nand/spi/macronix.c