diff options
Diffstat (limited to 'fs/nfs/pagelist.c')
-rw-r--r-- | fs/nfs/pagelist.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/fs/nfs/pagelist.c b/fs/nfs/pagelist.c index e2975939126a..a12c45b65dd4 100644 --- a/fs/nfs/pagelist.c +++ b/fs/nfs/pagelist.c | |||
@@ -176,6 +176,12 @@ void nfs_release_request(struct nfs_page *req) | |||
176 | kref_put(&req->wb_kref, nfs_free_request); | 176 | kref_put(&req->wb_kref, nfs_free_request); |
177 | } | 177 | } |
178 | 178 | ||
179 | static int nfs_wait_bit_uninterruptible(void *word) | ||
180 | { | ||
181 | io_schedule(); | ||
182 | return 0; | ||
183 | } | ||
184 | |||
179 | /** | 185 | /** |
180 | * nfs_wait_on_request - Wait for a request to complete. | 186 | * nfs_wait_on_request - Wait for a request to complete. |
181 | * @req: request to wait upon. | 187 | * @req: request to wait upon. |
@@ -186,14 +192,9 @@ void nfs_release_request(struct nfs_page *req) | |||
186 | int | 192 | int |
187 | nfs_wait_on_request(struct nfs_page *req) | 193 | nfs_wait_on_request(struct nfs_page *req) |
188 | { | 194 | { |
189 | int ret = 0; | 195 | return wait_on_bit(&req->wb_flags, PG_BUSY, |
190 | 196 | nfs_wait_bit_uninterruptible, | |
191 | if (!test_bit(PG_BUSY, &req->wb_flags)) | 197 | TASK_UNINTERRUPTIBLE); |
192 | goto out; | ||
193 | ret = out_of_line_wait_on_bit(&req->wb_flags, PG_BUSY, | ||
194 | nfs_wait_bit_killable, TASK_KILLABLE); | ||
195 | out: | ||
196 | return ret; | ||
197 | } | 198 | } |
198 | 199 | ||
199 | /** | 200 | /** |