On 24.10.2023 21:59, Stefano Stabellini wrote: > If I understood correctly I am fine with that. To make sure we are all > on the same page, can you provide a couple of samples?
Taking the earlier example, instead of DRIVERS_PASSTHROUGH_VTD_DMAR_H it would then be VTD_DMAR_H. arch/x86/pv/mm.h would use PV_MM_H, but then you can already see that a hypothetical arch/x86/mm.h would use X86_MM_H, thus colliding with what your proposal would also yield for arch/x86/include/asm/mm.h. So maybe private header guards should come with e.g. a trailing underscore? Or double underscores as component separators, where .../include/... use only single underscores? Or headers in arch/*/include/asm/ use ASM_<name>_H (i.e. not making the architecture explicit in the guard name, on the grounds that headers from multiple architectures shouldn't be included at the same time)? Jan