diff options
author | Chris Metcalf <cmetcalf@tilera.com> | 2011-11-02 23:02:17 -0400 |
---|---|---|
committer | Chris Metcalf <cmetcalf@tilera.com> | 2011-11-03 16:58:54 -0400 |
commit | eb7c792da5afa3b9ec3e802c30952f82d2e9722b (patch) | |
tree | db796193297d4cc14bdb4d2b8001750a1f515f17 /arch/tile/kernel/traps.c | |
parent | aeddea5d37d86d38c7a347110d8a052e9f45d955 (diff) |
arch/tile: factor out <arch/opcode.h> header
The kernel code was using some <asm> headers that included a mix
of hardware-specific information (typically found in Tilera <arch>
headers) and structures, enums, and function declarations supporting
the disassembly function of the tile-desc.c sources.
This change refactors that code so that a hardware-specific, but
OS- and application-agnostic header, is created: <arch/opcode.h>.
This header is then exported to userspace along with the other
<arch> headers and can be used to build userspace code; in particular,
it is used by glibc as part of implementing the backtrace() function.
The new header, together with a header that specifically describes
the disassembly code (<asm/tile-desc.h> with _32 and _64 variants),
replaces the old <asm/opcode-tile*.h> and <asm/opcode_constants*.h>
headers.
As part of this change, we are also renaming the 32-bit constants
from TILE_xxx to TILEPRO_xxx to better reflect the fact that they
are specific to the TILEPro architecture, and not to TILE-Gx
and any successor "tile" architecture chips.
Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
Diffstat (limited to 'arch/tile/kernel/traps.c')
-rw-r--r-- | arch/tile/kernel/traps.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/arch/tile/kernel/traps.c b/arch/tile/kernel/traps.c index f9803dfa7357..4f47b8a356df 100644 --- a/arch/tile/kernel/traps.c +++ b/arch/tile/kernel/traps.c | |||
@@ -19,13 +19,12 @@ | |||
19 | #include <linux/reboot.h> | 19 | #include <linux/reboot.h> |
20 | #include <linux/uaccess.h> | 20 | #include <linux/uaccess.h> |
21 | #include <linux/ptrace.h> | 21 | #include <linux/ptrace.h> |
22 | #include <asm/opcode-tile.h> | ||
23 | #include <asm/opcode_constants.h> | ||
24 | #include <asm/stack.h> | 22 | #include <asm/stack.h> |
25 | #include <asm/traps.h> | 23 | #include <asm/traps.h> |
26 | 24 | ||
27 | #include <arch/interrupts.h> | 25 | #include <arch/interrupts.h> |
28 | #include <arch/spr_def.h> | 26 | #include <arch/spr_def.h> |
27 | #include <arch/opcode.h> | ||
29 | 28 | ||
30 | void __init trap_init(void) | 29 | void __init trap_init(void) |
31 | { | 30 | { |
@@ -135,7 +134,7 @@ static int special_ill(bundle_bits bundle, int *sigp, int *codep) | |||
135 | if (get_UnaryOpcodeExtension_X1(bundle) != ILL_UNARY_OPCODE_X1) | 134 | if (get_UnaryOpcodeExtension_X1(bundle) != ILL_UNARY_OPCODE_X1) |
136 | return 0; | 135 | return 0; |
137 | #else | 136 | #else |
138 | if (bundle & TILE_BUNDLE_Y_ENCODING_MASK) | 137 | if (bundle & TILEPRO_BUNDLE_Y_ENCODING_MASK) |
139 | return 0; | 138 | return 0; |
140 | if (get_Opcode_X1(bundle) != SHUN_0_OPCODE_X1) | 139 | if (get_Opcode_X1(bundle) != SHUN_0_OPCODE_X1) |
141 | return 0; | 140 | return 0; |