Re: [PATCH v2 1/8] x86, syscalls: Refactor SYSCALL_DEFINEx macros

From: Dominik Brodowski
Date: Tue Feb 25 2020 - 16:19:59 EST


Thanks for the updated series! Looks nicer to me now.

> +#ifdef CONFIG_X86_64
> +#define __X64_SYS_STUBx(x, sys_name, ...) \
> + __SYS_STUBx(x64, sys_name, \
> + SC_X86_64_REGS_TO_ARGS(x, __VA_ARGS__))

I'd say it's easier to read if "name" is passed to this macro, and it is
expanded to sys_##name only within this macro...

> +#define __IA32_COMPAT_SYS_STUBx(x, compat_sys_name, ...) \
> + __SYS_STUBx(ia32, compat_sys_name, \
> + SC_IA32_REGS_TO_ARGS(x, __VA_ARGS__))

... and in particular here (with compat_sys)

> +#define __IA32_SYS_STUBx(x, sys_name, ...) \
> + __SYS_STUBx(ia32, sys_name, \
> + SC_IA32_REGS_TO_ARGS(x, __VA_ARGS__))

... same here

> +#define __X32_COMPAT_SYS_STUBx(x, compat_sys_name, ...) \
> + __SYS_STUBx(x32, compat_sys_name, \
> + SC_X86_64_REGS_TO_ARGS(x, __VA_ARGS__))

... and here.

Otherwise, a nice cleanup!

Thanks,
Dominik