Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 05-22-07, 10:31 AM   #13
m-singh
Registered User
 
Join Date: May 2007
Posts: 40
Default Re: SUSPEND works; HIBERNATE will not poweroff

Quote:
Originally Posted by gbil
I have a desktop system with core 2 duo + 8800gts and both suspend to ram and disk work fine using the kernel suspend system and not suspend2 .

Have you ever thought that the problem might be elsewhere? And pls pls pls stop whining!
Just recompiled kernels and tried swsusp.

Upshot :

With the nvidia binary driver and from graphical display, ACPI S4 suspend does NOT work. It fails to poweroff as before. Upon hard reset and reboot, the earlier tale of woe follows. I get a message that goes by really fast (can't find it in dmesg, messages or syslog) :

resume : libgcrypt something loaded
resume : cannot read image.

Probably not surprising considering that it earlier failed to write the image. I have tried the Magic Sysrq trick as well (to flush the disks at the end) - no use.

I also tried uswsusp with the following settings :

# /etc/uswsusp.conf(8) -- Configuration file for s2disk/s2both
resume device = /dev/sda5
early writeout = y
image size = 483844751
RSA key file = /etc/uswsusp.key
compute checksum = y

During dpkg-reconfigure, I specifically refused encryption and compression support (I do not have any LZF support in my non-suspend2 patched kernel).

Kernel versions tried :

2.6.20 and 2.6.18-4-686 (Debian vanilla kernel).
Nvidia driver : 9755

/var/log/suspend2disk.log contains no helpful error messages :

suspend2disk initiated: 2007-05-22 07:46:47 AM
Debug info follows here, please include in your bug reports. Thanks.
--------------------------------------------------------------------
Loaded modules:
Module Size Used by
ipw3945 181284 1
ieee80211 29416 1 ipw3945
ieee80211_crypt 5952 1 ieee80211
wacom 15616 0
binfmt_misc 10984 1
cpufreq_ondemand 6636 1
cpufreq_powersave 1920 0
rfcomm 34584 7
l2cap 21696 5 rfcomm
xfrm_user 20352 0
xfrm4_tunnel 2624 0
tunnel4 3396 1 xfrm4_tunnel
ipcomp 7336 0
esp4 7648 0
ah4 6336 0
irda 162588 0
crc_ccitt 2240 1 irda
ppdev 8676 0
parport_pc 32132 0
lp 11012 0
parport 33256 3 ppdev,parport_pc,lp
video 15108 0
sbs 14404 0
i2c_ec 5088 1 sbs
dock 7276 0
button 6672 0
battery 9636 0
container 4448 0
ac 5188 0
asus_acpi 15320 0
ipv6 226016 14
deflate 3840 0
zlib_deflate 18200 1 deflate
twofish 43136 0
serpent 19008 0
aes 28160 0
blowfish 9440 0
des 17536 0
sha256 11104 0
sha1 2656 0
crypto_null 2656 0
af_key 32016 0
xfs 475800 1
fuse 39828 1
dm_snapshot 15552 0
dm_mirror 19152 0
dm_mod 50232 2 dm_snapshot,dm_mirror
microtek 8224 0
tun 10336 0
speedstep_centrino 8384 2
freq_table 4576 1 speedstep_centrino
cpufreq_userspace 4448 0
i8k 6072 1
nvidia 6835988 22
joydev 9088 0
snd_hda_intel 17332 2
snd_hda_codec 137856 1 snd_hda_intel
snd_pcm_oss 38368 0
snd_pcm 68676 3 snd_hda_intel,snd_hda_codec,snd_pcm_oss
snd_mixer_oss 15200 1 snd_pcm_oss
snd_seq_dummy 3844 0
snd_seq_oss 28768 0
snd_seq_midi 8192 0
snd_rawmidi 22560 1 snd_seq_midi
pcmcia 34140 0
snd_seq_midi_event 7008 2 snd_seq_oss,snd_seq_midi
snd_seq 45680 6 snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_seq_mid i_event
snd_timer 20996 2 snd_pcm,snd_seq
snd_seq_device 7820 5 snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_rawmidi ,snd_seq
snd 47012 14 snd_hda_intel,snd_hda_codec,snd_pcm_oss,snd_pcm,sn d_mixer_oss,snd_seq_oss,snd_rawmidi,snd_seq,snd_ti mer,snd_seq_device
intel_agp 21148 1
psmouse 35016 0
i2c_i801 7468 0
hci_usb 16028 6
yenta_socket 24460 1
rsrc_nonstatic 11840 1 yenta_socket
pcmcia_core 36852 3 pcmcia,yenta_socket,rsrc_nonstatic
serio_raw 6660 0
i2c_core 19680 3 i2c_ec,nvidia,i2c_i801
agpgart 29896 2 nvidia,intel_agp
bluetooth 45956 15 rfcomm,l2cap,hci_usb
firmware_class 9600 2 ipw3945,pcmcia
soundcore 9248 1 snd
snd_page_alloc 9640 2 snd_hda_intel,snd_pcm
eth1394 18212 0
rtc 12372 0
ohci1394 30800 0
ieee1394 86904 2 eth1394,ohci1394
sd_mod 19040 8
thermal 13608 0
processor 28840 2 speedstep_centrino,thermal
fan 4804 0
tg3 94948 0
ide_cd 36064 0
ide_disk 14848 0
generic 5476 0 [permanent]
ide_generic 1408 0 [permanent]
ide_core 110504 4 ide_cd,ide_disk,generic,ide_generic
vga16fb 11340 1
vgastate 7776 1 vga16fb
usbhid 37248 0
uhci_hcd 21164 0
ehci_hcd 28136 0
usbcore 112644 7 wacom,microtek,hci_usb,usbhid,uhci_hcd,ehci_hcd
reiserfs 212640 2
ext3 119240 3
jbd 52456 1 ext3
mbcache 8356 1 ext3
sr_mod 15876 0
cdrom 32544 2 ide_cd,sr_mod
sg 31292 0
ata_piix 13576 7
libata 89396 1 ata_piix
scsi_mod 124168 5 microtek,sd_mod,sr_mod,sg,libata
tsdev 7520 0
evdev 9088 2

Memory info:
total used free shared buffers cached
Mem: 1035148 681552 353596 0 44192 434948
-/+ buffers/cache: 202412 832736
Swap: 979924 0 979924

/proc/cmdline: root=/dev/sda2 ro resume=/dev/sda5
------------------------------------------------------------------------------
========we are going to sleep, preparing.========
running kernel is grub menu entry 2 (vmlinuz-2.6.18-4-686)
== checking runlevel ==
no shutdown/reboot in progress, good.
== Unmounting FAT/NTFS filesystems: ==
none found in /etc/mtab
== FAT/NTFS filesystems unmounted ==
Stopping services: ('networking cupsys bluetooth spamassassin guarddog' configured)
stopping networking:
## * Deconfiguring network interfaces...  There is already a pid file /var/run/dhclient.eth0.pid with pid 3364
## killed old client process, removed PID file
## Internet Systems Consortium DHCP Client V3.0.4
## Copyright 2004-2006 Internet Systems Consortium.
## All rights reserved.
## For info, please visit http://www.isc.org/sw/dhcp/
##
## Listening on LPF/eth0/00:15:c5:b5:26:56
## Sending on LPF/eth0/00:15:c5:b5:26:56
## Sending on Socket/fallback
## DHCPRELEASE on eth0 to 18.69.0.33 port 67
## There is already a pid file /var/run/dhclient.eth2.pid with pid 5816
## killed old client process, removed PID file
## Internet Systems Consortium DHCP Client V3.0.4
## Copyright 2004-2006 Internet Systems Consortium.
## All rights reserved.
## For info, please visit http://www.isc.org/sw/dhcp/
##
## Listening on LPF/eth2/48:0e:d5:9b:61:28
## Sending on LPF/eth2/48:0e:d5:9b:61:28
## Sending on Socket/fallback
## DHCPRELEASE on eth2 to 192.168.1.1 port 67
##
[ ok ]
stopping cupsys:
## * Stopping Common Unix Printing System: cupsd 
[ ok ]
stopping bluetooth:
## * Stopping bluetooth 
[ ok ]
stopping spamassassin:
## Stopping SpamAssassin Mail Filter Daemon: spamd.
stopping guarddog:
## Stopping iptables firewall...done.

------------------------------------------------------------------------------
Unloading modules: ('ehci_hcd uhci_hcd usbhid usb_storage wacom bluetooth tun tg3' configured)
checking ehci_hcd
# trying to unload: ehci_hcd
unloaded: ehci_hcd
checking uhci_hcd
# trying to unload: uhci_hcd
unloaded: uhci_hcd
checking usbhid
# trying to unload: usbhid
unloaded: usbhid
checking usb_storage
checking wacom
# trying to unload: wacom
unloaded: wacom
checking bluetooth
# trying to unload: hci_usb
unloaded: hci_usb
# trying to unload: rfcomm
unloaded: rfcomm
# trying to unload: l2cap
unloaded: l2cap
# trying to unload: bluetooth
unloaded: bluetooth
checking tun
# trying to unload: tun
unloaded: tun
checking tg3
# trying to unload: tg3
unloaded: tg3
------------------------------------------------------------------------------
prepare_sleep finished for suspend2disk
------------------------------------------------------------------------------
preparing boot-loader: selecting entry 2, kernel /boot/2.6.18-4-686
/boot/grub/menu.lst: default is not set to saved, not preparing bootloader
time needed for sync: 1.1 seconds, time needed for grub: 0.0 seconds.
calculated image_size: 500

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

If you want to consider the above to be "whining" as well, be my guest.

There does not seem to be any getting away from the fact that nvidia drivers are broken as far as ACPI S4 suspend is concerned despite the advertisement to the contrary in the readme file.
m-singh is offline   Reply With Quote
Old 05-23-07, 09:42 PM   #14
cement_head
Registered User
 
Join Date: Jun 2006
Posts: 22
Default Re: SUSPEND works; HIBERNATE will not poweroff

Hey m-singh,

Does
Code:
$ shutdown -h now
shutdown your machine and power it off?

Saved & close everything before trying

- CH
cement_head is offline   Reply With Quote
Old 05-23-07, 11:54 PM   #15
m-singh
Registered User
 
Join Date: May 2007
Posts: 40
Default Re: SUSPEND works; HIBERNATE will not poweroff

Quote:
Originally Posted by cement_head
Hey m-singh,

Does
Code:
$ shutdown -h now
shutdown your machine and power it off?

Saved & close everything before trying

- CH
Never failed to power down when shutting down. But just to be certain, I did try what you suggested. Powers down as expected.

Its only hibernate that does not power down, when using nvidia drivers.
m-singh is offline   Reply With Quote
Old 05-24-07, 06:31 AM   #16
quintesse
Registered User
 
Join Date: Feb 2006
Posts: 11
Default Re: SUSPEND works; HIBERNATE will not poweroff

@cement_head: did you try swsusp2? Because persoanlly I've never been able to get the in-kernel hibernate to work while swsusp2 has been working flawlessly for a couple of years now (keeping up with new kernels and new nVidia drivers).

(Did need to set the "ProcSetting extra_pages_allowance 0" for it to work)
quintesse is offline   Reply With Quote
Old 05-24-07, 06:56 AM   #17
lloeki
Arch Linux
 
lloeki's Avatar
 
Join Date: Oct 2006
Posts: 122
Default Re: SUSPEND works; HIBERNATE will not poweroff

I am convinced your problem is not of not powering off, because I think suspend2/swsusp never even reach the 'poweroff' call. for me, it hangs the computer way before reaching that point.

simplified, hibernation (suspend2, but swsusp does work just the same) works that way:
1 initialization
2 processes freezing
3 main memory pages writing
4 kernel freezing & copying
5 kernel memory pages writing
6 poweroff

2 and 3 usually goes well
4 is 'doing atomic copy' part where computer appears to "hang" for ~1s, because kernel is voluntarily frozen
5 usually goes well
6 isn't an issue, unless shutdown -h now doesn't work

to ease 4 (and to be more fault resilient), a certain version of suspend2 introduced a 'finding driver allowance' in 1, which was previously done in 4. during that part (whether done in 1 or 4 doesn't matter), kernel modules are queried and disabled (or scheduled to disable) in a certain way, so that they won't interrupt the kernel during the 'atomic copy' part (which must be, by definition, atomic).
the thing is, nvidia's module supposedly makes the kernel panic in that case, with an 'off' screen and a 'refuse to powerdown' state.
when it works (because I have a w7j laptop where it works, so I can compare), at the driver query phase, you can see the screen goes off a split second, then back on as the nvidia driver is queried, and then suspend2 continues with the next phase. but when it fails (on my xps with same hardware), the screen goes off, but never turns back on. and since in that case there is no life sign from the computer (no sysrq), I reckon the kernel has badly panic'ed, or it entered an endless loop, or some racing of that sort.
lloeki is offline   Reply With Quote
Old 05-24-07, 07:16 AM   #18
cement_head
Registered User
 
Join Date: Jun 2006
Posts: 22
Default Re: SUSPEND works; HIBERNATE will not poweroff

been talking to some better linuxheads than I, the problem is likely in the ACPI subsystem. The 'nvidia' module hangs the system because it isn't getting unloaded. We are going to have to change the code to forcefully unload the 'nvidia' module.

I'll try some hacks and get back to this post


cement_head is offline   Reply With Quote
Old 05-24-07, 12:02 PM   #19
m-singh
Registered User
 
Join Date: May 2007
Posts: 40
Default Re: SUSPEND works; HIBERNATE will not poweroff

Quote:
Originally Posted by quintesse
@cement_head: did you try swsusp2? Because persoanlly I've never been able to get the in-kernel hibernate to work while swsusp2 has been working flawlessly for a couple of years now (keeping up with new kernels and new nVidia drivers).

(Did need to set the "ProcSetting extra_pages_allowance 0" for it to work)
Yes, and yes.

suspend2 was my preferred suspend method. Until I bought this dual core laptop (and SMP problems were not sorted by Nigel until patch 2.2.9.13).

And I yes, I tried that ProcSetting (its in my /etc/hibernate/suspend2.conf). Also had echo 0 > /sys/power/suspend2/extra_pages_allowance in my /etc/rc.local as well at one point in time (just to make certain that things were working).

I get precisely the same symptoms with suspend2 and in kernel suspend. Suspend to RAM (ACPI S3) works flawlessly in both cases. Suspend to disk works near flawlessly (sometimes I have a missing cursor upon resume) if I use open source nv drivers with X running, or works flawlessly if I stop X, unload nvidia driver and then suspend to disk (a satisfying parlour game, which is of no practical use at all).

hibernate (with suspend2 and the text userui) and suspend to disk with kpowersave using in kernel suspend (ACPI S4) does not unmount the disks (as evidenced by the fact that they are fsck'ed upon hard reset and boot) and does not poweroff.

I am beginning to think that this is a hardware related thing and nvidia's drivers just aren't bug free enough to handle it. For starters, my Nvidia 7400 GeForce Go card is not an AGP card, it is the PCI-E variety(whatever that means).
m-singh is offline   Reply With Quote
Old 05-26-07, 04:41 AM   #20
quintesse
Registered User
 
Join Date: Feb 2006
Posts: 11
Default Re: SUSPEND works; HIBERNATE will not poweroff

@m-singh: yes, I saw you tried all that, I wondered if cement_head had done the same.

The only thing I can think of now is to try to contact Nigel (directly or via the suspend2 forums) and try to work it out with him. He is quite busy nowadays with his new life but he has always been very helpfull and maybe working togehter you might be able to find out what goes wrong in your case.
quintesse is offline   Reply With Quote

Old 05-26-07, 07:59 AM   #21
cement_head
Registered User
 
Join Date: Jun 2006
Posts: 22
Default Re: SUSPEND works; HIBERNATE will not poweroff

Quote:
Originally Posted by quintesse
@m-singh: yes, I saw you tried all that, I wondered if cement_head had done the same.

The only thing I can think of now is to try to contact Nigel (directly or via the suspend2 forums) and try to work it out with him. He is quite busy nowadays with his new life but he has always been very helpfull and maybe working togehter you might be able to find out what goes wrong in your case.

I've been digging around Debian developer lists and I think its pretty clear that the 'core' people at Debian believe that the reason machines can't suspend or hibernate is to do with specifics of ACPI interaction with different hardware. Yes, this is an obvious statement, BUT, what it means is that hacking the ACPI scripts should enable suspend and hibernate on ALL machines.

So, if the nv module (the Xorg driver) allows suspend and hibernate, that means the scripts work. If suspend works with the nvidia, but hibernate does not; the implication is that the nvidia module is not being removed from the kernel during the hibernate process, and poweroff won't occur because the module hasn't been unloaded. Suspend doesn't enter into this 'problem' or 'issue' because it isn't doing a poweroff command.

We need to do several things: (a) make sure that the MODULES variable is correctly identifying the nvidia module as loaded; (b) make sure that nvidia module is being loaded at the correct time in the module/boot sequence. This doesn't matter during a regular boot, but is a major issue during a hibernate cycle, and (c) make sure we "force" the unloading of the nvidia module. I'm convinced that the correct order (b) should help alleviate (c).

Thats what I'm working on...and how I'm approaching it.

- CH
cement_head is offline   Reply With Quote
Old 05-26-07, 03:33 PM   #22
m-singh
Registered User
 
Join Date: May 2007
Posts: 40
Default Re: SUSPEND works; HIBERNATE will not poweroff

Quote:
Originally Posted by quintesse
@m-singh: yes, I saw you tried all that, I wondered if cement_head had done the same.

The only thing I can think of now is to try to contact Nigel (directly or via the suspend2 forums) and try to work it out with him. He is quite busy nowadays with his new life but he has always been very helpfull and maybe working togehter you might be able to find out what goes wrong in your case.
I have bugged poor Nigel for months. He and others on the mailing list have been very helpful but there is only so much they can do regarding a buggy driver (confirmed by identical behaviour with suspend2 and swsusp).
m-singh is offline   Reply With Quote
Old 05-26-07, 03:35 PM   #23
m-singh
Registered User
 
Join Date: May 2007
Posts: 40
Default Re: SUSPEND works; HIBERNATE will not poweroff

Quote:
Originally Posted by cement_head
We need to do several things: (a) make sure that the MODULES variable is correctly identifying the nvidia module as loaded; (b) make sure that nvidia module is being loaded at the correct time in the module/boot sequence. This doesn't matter during a regular boot, but is a major issue during a hibernate cycle, and (c) make sure we "force" the unloading of the nvidia module. I'm convinced that the correct order (b) should help alleviate (c).

Thats what I'm working on...and how I'm approaching it.

- CH
Needless to add, I, and many others with this issue, will await your reports with bated breath.

m-singh is offline   Reply With Quote
Old 05-27-07, 01:34 AM   #24
m-singh
Registered User
 
Join Date: May 2007
Posts: 40
Default Re: SUSPEND works; HIBERNATE will not poweroff

Quote:
Originally Posted by cement_head
We need to do several things: (a) make sure that the MODULES variable is correctly identifying the nvidia module as loaded; (b) make sure that nvidia module is being loaded at the correct time in the module/boot sequence. This doesn't matter during a regular boot, but is a major issue during a hibernate cycle, and (c) make sure we "force" the unloading of the nvidia module. I'm convinced that the correct order (b) should help alleviate (c).

Thats what I'm working on...and how I'm approaching it.

- CH
I found the following bizarre report :
http://parrenin.frederic.free.fr/Del...00_Breezy.html


"Hibernate works when my RAM is 500 Mb.

When I have 1 Gb of RAM, the laptop write the data to the swap without problem and shut down.
At startup, it reads the swap but then freezes after these messages (I don't know if they are related to this problem):
Error evaluating _GTM
ACPI: PCI interrupt for devide 0000:02:01.1 disabled
ACPI: PCI interrupt for devide 0000:02:01.0 disabled
ACPI: PCI interrupt for devide 0000:02:1f.5 disabled
Resume=option should be used to set suspend device..............
swsusp: Need to copy 30063 pages
It is really the amount of RAM that counts, because when I use either of my two512 Mb RAM modules, hibernate works, but when I use both, it does not.
Note also that it is not due to the size of my SWAP partition, because I have 1.8 Gb.
This is probably a kernel bug, but I have not investigated more time in this."

I do have 1 GB RAM, but I do not see what does the amount of system memory have to do with this.
m-singh is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
Redhat 8.0 NVIDIA works - INSTRUCTIONS STEEL1 NVIDIA Linux 267 04-15-03 06:48 PM

All times are GMT -5. The time now is 05:22 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.