From: Andrew Lunn <andrew@lunn.ch>
To: Alexander Lobakin <alexandr.lobakin@intel.com>
Cc: wei.fang@nxp.com, shenwei.wang@nxp.com, xiaoning.wang@nxp.com,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, simon.horman@corigine.com,
netdev@vger.kernel.org, linux-imx@nxp.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH V2 net-next] net: fec: add CBS offload support
Date: Mon, 13 Feb 2023 19:07:21 +0100 [thread overview]
Message-ID: <Y+p8WZCPKhp4/RIH@lunn.ch> (raw)
In-Reply-To: <8b25bd1f-4265-33ea-bdb9-bc700eff0b0e@intel.com>
On Mon, Feb 13, 2023 at 06:44:05PM +0100, Alexander Lobakin wrote:
> From: Andrew Lunn <andrew@lunn.ch>
> Date: Mon, 13 Feb 2023 17:21:43 +0100
>
> >>> + if (!speed) {
> >>> + netdev_err(ndev, "Link speed is 0!\n");
> >>
> >> ??? Is this possible? If so, why is it checked only here and why can it
> >> be possible?
> >
> > The obvious way this happens is that there is no link partner, so
> > auto-neg has not completed yet. The link speed is unknown.
>
> Sure, but why treat it an error path then?
You need to treat is somehow. I would actually disagree with
netdev_err(), netdev_dbg() seems more appropriate. But if you don't
know the link speed, you cannot program the scheduler.
This also comes back to my question about what should happen with a TC
configuration which works fine for 1000BaseT, but will not work for
10BaseT. Should the driver accept it only if the current link speed is
sufficient? Should it always accept it, and not program it into the
hardware if the current link speed does not support it?
Since we are talking about hardware acceleration here, what does the
pure software version do? Ideally we want the accelerated version to
do the same as the software version.
Wei, please disable all clever stuff in the hardware, setup a pure
software qdisc and a 10BaseT link. Oversubscribe the link and see what
happens. Does other traffic get starved?
Andrew
next prev parent reply other threads:[~2023-02-13 18:37 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-13 9:29 [PATCH V2 net-next] net: fec: add CBS offload support wei.fang
2023-02-13 13:32 ` Andrew Lunn
2023-02-14 8:02 ` Wei Fang
2023-02-13 16:04 ` Alexander Lobakin
2023-02-13 16:21 ` Andrew Lunn
2023-02-13 17:44 ` Alexander Lobakin
2023-02-13 18:07 ` Andrew Lunn [this message]
2023-02-14 13:22 ` Wei Fang
2023-02-14 14:28 ` Andrew Lunn
2023-02-16 12:43 ` Wei Fang
2023-02-18 1:15 ` Andrew Lunn
2023-02-18 1:59 ` Wei Fang
2023-02-21 2:25 ` Andrew Lunn
2023-02-14 9:34 ` Wei Fang
2023-02-14 13:49 ` Andrew Lunn
2023-02-14 16:49 ` Alexander Lobakin
2023-02-16 13:03 ` Wei Fang
2023-02-16 15:28 ` Alexander Lobakin
2023-02-17 2:18 ` Wei Fang
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=Y+p8WZCPKhp4/RIH@lunn.ch \
--to=andrew@lunn.ch \
--cc=alexandr.lobakin@intel.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-imx@nxp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=shenwei.wang@nxp.com \
--cc=simon.horman@corigine.com \
--cc=wei.fang@nxp.com \
--cc=xiaoning.wang@nxp.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).