Subject: Re: MP, SP, extintr, mc, ofb
To: Michael <macallan18@earthlink.net>
From: Dan LaBell <dan4l-nospam@verizon.net>
List: port-macppc
Date: 12/24/2004 20:44:57
On Saturday, December 18, 2004, at 03:07 PM, Michael wrote:
>>
> Ok, I've made a highly experimental driver for the adm1030, since I 
> don't have a way to test it I can't tell you if it works or even 
> attaches, you'll have to see yourself :)
> Try this one:
> http://macallan.homeunix.org:6704/stuff/BSD/netbsd_GENERIC_sensors.bz2
> Should work on any Mac supported by macppc and contains both sensor 
> drivers.
>

This works!  I was able to see and set the fan related values via 
sysctl, and force
the fan on , and off.  I would have tried this much earlier, but I 
haven't read any
list email since the 18th, between testing new hardware and holiday 
shopping. Actually I caught up with email late last night, and thought 
I was testing a new kernel, but I think I actually just tested the G4 
again.
Here's the kernels I've tested:
netbsd_iBook_G4        ### fan no
netbsd_GENERIC_sensors ### fan yes !!!
netbsd_GENERIC_12_18_a ### fan no
netbsd_GENERIC_12_18_b #### fan yes
All boot OK.

sysctl -A | grep machdep looks like
sysctl: machdep.cacheinfo: this type is unknown to this program
machdep.altivec = 0
machdep.model = 750FX (Revision 2.2)
machdep.powersave = 1
machdep.adm1030c0.temp0 = 76
machdep.adm1030c0.temp1 = 60

Also I get envstat output like:
CPU temp    CPU temperature   case temperature          fan speed
     degC               degC               degC                RPM
     4.00              48.00              50.00            5737500

instead of:
CPU temp
     degC
     4.00

Fan speed rpm values don't seem real, but I'm  not complaining.
My machine is an ibook g3 12"  2 usb ports 1 firewire.  OF shows  my 
fan as
/uni-n/@f8001000/ic2@f8001000/fan@158 , thats pwd after dev 
/uni-n/ic2/fan (If you need, I noticed fan address was mentioned in 
thread -- also, it's very nice to learn I could "dev /uni-n/ic2"  I had 
been trying to type in the addresses and it just would never take them, 
to my constant frustation. )

Anyway, its all pretty cool, though I'm not completely understanding 
temp0 and temp1,
I plan to read the pdf you posted as, right now I'm thinking of them 
kinda of like as potentiometer inputs, which I know is wrong, but 
seemed to work intuitively for setting values to temp0 and temp1 and 
getting the fan to come on, at various speeds.