On Mon, 2022-09-26 at 14:54 +0000, Christophe Leroy wrote: > > diff --git a/arch/powerpc/kernel/static_call.c > > b/arch/powerpc/kernel/static_call.c > > index 863a7aa24650..ecbb74e1b4d3 100644 > > --- a/arch/powerpc/kernel/static_call.c > > +++ b/arch/powerpc/kernel/static_call.c > > @@ -4,30 +4,108 @@ > > > > #include <asm/code-patching.h> > > > > +static void* ppc_function_toc(u32 *func) > > +{ > > +#ifdef CONFIG_PPC64_ELF_ABI_V2 > > Can you use IS_ENABLED(CONFIG_PPC64_ELF_ABI_V2) instead ?
I tried when implementing it, but the `(u64) func` cast is an issue. I could side step it and use `unsigned long` if that's preferable? Otherwise I like being explicit about the size, it's a delicate function.