On Tue, May 28, 2019 at 08:12:24PM +0200, Markus Armbruster wrote:
> We have a bunch of headers without multiple inclusion guards.  Some are
> clearly intentional, some look accidental.  Too many for me to find out
> by examining each of them, so I'm asking their maintainers.
> 
> Why do I ask?  I'd like to mark the intentional ones and fix the
> accidental ones, so they don't flunk "make check-headers" from "[RFC v4
> 0/7] Baby steps towards saner headers" just because they lack multiple
> inclusion guards.
> 
> Just in case: what's a multiple inclusion guard?  It's
> 
>     #ifndef UNIQUE_GUARD_SYMBOL_H
>     #define UNIQUE_GUARD_SYMBOL_H
>     ...
>     #endif
> 
> with nothing but comments outside the conditional, so that the header
> can safely be included more than once.
> 
> I append the alphabetical list of headers without multiple inclusion
> guards (as reported by scripts/clean-header-guards -nv), followed by the
> same list sorted into maintainer buckets.  If you're cc'ed, please find
> your bucket(s), and tell me which headers intentionally lack guards.
> 
[...]
> X86
> M: Paolo Bonzini <pbonz...@redhat.com>
> M: Richard Henderson <r...@twiddle.net>
> M: Eduardo Habkost <ehabk...@redhat.com>
> target/i386/cc_helper_template.h

Intentional.  See usage at target/i386/cc_helper.c.

> target/i386/helper.h

I believe helper.h intentionally lack guards on all
architectures.  See helper-proto.h, helper-tcg.h,
helper-gen.h.

> target/i386/ops_sse.h

Intentional, see usage at target/i386/fpu_helper.c.

> target/i386/ops_sse_header.h

Intentional, see usage at target/i386/helper.h.

> target/i386/shift_helper_template.h

Intentional, see usage at target/i386/int_helper.c.

> target/i386/whp-dispatch.h

Seems unintentional.

[...]
> Guest CPU Cores (KVM):
> ----------------------
> 
> Overall
> M: Paolo Bonzini <pbonz...@redhat.com>
> include/hw/kvm/clock.h

Seems unintentional.

[...]
> Guest CPU Cores (Xen):
> ----------------------
> 
> X86
> M: Stefano Stabellini <sstabell...@kernel.org>
> M: Anthony Perard <anthony.per...@citrix.com>
> M: Paul Durrant <paul.durr...@citrix.com>
> include/hw/xen/io/ring.h

I see a __XEN_PUBLIC_IO_RING_H__ guard there.  Probably
clean-header-guards.pl is confused by the comments at the end of
the file?

> [...]

-- 
Eduardo

Reply via email to