Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
e500_tlb.c File Reference
#include <linux/kernel.h>
#include <linux/types.h>
#include <linux/slab.h>
#include <linux/string.h>
#include <linux/kvm.h>
#include <linux/kvm_host.h>
#include <linux/highmem.h>
#include <linux/log2.h>
#include <linux/uaccess.h>
#include <linux/sched.h>
#include <linux/rwsem.h>
#include <linux/vmalloc.h>
#include <linux/hugetlb.h>
#include <asm/kvm_ppc.h>
#include "e500.h"
#include "trace.h"
#include "timing.h"

Go to the source code of this file.

Macros

#define to_htlb1_esel(esel)   (host_tlb_params[1].entries - (esel) - 1)
 

Functions

int kvmppc_e500_emul_mt_mmucsr0 (struct kvmppc_vcpu_e500 *vcpu_e500, ulong value)
 
int kvmppc_e500_emul_tlbivax (struct kvm_vcpu *vcpu, int ra, int rb)
 
int kvmppc_e500_emul_tlbilx (struct kvm_vcpu *vcpu, int rt, int ra, int rb)
 
int kvmppc_e500_emul_tlbre (struct kvm_vcpu *vcpu)
 
int kvmppc_e500_emul_tlbsx (struct kvm_vcpu *vcpu, int rb)
 
int kvmppc_e500_emul_tlbwe (struct kvm_vcpu *vcpu)
 
int kvmppc_core_vcpu_translate (struct kvm_vcpu *vcpu, struct kvm_translation *tr)
 
int kvmppc_mmu_itlb_index (struct kvm_vcpu *vcpu, gva_t eaddr)
 
int kvmppc_mmu_dtlb_index (struct kvm_vcpu *vcpu, gva_t eaddr)
 
void kvmppc_mmu_itlb_miss (struct kvm_vcpu *vcpu)
 
void kvmppc_mmu_dtlb_miss (struct kvm_vcpu *vcpu)
 
gpa_t kvmppc_mmu_xlate (struct kvm_vcpu *vcpu, unsigned int index, gva_t eaddr)
 
void kvmppc_mmu_destroy (struct kvm_vcpu *vcpu)
 
void kvmppc_mmu_map (struct kvm_vcpu *vcpu, u64 eaddr, gpa_t gpaddr, unsigned int index)
 
void kvmppc_get_sregs_e500_tlb (struct kvm_vcpu *vcpu, struct kvm_sregs *sregs)
 
int kvmppc_set_sregs_e500_tlb (struct kvm_vcpu *vcpu, struct kvm_sregs *sregs)
 
int kvm_vcpu_ioctl_config_tlb (struct kvm_vcpu *vcpu, struct kvm_config_tlb *cfg)
 
int kvm_vcpu_ioctl_dirty_tlb (struct kvm_vcpu *vcpu, struct kvm_dirty_tlb *dirty)
 
int kvmppc_e500_tlb_init (struct kvmppc_vcpu_e500 *vcpu_e500)
 
void kvmppc_e500_tlb_uninit (struct kvmppc_vcpu_e500 *vcpu_e500)
 

Macro Definition Documentation

#define to_htlb1_esel (   esel)    (host_tlb_params[1].entries - (esel) - 1)

Definition at line 37 of file e500_tlb.c.

Function Documentation

int kvm_vcpu_ioctl_config_tlb ( struct kvm_vcpu vcpu,
struct kvm_config_tlb cfg 
)

Definition at line 1122 of file e500_tlb.c.

int kvm_vcpu_ioctl_dirty_tlb ( struct kvm_vcpu vcpu,
struct kvm_dirty_tlb dirty 
)

Definition at line 1247 of file e500_tlb.c.

int kvmppc_core_vcpu_translate ( struct kvm_vcpu vcpu,
struct kvm_translation tr 
)

Definition at line 953 of file e500_tlb.c.

int kvmppc_e500_emul_mt_mmucsr0 ( struct kvmppc_vcpu_e500 vcpu_e500,
ulong  value 
)

Definition at line 668 of file e500_tlb.c.

int kvmppc_e500_emul_tlbilx ( struct kvm_vcpu vcpu,
int  rt,
int  ra,
int  rb 
)

Definition at line 755 of file e500_tlb.c.

int kvmppc_e500_emul_tlbivax ( struct kvm_vcpu vcpu,
int  ra,
int  rb 
)

Definition at line 685 of file e500_tlb.c.

int kvmppc_e500_emul_tlbre ( struct kvm_vcpu vcpu)

Definition at line 770 of file e500_tlb.c.

int kvmppc_e500_emul_tlbsx ( struct kvm_vcpu vcpu,
int  rb 
)

Definition at line 789 of file e500_tlb.c.

int kvmppc_e500_emul_tlbwe ( struct kvm_vcpu vcpu)

Definition at line 857 of file e500_tlb.c.

int kvmppc_e500_tlb_init ( struct kvmppc_vcpu_e500 vcpu_e500)

Definition at line 1256 of file e500_tlb.c.

void kvmppc_e500_tlb_uninit ( struct kvmppc_vcpu_e500 vcpu_e500)

Definition at line 1370 of file e500_tlb.c.

void kvmppc_get_sregs_e500_tlb ( struct kvm_vcpu vcpu,
struct kvm_sregs sregs 
)

Definition at line 1092 of file e500_tlb.c.

void kvmppc_mmu_destroy ( struct kvm_vcpu vcpu)

Definition at line 1020 of file e500_tlb.c.

int kvmppc_mmu_dtlb_index ( struct kvm_vcpu vcpu,
gva_t  eaddr 
)

Definition at line 986 of file e500_tlb.c.

void kvmppc_mmu_dtlb_miss ( struct kvm_vcpu vcpu)

Definition at line 1000 of file e500_tlb.c.

int kvmppc_mmu_itlb_index ( struct kvm_vcpu vcpu,
gva_t  eaddr 
)

Definition at line 979 of file e500_tlb.c.

void kvmppc_mmu_itlb_miss ( struct kvm_vcpu vcpu)

Definition at line 993 of file e500_tlb.c.

void kvmppc_mmu_map ( struct kvm_vcpu vcpu,
u64  eaddr,
gpa_t  gpaddr,
unsigned int  index 
)

kvmppc_mmu_map – create a host mapping for guest memory

If the guest wanted a larger page than the host supports, only the first host page is mapped here and the rest are demand faulted.

If the guest wanted a smaller page than the host page size, we map only the guest-size page (i.e. not a full host page mapping).

Caller must ensure that the specified guest TLB entry is safe to insert into the shadow TLB.

Definition at line 1024 of file e500_tlb.c.

gpa_t kvmppc_mmu_xlate ( struct kvm_vcpu vcpu,
unsigned int  index,
gva_t  eaddr 
)

Definition at line 1007 of file e500_tlb.c.

int kvmppc_set_sregs_e500_tlb ( struct kvm_vcpu vcpu,
struct kvm_sregs sregs 
)

Definition at line 1108 of file e500_tlb.c.