diff options
Diffstat (limited to 'drivers/infiniband/hw/cxgb3/iwch.c')
-rw-r--r-- | drivers/infiniband/hw/cxgb3/iwch.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/cxgb3/iwch.c b/drivers/infiniband/hw/cxgb3/iwch.c index 4489c89d6710..37a4fc264a07 100644 --- a/drivers/infiniband/hw/cxgb3/iwch.c +++ b/drivers/infiniband/hw/cxgb3/iwch.c | |||
@@ -51,13 +51,15 @@ cxgb3_cpl_handler_func t3c_handlers[NUM_CPL_CMDS]; | |||
51 | 51 | ||
52 | static void open_rnic_dev(struct t3cdev *); | 52 | static void open_rnic_dev(struct t3cdev *); |
53 | static void close_rnic_dev(struct t3cdev *); | 53 | static void close_rnic_dev(struct t3cdev *); |
54 | static void iwch_err_handler(struct t3cdev *, u32, u32); | ||
54 | 55 | ||
55 | struct cxgb3_client t3c_client = { | 56 | struct cxgb3_client t3c_client = { |
56 | .name = "iw_cxgb3", | 57 | .name = "iw_cxgb3", |
57 | .add = open_rnic_dev, | 58 | .add = open_rnic_dev, |
58 | .remove = close_rnic_dev, | 59 | .remove = close_rnic_dev, |
59 | .handlers = t3c_handlers, | 60 | .handlers = t3c_handlers, |
60 | .redirect = iwch_ep_redirect | 61 | .redirect = iwch_ep_redirect, |
62 | .err_handler = iwch_err_handler | ||
61 | }; | 63 | }; |
62 | 64 | ||
63 | static LIST_HEAD(dev_list); | 65 | static LIST_HEAD(dev_list); |
@@ -160,6 +162,17 @@ static void close_rnic_dev(struct t3cdev *tdev) | |||
160 | mutex_unlock(&dev_mutex); | 162 | mutex_unlock(&dev_mutex); |
161 | } | 163 | } |
162 | 164 | ||
165 | static void iwch_err_handler(struct t3cdev *tdev, u32 status, u32 error) | ||
166 | { | ||
167 | struct cxio_rdev *rdev = tdev->ulp; | ||
168 | |||
169 | if (status == OFFLOAD_STATUS_DOWN) | ||
170 | rdev->flags = CXIO_ERROR_FATAL; | ||
171 | |||
172 | return; | ||
173 | |||
174 | } | ||
175 | |||
163 | static int __init iwch_init_module(void) | 176 | static int __init iwch_init_module(void) |
164 | { | 177 | { |
165 | int err; | 178 | int err; |