View Single Post
Old 04-18-06, 12:23 AM   #6
pauljohn
Registered User
 
Join Date: Jul 2005
Posts: 28
Default Re: Suspend/Hibernate - does it work for you?

Suspend does not work for me with the nvidia driver for X. It used to work with the early Fedora Core 3 kernel, which was 2.6.11 or 2.6.12, but in later FC3 and FC4 and FC5, the suspend to RAM or disk and resume fails. The system appears dead, but usually it is really running, with no video turned on. SOmetimes I can ssh into the machine and force it to reboot.

I have Dell Latitude D800 with GO5200FX and a display that is 1680x1050 native.

The main problem I have is that the video does not wake up after the system resumes. I have the same experience using the ACPI support from the kernel, with or without the kernel's agpgart or with Nvidia's agp support. I've tried suspend2. Result is the same. I found suspend to disk to be so slow as to be useless--it is just as slow as rebooting. Suspend to memory is not improved or changed by suspend2. So I ignore that and just try to make the kernel and acpi handle it.

The kernel authors say "it is some flaw in the nvidia driver", but I don't believe it because this used to work in the old days. I believe instead that some kernel tinkering went on, probably to clean up some hack or beautify the structure of something, and they broke whatever it was that used to work. I have not been able to find out which particular mother board dell put in here, but I BELIEVE it is an ASUS motherboard of some type, but the Dell company says they do not know exactly which one (unless I mail it back for them to look over). But they offer no Linux related support or warranty, so I don't bother.

Yesterday, I experimented more on this, and I've learned that I CAN resume if I use the "nv" driver that comes with xorg servers. That only works IF I leave in the vbetool post command in the following script. If I don't have that "post" command, the screen stays dark. If I use the same approach with Nvidia's driver, the X screen is just a blur of awful looking colors and I'm afraid it is damaging the display.

HEre are the acpi scripts that DO work with the "nv" driver.

action sleep:

$ cat /etc/acpi/events/sleep
# /etc/acpid/events/sleep

event=button[/]sleep
action=/etc/acpi/actions/sleep.sh %e


sleep.sh:

$ cat /etc/acpi/actions/sleep.sh
#!/bin/sh

# do not got to suspend mode if some command fails!
set -e

PATH="/sbin:/bin:/usr/sbin:/usr/bin"


rmmodules () {
mname=$1
if grep $mname /proc/modules ; then
/sbin/rmmod $mname
fi
}

# if network is up, shut it down!
if [ -f /var/lock/subsys/network ] ; then
/sbin/service network stop
fi

/sbin/service syslog stop

# remmod all problematic modules
rmmodules tg3
rmmodules uhci_hcd
rmmodules ehci_hcd
rmmodules hci_usb
rmmodules ipw2200

/usr/bin/chvt 1

echo mem > /sys/power/state

/usr/sbin/vbetool post

# after waking up, move to terminal 1, this give some time to graphic card to get into sane state
# sleep 0.5
# change into gui terminal, graphic card is ok at this point
/usr/bin/chvt 7

/sbin/hwclock --hctosys

#load modules
/sbin/modprobe uhci_hcd
/sbin/modprobe ehci_hcd
/sbin/modprobe ipw2200
/sbin/service syslog start
/sbin/ifup lo
/sbin/ifup eth1

--------------------

Now, just one other thing. About AGP support. THe old linux never did work with the native AGP turned on. So I had this in xorg.conf:

Option "NvAGP" "1"

and it did work. No vbetool magic was needed in my sleep.sh script or anything. Now, however, the /var/log/Xorg.0.log file shows that the NvAGP module cannot load because the kernel already has agpgart service loaded.

One can re-compile the kernel to remove AGP-nv (change "y" to "m" or "n"), but that's a hassle. So add the command line option agp=off line to the kernel line (say, in /etc/grub.conf) or at startup time. That allows the Nvidia AGP to load.

However, I'm still left with the dark screen.

Good luck. I hope you solve it. This has been the most frustrating, long-enduring hassle in the 10 years I've been playing around with Linux. Even worse than owning a Matrox Mystique on a Pentium-75 with kernel 2.0. And that was the pits!

Sincerely,

Paul Johnson
Professor, Political Science
University of Kansas
pauljohn is offline   Reply With Quote