[rdma/f18] Various minor fixes
Doug Ledford
dledford at fedoraproject.org
Tue Nov 26 16:18:56 UTC 2013
commit b5e6e42cdbaada3b86d52055e7bfc621e08e0057
Author: Doug Ledford <dledford at redhat.com>
Date: Tue Nov 26 11:18:32 2013 -0500
Various minor fixes
Signed-off-by: Doug Ledford <dledford at redhat.com>
rdma.ifdown-ib | 2 +-
rdma.sbin | 2 +-
rdma.spec | 8 +++++++-
rdma.udev-rules | 18 ++++++++++--------
4 files changed, 19 insertions(+), 11 deletions(-)
---
diff --git a/rdma.ifdown-ib b/rdma.ifdown-ib
index 00ed8c4..b289ea0 100644
--- a/rdma.ifdown-ib
+++ b/rdma.ifdown-ib
@@ -177,7 +177,7 @@ fi
if [ -n "$PKEY" ]; then
# PKey PKEY
- echo "$NEW_PKEY_ID" > /sys/class/net/${PARENTDEVICE}/delete_child
+ echo "$NEW_PKEY_ID" > /sys/class/net/${PHYSDEV}/delete_child
fi
exit $retcode
diff --git a/rdma.sbin b/rdma.sbin
index b960200..f60d5b1 100644
--- a/rdma.sbin
+++ b/rdma.sbin
@@ -27,7 +27,7 @@ if [ -f $CONFIG ]; then
LOAD_ULP_MODULES="ib_ipoib"
fi
- if [ "${RDS_LOAD}" == "yes" ]; then
+ if [ "${RDS_LOAD}" == "yes" -a -f /lib/modules/`uname -r`/kernel/net/rds/rds.ko ]; then
LOAD_ULP_MODULES="$LOAD_ULP_MODULES rds"
fi
diff --git a/rdma.spec b/rdma.spec
index 9835f37..4af946a 100644
--- a/rdma.spec
+++ b/rdma.spec
@@ -6,7 +6,7 @@
Summary: Infiniband/iWARP Kernel Module Initializer
Name: rdma
Version: 2.0
-Release: 12%{?dist}
+Release: 13%{?dist}
License: GPLv2+
Group: System Environment/Base
Source0: rdma.conf
@@ -75,6 +75,12 @@ rm -rf %{buildroot}
/lib/udev/rules.d/*
%changelog
+* Tue Nov 26 2013 Doug Ledford <dledford at redhat.com> - 2.0-13
+- Fix bug in ifdown-ib script handling of P_Key devs
+- Move setting of node_desc to udev rules and make it more reliable
+- Only load RDS if rds kernel module exists as we've disabled it
+ in some places
+
* Tue Jul 30 2013 Doug Ledford <dledford at redhat.com> - 2.0-12
- Change VLAN/PKEY in ifup/ifdown scripts. Overloading VLAN was
causing problems
diff --git a/rdma.udev-rules b/rdma.udev-rules
index 64dcd80..01e01de 100644
--- a/rdma.udev-rules
+++ b/rdma.udev-rules
@@ -4,12 +4,14 @@
# enable the IB stack, so do so unilaterally) and on load of any of that
# hardware, we trigger the rdma.service load in systemd
-SUBSYSTEM=="module", KERNEL=="cxgb3", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
-SUBSYSTEM=="module", KERNEL=="cxgb4", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
-SUBSYSTEM=="module", KERNEL=="ib_mthca", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
-SUBSYSTEM=="module", KERNEL=="mlx4_core", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
-SUBSYSTEM=="module", KERNEL=="ib_ipath", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
-SUBSYSTEM=="module", KERNEL=="ib_qib", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
-SUBSYSTEM=="module", KERNEL=="iw_c2", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
-SUBSYSTEM=="module", KERNEL=="iw_nes", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
+SUBSYSTEM=="module", KERNEL=="cxgb*", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
+SUBSYSTEM=="module", KERNEL=="ib_*", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
+SUBSYSTEM=="module", KERNEL=="mlx*", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
+SUBSYSTEM=="module", KERNEL=="iw_*", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
SUBSYSTEM=="module", KERNEL=="be2net", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
+SUBSYSTEM=="module", KERNEL=="enic", ACTION=="add", TAG+="systemd", ENV{SYSTEMD_WANTS}="rdma.service"
+
+# When we detect a new verbs device is added to the system, set the node
+# description on that device
+SUBSYSTEM=="infiniband", KERNEL=="*", ACTION=="add", RUN+="/bin/bash -c 'sleep 1; echo -n `hostname -s` %k > /sys/class/infiniband/%k/node_desc'"
+
More information about the scm-commits
mailing list