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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BC0CBC001B3 for ; Mon, 19 Jun 2023 18:22:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232334AbjFSSWp convert rfc822-to-8bit (ORCPT ); Mon, 19 Jun 2023 14:22:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51876 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231918AbjFSSWn (ORCPT ); Mon, 19 Jun 2023 14:22:43 -0400 Received: from outpost1.zedat.fu-berlin.de (outpost1.zedat.fu-berlin.de [130.133.4.66]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D2079118; Mon, 19 Jun 2023 11:22:38 -0700 (PDT) Received: from inpost2.zedat.fu-berlin.de ([130.133.4.69]) by outpost.zedat.fu-berlin.de (Exim 4.95) with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (envelope-from ) id 1qBJVV-000Ryh-FD; Mon, 19 Jun 2023 20:21:41 +0200 Received: from p57bd9486.dip0.t-ipconnect.de ([87.189.148.134] helo=[192.168.178.81]) by inpost2.zedat.fu-berlin.de (Exim 4.95) with esmtpsa (TLS1.3) tls TLS_AES_256_GCM_SHA384 (envelope-from ) id 1qBJVV-000OlA-36; Mon, 19 Jun 2023 20:21:41 +0200 Message-ID: <5c66d9a869e24e795ae242598935eddfea095730.camel@physik.fu-berlin.de> Subject: Re: [PATCH v2 13/13] sh/kexec: refactor for kernel/Kconfig.kexec From: John Paul Adrian Glaubitz To: Eric DeVolder , linux@armlinux.org.uk, catalin.marinas@arm.com, will@kernel.org, chenhuacai@kernel.org, geert@linux-m68k.org, tsbogend@alpha.franken.de, James.Bottomley@HansenPartnership.com, deller@gmx.de, ysato@users.sourceforge.jp, dalias@libc.org, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, x86@kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-ia64@vger.kernel.org, loongarch@lists.linux.dev, linux-m68k@lists.linux-m68k.org, linux-mips@vger.kernel.org, linux-parisc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, linux-sh@vger.kernel.org Cc: kernel@xen0n.name, mpe@ellerman.id.au, npiggin@gmail.com, christophe.leroy@csgroup.eu, paul.walmsley@sifive.com, palmer@dabbelt.com, aou@eecs.berkeley.edu, hca@linux.ibm.com, gor@linux.ibm.com, agordeev@linux.ibm.com, borntraeger@linux.ibm.com, svens@linux.ibm.com, hpa@zytor.com, keescook@chromium.org, paulmck@kernel.org, peterz@infradead.org, frederic@kernel.org, akpm@linux-foundation.org, ardb@kernel.org, samitolvanen@google.com, juerg.haefliger@canonical.com, arnd@arndb.de, rmk+kernel@armlinux.org.uk, linus.walleij@linaro.org, sebastian.reichel@collabora.com, rppt@kernel.org, kirill.shutemov@linux.intel.com, anshuman.khandual@arm.com, ziy@nvidia.com, masahiroy@kernel.org, ndesaulniers@google.com, mhiramat@kernel.org, ojeda@kernel.org, thunder.leizhen@huawei.com, xin3.li@intel.com, tj@kernel.org, gregkh@linuxfoundation.org, tsi@tuyoix.net, bhe@redhat.com, hbathini@linux.ibm.com, sourabhjain@linux.ibm.com, boris.ostrovsky@oracle.com, konrad.wilk@oracle.com Date: Mon, 19 Jun 2023 20:21:38 +0200 In-Reply-To: <20230619145801.1064716-14-eric.devolder@oracle.com> References: <20230619145801.1064716-1-eric.devolder@oracle.com> <20230619145801.1064716-14-eric.devolder@oracle.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT User-Agent: Evolution 3.48.3 MIME-Version: 1.0 X-Original-Sender: glaubitz@physik.fu-berlin.de X-Originating-IP: 87.189.148.134 X-ZEDAT-Hint: PO Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Eric! On Mon, 2023-06-19 at 10:58 -0400, Eric DeVolder wrote: > The kexec and crash kernel options are provided in the common > kernel/Kconfig.kexec. Utilize the common options and provide > the ARCH_SUPPORTS_ and ARCH_SELECTS_ entries to recreate the > equivalent set of KEXEC and CRASH options. > > Signed-off-by: Eric DeVolder > --- > arch/sh/Kconfig | 46 ++++++++-------------------------------------- > 1 file changed, 8 insertions(+), 38 deletions(-) > > diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig > index 9652d367fc37..d52e0beed7e9 100644 > --- a/arch/sh/Kconfig > +++ b/arch/sh/Kconfig > @@ -546,44 +546,14 @@ menu "Kernel features" > > source "kernel/Kconfig.hz" > > -config KEXEC > - bool "kexec system call (EXPERIMENTAL)" > - depends on MMU > - select KEXEC_CORE > - help > - kexec is a system call that implements the ability to shutdown your > - current kernel, and to start another kernel. It is like a reboot > - but it is independent of the system firmware. And like a reboot > - you can start any kernel with it, not just Linux. > - > - The name comes from the similarity to the exec system call. > - > - It is an ongoing process to be certain the hardware in a machine > - is properly shutdown, so do not be surprised if this code does not > - initially work for you. As of this writing the exact hardware > - interface is strongly in flux, so no good recommendation can be > - made. > - > -config CRASH_DUMP > - bool "kernel crash dumps (EXPERIMENTAL)" > - depends on BROKEN_ON_SMP > - help > - Generate crash dump after being started by kexec. > - This should be normally only set in special crash dump kernels > - which are loaded in the main kernel with kexec-tools into > - a specially reserved region and then later executed after > - a crash by kdump/kexec. The crash dump kernel must be compiled > - to a memory address not used by the main kernel using > - PHYSICAL_START. > - > - For more details see Documentation/admin-guide/kdump/kdump.rst > - > -config KEXEC_JUMP > - bool "kexec jump (EXPERIMENTAL)" > - depends on KEXEC && HIBERNATION > - help > - Jump between original kernel and kexeced kernel and invoke > - code via KEXEC > +config ARCH_SUPPORTS_KEXEC > + def_bool MMU > + > +config ARCH_SUPPORTS_CRASH_DUMP > + def_bool BROKEN_ON_SMP > + > +config ARCH_SUPPORTS_KEXEC_JUMP > + def_bool y > > config PHYSICAL_START > hex "Physical address where the kernel is loaded" if (EXPERT || CRASH_DUMP) Acked-by: John Paul Adrian Glaubitz -- .''`. John Paul Adrian Glaubitz : :' : Debian Developer `. `' Physicist `- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913