Bug 342 reported distributor_autotest execution suspension on aarch64 platform. Issue was due to lack of synchronization among threads. Distributor thread and worker thread may get deadlocked. Fixed synchronization issue by adding barriers.
Another issue identified was in test case. Non-atomic operation on stat value could cause value reset not been observed by worker thread and mess counters. The issue was fixed by using atomic operations. --- v3: Added comments for using of C11 acquire/release semantics. (Honnappa) v2: Fixed intermittent packet count incorrect failure. (Aaron, David) Fixed Clang build on 32bit systems. Additional patch to fix non-atomic operation in unit test. Ruifeng Wang (2): lib/distributor: fix deadlock issue for aarch64 test/distributor: fix false unit test failure app/test/test_distributor.c | 6 +- lib/librte_distributor/meson.build | 5 ++ lib/librte_distributor/rte_distributor.c | 68 ++++++++++++++------ lib/librte_distributor/rte_distributor_v20.c | 59 ++++++++++++----- 4 files changed, 101 insertions(+), 37 deletions(-) -- 2.17.1