[patch] Obtain PAGE_OFFSET from running kernel

From: Horms <horms_at_verge.net.au>
Date: 2006-10-06 14:11:17
Currently the page offset is hard coded to 0xe000000000000000UL
at compile time of kexec-tools. This patch changes things around
so the page offset is handed to purgatory by the kexecing kernel.

Note that this changes the ABI between purgatory (part of kexec-tools)
and the kernel kexec code. There is an accomanying kexec-tools patch.

Signed-Off-By: Simon Horman <horms@verge.net.au>

Index: kexec-ia64-2.6/arch/ia64/kernel/relocate_kernel.S
===================================================================
--- kexec-ia64-2.6.orig/arch/ia64/kernel/relocate_kernel.S	2006-10-05 11:56:24.000000000 +0900
+++ kexec-ia64-2.6/arch/ia64/kernel/relocate_kernel.S	2006-10-05 11:57:24.000000000 +0900
@@ -22,7 +22,7 @@
 */
 GLOBAL_ENTRY(relocate_new_kernel)
 	.prologue
-	alloc r31=ar.pfs,4,0,0,0
+	alloc r31=ar.pfs,4,0,1,0
 	.body
 .reloc_entry:
 {
@@ -180,6 +180,7 @@
 	;;
 	srlz.d
 	;;
+	movl out0=PAGE_OFFSET;;
 	br.call.sptk.many b0=b6;;
 
 .align 32

--

-- 
Horms
  H: http://www.vergenet.net/~horms/
  W: http://www.valinux.co.jp/en/

-
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Received on Fri Oct 06 14:59:37 2006

This archive was generated by hypermail 2.1.8 : 2006-10-06 15:05:19 EST