Debian enables the solution of the power-off problem of the mouse when the laptop mode tools is turned on

Laptop mode tools is a common standard tool for laptops running Linux. It is often called “power saving mode” in Chinese Linux community. Its principle is to reduce the power consumption of laptops running Linux by slowing down the hard disk and CPU, automatically sleeping part of USB and other ways< this tool is very popular because it greatly improves the endurance of Linux notebook. However, it is often injured by mistake. For example, Kaijia’s USB mouse is shot every time. When the mouse starts and enters grub interface, everything is normal. After that, when the laptop mode tools starts (enabled), the mouse will automatically power off and sleep, no matter whether it is connected to the power supply or whether the power saving mode is activated ([not] active). It needs to be re plugged every time before it can be used normally

this problem has existed for a long time, and a large number of Posts and blogs in the Chinese community have provided solutions. The core idea is that the mouse auto hibernation is controlled by the USB autosuspend module of the laptop mode tools tool, so the solution can be divided into two kinds:

Edit/etc/laptop mode/conf.d/usb-autosuspend.conf to write the mouse into the blacklist of forbidding auto hibernation, such as this article
disable the USB autosuspend module directly, such as this post
in Ubuntu 14.04 and 12.04, this method can work normally. However, in the laptop mode tools 1.65, the developer has removed the USB autosuspend module, so in Ubuntu 16.04 (running the 1.68 version of the laptop mode tools), the above methods can no longer be used

so Kaijia studied the change log and found that the reason given by the developer was that the runtime power management framework had been strengthened. Following suit, Kaijia found a configuration item with similar function in the new configuration file/etc/laptop mode/conf.d/runtime-pm.conf. The name of the configuration item has been changed by autosuspend_ USBTYPE_ Blacklist changed to autosuspend_ RUNTIME_ DEVTYPE_ BLACKLIST 。 So, referring to the previous method, line 45:

AUTOSUSPEND_RUNTIME_DEVTYPE_BLACKLIST=""

Change to:

AUTOSUSPEND_RUNTIME_DEVTYPE_BLACKLIST="usbhid usb-storage"

After saving and restarting the computer, the mouse will not power off automatically again

in addition, the developer of this tool is careless, and the sample code parameter above this line in the configuration file is wrong (# example:
autosuspend)_ DEVID_ Blacklist = “USB HID USB storage”)

Similar Posts: