The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/xen/interface/elfnote.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /******************************************************************************
    2  * elfnote.h
    3  *
    4  * Definitions used for the Xen ELF notes.
    5  *
    6  * Permission is hereby granted, free of charge, to any person obtaining a copy
    7  * of this software and associated documentation files (the "Software"), to
    8  * deal in the Software without restriction, including without limitation the
    9  * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
   10  * sell copies of the Software, and to permit persons to whom the Software is
   11  * furnished to do so, subject to the following conditions:
   12  *
   13  * The above copyright notice and this permission notice shall be included in
   14  * all copies or substantial portions of the Software.
   15  *
   16  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
   17  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
   18  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
   19  * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
   20  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
   21  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
   22  * DEALINGS IN THE SOFTWARE.
   23  *
   24  * Copyright (c) 2006, Ian Campbell, XenSource Ltd.
   25  */
   26 
   27 #ifndef __XEN_PUBLIC_ELFNOTE_H__
   28 #define __XEN_PUBLIC_ELFNOTE_H__
   29 
   30 /*
   31  * The notes should live in a PT_NOTE segment and have "Xen" in the
   32  * name field.
   33  *
   34  * Numeric types are either 4 or 8 bytes depending on the content of
   35  * the desc field.
   36  *
   37  * LEGACY indicated the fields in the legacy __xen_guest string which
   38  * this a note type replaces.
   39  */
   40 
   41 /*
   42  * NAME=VALUE pair (string).
   43  */
   44 #define XEN_ELFNOTE_INFO           0
   45 
   46 /*
   47  * The virtual address of the entry point (numeric).
   48  *
   49  * LEGACY: VIRT_ENTRY
   50  */
   51 #define XEN_ELFNOTE_ENTRY          1
   52 
   53 /* The virtual address of the hypercall transfer page (numeric).
   54  *
   55  * LEGACY: HYPERCALL_PAGE. (n.b. legacy value is a physical page
   56  * number not a virtual address)
   57  */
   58 #define XEN_ELFNOTE_HYPERCALL_PAGE 2
   59 
   60 /* The virtual address where the kernel image should be mapped (numeric).
   61  *
   62  * Defaults to 0.
   63  *
   64  * LEGACY: VIRT_BASE
   65  */
   66 #define XEN_ELFNOTE_VIRT_BASE      3
   67 
   68 /*
   69  * The offset of the ELF paddr field from the acutal required
   70  * psuedo-physical address (numeric).
   71  *
   72  * This is used to maintain backwards compatibility with older kernels
   73  * which wrote __PAGE_OFFSET into that field. This field defaults to 0
   74  * if not present.
   75  *
   76  * LEGACY: ELF_PADDR_OFFSET. (n.b. legacy default is VIRT_BASE)
   77  */
   78 #define XEN_ELFNOTE_PADDR_OFFSET   4
   79 
   80 /*
   81  * The version of Xen that we work with (string).
   82  *
   83  * LEGACY: XEN_VER
   84  */
   85 #define XEN_ELFNOTE_XEN_VERSION    5
   86 
   87 /*
   88  * The name of the guest operating system (string).
   89  *
   90  * LEGACY: GUEST_OS
   91  */
   92 #define XEN_ELFNOTE_GUEST_OS       6
   93 
   94 /*
   95  * The version of the guest operating system (string).
   96  *
   97  * LEGACY: GUEST_VER
   98  */
   99 #define XEN_ELFNOTE_GUEST_VERSION  7
  100 
  101 /*
  102  * The loader type (string).
  103  *
  104  * LEGACY: LOADER
  105  */
  106 #define XEN_ELFNOTE_LOADER         8
  107 
  108 /*
  109  * The kernel supports PAE (x86/32 only, string = "yes", "no" or
  110  * "bimodal").
  111  *
  112  * For compatibility with Xen 3.0.3 and earlier the "bimodal" setting
  113  * may be given as "yes,bimodal" which will cause older Xen to treat
  114  * this kernel as PAE.
  115  *
  116  * LEGACY: PAE (n.b. The legacy interface included a provision to
  117  * indicate 'extended-cr3' support allowing L3 page tables to be
  118  * placed above 4G. It is assumed that any kernel new enough to use
  119  * these ELF notes will include this and therefore "yes" here is
  120  * equivalent to "yes[entended-cr3]" in the __xen_guest interface.
  121  */
  122 #define XEN_ELFNOTE_PAE_MODE       9
  123 
  124 /*
  125  * The features supported/required by this kernel (string).
  126  *
  127  * The string must consist of a list of feature names (as given in
  128  * features.h, without the "XENFEAT_" prefix) separated by '|'
  129  * characters. If a feature is required for the kernel to function
  130  * then the feature name must be preceded by a '!' character.
  131  *
  132  * LEGACY: FEATURES
  133  */
  134 #define XEN_ELFNOTE_FEATURES      10
  135 
  136 /*
  137  * The kernel requires the symbol table to be loaded (string = "yes" or "no")
  138  * LEGACY: BSD_SYMTAB (n.b. The legacy treated the presence or absence
  139  * of this string as a boolean flag rather than requiring "yes" or
  140  * "no".
  141  */
  142 #define XEN_ELFNOTE_BSD_SYMTAB    11
  143 
  144 /*
  145  * The lowest address the hypervisor hole can begin at (numeric).
  146  *
  147  * This must not be set higher than HYPERVISOR_VIRT_START. Its presence
  148  * also indicates to the hypervisor that the kernel can deal with the
  149  * hole starting at a higher address.
  150  */
  151 #define XEN_ELFNOTE_HV_START_LOW  12
  152 
  153 /*
  154  * List of maddr_t-sized mask/value pairs describing how to recognize
  155  * (non-present) L1 page table entries carrying valid MFNs (numeric).
  156  */
  157 #define XEN_ELFNOTE_L1_MFN_VALID  13
  158 
  159 /*
  160  * Whether or not the guest supports cooperative suspend cancellation.
  161  */
  162 #define XEN_ELFNOTE_SUSPEND_CANCEL 14
  163 
  164 /*
  165  * The (non-default) location the initial phys-to-machine map should be
  166  * placed at by the hypervisor (Dom0) or the tools (DomU).
  167  * The kernel must be prepared for this mapping to be established using
  168  * large pages, despite such otherwise not being available to guests.
  169  * The kernel must also be able to handle the page table pages used for
  170  * this mapping not being accessible through the initial mapping.
  171  * (Only x86-64 supports this at present.)
  172  */
  173 #define XEN_ELFNOTE_INIT_P2M      15
  174 
  175 /*
  176  * Whether or not the guest can deal with being passed an initrd not
  177  * mapped through its initial page tables.
  178  */
  179 #define XEN_ELFNOTE_MOD_START_PFN 16
  180 
  181 /*
  182  * The features supported by this kernel (numeric).
  183  *
  184  * Other than XEN_ELFNOTE_FEATURES on pre-4.2 Xen, this note allows a
  185  * kernel to specify support for features that older hypervisors don't
  186  * know about. The set of features 4.2 and newer hypervisors will
  187  * consider supported by the kernel is the combination of the sets
  188  * specified through this and the string note.
  189  *
  190  * LEGACY: FEATURES
  191  */
  192 #define XEN_ELFNOTE_SUPPORTED_FEATURES 17
  193 
  194 /*
  195  * The number of the highest elfnote defined.
  196  */
  197 #define XEN_ELFNOTE_MAX XEN_ELFNOTE_SUPPORTED_FEATURES
  198 
  199 /*
  200  * System information exported through crash notes.
  201  *
  202  * The kexec / kdump code will create one XEN_ELFNOTE_CRASH_INFO 
  203  * note in case of a system crash. This note will contain various
  204  * information about the system, see xen/include/xen/elfcore.h.
  205  */
  206 #define XEN_ELFNOTE_CRASH_INFO 0x1000001
  207 
  208 /*
  209  * System registers exported through crash notes.
  210  *
  211  * The kexec / kdump code will create one XEN_ELFNOTE_CRASH_REGS 
  212  * note per cpu in case of a system crash. This note is architecture
  213  * specific and will contain registers not saved in the "CORE" note.
  214  * See xen/include/xen/elfcore.h for more information.
  215  */
  216 #define XEN_ELFNOTE_CRASH_REGS 0x1000002
  217 
  218 
  219 /*
  220  * xen dump-core none note.
  221  * xm dump-core code will create one XEN_ELFNOTE_DUMPCORE_NONE
  222  * in its dump file to indicate that the file is xen dump-core
  223  * file. This note doesn't have any other information.
  224  * See tools/libxc/xc_core.h for more information.
  225  */
  226 #define XEN_ELFNOTE_DUMPCORE_NONE               0x2000000
  227 
  228 /*
  229  * xen dump-core header note.
  230  * xm dump-core code will create one XEN_ELFNOTE_DUMPCORE_HEADER
  231  * in its dump file.
  232  * See tools/libxc/xc_core.h for more information.
  233  */
  234 #define XEN_ELFNOTE_DUMPCORE_HEADER             0x2000001
  235 
  236 /*
  237  * xen dump-core xen version note.
  238  * xm dump-core code will create one XEN_ELFNOTE_DUMPCORE_XEN_VERSION
  239  * in its dump file. It contains the xen version obtained via the
  240  * XENVER hypercall.
  241  * See tools/libxc/xc_core.h for more information.
  242  */
  243 #define XEN_ELFNOTE_DUMPCORE_XEN_VERSION        0x2000002
  244 
  245 /*
  246  * xen dump-core format version note.
  247  * xm dump-core code will create one XEN_ELFNOTE_DUMPCORE_FORMAT_VERSION
  248  * in its dump file. It contains a format version identifier.
  249  * See tools/libxc/xc_core.h for more information.
  250  */
  251 #define XEN_ELFNOTE_DUMPCORE_FORMAT_VERSION     0x2000003
  252 
  253 #endif /* __XEN_PUBLIC_ELFNOTE_H__ */
  254 
  255 /*
  256  * Local variables:
  257  * mode: C
  258  * c-set-style: "BSD"
  259  * c-basic-offset: 4
  260  * tab-width: 4
  261  * indent-tabs-mode: nil
  262  * End:
  263  */

Cache object: 29bd8c5cfa1b0ae601aa207a20aebbe9


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.