[an error occurred while processing this directive]
[an error occurred while processing this directive]
|
|
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250730075139.21848612@hermes.local>
Date: Wed, 30 Jul 2025 07:51:39 -0700
From: Stephen Hemminger <stephen@...workplumber.org>
To: Hangbin Liu <liuhangbin@...il.com>
Cc: Eric Dumazet <edumazet@...gle.com>, "David S . Miller"
<davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>, Paolo Abeni
<pabeni@...hat.com>, Simon Horman <horms@...nel.org>,
netdev@...r.kernel.org, eric.dumazet@...il.com, Dong Chenchen
<dongchenchen2@...wei.com>
Subject: Re: [PATCH net] selftests: avoid using ifconfig
On Wed, 30 Jul 2025 12:56:19 +0000
Hangbin Liu <liuhangbin@...il.com> wrote:
> On Wed, Jul 30, 2025 at 11:53:13AM +0000, Eric Dumazet wrote:
> > ifconfig is deprecated and not always present, use ip command instead.
> >
> > Fixes: e0f3b3e5c77a ("selftests: Add test cases for vlan_filter modification during runtime")
> > Signed-off-by: Eric Dumazet <edumazet@...gle.com>
> > Cc: Dong Chenchen <dongchenchen2@...wei.com>
>
> Not sure if there is a way to replace the ifconfig in rtnetlink.sh.
>
> Reviewed-by: Hangbin Liu <liuhangbin@...il.com>
>
Would this work:
diff --git a/tools/testing/selftests/net/rtnetlink.sh b/tools/testing/selftests/net/rtnetlink.sh
index 2e8243a65b50..a3d3f2261bab 100755
--- a/tools/testing/selftests/net/rtnetlink.sh
+++ b/tools/testing/selftests/net/rtnetlink.sh
@@ -318,7 +318,7 @@ kci_test_promote_secondaries()
for i in $(seq 2 254);do
IP="10.23.11.$i"
ip -f inet addr add $IP/16 brd + dev "$devdummy"
- ifconfig "$devdummy" $IP netmask 255.255.0.0
+ ip addr add dev "$devdummy" $IP/16
done
ip addr flush dev "$devdummy"
Powered by blists - more mailing lists