Re: [PATCH v4 2/2] powerpc: Uprobes port to powerpc

From
Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date
2012-08-23 10:07:37
Also in
lkml
Reply to
Srikar Dronamraju, 2012-08-23
On Thu, 2012-08-23 at 11:02 +0530, Srikar Dronamraju wrote:
quoted
insn is updated/accessed in the arch independent code. Size of
uprobe_opcode_t could be different for different archs.
uprobe_opcode_t
represents the size of the smallest breakpoint instruction for an
arch.

Hence u8 works out the best. I know we could still use uprobe_opcode_t
and achieve the same. In which case, we would have to interpret
MAX_UINSN_BYTES differently. Do you see any advantages of using
uprobe_opcode_t instead of u8 across archs?
But don't you actively rely on the fact that on powerpc, unlike x86, you
-can- atomically replace an instruction with a single 32-bit store ?

If you don't you should consider it, and that makes defining this as a
u8 array non-sensical (as is using memcpy)

Ben.
Thread (15 messages) 15 messages, 5 authors, last reply 2012-08-24
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help