entry/kvm: Have xfer_to_guest_mode_work_pending() flush rcuog wakeup

Both arm64 and riscv usage of the generic guest entry infra fail to
flush pending rcuog wakeups before the last scheduling point.
xfer_to_guest_mode_work_pending() is the last scheduling point before
guest entry across all architectures, and in every case it is called
exactly once. Thus, there is little value in having a separate helper to
perform the deferred wakeup.

Fix both of the messed up arches (and avoid repeated failures future
adoption) by processing the deferred wakeup implicitly in
xfer_to_guest_mode_work_pending().

Fixes: 6caa5812e2d1 ("KVM: arm64: Use generic KVM xfer to guest work function")
Fixes: 9c00fbdd93a2 ("RISC-V: KVM: Use generic guest entry infrastructure")
Cc: Jisheng Zhang <jszhang@kernel.org>
Cc: Anup Patel <anup@brainfault.org>
Cc: stable@vger.kernel.org
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
2 files changed