]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
gfs2: Remove gfs2_jdata_writepage()
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Fri, 19 Jul 2024 17:51:03 +0000 (18:51 +0100)
committerAndreas Gruenbacher <agruenba@redhat.com>
Mon, 2 Sep 2024 12:46:33 +0000 (14:46 +0200)
There are no remaining callers of gfs2_jdata_writepage() other than
vmscan, which is known to do more harm than good.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
fs/gfs2/aops.c

index 10d5acd3f74233ca2094bfe5908cd97b857bfe4d..68fc8af14700d3bdc6d8ee22f095aeeba98b14b4 100644 (file)
@@ -138,35 +138,6 @@ static int __gfs2_jdata_write_folio(struct folio *folio,
        return gfs2_write_jdata_folio(folio, wbc);
 }
 
-/**
- * gfs2_jdata_writepage - Write complete page
- * @page: Page to write
- * @wbc: The writeback control
- *
- * Returns: errno
- *
- */
-
-static int gfs2_jdata_writepage(struct page *page, struct writeback_control *wbc)
-{
-       struct folio *folio = page_folio(page);
-       struct inode *inode = page->mapping->host;
-       struct gfs2_inode *ip = GFS2_I(inode);
-       struct gfs2_sbd *sdp = GFS2_SB(inode);
-
-       if (gfs2_assert_withdraw(sdp, ip->i_gl->gl_state == LM_ST_EXCLUSIVE))
-               goto out;
-       if (folio_test_checked(folio) || current->journal_info)
-               goto out_ignore;
-       return __gfs2_jdata_write_folio(folio, wbc);
-
-out_ignore:
-       folio_redirty_for_writepage(wbc, folio);
-out:
-       folio_unlock(folio);
-       return 0;
-}
-
 /**
  * gfs2_writepages - Write a bunch of dirty pages back to disk
  * @mapping: The mapping to write
@@ -748,7 +719,6 @@ static const struct address_space_operations gfs2_aops = {
 };
 
 static const struct address_space_operations gfs2_jdata_aops = {
-       .writepage = gfs2_jdata_writepage,
        .writepages = gfs2_jdata_writepages,
        .read_folio = gfs2_read_folio,
        .readahead = gfs2_readahead,