Skip to content

Commit 99d174c

Browse files
Tony O'Briengregkh
authored andcommitted
hwmon: (adt7475) Display smoothing attributes in correct order
[ Upstream commit 5f8d1e3 ] Throughout the ADT7475 driver, attributes relating to the temperature sensors are displayed in the order Remote 1, Local, Remote 2. Make temp_st_show() conform to this expectation so that values set by temp_st_store() can be displayed using the correct attribute. Fixes: 8f05bcc ("hwmon: (adt7475) temperature smoothing") Signed-off-by: Tony O'Brien <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]> Signed-off-by: Sasha Levin <[email protected]>
1 parent 75d53e8 commit 99d174c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/hwmon/adt7475.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -549,11 +549,11 @@ static ssize_t show_temp_st(struct device *dev, struct device_attribute *attr,
549549
val = data->enh_acoustics[0] & 0xf;
550550
break;
551551
case 1:
552-
val = (data->enh_acoustics[1] >> 4) & 0xf;
552+
val = data->enh_acoustics[1] & 0xf;
553553
break;
554554
case 2:
555555
default:
556-
val = data->enh_acoustics[1] & 0xf;
556+
val = (data->enh_acoustics[1] >> 4) & 0xf;
557557
break;
558558
}
559559

0 commit comments

Comments
 (0)