Skip to content

Commit c08dfb1

Browse files
lxbszidryomov
authored andcommitted
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: 5dda377 ("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>
1 parent 7424918 commit c08dfb1

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

fs/ceph/addr.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ static bool ceph_dirty_folio(struct address_space *mapping, struct folio *folio)
9595

9696
/* dirty the head */
9797
spin_lock(&ci->i_ceph_lock);
98-
BUG_ON(ci->i_wr_ref == 0); // caller should hold Fw reference
9998
if (__ceph_have_pending_cap_snap(ci)) {
10099
struct ceph_cap_snap *capsnap =
101100
list_last_entry(&ci->i_cap_snaps,

0 commit comments

Comments
 (0)