3.5.1 hid_generic causes mouse locking until a button is clicked

Started by Dâniel Fraga on Aug 11, 2012 · 5 messages from 3 authors · Last reply Aug 13, 2012

open the first message on its own page

Message details and related content
	I upgraded from 3.4.4 to 3.5.1 kernel and now I see the new
hid_generic module is causing problem with my mouse (a regular Logitech
USB optical mouse).

	The problem is: after 2 seconds without moving the mouse, the
pointer will NOT move again UNLESS I click a mouse button.

	So now I have to click a button everytime I want to "unlock"
the mouse pointer. It didn't happen with 3.4.4 so it's clearly a
regression.

Any hints? I can try patches. Thanks.

-- 
http://www.youtube.com/DanielFragaBR

Message details and related content
Hi,

On Sat, 11 August 2012 Dâniel Fraga [off-list ref] wrote:
	I upgraded from 3.4.4 to 3.5.1 kernel and now I see the new
hid_generic module is causing problem with my mouse (a regular Logitech
USB optical mouse).

	The problem is: after 2 seconds without moving the mouse, the
pointer will NOT move again UNLESS I click a mouse button.

	So now I have to click a button everytime I want to "unlock"
the mouse pointer. It didn't happen with 3.4.4 so it's clearly a
regression.

Any hints? I can try patches. Thanks.
This might be USB-autosuspend. 2 seconds seems to match the default
delay for autosuspending USB devices.

Have a look at the values under /power/ for your USB devices.
(probably the port to which your mouse is connected and/or the mouse
itself).
Check if disabling USB-autosuspend helps.

Compare the output of:
  grep . /sys/bus/usb/devices/*/power/*
for the time your mouse can move your pointer and when it can't.
Also change the autosuspend delay or disable autosuspend for the
mouse.

See also in your kernel sources:
  Documentation/usb/power-management.txt
  Documentation/ABI/testing/sysfs-bus-usb


Bruno
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Message details and related content
On Sun, 12 Aug 2012 19:53:29 +0200
Bruno Prémont [off-list ref] wrote:
This might be USB-autosuspend. 2 seconds seems to match the default
delay for autosuspending USB devices.
	Hi Bruno. That's it! 

	I raised the autosuspend value and I'm using it as a
workaround... but the default values are the same as the kernel 3.4.4
values, so something has changed:

/sys/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.6/power$ cat
autosuspend* 
2 <----- autosuspend
2000 <-- autosuspend_delay_ms

	So, if the values are the same, why the behaviour has changed
from kernel 3.4 to 3.5?

	I mean, it seems that with kernel 3.4 simply moving the mouse
would wake up the usb port and now with kernel 3.5 it only works if I
press a button.

	So, kernel 3.5 is supposed to wake up the usb port when we move
the mouse or not?

	Is there a way to restore the old behaviour from kernel 3.4?
	
	Thanks.

-- 
Linux 3.5.1: Saber-toothed Squirrel
http://www.youtube.com/DanielFragaBR
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Message details and related content
On Sunday 12 August 2012 18:16:22 Dâniel Fraga wrote:
	I mean, it seems that with kernel 3.4 simply moving the mouse
would wake up the usb port and now with kernel 3.5 it only works if I
press a button.

	So, kernel 3.5 is supposed to wake up the usb port when we move
the mouse or not?
The kernel doesn't do this. Mice are told to wake up when they have input
data. They decide themselves what data should be collected while they
sleep. The USB HID spec offers no way to learn what will wake up a device.
In fact, it does'nt mention power management.
	Is there a way to restore the old behaviour from kernel 3.4?
Probably the device didn't autosuspend. Disable autosuspension.

	Regards
		Oliver

--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Message details and related content
On Mon, 13 Aug 2012 08:30:35 +0200
Oliver Neukum [off-list ref] wrote:
The kernel doesn't do this. Mice are told to wake up when they have input
data. They decide themselves what data should be collected while they
sleep. The USB HID spec offers no way to learn what will wake up a device.
In fact, it does'nt mention power management.
	Ok.
Probably the device didn't autosuspend. Disable autosuspension.
	Nice, this is a good workaround:

/sys/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.6/power$ echo -1 >
autosuspend

	Now it's correct. Thank you ;)

-- 
Linux 3.5.1: Saber-toothed Squirrel
http://www.youtube.com/DanielFragaBR
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help