Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

hwmon: (ltc4261) Fix error message format

adapter->id is deprecated and not set by any adapter driver, so this
was certainly not what the author wanted to use. adapter->nr maybe,
but as dev_err() already includes this value, as well as the client's
address, there's no point repeating them. Better print a simple error
message in plain English words.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>

authored by

Jean Delvare and committed by
Guenter Roeck
475200c0 69f8b741

+1 -2
+1 -2
drivers/hwmon/ltc4261.c
··· 230 230 return -ENODEV; 231 231 232 232 if (i2c_smbus_read_byte_data(client, LTC4261_STATUS) < 0) { 233 - dev_err(&client->dev, "Failed to read register %d:%02x:%02x\n", 234 - adapter->id, client->addr, LTC4261_STATUS); 233 + dev_err(&client->dev, "Failed to read status register\n"); 235 234 return -ENODEV; 236 235 } 237 236