KVM
|
#include <linux/kvm_host.h>
#include <kvm/arm_vgic.h>
#include <linux/uaccess.h>
#include <asm/kvm_mmu.h>
#include <asm/cputype.h>
#include "vgic.h"
Go to the source code of this file.
Functions | |
int | vgic_check_iorange (struct kvm *kvm, phys_addr_t ioaddr, phys_addr_t addr, phys_addr_t alignment, phys_addr_t size) |
static int | vgic_check_type (struct kvm *kvm, int type_needed) |
int | kvm_set_legacy_vgic_v2_addr (struct kvm *kvm, struct kvm_arm_device_addr *dev_addr) |
static int | kvm_vgic_addr (struct kvm *kvm, struct kvm_device_attr *attr, bool write) |
static int | vgic_set_common_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
static int | vgic_get_common_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
static int | vgic_create (struct kvm_device *dev, u32 type) |
static void | vgic_destroy (struct kvm_device *dev) |
int | kvm_register_vgic_device (unsigned long type) |
int | vgic_v2_parse_attr (struct kvm_device *dev, struct kvm_device_attr *attr, struct vgic_reg_attr *reg_attr) |
static int | vgic_v2_attr_regs_access (struct kvm_device *dev, struct kvm_device_attr *attr, bool is_write) |
static int | vgic_v2_set_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
static int | vgic_v2_get_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
static int | vgic_v2_has_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
int | vgic_v3_parse_attr (struct kvm_device *dev, struct kvm_device_attr *attr, struct vgic_reg_attr *reg_attr) |
static int | vgic_v3_attr_regs_access (struct kvm_device *dev, struct kvm_device_attr *attr, bool is_write) |
static int | vgic_v3_set_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
static int | vgic_v3_get_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
static int | vgic_v3_has_attr (struct kvm_device *dev, struct kvm_device_attr *attr) |
Variables | |
struct kvm_device_ops | kvm_arm_vgic_v2_ops |
struct kvm_device_ops | kvm_arm_vgic_v3_ops |
int kvm_register_vgic_device | ( | unsigned long | type | ) |
Definition at line 316 of file vgic-kvm-device.c.
int kvm_set_legacy_vgic_v2_addr | ( | struct kvm * | kvm, |
struct kvm_arm_device_addr * | dev_addr | ||
) |
Definition at line 45 of file vgic-kvm-device.c.
|
static |
kvm_vgic_addr - set or get vgic VM base addresses @kvm: pointer to the vm struct @attr: pointer to the attribute being retrieved/updated @write: if true set the address in the VM address space, if false read the address
Set or get the vgic base addresses for the distributor and the virtual CPU interface in the VM physical address space. These addresses are properties of the emulated core/SoC and therefore user space initially knows this information. Check them for sanity (alignment, double assignment). We can't check for overlapping regions in case of a virtual GICv3 here, since we don't know the number of VCPUs yet, so we defer this check to map_resources().
Definition at line 92 of file vgic-kvm-device.c.
int vgic_check_iorange | ( | struct kvm * | kvm, |
phys_addr_t | ioaddr, | ||
phys_addr_t | addr, | ||
phys_addr_t | alignment, | ||
phys_addr_t | size | ||
) |
|
static |
|
static |
|
static |
Definition at line 311 of file vgic-kvm-device.c.
|
static |
Definition at line 285 of file vgic-kvm-device.c.
|
static |
Definition at line 209 of file vgic-kvm-device.c.
|
static |
vgic_v2_attr_regs_access - allows user space to access VGIC v2 state
@dev: kvm device handle @attr: kvm device attribute @is_write: true if userspace is writing a register
Definition at line 358 of file vgic-kvm-device.c.
|
static |
Definition at line 428 of file vgic-kvm-device.c.
|
static |
Definition at line 440 of file vgic-kvm-device.c.
int vgic_v2_parse_attr | ( | struct kvm_device * | dev, |
struct kvm_device_attr * | attr, | ||
struct vgic_reg_attr * | reg_attr | ||
) |
|
static |
Definition at line 416 of file vgic-kvm-device.c.
|
static |
Definition at line 508 of file vgic-kvm-device.c.
|
static |
Definition at line 612 of file vgic-kvm-device.c.
|
static |
Definition at line 626 of file vgic-kvm-device.c.
int vgic_v3_parse_attr | ( | struct kvm_device * | dev, |
struct kvm_device_attr * | attr, | ||
struct vgic_reg_attr * | reg_attr | ||
) |
Definition at line 474 of file vgic-kvm-device.c.
|
static |
struct kvm_device_ops kvm_arm_vgic_v2_ops |
Definition at line 440 of file vgic-kvm-device.c.
struct kvm_device_ops kvm_arm_vgic_v3_ops |
Definition at line 626 of file vgic-kvm-device.c.