diff options
author | Divy Le Ray <divy@chelsio.com> | 2010-10-25 03:35:02 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-10-25 15:14:09 -0400 |
commit | 18edc84cf15cbe114dcdf7e8612ee52586d0aad7 (patch) | |
tree | 304d01879a6928586ac68313c54411e2185cc617 /drivers/net/cxgb3 | |
parent | e341b2ddc1e8e5ff998ac5462dc5138775d1d492 (diff) |
cxgb3: fix device opening error path
Only negative return from bind_qsets() should be considered an error and
propagated.
It fixes an issue reported by IBM on P Series platform.
Signed-off-by: Divy Le Ray <divy@chelsio.com>
Tested-by: Nishanth Aravamudan <nacc@us.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cxgb3')
-rw-r--r-- | drivers/net/cxgb3/cxgb3_main.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/cxgb3/cxgb3_main.c b/drivers/net/cxgb3/cxgb3_main.c index a04ce6a5f637..4e3c12371aae 100644 --- a/drivers/net/cxgb3/cxgb3_main.c +++ b/drivers/net/cxgb3/cxgb3_main.c | |||
@@ -1266,11 +1266,13 @@ static int cxgb_up(struct adapter *adap) | |||
1266 | } | 1266 | } |
1267 | 1267 | ||
1268 | if (!(adap->flags & QUEUES_BOUND)) { | 1268 | if (!(adap->flags & QUEUES_BOUND)) { |
1269 | err = bind_qsets(adap); | 1269 | int ret = bind_qsets(adap); |
1270 | if (err) { | 1270 | |
1271 | CH_ERR(adap, "failed to bind qsets, err %d\n", err); | 1271 | if (ret < 0) { |
1272 | CH_ERR(adap, "failed to bind qsets, err %d\n", ret); | ||
1272 | t3_intr_disable(adap); | 1273 | t3_intr_disable(adap); |
1273 | free_irq_resources(adap); | 1274 | free_irq_resources(adap); |
1275 | err = ret; | ||
1274 | goto out; | 1276 | goto out; |
1275 | } | 1277 | } |
1276 | adap->flags |= QUEUES_BOUND; | 1278 | adap->flags |= QUEUES_BOUND; |