[RFC,3/5] examples/bond: use lcore accessor
Checks
Commit Message
Refering to lcore_config directly is no longer recommended.
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
examples/bond/main.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
@@ -526,8 +526,8 @@ static void cmd_start_parsed(__attribute__((unused)) void *parsed_result,
int slave_core_id = rte_lcore_id();
rte_spinlock_trylock(&global_flag_stru_p->lock);
- if (global_flag_stru_p->LcoreMainIsRunning == 0) {
- if (lcore_config[global_flag_stru_p->LcoreMainCore].state != WAIT) {
+ if (global_flag_stru_p->LcoreMainIsRunning == 0) {
+ if (rte_lcore_state(global_flag_stru_p->LcoreMainCore) != WAIT) {
rte_spinlock_unlock(&global_flag_stru_p->lock);
return;
}