Re: objtool warning breaks build for fs/dlm/lock.o

From: Josh Poimboeuf
Date: Fri May 08 2020 - 12:29:25 EST


On Fri, May 08, 2020 at 06:26:04PM +0200, Peter Zijlstra wrote:
> On Fri, May 08, 2020 at 11:17:50AM -0500, Josh Poimboeuf wrote:
> > On Fri, May 08, 2020 at 11:55:09AM +0200, Peter Zijlstra wrote:
> > > On Fri, May 08, 2020 at 11:27:39AM +0200, Arnd Bergmann wrote:
> > >
> > > > Right, makes sense. It would be nice though to have a way of intentionally
> > > > turning all objtool warnings into errors. I do my randconfig tests
> > > > with '-Werror'
> > > > at the moment in order to catch all new warnings, but this does not catch
> > > > objtool errors at the moment. For now, this is probably the right thing to do,
> > > > as there are a couple of warnings that I have no patches for, but at some point
> > > > I would prefer to trap immediately when a new warning pops up.
> > >
> > > Completely untested, and I'm 100% unsure of the Makefile change, but
> > > something like so, then?
> >
> > Mostly looks good, but it only errors out on fatal errors, right? For
> > -Werror (and what Arnd is asking about) should it also return error on
> > "warnings > 0"?
>
> Oh, good point. Extra knob or just: if (error && ret) return -1 ?

I think a single knob (hooked up to -Werror) is good enough for now.

--
Josh