From: Dave Martin <hidden> Date: 2012-01-31 11:09:40
This patch adds some endianness-agnostic helpers to convert machine
instructions between canonical integer form and in-memory
representation.
A canonical integer form for representing instructions is also
formalised here.
Signed-off-by: Dave Martin <redacted>
Acked-by: Nicolas Pitre <redacted>
---
Changes since v1:
v5: Avoid inclusion of C headers or definition of the __opcode_*
macros when opcodes.h is included in assembler files. Since
the __opcode_* macros rely on C declarations, they are not
directly usable in assembler anyway.
v4: Rebase on top of Leif's patch which created <asm/opcodes.h>
ARM: 7206/1: Add generic ARM instruction set condition code checks.
No functional changes.
v3: Fix some stupid errors:
* remove bogus extra (x) in __opcode_to_mem_arm
* fix use of nonexistent "thumb_opcode" argument in
__opcode_thumb32_{first,second} which causes these
macros to be broken.
v2: Remove unnecessary typedef for arm_opcode_t.
The general "everything is a word" concept works just fine here --
we don't need a typedef, and people will probably not use it
anyway.
arch/arm/include/asm/opcodes.h | 59 ++++++++++++++++++++++++++++++++++++++++
1 files changed, 59 insertions(+), 0 deletions(-)
On Tue, 2012-01-31 at 11:09 +0000, Dave Martin wrote:
This patch adds some endianness-agnostic helpers to convert machine
instructions between canonical integer form and in-memory
representation.
A canonical integer form for representing instructions is also
formalised here.
Signed-off-by: Dave Martin <redacted>
Acked-by: Nicolas Pitre <redacted>
I can confirm this version applies and builds cleanly against
linux-next. And works with Rabin 's jump label support patches.
--
Tixy
quoted hunk
---
Changes since v1:
v5: Avoid inclusion of C headers or definition of the __opcode_*
macros when opcodes.h is included in assembler files. Since
the __opcode_* macros rely on C declarations, they are not
directly usable in assembler anyway.
v4: Rebase on top of Leif's patch which created <asm/opcodes.h>
ARM: 7206/1: Add generic ARM instruction set condition code checks.
No functional changes.
v3: Fix some stupid errors:
* remove bogus extra (x) in __opcode_to_mem_arm
* fix use of nonexistent "thumb_opcode" argument in
__opcode_thumb32_{first,second} which causes these
macros to be broken.
v2: Remove unnecessary typedef for arm_opcode_t.
The general "everything is a word" concept works just fine here --
we don't need a typedef, and people will probably not use it
anyway.
arch/arm/include/asm/opcodes.h | 59 ++++++++++++++++++++++++++++++++++++++++
1 files changed, 59 insertions(+), 0 deletions(-)
From: Dave Martin <hidden> Date: 2012-01-31 18:27:12
On Tue, Jan 31, 2012 at 06:22:20PM +0000, Tixy wrote:
On Tue, 2012-01-31 at 11:09 +0000, Dave Martin wrote:
quoted
This patch adds some endianness-agnostic helpers to convert machine
instructions between canonical integer form and in-memory
representation.
A canonical integer form for representing instructions is also
formalised here.
Signed-off-by: Dave Martin <redacted>
Acked-by: Nicolas Pitre <redacted>
I can confirm this version applies and builds cleanly against
linux-next. And works with Rabin 's jump label support patches.
OK -- thanks. Can I add your Tested-by for completeness?
Cheers
---Dave
--
Tixy
quoted
---
Changes since v1:
v5: Avoid inclusion of C headers or definition of the __opcode_*
macros when opcodes.h is included in assembler files. Since
the __opcode_* macros rely on C declarations, they are not
directly usable in assembler anyway.
v4: Rebase on top of Leif's patch which created <asm/opcodes.h>
ARM: 7206/1: Add generic ARM instruction set condition code checks.
No functional changes.
v3: Fix some stupid errors:
* remove bogus extra (x) in __opcode_to_mem_arm
* fix use of nonexistent "thumb_opcode" argument in
__opcode_thumb32_{first,second} which causes these
macros to be broken.
v2: Remove unnecessary typedef for arm_opcode_t.
The general "everything is a word" concept works just fine here --
we don't need a typedef, and people will probably not use it
anyway.
arch/arm/include/asm/opcodes.h | 59 ++++++++++++++++++++++++++++++++++++++++
1 files changed, 59 insertions(+), 0 deletions(-)
On Tue, 2012-01-31 at 18:27 +0000, Dave Martin wrote:
On Tue, Jan 31, 2012 at 06:22:20PM +0000, Tixy wrote:
quoted
On Tue, 2012-01-31 at 11:09 +0000, Dave Martin wrote:
quoted
This patch adds some endianness-agnostic helpers to convert machine
instructions between canonical integer form and in-memory
representation.
A canonical integer form for representing instructions is also
formalised here.
Signed-off-by: Dave Martin <redacted>
Acked-by: Nicolas Pitre <redacted>
I can confirm this version applies and builds cleanly against
linux-next. And works with Rabin 's jump label support patches.
OK -- thanks. Can I add your Tested-by for completeness?
Yep...
Tested-by: Jon Medhurst <redacted>
--
Tixy
quoted
quoted
---
Changes since v1:
v5: Avoid inclusion of C headers or definition of the __opcode_*
macros when opcodes.h is included in assembler files. Since
the __opcode_* macros rely on C declarations, they are not
directly usable in assembler anyway.
v4: Rebase on top of Leif's patch which created <asm/opcodes.h>
ARM: 7206/1: Add generic ARM instruction set condition code checks.
No functional changes.
v3: Fix some stupid errors:
* remove bogus extra (x) in __opcode_to_mem_arm
* fix use of nonexistent "thumb_opcode" argument in
__opcode_thumb32_{first,second} which causes these
macros to be broken.
v2: Remove unnecessary typedef for arm_opcode_t.
The general "everything is a word" concept works just fine here --
we don't need a typedef, and people will probably not use it
anyway.
arch/arm/include/asm/opcodes.h | 59 ++++++++++++++++++++++++++++++++++++++++
1 files changed, 59 insertions(+), 0 deletions(-)