netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jiri Olsa <jolsa@redhat.com>
To: Jiri Olsa <jolsa@kernel.org>, Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	netdev@vger.kernel.org, bpf@vger.kernel.org,
	Martin KaFai Lau <kafai@fb.com>, Song Liu <songliubraving@fb.com>,
	Yonghong Song <yhs@fb.com>, Andrii Nakryiko <andriin@fb.com>,
	John Fastabend <john.fastabend@gmail.com>,
	KP Singh <kpsingh@chromium.org>,
	Jesper Dangaard Brouer <brouer@redhat.com>
Subject: Re: [PATCH] perf tools: Do not use deprecated bpf_program__title
Date: Mon, 7 Sep 2020 13:05:49 +0200	[thread overview]
Message-ID: <20200907110549.GI1199773@krava> (raw)
In-Reply-To: <20200907110237.1329532-1-jolsa@kernel.org>

On Mon, Sep 07, 2020 at 01:02:37PM +0200, Jiri Olsa wrote:
> The bpf_program__title function got deprecated in libbpf,
> use the suggested alternative.
> 
> Fixes: 521095842027 ("libbpf: Deprecate notion of BPF program "title" in favor of "section name"")
> Signed-off-by: Jiri Olsa <jolsa@kernel.org>

Arnaldo,
the commit in 'Fixes' is not yet in your tree yet and the patch
below will make the perf compilation fail in your perf/core..

it fixes perf compilation on top of bpf-next tree.. so I think it
should go in through bpf-next tree

thanks,
jirka

> ---
>  tools/perf/util/bpf-loader.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/tools/perf/util/bpf-loader.c b/tools/perf/util/bpf-loader.c
> index 2feb751516ab..73de3973c8ec 100644
> --- a/tools/perf/util/bpf-loader.c
> +++ b/tools/perf/util/bpf-loader.c
> @@ -328,7 +328,7 @@ config_bpf_program(struct bpf_program *prog)
>  	probe_conf.no_inlines = false;
>  	probe_conf.force_add = false;
>  
> -	config_str = bpf_program__title(prog, false);
> +	config_str = bpf_program__section_name(prog);
>  	if (IS_ERR(config_str)) {
>  		pr_debug("bpf: unable to get title for program\n");
>  		return PTR_ERR(config_str);
> @@ -454,7 +454,7 @@ preproc_gen_prologue(struct bpf_program *prog, int n,
>  	if (err) {
>  		const char *title;
>  
> -		title = bpf_program__title(prog, false);
> +		title = bpf_program__section_name(prog);
>  		if (!title)
>  			title = "[unknown]";
>  
> -- 
> 2.26.2
> 


  reply	other threads:[~2020-09-07 11:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-07 11:02 [PATCH] perf tools: Do not use deprecated bpf_program__title Jiri Olsa
2020-09-07 11:05 ` Jiri Olsa [this message]
2020-09-07 15:59   ` Tobias Klauser
2020-09-07 16:22     ` Jiri Olsa
2020-09-07 16:27       ` Tobias Klauser
2020-09-08 20:11 ` Andrii Nakryiko
2020-09-09  7:19   ` Jiri Olsa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200907110549.GI1199773@krava \
    --to=jolsa@redhat.com \
    --cc=acme@redhat.com \
    --cc=andriin@fb.com \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=brouer@redhat.com \
    --cc=daniel@iogearbox.net \
    --cc=john.fastabend@gmail.com \
    --cc=jolsa@kernel.org \
    --cc=kafai@fb.com \
    --cc=kpsingh@chromium.org \
    --cc=netdev@vger.kernel.org \
    --cc=songliubraving@fb.com \
    --cc=yhs@fb.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).