Commit 43d78672 authored by Shuhei Matsumoto's avatar Shuhei Matsumoto Committed by Tomasz Zawadzki
Browse files

lib/thread: Update comment for spdk_thread_poll about thread exiting



Remove the description "return -1 if thread has exited" and add
the description "If the thread has exited, return immediately" instead.

Signed-off-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: If4b4b565dc7aa1261fa7c3fdfb73cfc814e38d5d
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/478385


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatarPaul Luse <paul.e.luse@intel.com>
parent 876fdf2a
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -272,7 +272,8 @@ struct spdk_thread *spdk_thread_get_from_ctx(void *ctx);

/**
 * Perform one iteration worth of processing on the thread. This includes
 * both expired and continuous pollers as well as messages.
 * both expired and continuous pollers as well as messages. If the thread
 * has exited, return immediately.
 *
 * \param thread The thread to process
 * \param max_msgs The maximum number of messages that will be processed.
@@ -280,7 +281,7 @@ struct spdk_thread *spdk_thread_get_from_ctx(void *ctx);
 * \param now The current time, in ticks. Optional. If 0 is passed, this
 *            function may call spdk_get_ticks() to get the current time.
 *
 * \return 1 if work was done. 0 if no work was done. -1 if thread has exited.
 * \return 1 if work was done. 0 if no work was done.
 */
int spdk_thread_poll(struct spdk_thread *thread, uint32_t max_msgs, uint64_t now);