diff mbox series

[v3,2/5] dt-bindings: net: Add bindings for AX88796C SPI Ethernet Adapter

Message ID 20201021214910.20001-3-l.stelmach@samsung.com (mailing list archive)
State Not Applicable
Delegated to: Netdev Maintainers
Headers show
Series [v3,1/5] dt-bindings: vendor-prefixes: Add asix prefix | expand

Commit Message

Lukasz Stelmach Oct. 21, 2020, 9:49 p.m. UTC
Add bindings for AX88796C SPI Ethernet Adapter.

Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
---
 .../bindings/net/asix,ax88796c.yaml           | 69 +++++++++++++++++++
 1 file changed, 69 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/net/asix,ax88796c.yaml

Comments

Krzysztof Kozlowski Oct. 22, 2020, 6:55 a.m. UTC | #1
On Wed, Oct 21, 2020 at 11:49:07PM +0200, Łukasz Stelmach wrote:
> Add bindings for AX88796C SPI Ethernet Adapter.
> 
> Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
> ---
>  .../bindings/net/asix,ax88796c.yaml           | 69 +++++++++++++++++++
>  1 file changed, 69 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/net/asix,ax88796c.yaml
> 

Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>

Best regards,
Krzysztof
Rob Herring (Arm) Oct. 23, 2020, 4:05 p.m. UTC | #2
On Wed, 21 Oct 2020 23:49:07 +0200, Łukasz Stelmach wrote:
> Add bindings for AX88796C SPI Ethernet Adapter.
> 
> Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
> ---
>  .../bindings/net/asix,ax88796c.yaml           | 69 +++++++++++++++++++
>  1 file changed, 69 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/net/asix,ax88796c.yaml
> 


My bot found errors running 'make dt_binding_check' on your patch:

yamllint warnings/errors:

dtschema/dtc warnings/errors:
./Documentation/devicetree/bindings/net/asix,ax88796c.yaml: $id: relative path/filename doesn't match actual path or filename
	expected: http://devicetree.org/schemas/net/asix,ax88796c.yaml#
Documentation/devicetree/bindings/net/asix,ax88796c.example.dts:20:18: fatal error: dt-bindings/interrupt-controller/gpio.h: No such file or directory
   20 |         #include <dt-bindings/interrupt-controller/gpio.h>
      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[1]: *** [scripts/Makefile.lib:342: Documentation/devicetree/bindings/net/asix,ax88796c.example.dt.yaml] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:1366: dt_binding_check] Error 2


See https://patchwork.ozlabs.org/patch/1385812

The base for the patch is generally the last rc1. Any dependencies
should be noted.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit.
Krzysztof Kozlowski Oct. 23, 2020, 4:27 p.m. UTC | #3
On Fri, 23 Oct 2020 at 18:05, Rob Herring <robh@kernel.org> wrote:
>
> On Wed, 21 Oct 2020 23:49:07 +0200, Łukasz Stelmach wrote:
> > Add bindings for AX88796C SPI Ethernet Adapter.
> >
> > Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
> > ---
> >  .../bindings/net/asix,ax88796c.yaml           | 69 +++++++++++++++++++
> >  1 file changed, 69 insertions(+)
> >  create mode 100644 Documentation/devicetree/bindings/net/asix,ax88796c.yaml
> >
>
>
> My bot found errors running 'make dt_binding_check' on your patch:
>
> yamllint warnings/errors:
>
> dtschema/dtc warnings/errors:
> ./Documentation/devicetree/bindings/net/asix,ax88796c.yaml: $id: relative path/filename doesn't match actual path or filename
>         expected: http://devicetree.org/schemas/net/asix,ax88796c.yaml#
> Documentation/devicetree/bindings/net/asix,ax88796c.example.dts:20:18: fatal error: dt-bindings/interrupt-controller/gpio.h: No such file or directory

Łukasz,

So you really did not compile/test these patches... It's the second
build failure in the patchset. All sent patches should at least be
compiled on the latest kernel, if you cannot test them. However this
patchset should be testable - Artik5 should boot on mainline kernel

Best regards,
Krzysztof
Lukasz Stelmach Oct. 23, 2020, 6:21 p.m. UTC | #4
It was <2020-10-23 pią 18:27>, when Krzysztof Kozlowski wrote:
> On Fri, 23 Oct 2020 at 18:05, Rob Herring <robh@kernel.org> wrote:
>>
>> On Wed, 21 Oct 2020 23:49:07 +0200, Łukasz Stelmach wrote:
>> > Add bindings for AX88796C SPI Ethernet Adapter.
>> >
>> > Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
>> > ---
>> >  .../bindings/net/asix,ax88796c.yaml           | 69 +++++++++++++++++++
>> >  1 file changed, 69 insertions(+)
>> >  create mode 100644 Documentation/devicetree/bindings/net/asix,ax88796c.yaml
>> >
>>
>>
>> My bot found errors running 'make dt_binding_check' on your patch:
>>
>> yamllint warnings/errors:
>>
>> dtschema/dtc warnings/errors:
>> ./Documentation/devicetree/bindings/net/asix,ax88796c.yaml: $id:
>> relative path/filename doesn't match actual path or filename
>>         expected:
>> https://protect2.fireeye.com/v1/url?k=b676d09f-eb1194b9-b6775bd0-0cc47a31384a-e1cc7da4db18c501&q=1&e=ea7ae062-8c39-4ee3-82fa-37d28062f086&u=http%3A%2F%2Fdevicetree.org%2Fschemas%2Fnet%2Fasix%2Cax88796c.yaml%23
>> Documentation/devicetree/bindings/net/asix,ax88796c.example.dts:20:18:
>> fatal error: dt-bindings/interrupt-controller/gpio.h: No such file
>> or directory

Fixed.

> Łukasz,
>
> So you really did not compile/test these patches... It's the second
> build failure in the patchset. All sent patches should at least be
> compiled on the latest kernel, if you cannot test them. However this
> patchset should be testable - Artik5 should boot on mainline kernel

Yes, I messed up a bit. I made moved some code around without changing
it just before sending and I didn't run dt_binding_check. My fault, I am
sorry.
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/net/asix,ax88796c.yaml b/Documentation/devicetree/bindings/net/asix,ax88796c.yaml
new file mode 100644
index 000000000000..6c4c49fcad66
--- /dev/null
+++ b/Documentation/devicetree/bindings/net/asix,ax88796c.yaml
@@ -0,0 +1,69 @@ 
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/net/asix,ax88796c-spi.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: ASIX AX88796C SPI Ethernet Adapter
+
+maintainers:
+  - Łukasz Stelmach <l.stelmach@samsung.com>
+
+description: |
+  ASIX AX88796C is an Ethernet controller with a built in PHY. This
+  describes SPI mode of the chip.
+
+  The node for this driver must be a child node of an SPI controller,
+  hence all mandatory properties described in
+  ../spi/spi-controller.yaml must be specified.
+
+allOf:
+  - $ref: ethernet-controller.yaml#
+
+properties:
+  compatible:
+    const: asix,ax88796c
+
+  reg:
+    maxItems: 1
+
+  spi-max-frequency:
+    maximum: 40000000
+
+  interrupts:
+    maxItems: 1
+
+  reset-gpios:
+    description:
+      A GPIO line handling reset of the chip. As the line is active low,
+      it should be marked GPIO_ACTIVE_LOW.
+    maxItems: 1
+
+  local-mac-address: true
+
+  mac-address: true
+
+required:
+  - compatible
+  - reg
+  - spi-max-frequency
+  - interrupts
+  - interrupt-parrent
+  - reset-gpios
+
+additionalProperties: false
+
+examples:
+  # Artik5 eval board
+  - |
+    #include <dt-bindings/interrupt-controller/irq.h>
+    #include <dt-bindings/interrupt-controller/gpio.h>
+    ethernet@0 {
+        compatible = "asix,ax88796c";
+        reg = <0x0>;
+        local-mac-address = [00 00 00 00 00 00]; /* Filled in by a bootloader */
+        interrupt-parent = <&gpx2>;
+        interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
+        spi-max-frequency = <40000000>;
+        reset-gpios = <&gpe0 2 GPIO_ACTIVE_LOW>;
+    };