examples/accel_perf: move some code around in prep for batching

First in a series of patches to change how batching is implemented.

Signed-off-by: paul luse <paul.e.luse@intel.com>
Change-Id: Iaee780cd948beee66a37528fdad6fc6841ea642b
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/5486
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
This commit is contained in:
paul luse 2020-12-08 11:32:49 -05:00 committed by Tomasz Zawadzki
parent 2e26faa975
commit cdefd3d3f8

View File

@ -60,7 +60,19 @@ static struct worker_thread *g_workers = NULL;
static int g_num_workers = 0;
static pthread_mutex_t g_workers_lock = PTHREAD_MUTEX_INITIALIZER;
uint64_t g_capabilites;
struct ap_task;
struct worker_thread;
static void accel_done(void *ref, int status);
struct ap_task {
void *src;
void *dst;
void *dst2;
struct worker_thread *worker;
int status;
int expected_status; /* used for the compare operation */
TAILQ_ENTRY(ap_task) link;
};
struct worker_thread {
struct spdk_io_channel *ch;
@ -77,16 +89,6 @@ struct worker_thread {
struct spdk_poller *stop_poller;
};
struct ap_task {
void *src;
void *dst;
void *dst2;
struct worker_thread *worker;
int status;
int expected_status; /* used for compare */
TAILQ_ENTRY(ap_task) link;
};
static void
dump_user_config(struct spdk_app_opts *opts)
{