[PATCH kvm-unit-tests 1/2] s390x: diag288: Add missing clobber

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

 



We clobber r0 and thus should let the compiler know we're doing so.

Because we change from basic to extended ASM, we need to change the
register names, as %r0 will be interpreted as a token in the assembler
template.

For consistency, we align with the common style in kvm-unit-tests which
is just 0.

Signed-off-by: Nico Boehr <nrb@xxxxxxxxxxxxx>
---
 s390x/diag288.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/s390x/diag288.c b/s390x/diag288.c
index 072c04a5cbd6..da7b06c365bf 100644
--- a/s390x/diag288.c
+++ b/s390x/diag288.c
@@ -94,11 +94,12 @@ static void test_bite(void)
 	/* Arm watchdog */
 	lc->restart_new_psw.mask = extract_psw_mask() & ~PSW_MASK_EXT;
 	diag288(CODE_INIT, 15, ACTION_RESTART);
-	asm volatile("		larl	%r0, 1f\n"
-		     "		stg	%r0, 424\n"
+	asm volatile("		larl	0, 1f\n"
+		     "		stg	0, 424\n"
 		     "0:	nop\n"
 		     "		j	0b\n"
-		     "1:");
+		     "1:"
+		     : : : "0");
 	report_pass("restart");
 }
 
-- 
2.31.1




[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