From 6cd3209967469f6e89d329deda6bb0b4700e7b62 Mon Sep 17 00:00:00 2001 From: Benjamin Herrenschmidt Date: Sun, 29 Apr 2012 15:42:27 +0000 Subject: powerpc/powermac: New windfarm driver for PowerMac G5 (AGP) and Xserve G5 This replaces the old therm_pm72 using the same windfarm infrastructure that was used for other PowerMac G5 models. The fan speeds and sensors should now be visible in the same location in sysfs. The driver is split into separate core modules for PowerMac7,2 (and 7,3) and RackMac3,1, with a lot of the shared code now in the separate sensor and control modules. Signed-off-by: Benjamin Herrenschmidt --- drivers/macintosh/windfarm_fcu_controls.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'drivers/macintosh/windfarm_fcu_controls.c') diff --git a/drivers/macintosh/windfarm_fcu_controls.c b/drivers/macintosh/windfarm_fcu_controls.c index 871f8b4cf367..b3411edb324b 100644 --- a/drivers/macintosh/windfarm_fcu_controls.c +++ b/drivers/macintosh/windfarm_fcu_controls.c @@ -41,10 +41,10 @@ * applied to the setpoint RPM speed, that is basically the * speed we proviously "asked" for. * - * I'm not sure which of these Apple's algorithm is supposed - * to use + * I'm using 0 for now which is what therm_pm72 used to do and + * what Darwin -apparently- does based on observed behaviour. */ -#define RPM_PID_USE_ACTUAL_SPEED 1 +#define RPM_PID_USE_ACTUAL_SPEED 0 /* Default min/max for pumps */ #define CPU_PUMP_OUTPUT_MAX 3200 @@ -154,8 +154,6 @@ static int wf_fcu_fan_set_rpm(struct wf_control *ct, s32 value) if (value > fan->max) value = fan->max; - if (fan->target && fan->target == value) - return 0; fan->target = value; buf[0] = value >> (8 - shift); @@ -213,8 +211,6 @@ static int wf_fcu_fan_set_pwm(struct wf_control *ct, s32 value) if (value > fan->max) value = fan->max; - if (fan->target && fan->target == value) - return 0; fan->target = value; value = (value * 2559) / 1000; -- cgit v1.2.3