Lines Matching refs:sfd
71 cf_copy_file_range(int sfd, loff_t *soff, int dfd, loff_t *doff, in cf_copy_file_range() argument
75 return (copy_file_range(sfd, soff, dfd, doff, len, flags)); in cf_copy_file_range()
77 syscall(__NR_copy_file_range, sfd, soff, dfd, doff, len, flags)); in cf_copy_file_range()
153 int do_clone(int sfd, int dfd);
154 int do_clonerange(int sfd, int dfd, loff_t soff, loff_t doff, size_t len);
155 int do_copyfilerange(int sfd, int dfd, loff_t soff, loff_t doff, size_t len);
156 int do_deduperange(int sfd, int dfd, loff_t soff, loff_t doff, size_t len);
231 int sfd = open(argv[optind], O_RDONLY); in main() local
232 if (sfd < 0) { in main()
243 close(sfd); in main()
250 err = do_clone(sfd, dfd); in main()
253 err = do_clonerange(sfd, dfd, soff, doff, len); in main()
256 err = do_copyfilerange(sfd, dfd, soff, doff, len); in main()
259 err = do_deduperange(sfd, dfd, soff, doff, len); in main()
266 off_t spos = lseek(sfd, 0, SEEK_CUR); in main()
267 off_t slen = lseek(sfd, 0, SEEK_END); in main()
276 close(sfd); in main()
282 do_clone(int sfd, int dfd) in do_clone() argument
286 int err = ioctl(dfd, CF_FICLONE, sfd); in do_clone()
295 do_clonerange(int sfd, int dfd, loff_t soff, loff_t doff, size_t len) in do_clonerange() argument
300 .src_fd = sfd, in do_clonerange()
314 do_copyfilerange(int sfd, int dfd, loff_t soff, loff_t doff, size_t len) in do_copyfilerange() argument
318 ssize_t copied = cf_copy_file_range(sfd, &soff, dfd, &doff, len, 0); in do_copyfilerange()
326 if (fstat(sfd, &sb) < 0) { in do_copyfilerange()
341 do_deduperange(int sfd, int dfd, loff_t soff, loff_t doff, size_t len) in do_deduperange() argument
360 int err = ioctl(sfd, CF_FIDEDUPERANGE, fdr); in do_deduperange()