X-Git-Url: https://jxself.org/git/?p=b43-tools.git;a=blobdiff_plain;f=disassembler%2Fmain.c;h=718e33fcb013874a7ccf28a0ef13dd547878a465;hp=8e6415ed875ee8ca98b9068f9786bf5aff772f14;hb=f981680e63cf6efb80b270d5ba2d30ffcbbf0ef4;hpb=1c0560b49eb2c403d0d0fa99f789f13f750a40d8 diff --git a/disassembler/main.c b/disassembler/main.c index 8e6415e..718e33f 100644 --- a/disassembler/main.c +++ b/disassembler/main.c @@ -539,9 +539,13 @@ static void disasm_opcodes(struct disassembler_context *ctx) snprintf(str, 5, "0x%02X", (bin->opcode & 0x0FF)); stmt->u.insn.operands[0] = str; - disasm_std_operand(stmt, 0, 1, 0); - disasm_std_operand(stmt, 1, 2, 0); - stmt->u.insn.is_labelref = 3; + /* We don't disassemble the first and second operand, as + * that always is a dummy r0 operand. + * disasm_std_operand(stmt, 0, 1, 0); + * disasm_std_operand(stmt, 1, 2, 0); + * stmt->u.insn.is_labelref = 3; + */ + stmt->u.insn.is_labelref = 1; stmt->u.insn.labeladdr = stmt->u.insn.bin->operands[2]; break; case 0x700: @@ -551,9 +555,13 @@ static void disasm_opcodes(struct disassembler_context *ctx) snprintf(str, 5, "0x%02X", (bin->opcode & 0x0FF)); stmt->u.insn.operands[0] = str; - disasm_std_operand(stmt, 0, 1, 0); - disasm_std_operand(stmt, 1, 2, 0); - stmt->u.insn.is_labelref = 3; + /* We don't disassemble the first and second operand, as + * that always is a dummy r0 operand. + * disasm_std_operand(stmt, 0, 1, 0); + * disasm_std_operand(stmt, 1, 2, 0); + * stmt->u.insn.is_labelref = 3; + */ + stmt->u.insn.is_labelref = 1; stmt->u.insn.labeladdr = stmt->u.insn.bin->operands[2]; break; default: