Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp1805828pxt; Sun, 8 Aug 2021 02:04:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzlCwFwSD6rS0jlDHPC6LorJvtVeFL99tA/ctPI9b3x+UpSFMWxP8G13MZL4u2YKbwG7P4V X-Received: by 2002:a5d:9d93:: with SMTP id ay19mr170994iob.114.1628413492894; Sun, 08 Aug 2021 02:04:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628413492; cv=none; d=google.com; s=arc-20160816; b=JMTFPTAaCMDHOeK6+yPtvDPncNGqBbwcM0O/K1iheVmpAgVPct/O96RlpD4SD2m2UW 2qojHnxp3wdU4LIoaxKSqAuriud1UN0tv59ml9f7FqwueWqQWeo/MHL2Ne097mjXatgW 5SvQ+BaoDZ7cpljxKGy3jXoN7TYkJX2IiQZaL9MjAFXFNNlTi1RNYO9kp5ZoJlSOG7+d zirZfEGMlHLbgWEbmBJjvUvEZ4DAc86UniBFDzo2D/IT/11LtsQpirdmOSOFeY77HJQP BYU54S3nlLA5MRpqBcUm64KwPqrAopAgxh1B3pxhg5fGaalvTphVDpyvEgg92rNyrczk WVgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from:wdcironportexception:ironport-sdr:ironport-sdr :dkim-signature; bh=FHViy5q4056NrBUsdSxFnAjbE6MSOJv9t8qIOmNLpC4=; b=fjaIsQLeBR+N//KOx8G3/9AE7MSo5x6dJDWgIidtNEX0ZzUuV0W1nn4hrZ0yJAHs6h kX4N25BXRMsIap4rxCmfM178Mtsk7M4MeMOwl63sBmkln6Toyac5SCQI+g4xlj6QD9k9 l/g5kC7PXOzeHhHAwxPnu8x3z98waBrU7+UQIWSl8fq2TM8omWoXBoJ8/eb/stu93XS/ FoumuJ14Cw+7tSQIMVlhd0SvVMDdT4rX0D6rVWUgd6SwodnC+/NDBg54ZzghmlEeSEZr /8/9dtbYWiQyQ/y2+psi1Tn5hEDdGUU3gXGgfmZI2Y7oERslJAqc/sBU9R946jzrUTDI MkZA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=chq0CCd2; 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=wdc.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x17si380006ion.97.2021.08.08.02.04.42; Sun, 08 Aug 2021 02:04:52 -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=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=chq0CCd2; 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=wdc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231557AbhHHJBl (ORCPT + 99 others); Sun, 8 Aug 2021 05:01:41 -0400 Received: from esa2.hgst.iphmx.com ([68.232.143.124]:59571 "EHLO esa2.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231130AbhHHJBk (ORCPT ); Sun, 8 Aug 2021 05:01:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1628413281; x=1659949281; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=bjgGRXxjJDNLHzEfzuNKdyk/I6//YiMoxvenotPsMHA=; b=chq0CCd2+dy8PTMMG+WrxC6g+2ATXbOd78f3EsUlCKeFdlc4t63uGXZW lsVgPljKp9tdxnZYVxh7pjEgX6+xvyuSSldLE0lRcKFF3Z56npu6FWi+m 1JkPE4f9GHtAN22X4BNJk67awgzA3oioYApobmbpIhWMfFROWtXWEQmlC 1M8eXyGODR4tZyGtMAUetwCf7KxFhF5RCB07x8FbrQwF/zIZcyF8NV4gF 55FQUqDvjld0LcisakJNa7joIYF5pMsj+e6eeQeXofOdDTR75YtJv2bg6 5FCot8nmCq8BR9FVjyM6lX4Nb7u0ukLOaWTKmTcH23OTFvqjFugFB3q5m A==; X-IronPort-AV: E=Sophos;i="5.84,305,1620662400"; d="scan'208";a="280449782" Received: from uls-op-cesaip02.wdc.com (HELO uls-op-cesaep02.wdc.com) ([199.255.45.15]) by ob1.hgst.iphmx.com with ESMTP; 08 Aug 2021 17:01:21 +0800 IronPort-SDR: fJaxbcIW++bYCTtmNWhuc3GRBvQE4JfjebWgsmJKzsSxIRwgVeOgPmrnpWS8XD2XeGsw8oGSep uVg/QLPX2e0ULpeGMbYF3ymPgVxv557bb2sWPIoSsSqsBl0lc7330kGjuIIlFkSxUWx1yBx8ww cfIKgMbYGBQK7hWzx+ZhiGytuW2HsNkp4dyB+o3hA4UZQiICnuEGBT7HlMrlA+crssB/8QX/tA ONjkKClXBawQtRK8Vor9uMPa+DDGrVuymehtAsys5kI3tKJ6zcqJWNDdZ3n4SnC4P6EwiC2gko Yp0FKtNjhBuiZey7swp5PHD7 Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Aug 2021 01:36:56 -0700 IronPort-SDR: lPE7UCqk6qeiVobRoFkeWH+ksh8W4hROFo5RGGkKM71ycIe8DqVLg//RTI76zsRLo2co6DlP3t q8MLY3qUtbN7prth2t08xKQmGPpEhp0z33jEjoVILevtBzNxbnvglZwQZcpKKIVIdSVlfJ3ffT dqiB2BLmjTjxO976EEK94ipktntTVLoXMlEWO+sWsGTln1lF+Bzs6ik69cfj4L7jUIopJiAy2B 9mJfktIjNB/xDswzDRDXbB66qYsz8ReDBd38r/KQoSwa4HhE2y3ltMbKOWr7ptjAWobPg8StT4 wJE= WDCIronportException: Internal Received: from bxygm33.sdcorp.global.sandisk.com (HELO BXYGM33.ad.shared) ([10.0.231.247]) by uls-op-cesaip02.wdc.com with ESMTP; 08 Aug 2021 02:01:19 -0700 From: Avri Altman To: "James E . J . Bottomley" , "Martin K . Petersen" Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, Bart Van Assche , Daejun Park , Avri Altman Subject: [PATCH 4/4] scsi: ufshpb: Do not report victim error in HCM Date: Sun, 8 Aug 2021 12:00:24 +0300 Message-Id: <20210808090024.21721-5-avri.altman@wdc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210808090024.21721-1-avri.altman@wdc.com> References: <20210808090024.21721-1-avri.altman@wdc.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In host control mode, eviction is perceived as an extreme measure. There are several conditions that both the entering and exiting regions should meet, so that eviction will take place. The common case however, is that those conditions are rarely met, so it is normal that the act of eviction fails. Therefore, Do not report an error in host control mode if eviction fails. Fixes: 6c59cb501b86 (scsi: ufs: ufshpb: Make eviction depend on region's reads) Signed-off-by: Avri Altman --- drivers/scsi/ufs/ufshpb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/scsi/ufs/ufshpb.c b/drivers/scsi/ufs/ufshpb.c index cd48367f94cc..aafb55136c7e 100644 --- a/drivers/scsi/ufs/ufshpb.c +++ b/drivers/scsi/ufs/ufshpb.c @@ -1385,7 +1385,8 @@ static int ufshpb_add_region(struct ufshpb_lu *hpb, struct ufshpb_region *rgn) victim_rgn = ufshpb_victim_lru_info(hpb); if (!victim_rgn) { dev_warn(&hpb->sdev_ufs_lu->sdev_dev, - "cannot get victim region error\n"); + "cannot get victim region %s\n", + hpb->is_hcm ? "" : "error"); ret = -ENOMEM; goto out; } -- 2.17.1