vbdev_delay: fix wrong usage of spdk_for_each_channel()
We can't call spdk_io_channel_iter_get_channel() in the completion callback of spdk_for_each_channel(), the value is always NULL. Change-Id: I65bc972da8a7ab309f3cab438432196a59f26bd4 Signed-off-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/9983 Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Dong Yi <dongx.yi@intel.com> Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
534e2e7c04
commit
9024562463
@ -304,8 +304,8 @@ static void
|
||||
vbdev_delay_reset_dev(struct spdk_io_channel_iter *i, int status)
|
||||
{
|
||||
struct spdk_bdev_io *bdev_io = spdk_io_channel_iter_get_ctx(i);
|
||||
struct spdk_io_channel *ch = spdk_io_channel_iter_get_channel(i);
|
||||
struct delay_io_channel *delay_ch = spdk_io_channel_get_ctx(ch);
|
||||
struct delay_bdev_io *io_ctx = (struct delay_bdev_io *)bdev_io->driver_ctx;
|
||||
struct delay_io_channel *delay_ch = spdk_io_channel_get_ctx(io_ctx->ch);
|
||||
struct vbdev_delay *delay_node = spdk_io_channel_iter_get_io_device(i);
|
||||
int rc;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user