Skip to content

Commit

Permalink
hwmon: (pmbus) Auto-detect temp2 and temp3 registers/attributes
Browse files Browse the repository at this point in the history
Additional temperature attribute support is easy to detect, so do it.

Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Reviewed-by: Robert Coulson <robert.coulson@ericsson.com>
Cc: stable.kernel.org # 2.6.39
  • Loading branch information
Guenter Roeck committed Jul 1, 2011
1 parent 81ae681 commit 0e502ec
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/hwmon/pmbus.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ static void pmbus_find_sensor_groups(struct i2c_client *client,
PMBUS_STATUS_TEMPERATURE))
info->func[0] |= PMBUS_HAVE_STATUS_TEMP;
}
if (pmbus_check_word_register(client, 0, PMBUS_READ_TEMPERATURE_2))
info->func[0] |= PMBUS_HAVE_TEMP2;
if (pmbus_check_word_register(client, 0, PMBUS_READ_TEMPERATURE_3))
info->func[0] |= PMBUS_HAVE_TEMP3;

/* Sensors detected on all pages */
for (page = 0; page < info->pages; page++) {
Expand Down

0 comments on commit 0e502ec

Please sign in to comment.