[kvm-unit-tests GIT PULL 09/13] s390x: emulator: Fix error path of invalid function code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


From: Christian Borntraeger <borntraeger@xxxxxxxxxxxxx>

When 127 is not an invalid function code we should not wait for the
program check. Move this check into the else branch.

Signed-off-by: Christian Borntraeger <borntraeger@xxxxxxxxxxxxx>
Signed-off-by: Nico Boehr <nrb@xxxxxxxxxxxxx>
 s390x/emulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/s390x/emulator.c b/s390x/emulator.c
index 2c42f96f..5a5a3edb 100644
--- a/s390x/emulator.c
+++ b/s390x/emulator.c
@@ -130,8 +130,8 @@ static __always_inline void __test_cpacf_invalid_func(unsigned int opcode)
 		report_skip("127 not invalid");
 	} else {
 		__test_cpacf(opcode, 127, 2, 4, 6);
+		check_pgm_int_code(PGM_INT_CODE_SPECIFICATION);
-	check_pgm_int_code(PGM_INT_CODE_SPECIFICATION);

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux