Re: [PATCH] Revert "RDMA/rxe: Remove VLAN code leftovers from RXE"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2021-01-19 at 09:01 -0400, Jason Gunthorpe wrote:
> On Tue, Jan 19, 2021 at 02:40:52PM +0200, Mohamed._. Heib wrote:
> >    Hi,
> >    As far as i remember the traffic still can be encapsulated over
> > the
> >    vlan interface with vlan tag
> >    by specifying the vlan interface gid index that mapped to the
> > vlan ip
> >    on the vlan parent interface gids table.
> >    And by removing the vlan related functionality on rxe (commit:
> >    b2d2440430c0) the rxe still can send traffic via vlan interface
> >    but can't receive from vlan interface and that will break the
> > vlan
> >    functionality on rxe so i think you need keep the vlan related
> > code on
> >    rxe.
> 
> That may be, but the code here is still wrong.
> 
> Incoming packets are supposed to be matched to the gid table, which
> specifies the allowed vlans, it can't just be taken raw from the skb
> like this.

I lack the deep understanding of the RDMA stack to fully understand.
Are you saying it's a permission problem? Do you see a security issue?
Or is it not compliant with some spec? Which?

> If someone wants to add vlan support to rxe it needs to be done
> right,
> currently it doesn't support vlan.

Hm. As a matter of fact, it has "worked" this way in mainline since
v5.0, when 43c9fc509fa5 ("rdma_rxe: make rxe work over 802.1q VLAN
devices") had been merged. The code that deals with VLANs in RXE, which
was fixed by that commit, is older. AFAICS it dates back to the first
merge of the rxe driver.

Just ripping the code out causes a regression, after 10 kernel minor
releases during which it "worked" in practice (as far as I can judge).
I suppose there are only a few users of this feature, but I fail to see
why keeping this code in until a clean implementation is available
would do any harm.

I'd like to fix this for good, but I lack the knowledge to do this, at
least in the short term. I've asked back in 2018 how RXE+VLAN was
intended to work, but never got an answer.

Regards,
Martin





[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux