From: David Disseldorp <ddiss-l3A5Bk7waGM@public.gmane.org> To: Christoph Hellwig <hch-jcswGhMUV9g@public.gmane.org> Cc: viro-RmSDqhL/yNMiFSDQTTA3OLVCufUGDwFn@public.gmane.org, tao.peng-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org, jeff.layton-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org, linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Steve French <smfrench-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> Subject: Re: [PATCH 1/5] cifs: implement clone_file_range operation Date: Fri, 27 Nov 2015 11:42:32 +0100 [thread overview] Message-ID: <20151127114232.5b367b7b@g21.suse.de> (raw) In-Reply-To: <1448563859-21922-2-git-send-email-hch-jcswGhMUV9g@public.gmane.org> Hi Christoph, On Thu, 26 Nov 2015 19:50:55 +0100, Christoph Hellwig wrote: > And drop the fake support for the btrfs CLONE ioctl - SMB2 copies are > chunked and do not actually implement clone semantics! BTRFS_IOC_CLONE is implemented using the new ReFS FSCTL_DUPLICATE_EXTENTS_TO_FILE request, which was deemed to be COW based[1]: "The purpose of this operation is to make it look like a copy of a region from the source stream to the target stream has occurred when in reality no data is actually copied. This operation modifies the target stream’s extent list such that, the same clusters are pointed to by both the source and target streams’ extent lists for the region being copied." I think that's about as close as we're going to get to clone semantics for cifs. It's also dispatched as a single request covering the full file - chunking only occurs for CIFS_IOC_COPYCHUNK_FILE based requests, which are implemented using FSCTL_SRV_COPYCHUNK_WRITE, and not (always) handled by the server as a COW clone. It looks like there's also a minor cut 'n paste error here... > @@ -942,6 +960,8 @@ const struct file_operations cifs_file_strict_ops = { > .splice_read = generic_file_splice_read, > .llseek = cifs_llseek, > .unlocked_ioctl = cifs_ioctl, > + .copy_file_range = cifs_file_copy_range, > + .copy_file_range = cifs_file_copy_range, Cheers, David 1. FSCTL_DUPLICATE_EXTENTS_TO_FILE discussion https://lists.samba.org/archive/samba-technical/2015-February/105410.html
WARNING: multiple messages have this Message-ID (diff)
From: David Disseldorp <ddiss@suse.de> To: Christoph Hellwig <hch@lst.de> Cc: viro@zeniv.linux.org.uk, tao.peng@primarydata.com, jeff.layton@primarydata.com, linux-fsdevel@vger.kernel.org, linux-cifs@vger.kernel.org, Steve French <smfrench@gmail.com> Subject: Re: [PATCH 1/5] cifs: implement clone_file_range operation Date: Fri, 27 Nov 2015 11:42:32 +0100 [thread overview] Message-ID: <20151127114232.5b367b7b@g21.suse.de> (raw) In-Reply-To: <1448563859-21922-2-git-send-email-hch@lst.de> Hi Christoph, On Thu, 26 Nov 2015 19:50:55 +0100, Christoph Hellwig wrote: > And drop the fake support for the btrfs CLONE ioctl - SMB2 copies are > chunked and do not actually implement clone semantics! BTRFS_IOC_CLONE is implemented using the new ReFS FSCTL_DUPLICATE_EXTENTS_TO_FILE request, which was deemed to be COW based[1]: "The purpose of this operation is to make it look like a copy of a region from the source stream to the target stream has occurred when in reality no data is actually copied. This operation modifies the target stream’s extent list such that, the same clusters are pointed to by both the source and target streams’ extent lists for the region being copied." I think that's about as close as we're going to get to clone semantics for cifs. It's also dispatched as a single request covering the full file - chunking only occurs for CIFS_IOC_COPYCHUNK_FILE based requests, which are implemented using FSCTL_SRV_COPYCHUNK_WRITE, and not (always) handled by the server as a COW clone. It looks like there's also a minor cut 'n paste error here... > @@ -942,6 +960,8 @@ const struct file_operations cifs_file_strict_ops = { > .splice_read = generic_file_splice_read, > .llseek = cifs_llseek, > .unlocked_ioctl = cifs_ioctl, > + .copy_file_range = cifs_file_copy_range, > + .copy_file_range = cifs_file_copy_range, Cheers, David 1. FSCTL_DUPLICATE_EXTENTS_TO_FILE discussion https://lists.samba.org/archive/samba-technical/2015-February/105410.html
next prev parent reply other threads:[~2015-11-27 10:42 UTC|newest] Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top 2015-11-26 18:50 vfs: move btrfs clone ioctls to common code Christoph Hellwig 2015-11-26 18:50 ` Christoph Hellwig 2015-11-26 18:50 ` [PATCH 1/5] cifs: implement clone_file_range operation Christoph Hellwig 2015-11-26 18:50 ` Christoph Hellwig [not found] ` <1448563859-21922-2-git-send-email-hch-jcswGhMUV9g@public.gmane.org> 2015-11-27 10:42 ` David Disseldorp [this message] 2015-11-27 10:42 ` David Disseldorp [not found] ` <20151127114232.5b367b7b-TzLh5lQYVSQb1SvskN2V4Q@public.gmane.org> 2015-11-30 9:02 ` Christoph Hellwig 2015-11-30 9:02 ` Christoph Hellwig 2015-11-26 18:50 ` [PATCH 2/5] locks: new locks_mandatory_area calling convention Christoph Hellwig 2015-11-30 22:38 ` J. Bruce Fields 2015-11-30 22:38 ` J. Bruce Fields 2015-12-01 7:37 ` Christoph Hellwig 2015-12-01 7:37 ` Christoph Hellwig 2015-11-26 18:50 ` [PATCH 3/5] vfs: pull btrfs clone API to vfs layer Christoph Hellwig 2015-11-26 18:50 ` [PATCH 4/5] nfsd: Pass filehandle to nfs4_preprocess_stateid_op() Christoph Hellwig 2015-11-26 18:50 ` [PATCH 5/5] nfsd: implement the NFSv4.2 CLONE operation Christoph Hellwig 2015-11-26 18:50 ` Christoph Hellwig 2015-11-30 22:56 ` vfs: move btrfs clone ioctls to common code J. Bruce Fields 2015-11-30 22:56 ` J. Bruce Fields 2015-12-01 17:09 ` Chris Mason 2015-12-01 17:09 ` Chris Mason 2015-12-01 22:48 ` Steve French 2015-12-01 22:48 ` Steve French 2015-12-02 7:27 ` Christoph Hellwig 2015-12-02 17:40 ` Steve French 2015-12-02 17:40 ` Steve French 2015-12-03 10:30 ` Christoph Hellwig 2015-12-03 19:28 ` Steve French 2015-12-03 19:28 ` Steve French
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20151127114232.5b367b7b@g21.suse.de \ --to=ddiss-l3a5bk7wagm@public.gmane.org \ --cc=hch-jcswGhMUV9g@public.gmane.org \ --cc=jeff.layton-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org \ --cc=linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \ --cc=linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \ --cc=smfrench-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \ --cc=tao.peng-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org \ --cc=viro-RmSDqhL/yNMiFSDQTTA3OLVCufUGDwFn@public.gmane.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.