summaryrefslogtreecommitdiff
path: root/arch/sparc/kernel/kernel.h
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2011-08-02 10:27:17 +0400
committerDavid S. Miller <davem@davemloft.net>2011-08-03 08:28:52 +0400
commitea5e7447ea9d555558e0f13798f5143dd51a915a (patch)
treed444f3edbe02b4dddbc958a78b962a96e703d9ca /arch/sparc/kernel/kernel.h
parente2eb9f8158ead43a88c0f0b4d74257b1be938a18 (diff)
downloadlinux-ea5e7447ea9d555558e0f13798f5143dd51a915a.tar.xz
sparc: Set reboot-cmd using reboot data hypervisor call if available.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/kernel.h')
-rw-r--r--arch/sparc/kernel/kernel.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/sparc/kernel/kernel.h b/arch/sparc/kernel/kernel.h
index 8325d7759381..fd6c36b1df74 100644
--- a/arch/sparc/kernel/kernel.h
+++ b/arch/sparc/kernel/kernel.h
@@ -4,6 +4,8 @@
#include <linux/interrupt.h>
#include <asm/traps.h>
+#include <asm/head.h>
+#include <asm/io.h>
/* cpu.c */
extern const char *sparc_pmu_type;
@@ -14,6 +16,13 @@ extern int ncpus_probed;
/* setup_64.c */
struct seq_file;
extern void cpucap_info(struct seq_file *);
+
+static inline unsigned long kimage_addr_to_ra(const char *p)
+{
+ unsigned long val = (unsigned long) p;
+
+ return kern_base + (val - KERNBASE);
+}
#endif
#ifdef CONFIG_SPARC32