From owner-svn-src-all@FreeBSD.ORG Sun Feb 7 15:42:15 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C2E791065670; Sun, 7 Feb 2010 15:42:15 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A95908FC14; Sun, 7 Feb 2010 15:42:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o17FgFmq062255; Sun, 7 Feb 2010 15:42:15 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o17FgFIV062252; Sun, 7 Feb 2010 15:42:15 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201002071542.o17FgFIV062252@svn.freebsd.org> From: Ed Schouten Date: Sun, 7 Feb 2010 15:42:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r203611 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Feb 2010 15:42:16 -0000 Author: ed Date: Sun Feb 7 15:42:15 2010 New Revision: 203611 URL: http://svn.freebsd.org/changeset/base/203611 Log: Remove statistics from the TTY queues. I added counters to see how often fast copying to userspace was actually performed, which was only useful during development. Remove these statistics now we know it to be effective. Modified: head/sys/kern/tty_inq.c head/sys/kern/tty_outq.c Modified: head/sys/kern/tty_inq.c ============================================================================== --- head/sys/kern/tty_inq.c Sun Feb 7 13:59:03 2010 (r203610) +++ head/sys/kern/tty_inq.c Sun Feb 7 15:42:15 2010 (r203611) @@ -61,13 +61,6 @@ __FBSDID("$FreeBSD$"); * the outq, we'll stick to 128 byte blocks here. */ -/* Statistics. */ -static unsigned long ttyinq_nfast = 0; -SYSCTL_ULONG(_kern, OID_AUTO, tty_inq_nfast, CTLFLAG_RD, - &ttyinq_nfast, 0, "Unbuffered reads to userspace on input"); -static unsigned long ttyinq_nslow = 0; -SYSCTL_ULONG(_kern, OID_AUTO, tty_inq_nslow, CTLFLAG_RD, - &ttyinq_nslow, 0, "Buffered reads to userspace on input"); static int ttyinq_flush_secure = 1; SYSCTL_INT(_kern, OID_AUTO, tty_inq_flush_secure, CTLFLAG_RW, &ttyinq_flush_secure, 0, "Zero buffers while flushing"); @@ -201,8 +194,6 @@ ttyinq_read_uio(struct ttyinq *ti, struc * the write pointer to a new block. */ if (cend == TTYINQ_DATASIZE || cend == ti->ti_end) { - atomic_add_long(&ttyinq_nfast, 1); - /* * Fast path: zero copy. Remove the first block, * so we can unlock the TTY temporarily. @@ -239,7 +230,6 @@ ttyinq_read_uio(struct ttyinq *ti, struc TTYINQ_RECYCLE(ti, tib); } else { char ob[TTYINQ_DATASIZE - 1]; - atomic_add_long(&ttyinq_nslow, 1); /* * Slow path: store data in a temporary buffer. Modified: head/sys/kern/tty_outq.c ============================================================================== --- head/sys/kern/tty_outq.c Sun Feb 7 13:59:03 2010 (r203610) +++ head/sys/kern/tty_outq.c Sun Feb 7 15:42:15 2010 (r203611) @@ -34,7 +34,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include #include #include @@ -52,14 +51,6 @@ __FBSDID("$FreeBSD$"); * output. */ -/* Statistics. */ -static unsigned long ttyoutq_nfast = 0; -SYSCTL_ULONG(_kern, OID_AUTO, tty_outq_nfast, CTLFLAG_RD, - &ttyoutq_nfast, 0, "Unbuffered reads to userspace on output"); -static unsigned long ttyoutq_nslow = 0; -SYSCTL_ULONG(_kern, OID_AUTO, tty_outq_nslow, CTLFLAG_RD, - &ttyoutq_nslow, 0, "Buffered reads to userspace on output"); - struct ttyoutq_block { struct ttyoutq_block *tob_next; char tob_data[TTYOUTQ_DATASIZE]; @@ -236,8 +227,6 @@ ttyoutq_read_uio(struct ttyoutq *to, str * the write pointer to a new block. */ if (cend == TTYOUTQ_DATASIZE || cend == to->to_end) { - atomic_add_long(&ttyoutq_nfast, 1); - /* * Fast path: zero copy. Remove the first block, * so we can unlock the TTY temporarily. @@ -258,7 +247,6 @@ ttyoutq_read_uio(struct ttyoutq *to, str TTYOUTQ_RECYCLE(to, tob); } else { char ob[TTYOUTQ_DATASIZE - 1]; - atomic_add_long(&ttyoutq_nslow, 1); /* * Slow path: store data in a temporary buffer.