aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Holzheu <holzheu@de.ibm.com>2006-03-24 06:15:27 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-24 10:33:18 -0500
commit4cd190a736a97e302c038bd91357d636369d4c6b (patch)
treec424b0788f70eb3148bc7bedd43008daa3c41560
parent842d3fba94ed94cc5de7b712e0f4218ce6e4fd73 (diff)
[PATCH] s390: tape operation abortion leads to panic
When a request is aborted because of a signal, we currently stop the request via csh, but we do not wait for the interrupt of csh in any case. We free the request structure and therefore when the interrupt for the csh operation is presented, the request object is no longer valid and an invalid callback pointer is used. To fix this wait until the interrupt for csh arrives and until wait_event_interruptible() does not return -ERESTARTSYS. Signed-off-by: Michael Holzheu <holzheu@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--drivers/s390/char/tape_core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/s390/char/tape_core.c b/drivers/s390/char/tape_core.c
index c42f5e25024e..5d17149a6529 100644
--- a/drivers/s390/char/tape_core.c
+++ b/drivers/s390/char/tape_core.c
@@ -1015,7 +1015,7 @@ tape_do_io_interruptible(struct tape_device *device,
1015 wq, 1015 wq,
1016 (request->callback == NULL) 1016 (request->callback == NULL)
1017 ); 1017 );
1018 } while (rc != -ERESTARTSYS); 1018 } while (rc == -ERESTARTSYS);
1019 1019
1020 DBF_EVENT(3, "IO stopped on %08x\n", device->cdev_id); 1020 DBF_EVENT(3, "IO stopped on %08x\n", device->cdev_id);
1021 rc = -ERESTARTSYS; 1021 rc = -ERESTARTSYS;