Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

selftests: tdx: Use installed kernel headers search path

Use $(KHDR_INCLUDES) as lookup path for installed kernel headers rather
than using kernel headers in include/uapi from the source kernel tree
kernel headers.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: Shuah Khan <shuah@kernel.org>
Cc: linux-kselftest@vger.kernel.org
Cc: Ingo Molnar <mingo@redhat.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>

authored by

Mathieu Desnoyers and committed by
Shuah Khan
5adbe55c 4c983a14

+2 -2
+1 -1
tools/testing/selftests/tdx/Makefile
··· 1 1 # SPDX-License-Identifier: GPL-2.0 2 2 3 - CFLAGS += -O3 -Wl,-no-as-needed -Wall -static 3 + CFLAGS += -O3 -Wl,-no-as-needed -Wall $(KHDR_INCLUDES) -static 4 4 5 5 TEST_GEN_PROGS := tdx_guest_test 6 6
+1 -1
tools/testing/selftests/tdx/tdx_guest_test.c
··· 12 12 #include <errno.h> 13 13 #include <fcntl.h> 14 14 15 + #include <linux/tdx-guest.h> 15 16 #include "../kselftest_harness.h" 16 - #include "../../../../include/uapi/linux/tdx-guest.h" 17 17 18 18 #define TDX_GUEST_DEVNAME "/dev/tdx_guest" 19 19 #define HEX_DUMP_SIZE 8