[openib-general] [PATCH] udapl: PPC64 cpuinfo change

Troy Benjegerdes hozer at hozed.org
Thu Oct 6 21:01:21 PDT 2005


On Thu, Oct 06, 2005 at 02:14:08PM -0700, Grant Grundler wrote:
> On Thu, Oct 06, 2005 at 11:48:02AM -0600, Todd Bowman wrote:
> > /proc/cpuinfo on PPC64 prints different label for processor speed.
> ...
> 
> ISTR the "clock" value in cpuinfo is NOT the same as the CPU MHz.
> Can you remind me if "clock" value * "mtfb" results in
> "wall clock" time units?
> 
> If not, then use of DT_CPU_MHZ_MHZ needs to be reviewed since
> it typically makes that assumption.
> 
> Also, if someone cares about sparc (hey Tom! :^) ),
> then might leverage the get_clock.c code on:
> 	http://svn.gnumonks.org/trunk/mmio_test/

Oh boy.... is there some reason 'gettimeofday' does not work? Trying to
infer timebase/clock/rtsc frequency is going to be a mess. Think cpus
that dynamically change frequency.. Laptops do now.. how long before
something with infiniband does and breaks this code horribly? (think
embedded systems)

There are a couple of implementations of gettimeofday fully in userspace
that hide the details and still read the high-res hardware counters. Google
for 'vDSO gettimeofday'.



More information about the general mailing list