Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f748f4a7 authored by Heiko Carstens's avatar Heiko Carstens Committed by Christian Borntraeger
Browse files

KVM: s390: convert handle_store_prefix()



Convert handle_store_prefix() to new guest access functions.

Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
Reviewed-by: default avatarThomas Huth <thuth@linux.vnet.ibm.com>
Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
parent 0e7a3f94
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -106,6 +106,7 @@ static int handle_store_prefix(struct kvm_vcpu *vcpu)
{
	u64 operand2;
	u32 address;
	int rc;

	vcpu->stat.instruction_stpx++;

@@ -122,8 +123,9 @@ static int handle_store_prefix(struct kvm_vcpu *vcpu)
	address = address & 0x7fffe000u;

	/* get the value */
	if (put_guest(vcpu, address, (u32 __user *)operand2))
		return kvm_s390_inject_program_int(vcpu, PGM_ADDRESSING);
	rc = write_guest(vcpu, operand2, &address, sizeof(address));
	if (rc)
		return kvm_s390_inject_prog_cond(vcpu, rc);

	VCPU_EVENT(vcpu, 5, "storing prefix to %x", address);
	trace_kvm_s390_handle_prefix(vcpu, 0, address);