diff mbox series

[net,1/2] selftests: mptcp: join: only check for ip6tables if needed

Message ID 20230725-send-net-20230725-v1-1-6f60fe7137a9@kernel.org (mailing list archive)
State Accepted
Commit 016e7ba47f33064fbef8c4307a2485d2669dfd03
Delegated to: Netdev Maintainers
Headers show
Series mptcp: More fixes for 6.5 | expand

Checks

Context Check Description
netdev/series_format success Posting correctly formatted
netdev/tree_selection success Clearly marked for net
netdev/fixes_present success Fixes tag present in non-next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 9 this patch: 9
netdev/cc_maintainers warning 2 maintainers not CCed: shuah@kernel.org linux-kselftest@vger.kernel.org
netdev/build_clang success Errors and warnings before: 9 this patch: 9
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success net selftest script(s) already in Makefile
netdev/verify_fixes success Fixes tag looks correct
netdev/build_allmodconfig_warn success Errors and warnings before: 9 this patch: 9
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 10 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Mat Martineau July 25, 2023, 6:34 p.m. UTC
From: Matthieu Baerts <matthieu.baerts@tessares.net>

If 'iptables-legacy' is available, 'ip6tables-legacy' command will be
used instead of 'ip6tables'. So no need to look if 'ip6tables' is
available in this case.

Fixes: 0c4cd3f86a40 ("selftests: mptcp: join: use 'iptables-legacy' if available")
Acked-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
Signed-off-by: Mat Martineau <martineau@kernel.org>
---
 tools/testing/selftests/net/mptcp/mptcp_join.sh | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Comments

Greg Kroah-Hartman July 25, 2023, 6:39 p.m. UTC | #1
On Tue, Jul 25, 2023 at 11:34:55AM -0700, Mat Martineau wrote:
> From: Matthieu Baerts <matthieu.baerts@tessares.net>
> 
> If 'iptables-legacy' is available, 'ip6tables-legacy' command will be
> used instead of 'ip6tables'. So no need to look if 'ip6tables' is
> available in this case.
> 
> Fixes: 0c4cd3f86a40 ("selftests: mptcp: join: use 'iptables-legacy' if available")
> Acked-by: Paolo Abeni <pabeni@redhat.com>
> Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
> Signed-off-by: Mat Martineau <martineau@kernel.org>
> ---
>  tools/testing/selftests/net/mptcp/mptcp_join.sh | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh
> index e6c9d5451c5b..3c2096ac97ef 100755
> --- a/tools/testing/selftests/net/mptcp/mptcp_join.sh
> +++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh
> @@ -162,9 +162,7 @@ check_tools()
>  	elif ! iptables -V &> /dev/null; then
>  		echo "SKIP: Could not run all tests without iptables tool"
>  		exit $ksft_skip
> -	fi
> -
> -	if ! ip6tables -V &> /dev/null; then
> +	elif ! ip6tables -V &> /dev/null; then
>  		echo "SKIP: Could not run all tests without ip6tables tool"
>  		exit $ksft_skip
>  	fi
> 
> -- 
> 2.41.0
> 

<formletter>

This is not the correct way to submit patches for inclusion in the
stable kernel tree.  Please read:
    https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
for how to do this properly.

</formletter>
Mat Martineau July 25, 2023, 9:08 p.m. UTC | #2
On Tue, 25 Jul 2023, Greg KH wrote:

> On Tue, Jul 25, 2023 at 11:34:55AM -0700, Mat Martineau wrote:
>> From: Matthieu Baerts <matthieu.baerts@tessares.net>
>>
>> If 'iptables-legacy' is available, 'ip6tables-legacy' command will be
>> used instead of 'ip6tables'. So no need to look if 'ip6tables' is
>> available in this case.
>>
>> Fixes: 0c4cd3f86a40 ("selftests: mptcp: join: use 'iptables-legacy' if available")
>> Acked-by: Paolo Abeni <pabeni@redhat.com>
>> Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net>
>> Signed-off-by: Mat Martineau <martineau@kernel.org>
>> ---
>>  tools/testing/selftests/net/mptcp/mptcp_join.sh | 4 +---
>>  1 file changed, 1 insertion(+), 3 deletions(-)
>>
>> diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh
>> index e6c9d5451c5b..3c2096ac97ef 100755
>> --- a/tools/testing/selftests/net/mptcp/mptcp_join.sh
>> +++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh
>> @@ -162,9 +162,7 @@ check_tools()
>>  	elif ! iptables -V &> /dev/null; then
>>  		echo "SKIP: Could not run all tests without iptables tool"
>>  		exit $ksft_skip
>> -	fi
>> -
>> -	if ! ip6tables -V &> /dev/null; then
>> +	elif ! ip6tables -V &> /dev/null; then
>>  		echo "SKIP: Could not run all tests without ip6tables tool"
>>  		exit $ksft_skip
>>  	fi
>>
>> --
>> 2.41.0
>>
>
> <formletter>
>
> This is not the correct way to submit patches for inclusion in the
> stable kernel tree.  Please read:
>    https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
> for how to do this properly.
>
> </formletter>

Ugh, I did forget to add the "Cc: stable@vger.kernel.org" tag in the 
commit messages for this series and only added in the email cc field.

Jakub/Paolo, if you apply the series as-is I can make sure these end up in 
stable (as they likely will even without the cc tag). If you prefer I send 
a v2 just let me know.


- Mat
diff mbox series

Patch

diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh
index e6c9d5451c5b..3c2096ac97ef 100755
--- a/tools/testing/selftests/net/mptcp/mptcp_join.sh
+++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh
@@ -162,9 +162,7 @@  check_tools()
 	elif ! iptables -V &> /dev/null; then
 		echo "SKIP: Could not run all tests without iptables tool"
 		exit $ksft_skip
-	fi
-
-	if ! ip6tables -V &> /dev/null; then
+	elif ! ip6tables -V &> /dev/null; then
 		echo "SKIP: Could not run all tests without ip6tables tool"
 		exit $ksft_skip
 	fi