projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
hwmon: (mlxreg-fan) Fix out of bounds read on array fan->pwm
[linux-2.6-microblaze.git]
/
drivers
/
hwmon
/
mlxreg-fan.c
diff --git
a/drivers/hwmon/mlxreg-fan.c
b/drivers/hwmon/mlxreg-fan.c
index
35228ed
..
feab9ec
100644
(file)
--- a/
drivers/hwmon/mlxreg-fan.c
+++ b/
drivers/hwmon/mlxreg-fan.c
@@
-554,7
+554,7
@@
static int mlxreg_fan_cooling_config(struct device *dev, struct mlxreg_fan *fan)
{
int i, j;
- for (i = 0; i <
=
MLXREG_FAN_MAX_PWM; i++) {
+ for (i = 0; i < MLXREG_FAN_MAX_PWM; i++) {
struct mlxreg_fan_pwm *pwm = &fan->pwm[i];
if (!pwm->connected)