From: Simon Horman <horms@kernel.org>
To: Jack Ping CHNG <jchng@maxlinear.com>
Cc: netdev@vger.kernel.org, devicetree@vger.kernel.org,
davem@davemloft.net, andrew+netdev@lunn.ch, edumazet@google.com,
kuba@kernel.org, pabeni@redhat.com, robh@kernel.org,
krzk+dt@kernel.org, conor+dt@kernel.org, yzhu@maxlinear.com,
sureshnagaraj@maxlinear.com
Subject: Re: [PATCH net-next v3 2/2] net: maxlinear: Add support for MxL LGM SoC
Date: Tue, 2 Sep 2025 09:46:11 +0100 [thread overview]
Message-ID: <20250902084611.GR15473@horms.kernel.org> (raw)
In-Reply-To: <20250829124843.881786-3-jchng@maxlinear.com>
On Fri, Aug 29, 2025 at 08:48:43PM +0800, Jack Ping CHNG wrote:
> Add mxl_eth driver to introduce the initial implementation of ethernet
> support for Maxlinear LGM SoC.
> LGM SoC has a multi port MAC controller to interface with the PHY. It also
> has a master MDIO interface to control the external MDIO configured
> devices.
>
> Signed-off-by: Jack Ping CHNG <jchng@maxlinear.com>
...
> diff --git a/drivers/net/ethernet/maxlinear/mxl_eth.c b/drivers/net/ethernet/maxlinear/mxl_eth.c
...
> +static int mxl_eth_start_xmit(struct sk_buff *skb, struct net_device *ndev)
Hi Jack,
I think it would better for the return type of mxl_eth_start_xmit to be
netdev_tx_t to match the signature of the .ndo_start_xmit member of const
struct net_device_ops.
Flagged by Clang 20.1.8 with
KCFLAGS=-Wincompatible-function-pointer-types-strict
drivers/net/ethernet/maxlinear/mxl_eth.c:56:20: error: incompatible function pointer types initializing 'netdev_tx_t (*)(struct sk_buff *, struct net_device *)' (aka 'enum netdev_tx (*)(struct sk_buff *, struct net_device *)') with an expression of type 'int (struct sk_buff *, struct net_device *)' [-Werror,-Wincompatible-function-pointer-types-strict]
56 | .ndo_start_xmit = mxl_eth_start_xmit,
| ^~~~~~~~~~~~~~~~~~
> +{
> + dev_kfree_skb(skb);
> + return NETDEV_TX_OK;
> +}
> +
> +static const struct net_device_ops mxl_eth_netdev_ops = {
> + .ndo_open = mxl_eth_open,
> + .ndo_stop = mxl_eth_stop,
> + .ndo_start_xmit = mxl_eth_start_xmit,
> +};
...
prev parent reply other threads:[~2025-09-02 8:46 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-29 12:48 [PATCH net-next v3 0/2] Add MxL Ethernet driver & devicetree binding Jack Ping CHNG
2025-08-29 12:48 ` [PATCH net-next v3 1/2] dt-bindings: net: mxl: Add MxL LGM Network Processor SoC Jack Ping CHNG
2025-09-01 4:59 ` Krzysztof Kozlowski
2025-08-29 12:48 ` [PATCH net-next v3 2/2] net: maxlinear: Add support for MxL LGM SoC Jack Ping CHNG
2025-08-29 20:24 ` Andrew Lunn
2025-09-01 9:38 ` Jack Ping Chng
2025-09-01 13:11 ` Andrew Lunn
2025-09-02 10:39 ` Jack Ping Chng
2025-09-02 12:30 ` Andrew Lunn
2025-09-04 6:33 ` Jack Ping Chng
2025-09-04 12:20 ` Andrew Lunn
2025-08-29 20:29 ` Andrew Lunn
2025-09-01 5:01 ` Krzysztof Kozlowski
2025-09-02 8:46 ` Simon Horman [this message]
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=20250902084611.GR15473@horms.kernel.org \
--to=horms@kernel.org \
--cc=andrew+netdev@lunn.ch \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=jchng@maxlinear.com \
--cc=krzk+dt@kernel.org \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=robh@kernel.org \
--cc=sureshnagaraj@maxlinear.com \
--cc=yzhu@maxlinear.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).