diff options
Diffstat (limited to 'arch/mips/dts')
-rw-r--r-- | arch/mips/dts/.gitignore | 1 | ||||
-rw-r--r-- | arch/mips/dts/Makefile | 5 | ||||
-rw-r--r-- | arch/mips/dts/ar9331-dptechnics-dpt-module.dts | 22 | ||||
-rw-r--r-- | arch/mips/dts/ar9331-okud-max9331.dts | 142 | ||||
-rw-r--r-- | arch/mips/dts/ar9331-openembed-som9331-board.dts | 6 | ||||
-rw-r--r-- | arch/mips/dts/ar9331.dtsi | 12 | ||||
-rw-r--r-- | arch/mips/dts/ar9331_tl_mr3020.dts | 4 | ||||
-rw-r--r-- | arch/mips/dts/ar9344-tl-wdr4300-v1.7.dts | 4 | ||||
-rw-r--r-- | arch/mips/dts/loongson-ls1b.dts | 6 | ||||
-rw-r--r-- | arch/mips/dts/ls1b.dtsi | 17 | ||||
-rw-r--r-- | arch/mips/dts/qca4531-8devices-lima.dts | 4 | ||||
-rw-r--r-- | arch/mips/dts/qemu-malta.dts | 37 |
12 files changed, 225 insertions, 35 deletions
diff --git a/arch/mips/dts/.gitignore b/arch/mips/dts/.gitignore deleted file mode 100644 index 077903c50a..0000000000 --- a/arch/mips/dts/.gitignore +++ /dev/null @@ -1 +0,0 @@ -*dtb* diff --git a/arch/mips/dts/Makefile b/arch/mips/dts/Makefile index b0ad25ecfa..d99c4c6358 100644 --- a/arch/mips/dts/Makefile +++ b/arch/mips/dts/Makefile @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: GPL-2.0-only + BUILTIN_DTB := $(patsubst "%",%,$(CONFIG_BUILTIN_DTB_NAME)) ifneq ($(BUILTIN_DTB),) obj-$(CONFIG_BUILTIN_DTB) += $(BUILTIN_DTB).dtb.o @@ -8,6 +10,7 @@ pbl-$(CONFIG_BOARD_BLACK_SWIFT) += black-swift.dtb.o pbl-$(CONFIG_BOARD_CI20) += img-ci20.dtb.o pbl-$(CONFIG_BOARD_DLINK_DIR320) += dlink-dir-320.dtb.o pbl-$(CONFIG_BOARD_DPTECHNICS_DPT_MODULE) += ar9331-dptechnics-dpt-module.dtb.o +pbl-$(CONFIG_BOARD_OKUD_MAX9331) += ar9331-okud-max9331.dtb.o pbl-$(CONFIG_BOARD_OPENEMBEDED_SOM9331) += ar9331-openembed-som9331-board.dtb.o pbl-$(CONFIG_BOARD_LOONGSON_TECH_LS1B) += loongson-ls1b.dtb.o pbl-$(CONFIG_BOARD_QEMU_MALTA) += qemu-malta.dtb.o @@ -15,4 +18,4 @@ pbl-$(CONFIG_BOARD_RZX50) += rzx50.dtb.o pbl-$(CONFIG_BOARD_TPLINK_MR3020) += ar9331_tl_mr3020.dtb.o pbl-$(CONFIG_BOARD_TPLINK_WDR4300) += ar9344-tl-wdr4300-v1.7.dtb.o -clean-files := *.dtb *.dtb.S .*.dtc .*.pre .*.dts *.dtb.lzo +clean-files := *.dtb *.dtb.S .*.dtc .*.pre .*.dts *.dtb.z diff --git a/arch/mips/dts/ar9331-dptechnics-dpt-module.dts b/arch/mips/dts/ar9331-dptechnics-dpt-module.dts index cbaf5ab39e..25eabc9b7e 100644 --- a/arch/mips/dts/ar9331-dptechnics-dpt-module.dts +++ b/arch/mips/dts/ar9331-dptechnics-dpt-module.dts @@ -7,9 +7,11 @@ }; chosen { + stdout-path = &uart; + environment { compatible = "barebox,environment"; - device-path = &spiflash, "partname:barebox-environment"; + device-path = &env_nor; }; art@0 { @@ -18,18 +20,14 @@ barebox,provide-mac-address = <ð0>; }; }; +}; - leds { - system { - barebox,default-trigger = "heartbeat"; - }; - }; +&{/leds/led-0} { + barebox,default-trigger = "heartbeat"; +}; - gpio-keys { - button@0 { - gpios = <&gpio 11 GPIO_ACTIVE_HIGH>; - }; - }; +&{/gpio-keys/button-0} { + gpios = <&gpio 11 GPIO_ACTIVE_HIGH>; }; &spiflash { @@ -38,7 +36,7 @@ reg = <0 0x80000>; }; - partition@80000 { + env_nor: partition@80000 { label = "barebox-environment"; reg = <0x80000 0x10000>; }; diff --git a/arch/mips/dts/ar9331-okud-max9331.dts b/arch/mips/dts/ar9331-okud-max9331.dts new file mode 100644 index 0000000000..f65272905b --- /dev/null +++ b/arch/mips/dts/ar9331-okud-max9331.dts @@ -0,0 +1,142 @@ +// SPDX-License-Identifier: GPL-2.0 +/dts-v1/; +#include <mips/qca/ar9331.dtsi> + +#include <dt-bindings/gpio/gpio.h> +#include <dt-bindings/input/input.h> + +#include "ar9331.dtsi" + +/ { + model = "o&kud max9331"; + compatible = "okud,max9331"; + + aliases { + spiflash = &spiflash; + serial0 = &uart; + }; + + chosen { + stdout-path = &uart; + + environment { + compatible = "barebox,environment"; + device-path = &env_nor; + }; + + art@0 { + compatible = "qca,art-ar9331", "qca,art"; + device-path = &spiflash_art; + barebox,provide-mac-address = <ð0>; + }; + }; + + memory@0 { + device_type = "memory"; + reg = <0x0 0x4000000>; + }; + + /* FIXME: leds and gpio */ + leds { + compatible = "gpio-leds"; + + net { + label = "board:LED1:system"; + gpios = <&gpio 1 GPIO_ACTIVE_LOW>; + default-state = "off"; + barebox,default-trigger = "net"; + }; + + panic { + label = "board:LED2:system"; + gpios = <&gpio 0 GPIO_ACTIVE_LOW>; + default-state = "on"; + barebox,default-trigger = "panic"; + }; + + system { + label = "board:LED3:system"; + gpios = <&gpio 27 GPIO_ACTIVE_LOW>; + default-state = "off"; + barebox,default-trigger = "heartbeat"; + }; + }; + + gpio-keys { + compatible = "gpio-keys"; + #address-cells = <1>; + #size-cells = <0>; + + button@0 { + label = "reset"; + linux,code = <KEY_ENTER>; + gpios = <&gpio 11 GPIO_ACTIVE_LOW>; + }; + }; +}; + +ð0 { + status = "okay"; +}; + +&ref { + clock-frequency = <25000000>; +}; + +&uart { + status = "okay"; +}; + +&gpio { + status = "okay"; +}; + +&usb { + dr_mode = "host"; + status = "okay"; +}; + +&usb_phy { + status = "okay"; +}; + +&spi { + num-chipselects = <1>; + status = "okay"; + + /* Spansion FL128SA SPI flash */ + spiflash: s25fl128s@0 { + #address-cells = <1>; + #size-cells = <1>; + compatible = "spansion,s25fl128s1", "jedec,spi-nor"; + spi-max-frequency = <25000000>; + reg = <0>; + }; +}; + +&spiflash { + partition@0 { + label = "boot0"; + reg = <0 0x10000>; + }; + + env_nor: partition@10000 { + label = "barebox-environment"; + reg = <0x10000 0x10000>; + }; + + partition@20000 { + label = "barebox"; + reg = <0x20000 0x80000>; + }; + + partition@a0000 { + label = "kernel"; + reg = <0xA0000 0xF50000>; + }; + + spiflash_art: partition@ff0000 { + label = "art"; + reg = <0xff0000 0x10000>; + }; +}; diff --git a/arch/mips/dts/ar9331-openembed-som9331-board.dts b/arch/mips/dts/ar9331-openembed-som9331-board.dts index ff9d25e352..78f5ef1ea2 100644 --- a/arch/mips/dts/ar9331-openembed-som9331-board.dts +++ b/arch/mips/dts/ar9331-openembed-som9331-board.dts @@ -33,9 +33,11 @@ chosen { + stdout-path = &uart; + environment { compatible = "barebox,environment"; - device-path = &spiflash, "partname:barebox-environment"; + device-path = &env_nor; }; art@0 { @@ -93,7 +95,7 @@ reg = <0 0x80000>; }; - partition@80000 { + env_nor: partition@80000 { label = "barebox-environment"; reg = <0x80000 0x10000>; }; diff --git a/arch/mips/dts/ar9331.dtsi b/arch/mips/dts/ar9331.dtsi index 72f029754e..20e4d64c04 100644 --- a/arch/mips/dts/ar9331.dtsi +++ b/arch/mips/dts/ar9331.dtsi @@ -1,10 +1,8 @@ -/ { - ahb { - wdt0: wdt@18060008 { - compatible = "qca,ar9331-wdt", "qca,ar9344-wdt"; - reg = <0x18060008 0x8>; - clocks = <&pll ATH79_CLK_CPU>; - }; +&{/ahb} { + wdt0: wdt@18060008 { + compatible = "qca,ar9331-wdt", "qca,ar9344-wdt"; + reg = <0x18060008 0x8>; + clocks = <&pll ATH79_CLK_CPU>; }; }; diff --git a/arch/mips/dts/ar9331_tl_mr3020.dts b/arch/mips/dts/ar9331_tl_mr3020.dts index c6ae154f4f..66587912c4 100644 --- a/arch/mips/dts/ar9331_tl_mr3020.dts +++ b/arch/mips/dts/ar9331_tl_mr3020.dts @@ -11,7 +11,7 @@ environment { compatible = "barebox,environment"; - device-path = &spiflash, "partname:barebox-environment"; + device-path = &env_nor; }; }; }; @@ -22,7 +22,7 @@ reg = <0 0x80000>; }; - partition@80000 { + env_nor: partition@80000 { label = "barebox-environment"; reg = <0x80000 0x10000>; }; diff --git a/arch/mips/dts/ar9344-tl-wdr4300-v1.7.dts b/arch/mips/dts/ar9344-tl-wdr4300-v1.7.dts index 82daabbdd4..d788b5ed63 100644 --- a/arch/mips/dts/ar9344-tl-wdr4300-v1.7.dts +++ b/arch/mips/dts/ar9344-tl-wdr4300-v1.7.dts @@ -24,7 +24,7 @@ environment { compatible = "barebox,environment"; - device-path = &spiflash, "partname:barebox-environment"; + device-path = &env_nor; }; art@0 { @@ -65,7 +65,7 @@ reg = <0 0x80000>; }; - partition@80000 { + env_nor: partition@80000 { label = "barebox-environment"; reg = <0x80000 0x10000>; }; diff --git a/arch/mips/dts/loongson-ls1b.dts b/arch/mips/dts/loongson-ls1b.dts index 6b53311982..89cce5636b 100644 --- a/arch/mips/dts/loongson-ls1b.dts +++ b/arch/mips/dts/loongson-ls1b.dts @@ -6,6 +6,12 @@ model = "Loongson Tech LS1B Demo Board"; compatible = "loongson,ls1b"; + oscillator: oscillator { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <33000000>; + }; + memory@0 { device_type = "memory"; reg = <0x00000000 0x4000000>; diff --git a/arch/mips/dts/ls1b.dtsi b/arch/mips/dts/ls1b.dtsi index cb85814af4..3b57093c9b 100644 --- a/arch/mips/dts/ls1b.dtsi +++ b/arch/mips/dts/ls1b.dtsi @@ -1,3 +1,5 @@ +#include <dt-bindings/clock/ls1b-clk.h> + / { #address-cells = <1>; #size-cells = <1>; @@ -13,7 +15,7 @@ compatible = "ns16550a"; reg = <0x1fe40000 0x8>; reg-shift = <0>; - clock-frequency = <83000000>; + clocks = <&pll LS1B_CLK_APB_DIV>; status = "disabled"; }; @@ -21,7 +23,7 @@ compatible = "ns16550a"; reg = <0x1fe44000 0x8>; reg-shift = <0>; - clock-frequency = <83000000>; + clocks = <&pll LS1B_CLK_APB_DIV>; status = "disabled"; }; @@ -29,7 +31,7 @@ compatible = "ns16550a"; reg = <0x1fe48000 0x8>; reg-shift = <0>; - clock-frequency = <83000000>; + clocks = <&pll LS1B_CLK_APB_DIV>; status = "disabled"; }; @@ -37,8 +39,15 @@ compatible = "ns16550a"; reg = <0x1fe4c000 0x8>; reg-shift = <0>; - clock-frequency = <83000000>; + clocks = <&pll LS1B_CLK_APB_DIV>; status = "disabled"; }; + + pll: pll@1fe78030 { + compatible = "loongson,ls1b-pll"; + #clock-cells = <1>; + reg = <0x1fe78030 0x8>; + clocks = <&oscillator>; + }; }; }; diff --git a/arch/mips/dts/qca4531-8devices-lima.dts b/arch/mips/dts/qca4531-8devices-lima.dts index 4b960e12bf..bb3e5247dc 100644 --- a/arch/mips/dts/qca4531-8devices-lima.dts +++ b/arch/mips/dts/qca4531-8devices-lima.dts @@ -24,7 +24,7 @@ environment { compatible = "barebox,environment"; - device-path = &spiflash, "partname:barebox-environment"; + device-path = &env_nor; }; }; }; @@ -59,7 +59,7 @@ reg = <0 0x80000>; }; - partition@80000 { + env_nor: partition@80000 { label = "barebox-environment"; reg = <0x80000 0x10000>; }; diff --git a/arch/mips/dts/qemu-malta.dts b/arch/mips/dts/qemu-malta.dts index 32e473cac0..c2bc03dd46 100644 --- a/arch/mips/dts/qemu-malta.dts +++ b/arch/mips/dts/qemu-malta.dts @@ -10,7 +10,7 @@ chosen { environment { compatible = "barebox,environment"; - device-path = &nor0, "partname:barebox-environment"; + device-path = &env_nor; }; }; @@ -19,6 +19,26 @@ reg = <0x00000000 0x10000000>; }; + clocks { + ref_clk: ref_clk { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <320000000>; + }; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu@0 { + device_type = "cpu"; + compatible = "mips,mips24Kf"; + clocks = <&ref_clk>; + reg = <0>; + }; + }; + uart0: serial@180003f8 { compatible = "ns16550a"; reg = <0x180003f8 0x08>; @@ -27,6 +47,19 @@ clock-frequency = <1843200>; }; + fpga_regs: system-controller@1f000000 { + compatible = "mti,malta-fpga", "syscon", "simple-mfd"; + reg = <0x1f000000 0x600>; + native-endian; + + reboot { + compatible = "syscon-reboot"; + regmap = <&fpga_regs>; + offset = <0x500>; + mask = <0x42>; + }; + }; + gpio: gpio@1f000b00 { compatible = "mti,malta-fpga-i2c-gpio"; gpio-controller; @@ -66,7 +99,7 @@ read-only; }; - partition@80000 { + env_nor: partition@80000 { label = "barebox-environment"; reg = <0x80000 0x10000>; }; |