diff options
author | Peter Meerwald <pmeerw@pmeerw.net> | 2012-12-30 18:26:00 -0500 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2013-01-01 12:38:31 -0500 |
commit | 71d2c120fda094d14339bdbe6ff0a9328154940d (patch) | |
tree | 1898382af7e8ea030e0bc07d06b5bd0863df8f80 /drivers/iio | |
parent | 4389fbec5b8fd0577c1e854ff5d7139329558c20 (diff) |
iio: max1363 comment and whitespace fixes
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio')
-rw-r--r-- | drivers/iio/adc/max1363.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/drivers/iio/adc/max1363.c b/drivers/iio/adc/max1363.c index 46d8365dd348..0ba4fea960ac 100644 --- a/drivers/iio/adc/max1363.c +++ b/drivers/iio/adc/max1363.c | |||
@@ -56,7 +56,7 @@ | |||
56 | #define MAX1363_SETUP_POWER_UP_INT_REF 0x10 | 56 | #define MAX1363_SETUP_POWER_UP_INT_REF 0x10 |
57 | #define MAX1363_SETUP_POWER_DOWN_INT_REF 0x00 | 57 | #define MAX1363_SETUP_POWER_DOWN_INT_REF 0x00 |
58 | 58 | ||
59 | /* think about includeing max11600 etc - more settings */ | 59 | /* think about including max11600 etc - more settings */ |
60 | #define MAX1363_SETUP_EXT_CLOCK 0x08 | 60 | #define MAX1363_SETUP_EXT_CLOCK 0x08 |
61 | #define MAX1363_SETUP_INT_CLOCK 0x00 | 61 | #define MAX1363_SETUP_INT_CLOCK 0x00 |
62 | #define MAX1363_SETUP_UNIPOLAR 0x00 | 62 | #define MAX1363_SETUP_UNIPOLAR 0x00 |
@@ -87,7 +87,7 @@ | |||
87 | /* max123{6-9} only */ | 87 | /* max123{6-9} only */ |
88 | #define MAX1236_SCAN_MID_TO_CHANNEL 0x40 | 88 | #define MAX1236_SCAN_MID_TO_CHANNEL 0x40 |
89 | 89 | ||
90 | /* max1363 only - merely part of channel selects or don't care for others*/ | 90 | /* max1363 only - merely part of channel selects or don't care for others */ |
91 | #define MAX1363_CONFIG_EN_MON_MODE_READ 0x18 | 91 | #define MAX1363_CONFIG_EN_MON_MODE_READ 0x18 |
92 | 92 | ||
93 | #define MAX1363_CHANNEL_SEL(a) ((a) << 1) | 93 | #define MAX1363_CHANNEL_SEL(a) ((a) << 1) |
@@ -134,7 +134,7 @@ enum max1363_modes { | |||
134 | * @mode_list: array of available scan modes | 134 | * @mode_list: array of available scan modes |
135 | * @default_mode: the scan mode in which the chip starts up | 135 | * @default_mode: the scan mode in which the chip starts up |
136 | * @int_vref_mv: the internal reference voltage | 136 | * @int_vref_mv: the internal reference voltage |
137 | * @num_channels: number of channels | 137 | * @num_modes: number of modes |
138 | * @bits: accuracy of the adc in bits | 138 | * @bits: accuracy of the adc in bits |
139 | */ | 139 | */ |
140 | struct max1363_chip_info { | 140 | struct max1363_chip_info { |
@@ -153,7 +153,7 @@ struct max1363_chip_info { | |||
153 | * @client: i2c_client | 153 | * @client: i2c_client |
154 | * @setupbyte: cache of current device setup byte | 154 | * @setupbyte: cache of current device setup byte |
155 | * @configbyte: cache of current device config byte | 155 | * @configbyte: cache of current device config byte |
156 | * @chip_info: chip model specific constants, available modes etc | 156 | * @chip_info: chip model specific constants, available modes, etc. |
157 | * @current_mode: the scan mode of this chip | 157 | * @current_mode: the scan mode of this chip |
158 | * @requestedmask: a valid requested set of channels | 158 | * @requestedmask: a valid requested set of channels |
159 | * @reg: supply regulator | 159 | * @reg: supply regulator |
@@ -294,7 +294,7 @@ static const struct max1363_mode max1363_mode_table[] = { | |||
294 | 294 | ||
295 | static const struct max1363_mode | 295 | static const struct max1363_mode |
296 | *max1363_match_mode(const unsigned long *mask, | 296 | *max1363_match_mode(const unsigned long *mask, |
297 | const struct max1363_chip_info *ci) | 297 | const struct max1363_chip_info *ci) |
298 | { | 298 | { |
299 | int i; | 299 | int i; |
300 | if (mask) | 300 | if (mask) |
@@ -1395,7 +1395,7 @@ static int max1363_initial_setup(struct max1363_state *st) | |||
1395 | | MAX1363_SETUP_UNIPOLAR | 1395 | | MAX1363_SETUP_UNIPOLAR |
1396 | | MAX1363_SETUP_NORESET; | 1396 | | MAX1363_SETUP_NORESET; |
1397 | 1397 | ||
1398 | /* Set scan mode writes the config anyway so wait until then*/ | 1398 | /* Set scan mode writes the config anyway so wait until then */ |
1399 | st->setupbyte = MAX1363_SETUP_BYTE(st->setupbyte); | 1399 | st->setupbyte = MAX1363_SETUP_BYTE(st->setupbyte); |
1400 | st->current_mode = &max1363_mode_table[st->chip_info->default_mode]; | 1400 | st->current_mode = &max1363_mode_table[st->chip_info->default_mode]; |
1401 | st->configbyte = MAX1363_CONFIG_BYTE(st->configbyte); | 1401 | st->configbyte = MAX1363_CONFIG_BYTE(st->configbyte); |
@@ -1424,7 +1424,6 @@ static int __devinit max1363_alloc_scan_masks(struct iio_dev *indio_dev) | |||
1424 | return 0; | 1424 | return 0; |
1425 | } | 1425 | } |
1426 | 1426 | ||
1427 | |||
1428 | static irqreturn_t max1363_trigger_handler(int irq, void *p) | 1427 | static irqreturn_t max1363_trigger_handler(int irq, void *p) |
1429 | { | 1428 | { |
1430 | struct iio_poll_func *pf = p; | 1429 | struct iio_poll_func *pf = p; |
@@ -1523,7 +1522,7 @@ static int __devinit max1363_probe(struct i2c_client *client, | |||
1523 | if (ret) | 1522 | if (ret) |
1524 | goto error_disable_reg; | 1523 | goto error_disable_reg; |
1525 | 1524 | ||
1526 | /* Estabilish that the iio_dev is a child of the i2c device */ | 1525 | /* Establish that the iio_dev is a child of the i2c device */ |
1527 | indio_dev->dev.parent = &client->dev; | 1526 | indio_dev->dev.parent = &client->dev; |
1528 | indio_dev->name = id->name; | 1527 | indio_dev->name = id->name; |
1529 | indio_dev->channels = st->chip_info->channels; | 1528 | indio_dev->channels = st->chip_info->channels; |