diff --git a/app/nvmf_tgt/nvmf_tgt.c b/app/nvmf_tgt/nvmf_tgt.c index e593df008..298f9d9c7 100644 --- a/app/nvmf_tgt/nvmf_tgt.c +++ b/app/nvmf_tgt/nvmf_tgt.c @@ -208,7 +208,7 @@ _nvmf_tgt_start_subsystem(void *arg1, void *arg2) void nvmf_tgt_start_subsystem(struct nvmf_tgt_subsystem *app_subsys) { - spdk_event_t event; + struct spdk_event *event; event = spdk_event_allocate(app_subsys->lcore, _nvmf_tgt_start_subsystem, app_subsys, NULL, NULL); diff --git a/include/spdk/event.h b/include/spdk/event.h index 5972db60f..8d61a77fc 100644 --- a/include/spdk/event.h +++ b/include/spdk/event.h @@ -80,7 +80,6 @@ #include "spdk/queue.h" -typedef struct spdk_event *spdk_event_t; typedef void (*spdk_event_fn)(void *arg1, void *arg2); /** @@ -199,14 +198,14 @@ uint32_t spdk_app_get_current_core(void); /** * \brief Allocate an event to be passed to \ref spdk_event_call */ -spdk_event_t spdk_event_allocate(uint32_t lcore, spdk_event_fn fn, - void *arg1, void *arg2, - spdk_event_t next); +struct spdk_event *spdk_event_allocate(uint32_t lcore, spdk_event_fn fn, + void *arg1, void *arg2, + struct spdk_event *next); /** * \brief Pass the given event to the associated lcore and call the function. */ -void spdk_event_call(spdk_event_t event); +void spdk_event_call(struct spdk_event *event); /* TODO: This is only used by tests and should be made private */ uint32_t spdk_event_queue_run_batch(uint32_t lcore); diff --git a/include/spdk/scsi.h b/include/spdk/scsi.h index 3cfa02b11..a26ec1744 100644 --- a/include/spdk/scsi.h +++ b/include/spdk/scsi.h @@ -104,7 +104,7 @@ struct spdk_scsi_task { struct spdk_io_channel *ch; struct spdk_scsi_port *target_port; struct spdk_scsi_port *initiator_port; - spdk_event_t cb_event; + struct spdk_event *cb_event; uint32_t ref; uint32_t id; diff --git a/lib/bdev/bdev.c b/lib/bdev/bdev.c index 237ea8c80..e595005a6 100644 --- a/lib/bdev/bdev.c +++ b/lib/bdev/bdev.c @@ -409,7 +409,7 @@ spdk_bdev_cleanup_pending_rbuf_io(struct spdk_bdev *bdev) } static void -__submit_request(struct spdk_bdev *bdev, struct spdk_bdev_io *bdev_io, spdk_event_t cb_event) +__submit_request(struct spdk_bdev *bdev, struct spdk_bdev_io *bdev_io, struct spdk_event *cb_event) { bdev_io->cb_event = cb_event; diff --git a/lib/event/app.c b/lib/event/app.c index a2eb7e712..2c0900222 100644 --- a/lib/event/app.c +++ b/lib/event/app.c @@ -74,7 +74,7 @@ struct spdk_app { }; static struct spdk_app g_spdk_app; -static spdk_event_t g_shutdown_event = NULL; +static struct spdk_event *g_shutdown_event = NULL; static int spdk_app_write_pidfile(void); static void spdk_app_remove_pidfile(void); @@ -429,7 +429,7 @@ spdk_app_fini(void) int spdk_app_start(spdk_event_fn start_fn, void *arg1, void *arg2) { - spdk_event_t event; + struct spdk_event *event; g_spdk_app.rc = 0; diff --git a/lib/event/reactor.c b/lib/event/reactor.c index ab2ff136c..6d7c1680d 100644 --- a/lib/event/reactor.c +++ b/lib/event/reactor.c @@ -139,9 +139,9 @@ spdk_reactor_get(uint32_t lcore) return reactor; } -spdk_event_t +struct spdk_event * spdk_event_allocate(uint32_t lcore, spdk_event_fn fn, void *arg1, void *arg2, - spdk_event_t next) + struct spdk_event *next) { struct spdk_event *event = NULL; unsigned socket_id = rte_lcore_to_socket_id(lcore); @@ -164,7 +164,7 @@ spdk_event_allocate(uint32_t lcore, spdk_event_fn fn, void *arg1, void *arg2, } void -spdk_event_call(spdk_event_t event) +spdk_event_call(struct spdk_event *event) { int rc; struct spdk_reactor *reactor; diff --git a/test/lib/bdev/bdevio/bdevio.c b/test/lib/bdev/bdevio/bdevio.c index b1f1fb21c..748b7cf58 100644 --- a/test/lib/bdev/bdevio/bdevio.c +++ b/test/lib/bdev/bdevio/bdevio.c @@ -185,7 +185,7 @@ blockdev_write(struct io_target *target, char *tx_buf, uint64_t offset, int data_len, int iov_len) { struct bdevio_request req; - spdk_event_t event; + struct spdk_event *event; req.target = target; req.buf = tx_buf; @@ -231,7 +231,7 @@ blockdev_read(struct io_target *target, char *rx_buf, uint64_t offset, int data_len, int iov_len) { struct bdevio_request req; - spdk_event_t event; + struct spdk_event *event; req.target = target; req.buf = rx_buf; @@ -641,7 +641,7 @@ static void blockdev_reset(struct io_target *target, enum spdk_bdev_reset_type reset_type) { struct bdevio_request req; - spdk_event_t event; + struct spdk_event *event; req.target = target; diff --git a/test/lib/bdev/bdevperf/bdevperf.c b/test/lib/bdev/bdevperf/bdevperf.c index 2f5767c16..b6e534547 100644 --- a/test/lib/bdev/bdevperf/bdevperf.c +++ b/test/lib/bdev/bdevperf/bdevperf.c @@ -185,7 +185,7 @@ bdevperf_complete(void *arg1, void *arg2) struct io_target *target; struct bdevperf_task *task = arg1; struct spdk_bdev_io *bdev_io = arg2; - spdk_event_t complete; + struct spdk_event *complete; target = task->target; @@ -485,7 +485,7 @@ bdevperf_run(void *arg1, void *arg2) { int i; struct io_target *target; - spdk_event_t event; + struct spdk_event *event; printf("Running I/O for %d seconds...\n", g_time_in_sec); fflush(stdout); diff --git a/test/lib/iscsi/common.c b/test/lib/iscsi/common.c index 2c47620c2..ca26a03af 100644 --- a/test/lib/iscsi/common.c +++ b/test/lib/iscsi/common.c @@ -92,8 +92,9 @@ spdk_app_get_current_core(void) return 0; } -spdk_event_t -spdk_event_allocate(uint32_t core, spdk_event_fn fn, void *arg1, void *arg2, spdk_event_t next) +struct spdk_event * +spdk_event_allocate(uint32_t core, spdk_event_fn fn, void *arg1, void *arg2, + struct spdk_event *next) { return NULL; } diff --git a/test/lib/scsi/lun/lun_ut.c b/test/lib/scsi/lun/lun_ut.c index e8c393860..dd78dd2f7 100644 --- a/test/lib/scsi/lun/lun_ut.c +++ b/test/lib/scsi/lun/lun_ut.c @@ -161,7 +161,7 @@ spdk_put_io_channel(struct spdk_io_channel *ch) { } -void spdk_event_call(spdk_event_t event) +void spdk_event_call(struct spdk_event *event) { }