[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1439920986.28471.13.camel@synopsys.com>
Date: Tue, 18 Aug 2015 18:03:07 +0000
From: Alexey Brodkin <Alexey.Brodkin@...opsys.com>
To: "peterz@...radead.org" <peterz@...radead.org>
CC: "linux-arch@...r.kernel.org" <linux-arch@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"Vineet.Gupta1@...opsys.com" <Vineet.Gupta1@...opsys.com>,
"arc-linux-dev@...opsys.com" <arc-linux-dev@...opsys.com>,
"arnd@...db.de" <arnd@...db.de>,
"acme@...nel.org" <acme@...nel.org>
Subject: Re: [PATCH v2 3/8] ARCv2: perf: implement "event_set_period" for
future use with interrupts
Hi Peter,
On Tue, 2015-08-18 at 19:52 +0200, Peter Zijlstra wrote:
> On Wed, Aug 05, 2015 at 06:13:29PM +0300, Alexey Brodkin wrote:
> > Even though this hardware implementation allows for more flexibility,
> > in Linux kernel we decided to mimic behavior of other architectures this
> > way:
> >
> > [1] Set limit value as half of counter's max value (to allow counter to
> > run after reaching it limit, see below for more explanation):
> > ---------->8-----------
> > arc_pmu->max_period = (1ULL << counter_size) / 2 - 1ULL;
> > ---------->8-----------
>
> > @@ -317,10 +365,11 @@ static int arc_pmu_device_probe(struct platform_device *pdev)
> > return -ENOMEM;
> >
> > arc_pmu->n_counters = pct_bcr.c;
> > - arc_pmu->counter_size = 32 + (pct_bcr.s << 4);
> > + counter_size = 32 + (pct_bcr.s << 4);
> > + arc_pmu->max_period = (1ULL << counter_size) - 1ULL;
> >
>
> I don't see that /2 there..
My comment was a bit too early.
That "/2" was actually introduced in the subsequent commit.
Do you think I need to do a re-spin of that patch with commit
message which matches real code (i.e. no "/2")?
-Alexey--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists