[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200622115007.GB14425@localhost.localdomain>
Date: Mon, 22 Jun 2020 13:50:07 +0200
From: Lorenzo Bianconi <lorenzo@...nel.org>
To: Jesper Dangaard Brouer <brouer@...hat.com>
Cc: bpf@...r.kernel.org, netdev@...r.kernel.org, davem@...emloft.net,
ast@...nel.org, daniel@...earbox.net, toke@...hat.com,
lorenzo.bianconi@...hat.com, dsahern@...nel.org
Subject: Re: [PATCH v2 bpf-next 3/8] cpumap: formalize map value as a named
struct
> On Sat, 20 Jun 2020 00:57:19 +0200
> Lorenzo Bianconi <lorenzo@...nel.org> wrote:
>
> > As it has been already done for devmap, introduce 'struct bpf_cpumap_val'
> > to formalize the expected values that can be passed in for a CPUMAP.
> > Update cpumap code to use the struct.
> >
> > Signed-off-by: Lorenzo Bianconi <lorenzo@...nel.org>
> > ---
> > include/uapi/linux/bpf.h | 9 +++++++++
> > kernel/bpf/cpumap.c | 25 +++++++++++++------------
> > tools/include/uapi/linux/bpf.h | 9 +++++++++
> > 3 files changed, 31 insertions(+), 12 deletions(-)
> >
> > diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h
> > index 19684813faae..a45d61bc886e 100644
> > --- a/include/uapi/linux/bpf.h
> > +++ b/include/uapi/linux/bpf.h
> > @@ -3774,6 +3774,15 @@ struct bpf_devmap_val {
> > } bpf_prog;
> > };
> >
> > +/* CPUMAP map-value layout
> > + *
> > + * The struct data-layout of map-value is a configuration interface.
> > + * New members can only be added to the end of this structure.
> > + */
> > +struct bpf_cpumap_val {
> > + __u32 qsize; /* queue size */
> > +};
> > +
>
> Nitpicking the comment: /* queue size */
> It doesn't provide much information to the end-user.
>
> What about changing it to: /* queue size to remote target CPU */
Yes, I agree. I will fix it in v3.
Regards,
Lorenzo
> ?
>
> --
> Best regards,
> Jesper Dangaard Brouer
> MSc.CS, Principal Kernel Engineer at Red Hat
> LinkedIn: http://www.linkedin.com/in/brouer
>
Download attachment "signature.asc" of type "application/pgp-signature" (229 bytes)
Powered by blists - more mailing lists