Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 315865
b: refs/heads/master
c: 0744426
h: refs/heads/master
i:
  315863: b72465c
v: v3
  • Loading branch information
Heiko Carstens authored and Marcelo Tosatti committed Jul 3, 2012
1 parent 5d18d06 commit 28b9643
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7ba26c482fcb42b01785ee1f39871fcc636ab3fe
refs/heads/master: 0744426e28490357855aafd2ca76c819231851c5
7 changes: 5 additions & 2 deletions trunk/arch/s390/kvm/sigp.c
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ static int __sigp_set_prefix(struct kvm_vcpu *vcpu, u16 cpu_addr, u32 address,
address = address & 0x7fffe000u;
if (copy_from_guest_absolute(vcpu, &tmp, address, 1) ||
copy_from_guest_absolute(vcpu, &tmp, address + PAGE_SIZE, 1)) {
*reg &= 0xffffffff00000000UL;
*reg |= SIGP_STATUS_INVALID_PARAMETER;
return 1; /* invalid parameter */
}
Expand All @@ -220,17 +221,19 @@ static int __sigp_set_prefix(struct kvm_vcpu *vcpu, u16 cpu_addr, u32 address,
li = fi->local_int[cpu_addr];

if (li == NULL) {
*reg &= 0xffffffff00000000UL;
*reg |= SIGP_STATUS_INCORRECT_STATE;
rc = 1; /* incorrect state */
*reg &= SIGP_STATUS_INCORRECT_STATE;
kfree(inti);
goto out_fi;
}

spin_lock_bh(&li->lock);
/* cpu must be in stopped state */
if (!(atomic_read(li->cpuflags) & CPUSTAT_STOPPED)) {
*reg &= 0xffffffff00000000UL;
*reg |= SIGP_STATUS_INCORRECT_STATE;
rc = 1; /* incorrect state */
*reg &= SIGP_STATUS_INCORRECT_STATE;
kfree(inti);
goto out_li;
}
Expand Down

0 comments on commit 28b9643

Please sign in to comment.