Skip to content

Commit a445d98

Browse files
Christoph HellwigGreg Ungerer
authored andcommitted
binfmt_flat: move the MAX_SHARED_LIBS definition to binfmt_flat.c
MAX_SHARED_LIBS is an implementation detail of the kernel loader, and should be kept away from the file format definition. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Greg Ungerer <gerg@linux-m68k.org>
1 parent 6843d8a commit a445d98

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

fs/binfmt_flat.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,12 @@
6868
#define RELOC_FAILED 0xff00ff01 /* Relocation incorrect somewhere */
6969
#define UNLOADED_LIB 0x7ff000ff /* Placeholder for unused library */
7070

71+
#ifdef CONFIG_BINFMT_SHARED_FLAT
72+
#define MAX_SHARED_LIBS (4)
73+
#else
74+
#define MAX_SHARED_LIBS (1)
75+
#endif
76+
7177
struct lib_info {
7278
struct {
7379
unsigned long start_code; /* Start of text segment */

include/linux/flat.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,6 @@
1212

1313
#define FLAT_VERSION 0x00000004L
1414

15-
#ifdef CONFIG_BINFMT_SHARED_FLAT
16-
#define MAX_SHARED_LIBS (4)
17-
#else
18-
#define MAX_SHARED_LIBS (1)
19-
#endif
20-
2115
/*
2216
* To make everything easier to port and manage cross platform
2317
* development, all fields are in network byte order.

0 commit comments

Comments
 (0)