2
* vmx_platform.h: VMX platform support
3
* Copyright (c) 2004, Intel Corporation.
5
* This program is free software; you can redistribute it and/or modify it
6
* under the terms and conditions of the GNU General Public License,
7
* version 2, as published by the Free Software Foundation.
9
* This program is distributed in the hope it will be useful, but WITHOUT
10
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14
* You should have received a copy of the GNU General Public License along with
15
* this program; if not, write to the Free Software Foundation, Inc., 59 Temple
16
* Place - Suite 330, Boston, MA 02111-1307 USA.
19
#ifndef __ASM_IA64_VMX_PLATFORM_H__
20
#define __ASM_IA64_VMX_PLATFORM_H__
22
#include <public/xen.h>
23
#include <public/hvm/params.h>
24
#include <asm/hvm/irq.h>
25
#include <asm/viosapic.h>
26
#include <asm/hvm/vacpi.h>
27
#include <xen/hvm/iommu.h>
29
struct vmx_ioreq_page {
31
struct page_info *page;
34
int vmx_set_ioreq_page(struct domain *d,
35
struct vmx_ioreq_page *iorp, unsigned long gmfn);
37
typedef struct virtual_platform_def {
38
struct vmx_ioreq_page ioreq;
39
struct vmx_ioreq_page buf_ioreq;
40
struct vmx_ioreq_page buf_pioreq;
41
unsigned long pib_base;
42
unsigned long params[HVM_NR_PARAMS];
43
/* One IOSAPIC now... */
44
struct viosapic viosapic;
46
/* Pass-throgh VT-d */
48
struct hvm_iommu hvm_iommu;
51
static inline int __fls(uint32_t word)
56
__asm__ __volatile__ ("getf.exp %0=%1" : "=r"(exp) : "f"(d));
57
return word ? (exp - 0xffff) : -1;