ia64/xen-unstable

view xen/include/xen/elfcore.h @ 17761:439a3e9459f2

Add xen_phys_start value in the crash info note

This patch makes the vmcore utilities (ex. crash, makedumpfile) be
able to get the relocation address of the xen hypervisor from a
vmcore. It is necessary for the utilities to find the data of the
hypervisor structures.

Note that this patch does not raise any comptibility issue for the
utilities (which I know) nor the other components of xen.

Signed-off-by: Itsuro Oda <oda@valinux.co.jp>
author Keir Fraser <keir.fraser@citrix.com>
date Fri May 30 16:04:20 2008 +0100 (2008-05-30)
parents d7c3b12014b3
children
line source
1 /******************************************************************************
2 * elfcore.h
3 *
4 * Based heavily on include/linux/elfcore.h from Linux 2.6.16
5 * Naming scheeme based on include/xen/elf.h (not include/linux/elfcore.h)
6 *
7 */
9 #ifndef __ELFCOREC_H__
10 #define __ELFCOREC_H__
12 #include <xen/types.h>
13 #include <xen/elf.h>
14 #include <asm/elf.h>
15 #include <public/xen.h>
17 #define NT_PRSTATUS 1
19 typedef struct
20 {
21 int signo; /* signal number */
22 int code; /* extra code */
23 int errno; /* errno */
24 } ELF_Signifo;
26 /* These seem to be the same length on all architectures on Linux */
27 typedef int ELF_Pid;
28 typedef struct {
29 long tv_sec;
30 long tv_usec;
31 } ELF_Timeval;
33 /*
34 * Definitions to generate Intel SVR4-like core files.
35 * These mostly have the same names as the SVR4 types with "elf_"
36 * tacked on the front to prevent clashes with linux definitions,
37 * and the typedef forms have been avoided. This is mostly like
38 * the SVR4 structure, but more Linuxy, with things that Linux does
39 * not support and which gdb doesn't really use excluded.
40 */
41 typedef struct
42 {
43 ELF_Signifo pr_info; /* Info associated with signal */
44 short pr_cursig; /* Current signal */
45 unsigned long pr_sigpend; /* Set of pending signals */
46 unsigned long pr_sighold; /* Set of held signals */
47 ELF_Pid pr_pid;
48 ELF_Pid pr_ppid;
49 ELF_Pid pr_pgrp;
50 ELF_Pid pr_sid;
51 ELF_Timeval pr_utime; /* User time */
52 ELF_Timeval pr_stime; /* System time */
53 ELF_Timeval pr_cutime; /* Cumulative user time */
54 ELF_Timeval pr_cstime; /* Cumulative system time */
55 ELF_Gregset pr_reg; /* GP registers - from asm header file */
56 int pr_fpvalid; /* True if math co-processor being used. */
57 } ELF_Prstatus;
59 typedef struct {
60 unsigned long xen_major_version;
61 unsigned long xen_minor_version;
62 unsigned long xen_extra_version;
63 unsigned long xen_changeset;
64 unsigned long xen_compiler;
65 unsigned long xen_compile_date;
66 unsigned long xen_compile_time;
67 unsigned long tainted;
68 #if defined(__i386__) || defined(__x86_64__)
69 unsigned long xen_phys_start;
70 unsigned long dom0_pfn_to_mfn_frame_list_list;
71 #endif
72 #if defined(__ia64__)
73 unsigned long dom0_mm_pgd_mfn;
74 #endif
75 } crash_xen_info_t;
77 #endif /* __ELFCOREC_H__ */
79 /*
80 * Local variables:
81 * mode: C
82 * c-set-style: "BSD"
83 * c-basic-offset: 4
84 * tab-width: 4
85 * indent-tabs-mode: nil
86 * End:
87 */