linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] x86/Kconfig: select ARCH_SELECT_MEMORY_MODEL only if FLATMEM and SPARSEMEM are possible
@ 2021-09-29 14:43 David Hildenbrand
  2022-01-23 19:58 ` [tip: x86/build] x86/Kconfig: Select " tip-bot2 for David Hildenbrand
  0 siblings, 1 reply; 2+ messages in thread
From: David Hildenbrand @ 2021-09-29 14:43 UTC (permalink / raw)
  To: linux-kernel
  Cc: David Hildenbrand, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	H. Peter Anvin, x86, linux-mm

On x86-64 we really only support CONFIG_SPARSEMEM; there is nothing users
can select. So enable the memory model selection (via
CONFIG_ARCH_SELECT_MEMORY_MODEL) only if both, SPARSEMEM and FLATMEM are
possible, which isn't the case on x86-64.

Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: x86@kernel.org
Cc: linux-mm@kvack.org
Signed-off-by: David Hildenbrand <david@redhat.com>
---
 arch/x86/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index ab83c22d274e..50f98dc02ad4 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1611,7 +1611,7 @@ config ARCH_SPARSEMEM_DEFAULT
 
 config ARCH_SELECT_MEMORY_MODEL
 	def_bool y
-	depends on ARCH_SPARSEMEM_ENABLE
+	depends on ARCH_SPARSEMEM_ENABLE && ARCH_FLATMEM_ENABLE
 
 config ARCH_MEMORY_PROBE
 	bool "Enable sysfs memory/probe interface"
-- 
2.31.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [tip: x86/build] x86/Kconfig: Select ARCH_SELECT_MEMORY_MODEL only if FLATMEM and SPARSEMEM are possible
  2021-09-29 14:43 [PATCH v1] x86/Kconfig: select ARCH_SELECT_MEMORY_MODEL only if FLATMEM and SPARSEMEM are possible David Hildenbrand
@ 2022-01-23 19:58 ` tip-bot2 for David Hildenbrand
  0 siblings, 0 replies; 2+ messages in thread
From: tip-bot2 for David Hildenbrand @ 2022-01-23 19:58 UTC (permalink / raw)
  To: linux-tip-commits; +Cc: David Hildenbrand, Borislav Petkov, x86, linux-kernel

The following commit has been merged into the x86/build branch of tip:

Commit-ID:     4eda2bc3431ebe5c8361580877a4666d10ea28a7
Gitweb:        https://git.kernel.org/tip/4eda2bc3431ebe5c8361580877a4666d10ea28a7
Author:        David Hildenbrand <david@redhat.com>
AuthorDate:    Wed, 29 Sep 2021 16:43:21 +02:00
Committer:     Borislav Petkov <bp@suse.de>
CommitterDate: Sun, 23 Jan 2022 20:52:16 +01:00

x86/Kconfig: Select ARCH_SELECT_MEMORY_MODEL only if FLATMEM and SPARSEMEM are possible

x86-64 supports only CONFIG_SPARSEMEM; there is nothing users can select.
So enable the memory model selection (via CONFIG_ARCH_SELECT_MEMORY_MODEL)
only if both, SPARSEMEM and FLATMEM are possible, which isn't the case
on x86-64.

Signed-off-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Link: https://lore.kernel.org/r/20210929144321.50411-1-david@redhat.com
---
 arch/x86/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index ebe8fc7..a7e0bf4 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1637,7 +1637,7 @@ config ARCH_SPARSEMEM_DEFAULT
 
 config ARCH_SELECT_MEMORY_MODEL
 	def_bool y
-	depends on ARCH_SPARSEMEM_ENABLE
+	depends on ARCH_SPARSEMEM_ENABLE && ARCH_FLATMEM_ENABLE
 
 config ARCH_MEMORY_PROBE
 	bool "Enable sysfs memory/probe interface"

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-01-23 19:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-29 14:43 [PATCH v1] x86/Kconfig: select ARCH_SELECT_MEMORY_MODEL only if FLATMEM and SPARSEMEM are possible David Hildenbrand
2022-01-23 19:58 ` [tip: x86/build] x86/Kconfig: Select " tip-bot2 for David Hildenbrand

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).