Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932819AbbDKLVr (ORCPT ); Sat, 11 Apr 2015 07:21:47 -0400 Received: from e31.co.us.ibm.com ([32.97.110.149]:56219 "EHLO e31.co.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751820AbbDKLVn (ORCPT ); Sat, 11 Apr 2015 07:21:43 -0400 Message-ID: <552903BC.3050103@linux.vnet.ibm.com> Date: Sat, 11 Apr 2015 16:51:32 +0530 From: Preeti U Murthy User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Peter Zijlstra , tj@kernel.org CC: svaidy@linux.vnet.ibm.com, nacc@linux.vnet.ibm.com, rjw@rjwysocki.net, linux-kernel@vger.kernel.org, lizefan@huawei.com, anton@samba.org, bharata@linux.vnet.ibm.com, cgroups@vger.kernel.org, paulmck@linux.vnet.ibm.com, mingo@kernel.org, serge@hallyn.com Subject: Re: [PATCH V2] cpuset: Add knob to make allowed masks hotplug invariant on legacy hierarchy References: <20150410141118.11284.36206.stgit@preeti.in.ibm.com> <20150411083537.GR27490@worktop.programming.kicks-ass.net> In-Reply-To: <20150411083537.GR27490@worktop.programming.kicks-ass.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 15041111-8236-0000-0000-00000AAFED76 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2475 Lines: 53 On 04/11/2015 02:05 PM, Peter Zijlstra wrote: > On Fri, Apr 10, 2015 at 07:41:52PM +0530, Preeti U Murthy wrote: >> The cpus_allowed and mems_allowed masks of a cpuset get overwritten >> after each hotplug operation on the legacy hierarchy of cgroups so as to >> remain in sync with the online mask. But there are use cases which >> expect user configured masks to remain unchanged. >> >> For instance, when hotplugged out CPUs are brought back online, they >> remain idle with none of the existing tasks allowed to run on them since >> the cpus_allowed mask was overwritten to not include them when they were >> offlined. >> >> We cannot change the legacy hierarchy design now to keep the allowed >> masks hotplug invariant since it is a user visible change. It was >> suggested instead to add a knob in the root cpuset directory which >> allows the user to specify if he wants the user configured masks to be >> hotplug invariant [1]. This knob will enforce the choice throughout the >> hierarchy. If the knob is set, the allowed maks will not be varied on >> hotplug. It is also to to be noted that this knob will appear in the >> root cgroup mounted on the legacy hierarchy alone since the default >> hierarchy does not overwrite the allowed masks anyway. >> >> Having said this, there are fair reasons to argue that the kernel is not >> responsible for taking care of user configurations in the face of >> hotplug. But one of the consequences of the current legacy hierarchy >> design, is that CPUs are left out from being used at all on online >> operations. The reason for this is not very obvious at first and several >> users have raised the issue as a bug. Hence the patch was strongly >> called for. >> >> Moreover the default hierarchy keeps the allowed masks hotplug invariant >> too. So the patch is not bringing about a fundamental change in the >> design of cgroups. > > What you've not explained is why you can use this knob but not use the > other new mode? It is claimed that the existing software which work with the legacy hierarchy break when cgroups are mounted on the default hierarchy due to poor backward compatibility. I will include this point in the changelog. Thanks Regards Preeti U Murthy > -- 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/