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=-5.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY, USER_AGENT_SANE_1 autolearn=ham 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 277EBC432C0 for ; Wed, 20 Nov 2019 11:49:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0A91C22444 for ; Wed, 20 Nov 2019 11:49:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728745AbfKTLtI (ORCPT ); Wed, 20 Nov 2019 06:49:08 -0500 Received: from out30-42.freemail.mail.aliyun.com ([115.124.30.42]:46325 "EHLO out30-42.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727619AbfKTLtH (ORCPT ); Wed, 20 Nov 2019 06:49:07 -0500 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R141e4;CH=green;DM=||false|;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e07486;MF=alex.shi@linux.alibaba.com;NM=1;PH=DS;RN=37;SR=0;TI=SMTPD_---0Tie.IxI_1574250537; Received: from IT-FVFX43SYHV2H.local(mailfrom:alex.shi@linux.alibaba.com fp:SMTPD_---0Tie.IxI_1574250537) by smtp.aliyun-inc.com(127.0.0.1); Wed, 20 Nov 2019 19:48:58 +0800 Subject: Re: [PATCH v4 9/9] mm/lru: revise the comments of lru_lock To: Johannes Weiner Cc: cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, akpm@linux-foundation.org, mgorman@techsingularity.net, tj@kernel.org, hughd@google.com, khlebnikov@yandex-team.ru, daniel.m.jordan@oracle.com, yang.shi@linux.alibaba.com, willy@infradead.org, shakeelb@google.com, Jason Gunthorpe , Dan Williams , Vlastimil Babka , Ira Weiny , Jesper Dangaard Brouer , Andrey Ryabinin , Jann Horn , Logan Gunthorpe , Souptick Joarder , Ralph Campbell , "Tobin C. Harding" , Michal Hocko , Oscar Salvador , Wei Yang , Arun KS , "Darrick J. Wong" , Amir Goldstein , Dave Chinner , Josef Bacik , "Kirill A. Shutemov" , =?UTF-8?B?SsOpcsO0bWUgR2xpc3Nl?= , Mike Kravetz , Kirill Tkhai , Yafang Shao References: <1574166203-151975-1-git-send-email-alex.shi@linux.alibaba.com> <1574166203-151975-10-git-send-email-alex.shi@linux.alibaba.com> <20191119161958.GE382712@cmpxchg.org> From: Alex Shi Message-ID: Date: Wed, 20 Nov 2019 19:48:57 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:60.0) Gecko/20100101 Thunderbird/60.9.1 MIME-Version: 1.0 In-Reply-To: <20191119161958.GE382712@cmpxchg.org> Content-Type: text/plain; charset=gbk Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ÔÚ 2019/11/20 ÉÏÎç12:19, Johannes Weiner дµÀ: > On Tue, Nov 19, 2019 at 08:23:23PM +0800, Alex Shi wrote: >> Since we changed the pgdat->lru_lock to lruvec->lru_lock, it's time to >> fix the incorrect comments in code. Also fixed some zone->lru_lock comment >> error from ancient time. etc. >> >> Originally-from: Hugh Dickins > > You can resubmit a patch written by somebody else, but you need to > preserve authorship such that git can attribute it properly: > > From: Hugh Dickins > > in the patch header, as well as > > Signed-off-by: Hugh Dickins > > in the changelog tags. It should look something like this: > > --- > From: Hugh Dickins > Subject: [PATCH] mm/memcg: update lru_lock Doc and comments > > Update scattered references from "zone_lru_lock" to "lruvec->lru_lock" > (in low-level descriptions) or "lruvec lock" (where that reads better). > > In the course of doing so, update lock ordering comments in mm/rmap.c > and mm/filemap.c and Documentation/cgroups/memory.txt - slightly, with > no attempt to be complete (swap_lock, in particular, left out-of-date). > Remove allusions to set_page_dirty under page_remove_rmap: gone in v3.9. > > memcg_test.txt looks quite out-of-date: just give LRU a short paragraph. > Replaced zone by node throughout unevictable-lru.txt (except for stats). > Leave Documentation/locking/lockstat.txt untouched this time: it doesn't > matter if that still refers to zone->lru_lock, along with other history. > > I struggled to understand the comment above move_pages_to_lru() (surely > it never calls page_referenced()), and eventually realized that most of > it had got separated from shrink_active_list(): move that comment back. > > Signed-off-by: Hugh Dickins > Signed-off-by: Alex Shi > --- > Thanks for teaching!