xprtrdma: Remove rpcrdma_ep::rep_func and ::rep_xprt
authorChuck Lever <chuck.lever@oracle.com>
Wed, 21 Jan 2015 16:03:11 +0000 (11:03 -0500)
committerAnna Schumaker <Anna.Schumaker@Netapp.com>
Fri, 30 Jan 2015 15:47:48 +0000 (10:47 -0500)
Clean up: The rep_func field always refers to rpcrdma_conn_func().
rep_func should have been removed by commit b45ccfd25d50 ("xprtrdma:
Remove MEMWINDOWS registration modes").

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Reviewed-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
net/sunrpc/xprtrdma/rpc_rdma.c
net/sunrpc/xprtrdma/transport.c
net/sunrpc/xprtrdma/verbs.c
net/sunrpc/xprtrdma/xprt_rdma.h

index d7310109b6014b110e5fec626f799b4bb44ba104..f2eda155299a874f8ca070a79c0e16a8b4b18b85 100644 (file)
@@ -695,7 +695,9 @@ rpcrdma_connect_worker(struct work_struct *work)
 {
        struct rpcrdma_ep *ep =
                container_of(work, struct rpcrdma_ep, rep_connect_worker.work);
-       struct rpc_xprt *xprt = ep->rep_xprt;
+       struct rpcrdma_xprt *r_xprt =
+               container_of(ep, struct rpcrdma_xprt, rx_ep);
+       struct rpc_xprt *xprt = &r_xprt->rx_xprt;
 
        spin_lock_bh(&xprt->transport_lock);
        if (++xprt->connect_cookie == 0)        /* maintain a reserved value */
index ee57513263398bfcced05a3ade4a0823905fa0e9..a487bde71b4a1aab64052adfe72c21a3616739e1 100644 (file)
@@ -376,8 +376,6 @@ xprt_setup_rdma(struct xprt_create *args)
         */
        INIT_DELAYED_WORK(&new_xprt->rx_connect_worker,
                          xprt_rdma_connect_worker);
-       new_ep->rep_func = rpcrdma_conn_func;
-       new_ep->rep_xprt = xprt;
 
        xprt_rdma_format_addresses(xprt);
        xprt->max_payload = rpcrdma_max_payload(new_xprt);
index 71a071aaf0ab686a415d1a6ac82b754f359880d7..c61bb61c4d13388d21685062a8e26925e200f35a 100644 (file)
@@ -154,7 +154,7 @@ rpcrdma_qp_async_error_upcall(struct ib_event *event, void *context)
                event->device->name, context);
        if (ep->rep_connected == 1) {
                ep->rep_connected = -EIO;
-               ep->rep_func(ep);
+               rpcrdma_conn_func(ep);
                wake_up_all(&ep->rep_connect_wait);
        }
 }
@@ -169,7 +169,7 @@ rpcrdma_cq_async_error_upcall(struct ib_event *event, void *context)
                event->device->name, context);
        if (ep->rep_connected == 1) {
                ep->rep_connected = -EIO;
-               ep->rep_func(ep);
+               rpcrdma_conn_func(ep);
                wake_up_all(&ep->rep_connect_wait);
        }
 }
@@ -474,7 +474,7 @@ connected:
                dprintk("RPC:       %s: %sconnected\n",
                                        __func__, connstate > 0 ? "" : "dis");
                ep->rep_connected = connstate;
-               ep->rep_func(ep);
+               rpcrdma_conn_func(ep);
                wake_up_all(&ep->rep_connect_wait);
                /*FALLTHROUGH*/
        default:
index 3fcc92b0e3cafe7e6055bbabdc3a603ac5f5c72b..657c370e48b9e77eaf0cd5a606859958ca2ecd3a 100644 (file)
@@ -87,8 +87,6 @@ struct rpcrdma_ep {
        wait_queue_head_t       rep_connect_wait;
        struct ib_sge           rep_pad;        /* holds zeroed pad */
        struct ib_mr            *rep_pad_mr;    /* holds zeroed pad */
-       void                    (*rep_func)(struct rpcrdma_ep *);
-       struct rpc_xprt         *rep_xprt;      /* for rep_func */
        struct rdma_conn_param  rep_remote_cma;
        struct sockaddr_storage rep_remote_addr;
        struct delayed_work     rep_connect_worker;
This page took 0.030351 seconds and 5 git commands to generate.