[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ec3a5337b9da71a7bc9527728067a4a3d027419b.camel@hammerspace.com>
Date: Mon, 15 Feb 2021 16:02:20 +0000
From: Trond Myklebust <trondmy@...merspace.com>
To: "drinkcat@...omium.org" <drinkcat@...omium.org>,
"anna.schumaker@...app.com" <anna.schumaker@...app.com>,
"iant@...gle.com" <iant@...gle.com>,
"gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
"dchinner@...hat.com" <dchinner@...hat.com>,
"llozano@...omium.org" <llozano@...omium.org>,
"lhenriques@...e.de" <lhenriques@...e.de>,
"sfrench@...ba.org" <sfrench@...ba.org>,
"darrick.wong@...cle.com" <darrick.wong@...cle.com>,
"jlayton@...nel.org" <jlayton@...nel.org>,
"amir73il@...il.com" <amir73il@...il.com>,
"viro@...iv.linux.org.uk" <viro@...iv.linux.org.uk>,
"miklos@...redi.hu" <miklos@...redi.hu>
CC: "samba-technical@...ts.samba.org" <samba-technical@...ts.samba.org>,
"ceph-devel@...r.kernel.org" <ceph-devel@...r.kernel.org>,
"linux-fsdevel@...r.kernel.org" <linux-fsdevel@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-nfs@...r.kernel.org" <linux-nfs@...r.kernel.org>,
"linux-cifs@...r.kernel.org" <linux-cifs@...r.kernel.org>
Subject: Re: [PATCH v2] vfs: prevent copy_file_range to copy across devices
On Mon, 2021-02-15 at 15:43 +0000, Luis Henriques wrote:
> Nicolas Boichat reported an issue when trying to use the
> copy_file_range
> syscall on a tracefs file. It failed silently because the file
> content is
> generated on-the-fly (reporting a size of zero) and copy_file_range
> needs
> to know in advance how much data is present.
That explanation makes no sense whatsoever. copy_file_range is a non-
atomic operation and so the file can change while being copied. Any
determination of 'how much data is present' that is made in advance
would therefore be a flaw in the copy process being used (i.e.
do_splice_direct()). Does sendfile() also 'issue' in the same way?
--
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@...merspace.com
Powered by blists - more mailing lists