On Tue, 20 Oct 2009 15:00:23 -0500 Dave Kleikamp <[email protected]> wrote: > I proposed another fix here: > http://bugzilla.kernel.org/show_bug.cgi?id=13613 > > It seems I haven't followed up and submitted it to the vfs maintainer. > Could you please give that patch a try and see if it fixes the problem > for you? >
Your patch fixes the previously reported (old) lockdep problem. I am not able to trigger the lockdep report while it takes a few minutes without the patch. Tested-by: Krzysztof Helt <[email protected]> Your fix I have tested is below: VFS: Fix potential deadlock in __read_cache_page() lockdep reports a potential deadlock when using jfs because add_to_page_cache_lru() is called from __read_cache_page() with GFP_KERNEL. Detailed lockdep output can be found at http://bugzilla.kernel.org/show_bug.cgi?id=13613 Passing mapping_gfp_mask(mapping) instead of GFP_KERNEL fixes the problem. Signed-off-by: Dave Kleikamp <[email protected]> diff --git a/mm/filemap.c b/mm/filemap.c index ccea3b6..59f5406 100644 --- a/mm/filemap.c +++ b/mm/filemap.c @@ -1702,7 +1702,8 @@ repeat: page = page_cache_alloc_cold(mapping); 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, + mapping_gfp_mask(mapping)); if (unlikely(err)) { page_cache_release(page); if (err == -EEXIST) ------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ Jfs-discussion mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/jfs-discussion
