]> www.infradead.org Git - users/jedix/linux-maple.git/commit
cnic: Improve error recovery on bnx2x devices
authorMichael Chan <mchan@broadcom.com>
Wed, 4 Jan 2012 12:12:28 +0000 (12:12 +0000)
committerJoe Jin <joe.jin@oracle.com>
Wed, 16 May 2012 06:30:00 +0000 (14:30 +0800)
commit6e6fdfbe4b897e3314999863fe389056f9207d12
treed2d7081df442f1647f70b7e6e8540851ce1cc9ac
parenta1baf987f705502ab2a2afee573b9bdf40a70236
cnic: Improve error recovery on bnx2x devices

When a bnx2x device encounters parity errors, it will not respond to all
SPQ messages.  As a result, the shutdown sequence before reset can take
a long time as the ulp drivers (bnx2i/bnx2fc) have to wait for timeout
of all such messages.

To improve this scenario, when bnx2x returns error on the SPQ, we'll send
an immediate response to the ulp drivers to avoid such lengthy timeouts.

Adjust the return code of relevant functions to return error only if
the message cannot be sent on the SPQ so that we'll generate an error
completion to the ulp drivers.

(cherry picked from commit 23021c21055f88a428b6deb6f803fa0d659e023f)
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Joe Jin <joe.jin@oracle.com>
drivers/net/cnic.c
drivers/net/cnic_defs.h
drivers/net/cnic_if.h