From nobody Sat Jun 13 01:45:53 2026 Received: from mailout4.samsung.com (mailout4.samsung.com [203.254.224.34]) (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 EC6D440DFC0 for ; Thu, 16 Apr 2026 01:07:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=203.254.224.34 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776301645; cv=none; b=FdZmy1R4OOaELJTSQiCuFOLj0CjY4qgDgyEk31yGD+fxK/VeSNvawC/BU+SUojF7AxR8dF7oKkBi1QwjS83TMPaF0vHAtNmgIymplFk1BvQ+sD0EW2fsxmo9S1RJrqZfuMV0Vs8Af9BtsM+4LGuIhonpx24nPTCIipT+WkG2J3M= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776301645; c=relaxed/simple; bh=zu8ajfbg2Dz1eaDX4ahqlJla9e+NBkqU/7sm/XsQA2g=; h=Mime-Version:Subject:From:To:CC:Message-ID:Date:Content-Type: References; b=aAvC9AY4kZMIB/mI3a4Jfum+exfG9HXkBafkyJwCx1iEPsiiP+qPSWEm7AWvNBD82s4L3SzXTuO14K+L9os0ePIYQg7+1LSsmbnfDwBg/U2s1gxN5cGPMXiFAPDq1n4WWcCmxPGvAExNYX4nNP47vyy1XGwuvB7WG8wu1wXRCTc= 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=Qr+DcI7q; arc=none smtp.client-ip=203.254.224.34 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 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b="Qr+DcI7q" Received: from epcas2p1.samsung.com (unknown [182.195.41.53]) by mailout4.samsung.com (KnoxPortal) with ESMTP id 20260416010714epoutp04011edf64dc8740f181a01fd667ba47b1~msOz95Tng1850318503epoutp04T for ; Thu, 16 Apr 2026 01:07:14 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout4.samsung.com 20260416010714epoutp04011edf64dc8740f181a01fd667ba47b1~msOz95Tng1850318503epoutp04T DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1776301635; bh=dOcrdt3IS2q/Pm2ZxII48JYZMOmqsJvtRrRQXt2YHi0=; h=Subject:Reply-To:From:To:CC:Date:References:From; b=Qr+DcI7qNxu2Pm+sMK/vD7RNE1oGtvV+ikFtpnJGy+qZ8uxk4wt+uzwVfw5o0v9Hc 6BCvEBBMt5Srt/f0Aa5PG3HXdeySrDQR2vyH99Mt6CT5UlEiMu+SLABUSdQ+U6c1/s jf3izetitQptRGFHhUZH/oh69YGLp206glOXK92c= Received: from epsnrtp01.localdomain (unknown [182.195.42.153]) by epcas2p3.samsung.com (KnoxPortal) with ESMTPS id 20260416010714epcas2p3293bed73537e5176d2a4cf093833dc89~msOzdQY2T1776317763epcas2p3I; Thu, 16 Apr 2026 01:07:14 +0000 (GMT) Received: from epcas2p2.samsung.com (unknown [182.195.38.212]) by epsnrtp01.localdomain (Postfix) with ESMTP id 4fx0Gp1H28z6B9mK; Thu, 16 Apr 2026 01:07:14 +0000 (GMT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Subject: [PATCH v6] nvme: Skip trace complete_rq on host path error Reply-To: hmi.jeon@samsung.com Sender: =?UTF-8?B?7KCE66+87Iud?= From: =?UTF-8?B?7KCE66+87Iud?= To: "kbusch@kernel.org" , "hch@lst.de" CC: "axboe@kernel.dk" , "sagi@grimberg.me" , "linux-nvme@lists.infradead.org" , "linux-kernel@vger.kernel.org" , =?UTF-8?B?7KCE66+87Iud?= , =?UTF-8?B?7J207J2A7IiY?= , =?UTF-8?B?7Lm47LCs?= X-Priority: 3 X-Content-Kind-Code: NORMAL X-CPGS-Detection: blocking_info_exchange X-Drm-Type: N,general X-Msg-Generator: Mail X-Msg-Type: PERSONAL X-Reply-Demand: N Message-ID: <20260416010713epcms2p78575bd400f93f6edb7fe3f3ead5bf930@epcms2p7> Date: Thu, 16 Apr 2026 10:07:13 +0900 X-CMS-MailID: 20260416010713epcms2p78575bd400f93f6edb7fe3f3ead5bf930 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" X-Sendblock-Type: AUTO_CONFIDENTIAL CMS-TYPE: 102P cpgsPolicy: CPGSC10-223,Y X-CFilter-Loop: Reflected X-CMS-RootMailID: 20260416010713epcms2p78575bd400f93f6edb7fe3f3ead5bf930 References: From cfd386c2d769552c4dd32ec8ff5233ef34f9830d Mon Sep 17 00:00:00 2001 From: Minsik Jeon Date: Thu, 16 Apr 2026 10:43:00 +0900 Subject: [PATCH v6] nvme: Skip trace complete_rq on host path error we were checking host_pathing_error before calling nvme_setup_cmd(). This is caused the command setup to be skipped entirely when a pathing error occurred, making it impossible to trace the nvme command via trace_cmd nvme_complete_rq(). As a result, when nvme_complete_rq() logged a completion with cmdid=3D0, it was impossible to correlate the completion with the nvme command request. This patch Skip trace_nvme_complete_rq() on NVMe host path error. Co-authored-by: Beomsoo Kim Co-authored-by: Eunsoo Lee Co-authored-by: Steven Seungcheol Lee Signed-off-by: Minsik Jeon --- drivers/nvme/host/core.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c index 1e33af94c24b..e92c97fad305 100644 --- a/drivers/nvme/host/core.c +++ b/drivers/nvme/host/core.c @@ -454,11 +454,10 @@ void nvme_end_req(struct request *req) blk_mq_end_request(req, status); } =20 -void nvme_complete_rq(struct request *req) +void __nvme_complete_rq(struct request *req) { struct nvme_ctrl *ctrl =3D nvme_req(req)->ctrl; =20 - trace_nvme_complete_rq(req); nvme_cleanup_cmd(req); =20 /* @@ -493,6 +492,12 @@ void nvme_complete_rq(struct request *req) return; } } + +void nvme_complete_rq(struct request *req) +{ + trace_nvme_complete_rq(req); + __nvme_complete_rq(req); +} EXPORT_SYMBOL_GPL(nvme_complete_rq); =20 void nvme_complete_batch_req(struct request *req) @@ -513,7 +518,7 @@ blk_status_t nvme_host_path_error(struct request *req) { nvme_req(req)->status =3D NVME_SC_HOST_PATH_ERROR; blk_mq_set_request_complete(req); - nvme_complete_rq(req); + __nvme_complete_rq(req); return BLK_STS_OK; } EXPORT_SYMBOL_GPL(nvme_host_path_error); --=20 2.52.0