summaryrefslogtreecommitdiff
path: root/kexec
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2010-09-07 11:42:39 -0700
committerEric W. Biederman <ebiederm@xmission.com>2010-09-08 11:02:29 -0700
commitd9bf000b6260ee4558b2d2eb3af08e09cd1fe794 (patch)
tree95d619af3a1e1841b96e76a309b46b4c6d611331 /kexec
parent3578b1f1437f8d1b569d1e30f6d4e15edd1cce53 (diff)
kexec: Kill arch_init
The function only had one user, the error checking was wrong, and the functions it performed are best done elsewhere so remove the tempation of a problemenatic hook. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Diffstat (limited to 'kexec')
-rw-r--r--kexec/Makefile2
-rw-r--r--kexec/arch/x86_64/Makefile4
-rw-r--r--kexec/arch/x86_64/arch_init.c12
-rw-r--r--kexec/arch_init.c4
-rw-r--r--kexec/kexec.c2
-rw-r--r--kexec/kexec.h2
6 files changed, 1 insertions, 25 deletions
diff --git a/kexec/Makefile b/kexec/Makefile
index 5d7b618..2137cab 100644
--- a/kexec/Makefile
+++ b/kexec/Makefile
@@ -48,8 +48,6 @@ $(ARCH)_ADD_BUFFER = kexec/add_buffer.c
KEXEC_SRCS += $($(ARCH)_ADD_BUFFER)
$(ARCH)_ARCH_REUSE_INITRD = kexec/arch_reuse_initrd.c
KEXEC_SRCS += $($(ARCH)_ARCH_REUSE_INITRD)
-$(ARCH)_ARCH_INIT = kexec/arch_init.c
-KEXEC_SRCS += $($(ARCH)_ARCH_INIT)
include $(srcdir)/kexec/arch/alpha/Makefile
include $(srcdir)/kexec/arch/arm/Makefile
diff --git a/kexec/arch/x86_64/Makefile b/kexec/arch/x86_64/Makefile
index 0f35a46..c9a708a 100644
--- a/kexec/arch/x86_64/Makefile
+++ b/kexec/arch/x86_64/Makefile
@@ -13,8 +13,6 @@ x86_64_KEXEC_SRCS += kexec/arch/x86_64/kexec-x86_64.c
x86_64_KEXEC_SRCS += kexec/arch/x86_64/kexec-elf-x86_64.c
x86_64_KEXEC_SRCS += kexec/arch/x86_64/kexec-elf-rel-x86_64.c
-x86_64_ARCH_INIT = kexec/arch/x86_64/arch_init.c
-
-dist += kexec/arch/x86_64/Makefile $(x86_64_KEXEC_SRCS) $(x86_64_ARCH_INIT) \
+dist += kexec/arch/x86_64/Makefile $(x86_64_KEXEC_SRCS) \
kexec/arch/x86_64/kexec-x86_64.h kexec/arch/x86_64/crashdump-x86_64.h \
kexec/arch/x86_64/include/arch/options.h
diff --git a/kexec/arch/x86_64/arch_init.c b/kexec/arch/x86_64/arch_init.c
deleted file mode 100644
index bebb92d..0000000
--- a/kexec/arch/x86_64/arch_init.c
+++ /dev/null
@@ -1,12 +0,0 @@
-#include "../../kexec.h"
-#include <errno.h>
-#include <string.h>
-#include <sys/utsname.h>
-#include <stdlib.h>
-#include <limits.h>
-#include <stdio.h>
-
-int arch_init(void)
-{
- return 0;
-}
diff --git a/kexec/arch_init.c b/kexec/arch_init.c
deleted file mode 100644
index afce72f..0000000
--- a/kexec/arch_init.c
+++ /dev/null
@@ -1,4 +0,0 @@
-int arch_init(void)
-{
- return 0;
-}
diff --git a/kexec/kexec.c b/kexec/kexec.c
index 2b5dc42..10ad41d 100644
--- a/kexec/kexec.c
+++ b/kexec/kexec.c
@@ -1062,8 +1062,6 @@ int main(int argc, char *argv[])
};
static const char short_options[] = KEXEC_ALL_OPT_STR;
- arch_init();
-
while ((opt = getopt_long(argc, argv, short_options,
options, 0)) != -1) {
switch(opt) {
diff --git a/kexec/kexec.h b/kexec/kexec.h
index 6909ca1..6a8a345 100644
--- a/kexec/kexec.h
+++ b/kexec/kexec.h
@@ -253,8 +253,6 @@ int kexec_iomem_for_each_line(char *match,
int parse_iomem_single(char *str, uint64_t *start, uint64_t *end);
const char * proc_iomem(void);
-int arch_init(void);
-
extern int add_backup_segments(struct kexec_info *info,
unsigned long backup_base,
unsigned long backup_size);