therm_adt746x: Don't access non-existing register]
Subsystems (2)
PATCH 1/1 therm_adt746x: Don't access non-existing register]
Michel, Darrick,
Apparently you are using the therm_adt746x driver, so maybe you would be interested in testing and carrying the following patch. I've sent it to Colin Leroy, who is listed as the maintainer for this driver, 1.5 month ago, but did not hear back.
* * * * *
The ADT746x don't have any register at sub-address 0, so better use an existing register for the initial test read.
Signed-off-by Jean Delvare <[email protected]>
Tested-by Tim Shepard <[email protected]>
Cc Colin Leroy <[email protected]>
Cc Benjamin Herrenschmidt <[email protected]>
Cc Paul Mackerras <[email protected]>
--- drivers/macintosh/therm_adt746x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/macintosh/therm_adt746x.c +1 -1
@@ -387,7 +387,7 @@ static int probe_thermostat(struct i2c_ci2c_set_clientdata (client, th); th->clt = client; - rc =read_reg (th,0 ); + rc =read_reg (th,CONFIG_REG );if (rc <0 ) {dev_err (&client->dev,"Thermostat failed to read config!\n" );kfree (th);
Signature · 6 lines
Jean Delvare -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/