mirror of
https://github.com/armbian/linux.git
synced 2026-01-06 10:13:00 -08:00
commita534dbe96eupstream. blk_rq_timed_out_timer() relied on blk_add_timer() never returning a timer value of zero, but commit7838c15b8dremoved the code that bumped this value when it was zero. Therefore when jiffies is near wrap we could get unlucky & not set the timeout value correctly. This patch uses a flag to indicate that the timeout value was set and so handles jiffies wrap correctly, and it keeps all the logic in one function so should be easier to maintain in the future. Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk> Signed-off-by: Jens Axboe <jens.axboe@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>