Received: by 2002:a05:7412:7c14:b0:fa:6e18:a558 with SMTP id ii20csp192193rdb; Mon, 22 Jan 2024 00:32:18 -0800 (PST) X-Google-Smtp-Source: AGHT+IHrdhLCCh/G5N0AMdz33WXyqZtZ4M4vAP71xiWx3howg6mrGH4DaaiolDOZgg/d4oxWHHe1 X-Received: by 2002:a05:622a:209:b0:42a:3ea3:447f with SMTP id b9-20020a05622a020900b0042a3ea3447fmr1795044qtx.137.1705912338178; Mon, 22 Jan 2024 00:32:18 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705912338; cv=pass; d=google.com; s=arc-20160816; b=lEbavxnkO1078GR4+e/xM7A99Y2Az3pdtY7LcAh48iz9X6qRZ9JhJLuv0dhLJ2BUe0 hMaowSbUzXENsKFUCGBAwgZAdS1rZrU7NkNNArkMCfbzD7CD1HPSsM9MgE0lUY4uFra7 2iGK/LwT+ZynA2sDghJaKrnFrTACEpROsPE3hLzYSNWUEFjTHSEfNp0J6D0a8w5PdJFh pRuyrthcqGoQFoL1eSOZpyjYbnMUWuDLmAYA1FlOPcAyUGLO1LWVBKaYTxHhz21OuDz7 WSJEmSH8Rq7cWKJYNAtzLg8JiRG7egzAdrK34bglFA0KiYPLrM851etqirNK/cSPSDC6 kZSw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:dlp-filter:cms-type:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :message-id:date:subject:cc:to:from:dkim-signature:dkim-filter; bh=Q9LPucC8reHb0aOkKH2OVTRw75unmT9gWgBiSVlLMbI=; fh=JUPHO5JPg2fxUDWYqQ8lJida5578Eiim2hnITguaQYA=; b=G2QLFFahNpZHwvlle3iWUcc+yu6vn6ymkQUkBX1yrBt8xhjV6nGLxKVCpqKuvz78R6 mAzcYCT4S5uxRd8Y9ov7tIQYv2RXXuMiCtvsyWsgrPEyUV3/RmacO8wE+a3kbwmbpaYp KdQkkcXVAsLz10z4upf33OdsZXfbK9smgXYbI4KN1QZz7jUSGsk601u+N0attuxcRhc6 uEL82ZWKc0gb4dLvv+FbItxDj3Xg0624xNpisprD52HaQfA4HInEzCw1Ik4nWxWKfk4g kHEGQtKyFZ2hG98ZIPDfOcbsVVDxgbFeFY8WF6pej+3CvHFKVixXzFvcq2ylysNcVthk D2iA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=e1f+jOVe; arc=pass (i=1 spf=pass spfdomain=samsung.com dkim=pass dkdomain=samsung.com dmarc=pass fromdomain=samsung.com); spf=pass (google.com: domain of linux-kernel+bounces-32525-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32525-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id t4-20020a05622a01c400b00429fb333416si5009321qtw.53.2024.01.22.00.32.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 Jan 2024 00:32:18 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-32525-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=e1f+jOVe; arc=pass (i=1 spf=pass spfdomain=samsung.com dkim=pass dkdomain=samsung.com dmarc=pass fromdomain=samsung.com); spf=pass (google.com: domain of linux-kernel+bounces-32525-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32525-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id DCB421C210ED for ; Mon, 22 Jan 2024 08:32:17 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1C69021350; Mon, 22 Jan 2024 08:32:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b="e1f+jOVe" Received: from mailout1.samsung.com (mailout1.samsung.com [203.254.224.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 981E6210EE for ; Mon, 22 Jan 2024 08:32:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=203.254.224.24 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705912332; cv=none; b=jnCsmpJddLmnvFjXwg3TEryBccrN6nsBD5wfGKmXCJD4+yMj1dqqkV8y+JPNeM/TZwd4dExPYFfXQg3ZPMQ3FhF8ljW7Mb+uZkfV9y3kvQ2+JTgeJo5sHkFigar0X+SUVi+/u8NtK2MYrQd0n1UDPRrHzrd8r/zR+NjcYaGagh0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705912332; c=relaxed/simple; bh=r8RMMePrnokt+ZSxwLfX4KeSzho5CPuG/hIPS3IXFYs=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version:Content-Type: References; b=cg5VcCzScB8cWdIHEwuSDA+Wm+VW45lDQh6E6PULIBYPz3lMOLIElfwrCjQOwHys6OeUvwbFZdwpYgGz2SJ8b/gPWlkVfhNJITFWYl7K+8SgVVj4W8DWZ9P44EVdliVLs2o6Y94EOfOlq7MSND71lwDGyvCPAIrHLx846rEi5vU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=samsung.com; spf=pass smtp.mailfrom=samsung.com; dkim=pass (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b=e1f+jOVe; arc=none smtp.client-ip=203.254.224.24 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=samsung.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=samsung.com Received: from epcas2p3.samsung.com (unknown [182.195.41.55]) by mailout1.samsung.com (KnoxPortal) with ESMTP id 20240122083206epoutp01f4e862c311ce830e88905ef08fe1ade8~snjkaWKj42324723247epoutp01V for ; Mon, 22 Jan 2024 08:32:06 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.samsung.com 20240122083206epoutp01f4e862c311ce830e88905ef08fe1ade8~snjkaWKj42324723247epoutp01V DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1705912326; bh=Q9LPucC8reHb0aOkKH2OVTRw75unmT9gWgBiSVlLMbI=; h=From:To:Cc:Subject:Date:References:From; b=e1f+jOVe+/8fx6X4J3MDQqdRMoRKromZhB0VCODQp3KBrEq5VcJSXkQ+fIm5ff3cf lnJPNXhqolhGhOzvzxs/E/jjluJrUFsBELhdFu1yMeZMD7JZLW9ST281NNWdlqevK8 MjwveLGBm6Kd0vTYPj8tzoeWBeY2cwPVZg+wRl9U= Received: from epsnrtp3.localdomain (unknown [182.195.42.164]) by epcas2p3.samsung.com (KnoxPortal) with ESMTP id 20240122083206epcas2p3ec5b42f9b9500a1b32855d79cdb2b436~snjj7VJvG1680416804epcas2p3Z; Mon, 22 Jan 2024 08:32:06 +0000 (GMT) Received: from epsmgec2p1-new.samsung.com (unknown [182.195.36.100]) by epsnrtp3.localdomain (Postfix) with ESMTP id 4TJNkF53Dtz4x9QC; Mon, 22 Jan 2024 08:32:05 +0000 (GMT) Received: from epcas2p3.samsung.com ( [182.195.41.55]) by epsmgec2p1-new.samsung.com (Symantec Messaging Gateway) with SMTP id 8D.F7.18994.5082EA56; Mon, 22 Jan 2024 17:32:05 +0900 (KST) Received: from epsmtrp1.samsung.com (unknown [182.195.40.13]) by epcas2p2.samsung.com (KnoxPortal) with ESMTPA id 20240122083204epcas2p26a1bca522e201972ca072e0b24d23a52~snjilEWn31176011760epcas2p2J; Mon, 22 Jan 2024 08:32:04 +0000 (GMT) Received: from epsmgmcp1.samsung.com (unknown [182.195.42.82]) by epsmtrp1.samsung.com (KnoxPortal) with ESMTP id 20240122083204epsmtrp1d662de87164cede84097084f6ffbb349~snjikKGaX0472204722epsmtrp1g; Mon, 22 Jan 2024 08:32:04 +0000 (GMT) X-AuditID: b6c32a4d-743ff70000004a32-39-65ae28058d23 Received: from epsmtip2.samsung.com ( [182.195.34.31]) by epsmgmcp1.samsung.com (Symantec Messaging Gateway) with SMTP id 43.9B.18939.4082EA56; Mon, 22 Jan 2024 17:32:04 +0900 (KST) Received: from rack03.dsn.sec.samsung.com (unknown [10.229.95.126]) by epsmtip2.samsung.com (KnoxPortal) with ESMTPA id 20240122083204epsmtip290d357a363c25a809cb19b11951d9029~snjiWEHmI0795907959epsmtip2S; Mon, 22 Jan 2024 08:32:04 +0000 (GMT) From: SEO HOYOUNG To: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, alim.akhtar@samsung.com, avri.altman@wdc.com, jejb@linux.ibm.com, martin.petersen@oracle.com, beanhuo@micron.com, bvanassche@acm.org, kwangwon.min@samsung.com, kwmad.kim@samsung.com, sh425.lee@samsung.com, sc.suh@samsung.com, quic_nguyenb@quicinc.com, cpgs@samsung.com, grant.jung@samsung.com, junwoo80.lee@samsung.com Cc: SEO HOYOUNG Subject: [PATCH v1] scsi: ufs: core: Remove the ufshcd_release in ufshcd_err_handling_prepare Date: Mon, 22 Jan 2024 17:33:24 +0900 Message-Id: <20240122083324.11797-1-hy50.seo@samsung.com> X-Mailer: git-send-email 2.26.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrLJsWRmVeSWpSXmKPExsWy7bCmuS6rxrpUg9sn1SwezNvGZvHy51U2 i4MPO1kspn34yWzx8pCmxa+/69ktVi9+wGKx6MY2Jotdf5uZLLbe2MlicXPLURaLy7vmsFl0 X9/BZrH8+D8mi6kvjrNbdN29wWix9N9bFgdBj8tXvD0mLDrA6PF9fQebx8ent1g8Ju6p8+jb sorR4/MmOY/2A91MARxR2TYZqYkpqUUKqXnJ+SmZeem2St7B8c7xpmYGhrqGlhbmSgp5ibmp tkouPgG6bpk5QE8oKZQl5pQChQISi4uV9O1sivJLS1IVMvKLS2yVUgtScgrMC/SKE3OLS/PS 9fJSS6wMDQyMTIEKE7IzNm/cyVLwg71ixb5zTA2MD9i6GDk5JARMJC509QPZXBxCAnsYJZpe P2KFcD4xSvz9tArBeTFhHTtMS1v3NGaIxE5GiQt750M5Pxglum8/AxvMJqAhsebYISaQhIhA G7PEyj+XwRLMAmoSn+8uYwGxhQXiJb7M380KYrMIqEr8W74WLM4rYCnxpeknE8Q6eYlFDb+Z IOKCEidnPmGBmCMv0bx1NthmCYGFHBL7n1xnhGhwkZg/5x0LhC0s8er4Fqi7pSRe9rcB2RxA drHErIXVEL0NjBKHZs+CqjGWmPWsnRGkhllAU2L9Ln2IcmWJI7eg1vJJdBz+C1XNK9Gw8TfU RF6JjjYhiLCSxJm5t6HCEhIHZ+dAhD0k1u36BzZFSCBW4s6pk0wTGBVmIflrFpK/ZiGcsICR eRWjVGpBcW56arJRgaFuXmo5PJKT83M3MYLTtZbvDsbX6//qHWJk4mA8xCjBwawkwntDcl2q EG9KYmVValF+fFFpTmrxIUZTYGhPZJYSTc4HZoy8knhDE0sDEzMzQ3MjUwNzJXHee61zU4QE 0hNLUr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ZM2VMH4pkxWO2nZRC/nn82Yfqzqh6R1+1/+0Y5d96AG5xlk6vF/0uK7IlfSwnK71 j1y0Py/K0udRA+eVe5/NPBYYb2Pu+Xrp9uWTaVlXTCyu+PS5hxV8jj1/797LZbcXv17dxSYv M4cnf7fv01kZ163VfO/tbLEr+yzbMkvVdXV91Kr6XSo2qxP7vSyCl2udEM08soH9S3Vgfve2 9lqT2cJP5fZe1Tc/vSJtWvSVtk8TLZxvNdocarvpcJVlWXyQ+eXjfDM/PXedsMnr0+PeK/GH mPi/3X1lWFcgUKpqVNDdvkRO3mqNuUJBvBJLcUaioRZzUXEiAIIEG778AgAA X-CMS-MailID: 20240122083204epcas2p26a1bca522e201972ca072e0b24d23a52 X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-Sendblock-Type: AUTO_CONFIDENTIAL CMS-TYPE: 102P X-CPGSPASS: Y DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20240122083204epcas2p26a1bca522e201972ca072e0b24d23a52 References: If err_handler is performed in the suspend/resume situation, ufs_release can be called twice and active_reqs valid can be negative. This is because ufshcd_errhandling_prepare() and ufshcd_err_handling_unprepare() repeatedly release calls. Eventually, active_reqs have a value different from the intention. To prevent this, release duplication processing was removed. Signed-off-by: SEO HOYOUNG --- drivers/ufs/core/ufshcd.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c index 7c59d7a02243..423e83074a20 100644 --- a/drivers/ufs/core/ufshcd.c +++ b/drivers/ufs/core/ufshcd.c @@ -6351,7 +6351,6 @@ static void ufshcd_err_handling_prepare(struct ufs_hba *hba) ufshcd_hold(hba); if (!ufshcd_is_clkgating_allowed(hba)) ufshcd_setup_clocks(hba, true); - ufshcd_release(hba); pm_op = hba->is_sys_suspended ? UFS_SYSTEM_PM : UFS_RUNTIME_PM; ufshcd_vops_resume(hba, pm_op); } else { -- 2.26.0