Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f934af05 authored by Mark Salter's avatar Mark Salter
Browse files

add memory barrier to arch_local_irq_restore



arch_local_irq_save() and friends are required to act as compiler
memory barriers. This patch adds a "memory" clobber to the inline
asm code in arch_local_irq_restore() which is used as the building
block for other functions needing to set/clear the interrupt enable
in the CSR register.

Signed-off-by: default avatarMark Salter <msalter@redhat.com>
parent 31880c37
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -27,7 +27,7 @@ static inline unsigned long arch_local_save_flags(void)
/* set interrupt enabled status */
static inline void arch_local_irq_restore(unsigned long flags)
{
	asm volatile (" mvc .s2 %0,CSR\n" : : "b"(flags));
	asm volatile (" mvc .s2 %0,CSR\n" : : "b"(flags) : "memory");
}

/* unconditionally enable interrupts */