Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
kvm_book3s.h File Reference
#include <linux/types.h>
#include <linux/kvm_host.h>
#include <asm/kvm_book3s_asm.h>

Go to the source code of this file.

Data Structures

struct  kvmppc_bat
 
struct  kvmppc_sid_map
 
struct  hpte_cache
 
struct  kvmppc_vcpu_book3s
 

Macros

#define SID_MAP_BITS   9
 
#define SID_MAP_NUM   (1 << SID_MAP_BITS)
 
#define SID_MAP_MASK   (SID_MAP_NUM - 1)
 
#define SID_CONTEXTS   128
 
#define VSID_POOL_SIZE   (SID_CONTEXTS * 16)
 
#define CONTEXT_HOST   0
 
#define CONTEXT_GUEST   1
 
#define CONTEXT_GUEST_END   2
 
#define VSID_REAL   0x1fffffffffc00000ULL
 
#define VSID_BAT   0x1fffffffffb00000ULL
 
#define VSID_REAL_DR   0x2000000000000000ULL
 
#define VSID_REAL_IR   0x4000000000000000ULL
 
#define VSID_PR   0x8000000000000000ULL
 
#define OSI_SC_MAGIC_R3   0x113724FA
 
#define OSI_SC_MAGIC_R4   0x77810F9B
 
#define INS_DCBZ   0x7c0007ec
 
#define KVMPPC_NR_LPIDS   (LPID_RSVD + 1)
 

Functions

void kvmppc_mmu_pte_flush (struct kvm_vcpu *vcpu, ulong ea, ulong ea_mask)
 
void kvmppc_mmu_pte_vflush (struct kvm_vcpu *vcpu, u64 vp, u64 vp_mask)
 
void kvmppc_mmu_pte_pflush (struct kvm_vcpu *vcpu, ulong pa_start, ulong pa_end)
 
void kvmppc_set_msr (struct kvm_vcpu *vcpu, u64 new_msr)
 
void kvmppc_set_pvr (struct kvm_vcpu *vcpu, u32 pvr)
 
void kvmppc_mmu_book3s_64_init (struct kvm_vcpu *vcpu)
 
void kvmppc_mmu_book3s_32_init (struct kvm_vcpu *vcpu)
 
void kvmppc_mmu_book3s_hv_init (struct kvm_vcpu *vcpu)
 
int kvmppc_mmu_map_page (struct kvm_vcpu *vcpu, struct kvmppc_pte *pte)
 
int kvmppc_mmu_map_segment (struct kvm_vcpu *vcpu, ulong eaddr)
 
void kvmppc_mmu_flush_segments (struct kvm_vcpu *vcpu)
 
int kvmppc_book3s_hv_page_fault (struct kvm_run *run, struct kvm_vcpu *vcpu, unsigned long addr, unsigned long status)
 
long kvmppc_hv_find_lock_hpte (struct kvm *kvm, gva_t eaddr, unsigned long slb_v, unsigned long valid)
 
void kvmppc_mmu_hpte_cache_map (struct kvm_vcpu *vcpu, struct hpte_cache *pte)
 
struct hpte_cachekvmppc_mmu_hpte_cache_next (struct kvm_vcpu *vcpu)
 
void kvmppc_mmu_hpte_destroy (struct kvm_vcpu *vcpu)
 
int kvmppc_mmu_hpte_init (struct kvm_vcpu *vcpu)
 
void kvmppc_mmu_invalidate_pte (struct kvm_vcpu *vcpu, struct hpte_cache *pte)
 
int kvmppc_mmu_hpte_sysinit (void)
 
void kvmppc_mmu_hpte_sysexit (void)
 
int kvmppc_mmu_hv_init (void)
 
int kvmppc_ld (struct kvm_vcpu *vcpu, ulong *eaddr, int size, void *ptr, bool data)
 
int kvmppc_st (struct kvm_vcpu *vcpu, ulong *eaddr, int size, void *ptr, bool data)
 
void kvmppc_book3s_queue_irqprio (struct kvm_vcpu *vcpu, unsigned int vec)
 
void kvmppc_inject_interrupt (struct kvm_vcpu *vcpu, int vec, u64 flags)
 
void kvmppc_set_bat (struct kvm_vcpu *vcpu, struct kvmppc_bat *bat, bool upper, u32 val)
 
void kvmppc_giveup_ext (struct kvm_vcpu *vcpu, ulong msr)
 
int kvmppc_emulate_paired_single (struct kvm_run *run, struct kvm_vcpu *vcpu)
 
pfn_t kvmppc_gfn_to_pfn (struct kvm_vcpu *vcpu, gfn_t gfn)
 
void kvmppc_add_revmap_chain (struct kvm *kvm, struct revmap_entry *rev, unsigned long *rmap, long pte_index, int realmode)
 
void kvmppc_invalidate_hpte (struct kvm *kvm, unsigned long *hptep, unsigned long pte_index)
 
void kvmppc_clear_ref_hpte (struct kvm *kvm, unsigned long *hptep, unsigned long pte_index)
 
voidkvmppc_pin_guest_page (struct kvm *kvm, unsigned long addr, unsigned long *nb_ret)
 
void kvmppc_unpin_guest_page (struct kvm *kvm, void *addr)
 
long kvmppc_virtmode_h_enter (struct kvm_vcpu *vcpu, unsigned long flags, long pte_index, unsigned long pteh, unsigned long ptel)
 
long kvmppc_h_enter (struct kvm_vcpu *vcpu, unsigned long flags, long pte_index, unsigned long pteh, unsigned long ptel)
 
long kvmppc_hv_get_dirty_log (struct kvm *kvm, struct kvm_memory_slot *memslot)
 
void kvmppc_entry_trampoline (void)
 
void kvmppc_hv_entry_trampoline (void)
 
void kvmppc_load_up_fpu (void)
 
void kvmppc_load_up_altivec (void)
 
void kvmppc_load_up_vsx (void)
 
u32 kvmppc_alignment_dsisr (struct kvm_vcpu *vcpu, unsigned int inst)
 
ulong kvmppc_alignment_dar (struct kvm_vcpu *vcpu, unsigned int inst)
 
int kvmppc_h_pr (struct kvm_vcpu *vcpu, unsigned long cmd)
 
void kvm_return_point (void)
 

Macro Definition Documentation

#define CONTEXT_GUEST   1

Definition at line 105 of file kvm_book3s.h.

#define CONTEXT_GUEST_END   2

Definition at line 106 of file kvm_book3s.h.

#define CONTEXT_HOST   0

Definition at line 104 of file kvm_book3s.h.

#define INS_DCBZ   0x7c0007ec

Definition at line 454 of file kvm_book3s.h.

#define KVMPPC_NR_LPIDS   (LPID_RSVD + 1)

Definition at line 457 of file kvm_book3s.h.

#define OSI_SC_MAGIC_R3   0x113724FA

Definition at line 451 of file kvm_book3s.h.

#define OSI_SC_MAGIC_R4   0x77810F9B

Definition at line 452 of file kvm_book3s.h.

#define SID_CONTEXTS   128

Definition at line 52 of file kvm_book3s.h.

#define SID_MAP_BITS   9

Definition at line 45 of file kvm_book3s.h.

#define SID_MAP_MASK   (SID_MAP_NUM - 1)

Definition at line 47 of file kvm_book3s.h.

#define SID_MAP_NUM   (1 << SID_MAP_BITS)

Definition at line 46 of file kvm_book3s.h.

#define VSID_BAT   0x1fffffffffb00000ULL

Definition at line 109 of file kvm_book3s.h.

#define VSID_POOL_SIZE   (SID_CONTEXTS * 16)

Definition at line 53 of file kvm_book3s.h.

#define VSID_PR   0x8000000000000000ULL

Definition at line 112 of file kvm_book3s.h.

#define VSID_REAL   0x1fffffffffc00000ULL

Definition at line 108 of file kvm_book3s.h.

#define VSID_REAL_DR   0x2000000000000000ULL

Definition at line 110 of file kvm_book3s.h.

#define VSID_REAL_IR   0x4000000000000000ULL

Definition at line 111 of file kvm_book3s.h.

Function Documentation

void kvm_return_point ( void  )
void kvmppc_add_revmap_chain ( struct kvm kvm,
struct revmap_entry rev,
unsigned long rmap,
long  pte_index,
int  realmode 
)

Definition at line 42 of file book3s_hv_rm_mmu.c.

ulong kvmppc_alignment_dar ( struct kvm_vcpu vcpu,
unsigned int  inst 
)

Definition at line 568 of file book3s_emulate.c.

u32 kvmppc_alignment_dsisr ( struct kvm_vcpu vcpu,
unsigned int  inst 
)

Definition at line 526 of file book3s_emulate.c.

int kvmppc_book3s_hv_page_fault ( struct kvm_run run,
struct kvm_vcpu vcpu,
unsigned long  addr,
unsigned long  status 
)

Definition at line 567 of file book3s_64_mmu_hv.c.

void kvmppc_book3s_queue_irqprio ( struct kvm_vcpu vcpu,
unsigned int  vec 
)

Definition at line 119 of file book3s.c.

void kvmppc_clear_ref_hpte ( struct kvm kvm,
unsigned long hptep,
unsigned long  pte_index 
)

Definition at line 627 of file book3s_hv_rm_mmu.c.

int kvmppc_emulate_paired_single ( struct kvm_run run,
struct kvm_vcpu vcpu 
)

Definition at line 641 of file book3s_paired_singles.c.

void kvmppc_entry_trampoline ( void  )
pfn_t kvmppc_gfn_to_pfn ( struct kvm_vcpu vcpu,
gfn_t  gfn 
)

Definition at line 290 of file book3s.c.

void kvmppc_giveup_ext ( struct kvm_vcpu vcpu,
ulong  msr 
)

Definition at line 389 of file book3s_pr.c.

long kvmppc_h_enter ( struct kvm_vcpu vcpu,
unsigned long  flags,
long  pte_index,
unsigned long  pteh,
unsigned long  ptel 
)

Definition at line 133 of file book3s_hv_rm_mmu.c.

int kvmppc_h_pr ( struct kvm_vcpu vcpu,
unsigned long  cmd 
)

Definition at line 230 of file book3s_pr_papr.c.

void kvmppc_hv_entry_trampoline ( void  )
long kvmppc_hv_find_lock_hpte ( struct kvm kvm,
gva_t  eaddr,
unsigned long  slb_v,
unsigned long  valid 
)

Definition at line 653 of file book3s_hv_rm_mmu.c.

long kvmppc_hv_get_dirty_log ( struct kvm kvm,
struct kvm_memory_slot memslot 
)

Definition at line 1033 of file book3s_64_mmu_hv.c.

void kvmppc_inject_interrupt ( struct kvm_vcpu vcpu,
int  vec,
u64  flags 
)

Definition at line 72 of file book3s.c.

void kvmppc_invalidate_hpte ( struct kvm kvm,
unsigned long hptep,
unsigned long  pte_index 
)

Definition at line 610 of file book3s_hv_rm_mmu.c.

int kvmppc_ld ( struct kvm_vcpu vcpu,
ulong eaddr,
int  size,
void ptr,
bool  data 
)

Definition at line 379 of file book3s.c.

void kvmppc_load_up_altivec ( void  )
void kvmppc_load_up_fpu ( void  )
void kvmppc_load_up_vsx ( void  )
void kvmppc_mmu_book3s_32_init ( struct kvm_vcpu vcpu)

Definition at line 401 of file book3s_32_mmu.c.

void kvmppc_mmu_book3s_64_init ( struct kvm_vcpu vcpu)

Definition at line 517 of file book3s_64_mmu.c.

void kvmppc_mmu_book3s_hv_init ( struct kvm_vcpu vcpu)

Definition at line 1103 of file book3s_64_mmu_hv.c.

void kvmppc_mmu_flush_segments ( struct kvm_vcpu vcpu)

Definition at line 331 of file book3s_32_mmu_host.c.

void kvmppc_mmu_hpte_cache_map ( struct kvm_vcpu vcpu,
struct hpte_cache pte 
)

Definition at line 59 of file book3s_mmu_hpte.c.

struct hpte_cache* kvmppc_mmu_hpte_cache_next ( struct kvm_vcpu vcpu)
read

Definition at line 294 of file book3s_mmu_hpte.c.

void kvmppc_mmu_hpte_destroy ( struct kvm_vcpu vcpu)

Definition at line 308 of file book3s_mmu_hpte.c.

int kvmppc_mmu_hpte_init ( struct kvm_vcpu vcpu)

Definition at line 321 of file book3s_mmu_hpte.c.

void kvmppc_mmu_hpte_sysexit ( void  )

Definition at line 349 of file book3s_mmu_hpte.c.

int kvmppc_mmu_hpte_sysinit ( void  )

Definition at line 340 of file book3s_mmu_hpte.c.

int kvmppc_mmu_hv_init ( void  )

Definition at line 227 of file book3s_64_mmu_hv.c.

void kvmppc_mmu_invalidate_pte ( struct kvm_vcpu vcpu,
struct hpte_cache pte 
)

Definition at line 60 of file book3s_32_mmu_host.c.

int kvmppc_mmu_map_page ( struct kvm_vcpu vcpu,
struct kvmppc_pte pte 
)

Definition at line 141 of file book3s_32_mmu_host.c.

int kvmppc_mmu_map_segment ( struct kvm_vcpu vcpu,
ulong  eaddr 
)

Definition at line 300 of file book3s_32_mmu_host.c.

void kvmppc_mmu_pte_flush ( struct kvm_vcpu vcpu,
ulong  ea,
ulong  ea_mask 
)

Definition at line 188 of file book3s_mmu_hpte.c.

void kvmppc_mmu_pte_pflush ( struct kvm_vcpu vcpu,
ulong  pa_start,
ulong  pa_end 
)

Definition at line 1547 of file book3s_hv.c.

void kvmppc_mmu_pte_vflush ( struct kvm_vcpu vcpu,
u64  vp,
u64  vp_mask 
)

Definition at line 253 of file book3s_mmu_hpte.c.

void* kvmppc_pin_guest_page ( struct kvm kvm,
unsigned long  addr,
unsigned long nb_ret 
)

Definition at line 1050 of file book3s_64_mmu_hv.c.

void kvmppc_set_bat ( struct kvm_vcpu vcpu,
struct kvmppc_bat bat,
bool  upper,
u32  val 
)

Definition at line 276 of file book3s_emulate.c.

void kvmppc_set_msr ( struct kvm_vcpu vcpu,
u64  new_msr 
)

Definition at line 79 of file book3s_hv.c.

void kvmppc_set_pvr ( struct kvm_vcpu vcpu,
u32  pvr 
)

Definition at line 85 of file book3s_hv.c.

int kvmppc_st ( struct kvm_vcpu vcpu,
ulong eaddr,
int  size,
void ptr,
bool  data 
)

Definition at line 358 of file book3s.c.

void kvmppc_unpin_guest_page ( struct kvm kvm,
void addr 
)

Definition at line 1096 of file book3s_64_mmu_hv.c.

long kvmppc_virtmode_h_enter ( struct kvm_vcpu vcpu,
unsigned long  flags,
long  pte_index,
unsigned long  pteh,
unsigned long  ptel 
)

Definition at line 361 of file book3s_64_mmu_hv.c.