netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h
@ 2019-02-26 22:55 Willem de Bruijn
  2019-02-26 22:59 ` Soheil Hassas Yeganeh
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Willem de Bruijn @ 2019-02-26 22:55 UTC (permalink / raw)
  To: netdev, sdf; +Cc: soheil, Willem de Bruijn

From: Willem de Bruijn <willemb@google.com>

Signed-off-by: Willem de Bruijn <willemb@google.com>
---
 tools/testing/selftests/bpf/bpf_helpers.h | 29 +++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/tools/testing/selftests/bpf/bpf_helpers.h b/tools/testing/selftests/bpf/bpf_helpers.h
index d9999f1ed1d2a..fcd11839903c7 100644
--- a/tools/testing/selftests/bpf/bpf_helpers.h
+++ b/tools/testing/selftests/bpf/bpf_helpers.h
@@ -232,6 +232,35 @@ static int (*bpf_skb_change_head)(void *, int len, int flags) =
 	(void *) BPF_FUNC_skb_change_head;
 static int (*bpf_skb_pull_data)(void *, int len) =
 	(void *) BPF_FUNC_skb_pull_data;
+static unsigned long long (*bpf_get_cgroup_classid)(void *ctx) =
+	(void *) BPF_FUNC_get_cgroup_classid;
+static unsigned long long (*bpf_get_route_realm)(void *ctx) =
+	(void *) BPF_FUNC_get_route_realm;
+static int (*bpf_skb_change_proto)(void *ctx, __be16 proto, __u64 flags) =
+	(void *) BPF_FUNC_skb_change_proto;
+static int (*bpf_skb_change_type)(void *ctx, __u32 type) =
+	(void *) BPF_FUNC_skb_change_type;
+static unsigned long long (*bpf_get_hash_recalc)(void *ctx) =
+	(void *) BPF_FUNC_get_hash_recalc;
+static unsigned long long (*bpf_get_current_task)(void *ctx) =
+	(void *) BPF_FUNC_get_current_task;
+static int (*bpf_skb_change_tail)(void *ctx, __u32 len, __u64 flags) =
+	(void *) BPF_FUNC_skb_change_tail;
+static long long (*bpf_csum_update)(void *ctx, __u32 csum) =
+	(void *) BPF_FUNC_csum_update;
+static void (*bpf_set_hash_invalid)(void *ctx) =
+	(void *) BPF_FUNC_set_hash_invalid;
+static int (*bpf_get_numa_node_id)(void) =
+	(void *) BPF_FUNC_get_numa_node_id;
+static int (*bpf_probe_read_str)(void *ctx, int size, const void *unsafe_ptr) =
+	(void *) BPF_FUNC_probe_read_str;
+static unsigned int (*bpf_get_socket_uid)(void *ctx) =
+	(void *) BPF_FUNC_get_socket_uid;
+static unsigned int (*bpf_set_hash)(void *ctx, __u32 hash) =
+	(void *) BPF_FUNC_set_hash;
+static int (*bpf_skb_adjust_room)(void *ctx, __s32 len_diff, __u32 mode,
+				  unsigned long long flags) =
+	(void *) BPF_FUNC_skb_adjust_room;
 
 /* Scan the ARCH passed in from ARCH env variable (see Makefile) */
 #if defined(__TARGET_ARCH_x86)
-- 
2.21.0.rc2.261.ga7da99ff1b-goog


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

* Re: [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h
  2019-02-26 22:55 [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h Willem de Bruijn
@ 2019-02-26 22:59 ` Soheil Hassas Yeganeh
  2019-02-26 23:00 ` Willem de Bruijn
  2019-02-27  6:52 ` Martin Lau
  2 siblings, 0 replies; 4+ messages in thread
From: Soheil Hassas Yeganeh @ 2019-02-26 22:59 UTC (permalink / raw)
  To: Willem de Bruijn; +Cc: netdev, Stanislav Fomichev, Willem de Bruijn

On Tue, Feb 26, 2019 at 5:55 PM Willem de Bruijn
<willemdebruijn.kernel@gmail.com> wrote:
>
> From: Willem de Bruijn <willemb@google.com>
>
> Signed-off-by: Willem de Bruijn <willemb@google.com>

Acked-by: Soheil Hassas Yeganeh <soheil@google.com>

> ---
>  tools/testing/selftests/bpf/bpf_helpers.h | 29 +++++++++++++++++++++++
>  1 file changed, 29 insertions(+)
>
> diff --git a/tools/testing/selftests/bpf/bpf_helpers.h b/tools/testing/selftests/bpf/bpf_helpers.h
> index d9999f1ed1d2a..fcd11839903c7 100644
> --- a/tools/testing/selftests/bpf/bpf_helpers.h
> +++ b/tools/testing/selftests/bpf/bpf_helpers.h
> @@ -232,6 +232,35 @@ static int (*bpf_skb_change_head)(void *, int len, int flags) =
>         (void *) BPF_FUNC_skb_change_head;
>  static int (*bpf_skb_pull_data)(void *, int len) =
>         (void *) BPF_FUNC_skb_pull_data;
> +static unsigned long long (*bpf_get_cgroup_classid)(void *ctx) =
> +       (void *) BPF_FUNC_get_cgroup_classid;
> +static unsigned long long (*bpf_get_route_realm)(void *ctx) =
> +       (void *) BPF_FUNC_get_route_realm;
> +static int (*bpf_skb_change_proto)(void *ctx, __be16 proto, __u64 flags) =
> +       (void *) BPF_FUNC_skb_change_proto;
> +static int (*bpf_skb_change_type)(void *ctx, __u32 type) =
> +       (void *) BPF_FUNC_skb_change_type;
> +static unsigned long long (*bpf_get_hash_recalc)(void *ctx) =
> +       (void *) BPF_FUNC_get_hash_recalc;
> +static unsigned long long (*bpf_get_current_task)(void *ctx) =
> +       (void *) BPF_FUNC_get_current_task;
> +static int (*bpf_skb_change_tail)(void *ctx, __u32 len, __u64 flags) =
> +       (void *) BPF_FUNC_skb_change_tail;
> +static long long (*bpf_csum_update)(void *ctx, __u32 csum) =
> +       (void *) BPF_FUNC_csum_update;
> +static void (*bpf_set_hash_invalid)(void *ctx) =
> +       (void *) BPF_FUNC_set_hash_invalid;
> +static int (*bpf_get_numa_node_id)(void) =
> +       (void *) BPF_FUNC_get_numa_node_id;
> +static int (*bpf_probe_read_str)(void *ctx, int size, const void *unsafe_ptr) =
> +       (void *) BPF_FUNC_probe_read_str;
> +static unsigned int (*bpf_get_socket_uid)(void *ctx) =
> +       (void *) BPF_FUNC_get_socket_uid;
> +static unsigned int (*bpf_set_hash)(void *ctx, __u32 hash) =
> +       (void *) BPF_FUNC_set_hash;
> +static int (*bpf_skb_adjust_room)(void *ctx, __s32 len_diff, __u32 mode,
> +                                 unsigned long long flags) =
> +       (void *) BPF_FUNC_skb_adjust_room;
>
>  /* Scan the ARCH passed in from ARCH env variable (see Makefile) */
>  #if defined(__TARGET_ARCH_x86)
> --
> 2.21.0.rc2.261.ga7da99ff1b-goog
>

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

* Re: [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h
  2019-02-26 22:55 [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h Willem de Bruijn
  2019-02-26 22:59 ` Soheil Hassas Yeganeh
@ 2019-02-26 23:00 ` Willem de Bruijn
  2019-02-27  6:52 ` Martin Lau
  2 siblings, 0 replies; 4+ messages in thread
From: Willem de Bruijn @ 2019-02-26 23:00 UTC (permalink / raw)
  To: Network Development, Stanislav Fomichev
  Cc: Soheil Hassas Yeganeh, Willem de Bruijn

On Tue, Feb 26, 2019 at 5:55 PM Willem de Bruijn
<willemdebruijn.kernel@gmail.com> wrote:
>
> From: Willem de Bruijn <willemb@google.com>
>
> Signed-off-by: Willem de Bruijn <willemb@google.com>

As the topic indicated I did not intend to send for review to netdev@
just yet. Apologies for the spam.

For one, this commit lacks a commit message.

That said. It is out there, so any comments welcome, thanks.

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

* Re: [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h
  2019-02-26 22:55 [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h Willem de Bruijn
  2019-02-26 22:59 ` Soheil Hassas Yeganeh
  2019-02-26 23:00 ` Willem de Bruijn
@ 2019-02-27  6:52 ` Martin Lau
  2 siblings, 0 replies; 4+ messages in thread
From: Martin Lau @ 2019-02-27  6:52 UTC (permalink / raw)
  To: Willem de Bruijn; +Cc: netdev, sdf, soheil, Willem de Bruijn

On Tue, Feb 26, 2019 at 05:55:53PM -0500, Willem de Bruijn wrote:
> From: Willem de Bruijn <willemb@google.com>
> 
> Signed-off-by: Willem de Bruijn <willemb@google.com>
> ---
>  tools/testing/selftests/bpf/bpf_helpers.h | 29 +++++++++++++++++++++++
>  1 file changed, 29 insertions(+)
> 
> diff --git a/tools/testing/selftests/bpf/bpf_helpers.h b/tools/testing/selftests/bpf/bpf_helpers.h
> index d9999f1ed1d2a..fcd11839903c7 100644
> --- a/tools/testing/selftests/bpf/bpf_helpers.h
> +++ b/tools/testing/selftests/bpf/bpf_helpers.h
> @@ -232,6 +232,35 @@ static int (*bpf_skb_change_head)(void *, int len, int flags) =
>  	(void *) BPF_FUNC_skb_change_head;
>  static int (*bpf_skb_pull_data)(void *, int len) =
>  	(void *) BPF_FUNC_skb_pull_data;
> +static unsigned long long (*bpf_get_cgroup_classid)(void *ctx) =
> +	(void *) BPF_FUNC_get_cgroup_classid;
> +static unsigned long long (*bpf_get_route_realm)(void *ctx) =
> +	(void *) BPF_FUNC_get_route_realm;
> +static int (*bpf_skb_change_proto)(void *ctx, __be16 proto, __u64 flags) =
> +	(void *) BPF_FUNC_skb_change_proto;
> +static int (*bpf_skb_change_type)(void *ctx, __u32 type) =
> +	(void *) BPF_FUNC_skb_change_type;
> +static unsigned long long (*bpf_get_hash_recalc)(void *ctx) =
> +	(void *) BPF_FUNC_get_hash_recalc;
> +static unsigned long long (*bpf_get_current_task)(void *ctx) =
> +	(void *) BPF_FUNC_get_current_task;
> +static int (*bpf_skb_change_tail)(void *ctx, __u32 len, __u64 flags) =
> +	(void *) BPF_FUNC_skb_change_tail;
> +static long long (*bpf_csum_update)(void *ctx, __u32 csum) =
> +	(void *) BPF_FUNC_csum_update;
> +static void (*bpf_set_hash_invalid)(void *ctx) =
> +	(void *) BPF_FUNC_set_hash_invalid;
> +static int (*bpf_get_numa_node_id)(void) =
> +	(void *) BPF_FUNC_get_numa_node_id;
> +static int (*bpf_probe_read_str)(void *ctx, int size, const void *unsafe_ptr) =
> +	(void *) BPF_FUNC_probe_read_str;
> +static unsigned int (*bpf_get_socket_uid)(void *ctx) =
> +	(void *) BPF_FUNC_get_socket_uid;
> +static unsigned int (*bpf_set_hash)(void *ctx, __u32 hash) =
> +	(void *) BPF_FUNC_set_hash;
> +static int (*bpf_skb_adjust_room)(void *ctx, __s32 len_diff, __u32 mode,
> +				  unsigned long long flags) =
> +	(void *) BPF_FUNC_skb_adjust_room;
>  
>  /* Scan the ARCH passed in from ARCH env variable (see Makefile) */
>  #if defined(__TARGET_ARCH_x86)
> -- 
> 2.21.0.rc2.261.ga7da99ff1b-goog
> 
LGTM.  Please respin with a commit message.

Acked-by: Martin KaFai Lau <kafai@fb.com>

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

end of thread, other threads:[~2019-02-27  6:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-26 22:55 [PATCH internal pre-review] bpf: add missing entries to bpf_helpers.h Willem de Bruijn
2019-02-26 22:59 ` Soheil Hassas Yeganeh
2019-02-26 23:00 ` Willem de Bruijn
2019-02-27  6:52 ` Martin Lau

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).