On Fri, Oct 26, 2012 at 09:37:38AM +0200, Jean Delvare wrote: > Don't assume bank 0 is selected at device probe time. This may not be > the case. Force bank selection at first register access to guarantee > that we read the right registers upon driver loading. > > Signed-off-by: Jean Delvare <khali@xxxxxxxxxxxx> > Cc: Guenter Roeck <linux@xxxxxxxxxxxx> > Cc: stable@xxxxxxxxxxxxxxx Excellent idea. Reviewed-by: Guenter Roeck <linux@xxxxxxxxxxxx> > --- > drivers/hwmon/w83627ehf.c | 1 + > 1 file changed, 1 insertion(+) > > --- linux-3.7-rc2.orig/drivers/hwmon/w83627ehf.c 2012-10-26 09:28:16.000000000 +0200 > +++ linux-3.7-rc2/drivers/hwmon/w83627ehf.c 2012-10-26 09:34:04.028295469 +0200 > @@ -2083,6 +2083,7 @@ static int __devinit w83627ehf_probe(str > mutex_init(&data->lock); > mutex_init(&data->update_lock); > data->name = w83627ehf_device_names[sio_data->kind]; > + data->bank = 0xff; /* Force initial bank selection */ > platform_set_drvdata(pdev, data); > > /* 627EHG and 627EHF have 10 voltage inputs; 627DHG and 667HG have 9 */ > > > -- > Jean Delvare > _______________________________________________ lm-sensors mailing list lm-sensors@xxxxxxxxxxxxxx http://lists.lm-sensors.org/mailman/listinfo/lm-sensors