diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2019-05-06 19:56:51 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2019-05-06 19:56:51 -0700 |
commit | 7aefd944f038c7469571adb37769cb6f3924ecfa (patch) | |
tree | f0a8dc23633b6bbbc4f0bff932f332e847fb6c1b /drivers/hwmon/ltc4245.c | |
parent | ffa6f55eb6188ee73339cab710fabf30d13110a7 (diff) | |
parent | 39abe9d88b30a51029b0b29a708a4f4459034565 (diff) | |
download | blackbird-op-linux-7aefd944f038c7469571adb37769cb6f3924ecfa.tar.gz blackbird-op-linux-7aefd944f038c7469571adb37769cb6f3924ecfa.zip |
Merge tag 'hwmon-for-v5.2' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging
Pull hwmon updates from Guenter Roeck:
- Add driver for Intersil ISL68137 PWM Controller
- Add driver for Lochnagar 2
- Add driver for Infineon IR38064 Voltage Regulator
- Add support for TMP75B to lm75 driver
- Convert documentation to ReST format
- Use request_muxed_region for Super-IO accesses in several drivers
- Add 'samples' attribute to ABI, and start using it
- Add support for custom sysfs attributes to pmbus drivers (used in
ISL68137 driver)
- Introduce HWMON_CHANNEL_INFO macro
- Automated changes:
- Use permission specific [SENSOR_][DEVICE_]ATTR variants
- Fix build warnings due to unused of_device_id structures
- Use HWMON_CHANNEL_INFO macro
- Various minor improvements and fixes
* tag 'hwmon-for-v5.2' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: (125 commits)
hwmon: (lm75) Add support for TMP75B
dt-bindings: hwmon: Add tmp75b to lm75.txt
hwmon: (s3c) Use dev_get_drvdata()
hwmon: (max6650) Drop call to thermal_cdev_update
docs: hwmon: remove the extension from .rst files
docs: hwmon: convert three docs to ReST format
hwmon: (max6650) add thermal cooling device capability
hwmon: (ina3221) Add voltage conversion time settings
hwmon: (ina3221) Do not read-back to cache reg_config
docs: hwmon: Add an index file and rename docs to *.rst
docs: hwmon: convert remaining files to ReST format
docs: hwmon: misc files: convert to ReST format
docs: hwmon: pmbus files: convert to ReST format
docs: hwmon: k8temp, w83793: convert to ReST format
docs: hwmon: da9052, da9055: convert to ReST format
docs: hwmon: wm831x, wm8350: convert to ReST format
docs: hwmon: dme1737, vt1211: convert to ReST format
docs: hwmon: ads1015: convert to ReST format
docs: hwmon: asc7621: convert to ReST format
docs: hwmon: ibmpowernv: convert to ReST format
...
Diffstat (limited to 'drivers/hwmon/ltc4245.c')
-rw-r--r-- | drivers/hwmon/ltc4245.c | 73 |
1 files changed, 23 insertions, 50 deletions
diff --git a/drivers/hwmon/ltc4245.c b/drivers/hwmon/ltc4245.c index 34d0653ca607..26542635de9b 100644 --- a/drivers/hwmon/ltc4245.c +++ b/drivers/hwmon/ltc4245.c @@ -390,57 +390,30 @@ static umode_t ltc4245_is_visible(const void *_data, } } -static const u32 ltc4245_in_config[] = { - HWMON_I_INPUT, /* dummy, skipped in is_visible */ - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT | HWMON_I_MIN_ALARM, - HWMON_I_INPUT, - HWMON_I_INPUT, - HWMON_I_INPUT, - 0 -}; - -static const struct hwmon_channel_info ltc4245_in = { - .type = hwmon_in, - .config = ltc4245_in_config, -}; - -static const u32 ltc4245_curr_config[] = { - HWMON_C_INPUT | HWMON_C_MAX_ALARM, - HWMON_C_INPUT | HWMON_C_MAX_ALARM, - HWMON_C_INPUT | HWMON_C_MAX_ALARM, - HWMON_C_INPUT | HWMON_C_MAX_ALARM, - 0 -}; - -static const struct hwmon_channel_info ltc4245_curr = { - .type = hwmon_curr, - .config = ltc4245_curr_config, -}; - -static const u32 ltc4245_power_config[] = { - HWMON_P_INPUT, - HWMON_P_INPUT, - HWMON_P_INPUT, - HWMON_P_INPUT, - 0 -}; - -static const struct hwmon_channel_info ltc4245_power = { - .type = hwmon_power, - .config = ltc4245_power_config, -}; - static const struct hwmon_channel_info *ltc4245_info[] = { - <c4245_in, - <c4245_curr, - <c4245_power, + HWMON_CHANNEL_INFO(in, + HWMON_I_INPUT, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT | HWMON_I_MIN_ALARM, + HWMON_I_INPUT, + HWMON_I_INPUT, + HWMON_I_INPUT), + HWMON_CHANNEL_INFO(curr, + HWMON_C_INPUT | HWMON_C_MAX_ALARM, + HWMON_C_INPUT | HWMON_C_MAX_ALARM, + HWMON_C_INPUT | HWMON_C_MAX_ALARM, + HWMON_C_INPUT | HWMON_C_MAX_ALARM), + HWMON_CHANNEL_INFO(power, + HWMON_P_INPUT, + HWMON_P_INPUT, + HWMON_P_INPUT, + HWMON_P_INPUT), NULL }; |