git://ftp.safe.ca
/
safe
/
jmp
/
linux-2.6
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
[PATCH] filemap_getpage can block when MAP_NONBLOCK specified
[safe/jmp/linux-2.6]
/
mm
/
filemap.c
diff --git
a/mm/filemap.c
b/mm/filemap.c
index
439b2be
..
93595c3
100644
(file)
--- a/
mm/filemap.c
+++ b/
mm/filemap.c
@@
-1379,8
+1379,13
@@
retry_find:
* Ok, found a page in the page cache, now we need to check
* that it's up-to-date.
*/
- if (!PageUptodate(page))
+ if (!PageUptodate(page)) {
+ if (nonblock) {
+ page_cache_release(page);
+ return NULL;
+ }
goto page_not_uptodate;
+ }
success:
/*