aboutsummaryrefslogtreecommitdiffstats
path: root/fs/9p
diff options
context:
space:
mode:
authorJim Garlick <garlick@llnl.gov>2012-01-03 16:27:50 -0500
committerEric Van Hensbergen <ericvh@gmail.com>2012-01-05 11:51:44 -0500
commita0ea787b027b79cf2e01c6758e5246db06520158 (patch)
treeb3066e9a557e5add9dc99ee9f763fcf7c3926b5f /fs/9p
parent805a6af8dba5dfdd35ec35dc52ec0122400b2610 (diff)
fs/9p: check schedule_timeout_interruptible return value
In v9fs_file_do_lock() we need to check return value of schedule_timeout_interruptible() and exit the loop when it returns nonzero, otherwise the loop is not really interruptible and after the signal, the loop is no longer throttled by P9_LOCK_TIMEOUT. Signed-off-by: Jim Garlick <garlick.jim@gmail.com> Signed-off-by: Eric Van Hensbergen <ericvh@gmail.com>
Diffstat (limited to 'fs/9p')
-rw-r--r--fs/9p/vfs_file.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/9p/vfs_file.c b/fs/9p/vfs_file.c
index 62857a810a79..a7ac45d5bd2c 100644
--- a/fs/9p/vfs_file.c
+++ b/fs/9p/vfs_file.c
@@ -204,7 +204,8 @@ static int v9fs_file_do_lock(struct file *filp, int cmd, struct file_lock *fl)
204 break; 204 break;
205 if (status == P9_LOCK_BLOCKED && !IS_SETLKW(cmd)) 205 if (status == P9_LOCK_BLOCKED && !IS_SETLKW(cmd))
206 break; 206 break;
207 schedule_timeout_interruptible(P9_LOCK_TIMEOUT); 207 if (schedule_timeout_interruptible(P9_LOCK_TIMEOUT) != 0)
208 break;
208 } 209 }
209 210
210 /* map 9p status to VFS status */ 211 /* map 9p status to VFS status */