summaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/ftrace/test.d/functions
diff options
context:
space:
mode:
authorMasami Hiramatsu <mhiramat@kernel.org>2018-08-30 23:17:10 +0900
committerShuah Khan (Samsung OSG) <shuah@kernel.org>2018-10-24 14:49:35 -0600
commitcec3adf5f57160d829a033bcb578c3dd0a90c693 (patch)
tree32b7e492316f480588b0017f10db5d811f938893 /tools/testing/selftests/ftrace/test.d/functions
parent72ce3daf92ba4f5bae6e91095d40e67b367c6b2f (diff)
downloadtalos-op-linux-cec3adf5f57160d829a033bcb578c3dd0a90c693.tar.gz
talos-op-linux-cec3adf5f57160d829a033bcb578c3dd0a90c693.zip
selftests/ftrace: Use loopback address instead of localhost
Use raw loopback address instead of localhost, because "localhost" can depend on nsswitch and in some case we can not resolve the localhost. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Shuah Khan (Samsung OSG) <shuah@kernel.org>
Diffstat (limited to 'tools/testing/selftests/ftrace/test.d/functions')
-rw-r--r--tools/testing/selftests/ftrace/test.d/functions6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/testing/selftests/ftrace/test.d/functions b/tools/testing/selftests/ftrace/test.d/functions
index b2bfa4dd43f7..7b96e80e6b8a 100644
--- a/tools/testing/selftests/ftrace/test.d/functions
+++ b/tools/testing/selftests/ftrace/test.d/functions
@@ -103,3 +103,9 @@ initialize_ftrace() { # Reset ftrace to initial-state
clear_trace
enable_tracing
}
+
+LOCALHOST=127.0.0.1
+
+yield() {
+ ping $LOCALHOST -c 1 || sleep .001 || usleep 1 || sleep 1
+}
OpenPOWER on IntegriCloud