aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-02-01 10:56:37 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-02-01 10:56:37 +0000
commitc20d06defed83f2b209046160df16cfc7f27106f (patch)
treeea747a43c3ca8e8daf217b21d27504e7fa25fb57
parent32b59703102952cfdae5520f9070cf3040f3a3fe (diff)
parent475310ebadc8484df509a3d66833b97dcd254178 (diff)
downloadlinux-kselftest-platform-tools-34.0.1.tar.gz
Snap for 9550355 from 475310ebadc8484df509a3d66833b97dcd254178 to sdk-releaseplatform-tools-34.0.1platform-tools-34.0.0platform-tools-33.0.4
Change-Id: If2c88ac805226267d660ac1cae49a7a66c7ddfce
-rw-r--r--Android.bp23
-rw-r--r--OWNERS2
-rw-r--r--TEST_MAPPING38
-rw-r--r--android/README.md14
-rw-r--r--android/kselftest_test_list.mk2
-rw-r--r--tools/testing/selftests/vDSO/vdso_test_getcpu.c4
-rw-r--r--tools/testing/selftests/vDSO/vdso_test_gettimeofday.c3
7 files changed, 78 insertions, 8 deletions
diff --git a/Android.bp b/Android.bp
index 8841d8a32f9d..5398c3976467 100644
--- a/Android.bp
+++ b/Android.bp
@@ -93,6 +93,12 @@ cc_defaults {
no_named_install_directory: true,
test_per_src: true,
+
+ // FIXME: test fails to build with LTO
+ // http://b/241723066
+ lto: {
+ never: true,
+ },
}
// binderfs test
@@ -115,6 +121,9 @@ cc_test {
arm: {
enabled: false,
},
+ riscv64: {
+ enabled: false,
+ },
arm64: {
srcs: [
"tools/testing/selftests/breakpoints/breakpoint_test_arm64.c",
@@ -662,6 +671,8 @@ cc_test {
"tools/testing/selftests/vm/mlock-random-test.c",
"tools/testing/selftests/vm/mlock2-tests.c",
"tools/testing/selftests/vm/on-fault-limit.c",
+ "tools/testing/selftests/vm/mremap_dontunmap.c",
+ "tools/testing/selftests/vm/mremap_test.c",
"tools/testing/selftests/vm/userfaultfd.c",
"tools/testing/selftests/vm/thuge-gen.c",
"tools/testing/selftests/vm/transhuge-stress.c",
@@ -731,6 +742,9 @@ cc_test {
"libdl",
],
},
+ riscv64: {
+ enabled: false,
+ },
},
cflags: [
"-O2",
@@ -761,6 +775,9 @@ cc_test {
x86_64: {
enabled: true,
},
+ riscv64: {
+ enabled: false,
+ },
},
cflags: [
"-O2",
@@ -832,6 +849,9 @@ cc_test {
"tools/testing/selftests/x86/thunks.S",
],
},
+ riscv64: {
+ enabled: false,
+ },
},
}
@@ -856,6 +876,9 @@ cc_test {
x86: {
enabled: true,
},
+ riscv64: {
+ enabled: false,
+ },
},
}
diff --git a/OWNERS b/OWNERS
index 3ae489ae8e6c..ba3dfce78e91 100644
--- a/OWNERS
+++ b/OWNERS
@@ -1,3 +1,3 @@
drosen@google.com
-smuckle@google.com
+edliaw@google.com
willmcvicker@google.com
diff --git a/TEST_MAPPING b/TEST_MAPPING
new file mode 100644
index 000000000000..001fa54e7b35
--- /dev/null
+++ b/TEST_MAPPING
@@ -0,0 +1,38 @@
+{
+ "kernel-presubmit": [
+ {
+ "name": "vts_linux_kselftest_arm_32"
+ },
+ {
+ "name" :"vts_linux_kselftest_arm_64",
+ "options": [
+ {
+ // TODO(b/243948409)
+ "exclude-filter": "net_psock_tpacket_arm_64#net_psock_tpacket_arm_64"
+ }
+ ]
+ },
+ {
+ "name": "vts_linux_kselftest_x86_32",
+ "options": [
+ {
+ // TODO(b/143654050)
+ "exclude-filter": "x86_single_step_syscall_x86_32#x86_single_step_syscall_x86_32"
+ },
+ {
+ // TODO(b/182363365)
+ "exclude-filter": "x86_syscall_nt_x86_32"
+ }
+ ]
+ },
+ {
+ "name": "vts_linux_kselftest_x86_64",
+ "options": [
+ {
+ // TODO(b/191663053)
+ "exclude-filter": "x86_single_step_syscall_x86_64"
+ }
+ ]
+ }
+ ]
+}
diff --git a/android/README.md b/android/README.md
index 7a12a1d3aa21..e375af098980 100644
--- a/android/README.md
+++ b/android/README.md
@@ -11,8 +11,8 @@ at tools/testing/selftests. The tests cover a broad range of areas but total
coverage (as of 4.14 anyway) is very spotty. Many of the tests do not apply to
Android platforms.
-As of mid 2018 there are 23 tests in kselftest which run on ARM in VTS.
-Almost all of them get executed in both 32-bit and 64-bit mode. There are many
+As of Jan 2023 there are 31 tests in kselftest which run on ARM in VTS.
+22 of these tests are executed in both 32-bit and 64-bit mode. There are many
tests which are not enabled because they have dependencies which are not met on
Android platforms.
@@ -42,13 +42,13 @@ Running Kselftest through atest
You can run Kselftest tests with atest, which handles all the setup and build steps.
To run all 32 bit Kselftest tests:
-* `atest vts_linux_kselftest_arm`
+* `atest -a vts_linux_kselftest_arm_32`
To run all 64 bit Kselftest tests:
-* `atest vts_linux_kselftest_arm_64`
+* `atest -a vts_linux_kselftest_arm_64`
To run a single test:
-* `atest vts_linux_kselftest_arm_64:timers_valid-adjtimex_arm_64`
+* `atest -a vts_linux_kselftest_arm_64:timers_valid-adjtimex_arm_64`
Running Kselftest through VTS
-----------------------------
@@ -103,8 +103,8 @@ platform and are unsure if they are safe you should run them in emulation, in a
virtualized environment, or on a dedicated development x86 platform.
To run Kselftest tests for x86 platform, you can do:
-* `atest vts_linux_kselftest_x86`
-* `atest vts_linux_kselftest_x86_64`
+* `atest -a vts_linux_kselftest_x86_32`
+* `atest -a vts_linux_kselftest_x86_64`
Sending Fixes Upstream
----------------------
diff --git a/android/kselftest_test_list.mk b/android/kselftest_test_list.mk
index c0c9ee934ba0..e9b8b7b1db33 100644
--- a/android/kselftest_test_list.mk
+++ b/android/kselftest_test_list.mk
@@ -61,6 +61,8 @@ kselftest_modules += \
kselftest_vdso_test_gettimeofday \
kselftest_vm_tests_mlock2-tests \
kselftest_vm_tests_on-fault-limit \
+ kselftest_vm_tests_mremap_dontunmap \
+ kselftest_vm_tests_mremap_test \
kselftest_vm_tests_userfaultfd \
kselftest_vm64_tests_virtual_address_range \
kselftest_x86_ptrace_syscall \
diff --git a/tools/testing/selftests/vDSO/vdso_test_getcpu.c b/tools/testing/selftests/vDSO/vdso_test_getcpu.c
index fc25ede131b8..1df5d057d79f 100644
--- a/tools/testing/selftests/vDSO/vdso_test_getcpu.c
+++ b/tools/testing/selftests/vDSO/vdso_test_getcpu.c
@@ -14,7 +14,11 @@
#include "../kselftest.h"
#include "parse_vdso.h"
+#if defined(__riscv)
+const char *version = "LINUX_4.15";
+#else
const char *version = "LINUX_2.6";
+#endif
const char *name = "__vdso_getcpu";
struct getcpu_cache;
diff --git a/tools/testing/selftests/vDSO/vdso_test_gettimeofday.c b/tools/testing/selftests/vDSO/vdso_test_gettimeofday.c
index 8ccc73ed8240..e411f287a426 100644
--- a/tools/testing/selftests/vDSO/vdso_test_gettimeofday.c
+++ b/tools/testing/selftests/vDSO/vdso_test_gettimeofday.c
@@ -27,6 +27,9 @@
#if defined(__aarch64__)
const char *version = "LINUX_2.6.39";
const char *name = "__kernel_gettimeofday";
+#elif defined(__riscv)
+const char *version = "LINUX_4.15";
+const char *name = "__vdso_gettimeofday";
#else
const char *version = "LINUX_2.6";
const char *name = "__vdso_gettimeofday";