lkml.org 
[lkml]   [2008]   [Mar]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[Patch (block.git) 1/2] Add irqsave to spinlocks in call function single interrupt

Signed-off-by: Alan D. Brunelle <alan.brunelle@hp.com>
---
kernel/smp.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/kernel/smp.c b/kernel/smp.c
index 852abd3..7232e1c 100644
--- a/kernel/smp.c
+++ b/kernel/smp.c
@@ -24,12 +24,13 @@ void __cpuinit generic_init_call_single_data(void)
void generic_smp_call_function_single_interrupt(void)
{
struct call_single_queue *q;
+ unsigned long flags;
LIST_HEAD(list);

q = &__get_cpu_var(call_single_queue);
- spin_lock(&q->lock);
+ spin_lock_irqsave(&q->lock, flags);
list_replace_init(&q->list, &list);
- spin_unlock(&q->lock);
+ spin_unlock_irqrestore(&q->lock, flags);

while (!list_empty(&list)) {
struct call_single_data *data;
--
1.5.2.5


\
 
 \ /
  Last update: 2008-03-17 17:37    [W:0.061 / U:0.488 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site