Karl Meakin | 8e58ddc | 2024-11-08 23:19:34 +0000 | [diff] [blame^] | 1 | /* |
| 2 | * Copyright 2024 The Hafnium Authors. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style |
| 5 | * license that can be found in the LICENSE file or at |
| 6 | * https://opensource.org/licenses/BSD-3-Clause. |
| 7 | */ |
| 8 | |
| 9 | #pragma once |
| 10 | |
| 11 | #include "hf/vm.h" |
| 12 | |
| 13 | /** |
| 14 | * Deactivate interrupt. |
| 15 | */ |
| 16 | int64_t plat_ffa_interrupt_deactivate(uint32_t pint_id, uint32_t vint_id, |
| 17 | struct vcpu *current); |
| 18 | |
| 19 | void plat_ffa_handle_secure_interrupt(struct vcpu *current, struct vcpu **next); |
| 20 | bool plat_ffa_inject_notification_pending_interrupt( |
| 21 | struct vcpu_locked next_locked, struct vcpu_locked current_locked, |
| 22 | struct vm_locked receiver_locked); |
| 23 | |
| 24 | bool plat_ffa_intercept_call(struct vcpu_locked current_locked, |
| 25 | struct vcpu_locked next_locked, |
| 26 | struct ffa_value *signal_interrupt); |
| 27 | |
| 28 | struct vcpu *plat_ffa_unwind_nwd_call_chain_interrupt(struct vcpu *current); |
| 29 | |
| 30 | void plat_ffa_enable_virtual_interrupts(struct vcpu_locked current_locked, |
| 31 | struct vm_locked vm_locked); |
| 32 | |
| 33 | /** |
| 34 | * Reconfigure the interrupt belonging to the current partition at runtime. |
| 35 | */ |
| 36 | int64_t plat_ffa_interrupt_reconfigure(uint32_t int_id, uint32_t command, |
| 37 | uint32_t value, struct vcpu *current); |
| 38 | |
| 39 | uint32_t plat_ffa_interrupt_get(struct vcpu_locked current_locked); |