Skip to content

Commit

Permalink
s390/tape: Use del_timer_sync()
Browse files Browse the repository at this point in the history
del_timer() does not wait for a possible running callback to
complete. So the call side might free request and the associated
objects while on another cpu the timer handler runs.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Thomas Gleixner authored and Martin Schwidefsky committed Apr 1, 2014
1 parent bd1cb5d commit 02ba8d2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/s390/char/tape_std.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ tape_std_assign(struct tape_device *device)

rc = tape_do_io_interruptible(device, request);

del_timer(&timeout);
del_timer_sync(&timeout);

if (rc != 0) {
DBF_EVENT(3, "%08x: assign failed - device might be busy\n",
Expand Down

0 comments on commit 02ba8d2

Please sign in to comment.