Commit 687e3d55 authored by Petr Štetiar's avatar Petr Štetiar Committed by David S. Miller

dt-bindings: doc: reflect new NVMEM of_get_mac_address behaviour

As of_get_mac_address now supports NVMEM under the hood, we need to update
the bindings documentation with the new nvmem-cell* properties, which would
mean copy&pasting a lot of redundant information to every binding
documentation currently referencing some of the MAC address properties.

So I've just removed all the references to the optional MAC address
properties and replaced them with the small note referencing
net/ethernet.txt file.
Signed-off-by: default avatarPetr Štetiar <ynezz@true.cz>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent d01f449c
...@@ -46,9 +46,8 @@ Required properties: ...@@ -46,9 +46,8 @@ Required properties:
- reg: phy id used to communicate to phy. - reg: phy id used to communicate to phy.
- device_type: Must be "ethernet-phy". - device_type: Must be "ethernet-phy".
Optional properties: The MAC address will be determined using the optional properties defined in
- local-mac-address: See ethernet.txt in the same directory. ethernet.txt.
- max-frame-size: See ethernet.txt in the same directory.
Example: Example:
......
...@@ -24,8 +24,6 @@ Required properties: ...@@ -24,8 +24,6 @@ Required properties:
- phy-mode: See ethernet.txt file in the same directory - phy-mode: See ethernet.txt file in the same directory
Optional properties: Optional properties:
- mac-address: mac address to be assigned to the device. Can be overridden
by UEFI.
- dma-coherent: Present if dma operations are coherent - dma-coherent: Present if dma operations are coherent
- amd,per-channel-interrupt: Indicates that Rx and Tx complete will generate - amd,per-channel-interrupt: Indicates that Rx and Tx complete will generate
a unique interrupt for each DMA channel - this requires an additional a unique interrupt for each DMA channel - this requires an additional
...@@ -34,6 +32,9 @@ Optional properties: ...@@ -34,6 +32,9 @@ Optional properties:
0 - 1GbE and 10GbE (default) 0 - 1GbE and 10GbE (default)
1 - 2.5GbE and 10GbE 1 - 2.5GbE and 10GbE
The MAC address will be determined using the optional properties defined in
ethernet.txt.
The following optional properties are represented by an array with each The following optional properties are represented by an array with each
value corresponding to a particular speed. The first array value represents value corresponding to a particular speed. The first array value represents
the setting for the 1GbE speed, the second value for the 2.5GbE speed and the setting for the 1GbE speed, the second value for the 2.5GbE speed and
......
...@@ -16,8 +16,8 @@ Required properties: ...@@ -16,8 +16,8 @@ Required properties:
registers (required for Northstar2) registers (required for Northstar2)
- interrupts: Interrupt number - interrupts: Interrupt number
Optional properties: The MAC address will be determined using the optional properties
- mac-address: See ethernet.txt file in the same directory defined in ethernet.txt.
Examples: Examples:
......
...@@ -49,10 +49,12 @@ Required properties: ...@@ -49,10 +49,12 @@ Required properties:
Optional properties: Optional properties:
- dual_emac_res_vlan : Specifies VID to be used to segregate the ports - dual_emac_res_vlan : Specifies VID to be used to segregate the ports
- mac-address : See ethernet.txt file in the same directory
- phy_id : Specifies slave phy id (deprecated, use phy-handle) - phy_id : Specifies slave phy id (deprecated, use phy-handle)
- phy-handle : See ethernet.txt file in the same directory - phy-handle : See ethernet.txt file in the same directory
The MAC address will be determined using the optional properties
defined in ethernet.txt.
Slave sub-nodes: Slave sub-nodes:
- fixed-link : See fixed-link.txt file in the same directory - fixed-link : See fixed-link.txt file in the same directory
......
...@@ -20,11 +20,12 @@ Required properties: ...@@ -20,11 +20,12 @@ Required properties:
Optional properties: Optional properties:
- phy-handle: See ethernet.txt file in the same directory. - phy-handle: See ethernet.txt file in the same directory.
If absent, davinci_emac driver defaults to 100/FULL. If absent, davinci_emac driver defaults to 100/FULL.
- nvmem-cells: phandle, reference to an nvmem node for the MAC address
- nvmem-cell-names: string, should be "mac-address" if nvmem is to be used
- ti,davinci-rmii-en: 1 byte, 1 means use RMII - ti,davinci-rmii-en: 1 byte, 1 means use RMII
- ti,davinci-no-bd-ram: boolean, does EMAC have BD RAM? - ti,davinci-no-bd-ram: boolean, does EMAC have BD RAM?
The MAC address will be determined using the optional properties
defined in ethernet.txt.
Example (enbw_cmc board): Example (enbw_cmc board):
eth0: emac@1e20000 { eth0: emac@1e20000 {
compatible = "ti,davinci-dm6467-emac"; compatible = "ti,davinci-dm6467-emac";
......
...@@ -65,9 +65,8 @@ properties, described in binding documents: ...@@ -65,9 +65,8 @@ properties, described in binding documents:
Documentation/devicetree/bindings/net/fixed-link.txt Documentation/devicetree/bindings/net/fixed-link.txt
for details. for details.
- local-mac-address : See The MAC address will be determined using the optional properties
Documentation/devicetree/bindings/net/ethernet.txt defined in ethernet.txt.
for details.
Example Example
......
...@@ -4,12 +4,14 @@ NOTE: All 'phy*' properties documented below are Ethernet specific. For the ...@@ -4,12 +4,14 @@ NOTE: All 'phy*' properties documented below are Ethernet specific. For the
generic PHY 'phys' property, see generic PHY 'phys' property, see
Documentation/devicetree/bindings/phy/phy-bindings.txt. Documentation/devicetree/bindings/phy/phy-bindings.txt.
- local-mac-address: array of 6 bytes, specifies the MAC address that was
assigned to the network device;
- mac-address: array of 6 bytes, specifies the MAC address that was last used by - mac-address: array of 6 bytes, specifies the MAC address that was last used by
the boot program; should be used in cases where the MAC address assigned to the boot program; should be used in cases where the MAC address assigned to
the device by the boot program is different from the "local-mac-address" the device by the boot program is different from the "local-mac-address"
property; property;
- local-mac-address: array of 6 bytes, specifies the MAC address that was
assigned to the network device;
- nvmem-cells: phandle, reference to an nvmem node for the MAC address
- nvmem-cell-names: string, should be "mac-address" if nvmem is to be used
- max-speed: number, specifies maximum speed in Mbit/s supported by the device; - max-speed: number, specifies maximum speed in Mbit/s supported by the device;
- max-frame-size: number, maximum transfer unit (IEEE defined MTU), rather than - max-frame-size: number, maximum transfer unit (IEEE defined MTU), rather than
the maximum frame size (there's contradiction in the Devicetree the maximum frame size (there's contradiction in the Devicetree
......
...@@ -14,7 +14,6 @@ Required properties: ...@@ -14,7 +14,6 @@ Required properties:
the PHY reset signal(optional). the PHY reset signal(optional).
- reset-names: should contain the reset signal name "mac"(required) - reset-names: should contain the reset signal name "mac"(required)
and "phy"(optional). and "phy"(optional).
- mac-address: see ethernet.txt [1].
- phy-mode: see ethernet.txt [1]. - phy-mode: see ethernet.txt [1].
- phy-handle: see ethernet.txt [1]. - phy-handle: see ethernet.txt [1].
- hisilicon,phy-reset-delays-us: triplet of delays if PHY reset signal given. - hisilicon,phy-reset-delays-us: triplet of delays if PHY reset signal given.
...@@ -22,6 +21,9 @@ Required properties: ...@@ -22,6 +21,9 @@ Required properties:
The 2nd cell is reset pulse in micro seconds. The 2nd cell is reset pulse in micro seconds.
The 3rd cell is reset post-delay in micro seconds. The 3rd cell is reset post-delay in micro seconds.
The MAC address will be determined using the optional properties
defined in ethernet.txt[1].
[1] Documentation/devicetree/bindings/net/ethernet.txt [1] Documentation/devicetree/bindings/net/ethernet.txt
Example: Example:
......
...@@ -18,7 +18,6 @@ Required properties: ...@@ -18,7 +18,6 @@ Required properties:
- #size-cells: must be <0>. - #size-cells: must be <0>.
- phy-mode: see ethernet.txt [1]. - phy-mode: see ethernet.txt [1].
- phy-handle: see ethernet.txt [1]. - phy-handle: see ethernet.txt [1].
- mac-address: see ethernet.txt [1].
- clocks: clock phandle and specifier pair. - clocks: clock phandle and specifier pair.
- clock-names: contain the clock name "mac_core"(required) and "mac_ifc"(optional). - clock-names: contain the clock name "mac_core"(required) and "mac_ifc"(optional).
- resets: should contain the phandle to the MAC core reset signal(optional), - resets: should contain the phandle to the MAC core reset signal(optional),
...@@ -31,6 +30,9 @@ Required properties: ...@@ -31,6 +30,9 @@ Required properties:
The 2nd cell is reset pulse in micro seconds. The 2nd cell is reset pulse in micro seconds.
The 3rd cell is reset post-delay in micro seconds. The 3rd cell is reset post-delay in micro seconds.
The MAC address will be determined using the properties defined in
ethernet.txt[1].
- PHY subnode: inherits from phy binding [2] - PHY subnode: inherits from phy binding [2]
[1] Documentation/devicetree/bindings/net/ethernet.txt [1] Documentation/devicetree/bindings/net/ethernet.txt
......
...@@ -135,14 +135,14 @@ Optional properties: ...@@ -135,14 +135,14 @@ Optional properties:
are swapped. The netcp driver will swap the two DWORDs are swapped. The netcp driver will swap the two DWORDs
back to the proper order when this property is set to 2 back to the proper order when this property is set to 2
when it obtains the mac address from efuse. when it obtains the mac address from efuse.
- local-mac-address: the driver is designed to use the of_get_mac_address api
only if efuse-mac is 0. When efuse-mac is 0, the MAC
address is obtained from local-mac-address. If this
attribute is not present, then the driver will use a
random MAC address.
- "netcp-device label": phandle to the device specification for each of NetCP - "netcp-device label": phandle to the device specification for each of NetCP
sub-module attached to this interface. sub-module attached to this interface.
The MAC address will be determined using the optional properties defined in
ethernet.txt, as provided by the of_get_mac_address API and only if efuse-mac
is set to 0. If any of the optional MAC address properties are not present,
then the driver will use random MAC address.
Example binding: Example binding:
netcp: netcp@2000000 { netcp: netcp@2000000 {
......
...@@ -26,9 +26,8 @@ Required properties: ...@@ -26,9 +26,8 @@ Required properties:
Optional elements: 'tsu_clk' Optional elements: 'tsu_clk'
- clocks: Phandles to input clocks. - clocks: Phandles to input clocks.
Optional properties: The MAC address will be determined using the optional properties
- nvmem-cells: phandle, reference to an nvmem node for the MAC address defined in ethernet.txt.
- nvmem-cell-names: string, should be "mac-address" if nvmem is to be used
Optional properties for PHY child node: Optional properties for PHY child node:
- reset-gpios : Should specify the gpio for phy reset - reset-gpios : Should specify the gpio for phy reset
......
...@@ -11,7 +11,9 @@ Optional properties: ...@@ -11,7 +11,9 @@ Optional properties:
- #address-cells: must be 1 when using sub-nodes. - #address-cells: must be 1 when using sub-nodes.
- #size-cells: must be 0 when using sub-nodes. - #size-cells: must be 0 when using sub-nodes.
- phy-handle: see ethernet.txt file in the same directory. - phy-handle: see ethernet.txt file in the same directory.
- local-mac-address: see ethernet.txt file in the same directory.
The MAC address will be determined using the optional properties
defined in ethernet.txt.
Sub-nodes: Sub-nodes:
Each PHY can be represented as a sub-node. This is not mandatory. Each PHY can be represented as a sub-node. This is not mandatory.
......
...@@ -21,8 +21,9 @@ Optional properties: ...@@ -21,8 +21,9 @@ Optional properties:
- spi-max-frequency: Maximum frequency of the SPI bus when accessing the ENC28J60. - spi-max-frequency: Maximum frequency of the SPI bus when accessing the ENC28J60.
According to the ENC28J80 datasheet, the chip allows a maximum of 20 MHz, however, According to the ENC28J80 datasheet, the chip allows a maximum of 20 MHz, however,
board designs may need to limit this value. board designs may need to limit this value.
- local-mac-address: See ethernet.txt in the same directory.
The MAC address will be determined using the optional properties
defined in ethernet.txt.
Example (for NXP i.MX28 with pin control stuff for GPIO irq): Example (for NXP i.MX28 with pin control stuff for GPIO irq):
......
...@@ -7,9 +7,8 @@ The Device Tree properties, if present, override the OTP and EEPROM. ...@@ -7,9 +7,8 @@ The Device Tree properties, if present, override the OTP and EEPROM.
Required properties: Required properties:
- compatible: Should be one of "usb424,7800", "usb424,7801" or "usb424,7850". - compatible: Should be one of "usb424,7800", "usb424,7801" or "usb424,7850".
Optional properties: The MAC address will be determined using the optional properties
- local-mac-address: see ethernet.txt defined in ethernet.txt.
- mac-address: see ethernet.txt
Optional properties of the embedded PHY: Optional properties of the embedded PHY:
- microchip,led-modes: a 0..4 element vector, with each element configuring - microchip,led-modes: a 0..4 element vector, with each element configuring
......
...@@ -23,7 +23,6 @@ Optional properties: ...@@ -23,7 +23,6 @@ Optional properties:
Numbers smaller than 1000000 or greater than 16000000 Numbers smaller than 1000000 or greater than 16000000
are invalid. Missing the property will set the SPI are invalid. Missing the property will set the SPI
frequency to 8000000 Hertz. frequency to 8000000 Hertz.
- local-mac-address : see ./ethernet.txt
- qca,legacy-mode : Set the SPI data transfer of the QCA7000 to legacy mode. - qca,legacy-mode : Set the SPI data transfer of the QCA7000 to legacy mode.
In this mode the SPI master must toggle the chip select In this mode the SPI master must toggle the chip select
between each data word. In burst mode these gaps aren't between each data word. In burst mode these gaps aren't
...@@ -31,6 +30,9 @@ Optional properties: ...@@ -31,6 +30,9 @@ Optional properties:
the QCA7000 is setup via GPIO pin strapping. If the the QCA7000 is setup via GPIO pin strapping. If the
property is missing the driver defaults to burst mode. property is missing the driver defaults to burst mode.
The MAC address will be determined using the optional properties
defined in ethernet.txt.
SPI Example: SPI Example:
/* Freescale i.MX28 SPI master*/ /* Freescale i.MX28 SPI master*/
......
...@@ -21,10 +21,12 @@ Required properties: ...@@ -21,10 +21,12 @@ Required properties:
range. range.
Optional properties: Optional properties:
- mac-address: 6 bytes, mac address
- max-frame-size: Maximum Transfer Unit (IEEE defined MTU), rather - max-frame-size: Maximum Transfer Unit (IEEE defined MTU), rather
than the maximum frame size. than the maximum frame size.
The MAC address will be determined using the optional properties
defined in ethernet.txt.
Example: Example:
aliases { aliases {
......
...@@ -103,8 +103,6 @@ Required properties: ...@@ -103,8 +103,6 @@ Required properties:
Optional properties: Optional properties:
- dma-coherent: Present if dma operations are coherent - dma-coherent: Present if dma operations are coherent
- mac-address: See ethernet.txt in the same directory
- local-mac-address: See ethernet.txt in the same directory
- phy-reset-gpios: Phandle and specifier for any GPIO used to reset the PHY. - phy-reset-gpios: Phandle and specifier for any GPIO used to reset the PHY.
See ../gpio/gpio.txt. See ../gpio/gpio.txt.
- snps,en-lpi: If present it enables use of the AXI low-power interface - snps,en-lpi: If present it enables use of the AXI low-power interface
...@@ -133,6 +131,9 @@ Optional properties: ...@@ -133,6 +131,9 @@ Optional properties:
- device_type: Must be "ethernet-phy". - device_type: Must be "ethernet-phy".
- fixed-mode device tree subnode: see fixed-link.txt in the same directory - fixed-mode device tree subnode: see fixed-link.txt in the same directory
The MAC address will be determined using the optional properties
defined in ethernet.txt.
Examples: Examples:
ethernet2@40010000 { ethernet2@40010000 {
clock-names = "phy_ref_clk", "apb_pclk"; clock-names = "phy_ref_clk", "apb_pclk";
......
...@@ -31,8 +31,8 @@ Required properties: ...@@ -31,8 +31,8 @@ Required properties:
- socionext,syscon-phy-mode: A phandle to syscon with one argument - socionext,syscon-phy-mode: A phandle to syscon with one argument
that configures phy mode. The argument is the ID of MAC instance. that configures phy mode. The argument is the ID of MAC instance.
Optional properties: The MAC address will be determined using the optional properties
- local-mac-address: See ethernet.txt in the same directory. defined in ethernet.txt.
Required subnode: Required subnode:
- mdio: A container for child nodes representing phy nodes. - mdio: A container for child nodes representing phy nodes.
......
...@@ -26,11 +26,12 @@ Required properties: ...@@ -26,11 +26,12 @@ Required properties:
Optional properties: (See ethernet.txt file in the same directory) Optional properties: (See ethernet.txt file in the same directory)
- dma-coherent: Boolean property, must only be present if memory - dma-coherent: Boolean property, must only be present if memory
accesses performed by the device are cache coherent. accesses performed by the device are cache coherent.
- local-mac-address: See ethernet.txt in the same directory.
- mac-address: See ethernet.txt in the same directory.
- max-speed: See ethernet.txt in the same directory. - max-speed: See ethernet.txt in the same directory.
- max-frame-size: See ethernet.txt in the same directory. - max-frame-size: See ethernet.txt in the same directory.
The MAC address will be determined using the optional properties
defined in ethernet.txt.
Example: Example:
eth0: ethernet@522d0000 { eth0: ethernet@522d0000 {
compatible = "socionext,synquacer-netsec"; compatible = "socionext,synquacer-netsec";
......
...@@ -13,11 +13,12 @@ properties: ...@@ -13,11 +13,12 @@ properties:
Optional properties: Optional properties:
- mac-address: See ethernet.txt in the parent directory
- local-mac-address: See ethernet.txt in the parent directory
- ieee80211-freq-limit: See ieee80211.txt - ieee80211-freq-limit: See ieee80211.txt
- mediatek,mtd-eeprom: Specify a MTD partition + offset containing EEPROM data - mediatek,mtd-eeprom: Specify a MTD partition + offset containing EEPROM data
The driver is using of_get_mac_address API, so the MAC address can be as well
be set with corresponding optional properties defined in net/ethernet.txt.
Optional nodes: Optional nodes:
- led: Properties for a connected LED - led: Properties for a connected LED
Optional properties: Optional properties:
......
...@@ -34,9 +34,9 @@ Optional properties: ...@@ -34,9 +34,9 @@ Optional properties:
ath9k wireless chip (in this case the calibration / ath9k wireless chip (in this case the calibration /
EEPROM data will be loaded from userspace using the EEPROM data will be loaded from userspace using the
kernel firmware loader). kernel firmware loader).
- mac-address: See ethernet.txt in the parent directory
- local-mac-address: See ethernet.txt in the parent directory
The MAC address will be determined using the optional properties defined in
net/ethernet.txt.
In this example, the node is defined as child node of the PCI controller: In this example, the node is defined as child node of the PCI controller:
&pci0 { &pci0 {
......
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