Re: [PATCH v4 01/10] objtool: Handle various symbol types of rodata

From: Josh Poimboeuf
Date: Tue Nov 26 2024 - 19:52:16 EST


On Tue, Nov 26, 2024 at 06:41:29PM +0800, Tiezhu Yang wrote:
> On 11/26/2024 02:44 PM, Josh Poimboeuf wrote:
> > On Fri, Nov 22, 2024 at 12:49:56PM +0800, Tiezhu Yang wrote:
> > > @@ -2094,12 +2095,19 @@ static int add_jump_table(struct objtool_file *file, struct instruction *insn,
> >
> > 'prev_offset' needs to be updated as well.
>
> I am not sure I understand your comment correctly, I can not see
> what should to do about 'prev_offset'.

Further down the function there is

prev_offset = reloc_offset(reloc);

which needs to be changed to

prev_offset = offset;

as part of the patch.

--
Josh