From mboxrd@z Thu Jan 1 00:00:00 1970 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 4B1CAC04A95 for ; Tue, 25 Oct 2022 10:39:37 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D6DB28E0002; Tue, 25 Oct 2022 06:39:36 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id D1D708E0001; Tue, 25 Oct 2022 06:39:36 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id BE5258E0002; Tue, 25 Oct 2022 06:39:36 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id ABC938E0001 for ; Tue, 25 Oct 2022 06:39:36 -0400 (EDT) Received: from smtpin25.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 8395F1C6677 for ; Tue, 25 Oct 2022 10:39:36 +0000 (UTC) X-FDA: 80059125552.25.A3D61A0 Received: from mail.skyhub.de (mail.skyhub.de [5.9.137.197]) by imf26.hostedemail.com (Postfix) with ESMTP id E5EB514001D for ; Tue, 25 Oct 2022 10:39:35 +0000 (UTC) Received: from zn.tnic (p200300ea9733e753329c23fffea6a903.dip0.t-ipconnect.de [IPv6:2003:ea:9733:e753:329c:23ff:fea6:a903]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 77F211EC04CB; Tue, 25 Oct 2022 12:39:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1666694374; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=bJEdtbRqgdbjhqUqDGLu9oDkYSzHvDi/vH6BXxoFAh8=; b=JxIF5aD8t+drPh0XyHi/aIDkukRMN7v+nUHqpoC0kztFZF/DC3CYHhIjv8G0wKaXyWcgJ2 NJswHW8qF/0qgkCUBTscjqoybTkfq7npVh1L77t2FH8Z+j9aYvMn2i6v+EnvcLXRHTv8xn 0ypbB4muvtXV4mgjUbabEqF3ztjeN8Y= Date: Tue, 25 Oct 2022 12:39:34 +0200 From: Borislav Petkov To: Eric DeVolder Cc: Oscar Salvador , Andrew Morton , david@redhat.com, linux-kernel@vger.kernel.org, x86@kernel.org, kexec@lists.infradead.org, ebiederm@xmission.com, dyoung@redhat.com, bhe@redhat.com, vgoyal@redhat.com, tglx@linutronix.de, mingo@redhat.com, dave.hansen@linux.intel.com, hpa@zytor.com, nramas@linux.microsoft.com, thomas.lendacky@amd.com, robh@kernel.org, efault@gmx.de, rppt@kernel.org, sourabhjain@linux.ibm.com, linux-mm@kvack.org Subject: Re: [PATCH v12 7/7] x86/crash: Add x86 crash hotplug support Message-ID: References: <20220909210509.6286-1-eric.devolder@oracle.com> <20220909210509.6286-8-eric.devolder@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1666694376; 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-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=bJEdtbRqgdbjhqUqDGLu9oDkYSzHvDi/vH6BXxoFAh8=; b=rU2te86h/38pXFSIg8dxHBev/ituDRsFIEdXOviFK2kXHjpsuZfKd8uApaQa+vFi0NrV2T aE9u0f58UQ/GWGGjnUQ88VFMq5yMlNRhBn/ja8AKDCyV0pgI7x3+qiw2GTy5gJtSKd4MI8 rOQkodltHD9vXi/hobMFqWFbOur8Yv0= ARC-Authentication-Results: i=1; imf26.hostedemail.com; dkim=pass header.d=alien8.de header.s=dkim header.b=JxIF5aD8; spf=pass (imf26.hostedemail.com: domain of bp@alien8.de designates 5.9.137.197 as permitted sender) smtp.mailfrom=bp@alien8.de; dmarc=pass (policy=none) header.from=alien8.de ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1666694376; a=rsa-sha256; cv=none; b=LDiGz8qCL92wlMCvkT6hjS/IoqQj85lCTZ+pKMive9V3fOaBo1pwmsBtKNMEQYR+AZlBrX 5uq6C70lrB1bxWMT34YZ6QZ7eXCXz/zB+PkObT2/RgqcAauMmPvT7vb8lqFuhEcY2E7jJy 17b4v+K11AiHvmuF3zXV5jrC6VMVgSI= Authentication-Results: imf26.hostedemail.com; dkim=pass header.d=alien8.de header.s=dkim header.b=JxIF5aD8; spf=pass (imf26.hostedemail.com: domain of bp@alien8.de designates 5.9.137.197 as permitted sender) smtp.mailfrom=bp@alien8.de; dmarc=pass (policy=none) header.from=alien8.de X-Stat-Signature: njxm51tp8ypos351k6q97tun4geg6crq X-Rspamd-Queue-Id: E5EB514001D X-Rspamd-Server: rspam07 X-Rspam-User: X-HE-Tag: 1666694375-625232 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 Wed, Oct 12, 2022 at 11:20:59AM -0500, Eric DeVolder wrote: > I once had CONFIG_CRASH_HOTPLUG, but you disagreed. > > https://lore.kernel.org/lkml/Ylgot+LUDQl+G%2F5N@zn.tnic/ > > From there I simply went with > > #if defined(CONFIG_HOTPLUG_CPU) || defined(CONFIG_MEMORY_HOTPLUG) > > which route do you prefer? If you do a single Kconfig item which depends on those two, it probably is cleaner this way. And if the max memory ranges are hardcoded you don't need the other prompt asking the user something she most likely doesn't know how to answer properly. That is, unless you wanna have that crash hotplug built in all the time. Because CONFIG_HOTPLUG_CPU is pretty much always enabled so you might just as well add the crash hotplug support unconditionally, without any Kconfig ifdeffery whatsoever except CONFIG_MEMORY_HOTPLUG as that is special and not present on the majority of hardware. But on a plain simple laptop or workstation which has CPU hotplug, would it make sense for the crash ranges to get updated too when CPUs are offlined? If so, I think you want this code present there too, without a Kconfig item. If this is server-only anyway, then a single Kconfig item sounds like not such a bad idea. I hope that makes some sense. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette