Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp3145460ybh; Sat, 25 Jul 2020 12:29:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy4gmQEckgdqRwYTKTJXX1FfFZErNAj4QqFrtrehpUPoe7Wbsr+OBDjz7p5iXcg7xw9FqyO X-Received: by 2002:a05:6402:217:: with SMTP id t23mr1628152edv.224.1595705383124; Sat, 25 Jul 2020 12:29:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595705383; cv=none; d=google.com; s=arc-20160816; b=CboD6/d73wGx11Q06g1iwXtZDC10C4v5SrCHYl762MQGwyF1JZ/lVmez16Vg6K94vg riFvp2cAIDObxsDN5p2oj3ZTDqOJEZdASy9HzN5ySucaOYyCczAS8Arjnatd7UCz9CK5 l6OzPPDxq6Kw3SPXagtXyzYRV1avNocTVL4ree7qajEqKYi6VSgo6Daxxq6HPYm7JfQl oJUtij3Ky7i9WiqNnGanvaCdnw/91g60Z5B/wDnwQN+bZScjQrirDdo2WrUmmTT+EySz r9XKhGRISsNK3pVu3j6bqEAEv0ABSjgBAomslCbg/gB9oqnAJ5vxJ/m+tbZN/shD2FNr 9mmQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=E4b8xOE1a+SCo8hP5TdzZ/KYctFwKJKu7PER0hCduYU=; b=iYGFq41sEFCXARmrSSCjlPEd3La2HcM2+CMq3V8vnP2r+6wgLBlZDQ/MU+/6Q+Un8P Pd0c/NIwKGiEONoQ5KHRlPzCNseFnMQExsn1Np+ukvD6MWYAduT2FF9VIPyU+NBEbZ7F iMc0rlSsxP3/CqorOEUyNkPkZ6xBvYSpiWFEoOWVjkzuZRgW6n8SRg4ncUwiHQ2X+RZj OydmGNiVreR1qIn8gTUXvVAMAn4MLrMIpOjS8vWVUz6arV5VBTY5Bes6cqonbjcwvXY1 E/qpYai+UcNvsVOkkBQrrA/3pncnzqgeN5LPJWgzRjZ4H9u4Im22uaF6qNQbwFpxt+N1 KCTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=JpqjVj1N; 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=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u18si143522ejr.600.2020.07.25.12.29.18; Sat, 25 Jul 2020 12:29:43 -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=@redhat.com header.s=mimecast20190719 header.b=JpqjVj1N; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726834AbgGYT2E (ORCPT + 99 others); Sat, 25 Jul 2020 15:28:04 -0400 Received: from us-smtp-delivery-1.mimecast.com ([205.139.110.120]:28250 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726381AbgGYT2E (ORCPT ); Sat, 25 Jul 2020 15:28:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1595705282; 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=E4b8xOE1a+SCo8hP5TdzZ/KYctFwKJKu7PER0hCduYU=; b=JpqjVj1NbLi1j2yZoeqWUY6JUrBbiC9KzZU/dZQcTI/91qXn02X7KowlTlnBY5H5H3Fn7n hbDFCVXb6PeB7f3+SDR3NVPlLpWGQkncCfjx/nL3N9aA4z4qs77SwuUdZZPgO7NJmy+nKb vMkTgEmVaR/dxAV3lEGh3O3rjvItgds= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-340-OtXHO55vMHqSr1UcLHQKag-1; Sat, 25 Jul 2020 15:27:58 -0400 X-MC-Unique: OtXHO55vMHqSr1UcLHQKag-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 2C47C185BDF9; Sat, 25 Jul 2020 19:27:57 +0000 (UTC) Received: from dhcp-27-174.brq.redhat.com (unknown [10.40.192.14]) by smtp.corp.redhat.com (Postfix) with SMTP id 111741C4; Sat, 25 Jul 2020 19:27:54 +0000 (UTC) Received: by dhcp-27-174.brq.redhat.com (nbSMTP-1.00) for uid 1000 oleg@redhat.com; Sat, 25 Jul 2020 21:27:56 +0200 (CEST) Date: Sat, 25 Jul 2020 21:27:53 +0200 From: Oleg Nesterov To: Linus Torvalds Cc: Hugh Dickins , Michal Hocko , Linux-MM , LKML , Andrew Morton , Tim Chen , Michal Hocko Subject: Re: [RFC PATCH] mm: silence soft lockups from unlock_page Message-ID: <20200725192753.GA21962@redhat.com> References: <20200723124749.GA7428@redhat.com> <20200724152424.GC17209@redhat.com> <20200725101445.GB3870@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Firstly, to avoid the confusion, let me repeat I think your patch is fine. I too thought that non-exclusive waiters do not care about the bit state and thus wake_page_function() can simply wake them all up. But then I did "git blame", found your commit 3510ca20ece0150 and came to conclusion there are reasons we should not do this. On 07/25, Linus Torvalds wrote: > > On Sat, Jul 25, 2020 at 3:14 AM Oleg Nesterov wrote: > > > > In essense, this partly reverts your commit 3510ca20ece0150 > > ("Minor page waitqueue cleanups"). I mean this part: > > Well, no. I mean, it keeps the "always add to the fail" behavior. Ah, sorry for confusion, this doesn't matter. I didn't mean "fairness". What I tried to say. AFAICS before that commit we had (almost) the same behaviour you propose now: unlock_page/etc wakes all the non-exclusive waiters up. No? Or I misunderstood your reply? Quite possibly, too late for me... Oleg.