| /linux/net/core/ |
| H A D | net_test.c | 51 unsigned int nr_segs; member 60 .nr_segs = 1, 67 .nr_segs = 3, 76 .nr_segs = 3, 84 .nr_segs = 3, 93 .nr_segs = 2, 103 .nr_segs = 3, 111 .nr_segs = 2, 121 .nr_segs = 4, 135 .nr_segs = 4, [all …]
|
| /linux/block/ |
| H A D | blk.h | 336 struct bio *bio, unsigned int nr_segs); 338 unsigned int nr_segs); 340 struct bio *bio, unsigned int nr_segs); 379 unsigned *nr_segs); 381 const struct queue_limits *lim, unsigned *nr_segs); 422 const struct queue_limits *lim, unsigned int *nr_segs) in __bio_split_to_limits() argument 428 return bio_split_rw(bio, lim, nr_segs); in __bio_split_to_limits() 429 *nr_segs = 1; in __bio_split_to_limits() 432 return bio_split_zone_append(bio, lim, nr_segs); in __bio_split_to_limits() 435 return bio_split_discard(bio, lim, nr_segs); in __bio_split_to_limits() [all …]
|
| H A D | blk-crypto-fallback.c | 173 unsigned int nr_segs, struct page ***pages_ret) in blk_crypto_alloc_enc_bio() argument 180 bio = bio_alloc_bioset(bio_src->bi_bdev, nr_segs, bio_src->bi_opf, in blk_crypto_alloc_enc_bio() 199 pages += nr_segs * (PAGE_PTRS_PER_BVEC - 1); in blk_crypto_alloc_enc_bio() 208 memset(pages, 0, sizeof(struct page *) * nr_segs); in blk_crypto_alloc_enc_bio() 209 nr_allocated = alloc_pages_bulk(GFP_KERNEL, nr_segs, pages); in blk_crypto_alloc_enc_bio() 210 if (nr_allocated < nr_segs) in blk_crypto_alloc_enc_bio() 212 nr_segs, nr_allocated); in blk_crypto_alloc_enc_bio()
|
| H A D | blk-map.c | 26 if (data->nr_segs > UIO_MAXIOV) in bio_alloc_map_data() 29 bmd = kmalloc_flex(*bmd, iov, data->nr_segs, gfp_mask); in bio_alloc_map_data() 34 memcpy(bmd->iov, iter_iov(data), sizeof(struct iovec) * data->nr_segs); in bio_alloc_map_data() 430 unsigned int nr_segs = 0; in blk_rq_append_bio() local 434 ret = bio_split_io_at(bio, lim, &nr_segs, max_bytes, 0); in blk_rq_append_bio() 443 if (!ll_back_merge_fn(rq, bio, nr_segs)) in blk_rq_append_bio() 454 rq->nr_phys_segments = nr_segs; in blk_rq_append_bio()
|
| H A D | blk-mq-sched.c | 336 unsigned int nr_segs) in blk_mq_sched_bio_merge() argument 345 ret = e->type->ops.bio_merge(q, bio, nr_segs); in blk_mq_sched_bio_merge() 362 if (blk_bio_list_merge(q, &ctx->rq_lists[type], bio, nr_segs)) in blk_mq_sched_bio_merge()
|
| H A D | blk-mq.c | 2686 unsigned int nr_segs) in blk_mq_bio_to_request() argument 2698 rq->nr_phys_segments = nr_segs; in blk_mq_bio_to_request() 3035 struct bio *bio, unsigned int nr_segs) in blk_mq_attempt_bio_merge() argument 3038 if (blk_attempt_plug_merge(q, bio, nr_segs)) in blk_mq_attempt_bio_merge() 3040 if (blk_mq_sched_bio_merge(q, bio, nr_segs)) in blk_mq_attempt_bio_merge() 3148 unsigned int nr_segs; in blk_mq_submit_bio() local 3164 nr_segs = bio->__bi_nr_segments; in blk_mq_submit_bio() 3195 bio = __bio_split_to_limits(bio, &q->limits, &nr_segs); in blk_mq_submit_bio() 3204 if (blk_mq_attempt_bio_merge(q, bio, nr_segs)) in blk_mq_submit_bio() 3208 if (blk_zone_plug_bio(bio, nr_segs)) in blk_mq_submit_bio() [all …]
|
| /linux/drivers/scsi/ |
| H A D | xen-scsifront.c | 1133 unsigned int sg_grant, nr_segs; in scsifront_read_backend_params() local 1137 nr_segs = min_t(unsigned int, sg_grant, SG_ALL); in scsifront_read_backend_params() 1138 nr_segs = max_t(unsigned int, nr_segs, VSCSIIF_SG_TABLESIZE); in scsifront_read_backend_params() 1139 nr_segs = min_t(unsigned int, nr_segs, in scsifront_read_backend_params() 1144 dev_info(&dev->dev, "using up to %d SG entries\n", nr_segs); in scsifront_read_backend_params() 1145 else if (info->pause && nr_segs < host->sg_tablesize) in scsifront_read_backend_params() 1148 host->sg_tablesize, nr_segs); in scsifront_read_backend_params() 1150 host->sg_tablesize = nr_segs; in scsifront_read_backend_params() 1151 host->max_sectors = (nr_segs - 1) * PAGE_SIZE / 512; in scsifront_read_backend_params()
|
| /linux/io_uring/ |
| H A D | rsrc.c | 1058 unsigned nr_segs; in io_import_fixed() local 1098 nr_segs = (offset + len + bvec->bv_offset + folio_mask) >> imu->folio_shift; in io_import_fixed() 1099 iov_iter_bvec(iter, ddir, bvec, nr_segs, len); in io_import_fixed() 1451 struct io_mapped_ubuf *imu, unsigned *nr_segs) in io_kern_bvec_size() argument 1458 *nr_segs = 0; in io_kern_bvec_size() 1468 *nr_segs += max_segs; in io_kern_bvec_size() 1483 unsigned nr_segs; in io_import_reg_vec() local 1496 int ret = io_kern_bvec_size(iov, nr_iovs, imu, &nr_segs); in io_import_reg_vec() 1505 nr_segs = ret; in io_import_reg_vec() 1511 bvec_bytes = nr_segs * sizeof(struct bio_vec); in io_import_reg_vec() [all …]
|
| H A D | net.c | 216 int ret, nr_segs; in io_net_import_vec() local 219 nr_segs = iomsg->vec.nr; in io_net_import_vec() 222 nr_segs = 1; in io_net_import_vec() 226 ret = __import_iovec(ddir, uiov, uvec_seg, nr_segs, &iov, in io_net_import_vec() 233 io_vec_reset_iovec(&iomsg->vec, iov, iomsg->msg.msg_iter.nr_segs); in io_net_import_vec() 298 iomsg->msg.msg_iter.nr_segs = 0; in io_msg_copy_hdr() 383 kmsg->msg.msg_iter.nr_segs = sr->len; in io_send_setup() 411 kmsg->msg.msg_iter.nr_segs = msg.msg_iovlen; in io_sendmsg_setup() 1447 from->nr_segs -= bi.bi_idx; in io_sg_from_iter() 1474 unsigned uvec_segs = kmsg->msg.msg_iter.nr_segs; in io_send_zc_import()
|
| H A D | rw.c | 88 int ret, nr_segs; in io_import_vec() local 92 nr_segs = io->vec.nr; in io_import_vec() 95 nr_segs = 1; in io_import_vec() 99 ret = __import_iovec(ddir, uvec, uvec_segs, nr_segs, &iov, &io->iter, in io_import_vec() 105 io_vec_reset_iovec(&io->vec, iov, io->iter.nr_segs); in io_import_vec()
|
| /linux/arch/powerpc/mm/ |
| H A D | dma-noncoherent.c | 65 int nr_segs = 1 + ((size - seg_size) + PAGE_SIZE - 1)/PAGE_SIZE; in __dma_sync_page_highmem() local 84 } while (seg_nr < nr_segs); in __dma_sync_page_highmem()
|
| /linux/drivers/hwtracing/intel_th/ |
| H A D | msu.c | 74 unsigned int nr_segs; member 339 for_each_sg(win->sgt->sgl, sg, win->nr_segs, blk) { in msc_win_total_sz() 434 for_each_sg(win->sgt->sgl, sg, win->nr_segs, blk) { in msc_win_oldest_sg() 671 for_each_sg(win->sgt->sgl, sg, win->nr_segs, blk) { in msc_buffer_clear_hw_header() 1002 unsigned int nr_segs) in __msc_buffer_win_alloc() argument 1008 ret = sg_alloc_table(win->sgt, nr_segs, GFP_KERNEL); in __msc_buffer_win_alloc() 1012 for_each_sg(win->sgt->sgl, sg_ptr, nr_segs, i) { in __msc_buffer_win_alloc() 1022 return nr_segs; in __msc_buffer_win_alloc() 1047 for_each_sg(win->sgt->sgl, sg_ptr, win->nr_segs, i) { in msc_buffer_set_uc() 1067 for_each_sg(win->sgt->sgl, sg_ptr, win->nr_segs, i) { in msc_buffer_set_wb() [all …]
|
| /linux/drivers/md/bcache/ |
| H A D | debug.c | 110 unsigned int nr_segs = bio_segments(bio); in bch_data_verify() local 115 check = bio_kmalloc(nr_segs, GFP_NOIO); in bch_data_verify() 118 bio_init_inline(check, bio->bi_bdev, nr_segs, REQ_OP_READ); in bch_data_verify()
|
| /linux/include/linux/ |
| H A D | iov_iter.h | 64 iter->nr_segs -= p - iter->__iov; in iterate_iovec() 98 iter->nr_segs -= p - iter->kvec; in iterate_kvec() 137 iter->nr_segs -= p - iter->bvec; in iterate_bvec()
|
| H A D | netfs.h | 184 unsigned int nr_segs; /* Number of segs in io_iter */ member
|
| /linux/drivers/nvme/target/ |
| H A D | pci-epf.c | 706 int nr_segs = iod->nr_data_segs + nsegs; in nvmet_pci_epf_alloc_iod_data_segs() local 709 nr_segs * sizeof(struct nvmet_pci_epf_segment), in nvmet_pci_epf_alloc_iod_data_segs() 714 iod->nr_data_segs = nr_segs; in nvmet_pci_epf_alloc_iod_data_segs() 797 int nr_segs, nr_prps = 0; in nvmet_pci_epf_iod_parse_prp_list() local 817 nr_segs = (transfer_len + ofst + ctrl->mps - 1) >> ctrl->mps_shift; in nvmet_pci_epf_iod_parse_prp_list() 819 ret = nvmet_pci_epf_alloc_iod_data_segs(iod, nr_segs); in nvmet_pci_epf_iod_parse_prp_list() 830 nr_segs = 1; in nvmet_pci_epf_iod_parse_prp_list() 871 nr_segs++; in nvmet_pci_epf_iod_parse_prp_list() 872 if (WARN_ON_ONCE(nr_segs > iod->nr_data_segs)) in nvmet_pci_epf_iod_parse_prp_list() 889 iod->nr_data_segs = nr_segs; in nvmet_pci_epf_iod_parse_prp_list() [all …]
|
| H A D | io-cmd-file.c | 77 unsigned long nr_segs, size_t count, int ki_flags) in nvmet_file_submit_bvec() argument 94 iov_iter_bvec(&iter, rw, req->f.bvec, nr_segs, count); in nvmet_file_submit_bvec()
|
| /linux/fs/netfs/ |
| H A D | iterator.c | 113 unsigned int nbv = iter->nr_segs, ix = 0, nsegs = 0; in netfs_limit_bvec() 154 unsigned int nkv = iter->nr_segs, ix = 0, nsegs = 0; in netfs_limit_kvec()
|
| H A D | write_issue.c | 303 subreq->nr_segs++; in netfs_advance_write() 307 subreq->nr_segs >= stream->sreq_max_segs || in netfs_advance_write()
|
| /linux/fs/iomap/ |
| H A D | ioend.c | 459 unsigned int nr_segs; in iomap_split_ioend() local 469 sector_offset = bio_split_rw_at(bio, lim, &nr_segs, max_len); in iomap_split_ioend()
|
| /linux/drivers/block/xen-blkback/ |
| H A D | blkback.c | 710 invcount = xen_blkbk_unmap_prepare(ring, pages, req->nr_segs, in xen_blkbk_unmap_and_respond() 906 pending_req->nr_segs, in xen_blkbk_map_seg() 922 nseg = pending_req->nr_segs; in xen_blkbk_parse_indirect() 1360 pending_req->nr_segs = nseg; in dispatch_rw_block_io() 1474 pending_req->nr_segs); in dispatch_rw_block_io()
|
| H A D | common.h | 347 int nr_segs; member
|
| /linux/drivers/usb/host/ |
| H A D | xen-hcd.c | 719 int nr_segs = 0; in xenhcd_gnttab_done() local 728 nr_segs = shadow->req.nr_buffer_segs; in xenhcd_gnttab_done() 731 nr_segs += shadow->req.u.isoc.nr_frame_desc_segs; in xenhcd_gnttab_done() 733 for (i = 0; i < nr_segs; i++) { in xenhcd_gnttab_done()
|
| /linux/sound/core/ |
| H A D | pcm_native.c | 3629 if (to->nr_segs > 1024 || to->nr_segs != runtime->channels) in snd_pcm_readv() 3636 kmalloc_array(to->nr_segs, sizeof(void *), GFP_KERNEL); in snd_pcm_readv() 3639 for (i = 0; i < to->nr_segs; ++i) { in snd_pcm_readv() 3669 if (from->nr_segs > 128 || from->nr_segs != runtime->channels || in snd_pcm_writev() 3675 kmalloc_array(from->nr_segs, sizeof(void *), GFP_KERNEL); in snd_pcm_writev() 3678 for (i = 0; i < from->nr_segs; ++i) { in snd_pcm_writev()
|
| /linux/fs/smb/client/ |
| H A D | smb1ops.c | 934 struct kvec *iov, unsigned long nr_segs) in cifs_sync_write() argument 938 return CIFSSMBWrite2(xid, parms, written, iov, nr_segs); in cifs_sync_write()
|