[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [RFC PATCH V5 04/14] xen: sync public headers
Stay in sync with Xen public headers: * event_channel.h: * EVTCHNOP_query_extended_abis * EVTCHNOP_register_3level * xen.h: * NR_EVENT_CHANNEL* EVTCHNOP_query_extended_aibs is pretty self-explanatory. Other structure and macro definitions belong to the 3-level event channel ABI. Signed-off-by: Wei Liu <wei.liu2@xxxxxxxxxx> --- include/xen/interface/event_channel.h | 45 +++++++++++++++++++++++++++++++++ include/xen/interface/xen.h | 13 +++++++++- 2 files changed, 57 insertions(+), 1 deletion(-) diff --git a/include/xen/interface/event_channel.h b/include/xen/interface/event_channel.h index 293c3f0..155454e 100644 --- a/include/xen/interface/event_channel.h +++ b/include/xen/interface/event_channel.h @@ -189,6 +189,51 @@ struct evtchn_reset { domid_t dom; }; +/* + * EVTCHNOP_query_extended_abis: Query the hypervisor for supported extended + * event channel ABIs. + */ +#define EVTCHNOP_query_extended_abis 11 +#define EVTCHN_EXTENDED_NONE 0 +#define _EVTCHN_EXTENDED_L3 1 +#define EVTCHN_EXTENDED_L3 (1UL << _EVTCHN_EXTENDED_L3) +struct evtchn_query_extended_abis { + /* OUT parameters. */ + uint64_t abis; +}; + +/* + * EVTCHNOP_register_3level: Register 3-level event channel. + */ +#define EVTCHNOP_register_3level 12 +/* + * 64 bits guests need 8 pages for evtchn_pending and evtchn_mask for 256k + * event channels while 32 bits ones only need 1 page for 32k event channels. + */ +#define EVTCHN_MAX_L3_PAGES 8 +/* + * A guest should register the bitmaps first, then register L2 selector for + * individual cpu. + */ +#define REGISTER_BITMAPS 1 +#define REGISTER_L2_SELECTOR 2 +struct evtchn_register_3level { + /* IN parameters. */ + uint32_t cmd; + union { + struct { + uint32_t nr_pages; + GUEST_HANDLE(xen_pfn_t) evtchn_pending; + GUEST_HANDLE(xen_pfn_t) evtchn_mask; + } bitmaps; + struct { + uint32_t cpu_id; + xen_pfn_t mfn; /* mfn for L2 selector */ + xen_pfn_t offset; /* offset of L2 selector */ + } l2_selector; + } u; +}; + struct evtchn_op { uint32_t cmd; /* EVTCHNOP_* */ union { diff --git a/include/xen/interface/xen.h b/include/xen/interface/xen.h index 53ec416..9b0248d 100644 --- a/include/xen/interface/xen.h +++ b/include/xen/interface/xen.h @@ -283,9 +283,20 @@ DEFINE_GUEST_HANDLE_STRUCT(multicall_entry); /* * Event channel endpoints per domain: + * 2-level for x86: * 1024 if a long is 32 bits; 4096 if a long is 64 bits. + * 3-level for x86: + * 32k if a long is 32 bits; 256k if a long is 64 bits. + * 2-level for ARM: + * 4096 for both 32 bits and 64 bits. + * 3-level for ARM: + * 256k for both 32 bits and 64 bits. */ -#define NR_EVENT_CHANNELS (sizeof(xen_ulong_t) * sizeof(xen_ulong_t) * 64) +#define NR_EVENT_CHANNELS_L2 (sizeof(xen_ulong_t) * sizeof(xen_ulong_t) * 64) +#define NR_EVENT_CHANNELS_L3 (NR_EVENT_CHANNELS_L2 * sizeof(xen_ulong_t) * 8) +#if !defined(__XEN__) && !defined(__XEN_TOOLS__) +#define NR_EVENT_CHANNELS NR_EVENT_CHANNELS_L2 /* for compatibility */ +#endif struct vcpu_time_info { /* -- 1.7.10.4 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |