Commit e678748a authored by Jordan Niethe's avatar Jordan Niethe Committed by Michael Ellerman
Browse files

KVM: PPC: Book3S HV nestedv2: Get the PID only if needed to copy tofrom a guest



kvmhv_copy_tofrom_guest_radix() gets the PID at the start of the
function. If pid is not used, then this is a wasteful H_GUEST_GET_STATE
hcall for nestedv2 hosts. Move the assignment to where pid will be used.

Suggested-by: default avatarNicholas Piggin <npiggin@gmail.com>
Signed-off-by: default avatarJordan Niethe <jniethe5@gmail.com>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20231201132618.555031-5-vaibhav@linux.ibm.com
parent 63ccae78
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment