Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: net: micrel: Convert to DT schema

Convert the devicetree bindings for the Micrel PHYs and switches to DT
schema.

Signed-off-by: Stefan Eichenberger <stefan.eichenberger@toradex.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Link: https://patch.msgid.link/20260116130948.79558-2-eichest@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>

authored by

Stefan Eichenberger and committed by
Jakub Kicinski
4dd29c65 3cc3ca6d

+131 -57
-57
Documentation/devicetree/bindings/net/micrel.txt
··· 1 - Micrel PHY properties. 2 - 3 - These properties cover the base properties Micrel PHYs. 4 - 5 - Optional properties: 6 - 7 - - micrel,led-mode : LED mode value to set for PHYs with configurable LEDs. 8 - 9 - Configure the LED mode with single value. The list of PHYs and the 10 - bits that are currently supported: 11 - 12 - KSZ8001: register 0x1e, bits 15..14 13 - KSZ8041: register 0x1e, bits 15..14 14 - KSZ8021: register 0x1f, bits 5..4 15 - KSZ8031: register 0x1f, bits 5..4 16 - KSZ8051: register 0x1f, bits 5..4 17 - KSZ8081: register 0x1f, bits 5..4 18 - KSZ8091: register 0x1f, bits 5..4 19 - LAN8814: register EP5.0, bit 6 20 - 21 - See the respective PHY datasheet for the mode values. 22 - 23 - - micrel,rmii-reference-clock-select-25-mhz: RMII Reference Clock Select 24 - bit selects 25 MHz mode 25 - 26 - Setting the RMII Reference Clock Select bit enables 25 MHz rather 27 - than 50 MHz clock mode. 28 - 29 - Note that this option is only needed for certain PHY revisions with a 30 - non-standard, inverted function of this configuration bit. 31 - Specifically, a clock reference ("rmii-ref" below) is always needed to 32 - actually select a mode. 33 - 34 - - clocks, clock-names: contains clocks according to the common clock bindings. 35 - 36 - supported clocks: 37 - - KSZ8021, KSZ8031, KSZ8081, KSZ8091: "rmii-ref": The RMII reference 38 - input clock. Used to determine the XI input clock. 39 - 40 - - micrel,fiber-mode: If present the PHY is configured to operate in fiber mode 41 - 42 - Some PHYs, such as the KSZ8041FTL variant, support fiber mode, enabled 43 - by the FXEN boot strapping pin. It can't be determined from the PHY 44 - registers whether the PHY is in fiber mode, so this boolean device tree 45 - property can be used to describe it. 46 - 47 - In fiber mode, auto-negotiation is disabled and the PHY can only work in 48 - 100base-fx (full and half duplex) modes. 49 - 50 - - coma-mode-gpios: If present the given gpio will be deasserted when the 51 - PHY is probed. 52 - 53 - Some PHYs have a COMA mode input pin which puts the PHY into 54 - isolate and power-down mode. On some boards this input is connected 55 - to a GPIO of the SoC. 56 - 57 - Supported on the LAN8814.
+131
Documentation/devicetree/bindings/net/micrel.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/net/micrel.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Micrel KSZ series PHYs and switches 8 + 9 + maintainers: 10 + - Andrew Lunn <andrew@lunn.ch> 11 + - Stefan Eichenberger <eichest@gmail.com> 12 + 13 + description: 14 + The Micrel KSZ series contains different network phys and switches. 15 + 16 + properties: 17 + compatible: 18 + enum: 19 + - ethernet-phy-id000e.7237 # KSZ8873MLL 20 + - ethernet-phy-id0022.1430 # KSZ886X 21 + - ethernet-phy-id0022.1435 # KSZ8863 22 + - ethernet-phy-id0022.1510 # KSZ8041 23 + - ethernet-phy-id0022.1537 # KSZ8041RNLI 24 + - ethernet-phy-id0022.1550 # KSZ8051 25 + - ethernet-phy-id0022.1555 # KSZ8021 26 + - ethernet-phy-id0022.1556 # KSZ8031 27 + - ethernet-phy-id0022.1560 # KSZ8081, KSZ8091 28 + - ethernet-phy-id0022.1570 # KSZ8061 29 + - ethernet-phy-id0022.161a # KSZ8001 30 + - ethernet-phy-id0022.1720 # KS8737 31 + 32 + micrel,fiber-mode: 33 + type: boolean 34 + description: | 35 + If present the PHY is configured to operate in fiber mode. 36 + 37 + The KSZ8041FTL variant supports fiber mode, enabled by the FXEN 38 + boot strapping pin. It can't be determined from the PHY registers 39 + whether the PHY is in fiber mode, so this boolean device tree 40 + property can be used to describe it. 41 + 42 + In fiber mode, auto-negotiation is disabled and the PHY can only 43 + work in 100base-fx (full and half duplex) modes. 44 + 45 + micrel,led-mode: 46 + $ref: /schemas/types.yaml#/definitions/uint32 47 + description: | 48 + LED mode value to set for PHYs with configurable LEDs. 49 + 50 + Configure the LED mode with single value. The list of PHYs and the 51 + bits that are currently supported: 52 + 53 + KSZ8001: register 0x1e, bits 15..14 54 + KSZ8041: register 0x1e, bits 15..14 55 + KSZ8021: register 0x1f, bits 5..4 56 + KSZ8031: register 0x1f, bits 5..4 57 + KSZ8051: register 0x1f, bits 5..4 58 + KSZ8081: register 0x1f, bits 5..4 59 + KSZ8091: register 0x1f, bits 5..4 60 + 61 + See the respective PHY datasheet for the mode values. 62 + minimum: 0 63 + maximum: 3 64 + 65 + allOf: 66 + - $ref: ethernet-phy.yaml# 67 + - if: 68 + not: 69 + properties: 70 + compatible: 71 + contains: 72 + const: ethernet-phy-id0022.1510 73 + then: 74 + properties: 75 + micrel,fiber-mode: false 76 + - if: 77 + not: 78 + properties: 79 + compatible: 80 + contains: 81 + enum: 82 + - ethernet-phy-id0022.1510 83 + - ethernet-phy-id0022.1555 84 + - ethernet-phy-id0022.1556 85 + - ethernet-phy-id0022.1550 86 + - ethernet-phy-id0022.1560 87 + - ethernet-phy-id0022.161a 88 + then: 89 + properties: 90 + micrel,led-mode: false 91 + - if: 92 + properties: 93 + compatible: 94 + contains: 95 + enum: 96 + - ethernet-phy-id0022.1555 97 + - ethernet-phy-id0022.1556 98 + - ethernet-phy-id0022.1560 99 + then: 100 + properties: 101 + clock-names: 102 + const: rmii-ref 103 + description: 104 + The RMII reference input clock. Used to determine the XI input 105 + clock. 106 + micrel,rmii-reference-clock-select-25-mhz: 107 + type: boolean 108 + description: | 109 + RMII Reference Clock Select bit selects 25 MHz mode 110 + 111 + Setting the RMII Reference Clock Select bit enables 25 MHz rather 112 + than 50 MHz clock mode. 113 + 114 + dependentRequired: 115 + micrel,rmii-reference-clock-select-25-mhz: [ clock-names ] 116 + 117 + unevaluatedProperties: false 118 + 119 + examples: 120 + - | 121 + mdio { 122 + #address-cells = <1>; 123 + #size-cells = <0>; 124 + 125 + ethernet-phy@5 { 126 + compatible = "ethernet-phy-id0022.1510"; 127 + reg = <5>; 128 + micrel,led-mode = <2>; 129 + micrel,fiber-mode; 130 + }; 131 + };