Skip to contentSkip to conversation

hwmon: ltc4215: clear faults at startup

PATCH New Ira W. Snyder 1 participant 1 message Sep 2, 2009 Hardware monitoring

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 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.

---
 drivers/hwmon/ltc4215.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/hwmon/ltc4215.c +1 -1
index 9386e2a..6c9a041 100644
@@ -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, &ltc4215_group);
Signature · 7 lines
1.5.4.3


_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors