Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp5551927pxb; Tue, 16 Feb 2021 01:08:43 -0800 (PST) X-Google-Smtp-Source: ABdhPJwvr1PpFdcniMpYvUSm7JbEiaGpV2oO+tg4pa0f9PGORk4ZZTzdIi+HQ8W0TJLQtinn+kex X-Received: by 2002:a17:906:7e42:: with SMTP id z2mr19484089ejr.177.1613466523044; Tue, 16 Feb 2021 01:08:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613466523; cv=none; d=google.com; s=arc-20160816; b=tsoyxHKGIMoCoKF1k2UfzIS8MErUQs1SbfNt+lGpSIbKy0s8GD96fiz/KmqxtqrXBH yAf2CgWvK9/25hrQNL7xq+727mI0N90x2PFSpD3m4F4TSDUU9zSoXWj0+gOrqer0HomL 7vwn9sXkRxVwfo/zKcd/RtyFtmK22iSISaIX7yXqLrnmh6NqkO+OXYgKoDJTZjhoLlXw +h2RaVgPJ6XoaPao7E/bHcAR8zJ3AluBLDb19uKt4SLrlRwIdfZECUeMoEkmx8Wh6/Ug 1Q/PvbyYRrhy7GS9/CKElUavfq2Qwzuue8Eyp55xUsBU3bPJ2Xi8lrjcGylai4XMqWJx PCPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:dkim-signature :dkim-signature:date; bh=pXA7fe5dhXsardy0H04SmPnjEF++cQlTzGur8gI2QwM=; b=My2FIss90pr4mtAeOYt1lYQ4HgYUwgl31wIQ4/CoYJ7g+D+Olhr/n/8WA7xUCQipjh NluN1IpYtqbkI2/15aYyZXW4pMdHoKIb/ZKi5WRzWD58xDC5/Ih1ZeWOVnd08EWRwTmk a3DRwZmdZ6AtNwFBIyNHKgIIqQKFwZs1bZLPG1fz2MKGcVEsgSdkcsmOfqpCoi73Xbc+ vsqSM+4SBG2XINk2NuSC6/iwZHJ8cFwpubUKqzZuFGX1YggbtifV7Lohxbrazh3SBvLV XDrs0qbJWUXUHw7AxBPkcgz5/n5XQX4G9ijjagQYiLAhNl8jHCMEpPiGlu7eh4tVDFoR Wmtg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=uXu4DrRf; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p24si3617381edm.277.2021.02.16.01.08.12; Tue, 16 Feb 2021 01:08:43 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs-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=@linutronix.de header.s=2020 header.b=uXu4DrRf; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230001AbhBPJHY (ORCPT + 99 others); Tue, 16 Feb 2021 04:07:24 -0500 Received: from Galois.linutronix.de ([193.142.43.55]:37810 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229784AbhBPJHK (ORCPT ); Tue, 16 Feb 2021 04:07:10 -0500 Date: Tue, 16 Feb 2021 10:06:26 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1613466388; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=pXA7fe5dhXsardy0H04SmPnjEF++cQlTzGur8gI2QwM=; b=uXu4DrRfVfYd+SEG3ThhnB52KojptJp1umEHZg0FmpjEQep/Ku3kzNsXtNtm4y2OvGQYCz OLs6q1Olm4WMjW8Ea8Taei49T0k0cKzTOrGtC+oWXJ9GC9xRA/7JtEnNpLZULW8V29OnOk wHRKW12eXeYum2jTj0jCN9oFFhwRzyFoROpBA1D2OM7d+/uei0+SwOk2ugACt13vA4WPVh S7Uwi+v7smyObt0GWYz9jP+YanQo0+/A5vhfmAt0DTRoaPu4Rv3MoJeSkZdCkGLgqFco24 FlES+01Vf/SwNmUk4/j8HuJUCPA0ndLoqPKs4DCDgxP8GNsXW2EkLnFvJ1PJJw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1613466388; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=pXA7fe5dhXsardy0H04SmPnjEF++cQlTzGur8gI2QwM=; b=Ex3kELqMANnnWJzXjLUZrdgvFr6FqspWhFNNwj6u53hxH3IdxEGU5swcYLIBWpwsv6M7s8 aY5ia4rpeMb3TYAQ== From: Sebastian Andrzej Siewior To: Christoph Hellwig Cc: David Howells , Trond Myklebust , Marc Dionne , Anna Schumaker , Steve French , Dominique Martinet , linux-cifs@vger.kernel.org, ceph-devel@vger.kernel.org, Jeff Layton , Matthew Wilcox , linux-cachefs@redhat.com, Alexander Viro , linux-mm@kvack.org, linux-afs@lists.infradead.org, v9fs-developer@lists.sourceforge.net, linux-fsdevel@vger.kernel.org, linux-nfs@vger.kernel.org, Jeff Layton , David Wysochanski , linux-kernel@vger.kernel.org Subject: Re: [PATCH 34/33] netfs: Use in_interrupt() not in_softirq() Message-ID: <20210216090626.kqnk726i6f77libt@linutronix.de> References: <161340385320.1303470.2392622971006879777.stgit@warthog.procyon.org.uk> <1376938.1613429183@warthog.procyon.org.uk> <20210216084230.GA23669@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20210216084230.GA23669@lst.de> Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On 2021-02-16 09:42:30 [+0100], Christoph Hellwig wrote: > On Mon, Feb 15, 2021 at 10:46:23PM +0000, David Howells wrote: > > The in_softirq() in netfs_rreq_terminated() works fine for the cache being > > on a normal disk, as the completion handlers may get called in softirq > > context, but for an NVMe drive, the completion handler may get called in > > IRQ context. > > > > Fix to use in_interrupt() instead of in_softirq() throughout the read > > helpers, particularly when deciding whether to punt code that might sleep > > off to a worker thread. > > We must not use either check, as they all are unreliable especially > for PREEMPT-RT. Yes, please. I try to cleanup the users one by one https://lore.kernel.org/r/20200914204209.256266093@linutronix.de/ https://lore.kernel.org/amd-gfx/20210209124439.408140-1-bigeasy@linutronix.de/ Sebastian