Fix Linux Suspend/Sleep in Gigabyte B550i Aorus Pro AX

Linux won’t sleep on this motherboard out of the box. I have a rev1.1 motherboard running BIOS version F17b. No idea if this applies to rev1.2. There’s a workaround you can do which is to disable PCIe wakeup on GPP0 (GPP bridge to the m.2 NVMe drives): echo GPP0 | sudo tee /proc/acpi/wakeup. To make this persistent you need to run this command at boot. I do not know why it is like this. systemd/openrc methods to run this at boot:

systemd service:

[Unit]
Description=fix sleep

[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=sh -c 'echo GPP0 > /proc/acpi/wakeup'

[Install]
WantedBy=multi-user.target

openrc:

Ensure local is enabled

rc-update add local default

Create /etc/local.d/fix-sleep.start. As root:

cat >/etc/local.d/fix-sleep.start <<EOF
#!/usr/bin/env bash
echo GPP0 > /proc/acpi/wakeup
EOF

chmod +x /etc/local.d/fix-sleep.start