On 5/17/21 6:14 PM, Cornelia Huck wrote: > On Wed, 12 May 2021 19:15:48 +0200 > Thomas Huth <th...@redhat.com> wrote: > >> Clang versions before v11.0 insist on having the %rX or %cX register >> names instead of just a number. Since our Travis-CI is currently >> still using Clang v6.0, we have to fix this to avoid failing jobs. >> >> Signed-off-by: Thomas Huth <th...@redhat.com> >> --- >> pc-bios/s390-ccw/helper.h | 2 +- >> pc-bios/s390-ccw/jump2ipl.c | 4 ++-- >> pc-bios/s390-ccw/menu.c | 8 ++++---- >> pc-bios/s390-ccw/virtio.c | 2 +- >> 4 files changed, 8 insertions(+), 8 deletions(-) >> >> diff --git a/pc-bios/s390-ccw/helper.h b/pc-bios/s390-ccw/helper.h >> index dfcfea0ff0..3d0731c4c6 100644 >> --- a/pc-bios/s390-ccw/helper.h >> +++ b/pc-bios/s390-ccw/helper.h >> @@ -31,7 +31,7 @@ static inline void *u32toptr(uint32_t n) >> >> static inline void yield(void) >> { >> - asm volatile ("diag 0,0,0x44" >> + asm volatile ("diag %%r0,%%r0,0x44" >> : : >> : "memory", "cc"); >> } > > Sigh, this really looks uglier, but if it pleases the compiler...
Personally I find it easier to read, it makes obvious we are accessing a register, not using an immediate value.