svn commit: r263261 - stable/10/sys/dev/usb/input

Hans Petter Selasky hselasky at FreeBSD.org
Mon Mar 17 06:38:41 UTC 2014


Author: hselasky
Date: Mon Mar 17 06:38:40 2014
New Revision: 263261
URL: http://svnweb.freebsd.org/changeset/base/263261

Log:
  MFC r262972:
  Ignore USB keyboard driver calls from critical sections.

Modified:
  stable/10/sys/dev/usb/input/ukbd.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/usb/input/ukbd.c
==============================================================================
--- stable/10/sys/dev/usb/input/ukbd.c	Mon Mar 17 06:36:54 2014	(r263260)
+++ stable/10/sys/dev/usb/input/ukbd.c	Mon Mar 17 06:38:40 2014	(r263261)
@@ -1909,6 +1909,12 @@ ukbd_ioctl(keyboard_t *kbd, u_long cmd, 
 	int result;
 
 	/*
+	 * XXX Check of someone is calling us from a critical section:
+	 */
+	if (curthread->td_critnest != 0)
+		return (EDEADLK);
+
+	/*
 	 * XXX KDGKBSTATE, KDSKBSTATE and KDSETLED can be called from any
 	 * context where printf(9) can be called, which among other things
 	 * includes interrupt filters and threads with any kinds of locks


More information about the svn-src-all mailing list