netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: karl.beldan@gmail.com
Cc: karl.beldan@rivierawaves.com, netdev@vger.kernel.org,
	ijc@hellion.org.uk, eric.dumazet@gmail.com,
	ezequiel.garcia@free-electrons.com,
	sebastian.hesselbarth@gmail.com
Subject: Re: [PATCH] net: mv643xx_eth: reclaim TX skbs only when released by the HW
Date: Thu, 06 Nov 2014 14:55:34 -0500 (EST)	[thread overview]
Message-ID: <20141106.145534.804171709065169233.davem@davemloft.net> (raw)
In-Reply-To: <1415197979-1702-1-git-send-email-karl.beldan@gmail.com>

From: Karl Beldan <karl.beldan@gmail.com>
Date: Wed,  5 Nov 2014 15:32:59 +0100

> From: Karl Beldan <karl.beldan@rivierawaves.com>
> 
> ATM, txq_reclaim will dequeue and free an skb for each tx desc released
> by the hw that has TX_LAST_DESC set. However, in case of TSO, each
> hw desc embedding the last part of a segment has TX_LAST_DESC set,
> losing the one-to-one 'last skb frag'/'TX_LAST_DESC set' correspondance,
> which causes data corruption.
> 
> Fix this by checking TX_ENABLE_INTERRUPT instead of TX_LAST_DESC, and
> warn when trying to dequeue from an empty txq (which can be symptomatic
> of releasing skbs prematurely).
> 
> Fixes: 3ae8f4e0b98 ('net: mv643xx_eth: Implement software TSO')
> Reported-by: Slawomir Gajzner <slawomir.gajzner@gmail.com>
> Reported-by: Julien D'Ascenzio <jdascenzio@yahoo.fr>
> Signed-off-by: Karl Beldan <karl.beldan@rivierawaves.com>

Applied and queued up for -stable, but it seems there might still be some
bugs to resolve...

      parent reply	other threads:[~2014-11-06 19:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-05 14:32 [PATCH] net: mv643xx_eth: reclaim TX skbs only when released by the HW Karl Beldan
2014-11-05 14:46 ` Ezequiel Garcia
2014-11-05 15:05   ` Karl Beldan
2014-11-05 18:31     ` Karl Beldan
2014-11-05 15:41   ` Eric Dumazet
2014-11-05 19:04     ` Ian Campbell
2014-11-06 19:55 ` David Miller [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=20141106.145534.804171709065169233.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=eric.dumazet@gmail.com \
    --cc=ezequiel.garcia@free-electrons.com \
    --cc=ijc@hellion.org.uk \
    --cc=karl.beldan@gmail.com \
    --cc=karl.beldan@rivierawaves.com \
    --cc=netdev@vger.kernel.org \
    --cc=sebastian.hesselbarth@gmail.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).