From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paul Mackerras Subject: Re: [RFC patch 04/15] get_cycles() : powerpc64 HAVE_GET_CYCLES Date: Fri, 17 Oct 2008 11:26:23 +1100 Message-ID: <18679.56239.74999.534588@cargo.ozlabs.ibm.com> References: <20081016232729.699004293@polymtl.ca> <20081016234656.055839676@polymtl.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Return-path: Received: from ozlabs.org ([203.10.76.45]:52798 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751511AbYJQA06 (ORCPT ); Thu, 16 Oct 2008 20:26:58 -0400 In-Reply-To: <20081016234656.055839676@polymtl.ca> Sender: linux-arch-owner@vger.kernel.org List-ID: To: Mathieu Desnoyers Cc: Linus Torvalds , Andrew Morton , Ingo Molnar , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, Steven Rostedt , Peter Zijlstra , Thomas Gleixner , David Miller , benh@kernel.crashing.org, Ingo Molnar Mathieu Desnoyers writes: > This patch selects HAVE_GET_CYCLES and makes sure get_cycles_barrier() and > get_cycles_rate() are implemented. [snip] > +static inline cycles_t get_cycles_rate(void) > +{ > + return CLOCK_TICK_RATE; > +} CLOCK_TICK_RATE is certainly wrong. You want ppc_tb_freq (declared in asm/time.h). Or tb_ticks_per_sec, since we seem to have two variables for exactly the same thing, for some reason. :) Paul.