: smp_call_function deadlock
Subsystems (4)
PATCH 1/3 : smp_call_function deadlock
From: Martin Schwidefsky <[email protected]>
From: Heiko Carstens <[email protected]>
From: Ursula Braun <[email protected]>
Calling smp_call_function can lead to a deadlock if it is called from tasklet context.
Fixing this deadlock requires to move the smp_call_function from the tasklet context to a work queue. To do that queue the path pending interrupts to a separate list and move the path cleanup out of iucv_path_sever to iucv_path_connect and iucv_path_pending. This creates a new requirement for iucv_path_connect: it may not be called from tasklet context anymore.
Also fixed compile problem for CONFIG_HOTPLUG_CPU=n and another one when walking the cpu_online mask. When doing this, we must disable cpu hotplug.
---
include/net/iucv/iucv.h | 2 net/iucv/iucv.c | 207 ++++++++++++++++++++++++++++++------------------ 2 files changed, 133 insertions(+), 76 deletions(-)
include/net/iucv/iucv.h +1 -1
@@ -16,7 +16,7 @@* completed a register, it can exploit the other functions. * For furthur reference on all IUCV functionality, refer to the * CP Programming Services book, also available on the web thru -* www.ibm.com/s390/vm/pubs, manual # SC24-5760 +* www.vm.ibm.com/pubs, manual # SC24-6084 * * Definition of Return Codes * - All positive return codes including zero are reflected back
net/iucv/iucv.c +132 -75
426 lines not on this page · raw message
Signature · 1 line
1.5.0.1
From: Frank Pavlic <[email protected]>
Date: Thu, 19 Apr 2007 11:11:45 +0200
Quoted 16 lines
From: Martin Schwidefsky <[email protected]>
From: Heiko Carstens <[email protected]>
From: Ursula Braun <[email protected]>Calling
smp_call_functioncan lead to a deadlock if it is called from tasklet context.
Fixing this deadlock requires to move thesmp_call_functionfrom the tasklet context to a work queue. To do that queue the path pending interrupts to a separate list and move the path cleanup out ofiucv_path_severtoiucv_path_connectandiucv_path_pending. This creates a new requirement foriucv_path_connect: it may not be called from tasklet context anymore.
Also fixed compile problem forCONFIG_HOTPLUG_CPU=nand another one when walking thecpu_onlinemask. When doing this, we must disable cpu hotplug.
Quoted 2 lines
Signed-off-by Frank Pavlic <[email protected]>Signed-off-by Martin Schwidefsky <[email protected]>
Applied, except I had to kick out the HOTPLUT_CPU ifdef removal since that was already done by f8a6d97043f9adc25889876b681998b77f543bfa
Thanks.