6 #define CONFIG_X86_32 1
12 #define CONFIG_X86_64 1
16 #if defined(__i386__) || defined (__x86_64__)
42 * This program is free software; you can redistribute it and/or modify
43 * it under the terms of the GNU General Public License, version 2, as
44 * published by the Free Software Foundation.
46 * This program is distributed in the hope that it will be useful,
47 * but WITHOUT ANY WARRANTY; without even the implied warranty of
48 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
49 * GNU General Public License for more details.
51 * You should have received a copy of the GNU General Public License
52 * along with this program; if not, write to the Free Software
53 * Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
55 * Copyright IBM Corp. 2008
57 * Authors: Hollis Blanchard <hollisb@us.ibm.com>
60 #ifndef __POWERPC_KVM_ASM_H__
61 #define __POWERPC_KVM_ASM_H__
63 /* IVPR must be 64KiB-aligned. */
64 #define VCPU_SIZE_ORDER 4
65 #define VCPU_SIZE_LOG (VCPU_SIZE_ORDER + 12)
66 #define VCPU_TLB_PGSZ PPC44x_TLB_64K
67 #define VCPU_SIZE_BYTES (1<<VCPU_SIZE_LOG)
69 #define BOOKE_INTERRUPT_CRITICAL 0
70 #define BOOKE_INTERRUPT_MACHINE_CHECK 1
71 #define BOOKE_INTERRUPT_DATA_STORAGE 2
72 #define BOOKE_INTERRUPT_INST_STORAGE 3
73 #define BOOKE_INTERRUPT_EXTERNAL 4
74 #define BOOKE_INTERRUPT_ALIGNMENT 5
75 #define BOOKE_INTERRUPT_PROGRAM 6
76 #define BOOKE_INTERRUPT_FP_UNAVAIL 7
77 #define BOOKE_INTERRUPT_SYSCALL 8
78 #define BOOKE_INTERRUPT_AP_UNAVAIL 9
79 #define BOOKE_INTERRUPT_DECREMENTER 10
80 #define BOOKE_INTERRUPT_FIT 11
81 #define BOOKE_INTERRUPT_WATCHDOG 12
82 #define BOOKE_INTERRUPT_DTLB_MISS 13
83 #define BOOKE_INTERRUPT_ITLB_MISS 14
84 #define BOOKE_INTERRUPT_DEBUG 15
87 #define BOOKE_INTERRUPT_SPE_UNAVAIL 32
88 #define BOOKE_INTERRUPT_SPE_FP_DATA 33
89 #define BOOKE_INTERRUPT_SPE_FP_ROUND 34
90 #define BOOKE_INTERRUPT_PERFORMANCE_MONITOR 35
92 #define RESUME_FLAG_NV (1<<0) /* Reload guest nonvolatile state? */
93 #define RESUME_FLAG_HOST (1<<1) /* Resume host? */
95 #define RESUME_GUEST 0
96 #define RESUME_GUEST_NV RESUME_FLAG_NV
97 #define RESUME_HOST RESUME_FLAG_HOST
98 #define RESUME_HOST_NV (RESUME_FLAG_HOST|RESUME_FLAG_NV)
100 #endif /* __POWERPC_KVM_ASM_H__ */