症状就是每次让x31自己休眠后再启动后放音乐或者电影没声音,程序也不能正常退出。简单的解决方法就是
alsa force-reload
还有更复杂但是应该差不多是全自动的方法
After pulling hair trying to figure out what's going on, I've found a slightly more elegant solution to the problem.
The big hint is the fact that nothing
under /etc/acpi/resume.d or /etc/acpi/suspend.d is actually executed if the gnome-power-manager is running.
Note: The problem of reloading the mixer still applies.
I haven't yet figured out how to programatically reload it after a resume.
Step 1: Modify /etc/default/alsa
and change "force_unload_modules_before_suspend" to:
Code:
force_unload_modules_before_suspend="snd_hda_intel"
Step 2: Create /usr/lib/pm-utils/sleep.d/45sound
Code:
#!/bin/bash if [ ! -x /sbin/alsa ]; then exit 0; fi case "$1" in hibernate|suspend) /sbin/alsa suspend ;; thaw|resume) /sbin/alsa resume ;; *) ;; esac exit $?
Step 3: Make /usr/lib/pm-utils/sleep.d/45sound executable:
Code:
chmod +x /usr/lib/pm-utils/sleep.d/45sound
That's it. Sound should now work after resuming a suspended eeepc 900 w/ hardy.