cfq-iosched: fix possible problem with jiffies wraparound
authorCorrado Zoccolo <czoccolo@gmail.com>
Mon, 5 Oct 2009 06:49:23 +0000 (08:49 +0200)
committerJens Axboe <jens.axboe@oracle.com>
Mon, 5 Oct 2009 09:03:55 +0000 (11:03 +0200)
commit48e025e63ac908ed6ec5394a294f4ecd510a7476
tree49828c00687c810627f00430dd56ce9901537fc9
parent30996f40bffe73f05abb92a4cec254befa8cecf7
cfq-iosched: fix possible problem with jiffies wraparound

The RR service tree is indexed by a key that is relative to current jiffies.
This can cause problems on jiffies wraparound.

The patch fixes it using time_before comparison, and changing
the add_front path to use a relative number, too.

Signed-off-by: Corrado Zoccolo <czoccolo@gmail.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
block/cfq-iosched.c