From: Bhanu Prakash Gollapudi Date: Fri, 5 Aug 2011 00:38:43 +0000 (-0700) Subject: [SCSI] bnx2fc: Clear DESTROY_CMPL flag after firmware destroy X-Git-Tag: v2.6.39-400.9.0~423^2~19^2~11^2~443 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=da0d8f74f7fa7863225bfd8dbe542c30906df80f;p=users%2Fjedix%2Flinux-maple.git [SCSI] bnx2fc: Clear DESTROY_CMPL flag after firmware destroy Since this flag was never cleared, the driver does not wait for firmware destroy completions, causing missed KCQEs. Signed-off-by: Bhanu Prakash Gollapudi Signed-off-by: James Bottomley (cherry picked from commit cd703ae790a07ece30e51a8583ea2490d14efb7c) Signed-off-by: Joe Jin --- diff --git a/drivers/scsi/bnx2fc/bnx2fc_fcoe.c b/drivers/scsi/bnx2fc/bnx2fc_fcoe.c index c461992c38b83..e0636473e2e95 100644 --- a/drivers/scsi/bnx2fc/bnx2fc_fcoe.c +++ b/drivers/scsi/bnx2fc/bnx2fc_fcoe.c @@ -772,8 +772,8 @@ static void bnx2fc_destroy_timer(unsigned long data) { struct bnx2fc_hba *hba = (struct bnx2fc_hba *)data; - BNX2FC_MISC_DBG("ERROR:bnx2fc_destroy_timer - " - "Destroy compl not received!!\n"); + printk(KERN_ERR PFX "ERROR:bnx2fc_destroy_timer - " + "Destroy compl not received!!\n"); set_bit(BNX2FC_FLAG_DESTROY_CMPL, &hba->flags); wake_up_interruptible(&hba->destroy_wait); } @@ -1702,6 +1702,7 @@ static void bnx2fc_fw_destroy(struct bnx2fc_hba *hba) wait_event_interruptible(hba->destroy_wait, test_bit(BNX2FC_FLAG_DESTROY_CMPL, &hba->flags)); + clear_bit(BNX2FC_FLAG_DESTROY_CMPL, &hba->flags); /* This should never happen */ if (signal_pending(current)) flush_signals(current);