]> git.ipfire.org Git - thirdparty/u-boot.git/commit
mtd: rawnand: sunxi: Replace hard coded value by a define
authorRichard Genoud <richard.genoud@bootlin.com>
Fri, 27 Mar 2026 14:05:04 +0000 (15:05 +0100)
committerAndre Przywara <andre.przywara@arm.com>
Thu, 30 Apr 2026 22:35:59 +0000 (00:35 +0200)
commit125bba0f61e3643de67d03c95e5cdcf5fded1f5b
treea68e41b0c10386da5ac7e995c93cae101e0b820a
parent11b5cd22bae8372447a8089df7a2400ac21ed021
mtd: rawnand: sunxi: Replace hard coded value by a define

The user data length (4) used all over the code hard coded.
And sometimes, it's not that trivial to know that it's the user data
length and not something else.
Moreover, for the H6/H616 this value is no more fixed by hardware, but
could be modified.

Using a define here makes the code more readable.

Suggested-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Richard Genoud <richard.genoud@bootlin.com>
Acked-by: Andre Przywara <andre.przywara@arm.com>
drivers/mtd/nand/raw/sunxi_nand.c
drivers/mtd/nand/raw/sunxi_nand.h
drivers/mtd/nand/raw/sunxi_nand_spl.c