Realtek RTL I2C Controller

Schema identifier ($id): "http://devicetree.org/schemas/i2c/realtek,rtl9301-i2c.yaml#"

Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"

Maintainers (maintainers): "Chris Packham <chris.packham@alliedtelesis.co.nz>"

RTL9300 SoCs have two I2C controllers. Each of these has an SCL line (which if not-used for SCL can be a GPIO). There are 8 common SDA lines that can be assigned to either I2C controller. RTL9310 SoCs have equal capabilities but support 12 common SDA lines which can be assigned to either I2C controller.

Properties and child nodes (properties) #

compatible — required here #

Exactly one of these rules must match (oneOf) #

Rule 1

Array item rules (items)

Item 1

Allowed values (enum): "realtek,rtl9302b-i2c", "realtek,rtl9302c-i2c", "realtek,rtl9303-i2c"

Item 2

Exact value (const): "realtek,rtl9301-i2c"

Rule 2

Array item rules (items)

Item 1

Allowed values (enum): "realtek,rtl9311-i2c", "realtek,rtl9312-i2c", "realtek,rtl9313-i2c"

Item 2

Exact value (const): "realtek,rtl9310-i2c"

Rule 3

Allowed values (enum): "realtek,rtl9301-i2c", "realtek,rtl9310-i2c"

reg — required here #

Array item rules (items) #

Item 1

Register offset and size of this I2C controller.

#address-cells — not listed as required here #

Exact value (const): 1

#size-cells — not listed as required here #

Exact value (const): 0

realtek,scl — not listed as required here #

Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32

The SCL line number of this I2C controller.

Allowed values (enum): 0, 1

Properties matching a name pattern (patternProperties) #

^i2c@[0-9ab]$ — name matches this regular expression #

Shared schema rule ($ref): /schemas/i2c/i2c-controller.yaml

Properties not evaluated by applicable rules (unevaluatedProperties) #

false

Not allowed by this rule.

Properties and child nodes (properties) #

reg — required here

The SDA line number associated with the I2C bus.

Maximum number of items (maxItems): 1

Required in this object (required): "reg"

All of these rules must match (allOf) #

Rule 1 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Exact value (const): "realtek,rtl9310-i2c"

When the condition matches (then) #

Required in this object (required): "realtek,scl"

Rule 2 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Exact value (const): "realtek,rtl9301-i2c"

When the condition matches (then) #

Properties matching a name pattern (patternProperties)

^i2c@[89ab]$ — name matches this regular expression

false — Not permitted by this property rule.

Required in this object (required): "compatible", "reg"

Properties not matched by properties or patternProperties in this schema (additionalProperties) #

false

Not allowed by this rule.

Examples (examples) #

i2c@36c {
  compatible = "realtek,rtl9301-i2c";
  reg = <0x36c 0x14>;
  #address-cells = <1>;
  #size-cells = <0>;

  i2c@2 {
    reg = <2>;
    #address-cells = <1>;
    #size-cells = <0>;
  };
};

Source notes #

Annotations retained from the schema source

Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)

Edit this page