/Linux-v6.1/virt/kvm/ |
D | binary_stats.c | 58 ssize_t copylen; in kvm_stats_read() local 83 copylen = size_header - pos; in kvm_stats_read() 84 copylen = min(copylen, remain); in kvm_stats_read() 85 if (copylen > 0) { in kvm_stats_read() 87 if (copy_to_user(dest, src, copylen)) in kvm_stats_read() 89 remain -= copylen; in kvm_stats_read() 90 pos += copylen; in kvm_stats_read() 91 dest += copylen; in kvm_stats_read() 103 copylen = header->id_offset + KVM_STATS_NAME_SIZE - pos; in kvm_stats_read() 104 copylen = min(copylen, remain); in kvm_stats_read() [all …]
|
/Linux-v6.1/drivers/input/serio/ |
D | userio.c | 126 size_t nonwrap_len, copylen; in userio_char_read() local 143 copylen = min(nonwrap_len, count); in userio_char_read() 144 if (copylen) { in userio_char_read() 145 memcpy(buf, &userio->buf[userio->tail], copylen); in userio_char_read() 146 userio->tail = (userio->tail + copylen) % in userio_char_read() 172 if (copylen) in userio_char_read() 173 if (copy_to_user(user_buffer, buf, copylen)) in userio_char_read() 176 return copylen; in userio_char_read()
|
/Linux-v6.1/net/phonet/ |
D | datagram.c | 120 int copylen; in pn_recvmsg() local 132 copylen = skb->len; in pn_recvmsg() 133 if (len < copylen) { in pn_recvmsg() 135 copylen = len; in pn_recvmsg() 138 rval = skb_copy_datagram_msg(skb, 0, msg, copylen); in pn_recvmsg() 144 rval = (flags & MSG_TRUNC) ? skb->len : copylen; in pn_recvmsg()
|
/Linux-v6.1/net/dccp/ |
D | options.c | 435 int copylen = len; in dccp_insert_option_ackvec() local 438 copylen = DCCP_SINGLE_OPT_MAXLEN; in dccp_insert_option_ackvec() 447 *to++ = copylen + 2; in dccp_insert_option_ackvec() 450 if (from + copylen > tail) { in dccp_insert_option_ackvec() 456 copylen -= tailsize; in dccp_insert_option_ackvec() 460 memcpy(to, from, copylen); in dccp_insert_option_ackvec() 461 from += copylen; in dccp_insert_option_ackvec() 462 to += copylen; in dccp_insert_option_ackvec() 463 len -= copylen; in dccp_insert_option_ackvec()
|
/Linux-v6.1/net/smc/ |
D | smc_rx.c | 343 size_t copylen, read_done = 0, read_remaining = len; in smc_rx_recvmsg() local 452 copylen = min_t(size_t, read_remaining, readable); in smc_rx_recvmsg() 455 chunk_len = min_t(size_t, copylen, conn->rmb_desc->len - in smc_rx_recvmsg() 480 if (chunk_len_sum == copylen) in smc_rx_recvmsg() 483 chunk_len = copylen - chunk_len; /* remainder */ in smc_rx_recvmsg() 492 atomic_sub(copylen, &conn->bytes_to_rcv); in smc_rx_recvmsg() 495 if (msg && smc_rx_update_consumer(smc, cons, copylen)) in smc_rx_recvmsg() 499 trace_smc_rx_recvmsg(smc, copylen); in smc_rx_recvmsg()
|
D | smc_tx.c | 184 size_t copylen, send_done = 0, send_remaining = len; in smc_tx_sendmsg() local 238 copylen = min_t(size_t, send_remaining, writespace); in smc_tx_sendmsg() 245 chunk_len = min_t(size_t, copylen, conn->sndbuf_desc->len - in smc_tx_sendmsg() 261 if (chunk_len_sum == copylen) in smc_tx_sendmsg() 264 chunk_len = copylen - chunk_len; /* remainder */ in smc_tx_sendmsg() 270 smc_curs_add(conn->sndbuf_desc->len, &prep, copylen); in smc_tx_sendmsg() 274 atomic_sub(copylen, &conn->sndbuf_space); in smc_tx_sendmsg() 288 trace_smc_tx_sendmsg(smc, copylen); in smc_tx_sendmsg()
|
/Linux-v6.1/drivers/net/ |
D | tap.c | 641 int copylen = 0; in tap_get_user() local 678 copylen = vnet_hdr.hdr_len ? in tap_get_user() 680 if (copylen > good_linear) in tap_get_user() 681 copylen = good_linear; in tap_get_user() 682 else if (copylen < ETH_HLEN) in tap_get_user() 683 copylen = ETH_HLEN; in tap_get_user() 684 linear = copylen; in tap_get_user() 686 iov_iter_advance(&i, copylen); in tap_get_user() 692 copylen = len; in tap_get_user() 700 skb = tap_alloc_skb(&q->sk, TAP_RESERVE, copylen, in tap_get_user()
|
D | tun.c | 1745 int copylen; in tun_get_user() local 1797 copylen = gso.hdr_len ? tun16_to_cpu(tun, gso.hdr_len) : GOODCOPY_LEN; in tun_get_user() 1798 if (copylen > good_linear) in tun_get_user() 1799 copylen = good_linear; in tun_get_user() 1800 linear = copylen; in tun_get_user() 1801 iov_iter_advance(&i, copylen); in tun_get_user() 1820 copylen = len; in tun_get_user() 1829 skb = tun_napi_alloc_frags(tfile, copylen, from); in tun_get_user() 1836 skb = tun_alloc_skb(tfile, align, copylen, linear, in tun_get_user()
|
/Linux-v6.1/net/hsr/ |
D | hsr_forward.c | 124 int copylen; in create_stripped_skb_hsr() local 138 copylen = 2 * ETH_ALEN; in create_stripped_skb_hsr() 140 copylen += VLAN_HLEN; in create_stripped_skb_hsr() 143 memcpy(dst, src, copylen); in create_stripped_skb_hsr()
|
/Linux-v6.1/net/caif/ |
D | caif_socket.c | 273 int copylen; in caif_seqpkt_recvmsg() local 282 copylen = skb->len; in caif_seqpkt_recvmsg() 283 if (len < copylen) { in caif_seqpkt_recvmsg() 285 copylen = len; in caif_seqpkt_recvmsg() 288 ret = skb_copy_datagram_msg(skb, 0, m, copylen); in caif_seqpkt_recvmsg() 292 ret = (flags & MSG_TRUNC) ? skb->len : copylen; in caif_seqpkt_recvmsg()
|
/Linux-v6.1/tools/testing/selftests/rseq/ |
D | param_test.c | 924 size_t copylen; in this_cpu_memcpy_buffer_push() local 935 copylen = sizeof(item); in this_cpu_memcpy_buffer_push() 941 destptr, srcptr, copylen, in this_cpu_memcpy_buffer_push() 945 offset, destptr, srcptr, copylen, in this_cpu_memcpy_buffer_push() 968 size_t copylen; in this_cpu_memcpy_buffer_pop() local 979 copylen = sizeof(*item); in this_cpu_memcpy_buffer_pop() 983 offset, destptr, srcptr, copylen, in this_cpu_memcpy_buffer_pop()
|
/Linux-v6.1/net/mptcp/ |
D | sockopt.c | 940 u32 copylen = min_t(u32, sfd->size_subflow_data, sizeof(*sfd)); in mptcp_put_subflow_data() local 945 copied = copylen; in mptcp_put_subflow_data() 950 if (copy_to_user(optval, sfd, copylen)) in mptcp_put_subflow_data() 959 int len, copylen; in mptcp_get_subflow_data() local 974 copylen = min_t(unsigned int, len, sizeof(*sfd)); in mptcp_get_subflow_data() 975 if (copy_from_user(sfd, optval, copylen)) in mptcp_get_subflow_data()
|
/Linux-v6.1/net/ipv4/ |
D | tcp.c | 2026 struct sk_buff *skb, u32 copylen, in tcp_copy_straggler_data() argument 2038 copylen, &iov, &msg.msg_iter); in tcp_copy_straggler_data() 2041 err = skb_copy_datagram_msg(skb, *offset, &msg, copylen); in tcp_copy_straggler_data() 2044 zc->recv_skip_hint -= copylen; in tcp_copy_straggler_data() 2045 *offset += copylen; in tcp_copy_straggler_data() 2046 *seq += copylen; in tcp_copy_straggler_data() 2047 return (__s32)copylen; in tcp_copy_straggler_data() 2057 u32 offset, copylen = min_t(u32, copybuf_len, zc->recv_skip_hint); in tcp_zc_handle_leftover() local 2059 if (!copylen) in tcp_zc_handle_leftover() 2072 zc->copybuf_len = tcp_copy_straggler_data(zc, skb, copylen, &offset, in tcp_zc_handle_leftover() [all …]
|
/Linux-v6.1/drivers/net/wireless/intel/iwlwifi/dvm/ |
D | rx.c | 910 u32 copylen = len; in iwlagn_rx_noa_notification() local 916 copylen += 1 + 2; in iwlagn_rx_noa_notification() 928 copylen); in iwlagn_rx_noa_notification()
|
/Linux-v6.1/drivers/net/wireless/zydas/ |
D | zd1201.c | 230 unsigned short infotype, copylen; in zd1201_usbrx() local 294 copylen = le16_to_cpu(*(__le16*)&data[i+2]); in zd1201_usbrx() 296 if (copylen+zd->rxlen > sizeof(zd->rxdata)) in zd1201_usbrx() 298 memcpy(zd->rxdata+zd->rxlen, data+i+4, copylen); in zd1201_usbrx() 299 zd->rxlen += copylen; in zd1201_usbrx()
|
/Linux-v6.1/net/packet/ |
D | af_packet.c | 2566 __be16 proto, unsigned char *addr, int hlen, int copylen, in tpacket_fill_skb() argument 2595 } else if (copylen) { in tpacket_fill_skb() 2596 int hdrlen = min_t(int, copylen, tp_len); in tpacket_fill_skb() 2599 skb_put(skb, copylen - dev->hard_header_len); in tpacket_fill_skb() 2728 int hlen, tlen, copylen = 0; in tpacket_snd() local 2818 copylen = __virtio16_to_cpu(vio_le(), in tpacket_snd() 2821 copylen = max_t(int, copylen, dev->hard_header_len); in tpacket_snd() 2824 (copylen - dev->hard_header_len), in tpacket_snd() 2834 addr, hlen, copylen, &sockc); in tpacket_snd()
|
/Linux-v6.1/drivers/net/wireless/ |
D | rndis_wlan.c | 700 int resplen, respoffs, copylen; in rndis_query_oid() local 747 copylen = buflen - respoffs; in rndis_query_oid() 749 copylen = resplen; in rndis_query_oid() 752 if (copylen > *len) in rndis_query_oid() 753 copylen = *len; in rndis_query_oid() 755 memcpy(data, u.buf + respoffs, copylen); in rndis_query_oid()
|
/Linux-v6.1/net/netfilter/ipvs/ |
D | ip_vs_ctl.c | 2778 unsigned int copylen; in do_ip_vs_get_ctl() local 2790 copylen = get_arglen[CMDID(cmd)]; in do_ip_vs_get_ctl() 2791 if (*len < (int) copylen) { in do_ip_vs_get_ctl() 2792 IP_VS_DBG(1, "get_ctl: len %d < %u\n", *len, copylen); in do_ip_vs_get_ctl() 2796 if (copy_from_user(arg, user, copylen) != 0) in do_ip_vs_get_ctl()
|
/Linux-v6.1/net/netfilter/ipset/ |
D | ip_set_core.c | 2192 int copylen = *len, ret = 0; in ip_set_sockfn_get() local 2298 if (copy_to_user(user, data, copylen)) in ip_set_sockfn_get()
|