Skip to content

Commit

Permalink
Merge branch 'for-4.11-fixes' of git://git.kernel.org/pub/scm/linux/k…
Browse files Browse the repository at this point in the history
…ernel/git/tj/cgroup

Pull cgroup fixes from Tejun Heo:
 "Three cgroup fixes.  Nothing critical:

   - the pids controller could trigger suspicious RCU warning
     spuriously. Fixed.

   - in the debug controller, %p -> %pK to protect kernel pointer
     from getting exposed.

   - documentation formatting fix"

* 'for-4.11-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup:
  cgroups: censor kernel pointer in debug files
  cgroup/pids: remove spurious suspicious RCU usage warning
  cgroup: Fix indenting in PID controller documentation
  • Loading branch information
Linus Torvalds committed Mar 14, 2017
2 parents 6517569 + b6a6759 commit 352526f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
11 changes: 6 additions & 5 deletions Documentation/cgroup-v2.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1142,16 +1142,17 @@ used by the kernel.

pids.max

A read-write single value file which exists on non-root cgroups. The
default is "max".
A read-write single value file which exists on non-root
cgroups. The default is "max".

Hard limit of number of processes.
Hard limit of number of processes.

pids.current

A read-only single value file which exists on all cgroups.
A read-only single value file which exists on all cgroups.

The number of processes currently in the cgroup and its descendants.
The number of processes currently in the cgroup and its
descendants.

Organisational operations are not blocked by cgroup policies, so it is
possible to have pids.current > pids.max. This can be done by either
Expand Down
2 changes: 1 addition & 1 deletion kernel/cgroup/cgroup-v1.c
Original file line number Diff line number Diff line change
Expand Up @@ -1329,7 +1329,7 @@ static int cgroup_css_links_read(struct seq_file *seq, void *v)
struct task_struct *task;
int count = 0;

seq_printf(seq, "css_set %p\n", cset);
seq_printf(seq, "css_set %pK\n", cset);

list_for_each_entry(task, &cset->tasks, cg_list) {
if (count++ > MAX_TASKS_SHOWN_PER_CSS)
Expand Down
2 changes: 1 addition & 1 deletion kernel/cgroup/pids.c
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ static int pids_can_fork(struct task_struct *task)
/* Only log the first time events_limit is incremented. */
if (atomic64_inc_return(&pids->events_limit) == 1) {
pr_info("cgroup: fork rejected by pids controller in ");
pr_cont_cgroup_path(task_cgroup(current, pids_cgrp_id));
pr_cont_cgroup_path(css->cgroup);
pr_cont("\n");
}
cgroup_file_notify(&pids->events_file);
Expand Down

0 comments on commit 352526f

Please sign in to comment.