hwmon: (max6650) Cache alarm_en register
authorGuenter Roeck <linux@roeck-us.net>
Fri, 7 Jun 2019 17:23:20 +0000 (10:23 -0700)
committerGuenter Roeck <linux@roeck-us.net>
Mon, 24 Jun 2019 01:33:01 +0000 (18:33 -0700)
commitf5b20b11bbc230f64c099b12c37121aacf6f0b65
tree7552bf9f1b55b5daf221535b05437de6c77b4a59
parentbf8c9edaa5c61999ed06c001d87c9a0c86cd0bf8
hwmon: (max6650) Cache alarm_en register

The alarm_en register is read each time the is_visible function is called.
Since it is a configuration register, this is completely unnecessary.
Read it once and cache its value.

Cc: Jean-Francois Dagenais <jeff.dagenais@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/max6650.c