[PATCH v2] arm: Replace ASSEMBLY with ASSEMBLER in uapi headers

Nick Huang sef1548 at gmail.com
Sat Feb 28 04:45:34 PST 2026


Thomas Weißschuh <linux at weissschuh.net> 於 2026年2月28日週六 下午8:20寫道:

> > diff --git a/arch/arm/include/uapi/asm/ptrace.h b/arch/arm/include/uapi/asm/ptrace.h
> > index 8896c23cc..51cfefeae 100644
> > --- a/arch/arm/include/uapi/asm/ptrace.h
> > +++ b/arch/arm/include/uapi/asm/ptrace.h
> > @@ -119,7 +119,12 @@
> >  #define PT_DATA_ADDR         0x10004
> >  #define PT_TEXT_END_ADDR     0x10008
> >
> > -#ifndef __ASSEMBLY__
> > +#if defined(__GNUC__) && (__GNUC__ <  3)
> > +# error "GCC 3.0+ is required for proper __ASSEMBLER__ support. \
> > +Your compiler is too old to safely handle modern kernel assembly headers."
> > +#endif
>
> Having this check in a random, architecture-specific header does not
> make much sense. It should go into a generic header if we want to have it.
> Or we can have some generic postprocessing in 'headers_install'.
> But as most other architecture UAPI headers already have switched to
> __ASSEMBLER__, it seems nobody will be affected by this, so this check
> should be unnecessary.
>
Hi Thomas Weißschu
I'm aware that other architectures have transitioned to __ASSEMBLER__.
However, I implemented this check here because Maciej W. Rozycki
specifically suggested this approach during our discussion.

-- 
Regards,
Nick Huang



More information about the linux-arm-kernel mailing list