From 11d1f1c43b820a4bb163bdde54025a21bd561dac Mon Sep 17 00:00:00 2001 From: Adriaan Schmidt Date: Tue, 23 Jan 2024 15:21:35 +0100 Subject: [PATCH] scheduler: add option for ignoring IRQs affinity This adds the [scheduler] plugin option `irq_process`, which controls whether the plugin performs any tuning of IRQ affinities. Resolves: RHEL-21923 Signed-off-by: Adriaan Schmidt --- tuned/plugins/plugin_scheduler.py | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/tuned/plugins/plugin_scheduler.py b/tuned/plugins/plugin_scheduler.py index 9b0467b1a..85d615159 100644 --- a/tuned/plugins/plugin_scheduler.py +++ b/tuned/plugins/plugin_scheduler.py @@ -169,6 +169,12 @@ class SchedulerPlugin(base.Plugin): Isolate CPUs 2-4 while ignoring processes and threads matching `ps_blacklist` regular expressions. ==== + The [option]`irq_process` option controls whether the scheduler plugin + applies the `isolated_cores` parameter to IRQ affinities. The default + value is `true`, which means that the scheduler plugin will move all + possible IRQs away from the isolated cores. When `irq_process` is set + to `false`, the plugin will not change any IRQ affinities. + ==== The [option]`default_irq_smp_affinity` option controls the values *TuneD* writes to `/proc/irq/default_smp_affinity`. The file specifies default affinity mask that applies to all non-active IRQs. Once an @@ -444,6 +450,7 @@ def __init__(self, monitor_repository, storage_factory, hardware_inventory, devi self._cpus = perf.cpu_map() self._scheduler_storage_key = self._storage_key( command_name = "scheduler") + self._irq_process = True self._irq_storage_key = self._storage_key( command_name = "irq") self._evlist = None @@ -543,6 +550,7 @@ def _get_config_options(cls): "cgroup_ps_blacklist": None, "ps_whitelist": None, "ps_blacklist": None, + "irq_process": True, "default_irq_smp_affinity": "calc", "perf_mmap_pages": None, "perf_process_fork": "false", @@ -1126,6 +1134,14 @@ def _ps_blacklist(self, enabling, value, verify, ignore_missing): if enabling and value is not None: self._ps_blacklist = "|".join(["(%s)" % v for v in re.split(r"(?