Home
last modified time | relevance | path

Searched refs:to_copy (Results 1 - 25 of 66) sorted by relevance

123

/kernel/linux/linux-5.10/net/rds/
H A Dtcp_recv.c74 unsigned long to_copy, skb_off; in rds_tcp_inc_copy_to_user() local
75 for (skb_off = 0; skb_off < skb->len; skb_off += to_copy) { in rds_tcp_inc_copy_to_user()
76 to_copy = iov_iter_count(to); in rds_tcp_inc_copy_to_user()
77 to_copy = min(to_copy, skb->len - skb_off); in rds_tcp_inc_copy_to_user()
79 if (skb_copy_datagram_iter(skb, skb_off, to, to_copy)) in rds_tcp_inc_copy_to_user()
82 rds_stats_add(s_copy_to_user, to_copy); in rds_tcp_inc_copy_to_user()
83 ret += to_copy; in rds_tcp_inc_copy_to_user()
109 unsigned int to_copy, skb_off; in rds_tcp_cong_recv() local
126 to_copy in rds_tcp_cong_recv()
162 size_t left = len, to_copy; rds_tcp_data_recv() local
[all...]
H A Dmessage.c425 unsigned long to_copy, nbytes; in rds_message_copy_from_user() local
449 to_copy = min_t(unsigned long, iov_iter_count(from), in rds_message_copy_from_user()
452 rds_stats_add(s_copy_from_user, to_copy); in rds_message_copy_from_user()
454 to_copy, from); in rds_message_copy_from_user()
455 if (nbytes != to_copy) in rds_message_copy_from_user()
458 sg_off += to_copy; in rds_message_copy_from_user()
471 unsigned long to_copy; in rds_message_inc_copy_to_user() local
485 to_copy = min_t(unsigned long, iov_iter_count(to), in rds_message_inc_copy_to_user()
487 to_copy = min_t(unsigned long, to_copy, le in rds_message_inc_copy_to_user()
[all...]
H A Dib_recv.c537 unsigned long to_copy; in rds_ib_inc_copy_to_user() local
553 to_copy = min_t(unsigned long, iov_iter_count(to), in rds_ib_inc_copy_to_user()
555 to_copy = min_t(unsigned long, to_copy, len - copied); in rds_ib_inc_copy_to_user()
558 rds_stats_add(s_copy_to_user, to_copy); in rds_ib_inc_copy_to_user()
561 to_copy, in rds_ib_inc_copy_to_user()
563 if (ret != to_copy) in rds_ib_inc_copy_to_user()
566 frag_off += to_copy; in rds_ib_inc_copy_to_user()
567 copied += to_copy; in rds_ib_inc_copy_to_user()
791 unsigned long to_copy; in rds_ib_cong_recv() local
[all...]
/kernel/linux/linux-6.6/net/rds/
H A Dtcp_recv.c75 unsigned long to_copy, skb_off; in rds_tcp_inc_copy_to_user() local
76 for (skb_off = 0; skb_off < skb->len; skb_off += to_copy) { in rds_tcp_inc_copy_to_user()
77 to_copy = iov_iter_count(to); in rds_tcp_inc_copy_to_user()
78 to_copy = min(to_copy, skb->len - skb_off); in rds_tcp_inc_copy_to_user()
80 if (skb_copy_datagram_iter(skb, skb_off, to, to_copy)) in rds_tcp_inc_copy_to_user()
83 rds_stats_add(s_copy_to_user, to_copy); in rds_tcp_inc_copy_to_user()
84 ret += to_copy; in rds_tcp_inc_copy_to_user()
110 unsigned int to_copy, skb_off; in rds_tcp_cong_recv() local
127 to_copy in rds_tcp_cong_recv()
163 size_t left = len, to_copy; rds_tcp_data_recv() local
[all...]
H A Dmessage.c422 unsigned long to_copy, nbytes; in rds_message_copy_from_user() local
446 to_copy = min_t(unsigned long, iov_iter_count(from), in rds_message_copy_from_user()
449 rds_stats_add(s_copy_from_user, to_copy); in rds_message_copy_from_user()
451 to_copy, from); in rds_message_copy_from_user()
452 if (nbytes != to_copy) in rds_message_copy_from_user()
455 sg_off += to_copy; in rds_message_copy_from_user()
468 unsigned long to_copy; in rds_message_inc_copy_to_user() local
482 to_copy = min_t(unsigned long, iov_iter_count(to), in rds_message_inc_copy_to_user()
484 to_copy = min_t(unsigned long, to_copy, le in rds_message_inc_copy_to_user()
[all...]
H A Dib_recv.c538 unsigned long to_copy; in rds_ib_inc_copy_to_user() local
554 to_copy = min_t(unsigned long, iov_iter_count(to), in rds_ib_inc_copy_to_user()
556 to_copy = min_t(unsigned long, to_copy, len - copied); in rds_ib_inc_copy_to_user()
559 rds_stats_add(s_copy_to_user, to_copy); in rds_ib_inc_copy_to_user()
562 to_copy, in rds_ib_inc_copy_to_user()
564 if (ret != to_copy) in rds_ib_inc_copy_to_user()
567 frag_off += to_copy; in rds_ib_inc_copy_to_user()
568 copied += to_copy; in rds_ib_inc_copy_to_user()
792 unsigned long to_copy; in rds_ib_cong_recv() local
[all...]
/kernel/linux/linux-5.10/drivers/staging/fbtft/
H A Dfbtft-bus.c126 size_t to_copy; in fbtft_write_vmem16_bus8() local
155 to_copy = min(tx_array_size, remain); in fbtft_write_vmem16_bus8()
156 dev_dbg(par->info->device, "to_copy=%zu, remain=%zu\n", in fbtft_write_vmem16_bus8()
157 to_copy, remain - to_copy); in fbtft_write_vmem16_bus8()
159 for (i = 0; i < to_copy; i++) in fbtft_write_vmem16_bus8()
162 vmem16 = vmem16 + to_copy; in fbtft_write_vmem16_bus8()
164 startbyte_size + to_copy * 2); in fbtft_write_vmem16_bus8()
167 remain -= to_copy; in fbtft_write_vmem16_bus8()
180 size_t to_copy; in fbtft_write_vmem16_bus9() local
[all...]
H A Dfb_ra8875.c249 size_t to_copy; in write_vmem16_bus8() local
267 to_copy = min(tx_array_size, remain); in write_vmem16_bus8()
268 dev_dbg(par->info->device, " to_copy=%zu, remain=%zu\n", in write_vmem16_bus8()
269 to_copy, remain - to_copy); in write_vmem16_bus8()
271 for (i = 0; i < to_copy; i++) in write_vmem16_bus8()
274 vmem16 = vmem16 + to_copy; in write_vmem16_bus8()
276 startbyte_size + to_copy * 2); in write_vmem16_bus8()
279 remain -= to_copy; in write_vmem16_bus8()
/kernel/linux/linux-6.6/drivers/staging/fbtft/
H A Dfbtft-bus.c126 size_t to_copy; in fbtft_write_vmem16_bus8() local
155 to_copy = min(tx_array_size, remain); in fbtft_write_vmem16_bus8()
156 dev_dbg(par->info->device, "to_copy=%zu, remain=%zu\n", in fbtft_write_vmem16_bus8()
157 to_copy, remain - to_copy); in fbtft_write_vmem16_bus8()
159 for (i = 0; i < to_copy; i++) in fbtft_write_vmem16_bus8()
162 vmem16 = vmem16 + to_copy; in fbtft_write_vmem16_bus8()
164 startbyte_size + to_copy * 2); in fbtft_write_vmem16_bus8()
167 remain -= to_copy; in fbtft_write_vmem16_bus8()
180 size_t to_copy; in fbtft_write_vmem16_bus9() local
[all...]
H A Dfb_ra8875.c249 size_t to_copy; in write_vmem16_bus8() local
267 to_copy = min(tx_array_size, remain); in write_vmem16_bus8()
268 dev_dbg(par->info->device, " to_copy=%zu, remain=%zu\n", in write_vmem16_bus8()
269 to_copy, remain - to_copy); in write_vmem16_bus8()
271 for (i = 0; i < to_copy; i++) in write_vmem16_bus8()
274 vmem16 = vmem16 + to_copy; in write_vmem16_bus8()
276 startbyte_size + to_copy * 2); in write_vmem16_bus8()
279 remain -= to_copy; in write_vmem16_bus8()
/kernel/linux/linux-6.6/drivers/hwtracing/coresight/
H A Dultrasoc-smb.c130 ssize_t to_copy = 0; in smb_read() local
138 to_copy = min(sdb->data_size, len); in smb_read()
141 if (sdb->buf_rdptr + to_copy > sdb->buf_size) in smb_read()
142 to_copy = sdb->buf_size - sdb->buf_rdptr; in smb_read()
144 if (copy_to_user(data, sdb->buf_base + sdb->buf_rdptr, to_copy)) { in smb_read()
149 *ppos += to_copy; in smb_read()
150 smb_update_read_ptr(drvdata, to_copy); in smb_read()
154 dev_dbg(dev, "%zu bytes copied\n", to_copy); in smb_read()
155 return to_copy; in smb_read()
361 unsigned long to_copy; in smb_sync_perf_buffer() local
[all...]
/kernel/linux/linux-5.10/drivers/gpu/drm/amd/amdkfd/
H A Dkfd_smi_events.c80 size_t to_copy; in kfd_smi_ev_read() local
92 to_copy = kfifo_len(&client->fifo); in kfd_smi_ev_read()
93 if (!to_copy) { in kfd_smi_ev_read()
98 to_copy = min3(size, sizeof(buf), to_copy); in kfd_smi_ev_read()
99 ret = kfifo_out(&client->fifo, buf, to_copy); in kfd_smi_ev_read()
106 ret = copy_to_user(user, buf, to_copy); in kfd_smi_ev_read()
113 return to_copy; in kfd_smi_ev_read()
/kernel/linux/linux-6.6/tools/testing/selftests/arm64/signal/
H A Dtest_signals_utils.c175 size_t to_copy; in handle_signal_copyctx() local
196 to_copy = __builtin_offsetof(ucontext_t, in handle_signal_copyctx()
198 to_copy += offset + sizeof(struct extra_context) + 16; in handle_signal_copyctx()
199 to_copy += extra->size; in handle_signal_copyctx()
203 to_copy = sizeof(ucontext_t); in handle_signal_copyctx()
206 if (to_copy > td->live_sz) { in handle_signal_copyctx()
209 td->live_sz, to_copy); in handle_signal_copyctx()
213 memcpy(td->live_uc, uc, to_copy); in handle_signal_copyctx()
228 to_copy); in handle_signal_copyctx()
/kernel/linux/linux-5.10/drivers/xen/
H A Dxen-front-pgdir-shbuf.c285 int to_copy = XEN_NUM_GREFS_PER_PAGE; in backend_map() local
287 if (to_copy > grefs_left) in backend_map()
288 to_copy = grefs_left; in backend_map()
290 for (cur_gref = 0; cur_gref < to_copy; cur_gref++) { in backend_map()
301 grefs_left -= to_copy; in backend_map()
364 int cur_gref, grefs_left, to_copy, i, num_pages_dir; in guest_fill_page_dir() local
380 to_copy = grefs_left; in guest_fill_page_dir()
383 to_copy = XEN_NUM_GREFS_PER_PAGE; in guest_fill_page_dir()
387 to_copy * sizeof(grant_ref_t)); in guest_fill_page_dir()
389 grefs_left -= to_copy; in guest_fill_page_dir()
[all...]
/kernel/linux/linux-6.6/drivers/xen/
H A Dxen-front-pgdir-shbuf.c276 int to_copy = XEN_NUM_GREFS_PER_PAGE; in backend_map() local
278 if (to_copy > grefs_left) in backend_map()
279 to_copy = grefs_left; in backend_map()
281 for (cur_gref = 0; cur_gref < to_copy; cur_gref++) { in backend_map()
292 grefs_left -= to_copy; in backend_map()
362 int cur_gref, grefs_left, to_copy, i, num_pages_dir; in guest_fill_page_dir() local
378 to_copy = grefs_left; in guest_fill_page_dir()
381 to_copy = XEN_NUM_GREFS_PER_PAGE; in guest_fill_page_dir()
385 to_copy * sizeof(grant_ref_t)); in guest_fill_page_dir()
387 grefs_left -= to_copy; in guest_fill_page_dir()
[all...]
/kernel/linux/linux-5.10/drivers/most/
H A Dmost_cdev.c186 size_t to_copy, left; in comp_write() local
206 to_copy = min(count, c->cfg->buffer_size - c->mbo_offs); in comp_write()
207 left = copy_from_user(mbo->virt_address + c->mbo_offs, buf, to_copy); in comp_write()
208 if (left == to_copy) { in comp_write()
213 c->mbo_offs += to_copy - left; in comp_write()
223 ret = to_copy - left; in comp_write()
239 size_t to_copy, not_copied, copied; in comp_read() local
261 to_copy = min_t(size_t, in comp_read()
267 to_copy); in comp_read()
269 copied = to_copy in comp_read()
[all...]
/kernel/linux/linux-6.6/drivers/most/
H A Dmost_cdev.c186 size_t to_copy, left; in comp_write() local
206 to_copy = min(count, c->cfg->buffer_size - c->mbo_offs); in comp_write()
207 left = copy_from_user(mbo->virt_address + c->mbo_offs, buf, to_copy); in comp_write()
208 if (left == to_copy) { in comp_write()
213 c->mbo_offs += to_copy - left; in comp_write()
223 ret = to_copy - left; in comp_write()
239 size_t to_copy, not_copied, copied; in comp_read() local
261 to_copy = min_t(size_t, in comp_read()
267 to_copy); in comp_read()
269 copied = to_copy in comp_read()
[all...]
/kernel/linux/linux-5.10/drivers/infiniband/hw/hfi1/
H A Deprom.c304 u32 bytes_available, ncopied, to_copy; in read_segment_platform_config() local
408 to_copy = entry->size - ncopied; in read_segment_platform_config()
411 if (to_copy > bytes_available) in read_segment_platform_config()
412 to_copy = bytes_available; in read_segment_platform_config()
424 ret = read_length(dd, seg_base + seg_offset, to_copy, in read_segment_platform_config()
429 ncopied += to_copy; in read_segment_platform_config()
/kernel/linux/linux-6.6/drivers/infiniband/hw/hfi1/
H A Deprom.c263 u32 bytes_available, ncopied, to_copy; in read_segment_platform_config() local
367 to_copy = entry->size - ncopied; in read_segment_platform_config()
370 if (to_copy > bytes_available) in read_segment_platform_config()
371 to_copy = bytes_available; in read_segment_platform_config()
383 ret = read_length(dd, seg_base + seg_offset, to_copy, in read_segment_platform_config()
388 ncopied += to_copy; in read_segment_platform_config()
/kernel/linux/linux-6.6/drivers/nvmem/
H A Dbrcm_nvram.c53 size_t to_copy; in brcm_nvram_read() local
56 to_copy = max_t(ssize_t, (ssize_t)priv->data_len - offset, 0); in brcm_nvram_read()
58 to_copy = bytes; in brcm_nvram_read()
60 memcpy(val, priv->data + offset, to_copy); in brcm_nvram_read()
62 memset((uint8_t *)val + to_copy, priv->padding_byte, bytes - to_copy); in brcm_nvram_read()
/kernel/linux/linux-5.10/drivers/gpu/drm/vmwgfx/
H A Dvmwgfx_blit.c122 size_t to_copy = size & ~(sizeof(_type) - 1); \
125 ((_type *) dst, (_type *) src, to_copy); \
195 size_t to_copy = round_down(size, sizeof(_type)); \
198 ((_type *) dst, (_type *) src, to_copy); \
199 location = size - to_copy + diff_offs - sizeof(_type); \
203 dst -= to_copy - diff_offs; \
204 src -= to_copy - diff_offs; \
205 size -= to_copy - diff_offs; \
/kernel/linux/linux-6.6/drivers/gpu/drm/amd/amdkfd/
H A Dkfd_smi_events.c84 size_t to_copy; in kfd_smi_ev_read() local
97 to_copy = kfifo_len(&client->fifo); in kfd_smi_ev_read()
98 if (!to_copy) { in kfd_smi_ev_read()
103 to_copy = min(size, to_copy); in kfd_smi_ev_read()
104 ret = kfifo_out(&client->fifo, buf, to_copy); in kfd_smi_ev_read()
111 ret = copy_to_user(user, buf, to_copy); in kfd_smi_ev_read()
118 return to_copy; in kfd_smi_ev_read()
/kernel/linux/linux-6.6/drivers/gpu/drm/vmwgfx/
H A Dvmwgfx_blit.c122 size_t to_copy = size & ~(sizeof(_type) - 1); \
125 ((_type *) dst, (_type *) src, to_copy); \
195 size_t to_copy = round_down(size, sizeof(_type)); \
198 ((_type *) dst, (_type *) src, to_copy); \
199 location = size - to_copy + diff_offs - sizeof(_type); \
203 dst -= to_copy - diff_offs; \
204 src -= to_copy - diff_offs; \
205 size -= to_copy - diff_offs; \
/kernel/linux/linux-6.6/include/linux/
H A Dkmsan-checks.h53 * @to_copy: number of bytes to copy.
61 void kmsan_copy_to_user(void __user *to, const void *from, size_t to_copy,
77 size_t to_copy, size_t left) in kmsan_copy_to_user()
76 kmsan_copy_to_user(void __user *to, const void *from, size_t to_copy, size_t left) kmsan_copy_to_user() argument
/kernel/linux/linux-5.10/drivers/infiniband/sw/siw/
H A Dsiw_qp_rx.c892 u16 to_copy = sizeof(struct iwarp_ctrl); in siw_proc_terminate() local
921 skb_copy_bits(skb, srx->skb_offset, infop, to_copy); in siw_proc_terminate()
927 infop += to_copy; in siw_proc_terminate()
928 srx->skb_offset += to_copy; in siw_proc_terminate()
929 srx->skb_new -= to_copy; in siw_proc_terminate()
930 srx->skb_copied += to_copy; in siw_proc_terminate()
931 srx->fpdu_part_rcvd += to_copy; in siw_proc_terminate()
932 srx->fpdu_part_rem -= to_copy; in siw_proc_terminate()
934 to_copy = iwarp_pktinfo[op].hdr_len - to_copy; in siw_proc_terminate()
[all...]

Completed in 17 milliseconds

123