mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 23:33:54 -06:00
target/arm: Put all PAC keys into a structure
This allows us to use a single syscall to initialize them all. Reviewed-by: Laurent Vivier <lvivier@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
parent
e8196d2111
commit
108b3ba891
5 changed files with 32 additions and 34 deletions
|
@ -9775,23 +9775,23 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1,
|
|||
return -TARGET_EINVAL;
|
||||
}
|
||||
if (arg2 & TARGET_PR_PAC_APIAKEY) {
|
||||
ret |= qemu_guest_getrandom(&env->apia_key,
|
||||
ret |= qemu_guest_getrandom(&env->keys.apia,
|
||||
sizeof(ARMPACKey), &err);
|
||||
}
|
||||
if (arg2 & TARGET_PR_PAC_APIBKEY) {
|
||||
ret |= qemu_guest_getrandom(&env->apib_key,
|
||||
ret |= qemu_guest_getrandom(&env->keys.apib,
|
||||
sizeof(ARMPACKey), &err);
|
||||
}
|
||||
if (arg2 & TARGET_PR_PAC_APDAKEY) {
|
||||
ret |= qemu_guest_getrandom(&env->apda_key,
|
||||
ret |= qemu_guest_getrandom(&env->keys.apda,
|
||||
sizeof(ARMPACKey), &err);
|
||||
}
|
||||
if (arg2 & TARGET_PR_PAC_APDBKEY) {
|
||||
ret |= qemu_guest_getrandom(&env->apdb_key,
|
||||
ret |= qemu_guest_getrandom(&env->keys.apdb,
|
||||
sizeof(ARMPACKey), &err);
|
||||
}
|
||||
if (arg2 & TARGET_PR_PAC_APGAKEY) {
|
||||
ret |= qemu_guest_getrandom(&env->apga_key,
|
||||
ret |= qemu_guest_getrandom(&env->keys.apga,
|
||||
sizeof(ARMPACKey), &err);
|
||||
}
|
||||
if (ret != 0) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue