]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/net: udpgso_bench_tx: fix dst ip argument
authorwujianguo <wujianguo@chinatelecom.cn>
Wed, 29 Dec 2021 10:58:10 +0000 (18:58 +0800)
committerJakub Kicinski <kuba@kernel.org>
Thu, 30 Dec 2021 01:29:50 +0000 (17:29 -0800)
commit6b58e97b4abb1fd96313f51244c0cc86beed74c2
tree6e57d5886fe13c83e4938639a8365b8284a8b964
parentdcbf71273cf7c77abba34d3307beaccbad94c935
selftests/net: udpgso_bench_tx: fix dst ip argument

udpgso_bench_tx call setup_sockaddr() for dest address before
parsing all arguments, if we specify "-p ${dst_port}" after "-D ${dst_ip}",
then ${dst_port} will be ignored, and using default cfg_port 8000.

This will cause test case "multiple GRO socks" failed in udpgro.sh.

Setup sockaddr after parsing all arguments.

Fixes: 1b5a4274c815 ("selftests: udp gso benchmark")
Signed-off-by: Jianguo Wu <wujianguo@chinatelecom.cn>
Reviewed-by: Willem de Bruijn <willemb@google.com>
Link: https://lore.kernel.org/r/ff620d9f-5b52-06ab-5286-44b945453002@163.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
tools/testing/selftests/net/udpgso_bench_tx.c