Home | History | Annotate | Line # | Download | only in public
      1  1.1  cherry /******************************************************************************
      2  1.1  cherry  * features.h
      3  1.1  cherry  *
      4  1.1  cherry  * Feature flags, reported by XENVER_get_features.
      5  1.1  cherry  *
      6  1.1  cherry  * Permission is hereby granted, free of charge, to any person obtaining a copy
      7  1.1  cherry  * of this software and associated documentation files (the "Software"), to
      8  1.1  cherry  * deal in the Software without restriction, including without limitation the
      9  1.1  cherry  * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
     10  1.1  cherry  * sell copies of the Software, and to permit persons to whom the Software is
     11  1.1  cherry  * furnished to do so, subject to the following conditions:
     12  1.1  cherry  *
     13  1.1  cherry  * The above copyright notice and this permission notice shall be included in
     14  1.1  cherry  * all copies or substantial portions of the Software.
     15  1.1  cherry  *
     16  1.1  cherry  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
     17  1.1  cherry  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
     18  1.1  cherry  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
     19  1.1  cherry  * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
     20  1.1  cherry  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
     21  1.1  cherry  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
     22  1.1  cherry  * DEALINGS IN THE SOFTWARE.
     23  1.1  cherry  *
     24  1.1  cherry  * Copyright (c) 2006, Keir Fraser <keir (at) xensource.com>
     25  1.1  cherry  */
     26  1.1  cherry 
     27  1.1  cherry #ifndef __XEN_PUBLIC_FEATURES_H__
     28  1.1  cherry #define __XEN_PUBLIC_FEATURES_H__
     29  1.1  cherry 
     30  1.1  cherry /*
     31  1.1  cherry  * `incontents 200 elfnotes_features XEN_ELFNOTE_FEATURES
     32  1.1  cherry  *
     33  1.1  cherry  * The list of all the features the guest supports. They are set by
     34  1.1  cherry  * parsing the XEN_ELFNOTE_FEATURES and XEN_ELFNOTE_SUPPORTED_FEATURES
     35  1.1  cherry  * string. The format is the  feature names (as given here without the
     36  1.1  cherry  * "XENFEAT_" prefix) separated by '|' characters.
     37  1.1  cherry  * If a feature is required for the kernel to function then the feature name
     38  1.1  cherry  * must be preceded by a '!' character.
     39  1.1  cherry  *
     40  1.1  cherry  * Note that if XEN_ELFNOTE_SUPPORTED_FEATURES is used, then in the
     41  1.1  cherry  * XENFEAT_dom0 MUST be set if the guest is to be booted as dom0,
     42  1.1  cherry  */
     43  1.1  cherry 
     44  1.1  cherry /*
     45  1.1  cherry  * If set, the guest does not need to write-protect its pagetables, and can
     46  1.1  cherry  * update them via direct writes.
     47  1.1  cherry  */
     48  1.1  cherry #define XENFEAT_writable_page_tables       0
     49  1.1  cherry 
     50  1.1  cherry /*
     51  1.1  cherry  * If set, the guest does not need to write-protect its segment descriptor
     52  1.1  cherry  * tables, and can update them via direct writes.
     53  1.1  cherry  */
     54  1.1  cherry #define XENFEAT_writable_descriptor_tables 1
     55  1.1  cherry 
     56  1.1  cherry /*
     57  1.1  cherry  * If set, translation between the guest's 'pseudo-physical' address space
     58  1.1  cherry  * and the host's machine address space are handled by the hypervisor. In this
     59  1.1  cherry  * mode the guest does not need to perform phys-to/from-machine translations
     60  1.1  cherry  * when performing page table operations.
     61  1.1  cherry  */
     62  1.1  cherry #define XENFEAT_auto_translated_physmap    2
     63  1.1  cherry 
     64  1.1  cherry /* If set, the guest is running in supervisor mode (e.g., x86 ring 0). */
     65  1.1  cherry #define XENFEAT_supervisor_mode_kernel     3
     66  1.1  cherry 
     67  1.1  cherry /*
     68  1.1  cherry  * If set, the guest does not need to allocate x86 PAE page directories
     69  1.1  cherry  * below 4GB. This flag is usually implied by auto_translated_physmap.
     70  1.1  cherry  */
     71  1.1  cherry #define XENFEAT_pae_pgdir_above_4gb        4
     72  1.1  cherry 
     73  1.1  cherry /* x86: Does this Xen host support the MMU_PT_UPDATE_PRESERVE_AD hypercall? */
     74  1.1  cherry #define XENFEAT_mmu_pt_update_preserve_ad  5
     75  1.1  cherry 
     76  1.1  cherry /* x86: Does this Xen host support the MMU_{CLEAR,COPY}_PAGE hypercall? */
     77  1.1  cherry #define XENFEAT_highmem_assist             6
     78  1.1  cherry 
     79  1.1  cherry /*
     80  1.1  cherry  * If set, GNTTABOP_map_grant_ref honors flags to be placed into guest kernel
     81  1.1  cherry  * available pte bits.
     82  1.1  cherry  */
     83  1.1  cherry #define XENFEAT_gnttab_map_avail_bits      7
     84  1.1  cherry 
     85  1.1  cherry /* x86: Does this Xen host support the HVM callback vector type? */
     86  1.1  cherry #define XENFEAT_hvm_callback_vector        8
     87  1.1  cherry 
     88  1.1  cherry /* x86: pvclock algorithm is safe to use on HVM */
     89  1.1  cherry #define XENFEAT_hvm_safe_pvclock           9
     90  1.1  cherry 
     91  1.1  cherry /* x86: pirq can be used by HVM guests */
     92  1.1  cherry #define XENFEAT_hvm_pirqs                 10
     93  1.1  cherry 
     94  1.1  cherry /* operation as Dom0 is supported */
     95  1.1  cherry #define XENFEAT_dom0                      11
     96  1.1  cherry 
     97  1.1  cherry /* Xen also maps grant references at pfn = mfn.
     98  1.1  cherry  * This feature flag is deprecated and should not be used.
     99  1.1  cherry #define XENFEAT_grant_map_identity        12
    100  1.1  cherry  */
    101  1.1  cherry 
    102  1.1  cherry /* Guest can use XENMEMF_vnode to specify virtual node for memory op. */
    103  1.1  cherry #define XENFEAT_memory_op_vnode_supported 13
    104  1.1  cherry 
    105  1.1  cherry /* arm: Hypervisor supports ARM SMC calling convention. */
    106  1.1  cherry #define XENFEAT_ARM_SMCCC_supported       14
    107  1.1  cherry 
    108  1.1  cherry /*
    109  1.1  cherry  * x86/PVH: If set, ACPI RSDP can be placed at any address. Otherwise RSDP
    110  1.1  cherry  * must be located in lower 1MB, as required by ACPI Specification for IA-PC
    111  1.1  cherry  * systems.
    112  1.1  cherry  * This feature flag is only consulted if XEN_ELFNOTE_GUEST_OS contains
    113  1.1  cherry  * the "linux" string.
    114  1.1  cherry  */
    115  1.1  cherry #define XENFEAT_linux_rsdp_unrestricted   15
    116  1.1  cherry 
    117  1.1  cherry #define XENFEAT_NR_SUBMAPS 1
    118  1.1  cherry 
    119  1.1  cherry #endif /* __XEN_PUBLIC_FEATURES_H__ */
    120  1.1  cherry 
    121  1.1  cherry /*
    122  1.1  cherry  * Local variables:
    123  1.1  cherry  * mode: C
    124  1.1  cherry  * c-file-style: "BSD"
    125  1.1  cherry  * c-basic-offset: 4
    126  1.1  cherry  * tab-width: 4
    127  1.1  cherry  * indent-tabs-mode: nil
    128  1.1  cherry  * End:
    129  1.1  cherry  */
    130