Home Home > GIT Browse > openSUSE-15.1
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Bogendoerfer <tbogendoerfer@suse.de>2019-06-07 13:27:44 +0200
committerThomas Bogendoerfer <tbogendoerfer@suse.de>2019-06-07 13:29:46 +0200
commit96be81dcdac080ddc39c921928b502435e023052 (patch)
tree0107189b7f8b6e32d31c31ec663cc9ec12d964fd
parent8294d0b7342160d1f0711645906ec21f7119c89f (diff)
RDMA/hns: Bugfix for mapping user db (bsc#1104427 FATE#326416
bsc#1137236).
-rw-r--r--patches.drivers/RDMA-hns-Bugfix-for-mapping-user-db.patch41
-rw-r--r--series.conf1
2 files changed, 42 insertions, 0 deletions
diff --git a/patches.drivers/RDMA-hns-Bugfix-for-mapping-user-db.patch b/patches.drivers/RDMA-hns-Bugfix-for-mapping-user-db.patch
new file mode 100644
index 0000000000..c6bc11523f
--- /dev/null
+++ b/patches.drivers/RDMA-hns-Bugfix-for-mapping-user-db.patch
@@ -0,0 +1,41 @@
+From: Lijun Ou <oulijun@huawei.com>
+Date: Tue, 23 Apr 2019 17:30:26 +0800
+Subject: RDMA/hns: Bugfix for mapping user db
+Patch-mainline: v5.1-rc7
+Git-commit: 2557fabd6e29f349bfa0ac13f38ac98aa5eafc74
+References: bsc#1104427 FATE#326416 bsc#1137236
+
+When the maximum send wr delivered by the user is zero, the qp does not
+have a sq.
+
+When allocating the sq db buffer to store the user sq pi pointer and map
+it to the kernel mode, max_send_wr is used as the trigger condition, while
+the kernel does not consider the max_send_wr trigger condition when
+mapmping db. It will cause sq record doorbell map fail and create qp fail.
+
+The failed print information as follows:
+
+ hns3 0000:7d:00.1: Send cmd: tail - 418, opcode - 0x8504, flag - 0x0011, retval - 0x0000
+ hns3 0000:7d:00.1: Send cmd: 0xe59dc000 0x00000000 0x00000000 0x00000000 0x00000116 0x0000ffff
+ hns3 0000:7d:00.1: sq record doorbell map failed!
+ hns3 0000:7d:00.1: Create RC QP failed
+
+Fixes: 0425e3e6e0c7 ("RDMA/hns: Support flush cqe for hip08 in kernel space")
+Signed-off-by: Lijun Ou <oulijun@huawei.com>
+Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
+Acked-by: Thomas Bogendoerfer <tbogendoerfer@suse.de>
+---
+ drivers/infiniband/hw/hns/hns_roce_qp.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/infiniband/hw/hns/hns_roce_qp.c
++++ b/drivers/infiniband/hw/hns/hns_roce_qp.c
+@@ -532,7 +532,7 @@ static int hns_roce_set_kernel_sq_size(s
+
+ static int hns_roce_qp_has_sq(struct ib_qp_init_attr *attr)
+ {
+- if (attr->qp_type == IB_QPT_XRC_TGT)
++ if (attr->qp_type == IB_QPT_XRC_TGT || !attr->cap.max_send_wr)
+ return 0;
+
+ return 1;
diff --git a/series.conf b/series.conf
index 0dc9849c20..f41ef0b464 100644
--- a/series.conf
+++ b/series.conf
@@ -46152,6 +46152,7 @@
patches.drivers/Input-synaptics-rmi4-write-config-register-values-to.patch
patches.drivers/dmaengine-sh-rcar-dmac-With-cyclic-DMA-residue-0-is-.patch
patches.drivers/IB-rdmavt-Fix-frwr-memory-registration.patch
+ patches.drivers/RDMA-hns-Bugfix-for-mapping-user-db.patch
patches.fixes/selinux-use-kernel-linux-socket.h-for-genheaders-and-mdp
patches.drivers/USB-core-Fix-unterminated-string-returned-by-usb_str.patch
patches.drivers/USB-core-Fix-bug-caused-by-duplicate-interface-PM-us.patch