prov/verbs: backport addr_format filter to v1.22.x (cherry-pick 8db79ab3b) - #12264
Conversation
…r_format> This commit addresses issue ofiwg#9443 for verbs provider. Address format matching needs to happen for each info in the linked list which was not happening earlier. This check has been moved to the end of vrb_getinfo(). Signed-off-by: Juee Himalbhai Desai <juee.himalbhai.desai@intel.com> Signed-off-by: Alexander Timofeyev <atimofeyev@linkedin.com>
Runtime verification — RoCE on RDMA hardwareRan
Stock 1.22 returns the same 40 verbs/rxm entries no matter which This is the precise gap that prevents the DAOS-side patch daos-stack/daos#18254 from being effective on the Happy to add a fabtests entry exercising the hint if reviewers want one; the existing |
|
Please add a line |
|
AWS CI is not running with verbs and can be ignored (and it is failing because the jenkinsfile in that branch is old using some deprecated OSes) |
|
@alexandertimofeyev Please accept the invitation I sent to you so that the CI can run properly. |
Summary
Cherry-pick of upstream commit
8db79ab3b("prov/verbs: Fix issue while displaying addresses with fi_info -a <addr_format>", merged 2024-07-30 by @jueedesai) onto the v1.22.x maintenance branch.The fix is already present in
mainand everyv2.xmaintenance branch but never made it tov1.22.x. Without it, callers that passhints->addr_format = FI_SOCKADDR_IN6intofi_getinfo()against the verbs provider get the hint silently ignored:vrb_getinfo()validates the hint viaofi_valid_addr_format()but does not prune the returnedfi_infolinked list, so v4 entries from the dual-stackgetifaddrs()enumeration remain at the head of the list. Downstream consumers that simply useinfo_list[0]end up on a v4-mapped GID even when they explicitly requested IPv6.The patch adds the static
vrb_filter_info_by_addr_format()helper and a 3-line call site at the end ofvrb_getinfo(). Same code that exists in main and v2.x.Motivation
DAOS 2.6.x pins libfabric 1.22.0-2 (
utils/rpms/daos.spec). Operators running DAOS over RoCE on dual-stack networks who want to land the data plane on IPv6 (rather than a v4-mapped GID) currently have no path:FI_VERBS_GID_IDXonly affects UD/DGRAM, not theverbs;ofi_rxm(RC + RDMA-CM) path used by DAOS. The forthcoming DAOS PR daos-stack/daos#18254 (DAOS-18972) passesaddr_format = FI_SOCKADDR_IN6tofi_getinfofrom CaRT, but on stock libfabric 1.22 that hint is currently a no-op.This backport closes the gap so the DAOS-side patch becomes effective on the libfabric version DAOS actually ships, without requiring DAOS to bump to libfabric ≥ 2.0.0.
Verification
vrb_getinfo()now referencesofi_match_addr_formatandfi_freeinfo(compiler inlines the small static filter helper at -O2), confirmed viaobjdump -dandnmon the resultingverbs_info.o.hints->addr_format; no API/ABI change, no test surface impact (existing fabtestsmsg_sockets.calready exercises v6 sockaddrs).Test plan
fi_info -p verbsreturns only v6 entries whenFI_SOCKADDR_IN6is requested via the APIcc @jueedesai (original author)
🤖 Generated with Claude Code