Kernel 6.11.3-200.fc40 unable to resume from suspend when bluetooth enabled

I worked around this on OpenSUSE Tumbleweed by adding a Systemd script that disables Bluetooth right before suspend and re-enabling it on wake.

Make a file /usr/lib/systemd/system-sleep/bluetooth-toggle.sh and chmod +x it.

Add this to the script:

#!/usr/bin/env bash

# Define a temporary file to store the Bluetooth status
STATUS_FILE="/tmp/bluetooth_status_before_suspend"

case "$1" in
    pre)
        if systemctl is-active --quiet bluetooth.service; then
            systemctl stop bluetooth.service
            echo "enabled" > $STATUS_FILE
            logger -t bluetooth-toggle-script "Bluetooth was active and has been disabled before suspend"
        else
            echo "disabled" > $STATUS_FILE
            logger -t bluetooth-toggle-script "Bluetooth was already disabled before suspend"
        fi
        ;;
    post)
        if [ -f $STATUS_FILE ] && grep -q "enabled" $STATUS_FILE; then
            systemctl start bluetooth.service
            logger -t bluetooth-toggle-script "Bluetooth was re-enabled after resume"
        else
            logger -t bluetooth-toggle-script "Bluetooth remains disabled after resume"
        fi
        rm -f $STATUS_FILE
        ;;
esac

Curious if this would work on Fedora as well. I am on Silverblue so I can’t figure out how to get it to work with an immutable /usr/. You can view logs with journalctl -t bluetooth-toggle-script.

Another option is to switch to the LTS kernel. That worked for me (again on Tumbleweed), but I did experience some minor performance degradation in games.

4 Likes