[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150408122459.GE23123@twins.programming.kicks-ass.net>
Date: Wed, 8 Apr 2015 14:24:59 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Sukadev Bhattiprolu <sukadev@...ux.vnet.ibm.com>
Cc: Paul Mackerras <paulus@...ba.org>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
mingo@...hat.com, Michael Ellerman <mpe@...erman.id.au>,
dev@...yps.com, linux-kernel@...r.kernel.org,
linuxppc-dev@...ts.ozlabs.org
Subject: Re: [PATCH v2 3/5] perf: Rename perf_event_read_value
On Tue, Apr 07, 2015 at 05:34:57PM -0700, Sukadev Bhattiprolu wrote:
> perf_event_read_value() is mostly computing the event count and enabled/
> running times. Move the perf_event_read() into caller and rename
> perf_event_read_value() to perf_event_compute_values().
>
> Changelog[v2]
> Export symbol perf_event_read() since x86/kvm needs it now.
FWIW these changed since last things go below the --- since they're
pointless for the permanent record.
> Signed-off-by: Sukadev Bhattiprolu <sukadev@...ux.vnet.ibm.com>
> ---
> arch/x86/kvm/pmu.c | 6 ++++--
> include/linux/perf_event.h | 3 ++-
> kernel/events/core.c | 18 +++++++++++-------
> 3 files changed, 17 insertions(+), 10 deletions(-)
>
> diff --git a/arch/x86/kvm/pmu.c b/arch/x86/kvm/pmu.c
> index 8e6b7d8..5896cb1 100644
> --- a/arch/x86/kvm/pmu.c
> +++ b/arch/x86/kvm/pmu.c
> @@ -144,9 +144,11 @@ static u64 read_pmc(struct kvm_pmc *pmc)
>
> counter = pmc->counter;
>
> - if (pmc->perf_event)
> - counter += perf_event_read_value(pmc->perf_event,
> + if (pmc->perf_event) {
> + perf_event_read(pmc->perf_event);
> + counter += perf_event_compute_values(pmc->perf_event,
> &enabled, &running);
> + }
That's more than a rename, that's a functionality split just like the
previous patch.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists