[S390] Inline assembly cleanup.
Major cleanup of all s390 inline assemblies. They now have a common coding style. Quite a few have been shortened, mainly by using register asm variables. Use of the EX_TABLE macro helps as well. The atomic ops, bit ops and locking inlines new use the Q-constraint if a newer gcc is used. That results in slightly better code. Thanks to Christian Borntraeger for proof reading the changes. Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
@@ -142,17 +142,17 @@ dcss_diag (__u8 func, void *parameter,
|
||||
|
||||
rx = (unsigned long) parameter;
|
||||
ry = (unsigned long) func;
|
||||
__asm__ __volatile__(
|
||||
asm volatile(
|
||||
#ifdef CONFIG_64BIT
|
||||
" sam31\n" // switch to 31 bit
|
||||
" diag %0,%1,0x64\n"
|
||||
" sam64\n" // switch back to 64 bit
|
||||
" sam31\n"
|
||||
" diag %0,%1,0x64\n"
|
||||
" sam64\n"
|
||||
#else
|
||||
" diag %0,%1,0x64\n"
|
||||
" diag %0,%1,0x64\n"
|
||||
#endif
|
||||
" ipm %2\n"
|
||||
" srl %2,28\n"
|
||||
: "+d" (rx), "+d" (ry), "=d" (rc) : : "cc" );
|
||||
" ipm %2\n"
|
||||
" srl %2,28\n"
|
||||
: "+d" (rx), "+d" (ry), "=d" (rc) : : "cc");
|
||||
*ret1 = rx;
|
||||
*ret2 = ry;
|
||||
return rc;
|
||||
|
Reference in New Issue
Block a user