diff options
author | nickcooper-zhangtonghao <nic@opencloud.tech> | 2017-01-08 17:30:21 -0800 |
---|---|---|
committer | Daniele Di Proietto <diproiettod@vmware.com> | 2017-01-08 18:06:39 -0800 |
commit | cce57f8daaf49e699a73b37f8aab043e37d697aa (patch) | |
tree | 036b1a1f6f4a187e29fc31f02e9b82883871afa8 /lib | |
parent | 182ca1ae947b3a8b6e203ad897bc07eccb519345 (diff) | |
download | openvswitch-cce57f8daaf49e699a73b37f8aab043e37d697aa.tar.gz |
netdev-dummy: Uses the NR_QUEUE instead of magic numbers.
The NR_QUEUE is defined in "lib/dpif-netdev.h", netdev-dpdk
uses it instead of magic number. netdev-dummy should be
in the same case.
Signed-off-by: nickcooper-zhangtonghao <nic@opencloud.tech>
Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/netdev-dummy.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/netdev-dummy.c b/lib/netdev-dummy.c index d406cbcaf..bdb77e131 100644 --- a/lib/netdev-dummy.c +++ b/lib/netdev-dummy.c @@ -868,8 +868,8 @@ netdev_dummy_set_config(struct netdev *netdev_, const struct smap *args) goto exit; } - new_n_rxq = MAX(smap_get_int(args, "n_rxq", 1), 1); - new_n_txq = MAX(smap_get_int(args, "n_txq", 1), 1); + new_n_rxq = MAX(smap_get_int(args, "n_rxq", NR_QUEUE), 1); + new_n_txq = MAX(smap_get_int(args, "n_txq", NR_QUEUE), 1); new_numa_id = smap_get_int(args, "numa_id", 0); if (new_n_rxq != netdev->requested_n_rxq || new_n_txq != netdev->requested_n_txq |