From patchwork Wed Sep 29 14:43:21 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Hildenbrand X-Patchwork-Id: 12525689 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 210F5C433EF for ; Wed, 29 Sep 2021 14:43:29 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id C356D61288 for ; Wed, 29 Sep 2021 14:43:28 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org C356D61288 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 53B26940035; Wed, 29 Sep 2021 10:43:28 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 51C8A940020; Wed, 29 Sep 2021 10:43:28 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 400D2940035; Wed, 29 Sep 2021 10:43:28 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0078.hostedemail.com [216.40.44.78]) by kanga.kvack.org (Postfix) with ESMTP id 31D1F940020 for ; Wed, 29 Sep 2021 10:43:28 -0400 (EDT) Received: from smtpin39.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id DBA2725F5D for ; Wed, 29 Sep 2021 14:43:27 +0000 (UTC) X-FDA: 78640879254.39.F152A43 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by imf26.hostedemail.com (Postfix) with ESMTP id 823B520019ED for ; Wed, 29 Sep 2021 14:43:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1632926607; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=k2mLc/radmqh34XgUWy+HwWaMs9PrqhstK/RW+oNKnc=; b=hs5mKGQpv5TsD2uWcnCEtb68+6p7Vb0iJ9soH+KInBz2DkiwXXGiMMyzmxEuTezF59IB7s NzKvcgmK4uk4xf/OgHdDbJSu345ctVu81KX5aeKfVjDP8zxP5CgeJu6HkPp6w2FifeeEcS FBC+Voqe8KEFsSQeEtOI9pB0ktv0XLs= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-315-yY6d50MPNzqq9ntTG_In9g-1; Wed, 29 Sep 2021 10:43:25 -0400 X-MC-Unique: yY6d50MPNzqq9ntTG_In9g-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 7065518414A6; Wed, 29 Sep 2021 14:43:24 +0000 (UTC) Received: from t480s.redhat.com (unknown [10.39.195.135]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5B69319C59; Wed, 29 Sep 2021 14:43:22 +0000 (UTC) From: David Hildenbrand To: linux-kernel@vger.kernel.org Cc: David Hildenbrand , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , x86@kernel.org, linux-mm@kvack.org Subject: [PATCH v1] x86/Kconfig: select ARCH_SELECT_MEMORY_MODEL only if FLATMEM and SPARSEMEM are possible Date: Wed, 29 Sep 2021 16:43:21 +0200 Message-Id: <20210929144321.50411-1-david@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 Authentication-Results: imf26.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=hs5mKGQp; spf=none (imf26.hostedemail.com: domain of david@redhat.com has no SPF policy when checking 216.205.24.124) smtp.mailfrom=david@redhat.com; dmarc=pass (policy=none) header.from=redhat.com X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: 823B520019ED X-Stat-Signature: p4cx4tn59wat8a95cnybakgco76or4ep X-HE-Tag: 1632926607-418550 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: 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 Cc: Ingo Molnar Cc: Borislav Petkov Cc: "H. Peter Anvin" Cc: x86@kernel.org Cc: linux-mm@kvack.org Signed-off-by: David Hildenbrand --- 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"