Frederic Weisbecker
a85c2257a8
sched/isolation: add cpu_is_isolated() API
...
Patch series "memcg, cpuisol: do not interfere pcp cache charges draining
with cpuisol workloads".
Leonardo has reported [1] that pcp memcg charge draining can interfere
with cpu isolated workloads. The said draining is done from a WQ context
with a pcp worker scheduled on each CPU which holds any cached charges for
a specific memcg hierarchy. Operation is not really a common operation
[2]. It can be triggered from the userspace though so some care is
definitely due.
Leonardo has tried to address the issue by allowing remote charge draining
[3]. This approach requires an additional locking to synchronize pcp
caches sync from a remote cpu from local pcp consumers. Even though the
proposed lock was per-cpu there is still potential for contention and less
predictable behavior.
This patchset addresses the issue from a different angle. Rather than
dealing with a potential synchronization, cpus which are isolated are
simply never scheduled to be drained. This means that a small amount of
charges could be laying around and waiting for a later use or they are
flushed when a different memcg is charged from the same cpu. More details
are in patch 2. The first patch from Frederic is implementing an
abstraction to tell whether a specific cpu has been isolated and therefore
require a special treatment.
This patch (of 2):
Provide this new API to check if a CPU has been isolated either through
isolcpus= or nohz_full= kernel parameter.
It aims at avoiding kernel load deemed to be safely spared on CPUs running
sensitive workload that can't bear any disturbance, such as pcp cache
draining.
Link: https://lkml.kernel.org/r/20230317134448.11082-1-mhocko@kernel.org
Link: https://lkml.kernel.org/r/20230317134448.11082-2-mhocko@kernel.org
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
Signed-off-by: Michal Hocko <mhocko@suse.com>
Suggested-by: Michal Hocko <mhocko@suse.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Marcelo Tosatti <mtosatti@redhat.com>
Cc: Muchun Song <muchun.song@linux.dev>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Roman Gushchin <roman.gushchin@linux.dev>
Cc: Shakeel Butt <shakeelb@google.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Leonardo Bras <leobras@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2023-04-18 16:29:43 -07:00
..
2023-01-16 09:26:05 +01:00
2023-01-25 08:55:19 -08:00
2023-02-08 21:53:24 +01:00
2023-02-02 13:40:23 +01:00
2023-01-16 09:26:05 +01:00
2023-02-10 10:16:42 +01:00
2023-02-24 17:18:54 -08:00
2023-01-13 08:40:41 +00:00
2023-02-27 10:04:49 -08:00
2023-01-20 18:20:38 -08:00
2023-02-22 11:05:56 -08:00
2023-02-16 13:42:22 +01:00
2022-12-28 17:19:44 +00:00
2023-03-14 14:00:55 -04:00
2023-02-26 18:31:37 +00:00
2023-02-25 15:16:23 -08:00
2023-02-24 15:11:03 -08:00
2023-02-24 15:11:03 -08:00
2023-02-27 09:47:26 -08:00
2023-03-01 09:06:51 -08:00
2023-01-02 15:10:05 +01:00
2023-02-25 11:30:21 -08:00
2023-02-03 10:52:49 +05:30
2023-02-24 17:12:23 -08:00
2023-02-25 15:01:32 -08:00
2023-01-09 17:00:54 +01:00
2023-01-06 09:16:16 -07:00
2023-02-14 08:19:38 -08:00
2023-04-18 16:29:43 -07:00
2023-02-27 10:04:49 -08:00
2023-02-24 17:29:52 -08:00
2023-02-24 12:58:55 -08:00
2023-01-27 13:45:52 +01:00
2023-02-20 09:20:55 -05:00
2023-02-24 12:58:55 -08:00
2023-02-24 12:07:00 -08:00
2023-03-19 10:48:35 +00:00
2023-02-24 12:58:55 -08:00
2023-02-03 21:59:41 +01:00
2023-01-24 13:41:57 +01:00
2023-02-07 12:53:53 +01:00
2023-01-12 11:22:22 +01:00
2023-02-09 23:01:49 +01:00
2023-02-15 19:38:50 +01:00
2023-01-19 14:46:25 +01:00
2023-01-31 14:42:10 +01:00
2022-12-13 10:43:59 -08:00
2023-03-14 09:25:50 -06:00
2023-03-15 09:25:04 -06:00
2023-02-22 08:27:49 +09:00
2023-02-13 13:37:37 -08:00
2023-02-15 15:40:06 -08:00
2023-02-02 00:25:13 +01:00
2023-01-18 17:12:39 -08:00
2023-02-03 08:20:55 -07:00
2023-01-31 16:02:02 +01:00
2023-03-01 10:01:22 -08:00
2023-03-09 15:40:49 -08:00
2023-01-13 11:48:15 +01:00
2023-03-05 10:49:37 -08:00
2023-03-05 10:49:37 -08:00
2023-01-19 15:06:42 +01:00
2023-02-24 12:17:14 -08:00
2023-01-31 12:44:20 +01:00
2023-03-21 11:53:16 +01:00
2023-03-21 11:53:16 +01:00
2022-12-12 18:18:34 -08:00
2023-01-19 10:16:47 +00:00
2023-01-20 11:38:15 +00:00
2023-01-13 11:48:15 +01:00
2023-02-09 20:19:18 +01:00
2023-02-25 11:30:21 -08:00
2023-01-18 12:27:17 +01:00
2023-03-25 12:57:34 -07:00
2023-02-13 18:35:15 +08:00
2023-02-02 22:33:25 -08:00
2023-02-10 17:33:34 -08:00
2023-01-30 07:37:40 -08:00
2023-02-14 14:23:06 -05:00
2023-02-08 13:37:54 +01:00
2023-01-19 16:07:40 +01:00
2023-02-14 14:23:06 -05:00
2023-02-14 14:23:06 -05:00
2023-02-14 14:23:06 -05:00
2023-02-14 14:23:06 -05:00
2023-02-14 14:23:06 -05:00
2023-02-15 12:35:20 +01:00
2023-02-24 17:18:54 -08:00
2023-02-03 11:06:03 +01:00
2023-01-29 15:18:33 -07:00
2023-01-29 15:18:33 -07:00
2023-01-29 15:18:33 -07:00
2023-01-29 15:18:33 -07:00
2023-03-13 23:28:43 +01:00
2023-01-05 15:12:12 +00:00
2023-02-02 22:50:00 -08:00
2023-02-06 19:06:58 +01:00
2023-01-26 15:28:25 +01:00
2023-02-13 11:05:12 +00:00
2022-12-13 10:33:08 -08:00
2023-01-19 09:24:28 +01:00
2023-02-25 12:53:42 -08:00
2023-01-31 10:47:45 -08:00
2023-02-07 12:53:53 +01:00
2023-03-13 10:14:05 +01:00
2023-01-19 09:24:27 +01:00
2023-01-11 06:52:43 -05:00
2023-01-27 11:19:46 +00:00
2023-03-19 10:02:04 -07:00
2023-02-24 12:58:55 -08:00
2023-01-05 12:08:29 -08:00
2022-12-13 09:47:48 -08:00
2023-02-23 17:09:35 -08:00
2023-02-20 12:33:41 -08:00
2023-01-27 14:46:31 -08:00
2023-01-24 11:49:42 +00:00
2023-02-08 13:37:54 +01:00
2023-03-28 16:20:16 -07:00
2023-04-05 19:42:53 -07:00
2023-01-30 15:55:29 +01:00
2023-01-17 18:50:06 +01:00
2023-01-18 22:08:38 +01:00
2022-12-20 15:24:57 +01:00
2023-02-23 11:51:56 +01:00
2023-02-13 14:16:35 +01:00
2023-03-28 16:20:09 -07:00
2023-02-24 12:47:33 -08:00
2023-01-26 15:55:38 +01:00
2023-04-05 19:42:56 -07:00
2023-02-13 15:54:27 -08:00
2023-04-05 19:42:48 -07:00
2023-02-16 11:34:19 -08:00
2023-02-24 12:58:55 -08:00
2023-03-09 21:59:11 +01:00
2023-02-02 21:08:32 +01:00
2023-02-16 09:33:25 +01:00
2023-01-03 19:48:43 +01:00
2023-01-27 11:19:45 +00:00
2023-02-22 12:36:25 -08:00
2022-12-30 19:57:38 +01:00
2023-02-06 13:47:40 +01:00
2023-03-07 22:19:05 +02:00
2023-02-22 09:57:23 -07:00
2023-03-20 20:01:25 -06:00
2023-03-28 16:20:16 -07:00
2023-02-22 13:50:13 -08:00
2023-02-24 14:34:12 -08:00
2023-02-03 15:45:23 -04:00
2022-12-16 03:54:54 -08:00
2023-02-01 20:54:27 -08:00
2023-02-05 10:57:55 +00:00
2023-02-24 14:34:12 -08:00
2023-01-25 09:46:49 +00:00
2023-01-26 06:59:40 -05:00
2023-03-12 08:55:55 -07:00
2023-01-18 17:12:55 -08:00
2023-01-05 12:21:11 -08:00
2023-02-18 14:34:09 -05:00
2023-02-02 22:50:05 -08:00
2023-02-13 10:11:20 +02:00
2023-04-18 14:22:13 -07:00
2023-01-27 13:45:53 +01:00
2023-02-21 08:49:16 +09:00
2023-02-07 17:58:19 -08:00
2023-01-19 21:48:38 +00:00
2023-01-30 08:03:35 +00:00
2023-01-14 07:32:42 +09:00
2023-02-13 17:01:05 -08:00
2023-01-06 16:37:46 +01:00
2023-02-06 15:31:05 +01:00
2023-01-19 09:24:28 +01:00
2023-01-19 09:24:28 +01:00
2023-02-09 16:51:30 -08:00
2023-01-31 15:01:47 +01:00
2023-01-27 13:45:49 +01:00
2023-01-10 15:53:36 -08:00
2023-02-13 11:12:31 +00:00
2023-04-05 19:42:55 -07:00
2023-03-28 16:20:16 -07:00
2023-02-10 17:33:29 -08:00
2023-01-05 16:15:26 -06:00
2023-01-27 12:31:41 +05:30
2023-02-08 09:16:07 +00:00
2023-02-20 12:46:18 -08:00
2023-04-05 19:42:44 -07:00
2023-04-16 12:31:58 -07:00
2023-04-18 16:29:42 -07:00
2023-02-02 22:33:24 -08:00
2023-04-05 20:02:57 -07:00
2023-02-02 22:32:54 -08:00
2023-04-05 19:42:56 -07:00
2023-01-19 09:24:30 +01:00
2023-02-23 14:05:08 -08:00
2023-02-23 14:00:10 -08:00
2023-02-24 19:20:07 -08:00
2023-03-05 11:19:16 -08:00
2023-02-22 14:21:40 -08:00
2023-03-15 00:04:04 -07:00
2023-02-22 21:25:23 -08:00
2023-02-20 17:25:43 -06:00
2023-02-01 21:04:09 -08:00
2023-02-22 14:47:20 -08:00
2023-02-14 14:22:33 -05:00
2023-02-20 09:20:21 -05:00
2023-01-19 15:55:12 -08:00
2023-02-21 14:45:22 -08:00
2023-03-22 09:19:56 +01:00
2023-03-15 14:58:52 +01:00
2023-02-06 19:06:59 +01:00
2023-02-06 19:06:59 +01:00
2023-02-11 12:37:51 +01:00
2023-01-25 11:48:27 +01:00
2023-01-27 13:45:28 +01:00
2023-01-30 15:55:31 +01:00
2023-01-25 11:48:28 +01:00
2023-03-19 10:48:35 +00:00
2023-02-24 13:31:53 -08:00
2023-04-05 19:42:54 -07:00
2023-01-11 16:14:22 -08:00
2023-03-28 16:20:16 -07:00
2023-04-05 19:42:46 -07:00
2023-04-05 19:42:42 -07:00
2023-02-02 22:33:18 -08:00
2023-01-18 17:12:39 -08:00
2023-01-20 13:12:00 +01:00
2023-01-16 09:26:06 +01:00
2023-01-31 09:34:41 +09:00
2023-02-25 11:48:02 -08:00
2023-02-14 07:27:32 +09:00
2023-02-14 07:27:32 +09:00
2023-03-13 09:15:11 +01:00
2023-03-19 10:02:04 -07:00
2023-01-13 11:48:17 +01:00
2023-01-18 11:57:20 +01:00
2023-03-28 16:20:12 -07:00
2023-02-23 13:43:23 +01:00
2023-01-18 17:12:37 -08:00
2023-02-20 17:25:43 -06:00
2023-01-04 14:44:13 -07:00
2023-01-17 19:04:17 +01:00
2023-01-10 11:07:10 -06:00
2023-02-13 19:17:34 +01:00
2023-02-21 18:24:12 -08:00
2023-01-19 09:24:28 +01:00
2022-12-20 03:13:45 +01:00
2023-01-11 15:35:11 +01:00
2023-01-19 14:39:04 +01:00
2023-01-13 08:40:41 +00:00
2023-02-22 10:55:22 +00:00
2023-01-30 16:42:45 +01:00
2023-01-19 09:24:29 +01:00
2022-12-20 03:13:45 +01:00
2023-02-10 17:32:37 -08:00
2023-01-03 17:28:33 -08:00
2023-02-02 16:33:43 -08:00
2023-01-03 17:48:40 -08:00
2023-01-03 17:48:40 -08:00
2023-02-17 00:08:44 +00:00
2023-01-23 17:40:30 +01:00
2023-02-27 17:00:14 -08:00
2023-02-20 17:41:08 -08:00
2023-01-19 09:49:54 +00:00
2023-01-19 09:24:28 +01:00
2023-01-19 16:04:35 +01:00
2023-01-19 15:01:19 +01:00
2022-12-15 10:37:27 -08:00
2023-02-27 10:49:43 +01:00
2023-04-05 19:42:48 -07:00
2023-02-09 15:56:51 -08:00
2023-02-20 16:46:10 -08:00
2023-01-18 17:12:55 -08:00
2023-04-05 19:42:54 -07:00
2023-01-18 17:12:55 -08:00
2023-01-31 20:37:18 +01:00
2023-01-03 17:49:22 -08:00
2023-01-03 17:49:22 -08:00
2023-02-16 20:43:52 -08:00
2023-01-26 07:00:06 -05:00
2023-03-19 10:56:03 +00:00
2023-02-09 22:30:24 -08:00
2023-01-18 17:12:47 -08:00
2023-03-28 16:20:13 -07:00
2023-01-18 17:12:38 -08:00
2023-02-16 18:10:18 +01:00
2023-03-18 11:44:57 +01:00
2023-03-22 15:20:38 +01:00
2023-01-13 11:48:16 +01:00
2023-02-07 18:20:00 -08:00
2023-01-13 17:15:17 +01:00
2023-02-13 10:11:20 +02:00
2023-02-12 10:23:39 -05:00
2023-01-31 15:01:46 +01:00
2023-02-07 12:42:54 -05:00
2023-02-07 12:49:56 -05:00
2023-03-14 17:07:54 -07:00
2023-01-20 14:22:50 +01:00
2023-01-19 16:04:35 +01:00
2023-01-19 16:04:35 +01:00
2023-01-19 16:04:35 +01:00
2023-01-12 20:57:43 -08:00
2023-01-20 12:06:26 +01:00
2023-02-08 15:26:58 -08:00
2023-02-08 15:26:58 -08:00
2023-04-05 19:42:57 -07:00
2023-01-23 15:38:08 +01:00
2023-04-05 19:42:48 -07:00
2023-02-23 17:55:40 -08:00
2023-02-03 07:23:03 +01:00
2023-02-20 19:26:58 -05:00
2023-02-09 11:43:39 -07:00
2023-02-15 06:46:22 -05:00
2023-02-20 19:26:58 -05:00
2023-01-16 13:26:33 +00:00
2023-01-27 13:45:46 +01:00
2023-04-05 20:03:01 -07:00
2023-04-05 19:42:57 -07:00
2023-04-05 20:03:01 -07:00
2023-02-20 19:26:59 -05:00
2023-01-04 12:25:29 -10:00
2023-02-02 22:33:34 -08:00
2023-02-02 22:33:24 -08:00
2023-01-19 09:24:28 +01:00