[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20250213223542.44542e542434158056d3b7ed@kernel.org>
Date: Thu, 13 Feb 2025 22:35:42 +0900
From: Masami Hiramatsu (Google) <mhiramat@...nel.org>
To: Peter Zijlstra <peterz@...radead.org>
Cc: Sami Tolvanen <samitolvanen@...gle.com>, Steven Rostedt
<rostedt@...dmis.org>, "Masami Hiramatsu (Google)" <mhiramat@...nel.org>,
Gabriel de Perthuis <g2p.code@...il.com>, Haiyue Wang <haiyuewa@....com>,
Mark Rutland <mark.rutland@....com>, Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>, Dave Hansen
<dave.hansen@...ux.intel.com>, "H . Peter Anvin" <hpa@...or.com>,
x86@...nel.org, linux-trace-kernel@...r.kernel.org, LKML
<linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] ftrace: x86: Fix a compile error about
get_kernel_nofault()
On Thu, 13 Feb 2025 11:26:34 +0100
Peter Zijlstra <peterz@...radead.org> wrote:
> On Thu, Feb 13, 2025 at 11:08:36AM +0100, Peter Zijlstra wrote:
> > On Wed, Feb 12, 2025 at 08:52:27AM -0800, Sami Tolvanen wrote:
> > > On Tue, Feb 11, 2025 at 7:49 AM Steven Rostedt <rostedt@...dmis.org> wrote:
> > > >
> > > > On Tue, 11 Feb 2025 11:09:14 +0100
> > > > Peter Zijlstra <peterz@...radead.org> wrote:
> > > >
> > > > > I was aiming my patch for x86/core, but if there's a reason to expedite
> > > > > them, I can stick it in x86/urgent I suppose.
> > > > >
> > > > > Just need a reason -- what's this compile error nonsense about, my
> > > > > kernels build just fine?
> > > >
> > > > Masami,
> > > >
> > > > Do you have a config that fails to build without this fix? If so, can you
> > > > please reply with it, and then this can go in as a quick fix.
> > >
> > > x86 builds with both CONFIG_GENDWARFKSYMS and CONFIG_FUNCTION_TRACER
> > > are broken without this fix. Here's how to reproduce:
> > >
> > > $ make defconfig
> > > $ ./scripts/config -e DEBUG_INFO -e DEBUG_INFO_DWARF5 -e MODVERSIONS
> > > -e GENDWARFKSYMS -e FUNCTION_TRACER
> > > $ make olddefconfig && make -j
> > > ...
> > > In file included from ./arch/x86/include/asm/asm-prototypes.h:2,
> > > from <stdin>:3:
> > > ./arch/x86/include/asm/ftrace.h: In function ‘arch_ftrace_get_symaddr’:
> > > ./arch/x86/include/asm/ftrace.h:46:21: error: implicit declaration of
> > > function ‘get_kernel_nofault’ [-Wimplicit-function-declaration]
> > > 46 | if (get_kernel_nofault(instr, (u32
> > > *)(fentry_ip - ENDBR_INSN_SIZE)))
> > > ...
> >
> > It breaks much sooner, complaining about not having dwarf.h.. let me go
> > figure out what package provides that :/
>
> Bah, ofcourse there's libdwarf-dev and libdw-dev, both providing
> dwarf.h. Obviously I installed libdwarf-dev and instead I need libdw-dev
> *hate*
Agreed. :(
>
> Anyway, yes, compile now fails as advertised.
>
> And patch fixes it -- now I need to figure out what to do about urgent,
> because applying it on top of Linus' tree will create conflicts with
> patches already in tip/x86/mm *sigh*.
Hmm, if so, can you pick my patch [1], which does not introduce any
additional header including issue?
[1] https://lore.kernel.org/all/173881156244.211648.1242168038709680511.stgit@devnote2/
Thank you,
>
>
--
Masami Hiramatsu (Google) <mhiramat@...nel.org>
Powered by blists - more mailing lists