PERFORCE change 149067 for review
Ed Schouten
ed at FreeBSD.org
Tue Sep 2 17:18:00 UTC 2008
http://perforce.freebsd.org/chv.cgi?CH=149067
Change 149067 by ed at ed_dull on 2008/09/02 17:17:00
IFC my ttydisc fix.
Affected files ...
.. //depot/projects/mpsafetty/sys/kern/tty_ttydisc.c#19 integrate
.. //depot/projects/mpsafetty/sys/kern/uipc_socket.c#3 integrate
Differences ...
==== //depot/projects/mpsafetty/sys/kern/tty_ttydisc.c#19 (text+ko) ====
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/tty_ttydisc.c,v 1.2 2008/08/29 15:02:50 ed Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/tty_ttydisc.c,v 1.3 2008/09/02 17:13:11 ed Exp $");
#include <sys/param.h>
#include <sys/fcntl.h>
@@ -1100,6 +1100,7 @@
ttyhook_getc_capture(tp, buf, len);
ttydisc_wakeup_watermark(tp);
+
atomic_add_long(&tty_nout, len);
return (len);
==== //depot/projects/mpsafetty/sys/kern/uipc_socket.c#3 (text+ko) ====
@@ -95,7 +95,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/uipc_socket.c,v 1.313 2008/07/21 00:49:34 kmacy Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/uipc_socket.c,v 1.314 2008/09/02 16:55:21 rwatson Exp $");
#include "opt_inet.h"
#include "opt_mac.h"
@@ -1857,7 +1857,6 @@
int flags, len, error, offset;
struct protosw *pr = so->so_proto;
struct mbuf *nextrecord;
- int orig_resid = uio->uio_resid;
if (psa != NULL)
*psa = NULL;
@@ -1935,7 +1934,6 @@
SBLASTRECORDCHK(&so->so_rcv);
SBLASTMBUFCHK(&so->so_rcv);
- /* XXXRW: sbwait() may not be as happy without sblock(). */
error = sbwait(&so->so_rcv);
SOCKBUF_UNLOCK(&so->so_rcv);
if (error)
@@ -1968,7 +1966,6 @@
if (pr->pr_flags & PR_ADDR) {
KASSERT(m->m_type == MT_SONAME,
("m->m_type == %d", m->m_type));
- orig_resid = 0;
if (psa != NULL)
*psa = sodupsockaddr(mtod(m, struct sockaddr *),
M_NOWAIT);
@@ -2048,13 +2045,11 @@
else
m_freem(cm);
if (controlp != NULL) {
- orig_resid = 0;
while (*controlp != NULL)
controlp = &(*controlp)->m_next;
}
cm = cmn;
}
- orig_resid = 0; /* XXXRW: why this? */
}
KASSERT(m->m_type == MT_DATA, ("soreceive_dgram: !data"));
More information about the p4-projects
mailing list