For .reloc directive, if the relocation offset is a symbol, then the relocation entry should be placed into relocation section and its sh_info should point to the section where relocation offset symbol at.
Test case:
.text ret nop nop .reloc foo, R_RISCV_32, 6 .data .globl foo foo: .word 0 .word 0 .word 0
The relocation entry should be placed into .reloc.data. And it is also what gnu as does.