From 6c9b7d0896314b5423d68acb850c089a5fc1b5e8 Mon Sep 17 00:00:00 2001 From: Liu Xiaodong Date: Thu, 22 Apr 2021 08:02:28 -0400 Subject: [PATCH] reactor: call callback if no need to set intr When do spdk_reactor_set_interrupt_mode, if reactor already runs in the specific mode, directly call callback function before return 0; Change-Id: I1fd8b753e9881755aa128aabe6d1e2749e58b39b Signed-off-by: Liu Xiaodong Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7549 Community-CI: Mellanox Build Bot Reviewed-by: Changpeng Liu Reviewed-by: Reviewed-by: Tomasz Zawadzki Tested-by: SPDK CI Jenkins --- lib/event/reactor.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/event/reactor.c b/lib/event/reactor.c index b175e7529..4b058ab32 100644 --- a/lib/event/reactor.c +++ b/lib/event/reactor.c @@ -443,6 +443,7 @@ spdk_reactor_set_interrupt_mode(uint32_t lcore, bool new_in_interrupt, } if (target->in_interrupt == new_in_interrupt) { + cb_fn(cb_arg); return 0; }