diff options
author | Jonathan Cameron <jic23@cam.ac.uk> | 2011-09-14 12:01:23 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-09-16 18:32:00 (GMT) |
commit | 322c95636739420631e51f3d3f24132dc220762a (patch) | |
tree | 6d8da8903e8620b6112fc67703e93baaa77ea5fe /drivers/staging/iio/adc | |
parent | 8775316e1ae147d90b77ba683e7455e89a74364a (diff) | |
download | linux-fsl-qoriq-322c95636739420631e51f3d3f24132dc220762a.tar.xz |
staging:iio:tree wide. abi fixup for in_ out_ prefix introduction.
This patch set should bring all the attributes created outside
of chan_spec registration inline with the new abi.
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/iio/adc')
-rw-r--r-- | drivers/staging/iio/adc/ad7192.c | 9 | ||||
-rw-r--r-- | drivers/staging/iio/adc/ad7280a.c | 12 | ||||
-rw-r--r-- | drivers/staging/iio/adc/ad7745.c | 36 | ||||
-rw-r--r-- | drivers/staging/iio/adc/ad799x_core.c | 60 |
4 files changed, 59 insertions, 58 deletions
diff --git a/drivers/staging/iio/adc/ad7192.c b/drivers/staging/iio/adc/ad7192.c index 5bc1051..5a389b8 100644 --- a/drivers/staging/iio/adc/ad7192.c +++ b/drivers/staging/iio/adc/ad7192.c @@ -747,10 +747,11 @@ static ssize_t ad7192_show_scale_available(struct device *dev, return len; } -static IIO_DEVICE_ATTR_NAMED(in_m_in_scale_available, in-in_scale_available, +static IIO_DEVICE_ATTR_NAMED(in_v_m_v_scale_available, + in_voltage-voltage_scale_available, S_IRUGO, ad7192_show_scale_available, NULL, 0); -static IIO_DEVICE_ATTR(in_scale_available, S_IRUGO, +static IIO_DEVICE_ATTR(in_voltage_scale_available, S_IRUGO, ad7192_show_scale_available, NULL, 0); static ssize_t ad7192_show_ac_excitation(struct device *dev, @@ -830,8 +831,8 @@ static IIO_DEVICE_ATTR(ac_excitation_en, S_IRUGO | S_IWUSR, static struct attribute *ad7192_attributes[] = { &iio_dev_attr_sampling_frequency.dev_attr.attr, - &iio_dev_attr_in_m_in_scale_available.dev_attr.attr, - &iio_dev_attr_in_scale_available.dev_attr.attr, + &iio_dev_attr_in_v_m_v_scale_available.dev_attr.attr, + &iio_dev_attr_in_voltage_scale_available.dev_attr.attr, &iio_dev_attr_bridge_switch_en.dev_attr.attr, &iio_dev_attr_ac_excitation_en.dev_attr.attr, NULL diff --git a/drivers/staging/iio/adc/ad7280a.c b/drivers/staging/iio/adc/ad7280a.c index 2d8d650..4c67cfe 100644 --- a/drivers/staging/iio/adc/ad7280a.c +++ b/drivers/staging/iio/adc/ad7280a.c @@ -736,26 +736,26 @@ static irqreturn_t ad7280_event_handler(int irq, void *private) } static IIO_DEVICE_ATTR_NAMED(in_thresh_low_value, - in-in_thresh_low_value, + in_voltage-voltage_thresh_low_value, S_IRUGO | S_IWUSR, ad7280_read_channel_config, ad7280_write_channel_config, AD7280A_CELL_UNDERVOLTAGE); static IIO_DEVICE_ATTR_NAMED(in_thresh_high_value, - in-in_thresh_high_value, + in_voltage-voltage_thresh_high_value, S_IRUGO | S_IWUSR, ad7280_read_channel_config, ad7280_write_channel_config, AD7280A_CELL_OVERVOLTAGE); -static IIO_DEVICE_ATTR(temp_thresh_low_value, +static IIO_DEVICE_ATTR(in_temp_thresh_low_value, S_IRUGO | S_IWUSR, ad7280_read_channel_config, ad7280_write_channel_config, AD7280A_AUX_ADC_UNDERVOLTAGE); -static IIO_DEVICE_ATTR(temp_thresh_high_value, +static IIO_DEVICE_ATTR(in_temp_thresh_high_value, S_IRUGO | S_IWUSR, ad7280_read_channel_config, ad7280_write_channel_config, @@ -765,8 +765,8 @@ static IIO_DEVICE_ATTR(temp_thresh_high_value, static struct attribute *ad7280_event_attributes[] = { &iio_dev_attr_in_thresh_low_value.dev_attr.attr, &iio_dev_attr_in_thresh_high_value.dev_attr.attr, - &iio_dev_attr_temp_thresh_low_value.dev_attr.attr, - &iio_dev_attr_temp_thresh_high_value.dev_attr.attr, + &iio_dev_attr_in_temp_thresh_low_value.dev_attr.attr, + &iio_dev_attr_in_temp_thresh_high_value.dev_attr.attr, NULL, }; diff --git a/drivers/staging/iio/adc/ad7745.c b/drivers/staging/iio/adc/ad7745.c index eea77f1..827344c 100644 --- a/drivers/staging/iio/adc/ad7745.c +++ b/drivers/staging/iio/adc/ad7745.c @@ -131,21 +131,21 @@ static int ad774x_i2c_write(struct ad774x_chip_info *chip, u8 reg, u8 data) #define IIO_DEV_ATTR_CONVERSION_MODE(_mode, _show, _store) \ IIO_DEVICE_ATTR(conversion_mode, _mode, _show, _store, 0) #define IIO_DEV_ATTR_CAP_SETUP(_mode, _show, _store) \ - IIO_DEVICE_ATTR(cap_setup, _mode, _show, _store, 0) + IIO_DEVICE_ATTR(in_capacitance_setup, _mode, _show, _store, 0) #define IIO_DEV_ATTR_VT_SETUP(_mode, _show, _store) \ - IIO_DEVICE_ATTR(in0_setup, _mode, _show, _store, 0) + IIO_DEVICE_ATTR(in_voltage0_setup, _mode, _show, _store, 0) #define IIO_DEV_ATTR_EXEC_SETUP(_mode, _show, _store) \ IIO_DEVICE_ATTR(exec_setup, _mode, _show, _store, 0) #define IIO_DEV_ATTR_VOLT_GAIN(_mode, _show, _store) \ - IIO_DEVICE_ATTR(in0_gain, _mode, _show, _store, 0) + IIO_DEVICE_ATTR(in_voltage0_gain, _mode, _show, _store, 0) #define IIO_DEV_ATTR_CAP_OFFS(_mode, _show, _store) \ - IIO_DEVICE_ATTR(cap_offs, _mode, _show, _store, 0) + IIO_DEVICE_ATTR(in_capacitance_offs, _mode, _show, _store, 0) #define IIO_DEV_ATTR_CAP_GAIN(_mode, _show, _store) \ - IIO_DEVICE_ATTR(cap_gain, _mode, _show, _store, 0) + IIO_DEVICE_ATTR(in_capacitance_gain, _mode, _show, _store, 0) #define IIO_DEV_ATTR_CAP_DATA(_show) \ - IIO_DEVICE_ATTR(cap0_raw, S_IRUGO, _show, NULL, 0) + IIO_DEVICE_ATTR(in_capacitance0_raw, S_IRUGO, _show, NULL, 0) #define IIO_DEV_ATTR_VT_DATA(_show) \ - IIO_DEVICE_ATTR(in0_raw, S_IRUGO, _show, NULL, 0) + IIO_DEVICE_ATTR(in_voltage0_raw, S_IRUGO, _show, NULL, 0) static ssize_t ad774x_show_conversion_modes(struct device *dev, struct device_attribute *attr, @@ -241,12 +241,12 @@ static ssize_t ad774x_store_dac_value(struct device *dev, return -EINVAL; } -static IIO_DEVICE_ATTR(capdac0_raw, S_IRUGO | S_IWUSR, +static IIO_DEVICE_ATTR(out_capacitance0_raw, S_IRUGO | S_IWUSR, ad774x_show_dac_value, ad774x_store_dac_value, AD774X_CAPDACA); -static IIO_DEVICE_ATTR(capdac1_raw, S_IRUGO | S_IWUSR, +static IIO_DEVICE_ATTR(out_capacitance1_raw, S_IRUGO | S_IWUSR, ad774x_show_dac_value, ad774x_store_dac_value, AD774X_CAPDACB); @@ -501,16 +501,16 @@ static IIO_DEV_ATTR_CAP_GAIN(S_IRUGO | S_IWUSR, static struct attribute *ad774x_attributes[] = { &iio_dev_attr_available_conversion_modes.dev_attr.attr, &iio_dev_attr_conversion_mode.dev_attr.attr, - &iio_dev_attr_cap_setup.dev_attr.attr, - &iio_dev_attr_in0_setup.dev_attr.attr, + &iio_dev_attr_in_capacitance_setup.dev_attr.attr, + &iio_dev_attr_in_voltage0_setup.dev_attr.attr, &iio_dev_attr_exec_setup.dev_attr.attr, - &iio_dev_attr_cap_offs.dev_attr.attr, - &iio_dev_attr_cap_gain.dev_attr.attr, - &iio_dev_attr_in0_gain.dev_attr.attr, - &iio_dev_attr_in0_raw.dev_attr.attr, - &iio_dev_attr_cap0_raw.dev_attr.attr, - &iio_dev_attr_capdac0_raw.dev_attr.attr, - &iio_dev_attr_capdac1_raw.dev_attr.attr, + &iio_dev_attr_in_capacitance_offs.dev_attr.attr, + &iio_dev_attr_in_capacitance_gain.dev_attr.attr, + &iio_dev_attr_in_voltage0_gain.dev_attr.attr, + &iio_dev_attr_in_voltage0_raw.dev_attr.attr, + &iio_dev_attr_in_capacitance0_raw.dev_attr.attr, + &iio_dev_attr_out_capacitance0_raw.dev_attr.attr, + &iio_dev_attr_out_capacitance1_raw.dev_attr.attr, NULL, }; diff --git a/drivers/staging/iio/adc/ad799x_core.c b/drivers/staging/iio/adc/ad799x_core.c index 75b8c37..ae64ee9 100644 --- a/drivers/staging/iio/adc/ad799x_core.c +++ b/drivers/staging/iio/adc/ad799x_core.c @@ -350,73 +350,73 @@ static irqreturn_t ad799x_event_handler(int irq, void *private) return IRQ_HANDLED; } -static IIO_DEVICE_ATTR(in0_thresh_low_value, +static IIO_DEVICE_ATTR(in_voltage0_thresh_low_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATALOW_CH1_REG); -static IIO_DEVICE_ATTR(in0_thresh_high_value, +static IIO_DEVICE_ATTR(in_voltage0_thresh_high_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATAHIGH_CH1_REG); -static IIO_DEVICE_ATTR(in0_thresh_both_hyst_raw, +static IIO_DEVICE_ATTR(in_voltage0_thresh_both_hyst_raw, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_HYST_CH1_REG); -static IIO_DEVICE_ATTR(in1_thresh_low_value, +static IIO_DEVICE_ATTR(in_voltage1_thresh_low_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATALOW_CH2_REG); -static IIO_DEVICE_ATTR(in1_thresh_high_value, +static IIO_DEVICE_ATTR(in_voltage1_thresh_high_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATAHIGH_CH2_REG); -static IIO_DEVICE_ATTR(in1_thresh_both_hyst_raw, +static IIO_DEVICE_ATTR(in_voltage1_thresh_both_hyst_raw, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_HYST_CH2_REG); -static IIO_DEVICE_ATTR(in2_thresh_low_value, +static IIO_DEVICE_ATTR(in_voltage2_thresh_low_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATALOW_CH3_REG); -static IIO_DEVICE_ATTR(in2_thresh_high_value, +static IIO_DEVICE_ATTR(in_voltage2_thresh_high_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATAHIGH_CH3_REG); -static IIO_DEVICE_ATTR(in2_thresh_both_hyst_raw, +static IIO_DEVICE_ATTR(in_voltage2_thresh_both_hyst_raw, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_HYST_CH3_REG); -static IIO_DEVICE_ATTR(in3_thresh_low_value, +static IIO_DEVICE_ATTR(in_voltage3_thresh_low_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATALOW_CH4_REG); -static IIO_DEVICE_ATTR(in3_thresh_high_value, +static IIO_DEVICE_ATTR(in_voltage3_thresh_high_value, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, AD7998_DATAHIGH_CH4_REG); -static IIO_DEVICE_ATTR(in3_thresh_both_hyst_raw, +static IIO_DEVICE_ATTR(in_voltage3_thresh_both_hyst_raw, S_IRUGO | S_IWUSR, ad799x_read_channel_config, ad799x_write_channel_config, @@ -428,18 +428,18 @@ static IIO_DEV_ATTR_SAMP_FREQ(S_IWUSR | S_IRUGO, static IIO_CONST_ATTR_SAMP_FREQ_AVAIL("15625 7812 3906 1953 976 488 244 0"); static struct attribute *ad7993_4_7_8_event_attributes[] = { - &iio_dev_attr_in0_thresh_low_value.dev_attr.attr, - &iio_dev_attr_in0_thresh_high_value.dev_attr.attr, - &iio_dev_attr_in0_thresh_both_hyst_raw.dev_attr.attr, - &iio_dev_attr_in1_thresh_low_value.dev_attr.attr, - &iio_dev_attr_in1_thresh_high_value.dev_attr.attr, - &iio_dev_attr_in1_thresh_both_hyst_raw.dev_attr.attr, - &iio_dev_attr_in2_thresh_low_value.dev_attr.attr, - &iio_dev_attr_in2_thresh_high_value.dev_attr.attr, - &iio_dev_attr_in2_thresh_both_hyst_raw.dev_attr.attr, - &iio_dev_attr_in3_thresh_low_value.dev_attr.attr, - &iio_dev_attr_in3_thresh_high_value.dev_attr.attr, - &iio_dev_attr_in3_thresh_both_hyst_raw.dev_attr.attr, + &iio_dev_attr_in_voltage0_thresh_low_value.dev_attr.attr, + &iio_dev_attr_in_voltage0_thresh_high_value.dev_attr.attr, + &iio_dev_attr_in_voltage0_thresh_both_hyst_raw.dev_attr.attr, + &iio_dev_attr_in_voltage1_thresh_low_value.dev_attr.attr, + &iio_dev_attr_in_voltage1_thresh_high_value.dev_attr.attr, + &iio_dev_attr_in_voltage1_thresh_both_hyst_raw.dev_attr.attr, + &iio_dev_attr_in_voltage2_thresh_low_value.dev_attr.attr, + &iio_dev_attr_in_voltage2_thresh_high_value.dev_attr.attr, + &iio_dev_attr_in_voltage2_thresh_both_hyst_raw.dev_attr.attr, + &iio_dev_attr_in_voltage3_thresh_low_value.dev_attr.attr, + &iio_dev_attr_in_voltage3_thresh_high_value.dev_attr.attr, + &iio_dev_attr_in_voltage3_thresh_both_hyst_raw.dev_attr.attr, &iio_dev_attr_sampling_frequency.dev_attr.attr, &iio_const_attr_sampling_frequency_available.dev_attr.attr, NULL, @@ -451,12 +451,12 @@ static struct attribute_group ad7993_4_7_8_event_attrs_group = { }; static struct attribute *ad7992_event_attributes[] = { - &iio_dev_attr_in0_thresh_low_value.dev_attr.attr, - &iio_dev_attr_in0_thresh_high_value.dev_attr.attr, - &iio_dev_attr_in0_thresh_both_hyst_raw.dev_attr.attr, - &iio_dev_attr_in1_thresh_low_value.dev_attr.attr, - &iio_dev_attr_in1_thresh_high_value.dev_attr.attr, - &iio_dev_attr_in1_thresh_both_hyst_raw.dev_attr.attr, + &iio_dev_attr_in_voltage0_thresh_low_value.dev_attr.attr, + &iio_dev_attr_in_voltage0_thresh_high_value.dev_attr.attr, + &iio_dev_attr_in_voltage0_thresh_both_hyst_raw.dev_attr.attr, + &iio_dev_attr_in_voltage1_thresh_low_value.dev_attr.attr, + &iio_dev_attr_in_voltage1_thresh_high_value.dev_attr.attr, + &iio_dev_attr_in_voltage1_thresh_both_hyst_raw.dev_attr.attr, &iio_dev_attr_sampling_frequency.dev_attr.attr, &iio_const_attr_sampling_frequency_available.dev_attr.attr, NULL, |