* [PATCH bpf-next v3 1/3] x86/cfi,bpf: Add a stub function for get_info of struct tcp_congestion_ops.
@ 2024-02-17 3:47 Thinker Lee
0 siblings, 0 replies; only message in thread
From: Thinker Lee @ 2024-02-17 3:47 UTC (permalink / raw)
To: netdev; +Cc: dsahern, kuba, pabeni
From: Kui-Feng Lee <thinker.li@gmail.com>
struct tcp_congestion_ops is missing a stub function for get_info. This is
required for checking the consistency of cfi_stubs of struct_ops.
Cc: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Kui-Feng Lee <thinker.li@gmail.com>
---
net/ipv4/bpf_tcp_ca.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/net/ipv4/bpf_tcp_ca.c b/net/ipv4/bpf_tcp_ca.c
index 7f518ea5f4ac..6ab5d9c36416 100644
--- a/net/ipv4/bpf_tcp_ca.c
+++ b/net/ipv4/bpf_tcp_ca.c
@@ -321,6 +321,12 @@ static u32 bpf_tcp_ca_sndbuf_expand(struct sock *sk)
return 0;
}
+static size_t bpf_tcp_ca_get_info(struct sock *sk, u32 ext, int *attr,
+ union tcp_cc_info *info)
+{
+ return 0;
+}
+
static void __bpf_tcp_ca_init(struct sock *sk)
{
}
@@ -340,6 +346,7 @@ static struct tcp_congestion_ops __bpf_ops_tcp_congestion_ops = {
.cong_control = bpf_tcp_ca_cong_control,
.undo_cwnd = bpf_tcp_ca_undo_cwnd,
.sndbuf_expand = bpf_tcp_ca_sndbuf_expand,
+ .get_info = bpf_tcp_ca_get_info,
.init = __bpf_tcp_ca_init,
.release = __bpf_tcp_ca_release,
--
2.34.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2024-02-17 3:47 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-17 3:47 [PATCH bpf-next v3 1/3] x86/cfi,bpf: Add a stub function for get_info of struct tcp_congestion_ops Thinker Lee
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).