From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757140AbbE2Sh4 (ORCPT ); Fri, 29 May 2015 14:37:56 -0400 Received: from terminus.zytor.com ([198.137.202.10]:35196 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757119AbbE2Shv (ORCPT ); Fri, 29 May 2015 14:37:51 -0400 Date: Fri, 29 May 2015 11:37:34 -0700 From: tip-bot for Arnaldo Carvalho de Melo Message-ID: Cc: bp@suse.de, namhyung@kernel.org, fweisbec@gmail.com, mingo@kernel.org, acme@redhat.com, dsahern@gmail.com, tglx@linutronix.de, hpa@zytor.com, linux-kernel@vger.kernel.org, jolsa@redhat.com, adrian.hunter@intel.com, eranian@google.com, dzickus@redhat.com Reply-To: dzickus@redhat.com, adrian.hunter@intel.com, eranian@google.com, jolsa@redhat.com, linux-kernel@vger.kernel.org, hpa@zytor.com, tglx@linutronix.de, acme@redhat.com, dsahern@gmail.com, mingo@kernel.org, fweisbec@gmail.com, namhyung@kernel.org, bp@suse.de To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf machine: Adopt findnew_kernel method Git-Commit-ID: 459ce518d9b563a99faa73aa340b764e0b3fb143 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 459ce518d9b563a99faa73aa340b764e0b3fb143 Gitweb: http://git.kernel.org/tip/459ce518d9b563a99faa73aa340b764e0b3fb143 Author: Arnaldo Carvalho de Melo AuthorDate: Thu, 28 May 2015 12:40:55 -0300 Committer: Arnaldo Carvalho de Melo CommitDate: Fri, 29 May 2015 12:43:43 -0300 perf machine: Adopt findnew_kernel method It never was a 'struct dso' method, so fix that by rename dso__kernel_findnew() to machine__findnew_kernel(). At some point I'll move it all to the machine.[ch] files, for now lets ease patch review by not moving too much stuff. Cc: Adrian Hunter Cc: Borislav Petkov Cc: David Ahern Cc: Don Zickus Cc: Frederic Weisbecker Cc: Jiri Olsa Cc: Namhyung Kim Cc: Stephane Eranian Link: http://lkml.kernel.org/n/tip-zrxmblgsg5vx0iv4rhvq2f6l@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/dso.c | 4 ++-- tools/perf/util/dso.h | 4 ++-- tools/perf/util/machine.c | 11 +++++------ 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/tools/perf/util/dso.c b/tools/perf/util/dso.c index 7e11a70..fe52368 100644 --- a/tools/perf/util/dso.c +++ b/tools/perf/util/dso.c @@ -827,8 +827,8 @@ struct map *dso__new_map(const char *name) return map; } -struct dso *dso__kernel_findnew(struct machine *machine, const char *name, - const char *short_name, int dso_type) +struct dso *machine__findnew_kernel(struct machine *machine, const char *name, + const char *short_name, int dso_type) { /* * The kernel dso could be created by build_id processing. diff --git a/tools/perf/util/dso.h b/tools/perf/util/dso.h index bcec06a..24a507a 100644 --- a/tools/perf/util/dso.h +++ b/tools/perf/util/dso.h @@ -294,8 +294,8 @@ ssize_t dso__data_read_addr(struct dso *dso, struct map *map, bool dso__data_status_seen(struct dso *dso, enum dso_data_status_seen by); struct map *dso__new_map(const char *name); -struct dso *dso__kernel_findnew(struct machine *machine, const char *name, - const char *short_name, int dso_type); +struct dso *machine__findnew_kernel(struct machine *machine, const char *name, + const char *short_name, int dso_type); void dsos__add(struct dsos *dsos, struct dso *dso); struct dso *dsos__addnew(struct dsos *dsos, const char *name); diff --git a/tools/perf/util/machine.c b/tools/perf/util/machine.c index 0c0e61c..8934dc4 100644 --- a/tools/perf/util/machine.c +++ b/tools/perf/util/machine.c @@ -640,9 +640,8 @@ static struct dso *machine__get_kernel(struct machine *machine) if (!vmlinux_name) vmlinux_name = "[kernel.kallsyms]"; - kernel = dso__kernel_findnew(machine, vmlinux_name, - "[kernel]", - DSO_TYPE_KERNEL); + kernel = machine__findnew_kernel(machine, vmlinux_name, + "[kernel]", DSO_TYPE_KERNEL); } else { char bf[PATH_MAX]; @@ -652,9 +651,9 @@ static struct dso *machine__get_kernel(struct machine *machine) vmlinux_name = machine__mmap_name(machine, bf, sizeof(bf)); - kernel = dso__kernel_findnew(machine, vmlinux_name, - "[guest.kernel]", - DSO_TYPE_GUEST_KERNEL); + kernel = machine__findnew_kernel(machine, vmlinux_name, + "[guest.kernel]", + DSO_TYPE_GUEST_KERNEL); } if (kernel != NULL && (!kernel->has_build_id))