Netdev List
 help / color / mirror / Atom feed
From: Daniel Borkmann <daniel@iogearbox.net>
To: ast@kernel.org
Cc: netdev@vger.kernel.org, Daniel Borkmann <daniel@iogearbox.net>
Subject: [PATCH bpf-next v2 00/13] Move ld_abs/ld_ind to native BPF
Date: Fri,  4 May 2018 01:08:11 +0200	[thread overview]
Message-ID: <20180503230824.3462-1-daniel@iogearbox.net> (raw)

This set simplifies BPF JITs significantly by moving ld_abs/ld_ind
to native BPF, for details see individual patches. Main rationale
is in patch 'implement ld_abs/ld_ind in native bpf'. Thanks!

v1 -> v2:
  - Added missing seen_lds_abs in LDX_MSH and use X = A
    initially due to being preserved on func call.
  - Added a large batch of cBPF tests into test_bpf.
  - Added x32 removal of LD_ABS/LD_IND, so all JITs are
    covered.

Daniel Borkmann (13):
  bpf: prefix cbpf internal helpers with bpf_
  bpf: migrate ebpf ld_abs/ld_ind tests to test_verifier
  bpf: implement ld_abs/ld_ind in native bpf
  bpf: add skb_load_bytes_relative helper
  bpf, x64: remove ld_abs/ld_ind
  bpf, arm64: remove ld_abs/ld_ind
  bpf, sparc64: remove ld_abs/ld_ind
  bpf, arm32: remove ld_abs/ld_ind
  bpf, mips64: remove ld_abs/ld_ind
  bpf, ppc64: remove ld_abs/ld_ind
  bpf, s390x: remove ld_abs/ld_ind
  bpf, x32: remove ld_abs/ld_ind
  bpf: sync tools bpf.h uapi header

 arch/arm/net/bpf_jit_32.c                   |  77 ----
 arch/arm64/net/bpf_jit_comp.c               |  65 ----
 arch/mips/net/ebpf_jit.c                    | 104 -----
 arch/powerpc/net/Makefile                   |   2 +-
 arch/powerpc/net/bpf_jit64.h                |  37 +-
 arch/powerpc/net/bpf_jit_asm64.S            | 180 ---------
 arch/powerpc/net/bpf_jit_comp64.c           | 109 +-----
 arch/s390/net/Makefile                      |   2 +-
 arch/s390/net/bpf_jit.S                     | 116 ------
 arch/s390/net/bpf_jit.h                     |  20 +-
 arch/s390/net/bpf_jit_comp.c                | 127 +------
 arch/sparc/net/Makefile                     |   5 +-
 arch/sparc/net/bpf_jit_64.h                 |  29 --
 arch/sparc/net/bpf_jit_asm_64.S             | 162 --------
 arch/sparc/net/bpf_jit_comp_64.c            |  79 +---
 arch/x86/net/Makefile                       |   3 +-
 arch/x86/net/bpf_jit.S                      | 154 --------
 arch/x86/net/bpf_jit_comp.c                 | 144 +------
 arch/x86/net/bpf_jit_comp32.c               | 136 +------
 include/linux/bpf.h                         |   4 +-
 include/linux/filter.h                      |   4 +-
 include/uapi/linux/bpf.h                    |  33 +-
 kernel/bpf/core.c                           |  96 +----
 kernel/bpf/verifier.c                       |  24 ++
 lib/test_bpf.c                              | 570 +++++++++++++++++-----------
 net/core/filter.c                           | 305 +++++++++++++--
 tools/include/uapi/linux/bpf.h              |  33 +-
 tools/testing/selftests/bpf/test_verifier.c | 266 ++++++++++++-
 28 files changed, 1035 insertions(+), 1851 deletions(-)
 delete mode 100644 arch/powerpc/net/bpf_jit_asm64.S
 delete mode 100644 arch/s390/net/bpf_jit.S
 delete mode 100644 arch/sparc/net/bpf_jit_asm_64.S
 delete mode 100644 arch/x86/net/bpf_jit.S

-- 
2.9.5

             reply	other threads:[~2018-05-03 23:08 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-03 23:08 Daniel Borkmann [this message]
2018-05-03 23:08 ` [PATCH bpf-next v2 01/13] bpf: prefix cbpf internal helpers with bpf_ Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 02/13] bpf: migrate ebpf ld_abs/ld_ind tests to test_verifier Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 03/13] bpf: implement ld_abs/ld_ind in native bpf Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 04/13] bpf: add skb_load_bytes_relative helper Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 05/13] bpf, x64: remove ld_abs/ld_ind Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 06/13] bpf, arm64: " Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 07/13] bpf, sparc64: " Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 08/13] bpf, arm32: " Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 09/13] bpf, mips64: " Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 10/13] bpf, ppc64: " Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 11/13] bpf, s390x: " Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 12/13] bpf, x32: " Daniel Borkmann
2018-05-03 23:08 ` [PATCH bpf-next v2 13/13] bpf: sync tools bpf.h uapi header Daniel Borkmann
2018-05-04  0:02 ` [PATCH bpf-next v2 00/13] Move ld_abs/ld_ind to native BPF Alexei Starovoitov

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=20180503230824.3462-1-daniel@iogearbox.net \
    --to=daniel@iogearbox.net \
    --cc=ast@kernel.org \
    --cc=netdev@vger.kernel.org \
    /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