CVS commit: src/share/man/man4
Module Name:src Committed By: wiz Date: Wed Jul 23 21:19:34 UTC 2014 Modified Files: src/share/man/man4: options.4 Log Message: Fix typo. Bump date for previous. To generate a diff of this commit: cvs rdiff -u -r1.438 -r1.439 src/share/man/man4/options.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man4/options.4 diff -u src/share/man/man4/options.4:1.438 src/share/man/man4/options.4:1.439 --- src/share/man/man4/options.4:1.438 Wed Jul 23 20:13:13 2014 +++ src/share/man/man4/options.4 Wed Jul 23 21:19:33 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: options.4,v 1.438 2014/07/23 20:13:13 gdt Exp $ +.\" $NetBSD: options.4,v 1.439 2014/07/23 21:19:33 wiz Exp $ .\" .\" Copyright (c) 1996 .\" Perry E. Metzger. All rights reserved. @@ -30,7 +30,7 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" -.Dd March 22, 2014 +.Dd July 23, 2014 .Dt OPTIONS 4 .Os .Sh NAME @@ -610,7 +610,7 @@ intended only for debugging or looking f Adds code to the kernel that does internal consistency checks. This code will cause the kernel to panic if corruption of internal data structures is detected. -Historically, the performance degredation is sufficiently small that +Historically, the performance degradation is sufficiently small that it is reasonable for systems with .Em options DIAGNOSTIC to be in production use, with the real consideration not being
CVS commit: src/share/man/man4
Module Name:src Committed By: gdt Date: Wed Jul 23 20:13:13 UTC 2014 Modified Files: src/share/man/man4: options.4 Log Message: Sync DIAGNOSTIC performance comments with historical reality. Somehow, options(4) ended up with a bizarre claim that DIAGNOSTIC can reduce performance by 15%. While that might have been true at some isolated point due to a bug, it's an outlier. Since at least 2BSD, DIAGNOSTIC has added asserts, resulting in at most difficult-to-perceived performance degredation, and many people have been running production systems (meaning systems they intend to use, rather than debugging targets) with this option.(The decision a while ago to enable DIAGNOSTIC in -current's GENERIC reflects this; if it really were a 15% hit such enabling by default would be unreasonable.) To generate a diff of this commit: cvs rdiff -u -r1.437 -r1.438 src/share/man/man4/options.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man4/options.4 diff -u src/share/man/man4/options.4:1.437 src/share/man/man4/options.4:1.438 --- src/share/man/man4/options.4:1.437 Sun Mar 23 00:50:20 2014 +++ src/share/man/man4/options.4 Wed Jul 23 20:13:13 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: options.4,v 1.437 2014/03/23 00:50:20 dholland Exp $ +.\" $NetBSD: options.4,v 1.438 2014/07/23 20:13:13 gdt Exp $ .\" .\" Copyright (c) 1996 .\" Perry E. Metzger. All rights reserved. @@ -604,11 +604,18 @@ Note that many parts of the kernel (typi conditionals instead. This option also turns on certain other options, which may decrease system performance. +Systems with this option are not suitable for regular use, and are +intended only for debugging or looking for bugs. .It Cd options DIAGNOSTIC Adds code to the kernel that does internal consistency checks. This code will cause the kernel to panic if corruption of internal data structures is detected. -These checks can decrease performance up to 15%. +Historically, the performance degredation is sufficiently small that +it is reasonable for systems with +.Em options DIAGNOSTIC +to be in production use, with the real consideration not being +performance but instead a preference for more panics versus continued +operation with undetected problems. .It Cd options LOCKDEBUG Adds code to the kernel to detect incorrect use of locking primitives (mutex, rwlock).
CVS commit: src/sys/external/bsd/drm2/i915drm
Module Name:src Committed By: riastradh Date: Wed Jul 23 18:05:44 UTC 2014 Modified Files: src/sys/external/bsd/drm2/i915drm: i915_pci.c Log Message: Omit redundant vga_is_console test. This was a copypasta error -- before it tested iot then memt -- but I see no evidence that passing memt to vga_is_console is ever sensible. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.13 src/sys/external/bsd/drm2/i915drm/i915_pci.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/external/bsd/drm2/i915drm/i915_pci.c diff -u src/sys/external/bsd/drm2/i915drm/i915_pci.c:1.12 src/sys/external/bsd/drm2/i915drm/i915_pci.c:1.13 --- src/sys/external/bsd/drm2/i915drm/i915_pci.c:1.12 Wed Jul 16 23:25:18 2014 +++ src/sys/external/bsd/drm2/i915drm/i915_pci.c Wed Jul 23 18:05:44 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: i915_pci.c,v 1.12 2014/07/16 23:25:18 riastradh Exp $ */ +/* $NetBSD: i915_pci.c,v 1.13 2014/07/23 18:05:44 riastradh Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: i915_pci.c,v 1.12 2014/07/16 23:25:18 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: i915_pci.c,v 1.13 2014/07/23 18:05:44 riastradh Exp $"); #ifdef _KERNEL_OPT #include "vga.h" @@ -301,8 +301,7 @@ intel_genfb_attach(struct drm_device *de int ret; #if NVGA > 0 - if (vga_is_console(dev->pdev->pd_pa.pa_iot, -1) || - vga_is_console(dev->pdev->pd_pa.pa_iot, -1)) { + if (vga_is_console(dev->pdev->pd_pa.pa_iot, -1)) { what_was_cons = CONS_VGA; prop_dictionary_set_bool(dict, "is_console", true); /*
CVS commit: src/sys/dev/wsfb
Module Name:src Committed By: riastradh Date: Wed Jul 23 16:56:49 UTC 2014 Modified Files: src/sys/dev/wsfb: genfbvar.h Log Message: RCS IDs do not go in header files. To generate a diff of this commit: cvs rdiff -u -r1.22 -r1.23 src/sys/dev/wsfb/genfbvar.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/wsfb/genfbvar.h diff -u src/sys/dev/wsfb/genfbvar.h:1.22 src/sys/dev/wsfb/genfbvar.h:1.23 --- src/sys/dev/wsfb/genfbvar.h:1.22 Tue Mar 18 18:20:42 2014 +++ src/sys/dev/wsfb/genfbvar.h Wed Jul 23 16:56:49 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: genfbvar.h,v 1.22 2014/03/18 18:20:42 riastradh Exp $ */ +/* $NetBSD: genfbvar.h,v 1.23 2014/07/23 16:56:49 riastradh Exp $ */ /*- * Copyright (c) 2007 Michael Lorenz @@ -26,9 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#include -__KERNEL_RCSID(0, "$NetBSD: genfbvar.h,v 1.22 2014/03/18 18:20:42 riastradh Exp $"); - #ifndef GENFBVAR_H #define GENFBVAR_H
CVS commit: src/sys/dev/pci
Module Name:src Committed By: riastradh Date: Wed Jul 23 14:50:23 UTC 2014 Modified Files: src/sys/dev/pci: agp_i810.c Log Message: Tweak style, make it compile...oops. To generate a diff of this commit: cvs rdiff -u -r1.110 -r1.111 src/sys/dev/pci/agp_i810.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/agp_i810.c diff -u src/sys/dev/pci/agp_i810.c:1.110 src/sys/dev/pci/agp_i810.c:1.111 --- src/sys/dev/pci/agp_i810.c:1.110 Wed Jul 23 14:48:06 2014 +++ src/sys/dev/pci/agp_i810.c Wed Jul 23 14:50:23 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: agp_i810.c,v 1.110 2014/07/23 14:48:06 riastradh Exp $ */ +/* $NetBSD: agp_i810.c,v 1.111 2014/07/23 14:50:23 riastradh Exp $ */ /*- * Copyright (c) 2000 Doug Rabson @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.110 2014/07/23 14:48:06 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.111 2014/07/23 14:50:23 riastradh Exp $"); #include #include @@ -1328,9 +1328,9 @@ agp_i810_bind_memory_dcache(struct agp_s if (error) goto fail0; } - mem->am_offset = offset; /* Success! */ + mem->am_offset = offset; return 0; fail0: for (j = 0; j < i; j += AGP_PAGE_SIZE) @@ -1376,9 +1376,7 @@ agp_i810_unbind_memory(struct agp_softc return agp_generic_unbind_memory(sc, mem); case AGP_I810_MEMTYPE_DCACHE: KASSERT(isc->chiptype == CHIP_I810); - for (i = 0; i < mem->am_size; i += AGP_PAGE_SIZE) - (void)agp_i810_unbind_page(isc, mem->am_offset + i); - break; + /* FALLTHROUGH */ case AGP_I810_MEMTYPE_HWCURSOR: for (i = 0; i < mem->am_size; i += AGP_PAGE_SIZE) (void)agp_i810_unbind_page(sc, mem->am_offset + i);
CVS commit: src/sys/dev/pci
Module Name:src Committed By: riastradh Date: Wed Jul 23 14:48:06 UTC 2014 Modified Files: src/sys/dev/pci: agp_i810.c Log Message: For the unbind code to work the bind code must set the offset. To generate a diff of this commit: cvs rdiff -u -r1.109 -r1.110 src/sys/dev/pci/agp_i810.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/agp_i810.c diff -u src/sys/dev/pci/agp_i810.c:1.109 src/sys/dev/pci/agp_i810.c:1.110 --- src/sys/dev/pci/agp_i810.c:1.109 Wed Jul 23 14:38:08 2014 +++ src/sys/dev/pci/agp_i810.c Wed Jul 23 14:48:06 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: agp_i810.c,v 1.109 2014/07/23 14:38:08 riastradh Exp $ */ +/* $NetBSD: agp_i810.c,v 1.110 2014/07/23 14:48:06 riastradh Exp $ */ /*- * Copyright (c) 2000 Doug Rabson @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.109 2014/07/23 14:38:08 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.110 2014/07/23 14:48:06 riastradh Exp $"); #include #include @@ -1328,6 +1328,7 @@ agp_i810_bind_memory_dcache(struct agp_s if (error) goto fail0; } + mem->am_offset = offset; /* Success! */ return 0;
CVS commit: src/sys/dev/pci
Module Name:src Committed By: riastradh Date: Wed Jul 23 14:38:08 UTC 2014 Modified Files: src/sys/dev/pci: agp_i810.c Log Message: Also unbind the right offset. To generate a diff of this commit: cvs rdiff -u -r1.108 -r1.109 src/sys/dev/pci/agp_i810.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/agp_i810.c diff -u src/sys/dev/pci/agp_i810.c:1.108 src/sys/dev/pci/agp_i810.c:1.109 --- src/sys/dev/pci/agp_i810.c:1.108 Wed Jul 23 14:23:09 2014 +++ src/sys/dev/pci/agp_i810.c Wed Jul 23 14:38:08 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: agp_i810.c,v 1.108 2014/07/23 14:23:09 riastradh Exp $ */ +/* $NetBSD: agp_i810.c,v 1.109 2014/07/23 14:38:08 riastradh Exp $ */ /*- * Copyright (c) 2000 Doug Rabson @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.108 2014/07/23 14:23:09 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.109 2014/07/23 14:38:08 riastradh Exp $"); #include #include @@ -1376,7 +1376,7 @@ agp_i810_unbind_memory(struct agp_softc case AGP_I810_MEMTYPE_DCACHE: KASSERT(isc->chiptype == CHIP_I810); for (i = 0; i < mem->am_size; i += AGP_PAGE_SIZE) - (void)agp_i810_write_gtt_entry(isc, i, 0); + (void)agp_i810_unbind_page(isc, mem->am_offset + i); break; case AGP_I810_MEMTYPE_HWCURSOR: for (i = 0; i < mem->am_size; i += AGP_PAGE_SIZE)
CVS commit: src/sys/dev/pci
Module Name:src Committed By: riastradh Date: Wed Jul 23 14:23:09 UTC 2014 Modified Files: src/sys/dev/pci: agp_i810.c Log Message: Bind i810 dcache pages at the requested offset, not at VA start. >From John D Baker in PR xsrc/48344. XXX pullup to 6 (by patch) To generate a diff of this commit: cvs rdiff -u -r1.107 -r1.108 src/sys/dev/pci/agp_i810.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/agp_i810.c diff -u src/sys/dev/pci/agp_i810.c:1.107 src/sys/dev/pci/agp_i810.c:1.108 --- src/sys/dev/pci/agp_i810.c:1.107 Tue Jul 1 16:27:25 2014 +++ src/sys/dev/pci/agp_i810.c Wed Jul 23 14:23:09 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: agp_i810.c,v 1.107 2014/07/01 16:27:25 riastradh Exp $ */ +/* $NetBSD: agp_i810.c,v 1.108 2014/07/23 14:23:09 riastradh Exp $ */ /*- * Copyright (c) 2000 Doug Rabson @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.107 2014/07/01 16:27:25 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: agp_i810.c,v 1.108 2014/07/23 14:23:09 riastradh Exp $"); #include #include @@ -1323,8 +1323,7 @@ agp_i810_bind_memory_dcache(struct agp_s KASSERT((mem->am_size & (AGP_PAGE_SIZE - 1)) == 0); for (i = 0; i < mem->am_size; i += AGP_PAGE_SIZE) { - /* XXX No offset? */ - error = agp_i810_write_gtt_entry(isc, i, + error = agp_i810_write_gtt_entry(isc, offset + i, i | I810_GTT_PTE_VALID | I810_GTT_PTE_DCACHE); if (error) goto fail0;
CVS commit: src/sys
Module Name:src Committed By: rtr Date: Wed Jul 23 13:17:19 UTC 2014 Modified Files: src/sys/dev: kttcp.c src/sys/kern: uipc_socket.c uipc_usrreq.c src/sys/net: raw_usrreq.c rtsock.c src/sys/netatalk: ddp_usrreq.c src/sys/netbt: hci_socket.c l2cap_socket.c rfcomm_socket.c sco_socket.c src/sys/netinet: raw_ip.c tcp_usrreq.c udp_usrreq.c src/sys/netinet6: raw_ip6.c udp6_usrreq.c src/sys/netipsec: keysock.c src/sys/netmpls: mpls_proto.c src/sys/netnatm: natm.c src/sys/rump/net/lib/libsockin: sockin.c src/sys/sys: protosw.h Log Message: split PRU_SENDOOB and PRU_RCVOOB function out of pr_generic() usrreq switches and put into separate functions xxx_sendoob(struct socket *, struct mbuf *, struct mbuf *) xxx_recvoob(struct socket *, struct mbuf *, int) - always KASSERT(solocked(so)) even if request is not implemented - replace calls to pr_generic() with req = PRU_{SEND,RCV}OOB with calls to pr_{send,recv}oob() respectively. there is still some tweaking of m_freem(m) and m_freem(control) to come for consistency. not performed with this commit for clarity. reviewed by rmind To generate a diff of this commit: cvs rdiff -u -r1.33 -r1.34 src/sys/dev/kttcp.c cvs rdiff -u -r1.225 -r1.226 src/sys/kern/uipc_socket.c cvs rdiff -u -r1.159 -r1.160 src/sys/kern/uipc_usrreq.c cvs rdiff -u -r1.43 -r1.44 src/sys/net/raw_usrreq.c cvs rdiff -u -r1.155 -r1.156 src/sys/net/rtsock.c cvs rdiff -u -r1.53 -r1.54 src/sys/netatalk/ddp_usrreq.c cvs rdiff -u -r1.32 -r1.33 src/sys/netbt/hci_socket.c cvs rdiff -u -r1.23 -r1.24 src/sys/netbt/l2cap_socket.c cvs rdiff -u -r1.24 -r1.25 src/sys/netbt/rfcomm_socket.c cvs rdiff -u -r1.25 -r1.26 src/sys/netbt/sco_socket.c cvs rdiff -u -r1.134 -r1.135 src/sys/netinet/raw_ip.c cvs rdiff -u -r1.188 -r1.189 src/sys/netinet/tcp_usrreq.c cvs rdiff -u -r1.208 -r1.209 src/sys/netinet/udp_usrreq.c cvs rdiff -u -r1.127 -r1.128 src/sys/netinet6/raw_ip6.c cvs rdiff -u -r1.107 -r1.108 src/sys/netinet6/udp6_usrreq.c cvs rdiff -u -r1.35 -r1.36 src/sys/netipsec/keysock.c cvs rdiff -u -r1.15 -r1.16 src/sys/netmpls/mpls_proto.c cvs rdiff -u -r1.37 -r1.38 src/sys/netnatm/natm.c cvs rdiff -u -r1.49 -r1.50 src/sys/rump/net/lib/libsockin/sockin.c cvs rdiff -u -r1.52 -r1.53 src/sys/sys/protosw.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/kttcp.c diff -u src/sys/dev/kttcp.c:1.33 src/sys/dev/kttcp.c:1.34 --- src/sys/dev/kttcp.c:1.33 Sun May 18 14:46:15 2014 +++ src/sys/dev/kttcp.c Wed Jul 23 13:17:18 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: kttcp.c,v 1.33 2014/05/18 14:46:15 rmind Exp $ */ +/* $NetBSD: kttcp.c,v 1.34 2014/07/23 13:17:18 rtr Exp $ */ /* * Copyright (c) 2002 Wasabi Systems, Inc. @@ -42,7 +42,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kttcp.c,v 1.33 2014/05/18 14:46:15 rmind Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kttcp.c,v 1.34 2014/07/23 13:17:18 rtr Exp $"); #include #include @@ -319,9 +319,12 @@ nopages: so->so_options |= SO_DONTROUTE; if (resid > 0) so->so_state |= SS_MORETOCOME; - error = (*so->so_proto->pr_usrreqs->pr_generic)(so, - (flags & MSG_OOB) ? PRU_SENDOOB : PRU_SEND, - top, NULL, NULL, l); + if (flags & MSG_OOB) +error = (*so->so_proto->pr_usrreqs->pr_sendoob)(so, +top, NULL); + else +error = (*so->so_proto->pr_usrreqs->pr_generic)(so, +PRU_SEND, top, NULL, NULL, l); if (dontroute) so->so_options &= ~SO_DONTROUTE; if (resid > 0) @@ -367,8 +370,7 @@ kttcp_soreceive(struct socket *so, unsig if (flags & MSG_OOB) { m = m_get(M_WAIT, MT_DATA); solock(so); - error = (*pr->pr_usrreqs->pr_generic)(so, PRU_RCVOOB, m, - (struct mbuf *)(long)(flags & MSG_PEEK), NULL, NULL); + error = (*pr->pr_usrreqs->pr_recvoob)(so, m, flags & MSG_PEEK); sounlock(so); if (error) goto bad; Index: src/sys/kern/uipc_socket.c diff -u src/sys/kern/uipc_socket.c:1.225 src/sys/kern/uipc_socket.c:1.226 --- src/sys/kern/uipc_socket.c:1.225 Wed Jul 9 14:41:42 2014 +++ src/sys/kern/uipc_socket.c Wed Jul 23 13:17:18 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_socket.c,v 1.225 2014/07/09 14:41:42 rtr Exp $ */ +/* $NetBSD: uipc_socket.c,v 1.226 2014/07/23 13:17:18 rtr Exp $ */ /*- * Copyright (c) 2002, 2007, 2008, 2009 The NetBSD Foundation, Inc. @@ -71,7 +71,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uipc_socket.c,v 1.225 2014/07/09 14:41:42 rtr Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_socket.c,v 1.226 2014/07/23 13:17:18 rtr Exp $"); #include "opt_compat_netbsd.h" #include "opt_sock_counters.h" @@ -1053,9 +1053,12 @@ sosend(struct socket *so, struct mbuf *a so->so_options |= SO_DONTROUTE; if (resid > 0) so->so_state |= SS_MORETOCOME; - error = (*so->so_proto->pr_usrreqs->pr_generic)(so, - (flags & MSG_OOB) ? PRU_SENDOOB : PRU_SEND, - top, addr, contro
CVS commit: src/sys
Module Name:src Committed By: pooka Date: Wed Jul 23 11:43:29 UTC 2014 Modified Files: src/sys/kern: init_sysent.c syscalls.c src/sys/rump/include/rump: rump_syscalls.h src/sys/rump/librump/rumpkern: rump_syscalls.c src/sys/sys: syscall.h syscallargs.h Log Message: regen To generate a diff of this commit: cvs rdiff -u -r1.284 -r1.285 src/sys/kern/init_sysent.c cvs rdiff -u -r1.275 -r1.276 src/sys/kern/syscalls.c cvs rdiff -u -r1.76 -r1.77 src/sys/rump/include/rump/rump_syscalls.h cvs rdiff -u -r1.101 -r1.102 src/sys/rump/librump/rumpkern/rump_syscalls.c cvs rdiff -u -r1.271 -r1.272 src/sys/sys/syscall.h cvs rdiff -u -r1.254 -r1.255 src/sys/sys/syscallargs.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/kern/init_sysent.c diff -u src/sys/kern/init_sysent.c:1.284 src/sys/kern/init_sysent.c:1.285 --- src/sys/kern/init_sysent.c:1.284 Thu Jun 12 21:42:26 2014 +++ src/sys/kern/init_sysent.c Wed Jul 23 11:43:29 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: init_sysent.c,v 1.284 2014/06/12 21:42:26 joerg Exp $ */ +/* $NetBSD: init_sysent.c,v 1.285 2014/07/23 11:43:29 pooka Exp $ */ /* * System call switch table. @@ -8,7 +8,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: init_sysent.c,v 1.284 2014/06/12 21:42:26 joerg Exp $"); +__KERNEL_RCSID(0, "$NetBSD: init_sysent.c,v 1.285 2014/07/23 11:43:29 pooka Exp $"); #include "opt_modular.h" #include "opt_ntp.h" Index: src/sys/kern/syscalls.c diff -u src/sys/kern/syscalls.c:1.275 src/sys/kern/syscalls.c:1.276 --- src/sys/kern/syscalls.c:1.275 Thu Jun 12 21:42:26 2014 +++ src/sys/kern/syscalls.c Wed Jul 23 11:43:29 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: syscalls.c,v 1.275 2014/06/12 21:42:26 joerg Exp $ */ +/* $NetBSD: syscalls.c,v 1.276 2014/07/23 11:43:29 pooka Exp $ */ /* * System call names. @@ -8,7 +8,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: syscalls.c,v 1.275 2014/06/12 21:42:26 joerg Exp $"); +__KERNEL_RCSID(0, "$NetBSD: syscalls.c,v 1.276 2014/07/23 11:43:29 pooka Exp $"); #if defined(_KERNEL_OPT) #include "opt_modular.h" Index: src/sys/rump/include/rump/rump_syscalls.h diff -u src/sys/rump/include/rump/rump_syscalls.h:1.76 src/sys/rump/include/rump/rump_syscalls.h:1.77 --- src/sys/rump/include/rump/rump_syscalls.h:1.76 Thu Jun 12 21:42:26 2014 +++ src/sys/rump/include/rump/rump_syscalls.h Wed Jul 23 11:43:29 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: rump_syscalls.h,v 1.76 2014/06/12 21:42:26 joerg Exp $ */ +/* $NetBSD: rump_syscalls.h,v 1.77 2014/07/23 11:43:29 pooka Exp $ */ /* * System call protos in rump namespace. @@ -16,800 +16,800 @@ #include -#ifndef RUMP_SYS_RENAME_FGETXATTR -#define RUMP_SYS_RENAME_FGETXATTR rump___sysimpl_fgetxattr +#ifndef RUMP_SYS_RENAME_FCHROOT +#define RUMP_SYS_RENAME_FCHROOT rump___sysimpl_fchroot #endif -#ifndef RUMP_SYS_RENAME_IOCTL -#define RUMP_SYS_RENAME_IOCTL rump___sysimpl_ioctl +#ifndef RUMP_SYS_RENAME__KSEM_INIT +#define RUMP_SYS_RENAME__KSEM_INIT rump___sysimpl__ksem_init #endif -#ifndef RUMP_SYS_RENAME_GETPPID -#define RUMP_SYS_RENAME_GETPPID rump___sysimpl_getppid +#ifndef RUMP_SYS_RENAME_EXTATTR_LIST_FD +#define RUMP_SYS_RENAME_EXTATTR_LIST_FD rump___sysimpl_extattr_list_fd #endif -#ifndef RUMP_SYS_RENAME___QUOTACTL -#define RUMP_SYS_RENAME___QUOTACTL rump___sysimpl___quotactl +#ifndef RUMP_SYS_RENAME_PWRITE +#define RUMP_SYS_RENAME_PWRITE rump___sysimpl_pwrite #endif -#ifndef RUMP_SYS_RENAME_GETPGID -#define RUMP_SYS_RENAME_GETPGID rump___sysimpl_getpgid +#ifndef RUMP_SYS_RENAME_FGETXATTR +#define RUMP_SYS_RENAME_FGETXATTR rump___sysimpl_fgetxattr #endif -#ifndef RUMP_SYS_RENAME___SETLOGIN -#define RUMP_SYS_RENAME___SETLOGIN rump___sysimpl___setlogin +#ifndef RUMP_SYS_RENAME_GETGID_WITH_EGID +#define RUMP_SYS_RENAME_GETGID_WITH_EGID rump___sysimpl_getgid #endif -#ifndef RUMP_SYS_RENAME_SETEUID -#define RUMP_SYS_RENAME_SETEUID rump___sysimpl_seteuid +#ifndef RUMP_SYS_RENAME_FUTIMENS +#define RUMP_SYS_RENAME_FUTIMENS rump___sysimpl_futimens #endif -#ifndef RUMP_SYS_RENAME_GETPEERNAME -#define RUMP_SYS_RENAME_GETPEERNAME rump___sysimpl_getpeername +#ifndef RUMP_SYS_RENAME_PREAD +#define RUMP_SYS_RENAME_PREAD rump___sysimpl_pread #endif -#ifndef RUMP_SYS_RENAME_SYMLINK -#define RUMP_SYS_RENAME_SYMLINK rump___sysimpl_symlink +#ifndef RUMP_SYS_RENAME__KSEM_TRYWAIT +#define RUMP_SYS_RENAME__KSEM_TRYWAIT rump___sysimpl__ksem_trywait #endif -#ifndef RUMP_SYS_RENAME_GETUID_WITH_EUID -#define RUMP_SYS_RENAME_GETUID_WITH_EUID rump___sysimpl_getuid +#ifndef RUMP_SYS_RENAME_READLINK +#define RUMP_SYS_RENAME_READLINK rump___sysimpl_readlink #endif -#ifndef RUMP_SYS_RENAME_TIMER_GETTIME -#define RUMP_SYS_RENAME_TIMER_GETTIME rump___sysimpl_timer_gettime50 +#ifndef RUMP_SYS_RENAME_FCHFLAGS +#define RUMP_SYS_RENAME_FCHFLAGS rump___sysimpl_fchflags #endif -#ifndef RUMP_SYS_RENAME_READ -#define RUMP_SYS_RENAME_READ rump___sysimpl_read +
CVS commit: src/sys/kern
Module Name:src Committed By: pooka Date: Wed Jul 23 11:41:34 UTC 2014 Modified Files: src/sys/kern: makesyscalls.sh Log Message: In the RUMP_KERNEL_IS_LIBC case, account for WEAKASM, i.e. create a _sys_foo strong alias, and _foo and foo weak aliases. This actually treats all syscalls as WEAKASM, but it's probably(?) harmless, and saves us from manual work a la libc. Fixes at least pthread_cancelstub. To generate a diff of this commit: cvs rdiff -u -r1.143 -r1.144 src/sys/kern/makesyscalls.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/kern/makesyscalls.sh diff -u src/sys/kern/makesyscalls.sh:1.143 src/sys/kern/makesyscalls.sh:1.144 --- src/sys/kern/makesyscalls.sh:1.143 Sun May 18 21:25:44 2014 +++ src/sys/kern/makesyscalls.sh Wed Jul 23 11:41:34 2014 @@ -1,4 +1,4 @@ -# $NetBSD: makesyscalls.sh,v 1.143 2014/05/18 21:25:44 justin Exp $ +# $NetBSD: makesyscalls.sh,v 1.144 2014/07/23 11:41:34 pooka Exp $ # # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou # All rights reserved. @@ -256,8 +256,9 @@ NR == 1 { printf "#ifdef RUMP_KERNEL_IS_LIBC\n" > rumpcalls printf "#define rsys_aliases(what,where) \\\n" > rumpcalls - printf "\t__strong_alias(what,where); \\\n" > rumpcalls - printf "\t__strong_alias(_##what,where);\n" > rumpcalls + printf "\t__weak_alias(what,where); \\\n" > rumpcalls + printf "\t__weak_alias(_##what,where); \\\n" > rumpcalls + printf "\t__strong_alias(_sys_##what,where);\n" > rumpcalls printf "#else\n#define rsys_aliases(a,b)\n#endif\n\n" > rumpcalls printf "#if\tBYTE_ORDER == BIG_ENDIAN\n" > rumpcalls
CVS commit: src/sys/dev/pci
Module Name:src Committed By: msaitoh Date: Wed Jul 23 09:44:52 UTC 2014 Modified Files: src/sys/dev/pci: if_wm.c Log Message: No functional change: - Add missing prototypes. - Rename functions for consistency and clarify. - KNF. To generate a diff of this commit: cvs rdiff -u -r1.279 -r1.280 src/sys/dev/pci/if_wm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/if_wm.c diff -u src/sys/dev/pci/if_wm.c:1.279 src/sys/dev/pci/if_wm.c:1.280 --- src/sys/dev/pci/if_wm.c:1.279 Tue Jul 22 04:20:39 2014 +++ src/sys/dev/pci/if_wm.c Wed Jul 23 09:44:52 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: if_wm.c,v 1.279 2014/07/22 04:20:39 msaitoh Exp $ */ +/* $NetBSD: if_wm.c,v 1.280 2014/07/23 09:44:52 msaitoh Exp $ */ /* * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc. @@ -76,7 +76,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.279 2014/07/22 04:20:39 msaitoh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.280 2014/07/23 09:44:52 msaitoh Exp $"); #include #include @@ -512,47 +512,83 @@ do { \ CSR_WRITE((sc), (sc)->sc_rdt_reg, (x));\ } while (/*CONSTCOND*/0) -static void wm_start(struct ifnet *); -static void wm_start_locked(struct ifnet *); -static void wm_nq_start(struct ifnet *); -static void wm_nq_start_locked(struct ifnet *); +/* + * Register read/write functions. + * Other than CSR_{READ|WRITE}(). + */ +#if 0 +static inline uint32_t wm_io_read(struct wm_softc *, int); +#endif +static inline void wm_io_write(struct wm_softc *, int, uint32_t); +static inline void wm_82575_write_8bit_ctlr_reg(struct wm_softc *, uint32_t, + uint32_t, uint32_t); +static inline void wm_set_dma_addr(volatile wiseman_addr_t *, bus_addr_t); + +/* + * Device driver interface functions and commonly used functions. + * match, attach, detach, init, start, stop, ioctl, watchdog and so on. + */ +static const struct wm_product *wm_lookup(const struct pci_attach_args *); +static int wm_match(device_t, cfdata_t, void *); +static void wm_attach(device_t, device_t, void *); +static int wm_detach(device_t, int); +static bool wm_suspend(device_t, const pmf_qual_t *); +static bool wm_resume(device_t, const pmf_qual_t *); static void wm_watchdog(struct ifnet *); +static void wm_tick(void *); static int wm_ifflags_cb(struct ethercom *); static int wm_ioctl(struct ifnet *, u_long, void *); -static int wm_init(struct ifnet *); -static int wm_init_locked(struct ifnet *); -static void wm_stop(struct ifnet *, int); -static void wm_stop_locked(struct ifnet *, int); -static bool wm_suspend(device_t, const pmf_qual_t *); -static bool wm_resume(device_t, const pmf_qual_t *); - -static void wm_reset(struct wm_softc *); -static void wm_rxdrain(struct wm_softc *); -static int wm_add_rxbuf(struct wm_softc *, int); -static int wm_read_eeprom(struct wm_softc *, int, int, u_int16_t *); -static int wm_read_eeprom_eerd(struct wm_softc *, int, int, u_int16_t *); -static int wm_validate_eeprom_checksum(struct wm_softc *); +/* MAC address related */ static int wm_check_alt_mac_addr(struct wm_softc *); static int wm_read_mac_addr(struct wm_softc *, uint8_t *); -static void wm_tick(void *); - +static void wm_set_ral(struct wm_softc *, const uint8_t *, int); +static uint32_t wm_mchash(struct wm_softc *, const uint8_t *); static void wm_set_filter(struct wm_softc *); +/* Reset and init related */ static void wm_set_vlan(struct wm_softc *); - -static int wm_intr(void *); +static void wm_set_pcie_completion_timeout(struct wm_softc *); +static void wm_get_auto_rd_done(struct wm_softc *); +static void wm_lan_init_done(struct wm_softc *); +static void wm_get_cfg_done(struct wm_softc *); +static void wm_reset(struct wm_softc *); +static int wm_add_rxbuf(struct wm_softc *, int); +static void wm_rxdrain(struct wm_softc *); +static int wm_init(struct ifnet *); +static int wm_init_locked(struct ifnet *); +static void wm_stop(struct ifnet *, int); +static void wm_stop_locked(struct ifnet *, int); +static int wm_tx_offload(struct wm_softc *, struct wm_txsoft *, +uint32_t *, uint8_t *); +static void wm_dump_mbuf_chain(struct wm_softc *, struct mbuf *); +static void wm_82547_txfifo_stall(void *); +static int wm_82547_txfifo_bugchk(struct wm_softc *, struct mbuf *); +/* Start */ +static void wm_start(struct ifnet *); +static void wm_start_locked(struct ifnet *); +static int wm_nq_tx_offload(struct wm_softc *, struct wm_txsoft *, +uint32_t *, uint32_t *, bool *); +static void wm_nq_start(struct ifnet *); +static void wm_nq_start_locked(struct ifnet *); +/* Interrupt */ static void wm_txintr(struct wm_softc *); static void wm_rxintr(struct wm_softc *); +static void wm_linkintr_gmii(struct wm_softc *, uint32_t); +static void wm_linkintr_tbi(struct wm_softc *, uint32_t); static void wm_linkintr(struct wm_softc *, uint32_t); +static int wm_intr(void *); -static void wm_tbi_mediainit(struct wm_softc *); -s
CVS commit: src
Module Name:src Committed By: apb Date: Wed Jul 23 08:52:32 UTC 2014 Modified Files: src: UPDATING Log Message: More general advice about "cvs [update aborted]... No such file or directory". Also invent a "Cause:" keyword for use in "Symptom:/Cause:/Fix" sections. Also add a note near the top of the file saying that there are several sections marked by "^^^". To generate a diff of this commit: cvs rdiff -u -r1.256 -r1.257 src/UPDATING Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/UPDATING diff -u src/UPDATING:1.256 src/UPDATING:1.257 --- src/UPDATING:1.256 Wed Jul 23 08:37:03 2014 +++ src/UPDATING Wed Jul 23 08:52:32 2014 @@ -1,4 +1,4 @@ -$NetBSD: UPDATING,v 1.256 2014/07/23 08:37:03 apb Exp $ +$NetBSD: UPDATING,v 1.257 2014/07/23 08:52:32 apb Exp $ This file (UPDATING) is intended to be a brief reference to recent changes that might cause problems in the build process, and a guide for @@ -11,6 +11,9 @@ Note that much of the advice in this UPD build.sh existed. Nevertheless, the advice here may be useful for working around specific problems with build.sh. +Sections are marked with "^". After the section on "Recent changes" +are several sections containing more general information. + See also: BUILDING, build.sh, Makefile. Recent changes: @@ -677,3 +680,13 @@ Fix:May need to build & install libs Symptom:Update build fails in src/tools/gcc complaining that a variable (e.g. CPPFLAGS) has changed since the previous run. Fix:Run "nbmake-${ARCH} clean" in src/tools/gcc or do a clean build. + +Symptom:cvs [update aborted]: cannot open directory /cvsroot/src/...: + No such file or directory. +Cause: If a directory is created by mistake, then it is sometimes + deleted from the CVS repository using administrative commands + that bypass the normal cvs access controls. If your cvs working tree + contains references to a directory that has been deleted on the + server in this way, then "cvs update" reports this error. +Fix: Recursively delete the affected directory from your working tree + and try the update again.
CVS commit: src
Module Name:src Committed By: apb Date: Wed Jul 23 08:37:03 UTC 2014 Modified Files: src: UPDATING Log Message: How to deal with src/external/mit/lua/src: No such file or directory To generate a diff of this commit: cvs rdiff -u -r1.255 -r1.256 src/UPDATING Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/UPDATING diff -u src/UPDATING:1.255 src/UPDATING:1.256 --- src/UPDATING:1.255 Fri May 30 18:33:30 2014 +++ src/UPDATING Wed Jul 23 08:37:03 2014 @@ -1,4 +1,4 @@ -$NetBSD: UPDATING,v 1.255 2014/05/30 18:33:30 joerg Exp $ +$NetBSD: UPDATING,v 1.256 2014/07/23 08:37:03 apb Exp $ This file (UPDATING) is intended to be a brief reference to recent changes that might cause problems in the build process, and a guide for @@ -16,6 +16,15 @@ See also: BUILDING, build.sh, Makefile. Recent changes: ^^^ +20140721: + The src/external/mit/lua/src directory was accidentally created + and then deleted in the CVS repository. If you get errors like + + cvs [update aborted]: cannot open directory + /cvsroot/src/external/mit/lua/src: No such file or directory + + then delete your local copy of that directory tree and try again. + 20140530: ARM eABI switched to DWARF based exception handling. This requires rebuilding all C++ code. It is strongly advised to do a clean build.
CVS commit: src
Module Name:src Committed By: alnsn Date: Wed Jul 23 07:16:14 UTC 2014 Modified Files: src/external/bsd/sljit: Makefile.inc src/sys/rump/kern/lib/libsljit: Makefile Added Files: src/sys/rump/kern/lib/libsljit/arch/arm: cpufunc.c sljit_rump.c Log Message: Implement rumpcomp_sync_icache() hyprecall for arm and add a barebone implementation of arm cache ops to librumpkern_sljit. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/external/bsd/sljit/Makefile.inc cvs rdiff -u -r1.2 -r1.3 src/sys/rump/kern/lib/libsljit/Makefile cvs rdiff -u -r0 -r1.1 src/sys/rump/kern/lib/libsljit/arch/arm/cpufunc.c \ src/sys/rump/kern/lib/libsljit/arch/arm/sljit_rump.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/bsd/sljit/Makefile.inc diff -u src/external/bsd/sljit/Makefile.inc:1.1 src/external/bsd/sljit/Makefile.inc:1.2 --- src/external/bsd/sljit/Makefile.inc:1.1 Mon Nov 5 00:23:18 2012 +++ src/external/bsd/sljit/Makefile.inc Wed Jul 23 07:16:14 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.inc,v 1.1 2012/11/05 00:23:18 alnsn Exp $ +# $NetBSD: Makefile.inc,v 1.2 2014/07/23 07:16:14 alnsn Exp $ .include @@ -6,3 +6,9 @@ SLJITDIST= ${NETBSDSRCDIR}/sys/external/ LIBSLJITDIR!= cd ${NETBSDSRCDIR}/external/bsd/sljit/lib && ${PRINTOBJDIR} CPPFLAGS+= -I${SLJITDIST}/sljit_src + +# Link to libarm to get arm_sync_icache(2), for mips it's not +# required because _cacheflush() is in libc. +.if !empty(MACHINE_ARCH:Marm*) || !empty(MACHINE_ARCH:Mearm*) +LDADD+= -larm +.endif Index: src/sys/rump/kern/lib/libsljit/Makefile diff -u src/sys/rump/kern/lib/libsljit/Makefile:1.2 src/sys/rump/kern/lib/libsljit/Makefile:1.3 --- src/sys/rump/kern/lib/libsljit/Makefile:1.2 Tue Jul 22 20:25:13 2014 +++ src/sys/rump/kern/lib/libsljit/Makefile Wed Jul 23 07:16:14 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.2 2014/07/22 20:25:13 alnsn Exp $ +# $NetBSD: Makefile,v 1.3 2014/07/23 07:16:14 alnsn Exp $ # # Public Domain. # @@ -23,5 +23,17 @@ RUMPCOMP_INCS_DIR:= ${.PARSEDIR} RUMPCOMP_USER_CPPFLAGS=-I${RUMPCOMP_INCS_DIR} .endif +.if !empty(MACHINE_ARCH:Marm*) || !empty(MACHINE_ARCH:Mearm*) +SRCS+= cpufunc.c +RUMPCOMP_USER_SRCS= sljit_rump.c +.PATH: ${.CURDIR}/arch/arm + +RUMPCOMP_INCS_DIR:= ${.PARSEDIR} +RUMPCOMP_USER_CPPFLAGS=-I${RUMPCOMP_INCS_DIR} + +# Link to libarm to get arm_sync_icache(2) +LDADD+= -larm +.endif + .include .include Added files: Index: src/sys/rump/kern/lib/libsljit/arch/arm/cpufunc.c diff -u /dev/null src/sys/rump/kern/lib/libsljit/arch/arm/cpufunc.c:1.1 --- /dev/null Wed Jul 23 07:16:14 2014 +++ src/sys/rump/kern/lib/libsljit/arch/arm/cpufunc.c Wed Jul 23 07:16:14 2014 @@ -0,0 +1,52 @@ +/* $NetBSD: cpufunc.c,v 1.1 2014/07/23 07:16:14 alnsn Exp $ */ + +/*- + * Copyright (c) 2014 Alexander Nasonov. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS + * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__KERNEL_RCSID(0, "$NetBSD: cpufunc.c,v 1.1 2014/07/23 07:16:14 alnsn Exp $"); + +/* + * Barebone implementation of arm cpufunc routines for rump. + */ + +#include +#include + +#include "sljit_rump.h" + +static void icache_sync_range(vaddr_t, vsize_t); + +struct cpu_functions cpufuncs = { + .cf_icache_sync_range = &icache_sync_range +}; + +static void +icache_sync_range(vaddr_t va, vsize_t sz) +{ + + (void)rumpcomp_sync_icache((void *)va, (uint64_t)sz); +} Index: src/sys/rump/kern/lib/libsljit/arch/arm/sljit_rump.c diff -u /dev/null src/sys/rump/kern/lib/libsljit/arch/arm/sljit_rump.c:1.1 --- /dev/null Wed Jul 23 07:16:14 2014 +++ src/sys/rump/kern/lib/libsljit/arch/arm/sljit_rump.c Wed Jul 23 07:16:14 2014 @@ -0,0 +1,47 @@ +/* $NetBSD: sljit_r