public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: David Vernet <void@manifault.com>
To: Alexei Starovoitov <alexei.starovoitov@gmail.com>
Cc: bpf <bpf@vger.kernel.org>, Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Andrii Nakryiko <andrii@kernel.org>,
	Martin KaFai Lau <martin.lau@linux.dev>,
	Song Liu <song@kernel.org>, Yonghong Song <yhs@meta.com>,
	John Fastabend <john.fastabend@gmail.com>,
	KP Singh <kpsingh@kernel.org>,
	Stanislav Fomichev <sdf@google.com>, Hao Luo <haoluo@google.com>,
	Jiri Olsa <jolsa@kernel.org>, LKML <linux-kernel@vger.kernel.org>,
	Kernel Team <kernel-team@meta.com>, Tejun Heo <tj@kernel.org>,
	Kumar Kartikeya Dwivedi <memxor@gmail.com>
Subject: Re: [PATCH bpf-next 3/3] bpf/selftests: Verify struct_ops prog sleepable behavior
Date: Tue, 24 Jan 2023 09:09:32 -0600	[thread overview]
Message-ID: <Y8/0rKGG2DSjDsIg@maniforge.lan> (raw)
In-Reply-To: <CAADnVQKnyz4gqDXfo0OTDuGGbn3i-+roB4M4Q-uxiMLrSP=S=g@mail.gmail.com>

On Mon, Jan 23, 2023 at 09:32:03PM -0800, Alexei Starovoitov wrote:
> On Mon, Jan 23, 2023 at 3:22 PM David Vernet <void@manifault.com> wrote:
> >
> > +static struct dummy_st_ops *open_load_skel(void)
> > +{
> > +       int err;
> > +       struct dummy_st_ops *skel;
> > +
> > +       skel = dummy_st_ops__open();
> > +       if (!ASSERT_OK_PTR(skel, "dummy_st_ops_open"))
> > +               return NULL;
> > +
> > +       err = bpf_program__set_flags(skel->progs.test_3, BPF_F_SLEEPABLE);
> 
> Feels that this is incomplete without libbpf support.
> Instead of:
> +SEC("struct_ops/test_3")
> the users should be able to:
> +SEC("struct_ops.s/test_3")
> 
> and the above manual set_flags won't be needed.

Thanks for the pointer, agreed that's far better (and matches existing
behavior for other prog types). Will address this in v2.

      reply	other threads:[~2023-01-24 15:09 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-23 23:22 [PATCH bpf-next 0/3] Enable struct_ops programs to be sleepable David Vernet
2023-01-23 23:22 ` [PATCH bpf-next 1/3] bpf: Allow BPF_PROG_TYPE_STRUCT_OPS " David Vernet
2023-01-23 23:22 ` [PATCH bpf-next 2/3] bpf: Pass const struct bpf_prog * to .check_member David Vernet
2023-01-23 23:22 ` [PATCH bpf-next 3/3] bpf/selftests: Verify struct_ops prog sleepable behavior David Vernet
2023-01-24  5:32   ` Alexei Starovoitov
2023-01-24 15:09     ` David Vernet [this message]

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=Y8/0rKGG2DSjDsIg@maniforge.lan \
    --to=void@manifault.com \
    --cc=alexei.starovoitov@gmail.com \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=haoluo@google.com \
    --cc=john.fastabend@gmail.com \
    --cc=jolsa@kernel.org \
    --cc=kernel-team@meta.com \
    --cc=kpsingh@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=martin.lau@linux.dev \
    --cc=memxor@gmail.com \
    --cc=sdf@google.com \
    --cc=song@kernel.org \
    --cc=tj@kernel.org \
    --cc=yhs@meta.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