Searched refs:tocopy (Results 1 - 15 of 15) sorted by relevance

/linux-4.1.27/arch/alpha/boot/tools/
H A Dobjstrip.c54 size_t nwritten, tocopy, n, mem_size, fil_size, pad = 0; main() local
237 tocopy = fil_size; main()
238 while (tocopy > 0) { main()
239 n = tocopy; main()
243 tocopy -= n; main()
262 tocopy = mem_size - fil_size; main()
263 if (tocopy > 0) { main()
266 prog_name, pad, (unsigned long) tocopy); main()
270 n = tocopy; main()
279 tocopy -= nwritten; main()
280 } while (tocopy > 0); main()
/linux-4.1.27/arch/arm/lib/
H A Duaccess_with_memcpy.c106 int tocopy; __copy_to_user_memcpy() local
117 tocopy = (~(unsigned long)to & ~PAGE_MASK) + 1; __copy_to_user_memcpy()
118 if (tocopy > n) __copy_to_user_memcpy()
119 tocopy = n; __copy_to_user_memcpy()
121 memcpy((void *)to, from, tocopy); __copy_to_user_memcpy()
122 to += tocopy; __copy_to_user_memcpy()
123 from += tocopy; __copy_to_user_memcpy()
124 n -= tocopy; __copy_to_user_memcpy()
165 int tocopy; __clear_user_memset() local
174 tocopy = (~(unsigned long)addr & ~PAGE_MASK) + 1; __clear_user_memset()
175 if (tocopy > n) __clear_user_memset()
176 tocopy = n; __clear_user_memset()
178 memset((void *)addr, 0, tocopy); __clear_user_memset()
179 addr += tocopy; __clear_user_memset()
180 n -= tocopy; __clear_user_memset()
/linux-4.1.27/kernel/
H A Dcapability.c81 static int cap_validate_magic(cap_user_header_t header, unsigned *tocopy) cap_validate_magic() argument
91 *tocopy = _LINUX_CAPABILITY_U32S_1; cap_validate_magic()
99 *tocopy = _LINUX_CAPABILITY_U32S_3; cap_validate_magic()
153 unsigned tocopy; SYSCALL_DEFINE2() local
156 ret = cap_validate_magic(header, &tocopy); SYSCALL_DEFINE2()
171 for (i = 0; i < tocopy; i++) { SYSCALL_DEFINE2()
178 * Note, in the case, tocopy < _KERNEL_CAPABILITY_U32S, SYSCALL_DEFINE2()
196 if (copy_to_user(dataptr, kdata, tocopy SYSCALL_DEFINE2()
226 unsigned i, tocopy, copybytes; SYSCALL_DEFINE2() local
232 ret = cap_validate_magic(header, &tocopy); SYSCALL_DEFINE2()
243 copybytes = tocopy * sizeof(struct __user_cap_data_struct); SYSCALL_DEFINE2()
250 for (i = 0; i < tocopy; i++) { SYSCALL_DEFINE2()
/linux-4.1.27/drivers/misc/genwqe/
H A Dcard_dev.c513 size_t tocopy = 0; do_flash_update() local
556 tocopy = min_t(size_t, load->size, FLASH_BLOCK); do_flash_update()
558 rc = copy_from_user(xbuf, buf, tocopy); do_flash_update()
563 crc = genwqe_crc32(xbuf, tocopy, 0xffffffff); do_flash_update()
567 __func__, (unsigned long)dma_addr, crc, tocopy, do_flash_update()
583 *(__be64 *)&req->__asiv[8] = cpu_to_be64(tocopy); do_flash_update()
595 *(__be32 *)&req->asiv[8] = cpu_to_be32(tocopy); do_flash_update()
631 load->size -= tocopy; do_flash_update()
632 flash += tocopy; do_flash_update()
633 buf += tocopy; do_flash_update()
649 size_t tocopy = 0; do_flash_read() local
690 tocopy = min_t(size_t, load->size, FLASH_BLOCK); do_flash_read()
694 __func__, (unsigned long)dma_addr, tocopy, do_flash_read()
709 *(__be64 *)&cmd->__asiv[8] = cpu_to_be64(tocopy); do_flash_read()
717 *(__be32 *)&cmd->asiv[8] = cpu_to_be32(tocopy); do_flash_read()
743 rc = copy_to_user(buf, xbuf, tocopy); do_flash_read()
760 load->size -= tocopy; do_flash_read()
761 flash += tocopy; do_flash_read()
762 buf += tocopy; do_flash_read()
/linux-4.1.27/fs/jfs/
H A Dsuper.c748 int tocopy; jfs_quota_read() local
760 tocopy = sb->s_blocksize - offset < toread ? jfs_quota_read()
769 memset(data, 0, tocopy); jfs_quota_read()
774 memcpy(data, bh->b_data+offset, tocopy); jfs_quota_read()
778 toread -= tocopy; jfs_quota_read()
779 data += tocopy; jfs_quota_read()
793 int tocopy; jfs_quota_write() local
800 tocopy = sb->s_blocksize - offset < towrite ? jfs_quota_write()
808 if (offset || tocopy != sb->s_blocksize) jfs_quota_write()
817 memcpy(bh->b_data+offset, data, tocopy); jfs_quota_write()
824 towrite -= tocopy; jfs_quota_write()
825 data += tocopy; jfs_quota_write()
/linux-4.1.27/sound/pci/asihpi/
H A Dhpicmn.c482 unsigned int tocopy; hpi_check_control_cache_single() local
505 tocopy = pad_string_len - offset; hpi_check_control_cache_single()
506 if (tocopy > sizeof(phr->u.cu.chars8.sz_data)) hpi_check_control_cache_single()
507 tocopy = sizeof(phr->u.cu.chars8. hpi_check_control_cache_single()
511 &pad_string[offset], tocopy); hpi_check_control_cache_single()
514 pad_string_len - offset - tocopy; hpi_check_control_cache_single()
/linux-4.1.27/sound/usb/bcd2000/
H A Dbcd2000.c108 unsigned int payload_length, tocopy; bcd2000_midi_handle_input() local
126 tocopy = min(payload_length, buf_len-1); bcd2000_midi_handle_input()
129 &buf[1], tocopy); bcd2000_midi_handle_input()
132 &buf[1], tocopy); bcd2000_midi_handle_input()
/linux-4.1.27/fs/ext2/
H A Dsuper.c1449 int tocopy; ext2_quota_read() local
1461 tocopy = sb->s_blocksize - offset < toread ? ext2_quota_read()
1470 memset(data, 0, tocopy); ext2_quota_read()
1475 memcpy(data, bh->b_data+offset, tocopy); ext2_quota_read()
1479 toread -= tocopy; ext2_quota_read()
1480 data += tocopy; ext2_quota_read()
1494 int tocopy; ext2_quota_write() local
1500 tocopy = sb->s_blocksize - offset < towrite ? ext2_quota_write()
1508 if (offset || tocopy != EXT2_BLOCK_SIZE(sb)) ext2_quota_write()
1517 memcpy(bh->b_data+offset, data, tocopy); ext2_quota_write()
1524 towrite -= tocopy; ext2_quota_write()
1525 data += tocopy; ext2_quota_write()
/linux-4.1.27/fs/reiserfs/
H A Dsuper.c2408 int err = 0, offset = off & (sb->s_blocksize - 1), tocopy; reiserfs_quota_read() local
2419 tocopy = reiserfs_quota_read()
2433 memset(data, 0, tocopy); reiserfs_quota_read()
2438 memcpy(data, bh->b_data + offset, tocopy); reiserfs_quota_read()
2442 toread -= tocopy; reiserfs_quota_read()
2443 data += tocopy; reiserfs_quota_read()
2458 int err = 0, offset = off & (sb->s_blocksize - 1), tocopy; reiserfs_quota_write() local
2469 tocopy = sb->s_blocksize - offset < towrite ? reiserfs_quota_write()
2477 if (offset || tocopy != sb->s_blocksize) reiserfs_quota_write()
2486 memcpy(bh->b_data + offset, data, tocopy); reiserfs_quota_write()
2498 towrite -= tocopy; reiserfs_quota_write()
2499 data += tocopy; reiserfs_quota_write()
/linux-4.1.27/fs/ocfs2/
H A Dquota_global.c175 size_t toread, tocopy; ocfs2_quota_read() local
184 tocopy = min_t(size_t, (sb->s_blocksize - offset), toread); ocfs2_quota_read()
202 memcpy(data, bh->b_data + offset, tocopy); ocfs2_quota_read()
205 toread -= tocopy; ocfs2_quota_read()
206 data += tocopy; ocfs2_quota_read()
/linux-4.1.27/security/
H A Dcommoncap.c385 unsigned tocopy, i; get_vfs_caps_from_disk() local
411 tocopy = VFS_CAP_U32_1; get_vfs_caps_from_disk()
416 tocopy = VFS_CAP_U32_2; get_vfs_caps_from_disk()
423 if (i >= tocopy) CAP_FOR_EACH_U32()
/linux-4.1.27/drivers/net/wireless/
H A Dwl3501_cs.c1756 u8 implemented, restricted, keys[100], len_keys, tocopy; wl3501_get_encode() local
1781 tocopy = min_t(u16, len_keys, wrqu->encoding.length); wl3501_get_encode()
1782 tocopy = min_t(u8, tocopy, 100); wl3501_get_encode()
1783 wrqu->encoding.length = tocopy; wl3501_get_encode()
1784 memcpy(extra, keys, tocopy); wl3501_get_encode()
/linux-4.1.27/fs/ext3/
H A Dsuper.c3023 int tocopy; ext3_quota_read() local
3034 tocopy = sb->s_blocksize - offset < toread ? ext3_quota_read()
3040 memset(data, 0, tocopy); ext3_quota_read()
3042 memcpy(data, bh->b_data+offset, tocopy); ext3_quota_read()
3045 toread -= tocopy; ext3_quota_read()
3046 data += tocopy; ext3_quota_read()
/linux-4.1.27/drivers/atm/
H A Dnicstar.c2214 int remaining, tocopy; dequeue_rx() local
2291 tocopy = dequeue_rx()
2295 (hb), tocopy); dequeue_rx()
2296 skb_put(hb, tocopy); dequeue_rx()
2298 remaining -= tocopy; dequeue_rx()
/linux-4.1.27/fs/ext4/
H A Dsuper.c5430 int tocopy; ext4_quota_read() local
5441 tocopy = sb->s_blocksize - offset < toread ? ext4_quota_read()
5447 memset(data, 0, tocopy); ext4_quota_read()
5449 memcpy(data, bh->b_data+offset, tocopy); ext4_quota_read()
5452 toread -= tocopy; ext4_quota_read()
5453 data += tocopy; ext4_quota_read()

Completed in 570 milliseconds