All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH mptcp-next 0/3] mptcp: misc. small cleanups
@ 2023-03-29 13:17 Matthieu Baerts
  2023-03-29 13:17 ` [PATCH mptcp-next 1/3] MAINTAINERS: add git trees for MPTCP Matthieu Baerts
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Matthieu Baerts @ 2023-03-29 13:17 UTC (permalink / raw)
  To: mptcp; +Cc: Matthieu Baerts, Abaci Robot, Mat Martineau, Jiapeng Chong

Here is a series of small unrelated cleanups, nothing very important nor
big.

I don't know if the modification of the MAINTAINERS file should go in
-net instead.

Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
---
Matthieu Baerts (3):
      MAINTAINERS: add git trees for MPTCP
      mptcp: remove unused 'remaining' variable
      selftests: mptcp: remove duplicated entries in usage

 MAINTAINERS                                       | 2 ++
 net/mptcp/options.c                               | 7 ++-----
 tools/testing/selftests/net/mptcp/mptcp_connect.c | 8 ++++----
 3 files changed, 8 insertions(+), 9 deletions(-)
---
base-commit: b2c5489c86ee1881dae3bc431ff6f284eb74f7ef
change-id: 20230329-mptcp-misc-cleanups-90754eb81610

Best regards,
-- 
Matthieu Baerts <matthieu.baerts@tessares.net>


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

* [PATCH mptcp-next 1/3] MAINTAINERS: add git trees for MPTCP
  2023-03-29 13:17 [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Matthieu Baerts
@ 2023-03-29 13:17 ` Matthieu Baerts
  2023-03-29 13:17 ` [PATCH mptcp-next 2/3] mptcp: remove unused 'remaining' variable Matthieu Baerts
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 8+ messages in thread
From: Matthieu Baerts @ 2023-03-29 13:17 UTC (permalink / raw)
  To: mptcp; +Cc: Matthieu Baerts

This will help occasional reviewers to find our git repo without having
to look at the wiki.

Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
---
 MAINTAINERS | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/MAINTAINERS b/MAINTAINERS
index 45fe6d7e918a..1b45ba8a1536 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -14607,6 +14607,8 @@ L:	mptcp@lists.linux.dev
 S:	Maintained
 W:	https://github.com/multipath-tcp/mptcp_net-next/wiki
 B:	https://github.com/multipath-tcp/mptcp_net-next/issues
+T:	git https://github.com/multipath-tcp/mptcp_net-next.git export-net
+T:	git https://github.com/multipath-tcp/mptcp_net-next.git export
 F:	Documentation/networking/mptcp-sysctl.rst
 F:	include/net/mptcp.h
 F:	include/trace/events/mptcp.h

-- 
2.39.2


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

* [PATCH mptcp-next 2/3] mptcp: remove unused 'remaining' variable
  2023-03-29 13:17 [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Matthieu Baerts
  2023-03-29 13:17 ` [PATCH mptcp-next 1/3] MAINTAINERS: add git trees for MPTCP Matthieu Baerts
@ 2023-03-29 13:17 ` Matthieu Baerts
  2023-03-29 13:17 ` [PATCH mptcp-next 3/3] selftests: mptcp: remove duplicated entries in usage Matthieu Baerts
  2023-04-07 13:25 ` [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Paolo Abeni
  3 siblings, 0 replies; 8+ messages in thread
From: Matthieu Baerts @ 2023-03-29 13:17 UTC (permalink / raw)
  To: mptcp; +Cc: Matthieu Baerts, Abaci Robot, Mat Martineau, Jiapeng Chong

In some functions, 'remaining' variable was given in argument and/or set but never read.

  net/mptcp/options.c:779:3: warning: Value stored to 'remaining' is never
  read [clang-analyzer-deadcode.DeadStores].

  net/mptcp/options.c:547:3: warning: Value stored to 'remaining' is never
  read [clang-analyzer-deadcode.DeadStores].

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Suggested-by: Mat Martineau <martineau@kernel.org>
Co-developed-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
---
 net/mptcp/options.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/net/mptcp/options.c b/net/mptcp/options.c
index cd3b885c8faa..19a01b6566f1 100644
--- a/net/mptcp/options.c
+++ b/net/mptcp/options.c
@@ -442,7 +442,6 @@ static void clear_3rdack_retransmission(struct sock *sk)
 static bool mptcp_established_options_mp(struct sock *sk, struct sk_buff *skb,
 					 bool snd_data_fin_enable,
 					 unsigned int *size,
-					 unsigned int remaining,
 					 struct mptcp_out_options *opts)
 {
 	struct mptcp_subflow_context *subflow = mptcp_subflow_ctx(sk);
@@ -556,7 +555,6 @@ static void mptcp_write_data_fin(struct mptcp_subflow_context *subflow,
 static bool mptcp_established_options_dss(struct sock *sk, struct sk_buff *skb,
 					  bool snd_data_fin_enable,
 					  unsigned int *size,
-					  unsigned int remaining,
 					  struct mptcp_out_options *opts)
 {
 	struct mptcp_subflow_context *subflow = mptcp_subflow_ctx(sk);
@@ -580,7 +578,6 @@ static bool mptcp_established_options_dss(struct sock *sk, struct sk_buff *skb,
 			opts->ext_copy = *mpext;
 		}
 
-		remaining -= map_size;
 		dss_size = map_size;
 		if (skb && snd_data_fin_enable)
 			mptcp_write_data_fin(subflow, skb, &opts->ext_copy);
@@ -851,9 +848,9 @@ bool mptcp_established_options(struct sock *sk, struct sk_buff *skb,
 	}
 
 	snd_data_fin = mptcp_data_fin_enabled(msk);
-	if (mptcp_established_options_mp(sk, skb, snd_data_fin, &opt_size, remaining, opts))
+	if (mptcp_established_options_mp(sk, skb, snd_data_fin, &opt_size, opts))
 		ret = true;
-	else if (mptcp_established_options_dss(sk, skb, snd_data_fin, &opt_size, remaining, opts)) {
+	else if (mptcp_established_options_dss(sk, skb, snd_data_fin, &opt_size, opts)) {
 		unsigned int mp_fail_size;
 
 		ret = true;

-- 
2.39.2


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

* [PATCH mptcp-next 3/3] selftests: mptcp: remove duplicated entries in usage
  2023-03-29 13:17 [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Matthieu Baerts
  2023-03-29 13:17 ` [PATCH mptcp-next 1/3] MAINTAINERS: add git trees for MPTCP Matthieu Baerts
  2023-03-29 13:17 ` [PATCH mptcp-next 2/3] mptcp: remove unused 'remaining' variable Matthieu Baerts
@ 2023-03-29 13:17 ` Matthieu Baerts
  2023-03-29 14:34   ` selftests: mptcp: remove duplicated entries in usage: Tests Results MPTCP CI
  2023-04-07 14:16   ` MPTCP CI
  2023-04-07 13:25 ` [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Paolo Abeni
  3 siblings, 2 replies; 8+ messages in thread
From: Matthieu Baerts @ 2023-03-29 13:17 UTC (permalink / raw)
  To: mptcp; +Cc: Matthieu Baerts

mptcp_connect tool was printing some duplicated entries when showing how
to use it: -j -l -r

While at it, I also:

 - moved the very few entries that were not sorted,

 - added -R that was missing since
   commit 8a4b910d005d ("mptcp: selftests: add rcvbuf set option")

- removed the -u parameter that has been removed in
  commit f730b65c9d85 ("selftests: mptcp: try to set mptcp ulp mode in different sk states").

No need to backport this, it is just an internal tool used by our
selftests. The help menu is mainly useful for MPTCP kernel devs.

Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
---
 tools/testing/selftests/net/mptcp/mptcp_connect.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/tools/testing/selftests/net/mptcp/mptcp_connect.c b/tools/testing/selftests/net/mptcp/mptcp_connect.c
index b25a31445ded..c7f9ebeebc2c 100644
--- a/tools/testing/selftests/net/mptcp/mptcp_connect.c
+++ b/tools/testing/selftests/net/mptcp/mptcp_connect.c
@@ -106,8 +106,8 @@ static struct cfg_sockopt_types cfg_sockopt_types;
 static void die_usage(void)
 {
 	fprintf(stderr, "Usage: mptcp_connect [-6] [-c cmsg] [-f offset] [-i file] [-I num] [-j] [-l] "
-		"[-m mode] [-M mark] [-o option] [-p port] [-P mode] [-j] [-l] [-r num] "
-		"[-s MPTCP|TCP] [-S num] [-r num] [-t num] [-T num] [-u] [-w sec] connect_address\n");
+		"[-m mode] [-M mark] [-o option] [-p port] [-P mode] [-r num] [-R num] "
+		"[-s MPTCP|TCP] [-S num] [-t num] [-T num] [-w sec] connect_address\n");
 	fprintf(stderr, "\t-6 use ipv6\n");
 	fprintf(stderr, "\t-c cmsg -- test cmsg type <cmsg>\n");
 	fprintf(stderr, "\t-f offset -- stop the I/O after receiving and sending the specified amount "
@@ -126,13 +126,13 @@ static void die_usage(void)
 	fprintf(stderr, "\t-p num -- use port num\n");
 	fprintf(stderr,
 		"\t-P [saveWithPeek|saveAfterPeek] -- save data with/after MSG_PEEK form tcp socket\n");
-	fprintf(stderr, "\t-t num -- set poll timeout to num\n");
-	fprintf(stderr, "\t-T num -- set expected runtime to num ms\n");
 	fprintf(stderr, "\t-r num -- enable slow mode, limiting each write to num bytes "
 		"-- for remove addr tests\n");
 	fprintf(stderr, "\t-R num -- set SO_RCVBUF to num\n");
 	fprintf(stderr, "\t-s [MPTCP|TCP] -- use mptcp(default) or tcp sockets\n");
 	fprintf(stderr, "\t-S num -- set SO_SNDBUF to num\n");
+	fprintf(stderr, "\t-t num -- set poll timeout to num\n");
+	fprintf(stderr, "\t-T num -- set expected runtime to num ms\n");
 	fprintf(stderr, "\t-w num -- wait num sec before closing the socket\n");
 	exit(1);
 }

-- 
2.39.2


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

* Re: selftests: mptcp: remove duplicated entries in usage: Tests Results
  2023-03-29 13:17 ` [PATCH mptcp-next 3/3] selftests: mptcp: remove duplicated entries in usage Matthieu Baerts
@ 2023-03-29 14:34   ` MPTCP CI
  2023-04-07 14:16   ` MPTCP CI
  1 sibling, 0 replies; 8+ messages in thread
From: MPTCP CI @ 2023-03-29 14:34 UTC (permalink / raw)
  To: Matthieu Baerts; +Cc: mptcp

Hi Matthieu,

Thank you for your modifications, that's great!

Our CI did some validations and here is its report:

- KVM Validation: normal (except selftest_mptcp_join):
  - Success! ✅:
  - Task: https://cirrus-ci.com/task/4990035158630400
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/4990035158630400/summary/summary.txt

- KVM Validation: normal (only selftest_mptcp_join):
  - Script error! ❓:
  - Task: https://cirrus-ci.com/task/6115935065473024
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/6115935065473024/summary/summary.txt

- KVM Validation: debug (except selftest_mptcp_join):
  - Unstable: 1 failed test(s): packetdrill_add_addr 🔴:
  - Task: https://cirrus-ci.com/task/5552985112051712
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/5552985112051712/summary/summary.txt

- KVM Validation: debug (only selftest_mptcp_join):
  - Success! ✅:
  - Task: https://cirrus-ci.com/task/6678885018894336
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/6678885018894336/summary/summary.txt

Initiator: Patchew Applier
Commits: https://github.com/multipath-tcp/mptcp_net-next/commits/df1c60a23322


If there are some issues, you can reproduce them using the same environment as
the one used by the CI thanks to a docker image, e.g.:

    $ cd [kernel source code]
    $ docker run -v "${PWD}:${PWD}:rw" -w "${PWD}" --privileged --rm -it \
        --pull always mptcp/mptcp-upstream-virtme-docker:latest \
        auto-debug

For more details:

    https://github.com/multipath-tcp/mptcp-upstream-virtme-docker


Please note that despite all the efforts that have been already done to have a
stable tests suite when executed on a public CI like here, it is possible some
reported issues are not due to your modifications. Still, do not hesitate to
help us improve that ;-)

Cheers,
MPTCP GH Action bot
Bot operated by Matthieu Baerts (Tessares)

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

* Re: [PATCH mptcp-next 0/3] mptcp: misc. small cleanups
  2023-03-29 13:17 [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Matthieu Baerts
                   ` (2 preceding siblings ...)
  2023-03-29 13:17 ` [PATCH mptcp-next 3/3] selftests: mptcp: remove duplicated entries in usage Matthieu Baerts
@ 2023-04-07 13:25 ` Paolo Abeni
  2023-04-11 15:18   ` Matthieu Baerts
  3 siblings, 1 reply; 8+ messages in thread
From: Paolo Abeni @ 2023-04-07 13:25 UTC (permalink / raw)
  To: Matthieu Baerts, mptcp; +Cc: Abaci Robot, Mat Martineau, Jiapeng Chong

On Wed, 2023-03-29 at 15:17 +0200, Matthieu Baerts wrote:
> Here is a series of small unrelated cleanups, nothing very important nor
> big.
> 
> I don't know if the modification of the MAINTAINERS file should go in
> -net instead.
> 
> Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
> ---
> Matthieu Baerts (3):
>       MAINTAINERS: add git trees for MPTCP
>       mptcp: remove unused 'remaining' variable
>       selftests: mptcp: remove duplicated entries in usage
> 
>  MAINTAINERS                                       | 2 ++
>  net/mptcp/options.c                               | 7 ++-----
>  tools/testing/selftests/net/mptcp/mptcp_connect.c | 8 ++++----
>  3 files changed, 8 insertions(+), 9 deletions(-)
> ---
> base-commit: b2c5489c86ee1881dae3bc431ff6f284eb74f7ef
> change-id: 20230329-mptcp-misc-cleanups-90754eb81610

LGTM, nice cleanups!

For the series:

Acked-by: Paolo Abeni <pabeni@redhat.com>


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

* Re: selftests: mptcp: remove duplicated entries in usage: Tests Results
  2023-03-29 13:17 ` [PATCH mptcp-next 3/3] selftests: mptcp: remove duplicated entries in usage Matthieu Baerts
  2023-03-29 14:34   ` selftests: mptcp: remove duplicated entries in usage: Tests Results MPTCP CI
@ 2023-04-07 14:16   ` MPTCP CI
  1 sibling, 0 replies; 8+ messages in thread
From: MPTCP CI @ 2023-04-07 14:16 UTC (permalink / raw)
  To: Matthieu Baerts; +Cc: mptcp

Hi Matthieu,

Thank you for your modifications, that's great!

Our CI did some validations and here is its report:

- KVM Validation: normal (except selftest_mptcp_join):
  - Success! ✅:
  - Task: https://cirrus-ci.com/task/5918299830091776
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/5918299830091776/summary/summary.txt

- KVM Validation: debug (only selftest_mptcp_join):
  - Success! ✅:
  - Task: https://cirrus-ci.com/task/4651662434893824
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/4651662434893824/summary/summary.txt

- KVM Validation: debug (except selftest_mptcp_join):
  - Success! ✅:
  - Task: https://cirrus-ci.com/task/6481249783513088
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/6481249783513088/summary/summary.txt

- KVM Validation: normal (only selftest_mptcp_join):
  - Success! ✅:
  - Task: https://cirrus-ci.com/task/5355349876670464
  - Summary: https://api.cirrus-ci.com/v1/artifact/task/5355349876670464/summary/summary.txt

Initiator: Patchew Applier
Commits: https://github.com/multipath-tcp/mptcp_net-next/commits/a5422f94b9f4


If there are some issues, you can reproduce them using the same environment as
the one used by the CI thanks to a docker image, e.g.:

    $ cd [kernel source code]
    $ docker run -v "${PWD}:${PWD}:rw" -w "${PWD}" --privileged --rm -it \
        --pull always mptcp/mptcp-upstream-virtme-docker:latest \
        auto-debug

For more details:

    https://github.com/multipath-tcp/mptcp-upstream-virtme-docker


Please note that despite all the efforts that have been already done to have a
stable tests suite when executed on a public CI like here, it is possible some
reported issues are not due to your modifications. Still, do not hesitate to
help us improve that ;-)

Cheers,
MPTCP GH Action bot
Bot operated by Matthieu Baerts (Tessares)

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

* Re: [PATCH mptcp-next 0/3] mptcp: misc. small cleanups
  2023-04-07 13:25 ` [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Paolo Abeni
@ 2023-04-11 15:18   ` Matthieu Baerts
  0 siblings, 0 replies; 8+ messages in thread
From: Matthieu Baerts @ 2023-04-11 15:18 UTC (permalink / raw)
  To: Paolo Abeni, mptcp; +Cc: Abaci Robot, Mat Martineau, Jiapeng Chong

Hi Paolo,

On 07/04/2023 15:25, Paolo Abeni wrote:
> On Wed, 2023-03-29 at 15:17 +0200, Matthieu Baerts wrote:
>> Here is a series of small unrelated cleanups, nothing very important nor
>> big.
>>
>> I don't know if the modification of the MAINTAINERS file should go in
>> -net instead.
>>
>> Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
>> ---
>> Matthieu Baerts (3):
>>       MAINTAINERS: add git trees for MPTCP
>>       mptcp: remove unused 'remaining' variable
>>       selftests: mptcp: remove duplicated entries in usage
>>
>>  MAINTAINERS                                       | 2 ++
>>  net/mptcp/options.c                               | 7 ++-----
>>  tools/testing/selftests/net/mptcp/mptcp_connect.c | 8 ++++----
>>  3 files changed, 8 insertions(+), 9 deletions(-)
>> ---
>> base-commit: b2c5489c86ee1881dae3bc431ff6f284eb74f7ef
>> change-id: 20230329-mptcp-misc-cleanups-90754eb81610
> 
> LGTM, nice cleanups!
> 
> For the series:
> 
> Acked-by: Paolo Abeni <pabeni@redhat.com>

Thank you for the review!

Now in our tree (feat. for net-next):

New patches for t/upstream:
- 144a31d2ebfc: MAINTAINERS: add git trees for MPTCP
- 4cd4a5a79d58: mptcp: remove unused 'remaining' variable
- d61fbc5070ca: selftests: mptcp: remove duplicated entries in usage
- Results: d11915457436..34df362b6d0a (export)

Tests are now in progress:

https://cirrus-ci.com/github/multipath-tcp/mptcp_net-next/export/20230411T150102

Cheers,
Matt
-- 
Tessares | Belgium | Hybrid Access Solutions
www.tessares.net

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

end of thread, other threads:[~2023-04-11 15:18 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-29 13:17 [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Matthieu Baerts
2023-03-29 13:17 ` [PATCH mptcp-next 1/3] MAINTAINERS: add git trees for MPTCP Matthieu Baerts
2023-03-29 13:17 ` [PATCH mptcp-next 2/3] mptcp: remove unused 'remaining' variable Matthieu Baerts
2023-03-29 13:17 ` [PATCH mptcp-next 3/3] selftests: mptcp: remove duplicated entries in usage Matthieu Baerts
2023-03-29 14:34   ` selftests: mptcp: remove duplicated entries in usage: Tests Results MPTCP CI
2023-04-07 14:16   ` MPTCP CI
2023-04-07 13:25 ` [PATCH mptcp-next 0/3] mptcp: misc. small cleanups Paolo Abeni
2023-04-11 15:18   ` 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.