netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Aleksander Jan Bajkowski <olek2@wp.pl>
Cc: hauke@hauke-m.de, andrew@lunn.ch, vivien.didelot@gmail.com,
	f.fainelli@gmail.com, olteanv@gmail.com, davem@davemloft.net,
	robh+dt@kernel.org, netdev@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 1/2] net: dsa: lantiq: allow to use all GPHYs on xRX300 and xRX330
Date: Mon, 7 Dec 2020 13:43:35 -0800	[thread overview]
Message-ID: <20201207134335.6ef718c9@kicinski-fedora-pc1c0hjn.DHCP.thefacebook.com> (raw)
In-Reply-To: <20201206132713.13452-2-olek2@wp.pl>

On Sun,  6 Dec 2020 14:27:12 +0100 Aleksander Jan Bajkowski wrote:
> This patch allows to use all PHYs on GRX300 and GRX330. The ARX300 has 3
> and the GRX330 has 4 integrated PHYs connected to different ports compared
> to VRX200.
> 
> Port configurations:
> 
> xRX200:
> GMAC0: RGMII/MII/REVMII/RMII port
> GMAC1: RGMII/MII/REVMII/RMII port
> GMAC2: GPHY0 (GMII)
> GMAC3: GPHY0 (MII)
> GMAC4: GPHY1 (GMII)
> GMAC5: GPHY1 (MII) or RGMII port
> 
> xRX300:
> GMAC0: RGMII port
> GMAC1: GPHY2 (GMII)
> GMAC2: GPHY0 (GMII)
> GMAC3: GPHY0 (MII)
> GMAC4: GPHY1 (GMII)
> GMAC5: GPHY1 (MII) or RGMII port
> 
> xRX330:
> GMAC0: RGMII/GMII/RMII port
> GMAC1: GPHY2 (GMII)
> GMAC2: GPHY0 (GMII)
> GMAC3: GPHY0 (MII) or GPHY3 (GMII)
> GMAC4: GPHY1 (GMII)
> GMAC5: GPHY1 (MII) or RGMII/RMII port
> 
> Tested on D-Link DWR966 with OpenWRT.
> 
> Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>

Please make sure you don't add W=1 C=1 build warnings:

In file included from ../include/linux/kasan-checks.h:5,
                 from ../include/asm-generic/rwonce.h:26,
                 from ./arch/x86/include/generated/asm/rwonce.h:1,
                 from ../include/linux/compiler.h:246,
                 from ../include/linux/err.h:5,
                 from ../include/linux/clk.h:12,
                 from ../drivers/net/dsa/lantiq_gswip.c:28:
drivers/net/dsa/lantiq_gswip.c: In function ‘gswip_xrx300_phylink_validate’:
drivers/net/dsa/lantiq_gswip.c:1496:35: warning: unused variable ‘mask’ [-Wunused-variable]
 1496 |  __ETHTOOL_DECLARE_LINK_MODE_MASK(mask) = { 0, };
      |                                   ^~~~
include/linux/types.h:11:16: note: in definition of macro ‘DECLARE_BITMAP’
   11 |  unsigned long name[BITS_TO_LONGS(bits)]
      |                ^~~~
drivers/net/dsa/lantiq_gswip.c:1496:2: note: in expansion of macro ‘__ETHTOOL_DECLARE_LINK_MODE_MASK’
 1496 |  __ETHTOOL_DECLARE_LINK_MODE_MASK(mask) = { 0, };
      |  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/dsa/lantiq_gswip.c: At top level:
drivers/net/dsa/lantiq_gswip.c:2079:9: warning: initialization discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
 2079 |  .ops = &gswip_xrx200_switch_ops,
      |         ^
drivers/net/dsa/lantiq_gswip.c:2085:9: warning: initialization discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
 2085 |  .ops = &gswip_xrx300_switch_ops,
      |         ^
drivers/net/dsa/lantiq_gswip.c:2079:17: warning: incorrect type in initializer (different modifiers)
drivers/net/dsa/lantiq_gswip.c:2079:17:    expected struct dsa_switch_ops *ops
drivers/net/dsa/lantiq_gswip.c:2079:17:    got struct dsa_switch_ops const *
drivers/net/dsa/lantiq_gswip.c:2085:17: warning: incorrect type in initializer (different modifiers)
drivers/net/dsa/lantiq_gswip.c:2085:17:    expected struct dsa_switch_ops *ops
drivers/net/dsa/lantiq_gswip.c:2085:17:    got struct dsa_switch_ops const *

  parent reply	other threads:[~2020-12-07 21:44 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-06 13:27 [PATCH v2 0/2] net: dsa: lantiq: add support for xRX300 and xRX330 Aleksander Jan Bajkowski
2020-12-06 13:27 ` [PATCH v2 1/2] net: dsa: lantiq: allow to use all GPHYs on " Aleksander Jan Bajkowski
2020-12-06 18:54   ` Vladimir Oltean
2020-12-07 21:43   ` Jakub Kicinski [this message]
2020-12-09 14:46   ` kernel test robot
2020-12-10  8:20   ` kernel test robot
2020-12-06 13:27 ` [PATCH v2 2/2] dt-bindings: net: dsa: lantiq, lantiq-gswip: add example for xRX330 Aleksander Jan Bajkowski
2020-12-10  3:40   ` Rob Herring

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201207134335.6ef718c9@kicinski-fedora-pc1c0hjn.DHCP.thefacebook.com \
    --to=kuba@kernel.org \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=f.fainelli@gmail.com \
    --cc=hauke@hauke-m.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olek2@wp.pl \
    --cc=olteanv@gmail.com \
    --cc=robh+dt@kernel.org \
    --cc=vivien.didelot@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).