aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2007-05-14 15:59:09 +0900
committerPaul Mundt <lethal@hera.kernel.org>2007-06-08 02:43:37 +0000
commit9655ad03af2d232c3b26e7562ab4f8c29b107e49 (patch)
tree6a76057e969ca072e7ca9bdf253219e759054d3f /include
parente08f457c7c0cc7720f28349f8780ea752c063441 (diff)
sh: Fixup machvec support.
This fixes up much of the machvec handling, allowing for it to be overloaded on boot. Making practical use of this still requires some Kconfig munging, however. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'include')
-rw-r--r--include/asm-sh/machvec_init.h34
-rw-r--r--include/asm-sh/sections.h2
-rw-r--r--include/asm-sh/setup.h1
3 files changed, 3 insertions, 34 deletions
diff --git a/include/asm-sh/machvec_init.h b/include/asm-sh/machvec_init.h
index e397798ebd9..88a973edcf1 100644
--- a/include/asm-sh/machvec_init.h
+++ b/include/asm-sh/machvec_init.h
@@ -12,42 +12,8 @@
#ifndef __SH_MACHVEC_INIT_H
#define __SH_MACHVEC_INIT_H
-
-/*
- * In a GENERIC kernel, we have lots of these vectors floating about,
- * all but one of which we want to go away. In a non-GENERIC kernel,
- * we want only one, ever.
- *
- * Accomplish this in the GENERIC kernel by puting all of the vectors
- * in the .init.data section where they'll go away. We'll copy the
- * one we want to the real alpha_mv vector in setup_arch.
- *
- * Accomplish this in a non-GENERIC kernel by ifdef'ing out all but
- * one of the vectors, which will not reside in .init.data. We then
- * alias this one vector to alpha_mv, so no copy is needed.
- *
- * Upshot: set __initdata to nothing for non-GENERIC kernels.
- *
- * Note we do the same thing for the UNKNOWN kernel, as we need to write
- * to the machine vector while setting it up.
- */
-
-#if defined(CONFIG_SH_GENERIC) || defined(CONFIG_SH_UNKNOWN)
#define __initmv __attribute__((unused,__section__ (".machvec.init")))
-#define ALIAS_MV(x)
-#else
-#define __initmv
-
-/* GCC actually has a syntax for defining aliases, but is under some
- delusion that you shouldn't be able to declare it extern somewhere
- else beforehand. Fine. We'll do it ourselves. */
-#if 0
-#define ALIAS_MV(system) \
- struct sh_machine_vector sh_mv __attribute__((alias("mv_"#system)));
-#else
#define ALIAS_MV(system) \
asm(".global sh_mv\nsh_mv = mv_"#system );
-#endif
-#endif /* GENERIC */
#endif /* __SH_MACHVEC_INIT_H */
diff --git a/include/asm-sh/sections.h b/include/asm-sh/sections.h
index 44c06c09e20..2a696b8ee4f 100644
--- a/include/asm-sh/sections.h
+++ b/include/asm-sh/sections.h
@@ -3,5 +3,7 @@
#include <asm-generic/sections.h>
+extern long __machvec_start, __machvec_end;
+
#endif /* __ASM_SH_SECTIONS_H */
diff --git a/include/asm-sh/setup.h b/include/asm-sh/setup.h
index 1583c6b7bda..586a9711a75 100644
--- a/include/asm-sh/setup.h
+++ b/include/asm-sh/setup.h
@@ -6,6 +6,7 @@
#ifdef __KERNEL__
int setup_early_printk(char *);
+void sh_mv_setup(void);
#endif /* __KERNEL__ */