From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1748F2DC32C for ; Mon, 13 Jul 2026 07:29:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=195.135.223.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783927789; cv=none; b=SSeRm8Sshl1SCu+wbjBdPtqH9jAHmELk9ew2okT0PJvMSwfq1On31QrG44qs056ZIzAlCGuIVPha50wGcM0C6gp9fToMPS6VQN1oq/Vo2pA97dnx13LCeKqj5S5SNtKJyiZgsxc5WLxlCwMuckKnF6b5fFd5+UQNQcBtn6Nog9w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783927789; c=relaxed/simple; bh=g3NqeSDCcM6gHbWOWqTnSM509URwHvZEheS2B/oZo9Q=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=jbLbuMvWqMRllBMer/42J8Kt/6XmNdsMoMX+FuC+iUxPDdjWVlAA96rX+4Nmx6BKLrbB/QpTlg78Bzt6ul/0I/ueQoZTU/VQ/2Utgmv494nCN/qVAe5qUi8Lc18JYT8bNxgbwyi+GTRQzMobn/zCO5cH2zYA2clzTEBHWzTcgEM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=suse.de; spf=pass smtp.mailfrom=suse.de; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b=K7eyYUxU; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b=SqRP+t5r; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b=QE7SM4Lw; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b=nPkQ6BA4; arc=none smtp.client-ip=195.135.223.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b="K7eyYUxU"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="SqRP+t5r"; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b="QE7SM4Lw"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="nPkQ6BA4" Received: from imap1.dmz-prg2.suse.org (unknown [10.150.64.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id E820077428; Mon, 13 Jul 2026 07:29:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1783927786; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=W7Xzew5rWDRlRGMpqB8Bq8Wd/JLPFE7C8SCawJlQk7U=; b=K7eyYUxUknkBwQC0L08GWrDp7lYnWJB1Q54UO6p2995QW8Uvo7rGSk09NrC8+XAM3lKELs gedGfUoShiRPwV9QoVpLhPxZYzswqdCQGGMdeaTQWlwFaPl5qc0kgNE/HP774QKgGHX1Ex 8IYGI0H2lr2MBWCN2dHVopxLmC1bcGc= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1783927786; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=W7Xzew5rWDRlRGMpqB8Bq8Wd/JLPFE7C8SCawJlQk7U=; b=SqRP+t5rvWpfn7clFb8/rfp709hx+RxwmopTuWPNnWKB/1/MoMGVrJ3MUWU7T9KdBoL5zP xHCOJjfvVCU4fABg== Authentication-Results: smtp-out2.suse.de; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1783927784; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=W7Xzew5rWDRlRGMpqB8Bq8Wd/JLPFE7C8SCawJlQk7U=; b=QE7SM4Lw0+2I0n9NigIFw1hYHCUR0h9cU+hpJbcRE7J5sI1/A7jQ41cQUGrJ/uxPNXlHMq zrAc3GWPERIqUXRDpoh7HzNMIvPtSzHMPZstWtHaNBNcoJ9ljrAa699lT8sEtjQuDz3wUy M93b7NWffr71/xq3gk3K1JZu/XCIKrc= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1783927784; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=W7Xzew5rWDRlRGMpqB8Bq8Wd/JLPFE7C8SCawJlQk7U=; b=nPkQ6BA4aoXU9cI4cB7hXjUsxSk9Z7ylvymj2pn8DMuCZ1K+OGiQPKibEi/ve95AspS65D cFFn5Rzg9mCrjZCQ== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 8F793779AE; Mon, 13 Jul 2026 07:29:44 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id ly7WIeiTVGpwaQAAD6G6ig (envelope-from ); Mon, 13 Jul 2026 07:29:44 +0000 Message-ID: Date: Mon, 13 Jul 2026 09:29:44 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v5 12/16] nvme-fc: Refactor IO error recovery To: Mohamed Khalfella , Justin Tee , Naresh Gottumukkala , Paul Ely , Chaitanya Kulkarni , Christoph Hellwig , Jens Axboe , Keith Busch , Sagi Grimberg , James Smart , Randy Jennings , Dhaval Giani Cc: Aaron Dailey , linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org References: <20260712022437.3743117-1-mkhalfella@purestorage.com> <20260712022437.3743117-13-mkhalfella@purestorage.com> Content-Language: en-US From: Hannes Reinecke In-Reply-To: <20260712022437.3743117-13-mkhalfella@purestorage.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Flag: NO X-Spamd-Result: default: False [-4.30 / 50.00]; BAYES_HAM(-3.00)[100.00%]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MIME_GOOD(-0.10)[text/plain]; ARC_NA(0.00)[]; FUZZY_RATELIMITED(0.00)[rspamd.com]; MIME_TRACE(0.00)[0:+]; RCPT_COUNT_TWELVE(0.00)[15]; FREEMAIL_TO(0.00)[purestorage.com,broadcom.com,gmail.com,nvidia.com,lst.de,kernel.dk,kernel.org,grimberg.me]; RCVD_VIA_SMTP_AUTH(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FREEMAIL_ENVRCPT(0.00)[gmail.com]; DKIM_SIGNED(0.00)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; FROM_EQ_ENVFROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; RCVD_TLS_ALL(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.de:email,suse.de:mid,purestorage.com:email,imap1.dmz-prg2.suse.org:helo] X-Spam-Level: X-Spam-Score: -4.30 On 7/12/26 4:23 AM, Mohamed Khalfella wrote: > Added new nvme_fc_start_ioerr_recovery() to trigger error recovery > instead of directly queueing ctrl->ioerr_work. nvme_fc_error_recovery() > now called only from ctrl->ioerr_work has been updated to not depend on > nvme_reset_ctrl() to handle error recovery. nvme_fc_error_recovery() > effectively resets the controller and attempts reconnection if needed. > This makes nvme-fc ioerr handling similar to other fabric transports. > > Update nvme_fc_timeout() to not abort timed out IOs. IOs aborted from > nvme_fc_timeout() are not accounted for in ctrl->iocnt and this causes > nvme_fc_delete_association() not to wait for them. Instead of aborting > IOs nvme_fc_timeout() calls nvme_fc_start_ioerr_recovery() to start IO > error recovery. Since error recovery runs in ctrl->ioerr_work this > change fixes the issue reported in the link below. > > Link: https://lore.kernel.org/all/20250529214928.2112990-1-mkhalfella@purestorage.com/ > Signed-off-by: Mohamed Khalfella > --- > drivers/nvme/host/fc.c | 119 +++++++++++++++++++++++------------------ > 1 file changed, 66 insertions(+), 53 deletions(-) > This is hard to read. Please split it several parst, one with open-coding nvme_reset_work(), one with adding nvme_fc_start_ioerr_recovery((), and another one with the rest. If that makes sense to you... Cheers, Hannes -- Dr. Hannes Reinecke Kernel Storage Architect hare@suse.de +49 911 74053 688 SUSE Software Solutions GmbH, Frankenstr. 146, 90461 Nürnberg HRB 36809 (AG Nürnberg), GF: I. Totev, A. McDonald, W. Knoblich