L4Re Operating System Framework
Interface and Usage Documentation
Loading...
Searching...
No Matches
vcpu.h File Reference

vCPU API More...

#include <l4/sys/types.h>
#include <l4/sys/__vcpu-arch.h>
+ Include dependency graph for vcpu.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  l4_vcpu_state_t
 State of a vCPU. More...
 

Typedefs

typedef struct l4_vcpu_state_t l4_vcpu_state_t
 State of a vCPU.
 

Enumerations

enum  L4_vcpu_state_flags {
  L4_VCPU_F_IRQ = 0x01 , L4_VCPU_F_PAGE_FAULTS = 0x02 , L4_VCPU_F_EXCEPTIONS = 0x04 , L4_VCPU_F_USER_MODE = 0x20 ,
  L4_VCPU_F_FPU_ENABLED = 0x80
}
 State flags of a vCPU. More...
 
enum  L4_vcpu_sticky_flags { L4_VCPU_SF_IRQ_PENDING = 0x01 }
 Sticky flags of a vCPU. More...
 

Functions

int l4_vcpu_check_version (l4_vcpu_state_t const *vcpu) L4_NOTHROW
 Check if a vCPU state has the right version.
 

Detailed Description

vCPU API

Definition in file vcpu.h.

Function Documentation

◆ l4_vcpu_check_version()

int l4_vcpu_check_version ( l4_vcpu_state_t const *  vcpu)
inline

Check if a vCPU state has the right version.

Parameters
vcpuA pointer to an initialized vCPU state.
Return values
1If the vCPU state has a matching version ID for the current vCPU user-level structures.
0If the vCPU state has a different (incompatible) version ID than the current vCPU user-level structures.

Definition at line 202 of file vcpu.h.

References L4_VCPU_STATE_VERSION, and l4_vcpu_state_t::version.