#define MAX_OPCODES 280
-static struct op_code_struct {
+static const struct op_code_struct {
const char *name;
short inst_type; /* registers and immediate values involved */
short inst_offset_type; /* immediate vals offset from PC? (= 1 for branches) */
#if 0
static char * get_field_unsigned_imm (long instr);
#endif
-char * get_field_special (long instr, struct op_code_struct * op);
-unsigned long read_insn_microblaze (bfd_vma memaddr,
- struct disassemble_info *info,
- struct op_code_struct **opr);
static char *
get_field (long instr, long mask, unsigned short low)
}
*/
-char *
-get_field_special (long instr, struct op_code_struct * op)
+static char *
+get_field_special(long instr, const struct op_code_struct *op)
{
char tmpstr[25];
char spr[6];
return(strdup(tmpstr));
}
-unsigned long
+static unsigned long
read_insn_microblaze (bfd_vma memaddr,
struct disassemble_info *info,
- struct op_code_struct **opr)
+ const struct op_code_struct **opr)
{
unsigned char ibytes[4];
int status;
- struct op_code_struct * op;
+ const struct op_code_struct *op;
unsigned long inst;
status = info->read_memory_func (memaddr, ibytes, 4, info);
fprintf_function fprintf_func = info->fprintf_func;
void * stream = info->stream;
unsigned long inst, prev_inst;
- struct op_code_struct * op, *pop;
+ const struct op_code_struct *op, *pop;
int immval = 0;
bfd_boolean immfound = FALSE;
static bfd_vma prev_insn_addr = -1; /*init the prev insn addr */