developer | 538f2d1 | 2024-11-05 15:54:46 +0800 | [diff] [blame] | 1 | From: Weijie Gao <weijie.gao@mediatek.com> |
| 2 | Subject: [PATCH] mediatek/filogic: add fitblk support for MediaTek RFBs |
| 3 | |
| 4 | Add fitblk support for MediaTek RFBs |
| 5 | |
| 6 | Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> |
| 7 | |
| 8 | --- a/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7981-rfb.dts |
| 9 | +++ b/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7981-rfb.dts |
| 10 | @@ -113,6 +113,22 @@ |
| 11 | }; |
| 12 | }; |
| 13 | |
| 14 | + spi2_flash_pins: spi2-pins { |
| 15 | + mux { |
| 16 | + function = "spi"; |
| 17 | + groups = "spi2", "spi2_wp_hold"; |
| 18 | + }; |
| 19 | + conf-pu { |
| 20 | + pins = "SPI2_CS", "SPI2_HOLD", "SPI2_WP"; |
| 21 | + drive-strength = <MTK_DRIVE_8mA>; |
| 22 | + bias-pull-up = <MTK_PUPD_SET_R1R0_11>; |
| 23 | + }; |
| 24 | + conf-pd { |
| 25 | + pins = "SPI2_CLK", "SPI2_MOSI", "SPI2_MISO"; |
| 26 | + drive-strength = <MTK_DRIVE_8mA>; |
| 27 | + bias-pull-down = <MTK_PUPD_SET_R1R0_11>; |
| 28 | + }; |
| 29 | + }; |
| 30 | }; |
| 31 | |
| 32 | &spi0 { |
| 33 | --- a/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a-rfb-emmc.dtso |
| 34 | +++ b/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a-rfb-emmc.dtso |
| 35 | @@ -28,6 +28,34 @@ |
| 36 | no-sd; |
| 37 | no-sdio; |
| 38 | status = "okay"; |
| 39 | + |
| 40 | + card@0 { |
| 41 | + compatible = "mmc-card"; |
| 42 | + reg = <0>; |
| 43 | + |
| 44 | + block { |
| 45 | + compatible = "block-device"; |
| 46 | + partitions { |
| 47 | + block-partition-env { |
| 48 | + partname = "u-boot-env"; |
| 49 | + nvmem-layout { |
| 50 | + compatible = "u-boot,env-layout"; |
| 51 | + }; |
| 52 | + }; |
| 53 | + |
| 54 | + emmc_rootfs: block-partition-production { |
| 55 | + partname = "firmware"; |
| 56 | + }; |
| 57 | + }; |
| 58 | + }; |
| 59 | + }; |
| 60 | + }; |
| 61 | + }; |
| 62 | + |
| 63 | + fragment@2 { |
| 64 | + target-path = "/chosen"; |
| 65 | + __overlay__ { |
| 66 | + rootdisk-emmc = <&emmc_rootfs>; |
| 67 | }; |
| 68 | }; |
| 69 | }; |
| 70 | --- a/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a-rfb-sd.dtso |
| 71 | +++ b/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a-rfb-sd.dtso |
| 72 | @@ -26,6 +26,34 @@ |
| 73 | vqmmc-supply = <®_3p3v>; |
| 74 | no-mmc; |
| 75 | status = "okay"; |
| 76 | + |
| 77 | + card@0 { |
| 78 | + compatible = "mmc-card"; |
| 79 | + reg = <0>; |
| 80 | + |
| 81 | + block { |
| 82 | + compatible = "block-device"; |
| 83 | + partitions { |
| 84 | + block-partition-env { |
| 85 | + partname = "u-boot-env"; |
| 86 | + nvmem-layout { |
| 87 | + compatible = "u-boot,env-layout"; |
| 88 | + }; |
| 89 | + }; |
| 90 | + |
| 91 | + sd_rootfs: block-partition-production { |
| 92 | + partname = "firmware"; |
| 93 | + }; |
| 94 | + }; |
| 95 | + }; |
| 96 | + }; |
| 97 | + }; |
| 98 | + }; |
| 99 | + |
| 100 | + fragment@2 { |
| 101 | + target-path = "/chosen"; |
| 102 | + __overlay__ { |
| 103 | + rootdisk-sd = <&sd_rootfs>; |
| 104 | }; |
| 105 | }; |
| 106 | }; |
| 107 | --- a/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a-rfb.dts |
| 108 | +++ b/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a-rfb.dts |
| 109 | @@ -18,7 +18,8 @@ |
| 110 | chosen { |
| 111 | bootargs = "console=ttyS0,115200n1 loglevel=8 \ |
| 112 | earlycon=uart8250,mmio32,0x11000000 \ |
| 113 | - pci=pcie_bus_perf"; |
| 114 | + pci=pcie_bus_perf ubi.block=0,firmware root=/dev/fit0 \ |
| 115 | + rootwait"; |
| 116 | }; |
| 117 | |
| 118 | memory { |
| 119 | --- a/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a.dtsi |
| 120 | +++ b/target/linux/mediatek/files-6.6/arch/arm64/boot/dts/mediatek/mt7988a.dtsi |
| 121 | @@ -828,6 +828,7 @@ |
| 122 | nvmem-cells = <&lvts_calibration>; |
| 123 | nvmem-cell-names = "lvts-calib-data-1"; |
| 124 | #thermal-sensor-cells = <1>; |
| 125 | + status = "disabled"; |
| 126 | }; |
| 127 | |
| 128 | ssusb0: usb@11190000 { |