From mboxrd@z Thu Jan 1 00:00:00 1970 From: Palmer Dabbelt Subject: [PATCH 08/13] Move MAX_SHARED_LIBS to fs/binfmt_flat.c Date: Tue, 3 Nov 2015 11:46:29 -0800 Message-ID: <1446579994-9937-9-git-send-email-palmer@dabbelt.com> References: <1442271047-4908-1-git-send-email-palmer@dabbelt.com> <1446579994-9937-1-git-send-email-palmer@dabbelt.com> Return-path: In-Reply-To: <1446579994-9937-1-git-send-email-palmer@dabbelt.com> Sender: linux-kernel-owner@vger.kernel.org To: arnd@arndb.de, dhowells@redhat.com Cc: viro@zeniv.linux.org.uk, ast@plumgrid.com, aishchuk@linux.vnet.ibm.com, aarcange@redhat.com, akpm@linux-foundation.org, luto@kernel.org, acme@kernel.org, bhe@redhat.com, 3chas3@gmail.com, chris@zankel.net, dave@sr71.net, dyoung@redhat.com, drysdale@google.com, davem@davemloft.net, ebiederm@xmission.com, geoff@infradead.org, gregkh@linuxfoundation.org, hpa@zytor.com, mingo@kernel.org, iulia.manda21@gmail.com, plagnioj@jcrosoft.com, jikos@kernel.org, josh@joshtriplett.org, kexec@lists.infradead.org, linux-api@vger.kernel.org, linux-arch@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-xtensa@linux-xtensa.org, mathieu.desnoyers@efficios.com, jcmvbkbc@gmail.com, paulmck@linux.vnet.ibm.com, a.p.zijlstra@chello.nl, tglx@linutronix.de, tomi.valkeinen@ti.com, vgoyal@redhat.com, x86@kernel.org, Palmer Dabbelt List-Id: linux-arch.vger.kernel.org I'm not sure what this is, but it doesn't feel like something that should be exposed to userspace here. I'm assuming this file was exposed for the structure in it, which doesn't depend on MAX_SHARED_LIBS. Signed-off-by: Palmer Dabbelt Reviewed-by: Andrew Waterman Reviewed-by: Albert Ou --- fs/binfmt_flat.c | 6 ++++++ include/uapi/linux/flat.h | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/binfmt_flat.c b/fs/binfmt_flat.c index f723cd3..e89fb43 100644 --- a/fs/binfmt_flat.c +++ b/fs/binfmt_flat.c @@ -72,6 +72,12 @@ #define RELOC_FAILED 0xff00ff01 /* Relocation incorrect somewhere */ #define UNLOADED_LIB 0x7ff000ff /* Placeholder for unused library */ +#ifdef CONFIG_BINFMT_SHARED_FLAT +#define MAX_SHARED_LIBS (4) +#else +#define MAX_SHARED_LIBS (1) +#endif + struct lib_info { struct { unsigned long start_code; /* Start of text segment */ diff --git a/include/uapi/linux/flat.h b/include/uapi/linux/flat.h index 88cd6ba..1b177c7 100644 --- a/include/uapi/linux/flat.h +++ b/include/uapi/linux/flat.h @@ -13,12 +13,6 @@ #define FLAT_VERSION 0x00000004L -#ifdef CONFIG_BINFMT_SHARED_FLAT -#define MAX_SHARED_LIBS (4) -#else -#define MAX_SHARED_LIBS (1) -#endif - /* * To make everything easier to port and manage cross platform * development, all fields are in network byte order. -- 2.4.10 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pa0-f43.google.com ([209.85.220.43]:34460 "EHLO mail-pa0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932498AbbKCTq4 (ORCPT ); Tue, 3 Nov 2015 14:46:56 -0500 Received: by padhx2 with SMTP id hx2so19311260pad.1 for ; Tue, 03 Nov 2015 11:46:56 -0800 (PST) From: Palmer Dabbelt Subject: [PATCH 08/13] Move MAX_SHARED_LIBS to fs/binfmt_flat.c Date: Tue, 3 Nov 2015 11:46:29 -0800 Message-ID: <1446579994-9937-9-git-send-email-palmer@dabbelt.com> In-Reply-To: <1446579994-9937-1-git-send-email-palmer@dabbelt.com> References: <1442271047-4908-1-git-send-email-palmer@dabbelt.com> <1446579994-9937-1-git-send-email-palmer@dabbelt.com> Sender: linux-arch-owner@vger.kernel.org List-ID: To: arnd@arndb.de, dhowells@redhat.com Cc: viro@zeniv.linux.org.uk, ast@plumgrid.com, aishchuk@linux.vnet.ibm.com, aarcange@redhat.com, akpm@linux-foundation.org, luto@kernel.org, acme@kernel.org, bhe@redhat.com, 3chas3@gmail.com, chris@zankel.net, dave@sr71.net, dyoung@redhat.com, drysdale@google.com, davem@davemloft.net, ebiederm@xmission.com, geoff@infradead.org, gregkh@linuxfoundation.org, hpa@zytor.com, mingo@kernel.org, iulia.manda21@gmail.com, plagnioj@jcrosoft.com, jikos@kernel.org, josh@joshtriplett.org, kexec@lists.infradead.org, linux-api@vger.kernel.org, linux-arch@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-xtensa@linux-xtensa.org, mathieu.desnoyers@efficios.com, jcmvbkbc@gmail.com, paulmck@linux.vnet.ibm.com, a.p.zijlstra@chello.nl, tglx@linutronix.de, tomi.valkeinen@ti.com, vgoyal@redhat.com, x86@kernel.org, Palmer Dabbelt Message-ID: <20151103194629.AYXu1Gk-S_uGddh5PpJEBMZzMB1O3o5VfNyDSelt51U@z> I'm not sure what this is, but it doesn't feel like something that should be exposed to userspace here. I'm assuming this file was exposed for the structure in it, which doesn't depend on MAX_SHARED_LIBS. Signed-off-by: Palmer Dabbelt Reviewed-by: Andrew Waterman Reviewed-by: Albert Ou --- fs/binfmt_flat.c | 6 ++++++ include/uapi/linux/flat.h | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/binfmt_flat.c b/fs/binfmt_flat.c index f723cd3..e89fb43 100644 --- a/fs/binfmt_flat.c +++ b/fs/binfmt_flat.c @@ -72,6 +72,12 @@ #define RELOC_FAILED 0xff00ff01 /* Relocation incorrect somewhere */ #define UNLOADED_LIB 0x7ff000ff /* Placeholder for unused library */ +#ifdef CONFIG_BINFMT_SHARED_FLAT +#define MAX_SHARED_LIBS (4) +#else +#define MAX_SHARED_LIBS (1) +#endif + struct lib_info { struct { unsigned long start_code; /* Start of text segment */ diff --git a/include/uapi/linux/flat.h b/include/uapi/linux/flat.h index 88cd6ba..1b177c7 100644 --- a/include/uapi/linux/flat.h +++ b/include/uapi/linux/flat.h @@ -13,12 +13,6 @@ #define FLAT_VERSION 0x00000004L -#ifdef CONFIG_BINFMT_SHARED_FLAT -#define MAX_SHARED_LIBS (4) -#else -#define MAX_SHARED_LIBS (1) -#endif - /* * To make everything easier to port and manage cross platform * development, all fields are in network byte order. -- 2.4.10