netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Patrick McHardy <kaber@trash.net>
To: David Miller <davem@davemloft.net>
Cc: bart@jukie.net, greearb@candelatech.com, shemminger@vyatta.com,
	dada1@cosmosbay.com, frank.blaschka@de.ibm.com,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [BUG] 2.6.29-rc* QinQ vlan trunking regression
Date: Wed, 04 Mar 2009 12:45:33 +0100	[thread overview]
Message-ID: <49AE69DD.80802@trash.net> (raw)
In-Reply-To: <20090304.025914.149394356.davem@davemloft.net>

David Miller wrote:
> From: Patrick McHardy <kaber@trash.net>
> Date: Wed, 04 Mar 2009 10:57:47 +0100
> 
>>>> I can reproduce it reliably with:
>>>>
>>>>   $ modprobe 8021q
>>>>   $ vconfig add eth1 5
>>>>   $ ifconfig eth1.5 up
>>>>   $ vconfig add eth1.5 4
>>> Stephen please fix this.
>> I'm maintaining vlan :) I haven't been able to look into this yet,
>> but I should be later today.
> 
> Ok, I don't actually care who fixes it :-)
> 
> I asked Stephen because this appears like it might be netdev_ops
> fallout.

Good point. I think I know whats happening. The VLAN devices are
registered with vlan_netdev_ops, the ->init function then potentially
replaces them based on whether the underlying device supports HW
acceleration. At this point the register_netdev() function already
has used the first netdev_ops structure to initialize the compat
pointers, meaning the new assignment is largely without effect and
causes incorrect ops to be used with HW acceleration

This probably causes the slab corruption since the HW accelerated
VLAN device doesn't increase the headroom, but the non-accelerated
functions try to add a hard header anyways.

This is a bit tricky to fix since we actually need some valid
ops before invoking ->init(). One way would be to move the compat
ops initialization to a seperate function and have VLAN use it to
switch its ops.

  reply	other threads:[~2009-03-04 11:45 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-28 18:05 [BUG] 2.6.29-rc* QinQ vlan trunking regression Bart Trojanowski
2009-03-04  7:43 ` David Miller
2009-03-04  9:57   ` Patrick McHardy
2009-03-04 10:59     ` David Miller
2009-03-04 11:45       ` Patrick McHardy [this message]
2009-03-05  3:53         ` David Miller
2009-03-05  4:54           ` Bart Trojanowski
2009-03-05  4:59             ` Bart Trojanowski
2009-03-05  5:51               ` Patrick McHardy
2009-03-05  5:21             ` David Miller
2009-03-05  5:51           ` Patrick McHardy
2009-03-05  6:57             ` David Miller
2009-03-05  7:00               ` David Miller
2009-03-05  7:05                 ` Patrick McHardy
2009-03-05  7:11                   ` David Miller
2009-03-05  7:12                     ` Patrick McHardy
2009-03-05  7:19                       ` David Miller
2009-03-05  7:26                         ` Patrick McHardy
2009-03-05  7:31                           ` Patrick McHardy
2009-03-05  7:45                             ` David Miller
2009-03-05  8:05                             ` Frank Blaschka
2009-03-05  8:27                               ` Patrick McHardy
2009-03-05  8:56                                 ` David Miller
2009-03-05  8:59                                   ` David Miller
2009-03-05  9:08                                     ` Patrick McHardy
2009-03-05  9:09                                       ` Patrick McHardy
2009-03-05  9:58                                         ` David Miller
2009-03-05 12:30           ` Maxime Bizon
2009-03-05 12:55             ` 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=49AE69DD.80802@trash.net \
    --to=kaber@trash.net \
    --cc=bart@jukie.net \
    --cc=dada1@cosmosbay.com \
    --cc=davem@davemloft.net \
    --cc=frank.blaschka@de.ibm.com \
    --cc=greearb@candelatech.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=shemminger@vyatta.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).