Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp1176568rwi; Thu, 20 Oct 2022 09:28:14 -0700 (PDT) X-Google-Smtp-Source: AMsMyM64ADKi+7jw+LOqDcFuDecn6GyM0TF5Z9Gn6hK0upAVzHGXu7jqPHjqQpuGwgXsiXHr8BJ4 X-Received: by 2002:a17:907:9815:b0:78e:4b6:1afb with SMTP id ji21-20020a170907981500b0078e04b61afbmr11671258ejc.291.1666283293670; Thu, 20 Oct 2022 09:28:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666283293; cv=none; d=google.com; s=arc-20160816; b=f5UxnW5DiQo7ob7gY52Oq1+3xx91DpZK0w/G/xP/ltmW3bHaYQRNKSC7YhZFevN8/b 5XkU/cT1GwMNOx4Saxmazbko8KA/8YRFdbaD7zO4Q1n2elWjExzWPBm894C0bFy3ST7Y +30yuwjBE83yAxWAkbe/k5auVxb/P/F3G28MScFazN03bOtuC0szCUtAro2OB8yk5A6S 32E2FY2+FPuGrMaOoZUdT7sxA94ZcsmzncUsgWKjaDzD7onsqGKGfjv3E7yeMvxMGh+T YJAXY0arT0Kx74qFkjuQjcF0Z7q/HpLOBe7l1u418tu6KNu8fmVALUDv6qqv9AqQz63T +EYw== 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:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=ni4X3dmGl/X2nX42rl36ixrL7U1+yS2xwlVe+exWxtk=; b=cZTnq8XPqV3cTwUgaOfDkxDw38Kz6XzmeiCLzXRSPIy5K/vD7HhZowquE5jtuyUcPi cfQneRR+iPHpA7pur4dKQryg29ljL3ttgqIibLzE/uBkvIn/tonQvFAjFixzP1tX6mh5 SBIRRu50atycUCq+6CS+U1v9UGHRiDfzu71w7Dm5eHPPjW3U9NvFodrJmqOwMZevyrk4 Or4OAt5nz8CDalz9x13U503nBWlzIRoCB9MHDI+cHWVQ5ELoflvKAY8dSDcuV9kOEWAr 5D483dXUSb5xIJIJYNZvmj/M4Zlz4mJHTWQVDnYnSWCnyfGaf3NX2MzsP0otSEJOGhK1 w59w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=R7R530j0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hr1-20020a1709073f8100b0078d71a6bd56si20273507ejc.757.2022.10.20.09.27.49; Thu, 20 Oct 2022 09:28:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=R7R530j0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229757AbiJTPWV (ORCPT + 99 others); Thu, 20 Oct 2022 11:22:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51044 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229975AbiJTPWK (ORCPT ); Thu, 20 Oct 2022 11:22:10 -0400 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 96C0F537D3; Thu, 20 Oct 2022 08:22:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1666279329; x=1697815329; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=Aczg4Jc/OHYoyF/FrcuRG5QzhTL5LWV6IYaxF3YgRoE=; b=R7R530j0oSaubckB4nFTfgD1fvMX40pEPVuzSrlXU9SRq//Ie7DaSh+P GcSa27wyYQhWSNnJT03MJGdakEdjc1VtZfvFeDvL4JcMMJL70XM2ce4S4 V1l6CzDG3nQLYIBgyzCD9cZqdBdxOI9/fZh9B9whp3a+QKEMOflfL5SuZ Ku5iPm8tbtBT1Dyg6IhLdNN8L2YFhQrsXoVT3C7DAfOt+/Ddz5YNQl7w8 w3AP4s0hb+SbYzwEDIyRuqy+QbH2jqd0XYRHCVg3zV45VFFVOII37mAjE p7i3URCAZgmgTceSc0qbHx8itbc97XevVWUxeTj8PfYSvP+MsxmRcQbMH Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10506"; a="307840395" X-IronPort-AV: E=Sophos;i="5.95,199,1661842800"; d="scan'208";a="307840395" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Oct 2022 08:22:09 -0700 X-IronPort-AV: E=McAfee;i="6500,9779,10506"; a="698724218" X-IronPort-AV: E=Sophos;i="5.95,199,1661842800"; d="scan'208";a="698724218" Received: from amancuso-mobl.amr.corp.intel.com (HELO [10.209.121.211]) ([10.209.121.211]) by fmsmga004-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Oct 2022 08:22:07 -0700 Message-ID: Date: Thu, 20 Oct 2022 08:21:56 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.2 Subject: Re: [PATCH V12 3/4] mm/sparse-vmemmap: Generalise vmemmap_populate_hugepages() Content-Language: en-US To: Huacai Chen , Arnd Bergmann , Huacai Chen , Thomas Bogendoerfer , Dave Hansen , Andy Lutomirski , Peter Zijlstra , Catalin Marinas , Will Deacon , Dinh Nguyen Cc: loongarch@lists.linux.dev, linux-arch@vger.kernel.org, Xuefeng Li , Guo Ren , Xuerui Wang , Jiaxun Yang , Andrew Morton , linux-mm@kvack.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Feiyang Chen References: <20221020072317.492906-1-chenhuacai@loongson.cn> <20221020072317.492906-4-chenhuacai@loongson.cn> From: Dave Hansen In-Reply-To: <20221020072317.492906-4-chenhuacai@loongson.cn> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_NONE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/20/22 00:23, Huacai Chen wrote: > From: Feiyang Chen > > Generalise vmemmap_populate_hugepages() so ARM64 & X86 & LoongArch can > share its implementation. > > Acked-by: Will Deacon > Signed-off-by: Feiyang Chen > Signed-off-by: Huacai Chen > --- > arch/arm64/mm/mmu.c | 55 +++++++----------------- > arch/loongarch/mm/init.c | 59 +++++++------------------- > arch/x86/mm/init_64.c | 92 ++++++++++++++-------------------------- > include/linux/mm.h | 6 +++ > mm/sparse-vmemmap.c | 63 +++++++++++++++++++++++++++ > 5 files changed, 132 insertions(+), 143 deletions(-) Thanks for doing this. It's always nice to see the per-arch duplication get collapsed! Acked-by: Dave Hansen