Skip to contentSkip to conversation

svcrdma: Fix incorrect return value/type in svc_rdma_post_recvs

PATCH In review Chuck Lever 2 participants 2 messages May 14, 2018 – May 16, 2018

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 svcrdma: Fix incorrect return value/type in svc_rdma_post_recvs

This crept in during the development process and wasn't caught before I posted the "final" version.

Fixes 0b2613c5883f ('svcrdma: Allocate recv_ctxt's on CPU ... ')
---
 net/sunrpc/xprtrdma/svc_rdma_recvfrom.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/sunrpc/xprtrdma/svc_rdma_recvfrom.c +1 -1
index 09ce09b..841fca1 100644
@@ -270,7 +270,7 @@ bool svc_rdma_post_recvs(struct svcxprt_rdma *rdma)
 	for (i = 0; i < rdma->sc_max_requests; i++) {
 		ctxt = svc_rdma_recv_ctxt_get(rdma);
 		if (!ctxt)
-			return -ENOMEM;
+			return false;
 		ctxt->rc_temp = true;
 		ret = __svc_rdma_post_recv(rdma, ctxt);
 		if (ret) {
#1 lore raw

Thanks!

--b.

Quoted 23 lines · Chuck Lever

This crept in during the development process and wasn't caught before I posted the "final" version.

Fixes 0b2613c5883f ('svcrdma: Allocate recv_ctxt's on CPU ... ')
---
 net/sunrpc/xprtrdma/svc_rdma_recvfrom.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/sunrpc/xprtrdma/svc_rdma_recvfrom.c +1 -1
index 09ce09b..841fca1 100644
@@ -270,7 +270,7 @@ bool svc_rdma_post_recvs(struct svcxprt_rdma *rdma)
 	for (i = 0; i < rdma->sc_max_requests; i++) {
 		ctxt = svc_rdma_recv_ctxt_get(rdma);
 		if (!ctxt)
-			return -ENOMEM;
+			return false;
 		ctxt->rc_temp = true;
 		ret = __svc_rdma_post_recv(rdma, ctxt);
 		if (ret) {