Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1036166iob; Fri, 13 May 2022 20:32:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJylebj1Gh43b1GXKHJIItV7LKLd4U8bSYalgnV/EHOyq4VMbIRD8h1QklCUGGQ20wE3wq2a X-Received: by 2002:adf:f14a:0:b0:20a:d7bd:a5d4 with SMTP id y10-20020adff14a000000b0020ad7bda5d4mr6108343wro.390.1652499124957; Fri, 13 May 2022 20:32:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652499124; cv=none; d=google.com; s=arc-20160816; b=VAVMag8mr3DTnyH8eZ1CwhrhEgHvWyC3FJyPJunkUK08HOVh9BOz5GlZExSYXx1AUB 64U1bOk3l9gDoTE9b62EUhp6Z6mPD4R4U2nlU4cTu46j0ENQeHDOUct0GjLV9qHYMFSB J4jsdHVhfm/RxEM52MdtmanGM+gqtzNRmjtzVcckdt3w1JHiH7gM+mBy2zxPdQhQAw1N ipPWiCtPAs7sZZvgAfaDyJP/v4PtmZEs8SizEoI7LzkQJ3SHEusPN9olCamtqMjFPgG2 MTs3a6iU486greNE6Eb1nmM8C9OVTYGIfjeycjajZl4H/dN3xvXoJYcq2+ZN6dz1fddy KaSg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=Ry7ba0ogTE6yHlJj3l0xHb6hRYa9Yi7LeK2WldUvqjI=; b=JfRo8jUp2eldNtOoqZ+C4S1oSYnWpCg41oD0aJS9mD3f9LBoZ/beJM0dIZVdLUcNhH m5jF+0H0EDl6IHI4vu1qF/Rfb4WJ091CpqDKW0LS4e5VPRoQY75SbT9KoivZebzyPPkF NhgduCaBoEkE1q5XacVKIYWQfG9dOFYptKzrF+B7sFr8TuS+jyJ/CgcdiZFHEwqKywnQ NpBL1QgtHWcRMAAqGaQk3M8rOkO4EcgSmTVbNjzUxR/UQHAdC+b/0FAkgkC8+WjuqEMw DiOaCCvfJ+KjMfwWfblvjHH3rMYSzjHgsSEBLyDPHeKO7v9r0elyTd87+SVkzfJDnIlH UUlQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@canb.auug.org.au header.s=201702 header.b=LMvGYq67; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id i11-20020a5d522b000000b00203ee271295si3565940wra.76.2022.05.13.20.32.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 May 2022 20:32:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@canb.auug.org.au header.s=201702 header.b=LMvGYq67; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id F14DE42B135; Fri, 13 May 2022 17:08:23 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377780AbiEMHSu (ORCPT + 99 others); Fri, 13 May 2022 03:18:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42116 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377778AbiEMHSq (ORCPT ); Fri, 13 May 2022 03:18:46 -0400 Received: from gandalf.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 96D3B2878E2; Fri, 13 May 2022 00:18:44 -0700 (PDT) Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 4L00PC5x3qz4xXn; Fri, 13 May 2022 17:18:39 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canb.auug.org.au; s=201702; t=1652426320; bh=Ry7ba0ogTE6yHlJj3l0xHb6hRYa9Yi7LeK2WldUvqjI=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=LMvGYq67D6ahXcnoUHOHm1PO12WuhH6R7N1fnv28ycEig7IUeUPkwL4gsbiAEPv55 0BCk4caofxYiqno6As1KeRz8osntqfimRz5/9YpW4Nxv7Dr1xnwhTDM2dV4H+pfNaQ 28TSac5dp+B3RYpKd2LleNuy7n8dn5hQsLt6qst6Y4MRodQlXqTceD2gVo1f5nygOx 1FebmXFr6R2BSKZQZZdJe7xPpOkAxP3dYjV4ef+m5wjVUjxMsPXVyZ7dtLMwo5eh1I vnSnuRukd+UqqiWErJVzv8jYRn2MWJZUlR16gIdGLO55wuTv5NOj2Xy+fRzKSqCvsv Vk2AE4USvmbeQ== Date: Fri, 13 May 2022 17:18:38 +1000 From: Stephen Rothwell To: Catalin Marinas Cc: Andrew Morton , Will Deacon , Anshuman Khandual , Baolin Wang , Linux Kernel Mailing List , Linux Next Mailing List Subject: Re: linux-next: build failure after merge of the mm tree Message-ID: <20220513171838.627ccc86@canb.auug.org.au> In-Reply-To: References: <20220512193855.4f6ce32f@canb.auug.org.au> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/S6tyXvo/95AbDqwnih9JeJ8"; protocol="application/pgp-signature"; micalg=pgp-sha256 X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 --Sig_/S6tyXvo/95AbDqwnih9JeJ8 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Hi Catalin, On Thu, 12 May 2022 12:07:41 +0100 Catalin Marinas wrote: > > Note that after the arm64 commit, get_clear_contig() no longer flushes > the TLB. So maybe something like: >=20 > diff --git a/arch/arm64/mm/hugetlbpage.c b/arch/arm64/mm/hugetlbpage.c > index 30f5b76aabe9..9a999550df8e 100644 > --- a/arch/arm64/mm/hugetlbpage.c > +++ b/arch/arm64/mm/hugetlbpage.c > @@ -485,12 +485,15 @@ pte_t huge_ptep_clear_flush(struct vm_area_struct *= vma, > { > size_t pgsize; > int ncontig; > + pte_t orig_pte; >=20 > if (!pte_cont(READ_ONCE(*ptep))) > return ptep_clear_flush(vma, addr, ptep); >=20 > ncontig =3D find_num_contig(vma->vm_mm, addr, ptep, &pgsize); > - return get_clear_contig(vma->vm_mm, addr, ptep, pgsize, ncontig); > + orig_pte =3D get_clear_contig(vma->vm_mm, addr, ptep, pgsize, ncontig); > + flush_tlb_range(vma, addr, addr + pgsize * ncontig); > + return orig_pte; > } >=20 > static int __init hugetlbpage_init(void) I have modified my merge resolution patch to as in the above so it looks like this now: From: Stephen Rothwell Date: Fri, 13 May 2022 17:08:07 +1000 Subject: [PATCH] fixup for "mm: change huge_ptep_clear_flush() to return th= e original pte" It interacts with commit fb396bb459c1 ("arm64/hugetlb: Drop TLB flush from get_clear_flush()") from the arm64 tree Signed-off-by: Stephen Rothwell --- arch/arm64/mm/hugetlbpage.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/arch/arm64/mm/hugetlbpage.c b/arch/arm64/mm/hugetlbpage.c index 5bdf913dedc7..10b4a19ed6a2 100644 --- a/arch/arm64/mm/hugetlbpage.c +++ b/arch/arm64/mm/hugetlbpage.c @@ -485,12 +485,15 @@ pte_t huge_ptep_clear_flush(struct vm_area_struct *vm= a, { size_t pgsize; int ncontig; + pte_t orig_pte; =20 if (!pte_cont(READ_ONCE(*ptep))) return ptep_clear_flush(vma, addr, ptep); =20 ncontig =3D find_num_contig(vma->vm_mm, addr, ptep, &pgsize); - return get_clear_flush(vma->vm_mm, addr, ptep, pgsize, ncontig); + orig_pte =3D get_clear_contig(vma->vm_mm, addr, ptep, pgsize, ncontig); + flush_tlb_range(vma, addr, addr + pgsize * ncontig); + return orig_pte; } =20 static int __init hugetlbpage_init(void) --=20 2.35.1 --=20 Cheers, Stephen Rothwell --Sig_/S6tyXvo/95AbDqwnih9JeJ8 Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEENIC96giZ81tWdLgKAVBC80lX0GwFAmJ+Bk4ACgkQAVBC80lX 0GxnEQgAnmB5YyNJxCEZkMLv9LEMvl/mtMzQAG9P53jT6S9/ghNP4Cs5Nu5WL3is CZPmCdZe6kH7svVzjWxZeVykPaAvDmDFcGG8wCE/aZBIRrz7gFRGZVh+ewMSxhUf PE2/WaBVTKCZbk/MmATYrTJN4/sepWyHqS7HNtfNjCwtLrdU2a4Xiogtxy78gmJe BOLaH9qtKuonXrbVpLwpd0ulHZSqd3jF8fY8k8S0YJF1eM+rmjbGVMMqP7OBudre AaE+hCIX/nTXltbJkyB1FZvqLqgws36enZiQNjWcrBsivbc259HyJPIHXDWJ1BaG NHs2eiCsXVXoEthvnnBcwtaMgq454Q== =xeD6 -----END PGP SIGNATURE----- --Sig_/S6tyXvo/95AbDqwnih9JeJ8--