From: Lorenzo Bianconi <lorenzo@kernel.org>
To: Alexander Lobakin <aleksander.lobakin@intel.com>
Cc: Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org, netdev@vger.kernel.org,
Xuegang Lu <xuegang.lu@airoha.com>
Subject: Re: [PATCH net-next 1/6] net: airoha: Introduce airoha_gdm_dev struct
Date: Thu, 28 May 2026 18:09:02 +0200 [thread overview]
Message-ID: <ahhonoI-oJ6gJqZ0@lore-desk> (raw)
In-Reply-To: <433b9d9a-bd7c-44ad-b387-a789b326488e@intel.com>
[-- Attachment #1: Type: text/plain, Size: 2025 bytes --]
On May 28, Alexander Lobakin wrote:
> From: Lorenzo Bianconi <lorenzo@kernel.org>
> Date: Wed, 27 May 2026 12:21:15 +0200
>
> > EN7581 and AN7583 SoCs support connecting multiple external SerDes to GDM3
> > or GDM4 ports via a hw arbiter that manages the traffic in a TDM manner.
> > As a result multiple net_devices can connect to the same GDM{3,4} port
> > and there is a theoretical "1:n" relation between GDM port and
> > net_devices.
> > Introduce airoha_gdm_dev struct to collect net_device related info (e.g.
> > net_device and external phy pointer). Please note this is just a
> > preliminary patch and we are still supporting a single net_device for
> > each GDM port. Subsequent patches will add support for multiple net_devices
> > connected to the same GDM port.
> >
> > Tested-by: Xuegang Lu <xuegang.lu@airoha.com>
> > Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
>
> [...]
>
> > diff --git a/drivers/net/ethernet/airoha/airoha_eth.h b/drivers/net/ethernet/airoha/airoha_eth.h
> > index d3781103abb5..c78cabbec753 100644
> > --- a/drivers/net/ethernet/airoha/airoha_eth.h
> > +++ b/drivers/net/ethernet/airoha/airoha_eth.h
> > @@ -535,10 +535,15 @@ struct airoha_qdma {
> > struct airoha_queue q_rx[AIROHA_NUM_RX_RING];
> > };
> >
> > +struct airoha_gdm_dev {
> > + struct airoha_gdm_port *port;
> > + struct net_device *dev;
>
> Nit: we now have priv_to_netdev() (I hope I remember its name
> correctly), so that we no longer need to store a netdev backpointer in
> netdev_priv structures.
> Just an option, up to you.
I think you mean netdev_from_priv(), right?
I guess I can fix if I need to repost, otherwise I will fix with with a
dedicated patch. Agree?
Regards,
Lorenzo
>
> > + struct airoha_eth *eth;
> > +};
> > +
> > struct airoha_gdm_port {
> > struct airoha_qdma *qdma;
> > - struct airoha_eth *eth;
> > - struct net_device *dev;
> > + struct airoha_gdm_dev *dev;
> > int id;
> > int nbq;
> >
> Thanks,
> Olek
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2026-05-28 16:09 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-27 10:21 [PATCH net-next 0/6] net: airoha: Preliminary patches to support multiple net_devices connected to the same GDM port Lorenzo Bianconi
2026-05-27 10:21 ` [PATCH net-next 1/6] net: airoha: Introduce airoha_gdm_dev struct Lorenzo Bianconi
2026-05-28 12:38 ` Lorenzo Bianconi
2026-05-28 13:42 ` Alexander Lobakin
2026-05-28 16:09 ` Lorenzo Bianconi [this message]
2026-05-27 10:21 ` [PATCH net-next 2/6] net: airoha: Move airoha_qdma pointer in " Lorenzo Bianconi
2026-05-27 10:21 ` [PATCH net-next 3/6] net: airoha: Rely on airoha_gdm_dev pointer in airoha_is_lan_gdm_port() Lorenzo Bianconi
2026-05-27 10:21 ` [PATCH net-next 4/6] net: airoha: Move qos_sq_bmap in airoha_gdm_dev struct Lorenzo Bianconi
2026-05-28 12:49 ` Lorenzo Bianconi
2026-05-27 10:21 ` [PATCH net-next 5/6] net: airoha: Move {cpu,fwd}_tx_packets " Lorenzo Bianconi
2026-05-27 10:21 ` [PATCH net-next 6/6] net: airoha: Rename airoha_set_gdm2_loopback in airoha_enable_gdm2_loopback Lorenzo Bianconi
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=ahhonoI-oJ6gJqZ0@lore-desk \
--to=lorenzo@kernel.org \
--cc=aleksander.lobakin@intel.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=xuegang.lu@airoha.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