Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp2210329pxb; Fri, 17 Sep 2021 05:00:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzabuY8ESwilUcItYZO4Fm8YCeMOaRnmubVorS+fVer7OqNBeazBFiIoGZPYs0f21SNxvDc X-Received: by 2002:a92:d90b:: with SMTP id s11mr7330974iln.206.1631880012940; Fri, 17 Sep 2021 05:00:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631880012; cv=none; d=google.com; s=arc-20160816; b=AIVzw0ccu6nM0DorIbZjcSWwfHD9jBVcdP+rMfdSTz8D4vflmAPtZeorYEIeh0wJDg IOy6ZZOfIfmsUDaTITeaef2KtnKZZRvTeGKYw7VUVB/DsGsxoqEhmRtjqNsT8Nv0p0J0 g+/dQmJHifLGgTPVhYmlm8vj/KMsYBq34KtyyJ+pzJNKX0NbELdZbxEI1cIXVCpYHh3+ oXZcMqrd2d256RE/Qdc8FFMHYM5djcd1XbcKWGRmbCht2rgG8MYDHexoJ8vACKhLzUL0 9V8LCCPN93MlnXL4rWyA4tFOD8RcY9rpG5r9TUMXye7Jhso9rHZL28ka1sGsbtLrpcnG H0LQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:message-id:date:cc:to:from:subject:dkim-signature :dkim-signature; bh=8pvkjCFdBH92niZgGsbVOrH9zONIePhOsL1BwdfqgnA=; b=bdlWQ6IfBiuArH0jk2MhqciE5g+k2bjB6kxm1C2mUX60VVo41Pm59NDM3a03tRqOEQ EOQqnDlbHfxVLW+mqPkRBtQhjNQc3DMsPaXydcMvGf2o8kNdLB/VTX0OQZAWiYhhxIuc Xx7yji6DXirPhGk7+Zx9dBfUVNiRmwvHZKKbdCmvPAbF6GI/+BmbS9VqZ5IpKvgP9nUV lTOwqcUbnXo9xB+/r2CFbeW0TrEvzY3jp70Sp1S261vFJusXAtUZRgYoDUlJ4v9FX1PD 9YSDAfMZlcDsLfiOAieZBB9rc13nI+JykedGrp0qmVNEpqWOaIVKhUzlOsuXzZwEqTWn ATEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=NrP8J0vh; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=PMuREhLf; 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=NONE dis=NONE) header.from=suse.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o12si5366977iow.40.2021.09.17.04.59.50; Fri, 17 Sep 2021 05:00:12 -0700 (PDT) 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=@suse.de header.s=susede2_rsa header.b=NrP8J0vh; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=PMuREhLf; 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=NONE dis=NONE) header.from=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243179AbhIQDAp (ORCPT + 99 others); Thu, 16 Sep 2021 23:00:45 -0400 Received: from smtp-out2.suse.de ([195.135.220.29]:41356 "EHLO smtp-out2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243049AbhIQDAp (ORCPT ); Thu, 16 Sep 2021 23:00:45 -0400 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 09F2B2007B; Fri, 17 Sep 2021 02:59:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1631847562; 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; bh=8pvkjCFdBH92niZgGsbVOrH9zONIePhOsL1BwdfqgnA=; b=NrP8J0vhVKv0eLroW/bpzL2ejtwWpy1oEAi7DdQ4kMU5Kv8Oq6l5iLYPu7H9EkxbF1q4/A na+xtpPAcJUY68yb7FlQ9lmxSLRRQKANIKbvzZj9RSTof31Djq1vJviErXSODqyW0wqB4e LQe1sAc/mk1g9ojaRCFZduOcyNryYAc= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1631847562; 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; bh=8pvkjCFdBH92niZgGsbVOrH9zONIePhOsL1BwdfqgnA=; b=PMuREhLfwiF/t1B800k94ChByfic8xUfzyWra9ANkKBEq5p7ic9AJetd/jrDccwucIyfGK Kco4+Zd25/JWTsBA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 9733913D0B; Fri, 17 Sep 2021 02:59:17 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id wyQIFYUERGFLMwAAMHmgww (envelope-from ); Fri, 17 Sep 2021 02:59:17 +0000 Subject: [PATCH 0/6 v2] congestion_wait() and GFP_NOFAIL From: NeilBrown To: Andrew Morton , Theodore Ts'o , Andreas Dilger , "Darrick J. Wong" , Matthew Wilcox , Mel Gorman , Michal Hocko , ". Dave Chinner" , Jonathan Corbet Cc: linux-xfs@vger.kernel.org, linux-ext4@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-nfs@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org Date: Fri, 17 Sep 2021 12:56:57 +1000 Message-ID: <163184698512.29351.4735492251524335974.stgit@noble.brown> User-Agent: StGit/0.23 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org This second version: - add recipients for the Documentation/core-api changes - add fix for __alloc_pages_bulk() to handle GFP_NOFAIL - drops the annotations for congestion_wait() as being ineffective as that isn't really useful until an alternative is available - changes to GFP_NOFAIL documentation changes to focus on the possible deadlocks rather than the use of memory reserves - Improves ext4 and xfs patches based on feedback from Ted and Dave. The patches are independent, except that the last patch depends on the first. As mentioned last time: These are the easy bits. There are 5 calls to congestion_wait() and one to wait_iff_congested() in mm/ which need consideration. There are multiple calls to congestion_wait in fs/, particularly fs/f2fs/ which need to be addressed too. I'll try to form an opinion about these in coming weeks. (other interesting comment in original cover letter just duplicates observations made in the commit messages of individual patches). NeilBrown --- NeilBrown (6): MM: Support __GFP_NOFAIL in alloc_pages_bulk_*() and improve doco MM: improve documentation for __GFP_NOFAIL EXT4: Remove ENOMEM/congestion_wait() loops. EXT4: remove congestion_wait from ext4_bio_write_page, and simplify XFS: remove congestion_wait() loop from kmem_alloc() XFS: remove congestion_wait() loop from xfs_buf_alloc_pages() Documentation/core-api/memory-allocation.rst | 25 ++++++++- fs/ext4/ext4.h | 2 +- fs/ext4/ext4_jbd2.c | 4 +- fs/ext4/ext4_jbd2.h | 14 +++--- fs/ext4/extents.c | 53 ++++++++------------ fs/ext4/extents_status.c | 35 +++++++------ fs/ext4/extents_status.h | 2 +- fs/ext4/ialloc.c | 3 +- fs/ext4/indirect.c | 2 +- fs/ext4/inode.c | 6 +-- fs/ext4/ioctl.c | 4 +- fs/ext4/page-io.c | 13 ++--- fs/ext4/super.c | 2 +- fs/jbd2/transaction.c | 8 +-- fs/xfs/kmem.c | 19 +++---- fs/xfs/xfs_buf.c | 14 +++--- include/linux/gfp.h | 6 ++- 17 files changed, 113 insertions(+), 99 deletions(-) -- Signature