[hardy] key events are delayed under circumstances

Bug #218516 reported by Tom Jaeger on 2008-04-17
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Tim Gardner
Tim Gardner
Tim Gardner

Bug Description

Most of the discussion of this bug can be found in the report of bug #124406. Since several bugs with similar symptions are being discussed in that thread, I thought I'd separate this issue from the discussion for which we know what is going on and for which there is a fix upstream.

Steps to reproduce:
1. Type a command into a console window in X that involves sudo and will generate some processor and/or disk activity, e.g. 'sudo apt-get upgrade'
2. Press the Enter key and hold it down for about half a second, so that there is CPU/disk activity when the key is released.
The X server will not receive the key up event until after a few seconds later, so autorepeat will kick in and generate lots of 'Enter' events.
A surefire way to trigger this bug is by doing something like 'for ((;;)); do sudo apt-get upgrade; done' and then trying to type something in a different window, you'll notice that key presses are delayed.

This turns out to be a scheduler issue where a task's vruntime wouldn't be reset when the task was moved between groups. The (essentially two-line) fix is included in the upstream 2.6.25 release. Here's the relevant git commit:

I've copied the debdiff fixing the issue on the ubuntu kernel from the other thread. It's causing absolutely ZERO new issues on my system.

Tom Jaeger (thjaeger) wrote :
Chris Jones (cmsj) wrote :

Absolutely confirmed, I regularly get a dozen or more blank lines after I hit enter to do a sudo apt-get operation (because the enter event is being repeated). It's extremely problematic because of being associated with sudo (e.g. I don't get to answer Y/n to apt-get, I get the default picked and if I'm lucky I can ctrl-c it before it actually happens, so I can review it).

Changed in linux:
status: New → Confirmed
Stefan Bader (smb) on 2008-04-25
Changed in linux:
assignee: nobody → stefan-bader-canonical
importance: Undecided → Low
milestone: none → ubuntu-8.04.1
status: Confirmed → In Progress
pauls (paulatgm) wrote :

confirmed here also on hardy, not gutsy

Stefan Bader (smb) on 2008-04-28
Changed in linux:
status: In Progress → Fix Committed
Savvas Radevic (medigeek) wrote :

Tom, does this fix the problem with the dozen lines *after* apt is done, or does it fix the problem that it overpasses the y/n/q prompt too?

Tim Gardner (timg-tpi) on 2008-04-30
Changed in linux:
assignee: stefan-bader-canonical → timg-tpi
Tim Gardner (timg-tpi) wrote :

SRU Justification:

Impact: Delayed and/or extra key strokes causing user confusion and annoyance.

Fix Description: Tasks would retain their old vruntime when moved between groups, this can cause funny lags. Re-set the vruntime on group move to fit within the new tree.

Patch: http://kernel.ubuntu.com/git?p=ubuntu/ubuntu-hardy.git;a=commit;h=4b7c68904bf9ada8c4770ce5927e8ec71769ed92

TEST CASE: See the first description in this bug report.

Colin Watson (cjwatson) wrote :

Accepted into hardy-proposed.

Steve Langasek (vorlon) wrote :

Chris, can you confirm that 2.6.24-17 resolves this problem for you in the environment where you're seeing it?

Steve Langasek (vorlon) on 2008-05-20
Changed in linux:
assignee: nobody → timg-tpi
importance: Undecided → Low
milestone: none → ubuntu-8.04.1
status: New → Fix Committed
milestone: ubuntu-8.04.1 → none
Lars Ljung (larslj) wrote :

I can confirm that 2.6.24-17 resolves the problem on my system.

Martin Pitt (pitti) wrote :

linux 2.6.24-17.31 copied to hardy-updates.

Changed in linux:
status: Fix Committed → Fix Released

This is "Fix Released" for Intrepid as well.

Changed in linux:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments