From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yuanhan Liu Subject: [PATCH 12/17] vhost: drop the Rx and Tx queue macro Date: Fri, 3 Mar 2017 17:51:17 +0800 Message-ID: <1488534682-3494-13-git-send-email-yuanhan.liu@linux.intel.com> References: <1488534682-3494-1-git-send-email-yuanhan.liu@linux.intel.com> Cc: Maxime Coquelin , Harris James R , Liu Changpeng , Yuanhan Liu To: dev@dpdk.org Return-path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id D08466CB4 for ; Fri, 3 Mar 2017 10:53:00 +0100 (CET) In-Reply-To: <1488534682-3494-1-git-send-email-yuanhan.liu@linux.intel.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" They are virti-net specific and should be defined inside the virtio-net driver. Signed-off-by: Yuanhan Liu --- drivers/net/vhost/rte_eth_vhost.c | 2 ++ examples/tep_termination/main.h | 2 ++ examples/vhost/main.h | 2 ++ lib/librte_vhost/rte_virtio_net.h | 3 --- 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/drivers/net/vhost/rte_eth_vhost.c b/drivers/net/vhost/rte_eth_vhost.c index 135fec1..450d167 100644 --- a/drivers/net/vhost/rte_eth_vhost.c +++ b/drivers/net/vhost/rte_eth_vhost.c @@ -45,6 +45,8 @@ #include "rte_eth_vhost.h" +enum {VIRTIO_RXQ, VIRTIO_TXQ, VIRTIO_QNUM}; + #define ETH_VHOST_IFACE_ARG "iface" #define ETH_VHOST_QUEUES_ARG "queues" #define ETH_VHOST_CLIENT_ARG "client" diff --git a/examples/tep_termination/main.h b/examples/tep_termination/main.h index c0ea766..8ed817d 100644 --- a/examples/tep_termination/main.h +++ b/examples/tep_termination/main.h @@ -54,6 +54,8 @@ /* Max number of devices. Limited by the application. */ #define MAX_DEVICES 64 +enum {VIRTIO_RXQ, VIRTIO_TXQ, VIRTIO_QNUM}; + /* Per-device statistics struct */ struct device_statistics { uint64_t tx_total; diff --git a/examples/vhost/main.h b/examples/vhost/main.h index 6bb42e8..7a3d251 100644 --- a/examples/vhost/main.h +++ b/examples/vhost/main.h @@ -41,6 +41,8 @@ #define RTE_LOGTYPE_VHOST_DATA RTE_LOGTYPE_USER2 #define RTE_LOGTYPE_VHOST_PORT RTE_LOGTYPE_USER3 +enum {VIRTIO_RXQ, VIRTIO_TXQ, VIRTIO_QNUM}; + struct device_statistics { uint64_t tx; uint64_t tx_total; diff --git a/lib/librte_vhost/rte_virtio_net.h b/lib/librte_vhost/rte_virtio_net.h index 280d9c2..fa98d29 100644 --- a/lib/librte_vhost/rte_virtio_net.h +++ b/lib/librte_vhost/rte_virtio_net.h @@ -55,9 +55,6 @@ #define RTE_VHOST_USER_NO_RECONNECT (1ULL << 1) #define RTE_VHOST_USER_DEQUEUE_ZERO_COPY (1ULL << 2) -/* Enum for virtqueue management. */ -enum {VIRTIO_RXQ, VIRTIO_TXQ, VIRTIO_QNUM}; - /** * Information relating to memory regions including offsets to * addresses in QEMUs memory file. -- 1.9.0