Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp2496151imm; Sat, 30 Jun 2018 22:19:22 -0700 (PDT) X-Google-Smtp-Source: ADUXVKLP3NN4OgIdfZUr2JC/uCIs836ZBG+QOXdL/wY0XwcV39vWdcNOARnPDyz3dHOL8CSaytSx X-Received: by 2002:a17:902:8207:: with SMTP id x7-v6mr20782494pln.57.1530422362425; Sat, 30 Jun 2018 22:19:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530422362; cv=none; d=google.com; s=arc-20160816; b=iPWZGrg78+oyMgKzyB+vV85pi6fTaK2EVAxF6w5a+8DdC8I+FlgbTNrdqAP4uC9Rcf LyEYLe1Pyhzo/X7L7yjhHd2tNo5i60lN0rq0Ki1CBouFdLPPfq4ldI/j50ts1/lDNnD7 ciZx1tBUR3PQtvdybH038AoHbnSo1ILNWc0Y6joCCMcRHr0qj/LnLc+e5SD1m7rCavQD 9Bl7KIZ7z2LBn2hTXgqv2YoMa1u9YROt9pm4kfJkJfas0kCt3WRrtsEI/WzSfUZEwGsh 4K8FrQ9MIqvnPngKaNxLUqFNODfOLUCdm3fpwgPx9sIjuxlh0p9tnkFrXgsZeuuA0yiK b/BQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=eZoOnZzxW1olp9hcyRjzjNs+4YYkVT60dnk9YMc+tes=; b=UjHOJqiFhgstN/hZF7GLsdY2+BhrX+o/d00ARG8oO+t83LIP1DSTLztDHAMVXiu1bE ZLKAR6UQ6RsJSPxNC86E73BzbXqNRf2AL/qinJ1ASOi84UaYD/ec+u+3+DAyF9MuoBOz rWb3M3rtiidxv8TZikDvR57//maQMAloPOvLCYStLZ5ECMsniyAIze8WM5zT4SV742Zg nBxZG9ZzEhlI4A7/v2+XSVw8XrRoQmBfEgqJd8DG+Q3OlIx9RJWhFSegDPPCxAocZHLS xjN+KpcgQfLCrzHSFJpKHnf9w6ANGrC0O3AEJC8JJQklitNhxOITQasfC5kPDexwJKJz jAzQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c87-v6si4250882pfe.29.2018.06.30.22.18.56; Sat, 30 Jun 2018 22:19:22 -0700 (PDT) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751894AbeGAFRx (ORCPT + 99 others); Sun, 1 Jul 2018 01:17:53 -0400 Received: from mga01.intel.com ([192.55.52.88]:16836 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751535AbeGAFRu (ORCPT ); Sun, 1 Jul 2018 01:17:50 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 30 Jun 2018 22:17:50 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,293,1526367600"; d="scan'208";a="54226733" Received: from rchatre-s.jf.intel.com ([10.54.70.76]) by orsmga006.jf.intel.com with ESMTP; 30 Jun 2018 22:17:50 -0700 From: Reinette Chatre To: tglx@linutronix.de, fenghua.yu@intel.com, tony.luck@intel.com, vikas.shivappa@linux.intel.com Cc: gavin.hindman@intel.com, jithu.joseph@intel.com, dave.hansen@intel.com, mingo@redhat.com, hpa@zytor.com, x86@kernel.org, linux-kernel@vger.kernel.org, Reinette Chatre Subject: [PATCH 0/2] x86/intel_rdt: Display CPUs associated with pseudo-locked region Date: Sat, 30 Jun 2018 22:17:31 -0700 Message-Id: X-Mailer: git-send-email 2.17.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Dear Maintainers, The cpus and cpus_list resctrl files are locked down when the resource group enters pseudo-locksetup mode and remains locked down when the resource group transitions to pseudo-locked mode. This was done to ensure a resource group in pseudo-locksetup mode is and remain unused until it transitions to pseudo-locked mode. With this series read (but not write) access is restored to the cpus and cpus_list files after a resource group enters pseudo-locked mode. The information displayed is also adjusted appropriately. It is now possible for users to view which cpus are associated with a pseudo-locked region through the existing cpus and cpus_list resctrl files. Only the tasks file remains locked down. For example: # mount -t resctrl resctrl /sys/fs/resctrl # cd /sys/fs/resctrl # echo 'L2:1=0xfc' > schemata # mkdir p1 # ls -l p1/cpus* p1/tasks -rw-r--r-- 1 root root 0 Jun 30 06:30 p1/cpus -rw-r--r-- 1 root root 0 Jun 30 06:30 p1/cpus_list -rw-r--r-- 1 root root 0 Jun 30 06:30 p1/tasks # echo pseudo-locksetup > p1/mode # ls -l p1/cpus* p1/tasks ---------- 1 root root 0 Jun 30 06:30 p1/cpus ---------- 1 root root 0 Jun 30 06:30 p1/cpus_list ---------- 1 root root 0 Jun 30 06:30 p1/tasks # echo 'L2:1=0x3' > p1/schemata # ls -l p1/cpus* p1/tasks -r--r--r-- 1 root root 0 Jun 30 06:30 p1/cpus -r--r--r-- 1 root root 0 Jun 30 06:30 p1/cpus_list ---------- 1 root root 0 Jun 30 06:30 p1/tasks # grep . p1/* p1/cpus:c p1/cpus_list:2-3 p1/mode:pseudo-locked p1/schemata:L2:1=3 p1/size:L2:1=262144 grep: p1/tasks: Permission denied Reinette Chatre (2): x86/intel_rdt: Support restoration of subset of permissions x86/intel_rdt: cpu information accessible for pseudo-locked regions Documentation/x86/intel_rdt_ui.txt | 3 +++ arch/x86/kernel/cpu/intel_rdt.h | 3 ++- arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c | 17 ++++++++++------- arch/x86/kernel/cpu/intel_rdt_rdtgroup.c | 14 ++++++++++---- 4 files changed, 25 insertions(+), 12 deletions(-) -- 2.17.0