Re: [PATCH v4 2/6] powerpc/idle: Add accessor function to always read latest idle PURR

2020-04-05 Thread Gautham R Shenoy
On Fri, Apr 03, 2020 at 04:04:56PM +0530, Naveen N. Rao wrote: > Gautham R Shenoy wrote: > >On Wed, Apr 01, 2020 at 03:12:53PM +0530, Naveen N. Rao wrote: > >>Hi Gautham, > >> > >>Gautham R. Shenoy wrote: > >>>From: "Gautham R. Shenoy" > >>> > >>>+ > >>>+static inline u64

Re: [PATCH v4 2/6] powerpc/idle: Add accessor function to always read latest idle PURR

2020-04-03 Thread Naveen N. Rao
Gautham R Shenoy wrote: On Wed, Apr 01, 2020 at 03:12:53PM +0530, Naveen N. Rao wrote: Hi Gautham, Gautham R. Shenoy wrote: >From: "Gautham R. Shenoy" > >+ >+static inline u64 read_this_idle_purr(void) >+{ >+ /* >+* If we are reading from an idle context, update the >+* idle-purr

Re: [PATCH v4 2/6] powerpc/idle: Add accessor function to always read latest idle PURR

2020-04-03 Thread Gautham R Shenoy
On Wed, Apr 01, 2020 at 03:12:53PM +0530, Naveen N. Rao wrote: > Hi Gautham, > > Gautham R. Shenoy wrote: > >From: "Gautham R. Shenoy" > > > >Currently when CPU goes idle, we take a snapshot of PURR via > >pseries_idle_prolog() which is used at the CPU idle exit to compute > >the idle PURR

Re: [PATCH v4 2/6] powerpc/idle: Add accessor function to always read latest idle PURR

2020-04-01 Thread Naveen N. Rao
Hi Gautham, Gautham R. Shenoy wrote: From: "Gautham R. Shenoy" Currently when CPU goes idle, we take a snapshot of PURR via pseries_idle_prolog() which is used at the CPU idle exit to compute the idle PURR cycles via the function pseries_idle_epilog(). Thus, the value of idle PURR cycle thus

[PATCH v4 2/6] powerpc/idle: Add accessor function to always read latest idle PURR

2020-03-27 Thread Gautham R. Shenoy
From: "Gautham R. Shenoy" Currently when CPU goes idle, we take a snapshot of PURR via pseries_idle_prolog() which is used at the CPU idle exit to compute the idle PURR cycles via the function pseries_idle_epilog(). Thus, the value of idle PURR cycle thus read before pseries_idle_prolog() and