Messages in this thread | | | Date | Mon, 8 Nov 2010 16:05:55 -0800 | From | Andrew Morton <> | Subject | Re: [v2][PATCH] [v2] Revalidate page->mapping in do_generic_file_read() |
| |
On Fri, 05 Nov 2010 14:16:15 -0700 Dave Hansen <dave@linux.vnet.ibm.com> wrote:
> --- linux-2.6.git/mm/filemap.c~is_partially_uptodate-revalidate-page 2010-11-03 13:49:21.000000000 -0700 > +++ linux-2.6.git-dave/mm/filemap.c 2010-11-04 06:59:08.000000000 -0700 > @@ -1016,6 +1016,9 @@ find_page: > goto page_not_up_to_date; > if (!trylock_page(page)) > goto page_not_up_to_date; > + /* Did it get truncated before we got the lock? */ > + if (!page->mapping) > + goto page_not_up_to_date_locked; > if (!mapping->a_ops->is_partially_uptodate(page, > desc, offset)) > goto page_not_up_to_date_locked;
whoops.
| |