lkml.org 
[lkml]   [2021]   [Aug]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v2 2/2] objtool: remove redundant len value from struct section
From
Date
On 8/20/21 3:44 PM, Joe Lawrence wrote:
> [ ... snip ... ]
> diff --git a/tools/objtool/check.c b/tools/objtool/check.c
> [ ... snip ... ]
> @@ -307,8 +307,9 @@ static int decode_instructions(struct objtool_file *file)
> insn->offset = offset;
>
> ret = arch_decode_instruction(file->elf, sec, offset,
> - sec->len - offset,
> - &insn->len, &insn->type,
> + sec->sh.sh_size - offset,
> + &insn->sec->sh.sh_size,
> + &insn->type,
> &insn->immediate,
> &insn->stack_ops);
> if (ret)

Nack! Not sure what I was thinking here. It was Friday afternoon, so I
probably wans't.

Changing insn->len to insn->sec->sh.sh_size is obviously bogus. I'll
correct this part of the patch, do better testing and post v3 on Monday.

Thanks to Andy for reporting.
--
Joe

\
 
 \ /
  Last update: 2021-08-22 03:18    [W:0.049 / U:0.396 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site