aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/kernel
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2005-02-10 07:00:06 -0500
committerRalf Baechle <ralf@linux-mips.org>2005-10-29 14:30:30 -0400
commit57f0060b8a2bb2a70a4cce1a37d5e0158cea92a6 (patch)
treef2cca6d9bc63b4f180739e9f2a86db0f0e2d7d86 /arch/mips/kernel
parent26852d5cdb2bac01f2a48b815194a045e8a8e300 (diff)
Document why calling smp_call_function will deadlock when called with
interrupts disabled. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/kernel')
-rw-r--r--arch/mips/kernel/smp.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/arch/mips/kernel/smp.c b/arch/mips/kernel/smp.c
index af5cd3b8a396..1d3a4b501949 100644
--- a/arch/mips/kernel/smp.c
+++ b/arch/mips/kernel/smp.c
@@ -121,7 +121,19 @@ struct call_data_struct *call_data;
121 * or are or have executed. 121 * or are or have executed.
122 * 122 *
123 * You must not call this function with disabled interrupts or from a 123 * You must not call this function with disabled interrupts or from a
124 * hardware interrupt handler or from a bottom half handler. 124 * hardware interrupt handler or from a bottom half handler:
125 *
126 * CPU A CPU B
127 * Disable interrupts
128 * smp_call_function()
129 * Take call_lock
130 * Send IPIs
131 * Wait for all cpus to acknowledge IPI
132 * CPU A has not responded, spin waiting
133 * for cpu A to respond, holding call_lock
134 * smp_call_function()
135 * Spin waiting for call_lock
136 * Deadlock Deadlock
125 */ 137 */
126int smp_call_function (void (*func) (void *info), void *info, int retry, 138int smp_call_function (void (*func) (void *info), void *info, int retry,
127 int wait) 139 int wait)