hwmon: (tmp401) Fix off-by-one error in chip
PATCH 1/1 hwmon: (tmp401) Fix off-by-one error in chip
This patch fixes an off-by-one error in chip detection output.
I2C kind starts with 1, so this cannot be used directly as the array index.
---
drivers/hwmon/tmp401.c +1 -1
@@ -576,7 +576,7 @@ goto exit_remove; }dev_info (&client->dev,"Detected TI %s chip\n" , - names[data->kind]); + names[data->kind -1 ]);return 0 ;
_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Re: [lm-sensors] [PATCH] hwmon: (tmp401) Fix off-by-one error in
Good catch!
Quoted 9 lines · Andre Prendel
This patch fixes an off-by-one error in chip detection output.
I2C kind starts with 1, so this cannot be used directly as the array index.
Signed-off-by Andre Prendel<[email protected]>---
drivers/hwmon/tmp401.c line 582
Quoted 8 lines
drivers/hwmon/tmp401.c +1
-1@@ -576,7 +576,7 @@ goto exit_remove; }dev_info (&client->dev,"Detected TI %s chip\n" , - names[data->kind]); + names[data->kind -1 ]);return 0 ;
_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Re: [lm-sensors] [PATCH] hwmon: (tmp401) Fix off-by-one error
In reply to Andre PrendelQuoted 1 line · Hans de Goede
Good catch!
Unfortunately this bug was introduced by myself :( I didn't read your code from fschmd carefully enough.
Andre
Quoted 18 lines
Acked-by Hans de Goede <[email protected]>Quoted 15 lines · Andre Prendel
This patch fixes an off-by-one error in chip detection output.
I2C kind starts with 1, so this cannot be used directly as the array index.
Signed-off-by Andre Prendel<[email protected]>---
drivers/hwmon/tmp401.c +1
-1@@ -576,7 +576,7 @@ goto exit_remove; }dev_info (&client->dev,"Detected TI %s chip\n" , - names[data->kind]); + names[data->kind -1 ]);
Quoted 7 lines
drivers/hwmon/tmp401.c line 582
Quoted 2 lines
drivers/hwmon/tmp401.c +0
-0return 0 ;_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Re: [lm-sensors] [PATCH] hwmon: (tmp401) Fix off-by-one error in
In reply to Andre PrendelQuoted 5 lines · Andre Prendel
Quoted 1 line · Hans de Goede
Good catch!
Unfortunately this bug was introduced by myself :( I didn't read your code from fschmd carefully enough.
The patch which introduces the bug isn't merged yet, so I will simply fold the fix into that patch. Thanks!
Signature · 6 lines
Jean Delvare _______________________________________________ lm-sensors mailing list [email protected] http://lists.lm-sensors.org/mailman/listinfo/lm-sensors