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
nfsd: delete wrong file comment from nfsd/nfs4xdr.c
[safe/jmp/linux-2.6]
/
block
/
blk-timeout.c
diff --git
a/block/blk-timeout.c
b/block/blk-timeout.c
index
116bbf3
..
a095353
100644
(file)
--- a/
block/blk-timeout.c
+++ b/
block/blk-timeout.c
@@
-73,11
+73,7
@@
ssize_t part_timeout_store(struct device *dev, struct device_attribute *attr,
*/
void blk_delete_timer(struct request *req)
{
*/
void blk_delete_timer(struct request *req)
{
- struct request_queue *q = req->q;
-
list_del_init(&req->timeout_list);
list_del_init(&req->timeout_list);
- if (list_empty(&q->timeout_list))
- del_timer(&q->timeout);
}
static void blk_rq_timed_out(struct request *req)
}
static void blk_rq_timed_out(struct request *req)
@@
-132,7
+128,12
@@
void blk_rq_timed_out_timer(unsigned long data)
}
}
}
}
- if (next_set && !list_empty(&q->timeout_list))
+ /*
+ * next can never be 0 here with the list non-empty, since we always
+ * bump ->deadline to 1 so we can detect if the timer was ever added
+ * or not. See comment in blk_add_timer()
+ */
+ if (next)
mod_timer(&q->timeout, round_jiffies_up(next));
spin_unlock_irqrestore(q->queue_lock, flags);
mod_timer(&q->timeout, round_jiffies_up(next));
spin_unlock_irqrestore(q->queue_lock, flags);