From: "Jan Beulich" Subject: Re: [V6] x86/cpuidle: get accurate C0 value with xenpm tool Date: Thu, 21 May 2015 10:34:12 +0100 Message-ID: <555DC2B4020000780007CA24@mail.emea.novell.com> References: <1432190417-9890-1-git-send-email-huaitong.han@intel.com> <555D9C4C020000780007C8BD@mail.emea.novell.com> <1432198104.3458.14.camel@huaitong-MOBL.ccr.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1432198104.3458.14.camel@huaitong-MOBL.ccr.corp.intel.com> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Huaitong Han Cc: "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org >>> On 21.05.15 at 10:48, wrote: > On Thu, 2015-05-21 at 07:50 +0100, Jan Beulich wrote: >> >>> On 21.05.15 at 08:40, wrote: >> > @@ -329,7 +340,7 @@ static uint64_t acpi_pm_ticks_elapsed(uint64_t t1, uint64_t t2) >> > } >> > >> > uint64_t (*__read_mostly cpuidle_get_tick)(void) = get_acpi_pm_tick; >> > -static uint64_t (*__read_mostly ticks_elapsed)(uint64_t, uint64_t) >> > +uint64_t (*__read_mostly ticks_elapsed)(uint64_t, uint64_t) >> > = acpi_pm_ticks_elapsed; >> >> Why? (And if a change like this was needed, you'd have to rename >> the symbol to become identifiable as cpuidle specific, just like its >> neighbor is). > For code compilation, because the ticks_elapsed in the middle of the > cpu_idle.c will be used by print_acpi_power in the beginning of the > cpu_idle.c, other solution is moving hunk not just the functions to > right place. > Accepted, the second solution will be used. Just to avoid any doubt - if you move this, please also move cpuidle_get_tick along with it. Jan