From: "David S. Miller" <davem@redhat.com>
To: Pekka Pietikainen <pp@ee.oulu.fi>
Cc: jgarzik@pobox.com, jolt@tuxbox.org, linux-kernel@vger.kernel.org,
netdev@oss.sgi.com
Subject: Re: [PATCH] b44 1GB DMA workaround (was: b44: add 47xx support)
Date: Sat, 7 Aug 2004 17:05:03 -0700 [thread overview]
Message-ID: <20040807170503.3b05255a.davem@redhat.com> (raw)
In-Reply-To: <20040807224019.GA24817@ee.oulu.fi>
On Sun, 8 Aug 2004 01:40:19 +0300
Pekka Pietikainen <pp@ee.oulu.fi> wrote:
> On Tue, Aug 03, 2004 at 06:39:19PM -0700, David S. Miller wrote:
> > Changing skb->data is not legal. Please implement this in
> > such a way that skb->data does not get modified. By modifying
> > skb->data you will break things such as packet sniffers and
> > netfilter, and that's just the tip of the iceberg. :-)
> >
> Haven't noticed any breakage (tm) but I'm just a x86 weenie :-)
Not an x86 specific problem :-) Just run tcpdump in a shell when
one of these TX bounce cases happen, your skb->data modification could
will make tcpdump see a corrupt packet.
> Current approach is:
>
> if(1 (just for testing ;) ) || mapping+len > B44_DMA_MASK) {
> /* Chip can't handle DMA to/from >1GB, use bounce buffer */
> pci_unmap_single(bp->pdev, mapping, len,PCI_DMA_TODEVICE);
> memcpy(bp->tx_bufs+entry*TX_PKT_BUF_SZ,skb->data,skb->len);
> mapping = pci_map_single(bp->pdev,bp->tx_bufs+entry*TX_PKT_BUF_SZ, len, PCI_DMA_TODEVICE);
> }
This looks a bit better.
next prev parent reply other threads:[~2004-08-08 0:06 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-23 21:35 b44: add 47xx support Florian Schirmer
2004-07-26 14:11 ` Pekka Pietikainen
2004-08-04 0:31 ` [PATCH] b44 1GB DMA workaround (was: b44: add 47xx support) Pekka Pietikainen
2004-08-04 1:39 ` David S. Miller
2004-08-07 22:40 ` Pekka Pietikainen
2004-08-08 0:05 ` David S. Miller [this message]
2004-08-08 9:31 ` [PATCH] b44 1GB DMA workaround Pekka Pietikainen
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=20040807170503.3b05255a.davem@redhat.com \
--to=davem@redhat.com \
--cc=jgarzik@pobox.com \
--cc=jolt@tuxbox.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@oss.sgi.com \
--cc=pp@ee.oulu.fi \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.