From: Jeff Layton <jlayton@kernel.org>
To: David Howells <dhowells@redhat.com>
Cc: idryomov@gmail.com, linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH v2 2/2] ceph: Remove some other inline-setting bits
Date: Fri, 17 Dec 2021 11:07:09 -0500 [thread overview]
Message-ID: <7017d22f7e09b1c8f6b181cdfcc8fd4c9f8566ce.camel@kernel.org> (raw)
In-Reply-To: <163975499268.2021751.9526015087273381693.stgit@warthog.procyon.org.uk>
On Fri, 2021-12-17 at 15:29 +0000, David Howells wrote:
> Remove some other bits where a ceph file can't be inline because we
> uninlined it when we opened it for writing.
>
> Signed-off-by: David Howells <dhowells@redhat.com>
> ---
>
> fs/ceph/addr.c | 4 +---
> fs/ceph/file.c | 4 ----
> 2 files changed, 1 insertion(+), 7 deletions(-)
>
> diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c
> index 6e1b15cc87cf..553e2b5653f3 100644
> --- a/fs/ceph/addr.c
> +++ b/fs/ceph/addr.c
> @@ -1534,11 +1534,9 @@ static vm_fault_t ceph_page_mkwrite(struct vm_fault *vmf)
> ceph_put_snap_context(snapc);
> } while (err == 0);
>
> - if (ret == VM_FAULT_LOCKED ||
> - ci->i_inline_version != CEPH_INLINE_NONE) {
> + if (ret == VM_FAULT_LOCKED) {
> int dirty;
> spin_lock(&ci->i_ceph_lock);
> - ci->i_inline_version = CEPH_INLINE_NONE;
> dirty = __ceph_mark_dirty_caps(ci, CEPH_CAP_FILE_WR,
> &prealloc_cf);
> spin_unlock(&ci->i_ceph_lock);
> diff --git a/fs/ceph/file.c b/fs/ceph/file.c
> index d16ba8720783..4a0aeed7f660 100644
> --- a/fs/ceph/file.c
> +++ b/fs/ceph/file.c
> @@ -1031,7 +1031,6 @@ static void ceph_aio_complete(struct inode *inode,
> }
>
> spin_lock(&ci->i_ceph_lock);
> - ci->i_inline_version = CEPH_INLINE_NONE;
> dirty = __ceph_mark_dirty_caps(ci, CEPH_CAP_FILE_WR,
> &aio_req->prealloc_cf);
> spin_unlock(&ci->i_ceph_lock);
> @@ -1838,7 +1837,6 @@ static ssize_t ceph_write_iter(struct kiocb *iocb, struct iov_iter *from)
> int dirty;
>
> spin_lock(&ci->i_ceph_lock);
> - ci->i_inline_version = CEPH_INLINE_NONE;
> dirty = __ceph_mark_dirty_caps(ci, CEPH_CAP_FILE_WR,
> &prealloc_cf);
> spin_unlock(&ci->i_ceph_lock);
> @@ -2116,7 +2114,6 @@ static long ceph_fallocate(struct file *file, int mode,
>
> if (!ret) {
> spin_lock(&ci->i_ceph_lock);
> - ci->i_inline_version = CEPH_INLINE_NONE;
> dirty = __ceph_mark_dirty_caps(ci, CEPH_CAP_FILE_WR,
> &prealloc_cf);
> spin_unlock(&ci->i_ceph_lock);
> @@ -2509,7 +2506,6 @@ static ssize_t __ceph_copy_file_range(struct file *src_file, loff_t src_off,
> }
> /* Mark Fw dirty */
> spin_lock(&dst_ci->i_ceph_lock);
> - dst_ci->i_inline_version = CEPH_INLINE_NONE;
> dirty = __ceph_mark_dirty_caps(dst_ci, CEPH_CAP_FILE_WR, &prealloc_cf);
> spin_unlock(&dst_ci->i_ceph_lock);
> if (dirty)
>
>
I'll probably just fold this one into the first patch if that's ok.
--
Jeff Layton <jlayton@kernel.org>
next prev parent reply other threads:[~2021-12-17 16:07 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-17 15:29 [PATCH v2 1/2] ceph: Uninline the data on a file opened for writing David Howells
2021-12-17 15:29 ` [PATCH v2 2/2] ceph: Remove some other inline-setting bits David Howells
2021-12-17 16:07 ` Jeff Layton [this message]
2021-12-17 16:05 ` [PATCH v2 1/2] ceph: Uninline the data on a file opened for writing Jeff Layton
2021-12-17 16:20 ` Matthew Wilcox
2021-12-17 17:18 ` Jeff Layton
2021-12-17 17:29 ` Matthew Wilcox
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=7017d22f7e09b1c8f6b181cdfcc8fd4c9f8566ce.camel@kernel.org \
--to=jlayton@kernel.org \
--cc=dhowells@redhat.com \
--cc=idryomov@gmail.com \
--cc=linux-fsdevel@vger.kernel.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: 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;
as well as URLs for NNTP newsgroup(s).