From patchwork Mon Jul 4 06:41:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Aneesh Kumar K.V" X-Patchwork-Id: 12904749 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1F050CCA479 for ; Mon, 4 Jul 2022 06:41:58 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 8BE058E0001; Mon, 4 Jul 2022 02:41:57 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 86D9E6B0073; Mon, 4 Jul 2022 02:41:57 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 734468E0001; Mon, 4 Jul 2022 02:41:57 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 60DAA6B0072 for ; Mon, 4 Jul 2022 02:41:57 -0400 (EDT) Received: from smtpin12.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 24DF135620 for ; Mon, 4 Jul 2022 06:41:57 +0000 (UTC) X-FDA: 79648472274.12.8BC76AA Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by imf14.hostedemail.com (Postfix) with ESMTP id 693AC100020 for ; Mon, 4 Jul 2022 06:41:56 +0000 (UTC) Received: from pps.filterd (m0127361.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 2646GRdo019337; Mon, 4 Jul 2022 06:41:53 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding; s=pp1; bh=I5EXbKb38ZXBB0N3z9chbigvZr8HTBSxyVhD3AUDyoc=; b=Q+RHPfdvvPq3FgV/HLAUWDv5enIyv2mxPmTea8ubeWnzqYUL3F40HQFfcqJ86GWjN+mf vQqTsdUgz0QStVOuHy+bSnuf2emB6tsv8dKVIng5HmQCKUptwgFXi048EaRz5r9LrvhY 00pnscttRKn99bAvx0P806d93TMayw+yh0QREtneKJteoYEmWk/6LO2TzIxJM/6Zcypz hmw0twJukf+xwIctzWZcqNan0QasOYh7wX+18FvL3dJJttjTlH8aHr5fmq8brGVyLdhC ngwCOldnHyi53KFPRBqW3bN4ZPK570TwdgNKvtKF3TlUlRflcqN64shFyGSVs4HnwIzJ 4w== Received: from ppma04dal.us.ibm.com (7a.29.35a9.ip4.static.sl-reverse.com [169.53.41.122]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3h3tsmgf9b-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 04 Jul 2022 06:41:52 +0000 Received: from pps.filterd (ppma04dal.us.ibm.com [127.0.0.1]) by ppma04dal.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 2646KT1Z020182; Mon, 4 Jul 2022 06:41:52 GMT Received: from b03cxnp07027.gho.boulder.ibm.com (b03cxnp07027.gho.boulder.ibm.com [9.17.130.14]) by ppma04dal.us.ibm.com with ESMTP id 3h2dn9h3xk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 04 Jul 2022 06:41:52 +0000 Received: from b03ledav003.gho.boulder.ibm.com (b03ledav003.gho.boulder.ibm.com [9.17.130.234]) by b03cxnp07027.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 2646fpYl23724502 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 4 Jul 2022 06:41:51 GMT Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 0E8B56A04F; Mon, 4 Jul 2022 06:41:51 +0000 (GMT) Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4FA196A047; Mon, 4 Jul 2022 06:41:48 +0000 (GMT) Received: from skywalker.ibmuc.com (unknown [9.43.74.198]) by b03ledav003.gho.boulder.ibm.com (Postfix) with ESMTP; Mon, 4 Jul 2022 06:41:47 +0000 (GMT) From: "Aneesh Kumar K.V" To: linux-mm@kvack.org, akpm@linux-foundation.org Cc: mpe@ellerman.id.au, linuxppc-dev@lists.ozlabs.org, "Aneesh Kumar K.V" , Michal Hocko Subject: [PATCH v2] mm/add_pages: Move Kconfig variable to mm/Kconfig Date: Mon, 4 Jul 2022 12:11:42 +0530 Message-Id: <20220704064142.296830-1-aneesh.kumar@linux.ibm.com> X-Mailer: git-send-email 2.36.1 MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: 6jt5jq-_Z8T-JmX_8gVeIwLM0AtN2qcc X-Proofpoint-ORIG-GUID: 6jt5jq-_Z8T-JmX_8gVeIwLM0AtN2qcc X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.883,Hydra:6.0.517,FMLib:17.11.122.1 definitions=2022-07-04_05,2022-06-28_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 impostorscore=0 clxscore=1015 malwarescore=0 mlxscore=0 mlxlogscore=883 phishscore=0 suspectscore=0 lowpriorityscore=0 adultscore=0 spamscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2204290000 definitions=main-2207040027 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1656916916; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:references:dkim-signature; bh=I5EXbKb38ZXBB0N3z9chbigvZr8HTBSxyVhD3AUDyoc=; b=hPs/e971P9g7evEVXTlOcfthOiQQo+n8BstXWhJjLHoj200yOzcKs3h93C3RMv50u7/uPG IjaTNalZLomjM6sn1JEFeCPAqtTsCql0tH/JBYlYYsYmnyUPvdwvz7SToKX0cEePBao32A U8Tb1lEWgN8Iqi5kjcOfQXG3am5cI2s= ARC-Authentication-Results: i=1; imf14.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=Q+RHPfdv; spf=pass (imf14.hostedemail.com: domain of aneesh.kumar@linux.ibm.com designates 148.163.158.5 as permitted sender) smtp.mailfrom=aneesh.kumar@linux.ibm.com; dmarc=pass (policy=none) header.from=ibm.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1656916916; a=rsa-sha256; cv=none; b=Xrg0Bb0xspvms13oXbWE9BipbxT/dw1G+L4qEgKi2wSNi4ODtyq2XhQ4HGxgngZfNLUDjN j2dNEEzAZPXr33ko4GiL49COgrPnrXyK3C1f8BV3ZY9+gFZJS0R7332X12swuKFSIXurLQ XjejjBWIF79VRzaQ8kLnFHYXl/K/Guk= X-Stat-Signature: iuc3u3krmg38jkhtrc837cb45j58g7u4 X-Rspamd-Queue-Id: 693AC100020 Authentication-Results: imf14.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=Q+RHPfdv; spf=pass (imf14.hostedemail.com: domain of aneesh.kumar@linux.ibm.com designates 148.163.158.5 as permitted sender) smtp.mailfrom=aneesh.kumar@linux.ibm.com; dmarc=pass (policy=none) header.from=ibm.com X-Rspam-User: X-Rspamd-Server: rspam02 X-HE-Tag: 1656916916-983099 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: No functional change in this patch. This was done so that the previous change (commit ac790d09885d ("powerpc/memhotplug: Add add_pages override for PPC")) can be easily backported. Cc: Michal Hocko Signed-off-by: Aneesh Kumar K.V --- arch/powerpc/Kconfig | 5 +---- arch/x86/Kconfig | 5 +---- mm/Kconfig | 3 +++ 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 7aa12e88c580..20c1f8e26c96 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -112,6 +112,7 @@ config PPC select ARCH_DISABLE_KASAN_INLINE if PPC_RADIX_MMU select ARCH_ENABLE_MEMORY_HOTPLUG select ARCH_ENABLE_MEMORY_HOTREMOVE + select ARCH_HAS_ADD_PAGES if ARCH_ENABLE_MEMORY_HOTPLUG select ARCH_HAS_COPY_MC if PPC64 select ARCH_HAS_CURRENT_STACK_POINTER select ARCH_HAS_DEBUG_VIRTUAL @@ -358,10 +359,6 @@ config ARCH_SUSPEND_NONZERO_CPU def_bool y depends on PPC_POWERNV || PPC_PSERIES -config ARCH_HAS_ADD_PAGES - def_bool y - depends on ARCH_ENABLE_MEMORY_HOTPLUG - config PPC_DCR_NATIVE bool diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index be0b95e51df6..151ddb96ae46 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -68,6 +68,7 @@ config X86 select ARCH_ENABLE_SPLIT_PMD_PTLOCK if (PGTABLE_LEVELS > 2) && (X86_64 || X86_PAE) select ARCH_ENABLE_THP_MIGRATION if X86_64 && TRANSPARENT_HUGEPAGE select ARCH_HAS_ACPI_TABLE_UPGRADE if ACPI + select ARCH_HAS_ADD_PAGES if ARCH_ENABLE_MEMORY_HOTPLUG select ARCH_HAS_CACHE_LINE_SIZE select ARCH_HAS_CURRENT_STACK_POINTER select ARCH_HAS_DEBUG_VIRTUAL @@ -2453,10 +2454,6 @@ source "kernel/livepatch/Kconfig" endmenu -config ARCH_HAS_ADD_PAGES - def_bool y - depends on ARCH_ENABLE_MEMORY_HOTPLUG - config ARCH_MHP_MEMMAP_ON_MEMORY_ENABLE def_bool y diff --git a/mm/Kconfig b/mm/Kconfig index 169e64192e48..af4e3f9a3019 100644 --- a/mm/Kconfig +++ b/mm/Kconfig @@ -475,6 +475,9 @@ config EXCLUSIVE_SYSTEM_RAM config HAVE_BOOTMEM_INFO_NODE def_bool n +config ARCH_HAS_ADD_PAGES + bool + config ARCH_ENABLE_MEMORY_HOTPLUG bool