Skip to contentSkip to conversation

arm64: tegra: Add ethernet alias on Jetson TX1

PATCH Thierry Reding 1 participant 1 message Jun 13, 2019 2 messages not in the archive Tegra architecture support

lore
Share & tools
lore
#2 lore raw
In reply to a message not in the archive
Quoted 8 lines · Stephen Warren
Quoted 6 lines · Thierry Reding

From: Thierry Reding <[email protected]>

Adding this alias for the Ethernet interface on Jetson TX1 allows the bootloader to pass the MAC address to the Linux kernel.

arch/arm64/boot/dts/nvidia/tegra210-p2597.dtsi +0 -0
Quoted 7 lines

arch/arm64/boot/dts/nvidia/tegra210-p2597.dtsi

Quoted 3 lines
arch/arm64/boot/dts/nvidia/tegra210-p2597.dtsi +3 -0
+	aliases {
+		ethernet = "/usb@70090000/ethernet@1";
+	};

Don't aliases require an ID in the property name, i.e shouldn't this be "ethernet0" rather than just "ethernet"? This is a bit more obvious in the TX2 patch where sdhci0, sdhci1, and serial0 are shown in the diff context.

I don't think there's a requirement for aliases to have an ID. The IDs, in the cases that I'm aware of, are used to fix the index given to the controllers in Linux (which is sometimes abused to get fixed numbering that can be hardcoded, rather than having a more robust way to look up the right hardware block).

U-Boot has a comment somewhere about ethernet being equivalent to ethernet0 and it treats them the same way, if I remember correctly.

As for upstream Linux, there does indeed seem to be a slight tendency towards ethernet0, though it's pretty well mixed. 32-bit ARM is mostly balanced, whereas 64-bit ARM uses ethernet0 almost exclusively. Maybe this means that recently there's been a push to standardize on always adding the index?

Quoted 1 line

Patch should probably be CC'd to some/all of ARM/DT/... mailing lists?

Oops... I meant to include those. Added now.

Thierry

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel