Lines Matching refs:location
57 static int apply_r_larch_none(struct module *mod, u32 *location, Elf_Addr v,
63 static int apply_r_larch_error(struct module *me, u32 *location, Elf_Addr v,
70 static int apply_r_larch_32(struct module *mod, u32 *location, Elf_Addr v,
73 *location = v;
77 static int apply_r_larch_64(struct module *mod, u32 *location, Elf_Addr v,
80 *(Elf_Addr *)location = v;
84 static int apply_r_larch_sop_push_pcrel(struct module *mod, u32 *location, Elf_Addr v,
87 return rela_stack_push(v - (u64)location, rela_stack, rela_stack_top);
90 static int apply_r_larch_sop_push_absolute(struct module *mod, u32 *location, Elf_Addr v,
96 static int apply_r_larch_sop_push_dup(struct module *mod, u32 *location, Elf_Addr v,
116 Elf_Shdr *sechdrs, u32 *location, Elf_Addr v,
119 ptrdiff_t offset = (void *)v - (void *)location;
127 return apply_r_larch_sop_push_pcrel(mod, location, v, rela_stack, rela_stack_top, type);
130 static int apply_r_larch_sop(struct module *mod, u32 *location, Elf_Addr v,
176 static int apply_r_larch_sop_imm_field(struct module *mod, u32 *location, Elf_Addr v,
181 union loongarch_instruction *insn = (union loongarch_instruction *)location;
249 *location = (u32)opr1;
267 static int apply_r_larch_add_sub(struct module *mod, u32 *location, Elf_Addr v,
272 *(s32 *)location += v;
275 *(s64 *)location += v;
278 *(s32 *)location -= v;
281 *(s64 *)location -= v;
290 Elf_Shdr *sechdrs, u32 *location, Elf_Addr v,
293 ptrdiff_t offset = (void *)v - (void *)location;
294 union loongarch_instruction *insn = (union loongarch_instruction *)location;
302 offset = (void *)v - (void *)location;
323 static int apply_r_larch_pcala(struct module *mod, u32 *location, Elf_Addr v,
326 union loongarch_instruction *insn = (union loongarch_instruction *)location;
329 (void *)((Elf_Addr)location & ~0xfff);
330 Elf_Addr anchor = (((Elf_Addr)location) & ~0xfff) + offset_hi20;
358 Elf_Shdr *sechdrs, u32 *location, Elf_Addr v,
378 return apply_r_larch_pcala(mod, location, got, rela_stack, rela_stack_top, type);
381 static int apply_r_larch_32_pcrel(struct module *mod, u32 *location, Elf_Addr v,
384 ptrdiff_t offset = (void *)v - (void *)location;
386 *(u32 *)location = offset;
390 static int apply_r_larch_64_pcrel(struct module *mod, u32 *location, Elf_Addr v,
393 ptrdiff_t offset = (void *)v - (void *)location;
395 *(u64 *)location = offset;
402 * @location: the address at which the reloc is to be applied
409 typedef int (*reloc_rela_handler)(struct module *mod, u32 *location, Elf_Addr v,
441 void *location;
452 location = (void *)sechdrs[sechdrs[relsec].sh_info].sh_addr + rel[i].r_offset;
477 sym->st_value, rel[i].r_addend, (u64)location);
482 err = apply_r_larch_b26(mod, sechdrs, location,
486 err = apply_r_larch_got_pc(mod, sechdrs, location,
490 err = apply_r_larch_sop_push_plt_pcrel(mod, sechdrs, location,
494 err = handler(mod, location, v, rela_stack, &rela_stack_top, type);