summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorXiubo Li <xiubli@redhat.com>2024-09-05 00:22:18 +0200
committerIlya Dryomov <idryomov@gmail.com>2024-09-24 22:51:33 +0200
commitc08dfb1b49492c09cf13838c71897493ea3b424e (patch)
tree33712eafbf03ad06a1adeb871e21a2c6b4e7d726 /fs
parentceph: Remove empty definition in header file (diff)
downloadlinux-c08dfb1b49492c09cf13838c71897493ea3b424e.tar.xz
linux-c08dfb1b49492c09cf13838c71897493ea3b424e.zip
ceph: remove the incorrect Fw reference check when dirtying pages
When doing the direct-io reads it will also try to mark pages dirty, but for the read path it won't hold the Fw caps and there is case will it get the Fw reference. Fixes: 5dda377cf0a6 ("ceph: set i_head_snapc when getting CEPH_CAP_FILE_WR reference") Signed-off-by: Xiubo Li <xiubli@redhat.com> Reviewed-by: Patrick Donnelly <pdonnell@redhat.com> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/ceph/addr.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c
index c4744a02db75..0df4623785dd 100644
--- a/fs/ceph/addr.c
+++ b/fs/ceph/addr.c
@@ -95,7 +95,6 @@ static bool ceph_dirty_folio(struct address_space *mapping, struct folio *folio)
/* dirty the head */
spin_lock(&ci->i_ceph_lock);
- BUG_ON(ci->i_wr_ref == 0); // caller should hold Fw reference
if (__ceph_have_pending_cap_snap(ci)) {
struct ceph_cap_snap *capsnap =
list_last_entry(&ci->i_cap_snaps,