From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arnaldo Carvalho de Melo Subject: Re: [bpf-next V3 PATCH 1/5] bpf: Sync kernel ABI header with tooling header for bpf_common.h Date: Thu, 8 Feb 2018 12:17:36 -0200 Message-ID: <20180208141736.GA4441@redhat.com> References: <151809046123.4625.11746882480100311060.stgit@firesoul> <151809049202.4625.16915834498996280027.stgit@firesoul> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: netdev@vger.kernel.org, Daniel Borkmann , Alexei Starovoitov , wangnan0@huawei.com, jakub.kicinski@netronome.com, joe@ovn.org, eric@regit.org, yhs@fb.com, Ingo Molnar , Jiri Olsa To: Jesper Dangaard Brouer Return-path: Received: from mx3-rdu2.redhat.com ([66.187.233.73]:54872 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751190AbeBHORk (ORCPT ); Thu, 8 Feb 2018 09:17:40 -0500 Content-Disposition: inline In-Reply-To: <151809049202.4625.16915834498996280027.stgit@firesoul> Sender: netdev-owner@vger.kernel.org List-ID: Em Thu, Feb 08, 2018 at 12:48:12PM +0100, Jesper Dangaard Brouer escreveu: > I recently fixed up a lot of commits that forgot to keep the tooling > headers in sync. And then I forgot to do the same thing in commit > cb5f7334d479 ("bpf: add comments to BPF ld/ldx sizes"). Let correct > that before people notice ;-). > > Lawrence did partly fix/sync this for bpf.h in commit d6d4f60c3a09 > ("bpf: add selftest for tcpbpf"). > > Fixes: cb5f7334d479 ("bpf: add comments to BPF ld/ldx sizes") We don't consider a bug to forget to update the tooling headers copy of the files, i.e. its not a strict requirement on kernel developers to care about tools/ :-) I, for one, like to get the warning, its an opportunity for me to see that something changed and that I should pay attention to see if something needs to be done in the tooling side. - Arnaldo > Signed-off-by: Jesper Dangaard Brouer > --- > tools/include/uapi/linux/bpf_common.h | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/tools/include/uapi/linux/bpf_common.h b/tools/include/uapi/linux/bpf_common.h > index 18be90725ab0..ee97668bdadb 100644 > --- a/tools/include/uapi/linux/bpf_common.h > +++ b/tools/include/uapi/linux/bpf_common.h > @@ -15,9 +15,10 @@ > > /* ld/ldx fields */ > #define BPF_SIZE(code) ((code) & 0x18) > -#define BPF_W 0x00 > -#define BPF_H 0x08 > -#define BPF_B 0x10 > +#define BPF_W 0x00 /* 32-bit */ > +#define BPF_H 0x08 /* 16-bit */ > +#define BPF_B 0x10 /* 8-bit */ > +/* eBPF BPF_DW 0x18 64-bit */ > #define BPF_MODE(code) ((code) & 0xe0) > #define BPF_IMM 0x00 > #define BPF_ABS 0x20