cnic: Return error code in cnic_cm_close() if unsuccessful.

So that bnx2i can handle the error condition immediately and not have to
wait for timeout.

Signed-off-by: Michael Chan <mchan@broadcom.com.
Signed-off-by: Eddie Wai <waie@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Michael Chan 2010-06-15 08:57:00 +00:00 committed by David S. Miller
parent 2850062af1
commit ed99daa5a0

View file

@ -3026,6 +3026,8 @@ static int cnic_cm_close(struct cnic_sock *csk)
if (cnic_close_prep(csk)) {
csk->state = L4_KCQE_OPCODE_VALUE_CLOSE_COMP;
return cnic_cm_close_req(csk);
} else {
return -EALREADY;
}
return 0;
}