Received: by 10.223.185.116 with SMTP id b49csp5448704wrg; Tue, 27 Feb 2018 13:35:18 -0800 (PST) X-Google-Smtp-Source: AH8x225JpQUQLrynTwzCFEduQnA/v5VxhdNqv2tl1Z1jS5vsz5GXGK+PbId9MP4AhAr5TnqFUe5F X-Received: by 10.167.131.135 with SMTP id u7mr15416016pfm.50.1519767318347; Tue, 27 Feb 2018 13:35:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519767318; cv=none; d=google.com; s=arc-20160816; b=h8jH7r/QjGIQslKmlp6G9DBpEk8O6MZ0uwBR2Sbjp+fFARTnHLJ0s+7LLS5gTWYuBb uEiDUftZp1SeBu2pGyl69qwa6gX9Z44pREw9m6BqW4dHYCQla68xByvP8J3R8jgC46Kj M/0oMLA0ql9apJhjQbNIyUkTLm1+0UNPGuzL84lI1xM5VLUqjsRYXPyhUF2LSGF8U52L EUTfahX2nSHRc9IVx9XqDtuLSt0bYEC21/ZyYIEAjMXYaulgqvwoh7E6hNhPXZjVYZ6w 89MUpkbrw6Tkq+gnHralQION+W/0wqiQFXehIUEW+uohnblNTStYpsB5V36ZW/CK+CKK YZMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:references:cc:to:from:subject:arc-authentication-results; bh=iykdA1VwzP/j5H5xzw/O7OBgfBvchydR2Qp5oBZoqhk=; b=t1O+TMkg6c0Y1O3kJhb/G+T9MhNNKKEzEm14M1FDguXUMivBGAAosbbF4egbd8aQr/ GI51ujaj3l+1sNhLOXTFc66wKWg2td1y2al1KB26nr20b9F5HmFFFU8+kPDkWQJJaE8T ctBkFRGxfdkI5tdUPADTxlnonlV/m+wxmhrmX1S6Fl1OgApKXB17pPMtbpdNbkwrGYY/ enwqyy/2KTCx/j1pzGENAjqgUE0EnuxxPEXFvCsQcjG7FYTLMhFLLIaekumqRApeGrOo BmNb/UX40ihEkYT7IHJfk2u03t4N02AQeaIEcTOPk90fjrD4lUkxOtAFIkdUqVlh9LXH 4pKw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n3si69401pfi.302.2018.02.27.13.35.03; Tue, 27 Feb 2018 13:35:18 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751793AbeB0Vd5 (ORCPT + 99 others); Tue, 27 Feb 2018 16:33:57 -0500 Received: from mga05.intel.com ([192.55.52.43]:30505 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751590AbeB0Vd4 (ORCPT ); Tue, 27 Feb 2018 16:33:56 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Feb 2018 13:33:55 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.47,402,1515484800"; d="scan'208";a="20656992" Received: from rchatre-mobl.amr.corp.intel.com (HELO [10.24.14.178]) ([10.24.14.178]) by fmsmga007.fm.intel.com with ESMTP; 27 Feb 2018 13:33:55 -0800 Subject: Re: [RFC PATCH V2 13/22] x86/intel_rdt: Support schemata write - pseudo-locking core From: Reinette Chatre To: Thomas Gleixner Cc: fenghua.yu@intel.com, tony.luck@intel.com, gavin.hindman@intel.com, vikas.shivappa@linux.intel.com, dave.hansen@intel.com, mingo@redhat.com, hpa@zytor.com, x86@kernel.org, linux-kernel@vger.kernel.org References: <73fb98d2-ce93-0443-b909-fde75908cc1e@intel.com> <69ed85f2-b9c5-30d1-8437-45f20be3e95e@intel.com> Message-ID: <16989547-8209-8428-80a2-910cf667885f@intel.com> Date: Tue, 27 Feb 2018 13:33:55 -0800 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <69ed85f2-b9c5-30d1-8437-45f20be3e95e@intel.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Thomas, On 2/27/2018 11:52 AM, Reinette Chatre wrote: > On 2/27/2018 2:36 AM, Thomas Gleixner wrote: >> Let's assume its real, >> so you could do the following: >> >> mkdir group <- acquires closid >> echo locksetup > mode <- Creates 'lockarea' file >> echo L2:0 > lockarea >> echo 'L2:0=0xf' > schemata >> echo locked > mode <- locks down all files, does the lock setup >> and drops closid >> >> That would solve quite some of the other issues as well. Hmm? > > At this time the resource group, represented by a resctrl directory, is > tightly associated with the closid. I'll take a closer look at what it > will take to separate them. > > Could you please elaborate on the purpose of the "lockarea" file? It > does seem to duplicate the information in the schemata written in the > subsequent line. > > If we do go this route then it seems that there would be one > pseudo-locked region per resource group, not multiple ones as I had in > my examples above. Actually, this need not be true. It could be possible for administrator to pseudo-lock two regions at once. For example, mkdir group echo locksetup > mode echo 'L2:0=0xf;1=0xf' > schemata This could have two pseudo-locked regions associated with a single resource group. This does complicate the usage of the "size" file even more though since the plan was to have a single "size" file associated with a resource group it is not intuitive how it should describe multiple pseudo-locked regions. I added the "size" file originally to help users of the pseudo-locking interface where a single pseudo-locked region existed in a directory. All information to compute the size themselves are available to users, perhaps I can add pseudo-code to compute the size from available information to the documentation? Reinette