arch/powerpc/include/asm/kvm_host.h
Source file repositories/reference/linux-study-clean/arch/powerpc/include/asm/kvm_host.h
File Facts
- System
- Linux kernel
- Corpus path
arch/powerpc/include/asm/kvm_host.h- Extension
.h- Size
- 22911 bytes
- Lines
- 911
- Domain
- Architecture Layer
- Bucket
- arch/powerpc
- Inferred role
- Architecture Layer: implementation source
- Status
- source implementation candidate
Why This File Exists
CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/mutex.hlinux/hrtimer.hlinux/interrupt.hlinux/types.hlinux/kvm_types.hlinux/threads.hlinux/spinlock.hlinux/kvm_para.hlinux/list.hlinux/atomic.hasm/kvm_asm.hasm/processor.hasm/page.hasm/cacheflush.hasm/hvcall.hasm/mce.hasm/guest-state-buffer.hasm/cputhreads.hasm/kvm_book3s_asm.hlinux/mmu_notifier.h
Detected Declarations
struct lppacastruct slb_shadowstruct dtl_entrystruct kvmppc_vcpu_book3sstruct kvmppc_book3s_shadow_vcpustruct kvm_nested_gueststruct kvm_vm_statstruct kvm_vcpu_statstruct kvmppc_exit_timingstruct kvmppc_pginfostruct kvmppc_spapr_tce_iommu_tablestruct kvmppc_spapr_tce_tablestruct kvmppc_xicsstruct kvmppc_icpstruct kvmppc_xivestruct kvmppc_xive_vcpustruct kvmppc_passthru_irqmapstruct revmap_entrystruct kvm_arch_memory_slotstruct kvm_hpt_infostruct kvm_resize_hptstruct kvm_archstruct kvmppc_vpastruct kvmppc_ptestruct kvmppc_mmustruct kvmppc_slbstruct kvmhv_tb_accumulatorstruct kvmppc_irq_mapstruct kvmppc_passthru_irqmapstruct mmio_hpte_cache_entrystruct mmio_hpte_cachestruct openpicstruct kvmhv_nestedv2_configstruct kvmhv_nestedv2_iostruct kvm_vcpu_archenum kvm_exit_typesfunction kvm_arch_memslots_updated
Annotated Snippet
struct kvm_vm_stat {
struct kvm_vm_stat_generic generic;
u64 num_2M_pages;
u64 num_1G_pages;
};
struct kvm_vcpu_stat {
struct kvm_vcpu_stat_generic generic;
u64 sum_exits;
u64 mmio_exits;
u64 signal_exits;
u64 light_exits;
/* Account for special types of light exits: */
u64 itlb_real_miss_exits;
u64 itlb_virt_miss_exits;
u64 dtlb_real_miss_exits;
u64 dtlb_virt_miss_exits;
u64 syscall_exits;
u64 isi_exits;
u64 dsi_exits;
u64 emulated_inst_exits;
u64 dec_exits;
u64 ext_intr_exits;
u64 halt_successful_wait;
u64 dbell_exits;
u64 gdbell_exits;
u64 ld;
u64 st;
#ifdef CONFIG_PPC_BOOK3S
u64 pf_storage;
u64 pf_instruc;
u64 sp_storage;
u64 sp_instruc;
u64 queue_intr;
u64 ld_slow;
u64 st_slow;
#endif
u64 pthru_all;
u64 pthru_host;
u64 pthru_bad_aff;
};
enum kvm_exit_types {
MMIO_EXITS,
SIGNAL_EXITS,
ITLB_REAL_MISS_EXITS,
ITLB_VIRT_MISS_EXITS,
DTLB_REAL_MISS_EXITS,
DTLB_VIRT_MISS_EXITS,
SYSCALL_EXITS,
ISI_EXITS,
DSI_EXITS,
EMULATED_INST_EXITS,
EMULATED_MTMSRWE_EXITS,
EMULATED_WRTEE_EXITS,
EMULATED_MTSPR_EXITS,
EMULATED_MFSPR_EXITS,
EMULATED_MTMSR_EXITS,
EMULATED_MFMSR_EXITS,
EMULATED_TLBSX_EXITS,
EMULATED_TLBWE_EXITS,
EMULATED_RFI_EXITS,
EMULATED_RFCI_EXITS,
EMULATED_RFDI_EXITS,
DEC_EXITS,
EXT_INTR_EXITS,
HALT_WAKEUP,
USR_PR_INST,
FP_UNAVAIL,
DEBUG_EXITS,
TIMEINGUEST,
DBELL_EXITS,
GDBELL_EXITS,
__NUMBER_OF_KVM_EXIT_TYPES
};
/* allow access to big endian 32bit upper/lower parts and 64bit var */
struct kvmppc_exit_timing {
union {
u64 tv64;
struct {
u32 tbu, tbl;
} tv32;
};
};
struct kvmppc_pginfo {
unsigned long pfn;
atomic_t refcnt;
};
Annotation
- Immediate include surface: `linux/mutex.h`, `linux/hrtimer.h`, `linux/interrupt.h`, `linux/types.h`, `linux/kvm_types.h`, `linux/threads.h`, `linux/spinlock.h`, `linux/kvm_para.h`.
- Detected declarations: `struct lppaca`, `struct slb_shadow`, `struct dtl_entry`, `struct kvmppc_vcpu_book3s`, `struct kvmppc_book3s_shadow_vcpu`, `struct kvm_nested_guest`, `struct kvm_vm_stat`, `struct kvm_vcpu_stat`, `struct kvmppc_exit_timing`, `struct kvmppc_pginfo`.
- Atlas domain: Architecture Layer / arch/powerpc.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.