]> Git Repo - linux.git/commit
cfq: explicitly use 64bit divide operation for 64bit arguments
authorAnatol Pomozov <[email protected]>
Sun, 22 Sep 2013 18:43:47 +0000 (12:43 -0600)
committerJens Axboe <[email protected]>
Sun, 22 Sep 2013 18:43:47 +0000 (12:43 -0600)
commitf3cff25f05f2ac29b2ee355e611b0657482f6f1d
tree8a06c59f0970a8bd4be2939792fc88ffddc39e62
parent75afb352991ff1cd3cf5955bfe611de6d83a0c87
cfq: explicitly use 64bit divide operation for 64bit arguments

'samples' is 64bit operant, but do_div() second parameter is 32.
do_div silently truncates high 32 bits and calculated result
is invalid.

In case if low 32bit of 'samples' are zeros then do_div() produces
kernel crash.

Signed-off-by: Anatol Pomozov <[email protected]>
Acked-by: Tejun Heo <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
block/cfq-iosched.c
This page took 0.051842 seconds and 4 git commands to generate.