mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-01 10:42:11 +00:00
s390/extmem: Convert to use flag output macros
Use flag output macros in inline asm to allow for better code generation if the compiler has support for the flag output constraint. Reviewed-by: Juergen Christ <jchrist@linux.ibm.com> Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
This commit is contained in:
parent
0caf91f6d6
commit
0b7265ae16
@ -28,6 +28,7 @@
|
|||||||
#include <asm/extmem.h>
|
#include <asm/extmem.h>
|
||||||
#include <asm/cpcmd.h>
|
#include <asm/cpcmd.h>
|
||||||
#include <asm/setup.h>
|
#include <asm/setup.h>
|
||||||
|
#include <asm/asm.h>
|
||||||
|
|
||||||
#define DCSS_PURGESEG 0x08
|
#define DCSS_PURGESEG 0x08
|
||||||
#define DCSS_LOADSHRX 0x20
|
#define DCSS_LOADSHRX 0x20
|
||||||
@ -134,20 +135,21 @@ dcss_diag(int *func, void *parameter,
|
|||||||
unsigned long *ret1, unsigned long *ret2)
|
unsigned long *ret1, unsigned long *ret2)
|
||||||
{
|
{
|
||||||
unsigned long rx, ry;
|
unsigned long rx, ry;
|
||||||
int rc;
|
int cc;
|
||||||
|
|
||||||
rx = virt_to_phys(parameter);
|
rx = virt_to_phys(parameter);
|
||||||
ry = (unsigned long) *func;
|
ry = (unsigned long) *func;
|
||||||
|
|
||||||
diag_stat_inc(DIAG_STAT_X064);
|
diag_stat_inc(DIAG_STAT_X064);
|
||||||
asm volatile(
|
asm volatile(
|
||||||
" diag %0,%1,0x64\n"
|
" diag %[rx],%[ry],0x64\n"
|
||||||
" ipm %2\n"
|
CC_IPM(cc)
|
||||||
" srl %2,28\n"
|
: CC_OUT(cc, cc), [rx] "+d" (rx), [ry] "+d" (ry)
|
||||||
: "+d" (rx), "+d" (ry), "=d" (rc) : : "cc");
|
:
|
||||||
|
: CC_CLOBBER);
|
||||||
*ret1 = rx;
|
*ret1 = rx;
|
||||||
*ret2 = ry;
|
*ret2 = ry;
|
||||||
return rc;
|
return CC_TRANSFORM(cc);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline int
|
static inline int
|
||||||
|
Loading…
Reference in New Issue
Block a user