Subject: Re: 7500-class boot SOLUTION (nap mode BAD, doze mode GOOD!)
To: Monroe Williams <monroe@pobox.com>
From: Monroe Williams <monroe@pobox.com>
List: port-macppc
Date: 10/27/2000 03:25:57
on 10/27/00 2:28 AM, Monroe Williams at monroe@pobox.com wrote:

> on 10/27/00 1:46 AM, Tsubai Masanari at tsubai@iri.co.jp wrote:
> 
>>> The change which kills my machine happened between 20000208-UTC and
>>> 20000209-UTC.  The full list of files that changed between these two dates
>> ...
>> 
>> It seems that meaningful change is power-saving related.
>> Does this patch work?
> [snip]
> 
> Before I received this patch from you, I tried changing the power-saving
> code in my 20000209 tree to put the 750 into "doze" mode instead of "nap"
> mode.  (In the same place, cpuattach() in arch/macppc/macppc/cpu.c.)
> 
> This seems to fix the problem.
[snip]
> I'll try applying this change to a more recent version of -current and see
> if the resulting kernel will boot.

I just now supped the latest -current and applied this change, and the
resulting kernel booted.  As should be expected, some commands weren't too
happy with the 8 months of version skew between the 20000205 userland and
today's kernel, but I was able to log in.

For the record, the change I used was (in /usr/src/sys/arch/macppc/macppc/):

*** cpu.c.orig  Fri Oct 27 01:52:33 2000
--- cpu.c       Fri Oct 27 01:53:26 2000
***************
*** 102,108 ****
                /* Select NAP power-saving mode. */
                __asm __volatile ("mfspr %0,1008" : "=r"(hid0));
                hid0 &= ~(HID0_DOZE | HID0_NAP | HID0_SLEEP);
!               hid0 |= HID0_NAP | HID0_DPM;
                __asm __volatile ("mtspr 1008,%0" :: "r"(hid0));
                powersave = 1;
                break;
--- 102,108 ----
                /* Select NAP power-saving mode. */
                __asm __volatile ("mfspr %0,1008" : "=r"(hid0));
                hid0 &= ~(HID0_DOZE | HID0_NAP | HID0_SLEEP);
!               hid0 |= HID0_DOZE | HID0_DPM;
                __asm __volatile ("mtspr 1008,%0" :: "r"(hid0));
                powersave = 1;
                break;


-- monroe
------------------------------------------------------------------------
Monroe Williams                                         monroe@pobox.com