WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

[Xen-ia64-devel] [patch 3/3] Set alternate location for /proc/iomem on i

To: xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-ia64-devel] [patch 3/3] Set alternate location for /proc/iomem on ia64 xen
From: Simon Horman <horms@xxxxxxxxxxxx>
Date: Wed, 12 Sep 2007 17:35:29 +0900
Delivery-date: Wed, 12 Sep 2007 01:45:50 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20070912083526.966413830@xxxxxxxxxxxx>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: quilt/0.46-1
Use /proc/iomem_machine for ia64 xen where pysical and machine efi maps
differ.  Without this kexec gets a very jaded view of the world, and
/proc/vmcore after a kdump will only have a partial memory dump. Requires a
companion patch to kexec-tools.

Signed-off-by: Simon Horman <horms@xxxxxxxxxxxx>


Index: kexec-tools-unstable/kexec/arch/ia64/kexec-iomem.c
===================================================================
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
+++ kexec-tools-unstable/kexec/arch/ia64/kexec-iomem.c  2007-05-09 
17:02:53.000000000 +0900
@@ -0,0 +1,21 @@
+#include <stdint.h>
+#include <stdio.h>
+#include "../../kexec.h"
+#include "../../crashdump.h"
+
+static const char proc_iomem_str[]= "/proc/iomem";
+static const char proc_iomem_machine_str[]= "/proc/iomem_machine";
+
+/*
+ * On IA64 XEN the EFI tables are virtualised and this
+ * /proc/iomem is too far from the truth to be useful to kexec.
+ * For this reason on such systems /proc/iomem_machine is provided,
+ * which is based on the hypervisor's (machine's) EFI tables.
+ */
+const char *proc_iomem(void)
+{
+       if (xen_present())
+               return proc_iomem_machine_str;
+        return proc_iomem_str;
+}
+
Index: kexec-tools-unstable/kexec/arch/ia64/Makefile
===================================================================
--- kexec-tools-unstable.orig/kexec/arch/ia64/Makefile  2007-05-09 
16:56:10.000000000 +0900
+++ kexec-tools-unstable/kexec/arch/ia64/Makefile       2007-05-09 
16:56:38.000000000 +0900
@@ -1,6 +1,7 @@
 #
 # kexec ia64 (linux booting linux)
 #
+KEXEC_C_SRCS+= kexec/arch/ia64/kexec-iomem.c
 KEXEC_C_SRCS+= kexec/arch/ia64/kexec-ia64.c 
 KEXEC_C_SRCS+= kexec/arch/ia64/kexec-elf-ia64.c 
 KEXEC_C_SRCS+= kexec/arch/ia64/kexec-elf-rel-ia64.c

-- 

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


_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel

<Prev in Thread] Current Thread [Next in Thread>