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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 061EFC433EF for ; Tue, 15 Feb 2022 17:41:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=fr8Pdj1Vtl33i2NG8iSp7Db8oTDHjXU4401EGbBDhZs=; b=RITp8TwfaCIfuq W2fz1sq1BE3/ic0iU7t+8bOUvdJNQVslq272T7ASpHFVgtaijspKqYUan0w65GzeAXJMT0t/F2DbN 0vCr6I684cVNUfEglfLKeYgwofmXH2tBjeabL960Swy509bsap9oVlz/zUfxQS86bI1xzzDy2/Zmh Zu/ErhIx2pk7bg8Eyhd0hYOuLPbSmU2KA+SJ+OpbZoF1ywawPMD/+RAoXQQVJBWqq0kjH1ob5K0Fs 3e7TzkUsmbfbv1JIVwWGaPW66MxtAgzRtKAaxwCjnS02rPKtVdlf6vfLPsTk8dAGFjU/GUJ0l+Wdx HiDctHm9SHeza6ozX5pg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nK1nj-003whY-BK; Tue, 15 Feb 2022 17:39:43 +0000 Received: from ams.source.kernel.org ([2604:1380:4601:e00::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nK1ne-003wgf-QO for linux-arm-kernel@lists.infradead.org; Tue, 15 Feb 2022 17:39:40 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 7361CB81BE4; Tue, 15 Feb 2022 17:39:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A4B73C340EB; Tue, 15 Feb 2022 17:39:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1644946776; bh=2tHi7kZbaBoOjuEb6MF9QuaDcCVYybeRUwQ1nG1qfss=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=cAfz/czYIPEedqNiyG6xiYVPTr0YJ38rLCJMajc/JfUWL10llGo3/KDQuB/Lz2/iy xadHevzpnqwfHHun345sWAbq6wueKMptP5TILMwGmTKnO80tXgT2mo5WBLnTO6/iLF dmi7rntZEN5tZDB4mUo6rO1sJKx7XEjuU+QbvGMBCAIgaDV3bwShtMK/eq3tAX+Jg4 7WpNPxyXtPGL95LGsrsnR+i6mTSp1wh5jJ8rJ7FQ9HeMs/JNtYZVw19oeGjs20Osqr wbXPeaRA9QIZxvwyhb8VLjNe9PVcMvBsEgvFgPyxKZ0UYgTXIQPMpivfxNBv04mD/F qlboqAYNUPX6g== Date: Tue, 15 Feb 2022 17:39:30 +0000 From: Will Deacon To: Catalin Marinas Cc: linux-arm-kernel@lists.infradead.org, Luis Machado , John Baldwin , Arnd Bergmann , "Eric W. Biederman" , Szabolcs Nagy , Andrew Morton Subject: Re: [PATCH v2 1/5] elfcore: Replace CONFIG_{IA64,UML} checks with a new option Message-ID: <20220215173930.GA8706@willie-the-truck> References: <20220131165456.2160675-1-catalin.marinas@arm.com> <20220131165456.2160675-2-catalin.marinas@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220131165456.2160675-2-catalin.marinas@arm.com> User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220215_093939_166652_8F74B62B X-CRM114-Status: GOOD ( 21.35 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Jan 31, 2022 at 04:54:52PM +0000, Catalin Marinas wrote: > As arm64 is about to introduce MTE-specific phdrs in the core dump, add > a common CONFIG_ARCH_BINFMT_ELF_EXTRA_PHDRS option currently selectable > by UML_X86 and IA64. > > Signed-off-by: Catalin Marinas > Cc: Eric Biederman > --- > arch/ia64/Kconfig | 1 + > arch/x86/um/Kconfig | 1 + > fs/Kconfig.binfmt | 3 +++ > include/linux/elfcore.h | 4 ++-- > 4 files changed, 7 insertions(+), 2 deletions(-) > > diff --git a/arch/ia64/Kconfig b/arch/ia64/Kconfig > index a7e01573abd8..e003b2473c64 100644 > --- a/arch/ia64/Kconfig > +++ b/arch/ia64/Kconfig > @@ -8,6 +8,7 @@ menu "Processor type and features" > > config IA64 > bool > + select ARCH_BINFMT_ELF_EXTRA_PHDRS > select ARCH_HAS_DMA_MARK_CLEAN > select ARCH_HAS_STRNCPY_FROM_USER > select ARCH_HAS_STRNLEN_USER > diff --git a/arch/x86/um/Kconfig b/arch/x86/um/Kconfig > index 40d6a06e41c8..ead7e5b3a975 100644 > --- a/arch/x86/um/Kconfig > +++ b/arch/x86/um/Kconfig > @@ -8,6 +8,7 @@ endmenu > > config UML_X86 > def_bool y > + select ARCH_BINFMT_ELF_EXTRA_PHDRS if X86_32 > > config 64BIT > bool "64-bit kernel" if "$(SUBARCH)" = "x86" > diff --git a/fs/Kconfig.binfmt b/fs/Kconfig.binfmt > index 4d5ae61580aa..68e586283764 100644 > --- a/fs/Kconfig.binfmt > +++ b/fs/Kconfig.binfmt > @@ -36,6 +36,9 @@ config COMPAT_BINFMT_ELF > config ARCH_BINFMT_ELF_STATE > bool > > +config ARCH_BINFMT_ELF_EXTRA_PHDRS > + bool > + > config ARCH_HAVE_ELF_PROT > bool > > diff --git a/include/linux/elfcore.h b/include/linux/elfcore.h > index 746e081879a5..b02d5fc711db 100644 > --- a/include/linux/elfcore.h > +++ b/include/linux/elfcore.h > @@ -114,7 +114,7 @@ static inline int elf_core_copy_task_fpregs(struct task_struct *t, struct pt_reg > #endif > } > > -#if (defined(CONFIG_UML) && defined(CONFIG_X86_32)) || defined(CONFIG_IA64) > +#ifdef CONFIG_ARCH_BINFMT_ELF_EXTRA_PHDRS > /* > * These functions parameterize elf_core_dump in fs/binfmt_elf.c to write out > * extra segments containing the gate DSO contents. Dumping its > @@ -149,6 +149,6 @@ static inline size_t elf_core_extra_data_size(void) > { > return 0; > } > -#endif > +#endif /* CONFIG_ARCH_EXTRA_PHDRS */ nit: closing comment doesn't match the name of the new Kconfig symbol. I'll fix that and put the series into -next. Will _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel