All of lore.kernel.org
 help / color / mirror / Atom feed
* [folded-merged] ceph-convert-ceph_zero_partial_page-to-use-a-folio-fix.patch removed from -mm tree
@ 2025-07-10  4:40 Andrew Morton
  0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2025-07-10  4:40 UTC (permalink / raw)
  To: mm-commits, xiubli, willy, Slava.Dubeyko, ira.weiny, idryomov,
	hch, axboe, amarkuze, dan.carpenter, akpm


The quilt patch titled
     Subject: ceph: fix NULL vs IS_ERR() bug in ceph_zero_partial_page()
has been removed from the -mm tree.  Its filename was
     ceph-convert-ceph_zero_partial_page-to-use-a-folio-fix.patch

This patch was dropped because it was folded into ceph-convert-ceph_zero_partial_page-to-use-a-folio.patch

------------------------------------------------------
From: Dan Carpenter <dan.carpenter@linaro.org>
Subject: ceph: fix NULL vs IS_ERR() bug in ceph_zero_partial_page()
Date: Wed, 25 Jun 2025 10:22:11 -0500

The filemap_lock_folio() never returns NULL.  It returns error pointers.
Update the checking to match.

Link: https://lkml.kernel.org/r/685c1424.050a0220.baa8.d6a1@mx.google.com
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: Viacheslav Dubeyko <Slava.Dubeyko@ibm.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Ilya Dryomov <idryomov@gmail.com>
Cc: Ira Weiny <ira.weiny@intel.com>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: "Matthew Wilcox (Oracle)" <willy@infradead.org>
Cc: Xiubo Li <xiubli@redhat.com>
Cc: Alex Markuze <amarkuze@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 fs/ceph/file.c |   13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

--- a/fs/ceph/file.c~ceph-convert-ceph_zero_partial_page-to-use-a-folio-fix
+++ a/fs/ceph/file.c
@@ -2536,12 +2536,13 @@ static inline void ceph_zero_partial_pag
 	struct folio *folio;
 
 	folio = filemap_lock_folio(inode->i_mapping, offset >> PAGE_SHIFT);
-	if (folio) {
-		folio_wait_writeback(folio);
-		folio_zero_range(folio, offset_in_folio(folio, offset), size);
-		folio_unlock(folio);
-		folio_put(folio);
-	}
+	if (IS_ERR(folio))
+		return;
+
+	folio_wait_writeback(folio);
+	folio_zero_range(folio, offset_in_folio(folio, offset), size);
+	folio_unlock(folio);
+	folio_put(folio);
 }
 
 static void ceph_zero_pagecache_range(struct inode *inode, loff_t offset,
_

Patches currently in -mm which might be from dan.carpenter@linaro.org are

ceph-convert-ceph_zero_partial_page-to-use-a-folio.patch
mmmemory_hotplug-implement-numa-node-notifier-fix.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-07-10  4:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-10  4:40 [folded-merged] ceph-convert-ceph_zero_partial_page-to-use-a-folio-fix.patch removed from -mm tree Andrew Morton

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.