1b13c7a88SŁukasz Stelmach# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2b13c7a88SŁukasz Stelmach%YAML 1.2
3b13c7a88SŁukasz Stelmach---
4b13c7a88SŁukasz Stelmach$id: http://devicetree.org/schemas/net/asix,ax88796c.yaml#
5b13c7a88SŁukasz Stelmach$schema: http://devicetree.org/meta-schemas/core.yaml#
6b13c7a88SŁukasz Stelmach
7b13c7a88SŁukasz Stelmachtitle: ASIX AX88796C SPI Ethernet Adapter
8b13c7a88SŁukasz Stelmach
9b13c7a88SŁukasz Stelmachmaintainers:
10b13c7a88SŁukasz Stelmach  - Łukasz Stelmach <l.stelmach@samsung.com>
11b13c7a88SŁukasz Stelmach
12b13c7a88SŁukasz Stelmachdescription: |
13b13c7a88SŁukasz Stelmach  ASIX AX88796C is an Ethernet controller with a built in PHY. This
14b13c7a88SŁukasz Stelmach  describes SPI mode of the chip.
15b13c7a88SŁukasz Stelmach
16b13c7a88SŁukasz Stelmach  The node for this driver must be a child node of an SPI controller,
17b13c7a88SŁukasz Stelmach  hence all mandatory properties described in
18b13c7a88SŁukasz Stelmach  ../spi/spi-controller.yaml must be specified.
19b13c7a88SŁukasz Stelmach
20b13c7a88SŁukasz StelmachallOf:
21b13c7a88SŁukasz Stelmach  - $ref: ethernet-controller.yaml#
22*306f2082SKrzysztof Kozlowski  - $ref: /schemas/spi/spi-peripheral-props.yaml
23b13c7a88SŁukasz Stelmach
24b13c7a88SŁukasz Stelmachproperties:
25b13c7a88SŁukasz Stelmach  compatible:
26b13c7a88SŁukasz Stelmach    const: asix,ax88796c
27b13c7a88SŁukasz Stelmach
28b13c7a88SŁukasz Stelmach  reg:
29b13c7a88SŁukasz Stelmach    maxItems: 1
30b13c7a88SŁukasz Stelmach
31b13c7a88SŁukasz Stelmach  spi-max-frequency:
32b13c7a88SŁukasz Stelmach    maximum: 40000000
33b13c7a88SŁukasz Stelmach
34b13c7a88SŁukasz Stelmach  interrupts:
35b13c7a88SŁukasz Stelmach    maxItems: 1
36b13c7a88SŁukasz Stelmach
37b13c7a88SŁukasz Stelmach  reset-gpios:
38b13c7a88SŁukasz Stelmach    description:
39b13c7a88SŁukasz Stelmach      A GPIO line handling reset of the chip. As the line is active low,
40b13c7a88SŁukasz Stelmach      it should be marked GPIO_ACTIVE_LOW.
41b13c7a88SŁukasz Stelmach    maxItems: 1
42b13c7a88SŁukasz Stelmach
43*306f2082SKrzysztof Kozlowski  controller-data: true
44b13c7a88SŁukasz Stelmach  local-mac-address: true
45b13c7a88SŁukasz Stelmach  mac-address: true
46b13c7a88SŁukasz Stelmach
47b13c7a88SŁukasz Stelmachrequired:
48b13c7a88SŁukasz Stelmach  - compatible
49b13c7a88SŁukasz Stelmach  - reg
50b13c7a88SŁukasz Stelmach  - spi-max-frequency
51b13c7a88SŁukasz Stelmach  - interrupts
52b13c7a88SŁukasz Stelmach  - reset-gpios
53b13c7a88SŁukasz Stelmach
54b13c7a88SŁukasz StelmachadditionalProperties: false
55b13c7a88SŁukasz Stelmach
56b13c7a88SŁukasz Stelmachexamples:
57b13c7a88SŁukasz Stelmach  # Artik5 eval board
58b13c7a88SŁukasz Stelmach  - |
59b13c7a88SŁukasz Stelmach    #include <dt-bindings/interrupt-controller/irq.h>
60b13c7a88SŁukasz Stelmach    #include <dt-bindings/gpio/gpio.h>
61b13c7a88SŁukasz Stelmach    spi0 {
62b13c7a88SŁukasz Stelmach        #address-cells = <1>;
63b13c7a88SŁukasz Stelmach        #size-cells = <0>;
64b13c7a88SŁukasz Stelmach
65b13c7a88SŁukasz Stelmach        ethernet@0 {
66b13c7a88SŁukasz Stelmach            compatible = "asix,ax88796c";
67b13c7a88SŁukasz Stelmach            reg = <0x0>;
68b13c7a88SŁukasz Stelmach            local-mac-address = [00 00 00 00 00 00]; /* Filled in by a bootloader */
69b13c7a88SŁukasz Stelmach            interrupt-parent = <&gpx2>;
70b13c7a88SŁukasz Stelmach            interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
71b13c7a88SŁukasz Stelmach            spi-max-frequency = <40000000>;
72b13c7a88SŁukasz Stelmach            reset-gpios = <&gpe0 2 GPIO_ACTIVE_LOW>;
73b13c7a88SŁukasz Stelmach        };
74b13c7a88SŁukasz Stelmach    };
75