Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp291358pxb; Thu, 14 Jan 2021 06:11:41 -0800 (PST) X-Google-Smtp-Source: ABdhPJwVMYuDQr311NSQlzfJCkx+PAectbuyphuuouVLOd8jBcd/NELulmNocWZkoU6/+ZAhSa7P X-Received: by 2002:a17:906:705:: with SMTP id y5mr1303853ejb.83.1610633501763; Thu, 14 Jan 2021 06:11:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610633501; cv=none; d=google.com; s=arc-20160816; b=ShhWG6dSJzWQl4xsJR3tCbk7UcuDKmVaTGfQFEsKDmVgZEna1KuwhuBjMelkiND2To oEkgzZmy63iLmombuDziAsYIeCL8L/URj2vbfXScV9CgId+3dl6jtd6VQALArBWdZLMu mPbBGUrFQ2t3svCDTdoST6gzJirCPwgTQFLD5nyS5JUElHEjTXcRikKhgNN9cwkZBHWJ tAEwYGFYdkBd6/RKJE3TchHY+bA6cJatq67Rga1y+BfN+3yqsejEz/GgG/fvZ03JP1wx HgMBbieN5ySd4+r0oCXmWqm9dlrpoutZE+iBtKLr1eNQE5O+fvFfAVfnyMTK1GaUyNgs u3KA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:cc:references:to :subject; bh=dNe2Xpoy4jByW2dONnnAly8/wpCIOk0U0BUIy/Y1g+Q=; b=VD5p/EicIB8WCQkXf0DMYTdaJy0VSeyuZGsbLkvbwU3M6Vb2Wibv73kMvLG0ATVP7V OGqjRpZvbZ2ccA4ryUemETS/o9LlTffJHqXgohe3rTmp+Ob35NLLAYIXkPeqZeCfhbdy swndgvKrx9GyrH2XWiUNozFATplBJA1hed6Lz1sKq3q5QyDJwR7C+7x5m5LKjdwlgq8d Z8owTsXtdIQiBkirOj1+ijRDF1RihGXdU+LhhKXVKmU5iNheaFEgIfdMt6lxSfSmTT5Y AvbRlGY7p0mgK3nvomeR946bJaTgFW+seK3wIBa46WUvQsCeemvdybf7yOrbDx4nBtE9 dD6w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p15si1050711eja.205.2021.01.14.06.11.14; Thu, 14 Jan 2021 06:11:41 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726736AbhANOKR (ORCPT + 99 others); Thu, 14 Jan 2021 09:10:17 -0500 Received: from szxga06-in.huawei.com ([45.249.212.32]:10968 "EHLO szxga06-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725884AbhANOKR (ORCPT ); Thu, 14 Jan 2021 09:10:17 -0500 Received: from DGGEMS408-HUB.china.huawei.com (unknown [172.30.72.58]) by szxga06-in.huawei.com (SkyGuard) with ESMTP id 4DGmNP1M54zhwcc; Thu, 14 Jan 2021 22:07:33 +0800 (CST) Received: from [10.174.176.61] (10.174.176.61) by DGGEMS408-HUB.china.huawei.com (10.3.19.208) with Microsoft SMTP Server id 14.3.498.0; Thu, 14 Jan 2021 22:08:20 +0800 Subject: Re: [PATCH v2] cgroup-v1: add disabled controller check in cgroup1_parse_param() To: =?UTF-8?Q?Michal_Koutn=c3=bd?= References: <20201218061755.121205-1-chenzhou10@huawei.com> CC: , , , , From: chenzhou Message-ID: Date: Thu, 14 Jan 2021 22:08:19 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.176.61] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Michal, On 2021/1/14 21:12, Michal Koutn? wrote: > Hello Chen. > > On Fri, Dec 18, 2020 at 02:17:55PM +0800, Chen Zhou wrote: >> When mounting a cgroup hierarchy with disabled controller in cgroup v1, >> all available controllers will be attached. > Not sure if I understand the situation -- have you observed a v1 > controller attached to a hierarchy while specifying cgroup_no_v1= kernel > cmdline arg? Yeah, this is the situation. In this case, at the beginning of function check_cgroupfs_options(), the mask ctx->subsys_mask will be 0. And if we mount without 'none' and 'name=' options, then in check_cgroupfs_options(), the flag ctx->all_ss will be set, that is, select all the subsystems. Thanks, Chen Zhou > > AFAICS, the disabled controllers are honored thanks to > check_cgroupfs_options(). > > Michal