From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751132AbdAaOhl (ORCPT ); Tue, 31 Jan 2017 09:37:41 -0500 Received: from mx2.suse.de ([195.135.220.15]:35997 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750775AbdAaOh3 (ORCPT ); Tue, 31 Jan 2017 09:37:29 -0500 Subject: Re: [RFC V2 05/12] cpuset: Add cpuset_inc() inside cpuset_init() To: Mel Gorman , Anshuman Khandual References: <20170130033602.12275-1-khandual@linux.vnet.ibm.com> <20170130033602.12275-6-khandual@linux.vnet.ibm.com> <20170130203003.dm2ydoi3e6cbbwcj@suse.de> Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, mhocko@suse.com, minchan@kernel.org, aneesh.kumar@linux.vnet.ibm.com, bsingharora@gmail.com, srikar@linux.vnet.ibm.com, haren@linux.vnet.ibm.com, jglisse@redhat.com, dave.hansen@intel.com, dan.j.williams@intel.com From: Vlastimil Babka Message-ID: <8f442e1d-6c4d-990b-74e7-6d9a16c4576f@suse.cz> Date: Tue, 31 Jan 2017 15:36:43 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <20170130203003.dm2ydoi3e6cbbwcj@suse.de> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/30/2017 09:30 PM, Mel Gorman wrote: > On Mon, Jan 30, 2017 at 09:05:46AM +0530, Anshuman Khandual wrote: >> Currently cpusets_enabled() wrongfully returns 0 even if we have a root >> cpuset configured on the system. This got missed when jump level was >> introduced in place of number_of_cpusets with the commit 664eeddeef65 >> ("mm: page_alloc: use jump labels to avoid checking number_of_cpusets") >> . This fixes the problem so that cpusets_enabled() returns positive even >> for the root cpuset. >> >> Fixes: 664eeddeef65 ("mm: page_alloc: use jump labels to avoid") >> Signed-off-by: Anshuman Khandual > > Superficially, this appears to always activate the cpuset_enabled > branch() when it doesn't really make sense that the root cpuset be > restricted. Yes that's why root cpuset doesn't "count", as it's not supposed to be restricted (it's also documented in cpusets.txt) Thus the "Fixes:" tag is very misleading. > I strongly suspect it should be altered to cpuset_inc only > if the root cpuset is configured to isolate memory. >