aboutsummaryrefslogtreecommitdiff
path: root/kernel/module-internal.h
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior <[email protected]>2022-03-22 14:40:38 -0700
committerLinus Torvalds <[email protected]>2022-03-22 15:57:02 -0700
commit2343e88d238f5de973d609d861c505890f94f22e (patch)
treeaf09354cbd41201f5c41329d0f99960a2d66f24a /kernel/module-internal.h
parentfead2b869764f89d524b79dc8862e61d5191be55 (diff)
mm/memcg: disable threshold event handlers on PREEMPT_RT
During the integration of PREEMPT_RT support, the code flow around memcg_check_events() resulted in `twisted code'. Moving the code around and avoiding then would then lead to an additional local-irq-save section within memcg_check_events(). While looking better, it adds a local-irq-save section to code flow which is usually within an local-irq-off block on non-PREEMPT_RT configurations. The threshold event handler is a deprecated memcg v1 feature. Instead of trying to get it to work under PREEMPT_RT just disable it. There should be no users on PREEMPT_RT. From that perspective it makes even less sense to get it to work under PREEMPT_RT while having zero users. Make memory.soft_limit_in_bytes and cgroup.event_control return -EOPNOTSUPP on PREEMPT_RT. Make an empty memcg_check_events() and memcg_write_event_control() which return only -EOPNOTSUPP on PREEMPT_RT. Document that the two knobs are disabled on PREEMPT_RT. Link: https://lkml.kernel.org/r/[email protected] Suggested-by: Michal Hocko <[email protected]> Suggested-by: Michal Koutný <[email protected]> Signed-off-by: Sebastian Andrzej Siewior <[email protected]> Acked-by: Roman Gushchin <[email protected]> Acked-by: Johannes Weiner <[email protected]> Reviewed-by: Shakeel Butt <[email protected]> Acked-by: Michal Hocko <[email protected]> Cc: kernel test robot <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Vladimir Davydov <[email protected]> Cc: Waiman Long <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'kernel/module-internal.h')
0 files changed, 0 insertions, 0 deletions