* [dpdk-dev] [PATCH] event/opdl: fix ICC fails at compile time
@ 2018-01-25 7:03 Zhiyong Yang
2018-01-25 11:03 ` Liang, Ma
0 siblings, 1 reply; 3+ messages in thread
From: Zhiyong Yang @ 2018-01-25 7:03 UTC (permalink / raw)
To: dev; +Cc: liang.j.ma, peter.mccarthy, ferruh.yigit, Zhiyong Yang
ICC reports the issue at compile time as follows.
error #592: variable "i" is used before its value is set
RTE_SET_USED(i);
The patch is to fix it. GCC and CLANG has been tested as well.
Fixes: d548ef513cd7 ("event/opdl: add unit tests")
Cc: liang.j.ma@intel.com
Cc: peter.mccarthy@intel.com
Cc: ferruh.yigit@intel.com
Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
---
drivers/event/opdl/opdl_test.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/event/opdl/opdl_test.c b/drivers/event/opdl/opdl_test.c
index 13d4f6b45..39c6cf8cf 100644
--- a/drivers/event/opdl/opdl_test.c
+++ b/drivers/event/opdl/opdl_test.c
@@ -562,7 +562,6 @@ single_link_w_stats(struct test *t)
uint32_t deq_pkts;
struct rte_mbuf *mbufs[3];
RTE_SET_USED(mbufs);
- RTE_SET_USED(i);
/* Create instance with 3 ports */
if (init(t, 2, tx_port + 1) < 0 ||
@@ -702,10 +701,8 @@ single_link(struct test *t)
/* const uint8_t w3_port = 3; */
const uint8_t tx_port = 2;
int err;
- int i;
struct rte_mbuf *mbufs[3];
RTE_SET_USED(mbufs);
- RTE_SET_USED(i);
/* Create instance with 5 ports */
if (init(t, 2, tx_port+1) < 0 ||
--
2.13.3
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] event/opdl: fix ICC fails at compile time
2018-01-25 7:03 [dpdk-dev] [PATCH] event/opdl: fix ICC fails at compile time Zhiyong Yang
@ 2018-01-25 11:03 ` Liang, Ma
2018-01-25 16:15 ` Thomas Monjalon
0 siblings, 1 reply; 3+ messages in thread
From: Liang, Ma @ 2018-01-25 11:03 UTC (permalink / raw)
To: Zhiyong Yang; +Cc: dev, peter.mccarthy, ferruh.yigit
On 25 Jan 15:03, Zhiyong Yang wrote:
> ICC reports the issue at compile time as follows.
> error #592: variable "i" is used before its value is set
> RTE_SET_USED(i);
>
> The patch is to fix it. GCC and CLANG has been tested as well.
>
> Fixes: d548ef513cd7 ("event/opdl: add unit tests")
> Cc: liang.j.ma@intel.com
> Cc: peter.mccarthy@intel.com
> Cc: ferruh.yigit@intel.com
>
> Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
> ---
> drivers/event/opdl/opdl_test.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/event/opdl/opdl_test.c b/drivers/event/opdl/opdl_test.c
> index 13d4f6b45..39c6cf8cf 100644
> --- a/drivers/event/opdl/opdl_test.c
> +++ b/drivers/event/opdl/opdl_test.c
> @@ -562,7 +562,6 @@ single_link_w_stats(struct test *t)
> uint32_t deq_pkts;
> struct rte_mbuf *mbufs[3];
> RTE_SET_USED(mbufs);
> - RTE_SET_USED(i);
>
> /* Create instance with 3 ports */
> if (init(t, 2, tx_port + 1) < 0 ||
> @@ -702,10 +701,8 @@ single_link(struct test *t)
> /* const uint8_t w3_port = 3; */
> const uint8_t tx_port = 2;
> int err;
> - int i;
> struct rte_mbuf *mbufs[3];
> RTE_SET_USED(mbufs);
> - RTE_SET_USED(i);
>
> /* Create instance with 5 ports */
> if (init(t, 2, tx_port+1) < 0 ||
> --
> 2.13.3
>
Many thanks Zhi Yong.
Acked-by: Liang Ma <liang.j.ma@intel.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] event/opdl: fix ICC fails at compile time
2018-01-25 11:03 ` Liang, Ma
@ 2018-01-25 16:15 ` Thomas Monjalon
0 siblings, 0 replies; 3+ messages in thread
From: Thomas Monjalon @ 2018-01-25 16:15 UTC (permalink / raw)
To: Zhiyong Yang; +Cc: dev, Liang, Ma, peter.mccarthy, ferruh.yigit
25/01/2018 12:03, Liang, Ma:
> On 25 Jan 15:03, Zhiyong Yang wrote:
> > ICC reports the issue at compile time as follows.
> > error #592: variable "i" is used before its value is set
> > RTE_SET_USED(i);
> >
> > The patch is to fix it. GCC and CLANG has been tested as well.
> >
> > Fixes: d548ef513cd7 ("event/opdl: add unit tests")
> > Cc: liang.j.ma@intel.com
> > Cc: peter.mccarthy@intel.com
> > Cc: ferruh.yigit@intel.com
> >
> > Signed-off-by: Zhiyong Yang <zhiyong.yang@intel.com>
> > ---
> Many thanks Zhi Yong.
>
> Acked-by: Liang Ma <liang.j.ma@intel.com>
Applied, thanks
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-01-25 16:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-25 7:03 [dpdk-dev] [PATCH] event/opdl: fix ICC fails at compile time Zhiyong Yang
2018-01-25 11:03 ` Liang, Ma
2018-01-25 16:15 ` Thomas Monjalon
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).