Re: [PATCH 1/3] objtool: Separate prefix code from stack validation code

From: Josh Poimboeuf
Date: Thu Apr 13 2023 - 11:27:44 EST


On Thu, Apr 13, 2023 at 11:30:31AM +0200, Peter Zijlstra wrote:
> On Wed, Apr 12, 2023 at 01:26:13PM -0700, Josh Poimboeuf wrote:
> > Simplify the prefix code and make it a standalone feature.
>
> The main thing being that you moved it all after
> validate_reachable_instructions() ?

The main thing being that I extricated it from validate_symbol() so it's
a proper independent feature.

> > +static int add_prefix_symbols(struct objtool_file *file)
> > +{
> > + struct section *sec;
> > + struct symbol *func;
> > + int ret, warnings = 0;
> > +
> > + for_each_sec(file, sec) {
> > + if (!(sec->sh.sh_flags & SHF_EXECINSTR))
> > + continue;
> > +
> > + list_for_each_entry(func, &sec->symbol_list, list) {
>
> One of the other patches did a sec_for_each_symbol() thing.

Too many patch sets floating around ;-)

--
Josh