From: Pravin B Shelar Date: Sun, 17 Jul 2016 16:52:11 +0000 (-0700) Subject: datapath: internal-dev: set IFF_NO_QUEUE X-Git-Url: http://git.cascardo.eti.br/?a=commitdiff_plain;h=6089e1d8429904d98ed682754a6f8802d724d759;p=cascardo%2Fovs.git datapath: internal-dev: set IFF_NO_QUEUE Introduced by upstream commit 4272cc51a6d ("openvswitch: Convert to using IFF_NO_QUEUE"). Signed-off-by: Pravin B Shelar Acked-by: Jesse Gross --- diff --git a/datapath/linux/compat/include/linux/netdevice.h b/datapath/linux/compat/include/linux/netdevice.h index 235851bd5..f066e91d5 100644 --- a/datapath/linux/compat/include/linux/netdevice.h +++ b/datapath/linux/compat/include/linux/netdevice.h @@ -281,4 +281,10 @@ static inline void netdev_reset_rx_headroom(struct net_device *dev) #endif +#ifdef IFF_NO_QUEUE +#define HAVE_IFF_NO_QUEUE +#else +#define IFF_NO_QUEUE 0 +#endif + #endif /* __LINUX_NETDEVICE_WRAPPER_H */ diff --git a/datapath/vport-internal_dev.c b/datapath/vport-internal_dev.c index 794f4808a..198bae663 100644 --- a/datapath/vport-internal_dev.c +++ b/datapath/vport-internal_dev.c @@ -169,11 +169,14 @@ static void do_setup(struct net_device *netdev) netdev->priv_flags &= ~IFF_TX_SKB_SHARING; netdev->priv_flags |= IFF_LIVE_ADDR_CHANGE | IFF_OPENVSWITCH | - IFF_PHONY_HEADROOM; + IFF_PHONY_HEADROOM | IFF_NO_QUEUE; netdev->destructor = internal_dev_destructor; netdev->ethtool_ops = &internal_dev_ethtool_ops; netdev->rtnl_link_ops = &internal_dev_link_ops; + +#ifndef HAVE_IFF_NO_QUEUE netdev->tx_queue_len = 0; +#endif netdev->features = NETIF_F_LLTX | NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_HIGHDMA | NETIF_F_HW_CSUM |