mirror of https://github.com/hak5/openwrt.git
mediatek: add latest fixes provided by MTK
Signed-off-by: John Crispin <john@phrozen.org>master
parent
ffd249366f
commit
083eb80bf2
|
@ -10,7 +10,7 @@
|
||||||
|
|
||||||
/ {
|
/ {
|
||||||
model = "MediaTek MT7629 reference board";
|
model = "MediaTek MT7629 reference board";
|
||||||
compatible = "mediatek,mt7629-rfb", "mediatek,mt7629";
|
compatible = "mediatek,mt7629-lynx-rfb", "mediatek,mt7629";
|
||||||
|
|
||||||
aliases {
|
aliases {
|
||||||
serial0 = &uart0;
|
serial0 = &uart0;
|
||||||
|
@ -18,6 +18,7 @@
|
||||||
|
|
||||||
chosen {
|
chosen {
|
||||||
stdout-path = "serial0:115200n8";
|
stdout-path = "serial0:115200n8";
|
||||||
|
bootargs = "earlycon=uart8250,mmio32,0x11002000 console=ttyS0,115200n8";
|
||||||
};
|
};
|
||||||
|
|
||||||
gpio-keys {
|
gpio-keys {
|
||||||
|
@ -36,6 +37,13 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
gsw: gsw@0 {
|
||||||
|
compatible = "mediatek,mt753x";
|
||||||
|
mediatek,ethsys = <ðsys>;
|
||||||
|
#address-cells = <1>;
|
||||||
|
#size-cells = <0>;
|
||||||
|
};
|
||||||
|
|
||||||
memory@40000000 {
|
memory@40000000 {
|
||||||
device_type = "memory";
|
device_type = "memory";
|
||||||
reg = <0 0x40000000 0 0x10000000>;
|
reg = <0 0x40000000 0 0x10000000>;
|
||||||
|
@ -58,46 +66,61 @@
|
||||||
regulator-boot-on;
|
regulator-boot-on;
|
||||||
regulator-always-on;
|
regulator-always-on;
|
||||||
};
|
};
|
||||||
|
|
||||||
rtkgsw: rtkgsw@0 {
|
|
||||||
compatible = "mediatek,rtk-gsw";
|
|
||||||
mediatek,ethsys = <ðsys>;
|
|
||||||
mediatek,mdio = <&mdio>;
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
ð {
|
ð {
|
||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
pinctrl-0 = <&ephy_leds_pins>;
|
pinctrl-0 = <&ephy_leds_pins>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
gmac0: mac@0 {
|
gmac0: mac@0 {
|
||||||
compatible = "mediatek,eth-mac";
|
compatible = "mediatek,eth-mac";
|
||||||
reg = <0>;
|
reg = <0>;
|
||||||
phy-mode = "sgmii";
|
mtd-mac-address = <&factory 0x2a>;
|
||||||
fixed-link {
|
phy-mode = "sgmii";
|
||||||
speed = <1000>;
|
fixed-link {
|
||||||
full-duplex;
|
speed = <1000>;
|
||||||
pause;
|
full-duplex;
|
||||||
};
|
pause;
|
||||||
};
|
};
|
||||||
|
};
|
||||||
|
|
||||||
gmac1: mac@1 {
|
gmac1: mac@1 {
|
||||||
compatible = "mediatek,eth-mac";
|
compatible = "mediatek,eth-mac";
|
||||||
reg = <1>;
|
reg = <1>;
|
||||||
phy-handle = <&phy0>;
|
mtd-mac-address = <&factory 0x24>;
|
||||||
};
|
phy-handle = <&phy0>;
|
||||||
|
};
|
||||||
|
|
||||||
mdio: mdio-bus {
|
mdio: mdio-bus {
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
|
|
||||||
phy0: ethernet-phy@0 {
|
phy0: ethernet-phy@0 {
|
||||||
reg = <0>;
|
reg = <0>;
|
||||||
phy-mode = "gmii";
|
phy-mode = "gmii";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
&gsw {
|
||||||
|
mediatek,mdio = <&mdio>;
|
||||||
|
mediatek,portmap = "llllw";
|
||||||
|
mediatek,mdio_master_pinmux = <0>;
|
||||||
|
reset-gpios = <&pio 28 0>;
|
||||||
|
interrupt-parent = <&pio>;
|
||||||
|
interrupts = <6 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
|
status = "okay";
|
||||||
|
|
||||||
|
port6: port@6 {
|
||||||
|
compatible = "mediatek,mt753x-port";
|
||||||
|
reg = <6>;
|
||||||
|
phy-mode = "sgmii";
|
||||||
|
fixed-link {
|
||||||
|
speed = <2500>;
|
||||||
|
full-duplex;
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
&i2c {
|
&i2c {
|
||||||
|
@ -133,13 +156,13 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
factory: partition@70000 {
|
factory: partition@70000 {
|
||||||
label = "Factory";
|
label = "factory";
|
||||||
reg = <0x70000 0x40000>;
|
reg = <0x70000 0x40000>;
|
||||||
read-only;
|
read-only;
|
||||||
};
|
};
|
||||||
|
|
||||||
partition@b0000 {
|
partition@b0000 {
|
||||||
label = "Kernel";
|
label = "firmware";
|
||||||
reg = <0xb0000 0xb50000>;
|
reg = <0xb0000 0xb50000>;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
|
|
||||||
chosen {
|
chosen {
|
||||||
stdout-path = "serial0:115200n8";
|
stdout-path = "serial0:115200n8";
|
||||||
bootargs = "earlycon=uart8250,mmio32,0x11002000 swiotlb=512";
|
bootargs = "earlycon=uart8250,mmio32,0x11002000 console=ttyS0,115200n1 swiotlb=512";
|
||||||
};
|
};
|
||||||
|
|
||||||
cpus {
|
cpus {
|
||||||
|
@ -55,6 +55,13 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
gsw: gsw@0 {
|
||||||
|
compatible = "mediatek,mt753x";
|
||||||
|
mediatek,ethsys = <ðsys>;
|
||||||
|
#address-cells = <1>;
|
||||||
|
#size-cells = <0>;
|
||||||
|
};
|
||||||
|
|
||||||
memory {
|
memory {
|
||||||
reg = <0 0x40000000 0 0x3F000000>;
|
reg = <0 0x40000000 0 0x3F000000>;
|
||||||
};
|
};
|
||||||
|
@ -84,14 +91,6 @@
|
||||||
regulator-boot-on;
|
regulator-boot-on;
|
||||||
regulator-always-on;
|
regulator-always-on;
|
||||||
};
|
};
|
||||||
|
|
||||||
rtkgsw: rtkgsw@0 {
|
|
||||||
compatible = "mediatek,rtk-gsw";
|
|
||||||
mediatek,ethsys = <ðsys>;
|
|
||||||
mediatek,mdio = <&mdio>;
|
|
||||||
mediatek,reset-pin = <&pio 54 0>;
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
&pcie {
|
&pcie {
|
||||||
|
@ -405,6 +404,36 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
&gsw {
|
||||||
|
mediatek,mdio = <&mdio>;
|
||||||
|
mediatek,portmap = "llllw";
|
||||||
|
mediatek,mdio_master_pinmux = <0>;
|
||||||
|
reset-gpios = <&pio 54 0>;
|
||||||
|
interrupt-parent = <&pio>;
|
||||||
|
interrupts = <53 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
|
status = "okay";
|
||||||
|
|
||||||
|
port5: port@5 {
|
||||||
|
compatible = "mediatek,mt753x-port";
|
||||||
|
reg = <5>;
|
||||||
|
phy-mode = "rgmii";
|
||||||
|
fixed-link {
|
||||||
|
speed = <1000>;
|
||||||
|
full-duplex;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
port6: port@6 {
|
||||||
|
compatible = "mediatek,mt753x-port";
|
||||||
|
reg = <6>;
|
||||||
|
phy-mode = "sgmii";
|
||||||
|
fixed-link {
|
||||||
|
speed = <2500>;
|
||||||
|
full-duplex;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
&i2c1 {
|
&i2c1 {
|
||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
pinctrl-0 = <&i2c1_pins>;
|
pinctrl-0 = <&i2c1_pins>;
|
||||||
|
|
|
@ -8,19 +8,8 @@ define Device/mediatek_mt7622-rfb1
|
||||||
endef
|
endef
|
||||||
TARGET_DEVICES += mediatek_mt7622-rfb1
|
TARGET_DEVICES += mediatek_mt7622-rfb1
|
||||||
|
|
||||||
define Device/mediatek_mt7622-lynx-rfb1
|
define Device/bpi_bananapi-r64
|
||||||
DEVICE_VENDOR := MediaTek
|
DEVICE_VENDOR := Bpi
|
||||||
DEVICE_MODEL := MTK7622 Lynx rfb1 AP
|
|
||||||
DEVICE_DTS := mt7622-lynx-rfb1
|
|
||||||
DEVICE_DTS_DIR := $(DTS_DIR)/mediatek
|
|
||||||
SUPPORTED_DEVICES := mediatek,mt7622-rfb1
|
|
||||||
DEVICE_PACKAGES := kmod-usb-ohci kmod-usb2 kmod-usb3 \
|
|
||||||
kmod-ata-core kmod-ata-ahci-mtk
|
|
||||||
endef
|
|
||||||
TARGET_DEVICES += mediatek_mt7622-lynx-rfb1
|
|
||||||
|
|
||||||
define Device/lemaker_bananapi-bpi-r64
|
|
||||||
DEVICE_VENDOR := LeMaker
|
|
||||||
DEVICE_MODEL := Banana Pi R64
|
DEVICE_MODEL := Banana Pi R64
|
||||||
DEVICE_DTS := mt7622-bananapi-bpi-r64
|
DEVICE_DTS := mt7622-bananapi-bpi-r64
|
||||||
DEVICE_DTS_DIR := $(DTS_DIR)/mediatek
|
DEVICE_DTS_DIR := $(DTS_DIR)/mediatek
|
||||||
|
@ -28,4 +17,4 @@ define Device/lemaker_bananapi-bpi-r64
|
||||||
DEVICE_PACKAGES := kmod-usb-ohci kmod-usb2 kmod-usb3 \
|
DEVICE_PACKAGES := kmod-usb-ohci kmod-usb2 kmod-usb3 \
|
||||||
kmod-ata-core kmod-ata-ahci-mtk
|
kmod-ata-core kmod-ata-ahci-mtk
|
||||||
endef
|
endef
|
||||||
TARGET_DEVICES += lemaker_bananapi-bpi-r64
|
TARGET_DEVICES += bpi_bananapi-r64
|
||||||
|
|
|
@ -9,10 +9,10 @@ define Device/unielec_u7623-02-emmc-512m
|
||||||
endef
|
endef
|
||||||
TARGET_DEVICES += unielec_u7623-02-emmc-512m
|
TARGET_DEVICES += unielec_u7623-02-emmc-512m
|
||||||
|
|
||||||
define Device/lemaker_bananapi-bpi-r2
|
define Device/bpi_bananapi-r2
|
||||||
DEVICE_VENDOR := LeMaker
|
DEVICE_VENDOR := Bpi
|
||||||
DEVICE_MODEL := Banana Pi R2
|
DEVICE_MODEL := Banana Pi R2
|
||||||
DEVICE_DTS := mt7623n-bananapi-bpi-r2
|
DEVICE_DTS := mt7623n-bananapi-bpi-r2
|
||||||
SUPPORTED_DEVICES := bananapi,bpi-r2
|
SUPPORTED_DEVICES := bananapi,bpi-r2
|
||||||
endef
|
endef
|
||||||
TARGET_DEVICES += lemaker_bananapi-bpi-r2
|
TARGET_DEVICES += bpi_bananapi-r2
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
define Device/mediatek_mt7629-lynx-rfb
|
define Device/mediatek_mt7629-rfb
|
||||||
DEVICE_VENDOR := MediaTek
|
DEVICE_VENDOR := MediaTek
|
||||||
DEVICE_MODEL := MT7629 Lynx reference board
|
DEVICE_MODEL := MT7629 rfb AP
|
||||||
DEVICE_DTS := mt7629-lynx-rfb
|
DEVICE_DTS := mt7629-rfb
|
||||||
DEVICE_PACKAGES := swconfig
|
DEVICE_PACKAGES := swconfig
|
||||||
endef
|
endef
|
||||||
TARGET_DEVICES += mediatek_mt7629-lynx-rfb
|
TARGET_DEVICES += mediatek_mt7629-rfb
|
||||||
|
|
|
@ -6,65 +6,10 @@ Subject: [PATCH] spi: spi-mem: Mediatek: Add SPI Nand support for MT7629
|
||||||
Signed-off-by: Xiangsheng Hou <xiangsheng.hou@mediatek.com>
|
Signed-off-by: Xiangsheng Hou <xiangsheng.hou@mediatek.com>
|
||||||
---
|
---
|
||||||
arch/arm/boot/dts/mt7629-rfb.dts | 45 ++++++++++++++++++++++++++++++++
|
arch/arm/boot/dts/mt7629-rfb.dts | 45 ++++++++++++++++++++++++++++++++
|
||||||
arch/arm/boot/dts/mt7629-lynx-rfb.dts | 45 ++++++++++++++++++++++++++++++++
|
|
||||||
arch/arm/boot/dts/mt7629.dtsi | 22 ++++++++++++++++
|
arch/arm/boot/dts/mt7629.dtsi | 22 ++++++++++++++++
|
||||||
drivers/spi/spi-mtk-snfi.c | 12 +++++++++
|
drivers/spi/spi-mtk-snfi.c | 12 +++++++++
|
||||||
3 files changed, 79 insertions(+)
|
3 files changed, 79 insertions(+)
|
||||||
|
|
||||||
--- a/arch/arm/boot/dts/mt7629-rfb.dts
|
|
||||||
+++ b/arch/arm/boot/dts/mt7629-rfb.dts
|
|
||||||
@@ -258,6 +258,51 @@
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
+&bch {
|
|
||||||
+ status = "okay";
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+&snfi {
|
|
||||||
+ pinctrl-names = "default";
|
|
||||||
+ pinctrl-0 = <&serial_nand_pins>;
|
|
||||||
+ status = "okay";
|
|
||||||
+
|
|
||||||
+ spi_nand@0 {
|
|
||||||
+ #address-cells = <1>;
|
|
||||||
+ #size-cells = <1>;
|
|
||||||
+ compatible = "spi-nand";
|
|
||||||
+ spi-max-frequency = <104000000>;
|
|
||||||
+ reg = <0>;
|
|
||||||
+
|
|
||||||
+ partitions {
|
|
||||||
+ compatible = "fixed-partitions";
|
|
||||||
+ #address-cells = <1>;
|
|
||||||
+ #size-cells = <1>;
|
|
||||||
+
|
|
||||||
+ partition@0 {
|
|
||||||
+ label = "Bootloader";
|
|
||||||
+ reg = <0x00000 0x0100000>;
|
|
||||||
+ read-only;
|
|
||||||
+ };
|
|
||||||
+
|
|
||||||
+ partition@100000 {
|
|
||||||
+ label = "Config";
|
|
||||||
+ reg = <0x100000 0x0040000>;
|
|
||||||
+ };
|
|
||||||
+
|
|
||||||
+ partition@140000 {
|
|
||||||
+ label = "factory";
|
|
||||||
+ reg = <0x140000 0x0080000>;
|
|
||||||
+ };
|
|
||||||
+
|
|
||||||
+ partition@1c0000 {
|
|
||||||
+ label = "firmware";
|
|
||||||
+ reg = <0x1c0000 0x1000000>;
|
|
||||||
+ };
|
|
||||||
+ };
|
|
||||||
+ };
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
&spi {
|
|
||||||
pinctrl-names = "default";
|
|
||||||
pinctrl-0 = <&spi_pins>;
|
|
||||||
--- a/arch/arm/boot/dts/mt7629.dtsi
|
--- a/arch/arm/boot/dts/mt7629.dtsi
|
||||||
+++ b/arch/arm/boot/dts/mt7629.dtsi
|
+++ b/arch/arm/boot/dts/mt7629.dtsi
|
||||||
@@ -259,6 +259,28 @@
|
@@ -259,6 +259,28 @@
|
||||||
|
@ -119,8 +64,8 @@ Signed-off-by: Xiangsheng Hou <xiangsheng.hou@mediatek.com>
|
||||||
{ /* sentinel */ }
|
{ /* sentinel */ }
|
||||||
};
|
};
|
||||||
|
|
||||||
--- a/arch/arm/boot/dts/mt7629-lynx-rfb.dts
|
--- a/arch/arm/boot/dts/mt7629-rfb.dts
|
||||||
+++ b/arch/arm/boot/dts/mt7629-lynx-rfb.dts
|
+++ b/arch/arm/boot/dts/mt7629-rfb.dts
|
||||||
@@ -281,6 +281,52 @@
|
@@ -281,6 +281,52 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue