Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp892134ybb; Wed, 1 Apr 2020 11:33:32 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsz0cdE1Qd7ueRks1/evOZb7FuiH7rqtblJpmI1LPe/fhwhH0nqksPDOuULR8DXVldWlXz/ X-Received: by 2002:a9d:7590:: with SMTP id s16mr17843534otk.250.1585766012029; Wed, 01 Apr 2020 11:33:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585766012; cv=none; d=google.com; s=arc-20160816; b=tKKgmhqG95e8zFCck7amJBuOqBirHExeJGrSdaKWiCdExnsT9QD0lFKg0pzDPFRqY3 0ugXty6qehiaYwsk4CWKcnhxT6jA/JRH/2MYPgRZWtC/wCpDn2bWqoBw2l37NByEbSsI lRdqFWfRTlqkiAX3qjJn0JSiFvb+R5SQtt2aBUCsZjRNobVoJDGq3yZoO6MyYW/vOrJY 2Vs1uvacpxIoFwPTOdhJ2YEyEX+2hSMmClR1fd3O5KfnxbzLtwiYgcXnUH/Ytit3OFdH sFIM3QB/bLNWJbWHwlCyklqTFK85csKhkypUJPCkyvfZUPEs1qbL7yKIg95oQHXDFcto xasA== 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:mime-version :message-id:date:subject:cc:to:from:ironport-sdr:ironport-sdr; bh=XYbVvfq6dFjNyy+8YHTy4o4y4ZDlyKEVvWW2giF0d+E=; b=EOiCmiMquA270Njn3TB/EPFLSf4fxNkiflb9II1zdxjyDxTV+M9nMCSDmvUFzh00wM fozy4AGOjd1gKSiDdBx0lLVlQ/YWwv+kPiys2fTQHqXeBXB0tH4oR2rKlpZvGEbenUOe A8SOZUxQqbKWFOlWB74Fo42K4vR43baT9L7Jxnhim7haM/dlRXoUTt2hbkAEdNdpwnos EkTqB6W5V19fh6SL84+dYTTQgeDt/bLPodMLvXP8dbwwwRPSyGTQQw1kKfV0pYUtuUpU 7Pw/lF8jhcrTJOtODNwzF1v1DdCXSo7FhW1ID96P6lx+Un2BBbFK5mcBWRfi6Z+Sb1Hg RjRg== 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 v20si1219719oif.63.2020.04.01.11.33.19; Wed, 01 Apr 2020 11:33:32 -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 S1732842AbgDASa6 (ORCPT + 99 others); Wed, 1 Apr 2020 14:30:58 -0400 Received: from mga14.intel.com ([192.55.52.115]:5040 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732316AbgDASa6 (ORCPT ); Wed, 1 Apr 2020 14:30:58 -0400 IronPort-SDR: gsMiNtKxcdu5oVJ76pI5gLAPdvxM/nETmL1y5M7CrLuOd1vvc4axrOfDx/itkBQn6dIg+9X8Xn /8O+LxjwQhMw== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Apr 2020 11:30:57 -0700 IronPort-SDR: wVPU0WUjVp8y/JWvA0x6xRVuOmgt37FAkIkzjAxLh7lReCE30B1UpmOoNMDWknHmdK7Qp5+Stm rP75WdVe2RDQ== X-IronPort-AV: E=Sophos;i="5.72,332,1580803200"; d="scan'208";a="249552580" Received: from rchatre-s.jf.intel.com ([10.54.70.76]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 Apr 2020 11:30:57 -0700 From: Reinette Chatre To: tglx@linutronix.de, fenghua.yu@intel.com, bp@alien8.de, tony.luck@intel.com Cc: kuo-lang.tseng@intel.com, mingo@redhat.com, babu.moger@amd.com, hpa@zytor.com, x86@kernel.org, linux-kernel@vger.kernel.org, Reinette Chatre Subject: [PATCH 0/2] x86/resctrl: Enable user to view and select thread throttling mode Date: Wed, 1 Apr 2020 11:30:46 -0700 Message-Id: X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The first patch in this series introduces a new resctrl file, "thread_throttle_mode", on Intel systems that exposes to the user how per-thread values are allocated to a core. This is added in support of newer Intel systems that can be configured to allocate either maximum or minimum throttling of the per-thread CLOS values to the core. Details about the feature can be found in the commit description and in Chapter 9 of the most recent Intel ISE available from https://software.intel.com/sites/default/files/managed/c5/15/architecture-instruction-set-extensions-programming-reference.pdf The first patch parses user input with the appropriate sysfs API that has not previously been used in resctrl. The second patch is added as a subsequent cleanup that switches existing resctrl string parsing code to also use this appropriate API. Reinette Chatre (2): x86/resctrl: Enable user to view and select thread throttling mode x86/resctrl: Use appropriate API for strings terminated by newline Documentation/x86/resctrl_ui.rst | 21 ++- arch/x86/kernel/cpu/resctrl/core.c | 29 ++++ arch/x86/kernel/cpu/resctrl/internal.h | 9 + arch/x86/kernel/cpu/resctrl/rdtgroup.c | 221 +++++++++++++++++++++++-- 4 files changed, 266 insertions(+), 14 deletions(-) -- 2.21.0