[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190617114241.GC3419@hirez.programming.kicks-ass.net>
Date: Mon, 17 Jun 2019 13:42:41 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Jiri Olsa <jolsa@...nel.org>
Cc: "Liang, Kan" <kan.liang@...ux.intel.com>,
Stephane Eranian <eranian@...gle.com>,
Andy Lutomirski <luto@...nel.org>,
lkml <linux-kernel@...r.kernel.org>,
Ingo Molnar <mingo@...nel.org>,
Namhyung Kim <namhyung@...nel.org>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Andi Kleen <ak@...ux.intel.com>,
Vince Weaver <vincent.weaver@...ne.edu>,
Thomas Gleixner <tglx@...utronix.de>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Subject: Re: [PATCH 6/8] perf/x86/rapl: Get msr values from new probe
framework
On Sun, Jun 16, 2019 at 04:03:56PM +0200, Jiri Olsa wrote:
> + cfg = array_index_nospec(cfg, NR_RAPL_DOMAINS + 1);
This one fails to build on i386. Istr we had issues like that before.
This makes it build.
diff --git a/arch/x86/events/intel/rapl.c b/arch/x86/events/intel/rapl.c
index ddad45ef8757..64ab51ffdf06 100644
--- a/arch/x86/events/intel/rapl.c
+++ b/arch/x86/events/intel/rapl.c
@@ -349,7 +349,7 @@ static int rapl_pmu_event_init(struct perf_event *event)
if (!cfg || cfg >= NR_RAPL_DOMAINS + 1)
return -EINVAL;
- cfg = array_index_nospec(cfg, NR_RAPL_DOMAINS + 1);
+ cfg = array_index_nospec((long)cfg, NR_RAPL_DOMAINS + 1);
bit = cfg - 1;
/* check event supported */
Powered by blists - more mailing lists