[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAM_iQpXkXub85d=oLRnLVQCfeDsyDBfmUW0xAke45o83nA5fZg@mail.gmail.com>
Date: Mon, 14 Mar 2016 11:13:35 -0700
From: Cong Wang <xiyou.wangcong@...il.com>
To: Mahesh Bandewar <maheshb@...gle.com>
Cc: Nicolas Dichtel <nicolas.dichtel@...nd.com>,
Mahesh Bandewar <mahesh@...dewar.net>,
David Miller <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
netdev <netdev@...r.kernel.org>,
"Eric W. Biederman" <ebiederm@...ssion.com>,
Cong Wang <cwang@...pensource.com>
Subject: Re: [PATCH next v2 0/7] Introduce l3_dev pointer for L3 processing
On Sun, Mar 13, 2016 at 5:01 PM, Mahesh Bandewar <maheshb@...gle.com> wrote:
>>> If I understand correctly (and as Cong already said), information are
>>> leaking
>>> between netns during the input phase. On the tx side, skb_scrub_packet() is
>>> called, but not on the rx side. I think it's wrong. There should be an
>>> explicit
>>> boundary.
>>
>> That is not what I am complaining about.
>>
>> I dislike the trick of switching skb->dev pointer with skb->dev->l3_dev.
>> This is not how we switch netns, nor the way how netns works.
>>
> How it is different from what we are doing currently?
>
> Current: Use skb->dev for L3 processing and derive netns from skb->dev
> Proposal: use skb->dev->l3_dev for L3 processing and derive netns from
> skb->dev->l3_dev
If you ever read the part you quote below, you will have the answer.
>
>> Look at veth pair or dev_change_net_namespace(), each time when we
>> switch netns, we need to do a full reregistration or a full reentrance, we
>> never just switch some pointers to switch netns. This is why I said it breaks
>> isolation.
^ You miss this part.
>>
>> Also, it is ugly to hide such a ipvlan-specific pointer for half of the RX code
>> path.
> I think I have already mentioned, I'm adding RX code now and later
> I'll add TX code to use
> l3_dev to make it symmetric. This way all L3 (Tx/Rx) will use this
> device reference
> always.
You are trying to convince me by telling me you will add more ugly code??
Seriously??
Powered by blists - more mailing lists