blob: 71d6f92538733be83ec8645d6723b3de510a72cf [file] [log] [blame]
/*
* Copyright 2018 The Hafnium Authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include "hf/arch/cpu.h"
#include "hf/spci.h"
void arch_irq_disable(void)
{
/* TODO */
}
void arch_irq_enable(void)
{
/* TODO */
}
void arch_regs_reset(struct arch_regs *r, bool is_primary, spci_vm_id_t vm_id,
cpu_id_t vcpu_id, paddr_t table)
{
/* TODO */
(void)is_primary;
(void)vm_id;
(void)table;
r->vcpu_id = vcpu_id;
}
void arch_regs_set_pc_arg(struct arch_regs *r, ipaddr_t pc, uintreg_t arg)
{
(void)pc;
r->r[0] = arg;
}
void arch_regs_set_retval(struct arch_regs *r, struct spci_value v)
{
r->r[0] = v.func;
r->r[1] = v.arg1;
r->r[2] = v.arg2;
r->r[3] = v.arg3;
r->r[4] = v.arg4;
r->r[5] = v.arg5;
r->r[6] = v.arg6;
r->r[7] = v.arg7;
}