Tim*_*son 4 gnome suspend power-management 18.04
我在纯英特尔 Thinkpad T480 上安装了 Ubuntu 18.04。它通常连接到几个外部显示器。如果我从电源图标选择挂起(按住 Alt),笔记本电脑将启动挂起过程,并且两个外接显示器进入挂起模式。笔记本电脑上的 LED 开始闪烁周期以指示挂起。但一秒钟后,笔记本电脑 LED 又恢复亮起。显示器不会再次启动,但只要移动无线鼠标,外接显示器就会打开。所以它不会进入挂起状态。
更新:
大多数时候它都有效。我想我必须看这个并尝试在它不起作用时找到一些日志记录
更新:journalctl | grep 暂停:
pci_pm_suspend(): hcd_pci_suspend+0x0/0x30 returns -16
Jun 17 16:57:46 moncrief kernel: dpm_run_callback(): pci_pm_suspend+0x0/0x150 returns -16
Jun 17 16:57:46 moncrief kernel: PM: Device 0000:00:14.0 failed to suspend async: error -16
Jun 17 16:57:46 moncrief kernel: PM: Some devices failed to suspend, or early wake event detected
Run Code Online (Sandbox Code Playgroud)
由 lspci 提供,该设备是
00:14.0 USB controller: Intel Corporation Sunrise Point-LP USB 3.0 xHCI Controller (rev 21)
Run Code Online (Sandbox Code Playgroud)
基于戴尔 Inspiron 灵越的类似问题
https://gist.github.com/ioggstream/8f380d398aef989ac455b93b92d42048
Run Code Online (Sandbox Code Playgroud)
我安装在
/lib/systemd/system-sleep
Run Code Online (Sandbox Code Playgroud)
这里的脚本: https://gist.github.com/timrs2998/77b3c2c2567cbd38f38cde64f1155956#file-system-sleep-xhci-sh
作者:Roberto Polli (ioggstream)
创建文件后,不要忘记
sudo chmod u+x
Run Code Online (Sandbox Code Playgroud)
...
#!/bin/sh
#
# This script should prevent the following suspend errors
# which block suspend on Dell Inspiron laptop & Thinkpad T480.
#
# Put it in /usr/lib/systemd/system-sleep/xhci.sh
#
# The PCI 00:14.0 device is the usb xhci controller.
#
# kernel: [67445.560610] pci_pm_suspend(): hcd_pci_suspend+0x0/0x30 returns -16
# kernel: [67445.560619] dpm_run_callback(): pci_pm_suspend+0x0/0x150 returns -16
# kernel: [67445.560624] PM: Device 0000:00:14.0 failed to suspend async: error -16
# kernel: [67445.886961] PM: Some devices failed to suspend, or early wake event detected
if [ "${1}" == "pre" ]; then
# Do the thing you want before suspend here, e.g.:
echo "Disable broken xhci module before suspending at $(date)..." > /tmp/systemd_suspend_test
grep XHC.*enable /proc/acpi/wakeup && echo XHC > /proc/acpi/wakeup
elif [ "${1}" == "post" ]; then
# Do the thing you want after resume here, e.g.:
echo "Enable broken xhci module at wakeup from $(date)" >> /tmp/systemd_suspend_test
grep XHC.*disable /proc/acpi/wakeup && echo XHC > /proc/acpi/wakeup
fi
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
2584 次 |
最近记录: |