USB 键盘和鼠标均滞后

USB 键盘和鼠标均滞后

今天我决定在我的工作站上试用 Ubuntu 10.10 RC。安装工作正常,但鼠标和键盘(都是 USB)的延迟令人难以忍受。当我从 Live CD 运行它时也是如此。

奇怪的是,进入 X 的前几秒钟它工作正常。然后后台发生了一些事情,鼠标突然表现得像我在最高设置下玩一些要求很高的 3D 游戏一样。键盘也很滞后,如果我每秒按下超过一个键,键就会掉落,并且只有大约五分之一的字符会真正出现在屏幕上。更奇怪的是,当使用 ctrl+alt+f1 切换到控制台模式时也会出现这种滞后。

如果我在启动时立即切换到控制台模式,它工作正常。然后当我切换回 X 时,需要几秒钟,然后这种情况再次发生。

我检查了日志,最可疑的消息是:

Oct  3 20:16:16 CHURCHILL kernel: [   70.868940] irq 19: nobody cared (try booting with the "irqpoll" option)
Oct  3 20:16:16 CHURCHILL kernel: [   70.868946] Pid: 0, comm: swapper Not tainted 2.6.35-22-generic #33-Ubuntu
Oct  3 20:16:16 CHURCHILL kernel: [   70.868948] Call Trace:
Oct  3 20:16:16 CHURCHILL kernel: [   70.868950]  <IRQ>  [<ffffffff810cba5b>] __report_bad_irq+0x2b/0xa0
Oct  3 20:16:16 CHURCHILL kernel: [   70.868961]  [<ffffffff810cbc5c>] note_interrupt+0x18c/0x1d0
Oct  3 20:16:16 CHURCHILL kernel: [   70.868967]  [<ffffffff81085d10>] ? sched_clock_tick+0x60/0x90
Oct  3 20:16:16 CHURCHILL kernel: [   70.868970]  [<ffffffff810cc45d>] handle_fasteoi_irq+0xdd/0x110
Oct  3 20:16:16 CHURCHILL kernel: [   70.868974]  [<ffffffff8100cb12>] handle_irq+0x22/0x30
Oct  3 20:16:16 CHURCHILL kernel: [   70.868978]  [<ffffffff81590b2c>] do_IRQ+0x6c/0xf0
Oct  3 20:16:16 CHURCHILL kernel: [   70.868981]  [<ffffffff81589713>] ret_from_intr+0x0/0x11
Oct  3 20:16:16 CHURCHILL kernel: [   70.868983]  <EOI>  [<ffffffff810360fb>] ? native_safe_halt+0xb/0x10
Oct  3 20:16:16 CHURCHILL kernel: [   70.868990]  [<ffffffff81012ecd>] default_idle+0x3d/0x90
Oct  3 20:16:16 CHURCHILL kernel: [   70.868995]  [<ffffffff81008da3>] cpu_idle+0xb3/0x110
Oct  3 20:16:16 CHURCHILL kernel: [   70.868999]  [<ffffffff8156f6fa>] rest_init+0x8a/0x90
Oct  3 20:16:16 CHURCHILL kernel: [   70.869004]  [<ffffffff81aedc9d>] start_kernel+0x387/0x390
Oct  3 20:16:16 CHURCHILL kernel: [   70.869007]  [<ffffffff81aed341>] x86_64_start_reservations+0x12c/0x130
Oct  3 20:16:16 CHURCHILL kernel: [   70.869011]  [<ffffffff81aed43f>] x86_64_start_kernel+0xfa/0x109
Oct  3 20:16:16 CHURCHILL kernel: [   70.869013] handlers:
Oct  3 20:16:16 CHURCHILL kernel: [   70.869014] [<ffffffff81404bb0>] (usb_hcd_irq+0x0/0x90)
Oct  3 20:16:16 CHURCHILL kernel: [   70.869019] [<ffffffff81404bb0>] (usb_hcd_irq+0x0/0x90)
Oct  3 20:16:16 CHURCHILL kernel: [   70.869022] [<ffffffff81404bb0>] (usb_hcd_irq+0x0/0x90)
Oct  3 20:16:16 CHURCHILL kernel: [   70.869026] Disabling IRQ #19

据我所知,与 IRQ 相关的问题相当常见。然而,大多数问题似乎与共享中断有关,但在我的计算机上,IRQ 19 由 USB 控制器独占使用:

root@CHURCHILL:/home/emil# cat /proc/interrupts
           CPU0
  0:         26   IO-APIC-edge      timer
  1:          2   IO-APIC-edge      i8042
  7:          1   IO-APIC-edge      parport0
  8:          0   IO-APIC-edge      rtc0
  9:          1   IO-APIC-fasteoi   acpi, firewire_ohci
 12:          4   IO-APIC-edge      i8042
 14:          0   IO-APIC-edge      pata_atiixp
 15:       1004   IO-APIC-edge      pata_atiixp
 17:        154   IO-APIC-fasteoi   ATI IXP
 18:       6164   IO-APIC-fasteoi   radeon, hda_intel
 19:    2000002   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb2, ohci_hcd:usb3
 20:       9097   IO-APIC-fasteoi   eth0, eth1
 22:      13702   IO-APIC-fasteoi   sata_sil
NMI:          0   Non-maskable interrupts
LOC:     105505   Local timer interrupts
SPU:          0   Spurious interrupts
PMI:          0   Performance monitoring interrupts
PND:          0   Performance pending work
RES:          0   Rescheduling interrupts
CAL:          0   Function call interrupts
TLB:          0   TLB shootdowns
TRM:          0   Thermal event interrupts
THR:          0   Threshold APIC interrupts
MCE:          0   Machine check exceptions
MCP:          4   Machine check polls
ERR:          1
MIS:          0

我发现另一个遇到类似问题的人按照内核消息的建议使用了 irqpoll。但是,他报告说,如果没有该选项,输入根本不起作用,这让我认为这可能与 IRQ 无关。特别是因为它在一段时间内工作正常。

lspci将 USB 控制器列为ATI Technologies Inc IXP SB400 USB Host Controller

任何建议将不胜感激。

答案1

也许不是内核错误,而是某些用户进程占用资源?例如,epic gnome-settings-daemon (https://bugs.launchpad.net/bugs/625793)?启动系统监视器,从菜单中打开所有进程并按 CPU 使用率排序,您可能会找到答案...

相关内容