diff options
author | Steve Wise <swise@opengridcomputing.com> | 2010-05-21 01:57:32 +0400 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2010-05-25 08:07:59 +0400 |
commit | 1c01c5388306a4c2245b71da0cba22d521e897ae (patch) | |
tree | 7e4fd41d4517df5d9fc6ae4075cbdb0df6ba0a0a /drivers/infiniband/hw/cxgb4/provider.c | |
parent | fd388ce677e7de9180a7d46d12c5162f76af64ac (diff) | |
download | linux-1c01c5388306a4c2245b71da0cba22d521e897ae.tar.xz |
RDMA/cxgb4: Register RDMA provider based on LLD state_change events
The LLD now supports proper UP state change events, so move the RDMA
provider registration to UP path.
This fixes a crash when loading iw_cxgb4 _after_ the NFS/RDMA
transport is up and running.
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/hw/cxgb4/provider.c')
-rw-r--r-- | drivers/infiniband/hw/cxgb4/provider.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/cxgb4/provider.c b/drivers/infiniband/hw/cxgb4/provider.c index dfc49020bb9c..322134bb8b73 100644 --- a/drivers/infiniband/hw/cxgb4/provider.c +++ b/drivers/infiniband/hw/cxgb4/provider.c @@ -496,6 +496,7 @@ int c4iw_register_device(struct c4iw_dev *dev) if (ret) goto bail2; } + dev->registered = 1; return 0; bail2: ib_unregister_device(&dev->ibdev); @@ -514,5 +515,6 @@ void c4iw_unregister_device(struct c4iw_dev *dev) c4iw_class_attributes[i]); ib_unregister_device(&dev->ibdev); kfree(dev->ibdev.iwcm); + dev->registered = 0; return; } |