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

bdev/nvme: Add nvme_ch parameter to bdev_nvme_flush()



bdev_nvme_flush() just completes with success now and uses only
bio parameter now, but matching parameters with other similar I/O
APIs will be good for future enhancement and following patches.

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


Community-CI: Broadcom CI
Community-CI: Mellanox Build Bot
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarAleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
parent 1a8c6c4d
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -295,8 +295,8 @@ bdev_nvme_destruct(void *ctx)
}

static int
bdev_nvme_flush(struct nvme_bdev_ns *nvme_ns, struct nvme_bdev_io *bio,
		uint64_t offset, uint64_t nbytes)
bdev_nvme_flush(struct nvme_bdev_ns *nvme_ns, struct nvme_io_channel *nvme_ch,
		struct nvme_bdev_io *bio, uint64_t offset, uint64_t nbytes)
{
	spdk_bdev_io_complete(spdk_bdev_io_from_ctx(bio), SPDK_BDEV_IO_STATUS_SUCCESS);

@@ -701,6 +701,7 @@ _bdev_nvme_submit_request(struct spdk_io_channel *ch, struct spdk_bdev_io *bdev_

	case SPDK_BDEV_IO_TYPE_FLUSH:
		return bdev_nvme_flush(nbdev->nvme_ns,
				       nvme_ch,
				       nbdev_io,
				       bdev_io->u.bdev.offset_blocks,
				       bdev_io->u.bdev.num_blocks);