Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

RDMA/rxe: Consider skb reserve space based on netdev of GID

Always consider the skb reserve space based on netdevice of the GID
attribute, regardless of vlan or non vlan netdevice.

Fixes: 43c9fc509fa5 ("rdma_rxe: make rxe work over 802.1q VLAN devices")
Signed-off-by: Parav Pandit <parav@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>

authored by

Parav Pandit and committed by
Jason Gunthorpe
3bf3e2b8 dd05cb82

+2 -1
+2 -1
drivers/infiniband/sw/rxe/rxe_net.c
··· 481 481 if (unlikely(!skb)) 482 482 goto out; 483 483 484 - skb_reserve(skb, hdr_len + LL_RESERVED_SPACE(rxe->ndev)); 484 + skb_reserve(skb, hdr_len + LL_RESERVED_SPACE(ndev)); 485 485 486 + /* FIXME: hold reference to this netdev until life of this skb. */ 486 487 skb->dev = ndev; 487 488 if (av->network_type == RDMA_NETWORK_IPV4) 488 489 skb->protocol = htons(ETH_P_IP);