Since the qemu/osdep.h file must be included as the very first header
in all C source files, there is no reason to include it in .h or .c.in
files.

Signed-off-by: Daniel P. Berrangé <berra...@redhat.com>
---
 tests/style.yml | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/tests/style.yml b/tests/style.yml
index 6d91ac6115..d2a0299a33 100644
--- a/tests/style.yml
+++ b/tests/style.yml
@@ -143,3 +143,8 @@ osdep_h_in_source:
     - tests/uefi-test-tools/.*
     - tests/unit/test-rcu-(simpleq|slist|tailq)\.c
     - tools/ebpf/rss.bpf.c
+
+osdep_h_in_header:
+  files: \.(h|c\.inc)$
+  prohibit: '#include "qemu/osdep\.h"'
+  message: only C source files may include qemu/osdep.h
-- 
2.36.1


Reply via email to