kernel/syscons - Fix excessive cpu latency during scrolling
authorMatthew Dillon <dillon@apollo.backplane.com>
Fri, 19 Jun 2015 16:21:55 +0000 (09:21 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Fri, 19 Jun 2015 16:21:55 +0000 (09:21 -0700)
commit7ae6dbf032d21ff5d054ee0841f774c177c59523
treef44efa9548250c31bb3912d969c07cecb8c9ccdf
parent7f455ce26b6edbe06e7571bafa45625822f92404
kernel/syscons - Fix excessive cpu latency during scrolling

* Scrolling a high-resolution (e.g. 4K monitor) kms console with the syscons
  spinlock held can prevent the cpu from being able to service interrupts
  for very long periods of time, enough to cause clicking and other audio
  issues.

* The previous hack tried to fix this by allowing yields inside the render
  loop, but this was not stable and did not completely solve the clicking.

* The new solution is to shove large screen updates off to a cothread which
  will then run the update lockless, allowing interrupts.  Minor frame buffer
  corruption can occur during scrolling but will be quickly cleaned up.

  This feature is disabled if the system is in the middle of a panic or
  shutdown.
sys/dev/misc/syscons/sckmsrndr.c
sys/dev/misc/syscons/scmouse.c
sys/dev/misc/syscons/scvgarndr.c
sys/dev/misc/syscons/syscons.c
sys/dev/misc/syscons/syscons.h