[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20141003104858.6745.62964.stgit@dragon>
Date: Fri, 03 Oct 2014 12:48:58 +0200
From: Jesper Dangaard Brouer <brouer@...hat.com>
To: Jesper Dangaard Brouer <brouer@...hat.com>, netdev@...r.kernel.org,
"David S. Miller" <davem@...emloft.net>
Cc: Jiri Pirko <jpirko@...hat.com>, mpatel@...hat.com
Subject: [net-next PATCH] veth: don't assign a qdisc to veth
The veth driver is a virtual device, and should not have assigned
the default qdisc. Verified (ndo_start_xmit) veth_xmit can only
return NETDEV_TX_OK, thus this should be safe to bypass qdisc.
Not assigning a qdisc is subtly done by setting tx_queue_len to zero.
Reported-by: Mrunal Patel <mpatel@...hat.com>
Signed-off-by: Jesper Dangaard Brouer <brouer@...hat.com>
---
drivers/net/veth.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/drivers/net/veth.c b/drivers/net/veth.c
index 8ad5965..3c32fcf 100644
--- a/drivers/net/veth.c
+++ b/drivers/net/veth.c
@@ -287,6 +287,7 @@ static const struct net_device_ops veth_netdev_ops = {
static void veth_setup(struct net_device *dev)
{
ether_setup(dev);
+ dev->tx_queue_len = 0;
dev->priv_flags &= ~IFF_TX_SKB_SHARING;
dev->priv_flags |= IFF_LIVE_ADDR_CHANGE;
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists