From: Guofeng Yue yueguofeng@h-partners.com
mainline inclusion commit ba4580a6c4f16ab7791e4d809eda91d586c1f04f category: bugfix bugzilla: https://gitee.com/src-openeuler/perftest/issues/IBGXBU
Reference: https://github.com/linux-rdma/perftest/commit/8ff29c1603215c012a886284b7184a...
----------------------------
When there are several network interface with different subnet address, perftest tools will always choose default route even I add --source_ip option to ask perftest to bind an interface. I found that there are two options that use the same name "--source_ip". Therefore, change --source_ip to --bind_source_ip to fix init connection establishment with specific interface.
Signed-off-by: Guofeng Yue yueguofeng@h-partners.com --- ...-to-bind_sounce_ip-to-fix-init-conne.patch | 35 +++++++++++++++++++ perftest.spec | 9 ++++- 2 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 0015-modify-source_ip-to-bind_sounce_ip-to-fix-init-conne.patch
diff --git a/0015-modify-source_ip-to-bind_sounce_ip-to-fix-init-conne.patch b/0015-modify-source_ip-to-bind_sounce_ip-to-fix-init-conne.patch new file mode 100644 index 0000000..95e5c41 --- /dev/null +++ b/0015-modify-source_ip-to-bind_sounce_ip-to-fix-init-conne.patch @@ -0,0 +1,35 @@ +From ee491fb51e068f1ff3d0277a3a3b33ee0bb38779 Mon Sep 17 00:00:00 2001 +From: "Huai-En, Tseng" huaien.tseng@shopee.com +Date: Thu, 18 May 2023 11:31:31 +0800 +Subject: [PATCH] modify --source_ip to --bind_sounce_ip to fix init connection + establishment with specific interface + +--- + src/perftest_parameters.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/perftest_parameters.c b/src/perftest_parameters.c +index 0a18b2a..73907ca 100755 +--- a/src/perftest_parameters.c ++++ b/src/perftest_parameters.c +@@ -476,7 +476,7 @@ static void usage(const char *argv0, VerbType verb, TestType tst, int connection + + // please note it is a different source_ip from raw_ethernet case + if (connection_type != RawEth) { +- printf(" --source_ip "); ++ printf(" --bind_source_ip "); + printf(" Source IP of the interface used for connection establishment. By default taken from routing table.\n"); + } + +@@ -2386,7 +2386,7 @@ int parser(struct perftest_parameters *user_param,char *argv[], int argc) + #ifdef HAVE_HNSDV + { .name = "congest_type", .has_arg = 1, .flag = &congest_type_flag, .val = 1}, + #endif +- {.name = "source_ip", .has_arg = 1, .flag = &source_ip_flag, .val = 1}, ++ {.name = "bind_source_ip", .has_arg = 1, .flag = &source_ip_flag, .val = 1}, + {0} + }; + c = getopt_long(argc,argv,"w:y:p:d:i:m:s:n:t:u:S:x:c:q:I:o:M:r:Q:A:l:D:f:B:T:L:E:J:j:K:k:X:W:aFegzRvhbNVCHUOZP",long_options,NULL); +-- +2.33.0 + diff --git a/perftest.spec b/perftest.spec index 737c993..6f48fac 100644 --- a/perftest.spec +++ b/perftest.spec @@ -1,6 +1,6 @@ Name: perftest Version: 4.5 -Release: 11 +Release: 12 License: GPLv2 or BSD Summary: RDMA Performance Testing Tools Url: https://github.com/linux-rdma/perftest @@ -20,6 +20,7 @@ Patch11: 0011-Perftest-Fix-rx_depth-check-for-XRC.patch Patch12: 0012-Perftest-Add-support-for-TD-lock-free-mode.patch Patch13: 0013-Perftest-Fix-TD-lock-free-mode-not-working-for-QP.patch Patch14: 0014-Perftest-Fix-failure-in-creating-cq-when-create-cq-e.patch +Patch15: 0015-modify-source_ip-to-bind_sounce_ip-to-fix-init-conne.patch
BuildRequires: automake gcc libibverbs-devel >= 1.2.0 librdmacm-devel >= 1.0.21 libibumad-devel >= 1.3.10.2 BuildRequires: pciutils-devel libibverbs librdmacm libibumad @@ -47,6 +48,12 @@ done %_bindir/*
%changelog +* Thu Jun 10 2025 Guofeng Yue yueguofeng@h-partners.com - 4.5-12 +- Type: bugfix +- ID: NA +- SUG: NA +- DESC: modify --source_ip to --bind_source_ip to fix init connection establishment with specific interface + * Mon Sep 2 2024 Xinghai Cen cenxinghai@h-partners.com - 4.5-11 - Type: bugfix - ID: NA -- 2.33.0