From: Kumar Kartikeya Dwivedi <memxor@gmail.com>
To: bpf@vger.kernel.org
Cc: "Kumar Kartikeya Dwivedi" <memxor@gmail.com>,
"Toke Høiland-Jørgensen" <toke@redhat.com>,
"Alexei Starovoitov" <ast@kernel.org>,
"Daniel Borkmann" <daniel@iogearbox.net>,
"Andrii Nakryiko" <andrii@kernel.org>,
"Jamal Hadi Salim" <jhs@mojatatu.com>,
"Vlad Buslov" <vladbu@nvidia.com>,
"Cong Wang" <xiyou.wangcong@gmail.com>,
"Jesper Dangaard Brouer" <brouer@redhat.com>,
netdev@vger.kernel.org
Subject: [PATCH bpf-next v2 5/7] tools: bpf.h: sync with kernel sources
Date: Fri, 4 Jun 2021 12:01:14 +0530 [thread overview]
Message-ID: <20210604063116.234316-6-memxor@gmail.com> (raw)
In-Reply-To: <20210604063116.234316-1-memxor@gmail.com>
This will be used to expose bpf_link based libbpf API to users.
Reviewed-by: Toke Høiland-Jørgensen <toke@redhat.com>.
Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
---
tools/include/uapi/linux/bpf.h | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/tools/include/uapi/linux/bpf.h b/tools/include/uapi/linux/bpf.h
index 2c1ba70abbf1..a3488463d145 100644
--- a/tools/include/uapi/linux/bpf.h
+++ b/tools/include/uapi/linux/bpf.h
@@ -994,6 +994,7 @@ enum bpf_attach_type {
BPF_SK_LOOKUP,
BPF_XDP,
BPF_SK_SKB_VERDICT,
+ BPF_TC,
__MAX_BPF_ATTACH_TYPE
};
@@ -1007,6 +1008,7 @@ enum bpf_link_type {
BPF_LINK_TYPE_ITER = 4,
BPF_LINK_TYPE_NETNS = 5,
BPF_LINK_TYPE_XDP = 6,
+ BPF_LINK_TYPE_TC = 7,
MAX_BPF_LINK_TYPE,
};
@@ -1447,6 +1449,12 @@ union bpf_attr {
__aligned_u64 iter_info; /* extra bpf_iter_link_info */
__u32 iter_info_len; /* iter_info length */
};
+ struct { /* used by BPF_TC */
+ __u32 parent;
+ __u32 handle;
+ __u32 gen_flags;
+ __u16 priority;
+ } tc;
};
} link_create;
@@ -5519,6 +5527,13 @@ struct bpf_link_info {
struct {
__u32 ifindex;
} xdp;
+ struct {
+ __u32 ifindex;
+ __u32 parent;
+ __u32 handle;
+ __u32 gen_flags;
+ __u16 priority;
+ } tc;
};
} __attribute__((aligned(8)));
--
2.31.1
next prev parent reply other threads:[~2021-06-04 6:32 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-04 6:31 [PATCH bpf-next v2 0/7] Add bpf_link based TC-BPF API Kumar Kartikeya Dwivedi
2021-06-04 6:31 ` [PATCH bpf-next v2 1/7] net: sched: refactor cls_bpf creation code Kumar Kartikeya Dwivedi
2021-06-04 6:31 ` [PATCH bpf-next v2 2/7] bpf: export bpf_link functions for modules Kumar Kartikeya Dwivedi
2021-06-04 6:31 ` [PATCH bpf-next v2 3/7] net: sched: add bpf_link API for bpf classifier Kumar Kartikeya Dwivedi
2021-06-04 11:32 ` kernel test robot
2021-06-04 11:32 ` kernel test robot
2021-06-05 3:08 ` Yonghong Song
2021-06-05 4:52 ` Kumar Kartikeya Dwivedi
2021-06-07 23:23 ` Andrii Nakryiko
2021-06-04 6:31 ` [PATCH bpf-next v2 4/7] net: sched: add lightweight update path for cls_bpf Kumar Kartikeya Dwivedi
2021-06-04 17:54 ` Alexei Starovoitov
2021-06-05 4:42 ` Kumar Kartikeya Dwivedi
2021-06-07 23:32 ` Andrii Nakryiko
2021-06-10 14:14 ` Kumar Kartikeya Dwivedi
2021-06-04 6:31 ` Kumar Kartikeya Dwivedi [this message]
2021-06-04 6:31 ` [PATCH bpf-next v2 6/7] libbpf: add bpf_link based TC-BPF management API Kumar Kartikeya Dwivedi
2021-06-04 18:01 ` Alexei Starovoitov
2021-06-05 4:51 ` Kumar Kartikeya Dwivedi
2021-06-07 23:37 ` Andrii Nakryiko
2021-06-05 17:09 ` Yonghong Song
2021-06-07 23:41 ` Andrii Nakryiko
2021-06-04 6:31 ` [PATCH bpf-next v2 7/7] libbpf: add selftest for " Kumar Kartikeya Dwivedi
2021-06-05 17:26 ` Yonghong Song
2021-06-07 23:57 ` Andrii Nakryiko
2022-06-10 0:24 ` [PATCH bpf-next v2 0/7] Add bpf_link based TC-BPF API Joanne Koong
2022-06-10 12:58 ` Kumar Kartikeya Dwivedi
2022-06-10 17:23 ` Joanne Koong
2022-06-10 19:07 ` Joanne Koong
2022-06-10 19:34 ` Kumar Kartikeya Dwivedi
2022-06-10 20:04 ` Daniel Borkmann
2022-06-10 22:01 ` Joanne Koong
2022-06-10 20:16 ` Toke Høiland-Jørgensen
2022-06-10 20:35 ` Daniel Borkmann
2022-06-10 20:41 ` Toke Høiland-Jørgensen
2022-06-10 21:52 ` Alexei Starovoitov
2022-06-10 22:02 ` Daniel Borkmann
2022-06-11 10:54 ` Toke Høiland-Jørgensen
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=20210604063116.234316-6-memxor@gmail.com \
--to=memxor@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=brouer@redhat.com \
--cc=daniel@iogearbox.net \
--cc=jhs@mojatatu.com \
--cc=netdev@vger.kernel.org \
--cc=toke@redhat.com \
--cc=vladbu@nvidia.com \
--cc=xiyou.wangcong@gmail.com \
/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 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.