All of lore.kernel.org
 help / color / mirror / Atom feed
* [merged] vfs-__read_cache_page-should-use-gfp-argument-rather-than-gfp_kernel.patch removed from -mm tree
@ 2011-12-22 19:49 akpm
  0 siblings, 0 replies; only message in thread
From: akpm @ 2011-12-22 19:49 UTC (permalink / raw)
  To: dave.kleikamp, hughd, stable, viro, mm-commits


The patch titled
     Subject: vfs: __read_cache_page() should use gfp argument rather than GFP_KERNEL
has been removed from the -mm tree.  Its filename was
     vfs-__read_cache_page-should-use-gfp-argument-rather-than-gfp_kernel.patch

This patch was dropped because it was merged into mainline or a subsystem tree

The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/

------------------------------------------------------
From: Dave Kleikamp <dave.kleikamp@oracle.com>
Subject: vfs: __read_cache_page() should use gfp argument rather than GFP_KERNEL

lockdep reports a deadlock in jfs because a special inode's rw semaphore
is taken recursively.  The mapping's gfp mask is GFP_NOFS, but is not used
when __read_cache_page() calls add_to_page_cache_lru().

Signed-off-by: Dave Kleikamp <dave.kleikamp@oracle.com>
Acked-by: Hugh Dickins <hughd@google.com>
Acked-by: Al Viro <viro@zeniv.linux.org.uk>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 mm/filemap.c |    7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff -puN mm/filemap.c~vfs-__read_cache_page-should-use-gfp-argument-rather-than-gfp_kernel mm/filemap.c
--- a/mm/filemap.c~vfs-__read_cache_page-should-use-gfp-argument-rather-than-gfp_kernel
+++ a/mm/filemap.c
@@ -1814,7 +1814,7 @@ repeat:
 		page = __page_cache_alloc(gfp | __GFP_COLD);
 		if (!page)
 			return ERR_PTR(-ENOMEM);
-		err = add_to_page_cache_lru(page, mapping, index, GFP_KERNEL);
+		err = add_to_page_cache_lru(page, mapping, index, gfp);
 		if (unlikely(err)) {
 			page_cache_release(page);
 			if (err == -EEXIST)
@@ -1911,10 +1911,7 @@ static struct page *wait_on_page_read(st
  * @gfp:	the page allocator flags to use if allocating
  *
  * This is the same as "read_mapping_page(mapping, index, NULL)", but with
- * any new page allocations done using the specified allocation flags. Note
- * that the Radix tree operations will still use GFP_KERNEL, so you can't
- * expect to do this atomically or anything like that - but you can pass in
- * other page requirements.
+ * any new page allocations done using the specified allocation flags.
  *
  * If the page does not get brought uptodate, return -EIO.
  */
_

Patches currently in -mm which might be from dave.kleikamp@oracle.com are

origin.patch


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

only message in thread, other threads:[~2011-12-22 20:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-22 19:49 [merged] vfs-__read_cache_page-should-use-gfp-argument-rather-than-gfp_kernel.patch removed from -mm tree akpm

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.