]> git.droids-corp.org - dpdk.git/commitdiff
net/tap: fix max queues redefinition
authorPascal Mazon <pascal.mazon@6wind.com>
Thu, 6 Apr 2017 14:18:04 +0000 (16:18 +0200)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Thu, 6 Apr 2017 14:29:32 +0000 (16:29 +0200)
The macro RTE_PMD_TAP_MAX_QUEUES was defined twice.
On machines with kernel < 3.8, IFF_MULTI_QUEUE didn't exist, and thus
both definitions used different values.

Fixes: cf5643661161 ("net/tap: move private elements to external header")
Signed-off-by: Pascal Mazon <pascal.mazon@6wind.com>
drivers/net/tap/rte_eth_tap.c
drivers/net/tap/rte_eth_tap.h

index 832186344047183ea038ef3b5809f49043087b94..70cf9eb8d35fd0baa06c95b52d4d8323daf36edf 100644 (file)
 #define ETH_TAP_SPEED_ARG       "speed"
 #define ETH_TAP_REMOTE_ARG      "remote"
 
-#ifdef IFF_MULTI_QUEUE
-#define RTE_PMD_TAP_MAX_QUEUES 16
-#else
-#define RTE_PMD_TAP_MAX_QUEUES 1
-#endif
-
 #define FLOWER_KERNEL_VERSION KERNEL_VERSION(4, 2, 0)
 #define FLOWER_VLAN_KERNEL_VERSION KERNEL_VERSION(4, 9, 0)
 
index f1496dcfdb1a10025281fe5f79096e9302371be1..ad497b3d1015076aa6c82fd82eb2f5fbcc153224 100644 (file)
 #include <rte_ethdev.h>
 #include <rte_ether.h>
 
-#define RTE_PMD_TAP_MAX_QUEUES 16
+#ifdef IFF_MULTI_QUEUE
+#define RTE_PMD_TAP_MAX_QUEUES 16
+#else
+#define RTE_PMD_TAP_MAX_QUEUES 1
+#endif
 
 struct pkt_stats {
        uint64_t opackets;              /* Number of output packets */