[packages/rdma-core] - updated to 37.1 (ABI rdmav34, i40iw driver replaced by irdma) - updated cxgb3,providers-update pat

qboosh qboosh at pld-linux.org
Mon Oct 25 21:32:33 CEST 2021


commit 3d682da5f5a459c62fd859f266117d243cbd8f46
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Mon Oct 25 21:37:39 2021 +0200

    - updated to 37.1 (ABI rdmav34, i40iw driver replaced by irdma)
    - updated cxgb3,providers-update patches

 rdma-core-cxgb3.patch            |  15 ----
 rdma-core-providers-update.patch | 144 +++++++++++++++++++++++++++++++++++++++
 rdma-core.spec                   |  99 ++++++++++++++-------------
 3 files changed, 196 insertions(+), 62 deletions(-)
---
diff --git a/rdma-core.spec b/rdma-core.spec
index 337bfbf..fbb2270 100644
--- a/rdma-core.spec
+++ b/rdma-core.spec
@@ -6,13 +6,13 @@
 Summary:	RDMA Core Userspace Libraries and Daemons
 Summary(pl.UTF-8):	RDMA Core - biblioteki i demony przestrzeni użytkownika
 Name:		rdma-core
-Version:	31.0
+Version:	37.1
 Release:	1
 License:	BSD or GPL v2
 Group:		Applications/System
 #Source0Download: https://github.com/linux-rdma/rdma-core/releases
 Source0:	https://github.com/linux-rdma/rdma-core/releases/download/v%{version}/%{name}-%{version}.tar.gz
-# Source0-md5:	6076b2cfd5b0b22b88f1fb8dffd1aef7
+# Source0-md5:	cc7227ca3b3357867742c95c73e66600
 Source1:	libibverbs.pc.in
 Source2:	librdmacm.pc.in
 Patch0:		%{name}-static.patch
@@ -50,7 +50,7 @@ Requires:	systemd-units
 Requires:	udev-core
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define		ibv_abi		rdmav25
+%define		ibv_abi		rdmav34
 
 %description
 This is the userspace components for the Linux Kernel's
@@ -66,8 +66,8 @@ included with support for the following Kernel RDMA drivers:
  - iw_cxgb4.ko
  - hfi1.ko
  - hns-roce.ko
- - i40iw.ko
  - ib_qib.ko
+ - irdma.ko
  - mlx4_ib.ko
  - mlx5_ib.ko
  - ib_mthca.ko
@@ -96,8 +96,8 @@ libibverbs w jądrze dla następujących sterowników RDMA z jądra:
  - iw_cxgb4.ko
  - hfi1.ko
  - hns-roce.ko
- - i40iw.ko
  - ib_qib.ko
+ - irdma.ko
  - mlx4_ib.ko
  - mlx5_ib.ko
  - ib_mthca.ko
@@ -391,37 +391,6 @@ application.
 Statyczna wersja sterownika hns, którą można wbudować bezpośrednio w
 aplikację.
 
-%package -n libibverbs-driver-i40iw
-Summary:	Userspace driver for the Intel Ethernet Connection X722 RDMA adapters
-Summary(pl.UTF-8):	Sterownik przestrzeni użytkownika dla kart RDMA Intel Ethernet Connection X722
-Group:		Libraries
-Requires:	libibverbs = %{version}-%{release}
-
-%description -n libibverbs-driver-i40iw
-libi40iw is a userspace driver for the Intel Ethernet Connection X722
-RDMA adapters. It works as a plug-in module for libibverbs that allows
-programs to use RDMA hardware directly from userspace.
-
-%description -n libibverbs-driver-i40iw -l pl.UTF-8
-libi40iw to sterownik przestrzeni użytkownika dla kart RDMA Intel
-Ethernet Connection X722 RDMA. Działa jako moduł ładowany przez
-libibverbs, pozwalający programom na dostęp z przestrzeni użytkownika
-do sprzętu RDMA.
-
-%package -n libibverbs-driver-i40iw-static
-Summary:	Static version of i40iw driver
-Summary(pl.UTF-8):	Statyczna wersja sterownika i40iw
-Group:		Development/Libraries
-Requires:	libibverbs-static = %{version}-%{release}
-
-%description -n libibverbs-driver-i40iw-static
-Static version of i40iw driver, which may be linked directly into
-application.
-
-%description -n libibverbs-driver-i40iw-static -l pl.UTF-8
-Statyczna wersja sterownika i40iw, którą można wbudować bezpośrednio
-w aplikację.
-
 %package -n libibverbs-driver-ipathverbs
 Summary:	Userspace driver for the QLogic InfiniBand HCAs
 Summary(pl.UTF-8):	Sterownik przestrzeni użytkownika dla kart QLogic InfiniBand HCA
@@ -469,6 +438,39 @@ application.
 Statyczna wersja sterownika ipathverbs, którą można wbudować
 bezpośrednio w aplikację.
 
+%package -n libibverbs-driver-irdma
+Summary:	Userspace driver for the Intel Ethernet Connection E810 and X722 RDMA adapters
+Summary(pl.UTF-8):	Sterownik przestrzeni użytkownika dla kart RDMA Intel Ethernet Connection E810 i X722
+Group:		Libraries
+Requires:	libibverbs = %{version}-%{release}
+Obsoletes:	libibverbs-driver-i40iw < 37.1
+
+%description -n libibverbs-driver-irdma
+libirdma is a userspace driver for the Intel Ethernet Connection E810
+and X722 RDMA adapters. It works as a plug-in module for libibverbs
+that allows programs to use RDMA hardware directly from userspace.
+
+%description -n libibverbs-driver-irdma -l pl.UTF-8
+libirdma to sterownik przestrzeni użytkownika dla kart RDMA Intel
+Ethernet Connection E810 i X722. Działa jako moduł ładowany przez
+libibverbs, pozwalający programom na dostęp z przestrzeni użytkownika
+do sprzętu RDMA.
+
+%package -n libibverbs-driver-irdma-static
+Summary:	Static version of irdma driver
+Summary(pl.UTF-8):	Statyczna wersja sterownika irdma
+Group:		Development/Libraries
+Requires:	libibverbs-static = %{version}-%{release}
+Obsoletes:	libibverbs-driver-i40iw-static < 37.1
+
+%description -n libibverbs-driver-irdma-static
+Static version of irdma driver, which may be linked directly into
+application.
+
+%description -n libibverbs-driver-irdma-static -l pl.UTF-8
+Statyczna wersja sterownika irdma, którą można wbudować bezpośrednio
+w aplikację.
+
 %package -n libibverbs-driver-mlx4
 Summary:	Userspace driver for the Mellanox ConnectX InfiniBand HCAs
 Summary(pl.UTF-8):	Sterownik przestrzeni użytkownika dla kart Mellanox ConnectX InfiniBand HCA
@@ -1267,6 +1269,9 @@ rm -rf $RPM_BUILD_ROOT
 %{_includedir}/infiniband/efadv.h
 %{_pkgconfigdir}/libefa.pc
 %{_mandir}/man3/efadv_create_driver_qp.3*
+%{_mandir}/man3/efadv_create_qp_ex.3*
+%{_mandir}/man3/efadv_query_ah.3*
+%{_mandir}/man3/efadv_query_device.3*
 %{_mandir}/man7/efadv.7*
 
 %if %{with static_libs}
@@ -1297,17 +1302,6 @@ rm -rf $RPM_BUILD_ROOT
 %{_libdir}/libhns-%{ibv_abi}.a
 %endif
 
-%files -n libibverbs-driver-i40iw
-%defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/libibverbs/libi40iw-%{ibv_abi}.so
-%{_sysconfdir}/libibverbs.d/i40iw.driver
-
-%if %{with static_libs}
-%files -n libibverbs-driver-i40iw-static
-%defattr(644,root,root,755)
-%{_libdir}/libi40iw-%{ibv_abi}.a
-%endif
-
 %files -n libibverbs-driver-ipathverbs
 %defattr(644,root,root,755)
 %attr(755,roor,root) %{_libexecdir}/truescale-serdes.cmds
@@ -1321,6 +1315,17 @@ rm -rf $RPM_BUILD_ROOT
 %{_libdir}/libipathverbs-%{ibv_abi}.a
 %endif
 
+%files -n libibverbs-driver-irdma
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libibverbs/libirdma-%{ibv_abi}.so
+%{_sysconfdir}/libibverbs.d/irdma.driver
+
+%if %{with static_libs}
+%files -n libibverbs-driver-irdma-static
+%defattr(644,root,root,755)
+%{_libdir}/libirdma-%{ibv_abi}.a
+%endif
+
 %files -n libibverbs-driver-mlx4
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/libibverbs/libmlx4-%{ibv_abi}.so
diff --git a/rdma-core-cxgb3.patch b/rdma-core-cxgb3.patch
index 4ca3b82..f912d66 100644
--- a/rdma-core-cxgb3.patch
+++ b/rdma-core-cxgb3.patch
@@ -3081,18 +3081,3 @@ index 39a44192e..000000000
 -		break;
 -	}
 -}
-diff --git a/redhat/rdma.kernel-init b/redhat/rdma.kernel-init
-index 6f50e72fc..c7444a1c8 100644
---- a/redhat/rdma.kernel-init
-+++ b/redhat/rdma.kernel-init
-@@ -125,10 +125,6 @@ load_hardware_modules()
- 	load_modules mlx5_ib
- 	RC+=$?
-     fi
--    if is_loaded cxgb3 -a ! is_loaded iw_cxgb3; then
--	load_modules iw_cxgb3
--	RC+=$?
--    fi
-     if is_loaded cxgb4 -a ! is_loaded iw_cxgb4; then
- 	load_modules iw_cxgb4
- 	RC+=$?
diff --git a/rdma-core-providers-update.patch b/rdma-core-providers-update.patch
index d1952d1..dd1ca82 100644
--- a/rdma-core-providers-update.patch
+++ b/rdma-core-providers-update.patch
@@ -101,3 +101,147 @@
 -	.free_context = nes_ufree_context,
  };
  PROVIDER_DRIVER(nes, nes_udev_ops);
+--- rdma-core-37.1/providers/cxgb3/iwch.h.orig	2021-10-23 21:31:34.732657063 +0200
++++ rdma-core-37.1/providers/cxgb3/iwch.h	2021-10-24 08:37:17.256269862 +0200
+@@ -143,7 +143,8 @@ static inline unsigned long long_log2(un
+ }
+ 
+ extern int iwch_query_device(struct ibv_context *context,
+-			     struct ibv_device_attr *attr);
++			     const struct ibv_query_device_ex_input *input,
++			     struct ibv_device_attr_ex *attr, size_t attr_size);
+ extern int iwch_query_port(struct ibv_context *context, uint8_t port,
+ 			   struct ibv_port_attr *attr);
+ 
+--- rdma-core-37.1/providers/cxgb3/verbs.c.orig	2021-10-23 21:31:34.735990379 +0200
++++ rdma-core-37.1/providers/cxgb3/verbs.c	2021-10-24 09:00:27.472071750 +0200
+@@ -42,23 +42,24 @@
+ #include "iwch.h"
+ #include "iwch-abi.h"
+ 
+-int iwch_query_device(struct ibv_context *context, struct ibv_device_attr *attr)
++int iwch_query_device(struct ibv_context *context, const struct ibv_query_device_ex_input *input, struct ibv_device_attr_ex *attr, size_t attr_size)
+ {
+-	struct ibv_query_device cmd;
++	struct ib_uverbs_ex_query_device_resp resp;
++	size_t resp_size = sizeof(resp);
+ 	uint64_t raw_fw_ver;
+ 	unsigned major, minor, sub_minor;
+ 	int ret;
+ 
+-	ret = ibv_cmd_query_device(context, attr, &raw_fw_ver, &cmd, 
+-	  			   sizeof cmd);
++	ret = ibv_cmd_query_device_any(context, input, attr, attr_size, &resp, &resp_size);
+ 	if (ret)
+ 		return ret;
+ 
++	raw_fw_ver = resp.base.fw_ver;
+ 	major = (raw_fw_ver >> 32) & 0xffff;
+ 	minor = (raw_fw_ver >> 16) & 0xffff;
+ 	sub_minor = raw_fw_ver & 0xffff;
+ 
+-	snprintf(attr->fw_ver, sizeof attr->fw_ver,
++	snprintf(attr->orig_attr.fw_ver, 64,
+ 		 "%d.%d.%d", major, minor, sub_minor);
+ 
+ 	return 0;
+--- rdma-core-37.1/providers/cxgb3/iwch.c.orig	2021-10-23 21:31:35.429319956 +0200
++++ rdma-core-37.1/providers/cxgb3/iwch.c	2021-10-25 18:20:12.958721287 +0200
+@@ -84,7 +84,7 @@ static void iwch_free_context(struct ibv
+ }
+ 
+ static const struct verbs_context_ops iwch_ctx_common_ops = {
+-	.query_device = iwch_query_device,
++	.query_device_ex = iwch_query_device,
+ 	.query_port = iwch_query_port,
+ 	.alloc_pd = iwch_alloc_pd,
+ 	.dealloc_pd = iwch_free_pd,
+@@ -185,35 +185,6 @@ static bool iwch_device_match(struct ver
+ 	if (!sysfs_dev->match)
+ 		return false;
+ 
+-	/* 
+-	 * Verify that the firmware major number matches.  Major number
+-	 * mismatches are fatal.  Minor number mismatches are tolerated.
+-	 */
+-	if (ibv_get_fw_ver(value, sizeof(value), sysfs_dev))
+-		return false;
+-
+-	cp = strtok(value+1, ".");
+-	sscanf(cp, "%i", &fw_maj);
+-	cp = strtok(NULL, ".");
+-	sscanf(cp, "%i", &fw_min);
+-
+-	if (fw_maj < FW_MAJ) {
+-		fprintf(stderr, "libcxgb3: Fatal firmware version mismatch.  "
+-			"Firmware major number is %u and libcxgb3 needs %u.\n",
+-			fw_maj, FW_MAJ);	
+-		fflush(stderr);
+-		return false;
+-	}
+-
+-	DBGLOG("libcxgb3");
+-
+-	if ((signed int)fw_min < FW_MIN) {
+-		PDBG("libcxgb3: non-fatal firmware version mismatch.  "
+-			"Firmware minor number is %u and libcxgb3 needs %u.\n",
+-			fw_min, FW_MIN);
+-		fflush(stderr);
+-	}
+-
+ 	return true;
+ }
+ 
+--- rdma-core-37.1/providers/nes/nes_umain.c.orig	2021-10-23 21:31:35.429319956 +0200
++++ rdma-core-37.1/providers/nes/nes_umain.c	2021-10-25 20:11:56.505738392 +0200
+@@ -76,7 +76,7 @@ static void nes_ufree_context(struct ibv
+ }
+ 
+ static const struct verbs_context_ops nes_uctx_ops = {
+-	.query_device = nes_uquery_device,
++	.query_device_ex = nes_uquery_device,
+ 	.query_port = nes_uquery_port,
+ 	.alloc_pd = nes_ualloc_pd,
+ 	.dealloc_pd = nes_ufree_pd,
+--- rdma-core-37.1/providers/nes/nes_umain.h.orig	2021-10-23 21:31:34.749323640 +0200
++++ rdma-core-37.1/providers/nes/nes_umain.h	2021-10-25 20:13:09.838674447 +0200
+@@ -346,7 +346,7 @@ static inline struct nes_uqp *to_nes_uqp
+ 
+ 
+ /* nes_uverbs.c */
+-int nes_uquery_device(struct ibv_context *, struct ibv_device_attr *);
++int nes_uquery_device(struct ibv_context *, const struct ibv_query_device_ex_input *, struct ibv_device_attr_ex *, size_t);
+ int nes_uquery_port(struct ibv_context *, uint8_t, struct ibv_port_attr *);
+ struct ibv_pd *nes_ualloc_pd(struct ibv_context *);
+ int nes_ufree_pd(struct ibv_pd *);
+--- rdma-core-37.1/providers/nes/nes_uverbs.c.orig	2021-10-23 21:31:34.749323640 +0200
++++ rdma-core-37.1/providers/nes/nes_uverbs.c	2021-10-25 20:17:56.213789687 +0200
+@@ -74,22 +74,23 @@ struct nes_ud_recv_wr {
+ /**
+  * nes_uquery_device
+  */
+-int nes_uquery_device(struct ibv_context *context, struct ibv_device_attr *attr)
++int nes_uquery_device(struct ibv_context *context, const struct ibv_query_device_ex_input *input, struct ibv_device_attr_ex *attr, size_t attr_size)
+ {
+-	struct ibv_query_device cmd;
++	struct ib_uverbs_ex_query_device_resp resp;
++	size_t resp_size = sizeof(resp);
+ 	uint64_t nes_fw_ver;
+ 	int ret;
+ 	unsigned int minor, major;
+ 
+-	ret = ibv_cmd_query_device(context, attr, &nes_fw_ver,
+-					&cmd, sizeof cmd);
++	ret = ibv_cmd_query_device_any(context, input, attr, attr_size, &resp, &resp_size);
+ 	if (ret)
+ 		return ret;
+ 
++	nes_fw_ver = resp.base.fw_ver;
+ 	major = (nes_fw_ver >> 16) & 0xffff;
+ 	minor = nes_fw_ver & 0xffff;
+ 
+-	snprintf(attr->fw_ver, sizeof attr->fw_ver,
++	snprintf(attr->orig_attr.fw_ver, 64,
+ 		"%d.%d", major, minor);
+ 
+ 	return 0;
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/rdma-core.git/commitdiff/3d682da5f5a459c62fd859f266117d243cbd8f46



More information about the pld-cvs-commit mailing list