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

selftests: move vDSO tests from Documentation/vDSO

Remove vDSO from Makefile to move the to selftests. Update vDSO Makefile
to work under selftests. vDSO will not be run as part of selftests suite
and will not be included in install targets. They can be built separately
for now.

Acked-by: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>

+21 -18
+1 -1
Documentation/Makefile
··· 1 1 subdir-y := accounting auxdisplay blackfin \ 2 2 ia64 laptops mic misc-devices \ 3 - networking pcmcia timers vDSO watchdog 3 + networking pcmcia timers watchdog
Documentation/vDSO/.gitignore tools/testing/selftests/vDSO/.gitignore
-17
Documentation/vDSO/Makefile
··· 1 - ifndef CROSS_COMPILE 2 - # vdso_test won't build for glibc < 2.16, so disable it 3 - # hostprogs-y := vdso_test 4 - hostprogs-$(CONFIG_X86) := vdso_standalone_test_x86 5 - vdso_standalone_test_x86-objs := vdso_standalone_test_x86.o parse_vdso.o 6 - vdso_test-objs := parse_vdso.o vdso_test.o 7 - 8 - # Tell kbuild to always build the programs 9 - always := $(hostprogs-y) 10 - 11 - HOSTCFLAGS := -I$(objtree)/usr/include -std=gnu99 12 - HOSTCFLAGS_vdso_standalone_test_x86.o := -fno-asynchronous-unwind-tables -fno-stack-protector 13 - HOSTLOADLIBES_vdso_standalone_test_x86 := -nostdlib 14 - ifeq ($(CONFIG_X86_32),y) 15 - HOSTLOADLIBES_vdso_standalone_test_x86 += -lgcc_s 16 - endif 17 - endif
Documentation/vDSO/parse_vdso.c tools/testing/selftests/vDSO/parse_vdso.c
Documentation/vDSO/vdso_standalone_test_x86.c tools/testing/selftests/vDSO/vdso_standalone_test_x86.c
Documentation/vDSO/vdso_test.c tools/testing/selftests/vDSO/vdso_test.c
+20
tools/testing/selftests/vDSO/Makefile
··· 1 + ifndef CROSS_COMPILE 2 + CFLAGS := -std=gnu99 3 + CFLAGS_vdso_standalone_test_x86 := -nostdlib -fno-asynchronous-unwind-tables -fno-stack-protector 4 + ifeq ($(CONFIG_X86_32),y) 5 + LDLIBS += -lgcc_s 6 + endif 7 + 8 + TEST_PROGS := vdso_test vdso_standalone_test_x86 9 + 10 + all: $(TEST_PROGS) 11 + vdso_test: parse_vdso.c vdso_test.c 12 + vdso_standalone_test_x86: vdso_standalone_test_x86.c parse_vdso.c 13 + $(CC) $(CFLAGS) $(CFLAGS_vdso_standalone_test_x86) \ 14 + vdso_standalone_test_x86.c parse_vdso.c \ 15 + -o vdso_standalone_test_x86 16 + 17 + include ../lib.mk 18 + clean: 19 + rm -fr $(TEST_PROGS) 20 + endif