summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--benchmarks/intel_upload_blit_large.c6
-rw-r--r--lib/drmtest.h9
-rw-r--r--lib/igt_core.c2
-rw-r--r--lib/igt_core.h2
-rw-r--r--lib/igt_debugfs.c1
-rw-r--r--lib/igt_kms.c6
-rw-r--r--lib/igt_kms.h2
-rw-r--r--lib/ioctl_wrappers.c1
-rw-r--r--tests/core_getclient.c3
-rw-r--r--tests/core_getstats.c5
-rw-r--r--tests/gem_ctx_bad_destroy.c2
-rw-r--r--tests/gem_ctx_create.c2
-rw-r--r--tests/gem_fenced_exec_thrash.c4
-rw-r--r--tests/gem_flink_race.c1
-rw-r--r--tests/gem_reg_read.c2
-rw-r--r--tests/gem_seqno_wrap.c1
-rw-r--r--tests/gem_vmap_blits.c1
-rw-r--r--tests/igt_simulation.c1
-rw-r--r--tests/pm_psr.c2
-rw-r--r--tests/pm_rc6_residency.c2
-rw-r--r--tests/pm_rps.c1
-rw-r--r--tests/prime_udl.c3
22 files changed, 47 insertions, 12 deletions
diff --git a/benchmarks/intel_upload_blit_large.c b/benchmarks/intel_upload_blit_large.c
index b44433f9..40bdbcfb 100644
--- a/benchmarks/intel_upload_blit_large.c
+++ b/benchmarks/intel_upload_blit_large.c
@@ -53,8 +53,10 @@
#include <errno.h>
#include <sys/stat.h>
#include <sys/time.h>
-#include "drm.h"
-#include "i915_drm.h"
+
+#include <drm.h>
+#include <i915_drm.h>
+
#include "drmtest.h"
#include "intel_bufmgr.h"
#include "intel_batchbuffer.h"
diff --git a/lib/drmtest.h b/lib/drmtest.h
index 4c55068e..97d60d0c 100644
--- a/lib/drmtest.h
+++ b/lib/drmtest.h
@@ -28,16 +28,13 @@
#ifndef DRMTEST_H
#define DRMTEST_H
-#include <stdio.h>
-#include <stdlib.h>
#include <unistd.h>
-#include <errno.h>
#include <stdbool.h>
+#include <stdint.h>
#include <sys/mman.h>
-#include "xf86drm.h"
-#include "xf86drmMode.h"
-#include "intel_batchbuffer.h"
+#include <xf86drm.h>
+#include <intel_batchbuffer.h>
#ifdef ANDROID
#ifndef HAVE_MMAP64
diff --git a/lib/igt_core.c b/lib/igt_core.c
index efcc4a11..81e37313 100644
--- a/lib/igt_core.c
+++ b/lib/igt_core.c
@@ -48,9 +48,9 @@
#include <sys/syscall.h>
#include <sys/utsname.h>
#include <termios.h>
+#include <errno.h>
#include "drmtest.h"
-#include "i915_drm.h"
#include "intel_chipset.h"
#include "intel_gpu_tools.h"
#include "igt_debugfs.h"
diff --git a/lib/igt_core.h b/lib/igt_core.h
index 47576da6..7ede0d37 100644
--- a/lib/igt_core.h
+++ b/lib/igt_core.h
@@ -32,8 +32,10 @@
#include <setjmp.h>
#include <stdbool.h>
+#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
+#include <stdarg.h>
bool __igt_fixture(void);
void __igt_fixture_complete(void);
diff --git a/lib/igt_debugfs.c b/lib/igt_debugfs.c
index f467ce0f..96adf396 100644
--- a/lib/igt_debugfs.c
+++ b/lib/igt_debugfs.c
@@ -27,6 +27,7 @@
#include <sys/mount.h>
#include <errno.h>
#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
#include <fcntl.h>
#include <unistd.h>
diff --git a/lib/igt_kms.c b/lib/igt_kms.c
index 88ee83be..f74f7070 100644
--- a/lib/igt_kms.c
+++ b/lib/igt_kms.c
@@ -23,14 +23,18 @@
*/
#define _GNU_SOURCE
+#include <unistd.h>
#include <stdio.h>
#include <stdarg.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <string.h>
+#include <stdlib.h>
#include <math.h>
#include <linux/kd.h>
-#include "drm_fourcc.h"
+#include <errno.h>
+
+#include <drm_fourcc.h>
#include "drmtest.h"
#include "igt_kms.h"
diff --git a/lib/igt_kms.h b/lib/igt_kms.h
index d141cfce..95735e8f 100644
--- a/lib/igt_kms.h
+++ b/lib/igt_kms.h
@@ -29,6 +29,8 @@
#include <stdint.h>
#include <cairo.h>
+#include <xf86drmMode.h>
+
#include "igt_display.h"
struct kmstest_connector_config {
diff --git a/lib/ioctl_wrappers.c b/lib/ioctl_wrappers.c
index 147334f3..5806f2a1 100644
--- a/lib/ioctl_wrappers.c
+++ b/lib/ioctl_wrappers.c
@@ -47,6 +47,7 @@
#include <sys/syscall.h>
#include <sys/utsname.h>
#include <termios.h>
+#include <errno.h>
#include "drmtest.h"
#include "i915_drm.h"
diff --git a/tests/core_getclient.c b/tests/core_getclient.c
index 22f0ab2e..ed46e519 100644
--- a/tests/core_getclient.c
+++ b/tests/core_getclient.c
@@ -27,6 +27,9 @@
#include <limits.h>
#include <sys/ioctl.h>
+#include <stdlib.h>
+#include <errno.h>
+
#include "drmtest.h"
/**
diff --git a/tests/core_getstats.c b/tests/core_getstats.c
index cce8271b..1e2c5651 100644
--- a/tests/core_getstats.c
+++ b/tests/core_getstats.c
@@ -27,6 +27,11 @@
#include <limits.h>
#include <sys/ioctl.h>
+#include <sys/types.h>
+
+#include <drm.h>
+
+#include "igt_core.h"
#include "drmtest.h"
/**
diff --git a/tests/gem_ctx_bad_destroy.c b/tests/gem_ctx_bad_destroy.c
index 092f3422..97a70666 100644
--- a/tests/gem_ctx_bad_destroy.c
+++ b/tests/gem_ctx_bad_destroy.c
@@ -31,6 +31,8 @@
#include <stdio.h>
#include <string.h>
+#include <errno.h>
+
#include "ioctl_wrappers.h"
#include "drmtest.h"
diff --git a/tests/gem_ctx_create.c b/tests/gem_ctx_create.c
index f32c2287..57494fc4 100644
--- a/tests/gem_ctx_create.c
+++ b/tests/gem_ctx_create.c
@@ -27,6 +27,8 @@
#include <stdio.h>
#include <string.h>
+#include <errno.h>
+
#include "ioctl_wrappers.h"
#include "drmtest.h"
diff --git a/tests/gem_fenced_exec_thrash.c b/tests/gem_fenced_exec_thrash.c
index cd53cafc..2ba85f2b 100644
--- a/tests/gem_fenced_exec_thrash.c
+++ b/tests/gem_fenced_exec_thrash.c
@@ -33,9 +33,11 @@
#include <string.h>
#include <fcntl.h>
#include <inttypes.h>
+#include <errno.h>
+
#include <drm.h>
-#include "ioctl_wrappers.h"
+#include "ioctl_wrappers.h"
#include "drmtest.h"
#include "intel_chipset.h"
#include "intel_gpu_tools.h"
diff --git a/tests/gem_flink_race.c b/tests/gem_flink_race.c
index 26c71cec..3353b83e 100644
--- a/tests/gem_flink_race.c
+++ b/tests/gem_flink_race.c
@@ -31,6 +31,7 @@
#include <fcntl.h>
#include <unistd.h>
#include <pthread.h>
+#include <errno.h>
#include "drmtest.h"
#include "ioctl_wrappers.h"
diff --git a/tests/gem_reg_read.c b/tests/gem_reg_read.c
index 19f1351b..b4a6650a 100644
--- a/tests/gem_reg_read.c
+++ b/tests/gem_reg_read.c
@@ -27,6 +27,8 @@
#include <stdio.h>
#include <string.h>
+#include <errno.h>
+
#include "ioctl_wrappers.h"
#include "drmtest.h"
diff --git a/tests/gem_seqno_wrap.c b/tests/gem_seqno_wrap.c
index 19c0201e..30d1a868 100644
--- a/tests/gem_seqno_wrap.c
+++ b/tests/gem_seqno_wrap.c
@@ -41,6 +41,7 @@
#include <wordexp.h>
#include <getopt.h>
#include <signal.h>
+#include <errno.h>
#include "ioctl_wrappers.h"
#include "drmtest.h"
diff --git a/tests/gem_vmap_blits.c b/tests/gem_vmap_blits.c
index 4fb2a215..157d6746 100644
--- a/tests/gem_vmap_blits.c
+++ b/tests/gem_vmap_blits.c
@@ -43,6 +43,7 @@
#include <errno.h>
#include <sys/stat.h>
#include <sys/time.h>
+
#include "drm.h"
#include "ioctl_wrappers.h"
#include "drmtest.h"
diff --git a/tests/igt_simulation.c b/tests/igt_simulation.c
index f4007b80..d3331176 100644
--- a/tests/igt_simulation.c
+++ b/tests/igt_simulation.c
@@ -29,6 +29,7 @@
#include <sys/wait.h>
#include <sys/types.h>
#include <assert.h>
+#include <errno.h>
#include "drmtest.h"
#include "igt_core.h"
diff --git a/tests/pm_psr.c b/tests/pm_psr.c
index 5d28c7a5..4ba121f1 100644
--- a/tests/pm_psr.c
+++ b/tests/pm_psr.c
@@ -29,6 +29,8 @@
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include <errno.h>
+
#include "drmtest.h"
#define SLEEP_DURATION 5000 // in milliseconds
diff --git a/tests/pm_rc6_residency.c b/tests/pm_rc6_residency.c
index 3fd9d47e..84eb8a90 100644
--- a/tests/pm_rc6_residency.c
+++ b/tests/pm_rc6_residency.c
@@ -30,6 +30,8 @@
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include <errno.h>
+
#include "drmtest.h"
#define SLEEP_DURATION 3000 // in milliseconds
diff --git a/tests/pm_rps.c b/tests/pm_rps.c
index e6ab3790..1f4b284c 100644
--- a/tests/pm_rps.c
+++ b/tests/pm_rps.c
@@ -34,6 +34,7 @@
#include <getopt.h>
#include <fcntl.h>
#include <signal.h>
+#include <errno.h>
#include "drmtest.h"
#include "intel_gpu_tools.h"
diff --git a/tests/prime_udl.c b/tests/prime_udl.c
index 892a9527..96661fcb 100644
--- a/tests/prime_udl.c
+++ b/tests/prime_udl.c
@@ -24,7 +24,8 @@
#include <errno.h>
#include "xf86drm.h"
-#include "xf86drmMode.h"
+#include <xf86drmMode.h>
+
#include "ioctl_wrappers.h"
#include "intel_bufmgr.h"
#include "intel_gpu_tools.h"