Subject: Re: Patch applied - no improvement - NOT!
To: None <port-macppc@netbsd.org>
From: Donald Lee <MacPPC1@caution.icompute.com>
List: port-macppc
Date: 03/14/2005 22:56:00
There is nothing in powerpc/oea, but in: arch/powerpc/mpc6xx/cpu_subr.c
I found a snippet of code that looks right.
I found this:
/*
* Configure power-saving mode.
*/
switch (vers) {
case MPC603:
case MPC603e:
case MPC603ev:
case MPC604ev:
case MPC750:
case IBM750FX:
case MPC7400:
case MPC7410:
case MPC8240:
case MPC8245:
/* Select DOZE mode. */
hid0 &= ~(HID0_DOZE | HID0_NAP | HID0_SLEEP);
hid0 |= HID0_DOZE | HID0_DPM;
powersave = 1;
break;
case MPC7455:
case MPC7450:
/* Disable BTIC on 7450 Rev 2.0 or earlier */
if ((pvr >> 16) == MPC7450 && (pvr & 0xFFFF) <= 0x0200)
hid0 &= ~HID0_BTIC;
/* Select NAP mode. */
hid0 &= ~(HID0_DOZE | HID0_NAP | HID0_SLEEP);
hid0 |= HID0_NAP | HID0_DPM;
powersave = 1;
break;
default:
/* No power-saving mode is available. */
}
I changed both spots "powersave = 0;".
I compiled a kernel, and tried it.
MAN! I'm impressed. With just the interrupt patch applied, there was
no improvement.
With this change (and... for the record, the interrupt changes are still
in), all my badness symptoms are gone. I killed off my CPU burner, and
tried a few things.....
1. Ping times were at 10 ms (on the nose)
With this change, Ping times are down to the .15 ms range (about right)
2. dump runs slowly
Dump now seems to run at appropriate speed (avg. 3.9 MB/s,
not bad for dumping /usr, with all its little files)
3. Doing any significant I/O would crash/hang the machine
With this change, the machine seems quite stable.
4. (this is only on the other machine, so....) load average is too high (2-5)
on an idle machine)
I have not set up to try this. The symptom is on my production
server, and I'm not willing to mess with it......
OK. Why? This makes little sense to me.
I was guessing that the problem had something to do with context
switching. It smelled to me like some sort of race condition that
surfaced with the faster CPU. The kicker was dump and its use of
synchronization. It seemed that the synchronization was
broken. On my other (production) machine, I also saw apache 2.x
getting "stuck" where all threads - rather than being idle - would start
burning CPU like mad. They'd still work, but they'd keep the CPU
pegged. I'd kill apache and restart, and it would be OK.
How does changing "powersave" fix this????????????????
Thanks a million. I'll run more tests. In particular, I want to know if
this fixes my "missing interrupts" in the cyclades serial card.
This looks sweet.
-dgl-