Skip to contentSkip to conversation

AVR32: nmi_enter() without nmi_exit()

PATCH Applied Manfred Spraul 2 participants 2 messages Aug 20, 2008 – Sep 19, 2008

lore
Share & tools
lore
#0 lore raw

Hi Haavard,

You are listed as the maintainer for AVR32. If someone else is doing that now, could you forward the mail?

While updating the rcu code, I noticed that do_nmi() for AVR32 is odd:
There is an nmi_enter() call without an nmi_exit().
This can't be correct, it breaks rcu (at least the preempt version) and lockdep.

Attached is a patch, not tested at all.

--
Manfred

arch/avr32/kernel/traps.c +3 -3
index b835c4c..c39cdfc 100644
@@ -120,11 +120,11 @@ asmlinkage void do_nmi(unsigned long ecr, struct pt_regs *regs)
 	case NOTIFY_BAD:
 		die("Fatal Non-Maskable Interrupt", regs, SIGINT);
 	default:
+		printk(KERN_ALERT "Got NMI, but nobody cared. Disabling...\n");
+		nmi_disable();
 		break;
 	}
-
-	printk(KERN_ALERT "Got NMI, but nobody cared. Disabling...\n");
-	nmi_disable();
+	nmi_exit();
 }
 
 asmlinkage void do_critical_exception(unsigned long ecr, struct pt_regs *regs)
#1 lore raw
Quoted 9 lines · Manfred Spraul

You are listed as the maintainer for AVR32. If someone else is doing that now, could you forward the mail?

While updating the rcu code, I noticed that do_nmi() for AVR32 is odd:
There is an nmi_enter() call without an nmi_exit().
This can't be correct, it breaks rcu (at least the preempt version) and lockdep.

Attached is a patch, not tested at all.

Totally forgot about this, sorry.

Applied, thanks.

Haavard