mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-23 05:56:14 -04:00
nvmet: Introduce nvmet_dsm_len() helper
Similar to the nvmet_rw_len helper. Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com> Signed-off-by: Christoph Hellwig <hch@lst.de> [split patch, update changelog] Signed-off-by: Logan Gunthorpe <logang@deltatee.com> Signed-off-by: Keith Busch <kbusch@kernel.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
committed by
Jens Axboe
parent
6f86f2c9d9
commit
59ef0eaa77
@@ -379,8 +379,7 @@ u16 nvmet_file_parse_io_cmd(struct nvmet_req *req)
|
||||
return 0;
|
||||
case nvme_cmd_dsm:
|
||||
req->execute = nvmet_file_execute_dsm;
|
||||
req->data_len = (le32_to_cpu(cmd->dsm.nr) + 1) *
|
||||
sizeof(struct nvme_dsm_range);
|
||||
req->data_len = nvmet_dsm_len(req);
|
||||
return 0;
|
||||
case nvme_cmd_write_zeroes:
|
||||
req->execute = nvmet_file_execute_write_zeroes;
|
||||
|
||||
Reference in New Issue
Block a user