From: Andrew Lunn <andrew@lunn.ch>
To: Yao Zi <ziyao@disroot.org>
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>,
Frank <Frank.Sae@motor-comm.com>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
Bjorn Helgaas <bhelgaas@google.com>,
"Russell King (Oracle)" <rmk+kernel@armlinux.org.uk>,
Vladimir Oltean <vladimir.oltean@nxp.com>,
Choong Yong Liang <yong.liang.choong@linux.intel.com>,
Chen-Yu Tsai <wens@csie.org>, Jisheng Zhang <jszhang@kernel.org>,
Furong Xu <0x1207@gmail.com>,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
linux-pci@vger.kernel.org
Subject: Re: [PATCH net-next 3/4] net: stmmac: Add glue driver for Motorcomm YT6801 ethernet controller
Date: Sat, 18 Oct 2025 16:53:04 +0200 [thread overview]
Message-ID: <cc564a19-7236-40d4-bf3c-6a24f7d00bec@lunn.ch> (raw)
In-Reply-To: <aPNM1jeKfMPNsO4N@pie>
> > I was also wondering about all the other parameters you set. Why have
> > i not seen any other glue driver with similar code? What makes this
> > glue driver different?
>
> Most glue drivers are for SoC-integrated IPs, for which
> stmmac_pltfr_probe() helper could be used to retrieve configuration
> arguments from devicetree to fill plat_stmmacenet_data. However, YT6801
> is a PCIe-based controller, and we couldn't rely on devicetree to carry
> these parameters.
>
> You could find similar parameter setup code in stmmac_pltfr_probe(), and
> also other glue drivers for PCIe-based controllers, like dwmac-intel.c
> (intel_mgbe_common_data) and dwmac-loongson.c (loongson_default_data).
Is there anything common with these two drivers? One of the problems
stmmac has had in the past is that glue driver writers just
copy/paste, rather than refactor other glue drivers to share code. If
there is shared code, maybe move it into stmmac_pci.c as helpers?
Andrew
next prev parent reply other threads:[~2025-10-18 14:53 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-14 16:47 [PATCH net-next 0/4] Add DWMAC glue driver for Motorcomm YT6801 Yao Zi
2025-10-14 16:47 ` [PATCH net-next 1/4] PCI: Add vendor ID for Motorcomm Electronic Technology Yao Zi
2025-10-14 20:43 ` Bjorn Helgaas
2025-10-15 9:57 ` Yao Zi
2025-10-14 16:47 ` [PATCH net-next 2/4] net: phy: motorcomm: Support YT8531S PHY in YT6801 Ethernet controller Yao Zi
2025-10-14 17:08 ` Russell King (Oracle)
2025-10-15 13:41 ` Yao Zi
2025-10-14 16:47 ` [PATCH net-next 3/4] net: stmmac: Add glue driver for Motorcomm YT6801 ethernet controller Yao Zi
2025-10-16 20:11 ` Andrew Lunn
2025-10-17 14:03 ` Yao Zi
2025-10-17 14:56 ` Andrew Lunn
2025-10-17 15:04 ` Russell King (Oracle)
2025-10-18 8:21 ` Yao Zi
2025-10-18 8:16 ` Yao Zi
2025-10-18 14:53 ` Andrew Lunn [this message]
2025-10-19 3:05 ` Yao Zi
2025-10-14 16:47 ` [PATCH net-next 4/4] MAINTAINERS: Assign myself as maintainer of Motorcomm DWMAC glue driver Yao Zi
2025-10-15 8:58 ` [PATCH net-next 0/4] Add DWMAC glue driver for Motorcomm YT6801 Mingcong Bai
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=cc564a19-7236-40d4-bf3c-6a24f7d00bec@lunn.ch \
--to=andrew@lunn.ch \
--cc=0x1207@gmail.com \
--cc=Frank.Sae@motor-comm.com \
--cc=andrew+netdev@lunn.ch \
--cc=bhelgaas@google.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=jszhang@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=rmk+kernel@armlinux.org.uk \
--cc=vladimir.oltean@nxp.com \
--cc=wens@csie.org \
--cc=yong.liang.choong@linux.intel.com \
--cc=ziyao@disroot.org \
/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).