diff options
author | Florin Coras <fcoras@cisco.com> | 2024-07-02 01:38:47 -0700 |
---|---|---|
committer | Dave Barach <vpp@barachs.net> | 2024-07-08 13:44:06 +0000 |
commit | 6df9f442277603d3ebd3bcf950f7dd0d28fb42f5 (patch) | |
tree | 23c48470a281c3034d1e92273a673c5a63a3e185 /src/vnet/session | |
parent | e3469369dabd2683c3ca8a7cdd3b04a67a2cecb9 (diff) |
session: handle multiple attempts to mark mq congested
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Iadc6ec58f5fc7fbff62e4fd31d509557b60395cb
Diffstat (limited to 'src/vnet/session')
-rw-r--r-- | src/vnet/session/application_worker.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/vnet/session/application_worker.c b/src/vnet/session/application_worker.c index befdb7c7002..43007ad76ed 100644 --- a/src/vnet/session/application_worker.c +++ b/src/vnet/session/application_worker.c @@ -836,9 +836,12 @@ app_worker_mq_wrk_is_congested (app_worker_t *app_wrk, u32 thread_index) void app_worker_set_mq_wrk_congested (app_worker_t *app_wrk, u32 thread_index) { - clib_atomic_fetch_add_relax (&app_wrk->mq_congested, 1); ASSERT (thread_index == vlib_get_thread_index ()); - app_wrk->wrk_mq_congested[thread_index] = 1; + if (!app_wrk->wrk_mq_congested[thread_index]) + { + clib_atomic_fetch_add_relax (&app_wrk->mq_congested, 1); + app_wrk->wrk_mq_congested[thread_index] = 1; + } } void |