Nvidia can't make my pc sleep

Here the output of inxi -Fxxc0z | eos-sendlog

  • the pc wakes up immediatly, it doesn’t even sleep but the screen turns off.
    so, running sudo dmesg gives this notable error:
[  178.201105] nvidia 0000:06:00.0: PM: pci_pm_suspend(): nv_pmops_suspend+0x0/0xf0 [nvidia] returns -5
[  178.201483] nvidia 0000:06:00.0: PM: dpm_run_callback(): pci_pm_suspend+0x0/0x1c0 returns -5
[  178.201488] nvidia 0000:06:00.0: PM: failed to suspend async: error -5
[  178.206101] sd 1:0:0:0: [sdb] Synchronizing SCSI cache
[  178.206124] sd 0:0:0:0: [sda] Synchronizing SCSI cache
[  178.206127] sd 2:0:0:0: [sdc] Synchronizing SCSI cache
[  178.206155] sd 1:0:0:0: [sdb] Stopping disk
[  178.206161] sd 0:0:0:0: [sda] Stopping disk
[  178.208283] sd 2:0:0:0: [sdc] Stopping disk
[  178.215255] sd 3:0:0:0: [sdd] Stopping disk
[  179.342836] PM: Some devices failed to suspend, or early wake event detected
  • What I tried:
  1. purging nvidia proprietary driver install nouveau, rebooting and reinstalling the proprietary
  2. enabling the following nvidia services:
  • systemctl enable nvidia-hibernate.service
  • systemctl enable nvidia-suspend.service
  • systemctl enable nvidia-suspend.service
  • What changed?
  1. nothing
  2. now the pc sleeps, but it appears I can’t wake it up. I have to force the shutdown using the tower button.

Do you use the resume = kernel parameters?

https://wiki.archlinux.org/title/Power_management/Suspend_and_hibernate#top-page

I have the laptop version of the RTX3070, can’t remember exactly what I did, but I definitely followed the Arch wiki and I needed:

nVidia resume from suspend

sudo nano /etc/modprobe.d/nvidia-power-management.conf

Then add the following line

options nvidia NVreg_PreserveVideoMemoryAllocations=1 NVreg_TemporaryFilePath=/var/tmp

Thank you very much for your answer. Not sure if I got what I should have done, so please bear with me.

EDIT: You might have referred to edit the line in GRUB, but I don’t have a swap partition, can I do somehow do it on ram?

Here what I got before the edit for the sake of clarity:
my /sys/power/state file has this inside: freeze mem disk. Isn’t it right to use suspension-to-idle mode?
Also this raised a doubt in me: I would like to enable sleep to ram, so I checked in my .config file it it’s supported (CONFIG_SUSPEND=y CONFIG_SUSPEND_FREEZER=y), standby mem disk?
Because I can’t edit with nano, so I tried using echo xx > file. I tried with echo mem > /sys/power/state and it is the same way in the post, with the same error in dsmesg.

as for what @xircon suggested, it was already like that but it won’t still work.

See Number 10, here:
https://wiki.archlinux.org/title/NVIDIA/Tips_and_tricks
That is what I followed.