.. | .. |
---|
6 | 6 | #ifndef __S390_STP_H |
---|
7 | 7 | #define __S390_STP_H |
---|
8 | 8 | |
---|
| 9 | +#include <linux/compiler.h> |
---|
| 10 | + |
---|
9 | 11 | /* notifier for syncs */ |
---|
10 | 12 | extern struct atomic_notifier_head s390_epoch_delta_notifier; |
---|
11 | 13 | |
---|
12 | 14 | /* STP interruption parameter */ |
---|
13 | 15 | struct stp_irq_parm { |
---|
14 | | - unsigned int _pad0 : 14; |
---|
15 | | - unsigned int tsc : 1; /* Timing status change */ |
---|
16 | | - unsigned int lac : 1; /* Link availability change */ |
---|
17 | | - unsigned int tcpc : 1; /* Time control parameter change */ |
---|
18 | | - unsigned int _pad2 : 15; |
---|
19 | | -} __attribute__ ((packed)); |
---|
| 16 | + u32 : 14; |
---|
| 17 | + u32 tsc : 1; /* Timing status change */ |
---|
| 18 | + u32 lac : 1; /* Link availability change */ |
---|
| 19 | + u32 tcpc : 1; /* Time control parameter change */ |
---|
| 20 | + u32 : 15; |
---|
| 21 | +} __packed; |
---|
20 | 22 | |
---|
21 | 23 | #define STP_OP_SYNC 1 |
---|
22 | 24 | #define STP_OP_CTRL 3 |
---|
23 | 25 | |
---|
24 | 26 | struct stp_sstpi { |
---|
25 | | - unsigned int rsvd0; |
---|
26 | | - unsigned int rsvd1 : 8; |
---|
27 | | - unsigned int stratum : 8; |
---|
28 | | - unsigned int vbits : 16; |
---|
29 | | - unsigned int leaps : 16; |
---|
30 | | - unsigned int tmd : 4; |
---|
31 | | - unsigned int ctn : 4; |
---|
32 | | - unsigned int rsvd2 : 3; |
---|
33 | | - unsigned int c : 1; |
---|
34 | | - unsigned int tst : 4; |
---|
35 | | - unsigned int tzo : 16; |
---|
36 | | - unsigned int dsto : 16; |
---|
37 | | - unsigned int ctrl : 16; |
---|
38 | | - unsigned int rsvd3 : 16; |
---|
39 | | - unsigned int tto; |
---|
40 | | - unsigned int rsvd4; |
---|
41 | | - unsigned int ctnid[3]; |
---|
42 | | - unsigned int rsvd5; |
---|
43 | | - unsigned int todoff[4]; |
---|
44 | | - unsigned int rsvd6[48]; |
---|
45 | | -} __attribute__ ((packed)); |
---|
| 27 | + u32 : 32; |
---|
| 28 | + u32 tu : 1; |
---|
| 29 | + u32 lu : 1; |
---|
| 30 | + u32 : 6; |
---|
| 31 | + u32 stratum : 8; |
---|
| 32 | + u32 vbits : 16; |
---|
| 33 | + u32 leaps : 16; |
---|
| 34 | + u32 tmd : 4; |
---|
| 35 | + u32 ctn : 4; |
---|
| 36 | + u32 : 3; |
---|
| 37 | + u32 c : 1; |
---|
| 38 | + u32 tst : 4; |
---|
| 39 | + u32 tzo : 16; |
---|
| 40 | + u32 dsto : 16; |
---|
| 41 | + u32 ctrl : 16; |
---|
| 42 | + u32 : 16; |
---|
| 43 | + u32 tto; |
---|
| 44 | + u32 : 32; |
---|
| 45 | + u32 ctnid[3]; |
---|
| 46 | + u32 : 32; |
---|
| 47 | + u32 todoff[4]; |
---|
| 48 | + u32 rsvd[48]; |
---|
| 49 | +} __packed; |
---|
| 50 | + |
---|
| 51 | +struct stp_tzib { |
---|
| 52 | + u32 tzan : 16; |
---|
| 53 | + u32 : 16; |
---|
| 54 | + u32 tzo : 16; |
---|
| 55 | + u32 dsto : 16; |
---|
| 56 | + u32 stn; |
---|
| 57 | + u32 dstn; |
---|
| 58 | + u64 dst_on_alg; |
---|
| 59 | + u64 dst_off_alg; |
---|
| 60 | +} __packed; |
---|
| 61 | + |
---|
| 62 | +struct stp_tcpib { |
---|
| 63 | + u32 atcode : 4; |
---|
| 64 | + u32 ntcode : 4; |
---|
| 65 | + u32 d : 1; |
---|
| 66 | + u32 : 23; |
---|
| 67 | + s32 tto; |
---|
| 68 | + struct stp_tzib atzib; |
---|
| 69 | + struct stp_tzib ntzib; |
---|
| 70 | + s32 adst_offset : 16; |
---|
| 71 | + s32 ndst_offset : 16; |
---|
| 72 | + u32 rsvd1; |
---|
| 73 | + u64 ntzib_update; |
---|
| 74 | + u64 ndsto_update; |
---|
| 75 | +} __packed; |
---|
| 76 | + |
---|
| 77 | +struct stp_lsoib { |
---|
| 78 | + u32 p : 1; |
---|
| 79 | + u32 : 31; |
---|
| 80 | + s32 also : 16; |
---|
| 81 | + s32 nlso : 16; |
---|
| 82 | + u64 nlsout; |
---|
| 83 | +} __packed; |
---|
| 84 | + |
---|
| 85 | +struct stp_stzi { |
---|
| 86 | + u32 rsvd0[3]; |
---|
| 87 | + u64 data_ts; |
---|
| 88 | + u32 rsvd1[22]; |
---|
| 89 | + struct stp_tcpib tcpib; |
---|
| 90 | + struct stp_lsoib lsoib; |
---|
| 91 | +} __packed; |
---|
46 | 92 | |
---|
47 | 93 | /* Functions needed by the machine check handler */ |
---|
48 | 94 | int stp_sync_check(void); |
---|