mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-29 18:19:02 +00:00
32c1ac8960
nvmem-cells is deprecated. nvmem-layout allows using mac-base. Signed-off-by: Rosen Penev <rosenp@gmail.com>
213 lines
3.5 KiB
Plaintext
213 lines
3.5 KiB
Plaintext
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
|
|
|
|
#include "mt7620n.dtsi"
|
|
|
|
#include <dt-bindings/gpio/gpio.h>
|
|
#include <dt-bindings/input/input.h>
|
|
|
|
/ {
|
|
compatible = "netgear,pr2000", "ralink,mt7620n-soc";
|
|
model = "Netgear PR2000";
|
|
|
|
aliases {
|
|
label-mac-device = ðernet;
|
|
};
|
|
|
|
leds {
|
|
compatible = "gpio-leds";
|
|
|
|
internet {
|
|
label = "green:internet";
|
|
gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
|
|
};
|
|
|
|
wifi {
|
|
label = "green:wifi";
|
|
gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
|
|
linux,default-trigger = "phy0tpt";
|
|
};
|
|
|
|
usb {
|
|
label = "green:usb";
|
|
gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
|
|
trigger-sources = <&ohci_port1>, <&ehci_port1>;
|
|
linux,default-trigger = "usbport";
|
|
};
|
|
};
|
|
|
|
keys {
|
|
compatible = "gpio-keys";
|
|
|
|
reset {
|
|
label = "reset";
|
|
gpios = <&gpio0 1 GPIO_ACTIVE_LOW>;
|
|
linux,code = <KEY_RESTART>;
|
|
};
|
|
|
|
wireless {
|
|
label = "wireless";
|
|
gpios = <&gpio0 20 GPIO_ACTIVE_LOW>;
|
|
linux,code = <BTN_0>;
|
|
linux,input-type = <EV_SW>;
|
|
};
|
|
|
|
wired {
|
|
label = "wired";
|
|
gpios = <&gpio0 21 GPIO_ACTIVE_LOW>;
|
|
linux,code = <BTN_0>;
|
|
linux,input-type = <EV_SW>;
|
|
};
|
|
};
|
|
};
|
|
|
|
&gpio2 {
|
|
status = "okay";
|
|
};
|
|
|
|
&gpio3 {
|
|
status = "okay";
|
|
};
|
|
|
|
&spi0 {
|
|
status = "okay";
|
|
|
|
flash@0 {
|
|
compatible = "jedec,spi-nor";
|
|
reg = <0>;
|
|
spi-max-frequency = <50000000>;
|
|
m25p,fast-read;
|
|
|
|
partitions {
|
|
compatible = "fixed-partitions";
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
|
|
partition@0 {
|
|
label = "u-boot";
|
|
reg = <0x0 0x30000>;
|
|
read-only;
|
|
};
|
|
|
|
partition@30000 {
|
|
label = "u-boot-env";
|
|
reg = <0x30000 0x10000>;
|
|
};
|
|
|
|
/* sercomm header for kernel starts at 0x3ffba
|
|
* can be safely ignored since not used by OpenWRT
|
|
*/
|
|
|
|
partition@40000 {
|
|
compatible = "denx,uimage";
|
|
label = "firmware";
|
|
reg = <0x40000 0xf20000>;
|
|
};
|
|
|
|
factory: partition@f60000 {
|
|
label = "factory";
|
|
reg = <0xf60000 0x10000>;
|
|
read-only;
|
|
|
|
nvmem-layout {
|
|
compatible = "fixed-layout";
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
|
|
eeprom_factory_0: eeprom@0 {
|
|
reg = <0x0 0x200>;
|
|
};
|
|
};
|
|
};
|
|
|
|
board_data: partition@f70000 {
|
|
label = "board_data";
|
|
reg = <0xf70000 0x10000>;
|
|
read-only;
|
|
|
|
nvmem-layout {
|
|
compatible = "fixed-layout";
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
|
|
macaddr_board_data_b0: macaddr@b0 {
|
|
reg = <0xb0 0x6>;
|
|
};
|
|
};
|
|
};
|
|
|
|
partition@f80000 {
|
|
label = "POT";
|
|
reg = <0xf80000 0x10000>;
|
|
read-only;
|
|
};
|
|
|
|
partition@f90000 {
|
|
label = "Traffic Meter";
|
|
reg = <0xf90000 0x10000>;
|
|
read-only;
|
|
};
|
|
|
|
partition@fa0000 {
|
|
label = "Traffic Meter2";
|
|
reg = <0xfa0000 0x10000>;
|
|
read-only;
|
|
};
|
|
|
|
partition@fb0000 {
|
|
label = "nvram";
|
|
reg = <0xfb0000 0x10000>;
|
|
};
|
|
|
|
partition@fc0000 {
|
|
label = "DPF";
|
|
reg = <0xfc0000 0x10000>;
|
|
read-only;
|
|
};
|
|
|
|
partition@fd0000 {
|
|
label = "ralink_nvram";
|
|
reg = <0xfd0000 0x10000>;
|
|
read-only;
|
|
};
|
|
|
|
partition@fe0000 {
|
|
label = "reserved1";
|
|
reg = <0xfe0000 0x10000>;
|
|
read-only;
|
|
};
|
|
|
|
partition@ff0000 {
|
|
label = "reserved2";
|
|
reg = <0xff0000 0x10000>;
|
|
read-only;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
ðernet {
|
|
mediatek,portmap = "wllll";
|
|
nvmem-cells = <&macaddr_board_data_b0>;
|
|
nvmem-cell-names = "mac-address";
|
|
};
|
|
|
|
&ehci {
|
|
status = "okay";
|
|
};
|
|
|
|
&ohci {
|
|
status = "okay";
|
|
};
|
|
|
|
&wmac {
|
|
nvmem-cells = <&eeprom_factory_0>, <&macaddr_board_data_b0>;
|
|
nvmem-cell-names = "eeprom", "mac-address";
|
|
};
|
|
|
|
&state_default {
|
|
default {
|
|
groups = "ephy", "wled", "pa", "i2c";
|
|
function = "gpio";
|
|
};
|
|
};
|