Skip to content

Commit c9fbaa8

Browse files
t-8chKAGA-KOKO
authored andcommitted
selftests: vDSO: parse_vdso: Use UAPI headers instead of libc headers
To allow the usage of parse_vdso.c together with a limited libc like nolibc, use the kernels own elf.h and auxvec.h headers. Signed-off-by: Thomas Weißschuh <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Reviewed-by: Vincenzo Frascino <[email protected]> Acked-by: Shuah Khan <[email protected]> Link: https://lore.kernel.org/all/[email protected]
1 parent 09dcec6 commit c9fbaa8

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

tools/testing/selftests/vDSO/Makefile

+3
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ LDLIBS += -lgcc_s
1919
endif
2020

2121
include ../lib.mk
22+
23+
CFLAGS += $(TOOLS_INCLUDES)
24+
2225
$(OUTPUT)/vdso_test_gettimeofday: parse_vdso.c vdso_test_gettimeofday.c
2326
$(OUTPUT)/vdso_test_getcpu: parse_vdso.c vdso_test_getcpu.c
2427
$(OUTPUT)/vdso_test_abi: parse_vdso.c vdso_test_abi.c

tools/testing/selftests/vDSO/parse_vdso.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@
1919
#include <stdint.h>
2020
#include <string.h>
2121
#include <limits.h>
22-
#include <elf.h>
22+
#include <linux/auxvec.h>
23+
#include <linux/elf.h>
2324

2425
#include "parse_vdso.h"
2526

0 commit comments

Comments
 (0)