From: Vadim Fedorenko <vadim.fedorenko@linux.dev>
To: Esben Haabendal <esben@geanix.com>,
netdev@vger.kernel.org,
Alexandre Torgue <alexandre.torgue@foss.st.com>,
Jose Abreu <joabreu@synopsys.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Maxime Coquelin <mcoquelin.stm32@gmail.com>,
Shawn Guo <shawnguo@kernel.org>,
Sascha Hauer <s.hauer@pengutronix.de>,
Pengutronix Kernel Team <kernel@pengutronix.de>,
Fabio Estevam <festevam@gmail.com>,
NXP Linux Team <linux-imx@nxp.com>
Cc: linux-arm-kernel@lists.infradead.org,
linux-stm32@st-md-mailman.stormreply.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] net: stmmac: dwmac-imx: set TSO/TBS TX queues default settings
Date: Thu, 25 Jan 2024 17:11:08 +0000 [thread overview]
Message-ID: <081af630-ab5d-4502-a29a-a8577d414809@linux.dev> (raw)
In-Reply-To: <5606bb5f0b7566a20bb136b268dae89d22a48898.1706184304.git.esben@geanix.com>
On 25/01/2024 12:34, Esben Haabendal wrote:
> TSO and TBS cannot coexist. For now we set i.MX Ethernet QOS controller to use
> TX queue with TSO and the rest for TBS.
>
> TX queues with TBS can support etf qdisc hw offload.
>
> Signed-off-by: Esben Haabendal <esben@geanix.com>
> ---
> drivers/net/ethernet/stmicro/stmmac/dwmac-imx.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-imx.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-imx.c
> index 8f730ada71f9..c42e8f972833 100644
> --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-imx.c
> +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-imx.c
> @@ -353,6 +353,12 @@ static int imx_dwmac_probe(struct platform_device *pdev)
> if (data->flags & STMMAC_FLAG_HWTSTAMP_CORRECT_LATENCY)
> plat_dat->flags |= STMMAC_FLAG_HWTSTAMP_CORRECT_LATENCY;
>
> + for (int i = 0; i < plat_dat->tx_queues_to_use; i++) {
> + /* Default TX Q0 to use TSO and rest TXQ for TBS */
> + if (i > 0)
> + plat_dat->tx_queues_cfg[i].tbs_en = 1;
> + }
> +
Just wonder why don't you start with i = 1 and remove 'if' completely?
Keeping comment in place will make it understandable.
> plat_dat->host_dma_width = dwmac->ops->addr_width;
> plat_dat->init = imx_dwmac_init;
> plat_dat->exit = imx_dwmac_exit;
next prev parent reply other threads:[~2024-01-25 17:11 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <cover.1706184304.git.esben@geanix.com>
2024-01-25 12:34 ` [PATCH 1/2] net: stmmac: do not clear TBS enable bit on link up/down Esben Haabendal
2024-01-25 12:34 ` [PATCH 2/2] net: stmmac: dwmac-imx: set TSO/TBS TX queues default settings Esben Haabendal
2024-01-25 17:11 ` Vadim Fedorenko [this message]
2024-01-25 18:31 ` Esben Haabendal
2024-01-26 1:22 ` Jakub Kicinski
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=081af630-ab5d-4502-a29a-a8577d414809@linux.dev \
--to=vadim.fedorenko@linux.dev \
--cc=alexandre.torgue@foss.st.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=esben@geanix.com \
--cc=festevam@gmail.com \
--cc=joabreu@synopsys.com \
--cc=kernel@pengutronix.de \
--cc=kuba@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-imx@nxp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=mcoquelin.stm32@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=s.hauer@pengutronix.de \
--cc=shawnguo@kernel.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).