/*-
* GPL LICENSE SUMMARY
*
- * Copyright(c) 2010-2013 Intel Corporation. All rights reserved.
+ * Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of version 2 of the GNU General Public License as
/*
* Transmit a packet (called by the kernel)
*/
+#ifdef RTE_KNI_VHOST
+static int
+kni_net_tx(struct sk_buff *skb, struct net_device *dev)
+{
+ struct kni_dev *kni = netdev_priv(dev);
+
+ dev_kfree_skb(skb);
+ kni->stats.tx_dropped++;
+
+ return NETDEV_TX_OK;
+}
+#else
static int
kni_net_tx(struct sk_buff *skb, struct net_device *dev)
{
return NETDEV_TX_OK;
}
+#endif
/*
* Deal with a transmit timeout.