aboutsummaryrefslogtreecommitdiff
path: root/platform/linux-generic/include/odp_traffic_mngr_internal.h
diff options
context:
space:
mode:
authorJere Leppänen <jere.leppanen@nokia.com>2024-03-05 12:22:27 +0200
committerMatias Elo <matias.elo@nokia.com>2024-03-28 11:01:25 +0200
commitda0d1cf171dee3e05fd65fa3545838600bd8b44b (patch)
tree3672206614aeb79d14a7aa4cfff385fadc0f045f /platform/linux-generic/include/odp_traffic_mngr_internal.h
parenta24edf35082d7df6c7eb47e81f2ea3cc7229ea8d (diff)
linux-gen: tm: make is_idle atomic
Change the type of tm_system_s.is_idle to odp_atomic_u32_t in order to avoid a data race reported by GCC thread sanitizer. Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
Diffstat (limited to 'platform/linux-generic/include/odp_traffic_mngr_internal.h')
-rw-r--r--platform/linux-generic/include/odp_traffic_mngr_internal.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/linux-generic/include/odp_traffic_mngr_internal.h b/platform/linux-generic/include/odp_traffic_mngr_internal.h
index 8b666184b..960756340 100644
--- a/platform/linux-generic/include/odp_traffic_mngr_internal.h
+++ b/platform/linux-generic/include/odp_traffic_mngr_internal.h
@@ -404,7 +404,7 @@ struct tm_system_s {
uint64_t current_time;
uint8_t tm_idx;
uint8_t first_enq;
- odp_bool_t is_idle;
+ odp_atomic_u32_t is_idle;
tm_status_t status;
uint64_t shaper_green_cnt;