A work-around mentioned by others in possibly related nvidia bug reports (bug 656279) is to disable hyperthreading processors before suspending and re-enable them after resume. That actually works for this problem as well. The slow performance after resume is gone.
I put the following script into /etc/pm/sleep.d/10_ht.sh :
#!/bin/sh
# Disable hyper-threading processor cores on suspend and hibernate, re-enable them
# on resume. Presumably helps for buggy nvidia or kernel behaviour.
# This file goes into /etc/pm/sleep.d/
case $1 in
hibernate|suspend)
echo 0 > /sys/devices/system/cpu/cpu1/online
echo 0 > /sys/devices/system/cpu/cpu3/online
;;
Of course, the script needs to be adapted according to CPU type of the target system, or improved to just autodetect all hyper-threading processors. I have a Core i7 with two real cores(proc id 0 and 2) and two hyper-threading cores (proc id 1 and 3).
A work-around mentioned by others in possibly related nvidia bug reports (bug 656279) is to disable hyperthreading processors before suspending and re-enable them after resume. That actually works for this problem as well. The slow performance after resume is gone.
I put the following script into /etc/pm/ sleep.d/ 10_ht.sh :
#!/bin/sh
# Disable hyper-threading processor cores on suspend and hibernate, re-enable them
# on resume. Presumably helps for buggy nvidia or kernel behaviour.
# This file goes into /etc/pm/sleep.d/
case $1 in system/ cpu/cpu1/ online system/ cpu/cpu3/ online
hibernate|suspend)
echo 0 > /sys/devices/
echo 0 > /sys/devices/
;;
thaw|resume) system/ cpu/cpu1/ online system/ cpu/cpu3/ online
echo 1 > /sys/devices/
echo 1 > /sys/devices/
;;
esac
Of course, the script needs to be adapted according to CPU type of the target system, or improved to just autodetect all hyper-threading processors. I have a Core i7 with two real cores(proc id 0 and 2) and two hyper-threading cores (proc id 1 and 3).