diff options
| author | Chris Down <[email protected]> | 2020-04-01 21:07:20 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2020-04-02 09:35:28 -0700 |
| commit | 15b42562d46debadaebd77ac1a647abae139a231 (patch) | |
| tree | 870fb610282ff7f4506932768df358439298fc32 /tools/perf/scripts/python | |
| parent | f6f989c5cebcc38b2d28c5b5f045d9a0a2082a9b (diff) | |
mm, memcg: prevent memory.max load tearing
This one is a bit more nuanced because we have memcg_max_mutex, which is
mostly just used for enforcing invariants, but we still need to READ_ONCE
since (despite its name) it doesn't really protect memory.max access.
On write (page_counter_set_max() and memory_max_write()) we use xchg(),
which uses smp_mb(), so that's already fine.
Signed-off-by: Chris Down <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Acked-by: Michal Hocko <[email protected]>
Cc: Johannes Weiner <[email protected]>
Cc: Roman Gushchin <[email protected]>
Cc: Tejun Heo <[email protected]>
Link: http://lkml.kernel.org/r/50a31e5f39f8ae6c8fb73966ba1455f0924e8f44.1584034301.git.chris@chrisdown.name
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions