public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Antoine Tenart <antoine.tenart@bootlin.com>
To: Matteo Croce <mcroce@redhat.com>
Cc: netdev@vger.kernel.org,
	Antoine Tenart <antoine.tenart@bootlin.com>,
	Maxime Chevallier <maxime.chevallier@bootlin.com>,
	Marcin Wojtas <mw@semihalf.com>,
	Stefan Chulski <stefanc@marvell.com>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH net-next] mvpp2: document HW checksum behaviour
Date: Fri, 26 Jul 2019 14:57:15 +0200	[thread overview]
Message-ID: <20190726125715.GB5031@kwain> (raw)
In-Reply-To: <20190725231546.23878-1-mcroce@redhat.com>

Hi Matteo,

On Fri, Jul 26, 2019 at 01:15:46AM +0200, Matteo Croce wrote:
> The hardware can only offload checksum calculation on first port due to
> the Tx FIFO size limitation. Document this in a comment.
> 
> Fixes: 576193f2d579 ("net: mvpp2: jumbo frames support")
> Signed-off-by: Matteo Croce <mcroce@redhat.com>

Looks good. Please note there's a similar code path in the probe. You
could also add a comment there (or move this check/comment in a common
place).

Thanks!
Antoine

> ---
>  drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c
> index d8e5241097a9..2f7286bd203b 100644
> --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c
> +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c
> @@ -843,7 +843,10 @@ static int mvpp2_bm_update_mtu(struct net_device *dev, int mtu)
>  		/* Add port to new short & long pool */
>  		mvpp2_swf_bm_pool_init(port);
>  
> -		/* Update L4 checksum when jumbo enable/disable on port */
> +		/* Update L4 checksum when jumbo enable/disable on port.
> +		 * Only port 0 supports hardware checksum offload due to
> +		 * the Tx FIFO size limitation.
> +		 */
>  		if (new_long_pool == MVPP2_BM_JUMBO && port->id != 0) {
>  			dev->features &= ~(NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM);
>  			dev->hw_features &= ~(NETIF_F_IP_CSUM |
> -- 
> 2.21.0
> 

-- 
Antoine Ténart, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

  reply	other threads:[~2019-07-26 12:57 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-25 23:15 [PATCH net-next] mvpp2: document HW checksum behaviour Matteo Croce
2019-07-26 12:57 ` Antoine Tenart [this message]
2019-07-26 14:35   ` Matteo Croce
2019-07-27 20:23     ` David Miller
2019-07-28  1:36   ` Matteo Croce
2019-07-28 14:30     ` Matteo Croce
2019-07-28 15:22       ` [EXT] " Stefan Chulski

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=20190726125715.GB5031@kwain \
    --to=antoine.tenart@bootlin.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mcroce@redhat.com \
    --cc=mw@semihalf.com \
    --cc=netdev@vger.kernel.org \
    --cc=stefanc@marvell.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