From patchwork Tue Nov 12 09:30:57 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Garry X-Patchwork-Id: 179177 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp7856018ilf; Tue, 12 Nov 2019 01:34:50 -0800 (PST) X-Google-Smtp-Source: APXvYqxvnobnx9X0f7nBoa0hMwHBAATBCDocHC8Mw41CHFyKo3Apdn5T7M4/z1iIxExm3TyhDfrR X-Received: by 2002:aa7:d916:: with SMTP id a22mr18254307edr.115.1573551290728; Tue, 12 Nov 2019 01:34:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573551290; cv=none; d=google.com; s=arc-20160816; b=WIy+KvyBiB2wNSV1417Q0XFGTfPJtSXDfbOXqNUfk+/L72V+XmLgnprynrKYW/6HBW i+ql/+IKdcV3oj2jF7yHjOB/szjCQCeQaRkmD3vfZsJ/OFcfK8AyKUunSaBbJwC7zRVg PbDZD7YGCXljH/7wgv8xb8+DMYV3xAPSPInzuvjYL8+kX/zjnQnemEKrvNZNSPj0V20U hwS2yg532dK3a/zmF4MFid55/NMjUaE6utXkQJh0KVoUacjwZXk4geoptZNngCUX85dP AujjOa5TPaG7+tonUKcg7ycRQbYqlegPoU4nCkN0kjxgcsLRvtE9XV51zq6kwtWI/g1h VXfg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from; bh=pk77XTFRNYH6rGy2KygEfMud1uU95+LWvPA4jBPtRHI=; b=bSyFB0MMVGQJ0S3JUW9Y1cEizp28lQczBDq9hmV1dE7ouzxi9aVolAx7+VR0wc/hCN xLKX7dm06RzCmYZphIlTuBtD7yLNq/mkYum+LP7lUZByxNhhM/wTA6shzS0t/0XvfLcv DbWbijqsxP4Qgdanjfp43SaOnZKsI/LoOEq64879oqBdT/8WKPoV2Bq8Ft2sNONMowSB gM4gmrbJWlGliZtEh+YrSGFVAQuIzTLLFkJqihz9SpRThPBZ3Mlv1Sr+gPAcR8Of0zfX DrG9axSypbk3uNP1IQV3TUQZjIZGvVhGbcpYl38Bp8WxhvT7qyBEuVhC9UbAve6HZne/ Veiw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c3si14111272edx.315.2019.11.12.01.34.50; Tue, 12 Nov 2019 01:34:50 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727478AbfKLJes (ORCPT + 26 others); Tue, 12 Nov 2019 04:34:48 -0500 Received: from szxga05-in.huawei.com ([45.249.212.191]:6207 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727216AbfKLJe1 (ORCPT ); Tue, 12 Nov 2019 04:34:27 -0500 Received: from DGGEMS401-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id D7E0CD00DD1FD5603B76; Tue, 12 Nov 2019 17:34:24 +0800 (CST) Received: from localhost.localdomain (10.69.192.58) by DGGEMS401-HUB.china.huawei.com (10.3.19.201) with Microsoft SMTP Server id 14.3.439.0; Tue, 12 Nov 2019 17:34:18 +0800 From: John Garry To: , CC: , , , Xiang Chen Subject: [PATCH 2/4] scsi: hisi_sas: Return directly if init hardware failed Date: Tue, 12 Nov 2019 17:30:57 +0800 Message-ID: <1573551059-107873-3-git-send-email-john.garry@huawei.com> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1573551059-107873-1-git-send-email-john.garry@huawei.com> References: <1573551059-107873-1-git-send-email-john.garry@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.69.192.58] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Xiang Chen Need to return directly if init hardware failed. Fixes: 73a4925d154c ("scsi: hisi_sas: Update all the registers after suspend and resume") Signed-off-by: Xiang Chen --- drivers/scsi/hisi_sas/hisi_sas_v3_hw.c | 1 + 1 file changed, 1 insertion(+) -- 2.17.1 Signed-off-by: John Garry diff --git a/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c b/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c index 2ae7070db41a..b7836406debe 100644 --- a/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c +++ b/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c @@ -3432,6 +3432,7 @@ static int hisi_sas_v3_resume(struct pci_dev *pdev) if (rc) { scsi_remove_host(shost); pci_disable_device(pdev); + return rc; } hisi_hba->hw->phys_init(hisi_hba); sas_resume_ha(sha);