Files
cubelinux-kernel/arch/arm64/boot/dts/mediatek/mt7981b-openwrt-one.dts
T
Greg Kroah-Hartman 598cf27219 Linux 6.19.3
Link: https://lore.kernel.org/r/20260217200002.683975158@linuxfoundation.org
Tested-by: Florian Fainelli <florian.fainelli@broadcom.com>
Tested-by: Takeshi Ogasawara <takeshi.ogasawara@futuring-girl.com>
Tested-by: Peter Schneider <pschneider1968@googlemail.com>
Tested-by: Jon Hunter <jonathanh@nvidia.com>
Tested-by: Salvatore Bonaccorso <carnil@debian.org>
Tested-by: Brett A C Sheffield <bacs@librecast.net>
Tested-by: Mark Brown <broonie@kernel.org>
Tested-by: Luna Jernberg <droidbittin@gmail.com>
Tested-by: Ronald Warsow <rwarsow@gmx.de>
Tested-by: Justin M. Forbes <jforbes@fedoraproject.org>
Tested-by: Ron Economos <re@w6rz.net>
Tested-by: Miguel Ojeda <ojeda@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2026-02-19 16:33:27 +01:00

166 lines
2.8 KiB
Devicetree

// SPDX-License-Identifier: GPL-2.0-only OR MIT
/dts-v1/;
#include "mt7981b.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/leds/common.h>
#include "dt-bindings/pinctrl/mt65xx.h"
/ {
compatible = "openwrt,one", "mediatek,mt7981b";
model = "OpenWrt One";
aliases {
serial0 = &uart0;
};
chosen {
stdout-path = "serial0:115200n8";
};
memory@40000000 {
reg = <0 0x40000000 0 0x40000000>;
device_type = "memory";
};
pwm-leds {
compatible = "pwm-leds";
led-0 {
color = <LED_COLOR_ID_WHITE>;
default-brightness = <0>;
function = LED_FUNCTION_STATUS;
max-brightness = <255>;
pwms = <&pwm 0 10000>;
};
led-1 {
color = <LED_COLOR_ID_GREEN>;
default-brightness = <0>;
function = LED_FUNCTION_STATUS;
max-brightness = <255>;
pwms = <&pwm 1 10000>;
};
};
gpio-leds {
compatible = "gpio-leds";
led-0 {
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_STATUS;
gpios = <&pio 9 GPIO_ACTIVE_HIGH>;
};
led-1 {
color = <LED_COLOR_ID_AMBER>;
function = LED_FUNCTION_LAN;
gpios = <&pio 34 GPIO_ACTIVE_LOW>;
linux,default-trigger = "netdev";
};
led-2 {
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_LAN;
gpios = <&pio 35 GPIO_ACTIVE_LOW>;
linux,default-trigger = "netdev";
};
};
};
&pio {
pwm_pins: pwm-pins {
mux {
function = "pwm";
groups = "pwm0_0", "pwm1_1";
};
};
spi2_flash_pins: spi2-pins {
mux {
function = "spi";
groups = "spi2";
};
conf-pu {
bias-pull-up = <MTK_PUPD_SET_R1R0_11>;
drive-strength = <8>;
pins = "SPI2_CS", "SPI2_WP";
};
conf-pd {
bias-pull-down = <MTK_PUPD_SET_R1R0_11>;
drive-strength = <8>;
pins = "SPI2_CLK", "SPI2_MOSI", "SPI2_MISO";
};
};
};
&pwm {
pinctrl-names = "default";
pinctrl-0 = <&pwm_pins>;
status = "okay";
};
&spi2 {
pinctrl-names = "default";
pinctrl-0 = <&spi2_flash_pins>;
status = "okay";
flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <40000000>;
#address-cells = <1>;
#size-cells = <1>;
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
reg = <0x00000 0x40000>;
label = "bl2-nor";
};
partition@40000 {
reg = <0x40000 0xc0000>;
label = "factory";
read-only;
nvmem-layout {
compatible = "fixed-layout";
#address-cells = <1>;
#size-cells = <1>;
wifi_factory_calibration: eeprom@0 {
reg = <0x0 0x1000>;
};
wan_factory_mac: macaddr@24 {
reg = <0x24 0x6>;
compatible = "mac-base";
#nvmem-cell-cells = <1>;
};
};
};
partition@100000 {
reg = <0x100000 0x80000>;
label = "fip-nor";
};
partition@180000 {
reg = <0x180000 0xc80000>;
label = "recovery";
};
};
};
};
&uart0 {
status = "okay";
};