From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
To: Fugang Duan <fugang.duan@freescale.com>
Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"David S. Miller" <davem@davemloft.net>,
Fabio Estevam <Fabio.Estevam@freescale.com>,
Frank Li <frank.li@freescale.net>,
Jim Baxter <jim_baxter@mentor.com>,
Marek Szyprowski <m.szyprowski@samsung.com>
Subject: Re: [PATCH] net: fec_main: dma_map() only the length of the skb
Date: Wed, 27 Nov 2013 14:38:27 +0100 [thread overview]
Message-ID: <5295F5D3.8020002@linutronix.de> (raw)
In-Reply-To: <9848F2DB572E5649BA045B288BE08FBE01899801@039-SN2MPN1-023.039d.mgd.msft.net>
- <frank.li@freescale.net> because MTA complains
On 11/27/2013 02:08 PM, Fugang Duan wrote:
> In fact, there have one memory copy for enet as below since enet have 16 bytes data buffer alignment request.
> if (((unsigned long) bufaddr) & FEC_ALIGNMENT) {
> memcpy(fep->tx_bounce[index], skb->data, skb->len);
> bufaddr = fep->tx_bounce[index];
> }
This memcpy() is only executed if the buffer isn't properly aligned
which shouldn't be the rule but an exception. This aligment check is
also available in v2.6.31 where the BUG_ON() statement was triggered.
>
> So, the bug you describe at commit log shouldn't exist.
>
> Anyway, it is better to use the real packet size for the mapping.
>
>
> I will do overnight stress test for the patch tomorrow.
Thanks.
>
> Thanks,
> Andy
>
Sebastian
next prev parent reply other threads:[~2013-11-27 13:38 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-27 12:44 [PATCH] net: fec_main: dma_map() only the length of the skb Sebastian Andrzej Siewior
2013-11-27 13:08 ` Fugang Duan
2013-11-27 13:38 ` Sebastian Andrzej Siewior [this message]
2013-11-28 1:18 ` Fugang Duan
2013-11-28 11:24 ` Sebastian Andrzej Siewior
2013-12-02 1:25 ` David Miller
2013-12-02 2:04 ` Fugang Duan
2013-12-02 2:14 ` Fugang Duan
2013-12-02 9:52 ` [PATCH v2] " Sebastian Andrzej Siewior
2013-12-02 9:58 ` Fugang Duan
2013-12-02 21:59 ` David Miller
2013-12-03 7:36 ` [PATCH] " Marek Szyprowski
2013-12-03 7:54 ` Sebastian Andrzej Siewior
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=5295F5D3.8020002@linutronix.de \
--to=bigeasy@linutronix.de \
--cc=Fabio.Estevam@freescale.com \
--cc=davem@davemloft.net \
--cc=frank.li@freescale.net \
--cc=fugang.duan@freescale.com \
--cc=jim_baxter@mentor.com \
--cc=m.szyprowski@samsung.com \
--cc=netdev@vger.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).