Re: [PATCH V3 3/9] objtool: Add support for intra-function calls

From: Miroslav Benes
Date: Thu Apr 16 2020 - 08:12:53 EST


> +static int configure_call(struct objtool_file *file, struct instruction *insn)
> +{
> + unsigned long dest_off;
> +
> + dest_off = insn->offset + insn->len + insn->immediate;
> + insn->call_dest = find_func_by_offset(insn->sec, dest_off);
> + if (!insn->call_dest)
> + insn->call_dest = find_symbol_by_offset(insn->sec, dest_off);
> +
> + if (insn->call_dest) {
> + /* regular call */
> + if (insn->func && insn->call_dest->type != STT_FUNC) {
> + WARN_FUNC("unsupported call to non-function",
> + insn->sec, insn->offset);
> + return -1;
> + }
> + return 0;
> + }
> +
> + /* intra-function call */
> + if (!insn->intra_function_call)
> + WARN_FUNC("intra-function call", insn->sec, insn->offset);

"unsupported intra-function call" ?

Miroslav