Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 184511
b: refs/heads/master
c: 66883e9
h: refs/heads/master
i:
  184509: d6ff4d5
  184507: 7ae0a0c
  184503: bfe5148
  184495: dac8ecb
  184479: 49380d8
  184447: 74163b7
v: v3
  • Loading branch information
Eddie Wai authored and David S. Miller committed Feb 26, 2010
1 parent 67404ba commit 4c941b0
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a9736c086cc6221659e498f0855152c32dbc1396
refs/heads/master: 66883e90eaa0dd55d395c0f9a0c6da5d50809804
21 changes: 16 additions & 5 deletions trunk/drivers/net/cnic.c
Original file line number Diff line number Diff line change
Expand Up @@ -3108,7 +3108,10 @@ static void cnic_cm_process_kcqe(struct cnic_dev *dev, struct kcqe *kcqe)
break;

case L4_KCQE_OPCODE_VALUE_RESET_RECEIVED:
if (test_and_clear_bit(SK_F_OFFLD_COMPLETE, &csk->flags))
if (test_bit(CNIC_F_BNX2_CLASS, &dev->flags)) {
cnic_cm_upcall(cp, csk, opcode);
break;
} else if (test_and_clear_bit(SK_F_OFFLD_COMPLETE, &csk->flags))
csk->state = opcode;
/* fall through */
case L4_KCQE_OPCODE_VALUE_CLOSE_COMP:
Expand Down Expand Up @@ -3172,6 +3175,16 @@ static int cnic_ready_to_close(struct cnic_sock *csk, u32 opcode)
if (!test_and_set_bit(SK_F_CLOSING, &csk->flags))
return 1;
}
/* 57710+ only workaround to handle unsolicited RESET_COMP
* which will be treated like a RESET RCVD notification
* which triggers the clean up procedure
*/
else if (opcode == L4_KCQE_OPCODE_VALUE_RESET_COMP) {
if (!test_and_set_bit(SK_F_CLOSING, &csk->flags)) {
csk->state = L4_KCQE_OPCODE_VALUE_RESET_RECEIVED;
return 1;
}
}
return 0;
}

Expand All @@ -3181,10 +3194,8 @@ static void cnic_close_bnx2_conn(struct cnic_sock *csk, u32 opcode)
struct cnic_local *cp = dev->cnic_priv;

clear_bit(SK_F_CONNECT_START, &csk->flags);
if (cnic_ready_to_close(csk, opcode)) {
cnic_close_conn(csk);
cnic_cm_upcall(cp, csk, opcode);
}
cnic_close_conn(csk);
cnic_cm_upcall(cp, csk, opcode);
}

static void cnic_cm_stop_bnx2_hw(struct cnic_dev *dev)
Expand Down

0 comments on commit 4c941b0

Please sign in to comment.