Battery mode creates lag on peripherals like mouse and keybord

Hi

When I disconnect my lenovo Thinkpad T410 running OpenSuse 12.1 from mains, my peripherals get a huge lag. For example, the first two clicks of the mouse are not recognized.
I guess it must have something to do with energy saving and systems going into sleep mode, but can’t find any USB related settings in the KDE power management tool.

Any suggestions?

Does really nobody else experience this problem?

Apparently not. Let me venture some guesses…

Does the touchpad lag only happen once after wake up or every time you use it?

If you plug the power adapter back does the lag go away?

Do you have any share (nfs, samba) or external drive active? If you disable them, the problem continue?

There is a thread in the forum about installing and using the yast power module, not included in a default installation as KDE’s power manager should suffice… Try searching for it.

Just guessing, mind you. Good luck.

Hi brunomcl

thanks for pointing out some paths. I am a bit late in replying as I was playing around a lot with figuring out what is going on. I have more hints, but no solution yet.

Does the touchpad lag only happen once after wake up or every time you use it?

This happens not only after unplugging power, but repeatably while running on power. It is usually when changing the active window or when there is a longer break between activities (maybe ~15s?).
What I noticed is that the laptop own input devices are not affected, it is only USB peripherals. So I can for example switch to terminal and start typing with usb keyboard without response, whereas laptop keyboard will type. similar with touchpad and mouse.

If you plug the power adapter back does the lag go away?

Yes. always.

Do you have any share (nfs, samba) or external drive active? If you disable them, the problem continue?

I do not remember of having set up any of this and my network place in dolphin is empty except the 3 standard links. Is there any other way to check if any of these are running?

There is a thread in the forum about installing and using the yast power module, not included in a default installation as KDE’s power manager should suffice… Try searching for it.

From what I read, this module is not working on OpenSuse 12.1. I tried with the cfu script instead. Have not seen any improvement yet

I was going to suggest you try to reload the usb driver right after a resume and see if it improve things, but there is no usb driver if I do a lsmod in my system (oS 11.4 64 bits), so I presume it is compiled into the kernel itself. The only thing I can think of to try is an up/downgrade of the kernel itself.

OTOH if your laptop keyboard is detected by the system as an USB device (run hwinfo --keyboard as root from a terminal) then as it uses the same controller I’d guess the USB driver is not the problem.

Also I’m reaching here, but you could play with the USB BIOS settings (legacy on/off, USB 3.0 on/off, etc.) if any.

Dear brunomcl

Your suggestions are very helpful.
The laptop keyboard does not seem to be USB PS/2 :

hwinfo --keyboard
22: PS/2 00.0: 10800 Keyboard                                   
  [Created at input.226]
  Unique ID: nLyy.+49ps10DtUF
  Hardware Class: keyboard
  Model: "AT Translated Set 2 keyboard"
  Vendor: 0x0001 
  Device: 0x0001 "AT Translated Set 2 keyboard"
  Compatible to: int 0x0211 0x0001
  Device File: /dev/input/event0
  Device Files: /dev/input/event0, /dev/input/by-path/platform-i8042-serio-0-event-kbd
  Device Number: char 13:64
  Driver Info #0:
    XkbRules: xfree86
    XkbModel: pc104
  Config Status: cfg=yes, avail=yes, need=yes, active=unknown

neither are trackball and trackpad.
So it could be really a USB driver issue.

Can’t change anything in BIOS regarding this. Only option is to enable for boot.

It must have something to do with some power save mode and the USB driver. I just can’t get it at the moment.

I think I got it. The Ubuntu forum helped me: [ubuntu] USB wireless mouse delay using battery - Ubuntu Forums](http://ubuntuforums.org/showthread.php?t=1675277)

I have laptop-mode installed and CONTROL_USB_AUTOSUSPEND=‘auto’ was set. I set it to 0 and it seems to help after reboot.

Cool! Thanks for the feedback.