From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 279BBCA9EAE for ; Tue, 29 Oct 2019 09:40:44 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id F39DD2087E for ; Tue, 29 Oct 2019 09:40:43 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org F39DD2087E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 9FF8C6B0005; Tue, 29 Oct 2019 05:40:43 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 9AF246B0006; Tue, 29 Oct 2019 05:40:43 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 89F3C6B0007; Tue, 29 Oct 2019 05:40:43 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0169.hostedemail.com [216.40.44.169]) by kanga.kvack.org (Postfix) with ESMTP id 67A4F6B0005 for ; Tue, 29 Oct 2019 05:40:43 -0400 (EDT) Received: from smtpin19.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with SMTP id 06AE9180BD9D5 for ; Tue, 29 Oct 2019 09:40:43 +0000 (UTC) X-FDA: 76096327566.19.tank28_6348d3e7a825 X-HE-Tag: tank28_6348d3e7a825 X-Filterd-Recvd-Size: 1961 Received: from mx1.suse.de (mx2.suse.de [195.135.220.15]) by imf33.hostedemail.com (Postfix) with ESMTP for ; Tue, 29 Oct 2019 09:40:42 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 68445B318; Tue, 29 Oct 2019 09:40:40 +0000 (UTC) Date: Tue, 29 Oct 2019 10:40:39 +0100 From: Michal Hocko To: zhong jiang Cc: akpm@linux-foundation.org, hannes@cmpxchg.org, ktkhai@virtuozzo.com, linux-mm@kvack.org, Minchan Kim Subject: Re: [PATCH] mm: fix unevictable page reclaim when calling madvise_pageout Message-ID: <20191029094039.GH31513@dhcp22.suse.cz> References: <1572275317-63910-1-git-send-email-zhongjiang@huawei.com> <20191029081102.GB31513@dhcp22.suse.cz> <5DB806D1.8020503@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5DB806D1.8020503@huawei.com> User-Agent: Mutt/1.10.1 (2018-07-13) X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue 29-10-19 17:30:57, zhong jiang wrote: > On 2019/10/29 16:11, Michal Hocko wrote: > > [Cc Minchan] [...] > > Removing a long existing BUG_ON begs for a much better explanation. > > shrink_page_list is not a trivial piece of code but I _suspect_ that > > removing it should be ok for mapped pages at least (try_to_unmap) but I > > am not so sure how unmapped unevictable pages are handled from top of my > > head. > As to the unmapped unevictable pages. shrink_page_list has taken that into account. > > shinkr_page_list > page_evictable --> will filter the unevictable pages to putback its lru. Ohh, it is right there at the top. Missed it. The check has been added by Nick along with the BUG_ON. So it is sounds more like a "this shouldn't happen" bugon. I wouldn't mind to remove it with that justification. -- Michal Hocko SUSE Labs