* [dpdk-dev] [PATCH] app/testpmd: compile even if ixgbe anf bnxt pmds are not compiling
@ 2017-10-19 18:53 aviadye
2017-10-23 22:32 ` Ferruh Yigit
2017-10-24 14:48 ` [dpdk-dev] [PATCH v2] app/testpmd: compile without ixgbe and bnxt pmds aviadye
0 siblings, 2 replies; 5+ messages in thread
From: aviadye @ 2017-10-19 18:53 UTC (permalink / raw)
To: dev, sergio.gonzalez.monroy, pablo.de.lara.guarch, aviadye
Cc: borisp, akhil.goyal, hemant.agrawal, radu.nicolau,
declan.doherty, aviadye, liranl, nelio.laranjeiro, thomas
From: Aviad Yehezkel <aviadye@mellanox.com>
Signed-off-by: Aviad Yehezkel <aviadye@mellanox.com>
Signed-off-by: Nicolai Radu <radu.nicolai@intel.com>
---
app/test-pmd/cmdline.c | 13 ++++++++++---
app/test-pmd/config.c | 12 +++++++++++-
2 files changed, 21 insertions(+), 4 deletions(-)
diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index bb01e98..204f1e3 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -7379,11 +7379,17 @@ struct cmd_set_vf_rxmode {
};
static void
-cmd_set_vf_rxmode_parsed(void *parsed_result,
- __attribute__((unused)) struct cmdline *cl,
- __attribute__((unused)) void *data)
+cmd_set_vf_rxmode_parsed(
+#if defined(RTE_LIBRTE_IXGBE_PMD) || defined(RTE_LIBRTE_BNXT_PMD)
+ void *parsed_result,
+#else
+ __attribute__((unused)) void *parsed_result,
+#endif
+ __attribute__((unused)) struct cmdline *cl,
+ __attribute__((unused)) void *data)
{
int ret = -ENOTSUP;
+#if defined(RTE_LIBRTE_IXGBE_PMD) || defined(RTE_LIBRTE_BNXT_PMD)
uint16_t rx_mode = 0;
struct cmd_set_vf_rxmode *res = parsed_result;
@@ -7398,6 +7404,7 @@ cmd_set_vf_rxmode_parsed(void *parsed_result,
else if (!strncmp(res->mode, "MPE",3))
rx_mode |= ETH_VMDQ_ACCEPT_MULTICAST;
}
+#endif
#ifdef RTE_LIBRTE_IXGBE_PMD
if (ret == -ENOTSUP)
diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index bafe76c..d38ba82 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -3181,7 +3181,17 @@ set_queue_rate_limit(portid_t port_id, uint16_t queue_idx, uint16_t rate)
}
int
-set_vf_rate_limit(portid_t port_id, uint16_t vf, uint16_t rate, uint64_t q_msk)
+set_vf_rate_limit(
+ portid_t port_id,
+#if defined(RTE_LIBRTE_IXGBE_PMD) || defined(RTE_LIBRTE_BNXT_PMD)
+ uint16_t vf,
+ uint16_t rate,
+ uint64_t q_msk)
+#else
+ __attribute__((unused)) uint16_t vf,
+ __attribute__((unused)) uint16_t rate,
+ __attribute__((unused)) uint64_t q_msk)
+#endif
{
int diag = -ENOTSUP;
--
2.7.4
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [dpdk-dev] [PATCH] app/testpmd: compile even if ixgbe anf bnxt pmds are not compiling
2017-10-19 18:53 [dpdk-dev] [PATCH] app/testpmd: compile even if ixgbe anf bnxt pmds are not compiling aviadye
@ 2017-10-23 22:32 ` Ferruh Yigit
2017-10-24 14:48 ` [dpdk-dev] [PATCH v2] app/testpmd: compile without ixgbe and bnxt pmds aviadye
1 sibling, 0 replies; 5+ messages in thread
From: Ferruh Yigit @ 2017-10-23 22:32 UTC (permalink / raw)
To: aviadye, dev, sergio.gonzalez.monroy, pablo.de.lara.guarch, aviadye
Cc: borisp, akhil.goyal, hemant.agrawal, radu.nicolau,
declan.doherty, liranl, nelio.laranjeiro, thomas
On 10/19/2017 11:53 AM, aviadye@dev.mellanox.co.il wrote:
> From: Aviad Yehezkel <aviadye@mellanox.com>
Hi Aviad,
What do you think using RTE_SET_USED() as done in other samples, we know those
variables may not be used if PMDs are not defined, no need to make code more
complex.
Like:
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -7504,6 +7504,9 @@ cmd_set_vf_rxmode_parsed(void *parsed_result,
ret = rte_pmd_bnxt_set_vf_rxmode(res->port_id, res->vf_id,
rx_mode, (uint8_t)is_on);
#endif
+
+ RTE_SET_USED(is_on);
+
if (ret < 0)
printf("bad VF receive mode parameter, return code = %d \n",
ret);
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -3197,6 +3197,10 @@ set_vf_rate_limit(portid_t port_id, uint16_t vf,
uint16_t rate, uint64_t q_msk)
if (diag == 0)
return diag;
+ RTE_SET_USED(vf);
+ RTE_SET_USED(rate);
+ RTE_SET_USED(q_msk);
+
printf("set_vf_rate_limit for port_id=%d failed diag=%d\n",
port_id, diag);
return diag;
>
> Signed-off-by: Aviad Yehezkel <aviadye@mellanox.com>
> Signed-off-by: Nicolai Radu <radu.nicolai@intel.com>
<...>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [dpdk-dev] [PATCH v2] app/testpmd: compile without ixgbe and bnxt pmds
2017-10-19 18:53 [dpdk-dev] [PATCH] app/testpmd: compile even if ixgbe anf bnxt pmds are not compiling aviadye
2017-10-23 22:32 ` Ferruh Yigit
@ 2017-10-24 14:48 ` aviadye
2017-10-24 18:31 ` Ferruh Yigit
1 sibling, 1 reply; 5+ messages in thread
From: aviadye @ 2017-10-24 14:48 UTC (permalink / raw)
To: jingjing.wu, dev, aviadye; +Cc: borisp, aviadye, liranl, thomas
From: Aviad Yehezkel <aviadye@mellanox.com>
Signed-off-by: Aviad Yehezkel <aviadye@mellanox.com>
--
v2:
* Address feedbacks.
Signed-off-by: Aviad Yehezkel <aviadye@mellanox.com>
---
app/test-pmd/cmdline.c | 2 ++
app/test-pmd/config.c | 4 ++++
2 files changed, 6 insertions(+)
diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index 1159a4a..1eefb04 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -7494,6 +7494,8 @@ cmd_set_vf_rxmode_parsed(void *parsed_result,
rx_mode |= ETH_VMDQ_ACCEPT_MULTICAST;
}
+ RTE_SET_USED(is_on);
+
#ifdef RTE_LIBRTE_IXGBE_PMD
if (ret == -ENOTSUP)
ret = rte_pmd_ixgbe_set_vf_rxmode(res->port_id, res->vf_id,
diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index bafe76c..3117cb1 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -3185,6 +3185,10 @@ set_vf_rate_limit(portid_t port_id, uint16_t vf, uint16_t rate, uint64_t q_msk)
{
int diag = -ENOTSUP;
+ RTE_SET_USED(vf);
+ RTE_SET_USED(rate);
+ RTE_SET_USED(q_msk);
+
#ifdef RTE_LIBRTE_IXGBE_PMD
if (diag == -ENOTSUP)
diag = rte_pmd_ixgbe_set_vf_rate_limit(port_id, vf, rate,
--
2.7.4
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [dpdk-dev] [PATCH v2] app/testpmd: compile without ixgbe and bnxt pmds
2017-10-24 14:48 ` [dpdk-dev] [PATCH v2] app/testpmd: compile without ixgbe and bnxt pmds aviadye
@ 2017-10-24 18:31 ` Ferruh Yigit
2017-10-24 18:46 ` Ferruh Yigit
0 siblings, 1 reply; 5+ messages in thread
From: Ferruh Yigit @ 2017-10-24 18:31 UTC (permalink / raw)
To: aviadye, jingjing.wu, dev, aviadye; +Cc: borisp, liranl, thomas
On 10/24/2017 7:48 AM, aviadye@dev.mellanox.co.il wrote:
> From: Aviad Yehezkel <aviadye@mellanox.com>
>
> Signed-off-by: Aviad Yehezkel <aviadye@mellanox.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [dpdk-dev] [PATCH v2] app/testpmd: compile without ixgbe and bnxt pmds
2017-10-24 18:31 ` Ferruh Yigit
@ 2017-10-24 18:46 ` Ferruh Yigit
0 siblings, 0 replies; 5+ messages in thread
From: Ferruh Yigit @ 2017-10-24 18:46 UTC (permalink / raw)
To: aviadye, jingjing.wu, dev, aviadye; +Cc: borisp, liranl, thomas
On 10/24/2017 11:31 AM, Ferruh Yigit wrote:
> On 10/24/2017 7:48 AM, aviadye@dev.mellanox.co.il wrote:
>> From: Aviad Yehezkel <aviadye@mellanox.com>
Fixes: 4cfe399f6550 ("net/bnxt: support to set VF rxmode")
Fixes: 36735a932ca7 ("net/bnxt: support set VF QOS and MAC anti spoof")
Cc: stable@dpdk.org
>> Signed-off-by: Aviad Yehezkel <aviadye@mellanox.com>
>
> Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Applied to dpdk-next-net/master, thanks.
Welcom Aviad!
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2017-10-24 18:46 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-19 18:53 [dpdk-dev] [PATCH] app/testpmd: compile even if ixgbe anf bnxt pmds are not compiling aviadye
2017-10-23 22:32 ` Ferruh Yigit
2017-10-24 14:48 ` [dpdk-dev] [PATCH v2] app/testpmd: compile without ixgbe and bnxt pmds aviadye
2017-10-24 18:31 ` Ferruh Yigit
2017-10-24 18:46 ` Ferruh Yigit
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).