From: Stefan Weinhuber Date: Wed, 11 Feb 2009 09:37:31 +0000 (+0100) Subject: [S390] dasd: fix race in dasd timer handling X-Git-Tag: v2.6.29-rc5~36^2~1 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=48cae885d5a896030588978f503c73c5ed5e62b1;p=pandora-kernel.git [S390] dasd: fix race in dasd timer handling In dasd_device_set_timer and dasd_block_set_timer we interpret the return value of mod_timer in a wrong way. If the timer expires in the small window between our check of timer_pending and the call to mod_timer, then the timer will be set, mod_timer returns zero and we will call add_timer for a timer that is already pending. As del_timer and mod_timer do all the necessary checking themselves, we can simplify our code and remove the race a the same time. Signed-off-by: Stefan Weinhuber Signed-off-by: Martin Schwidefsky --- Reading git-diff-tree failed