Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp124111imm; Tue, 19 Jun 2018 17:25:24 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKIgG+ygUcKjhlMpwLL5tZ3gF9F9DuGzArdeQzQydQ7yA0A5a5jxtzvf7NRFwCg3YmfgxSh X-Received: by 2002:a65:5085:: with SMTP id r5-v6mr17127648pgp.123.1529454324701; Tue, 19 Jun 2018 17:25:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529454324; cv=none; d=google.com; s=arc-20160816; b=jGurZPSJ8Ejt1CpNhuwMtmnknFNeNB0lNXMR/9cQ5xcYEmKQu8bw23nN9QwSRGV1c2 7qEyyASMErYS1IFxYTkWgn/ZbsRMR6KmDQDAz8KcYf5yuC/0bfVjra1XkpSpXrayzPTx 3GrbcADvzcRMvBmavdyK89YaERm4fhjyOAk9emdfsc4BSkxBkn44FZuThJcbMLWFIhLL dqpPLR/i8W269J/DoPM1mogVYiDt63ZasW67KO39ujzmqs+XuutZeNNP4M2caGDVNi57 4tzLRP6RwCLN9dIzEGRdX4T5QXWbcpjKOtSWWbmxUZ4DUFdhmqbsAJp4zvC0BJC2kg6Q xfiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:mime-version:robot-unsubscribe:robot-id :git-commit-id:subject:to:references:in-reply-to:reply-to:cc :message-id:from:date:arc-authentication-results; bh=+h+UbVMDiY4iihkY08l/nd1AZ/PchAstDuxqkXZLvdM=; b=cpHXraXwMbnURNK964n7pQNH3pDa2093r0zuFOxieTYnwPWd9tHyq0U0/Pv4elSxXq feIpqYuUfhADcJkE4Uw1MV9pyGxZF5Sv8k1b+YPm+rd+gmyNLZv8qqnATas2YAiwOYWW c0IQUSSqAei3LWgTFMhQEL98e9AJ8fuJ5nu8GqnBX8lMk2ARzIFqGX2HlYTNBmZ/kgA8 rcwuuh3+84/Xh3J8IWTi2JttPqUFh5yEJqdy4lHkeQ8LXp1MnQo/cqXJE0KUQBki+jBK UdsvLZyhW4d83J9Vu3R1GZJKY94qurwpBUb5GDdVAb5uUtAwV7bFhE70xQsNnoRoWNaS 0meg== 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 q8-v6si831774pgf.40.2018.06.19.17.25.10; Tue, 19 Jun 2018 17:25:24 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754077AbeFTAYf (ORCPT + 99 others); Tue, 19 Jun 2018 20:24:35 -0400 Received: from terminus.zytor.com ([198.137.202.136]:38037 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752807AbeFTAYc (ORCPT ); Tue, 19 Jun 2018 20:24:32 -0400 Received: from terminus.zytor.com (localhost [127.0.0.1]) by terminus.zytor.com (8.15.2/8.15.2) with ESMTPS id w5K0ORIu3299312 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 19 Jun 2018 17:24:27 -0700 Received: (from tipbot@localhost) by terminus.zytor.com (8.15.2/8.15.2/Submit) id w5K0ORSY3299309; Tue, 19 Jun 2018 17:24:27 -0700 Date: Tue, 19 Jun 2018 17:24:27 -0700 X-Authentication-Warning: terminus.zytor.com: tipbot set sender to tipbot@zytor.com using -f From: tip-bot for Reinette Chatre Message-ID: Cc: tglx@linutronix.de, reinette.chatre@intel.com, mingo@kernel.org, linux-kernel@vger.kernel.org, hpa@zytor.com Reply-To: linux-kernel@vger.kernel.org, mingo@kernel.org, hpa@zytor.com, reinette.chatre@intel.com, tglx@linutronix.de In-Reply-To: References: To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/cache] x86/intel_rdt: Add check to determine if monitoring in progress Git-Commit-ID: 8938db1da6e73ef2217c7ae304a89f8e29ad22c7 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, T_DATE_IN_FUTURE_96_Q autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on terminus.zytor.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 8938db1da6e73ef2217c7ae304a89f8e29ad22c7 Gitweb: https://git.kernel.org/tip/8938db1da6e73ef2217c7ae304a89f8e29ad22c7 Author: Reinette Chatre AuthorDate: Tue, 29 May 2018 05:57:47 -0700 Committer: Thomas Gleixner CommitDate: Wed, 20 Jun 2018 00:56:35 +0200 x86/intel_rdt: Add check to determine if monitoring in progress When a resource group is pseudo-locked it is orphaned without a class of service associated with it. We thus do not want any monitoring in progress on a resource group that will be used for pseudo-locking. Introduce a test that can be used to determine if pseudo-locking in progress on a resource group. Temporarily mark it as unused to avoid compile warnings until it is used. Signed-off-by: Reinette Chatre Signed-off-by: Thomas Gleixner Cc: fenghua.yu@intel.com Cc: tony.luck@intel.com Cc: vikas.shivappa@linux.intel.com Cc: gavin.hindman@intel.com Cc: jithu.joseph@intel.com Cc: dave.hansen@intel.com Cc: hpa@zytor.com Link: https://lkml.kernel.org/r/d3efe6b526e28e335463578870ec7d5dc91ed96d.1527593971.git.reinette.chatre@intel.com --- arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c b/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c index dc79b3090ac5..8693dbe602a2 100644 --- a/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c +++ b/arch/x86/kernel/cpu/intel_rdt_pseudo_lock.c @@ -13,6 +13,19 @@ #include "intel_rdt.h" +/** + * rdtgroup_monitor_in_progress - Test if monitoring in progress + * @r: resource group being queried + * + * Return: 1 if monitor groups have been created for this resource + * group, 0 otherwise. + */ +static int __attribute__ ((unused)) +rdtgroup_monitor_in_progress(struct rdtgroup *rdtgrp) +{ + return !list_empty(&rdtgrp->mon.crdtgrp_list); +} + /** * rdtgroup_locksetup_user_restrict - Restrict user access to group * @rdtgrp: resource group needing access restricted