From nobody Fri Dec 19 04:02:24 2025 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 448D9219E8D; Wed, 26 Feb 2025 12:24:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572670; cv=none; b=OEG6x5k6SfHpriYzNZmuaZqLOiULpfmtwmCa4cW5ZoM1yqGCEmOZw3M/h7HQQS3ByHWYJ5LP6RxWKERBYPmg9KVS3v5eTgxeHT3qC2aEBcOgck3Xw0DayeM42cU50Zo+NgHmPMoJ1KMc1T2D9s42smVDx/V+sMabe6olCs+tGuM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572670; c=relaxed/simple; bh=oh130ZfN7W4wku04HmoxfgsWtF4oVy+oljkEG0XQAD8=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=exV5+vvcv2v1uSLygLz/FXJEUogcIHFkMOZVdcM20I9pGxYrFNFJ39UkY57jIgxloH9fVUmgrkjZKUrV+239FQ9yB3Mt91kzOT6ZCyew8B8k75Lo1dEm1tghLTvddAaeVYSZxAeyAJ5jGt2EEdjrQubP7j9Qo1OvpTCLe9pUH7o= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 9CB9C16F3; Wed, 26 Feb 2025 04:24:44 -0800 (PST) Received: from a077893.arm.com (unknown [10.163.40.69]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id A1DC13F5A1; Wed, 26 Feb 2025 04:24:24 -0800 (PST) From: Anshuman Khandual To: linux-mm@kvack.org Cc: Anshuman Khandual , Andrew Morton , Mark Rutland , Christophe Leroy , kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, Steven Price Subject: [PATCH V3 1/5] configs: Drop GENERIC_PTDUMP from debug.config Date: Wed, 26 Feb 2025 17:54:00 +0530 Message-Id: <20250226122404.1927473-2-anshuman.khandual@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20250226122404.1927473-1-anshuman.khandual@arm.com> References: <20250226122404.1927473-1-anshuman.khandual@arm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The platforms that support GENERIC_PTDUMP select the config explicitly. But enabling this feature on platforms that don't really support - does nothing or might cause a build failure. Hence just drop GENERIC_PTDUMP from generic debug.config Cc: Andrew Morton Cc: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org Reviewed-by: Steven Price Signed-off-by: Anshuman Khandual --- kernel/configs/debug.config | 1 - 1 file changed, 1 deletion(-) diff --git a/kernel/configs/debug.config b/kernel/configs/debug.config index 20552f163930..8aafd050b754 100644 --- a/kernel/configs/debug.config +++ b/kernel/configs/debug.config @@ -73,7 +73,6 @@ CONFIG_DEBUG_VM=3Dy CONFIG_DEBUG_VM_PGFLAGS=3Dy CONFIG_DEBUG_VM_RB=3Dy CONFIG_DEBUG_VM_VMACACHE=3Dy -CONFIG_GENERIC_PTDUMP=3Dy CONFIG_KASAN=3Dy CONFIG_KASAN_GENERIC=3Dy CONFIG_KASAN_INLINE=3Dy --=20 2.25.1 From nobody Fri Dec 19 04:02:24 2025 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id F091E21B9D5; Wed, 26 Feb 2025 12:24:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572675; cv=none; b=eiVoo3RlrDMRbIeJBwOsu1dpdJRtwz3fPp9IR/lDhblspWUjWVQGTl0jdOx785o4ouxgh771cLMENLwBtewqKMu/z0LsXdcccUbGxqUK6Z9rGN4k693fbKlZlPFxmw/fHP3s0XPXhaeEc09zkfIQj+Nig1DUZkJHh2Q+LD/frEQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572675; c=relaxed/simple; bh=Hmagx55tkL6jALbXe4oXBq5nS6VxJeUAYDLWnZxQ+tw=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=L9XKucRD8MFwwHBhLCOFVcRw0jcPsEFU1SMKGf9vJpAKoM3Iv2poaW/i32FBL94+1N9TX9ELNYe6yQxY9+ee0BuhrS3UDOhiVe9cBKwHNuz8YX69MyY/6r8nO8ltspFVu1pL0qHOJYku4YKAmFJaPbD2PuNdR36G6Yb4LDci1FA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 94D281C0A; Wed, 26 Feb 2025 04:24:49 -0800 (PST) Received: from a077893.arm.com (unknown [10.163.40.69]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 2BC4A3F5A1; Wed, 26 Feb 2025 04:24:28 -0800 (PST) From: Anshuman Khandual To: linux-mm@kvack.org Cc: Anshuman Khandual , Andrew Morton , Mark Rutland , Christophe Leroy , kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, Madhavan Srinivasan , Michael Ellerman , Nicholas Piggin Subject: [PATCH V3 2/5] arch/powerpc: Drop GENERIC_PTDUMP from mpc885_ads_defconfig Date: Wed, 26 Feb 2025 17:54:01 +0530 Message-Id: <20250226122404.1927473-3-anshuman.khandual@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20250226122404.1927473-1-anshuman.khandual@arm.com> References: <20250226122404.1927473-1-anshuman.khandual@arm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" GENERIC_PTDUMP gets selected on powerpc explicitly and hence can be dropped off from mpc885_ads_defconfig. Replace with CONFIG_PTDUMP_DEBUGFS instead. Cc: Madhavan Srinivasan Cc: Michael Ellerman Cc: Nicholas Piggin Cc: Christophe Leroy Cc: linuxppc-dev@lists.ozlabs.org Cc: linux-kernel@vger.kernel.org Fixes: e084728393a5 ("powerpc/ptdump: Convert powerpc to GENERIC_PTDUMP") Suggested-by: Christophe Leroy Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy --- arch/powerpc/configs/mpc885_ads_defconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/configs/mpc885_ads_defconfig b/arch/powerpc/confi= gs/mpc885_ads_defconfig index 77306be62e9e..129355f87f80 100644 --- a/arch/powerpc/configs/mpc885_ads_defconfig +++ b/arch/powerpc/configs/mpc885_ads_defconfig @@ -78,4 +78,4 @@ CONFIG_DEBUG_VM_PGTABLE=3Dy CONFIG_DETECT_HUNG_TASK=3Dy CONFIG_BDI_SWITCH=3Dy CONFIG_PPC_EARLY_DEBUG=3Dy -CONFIG_GENERIC_PTDUMP=3Dy +CONFIG_PTDUMP_DEBUGFS=3Dy --=20 2.25.1 From nobody Fri Dec 19 04:02:24 2025 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1F7AA21D3DC; Wed, 26 Feb 2025 12:24:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572683; cv=none; b=h/SQMutXaHIY0k4c3vl8ormgU73kqBGcbmz78Y6W9x0Tx7iMdNKdlAGC+9eao+BlYfPPIDqXlA5dP6FkHz+ZhZLfdr6dw4pWbmT0rxB0DYoRE15Wg4Nh2ce200KmQduMpp2NiGk2f1dxb4fSkcuYgW1tdYR3Y1FMYXw53K+QtIE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572683; c=relaxed/simple; bh=+PviHAwD+iZdDuTMuUjKZtAItr3hYRxyxVhNRgE683o=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=UpPrKKqfJo4ih6L9dAMnLQCKWFjHPAX+o8WcGMNOwhwb24jtJb4RNA4M3NT4uDdKhTIy4W/rII65sPkA4HwXsbvEwTCseINpCcRFVux0ffdqO40POUfb+ZDwHjrQezpEp4vJXiam9a5dXIPiROFIsfrQdY6/zevbB3f8HSAJgag= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 77DF42308; Wed, 26 Feb 2025 04:24:55 -0800 (PST) Received: from a077893.arm.com (unknown [10.163.40.69]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 300E63F5A1; Wed, 26 Feb 2025 04:24:33 -0800 (PST) From: Anshuman Khandual To: linux-mm@kvack.org Cc: Anshuman Khandual , Andrew Morton , Mark Rutland , Christophe Leroy , kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, Catalin Marinas , Will Deacon , Jonathan Corbet , Steven Price Subject: [PATCH V3 3/5] docs: arm64: Drop PTDUMP config options from ptdump.rst Date: Wed, 26 Feb 2025 17:54:02 +0530 Message-Id: <20250226122404.1927473-4-anshuman.khandual@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20250226122404.1927473-1-anshuman.khandual@arm.com> References: <20250226122404.1927473-1-anshuman.khandual@arm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Both GENERIC_PTDUMP and PTDUMP_CORE are not user selectable config options. Just drop these from documentation. Cc: Catalin Marinas Cc: Will Deacon Cc: Jonathan Corbet Cc: linux-arm-kernel@lists.infradead.org Cc: linux-doc@vger.kernel.org Cc: linux-kernel@vger.kernel.org Suggested-by: Steven Price Signed-off-by: Anshuman Khandual Acked-by: Catalin Marinas --- Documentation/arch/arm64/ptdump.rst | 2 -- 1 file changed, 2 deletions(-) diff --git a/Documentation/arch/arm64/ptdump.rst b/Documentation/arch/arm64= /ptdump.rst index 5dcfc5d7cddf..51eb902ba41a 100644 --- a/Documentation/arch/arm64/ptdump.rst +++ b/Documentation/arch/arm64/ptdump.rst @@ -22,8 +22,6 @@ offlining of memory being accessed by the ptdump code. In order to dump the kernel page tables, enable the following configurations and mount debugfs:: =20 - CONFIG_GENERIC_PTDUMP=3Dy - CONFIG_PTDUMP_CORE=3Dy CONFIG_PTDUMP_DEBUGFS=3Dy =20 mount -t debugfs nodev /sys/kernel/debug --=20 2.25.1 From nobody Fri Dec 19 04:02:24 2025 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9E886221577; Wed, 26 Feb 2025 12:24:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572686; cv=none; b=eEpw1ivAHAFnmKqc1AjG6gjAT4T4M7hfAs3Aycvl/rkSnUltL1D7P8RUBR/NZO7yDqKOuS+Tdn31mM3lt+85k9vheSHyaM67Aap2QsdyhCTQvg+SOo8ESNPkCGsqzPrYXsj0rPBIPXB4YAKhQmLNNaxy6mFopOb4EkPRTwHDgkg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572686; c=relaxed/simple; bh=QF11rklDJlulOtMhX6JMt11M85VxHvDVfYl4vULNd3E=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=sS/6KW7vhft4w4eO0+4XZDB3JzV/ozWcR/ijR1YHUWM6P0qfk9q7eeCwcNemT58y5EPA+QdXCLAEXhXYLLQ7cUjScTCEBQLN26raopfZJe9GazCfb/D2pNHUkizzwaLK4j+LisUDjKWGCnZ6F3xzpQkMoZwjMOEW88eSlfz767Y= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0B27628C7; Wed, 26 Feb 2025 04:25:00 -0800 (PST) Received: from a077893.arm.com (unknown [10.163.40.69]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 146C63F5A1; Wed, 26 Feb 2025 04:24:39 -0800 (PST) From: Anshuman Khandual To: linux-mm@kvack.org Cc: Anshuman Khandual , Andrew Morton , Mark Rutland , Christophe Leroy , kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, Steven Price Subject: [PATCH V3 4/5] mm: Make DEBUG_WX depdendent on GENERIC_PTDUMP Date: Wed, 26 Feb 2025 17:54:03 +0530 Message-Id: <20250226122404.1927473-5-anshuman.khandual@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20250226122404.1927473-1-anshuman.khandual@arm.com> References: <20250226122404.1927473-1-anshuman.khandual@arm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" DEBUG_WX selects PTDUMP_CORE without even ensuring that the given platform implements GENERIC_PTDUMP. This problem has been latent until now, as all the platforms subscribing ARCH_HAS_DEBUG_WX also subscribe GENERIC_PTDUMP. Cc: Andrew Morton Cc: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org Reviewed-by: Steven Price Signed-off-by: Anshuman Khandual Reviewed-by: Christophe Leroy --- mm/Kconfig.debug | 1 + 1 file changed, 1 insertion(+) diff --git a/mm/Kconfig.debug b/mm/Kconfig.debug index 41a58536531d..a51a1149909a 100644 --- a/mm/Kconfig.debug +++ b/mm/Kconfig.debug @@ -186,6 +186,7 @@ config ARCH_HAS_DEBUG_WX config DEBUG_WX bool "Warn on W+X mappings at boot" depends on ARCH_HAS_DEBUG_WX + depends on GENERIC_PTDUMP depends on MMU select PTDUMP_CORE help --=20 2.25.1 From nobody Fri Dec 19 04:02:24 2025 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5E00121B192; Wed, 26 Feb 2025 12:24:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572694; cv=none; b=JNKfsRvp4DOWPCWRpCK7bKE+XTmoLCmFMfXCReUnKGLh04LiavJV2pJLDcx1SR+adLp+mtpppzBdxFAnRFopnmmsS9dFFo0eMdMqVayE9bwo7KEINhJzG6pplZgMzwklbmYyEsIdbwR6kXoCKEu2ragnPIUHq8ZknkRgBs+bCtk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740572694; c=relaxed/simple; bh=KVIdkwcyhTwRU6Kk1/0wXcaBwUFTrRKOlwkeh/UflVM=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=iuucAFLe12r8mZ/F5i/BxQikrrw/5/ZN9h8P+bhiwqwdbBEzsQS/bA+hLZ27JjcPN3M5LLO4WZmBrpbm+Vi+r36P2xpQkAcUkoLV1AiAk6mgsllXRZ0ok6eGL8FeyCnXCLg/A4hVcFyK+iywThuyDQR9mJydxr/ysZy0Nzah0uk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id DFA742BC0; Wed, 26 Feb 2025 04:25:07 -0800 (PST) Received: from a077893.arm.com (unknown [10.163.40.69]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id A5B7F3F5A1; Wed, 26 Feb 2025 04:24:44 -0800 (PST) From: Anshuman Khandual To: linux-mm@kvack.org Cc: Anshuman Khandual , Andrew Morton , Mark Rutland , Christophe Leroy , kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, Catalin Marinas , Will Deacon , Jonathan Corbet , Marc Zyngier , Michael Ellerman , Nicholas Piggin , Paul Walmsley , Palmer Dabbelt , Heiko Carstens , Vasily Gorbik , Thomas Gleixner , Ingo Molnar Subject: [PATCH V3 5/5] mm: Rename GENERIC_PTDUMP and PTDUMP_CORE Date: Wed, 26 Feb 2025 17:54:04 +0530 Message-Id: <20250226122404.1927473-6-anshuman.khandual@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20250226122404.1927473-1-anshuman.khandual@arm.com> References: <20250226122404.1927473-1-anshuman.khandual@arm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Platforms subscribe into generic ptdump implementation via GENERIC_PTDUMP. But generic ptdump gets enabled via PTDUMP_CORE. These configs combination is confusing as they sound very similar and does not differentiate between platform's feature subscription and feature enablement for ptdump. Rename the configs as ARCH_HAS_PTDUMP and PTDUMP making it more clear and improve readability. Cc: Catalin Marinas Cc: Will Deacon Cc: Jonathan Corbet Cc: Marc Zyngier Cc: Michael Ellerman Cc: Nicholas Piggin Cc: Paul Walmsley Cc: Palmer Dabbelt Cc: Heiko Carstens Cc: Vasily Gorbik Cc: Thomas Gleixner Cc: Ingo Molnar Cc: Andrew Morton Cc: linux-arm-kernel@lists.infradead.org Cc: linux-doc@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: kvmarm@lists.linux.dev Cc: linuxppc-dev@lists.ozlabs.org Cc: linux-riscv@lists.infradead.org Cc: linux-s390@vger.kernel.org Cc: linux-mm@kvack.org Signed-off-by: Anshuman Khandual Acked-by: Catalin Marinas Reviewed-by: Christophe Leroy (powerpc) --- arch/arm64/Kconfig | 2 +- arch/arm64/include/asm/ptdump.h | 4 ++-- arch/arm64/kvm/Kconfig | 4 ++-- arch/arm64/mm/Makefile | 2 +- arch/powerpc/Kconfig | 2 +- arch/powerpc/mm/Makefile | 2 +- arch/riscv/Kconfig | 2 +- arch/riscv/mm/Makefile | 2 +- arch/s390/Kconfig | 2 +- arch/s390/mm/Makefile | 2 +- arch/x86/Kconfig | 2 +- arch/x86/Kconfig.debug | 2 +- arch/x86/mm/Makefile | 2 +- mm/Kconfig.debug | 12 ++++++------ mm/Makefile | 2 +- 15 files changed, 22 insertions(+), 22 deletions(-) diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig index 940343beb3d4..5cf688ee01b7 100644 --- a/arch/arm64/Kconfig +++ b/arch/arm64/Kconfig @@ -41,6 +41,7 @@ config ARM64 select ARCH_HAS_NMI_SAFE_THIS_CPU_OPS select ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE select ARCH_HAS_NONLEAF_PMD_YOUNG if ARM64_HAFT + select ARCH_HAS_PTDUMP select ARCH_HAS_PTE_DEVMAP select ARCH_HAS_PTE_SPECIAL select ARCH_HAS_HW_PTE_YOUNG @@ -157,7 +158,6 @@ config ARM64 select GENERIC_IRQ_SHOW_LEVEL select GENERIC_LIB_DEVMEM_IS_ALLOWED select GENERIC_PCI_IOMAP - select GENERIC_PTDUMP select GENERIC_SCHED_CLOCK select GENERIC_SMP_IDLE_THREAD select GENERIC_TIME_VSYSCALL diff --git a/arch/arm64/include/asm/ptdump.h b/arch/arm64/include/asm/ptdum= p.h index 6cf4aae05219..b2931d1ae0fb 100644 --- a/arch/arm64/include/asm/ptdump.h +++ b/arch/arm64/include/asm/ptdump.h @@ -7,7 +7,7 @@ =20 #include =20 -#ifdef CONFIG_PTDUMP_CORE +#ifdef CONFIG_PTDUMP =20 #include #include @@ -70,6 +70,6 @@ static inline void ptdump_debugfs_register(struct ptdump_= info *info, #else static inline void note_page(struct ptdump_state *pt_st, unsigned long add= r, int level, u64 val) { } -#endif /* CONFIG_PTDUMP_CORE */ +#endif /* CONFIG_PTDUMP */ =20 #endif /* __ASM_PTDUMP_H */ diff --git a/arch/arm64/kvm/Kconfig b/arch/arm64/kvm/Kconfig index ead632ad01b4..096e45acadb2 100644 --- a/arch/arm64/kvm/Kconfig +++ b/arch/arm64/kvm/Kconfig @@ -71,8 +71,8 @@ config PTDUMP_STAGE2_DEBUGFS depends on KVM depends on DEBUG_KERNEL depends on DEBUG_FS - depends on GENERIC_PTDUMP - select PTDUMP_CORE + depends on ARCH_HAS_PTDUMP + select PTDUMP default n help Say Y here if you want to show the stage-2 kernel pagetables diff --git a/arch/arm64/mm/Makefile b/arch/arm64/mm/Makefile index fc92170a8f37..c26489cf96cd 100644 --- a/arch/arm64/mm/Makefile +++ b/arch/arm64/mm/Makefile @@ -5,7 +5,7 @@ obj-y :=3D dma-mapping.o extable.o fault.o init.o \ context.o proc.o pageattr.o fixmap.o obj-$(CONFIG_ARM64_CONTPTE) +=3D contpte.o obj-$(CONFIG_HUGETLB_PAGE) +=3D hugetlbpage.o -obj-$(CONFIG_PTDUMP_CORE) +=3D ptdump.o +obj-$(CONFIG_PTDUMP) +=3D ptdump.o obj-$(CONFIG_PTDUMP_DEBUGFS) +=3D ptdump_debugfs.o obj-$(CONFIG_TRANS_TABLE) +=3D trans_pgd.o obj-$(CONFIG_TRANS_TABLE) +=3D trans_pgd-asm.o diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 424f188e62d9..6f1ae41dcf85 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -148,6 +148,7 @@ config PPC select ARCH_HAS_PHYS_TO_DMA select ARCH_HAS_PMEM_API select ARCH_HAS_PREEMPT_LAZY + select ARCH_HAS_PTDUMP select ARCH_HAS_PTE_DEVMAP if PPC_BOOK3S_64 select ARCH_HAS_PTE_SPECIAL select ARCH_HAS_SCALED_CPUTIME if VIRT_CPU_ACCOUNTING_NATIVE && PPC_BOOK= 3S_64 @@ -206,7 +207,6 @@ config PPC select GENERIC_IRQ_SHOW select GENERIC_IRQ_SHOW_LEVEL select GENERIC_PCI_IOMAP if PCI - select GENERIC_PTDUMP select GENERIC_SMP_IDLE_THREAD select GENERIC_TIME_VSYSCALL select GENERIC_VDSO_TIME_NS diff --git a/arch/powerpc/mm/Makefile b/arch/powerpc/mm/Makefile index 0fe2f085c05a..8c1582b2987d 100644 --- a/arch/powerpc/mm/Makefile +++ b/arch/powerpc/mm/Makefile @@ -15,5 +15,5 @@ obj-$(CONFIG_NUMA) +=3D numa.o obj-$(CONFIG_HUGETLB_PAGE) +=3D hugetlbpage.o obj-$(CONFIG_NOT_COHERENT_CACHE) +=3D dma-noncoherent.o obj-$(CONFIG_PPC_COPRO_BASE) +=3D copro_fault.o -obj-$(CONFIG_PTDUMP_CORE) +=3D ptdump/ +obj-$(CONFIG_PTDUMP) +=3D ptdump/ obj-$(CONFIG_KASAN) +=3D kasan/ diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig index 7612c52e9b1e..353cf41d01f4 100644 --- a/arch/riscv/Kconfig +++ b/arch/riscv/Kconfig @@ -43,6 +43,7 @@ config RISCV select ARCH_HAS_PMEM_API select ARCH_HAS_PREEMPT_LAZY select ARCH_HAS_PREPARE_SYNC_CORE_CMD + select ARCH_HAS_PTDUMP if MMU select ARCH_HAS_PTE_DEVMAP if 64BIT && MMU select ARCH_HAS_PTE_SPECIAL select ARCH_HAS_SET_DIRECT_MAP if MMU @@ -112,7 +113,6 @@ config RISCV select GENERIC_IRQ_SHOW_LEVEL select GENERIC_LIB_DEVMEM_IS_ALLOWED select GENERIC_PCI_IOMAP - select GENERIC_PTDUMP if MMU select GENERIC_SCHED_CLOCK select GENERIC_SMP_IDLE_THREAD select GENERIC_TIME_VSYSCALL if MMU && 64BIT diff --git a/arch/riscv/mm/Makefile b/arch/riscv/mm/Makefile index cbe4d775ef56..b916a68d324a 100644 --- a/arch/riscv/mm/Makefile +++ b/arch/riscv/mm/Makefile @@ -19,7 +19,7 @@ obj-y +=3D context.o obj-y +=3D pmem.o =20 obj-$(CONFIG_HUGETLB_PAGE) +=3D hugetlbpage.o -obj-$(CONFIG_PTDUMP_CORE) +=3D ptdump.o +obj-$(CONFIG_PTDUMP) +=3D ptdump.o obj-$(CONFIG_KASAN) +=3D kasan_init.o =20 ifdef CONFIG_KASAN diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig index 9c9ec08d78c7..dd9dd2f8e673 100644 --- a/arch/s390/Kconfig +++ b/arch/s390/Kconfig @@ -96,6 +96,7 @@ config S390 select ARCH_HAS_MEM_ENCRYPT select ARCH_HAS_NMI_SAFE_THIS_CPU_OPS select ARCH_HAS_PREEMPT_LAZY + select ARCH_HAS_PTDUMP select ARCH_HAS_PTE_SPECIAL select ARCH_HAS_SCALED_CPUTIME select ARCH_HAS_SET_DIRECT_MAP @@ -163,7 +164,6 @@ config S390 select GENERIC_CPU_VULNERABILITIES select GENERIC_ENTRY select GENERIC_GETTIMEOFDAY - select GENERIC_PTDUMP select GENERIC_SMP_IDLE_THREAD select GENERIC_TIME_VSYSCALL select GENERIC_VDSO_TIME_NS diff --git a/arch/s390/mm/Makefile b/arch/s390/mm/Makefile index f6c2db7a8669..9726b91fe7e4 100644 --- a/arch/s390/mm/Makefile +++ b/arch/s390/mm/Makefile @@ -9,6 +9,6 @@ obj-y +=3D page-states.o pageattr.o pgtable.o pgalloc.o ex= table.o obj-$(CONFIG_CMM) +=3D cmm.o obj-$(CONFIG_DEBUG_VIRTUAL) +=3D physaddr.o obj-$(CONFIG_HUGETLB_PAGE) +=3D hugetlbpage.o -obj-$(CONFIG_PTDUMP_CORE) +=3D dump_pagetables.o +obj-$(CONFIG_PTDUMP) +=3D dump_pagetables.o obj-$(CONFIG_PGSTE) +=3D gmap.o obj-$(CONFIG_PFAULT) +=3D pfault.o diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index be2c311f5118..39ecafffc7e3 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -26,6 +26,7 @@ config X86_64 depends on 64BIT # Options that are inherently 64-bit kernel only: select ARCH_HAS_GIGANTIC_PAGE + select ARCH_HAS_PTDUMP select ARCH_SUPPORTS_INT128 if CC_HAS_INT128 select ARCH_SUPPORTS_PER_VMA_LOCK select ARCH_SUPPORTS_HUGE_PFNMAP if TRANSPARENT_HUGEPAGE @@ -174,7 +175,6 @@ config X86 select GENERIC_IRQ_RESERVATION_MODE select GENERIC_IRQ_SHOW select GENERIC_PENDING_IRQ if SMP - select GENERIC_PTDUMP select GENERIC_SMP_IDLE_THREAD select GENERIC_TIME_VSYSCALL select GENERIC_GETTIMEOFDAY diff --git a/arch/x86/Kconfig.debug b/arch/x86/Kconfig.debug index 1eb4d23cdaae..c95c3aaadf97 100644 --- a/arch/x86/Kconfig.debug +++ b/arch/x86/Kconfig.debug @@ -59,7 +59,7 @@ config EARLY_PRINTK_USB_XDBC config EFI_PGT_DUMP bool "Dump the EFI pagetable" depends on EFI - select PTDUMP_CORE + select PTDUMP help Enable this if you want to dump the EFI page table before enabling virtual mode. This can be used to debug miscellaneous diff --git a/arch/x86/mm/Makefile b/arch/x86/mm/Makefile index 690fbf48e853..e0c99a8760ca 100644 --- a/arch/x86/mm/Makefile +++ b/arch/x86/mm/Makefile @@ -39,7 +39,7 @@ CFLAGS_fault.o :=3D -I $(src)/../include/asm/trace obj-$(CONFIG_X86_32) +=3D pgtable_32.o iomap_32.o =20 obj-$(CONFIG_HUGETLB_PAGE) +=3D hugetlbpage.o -obj-$(CONFIG_PTDUMP_CORE) +=3D dump_pagetables.o +obj-$(CONFIG_PTDUMP) +=3D dump_pagetables.o obj-$(CONFIG_PTDUMP_DEBUGFS) +=3D debug_pagetables.o =20 obj-$(CONFIG_HIGHMEM) +=3D highmem_32.o diff --git a/mm/Kconfig.debug b/mm/Kconfig.debug index a51a1149909a..32b65073d0cc 100644 --- a/mm/Kconfig.debug +++ b/mm/Kconfig.debug @@ -186,9 +186,9 @@ config ARCH_HAS_DEBUG_WX config DEBUG_WX bool "Warn on W+X mappings at boot" depends on ARCH_HAS_DEBUG_WX - depends on GENERIC_PTDUMP + depends on ARCH_HAS_PTDUMP depends on MMU - select PTDUMP_CORE + select PTDUMP help Generate a warning if any W+X mappings are found at boot. =20 @@ -213,18 +213,18 @@ config DEBUG_WX =20 If in doubt, say "Y". =20 -config GENERIC_PTDUMP +config ARCH_HAS_PTDUMP bool =20 -config PTDUMP_CORE +config PTDUMP bool =20 config PTDUMP_DEBUGFS bool "Export kernel pagetable layout to userspace via debugfs" depends on DEBUG_KERNEL depends on DEBUG_FS - depends on GENERIC_PTDUMP - select PTDUMP_CORE + depends on ARCH_HAS_PTDUMP + select PTDUMP help Say Y here if you want to show the kernel pagetable layout in a debugfs file. This information is only useful for kernel developers diff --git a/mm/Makefile b/mm/Makefile index 850386a67b3e..26dfecd4d396 100644 --- a/mm/Makefile +++ b/mm/Makefile @@ -138,7 +138,7 @@ obj-$(CONFIG_ZONE_DEVICE) +=3D memremap.o obj-$(CONFIG_HMM_MIRROR) +=3D hmm.o obj-$(CONFIG_MEMFD_CREATE) +=3D memfd.o obj-$(CONFIG_MAPPING_DIRTY_HELPERS) +=3D mapping_dirty_helpers.o -obj-$(CONFIG_PTDUMP_CORE) +=3D ptdump.o +obj-$(CONFIG_PTDUMP) +=3D ptdump.o obj-$(CONFIG_PAGE_REPORTING) +=3D page_reporting.o obj-$(CONFIG_IO_MAPPING) +=3D io-mapping.o obj-$(CONFIG_HAVE_BOOTMEM_INFO_NODE) +=3D bootmem_info.o --=20 2.25.1