NXP SJA1105 Automotive Ethernet Switch Family
Schema identifier ($id): "http://devicetree.org/schemas/net/dsa/nxp,sja1105.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
The SJA1105 SPI interface requires a CS-to-CLK time (t2 in UM10944.pdf) of at least one half of t_CLK. At an SPI frequency of 1MHz, this means a minimum cs_sck_delay of 500ns. Ensuring that this SPI timing requirement is observed depends on the SPI bus master driver.
Maintainers (maintainers): "Vladimir Oltean <vladimir.oltean@nxp.com>"
Properties and child nodes (properties) #
compatible — required here #
Allowed values (enum): "nxp,sja1105e", "nxp,sja1105t", "nxp,sja1105p", "nxp,sja1105q", "nxp,sja1105r", "nxp,sja1105s", "nxp,sja1110a", "nxp,sja1110b", "nxp,sja1110c", "nxp,sja1110d"
reg — required here #
Maximum number of items (maxItems): 1
reset-gpios — not listed as required here #
A GPIO connected to the active-low RST_N pin of the SJA1105. Note that reset of this chip is performed via SPI and the RST_N pin must be wired to satisfy the power-up sequence documented in "SJA1105PQRS Application Hints" (AH1704) sec. 2.4.4. Connecting the SJA1105 RST_N pin to a GPIO is therefore discouraged.
Maximum number of items (maxItems): 1
clocks — not listed as required here #
Maximum number of items (maxItems): 1
spi-cpha — not listed as required here #
true — No constraints added by this property rule.
spi-cpol — not listed as required here #
true — No constraints added by this property rule.
mdios — not listed as required here #
Value type (type): "object"
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
false
Not allowed by this rule.
Properties and child nodes (properties) #
#address-cells — not listed as required here
Exact value (const): 1
#size-cells — not listed as required here
Exact value (const): 0
Properties matching a name pattern (patternProperties) #
^mdio@[0-1]$ — name matches this regular expression
Shared schema rule ($ref): /schemas/net/mdio.yaml#
Properties not evaluated by applicable rules (unevaluatedProperties)
false
Not allowed by this rule.
Properties and child nodes (properties)
compatible — required here
Exactly one of these rules must match (oneOf)
Rule 1
Allowed values (
enum):"nxp,sja1110-base-t1-mdio","nxp,sja1110-base-tx-mdio"
reg — required here
Exactly one of these rules must match (oneOf)
Rule 1
Required in this object (required): "compatible", "reg"
Properties matching a name pattern (patternProperties) #
^(ethernet-)?ports$ — name matches this regular expression #
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
true
Allowed by this rule.
Properties matching a name pattern (patternProperties) #
^(ethernet-)?port@[0-9]$ — name matches this regular expression
All of these rules must match (allOf)
Rule 1
Condition (
if)Properties and child nodes (
properties)
phy-mode— not listed as required hereRule for matching array elements (
contains)Allowed values (
enum):"rgmii","rgmii-rxid","rgmii-txid","rgmii-id"When the condition matches (
then)Properties and child nodes (
properties)
rx-internal-delay-ps— not listed as required hereShared schema rule (
$ref):#/$defs/internal-delay-ps
tx-internal-delay-ps— not listed as required hereShared schema rule (
$ref):#/$defs/internal-delay-ps
Required in this object (required): "compatible", "reg"
Reusable definitions ($defs) #
internal-delay-ps #
Disable tunable delay lines using 0 ps, or enable them and select the phase between 1640 ps (73.8 degree shift at 1Gbps) and 2260 ps (101.7 degree shift) in increments of 0.9 degrees (20 ps).
Allowed values (enum): 0, 1640, 1660, 1680, 1700, 1720, 1740, 1760, 1780, 1800, 1820, 1840, 1860, 1880, 1900, 1920, 1940, 1960, 1980, 2000, 2020, 2040, 2060, 2080, 2100, 2120, 2140, 2160, 2180, 2200, 2220, 2240, 2260
All of these rules must match (allOf) #
Rule 1 #
Shared schema rule (
$ref):dsa.yaml#/$defs/ethernet-ports
Rule 2 #
Shared schema rule (
$ref):/schemas/spi/spi-peripheral-props.yaml#
Rule 3 #
Condition (
if) #Properties and child nodes (
properties)
compatible— not listed as required hereAllowed values (
enum):"nxp,sja1105e","nxp,sja1105p","nxp,sja1105q","nxp,sja1105r","nxp,sja1105s","nxp,sja1105t"When the condition matches (
then) #Properties and child nodes (
properties)
spi-cpol— not listed as required here
false— Not permitted by this property rule.When the condition does not match (
else) #Properties and child nodes (
properties)
spi-cpha— not listed as required here
false— Not permitted by this property rule.
Properties not evaluated by applicable rules (unevaluatedProperties) #
false
Not allowed by this rule.
Examples (examples) #
spi {
#address-cells = <1>;
#size-cells = <0>;
ethernet-switch@1 {
reg = <0x1>;
compatible = "nxp,sja1105t";
spi-cpha;
ethernet-ports {
#address-cells = <1>;
#size-cells = <0>;
port@0 {
phy-handle = <&rgmii_phy6>;
phy-mode = "rgmii-id";
rx-internal-delay-ps = <0>;
tx-internal-delay-ps = <0>;
reg = <0>;
};
port@1 {
phy-handle = <&rgmii_phy3>;
phy-mode = "rgmii-id";
rx-internal-delay-ps = <0>;
tx-internal-delay-ps = <0>;
reg = <1>;
};
port@2 {
phy-handle = <&rgmii_phy4>;
phy-mode = "rgmii-id";
rx-internal-delay-ps = <0>;
tx-internal-delay-ps = <0>;
reg = <2>;
};
port@3 {
phy-handle = <&rgmii_phy4>;
phy-mode = "rgmii-id";
rx-internal-delay-ps = <0>;
tx-internal-delay-ps = <0>;
reg = <3>;
};
port@4 {
ethernet = <&enet2>;
phy-mode = "rgmii";
rx-internal-delay-ps = <0>;
tx-internal-delay-ps = <0>;
reg = <4>;
fixed-link {
speed = <1000>;
full-duplex;
};
};
};
};
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
Line 50: Optional container node for the 2 internal MDIO buses of the SJA1110
Line 51: (one for the internal 100base-T1 PHYs and the other for the single
Line 52: 100base-TX PHY). The "reg" property does not have physical significance.
Line 53: The PHY addresses to port correspondence is as follows: for 100base-T1,
Line 54: port 5 has PHY 1, port 6 has PHY 2 etc, while for 100base-TX, port 1 has
Line 55: PHY 1.