Received: by 10.223.176.5 with SMTP id f5csp776530wra; Sat, 3 Feb 2018 10:02:07 -0800 (PST) X-Google-Smtp-Source: AH8x227VEecQwKjOACpzbMmaNd0ekNEprgDclUGHTg7Q3lbd8quoH7QDpaj2/864DKVDFWdOZvXP X-Received: by 10.99.184.25 with SMTP id p25mr25461471pge.96.1517680927383; Sat, 03 Feb 2018 10:02:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517680927; cv=none; d=google.com; s=arc-20160816; b=pPnVR0CiPU52bm3JR+GFHLRc676Pa4qHfcjTdUh9CUNUnI1Qn15lc6BWp0Q+x7GUmq uKlGC4/dtfiNTb3BH7e8+nteja8flfcDTE5y6bD2PE+nFmfAa4dMCifgFRbwgGtl0FvT AIFCI8kLaqrZcvO0Te+RpJbwp0/YgHFiwedHokf4scvhk+voTm19KiwwIDS4x9CWuP0w CECV/RXJGmPHBvEuuXY4hxewfDMUrlo2znDjELmmjS0HYKH/Mh6Z9BWL3FyaDYrv0Y3r G8dfPzd6vmh5uDUz+xk/yfoebF/yLD3jDsb/ZrXU/YCXYcSZI5ofyOIukDCbZTaZlas0 HpjA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=T6meZv7+Fd/gQssU006hnnK7yvBEXyeGESA2Hgigl4E=; b=vyQGfJAolZKWPtFGkyJ+1Mp8I3EWabFuNzUDD1GeASzDoKm9V648/m7qsrF+NPPtfd scpp0g1wr8konMVqnlj2nWmUvcF3jdhmmpAVsWPH30AW2+leih15QcMQnhsFsRxnzk8G WKUNYmzYjbmB6CSKbb5fYBU/oh7T3fsZEVdiOEwFYdhDjVyAn0guV9j6+l5VLn35dtln tVAncBa+WpNo7Y+XwU4/04BYUYQ8Sg+cBdFYbzGfU/2uEot4tTZUWxljbAwp6Bn/tFmI zGmhhqh/EbiA/vB9Bxt0S2TzmneU+KizawDiXHWNlIgbj6dEPDMsDOAQ2VJXXuSh+Omk vIZQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=jSGtThzW; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v32-v6si2091190plb.725.2018.02.03.10.01.40; Sat, 03 Feb 2018 10:02:07 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=jSGtThzW; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752847AbeBCSBI (ORCPT + 99 others); Sat, 3 Feb 2018 13:01:08 -0500 Received: from mail-co1nam03on0122.outbound.protection.outlook.com ([104.47.40.122]:24267 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752708AbeBCSAh (ORCPT ); Sat, 3 Feb 2018 13:00:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=T6meZv7+Fd/gQssU006hnnK7yvBEXyeGESA2Hgigl4E=; b=jSGtThzW9moA7ifcOghvnhpiXWv/ikfHPKRoVWN7H1gKaEs9OZKe/hojEQyIFL2W4+SI1Zf1r+9cGGwlRTxFUy5MSRcZN4w8AF2DBuGGs1ooWlwsjXABX7gqdb+4E5/K9lrK6gDXneVNFIHOpbjYgToirPUimBkTYzhdw/F8UgU= Received: from BL0PR2101MB1027.namprd21.prod.outlook.com (52.132.20.161) by BL0PR2101MB1043.namprd21.prod.outlook.com (52.132.24.13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.506.3; Sat, 3 Feb 2018 18:00:32 +0000 Received: from BL0PR2101MB1027.namprd21.prod.outlook.com ([fe80::a8da:b5d9:d710:9bf9]) by BL0PR2101MB1027.namprd21.prod.outlook.com ([fe80::a8da:b5d9:d710:9bf9%3]) with mapi id 15.20.0485.006; Sat, 3 Feb 2018 18:00:32 +0000 From: Sasha Levin To: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" CC: James Smart , James Smart , Christoph Hellwig , Sasha Levin Subject: [PATCH AUTOSEL for 4.14 008/110] nvme-fc: remove double put reference if admin connect fails Thread-Topic: [PATCH AUTOSEL for 4.14 008/110] nvme-fc: remove double put reference if admin connect fails Thread-Index: AQHTnRjgYDi4pzVI+U6qcp7RPUIqAQ== Date: Sat, 3 Feb 2018 18:00:30 +0000 Message-ID: <20180203180015.29073-8-alexander.levin@microsoft.com> References: <20180203180015.29073-1-alexander.levin@microsoft.com> In-Reply-To: <20180203180015.29073-1-alexander.levin@microsoft.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [52.168.54.252] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;BL0PR2101MB1043;6:iNHfHT/0S+WbFcSGFNLm4byVjHlCCSPCsad4bAX05WLwYglagCpbR7zXRiZxycG/bqzTkD4F/HM+/bIFyWArOtuZv0lmzI5XHfiori9BCXtlZFMxkbNUKtOR51Kb2vpRkyuYgzuCW6KWGS5m0GrV6Kwf3TK32IyBSJ4QRDSkUIkuE3QrB9avYLeF0w4IDXA68Ur4GcxkiEyBV5XftoQlsCd7HV9jq4jVDp6ULIjj0Mb+c/2WVF184dyBwSsxPrurZu4SA3BcC5UKdyri1nvm6iZFXWLenPSWLdihXrgWrOlJxitmT91eozsca1jvpdnd+Nbe3ip7P3/35tu303suFxtxFLOrYMfAuSwBelMheaF50R3spGuMvHLpzeJBz4AD;5:3JAhRtBtGGYnSqXwJHM3NNQ4lPBzNqtaVDSWwyntDSpSVCVCLMjyf7FgApVtgI2cT7ztF+MkPrZX+Jj8CEEwvoD9ORDpWiqLJNda6OJcuitIWQ7pcsTDZTR2kFqDUuh76rG106ztAwBbFvLXQOIrR0CcM7DJeg/vMVieAM3ZkjQ=;24:/ZUcJk9Kn8Hzumy5bsod8QCfcrTtDKiNAKvnwt7pcnVYgzNzR2DP4xuco3Oa7Gf4PIwFNG0zquUqf0+Am++Upzd1Em9FxJE2SlkvzJOeiYI=;7:cjWyq7QD1vdZHzfVQLgU6JYkSiV1HatLdHDwPZ3DFMgLuI8LCskKq3arq4DI3mrH/KrWpyPtZyAbv88llbLXuIfSaCColXUBbnJofqI+sPQGzv7t2A86ukOqCp+VJF8ehhwajLrnfCqC8TYZ4F3g5LgtWSn4CmgliO8TkIuA/lVmtqO8bxuBlnicRfKp0jYTxh8UrBw78KTKXzQjpxmKNXZHmV9RVsYj1Ln1EDHUsFXoAXRUHtFH6GAYYvy/pZYL x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: b0d1a52f-bfc6-4c42-ce66-08d56b3004bc x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(48565401081)(4534165)(4627221)(201703031133081)(201702281549075)(5600026)(4604075)(3008032)(2017052603307)(7193020);SRVR:BL0PR2101MB1043; x-ms-traffictypediagnostic: BL0PR2101MB1043: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(28532068793085)(89211679590171)(85827821059158)(21532816269658); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(61425038)(6040501)(2401047)(5005006)(8121501046)(3231101)(2400082)(944501161)(93006095)(93001095)(3002001)(10201501046)(6055026)(61426038)(61427038)(6041288)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123558120)(20161123562045)(20161123564045)(6072148)(201708071742011);SRVR:BL0PR2101MB1043;BCL:0;PCL:0;RULEID:;SRVR:BL0PR2101MB1043; x-forefront-prvs: 05724A8921 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(39380400002)(376002)(39860400002)(366004)(346002)(396003)(189003)(199004)(59450400001)(10290500003)(186003)(6486002)(14454004)(1076002)(102836004)(6506007)(76176011)(26005)(6346003)(66066001)(10090500001)(5250100002)(36756003)(6512007)(2501003)(110136005)(99286004)(54906003)(478600001)(53936002)(72206003)(6436002)(316002)(305945005)(7736002)(2950100002)(2906002)(5660300001)(4326008)(106356001)(86362001)(97736004)(25786009)(22452003)(39060400002)(2900100001)(3846002)(107886003)(8676002)(8936002)(6116002)(3280700002)(105586002)(81156014)(81166006)(3660700001)(86612001)(68736007)(22906009)(217873001);DIR:OUT;SFP:1102;SCL:1;SRVR:BL0PR2101MB1043;H:BL0PR2101MB1027.namprd21.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; received-spf: None (protection.outlook.com: microsoft.com does not designate permitted sender hosts) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Alexander.Levin@microsoft.com; x-microsoft-antispam-message-info: OW9ihuocaG7b1t7Zzgh3eFrUcODoXxsdGiZGwsc2AVUYbZemfYg3JQQrL5XW5kJHwSW1+1iXfPutAmm/hp8SPg== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-Network-Message-Id: b0d1a52f-bfc6-4c42-ce66-08d56b3004bc X-MS-Exchange-CrossTenant-originalarrivaltime: 03 Feb 2018 18:00:30.1440 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR2101MB1043 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: James Smart [ Upstream commit 4596e752db02d47038cd7c965419789ab15d1985 ] There are two put references in the failure case of initial create_association. The first put actually frees the controller, thus the second put references freed memory. Remove the unnecessary 2nd put. Signed-off-by: James Smart Signed-off-by: Christoph Hellwig Signed-off-by: Sasha Levin --- drivers/nvme/host/fc.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/nvme/host/fc.c b/drivers/nvme/host/fc.c index 3148d760d825..7deb7b5d8683 100644 --- a/drivers/nvme/host/fc.c +++ b/drivers/nvme/host/fc.c @@ -2876,7 +2876,6 @@ nvme_fc_init_ctrl(struct device *dev, struct nvmf_ctr= l_options *opts, =20 /* initiate nvme ctrl ref counting teardown */ nvme_uninit_ctrl(&ctrl->ctrl); - nvme_put_ctrl(&ctrl->ctrl); =20 /* Remove core ctrl ref. */ nvme_put_ctrl(&ctrl->ctrl); --=20 2.11.0