TEST: Sleep patch #6
(As usual, I'm cross posting several lists, please don't reply to all of them, and CC me as I'm not subscribed to all of them neither)
Ok, here's the 6th version of the sleep patch for ATI based albooks & iBook G4. Other machine users, please test too as it may cause regressions (or improvements) as well.
This one fixes finally the cache flush problem that made cpufreq (on machines using the PMU for the switch) and sleep/wake unreliable occasionally (memory corruption would occur on some CPUs at least). It improves bits here or there too, and adds the sungem wake-on-lan feature.
There are still pending issues, like cpufreq on some machines will "think" it's running at full speed on wakeup while it's in fact running at slow speed (thankfully not the opposite). I don't think I'll fix this one in 2.6.9, but rather in 2.6.10.
http://gate.crashing.org/~benh/albook-ibookg4-sleep-6.diff
I'll post a 2.6.10-rc2-bk* based version of the patch soon.
Ben.
On 01 Dec 2004 at 16h12, Benjamin Herrenschmidt wrote:
Hi Ben,
Quoted 4 lines
This one fixes finally the cache flush problem that made cpufreq (on machines using the PMU for the switch) and sleep/wake unreliable occasionally (memory corruption would occur on some CPUs at least). It improves bits here or there too, and adds the sungem wake-on-lan feature.
Compiling that. btw, you didn't add the "&& !wol" before sungem's suspend call...
Signature · 1 line
Colin
Quoted 10 lines · Colin Leroy
On 01 Dec 2004 at 16h12, Benjamin Herrenschmidt wrote:
Hi Ben,
Quoted 4 lines
This one fixes finally the cache flush problem that made cpufreq (on machines using the PMU for the switch) and sleep/wake unreliable occasionally (memory corruption would occur on some CPUs at least). It improves bits here or there too, and adds the sungem wake-on-lan feature.
Compiling that. btw, you didn't add the "&& !wol" before sungem's suspend call...
What do you mean ? the whole code block is now in !wol...
Note that I'm still having problems with the cache ... I'm asking Moto/Freescale...
Ben.
On 01 Dec 2004 at 20h12, Benjamin Herrenschmidt wrote:
Hi,
Quoted 3 lines
Quoted 1 line
Compiling that. btw, you didn't add the "&& !wol" before sungem's suspend call...
What do you mean ? the whole code block is now in !wol...
I'm just being stupid, i didn't see that :)
So much for trying to read patches before having had my coffee...
Quoted 2 lines
Note that I'm still having problems with the cache ... I'm asking Moto/Freescale...
With which CPUs? I did notice zero problems with patch #5 (without freq scaling).
Signature · 1 line
Colin
Quoted 8 lines · Colin Leroy
On 01 Dec 2004 at 20h12, Benjamin Herrenschmidt wrote:
Hi,
Quoted 3 lines
Quoted 1 line
Compiling that. btw, you didn't add the "&& !wol" before sungem's suspend call...
What do you mean ? the whole code block is now in !wol...
Quoted 7 lines
I'm just being stupid, i didn't see that :)
So much for trying to read patches before having had my coffee...Quoted 2 lines
Note that I'm still having problems with the cache ... I'm asking Moto/Freescale...
With which CPUs? I did notice zero problems with patch #5 (without freq scaling).
On my 7455 rev 3.3 at least. cpufreq on mine uses the PMU as well, thus approx. the same code path as sleep. By doing freq. switches in a loop from a shell script, I can make it crash in a few iterations. It seem to be solid if I add an ugly displacement flush before the cache flush code, but that should not be necessary and thus makes me think something is wrong with the code.
Ben.
On 01 Dec 2004 at 16h12, Benjamin Herrenschmidt wrote:
Hi,
Quoted 3 lines
Ok, here's the 6th version of the sleep patch for ATI based albooks & iBook G4. Other machine users, please test too as it may cause regressions (or improvements) as well.
Works ok here on iBook G4.
Signature · 1 line
Colin
Quoted 6 lines · Benjamin Herrenschmidt
(As usual, I'm cross posting several lists, please don't reply to all of them, and CC me as I'm not subscribed to all of them neither)
Ok, here's the 6th version of the sleep patch for ATI based albooks & iBook G4. Other machine users, please test too as it may cause regressions (or improvements) as well.
kernel-2.6.9-1.691_FC3.dwmw2 in same place as before.
Signature · 1 line
dwmw2
Ok,
I mentioned those weird problems about the computer not falling asleep? It keeps happening. I compiled a kernel with the config from Alexander Wirt and tried alot of combinations.
The logs really wont help a lot.
USB-Mouse plugged in/out wont change anything, AC plugged in/out wont change anything, restarting X wont fix it.
Is there a possibility that pbbuttonsd is somehow related to that problem? I wonder. Might check that out later.
This problem I must fix before I can call sleep working. It's really annoying.
Do you have any hint on "what needs to be running" or "needs to be set to X" or anything I could look for?
There are two things I do get during boot:
_________________________________________________
Dec 2 01:41:38 localhost kernel: pmac_zilog: 0.6 (Benjamin Herrenschmidt <[email protected]>) Dec 2 01:41:38 localhost kernel: pmac_zilog: Error registering serial device, disabling pmac_zilog. Dec 2 01:41:38 localhost kernel: pmac_zilog: Did another serial driver already claim the minors? Dec 2 01:41:38 localhost kernel: RAMDISK driver initialized: 16 RAM disks of 8192K size 1024 blocksize Dec 2 01:41:38 localhost kernel: divert: not allocating divert_blk for non-ethernet device lo Dec 2 01:41:38 localhost kernel: MacIO PCI driver attached to Intrepid chipset Dec 2 01:41:38 localhost kernel: input: Macintosh mouse button
emulation
.
.
.
_________________________________________________
Dec 2 01:41:38 localhost kernel: device-mapper: 4.1.0-ioctl (2003-12-10) initialised: [email protected] Dec 2 01:41:38 localhost kernel: md: md driver 0.90.0 MAX_MD_DEVS=256, MD_SB_DISKS=27 Dec 2 01:41:38 localhost kernel: hdc: packet command error: status=0x51 { DriveReady SeekComplete Error } Dec 2 01:41:38 localhost kernel: hdc: packet command error: error=0x54 Dec 2 01:41:38 localhost kernel: ide: failed opcode was 100 Dec 2 01:41:38 localhost kernel: cdrom: open failed. Dec 2 01:41:38 localhost kernel: device-mapper: : dm-linear: Device lookup failed Dec 2 01:41:38 localhost kernel: Dec 2 01:41:38 localhost kernel: device-mapper: error adding target to table Dec 2 01:41:38 localhost kernel: device-mapper: : dm-linear: Device lookup failed Dec 2 01:41:38 localhost kernel: Dec 2 01:41:38 localhost kernel: device-mapper: error adding target to
table
.
. (20 times ".... failed"
.
Dec 2 01:41:38 localhost kernel: device-mapper: error adding target to
table
.
.
.
________________________________________________________
other than that my boot looks really clean and without any more errors.
If you could give me some hints I would really appreciate that.
Greetings
Timo Reimerdes
On 01 Dec 2004 at 16h12, Benjamin Herrenschmidt wrote:
Hi,
Quoted 4 lines
This one fixes finally the cache flush problem that made cpufreq (on machines using the PMU for the switch) and sleep/wake unreliable occasionally (memory corruption would occur on some CPUs at least). It improves bits here or there too, and adds the sungem wake-on-lan feature.
By the way, I noticed a problem when the laptop is put to sleep by closing lid:
wake-on-lan still works, but as soon as the laptop's awake, pbbuttonsd sleeps it again. Combined with the fact that a closed iBook G4 not sleeping shutdowns by itself, it would be nice if sungem could disable wol when suspending and the lid is closed - if such info is available.
Or maybe such a thing should be done in the pbbuttonsd scripts by calling ethtool?
Signature · 1 line
Colin
Quoted 4 lines · Colin Leroy
On 01 Dec 2004 at 16h12, Benjamin Herrenschmidt wrote:
Hi,
Quoted 8 lines
Quoted 4 lines
This one fixes finally the cache flush problem that made cpufreq (on machines using the PMU for the switch) and sleep/wake unreliable occasionally (memory corruption would occur on some CPUs at least). It improves bits here or there too, and adds the sungem wake-on-lan feature.
By the way, I noticed a problem when the laptop is put to sleep by closing lid:
wake-on-lan still works, but as soon as the laptop's awake, pbbuttonsd sleeps it again.
Useland shit :)
Quoted 3 lines
Combined with the fact that a closed iBook G4 not sleeping shutdowns by itself, it would be nice if sungem could disable wol when suspending and the lid is closed - if such info is available.
Userland shit (bis) :)
Quoted 2 lines
Or maybe such a thing should be done in the pbbuttonsd scripts by calling ethtool?
Signature · 1 line
Benjamin Herrenschmidt <[email protected]>
With patch #6 in some random situations, my PowerBook G4 (ATI 9600) doesn't goes to sleep.
One situation is:
- Turn PB
- Work
- Sleep
- 14 hours of sleep
- Turn back from sleep (perfect, no problem at all)
- Work for 4 hours (mails, www, no USB, Bluetooth, etc)
- Try to sleep and problem...
When I try to make sleep my PB, nothing happens (in X), and I can't switch from X to console.
Sorry, I can't help you more with this bug, I will keep trying to establish which are the events that trigger this bug.
Federico
Quoted 25 lines · Benjamin Herrenschmidt
(As usual, I'm cross posting several lists, please don't reply to all of them, and CC me as I'm not subscribed to all of them neither)
Ok, here's the 6th version of the sleep patch for ATI based albooks & iBook G4. Other machine users, please test too as it may cause regressions (or improvements) as well.
This one fixes finally the cache flush problem that made cpufreq (on machines using the PMU for the switch) and sleep/wake unreliable occasionally (memory corruption would occur on some CPUs at least). It improves bits here or there too, and adds the sungem wake-on-lan feature.
There are still pending issues, like cpufreq on some machines will "think" it's running at full speed on wakeup while it's in fact running at slow speed (thankfully not the opposite). I don't think I'll fix this one in 2.6.9, but rather in 2.6.10.
http://gate.crashing.org/~benh/albook-ibookg4-sleep-6.diff
I'll post a 2.6.10-rc2-bk* based version of the patch soon.
Ben.
Signature · 6 lines
My software never has bugs. | ASCII Ribbon Campaign /"\ It just develops random features. | For Standards-Complaint Email \ / Public GnuPG key available at: http://www.keyserver.net X 1024D/203E154B 2003-10-03 Federico Gamio <[email protected]> / \ Key fingerprint = 0B9E 3A19 C88B EBAC 5422 C05F 76B5 B922 203E 154B sub 2048g/32D2F465 2003-10-03
Quoted 1 line · Benjamin Herrenschmidt
Worked like a charm.
Signature · 1 line
Kjetil Orbekk