Re: [PATCH bpf-next v2 12/16] selftests/bpf: wq: add bpf_wq_init() checks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Apr 24 2024, Andrii Nakryiko wrote:
> On Sat, Apr 20, 2024 at 2:10 AM Benjamin Tissoires <bentiss@xxxxxxxxxx> wrote:
> >
> > Allows to test if allocation/free works
> >
> > Signed-off-by: Benjamin Tissoires <bentiss@xxxxxxxxxx>
> >
> > ---
> >
> > changes in v2:
> > - dropped mark_precise checks
> > ---
> >  tools/testing/selftests/bpf/bpf_experimental.h  |  1 +
> >  tools/testing/selftests/bpf/prog_tests/wq.c     |  8 +++
> >  tools/testing/selftests/bpf/progs/wq.c          | 10 ++++
> >  tools/testing/selftests/bpf/progs/wq_failures.c | 78 +++++++++++++++++++++++++
> >  4 files changed, 97 insertions(+)
> >
> > diff --git a/tools/testing/selftests/bpf/bpf_experimental.h b/tools/testing/selftests/bpf/bpf_experimental.h
> > index 3329ea080865..785b91b629be 100644
> > --- a/tools/testing/selftests/bpf/bpf_experimental.h
> > +++ b/tools/testing/selftests/bpf/bpf_experimental.h
> > @@ -470,4 +470,5 @@ extern int bpf_iter_css_new(struct bpf_iter_css *it,
> >  extern struct cgroup_subsys_state *bpf_iter_css_next(struct bpf_iter_css *it) __weak __ksym;
> >  extern void bpf_iter_css_destroy(struct bpf_iter_css *it) __weak __ksym;
> >
> > +extern int bpf_wq_init(struct bpf_wq *wq, void *p__map, unsigned int flags) __weak __ksym;
> >  #endif
> > diff --git a/tools/testing/selftests/bpf/prog_tests/wq.c b/tools/testing/selftests/bpf/prog_tests/wq.c
> > index 9a07b8bc2c52..26ab69796103 100644
> > --- a/tools/testing/selftests/bpf/prog_tests/wq.c
> > +++ b/tools/testing/selftests/bpf/prog_tests/wq.c
> > @@ -2,6 +2,7 @@
> >  /* Copyright (c) 2024 Benjamin Tissoires */
> >  #include <test_progs.h>
> >  #include "wq.skel.h"
> > +#include "wq_failures.skel.h"
> >
> >  void serial_test_wq(void)
> >  {
> > @@ -9,3 +10,10 @@ void serial_test_wq(void)
> >
> >         RUN_TESTS(wq);
> >  }
> > +
> > +void serial_test_failures_wq(void)
> > +{
> > +       LIBBPF_OPTS(bpf_test_run_opts, topts);
> > +
> 
> unused leftover?

Oops, yeah. Looks like it.

I'll send a removal of it while fixing 9/16

Cheers,
Benjamin

> 
> > +       RUN_TESTS(wq_failures);
> > +}
> 
> [...]




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux