lm96063 fan driver: Initialize "spinup" register to 50%
* b/13364869
* lm96063 has a spinup feature that defaults to 100% for 3.2 seconds
when fan is first turned on (to unfreeze a stuck fan?)
* fan @ 100% is too loud, 50% seems fine
* I hesitate to make it 0% or we might get stuck fans after years
Change-Id: I6879cc51148b11b5907d6857874c1f22d2276b89
diff --git a/drivers/hwmon/lm63.c b/drivers/hwmon/lm63.c
index 5e6457a..babbcb8 100644
--- a/drivers/hwmon/lm63.c
+++ b/drivers/hwmon/lm63.c
@@ -73,6 +73,7 @@
#define LM63_REG_TACH_LIMIT_MSB 0x49
#define LM63_REG_TACH_LIMIT_LSB 0x48
+#define LM63_REG_SPINUP 0x4B
#define LM63_REG_PWM_VALUE 0x4C
#define LM63_REG_PWM_FREQ 0x4D
#define LM63_REG_LUT_TEMP_HYST 0x4F
@@ -997,6 +998,9 @@
data->remote_unsigned = true;
}
+ /* 50% spinup for 3.2 seconds */
+ i2c_smbus_write_byte_data(client, LM63_REG_SPINUP, 0x0f);
+
/* Show some debug info about the LM63 configuration */
if (data->kind == lm63)
dev_dbg(&client->dev, "Alert/tach pin configured for %s\n",