Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp1609905pxb; Fri, 22 Oct 2021 04:28:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw0Ah+1VXDDs29wmqK9lkhmYjbnyF/mKwUUzurrU2rmJTBQr47ssr3zDgFcmYNUrqR5So9M X-Received: by 2002:a17:90a:5515:: with SMTP id b21mr13839978pji.239.1634902126636; Fri, 22 Oct 2021 04:28:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634902126; cv=none; d=google.com; s=arc-20160816; b=HyMiwmnI8RSlPMzXHNcMxAGrzk9M91/MyJbkLpbpljP/eHchJD4aw/FvIFQZGRaTtj gh6xAV8jiKMgdinuMPE6/5kc+TLZzBvUHa0VVia8HLZpl40tzg6cJjFffcIajo90f5Ep uSFuzUaWr+2ytS1aTGnuKL0TsJwDc3wHb3g9ycSpeBnoGc0WSzrKgDeRTMwoOxmi2VIs yy0W3vOGW+vp6rS4rZBsdD4ZepLuD9OBmlDV6dci3byM+Hfdubfd1WknVkqvMfGd458a SS9KBTaSpgV6zqBxYzDIemx4sXPPNrMaoQO+Lkldu1xXRV66JRacbKgU9Da1VqEYSnnf ZfWw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:references:in-reply-to:subject :cc:to:from:mime-version:content-transfer-encoding:dkim-signature :dkim-signature; bh=G+CT6BgCtYpvdAl4MhY2kM2fLPV09SlNX2gZkJNaBZo=; b=OxfNDRxsGuEEcRyZWooygV6Sv9cgagFMh0MoEbMKbqhhhKES6ZU2eeZJ/mM1sALHcP efxNWCLtW4NpC4bHYP/PnpQm2IelHw9ap9yMh0VMydk21P4MP2j2D9LUxgCpYeJ1Lo2O i9mkKGh1iDQbQOAvUanT9Kp0zqqPIPSAwtjDSzlikJQr9d9OS+lz2UF80+vlSgoEf3zv e5xfko+K09qjOoMWLNJdADln6nMgNKkbctcT6GwZBbez8mXr76aTYz447JrkK9OyNysf vl9sB+MNBybtoAjphplLjhAS3dnaVzrJvCK0JlyCiz2wjAoux3n7QRIWReP42755W0BB QE+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=DmdRpB0n; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-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 ls9si18204908pjb.73.2021.10.22.04.28.25; Fri, 22 Oct 2021 04:28:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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=DmdRpB0n; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-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 S232745AbhJVL3A (ORCPT + 99 others); Fri, 22 Oct 2021 07:29:00 -0400 Received: from smtp-out2.suse.de ([195.135.220.29]:33716 "EHLO smtp-out2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232741AbhJVL26 (ORCPT ); Fri, 22 Oct 2021 07:28:58 -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 CE4481FD58; Fri, 22 Oct 2021 11:26:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1634901999; 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=G+CT6BgCtYpvdAl4MhY2kM2fLPV09SlNX2gZkJNaBZo=; b=DmdRpB0nz/eEkPbaRbG5oT04ItfX62+OAxSQO3vWI+pOdkBg8ek78HvN7hTZwHiZmd6hYU ZG3SCvUAk20HFuSn5Dr5gKZ3zbkw6/AXc1vGYMYgnnkz0WkD+T4o7qzvXNHwRJD8UN3dYK 3fFYIBkfAtqPoMqVMpzdBsCp7fcWfrs= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1634901999; 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=G+CT6BgCtYpvdAl4MhY2kM2fLPV09SlNX2gZkJNaBZo=; b=j7JodYggPkHHKNiWjC6WC+fc7I4Vca5MEAR7EZMkb/nSTIY9J28Lv4ZDsmbb/vE6GGh22S BhWLFwOhBNrySdDQ== 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 8228F13CD4; Fri, 22 Oct 2021 11:26:34 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id EaZRDOqfcmHKIQAAMHmgww (envelope-from ); Fri, 22 Oct 2021 11:26:34 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 From: "NeilBrown" To: "Mel Gorman" Cc: "Andrew Morton" , "Theodore Ts'o" , "Andreas Dilger" , "Darrick J . Wong" , "Matthew Wilcox" , "Michal Hocko" , "Dave Chinner" , "Rik van Riel" , "Vlastimil Babka" , "Johannes Weiner" , "Jonathan Corbet" , "Linux-MM" , "Linux-fsdevel" , "LKML" Subject: Re: [PATCH v4 0/8] Remove dependency on congestion_wait in mm/ In-reply-to: <20211022083927.GI3959@techsingularity.net> References: <20211019090108.25501-1-mgorman@techsingularity.net>, <163486531001.17149.13533181049212473096@noble.neil.brown.name>, <20211022083927.GI3959@techsingularity.net> Date: Fri, 22 Oct 2021 22:26:30 +1100 Message-id: <163490199006.17149.17259708448207042563@noble.neil.brown.name> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 22 Oct 2021, Mel Gorman wrote: > On Fri, Oct 22, 2021 at 12:15:10PM +1100, NeilBrown wrote: > > > In general, I still don't like the use of wake_up_all(), though it won't > > cause incorrect behaviour. > > > > Removing wake_up_all would be tricky. I think there is a misunderstanding. Removing wake_up_all() is as simple as s/wake_up_all/wake_up/ If you used prepare_to_wait_exclusive(), then wake_up() would only wake one waiter, while wake_up_all() would wake all of them. As you use prepare_to_wait(), wake_up() will wake all waiters - as will wake_up_all(). When I see "wake_up_all()" I assume it is an exclusive wait, and that for some reason this particular wake_up needs to wake up all waiters. That is not the case here. I suspect it would be clearer if "wake_up" always woke everything, and "wake_up_one" was the special case - but unfortunately that isn't what we have. There are other non-exclusive waiters which use wake_up_all(), but the vast majority of wakeups use wake_up(), and most of those are for non-exclusive waiters. Thanks, NeilBrown