diff options
author | Michel Lespinasse <walken@google.com> | 2010-11-02 13:05:18 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-11-02 17:02:31 -0400 |
commit | d88c0922fa0e2c021a028b310a641126c6d4b7dc (patch) | |
tree | f6e74b391a526c845cbe44bbc5e6585256a4d097 /mm/filemap.c | |
parent | eb8abb927ae2fd1730e24ea94cd9527f3c086292 (diff) |
Release page reference during page fault retry
This slipped by when unifying the filemap and swap versions of
lock_page_or_retry()...
Signed-off-by: Michel Lespinasse <walken@google.com>
Acked-by: Rik van Riel <riel@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/filemap.c')
-rw-r--r-- | mm/filemap.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mm/filemap.c b/mm/filemap.c index 75572b5f237..61ba5e40579 100644 --- a/mm/filemap.c +++ b/mm/filemap.c @@ -1563,8 +1563,10 @@ retry_find: goto no_cached_page; } - if (!lock_page_or_retry(page, vma->vm_mm, vmf->flags)) + if (!lock_page_or_retry(page, vma->vm_mm, vmf->flags)) { + page_cache_release(page); return ret | VM_FAULT_RETRY; + } /* Did it get truncated? */ if (unlikely(page->mapping != mapping)) { |