diff options
| author | David Rientjes <[email protected]> | 2016-05-20 16:57:50 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2016-05-20 17:58:30 -0700 |
| commit | 297880f4af4e492ed5084be9397d65a18ade56ee (patch) | |
| tree | 86e635efbfa77ff397f5a0498ec857cf9d3b7b11 /tools/perf/scripts/python/bin | |
| parent | 63678c32e209bd165f33432bbed72b2954ce5ae4 (diff) | |
mm, hugetlb_cgroup: round limit_in_bytes down to hugepage size
The page_counter rounds limits down to page size values. This makes
sense, except in the case of hugetlb_cgroup where it's not possible to
charge partial hugepages. If the hugetlb_cgroup margin is less than the
hugepage size being charged, it will fail as expected.
Round the hugetlb_cgroup limit down to hugepage size, since it is the
effective limit of the cgroup.
For consistency, round down PAGE_COUNTER_MAX as well when a
hugetlb_cgroup is created: this prevents error reports when a user
cannot restore the value to the kernel default.
Signed-off-by: David Rientjes <[email protected]>
Cc: Michal Hocko <[email protected]>
Cc: Nikolay Borisov <[email protected]>
Cc: Johannes Weiner <[email protected]>
Cc: "Kirill A. Shutemov" <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions