Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp401764pxb; Fri, 16 Apr 2021 08:23:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwv3EcgADzh8jY46QQd+c98k/Dmj58OQPP12s75gy8VCt7VkYk24S6gZO0FtSt+VAP3Et4j X-Received: by 2002:a17:90a:c281:: with SMTP id f1mr10063395pjt.58.1618586592418; Fri, 16 Apr 2021 08:23:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618586592; cv=none; d=google.com; s=arc-20160816; b=nLBSXkdu2elABmnTy0hLvIevwJEGn/1z5LJ6u8DZGEXLmSftvQtFJCtoiuo+z2lcAy cHS8/MgXej3tW8oOctFGjdNoo2Q8EvI4cVo0roMpGoNBPHbgf3D1pOm+AtanRfMNcU9I H5rJ5wdcnupKq0wj4WR47BHgirH6XmYNND9DLTNyCzo+DzPlea+YdaGyuV5l+7vKfavI dngMQKXgEVYmTTcuSQETjEVX+21JW7NQwcw5lu5GitzggEfwSeb+Ht+kX4XaeVrajvR4 7ZTY4O7rFPpDnpNJxV7PcHqGDxZHfQDWmxX1SPhOu5Xf/LStf7T843qsLhC25//ZQ+wX C1ug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=vJQzDyPMzRCR3Pj66zSN4Mp2TuH3DXRBeVPYYvWoKrU=; b=k4W900hxGmxICIl9BKRpuO5kVvlmuYdET5swShsjurfI41SO7XnPaoQjdJAsM1RCHh 2fUeR8WjbXbXAVs1bEeXM4gI7Jc5fKf3mYS9xyt3CIosEc9xIjvpGnsMfCV6cQycES8c w1HYbm09dFifXjsKUh9JMYK2/uxy2fFw0k6pUiy5lse1iKG0KoLhFp4kunkwaBi3XSkE ffNUVbDNSjdabhzJT1BJYYGtaTLno73IWaTPPuM82OZRTN+OPw9Fp8u36DAzh2Gxb4cM AmU7Mu1oK3Or0F6hat0mdV+7QSzYi3iZ09ReaLlJsi8wjijyz5ED1pZXBOQYip9o4yuD OF6A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cmpxchg-org.20150623.gappssmtp.com header.s=20150623 header.b=uEKYeSNX; 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=fail (p=NONE sp=NONE dis=NONE) header.from=cmpxchg.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 41si7006385plb.404.2021.04.16.08.22.53; Fri, 16 Apr 2021 08:23:12 -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=@cmpxchg-org.20150623.gappssmtp.com header.s=20150623 header.b=uEKYeSNX; 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=fail (p=NONE sp=NONE dis=NONE) header.from=cmpxchg.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245589AbhDPPWB (ORCPT + 99 others); Fri, 16 Apr 2021 11:22:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55412 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245198AbhDPPVS (ORCPT ); Fri, 16 Apr 2021 11:21:18 -0400 Received: from mail-qk1-x735.google.com (mail-qk1-x735.google.com [IPv6:2607:f8b0:4864:20::735]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 820F4C061760 for ; Fri, 16 Apr 2021 08:20:52 -0700 (PDT) Received: by mail-qk1-x735.google.com with SMTP id h13so10526449qka.2 for ; Fri, 16 Apr 2021 08:20:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cmpxchg-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=vJQzDyPMzRCR3Pj66zSN4Mp2TuH3DXRBeVPYYvWoKrU=; b=uEKYeSNXrs0vvy9Juj5zS5C4UGxfquZmEwu9JoW5KpfTcfCHeCtkFbqIiVnFqv4n1m 6GPV/7cnX9H9daoTZHsDYLZC/9P89NumjGeKNXhrqm+i4ErxteTIZxdXgqIhxYPJw0QX BJOhfLNXfzZjE0lN2V9R6M6uOnyWXieqY2wCh1LNziVouc59fcrDODJbLIiQ62La2+YC FkGGQPSMMjnHIFktdRH+Nhdk16hG28vH1LHYKEcbEtDr0EY/2maOggPIWETx8NKfcrHs iq5bsLelijNu3aUF0D3WYUglqbZRXgkJTszbpCW0QgGfoeipKRTaZ0drVNOatoDOob8a Gojw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=vJQzDyPMzRCR3Pj66zSN4Mp2TuH3DXRBeVPYYvWoKrU=; b=tgwgjB8PXth0L40aklHjipF0g3SIpA/yJA/rlM4DycROsCGiHdAKRwRaP3wuDfWW4h UQ+vmRo3UvDBYZpo1XsHmlmmORBEkWdfkwrct4TAr+3iOvUK8Op6Bh9CoxX+mwTlAM6E zO7sepEEo9oowinY6kMxz1oodCOw0GR5Bj0zqRNmJ0Rk3ayBwUSzlS8yDtr5bO6W8Txd +3Pki5Pb2jNBw7C+JlEtjG6l+6fMTo7Cc4YkvfWdiNlandr+ldWfgCIjvM7KelcRaOSk DkD5Sn1EuowvJlIorYchkJX/alnibOhYIwGkthn2+kpWepFvTv9KmMhUMiTPaUP8avff oOLw== X-Gm-Message-State: AOAM532UZmWC2Y7K+f0mUMD0iigRv+OClFcC88YojQ6/5lVUcSCMBjkq r34CT+K2leyUibd75sIVDhL3Hg== X-Received: by 2002:a05:620a:22a5:: with SMTP id p5mr9275130qkh.480.1618586451806; Fri, 16 Apr 2021 08:20:51 -0700 (PDT) Received: from localhost (70.44.39.90.res-cmts.bus.ptd.net. [70.44.39.90]) by smtp.gmail.com with ESMTPSA id w4sm4393844qkd.94.2021.04.16.08.20.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Apr 2021 08:20:50 -0700 (PDT) Date: Fri, 16 Apr 2021 11:20:49 -0400 From: Johannes Weiner To: Muchun Song Cc: guro@fb.com, mhocko@kernel.org, akpm@linux-foundation.org, shakeelb@google.com, vdavydov.dev@gmail.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, duanxiongchun@bytedance.com Subject: Re: [PATCH v2 5/8] mm: memcontrol: rename lruvec_holds_page_lru_lock to page_matches_lruvec Message-ID: References: <20210416051407.54878-1-songmuchun@bytedance.com> <20210416051407.54878-6-songmuchun@bytedance.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210416051407.54878-6-songmuchun@bytedance.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Apr 16, 2021 at 01:14:04PM +0800, Muchun Song wrote: > lruvec_holds_page_lru_lock() doesn't check anything about locking and is > used to check whether the page belongs to the lruvec. So rename it to > page_matches_lruvec(). > > Signed-off-by: Muchun Song The rename makes sense, since the previous name was defined by a specific use case rather than what it does. That said, it did imply a lock context that makes the test result stable. Without that the function could use a short comment, IMO. How about: /* Test requires a stable page->memcg binding, see page_memcg() */ With that, Acked-by: Johannes Weiner