suspend => instant wakeup please help
Hi,
I have searched and found this thread on the archlinux.org board, however, I cannot even check /var/log/pm-suspend.log, because this file does not exist.
My /etc/systemd/logind.conf file is unmodified, except that I added the line HandleLidSwitch=ignore, so this is my entire logind.conf (stripped all commented lines)
[Login]
HandleLidSwitch=ignore
The files contains of 40 lines in total, however, all other lines begin with #, so they should not matter.
When I sudo systemctl suspend, my laptop will, indeed, suspend. Then, after only a few seconds, it will turn itself back on. I remember reading about this (but can't find the exact threat anymore) possibly having to do with USB hubs. In fact, I use two USB hubs, so this might be the reason. However, I don't know what to do about it. I do remember that, when I read that threat, I tried to follow the proposed solution step by step and could not get it working either (unfortunately, I do not remember what those steps were at the moment).
Here is $ lspci
00:00.0 Host bridge: Intel Corporation Crystal Well DRAM Controller (rev 08)
00:01.0 PCI bridge: Intel Corporation Crystal Well PCI Express x16 Controller (rev 08)
00:01.1 PCI bridge: Intel Corporation Crystal Well PCI Express x8 Controller (rev 08)
00:14.0 USB controller: Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI (rev 05)
00:16.0 Communication controller: Intel Corporation 8 Series/C220 Series Chipset Family MEI Controller #1 (rev 04)
00:1b.0 Audio device: Intel Corporation 8 Series/C220 Series Chipset High Definition Audio Controller (rev 05)
00:1c.0 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #1 (rev d5)
00:1c.2 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #3 (rev d5)
00:1c.3 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #4 (rev d5)
00:1c.4 PCI bridge: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #5 (rev d5)
00:1f.0 ISA bridge: Intel Corporation HM87 Express LPC Controller (rev 05)
00:1f.3 SMBus: Intel Corporation 8 Series/C220 Series Chipset Family SMBus Controller (rev 05)
01:00.0 VGA compatible controller: NVIDIA Corporation GK107M [GeForce GT 750M Mac Edition] (rev a1)
01:00.1 Audio device: NVIDIA Corporation GK107 HDMI Audio Controller (rev a1)
03:00.0 Network controller: Broadcom Inc. and subsidiaries BCM4360 802.11ac Wireless Network Adapter (rev 03)
04:00.0 Multimedia controller: Broadcom Inc. and subsidiaries 720p FaceTime HD Camera
05:00.0 SATA controller: Samsung Electronics Co Ltd Apple PCIe SSD (rev 01)
06:00.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt 2 Bridge [Falcon Ridge 4C 2013]
07:00.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt 2 Bridge [Falcon Ridge 4C 2013]
07:03.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt 2 Bridge [Falcon Ridge 4C 2013]
07:04.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt 2 Bridge [Falcon Ridge 4C 2013]
07:05.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt 2 Bridge [Falcon Ridge 4C 2013]
07:06.0 PCI bridge: Intel Corporation DSL5520 Thunderbolt 2 Bridge [Falcon Ridge 4C 2013]
08:00.0 System peripheral: Intel Corporation DSL5520 Thunderbolt 2 NHI [Falcon Ridge 4C 2013]
and $ lsusb
Bus 002 Device 003: ID 05ac:8406 Apple, Inc.
Bus 002 Device 006: ID 0bda:8153 Realtek Semiconductor Corp. RTL8153 Gigabit Ethernet Adapter
Bus 002 Device 005: ID 05e3:0617 Genesys Logic, Inc.
Bus 002 Device 004: ID 05e3:0617 Genesys Logic, Inc.
Bus 002 Device 002: ID 05e3:0617 Genesys Logic, Inc.
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 010: ID 05ac:8289 Apple, Inc.
Bus 001 Device 003: ID 0a5c:4500 Broadcom Corp. BCM2046B1 USB 2.0 Hub (part of BCM2046 Bluetooth)
Bus 001 Device 012: ID 0922:001f Dymo-CoStar Corp.
Bus 001 Device 014: ID 1a2c:2124 China Resource Semico Co., Ltd
Bus 001 Device 013: ID 045b:0209 Hitachi, Ltd
Bus 001 Device 011: ID 045b:0209 Hitachi, Ltd
Bus 001 Device 009: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
Bus 001 Device 007: ID 093a:2533 Pixart Imaging, Inc.
Bus 001 Device 004: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
Bus 001 Device 002: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
Bus 001 Device 005: ID 05ac:0263 Apple, Inc. Apple Internal Keyboard / Trackpad (MacBook Retina)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
I know that one of those outputs had to do with the proposed solution I had read before; however, I don't know where to go from there, neither am I able to find that exact post. Also, as I have mentioned above, I have already tried recreating the steps mentioned there, yet was not able to fix this problem.
While I don't think it matters for this specific problem, I'll try to give some more information. $ uname -a => Linux archbook 5.0.6-arch1-1-ARCH #1 SMP PREEMPT Wed Apr 3 09:35:20 UTC 2019 x86_64 GNU/Linux, WM is i3 version 4.16.1 (2019-01-27) © 2009 Michael Stapelberg and contributors. My USB hubs are atolla USB3.0HUB and showtech superspeed 3.0 USB Hub, both of which are powered by an external power source (so they stay on when my laptop turns off/suspends).
Trying to give some more information... I have had these hubs for quite a while, however, they had not caused my laptop to wake up from suspend before - however, before I was using OSX (yeah, I know... at least I have finally switched to Arch now :)), and while suspending was never a problem, there was actually a huge one: if I would turn of my Macbook (which I rarely did), and then turn it one, it got stuck before even displaying anything. That made my blood pressure rise each time, because due to rarely rebooting, this occurred seldomly enough for me to forget that supposedly one of those USB hubs caused this. Once I disconnected both hubs (one hub connected via the other, so disconnecting one particular hub would automatically disconnect the other as well), the device would boot and let me login; thereafter I was able to connect the hubs again.
However, I have tried to investigate whether these hubs (or one of them) sends any keyboard or mouse input, which they didn't. I just tried to find the tool I had used for this, but was not able to locate it. It was xsomething (one of the X server commands that would open a new window and wait for user input, then display what key(s) had been pressed); this did not return anything, and I let it run for a while. So there should not be any involuntary mouse button or keyboard key presses coming from these hubs, unless, for some reason, the tool would just ignore them.
What can I do to figure out what is causing this problem? My first thought was to add a command to disable USB ports upon starting my suspsend script (which is pretty much just i3lock && sudo systemctl suspend with some additional i3lock parameters, which are just for optics (so not related to suspend altogether) and then figuring out how to re-enable USB ports upon waking up my device. While this would be a temporary fix, though, it is not practicable; my laptop is closed most of the time, unless I have to open it. Which is usually only the case when turning it on because I need to reach the power button. If I have to open the laptop for each wake up from suspend, I might as well just shut down my system each time. (Arch is booting blazingly fast, so while wake up would be even faster, I could live with those few seconds booting freshly as well)
I hope I have explained everything in an understandable way. I am not a native English speaker, so if something is unclear, please just ask. I have tried researching a solution as well, but those two I had found did not work for me due to me not being able to reproduce those steps.
Any help is greatly appreciated. I started using Arch as my main OS about a month ago and wish I had years ago already. The minimalism combined with the possibility of tweaking and adding anything and everything is wonderful, and I have never had that with previous systems (mostly because they came with a GUI installer and DE right after setup). So thanks in advance for your help :)
About this post
- Posted
- Archived
- Score
- 6 · 100% up
- Kind
- Text
- ID
- basm0m
16 comments
I’ve been having this exact same issue too on a ThinkPad T580 for a while now
Have you tried the solution /u/MoonshineFox suggested? It works for me. The device will not automatically wake up from suspend any longer.
Question: What does ethtool tell you about WoL?
# ethtool interface | grep Wake-onWhen I ran
ethtoolas root, it displayedSupports Wake-On: pumbgandWake-On: pumbg(regular user seems not to be allowed to access these values).~ prompt means regular user and # prompt means root. Its a neat shorthand but can bite you if you're not paying attention.
Yeah, there's your problem. It wakes up on *any* network activity. You should change it to
monly so that it only wakes up on Wake-On-LAN "magic" packets.sudo ethtool -s IF wol mThat should take care of the instant wakeup.
Deleted before we saved it.
If it only says
I guess that means there is no problem here?
In my case (Lenovo Thinkpad T470p) I had to disable acpi wakeup on the XHC device.
Check if you have such a device:
grep XHC /proc/acpi/wakeupIf you do and its status is enabled, try to disable it:
echo XHC > /proc/acpi/wakeupand then test suspend.I have this command in a oneshot systemd service so that it takes effect at every boot.
Same problem. Stuck on an old 4.19 kernel to be able to suspend. Asus laptop.
I got this issue after 4.20 kernel and opened a thread but no one answered. You can try installing lts kernel and check if problem occurs with it.