examples/qos_sched: fix build for less lcores
authorHemant Agrawal <hemant.agrawal@nxp.com>
Wed, 19 Jul 2017 08:13:10 +0000 (13:43 +0530)
committerThomas Monjalon <thomas@monjalon.net>
Fri, 21 Jul 2017 14:36:29 +0000 (17:36 +0300)
commite481ebfd622c23a1d854cb4655a3534d68d322af
tree67fbef37986a3ed2e33e484583f01bfacc4cb6ae
parentaf35e12191f5817c38b37b0ea1142bcd19e30c74
examples/qos_sched: fix build for less lcores

APP_MAX_LCORES is hardcoded as 64.
This will cause build err when RTE_MAX_LCORE is less then 64.

"args.c:127:22: error: iteration 8 invokes undefined behavior
[-Werror=aggressive-loop-optimizations]
   if (cfg->lcore_role[i] == ROLE_RTE)
       ~~~~~~~~~~~~~~~^~~
args.c:126:2: note: within this loop
  for (i = 0; i < APP_MAX_LCORE; i++) {"

Fixes: d52b5e735aa3 ("examples/qos_sched: fix lcore limit")
Cc: stable@dpdk.org
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
examples/qos_sched/main.h