diff options
author | Tom Tucker <tom@opengridcomputing.com> | 2008-10-23 23:30:13 +0200 |
---|---|---|
committer | Eric Van Hensbergen <ericvh@gmail.com> | 2008-11-05 20:19:06 +0100 |
commit | 517ac45af4b55913587279d89001171c222f22e7 (patch) | |
tree | b3f30f82d27c7b0df885152ce34e9f475f6470dd /net/9p/trans_rdma.c | |
parent | Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6 (diff) | |
download | linux-517ac45af4b55913587279d89001171c222f22e7.tar.xz linux-517ac45af4b55913587279d89001171c222f22e7.zip |
9p: rdma: Set trans prior to requesting async connection ops
The RDMA connection manager is fundamentally asynchronous.
Since the async callback context is the client pointer, the
transport in the client struct needs to be set prior to calling
the first async op.
Signed-off-by: Tom Tucker <tom@opengridcomputing.com>
Signed-off-by: Eric Van Hensbergen <ericvh@gmail.com>
Diffstat (limited to 'net/9p/trans_rdma.c')
-rw-r--r-- | net/9p/trans_rdma.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/net/9p/trans_rdma.c b/net/9p/trans_rdma.c index 8d6cc4777aae..4e9d2e673cf4 100644 --- a/net/9p/trans_rdma.c +++ b/net/9p/trans_rdma.c @@ -589,6 +589,9 @@ rdma_create_trans(struct p9_client *client, const char *addr, char *args) if (IS_ERR(rdma->cm_id)) goto error; + /* Associate the client with the transport */ + client->trans = rdma; + /* Resolve the server's address */ rdma->addr.sin_family = AF_INET; rdma->addr.sin_addr.s_addr = in_aton(addr); @@ -669,7 +672,6 @@ rdma_create_trans(struct p9_client *client, const char *addr, char *args) if (err || (rdma->state != P9_RDMA_CONNECTED)) goto error; - client->trans = rdma; client->status = Connected; return 0; |