summaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/lm75.c
diff options
context:
space:
mode:
authorMichal Orzel <michalorzel.eng@gmail.com>2020-04-30 16:05:34 +0200
committerGuenter Roeck <linux@roeck-us.net>2020-05-22 15:28:38 +0200
commit8cbf217223fba3753c6425c6c1686580347c9b42 (patch)
tree2ebca8c54fdd878b8dbb17dc620051ded78edfb2 /drivers/hwmon/lm75.c
parenthwmon: Reduce indentation level in __hwmon_device_register() (diff)
downloadlinux-8cbf217223fba3753c6425c6c1686580347c9b42.tar.xz
linux-8cbf217223fba3753c6425c6c1686580347c9b42.zip
hwmon: (lm75) Fix all coding-style warnings on lm75 driver
Check/fix all warnings generated by checkpatch.pl script on LM75 driver. Signed-off-by: Michal Orzel <michalorzel.eng@gmail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/hwmon/lm75.c')
-rw-r--r--drivers/hwmon/lm75.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/hwmon/lm75.c b/drivers/hwmon/lm75.c
index 5e6392294c03..ba0be48aeadd 100644
--- a/drivers/hwmon/lm75.c
+++ b/drivers/hwmon/lm75.c
@@ -797,8 +797,10 @@ static int lm75_detect(struct i2c_client *new_client,
/* First check for LM75A */
if (i2c_smbus_read_byte_data(new_client, 7) == LM75A_ID) {
- /* LM75A returns 0xff on unused registers so
- just to be sure we check for that too. */
+ /*
+ * LM75A returns 0xff on unused registers so
+ * just to be sure we check for that too.
+ */
if (i2c_smbus_read_byte_data(new_client, 4) != 0xff
|| i2c_smbus_read_byte_data(new_client, 5) != 0xff
|| i2c_smbus_read_byte_data(new_client, 6) != 0xff)
@@ -849,6 +851,7 @@ static int lm75_suspend(struct device *dev)
{
int status;
struct i2c_client *client = to_i2c_client(dev);
+
status = i2c_smbus_read_byte_data(client, LM75_REG_CONF);
if (status < 0) {
dev_dbg(&client->dev, "Can't read config? %d\n", status);
@@ -863,6 +866,7 @@ static int lm75_resume(struct device *dev)
{
int status;
struct i2c_client *client = to_i2c_client(dev);
+
status = i2c_smbus_read_byte_data(client, LM75_REG_CONF);
if (status < 0) {
dev_dbg(&client->dev, "Can't read config? %d\n", status);