From patchwork Thu May 21 17:55:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Smart X-Patchwork-Id: 6457951 Return-Path: X-Original-To: patchwork-linux-scsi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 3202CC0020 for ; Thu, 21 May 2015 17:55:27 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5D1C22051D for ; Thu, 21 May 2015 17:55:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 84E9120523 for ; Thu, 21 May 2015 17:55:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932251AbbEURzY (ORCPT ); Thu, 21 May 2015 13:55:24 -0400 Received: from mail-qk0-f172.google.com ([209.85.220.172]:36093 "EHLO mail-qk0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932217AbbEURzX (ORCPT ); Thu, 21 May 2015 13:55:23 -0400 Received: by qkx62 with SMTP id 62so14710276qkx.3 for ; Thu, 21 May 2015 10:55:23 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:subject:message-id:user-agent :mime-version:content-type:content-transfer-encoding; bh=wbkaIX2WhtW7P5ThVP9gdZbRleMG7YEoQVJxML2dr2w=; b=E21cdwH8X610EytTmRYJ/nWxgnh+TX1xHjsY13IMXqyXiaoq7IY/8pVKqj3/PZqkUm CziFaBv/75paO1+Ws7Enr6eXQL7H3SOtEhQVGywPKEOCgvJCYx7lBIE5I9Lm3es2NPZ3 6qHxgpPGx6eVQeKonokQZ2SrnSkcDBMghvNS/evX0XWgIQFM7IufPiA0VwqkgCZmfWel xzHI3HmU33K5kOi6/VFL+3zg6vOppNe0cv4EP+/4oNClxL8v34vF85BueyxY+q1J/Pk2 a5lYwXwTK9J765l7u0LgZZkQ4t2lC7QN/EqyGKmfNJW3QQkHro3IdMDQNgLyA2crGwow nHEg== X-Gm-Message-State: ALoCoQlnJmX3b3DR9RhYDi9xkf9DnHqwrhPhwrbfMF1peASH8uxcLSChLFDigaNKH5Sp+erLh8cZ X-Received: by 10.140.16.173 with SMTP id 42mr5593948qgb.31.1432230922907; Thu, 21 May 2015 10:55:22 -0700 (PDT) Received: from myfc17 (c-75-67-235-135.hsd1.nh.comcast.net. [75.67.235.135]) by mx.google.com with ESMTPSA id m48sm13687590qgd.35.2015.05.21.10.55.21 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 21 May 2015 10:55:22 -0700 (PDT) Date: Thu, 21 May 2015 13:55:17 -0400 From: james.smart@avagotech.com (James Smart) To: linux-scsi@vger.kernel.org Subject: [PATCH v2 02/15] lpfc: Correct loss of target discovery after cable swap. Message-ID: <555e1c05.rC0jgIm4nXsedlru%james.smart@avagotech.com> User-Agent: Heirloom mailx 12.5 7/5/10 MIME-Version: 1.0 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Correct loss of target discovery after cable swap. Fix incorrect reference counting Signed-off-by: Dick Kennedy Signed-off-by: James Smart --- drivers/scsi/lpfc/lpfc_hbadisc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/lpfc/lpfc_hbadisc.c b/drivers/scsi/lpfc/lpfc_hbadisc.c index f2db89f..72388a6 100644 --- a/drivers/scsi/lpfc/lpfc_hbadisc.c +++ b/drivers/scsi/lpfc/lpfc_hbadisc.c @@ -4296,9 +4296,9 @@ lpfc_drop_node(struct lpfc_vport *vport, struct lpfc_nodelist *ndlp) if (vport->phba->sli_rev == LPFC_SLI_REV4) { lpfc_cleanup_vports_rrqs(vport, ndlp); lpfc_unreg_rpi(vport, ndlp); - } else { - lpfc_nlp_put(ndlp); } + + lpfc_nlp_put(ndlp); return; }