2018-09-04 12:03:11 +00:00
|
|
|
From 9f4fc59acf3df854da790da3824c1a3af497c40b Mon Sep 17 00:00:00 2001
|
|
|
|
From: Oliver Smith <osmith@sysmocom.de>
|
|
|
|
Date: Tue, 4 Sep 2018 14:24:52 +0200
|
2017-05-03 20:27:55 +00:00
|
|
|
Subject: [PATCH] disable the use of scheduler priorities and mlockall
|
|
|
|
|
|
|
|
This doesn't work inside of docker, so let's disable it
|
2018-09-04 12:03:11 +00:00
|
|
|
|
|
|
|
(This is the same patch as the one by laforge, just re-applied to
|
|
|
|
current master)
|
2017-05-03 20:27:55 +00:00
|
|
|
---
|
2018-09-04 12:03:11 +00:00
|
|
|
gtests/net/packetdrill/run.c | 4 ++--
|
|
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
2017-05-03 20:27:55 +00:00
|
|
|
|
|
|
|
diff --git a/gtests/net/packetdrill/run.c b/gtests/net/packetdrill/run.c
|
2018-09-04 12:03:11 +00:00
|
|
|
index 8467bb7..9268b50 100644
|
2017-05-03 20:27:55 +00:00
|
|
|
--- a/gtests/net/packetdrill/run.c
|
|
|
|
+++ b/gtests/net/packetdrill/run.c
|
2018-09-04 12:03:11 +00:00
|
|
|
@@ -454,7 +454,7 @@ void set_scheduling_priority(void)
|
2017-05-03 20:27:55 +00:00
|
|
|
if (num_cpus <= 1)
|
|
|
|
return;
|
|
|
|
|
2018-09-04 12:03:11 +00:00
|
|
|
-#if !defined(__OpenBSD__) && !defined(__APPLE__)
|
2017-05-03 20:27:55 +00:00
|
|
|
+#if 0
|
|
|
|
/* Chose a real-time policy, but use SCHED_RR instead of
|
|
|
|
* SCHED_FIFO, so that we round-robin among real-time threads
|
|
|
|
* of the same priority. In practice this shouldn't matter,
|
2018-09-04 12:03:11 +00:00
|
|
|
@@ -481,7 +481,7 @@ void set_scheduling_priority(void)
|
2017-05-03 20:27:55 +00:00
|
|
|
*/
|
|
|
|
void lock_memory(void)
|
|
|
|
{
|
2018-09-04 12:03:11 +00:00
|
|
|
-#if !defined(__APPLE__)
|
2017-05-03 20:27:55 +00:00
|
|
|
+#if 0
|
|
|
|
if (mlockall(MCL_CURRENT | MCL_FUTURE))
|
2018-09-04 12:03:11 +00:00
|
|
|
die_perror("mlockall(MCL_CURRENT | MCL_FUTURE)");
|
|
|
|
#endif
|
2017-05-03 20:27:55 +00:00
|
|
|
--
|
2018-09-04 12:03:11 +00:00
|
|
|
2.17.1
|
2017-05-03 20:27:55 +00:00
|
|
|
|