diff options
Diffstat (limited to 'chip/mchp/fan.c')
-rw-r--r-- | chip/mchp/fan.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/chip/mchp/fan.c b/chip/mchp/fan.c index 17b60b703d..3f61cb4d2f 100644 --- a/chip/mchp/fan.c +++ b/chip/mchp/fan.c @@ -1,4 +1,4 @@ -/* Copyright 2017 The Chromium OS Authors. All rights reserved. +/* Copyright 2017 The ChromiumOS Authors * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ @@ -38,7 +38,6 @@ static int rpm_setting; static int duty_setting; static int in_rpm_mode = 1; - static void clear_status(void) { /* Clear DRIVE_FAIL, FAN_SPIN, and FAN_STALL bits */ @@ -78,14 +77,14 @@ void fan_set_duty(int ch, int percent) duty_setting = percent; MCHP_FAN_SETTING(0) = (percent * MAX_FAN_DRIVER_SETTING / 100) - << FAN_DRIVER_SETTING_SHIFT; + << FAN_DRIVER_SETTING_SHIFT; clear_status(); } int fan_get_duty(int ch) { - duty_setting = (MCHP_FAN_SETTING(0) >> FAN_DRIVER_SETTING_SHIFT) - * 100 / MAX_FAN_DRIVER_SETTING; + duty_setting = (MCHP_FAN_SETTING(0) >> FAN_DRIVER_SETTING_SHIFT) * 100 / + MAX_FAN_DRIVER_SETTING; return duty_setting; } |