From nobody Wed Dec 17 17:44:51 2025 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D3DC94A02 for ; Mon, 9 Dec 2024 03:13:05 +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=1733713988; cv=none; b=tUc85dJPgZ6uL9Q7TeR0LZfUhJ9imImNrRnp6QABdq6Ba3EnqSjGnGeOqimcFU8D5Ee2f7N/7ERQhZ//BHitBRXlsosTS2ZWYqP8Zi/avHCv77PTVjX1jhWm8HwxSwqJgZ/05VrXWxM/OowrXiXjaZjZKPudc3lllLPuuhV5btA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733713988; c=relaxed/simple; bh=XBa8dBNPBeGiDtffe4gl1gj7H1aIeC7MmnQiRE4yBjA=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=rJMM1H9qa2rqh3w2RgQhSfXOl/WpZPVTKxLHogcy7ytMZCVLw/GoW14hxac8PKj+9aNLXSy3W4H0WeDYAMQtMopAT0jsl3t0svtHlcVjc2K1nVfoiq26gOH23CxIcXmUiEmavbwZKcnz46V+c6ymamFlks5wx36K3ilspVJIX+w= 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 30181143D; Sun, 8 Dec 2024 19:13:27 -0800 (PST) Received: from a077893.blr.arm.com (a077893.blr.arm.com [10.162.16.41]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 98D073F58B; Sun, 8 Dec 2024 19:12:56 -0800 (PST) From: Anshuman Khandual To: linux-mm@kvack.org Cc: Anshuman Khandual , Catalin Marinas , Will Deacon , Andrew Morton , Kees Cook , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] mm/execmem: Make ARCH_WANTS_EXECMEM_LATE depend on EXECMEM Date: Mon, 9 Dec 2024 08:42:51 +0530 Message-Id: <20241209031251.515903-1-anshuman.khandual@arm.com> X-Mailer: git-send-email 2.25.1 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" Late initialisation of EXECMEM inherently requires EXEMEM itself, and hence this dependency should not be left with the subscribing platforms. Cc: Catalin Marinas Cc: Will Deacon Cc: Andrew Morton Cc: Kees Cook Cc: linux-arm-kernel@lists.infradead.org Cc: linux-mm@kvack.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Anshuman Khandual --- This patch applies on v6.13-rc1 arch/Kconfig | 1 + arch/arm64/Kconfig | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/Kconfig b/arch/Kconfig index 6682b2a53e34..17716f32dc44 100644 --- a/arch/Kconfig +++ b/arch/Kconfig @@ -1058,6 +1058,7 @@ config ARCH_WANTS_MODULES_DATA_IN_VMALLOC =20 config ARCH_WANTS_EXECMEM_LATE bool + depends on EXECMEM help For architectures that do not allocate executable memory early on boot, but rather require its initialization late when there is diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig index b5479c8b454c..b146372bc365 100644 --- a/arch/arm64/Kconfig +++ b/arch/arm64/Kconfig @@ -113,7 +113,7 @@ config ARM64 select ARCH_WANT_FRAME_POINTERS select ARCH_WANT_HUGE_PMD_SHARE if ARM64_4K_PAGES || (ARM64_16K_PAGES && = !ARM64_VA_BITS_36) select ARCH_WANT_LD_ORPHAN_WARN - select ARCH_WANTS_EXECMEM_LATE if EXECMEM + select ARCH_WANTS_EXECMEM_LATE select ARCH_WANTS_NO_INSTR select ARCH_WANTS_THP_SWAP if ARM64_4K_PAGES select ARCH_HAS_UBSAN --=20 2.30.2