cmf.c (c02087162af5d8880ff2d688999d71e1bfa16f2f) | cmf.c (364c85584e030f7cfc25e9d27ca893dee6f4bf8e) |
---|---|
1/* 2 * linux/drivers/s390/cio/cmf.c 3 * 4 * Linux on zSeries Channel Measurement Facility support 5 * 6 * Copyright 2000,2006 IBM Corporation 7 * 8 * Authors: Arnd Bergmann <arndb@de.ibm.com> --- 475 unchanged lines hidden (view full) --- 484}; 485 486static struct cmb_area cmb_area = { 487 .lock = __SPIN_LOCK_UNLOCKED(cmb_area.lock), 488 .list = LIST_HEAD_INIT(cmb_area.list), 489 .num_channels = 1024, 490}; 491 | 1/* 2 * linux/drivers/s390/cio/cmf.c 3 * 4 * Linux on zSeries Channel Measurement Facility support 5 * 6 * Copyright 2000,2006 IBM Corporation 7 * 8 * Authors: Arnd Bergmann <arndb@de.ibm.com> --- 475 unchanged lines hidden (view full) --- 484}; 485 486static struct cmb_area cmb_area = { 487 .lock = __SPIN_LOCK_UNLOCKED(cmb_area.lock), 488 .list = LIST_HEAD_INIT(cmb_area.list), 489 .num_channels = 1024, 490}; 491 |
492 | |
493/* ****** old style CMB handling ********/ 494 495/* 496 * Basic channel measurement blocks are allocated in one contiguous 497 * block of memory, which can not be moved as long as any channel 498 * is active. Therefore, a maximum number of subchannels needs to 499 * be defined somewhere. This is a module parameter, defaulting to 500 * a resonable value of 1024, or 32 kb of memory. --- 306 unchanged lines hidden (view full) --- 807 .free = free_cmb, 808 .set = set_cmb, 809 .read = read_cmb, 810 .readall = readall_cmb, 811 .reset = reset_cmb, 812 .align = align_cmb, 813 .attr_group = &cmf_attr_group, 814}; | 492/* ****** old style CMB handling ********/ 493 494/* 495 * Basic channel measurement blocks are allocated in one contiguous 496 * block of memory, which can not be moved as long as any channel 497 * is active. Therefore, a maximum number of subchannels needs to 498 * be defined somewhere. This is a module parameter, defaulting to 499 * a resonable value of 1024, or 32 kb of memory. --- 306 unchanged lines hidden (view full) --- 806 .free = free_cmb, 807 .set = set_cmb, 808 .read = read_cmb, 809 .readall = readall_cmb, 810 .reset = reset_cmb, 811 .align = align_cmb, 812 .attr_group = &cmf_attr_group, 813}; |
815 | 814 |
816/* ******** extended cmb handling ********/ 817 818/** 819 * struct cmbe - extended channel measurement block 820 * @ssch_rsch_count: number of ssch and rsch 821 * @sample_count: number of samples 822 * @device_connect_time: time of device connect 823 * @function_pending_time: time of function pending --- 250 unchanged lines hidden (view full) --- 1074 .free = free_cmbe, 1075 .set = set_cmbe, 1076 .read = read_cmbe, 1077 .readall = readall_cmbe, 1078 .reset = reset_cmbe, 1079 .align = align_cmbe, 1080 .attr_group = &cmf_attr_group_ext, 1081}; | 815/* ******** extended cmb handling ********/ 816 817/** 818 * struct cmbe - extended channel measurement block 819 * @ssch_rsch_count: number of ssch and rsch 820 * @sample_count: number of samples 821 * @device_connect_time: time of device connect 822 * @function_pending_time: time of function pending --- 250 unchanged lines hidden (view full) --- 1073 .free = free_cmbe, 1074 .set = set_cmbe, 1075 .read = read_cmbe, 1076 .readall = readall_cmbe, 1077 .reset = reset_cmbe, 1078 .align = align_cmbe, 1079 .attr_group = &cmf_attr_group_ext, 1080}; |
1082 | |
1083 1084static ssize_t cmb_show_attr(struct device *dev, char *buf, enum cmb_index idx) 1085{ 1086 return sprintf(buf, "%lld\n", 1087 (unsigned long long) cmf_read(to_ccwdev(dev), idx)); 1088} 1089 1090static ssize_t cmb_show_avg_sample_interval(struct device *dev, --- 296 unchanged lines hidden --- | 1081 1082static ssize_t cmb_show_attr(struct device *dev, char *buf, enum cmb_index idx) 1083{ 1084 return sprintf(buf, "%lld\n", 1085 (unsigned long long) cmf_read(to_ccwdev(dev), idx)); 1086} 1087 1088static ssize_t cmb_show_avg_sample_interval(struct device *dev, --- 296 unchanged lines hidden --- |