症状就是每次让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.
本文提供了解决x31在休眠后播放音乐或电影时无声的问题,包括通过修改配置文件和创建自定义脚本来自动重启音频混音器的方法。此外,还详细介绍了如何避免在gnome-power-manager运行时执行/etc/acpi/resume.d或/etc/acpi/suspend.d中的命令。

1220

被折叠的 条评论
为什么被折叠?



