Commit Graph

7 Commits

Author SHA1 Message Date
Ed Schouten
d745c852be Mark MALLOC_DEFINEs static that have no corresponding MALLOC_DECLAREs.
This means that their use is restricted to a single C file.
2011-11-07 06:44:47 +00:00
Nathan Whitehorn
02d9c7407f Fix an error that could cause sysctl -a to enter an infinite loop in the
event of a broken or busy fan due to returning incorrect error codes from
the FCU sysctl handler.

Reported by:	Path Mather <paul at gromit dot dlib dot vt dot edu>1
Approved by:	re (kib)
2011-07-30 00:52:13 +00:00
Nathan Whitehorn
373506f71d Turn the minimum PWM fan speed down to 30 from 40. It turns out the burning
smell that caused me to turn this up was due to a failed fan burning, not
a CPU (plus a healthy dose of paranoia).

Submitted by:	Paul Mather <paul at gromit dot dlib dot vt dot edu>
2011-06-26 00:49:17 +00:00
Andreas Tobler
564a091bd2 - Improve error handling.
- Add retry loops for the i2c read/write functions.

Approved by:	nwhitehorn (mentor)
2011-06-04 09:25:59 +00:00
Nathan Whitehorn
815d7d92c1 Update the I2C-based temperature/fan drivers to connect to the Powermac
thermal control module. This provides automatic fan management on all G5
PowerMacs and Xserves.
2011-05-29 18:35:57 +00:00
Andreas Tobler
bd9aad47ea Add new functions, fcu_fan_set_pwm and fcu_fan_get_pwm, to set and get
the pwm values. We can now set the fan's speed of a PWM controlled fan
with % numbers between 30 and 100 % instead of trying to model a
% number based on rpm.
The fcu chip offers both, the dutycycle and the rpm value of the PWM
controlled fans. I added the rpm value to the list of information
available via sysctl(8).

Tested by: Paul Mather <paul at gromit dlib vt edu>

Approved by: nwhitehorn (mentor)
2011-01-11 21:18:29 +00:00
Andreas Tobler
da89fa28c6 Add three new drivers for fan control and temperature reading on the
PowerMac7,2.

- The fcu driver lets us read and write the fan RPMs for all fans in the
  PowerMac7,2. This driver is PowerMac specific.
- The ds1775 is a driver to read the temperature for the drive bay sensor.
- The max6690 is another driver to read temperatures. Here it is used to
  read the inlet, the backside and the U3 heatsink temperature.

An additional driver, the ad7417, will follow later.

Thanks to nwhitehorn for guiding me through this driver development.

Approved by:	nwhitehorn (mentor)
2010-10-15 20:08:16 +00:00