All of lore.kernel.org
 help / color / mirror / Atom feed
From: Willy Tarreau <w@1wt.eu>
To: Tien ChenLi <cltien@gmail.com>
Cc: linux-kernel@vger.kernel.org, David Miller <davem@davemloft.net>
Subject: Re: [PATCH]pktgen oops when used with balance-tlb bonding
Date: Wed, 2 Aug 2006 22:38:54 +0200	[thread overview]
Message-ID: <20060802203854.GA462@1wt.eu> (raw)
In-Reply-To: <cc862f80607221611x52efac88u620516e17edfa03b@mail.gmail.com>

On Sat, Jul 22, 2006 at 07:11:21PM -0400, Tien ChenLi wrote:
> I fixed a bug in pktgen so it won't cause oops when used with
> balance-tlb or balance-alb bonding driver:
> 
> --- linux-2.6.17.4/net/core/pktgen.c.orig       2006-07-06 
> 16:02:28.000000000 -0
> 400
> +++ linux-2.6.17.4/net/core/pktgen.c    2006-07-10 16:40:47.000000000 -0400
> @@ -2149,6 +2149,9 @@
>        skb->mac.raw = ((u8 *) iph) - 14 - pkt_dev->nr_labels*sizeof(u32);
>        skb->dev = odev;
>        skb->pkt_type = PACKET_HOST;
> +       skb->mac.raw = eth;
          ^^^^^^^^^^^^
Are you sure about this ? I don't understand why you change skb->mac.raw
here while it's still assigned 3 lines above. Either of those is unneeded
and/or erroneous.

> +       skb->nh.iph = iph;
> +       skb->h.uh = udph;
> 
>        if (pkt_dev->nfrags <= 0)
>                pgh = (struct pktgen_hdr *)skb_put(skb, datalen);
> 
> The root cause is that the bond_alb_xmit in bonding will peek the
> destination address in packet via the skb->nh.iph pointer, generally
> this will be filled by upper layer network driver, but the packet
> generated by pktgen will be sent to device driver so it will need to
> set this pointer correctly. The other two pointers are not necessary
> for now, they are set to avoid similar problem.

Fine. Please confirm your intention about mac.raw above, and as David
said, please sign-off the patch and check your mailer for unexpected
tabs/spaces conversions.

> Chen-Li Tien

Thanks in advance,
Willy


  parent reply	other threads:[~2006-08-02 20:39 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-22 23:11 [PATCH]pktgen oops when used with balance-tlb bonding Tien ChenLi
2006-07-24  6:35 ` David Miller
2006-08-02 20:38 ` Willy Tarreau [this message]
2006-08-07 19:04   ` Tien ChenLi
2006-08-07 19:07     ` Tien ChenLi
2006-08-08  3:51       ` David Miller
2006-08-08  3:49     ` David Miller

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=20060802203854.GA462@1wt.eu \
    --to=w@1wt.eu \
    --cc=cltien@gmail.com \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@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 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.