Interface guest_irq_controller.h
The libsel4vm IRQ controller interface provides a base abstraction around initialising a guest VM irq controller and methods for injecting IRQs into a running VM instance.
Brief content:
Functions:
Functions
The interface guest_irq_controller.h
defines the following functions.
Function vm_inject_irq(vcpu, irq)
Inject an IRQ into a VM’s interrupt controller
Parameters:
vcpu {vm_vcpu_t *}
: Handle to the VCPUirq {int}
: IRQ number to inject
Returns:
- 0 on success, otherwise -1 for error
Back to interface description.
Function vm_set_irq_level(vcpu, irq, irq_level)
Set level of IRQ number into a VM’s interrupt controller
Parameters:
vcpu {vm_vcpu_t}
: Handle to the VCPUirq {int}
: IRQ number to set level onirq_level {int}
: Value of IRQ level
Returns:
- 0 on success, otherwise -1 for error
Back to interface description.
Function vm_register_irq(vcpu, irq, ack_fn, cookie)
Register irq with an acknowledgment function
Parameters:
vcpu {vm_vcpu_t *}
: Handle to the VCPUirq {int}
: IRQ number to register acknowledgement function onack_fn {irq_ack_fn_t}
: IRQ acknowledgement functioncookie {void *}
: Cookie to pass back with IRQ acknowledgement function
Returns:
- 0 on success, otherwise -1 for error
Back to interface description.
Function vm_create_default_irq_controller(vm)
Install the default interrupt controller into the VM
Parameters:
vm {vm_t *}
: Handle to the VM
Returns:
- 0 on success, otherwise -1 for error
Back to interface description.
Back to top.