Commit 07b8c4bb authored by Arnd Bergmann's avatar Arnd Bergmann

Merge tag 'arm-soc/for-6.10/devicetree' of https://github.com/Broadcom/stblinux into soc/dt

This pull request contains Broadcom ARM-based SoCs Device Tree changes
for 6.10, please pull the following:

- Laurent converts the Raspberry Pi firmware DT binding to YAML, updates
  the firmware driver to use the proper 'struct device' reference for
  DMA mappings and drops unneeded properties from the DT node and
  finishes by removing the duplicate firmware-clocks property to
  bcm2835-rpi.dtsi. He also added support for the CAM1 camera interface
  regulator.

- Uwe adds a pinctrl-based multiplexing description to allow the use of
  I2C0 pins to allow usage between the 40-pin Raspberry Pi header and
  the CSI and DSI connectors. He then describes the PCF85063 RTC device
  available on the CM4 I/O board making use of that pinctrl-based
  muxing.

- Arinc updates the Asus RT-AC3100 and RT-AC88U DTs to have proper LED
  colors and function properties, NVMEM MAC addresses and removes
  duplicates and unnecessary properties and does a few Device Tree
  cleanups.. He then adds support for the Asus RT-AC3200 (BCM4709-based)
  and RT-AC3500 routers.

- Jean-Michel adds DT nodes for the CSI Unicam camera interfaces on the
  Raspberry Pi 4 / BCM2711 SoCs

- Florian adds support for the Ethernet LEDs on Raspberry Pi 4 B and
  Raspberry Pi 4 CM boards.

* tag 'arm-soc/for-6.10/devicetree' of https://github.com/Broadcom/stblinux:
  arm: dts: bcm2711: Describe Ethernet LEDs
  ARM: dts: BCM5301X: Conform to DTS Coding Style on ASUS RT-AC3100 & AC88U
  ARM: dts: BCM5301X: Add DT for ASUS RT-AC5300
  ARM: dts: BCM5301X: Add DT for ASUS RT-AC3200
  dt-bindings: arm: bcm: add bindings for ASUS RT-AC5300
  dt-bindings: arm: bcm: add bindings for ASUS RT-AC3200
  ARM: dts: bcm2835: Add Unicam CSI nodes
  ARM: dts: BCM5301X: remove earlycon on ASUS RT-AC3100 and ASUS RT-AC88U
  ARM: dts: BCM5301X: remove duplicate compatible on ASUS RT-AC3100 & AC88U
  ARM: dts: BCM5301X: provide address for SoC MACs on ASUS RT-AC3100 & AC88U
  ARM: dts: BCM5301X: use color and function on ASUS RT-AC3100 and RT-AC88U
  ARM: dts: bcm2711-rpi-4-b: Add CAM1 regulator
  ARM: dts: bcm2711-rpi-cm4-io: Add RTC on I2C0
  ARM: dts: bcm2711-rpi: Add pinctrl-based multiplexing for I2C0
  ARM: dts: bcm2835-rpi: Move duplicate firmware-clocks to bcm2835-rpi.dtsi
  ARM: dts: bcm283x: Drop unneeded properties in the bcm2835-firmware node
  firmware: raspberrypi: Use correct device for DMA mappings
  dt-bindings: arm: bcm: raspberrypi,bcm2835-firmware: Add gpio child node

Link: https://lore.kernel.org/r/20240429213703.2327834-2-florian.fainelli@broadcom.comSigned-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parents cc5dc7e7 a3592fae
......@@ -53,6 +53,7 @@ properties:
- description: BCM4709 based boards
items:
- enum:
- asus,rt-ac3200
- asus,rt-ac87u
- buffalo,wxr-1900dhp
- linksys,ea9200
......@@ -67,6 +68,7 @@ properties:
items:
- enum:
- asus,rt-ac3100
- asus,rt-ac5300
- asus,rt-ac88u
- dlink,dir-885l
- dlink,dir-890l
......
......@@ -46,6 +46,30 @@ properties:
- compatible
- "#clock-cells"
gpio:
type: object
additionalProperties: false
properties:
compatible:
const: raspberrypi,firmware-gpio
gpio-controller: true
"#gpio-cells":
const: 2
description:
The first cell is the pin number, and the second cell is used to
specify the gpio polarity (GPIO_ACTIVE_HIGH or GPIO_ACTIVE_LOW).
gpio-line-names:
minItems: 8
required:
- compatible
- gpio-controller
- "#gpio-cells"
reset:
type: object
additionalProperties: false
......@@ -96,6 +120,12 @@ examples:
#clock-cells = <1>;
};
expgpio: gpio {
compatible = "raspberrypi,firmware-gpio";
gpio-controller;
#gpio-cells = <2>;
};
reset: reset {
compatible = "raspberrypi,firmware-reset";
#reset-cells = <1>;
......
Raspberry Pi GPIO expander
The Raspberry Pi 3 GPIO expander is controlled by the VC4 firmware. The
firmware exposes a mailbox interface that allows the ARM core to control the
GPIO lines on the expander.
The Raspberry Pi GPIO expander node must be a child node of the Raspberry Pi
firmware node.
Required properties:
- compatible : Should be "raspberrypi,firmware-gpio"
- gpio-controller : Marks the device node as a gpio controller
- #gpio-cells : Should be two. The first cell is the pin number, and
the second cell is used to specify the gpio polarity:
0 = active high
1 = active low
Example:
firmware: firmware-rpi {
compatible = "raspberrypi,bcm2835-firmware";
mboxes = <&mailbox>;
expgpio: gpio {
compatible = "raspberrypi,firmware-gpio";
gpio-controller;
#gpio-cells = <2>;
};
};
......@@ -64,6 +64,7 @@ dtb-$(CONFIG_ARCH_BCM_5301X) += \
bcm47081-luxul-xap-1410.dtb \
bcm47081-luxul-xwr-1200.dtb \
bcm47081-tplink-archer-c5-v2.dtb \
bcm4709-asus-rt-ac3200.dtb \
bcm4709-asus-rt-ac87u.dtb \
bcm4709-buffalo-wxr-1900dhp.dtb \
bcm4709-linksys-ea9200.dtb \
......@@ -71,6 +72,7 @@ dtb-$(CONFIG_ARCH_BCM_5301X) += \
bcm4709-netgear-r8000.dtb \
bcm4709-tplink-archer-c9-v1.dtb \
bcm47094-asus-rt-ac3100.dtb \
bcm47094-asus-rt-ac5300.dtb \
bcm47094-asus-rt-ac88u.dtb \
bcm47094-dlink-dir-885l.dtb \
bcm47094-dlink-dir-890l.dtb \
......
......@@ -5,6 +5,7 @@
#include "bcm283x-rpi-led-deprecated.dtsi"
#include "bcm283x-rpi-usb-peripheral.dtsi"
#include "bcm283x-rpi-wifi-bt.dtsi"
#include <dt-bindings/leds/common.h>
/ {
compatible = "raspberrypi,4-model-b", "brcm,bcm2711";
......@@ -15,6 +16,13 @@ chosen {
stdout-path = "serial1:115200n8";
};
cam1_reg: regulator-cam1 {
compatible = "regulator-fixed";
regulator-name = "cam1-reg";
enable-active-high;
gpio = <&expgpio 5 GPIO_ACTIVE_HIGH>;
};
sd_io_1v8_reg: regulator-sd-io-1v8 {
compatible = "regulator-gpio";
regulator-name = "vdd-sd-io";
......@@ -197,6 +205,27 @@ &genet_mdio {
phy1: ethernet-phy@1 {
/* No PHY interrupt */
reg = <0x1>;
leds {
#address-cells = <1>;
#size-cells = <0>;
/* LED1 */
led@0 {
reg = <0>;
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_LAN;
default-state = "keep";
};
/* LED2 */
led@1 {
reg = <1>;
color = <LED_COLOR_ID_AMBER>;
function = LED_FUNCTION_LAN;
default-state = "keep";
};
};
};
};
......
......@@ -30,6 +30,7 @@ &expgpio {
&genet_mdio {
clock-frequency = <1950000>;
/delete-node/ leds;
};
&led_pwr {
......
// SPDX-License-Identifier: GPL-2.0
/dts-v1/;
#include <dt-bindings/leds/common.h>
#include "bcm2711-rpi-cm4.dtsi"
#include "bcm283x-rpi-led-deprecated.dtsi"
#include "bcm283x-rpi-usb-host.dtsi"
......@@ -101,6 +102,38 @@ &genet {
status = "okay";
};
&i2c0_1 {
rtc@51 {
/* Attention: An alarm resets the machine */
compatible = "nxp,pcf85063a";
reg = <0x51>;
quartz-load-femtofarads = <7000>;
};
};
&phy1 {
leds {
#address-cells = <1>;
#size-cells = <0>;
/* LED2 */
led@1 {
reg = <1>;
color = <LED_COLOR_ID_GREEN>;
function = LED_FUNCTION_LAN;
default-state = "keep";
};
/* LED3 */
led@2 {
reg = <2>;
color = <LED_COLOR_ID_AMBER>;
function = LED_FUNCTION_LAN;
default-state = "keep";
};
};
};
&led_act {
gpios = <&gpio 42 GPIO_ACTIVE_HIGH>;
};
......
......@@ -17,14 +17,33 @@ aliases {
pcie0 = &pcie0;
blconfig = &blconfig;
};
};
&firmware {
firmware_clocks: clocks {
compatible = "raspberrypi,firmware-clocks";
#clock-cells = <1>;
i2c0mux: i2c-mux0 {
compatible = "i2c-mux-pinctrl";
#address-cells = <1>;
#size-cells = <0>;
i2c-parent = <&i2c0>;
pinctrl-names = "i2c0", "i2c0-vc";
pinctrl-0 = <&i2c0_gpio0>;
pinctrl-1 = <&i2c0_gpio44>;
i2c0_0: i2c@0 {
reg = <0>;
#address-cells = <1>;
#size-cells = <0>;
};
i2c0_1: i2c@1 {
reg = <1>;
#address-cells = <1>;
#size-cells = <0>;
};
};
};
&firmware {
expgpio: gpio {
compatible = "raspberrypi,firmware-gpio";
gpio-controller;
......@@ -54,6 +73,11 @@ &hvs {
clocks = <&firmware_clocks 4>;
};
&i2c0 {
/delete-property/ pinctrl-names;
/delete-property/ pinctrl-0;
};
&rmem {
/*
* RPi4's co-processor will copy the board's bootloader configuration
......
......@@ -1114,6 +1114,14 @@ &rmem {
#address-cells = <2>;
};
&csi0 {
interrupts = <GIC_SPI 102 IRQ_TYPE_LEVEL_HIGH>;
};
&csi1 {
interrupts = <GIC_SPI 103 IRQ_TYPE_LEVEL_HIGH>;
};
&cma {
/*
* arm64 reserves the CMA by default somewhere in ZONE_DMA32,
......
......@@ -7,13 +7,6 @@
#include <dt-bindings/power/raspberrypi-power.h>
&firmware {
firmware_clocks: clocks {
compatible = "raspberrypi,firmware-clocks";
#clock-cells = <1>;
};
};
&hdmi {
clocks = <&firmware_clocks 9>,
<&firmware_clocks 13>;
......
......@@ -4,11 +4,12 @@ / {
soc {
firmware: firmware {
compatible = "raspberrypi,bcm2835-firmware", "simple-mfd";
#address-cells = <1>;
#size-cells = <1>;
mboxes = <&mailbox>;
dma-ranges;
firmware_clocks: clocks {
compatible = "raspberrypi,firmware-clocks";
#clock-cells = <1>;
};
};
power: power {
......@@ -25,6 +26,20 @@ vchiq: mailbox@7e00b840 {
};
};
&csi0 {
clocks = <&clocks BCM2835_CLOCK_CAM0>,
<&firmware_clocks 4>;
clock-names = "lp", "vpu";
power-domains = <&power RPI_POWER_DOMAIN_UNICAM0>;
};
&csi1 {
clocks = <&clocks BCM2835_CLOCK_CAM1>,
<&firmware_clocks 4>;
clock-names = "lp", "vpu";
power-domains = <&power RPI_POWER_DOMAIN_UNICAM1>;
};
&gpio {
gpioout: gpioout {
brcm,pins = <6>;
......
......@@ -454,6 +454,30 @@ dsi1: dsi@7e700000 {
status = "disabled";
};
csi0: csi@7e800000 {
compatible = "brcm,bcm2835-unicam";
reg = <0x7e800000 0x800>,
<0x7e802000 0x4>;
reg-names = "unicam", "cmi";
interrupts = <2 6>;
brcm,num-data-lanes = <2>;
status = "disabled";
port {
};
};
csi1: csi@7e801000 {
compatible = "brcm,bcm2835-unicam";
reg = <0x7e801000 0x800>,
<0x7e802004 0x4>;
reg-names = "unicam", "cmi";
interrupts = <2 7>;
brcm,num-data-lanes = <4>;
status = "disabled";
port {
};
};
i2c1: i2c@7e804000 {
compatible = "brcm,bcm2835-i2c";
reg = <0x7e804000 0x1000>;
......
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
/*
* Author: Tom Brautaset <tbrautaset@gmail.com>
*/
/dts-v1/;
#include "bcm4709.dtsi"
#include "bcm5301x-nand-cs0-bch8.dtsi"
#include <dt-bindings/leds/common.h>
/ {
compatible = "asus,rt-ac3200", "brcm,bcm4709", "brcm,bcm4708";
model = "ASUS RT-AC3200";
memory@0 {
reg = <0x00000000 0x08000000>,
<0x88000000 0x08000000>;
device_type = "memory";
};
nvram@1c080000 {
compatible = "brcm,nvram";
reg = <0x1c080000 0x00180000>;
et0macaddr: et0macaddr {
#nvmem-cell-cells = <1>;
};
};
gpio-keys {
compatible = "gpio-keys";
button-reset {
label = "Reset";
linux,code = <KEY_RESTART>;
gpios = <&chipcommon 11 GPIO_ACTIVE_LOW>;
};
button-wifi {
label = "Wi-Fi";
linux,code = <KEY_RFKILL>;
gpios = <&chipcommon 4 GPIO_ACTIVE_LOW>;
};
button-wps {
label = "WPS";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&chipcommon 7 GPIO_ACTIVE_LOW>;
};
};
leds {
compatible = "gpio-leds";
led-power {
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_POWER;
gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
linux,default-trigger = "default-on";
};
led-wan-red {
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_WAN;
gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>;
};
led-wps {
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_WPS;
gpios = <&chipcommon 14 GPIO_ACTIVE_LOW>;
};
};
};
&gmac0 {
nvmem-cells = <&et0macaddr 0>;
nvmem-cell-names = "mac-address";
};
&gmac1 {
nvmem-cells = <&et0macaddr 1>;
nvmem-cell-names = "mac-address";
};
&gmac2 {
nvmem-cells = <&et0macaddr 2>;
nvmem-cell-names = "mac-address";
};
&nandcs {
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
reg = <0x00000000 0x00080000>;
label = "boot";
read-only;
};
partition@80000 {
reg = <0x00080000 0x00180000>;
label = "nvram";
};
partition@200000 {
compatible = "brcm,trx";
reg = <0x00200000 0x07e00000>;
label = "firmware";
};
};
};
&srab {
status = "okay";
ports {
port@0 {
label = "wan";
};
port@1 {
label = "lan1";
};
port@2 {
label = "lan2";
};
port@3 {
label = "lan3";
};
port@4 {
label = "lan4";
};
};
};
&usb2 {
vcc-gpio = <&chipcommon 9 GPIO_ACTIVE_HIGH>;
};
&usb3_phy {
status = "okay";
};
......@@ -13,11 +13,22 @@ / {
nvram@1c080000 {
et0macaddr: et0macaddr {
#nvmem-cell-cells = <1>;
};
};
};
&gmac0 {
nvmem-cells = <&et0macaddr>;
nvmem-cells = <&et0macaddr 0>;
nvmem-cell-names = "mac-address";
};
&gmac1 {
nvmem-cells = <&et0macaddr 1>;
nvmem-cell-names = "mac-address";
};
&gmac2 {
nvmem-cells = <&et0macaddr 2>;
nvmem-cell-names = "mac-address";
};
......@@ -6,15 +6,13 @@
#include "bcm47094.dtsi"
#include "bcm5301x-nand-cs0-bch8.dtsi"
/ {
chosen {
bootargs = "earlycon";
};
#include <dt-bindings/leds/common.h>
/ {
memory@0 {
device_type = "memory";
reg = <0x00000000 0x08000000>,
<0x88000000 0x18000000>;
device_type = "memory";
};
nvram@1c080000 {
......@@ -22,76 +20,108 @@ nvram@1c080000 {
reg = <0x1c080000 0x00180000>;
};
leds {
compatible = "gpio-leds";
gpio-keys {
compatible = "gpio-keys";
led-power {
label = "white:power";
gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
linux,default-trigger = "default-on";
button-led {
label = "Backlight";
linux,code = <KEY_BRIGHTNESS_ZERO>;
gpios = <&chipcommon 4 GPIO_ACTIVE_LOW>;
};
led-wan-red {
label = "red:wan";
gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>;
button-reset {
label = "Reset";
linux,code = <KEY_RESTART>;
gpios = <&chipcommon 11 GPIO_ACTIVE_LOW>;
};
button-wifi {
label = "Wi-Fi";
linux,code = <KEY_RFKILL>;
gpios = <&chipcommon 18 GPIO_ACTIVE_LOW>;
};
button-wps {
label = "WPS";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&chipcommon 20 GPIO_ACTIVE_LOW>;
};
};
leds {
compatible = "gpio-leds";
led-lan {
label = "white:lan";
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_LAN;
gpios = <&chipcommon 21 GPIO_ACTIVE_LOW>;
};
led-power {
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_POWER;
gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
linux,default-trigger = "default-on";
};
led-usb2 {
label = "white:usb2";
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_USB;
function-enumerator = <1>;
gpios = <&chipcommon 16 GPIO_ACTIVE_LOW>;
trigger-sources = <&ehci_port2>;
linux,default-trigger = "usbport";
};
led-usb3 {
label = "white:usb3";
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_USB;
function-enumerator = <2>;
gpios = <&chipcommon 17 GPIO_ACTIVE_LOW>;
trigger-sources = <&ehci_port1>, <&xhci_port1>;
linux,default-trigger = "usbport";
};
led-wan-red {
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_WAN;
gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>;
};
led-wps {
label = "white:wps";
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_WPS;
gpios = <&chipcommon 19 GPIO_ACTIVE_LOW>;
};
};
};
gpio-keys {
compatible = "gpio-keys";
button-wps {
label = "WPS";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&chipcommon 20 GPIO_ACTIVE_LOW>;
};
&nandcs {
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
button-reset {
label = "Reset";
linux,code = <KEY_RESTART>;
gpios = <&chipcommon 11 GPIO_ACTIVE_LOW>;
partition@0 {
reg = <0x00000000 0x00080000>;
label = "boot";
read-only;
};
button-wifi {
label = "Wi-Fi";
linux,code = <KEY_RFKILL>;
gpios = <&chipcommon 18 GPIO_ACTIVE_LOW>;
partition@80000 {
reg = <0x00080000 0x00180000>;
label = "nvram";
};
button-led {
label = "Backlight";
linux,code = <KEY_BRIGHTNESS_ZERO>;
gpios = <&chipcommon 4 GPIO_ACTIVE_LOW>;
partition@200000 {
compatible = "brcm,trx";
reg = <0x00200000 0x07e00000>;
label = "firmware";
};
};
};
&srab {
compatible = "brcm,bcm53012-srab", "brcm,bcm5301x-srab";
status = "okay";
ports {
......@@ -136,28 +166,3 @@ &usb2 {
&usb3_phy {
status = "okay";
};
&nandcs {
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
label = "boot";
reg = <0x00000000 0x00080000>;
read-only;
};
partition@80000 {
label = "nvram";
reg = <0x00080000 0x00180000>;
};
partition@200000 {
label = "firmware";
reg = <0x00200000 0x07e00000>;
compatible = "brcm,trx";
};
};
};
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
/*
* Author: Tom Brautaset <tbrautaset@gmail.com>
*/
/dts-v1/;
#include "bcm47094.dtsi"
#include "bcm5301x-nand-cs0-bch8.dtsi"
#include <dt-bindings/leds/common.h>
/ {
compatible = "asus,rt-ac5300", "brcm,bcm47094", "brcm,bcm4708";
model = "ASUS RT-AC5300";
memory@0 {
reg = <0x00000000 0x08000000>,
<0x88000000 0x18000000>;
device_type = "memory";
};
nvram@1c080000 {
compatible = "brcm,nvram";
reg = <0x1c080000 0x00180000>;
et1macaddr: et1macaddr {
#nvmem-cell-cells = <1>;
};
};
gpio-keys {
compatible = "gpio-keys";
button-reset {
label = "Reset";
linux,code = <KEY_RESTART>;
gpios = <&chipcommon 11 GPIO_ACTIVE_LOW>;
};
button-wifi {
label = "Wi-Fi";
linux,code = <KEY_RFKILL>;
gpios = <&chipcommon 20 GPIO_ACTIVE_LOW>;
};
button-wps {
label = "WPS";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&chipcommon 18 GPIO_ACTIVE_LOW>;
};
};
leds {
compatible = "gpio-leds";
led-lan {
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_LAN;
gpios = <&chipcommon 21 GPIO_ACTIVE_LOW>;
};
led-power {
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_POWER;
gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>;
linux,default-trigger = "default-on";
};
led-wan-red {
color = <LED_COLOR_ID_RED>;
function = LED_FUNCTION_WAN;
gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>;
};
led-wps {
color = <LED_COLOR_ID_WHITE>;
function = LED_FUNCTION_WPS;
gpios = <&chipcommon 19 GPIO_ACTIVE_LOW>;
};
};
};
&gmac0 {
nvmem-cells = <&et1macaddr 0>;
nvmem-cell-names = "mac-address";
};
&gmac1 {
nvmem-cells = <&et1macaddr 1>;
nvmem-cell-names = "mac-address";
};
&gmac2 {
nvmem-cells = <&et1macaddr 2>;
nvmem-cell-names = "mac-address";
};
&nandcs {
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
reg = <0x00000000 0x00080000>;
label = "boot";
read-only;
};
partition@80000 {
reg = <0x00080000 0x00180000>;
label = "nvram";
};
partition@200000 {
compatible = "brcm,trx";
reg = <0x00200000 0x07e00000>;
label = "firmware";
};
};
};
&srab {
status = "okay";
ports {
port@0 {
label = "lan4";
};
port@1 {
label = "lan3";
};
port@2 {
label = "lan2";
};
port@3 {
label = "lan1";
};
port@4 {
label = "wan";
};
};
};
&usb2 {
vcc-gpio = <&chipcommon 9 GPIO_ACTIVE_HIGH>;
};
&usb3_phy {
status = "okay";
};
......@@ -13,18 +13,40 @@ / {
nvram@1c080000 {
et1macaddr: et1macaddr {
#nvmem-cell-cells = <1>;
};
};
switch {
compatible = "realtek,rtl8365mb";
/* 7 = MDIO (has input reads), 6 = MDC (clock, output only) */
mdc-gpios = <&chipcommon 6 GPIO_ACTIVE_HIGH>;
mdio-gpios = <&chipcommon 7 GPIO_ACTIVE_HIGH>;
reset-gpios = <&chipcommon 10 GPIO_ACTIVE_LOW>;
realtek,disable-leds;
dsa,member = <1 0>;
mdio {
compatible = "realtek,smi-mdio";
#address-cells = <1>;
#size-cells = <0>;
ethphy0: ethernet-phy@0 {
reg = <0>;
};
ethphy1: ethernet-phy@1 {
reg = <1>;
};
ethphy2: ethernet-phy@2 {
reg = <2>;
};
ethphy3: ethernet-phy@3 {
reg = <3>;
};
};
ports {
#address-cells = <1>;
#size-cells = <0>;
......@@ -68,29 +90,21 @@ fixed-link {
};
};
};
};
};
mdio {
compatible = "realtek,smi-mdio";
#address-cells = <1>;
#size-cells = <0>;
ethphy0: ethernet-phy@0 {
reg = <0>;
};
ethphy1: ethernet-phy@1 {
reg = <1>;
};
&gmac0 {
status = "disabled";
};
ethphy2: ethernet-phy@2 {
reg = <2>;
};
&gmac1 {
nvmem-cells = <&et1macaddr 0>;
nvmem-cell-names = "mac-address";
};
ethphy3: ethernet-phy@3 {
reg = <3>;
};
};
};
&gmac2 {
nvmem-cells = <&et1macaddr 1>;
nvmem-cell-names = "mac-address";
};
&srab {
......@@ -111,12 +125,3 @@ fixed-link {
};
};
};
&gmac0 {
status = "disabled";
};
&gmac1 {
nvmem-cells = <&et1macaddr>;
nvmem-cell-names = "mac-address";
};
......@@ -9,6 +9,7 @@
#include <linux/dma-mapping.h>
#include <linux/kref.h>
#include <linux/mailbox_client.h>
#include <linux/mailbox_controller.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/of_platform.h>
......@@ -97,8 +98,8 @@ int rpi_firmware_property_list(struct rpi_firmware *fw,
if (size & 3)
return -EINVAL;
buf = dma_alloc_coherent(fw->cl.dev, PAGE_ALIGN(size), &bus_addr,
GFP_ATOMIC);
buf = dma_alloc_coherent(fw->chan->mbox->dev, PAGE_ALIGN(size),
&bus_addr, GFP_ATOMIC);
if (!buf)
return -ENOMEM;
......@@ -126,7 +127,7 @@ int rpi_firmware_property_list(struct rpi_firmware *fw,
ret = -EINVAL;
}
dma_free_coherent(fw->cl.dev, PAGE_ALIGN(size), buf, bus_addr);
dma_free_coherent(fw->chan->mbox->dev, PAGE_ALIGN(size), buf, bus_addr);
return ret;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment