Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3189812pxf; Sun, 21 Mar 2021 23:15:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyVSrKgIRS9A2gty/HREQx1Arej912Yh1tIOcIXLN7jJbmRoUexROfX+p3ee2PfmRXr+uN+ X-Received: by 2002:aa7:cdcf:: with SMTP id h15mr23601478edw.28.1616393750177; Sun, 21 Mar 2021 23:15:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616393750; cv=none; d=google.com; s=arc-20160816; b=VTtOuzjHW73P/7XNHxJZc6FoujU8SGChJ3aBEfq56Tg25+WcKD5wWtShkbW2TUjc/e qeMnarChP1GOSyvO5fFT4YBOdicm7motCTXIuTAmyaHidKfXhWwbYtmj/X2xrAh++1Yr dHWFDiztX8YaL2FT0YHPh9P3zo2MJH7aiLeO2MEAqlTHhQuRE/J341gHJI24kiy5j0kb F0jpJkKxkRnMYKFQSzrg4GQMdtwq3OkAbmavW4PVRkb6U7u746tVEsbTQUzS5ijSsI4E 4Msunzoagv7hu2V5ywpQlbhb/bNT9bXe9ALFHEpgqht2tzAfQiA2Uvy+5GBN28/xn1fg yDng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:ironport-sdr:ironport-sdr; bh=MxPOdgmjFUmeBxdCUtm6UsvqAhDDktqV++UZcCfYdHc=; b=UOywEbChAh/1ilunS0zJN+CvLRURXLa8FHSY/ekA+rQcyDaSPyLoqvjH6luD9Aj/jP hgkByrfVy1XtRbwk8Jxjlxq68P8gU/LuXbCFEdNTH8YZjn/vTPelvdH2RxOL06PUMJrP 3Pq/iAQKUHo1qGW6AjK5kVWcsEkmDwH3Efn4hWj5dUo482j3e8VKTLJs6xRsrOe1poGr ODKvjuTF0YgZM+tTLKwehKnFn4NcU120fT1tejwH+9niMR3+5OQHZnjyrG0PgemKG05m DJ+fU9ZuQcqFrA3ON1l4+3n8nQxRza+y9mQeZKSDQm8GhYzfZbC5LAf761TpypdCM1x9 DNgA== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i25si10974393ejv.640.2021.03.21.23.15.28; Sun, 21 Mar 2021 23:15:50 -0700 (PDT) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229613AbhCVGOd (ORCPT + 99 others); Mon, 22 Mar 2021 02:14:33 -0400 Received: from mga11.intel.com ([192.55.52.93]:15223 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229728AbhCVGON (ORCPT ); Mon, 22 Mar 2021 02:14:13 -0400 IronPort-SDR: SkkmbfP1yHW+AFjglXZM+fvjOZFj0nw6qpceYzo9xaE0xQxJAhoZ7YTVJ8NjDA/eKjHUCx+OGy zpsd4Dzz+g2A== X-IronPort-AV: E=McAfee;i="6000,8403,9930"; a="186889246" X-IronPort-AV: E=Sophos;i="5.81,268,1610438400"; d="scan'208";a="186889246" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Mar 2021 23:14:13 -0700 IronPort-SDR: ZxxNthmSMV11c1LDwRs46tGtYC6PuxYcTebC8S9qDM5RBi0ponAQo/fIhIHAqZJwi/Nuww+oFC EULSejX1B06g== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.81,268,1610438400"; d="scan'208";a="441026231" Received: from clx-ap-likexu.sh.intel.com ([10.239.48.108]) by fmsmga002.fm.intel.com with ESMTP; 21 Mar 2021 23:14:09 -0700 From: Like Xu To: Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo Cc: Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Thomas Gleixner , Borislav Petkov , Kan Liang , x86@kernel.org, linux-kernel@vger.kernel.org, Like Xu Subject: [PATCH v4 RESEND 0/5] x86: The perf/x86 changes to support guest Arch LBR Date: Mon, 22 Mar 2021 14:06:30 +0800 Message-Id: <20210322060635.821531-1-like.xu@linux.intel.com> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Peter, Please help review these minor perf/x86 changes in this patch set, and we need some of them to support Guest Architectural LBR in KVM. If you are interested in the KVM emulation, please check https://lore.kernel.org/kvm/20210314155225.206661-1-like.xu@linux.intel.com/ Please check more details in each commit and feel free to comment. Like Xu (5): perf/x86/intel: Fix the comment about guest LBR support on KVM perf/x86/lbr: Simplify the exposure check for the LBR_INFO registers perf/x86/lbr: Move cpuc->lbr_xsave allocation out of sleeping region perf/x86/lbr: Skip checking for the existence of LBR_TOS for Arch LBR perf/x86: Move ARCH_LBR_CTL_MASK definition to include/asm/msr-index.h arch/x86/events/core.c | 8 +++++--- arch/x86/events/intel/bts.c | 2 +- arch/x86/events/intel/core.c | 6 +++--- arch/x86/events/intel/lbr.c | 28 +++++++++++++++++----------- arch/x86/events/perf_event.h | 8 +++++++- arch/x86/include/asm/msr-index.h | 1 + 6 files changed, 34 insertions(+), 19 deletions(-) -- 2.29.2