1
2
3
4
5
6
7
8
9#ifndef __s390io_h
10#define __s390io_h
11#include <linux/tqueue.h>
12
13
14
15
16
17
18
19typedef struct _ioinfo {
20 unsigned int irq;
21 spinlock_t irq_lock;
22 void *private_data;
23
24 struct _ioinfo *prev;
25 struct _ioinfo *next;
26
27 __u8 st;
28
29 union {
30 unsigned int info;
31 struct {
32 unsigned int busy : 1;
33 unsigned int oper : 1;
34 unsigned int fast : 1;
35
36
37 unsigned int ready : 1;
38 unsigned int haltio : 1;
39 unsigned int doio : 1;
40 unsigned int w4final : 1;
41
42 unsigned int repall : 1;
43 unsigned int unready : 1;
44 unsigned int d_disable : 1;
45 unsigned int w4sense : 1;
46 unsigned int syncio : 1;
47 unsigned int consns : 1;
48 unsigned int delsense : 1;
49 unsigned int s_pend : 1;
50 unsigned int pgid : 1;
51 unsigned int pgid_supp : 1;
52 unsigned int esid : 1;
53 unsigned int repnone : 1;
54 unsigned int newreq : 1;
55 unsigned int dval : 1;
56 unsigned int unknown : 1;
57 unsigned int unfriendly: 1;
58 unsigned int killio : 1;
59 unsigned int noio : 1;
60 unsigned int notacccap : 1;
61 unsigned int unused : (sizeof(unsigned int)*8 - 26);
62 } __attribute__ ((packed)) flags;
63 } ui;
64
65 unsigned long u_intparm;
66 senseid_t senseid;
67 irq_desc_t irq_desc;
68 not_oper_handler_func_t nopfunc;
69 __u8 opm;
70 __u16 devno;
71 pgid_t pgid;
72 schib_t schib;
73 orb_t orb;
74 devstat_t devstat;
75 ccw1_t senseccw;
76 __u8 sense_data[32];
77 unsigned int stctl;
78 ssd_info_t ssd_info;
79 struct tq_struct pver_bh;
80 atomic_t pver_pending;
81} __attribute__ ((aligned(8))) ioinfo_t;
82
83#define IOINFO_FLAGS_BUSY 0x80000000
84#define IOINFO_FLAGS_OPER 0x40000000
85#define IOINFO_FLAGS_FAST 0x20000000
86#define IOINFO_FLAGS_READY 0x10000000
87#define IOINFO_FLAGS_HALTIO 0x08000000
88#define IOINFO_FLAGS_DOIO 0x04000000
89#define IOINFO_FLAGS_DOIO_Q 0x02000000
90#define IOINFO_FLAGS_W4FINAL 0x01000000
91#define IOINFO_FLAGS_REPALL 0x00800000
92
93extern ioinfo_t *ioinfo[];
94int s390_set_private_data(int irq, void * data);
95void * s390_get_private_data(int irq);
96
97#define CHSC_SEI_ACC_CHPID 1
98#define CHSC_SEI_ACC_LINKADDR 2
99#define CHSC_SEI_ACC_FULLLINKADDR 3
100
101#define CIO_PATHGONE_WAIT4INT 0x01
102#define CIO_PATHGONE_IOERR 0x02
103#define CIO_PATHGONE_DEVGONE 0x04
104
105#endif
106
107