All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH bpf-next v5 0/2] bpf: allow map helpers access to map values directly
@ 2018-04-24 13:06 Paul Chaignon via iovisor-dev
  2018-04-24 21:54 ` Daniel Borkmann
  0 siblings, 1 reply; 2+ messages in thread
From: Paul Chaignon via iovisor-dev @ 2018-04-24 13:06 UTC (permalink / raw)
  To: Alexei Starovoitov, Daniel Borkmann, netdev-u79uwXL29TY76Z2rM5mHXA
  Cc: iovisor-dev-9jONkmmOlFHEE9lA1F8Ukti2O/JbrIOy

Currently, helpers that expect ARG_PTR_TO_MAP_KEY and ARG_PTR_TO_MAP_VALUE
can only access stack and packet memory.  This patchset allows these
helpers to directly access map values by passing registers of type
PTR_TO_MAP_VALUE.

The first patch changes the verifier; the second adds new test cases.

The first three versions of this patchset were sent on the iovisor-dev
mailing list only.

Changelogs:
  Changes in v5:
    - Refactor using check_helper_mem_access.
  Changes in v4:
    - Rebase.
  Changes in v3:
    - Bug fixes.
    - Negative test cases.
  Changes in v2:
    - Additional test cases for adjusted maps.

Paul Chaignon (2):
  bpf: allow map helpers access to map values directly
  tools/bpf: add verifier tests for accesses to map values

 kernel/bpf/verifier.c                       |  24 +--
 tools/testing/selftests/bpf/test_verifier.c | 266 ++++++++++++++++++++++++++++
 2 files changed, 273 insertions(+), 17 deletions(-)

-- 
2.7.4

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH bpf-next v5 0/2] bpf: allow map helpers access to map values directly
  2018-04-24 13:06 [PATCH bpf-next v5 0/2] bpf: allow map helpers access to map values directly Paul Chaignon via iovisor-dev
@ 2018-04-24 21:54 ` Daniel Borkmann
  0 siblings, 0 replies; 2+ messages in thread
From: Daniel Borkmann @ 2018-04-24 21:54 UTC (permalink / raw)
  To: Paul Chaignon, Alexei Starovoitov, netdev; +Cc: iovisor-dev, paul.chaignon

On 04/24/2018 03:06 PM, Paul Chaignon wrote:
> Currently, helpers that expect ARG_PTR_TO_MAP_KEY and ARG_PTR_TO_MAP_VALUE
> can only access stack and packet memory.  This patchset allows these
> helpers to directly access map values by passing registers of type
> PTR_TO_MAP_VALUE.
> 
> The first patch changes the verifier; the second adds new test cases.
> 
> The first three versions of this patchset were sent on the iovisor-dev
> mailing list only.
> 
> Changelogs:
>   Changes in v5:
>     - Refactor using check_helper_mem_access.
>   Changes in v4:
>     - Rebase.
>   Changes in v3:
>     - Bug fixes.
>     - Negative test cases.
>   Changes in v2:
>     - Additional test cases for adjusted maps.

Applied to bpf-next, thanks Paul!

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-04-24 21:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-24 13:06 [PATCH bpf-next v5 0/2] bpf: allow map helpers access to map values directly Paul Chaignon via iovisor-dev
2018-04-24 21:54 ` Daniel Borkmann

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.