lkml.org 
[lkml]   [2022]   [Nov]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] x86/asm: Remove unused COMPILE_OFFSETS macro from asm-offsets.c
On Mon, Nov 28, 2022, Paolo Bonzini wrote:
> On 11/28/22 18:45, Steven Rostedt wrote:
> >
> > > > If you are sure <asm/ftrace.h> is never included from asm-offsets.c,
> > > > remove #ifndef COMPILE_OFFSETS too.
> > > It is never included from asm-offsets.c but it is still used by
> > > kvm-asm-offsets.c:
> > > https://elixir.bootlin.com/linux/v6.1-rc7/source/arch/x86/kvm/kvm-asm-offsets.c#L7
> > IIRC, the reason for adding that was because that logic was screwing up
> > asm-offsets.c. I'm not sure it screws up kvm-asm-offsets.c though.
> >
> > This is one of those cases I wish I commented that code better :-/
>
> I don't think KVM includes linux/ftrace.h or asm/ftrace.h at all.

From include/linux/kvm_host.h

#include <linux/ftrace.h>

Even if that didn't exist, saying that XYZ never includes a header is a dangerous
business, it's all too easy to indirectly include headers in the kernel, now or
in the future.

\
 
 \ /
  Last update: 2022-11-28 19:22    [W:0.087 / U:0.212 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site