Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1457012

Re: [PATCH V4 4/6] perf tools: pushing driver configuration down to the kernel

From Jiri Olsa <jolsa@redhat.com>
Newsgroups linux.kernel
Subject Re: [PATCH V4 4/6] perf tools: pushing driver configuration down to the kernel
Date 2016-08-05 12:40 +0200
Message-ID <s2KHM-6gz-5@gated-at.bofh.it> (permalink)
References <s2u9X-3yY-15@gated-at.bofh.it> <s2ujF-3Tg-73@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu, Aug 04, 2016 at 10:53:22AM -0600, Mathieu Poirier wrote:

SNIP

> diff --git a/tools/perf/builtin-top.c b/tools/perf/builtin-top.c
> index 418ed94756d3..df74bdbb7524 100644
> --- a/tools/perf/builtin-top.c
> +++ b/tools/perf/builtin-top.c
> @@ -940,6 +940,10 @@ static int callchain_param__setup_sample_type(struct callchain_param *callchain)
>  
>  static int __cmd_top(struct perf_top *top)
>  {
> +	char msg[512];
> +	struct perf_evsel *pos;
> +	struct perf_evsel_config_term *err_term;
> +	struct perf_evlist *evlist = top->evlist;
>  	struct record_opts *opts = &top->record_opts;
>  	pthread_t thread;
>  	int ret;
> @@ -976,6 +980,13 @@ static int __cmd_top(struct perf_top *top)
>  	if (ret)
>  		goto out_delete;
>  
> +	if (perf_evlist__apply_drv_configs(evlist, &pos, &err_term)) {
> +		error("failed to set config \"%s\" on event %s with %d (%s)\n",
> +			err_term->val.drv_cfg, perf_evsel__name(pos), errno,
> +			strerror_r(errno, msg, sizeof(msg)));

hum ret is 0 in here..

> +		goto out_delete;
> +	}

thanks,
jirka

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH V4 0/6] perf: Driver specific configuration for PMU  Mathieu Poirier <mathieu.poirier@linaro.org> - 2016-08-04 19:10 +0200
  [PATCH V4 3/6] perf tools: add infrastructure for PMU specific configuration Mathieu Poirier <mathieu.poirier@linaro.org> - 2016-08-04 19:10 +0200
  [PATCH V4 1/6] perf/core: Adding PMU driver specific configuration Mathieu Poirier <mathieu.poirier@linaro.org> - 2016-08-04 19:10 +0200
  [PATCH V4 4/6] perf tools: pushing driver configuration down to the kernel Mathieu Poirier <mathieu.poirier@linaro.org> - 2016-08-04 19:10 +0200
    Re: [PATCH V4 4/6] perf tools: pushing driver configuration down to  the kernel Jiri Olsa <jolsa@redhat.com> - 2016-08-05 12:40 +0200

csiph-web