From b6b9d69602aec2c869dd2ca730aab2cc58473c2d Mon Sep 17 00:00:00 2001 From: "Ira W. Snyder" Date: Wed, 23 Sep 2009 22:59:43 +0200 Subject: [PATCH] hwmon: (ltc4215) Clear faults at startup When power is applied to the ltc4215 chip it sometimes reports spurious faults. The faults are not yet exposed via sysfs, however it may be useful for userspace to read the fault register directly with the i2cget command. Clear the fault register when the driver is installed so userspace doesn't have to worry about spurious fault indications. Signed-off-by: Ira W. Snyder Signed-off-by: Jean Delvare --- drivers/hwmon/ltc4215.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/hwmon/ltc4215.c b/drivers/hwmon/ltc4215.c index 9386e2a39211..6c9a04136e0a 100644 --- a/drivers/hwmon/ltc4215.c +++ b/drivers/hwmon/ltc4215.c @@ -259,7 +259,7 @@ static int ltc4215_probe(struct i2c_client *client, mutex_init(&data->update_lock); /* Initialize the LTC4215 chip */ - /* TODO */ + i2c_smbus_write_byte_data(client, LTC4215_FAULT, 0x00); /* Register sysfs hooks */ ret = sysfs_create_group(&client->dev.kobj, <c4215_group); -- 2.20.1