debuggers.hg
changeset 11274:7ca72a1c4182
[XEN] Define the types to be used with Xen in the ELF notes section.
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
author | Ian Campbell <ian.campbell@xensource.com> |
---|---|
date | Wed Aug 23 14:36:09 2006 +0100 (2006-08-23) |
parents | 62b7b5f3029f |
children | d57b174adfd6 |
files | xen/include/public/elfnote.h |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/xen/include/public/elfnote.h Wed Aug 23 14:36:09 2006 +0100 1.3 @@ -0,0 +1,133 @@ 1.4 +/****************************************************************************** 1.5 + * elfnote.h 1.6 + * 1.7 + * Definitions used for the Xen ELF notes. 1.8 + * 1.9 + * Copyright (c) 2006, Ian Campbell, XenSource Ltd. 1.10 + */ 1.11 + 1.12 +#ifndef __XEN_PUBLIC_ELFNOTE_H__ 1.13 +#define __XEN_PUBLIC_ELFNOTE_H__ 1.14 + 1.15 +/* 1.16 + * The notes should live in a SHT_NOTE segment and have "Xen" in the 1.17 + * name field. 1.18 + * 1.19 + * Numeric types are either 4 or 8 bytes depending on the content of 1.20 + * the desc field. 1.21 + * 1.22 + * LEGACY indicated the fields in the legacy __xen_guest string which 1.23 + * this a note type replaces. 1.24 + */ 1.25 + 1.26 +/* 1.27 + * NAME=VALUE pair (string). 1.28 + * 1.29 + * LEGACY: FEATURES and PAE 1.30 + */ 1.31 +#define XEN_ELFNOTE_INFO 0 1.32 + 1.33 +/* 1.34 + * The virtual address of the entry point (numeric). 1.35 + * 1.36 + * LEGACY: VIRT_ENTRY 1.37 + */ 1.38 +#define XEN_ELFNOTE_ENTRY 1 1.39 + 1.40 +/* The virtual address of the hypercall transfer page (numeric). 1.41 + * 1.42 + * LEGACY: HYPERCALL_PAGE. (n.b. legacy value is a physical page 1.43 + * number not a virtual address) 1.44 + */ 1.45 +#define XEN_ELFNOTE_HYPERCALL_PAGE 2 1.46 + 1.47 +/* The virtual address where the kernel image should be mapped (numeric). 1.48 + * 1.49 + * Defaults to 0. 1.50 + * 1.51 + * LEGACY: VIRT_BASE 1.52 + */ 1.53 +#define XEN_ELFNOTE_VIRT_BASE 3 1.54 + 1.55 +/* 1.56 + * The offset of the ELF paddr field from the acutal required 1.57 + * psuedo-physical address (numeric). 1.58 + * 1.59 + * This is used to maintain backwards compatibility with older kernels 1.60 + * which wrote __PAGE_OFFSET into that field. This field defaults to 0 1.61 + * if not present. 1.62 + * 1.63 + * LEGACY: ELF_PADDR_OFFSET. (n.b. legacy default is VIRT_BASE) 1.64 + */ 1.65 +#define XEN_ELFNOTE_PADDR_OFFSET 4 1.66 + 1.67 +/* 1.68 + * The version of Xen that we work with (string). 1.69 + * 1.70 + * LEGACY: XEN_VER 1.71 + */ 1.72 +#define XEN_ELFNOTE_XEN_VERSION 5 1.73 + 1.74 +/* 1.75 + * The name of the guest operating system (string). 1.76 + * 1.77 + * LEGACY: GUEST_OS 1.78 + */ 1.79 +#define XEN_ELFNOTE_GUEST_OS 6 1.80 + 1.81 +/* 1.82 + * The version of the guest operating system (string). 1.83 + * 1.84 + * LEGACY: GUEST_VER 1.85 + */ 1.86 +#define XEN_ELFNOTE_GUEST_VERSION 7 1.87 + 1.88 +/* 1.89 + * The loader type (string). 1.90 + * 1.91 + * LEGACY: LOADER 1.92 + */ 1.93 +#define XEN_ELFNOTE_LOADER 8 1.94 + 1.95 +/* 1.96 + * The kernel supports PAE (x86/32 only, string = "yes" or "no"). 1.97 + * 1.98 + * LEGACY: PAE (n.b. The legacy interface included a provision to 1.99 + * indicate 'extended-cr3' support allowing L3 page tables to be 1.100 + * placed above 4G. It is assumed that any kernel new enough to use 1.101 + * these ELF notes will include this and therefore "yes" here is 1.102 + * equivalent to "yes[entended-cr3]" in the __xen_guest interface. 1.103 + */ 1.104 +#define XEN_ELFNOTE_PAE_MODE 9 1.105 + 1.106 +/* 1.107 + * The features supported/required by this kernel (string). 1.108 + * 1.109 + * The string must consist of a list of feature names (as given in 1.110 + * features.h, without the "XENFEAT_" prefix) separated by '|' 1.111 + * characters. If a feature is required for the kernel to function 1.112 + * then the feature name must be preceded by a '!' character. 1.113 + * 1.114 + * LEGACY: FEATURES 1.115 + */ 1.116 +#define XEN_ELFNOTE_FEATURES 10 1.117 + 1.118 +/* 1.119 + * The kernel requires the symbol table to be loaded (string = "yes" or "no") 1.120 + * LEGACY: BSD_SYMTAB (n.b. The legacy treated the presence or absence 1.121 + * of this string as a boolean flag rather than requiring "yes" or 1.122 + * "no". 1.123 + */ 1.124 +#define XEN_ELFNOTE_BSD_SYMTAB 11 1.125 + 1.126 +#endif /* __XEN_PUBLIC_ELFNOTE_H__ */ 1.127 + 1.128 +/* 1.129 + * Local variables: 1.130 + * mode: C 1.131 + * c-set-style: "BSD" 1.132 + * c-basic-offset: 4 1.133 + * tab-width: 4 1.134 + * indent-tabs-mode: nil 1.135 + * End: 1.136 + */