Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
  • * Re: [PATCH 2/4] dt-bindings: net: Add support for Sophgo SG2044 dwmac
           [not found] ` <20241021103617.653386-3-inochiama@gmail.com>
           [not found]   ` <20241022-crisply-brute-45f98632ef78@spud>
    @ 2024-10-23 23:41   ` Emil Renner Berthing
      2024-10-24  5:08     ` Inochi Amaoto
      1 sibling, 1 reply; 11+ messages in thread
    From: Emil Renner Berthing @ 2024-10-23 23:41 UTC (permalink / raw)
      To: Inochi Amaoto, Chen Wang, Andrew Lunn, David S. Miller,
    	Eric Dumazet, Jakub Kicinski, Paolo Abeni, Rob Herring,
    	Krzysztof Kozlowski, Conor Dooley, Inochi Amaoto,
    	Alexandre Torgue, Jose Abreu, Maxime Coquelin, Richard Cochran,
    	Paul Walmsley, Palmer Dabbelt, Albert Ou, Giuseppe Cavallaro
      Cc: Yixun Lan, netdev, devicetree, linux-kernel, linux-stm32,
    	linux-arm-kernel, linux-riscv
    
    Inochi Amaoto wrote:
    > The GMAC IP on SG2044 is almost a standard Synopsys DesignWare MAC
    > with some extra clock.
    >
    > Add necessary compatible string for this device.
    >
    > Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
    > ---
    >  .../devicetree/bindings/net/snps,dwmac.yaml   |   1 +
    >  .../bindings/net/sophgo,sg2044-dwmac.yaml     | 145 ++++++++++++++++++
    >  2 files changed, 146 insertions(+)
    >  create mode 100644 Documentation/devicetree/bindings/net/sophgo,sg2044-dwmac.yaml
    >
    > diff --git a/Documentation/devicetree/bindings/net/snps,dwmac.yaml b/Documentation/devicetree/bindings/net/snps,dwmac.yaml
    > index 3c4007cb65f8..69f6bb36970b 100644
    > --- a/Documentation/devicetree/bindings/net/snps,dwmac.yaml
    > +++ b/Documentation/devicetree/bindings/net/snps,dwmac.yaml
    > @@ -99,6 +99,7 @@ properties:
    >          - snps,dwmac-5.30a
    >          - snps,dwxgmac
    >          - snps,dwxgmac-2.10
    > +        - sophgo,sg2044-dwmac
    >          - starfive,jh7100-dwmac
    >          - starfive,jh7110-dwmac
    >
    > diff --git a/Documentation/devicetree/bindings/net/sophgo,sg2044-dwmac.yaml b/Documentation/devicetree/bindings/net/sophgo,sg2044-dwmac.yaml
    > new file mode 100644
    > index 000000000000..93c41550b0b6
    > --- /dev/null
    > +++ b/Documentation/devicetree/bindings/net/sophgo,sg2044-dwmac.yaml
    > @@ -0,0 +1,145 @@
    > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
    > +%YAML 1.2
    > +---
    > +$id: http://devicetree.org/schemas/net/sophgo,sg2044-dwmac.yaml#
    > +$schema: http://devicetree.org/meta-schemas/core.yaml#
    > +
    > +title: StarFive JH7110 DWMAC glue layer
    
    I think you forgot to change this when you copied the binding.
    
    /Emil
    
    > +
    > +maintainers:
    > +  - Inochi Amaoto <inochiama@gmail.com>
    > +
    > +select:
    > +  properties:
    > +    compatible:
    > +      contains:
    > +        enum:
    > +          - sophgo,sg2044-dwmac
    > +  required:
    > +    - compatible
    > +
    > +properties:
    > +  compatible:
    > +    items:
    > +      - const: sophgo,sg2044-dwmac
    > +      - const: snps,dwmac-5.30a
    > +
    > +  reg:
    > +    maxItems: 1
    > +
    > +  clocks:
    > +    items:
    > +      - description: GMAC main clock
    > +      - description: PTP clock
    > +      - description: TX clock
    > +
    > +  clock-names:
    > +    items:
    > +      - const: stmmaceth
    > +      - const: ptp_ref
    > +      - const: tx
    > +
    > +  sophgo,syscon:
    > +    $ref: /schemas/types.yaml#/definitions/phandle-array
    > +    items:
    > +      - items:
    > +          - description: phandle to syscon that configures phy
    > +          - description: offset of phy mode register
    > +          - description: length of the phy mode register
    > +    description:
    > +      A phandle to syscon with two arguments that configure phy mode.
    > +      The argument one is the offset of phy mode register, the
    > +      argument two is the length of phy mode register.
    > +
    > +required:
    > +  - compatible
    > +  - reg
    > +  - clocks
    > +  - clock-names
    > +  - interrupts
    > +  - interrupt-names
    > +  - resets
    > +  - reset-names
    > +
    > +allOf:
    > +  - $ref: snps,dwmac.yaml#
    > +
    > +  - if:
    > +      properties:
    > +        compatible:
    > +          contains:
    > +            const: sophgo,sg2044-dwmac
    > +    then:
    > +      properties:
    > +        interrupts:
    > +          minItems: 1
    > +          maxItems: 1
    > +
    > +        interrupt-names:
    > +          minItems: 1
    > +          maxItems: 1
    > +
    > +        resets:
    > +          maxItems: 1
    > +
    > +        reset-names:
    > +          const: stmmaceth
    > +
    > +unevaluatedProperties: false
    > +
    > +examples:
    > +  - |
    > +    #include <dt-bindings/interrupt-controller/irq.h>
    > +
    > +    ethernet@30006000 {
    > +      compatible = "sophgo,sg2044-dwmac", "snps,dwmac-5.30a";
    > +      reg = <0x30006000 0x4000>;
    > +      clocks = <&clk 151>, <&clk 152>, <&clk 154>;
    > +      clock-names = "stmmaceth", "ptp_ref", "tx";
    > +      interrupt-parent = <&intc>;
    > +      interrupts = <296 IRQ_TYPE_LEVEL_HIGH>;
    > +      interrupt-names = "macirq";
    > +      resets = <&rst 30>;
    > +      reset-names = "stmmaceth";
    > +      snps,multicast-filter-bins = <0>;
    > +      snps,perfect-filter-entries = <1>;
    > +      snps,aal;
    > +      snps,tso;
    > +      snps,txpbl = <32>;
    > +      snps,rxpbl = <32>;
    > +      snps,mtl-rx-config = <&gmac0_mtl_rx_setup>;
    > +      snps,mtl-tx-config = <&gmac0_mtl_tx_setup>;
    > +      snps,axi-config = <&gmac0_stmmac_axi_setup>;
    > +      status = "disabled";
    > +
    > +      gmac0_mtl_rx_setup: rx-queues-config {
    > +        snps,rx-queues-to-use = <8>;
    > +        snps,rx-sched-wsp;
    > +        queue0 {};
    > +        queue1 {};
    > +        queue2 {};
    > +        queue3 {};
    > +        queue4 {};
    > +        queue5 {};
    > +        queue6 {};
    > +        queue7 {};
    > +      };
    > +
    > +      gmac0_mtl_tx_setup: tx-queues-config {
    > +        snps,tx-queues-to-use = <8>;
    > +        queue0 {};
    > +        queue1 {};
    > +        queue2 {};
    > +        queue3 {};
    > +        queue4 {};
    > +        queue5 {};
    > +        queue6 {};
    > +        queue7 {};
    > +      };
    > +
    > +      gmac0_stmmac_axi_setup: stmmac-axi-config {
    > +        snps,blen = <16 8 4 0 0 0 0>;
    > +        snps,wr_osr_lmt = <1>;
    > +        snps,rd_osr_lmt = <2>;
    > +      };
    > +    };
    > --
    > 2.47.0
    >
    >
    > _______________________________________________
    > linux-riscv mailing list
    > linux-riscv@lists.infradead.org
    > http://lists.infradead.org/mailman/listinfo/linux-riscv
    
    
    ^ permalink raw reply	[flat|nested] 11+ messages in thread
  • [parent not found: <20241021103617.653386-5-inochiama@gmail.com>]

  • end of thread, other threads:[~2024-10-25  1:41 UTC | newest]
    
    Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
    -- links below jump to the message on this page --
         [not found] <20241021103617.653386-1-inochiama@gmail.com>
         [not found] ` <20241021103617.653386-3-inochiama@gmail.com>
         [not found]   ` <20241022-crisply-brute-45f98632ef78@spud>
         [not found]     ` <yt2idyivivcxctosec3lwkjbmr4tmctbs4viefxsuqlsvihdeh@alya6g27625l>
    2024-10-23 20:49       ` [PATCH 2/4] dt-bindings: net: Add support for Sophgo SG2044 dwmac Conor Dooley
    2024-10-23 22:38         ` Inochi Amaoto
    2024-10-24 17:04           ` Conor Dooley
    2024-10-24 22:27             ` Inochi Amaoto
    2024-10-23 23:41   ` Emil Renner Berthing
    2024-10-24  5:08     ` Inochi Amaoto
         [not found] ` <20241021103617.653386-5-inochiama@gmail.com>
         [not found]   ` <227daa87-1924-4b0b-80db-77507fc20f19@lunn.ch>
         [not found]     ` <gwtiuotmwj2x3d5rhfrploj7o763yjye4jj7vniomv77s7crqx@5jwrpwrlwn4s>
         [not found]       ` <65720a16-d165-4379-a01f-54340fb907df@lunn.ch>
         [not found]         ` <424erlm55tuorjvs2xgmanzpximvey22ufhzf3fli7trpimxih@st4yz53hpzzr>
         [not found]           ` <66f35d1b-fd26-429b-bbf9-d03ed0c1edaf@lunn.ch>
         [not found]             ` <zum7n3656qonk4sdfu76owfs4jk2mkjrzayd57uuoqeb6iiris@635pw3mqymqd>
         [not found]               ` <d691a687-c0e2-48a9-bf76-d0a086aa7870@lunn.ch>
         [not found]                 ` <amg64lxjjetkzo5bpi7icmsfgmt5e7jmu2z2h3duqy2jcloj7s@nma2hjk4so5b>
    2024-10-23 12:42                   ` [PATCH 4/4] net: stmmac: Add glue layer for Sophgo SG2044 SoC Andrew Lunn
    2024-10-23 22:36                     ` Inochi Amaoto
    2024-10-23 23:56                       ` Andrew Lunn
    2024-10-24 15:37   ` Uwe Kleine-König
    2024-10-25  1:39     ` Inochi Amaoto
    

    This is a public inbox, see mirroring instructions
    for how to clone and mirror all data and code used for this inbox