2021-01-05 17:31:13 +08:00
|
|
|
From 677b686e223c74e64f5b230bdb4079555a5a62a9 Mon Sep 17 00:00:00 2001
|
|
|
|
|
From: ChanderG <mail@chandergovind.org>
|
|
|
|
|
Date: Tue, 25 Aug 2020 15:46:56 +0530
|
|
|
|
|
Subject: [PATCH] add env variable to ban cpus using cpulist syntax
|
|
|
|
|
|
|
|
|
|
allows banning of cpus using the taskset cpulist syntax in addition to the
|
|
|
|
|
bitmap syntax supported via the existing environment variable
|
|
|
|
|
IRQBALANCE_BANNED_CPUS
|
|
|
|
|
|
2021-04-09 14:45:12 +08:00
|
|
|
Conflict:NA
|
|
|
|
|
Reference:https://github.com/Irqbalance/irqbalance/commit/677b686e223c74e64f5b230bdb4079555a5a62a9
|
2021-01-05 17:31:13 +08:00
|
|
|
---
|
|
|
|
|
cputree.c | 6 ++++++
|
|
|
|
|
irqbalance.1 | 6 ++++++
|
|
|
|
|
2 files changed, 12 insertions(+)
|
|
|
|
|
|
|
|
|
|
diff --git a/cputree.c b/cputree.c
|
|
|
|
|
index 0433657..00cf47f 100644
|
|
|
|
|
--- a/cputree.c
|
|
|
|
|
+++ b/cputree.c
|
|
|
|
|
@@ -127,6 +127,12 @@ static void setup_banned_cpus(void)
|
|
|
|
|
goto out;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
+ env = getenv("IRQBALANCE_BANNED_CPULIST");
|
|
|
|
|
+ if (env && strlen(env)) {
|
|
|
|
|
+ cpulist_parse(env, strlen(env), banned_cpus);
|
|
|
|
|
+ goto out;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
path = "/sys/devices/system/cpu/isolated";
|
|
|
|
|
process_one_line(path, get_mask_from_cpulist, &isolated_cpus);
|
|
|
|
|
|
|
|
|
|
diff --git a/irqbalance.1 b/irqbalance.1
|
|
|
|
|
index 3005f6b..33ffd26 100644
|
|
|
|
|
--- a/irqbalance.1
|
|
|
|
|
+++ b/irqbalance.1
|
|
|
|
|
@@ -158,6 +158,12 @@ Provides a mask of CPUs which irqbalance should ignore and never assign interrup
|
|
|
|
|
If not specified, irqbalance use mask of isolated and adaptive-ticks CPUs on the
|
|
|
|
|
system as the default value.
|
|
|
|
|
|
|
|
|
|
+.TP
|
|
|
|
|
+.B IRQBALANCE_BANNED_CPULIST
|
|
|
|
|
+Provides a cpulist which irqbalance should ignore and never assign interrupts to.
|
|
|
|
|
+If not specified, irqbalance use mask of isolated and adaptive-ticks CPUs on the
|
|
|
|
|
+system as the default value.
|
|
|
|
|
+
|
|
|
|
|
.SH "SIGNALS"
|
|
|
|
|
.TP
|
|
|
|
|
.B SIGHUP
|
|
|
|
|
--
|
2021-04-09 14:45:12 +08:00
|
|
|
2.23.0
|
2021-01-05 17:31:13 +08:00
|
|
|
|