Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp256611pxx; Wed, 28 Oct 2020 04:15:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzj3UNG5cJ2DwBb7gfH22wd+7VDq2WaDUuIUSn+sdetn2ZM9TmmCuywealG3+7+VoaDJJZh X-Received: by 2002:a17:906:1a04:: with SMTP id i4mr7304152ejf.24.1603883728075; Wed, 28 Oct 2020 04:15:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603883728; cv=none; d=google.com; s=arc-20160816; b=yvveuuOQYiWtj74cntEWtKrdJN+P3L5+M+kzLFtAtKNlFov4rCGhyJVcJqZZMXgkyJ SX4ctxzoFiNtzNJZTcE6HrHVRnapfbF0AEKma+ekAqYOEvJSMqL0F6rty3ktL14DL8B0 TlWvY+j5lUW00Udp7FzE20ZAigqByWxsyLsiclpN6zq9wKWV/jumNm7/NGgY0/7jtts6 vVYjA967v4On/ay05u1BGICvZY1KmFbZ96JmZVAeoycNMOvOOi3KYa8msp1VBIiYp33t vu9NrlieekW4Em2FqXBuJjzjDZofEMHRf0ESkAwrNQPPVjJDJtad6oM0iPgk3rAx5Xm+ 2uBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=vruU1WFBXyjPPOd/L837xDmRb+b/26MK8VyJChUFI74=; b=ob+00MaPpfvXVe901EdU5WssZ1+Gm/q2NoATpaAV1r9x/zxAIFFngSvDdbe6bx7WlO PjE0ZXbqiQkpncNVhbzjNgxFSjUG4pTdLfFgTAMr4g7oWF52hc5aZvqZCx5FeMpAXcWE Wz1F0PghSLD1IlE+a6qS10QEKiSsRU5L4pl+Rc8qNL5ocbwCgqY5EypjfG+D5Cae/nyM uXSLlSDod/IZMRmBOjiViaXkzQTu95obl7iRa5pyFlCtU6/BbqZneeEnAikanQzB7nEI KupHyQhBCDVh90KPCtu65S8HF97fPaIqpph2z1m8gJueamyelalCAo3iofhY0euKjFY1 LSKQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=vcHhyTfF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bs17si3022913ejb.543.2020.10.28.04.15.05; Wed, 28 Oct 2020 04:15:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=vcHhyTfF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1788053AbgJ0PAW (ORCPT + 99 others); Tue, 27 Oct 2020 11:00:22 -0400 Received: from mail.kernel.org ([198.145.29.99]:56640 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1781703AbgJ0O4E (ORCPT ); Tue, 27 Oct 2020 10:56:04 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id AC52A22264; Tue, 27 Oct 2020 14:56:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603810564; bh=hDVORjIq6JPZCf+Mkul67ROnnJelVfKrbcgJPP7pvv0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=vcHhyTfFypERorAKKpcDS7KgBiMvhZRHJQspLFTDxbqNYjVCQCEHe2fCPs8r7unyP E/Q3UNksVj2yZquTRXi79/if4k+33VSPgjFxAp61W5nhni27INhQ7EkMzBKEuhHKBU h2hRyV55p4NIaQITznamblhfynYl4Kp2ooTd0vKY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Quinn Tran , Tianjia Zhang , "Martin K. Petersen" , Sasha Levin Subject: [PATCH 5.8 176/633] scsi: qla2xxx: Fix wrong return value in qlt_chk_unresolv_exchg() Date: Tue, 27 Oct 2020 14:48:39 +0100 Message-Id: <20201027135530.939811328@linuxfoundation.org> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201027135522.655719020@linuxfoundation.org> References: <20201027135522.655719020@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Tianjia Zhang [ Upstream commit bbf2d06a9d767718bfe6028d6288c03edb98554a ] In the case of a failed retry, a positive value EIO is returned here. I think this is a typo error. It is necessary to return an error value. [mkp: caller checks != 0 but the rest of the file uses -Exxx so fix this up to be consistent] Link: https://lore.kernel.org/r/20200802111528.4974-1-tianjia.zhang@linux.alibaba.com Fixes: 0691094ff3f2 ("scsi: qla2xxx: Add logic to detect ABTS hang and response completion") Cc: Quinn Tran Signed-off-by: Tianjia Zhang Signed-off-by: Martin K. Petersen Signed-off-by: Sasha Levin --- drivers/scsi/qla2xxx/qla_target.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/qla2xxx/qla_target.c b/drivers/scsi/qla2xxx/qla_target.c index 90289162dbd4c..a034e9caa2997 100644 --- a/drivers/scsi/qla2xxx/qla_target.c +++ b/drivers/scsi/qla2xxx/qla_target.c @@ -5668,7 +5668,7 @@ static int qlt_chk_unresolv_exchg(struct scsi_qla_host *vha, /* found existing exchange */ qpair->retry_term_cnt++; if (qpair->retry_term_cnt >= 5) { - rc = EIO; + rc = -EIO; qpair->retry_term_cnt = 0; ql_log(ql_log_warn, vha, 0xffff, "Unable to send ABTS Respond. Dumping firmware.\n"); -- 2.25.1