Skip to content

Commit

Permalink
kldxref: Handle R_RISCV_CHERI_CAPABILITY
Browse files Browse the repository at this point in the history
As with R_MORELLO_CAPINIT only the address is output.
  • Loading branch information
bsdjhb committed Mar 13, 2024
1 parent 35f9985 commit b260f1c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion usr.sbin/kldxref/ef_riscv.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ ef_riscv_reloc(struct elf_file *ef, const void *reldata, Elf_Type reltype,
le64enc(where, addr);
break;
case R_RISCV_CHERI_CAPABILITY:
warnx("unhandled R_RISCV_CHERI_CAPABILITY relocation");
addr = EF_SYMADDR(ef, symidx) + addend;
le64enc(where, addr);
break;
default:
warnx("unhandled relocation type %d", (int)rtype);
Expand Down

0 comments on commit b260f1c

Please sign in to comment.