[dm-devel] [PATCH 6/7] nvme: add simple copy support

2021-08-17 Thread SelvaKumar S
copy limits to queue limits. By default copy_offload is disabled. End-to-end protection is done by setting both PRINFOR and PRINFOW to 0. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi Signed-off-by: Nitesh Shetty Signed-off-by: Javier González --- drivers/nv

[dm-devel] [PATCH 1/7] block: make bio_map_kern() non static

2021-08-17 Thread SelvaKumar S
Make bio_map_kern() non static, so that copy offload/emulation can use it to add vmalloced memory to bio. Signed-off-by: SelvaKumar S Signed-off-by: Nitesh Shetty --- block/blk-map.c| 2 +- include/linux/blkdev.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a

[dm-devel] [PATCH 4/7] block: Introduce a new ioctl for simple copy

2021-08-17 Thread SelvaKumar S
rn ret; } Signed-off-by: Nitesh Shetty Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi --- block/ioctl.c | 33 + include/uapi/linux/fs.h | 8 2 files changed, 41 insertions(+) diff --git a/block/ioctl.c b/block/ioctl.c index eb049

[dm-devel] [PATCH 0/7] add simple copy support

2021-08-17 Thread SelvaKumar S
copy-offload support block: copy offload support infrastructure block: Introduce a new ioctl for simple copy block: add emulation for simple copy SelvaKumar S (3): block: make bio_map_kern() non static nvme: add simple copy support dm kcopyd: add simple copy offload support block/blk-

[dm-devel] [PATCH 5/7] block: add emulation for simple copy

2021-08-17 Thread SelvaKumar S
bio->bi_private and bio->bi_end_io are needed for chaining the bio and gets over-written, invalidate_kernel_vmap_range() for read is called in the caller. Signed-off-by: Nitesh Shetty Signed-off-by: SelvaKumar S --- block/blk-lib.c | 100

[dm-devel] [PATCH 3/7] block: copy offload support infrastructure

2021-08-17 Thread SelvaKumar S
submitted to zoned device. Native copy offload is not supported for stacked devices. Signed-off-by: Nitesh Shetty Signed-off-by: SelvaKumar S --- block/blk-core.c | 84 - block/blk-lib.c | 252 ++ block/blk-zoned.c | 1

[dm-devel] [PATCH 2/7] block: Introduce queue limits for copy-offload support

2021-08-17 Thread SelvaKumar S
-offload needs to be used. max_copy_sectors = 0, indicates the device doesn't support native copy. Signed-off-by: Nitesh Shetty Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi --- block/blk-settings.c | 4 block/blk-sysfs.c

[dm-devel] [PATCH 7/7] dm kcopyd: add simple copy offload support

2021-08-17 Thread SelvaKumar S
copied count is made zero, failed regions are processed via existing method. Signed-off-by: SelvaKumar S Signed-off-by: Nitesh Shetty --- drivers/md/dm-kcopyd.c | 56 +- 1 file changed, 50 insertions(+), 6 deletions(-) diff --git a/drivers/md/dm-kcopyd.c b

[dm-devel] [RFC PATCH v5 3/4] nvme: add simple copy support

2021-02-19 Thread SelvaKumar S
copy limits to queue limits. By default copy_offload is disabled. End-to-end protection is done by setting both PRINFOR and PRINFOW to 0. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi Signed-off-by: Nitesh Shetty Signed-off-by: Javier González --- drivers/n

[dm-devel] [RFC PATCH v5 4/4] dm kcopyd: add simple copy offload support

2021-02-19 Thread SelvaKumar S
queued for completion. If multiple destinations were present, the completed destination is zeroed and pushed to pages_jobs to process copy offload for other destinations. In case of copy_offload failure, remaining destinations are processed via regular copying mechanism. Signed-off-by: SelvaKumar S

[dm-devel] [RFC PATCH v5 2/4] block: add simple copy support

2021-02-19 Thread SelvaKumar S
orted for stacked devices and is done via copy emulation. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi Signed-off-by: Nitesh Shetty Signed-off-by: Javier González Signed-off-by: Chaitanya Kulkarni --- block/blk-core.c | 102 -- block/blk-lib.c | 222

[dm-devel] [RFC PATCH v5 0/4] add simple copy support

2021-02-19 Thread SelvaKumar S
me_config_copy 10. Remove return in QUEUE_FLAG_COPY check 11. Remove unused OCFS SelvaKumar S (4): block: make bio_map_kern() non static block: add simple copy support nvme: add simple copy support dm kcopyd: add simple copy offload support block/blk-core.c | 102

[dm-devel] [RFC PATCH v5 1/4] block: make bio_map_kern() non static

2021-02-19 Thread SelvaKumar S
Make bio_map_kern() non static, so that copy offload emulation can use it to add vmalloced memory to bio. Signed-off-by: SelvaKumar S Signed-off-by: Chaitanya Kulkarni --- block/blk-map.c| 2 +- include/linux/blkdev.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git

[dm-devel] [RFC PATCH v4 2/3] block: add simple copy support

2021-01-04 Thread SelvaKumar S
. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi Signed-off-by: Nitesh Shetty Signed-off-by: Javier González --- block/blk-core.c | 94 ++-- block/blk-lib.c | 223 ++ block/blk-merge.c | 2 + block/blk-setti

[dm-devel] [RFC PATCH v4 3/3] nvme: add simple copy support

2021-01-04 Thread SelvaKumar S
copy limits to queue limits. By default copy_offload is disabled. End-to-end protection is done by setting both PRINFOR and PRINFOW to 0. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi Signed-off-by: Nitesh Shetty Signed-off-by: Javier González --- drivers/n

[dm-devel] [RFC PATCH v4 1/3] block: export bio_map_kern()

2021-01-04 Thread SelvaKumar S
Export bio_map_kern() so that copy offload emulation can use it to add vmalloced memory to bio. Signed-off-by: SelvaKumar S --- block/blk-map.c| 3 ++- include/linux/blkdev.h | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/block/blk-map.c b/block/blk-map.c index

[dm-devel] [RFC PATCH v4 0/3] add simple copy support

2021-01-04 Thread SelvaKumar S
de more readable 5. Don't use bio_set_op_attrs and remove op and set bi_opf directly 6. Use struct_size to calculate total_size 7. Fix partition remap of copy destination 8. Remove mcl,mssrl,msrc from nvme_ns 9. Initialize copy queue limits to 0 in nvme_config_copy 10. Remove return in QUEUE

[dm-devel] [RFC PATCH v3 0/2] add simple copy support

2020-12-14 Thread SelvaKumar S
trs and remove op and set bi_opf directly 6. Use struct_size to calculate total_size 7. Fix partition remap of copy destination 8. Remove mcl,mssrl,msrc from nvme_ns 9. Initialize copy queue limits to 0 in nvme_config_copy 10. Remove return in QUEUE_FLAG_COPY check 11. Remove unused OCFS SelvaKu

[dm-devel] [RFC PATCH v3 2/2] nvme: add simple copy support

2020-12-14 Thread SelvaKumar S
Add support for TP 4065a ("Simple Copy Command"), v2020.05.04 ("Ratified") The implementation uses the payload passed from the block layer to form simple copy command. Set the device copy limits to queue limits. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi S

[dm-devel] [RFC PATCH v3 1/2] block: add simple copy support

2020-12-14 Thread SelvaKumar S
fault. max_copy_sectors = 0 indicates the device doesn't support copy. simple copy is not supported for stacked devices. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi Signed-off-by: Nitesh Shetty Signed-off-by: Javier González --- block/blk-core.c | 94 ++--

[dm-devel] [RFC PATCH v2 1/2] block: add simple copy support

2020-12-07 Thread SelvaKumar S
. - max_copy_sectors - max_copy_ranges_sectors - max_copy_nr_ranges max_copy_sectors = 0 indicates the device doesn't support copy. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi Signed-off-by: Nitesh Shetty Signed-off-by: Javier González --- block/blk-c

[dm-devel] [RFC PATCH v2 0/2] add simple copy support

2020-12-07 Thread SelvaKumar S
imits to 0 in nvme_config_copy 10. Remove return in QUEUE_FLAG_COPY check 11. Remove unused OCFS SelvaKumar S (2): block: add simple copy support nvme: add simple copy support block/blk-core.c | 94 ++--- block/blk-lib.c | 123 +++

[dm-devel] [RFC PATCH v2 2/2] nvme: add simple copy support

2020-12-07 Thread SelvaKumar S
Add support for TP 4065a ("Simple Copy Command"), v2020.05.04 ("Ratified") The implementation uses the payload passed from the block layer to form simple copy command. Set the device copy limits to queue limits. Signed-off-by: SelvaKumar S Signed-off-by: Kanchan Joshi S