All of lore.kernel.org
 help / color / mirror / Atom feed
* [MPTCP] [PATCH 3/7] mptcp: reduce number of pr_debug() calls.
@ 2019-06-06  0:36 Peter Krystad
  0 siblings, 0 replies; 2+ messages in thread
From: Peter Krystad @ 2019-06-06  0:36 UTC (permalink / raw)
  To: mptcp

[-- Attachment #1: Type: text/plain, Size: 1968 bytes --]

squash to: Create SUBFLOW socket for incoming connections

Signed-off-by: Peter Krystad <peter.krystad(a)linux.intel.com>
---
 net/mptcp/options.c  | 6 +++---
 net/mptcp/protocol.c | 5 +----
 2 files changed, 4 insertions(+), 7 deletions(-)

diff --git a/net/mptcp/options.c b/net/mptcp/options.c
index 7475c1d5c15f..b259c4343f36 100644
--- a/net/mptcp/options.c
+++ b/net/mptcp/options.c
@@ -339,14 +339,14 @@ bool mptcp_synack_options(const struct request_sock *req, unsigned int *size,
 {
 	struct subflow_request_sock *subflow_req = subflow_rsk(req);
 
-	pr_debug("subflow_req=%p", subflow_req);
 	if (subflow_req->mp_capable) {
 		opts->suboptions = OPTION_MPTCP_MPC_SYNACK;
 		opts->sndr_key = subflow_req->local_key;
 		opts->rcvr_key = subflow_req->remote_key;
 		*size = TCPOLEN_MPTCP_MPC_SYNACK;
-		pr_debug("local_key=%llu", subflow_req->local_key);
-		pr_debug("remote_key=%llu", subflow_req->remote_key);
+		pr_debug("subflow_req=%p, local_key=%llu, remote_key=%llu",
+			 subflow_req, subflow_req->local_key,
+			 subflow_req->remote_key);
 		return true;
 	}
 	return false;
diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c
index 902b6c994f00..78ce42b1617a 100644
--- a/net/mptcp/protocol.c
+++ b/net/mptcp/protocol.c
@@ -596,9 +596,7 @@ static struct sock *mptcp_accept(struct sock *sk, int flags, int *err,
 		return NULL;
 
 	subflow = subflow_ctx(new_sock->sk);
-	pr_debug("new subflow=%p", subflow);
-
-	pr_debug("new msk=%p", msk);
+	pr_debug("msk=%p, new subflow=%p, ", msk, subflow);
 
 	if (subflow->mp_capable) {
 		struct sock *new_mptcp_sock;
@@ -623,7 +621,6 @@ static struct sock *mptcp_accept(struct sock *sk, int flags, int *err,
 		msk->remote_key = subflow->remote_key;
 		msk->local_key = subflow->local_key;
 		msk->token = subflow->token;
-		pr_debug("token=%u", msk->token);
 		token_update_accept(new_sock->sk, new_mptcp_sock);
 		msk->subflow = NULL;
 
-- 
2.17.2


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

* Re: [MPTCP] [PATCH 3/7] mptcp: reduce number of pr_debug() calls.
@ 2019-06-07 11:23 Matthieu Baerts
  0 siblings, 0 replies; 2+ messages in thread
From: Matthieu Baerts @ 2019-06-07 11:23 UTC (permalink / raw)
  To: mptcp

[-- Attachment #1: Type: text/plain, Size: 2800 bytes --]

Hi Peter, Paolo,

On 06/06/2019 02:36, Peter Krystad wrote:
> squash to: Create SUBFLOW socket for incoming connections

Thank you for the patch and the review!

- 17c4b4cad16d: "squash" in "mptcp: Create SUBFLOW socket for incoming
connections": I didn't take one diff, see below
- signed-off was already there
- 5d1039667868: "squash" (part 2) in "mptcp: accept: don't leak mptcp
socket structure"
- no conflict
- 0569a65aca45..eec1d25d9283: result

> Signed-off-by: Peter Krystad <peter.krystad(a)linux.intel.com>
> ---
>  net/mptcp/options.c  | 6 +++---
>  net/mptcp/protocol.c | 5 +----
>  2 files changed, 4 insertions(+), 7 deletions(-)
> 
> diff --git a/net/mptcp/options.c b/net/mptcp/options.c
> index 7475c1d5c15f..b259c4343f36 100644
> --- a/net/mptcp/options.c
> +++ b/net/mptcp/options.c
> @@ -339,14 +339,14 @@ bool mptcp_synack_options(const struct request_sock *req, unsigned int *size,
>  {
>  	struct subflow_request_sock *subflow_req = subflow_rsk(req);
>  
> -	pr_debug("subflow_req=%p", subflow_req);
>  	if (subflow_req->mp_capable) {
>  		opts->suboptions = OPTION_MPTCP_MPC_SYNACK;
>  		opts->sndr_key = subflow_req->local_key;
>  		opts->rcvr_key = subflow_req->remote_key;
>  		*size = TCPOLEN_MPTCP_MPC_SYNACK;
> -		pr_debug("local_key=%llu", subflow_req->local_key);
> -		pr_debug("remote_key=%llu", subflow_req->remote_key);
> +		pr_debug("subflow_req=%p, local_key=%llu, remote_key=%llu",
> +			 subflow_req, subflow_req->local_key,
> +			 subflow_req->remote_key);
>  		return true;
>  	}
>  	return false;
> diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c
> index 902b6c994f00..78ce42b1617a 100644
> --- a/net/mptcp/protocol.c
> +++ b/net/mptcp/protocol.c
> @@ -596,9 +596,7 @@ static struct sock *mptcp_accept(struct sock *sk, int flags, int *err,
>  		return NULL;
>  
>  	subflow = subflow_ctx(new_sock->sk);
> -	pr_debug("new subflow=%p", subflow);
> -
> -	pr_debug("new msk=%p", msk);
> +	pr_debug("msk=%p, new subflow=%p, ", msk, subflow);
>  
>  	if (subflow->mp_capable) {
>  		struct sock *new_mptcp_sock;
> @@ -623,7 +621,6 @@ static struct sock *mptcp_accept(struct sock *sk, int flags, int *err,
>  		msk->remote_key = subflow->remote_key;
>  		msk->local_key = subflow->local_key;
>  		msk->token = subflow->token;
> -		pr_debug("token=%u", msk->token);

This pr_debug() has been added after, in "mptcp: Implement MPTCP receive
path". I then moved this change to the next patch (4/7).

Cheers,
Matt

>  		token_update_accept(new_sock->sk, new_mptcp_sock);
>  		msk->subflow = NULL;
>  
> 

-- 
Matthieu Baerts | R&D Engineer
matthieu.baerts(a)tessares.net
Tessares SA | Hybrid Access Solutions
www.tessares.net
1 Avenue Jean Monnet, 1348 Louvain-la-Neuve, Belgium

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

end of thread, other threads:[~2019-06-07 11:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-06  0:36 [MPTCP] [PATCH 3/7] mptcp: reduce number of pr_debug() calls Peter Krystad
2019-06-07 11:23 Matthieu Baerts

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.