Re: [PATCH 21/29] objtool: Rename --duplicate to --lto

From: Miroslav Benes
Date: Tue Mar 01 2022 - 09:19:58 EST


On Mon, 28 Feb 2022, Josh Poimboeuf wrote:

> On Mon, Feb 28, 2022 at 09:09:34PM +0100, Peter Zijlstra wrote:
> > > So how about we just get rid of the magical --vmlinux and --lto options
> > > altogether, and make --noinstr additive, like all the other options?
> > >
> > > A) legacy mode:
> > > .o files: objtool check [--module]
> > > vmlinux: N/A
> > > module: N/A
> > >
> > > B) CONFIG_NOINSTR_VALIDATION=y && !(CONFIG_X86_KERNEL_IBT=y || CONFIG_LTO=y):
> > > .o files: objtool check [--module]
> > > vmlinux: objtool check --noinstr-only
> > > module: objtool check --module --noinstr-only
> > >
> > > C) CONFIG_X86_KERNEL_IBT=y || CONFIG_LTO=y:
> > > .o files: N/A
> > > vmlinux: objtool check --noinstr
> > > module: objtool check --module --noinstr
> >
> > I like the --noinstr-only thing. But I think I still like a flag to
> > differentiate between TU/.o file and vmlinux/whole-module invocation.
>
> I'm missing why that would still be useful.
>
> > Anyway, you ok with me cleaning this up later, in a separate series?
>
> Sure. It's already less than ideal today anyway, with '--vmlinux' and
> '--duplicate'.

Since I always have hard times to figure out different passes and options
of objtool, could you add the above description (its final version) to
tools/objtool/Documentation/ as a part of the cleanup series, please?

Miroslav