From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752406AbdF3NM4 (ORCPT ); Fri, 30 Jun 2017 09:12:56 -0400 Received: from terminus.zytor.com ([65.50.211.136]:38249 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752068AbdF3NMz (ORCPT ); Fri, 30 Jun 2017 09:12:55 -0400 Date: Fri, 30 Jun 2017 06:09:14 -0700 From: tip-bot for Colin Ian King Message-ID: Cc: mingo@kernel.org, peterz@infradead.org, linux-kernel@vger.kernel.org, tglx@linutronix.de, torvalds@linux-foundation.org, hpa@zytor.com, dan.carpenter@oracle.com, colin.king@canonical.com Reply-To: peterz@infradead.org, mingo@kernel.org, tglx@linutronix.de, linux-kernel@vger.kernel.org, hpa@zytor.com, dan.carpenter@oracle.com, torvalds@linux-foundation.org, colin.king@canonical.com In-Reply-To: <20170629091406.9870-1-colin.king@canonical.com> References: <20170629091406.9870-1-colin.king@canonical.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf/x86/intel: Constify the 'lbr_desc[]' array and make a function static Git-Commit-ID: e91c8d97eac74e603481840d950536bcb62b471b 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 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: e91c8d97eac74e603481840d950536bcb62b471b Gitweb: http://git.kernel.org/tip/e91c8d97eac74e603481840d950536bcb62b471b Author: Colin Ian King AuthorDate: Thu, 29 Jun 2017 10:14:06 +0100 Committer: Ingo Molnar CommitDate: Fri, 30 Jun 2017 09:00:56 +0200 perf/x86/intel: Constify the 'lbr_desc[]' array and make a function static A few minor clean-ups: constify the lbr_desc[] array and make local function lbr_from_signext_quirk_rd() static to fix a sparse warning: "symbol 'lbr_from_signext_quirk_rd' was not declared. Should it be static?" Signed-off-by: Colin Ian King Cc: Dan Carpenter Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: kernel-janitors@vger.kernel.org Link: http://lkml.kernel.org/r/20170629091406.9870-1-colin.king@canonical.com Signed-off-by: Ingo Molnar --- arch/x86/events/intel/lbr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/events/intel/lbr.c b/arch/x86/events/intel/lbr.c index f924629..eb26165 100644 --- a/arch/x86/events/intel/lbr.c +++ b/arch/x86/events/intel/lbr.c @@ -18,7 +18,7 @@ enum { LBR_FORMAT_MAX_KNOWN = LBR_FORMAT_TIME, }; -static enum { +static const enum { LBR_EIP_FLAGS = 1, LBR_TSX = 2, } lbr_desc[LBR_FORMAT_MAX_KNOWN + 1] = { @@ -287,7 +287,7 @@ inline u64 lbr_from_signext_quirk_wr(u64 val) /* * If quirk is needed, ensure sign extension is 61 bits: */ -u64 lbr_from_signext_quirk_rd(u64 val) +static u64 lbr_from_signext_quirk_rd(u64 val) { if (static_branch_unlikely(&lbr_from_quirk_key)) { /*