Message ID | 20220711093218.10967-3-adrian.hunter@intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | perf intel-pt: Add support for tracing virtual machine user space on the host | expand |
On Mon, Jul 11, 2022 at 2:32 AM Adrian Hunter <adrian.hunter@intel.com> wrote: > > Export dsos__for_each_with_build_id() so it can be used elsewhere. > > Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Acked-by: Ian Rogers <irogers@google.com> Thanks, Ian > --- > tools/perf/util/build-id.c | 6 ------ > tools/perf/util/dso.h | 6 ++++++ > 2 files changed, 6 insertions(+), 6 deletions(-) > > diff --git a/tools/perf/util/build-id.c b/tools/perf/util/build-id.c > index 328668f38c69..4c9093b64d1f 100644 > --- a/tools/perf/util/build-id.c > +++ b/tools/perf/util/build-id.c > @@ -300,12 +300,6 @@ char *dso__build_id_filename(const struct dso *dso, char *bf, size_t size, > return __dso__build_id_filename(dso, bf, size, is_debug, is_kallsyms); > } > > -#define dsos__for_each_with_build_id(pos, head) \ > - list_for_each_entry(pos, head, node) \ > - if (!pos->has_build_id) \ > - continue; \ > - else > - > static int write_buildid(const char *name, size_t name_len, struct build_id *bid, > pid_t pid, u16 misc, struct feat_fd *fd) > { > diff --git a/tools/perf/util/dso.h b/tools/perf/util/dso.h > index 97047a11282b..66981c7a9a18 100644 > --- a/tools/perf/util/dso.h > +++ b/tools/perf/util/dso.h > @@ -227,6 +227,12 @@ struct dso { > #define dso__for_each_symbol(dso, pos, n) \ > symbols__for_each_entry(&(dso)->symbols, pos, n) > > +#define dsos__for_each_with_build_id(pos, head) \ > + list_for_each_entry(pos, head, node) \ > + if (!pos->has_build_id) \ > + continue; \ > + else > + > static inline void dso__set_loaded(struct dso *dso) > { > dso->loaded = true; > -- > 2.25.1 >
diff --git a/tools/perf/util/build-id.c b/tools/perf/util/build-id.c index 328668f38c69..4c9093b64d1f 100644 --- a/tools/perf/util/build-id.c +++ b/tools/perf/util/build-id.c @@ -300,12 +300,6 @@ char *dso__build_id_filename(const struct dso *dso, char *bf, size_t size, return __dso__build_id_filename(dso, bf, size, is_debug, is_kallsyms); } -#define dsos__for_each_with_build_id(pos, head) \ - list_for_each_entry(pos, head, node) \ - if (!pos->has_build_id) \ - continue; \ - else - static int write_buildid(const char *name, size_t name_len, struct build_id *bid, pid_t pid, u16 misc, struct feat_fd *fd) { diff --git a/tools/perf/util/dso.h b/tools/perf/util/dso.h index 97047a11282b..66981c7a9a18 100644 --- a/tools/perf/util/dso.h +++ b/tools/perf/util/dso.h @@ -227,6 +227,12 @@ struct dso { #define dso__for_each_symbol(dso, pos, n) \ symbols__for_each_entry(&(dso)->symbols, pos, n) +#define dsos__for_each_with_build_id(pos, head) \ + list_for_each_entry(pos, head, node) \ + if (!pos->has_build_id) \ + continue; \ + else + static inline void dso__set_loaded(struct dso *dso) { dso->loaded = true;
Export dsos__for_each_with_build_id() so it can be used elsewhere. Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> --- tools/perf/util/build-id.c | 6 ------ tools/perf/util/dso.h | 6 ++++++ 2 files changed, 6 insertions(+), 6 deletions(-)