Home
last modified time | relevance | path

Searched refs:tocopy (Results 1 – 18 of 18) sorted by relevance

/Linux-v4.19/arch/arm/lib/
Duaccess_with_memcpy.c106 int tocopy; in __copy_to_user_memcpy() local
117 tocopy = (~(unsigned long)to & ~PAGE_MASK) + 1; in __copy_to_user_memcpy()
118 if (tocopy > n) in __copy_to_user_memcpy()
119 tocopy = n; in __copy_to_user_memcpy()
122 memcpy((void *)to, from, tocopy); in __copy_to_user_memcpy()
124 to += tocopy; in __copy_to_user_memcpy()
125 from += tocopy; in __copy_to_user_memcpy()
126 n -= tocopy; in __copy_to_user_memcpy()
174 int tocopy; in __clear_user_memset() local
183 tocopy = (~(unsigned long)addr & ~PAGE_MASK) + 1; in __clear_user_memset()
[all …]
/Linux-v4.19/arch/alpha/boot/tools/
Dobjstrip.c55 size_t nwritten, tocopy, n, mem_size, fil_size, pad = 0; in main() local
238 tocopy = fil_size; in main()
239 while (tocopy > 0) { in main()
240 n = tocopy; in main()
244 tocopy -= n; in main()
263 tocopy = mem_size - fil_size; in main()
264 if (tocopy > 0) { in main()
267 prog_name, pad, (unsigned long) tocopy); in main()
271 n = tocopy; in main()
280 tocopy -= nwritten; in main()
[all …]
/Linux-v4.19/kernel/
Dcapability.c82 static int cap_validate_magic(cap_user_header_t header, unsigned *tocopy) in cap_validate_magic() argument
92 *tocopy = _LINUX_CAPABILITY_U32S_1; in cap_validate_magic()
100 *tocopy = _LINUX_CAPABILITY_U32S_3; in cap_validate_magic()
154 unsigned tocopy; in SYSCALL_DEFINE2() local
157 ret = cap_validate_magic(header, &tocopy); in SYSCALL_DEFINE2()
172 for (i = 0; i < tocopy; i++) { in SYSCALL_DEFINE2()
197 if (copy_to_user(dataptr, kdata, tocopy in SYSCALL_DEFINE2()
227 unsigned i, tocopy, copybytes; in SYSCALL_DEFINE2() local
233 ret = cap_validate_magic(header, &tocopy); in SYSCALL_DEFINE2()
244 copybytes = tocopy * sizeof(struct __user_cap_data_struct); in SYSCALL_DEFINE2()
[all …]
/Linux-v4.19/drivers/misc/genwqe/
Dcard_dev.c511 size_t tocopy = 0; in do_flash_update() local
554 tocopy = min_t(size_t, load->size, FLASH_BLOCK); in do_flash_update()
556 rc = copy_from_user(xbuf, buf, tocopy); in do_flash_update()
561 crc = genwqe_crc32(xbuf, tocopy, 0xffffffff); in do_flash_update()
565 __func__, (unsigned long)dma_addr, crc, tocopy, in do_flash_update()
581 *(__be64 *)&req->__asiv[8] = cpu_to_be64(tocopy); in do_flash_update()
593 *(__be32 *)&req->asiv[8] = cpu_to_be32(tocopy); in do_flash_update()
629 load->size -= tocopy; in do_flash_update()
630 flash += tocopy; in do_flash_update()
631 buf += tocopy; in do_flash_update()
[all …]
/Linux-v4.19/crypto/
Djitterentropy.c593 unsigned int tocopy; in jent_read_entropy() local
598 tocopy = (DATA_SIZE_BITS / 8); in jent_read_entropy()
600 tocopy = len; in jent_read_entropy()
601 jent_memcpy(p, &ec->data, tocopy); in jent_read_entropy()
603 len -= tocopy; in jent_read_entropy()
604 p += tocopy; in jent_read_entropy()
/Linux-v4.19/drivers/hwtracing/intel_th/
Dmsu.c401 size_t tocopy = data_bytes, copied = 0; in msc_buffer_iterate() local
419 tocopy = DATA_IN_PAGE - data_bytes; in msc_buffer_iterate()
423 if (!tocopy) in msc_buffer_iterate()
426 tocopy -= iter->block_off; in msc_buffer_iterate()
429 if (len < tocopy) { in msc_buffer_iterate()
430 tocopy = len; in msc_buffer_iterate()
434 remaining = fn(data, src, tocopy); in msc_buffer_iterate()
439 copied = tocopy - remaining; in msc_buffer_iterate()
1067 unsigned long start = off, tocopy = 0; in msc_single_to_user() local
1072 tocopy = min(rem, size - start); in msc_single_to_user()
[all …]
/Linux-v4.19/fs/jfs/
Dsuper.c769 int tocopy; in jfs_quota_read() local
781 tocopy = sb->s_blocksize - offset < toread ? in jfs_quota_read()
790 memset(data, 0, tocopy); in jfs_quota_read()
795 memcpy(data, bh->b_data+offset, tocopy); in jfs_quota_read()
799 toread -= tocopy; in jfs_quota_read()
800 data += tocopy; in jfs_quota_read()
814 int tocopy; in jfs_quota_write() local
821 tocopy = sb->s_blocksize - offset < towrite ? in jfs_quota_write()
829 if (offset || tocopy != sb->s_blocksize) in jfs_quota_write()
838 memcpy(bh->b_data+offset, data, tocopy); in jfs_quota_write()
[all …]
/Linux-v4.19/sound/usb/bcd2000/
Dbcd2000.c108 unsigned int payload_length, tocopy; in bcd2000_midi_handle_input() local
126 tocopy = min(payload_length, buf_len-1); in bcd2000_midi_handle_input()
129 &buf[1], tocopy); in bcd2000_midi_handle_input()
132 &buf[1], tocopy); in bcd2000_midi_handle_input()
/Linux-v4.19/sound/pci/asihpi/
Dhpicmn.c482 unsigned int tocopy; in hpi_check_control_cache_single() local
505 tocopy = pad_string_len - offset; in hpi_check_control_cache_single()
506 if (tocopy > sizeof(phr->u.cu.chars8.sz_data)) in hpi_check_control_cache_single()
507 tocopy = sizeof(phr->u.cu.chars8. in hpi_check_control_cache_single()
511 &pad_string[offset], tocopy); in hpi_check_control_cache_single()
514 pad_string_len - offset - tocopy; in hpi_check_control_cache_single()
/Linux-v4.19/fs/ext2/
Dsuper.c1496 int tocopy; in ext2_quota_read() local
1508 tocopy = sb->s_blocksize - offset < toread ? in ext2_quota_read()
1517 memset(data, 0, tocopy); in ext2_quota_read()
1522 memcpy(data, bh->b_data+offset, tocopy); in ext2_quota_read()
1526 toread -= tocopy; in ext2_quota_read()
1527 data += tocopy; in ext2_quota_read()
1541 int tocopy; in ext2_quota_write() local
1547 tocopy = sb->s_blocksize - offset < towrite ? in ext2_quota_write()
1555 if (offset || tocopy != EXT2_BLOCK_SIZE(sb)) in ext2_quota_write()
1564 memcpy(bh->b_data+offset, data, tocopy); in ext2_quota_write()
[all …]
/Linux-v4.19/fs/reiserfs/
Dsuper.c2495 int err = 0, offset = off & (sb->s_blocksize - 1), tocopy; in reiserfs_quota_read() local
2506 tocopy = in reiserfs_quota_read()
2520 memset(data, 0, tocopy); in reiserfs_quota_read()
2525 memcpy(data, bh->b_data + offset, tocopy); in reiserfs_quota_read()
2529 toread -= tocopy; in reiserfs_quota_read()
2530 data += tocopy; in reiserfs_quota_read()
2545 int err = 0, offset = off & (sb->s_blocksize - 1), tocopy; in reiserfs_quota_write() local
2556 tocopy = sb->s_blocksize - offset < towrite ? in reiserfs_quota_write()
2564 if (offset || tocopy != sb->s_blocksize) in reiserfs_quota_write()
2573 memcpy(bh->b_data + offset, data, tocopy); in reiserfs_quota_write()
[all …]
/Linux-v4.19/security/
Dcommoncap.c582 unsigned tocopy, i; in get_vfs_caps_from_disk() local
614 tocopy = VFS_CAP_U32_1; in get_vfs_caps_from_disk()
619 tocopy = VFS_CAP_U32_2; in get_vfs_caps_from_disk()
624 tocopy = VFS_CAP_U32_3; in get_vfs_caps_from_disk()
638 if (i >= tocopy) in get_vfs_caps_from_disk()
/Linux-v4.19/drivers/misc/cxl/
Dguest.c74 int rc = 0, i, tocopy; in guest_collect_vpd() local
134 tocopy = len; in guest_collect_vpd()
136 tocopy = SG_BUFFER_SIZE; in guest_collect_vpd()
137 memcpy(buf, vpd_buf[i], tocopy); in guest_collect_vpd()
138 buf += tocopy; in guest_collect_vpd()
139 len -= tocopy; in guest_collect_vpd()
/Linux-v4.19/fs/f2fs/
Dsuper.c1590 int tocopy; in f2fs_quota_read() local
1603 tocopy = min_t(unsigned long, sb->s_blocksize - offset, toread); in f2fs_quota_read()
1626 memcpy(data, kaddr + offset, tocopy); in f2fs_quota_read()
1631 toread -= tocopy; in f2fs_quota_read()
1632 data += tocopy; in f2fs_quota_read()
1650 int tocopy; in f2fs_quota_write() local
1653 tocopy = min_t(unsigned long, sb->s_blocksize - offset, in f2fs_quota_write()
1656 err = a_ops->write_begin(NULL, mapping, off, tocopy, 0, in f2fs_quota_write()
1667 memcpy(kaddr + offset, data, tocopy); in f2fs_quota_write()
1671 a_ops->write_end(NULL, mapping, off, tocopy, tocopy, in f2fs_quota_write()
[all …]
/Linux-v4.19/fs/ocfs2/
Dquota_global.c177 size_t toread, tocopy; in ocfs2_quota_read() local
186 tocopy = min_t(size_t, (sb->s_blocksize - offset), toread); in ocfs2_quota_read()
204 memcpy(data, bh->b_data + offset, tocopy); in ocfs2_quota_read()
207 toread -= tocopy; in ocfs2_quota_read()
208 data += tocopy; in ocfs2_quota_read()
/Linux-v4.19/drivers/net/wireless/
Dwl3501_cs.c1766 u8 implemented, restricted, keys[100], len_keys, tocopy; in wl3501_get_encode() local
1791 tocopy = min_t(u16, len_keys, wrqu->encoding.length); in wl3501_get_encode()
1792 tocopy = min_t(u8, tocopy, 100); in wl3501_get_encode()
1793 wrqu->encoding.length = tocopy; in wl3501_get_encode()
1794 memcpy(extra, keys, tocopy); in wl3501_get_encode()
/Linux-v4.19/drivers/atm/
Dnicstar.c2215 int remaining, tocopy; in dequeue_rx() local
2292 tocopy = in dequeue_rx()
2296 (hb), tocopy); in dequeue_rx()
2297 skb_put(hb, tocopy); in dequeue_rx()
2299 remaining -= tocopy; in dequeue_rx()
/Linux-v4.19/fs/ext4/
Dsuper.c5763 int tocopy; in ext4_quota_read() local
5774 tocopy = sb->s_blocksize - offset < toread ? in ext4_quota_read()
5780 memset(data, 0, tocopy); in ext4_quota_read()
5782 memcpy(data, bh->b_data+offset, tocopy); in ext4_quota_read()
5785 toread -= tocopy; in ext4_quota_read()
5786 data += tocopy; in ext4_quota_read()