From: Saurav Kashyap Date: Wed, 22 Aug 2012 18:21:25 +0000 (-0400) Subject: [SCSI] qla2xxx: Enclose adapter related calls in adapter check in failed state handler. X-Git-Tag: next-20120917~76^2^2~11 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=ed9f803dcee2361e12745d95a5cf54353ca552eb;p=karo-tx-linux.git [SCSI] qla2xxx: Enclose adapter related calls in adapter check in failed state handler. Signed-off-by: Saurav Kashyap Signed-off-by: Chad Dupuis Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/qla2xxx/qla_nx.c b/drivers/scsi/qla2xxx/qla_nx.c index 3a054445fca1..7807444418ff 100644 --- a/drivers/scsi/qla2xxx/qla_nx.c +++ b/drivers/scsi/qla2xxx/qla_nx.c @@ -3028,8 +3028,10 @@ qla8xxx_dev_failed_handler(scsi_qla_host_t *vha) ql_log(ql_log_fatal, vha, 0x00b8, "Disabling the board.\n"); - qla82xx_clear_drv_active(ha); - qla82xx_idc_unlock(ha); + if (IS_QLA82XX(ha)) { + qla82xx_clear_drv_active(ha); + qla82xx_idc_unlock(ha); + } /* Set DEV_FAILED flag to disable timer */ vha->device_flags |= DFLG_DEV_FAILED;