search for: blk_rq_map_sg

Displaying 20 results from an estimated 111 matches for "blk_rq_map_sg".

2012 Jun 13
2
drivers/block/cpqarray.c:938:2: error: too many arguments to function ‘blk_rq_map_sg’
...odge podge of things config: i386-allmodconfig (attached as .config) All related error/warning messages are: block/blk-core.c: In function ?attempt_plug_merge?: block/blk-core.c:1253:9: error: ?struct request? has no member named ?q? drivers/block/cpqarray.c:938:2: warning: passing argument 1 of ?blk_rq_map_sg? from incompatible pointer type [enabled by default] include/linux/blkdev.h:845:12: note: expected ?struct request *? but argument is of type ?struct request_queue *? drivers/block/cpqarray.c:938:2: warning: passing argument 2 of ?blk_rq_map_sg? from incompatible pointer type [enabled by default] i...
2012 Jun 13
2
drivers/block/cpqarray.c:938:2: error: too many arguments to function ‘blk_rq_map_sg’
...odge podge of things config: i386-allmodconfig (attached as .config) All related error/warning messages are: block/blk-core.c: In function ?attempt_plug_merge?: block/blk-core.c:1253:9: error: ?struct request? has no member named ?q? drivers/block/cpqarray.c:938:2: warning: passing argument 1 of ?blk_rq_map_sg? from incompatible pointer type [enabled by default] include/linux/blkdev.h:845:12: note: expected ?struct request *? but argument is of type ?struct request_queue *? drivers/block/cpqarray.c:938:2: warning: passing argument 2 of ?blk_rq_map_sg? from incompatible pointer type [enabled by default] i...
2018 Jun 07
2
[PATCH v6] virtio_blk: add DISCARD and WRIET ZEROES commands support
...blk_mq_start_request(req); > > > > + if (type == VIRTIO_BLK_T_DISCARD || type == > VIRTIO_BLK_T_WRITE_ZEROES) { > > + err = virtblk_setup_discard_write_zeroes(req, unmap); > > + if (err) > > + return BLK_STS_RESOURCE; > > + } > > + > > num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > if (num) { > > if (rq_data_dir(req) == WRITE) > > ...since we still do blk_rq_map_sg() here and num should be != 0. No, while here, we should keep the original logic for READ/WRITE commands.
2018 Jun 07
2
[PATCH v6] virtio_blk: add DISCARD and WRIET ZEROES commands support
...blk_mq_start_request(req); > > > > + if (type == VIRTIO_BLK_T_DISCARD || type == > VIRTIO_BLK_T_WRITE_ZEROES) { > > + err = virtblk_setup_discard_write_zeroes(req, unmap); > > + if (err) > > + return BLK_STS_RESOURCE; > > + } > > + > > num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > if (num) { > > if (rq_data_dir(req) == WRITE) > > ...since we still do blk_rq_map_sg() here and num should be != 0. No, while here, we should keep the original logic for READ/WRITE commands.
2018 Jun 11
1
[PATCH v6] virtio_blk: add DISCARD and WRIET ZEROES commands support
...LK_T_DISCARD || type == > > > VIRTIO_BLK_T_WRITE_ZEROES) { > > > > + err = virtblk_setup_discard_write_zeroes(req, unmap); > > > > + if (err) > > > > + return BLK_STS_RESOURCE; > > > > + } > > > > + > > > > num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > > > if (num) { > > > > if (rq_data_dir(req) == WRITE) > > > > > > ...since we still do blk_rq_map_sg() here and num should be != 0. > > No, while here, we should keep the original logic for READ/WRITE command...
2012 Jun 13
4
[PATCH RFC 0/2] Improve virtio-blk performance
This patchset implements bio-based IO path for virito-blk to improve performance. Fio test shows it gives, 28%, 24%, 21%, 16% IOPS boost and 32%, 17%, 21%, 16% latency improvement for sequential read/write, random read/write respectively. Asias He (2): block: Add blk_bio_map_sg() helper virtio-blk: Add bio-based IO path for virtio-blk block/blk-merge.c | 63 ++++++++++++++
2012 Jun 13
4
[PATCH RFC 0/2] Improve virtio-blk performance
This patchset implements bio-based IO path for virito-blk to improve performance. Fio test shows it gives, 28%, 24%, 21%, 16% IOPS boost and 32%, 17%, 21%, 16% latency improvement for sequential read/write, random read/write respectively. Asias He (2): block: Add blk_bio_map_sg() helper virtio-blk: Add bio-based IO path for virtio-blk block/blk-merge.c | 63 ++++++++++++++
2008 Nov 14
2
[PATCH RFC] virtio: use QUEUE_FLAG_CLUSTER in virtio_blk
This allows more requests to fit in the descriptor ring. Copying 1.7M kernel image 100 times (with sync between) Before: totsegs = 55661 totlen = 148859962 avg. 2674 After: totsegs = 36097 totlen = 139439355 avg: 3862 Unfortunately, this coalescing is done at blk_rq_map_sg() which is too late to be optimal: requests have already been limited to the value set by blk_queue_max_hw_segments(). For us, that value reflects the number of sg slots we can handle (ie. after clustering). I suspect other drivers have the same issue. Jens? (This patch is a one liner + tempora...
2008 Nov 14
2
[PATCH RFC] virtio: use QUEUE_FLAG_CLUSTER in virtio_blk
This allows more requests to fit in the descriptor ring. Copying 1.7M kernel image 100 times (with sync between) Before: totsegs = 55661 totlen = 148859962 avg. 2674 After: totsegs = 36097 totlen = 139439355 avg: 3862 Unfortunately, this coalescing is done at blk_rq_map_sg() which is too late to be optimal: requests have already been limited to the value set by blk_queue_max_hw_segments(). For us, that value reflects the number of sg slots we can handle (ie. after clustering). I suspect other drivers have the same issue. Jens? (This patch is a one liner + tempora...
2018 Jun 08
0
[PATCH v6] virtio_blk: add DISCARD and WRIET ZEROES commands support
...t; > > + if (type == VIRTIO_BLK_T_DISCARD || type == > > VIRTIO_BLK_T_WRITE_ZEROES) { > > > + err = virtblk_setup_discard_write_zeroes(req, unmap); > > > + if (err) > > > + return BLK_STS_RESOURCE; > > > + } > > > + > > > num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > > if (num) { > > > if (rq_data_dir(req) == WRITE) > > > > ...since we still do blk_rq_map_sg() here and num should be != 0. > No, while here, we should keep the original logic for READ/WRITE commands. My question is: why...
2015 Oct 01
2
req->nr_phys_segments > queue_max_segments (was Re: kernel BUG at drivers/block/virtio_blk.c:172!)
...how may we get more segments than blk_queue_max_segments? > Is driver expected to validate and drop such requests? > Whee! I'm not alone anymore! I have seen similar issues even on non-mq systems; occasionally I'm hitting this bug in drivers/scsi/scsi_lib.c:scsi_init_io() count = blk_rq_map_sg(req->q, req, sdb->table.sgl); BUG_ON(count > sdb->table.nents); There are actually two problems here: The one is that blk_rq_map_sg() requires a table (ie the last argument), but doesn't have any indications on how large the table is. So one needs to check if the returned number o...
2015 Oct 01
2
req->nr_phys_segments > queue_max_segments (was Re: kernel BUG at drivers/block/virtio_blk.c:172!)
...how may we get more segments than blk_queue_max_segments? > Is driver expected to validate and drop such requests? > Whee! I'm not alone anymore! I have seen similar issues even on non-mq systems; occasionally I'm hitting this bug in drivers/scsi/scsi_lib.c:scsi_init_io() count = blk_rq_map_sg(req->q, req, sdb->table.sgl); BUG_ON(count > sdb->table.nents); There are actually two problems here: The one is that blk_rq_map_sg() requires a table (ie the last argument), but doesn't have any indications on how large the table is. So one needs to check if the returned number o...
2017 Mar 28
6
[PATCH] virtio-blk: add DISCARD support to virtio-blk driver
...type); vbr->out_hdr.sector = type ? 0 : cpu_to_virtio64(vblk->vdev, blk_rq_pos(req)); - vbr->out_hdr.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); + vbr->out_hdr.u.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); blk_mq_start_request(req); - num = blk_rq_map_sg(hctx->queue, req, vbr->sg); - if (num) { - if (rq_data_dir(req) == WRITE) - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, VIRTIO_BLK_T_OUT); - else - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, VIRTIO_BLK_T_IN); + if (type == VIRTIO_BLK_T_DISCARD) { + vbr->out_hd...
2017 Mar 28
6
[PATCH] virtio-blk: add DISCARD support to virtio-blk driver
...type); vbr->out_hdr.sector = type ? 0 : cpu_to_virtio64(vblk->vdev, blk_rq_pos(req)); - vbr->out_hdr.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); + vbr->out_hdr.u.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); blk_mq_start_request(req); - num = blk_rq_map_sg(hctx->queue, req, vbr->sg); - if (num) { - if (rq_data_dir(req) == WRITE) - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, VIRTIO_BLK_T_OUT); - else - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, VIRTIO_BLK_T_IN); + if (type == VIRTIO_BLK_T_DISCARD) { + vbr->out_hd...
2017 Mar 28
1
[PATCH] virtio-blk: add DISCARD support to virtio-blk driver
...irtio64(vblk->vdev, blk_rq_pos(req)); > > - vbr->out_hdr.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); > > + vbr->out_hdr.u.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); > > > > blk_mq_start_request(req); > > > > - num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > - if (num) { > > - if (rq_data_dir(req) == WRITE) > > - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, > VIRTIO_BLK_T_OUT); > > - else > > - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, > VIRTIO_BLK_T_...
2017 Mar 28
1
[PATCH] virtio-blk: add DISCARD support to virtio-blk driver
...irtio64(vblk->vdev, blk_rq_pos(req)); > > - vbr->out_hdr.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); > > + vbr->out_hdr.u.ioprio = cpu_to_virtio32(vblk->vdev, req_get_ioprio(req)); > > > > blk_mq_start_request(req); > > > > - num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > - if (num) { > > - if (rq_data_dir(req) == WRITE) > > - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, > VIRTIO_BLK_T_OUT); > > - else > > - vbr->out_hdr.type |= cpu_to_virtio32(vblk->vdev, > VIRTIO_BLK_T_...
2018 May 31
2
[PATCH v4] virtio_blk: add DISCARD and WRIET ZEROES commands support
...t redhat.com; > jasowang at redhat.com; pbonzini at redhat.com; Wang, Wei W > <wei.w.wang at intel.com> > Subject: Re: [PATCH v4] virtio_blk: add DISCARD and WRIET ZEROES commands > support > > On Tue, May 29, 2018 at 09:42:24AM +0800, Changpeng Liu wrote: > > num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > if (num) { > > - if (rq_data_dir(req) == WRITE) > > + if (rq_data_dir(req) == WRITE || type == VIRTIO_BLK_T_DISCARD > || > > + type == VIRTIO_BLK_T_WRITE_ZEROES) > > vbr->out_hdr.type |= cpu_to_virtio32(vblk->...
2018 May 31
2
[PATCH v4] virtio_blk: add DISCARD and WRIET ZEROES commands support
...t redhat.com; > jasowang at redhat.com; pbonzini at redhat.com; Wang, Wei W > <wei.w.wang at intel.com> > Subject: Re: [PATCH v4] virtio_blk: add DISCARD and WRIET ZEROES commands > support > > On Tue, May 29, 2018 at 09:42:24AM +0800, Changpeng Liu wrote: > > num = blk_rq_map_sg(hctx->queue, req, vbr->sg); > > if (num) { > > - if (rq_data_dir(req) == WRITE) > > + if (rq_data_dir(req) == WRITE || type == VIRTIO_BLK_T_DISCARD > || > > + type == VIRTIO_BLK_T_WRITE_ZEROES) > > vbr->out_hdr.type |= cpu_to_virtio32(vblk->...
2012 Jul 13
5
[PATCH V3 0/3] Improve virtio-blk performance
This patchset implements bio-based IO path for virito-blk to improve performance. Fio test shows bio-based IO path gives the following performance improvement: 1) Ramdisk device With bio-based IO path, sequential read/write, random read/write IOPS boost : 28%, 24%, 21%, 16% Latency improvement: 32%, 17%, 21%, 16% 2) Fusion IO device With bio-based IO path, sequential
2012 Jul 13
5
[PATCH V3 0/3] Improve virtio-blk performance
This patchset implements bio-based IO path for virito-blk to improve performance. Fio test shows bio-based IO path gives the following performance improvement: 1) Ramdisk device With bio-based IO path, sequential read/write, random read/write IOPS boost : 28%, 24%, 21%, 16% Latency improvement: 32%, 17%, 21%, 16% 2) Fusion IO device With bio-based IO path, sequential