1
0
Fork 0

realtime-virtual-guest: re-assign kernel thread priorities

From 63e5ebfe0c71c5e6d0613c4d8327b2a6f3fba7ba Mon Sep 17 00:00:00 2001
From: Luiz Capitulino <lcapitulino@redhat.com>
Date: Fri, 19 May 2017 14:42:06 -0400
Subject:

The realtime guest profile uses the RT kernel default priority
assignment for the ksoftird, rcuc, and ktimersoftd kernel threads,
which is:

    17  FF   2  [rcuc/1] *
    19  FF   1  [ktimersoftd/1] *
    20  TS   -  [ksoftirqd/1] *

This doesn't allow running a PMD thread with fifo:1 in the
guest, since this will starve ktimersoftd and ksoftirqd if
those threads ever become runnable.

The solution is to use the same priority assigment we use
in the host where we've been running PMD threads with
fifo:1 priorities without problems. This assignment is:

   151  FF   4  [rcuc/15] *
   153  FF   3  [ktimersoftd/15] *
   154  FF   2  [ksoftirqd/15] *

This patch just copies the [scheduler] section from the
host profile.

Resolves: rhbz#1452357

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
This commit is contained in:
Luiz Capitulino 2017-05-19 15:10:19 -04:00 committed by Jaroslav Škarvada
parent 4483641602
commit 1ab378cc4a

View file

@ -20,6 +20,20 @@ isolated_cores_present_expanded=${f:cpulist_present:${isolated_cores}}
# Fail if isolated_cores contains CPUs which are not present
assert2=${f:assertion:isolated_cores contains present CPU(s):${isolated_cores_expanded}:${isolated_cores_present_expanded}}
[scheduler]
# group.group_name=rule_priority:scheduler_policy:scheduler_priority:core_affinity_in_hex:process_name_regex
# for i in `pgrep ksoftirqd` ; do grep Cpus_allowed_list /proc/$i/status ; done
group.ksoftirqd=0:f:2:*:ksoftirqd.*
# for i in `pgrep rcuc` ; do grep Cpus_allowed_list /proc/$i/status ; done
group.rcuc=0:f:4:*:rcuc.*
# for i in `pgrep rcub` ; do grep Cpus_allowed_list /proc/$i/status ; done
group.rcub=0:f:4:*:rcub.*
# for i in `pgrep ktimersoftd` ; do grep Cpus_allowed_list /proc/$i/status ; done
group.ktimersoftd=0:f:3:*:ktimersoftd.*
[script]
script=${i:PROFILE_DIR}/script.sh