diff mbox series

ARM: dts: BCM5301X: Set MACs for D-Link DIR-885L

Message ID 20230901105549.7076-1-zajec5@gmail.com (mailing list archive)
State New, archived
Headers show
Series ARM: dts: BCM5301X: Set MACs for D-Link DIR-885L | expand

Commit Message

Rafał Miłecki Sept. 1, 2023, 10:55 a.m. UTC
From: Rafał Miłecki <rafal@milecki.pl>

Specify NVRAM access and use its "et2macaddr" NVMEM cell.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
---
 .../dts/broadcom/bcm47094-dlink-dir-885l.dts     | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

Comments

Florian Fainelli Sept. 6, 2023, 8:55 p.m. UTC | #1
From: Florian Fainelli <f.fainelli@gmail.com>

On Fri,  1 Sep 2023 12:55:49 +0200, Rafał Miłecki <zajec5@gmail.com> wrote:
> From: Rafał Miłecki <rafal@milecki.pl>
> 
> Specify NVRAM access and use its "et2macaddr" NVMEM cell.
> 
> Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
> ---

Applied to https://github.com/Broadcom/stblinux/commits/devicetree/next, thanks!
--
Florian
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/broadcom/bcm47094-dlink-dir-885l.dts b/arch/arm/boot/dts/broadcom/bcm47094-dlink-dir-885l.dts
index c914569ddd5e..abe0cb245c7e 100644
--- a/arch/arm/boot/dts/broadcom/bcm47094-dlink-dir-885l.dts
+++ b/arch/arm/boot/dts/broadcom/bcm47094-dlink-dir-885l.dts
@@ -25,6 +25,15 @@  memory@0 {
 		      <0x88000000 0x08000000>;
 	};
 
+	nvram@1e3f0000 {
+		compatible = "brcm,nvram";
+		reg = <0x1e3f0000 0x10000>;
+
+		et2macaddr: et2macaddr {
+			#nvmem-cell-cells = <1>;
+		};
+	};
+
 	nand_controller: nand-controller@18028000 {
 		nand@0 {
 			partitions {
@@ -112,6 +121,11 @@  &usb3 {
 	vcc-gpio = <&chipcommon 18 GPIO_ACTIVE_HIGH>;
 };
 
+&gmac0 {
+	nvmem-cells = <&et2macaddr 0>;
+	nvmem-cell-names = "mac-address";
+};
+
 &spi_nor {
 	status = "okay";
 };
@@ -142,6 +156,8 @@  port@3 {
 
 		port@4 {
 			label = "wan";
+			nvmem-cells = <&et2macaddr 3>;
+			nvmem-cell-names = "mac-address";
 		};
 
 		port@8 {