1 From d278f43f25beedfd0cb784d1dd0a9e7e8c8f123f Mon Sep 17 00:00:00 2001
2 From: Daniel Golle <daniel@makrotopia.org>
3 Date: Wed, 19 Apr 2023 20:15:53 +0100
4 Subject: [PATCH] arm64: dts: mt7622: declare SPI-NAND present on BPI-R64
6 The SPI-NOR node in the device tree of the BananaPi R64 has most likely
7 been copied from the reference board's device tree even though the R64
8 comes with an SPI-NAND chip rather than SPI-NOR.
10 Setup the Serial NAND Flash Interface (SNFI) controller, enable
11 hardware BCH error detection and correction engine and add the SPI-NAND
12 chip including basic partitions,
14 Signed-off-by: Daniel Golle <daniel@makrotopia.org>
15 Link: https://lore.kernel.org/r/ZEA96dmaXqTpk8u8@makrotopia.org
16 Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
18 .../dts/mediatek/mt7622-bananapi-bpi-r64.dts | 38 ++++++++++++++++---
19 1 file changed, 33 insertions(+), 5 deletions(-)
21 --- a/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
22 +++ b/arch/arm64/boot/dts/mediatek/mt7622-bananapi-bpi-r64.dts
28 - pinctrl-names = "default";
29 - pinctrl-0 = <&spi_nor_pins>;
30 - status = "disabled";
36 + pinctrl-names = "default";
37 + pinctrl-0 = <&serial_nand_pins>;
40 - compatible = "jedec,spi-nor";
41 + compatible = "spi-nand";
43 + spi-tx-bus-width = <4>;
44 + spi-rx-bus-width = <4>;
45 + nand-ecc-engine = <&snfi>;
47 + compatible = "fixed-partitions";
48 + #address-cells = <1>;
53 + reg = <0x0 0x80000>;
59 + reg = <0x80000 0x200000>;
63 + ubi: partition@280000 {
65 + reg = <0x280000 0x7d80000>;