Commit 3690dbbd authored by Liu Xiaodong's avatar Liu Xiaodong Committed by Tomasz Zawadzki
Browse files

thread: remove redundant set_thread in intr



thread_interrupt_msg_process is registered to thread's
fd_group, so it will be called inside spdk_thread_poll.
Since spdk_thread_poll will set/restore tls_thread,
there is no need to set or restore it again here.

Change-Id: Ida10c736ef904ff975eeb42fd0cccad9fd8317cf
Signed-off-by: default avatarLiu Xiaodong <xiaodong.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/6720


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
parent ba7aac83
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -1861,15 +1861,11 @@ static int
thread_interrupt_msg_process(void *arg)
{
	struct spdk_thread *thread = arg;
	struct spdk_thread *orig_thread;
	uint32_t msg_count;
	spdk_msg_fn critical_msg;
	int rc = 0;
	uint64_t now = spdk_get_ticks();

	orig_thread = _get_thread();
	tls_thread = thread;

	critical_msg = thread->critical_msg;
	if (spdk_unlikely(critical_msg != NULL)) {
		critical_msg(NULL);
@@ -1883,8 +1879,6 @@ thread_interrupt_msg_process(void *arg)

	thread_update_stats(thread, spdk_get_ticks(), now, rc);

	tls_thread = orig_thread;

	return rc;
}