From: Michael Buesch Date: Sun, 11 Nov 2007 01:38:44 +0000 (+0100) Subject: assembler: Fix label-immediate for v15 X-Git-Tag: b43-fwcutter-013~86 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=84bcfa9ab4ca53f62758026107eb5776e9417ce8;p=b43-tools.git assembler: Fix label-immediate for v15 Signed-off-by: Michael Buesch --- diff --git a/assembler/main.c b/assembler/main.c index 2c47493..701721d 100644 --- a/assembler/main.c +++ b/assembler/main.c @@ -947,8 +947,16 @@ recalculate_addresses: if (addr < 0) goto does_not_exist; c->operands[i].u.operand = addr; - if (i != 2) /* Is not a jump target */ - c->operands[i].u.operand |= 0xC00; /* Make it be an immediate */ + if (i != 2) { + /* Is not a jump target. + * Make it be an immediate */ + if (ctx->arch == 5) + c->operands[i].u.operand |= 0xC00; + else if (ctx->arch == 15) + c->operands[i].u.operand |= 0xC00 << 1; + else + asm_error(ctx, "Internal error: label res imm"); + } } break; case OUT_LABEL: