public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Wengang Wang <wen.gang.wang@oracle.com>
Cc: "linux-xfs@vger.kernel.org" <linux-xfs@vger.kernel.org>,
	"Darrick J. Wong" <djwong@kernel.org>
Subject: Re: [PATCH V2] xfs: make src file readable during reflink
Date: Wed, 29 Jun 2022 08:21:50 +1000	[thread overview]
Message-ID: <20220628222150.GK227878@dread.disaster.area> (raw)
In-Reply-To: <5ED436A4-6BBF-4868-BF42-3CAC7B90BCCA@oracle.com>

On Tue, Jun 28, 2022 at 03:57:14PM +0000, Wengang Wang wrote:
> Hi Darrick,
> 
> How about the V2?
> 
> thanks,
> wengang
> 
> > On Jun 24, 2022, at 12:10 PM, Wengang Wang <wen.gang.wang@oracle.com> wrote:
> > 
> > During a reflink operation, the IOLOCK and MMAPLOCK of the source file
> > are held in exclusive mode for the duration. This prevents reads on the
> > source file, which could be a very long time if the source file has
> > millions of extents.
> > 
> > As the source of copy, besides some necessary modification (say dirty page
> > flushing), it plays readonly role. Locking source file exclusively through
> > out the full reflink copy is unreasonable.
> > 
> > This patch downgrades exclusive locks on source file to shared modes after
> > page cache flushing and before cloning the extents. To avoid source file
> > change after lock downgradation, direct write paths take IOLOCK_EXCL on
> > seeing reflink copy happening to the files.
> > 
> > Signed-off-by: Wengang Wang <wen.gang.wang@oracle.com>
> > ---
> > V2 changes:
> > Commit message
> > Make direct write paths take IOLOCK_EXCL when reflink copy is happening
> > Tiny changes

Version 2 never made it to the list. Please resend.

-Dave.
-- 
Dave Chinner
david@fromorbit.com

  reply	other threads:[~2022-06-28 22:25 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20220624191037.23683-1-wen.gang.wang@oracle.com>
2022-06-28 15:57 ` [PATCH V2] xfs: make src file readable during reflink Wengang Wang
2022-06-28 22:21   ` Dave Chinner [this message]
2022-06-29  6:07 Wengang Wang
2022-07-05 16:34 ` Wengang Wang
2022-07-05 18:37 ` Darrick J. Wong
2022-07-06  1:35   ` Dave Chinner
2022-08-04  2:50     ` Wengang Wang
2022-07-06  1:24 ` Dave Chinner

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=20220628222150.GK227878@dread.disaster.area \
    --to=david@fromorbit.com \
    --cc=djwong@kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    --cc=wen.gang.wang@oracle.com \
    /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: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox