From: Nicholas Bellinger Date: Thu, 20 Feb 2014 01:50:22 +0000 (-0800) Subject: qla2xxx: Check + fail when npiv_vports_inuse exists in shutdown X-Git-Tag: v3.14-rc5~7^2~8 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3c231bdae1e7c8d366eeb133980b81dff2e1e809;p=pandora-kernel.git qla2xxx: Check + fail when npiv_vports_inuse exists in shutdown This patch adds an check to qlt_stop_phase1() to avoid shutdown when the base_vha contains a non-zero fc_host->npiv_vports_inuse count. This includes holding qla_tgt_mutex in qlt_stop_phase1() between the fc_host->npiv_vports_inuse check + setting of tgt->tgt_stop to avoid a possible race between qlt_lport_register() -> tcm_qla2xxx -> tcm_qla2xxx_lport_register_npiv_cb() calling fc_vport_create(). Cc: Sawan Chandak Cc: Quinn Tran Cc: Saurav Kashyap Cc: Giridhar Malavali Signed-off-by: Nicholas Bellinger --- Reading git-diff-tree failed