Lines Matching refs:rela

114 	struct rela *rela;  in ignore_func()  local
117 if (file->whitelist && file->whitelist->rela) in ignore_func()
118 list_for_each_entry(rela, &file->whitelist->rela->rela_list, list) { in ignore_func()
119 if (rela->sym->type == STT_SECTION && in ignore_func()
120 rela->sym->sec == func->sec && in ignore_func()
121 rela->addend == func->offset) in ignore_func()
123 if (rela->sym->type == STT_FUNC && rela->sym == func) in ignore_func()
336 struct rela *rela; in add_dead_ends() local
355 list_for_each_entry(rela, &sec->rela_list, list) { in add_dead_ends()
356 if (rela->sym->type != STT_SECTION) { in add_dead_ends()
360 insn = find_insn(file, rela->sym->sec, rela->addend); in add_dead_ends()
363 else if (rela->addend == rela->sym->sec->len) { in add_dead_ends()
366 if (insn->sec == rela->sym->sec) { in add_dead_ends()
374 rela->sym->sec->name, rela->addend); in add_dead_ends()
379 rela->sym->sec->name, rela->addend); in add_dead_ends()
397 list_for_each_entry(rela, &sec->rela_list, list) { in add_dead_ends()
398 if (rela->sym->type != STT_SECTION) { in add_dead_ends()
402 insn = find_insn(file, rela->sym->sec, rela->addend); in add_dead_ends()
405 else if (rela->addend == rela->sym->sec->len) { in add_dead_ends()
408 if (insn->sec == rela->sym->sec) { in add_dead_ends()
416 rela->sym->sec->name, rela->addend); in add_dead_ends()
421 rela->sym->sec->name, rela->addend); in add_dead_ends()
463 struct rela *rela; in add_nospec_ignores() local
470 list_for_each_entry(rela, &sec->rela_list, list) { in add_nospec_ignores()
471 if (rela->sym->type != STT_SECTION) { in add_nospec_ignores()
476 insn = find_insn(file, rela->sym->sec, rela->addend); in add_nospec_ignores()
494 struct rela *rela; in add_jump_destinations() local
506 rela = find_rela_by_dest_range(insn->sec, insn->offset, in add_jump_destinations()
508 if (!rela) { in add_jump_destinations()
511 } else if (rela->sym->type == STT_SECTION) { in add_jump_destinations()
512 dest_sec = rela->sym->sec; in add_jump_destinations()
513 dest_off = rela->addend + 4; in add_jump_destinations()
514 } else if (rela->sym->sec->idx) { in add_jump_destinations()
515 dest_sec = rela->sym->sec; in add_jump_destinations()
516 dest_off = rela->sym->sym.st_value + rela->addend + 4; in add_jump_destinations()
517 } else if (strstr(rela->sym->name, "_indirect_thunk_")) { in add_jump_destinations()
581 struct rela *rela; in add_call_destinations() local
587 rela = find_rela_by_dest_range(insn->sec, insn->offset, in add_call_destinations()
589 if (!rela) { in add_call_destinations()
602 } else if (rela->sym->type == STT_SECTION) { in add_call_destinations()
603 insn->call_dest = find_symbol_by_offset(rela->sym->sec, in add_call_destinations()
604 rela->addend+4); in add_call_destinations()
609 rela->sym->sec->name, in add_call_destinations()
610 rela->addend + 4); in add_call_destinations()
614 insn->call_dest = rela->sym; in add_call_destinations()
831 struct rela *table, struct rela *next_table) in add_switch_table()
833 struct rela *rela = table; in add_switch_table() local
839 list_for_each_entry_from(rela, &file->rodata->rela->rela_list, list) { in add_switch_table()
840 if (rela == next_table) in add_switch_table()
844 if (prev_offset && rela->offset != prev_offset + 8) in add_switch_table()
848 if (rela->sym->sec == pfunc->sec && in add_switch_table()
849 rela->addend == pfunc->offset) in add_switch_table()
852 alt_insn = find_insn(file, rela->sym->sec, rela->addend); in add_switch_table()
868 prev_offset = rela->offset; in add_switch_table()
923 static struct rela *find_switch_table(struct objtool_file *file, in find_switch_table()
927 struct rela *text_rela, *rodata_rela; in find_switch_table()
992 struct rela *rela, *prev_rela = NULL; in add_func_switch_tables() local
1016 rela = find_switch_table(file, func, insn); in add_func_switch_tables()
1017 if (!rela) in add_func_switch_tables()
1026 ret = add_switch_table(file, prev_jump, prev_rela, rela); in add_func_switch_tables()
1032 prev_rela = rela; in add_func_switch_tables()
1055 if (!file->rodata || !file->rodata->rela) in add_switch_table_alts()
1075 struct rela *rela; in read_unwind_hints() local
1085 relasec = sec->rela; in read_unwind_hints()
1101 rela = find_rela_by_dest(sec, i * sizeof(*hint)); in read_unwind_hints()
1102 if (!rela) { in read_unwind_hints()
1107 insn = find_insn(file, rela->sym->sec, rela->addend); in read_unwind_hints()
1170 struct rela *rela; in read_retpoline_hints() local
1176 list_for_each_entry(rela, &sec->rela_list, list) { in read_retpoline_hints()
1177 if (rela->sym->type != STT_SECTION) { in read_retpoline_hints()
1182 insn = find_insn(file, rela->sym->sec, rela->addend); in read_retpoline_hints()