Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 3 Aug 2013 12:01:14 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        Mark R V Murray <mark@grondar.org>
Cc:        "freebsd-arm@freebsd.org" <arm@freebsd.org>, Aleksandr Rybalko <ray@freebsd.org>
Subject:   Re: PATCH: get_cyclecount() on ARMv6 and better
Message-ID:  <9342F2DA-2A30-4209-B8C6-A43F194852DA@bsdimp.com>
In-Reply-To: <E173CC12-0008-408B-B6BC-9FA162051C9F@grondar.org>
References:  <78D22A66-86E5-43B1-ABCA-7BF14F8061AB@grondar.org> <20130803145135.38196156.ray@freebsd.org> <E173CC12-0008-408B-B6BC-9FA162051C9F@grondar.org>

next in thread | previous in thread | raw e-mail | index | archive | help

On Aug 3, 2013, at 6:26 AM, Mark R V Murray wrote:

> 
> On 3 Aug 2013, at 12:51, Aleksandr Rybalko <ray@freebsd.org> wrote:
>> Hi Mark!
>> 
>> Do we setup Performance Monitor Control Register before use that
>> counter?
> 
> I've read up on PNMC register now, an looked for it in the code,
> and unless it is very well hidden, then NO, we don't set it up.
> 
> I've read now what I need to do; where is the best place do do it?
> I suspect it should be in start-up code right when the ARM is starting
> up; is that a good guess?

I'd make a timecounter for this, and put that in its initialization code.

Warner



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9342F2DA-2A30-4209-B8C6-A43F194852DA>