From: Stephen Hemminger <stephen@networkplumber.org>
To: Hangbin Liu <liuhangbin@gmail.com>
Cc: Eric Dumazet <edumazet@google.com>,
"David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Simon Horman <horms@kernel.org>,
netdev@vger.kernel.org, eric.dumazet@gmail.com,
Dong Chenchen <dongchenchen2@huawei.com>
Subject: Re: [PATCH net] selftests: avoid using ifconfig
Date: Wed, 30 Jul 2025 07:51:39 -0700 [thread overview]
Message-ID: <20250730075139.21848612@hermes.local> (raw)
In-Reply-To: <aIoWcxoHfToKkjf4@fedora>
On Wed, 30 Jul 2025 12:56:19 +0000
Hangbin Liu <liuhangbin@gmail.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@google.com>
> > Cc: Dong Chenchen <dongchenchen2@huawei.com>
>
> Not sure if there is a way to replace the ifconfig in rtnetlink.sh.
>
> Reviewed-by: Hangbin Liu <liuhangbin@gmail.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"
next prev parent reply other threads:[~2025-07-30 14:51 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-30 11:53 [PATCH net] selftests: avoid using ifconfig Eric Dumazet
2025-07-30 12:56 ` Hangbin Liu
2025-07-30 14:51 ` Stephen Hemminger [this message]
2025-07-31 1:16 ` Hangbin Liu
2025-08-02 0:14 ` patchwork-bot+netdevbpf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250730075139.21848612@hermes.local \
--to=stephen@networkplumber.org \
--cc=davem@davemloft.net \
--cc=dongchenchen2@huawei.com \
--cc=edumazet@google.com \
--cc=eric.dumazet@gmail.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=liuhangbin@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.