Thread (24 messages) 24 messages, 4 authors, 2017-01-04

Re: [PATCH v4 02/12] powerpc: move set_soft_enabled() and rename

flat view

From: Balbir Singh <bsingharora@gmail.com>
Date: 2016-12-20 09:04:02


On 19/12/16 19:06, Madhavan Srinivasan wrote:
Move set_soft_enabled() from powerpc/kernel/irq.c to
asm/hw_irq.c, to force updates to paca-soft_enabled
done via these access function. Add "memory" clobber
to hint compiler since paca->soft_enabled memory is the target
here
+static inline notrace void soft_enabled_set(unsigned long enable)
+{
+	__asm__ __volatile__("stb %0,%1(13)"
+	: : "r" (enable), "i" (offsetof(struct paca_struct, soft_enabled))
+	: "memory");
+}
+
Can't we just rewrite this in "C"?

local_paca->soft_enabled = enable

Balbir Singh.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help