Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3561353pxv; Mon, 19 Jul 2021 03:21:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwmg7xfem0NWqXPkZoizdPv0CrJ3RhxrnV1UNR4079j8mwdP3RXoGCmFsWdMjxiWv8fzkur X-Received: by 2002:a17:906:17c5:: with SMTP id u5mr26778469eje.326.1626690112332; Mon, 19 Jul 2021 03:21:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626690112; cv=none; d=google.com; s=arc-20160816; b=sOD9eaXiRtZgt1s5BGOpvyMNn0ByULpR3MJq2wtRt7vRL+4AxshC8Hv5+BmXJFPEwE KQbMwee1F6xt5tNr5UuNT3SfzCvoVm/pIRB5XU2T5QRXsbwQyD/T5jSdkSvwaLwPkKPX NSSK+mVBVSB0g9h/s3wg8A3qkrCT1xeMs1kYScbaIB7428CFHWFoXMJCMuV9cR8hlkwn etCQGjeo9kQYs+0P9lj0L9YSJbS1noOtdEjgEdDwZRXzm7YRmpzPP0k5v24+LSj7QzFI JM0/nTC9QOTFzK400ZxtOUNlAY8BunHnqBGtdjgrFZLayyZxUl5VtiOnBRh6I6O25y1q NwXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject:dkim-signature; bh=8+plMzy1GpXf0vMW4A7COLA30NEdDVp1gfiCAEBYGEg=; b=QPKbX6/VruyffOtAAA2v3ZXFVOfXgpGkBsc55AWWsJgxCb8ScPv33P9wI8NYcIg8Pu 1G8US6qVDrI4PpOPHhxbALD5YhCVCdSeujov43tx4ujlFCYPOXsWhBNDHBxATkU+Ehao m4mhVmE3rNwMURY4artPb9cQoseWEijdm3+fEYUFOJrzFvSsBGHgR1R+D6T6CCmGCqDf qbTY9o7ByVh+0xt9SeW72exN5jCuKvLvHfXNavZAFVBZvfgmxgjsJqzk1KrBb2UFFp3k cYiEcc7k1S+f/3u8dOVg4prmcp6EdaSQWE61I9afWWKfjkFD7Nrh09SraF3urRGWXKX3 uYcA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bytedance-com.20150623.gappssmtp.com header.s=20150623 header.b=ypqOgi5A; 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=bytedance.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x4si4527303edd.511.2021.07.19.03.21.29; Mon, 19 Jul 2021 03:21:52 -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=@bytedance-com.20150623.gappssmtp.com header.s=20150623 header.b=ypqOgi5A; 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=bytedance.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235416AbhGSJjp (ORCPT + 99 others); Mon, 19 Jul 2021 05:39:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47614 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235172AbhGSJjo (ORCPT ); Mon, 19 Jul 2021 05:39:44 -0400 Received: from mail-pg1-x531.google.com (mail-pg1-x531.google.com [IPv6:2607:f8b0:4864:20::531]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2BB02C061574 for ; Mon, 19 Jul 2021 02:26:02 -0700 (PDT) Received: by mail-pg1-x531.google.com with SMTP id o4so13886154pgs.6 for ; Mon, 19 Jul 2021 03:20:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance-com.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=8+plMzy1GpXf0vMW4A7COLA30NEdDVp1gfiCAEBYGEg=; b=ypqOgi5AFe9zex8bFiyIfAQA1juQ/lpgmpNaKCGT6um56q7CuxpGbFYc0hwwnznKpR EPtQ3YK/c4y5Sp4XX0fxx7BhrgyLZEaQzRyPo3uxAkwoLCefWPS0lq8QAC3viEJR9Cca ZOtaaisRiRp+Aa42k8ml1on/j0tSccOV/eiskpDf2SZSRIw1DcKNjdKMXNx4Yw4Ig6q4 hmnfLwLG8GNVdzodKph+xvp1hTqAB4sFdnnSRcB00m3jrHxkhggLoqraXbJtXt6iUKNZ cMftqKQdDpYAZSrVJdGZOde8sCfY7U8nZevXTgjpu9s4XcnkMcWzGBVUS5qzvXN2Zdzc NAtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=8+plMzy1GpXf0vMW4A7COLA30NEdDVp1gfiCAEBYGEg=; b=Nne4j6S2QPuYctrC2GeYQs8m18bLQlgBtaYcj2UMUq0A3+j9PLWitfeOnyUykgl+sn Qz/GpFitJZmRo0H3Qf6Tr3Wn+i8lZt1bniz2M6QyhiXNfX4vaIzf4zJNyAGu1+TxQrca Ijh4N5CgFhfGDUy776g+x8GJZpB7/14DOCHNQnVzHVRoGgof70ycsTMQjPG8OpsBUzWG 4bEw01HSeiJjRdVkw/tpukbd+0BDE0i36ivLeR+F/9wfPC5gUtFN7M4otqCpslqOg51t wxEGTU2swzfQ/HiiuGvI36TTXpB/ly6xakCv8bE/TYcEVb4vrRmSUT6GSPyZOTFcK3/1 79fQ== X-Gm-Message-State: AOAM531SoooO0NtzUkcygFc/qv3MM76pi8yqSKkd7iYfGP5mT084u7Vx 88pPFZT3s8/GAc/uYMfOEm1I+A== X-Received: by 2002:a63:514c:: with SMTP id r12mr25117618pgl.70.1626690024128; Mon, 19 Jul 2021 03:20:24 -0700 (PDT) Received: from [10.200.196.235] ([139.177.225.251]) by smtp.gmail.com with ESMTPSA id q125sm12669828pga.87.2021.07.19.03.20.20 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 19 Jul 2021 03:20:23 -0700 (PDT) Subject: Re: [PATCH 2/7] mm: introduce pte_install() helper To: "Kirill A. Shutemov" Cc: akpm@linux-foundation.org, tglx@linutronix.de, hannes@cmpxchg.org, mhocko@kernel.org, vdavydov.dev@gmail.com, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, songmuchun@bytedance.com References: <20210718043034.76431-1-zhengqi.arch@bytedance.com> <20210718043034.76431-3-zhengqi.arch@bytedance.com> <20210718213120.rtqbgseb6drcwxj4@box.shutemov.name> From: Qi Zheng Message-ID: <46573169-3c97-7024-bc04-ba1fb7a548f6@bytedance.com> Date: Mon, 19 Jul 2021 18:20:17 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: <20210718213120.rtqbgseb6drcwxj4@box.shutemov.name> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/19/21 5:31 AM, Kirill A. Shutemov wrote: > On Sun, Jul 18, 2021 at 12:30:28PM +0800, Qi Zheng wrote: >> Currently we have three times the same few lines repeated in the >> code. Deduplicate them by newly introduced pte_install() helper. >> >> Signed-off-by: Qi Zheng > > I don't like the name of the helper: we have confusion of PTE being > PTE-entry or PTE page table. And pte_install() doing pmd_populate() > doesn't help the situation. > > Maybe pmd_install()? Or pte_table_install()? I donno. > Look good to me, I will use pmd_install().