git: kernel - Fix panic when X11 intercepts console (II)
Matthew Dillon
dillon at crater.dragonflybsd.org
Sun Sep 5 11:19:11 PDT 2010
commit 28d7e704b1a949e1b01af023e51b33e2f87ce626
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date: Sun Sep 5 11:14:49 2010 -0700
kernel - Fix panic when X11 intercepts console (II)
* There is a secondary issue when the console is runs through a pty or
other device and kqueue is used, the tty_token is not enough.
* Rewrite kputchar() and shift all constty intercepts over to their own
kernel thread. kputchar() will write to the dmesg buffer and will call
cnputc() to write to the real console, and (for tprintf()) it will
output a specified tty. But it will no longer attempt to write to
the console tty via the kprintf() path.
Instead kputchar() simply wakes up the monitoring kernel thread and
the monitoring kernel thread tracks and copies the dmesg buffer to
the constty.
* This completely fixes the constty intercept issue. 'xconsole' now works
perfectly. Nothing can go wrong. Go wrong. Go wrong.
Summary of changes:
sys/kern/subr_prf.c | 114 +++++++++++++++++++++++++++++++++++++++++---------
1 files changed, 93 insertions(+), 21 deletions(-)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/28d7e704b1a949e1b01af023e51b33e2f87ce626
--
DragonFly BSD source repository
More information about the Commits
mailing list