Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp320354imu; Wed, 2 Jan 2019 21:05:32 -0800 (PST) X-Google-Smtp-Source: ALg8bN7RH2Imal/IUPjIihh5oeCuPr1x66kvFuzTmWZByogSvUTbWUtjoy+MSTHYeAs0pO9+epww X-Received: by 2002:a63:6207:: with SMTP id w7mr15366345pgb.90.1546491931995; Wed, 02 Jan 2019 21:05:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546491931; cv=none; d=google.com; s=arc-20160816; b=OYZzSel1c53FbfOArO9bIS50tLm3R/IaTuiNlFbCbG5hUXgk5xjx/Oy2r00jqV0gQV 6k3apCsu+24E68kWvR0SMfQRcKiZ2sB6Sqv5YZ1yRaY5yL+KwgHWe3u8z++uxgrZLUEr x1lRJt3o1z9hRS3UTKC7jidXOM/nrkGMIqXXpIyA1kVq7gxQ11ACRfE3c8rHsu1K0vxH 36dkRsWjWsVOWF7JuC3HUjFT6gDMBxhq6GC8xKJnz0ZUzxgWa5ydbBQJwdgoA7NAAgVm yEYKPROJvluxPwdPxGhWgk9AaqcNA+6fo1bw3c502oaQoG3cQ08PCgA08gm9fQ9C662I /81w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=5Dq8s8VHxow+zUibY1/aCV3mlwEnNo/G6KAGGdg2Ydg=; b=MbnjEeunHuLIM6g2vT8NH+6zVfDaO6wpDXmyZOyQZWWE1Q4CrvyNEEEPaS8AVO2TAj 30XBlUQ2pX+CQlDmGp39bCzZUspD3e2qYGg69S8lMHq/8b8Pnhw0FvOMCDJG25FscfIt 5n2ejdAoVB2/C2d+tceA6vsU5IfM4hrB3cxted1iofNRkXfPfcLejnsCdmAq7qsTL0rv D56KaNDBlf8o7jlz7b/tfpxjVXZpkVRFsx5+eDy0E77L2twkoKQtyJDpZXL6dKrsVzwo 1YGAco6Dc3tQ0BIt82/Rz+svaU73hkl6kHt9pDWPwmTUL0LHPwJi4k4HL5VhNIUxLvRP NQ1g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z14si32481304pgu.525.2019.01.02.21.05.04; Wed, 02 Jan 2019 21:05:31 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727149AbfACB2r (ORCPT + 99 others); Wed, 2 Jan 2019 20:28:47 -0500 Received: from www262.sakura.ne.jp ([202.181.97.72]:38059 "EHLO www262.sakura.ne.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726049AbfACB2r (ORCPT ); Wed, 2 Jan 2019 20:28:47 -0500 Received: from fsav402.sakura.ne.jp (fsav402.sakura.ne.jp [133.242.250.101]) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTP id x031SjC4040606; Thu, 3 Jan 2019 10:28:45 +0900 (JST) (envelope-from penguin-kernel@I-love.SAKURA.ne.jp) Received: from www262.sakura.ne.jp (202.181.97.72) by fsav402.sakura.ne.jp (F-Secure/fsigk_smtp/530/fsav402.sakura.ne.jp); Thu, 03 Jan 2019 10:28:44 +0900 (JST) X-Virus-Status: clean(F-Secure/fsigk_smtp/530/fsav402.sakura.ne.jp) Received: from [192.168.1.8] (softbank126126163036.bbtec.net [126.126.163.36]) (authenticated bits=0) by www262.sakura.ne.jp (8.15.2/8.15.2) with ESMTPSA id x031Siwb040603 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NO); Thu, 3 Jan 2019 10:28:44 +0900 (JST) (envelope-from penguin-kernel@I-love.SAKURA.ne.jp) Subject: Re: possible deadlock in __wake_up_common_lock To: Qian Cai , Mel Gorman , Vlastimil Babka Cc: syzbot , aarcange@redhat.com, akpm@linux-foundation.org, kirill.shutemov@linux.intel.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux@dominikbrodowski.net, mhocko@suse.com, rientjes@google.com, syzkaller-bugs@googlegroups.com, xieyisheng1@huawei.com, zhongjiang@huawei.com, Peter Zijlstra , Ingo Molnar References: <000000000000f67ca2057e75bec3@google.com> <1194004c-f176-6253-a5fd-682472dccacc@suse.cz> <20190102180611.GE31517@techsingularity.net> <73c41960-e282-e2ec-4edd-788a1f49f06a@lca.pw> From: Tetsuo Handa Message-ID: <530f88a1-3aa1-c36f-f487-7e5e33402fb0@I-love.SAKURA.ne.jp> Date: Thu, 3 Jan 2019 10:28:45 +0900 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0 MIME-Version: 1.0 In-Reply-To: <73c41960-e282-e2ec-4edd-788a1f49f06a@lca.pw> Content-Type: text/plain; charset=iso-8859-15 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2019/01/03 3:19, Qian Cai wrote: > On 1/2/19 1:06 PM, Mel Gorman wrote: > >> While I recognise there is no test case available, how often does this >> trigger in syzbot as it would be nice to have some confirmation any >> patch is really fixing the problem. > > I think I did manage to trigger this every time running a mmap() workload > causing swapping and a low-memory situation [1]. > > [1] > https://github.com/linux-test-project/ltp/blob/master/testcases/kernel/mem/oom/oom01.c wakeup_kswapd() is called because tlb_next_batch() is doing GFP_NOWAIT allocation. But since tlb_next_batch() can tolerate allocation failure, does below change in tlb_next_batch() help? #define GFP_NOWAIT (__GFP_KSWAPD_RECLAIM) - batch = (void *)__get_free_pages(GFP_NOWAIT | __GFP_NOWARN, 0); + batch = (void *)__get_free_pages(__GFP_NOWARN, 0);