Re: [patch 08/24] x86/entry: Convert Divide Error to IDTENTRY

From: Thomas Gleixner
Date: Wed Mar 04 2020 - 08:10:16 EST


Alexandre Chartre <alexandre.chartre@xxxxxxxxxx> writes:
> On 2/25/20 11:16 PM, Thomas Gleixner wrote:
>> +/* Simple exception entries: */
>> +DECLARE_IDTENTRY(X86_TRAP_DE, exc_divide_error);
>> +
>
> I think this macro has a tricky behavior because it will declare C functions
> when included in a C file, and define assembly idtentry when included in an
> assembly file.
>
> I see your point which is to have a single statement which provides both C
> and assembly functions, but this dual behavior is not obvious when reading
> the code. Maybe add a comment to explain this behavior?

Done.