4 * struct cmbdata -- channel measurement block data for user space
6 * @size: size of the stored data
7 * @ssch_rsch_count: XXX
9 * @device_connect_time:
10 * @function_pending_time:
11 * @device_disconnect_time:
12 * @control_unit_queuing_time:
13 * @device_active_only_time:
15 * @initial_command_response_time:
17 * all values are stored as 64 bit for simplicity, especially
18 * in 32 bit emulation mode. All time values are normalized to
20 * Currently, two formats are known, which differ by the size of
21 * this structure, i.e. the last two members are only set when
22 * the extended channel measurement facility (first shipped in
23 * z990 machines) is activated.
24 * Potentially, more fields could be added, which results in a
30 /* basic and exended format: */
31 __u64 ssch_rsch_count;
33 __u64 device_connect_time;
34 __u64 function_pending_time;
35 __u64 device_disconnect_time;
36 __u64 control_unit_queuing_time;
37 __u64 device_active_only_time;
38 /* extended format only: */
39 __u64 device_busy_time;
40 __u64 initial_command_response_time;
43 /* enable channel measurement */
44 #define BIODASDCMFENABLE _IO(DASD_IOCTL_LETTER,32)
45 /* enable channel measurement */
46 #define BIODASDCMFDISABLE _IO(DASD_IOCTL_LETTER,33)
47 /* reset channel measurement block */
48 #define BIODASDRESETCMB _IO(DASD_IOCTL_LETTER,34)
49 /* read channel measurement data */
50 #define BIODASDREADCMB _IOWR(DASD_IOCTL_LETTER,32,u64)
51 /* read channel measurement data */
52 #define BIODASDREADALLCMB _IOWR(DASD_IOCTL_LETTER,33,struct cmbdata)
57 * enable_cmf() - switch on the channel measurement for a specific device
58 * @cdev: The ccw device to be enabled
59 * returns 0 for success or a negative error value.
64 extern int enable_cmf(struct ccw_device *cdev);
67 * disable_cmf() - switch off the channel measurement for a specific device
68 * @cdev: The ccw device to be disabled
69 * returns 0 for success or a negative error value.
74 extern int disable_cmf(struct ccw_device *cdev);
77 * cmf_read() - read one value from the current channel measurement block
78 * @cmf: the channel to be read
79 * @index: the name of the value that is read
85 extern u64 cmf_read(struct ccw_device *cdev, int index);
87 * cmf_readall() - read one value from the current channel measurement block
88 * @cmf: the channel to be read
89 * @data: a pointer to a data block that will be filled
94 extern int cmf_readall(struct ccw_device *cdev, struct cmbdata*data);
95 extern void cmf_reset(struct ccw_device *cdev);
97 #endif /* __KERNEL__ */
98 #endif /* S390_CMB_H */