1 #ifndef S390_CIO_IOASM_H
2 #define S390_CIO_IOASM_H
11 struct subchannel_id schid
;
12 __u32 intparm
; /* interruption parameter */
19 } __attribute__ ((packed
));
23 * Some S390 specific IO instructions as inline
26 static inline int stsch(struct subchannel_id schid
, struct schib
*addr
)
28 register struct subchannel_id reg1
asm ("1") = schid
;
35 : "=d" (ccode
), "=m" (*addr
)
36 : "d" (reg1
), "a" (addr
)
41 static inline int stsch_err(struct subchannel_id schid
, struct schib
*addr
)
43 register struct subchannel_id reg1
asm ("1") = schid
;
52 : "+d" (ccode
), "=m" (*addr
)
53 : "d" (reg1
), "a" (addr
)
58 static inline int msch(struct subchannel_id schid
, struct schib
*addr
)
60 register struct subchannel_id reg1
asm ("1") = schid
;
68 : "d" (reg1
), "a" (addr
), "m" (*addr
)
73 static inline int msch_err(struct subchannel_id schid
, struct schib
*addr
)
75 register struct subchannel_id reg1
asm ("1") = schid
;
85 : "d" (reg1
), "a" (addr
), "m" (*addr
)
90 static inline int tsch(struct subchannel_id schid
, struct irb
*addr
)
92 register struct subchannel_id reg1
asm ("1") = schid
;
99 : "=d" (ccode
), "=m" (*addr
)
100 : "d" (reg1
), "a" (addr
)
105 static inline int tpi(struct tpi_info
*addr
)
113 : "=d" (ccode
), "=m" (*addr
)
119 static inline int chsc(void *chsc_area
)
121 typedef struct { char _
[4096]; } addr_type
;
125 " .insn rre,0xb25f0000,%2,0\n"
128 : "=d" (cc
), "=m" (*(addr_type
*) chsc_area
)
129 : "d" (chsc_area
), "m" (*(addr_type
*) chsc_area
)
134 static inline int rchp(struct chp_id chpid
)
136 register struct chp_id reg1
asm ("1") = chpid
;
144 : "=d" (ccode
) : "d" (reg1
) : "cc");