Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933144AbbEPEN7 (ORCPT ); Sat, 16 May 2015 00:13:59 -0400 Received: from mail-wg0-f45.google.com ([74.125.82.45]:36849 "EHLO mail-wg0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750888AbbEPEN4 (ORCPT ); Sat, 16 May 2015 00:13:56 -0400 From: Aleksa Sarai To: tj@kernel.org, lizefan@huawei.com, mingo@redhat.com, peterz@infradead.org Cc: richard@nod.at, fweisbec@gmail.com, linux-kernel@vger.kernel.org, cgroups@vger.kernel.org, Aleksa Sarai Subject: [PATCH v11 0/7] cgroups: add pids subsystem Date: Sat, 16 May 2015 14:13:34 +1000 Message-Id: <1431749621-30451-1-git-send-email-cyphar@cyphar.com> X-Mailer: git-send-email 2.4.1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2688 Lines: 71 This is an updated version of v10 of the pids patchset[1], with a few quite large-ish updates and improvments: * Switch all internal cgroup.c bitmasks to use (unsigned long), modify for_each_subsys_which() to use for_each_set_bit() [which required some other changes]. Also modify for_each_subsys_which() to take the pointer to the bitmask as an argument. * Modify argument order of for_each_subsys_which() so that it follows the kernel style of (cursors..., iterable). * Make naming of prefork / canfork consistent such that all references are canfork (such as CGROUP_CANFORK_*). * A whole bunch of style and naming fixes. * Remove ->detach and implement it using ->{can,cancel}_attach. * Remove the cancelfork bitmask -- just do ss->cancel_fork checks since it's not a hot path. * Add subsys_canfork_private{,p}(). * Include Tejun's implementation of task_get_css()[2] so that fork()s aren't failed because of a migration operation (which is guaranteed to complete in constant time). * Switch valid input value range for `pids.max` to [0, PIDS_MAX), to make the interface more consistent (so that you can't input a value that translates to "max" transparently). * Fixed up a whole bunch of comments that were too pids-specific or not explicit enough. [1]: https://lkml.org/lkml/2015/4/19/39 [2]: http://lkml.kernel.org/g/1428350318-8215-8-git-send-email-tj@kernel.org Aleksa Sarai (6): cgroup: switch to unsigned long for bitmasks cgroup: use bitmask to filter for_each_subsys cgroup: replace explicit ss_mask checking with for_each_subsys_which cgroup: move enum cgroup_subsys_id definition cgroup: allow a cgroup subsystem to reject a fork cgroup: implement the PIDs subsystem Tejun Heo (1): cgroup, block: implement task_get_css() and use it in bio_associate_current() CREDITS | 5 + block/bio.c | 11 +- include/linux/cgroup.h | 76 +++++++-- include/linux/cgroup_subsys.h | 22 +++ init/Kconfig | 16 ++ kernel/Makefile | 1 + kernel/cgroup.c | 215 ++++++++++++++++-------- kernel/cgroup_freezer.c | 2 +- kernel/cgroup_pids.c | 379 ++++++++++++++++++++++++++++++++++++++++++ kernel/fork.c | 17 +- kernel/sched/core.c | 2 +- 11 files changed, 652 insertions(+), 94 deletions(-) create mode 100644 kernel/cgroup_pids.c -- 2.4.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/