cvs commit: src/sys/dev/kbdmux kbdmux.c

Maksim Yevmenkin emax at
Sun Feb 26 22:24:27 PST 2006

emax        2006-02-27 06:24:26 UTC

  FreeBSD src repository

  Modified files:        (Branch: RELENG_6)
    sys/dev/kbdmux       kbdmux.c 
  MFC recent changes to kbdmux(4)
  Fix hard lockup caused by kbdmux(4) when kbdmux(4), PS/2 keyboard
  (atkbd(4)) and PS/2 mouse (psm(4)) are used together.
  Turns out that atkbd(4) check_char() method may return "true" while
  read_char() method returns NOKEY. When this happens kbdmux(4) was
  simply stuck in the dead loop. Avoid dead loop in kbdmux(4) by breaking
  out of the loop if read_char() method returns NOKEY.
  It almost seems like a bug in atkkbd(4), atkbd_check_char() calls
  kbdc_data_ready(), and, the later will return "true" if there are
  pending data in either kbd or aux queue. However, because both aux
  and kbd are on the same controller, I'm not sure if this is a bug
  or feature.
  While I'm here fix a couple of whitespaces.
  Tested by:      markus
  Approved by:    re (scottl)
  Revision  Changes    Path   +13 -4     src/sys/dev/kbdmux/kbdmux.c

More information about the cvs-src mailing list