From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-179.mta1.migadu.com (out-179.mta1.migadu.com [95.215.58.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8721320D4FF for ; Sat, 4 Apr 2026 07:37:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.179 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775288231; cv=none; b=pY5SS/pmZtkrE26KCwZQlmKbMPXo71w7bOC787uze2Med+YUDPGoGaMPY+xyyGQbMWlz4RHymup3S/Z5vCv00ol09JoZYk314I8J55EsiDjuRn17TlXTnPSSaow/bT4tulql7kjFShzxAX6nKuvfRrRyY4Y67NfqjOIDZ6mRH48= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775288231; c=relaxed/simple; bh=YjFLpQgBnF3HAvIxqtDDMQxGJDJnkaYb5atAFDTsFuA=; h=Content-Type:Mime-Version:Subject:From:In-Reply-To:Date:Cc: Message-Id:References:To; b=sWAOH9ZZf4k8Q/airph5EdxMIQbxwb1VR7kDxDXyVGtdl/D6H7/T2Si6PTQq+2wBNzLh4MNOm6EWETHyVl7GN12dP52HP/zD8E1mrkdGCTkNmPhsHtwvBBzqJrneE9sF3QxaMpg7YFW7TVV/G9Y0qGkKPHe/Zg7hfYJuGVCRYkc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=J33Tenz/; arc=none smtp.client-ip=95.215.58.179 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="J33Tenz/" Content-Type: text/plain; charset=us-ascii DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1775288226; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=3nWmxlFNX2J4GFdZGRIfE23zfRXOguYRhAS78blu2KA=; b=J33Tenz/ujh68w+9y9GSofFFuNbYRuCJy01kusKKlEkABY5ljUk6uvJbKYDHMmHBIJOXFT UXtt8AucZB5bfd/OfHI0wkfWil+HoheGoWkV+iMawWx8h6mRgQdLXNbMYzhRG4ENO3ICHP 3j2bY5ABGkDxRJU5fjDVh4NEdUHMPd4= Precedence: bulk X-Mailing-List: loongarch@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3864.500.181\)) Subject: Re: [PATCH 0/5] mm/sparse-vmemmap: provide generic vmemmap_set_pmd() and vmemmap_check_pmd() X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Muchun Song In-Reply-To: <20260404071720.3577290-1-songmuchun@bytedance.com> Date: Sat, 4 Apr 2026 15:35:52 +0800 Cc: Catalin Marinas , Will Deacon , Huacai Chen , Paul Walmsley , Palmer Dabbelt , Albert Ou , "David S. Miller" , Andreas Larsson , Andrew Morton , David Hildenbrand , WANG Xuerui , Alexandre Ghiti , Lorenzo Stoakes , "Liam R. Howlett" , Vlastimil Babka , Mike Rapoport , Suren Baghdasaryan , Michal Hocko , Ryan Roberts , Kevin Brodsky , Dev Jain , Anshuman Khandual , Yang Shi , Chaitanya S Prakash , Yuquan Wang , Petr Tesarik , Austin Kim , "Vishal Moola (Oracle)" , Junhui Liu , "Matthew Wilcox (Oracle)" , Alex Shi , Chengkaitao , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, loongarch@lists.linux.dev, linux-riscv@lists.infradead.org, sparclinux@vger.kernel.org, linux-mm@kvack.org Content-Transfer-Encoding: quoted-printable Message-Id: <2CFBEBBC-5273-48E9-9E5F-1F4599194050@linux.dev> References: <20260404071720.3577290-1-songmuchun@bytedance.com> To: Muchun Song X-Migadu-Flow: FLOW_OUT =20 > On Apr 4, 2026, at 15:17, Muchun Song = wrote: >=20 > The two weak functions vmemmap_set_pmd() and vmemmap_check_pmd() are > currently no-ops on every architecture, forcing each platform that = needs > them to duplicate the same handful of lines. Provide a generic = implementation: >=20 > - vmemmap_set_pmd() simply sets a huge PMD with PAGE_KERNEL = protection. >=20 > - vmemmap_check_pmd() verifies that the PMD is present and leaf, > then calls the existing vmemmap_verify() helper. >=20 > Architectures that need special handling can continue to override the > weak symbols; everyone else gets the standard version for free. >=20 > This series drops the custom implementations in arm64, riscv, = loongarch, > and sparc, replacing them with the generic implementation introduced > in the first patch. >=20 > Muchun Song (5): > mm/sparse-vmemmap: provide generic vmemmap_set_pmd() and > vmemmap_check_pmd() > arm64/mm: drop vmemmap_pmd helpers and use generic code > riscv/mm: drop vmemmap_pmd helpers and use generic code > loongarch/mm: drop vmemmap_check_pmd helper and use generic code > sparc/mm: drop vmemmap_check_pmd helper and use generic code Hi all, Please accept my sincere apologies for the mailing list noise. Due to an error in my local scripts (failing to clean up the patch output directory before regenerating the series with an updated commit range), multiple duplicate and conflicting patches were accidentally sent to the list simultaneously (10 patches in total instead of the intended 5). Sorry again for the inconvenience. Thanks, Muchun=20 >=20 > arch/arm64/mm/mmu.c | 14 -------------- > arch/loongarch/mm/init.c | 11 ----------- > arch/riscv/mm/init.c | 13 ------------- > arch/sparc/mm/init_64.c | 11 ----------- > mm/sparse-vmemmap.c | 7 ++++++- > 5 files changed, 6 insertions(+), 50 deletions(-) >=20 > --=20 > 2.20.1 >=20