diff options
Diffstat (limited to 'chip/npcx/fan.c')
-rw-r--r-- | chip/npcx/fan.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/chip/npcx/fan.c b/chip/npcx/fan.c index 8e08e4ec58..a92b01e60c 100644 --- a/chip/npcx/fan.c +++ b/chip/npcx/fan.c @@ -492,10 +492,10 @@ void fan_set_rpm_target(int ch, int rpm) /* If rpm = 0, disable PWM */ if (rpm == 0) fan_set_duty(ch, 0); - else if (rpm > fans[ch].rpm_max) - rpm = fans[ch].rpm_max; - else if (rpm < fans[ch].rpm_min) - rpm = fans[ch].rpm_min; + else if (rpm > fans[ch].rpm->rpm_max) + rpm = fans[ch].rpm->rpm_max; + else if (rpm < fans[ch].rpm->rpm_min) + rpm = fans[ch].rpm->rpm_min; /* Set target rpm */ fan_status[ch].rpm_target = rpm; |