netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress()
@ 2024-08-23 22:48 Yaxin Chen
  2024-08-26 21:49 ` Jakub Kicinski
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Yaxin Chen @ 2024-08-23 22:48 UTC (permalink / raw)
  To: netdev; +Cc: bpf, Yaxin Chen, Cong Wang, John Fastabend, Jakub Sitnicki

Parameter flags is not used in bpf_tcp_ingress().

Reviewed-by: Cong Wang <cong.wang@bytedance.com>
Cc: John Fastabend <john.fastabend@gmail.com>
Cc: Jakub Sitnicki <jakub@cloudflare.com>
Signed-off-by: Yaxin Chen <yaxin.chen1@bytedance.com>
---
 net/ipv4/tcp_bpf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/net/ipv4/tcp_bpf.c b/net/ipv4/tcp_bpf.c
index 53b0d62fd2c2..57a1614c55f9 100644
--- a/net/ipv4/tcp_bpf.c
+++ b/net/ipv4/tcp_bpf.c
@@ -30,7 +30,7 @@ void tcp_eat_skb(struct sock *sk, struct sk_buff *skb)
 }
 
 static int bpf_tcp_ingress(struct sock *sk, struct sk_psock *psock,
-			   struct sk_msg *msg, u32 apply_bytes, int flags)
+			   struct sk_msg *msg, u32 apply_bytes)
 {
 	bool apply = apply_bytes;
 	struct scatterlist *sge;
@@ -167,7 +167,7 @@ int tcp_bpf_sendmsg_redir(struct sock *sk, bool ingress,
 	if (unlikely(!psock))
 		return -EPIPE;
 
-	ret = ingress ? bpf_tcp_ingress(sk, psock, msg, bytes, flags) :
+	ret = ingress ? bpf_tcp_ingress(sk, psock, msg, bytes) :
 			tcp_bpf_push_locked(sk, msg, bytes, flags, false);
 	sk_psock_put(sk, psock);
 	return ret;
-- 
2.20.1


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

* Re: [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress()
  2024-08-23 22:48 [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress() Yaxin Chen
@ 2024-08-26 21:49 ` Jakub Kicinski
  2024-08-27 21:50 ` Martin KaFai Lau
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Jakub Kicinski @ 2024-08-26 21:49 UTC (permalink / raw)
  To: Yaxin Chen; +Cc: netdev, bpf, Cong Wang, John Fastabend, Jakub Sitnicki

On Fri, 23 Aug 2024 15:48:43 -0700 Yaxin Chen wrote:
> Parameter flags is not used in bpf_tcp_ingress().

LGTM, but reassigning to bpf-next.

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

* Re: [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress()
  2024-08-23 22:48 [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress() Yaxin Chen
  2024-08-26 21:49 ` Jakub Kicinski
@ 2024-08-27 21:50 ` Martin KaFai Lau
  2024-08-29 15:56 ` Jakub Sitnicki
  2024-09-02 16:50 ` patchwork-bot+netdevbpf
  3 siblings, 0 replies; 5+ messages in thread
From: Martin KaFai Lau @ 2024-08-27 21:50 UTC (permalink / raw)
  To: John Fastabend, Jakub Sitnicki; +Cc: bpf, Cong Wang, Yaxin Chen, netdev

On 8/23/24 3:48 PM, Yaxin Chen wrote:
> Parameter flags is not used in bpf_tcp_ingress().
> 
> Reviewed-by: Cong Wang <cong.wang@bytedance.com>
> Cc: John Fastabend <john.fastabend@gmail.com>
> Cc: Jakub Sitnicki <jakub@cloudflare.com>
> Signed-off-by: Yaxin Chen <yaxin.chen1@bytedance.com>
> ---
>   net/ipv4/tcp_bpf.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/net/ipv4/tcp_bpf.c b/net/ipv4/tcp_bpf.c
> index 53b0d62fd2c2..57a1614c55f9 100644
> --- a/net/ipv4/tcp_bpf.c
> +++ b/net/ipv4/tcp_bpf.c
> @@ -30,7 +30,7 @@ void tcp_eat_skb(struct sock *sk, struct sk_buff *skb)
>   }
>   
>   static int bpf_tcp_ingress(struct sock *sk, struct sk_psock *psock,
> -			   struct sk_msg *msg, u32 apply_bytes, int flags)
> +			   struct sk_msg *msg, u32 apply_bytes)
>   {
>   	bool apply = apply_bytes;
>   	struct scatterlist *sge;
> @@ -167,7 +167,7 @@ int tcp_bpf_sendmsg_redir(struct sock *sk, bool ingress,
>   	if (unlikely(!psock))
>   		return -EPIPE;
>   
> -	ret = ingress ? bpf_tcp_ingress(sk, psock, msg, bytes, flags) :
> +	ret = ingress ? bpf_tcp_ingress(sk, psock, msg, bytes) :

lgtm also. John and Jakub Sitnicki, please help to take a look and Ack if this 
looks good to you also.

>   			tcp_bpf_push_locked(sk, msg, bytes, flags, false);
>   	sk_psock_put(sk, psock);
>   	return ret;


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

* Re: [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress()
  2024-08-23 22:48 [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress() Yaxin Chen
  2024-08-26 21:49 ` Jakub Kicinski
  2024-08-27 21:50 ` Martin KaFai Lau
@ 2024-08-29 15:56 ` Jakub Sitnicki
  2024-09-02 16:50 ` patchwork-bot+netdevbpf
  3 siblings, 0 replies; 5+ messages in thread
From: Jakub Sitnicki @ 2024-08-29 15:56 UTC (permalink / raw)
  To: Yaxin Chen; +Cc: netdev, bpf, Cong Wang, John Fastabend

On Fri, Aug 23, 2024 at 03:48 PM -07, Yaxin Chen wrote:
> Parameter flags is not used in bpf_tcp_ingress().
>
> Reviewed-by: Cong Wang <cong.wang@bytedance.com>
> Cc: John Fastabend <john.fastabend@gmail.com>
> Cc: Jakub Sitnicki <jakub@cloudflare.com>
> Signed-off-by: Yaxin Chen <yaxin.chen1@bytedance.com>
> ---

First introduced in commit 8934ce2fd081 ("bpf: sockmap redirect ingress
support") [1]. Looks like it was never in use from the beginning.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=8934ce2fd08171e8605f7fada91ee7619fe17ab8

Acked-by: Jakub Sitnicki <jakub@cloudflare.com>


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

* Re: [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress()
  2024-08-23 22:48 [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress() Yaxin Chen
                   ` (2 preceding siblings ...)
  2024-08-29 15:56 ` Jakub Sitnicki
@ 2024-09-02 16:50 ` patchwork-bot+netdevbpf
  3 siblings, 0 replies; 5+ messages in thread
From: patchwork-bot+netdevbpf @ 2024-09-02 16:50 UTC (permalink / raw)
  To: Yaxin Chen; +Cc: netdev, bpf, cong.wang, john.fastabend, jakub

Hello:

This patch was applied to bpf/bpf-next.git (net)
by Daniel Borkmann <daniel@iogearbox.net>:

On Fri, 23 Aug 2024 15:48:43 -0700 you wrote:
> Parameter flags is not used in bpf_tcp_ingress().
> 
> Reviewed-by: Cong Wang <cong.wang@bytedance.com>
> Cc: John Fastabend <john.fastabend@gmail.com>
> Cc: Jakub Sitnicki <jakub@cloudflare.com>
> Signed-off-by: Yaxin Chen <yaxin.chen1@bytedance.com>
> 
> [...]

Here is the summary with links:
  - [net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress()
    https://git.kernel.org/bpf/bpf-next/c/5d1622831064

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



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

end of thread, other threads:[~2024-09-02 16:50 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-23 22:48 [Patch net-next] tcp_bpf: remove an unused parameter for bpf_tcp_ingress() Yaxin Chen
2024-08-26 21:49 ` Jakub Kicinski
2024-08-27 21:50 ` Martin KaFai Lau
2024-08-29 15:56 ` Jakub Sitnicki
2024-09-02 16:50 ` patchwork-bot+netdevbpf

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).