Re: [PATCH] PCI and I2C fixes for 2.6.8

Greg KH
2004-08-23T19:26:31Z

ChangeSet 1.1807.54.5, 2004/08/02 16:10:06-07:00, khali@linux-fr.org

[PATCH] I2C: Fix debug in w83781d driver

The trivial patch below fixes two debug prints in the w83781d driver
(one needless dereference and one debug print without device info).

Signed-off-by: Jean Delvare <khali at linux-fr dot org>
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>

drivers/i2c/chips/w83781d.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)

diff -Nru a/drivers/i2c/chips/w83781d.c b/drivers/i2c/chips/w83781d.c
--- a/drivers/i2c/chips/w83781d.c 2004-08-23 11:07:20 -07:00
+++ b/drivers/i2c/chips/w83781d.c 2004-08-23 11:07:20 -07:00
@@ -815,8 +815,7 @@
data->sens[nr - 1] = val;
break;
default:
- dev_err(&client->dev,
- "Invalid sensor type %ld; must be 1, 2, or %d\n",
+ dev_err(dev, "Invalid sensor type %ld; must be 1, 2, or %d\n",
(long) val, W83781D_DEFAULT_BETA);
break;
}
@@ -1593,7 +1592,7 @@
if (time_after
(jiffies - data->last_updated, (unsigned long) (HZ + HZ / 2))
|| time_before(jiffies, data->last_updated) || !data->valid) {
- pr_debug("Starting device update\n");
+ dev_dbg(dev, "Starting device update\n");

for (i = 0; i <= 8; i++) {
if ((data->type == w83783s || data->type == w83697hf)