CVS commit: src/lib/libperfuse
Module Name:src Committed By: manu Date: Wed Nov 12 05:08:44 UTC 2014 Modified Files: src/lib/libperfuse: ops.c Log Message: Allow setxattr to be called with a NULL value, instead of crashing. To generate a diff of this commit: cvs rdiff -u -r1.80 -r1.81 src/lib/libperfuse/ops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libperfuse/ops.c diff -u src/lib/libperfuse/ops.c:1.80 src/lib/libperfuse/ops.c:1.81 --- src/lib/libperfuse/ops.c:1.80 Tue Nov 4 09:17:31 2014 +++ src/lib/libperfuse/ops.c Wed Nov 12 05:08:43 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: ops.c,v 1.80 2014/11/04 09:17:31 manu Exp $ */ +/* $NetBSD: ops.c,v 1.81 2014/11/12 05:08:43 manu Exp $ */ /*- * Copyright (c) 2010-2011 Emmanuel Dreyfus. All rights reserved. @@ -3460,6 +3460,7 @@ perfuse_node_setextattr(struct puffs_use perfuse_msg_t *pm; struct fuse_setxattr_in *fsi; size_t attrnamelen; + size_t datalen; size_t len; char *np; int error; @@ -3472,23 +3473,27 @@ perfuse_node_setextattr(struct puffs_use ps = puffs_getspecific(pu); attrname = perfuse_native_ns(attrns, attrname, fuse_attrname); attrnamelen = strlen(attrname) + 1; - len = sizeof(*fsi) + attrnamelen + *resid; + + datalen = (resid != NULL) ? *resid : 0; + len = sizeof(*fsi) + attrnamelen + datalen; pm = ps->ps_new_msg(pu, opc, FUSE_SETXATTR, len, pcr); fsi = GET_INPAYLOAD(ps, pm, fuse_setxattr_in); - fsi->size = (unsigned int)*resid; + fsi->size = (unsigned int)datalen; fsi->flags = 0; np = (char *)(void *)(fsi + 1); (void)strlcpy(np, attrname, attrnamelen); np += attrnamelen; - (void)memcpy(np, (char *)attr, *resid); + if (datalen) + (void)memcpy(np, (char *)attr, datalen); if ((error = xchg_msg(pu, opc, pm, NO_PAYLOAD_REPLY_LEN, wait_reply)) != 0) goto out; ps->ps_destroy_msg(pm); - *resid = 0; + if (resid) + *resid = 0; error = 0; out:
CVS commit: src/sys/external/bsd/drm2
Module Name:src Committed By: christos Date: Wed Nov 12 04:53:14 UTC 2014 Modified Files: src/sys/external/bsd/drm2/drm: drm_sysctl.c src/sys/external/bsd/drm2/include/linux: moduleparam.h Log Message: fix description setting. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/external/bsd/drm2/drm/drm_sysctl.c cvs rdiff -u -r1.3 -r1.4 \ src/sys/external/bsd/drm2/include/linux/moduleparam.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/external/bsd/drm2/drm/drm_sysctl.c diff -u src/sys/external/bsd/drm2/drm/drm_sysctl.c:1.2 src/sys/external/bsd/drm2/drm/drm_sysctl.c:1.3 --- src/sys/external/bsd/drm2/drm/drm_sysctl.c:1.2 Tue Nov 11 22:14:00 2014 +++ src/sys/external/bsd/drm2/drm/drm_sysctl.c Tue Nov 11 23:53:13 2014 @@ -27,7 +27,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -__KERNEL_RCSID(0, "$NetBSD: drm_sysctl.c,v 1.2 2014/11/12 03:14:00 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: drm_sysctl.c,v 1.3 2014/11/12 04:53:13 christos Exp $"); #include #include @@ -48,7 +48,7 @@ drm_sysctl_get_description(const struct for (; b < e; b++) { const struct linux_module_param_desc *d = *b; - if (strcmp(p->name, d->name) == 0) + if (strcmp(p->dname, d->name) == 0) return d->description; } return NULL; Index: src/sys/external/bsd/drm2/include/linux/moduleparam.h diff -u src/sys/external/bsd/drm2/include/linux/moduleparam.h:1.3 src/sys/external/bsd/drm2/include/linux/moduleparam.h:1.4 --- src/sys/external/bsd/drm2/include/linux/moduleparam.h:1.3 Tue Nov 11 21:24:40 2014 +++ src/sys/external/bsd/drm2/include/linux/moduleparam.h Tue Nov 11 23:53:14 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: moduleparam.h,v 1.3 2014/11/12 02:24:40 christos Exp $ */ +/* $NetBSD: moduleparam.h,v 1.4 2014/11/12 04:53:14 christos Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -35,10 +35,11 @@ #include struct linux_module_param_info { - const char *name; - void *ptr; - int type; - mode_t mode; + const char *dname; // Name used for description + const char *name; // Name for sysctl + void *ptr; // Pointer to variable value + int type; // MTYPE_ + mode_t mode; // 600 (rw) or 400 (r) }; #define MTYPE_int 0 @@ -46,6 +47,7 @@ struct linux_module_param_info { #define module_param_named(NAME, VAR, TYPE, MODE) \ static __attribute__((__used__)) struct linux_module_param_info info_ ## NAME = { \ + .dname = # NAME, \ .name = # VAR, \ .ptr = & VAR, \ .type = MTYPE_ ## TYPE, \
CVS commit: src/distrib/sets
Module Name:src Committed By: enami Date: Wed Nov 12 03:49:26 UTC 2014 Modified Files: src/distrib/sets: sets.subr Log Message: List missing compatmodules keyword in the comment. To generate a diff of this commit: cvs rdiff -u -r1.160 -r1.161 src/distrib/sets/sets.subr Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/sets.subr diff -u src/distrib/sets/sets.subr:1.160 src/distrib/sets/sets.subr:1.161 --- src/distrib/sets/sets.subr:1.160 Wed Jan 29 22:35:52 2014 +++ src/distrib/sets/sets.subr Wed Nov 12 03:49:26 2014 @@ -1,4 +1,4 @@ -# $NetBSD: sets.subr,v 1.160 2014/01/29 22:35:52 joerg Exp $ +# $NetBSD: sets.subr,v 1.161 2014/11/12 03:49:26 enami Exp $ # # @@ -179,7 +179,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g # In each file, a record consists of a path and a System Package name, # separated by whitespace. E.g., # -# # $NetBSD: sets.subr,v 1.160 2014/01/29 22:35:52 joerg Exp $ +# # $NetBSD: sets.subr,v 1.161 2014/11/12 03:49:26 enami Exp $ # . base-sys-root [keyword[,...]] # ./altroot base-sys-root # ./bin base-sys-root @@ -205,6 +205,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g # bsdgrep ${MKBSDGREP} != no # catpages ${MKCATPAGES} != no # compat ${MKCOMPAT} != no +# compatmodules ${MKCOMPATMODULES} != no # crypto ${MKCRYPTO} != no # crypto_rc5 ${MKCRYPTO_RC5} != no # cvs ${MKCVS} != no
CVS commit: src/distrib/sets/lists/modules
Module Name:src Committed By: enami Date: Wed Nov 12 03:48:30 UTC 2014 Modified Files: src/distrib/sets/lists/modules: md.amd64 md.i386 Log Message: Add compatmodules keyword so that build.sh -V MKCOMPATMODULES=no won't fail. To generate a diff of this commit: cvs rdiff -u -r1.47 -r1.48 src/distrib/sets/lists/modules/md.amd64 cvs rdiff -u -r1.50 -r1.51 src/distrib/sets/lists/modules/md.i386 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/modules/md.amd64 diff -u src/distrib/sets/lists/modules/md.amd64:1.47 src/distrib/sets/lists/modules/md.amd64:1.48 --- src/distrib/sets/lists/modules/md.amd64:1.47 Tue Nov 11 11:23:25 2014 +++ src/distrib/sets/lists/modules/md.amd64 Wed Nov 12 03:48:30 2014 @@ -1,4 +1,4 @@ -# $NetBSD: md.amd64,v 1.47 2014/11/11 11:23:25 nonaka Exp $ +# $NetBSD: md.amd64,v 1.48 2014/11/12 03:48:30 enami Exp $ # # NOTE that there are two sets of files here: # @MODULEDIR@ and amd64-xen @@ -260,12 +260,12 @@ ./stand/amd64-xen/@OSRELEASE@/modules/dm/dm.kmod base-kernel-modules kmod,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/drmbase-kernel-modules kmod,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/drm/drm.kmod base-kernel-modules kmod,compatmodules -./stand/amd64-xen/@OSRELEASE@/modules/drmkmsbase-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/modules/drmkms/drmkms.kmod base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/modules/drmkms_linux base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/modules/drmkms_pci base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod +./stand/amd64-xen/@OSRELEASE@/modules/drmkmsbase-kernel-modules kmod,compatmodules +./stand/amd64-xen/@OSRELEASE@/modules/drmkms/drmkms.kmod base-kernel-modules kmod,compatmodules +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_linux base-kernel-modules kmod,compatmodules +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod,compatmodules +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_pci base-kernel-modules kmod,compatmodules +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/dtracebase-kernel-modules kmod,dtrace,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/dtrace/dtrace.kmod base-kernel-modules kmod,dtrace,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/dtrace_fbt base-kernel-modules kmod,dtrace,compatmodules Index: src/distrib/sets/lists/modules/md.i386 diff -u src/distrib/sets/lists/modules/md.i386:1.50 src/distrib/sets/lists/modules/md.i386:1.51 --- src/distrib/sets/lists/modules/md.i386:1.50 Tue Nov 11 11:23:25 2014 +++ src/distrib/sets/lists/modules/md.i386 Wed Nov 12 03:48:30 2014 @@ -1,4 +1,4 @@ -# $NetBSD: md.i386,v 1.50 2014/11/11 11:23:25 nonaka Exp $ +# $NetBSD: md.i386,v 1.51 2014/11/12 03:48:30 enami Exp $ # # NOTE that there are three sets of files here: # @MODULEDIR@, i386-xen, and i386pae-xen @@ -288,12 +288,12 @@ ./stand/i386-xen/@OSRELEASE@/modules/dm/dm.kmodbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drmbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drm/drm.kmod base-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/modules/drmkms base-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/modules/drmkms/drmkms.kmodbase-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/modules/drmkms_linuxbase-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/modules/drmkms_pci base-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod +./stand/i386-xen/@OSRELEASE@/modules/drmkmsbase-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/drmkms/drmkms.kmod base-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/drmkms_linux base-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/drmkms_pcibase-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtvbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtv/dtv.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtv_mathbase-kernel-modules kmod,compatmodules @@ -677,12 +677,12 @@ ./stand/i386pae-xen/@OSRELEASE@/modules/dm/dm.kmod base-kernel-modules kmod,compatmodules ./s
CVS commit: src/usr.bin/netstat
Module Name:src Committed By: christos Date: Wed Nov 12 03:34:59 UTC 2014 Modified Files: src/usr.bin/netstat: main.c Log Message: PR/47704: Takahiro HAYASHI: Fix -L flag To generate a diff of this commit: cvs rdiff -u -r1.94 -r1.95 src/usr.bin/netstat/main.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.bin/netstat/main.c diff -u src/usr.bin/netstat/main.c:1.94 src/usr.bin/netstat/main.c:1.95 --- src/usr.bin/netstat/main.c:1.94 Fri Nov 7 07:42:27 2014 +++ src/usr.bin/netstat/main.c Tue Nov 11 22:34:59 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: main.c,v 1.94 2014/11/07 12:42:27 christos Exp $ */ +/* $NetBSD: main.c,v 1.95 2014/11/12 03:34:59 christos Exp $ */ /* * Copyright (c) 1983, 1988, 1993 @@ -39,7 +39,7 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 19 #if 0 static char sccsid[] = "from: @(#)main.c 8.4 (Berkeley) 3/1/94"; #else -__RCSID("$NetBSD: main.c,v 1.94 2014/11/07 12:42:27 christos Exp $"); +__RCSID("$NetBSD: main.c,v 1.95 2014/11/12 03:34:59 christos Exp $"); #endif #endif /* not lint */ @@ -454,7 +454,7 @@ main(int argc, char *argv[]) iflag = 1; break; case 'L': - Lflag = 1; + Lflag = RT_LFLAG; break; case 'l': lflag = 1; @@ -639,7 +639,7 @@ main(int argc, char *argv[]) else { if (use_sysctl) p_rttables(af, - nflag|tagflag|vflag, 0, ~0); + nflag|tagflag|vflag|Lflag, 0, ~0); else routepr(nl[N_RTREE].n_value); }
CVS commit: src/sbin/route
Module Name:src Committed By: christos Date: Wed Nov 12 03:34:08 UTC 2014 Modified Files: src/sbin/route: route.8 route.c rtutil.c rtutil.h Log Message: PR/47704: Takahiro HAYASHI: Add -L flag To generate a diff of this commit: cvs rdiff -u -r1.51 -r1.52 src/sbin/route/route.8 cvs rdiff -u -r1.146 -r1.147 src/sbin/route/route.c cvs rdiff -u -r1.2 -r1.3 src/sbin/route/rtutil.c cvs rdiff -u -r1.1 -r1.2 src/sbin/route/rtutil.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sbin/route/route.8 diff -u src/sbin/route/route.8:1.51 src/sbin/route/route.8:1.52 --- src/sbin/route/route.8:1.51 Fri Nov 7 09:57:08 2014 +++ src/sbin/route/route.8 Tue Nov 11 22:34:08 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: route.8,v 1.51 2014/11/07 14:57:08 christos Exp $ +.\" $NetBSD: route.8,v 1.52 2014/11/12 03:34:08 christos Exp $ .\" .\" Copyright (c) 1983, 1991, 1993 .\" The Regents of the University of California. All rights reserved. @@ -29,7 +29,7 @@ .\" .\" @(#)route.8 8.4 (Berkeley) 6/1/94 .\" -.Dd November 7, 2014 +.Dd November 11, 2014 .Dt ROUTE 8 .Os .Sh NAME @@ -37,7 +37,7 @@ .Nd manually manipulate the routing tables .Sh SYNOPSIS .Nm -.Op Fl dfnqSsTtv +.Op Fl dfLnqSsTtv .Ar command .Oo .Op Ar modifiers @@ -81,6 +81,8 @@ or commands, .Nm removes the routes before performing the command. +.It Fl L +Don't show link layer entries in routing table. .It Fl n Bypasses attempts to print host and network names symbolically when reporting actions. Index: src/sbin/route/route.c diff -u src/sbin/route/route.c:1.146 src/sbin/route/route.c:1.147 --- src/sbin/route/route.c:1.146 Fri Nov 7 09:57:08 2014 +++ src/sbin/route/route.c Tue Nov 11 22:34:08 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: route.c,v 1.146 2014/11/07 14:57:08 christos Exp $ */ +/* $NetBSD: route.c,v 1.147 2014/11/12 03:34:08 christos Exp $ */ /* * Copyright (c) 1983, 1989, 1991, 1993 @@ -39,7 +39,7 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 19 #if 0 static char sccsid[] = "@(#)route.c 8.6 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: route.c,v 1.146 2014/11/07 14:57:08 christos Exp $"); +__RCSID("$NetBSD: route.c,v 1.147 2014/11/12 03:34:08 christos Exp $"); #endif #endif /* not lint */ @@ -126,15 +126,16 @@ static void sockaddr(const char *, struc int pid, rtm_addrs; int sock; -int forcehost, forcenet, doflush, nflag, af, qflag, tflag, Sflag, Tflag; -int iflag, verbose, aflen = sizeof(struct sockaddr_in), rtag; +int forcehost, forcenet, doflush, af; +int iflag, Lflag, nflag, qflag, tflag, Sflag, Tflag; +int verbose, aflen = sizeof(struct sockaddr_in), rtag; int locking, lockrest, debugonly, shortoutput; struct rt_metrics rt_metrics; int rtm_inits; short ns_nullh[] = {0,0,0}; short ns_bh[] = {-1,-1,-1}; -static const char opts[] = "dfnqSsTtv"; +static const char opts[] = "dfLnqSsTtv"; void usage(const char *cp) @@ -168,6 +169,9 @@ main(int argc, char * const *argv) case 'f': doflush = 1; break; + case 'L': + Lflag = RT_LFLAG; + break; case 'n': nflag = RT_NFLAG; break; @@ -228,7 +232,7 @@ main(int argc, char * const *argv) return newroute(argc, argv); case K_SHOW: - show(argc, argv, nflag|Tflag|verbose); + show(argc, argv, Lflag|nflag|Tflag|verbose); return 0; #ifndef SMALL Index: src/sbin/route/rtutil.c diff -u src/sbin/route/rtutil.c:1.2 src/sbin/route/rtutil.c:1.3 --- src/sbin/route/rtutil.c:1.2 Fri Nov 7 19:47:32 2014 +++ src/sbin/route/rtutil.c Tue Nov 11 22:34:08 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: rtutil.c,v 1.2 2014/11/08 00:47:32 christos Exp $ */ +/* $NetBSD: rtutil.c,v 1.3 2014/11/12 03:34:08 christos Exp $ */ /* $OpenBSD: show.c,v 1.1 2006/05/27 19:16:37 claudio Exp $ */ /* @@ -261,6 +261,9 @@ p_rtentry(struct rt_msghdr *rtm, int fla char ifbuf[IF_NAMESIZE]; #endif + if ((flags & RT_LFLAG) && (rtm->rtm_flags & RTF_LLINFO)) + return; + if (old_af != sa->sa_family) { old_af = sa->sa_family; p_family(sa->sa_family); Index: src/sbin/route/rtutil.h diff -u src/sbin/route/rtutil.h:1.1 src/sbin/route/rtutil.h:1.2 --- src/sbin/route/rtutil.h:1.1 Thu Nov 6 16:29:32 2014 +++ src/sbin/route/rtutil.h Tue Nov 11 22:34:08 2014 @@ -30,10 +30,11 @@ * POSSIBILITY OF SUCH DAMAGE. */ -#define RT_AFLAG 1 -#define RT_TFLAG 2 -#define RT_VFLAG 4 -#define RT_NFLAG 8 +#define RT_AFLAG __BIT(0) /* show address field */ +#define RT_TFLAG __BIT(1) /* show tag field */ +#define RT_VFLAG __BIT(2) /* show verbose statistics */ +#define RT_NFLAG __BIT(3) /* numeric output */ +#define RT_LFLAG __BIT(4) /* don't show LLINFO entries */ void p_rttables(int, int, int, int); void p_rthdr(int, int);
CVS commit: src/sys/netinet6
Module Name:src Committed By: ozaki-r Date: Wed Nov 12 03:24:25 UTC 2014 Modified Files: src/sys/netinet6: mld6.c Log Message: Ensure callout isn't running and pending before callout_destroy Call callout_halt before callout_destroy. And also let callout (mld_timeo) not call callout_schedule when we already called callout_halt. This fixes PR 47881. To generate a diff of this commit: cvs rdiff -u -r1.60 -r1.61 src/sys/netinet6/mld6.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/netinet6/mld6.c diff -u src/sys/netinet6/mld6.c:1.60 src/sys/netinet6/mld6.c:1.61 --- src/sys/netinet6/mld6.c:1.60 Tue Sep 9 20:16:12 2014 +++ src/sys/netinet6/mld6.c Wed Nov 12 03:24:25 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: mld6.c,v 1.60 2014/09/09 20:16:12 rmind Exp $ */ +/* $NetBSD: mld6.c,v 1.61 2014/11/12 03:24:25 ozaki-r Exp $ */ /* $KAME: mld6.c,v 1.25 2001/01/16 14:14:18 itojun Exp $ */ /* @@ -102,7 +102,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: mld6.c,v 1.60 2014/09/09 20:16:12 rmind Exp $"); +__KERNEL_RCSID(0, "$NetBSD: mld6.c,v 1.61 2014/11/12 03:24:25 ozaki-r Exp $"); #include "opt_inet.h" @@ -195,6 +195,8 @@ mld_starttimer(struct in6_multi *in6m) { struct timeval now; + KASSERT(in6m->in6m_timer != IN6M_TIMER_UNDEF); + microtime(&now); in6m->in6m_timer_expire.tv_sec = now.tv_sec + in6m->in6m_timer / hz; in6m->in6m_timer_expire.tv_usec = now.tv_usec + @@ -227,6 +229,9 @@ mld_timeo(void *arg) mutex_enter(softnet_lock); KERNEL_LOCK(1, NULL); + if (in6m->in6m_timer == IN6M_TIMER_UNDEF) + goto out; + in6m->in6m_timer = IN6M_TIMER_UNDEF; switch (in6m->in6m_state) { @@ -238,6 +243,7 @@ mld_timeo(void *arg) break; } +out: KERNEL_UNLOCK_ONE(NULL); mutex_exit(softnet_lock); } @@ -741,7 +747,12 @@ in6_delmulti(struct in6_multi *in6m) */ sockaddr_in6_init(&sin6, &in6m->in6m_addr, 0, 0, 0); if_mcast_op(in6m->in6m_ifp, SIOCDELMULTI, sin6tosa(&sin6)); + + /* Tell mld_timeo we're halting the timer */ + in6m->in6m_timer = IN6M_TIMER_UNDEF; + callout_halt(&in6m->in6m_timer_ch, softnet_lock); callout_destroy(&in6m->in6m_timer_ch); + free(in6m, M_IPMADDR); } splx(s);
CVS commit: src/sys/external/bsd/drm2
Module Name:src Committed By: christos Date: Wed Nov 12 03:14:00 UTC 2014 Modified Files: src/sys/external/bsd/drm2/drm: drm_module.c drm_sysctl.c src/sys/external/bsd/drm2/i915drm: i915_module.c src/sys/external/bsd/drm2/include/drm: drm_sysctl.h src/sys/external/bsd/drm2/nouveau: nouveau_module.c src/sys/external/bsd/drm2/radeon: radeon_module.c Log Message: prettify and add to all the modules that have it. To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sys/external/bsd/drm2/drm/drm_module.c cvs rdiff -u -r1.1 -r1.2 src/sys/external/bsd/drm2/drm/drm_sysctl.c cvs rdiff -u -r1.4 -r1.5 src/sys/external/bsd/drm2/i915drm/i915_module.c cvs rdiff -u -r1.1 -r1.2 src/sys/external/bsd/drm2/include/drm/drm_sysctl.h cvs rdiff -u -r1.2 -r1.3 src/sys/external/bsd/drm2/nouveau/nouveau_module.c cvs rdiff -u -r1.2 -r1.3 src/sys/external/bsd/drm2/radeon/radeon_module.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/drm/drm_module.c diff -u src/sys/external/bsd/drm2/drm/drm_module.c:1.8 src/sys/external/bsd/drm2/drm/drm_module.c:1.9 --- src/sys/external/bsd/drm2/drm/drm_module.c:1.8 Sun Sep 14 16:08:21 2014 +++ src/sys/external/bsd/drm2/drm/drm_module.c Tue Nov 11 22:14:00 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: drm_module.c,v 1.8 2014/09/14 20:08:21 riastradh Exp $ */ +/* $NetBSD: drm_module.c,v 1.9 2014/11/12 03:14:00 christos Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: drm_module.c,v 1.8 2014/09/14 20:08:21 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: drm_module.c,v 1.9 2014/11/12 03:14:00 christos Exp $"); #include #include @@ -45,6 +45,7 @@ __KERNEL_RCSID(0, "$NetBSD: drm_module.c #include #include +#include /* * XXX I2C stuff should be moved to a separate drmkms_i2c module. @@ -53,6 +54,8 @@ MODULE(MODULE_CLASS_DRIVER, drmkms, "iic struct mutex drm_global_mutex; +struct drm_sysctl_def drm_def = DRM_SYSCTL_INIT(); + static int drm_init(void) { @@ -71,6 +74,7 @@ drm_init(void) linux_mutex_init(&drm_global_mutex); drm_connector_ida_init(); drm_global_init(); + drm_sysctl_init(&drm_def); return 0; } @@ -91,7 +95,7 @@ drm_guarantee_initialized(void) static void drm_fini(void) { - + drm_sysctl_fini(&drm_def); drm_global_release(); drm_connector_ida_destroy(); linux_mutex_destroy(&drm_global_mutex); Index: src/sys/external/bsd/drm2/drm/drm_sysctl.c diff -u src/sys/external/bsd/drm2/drm/drm_sysctl.c:1.1 src/sys/external/bsd/drm2/drm/drm_sysctl.c:1.2 --- src/sys/external/bsd/drm2/drm/drm_sysctl.c:1.1 Tue Nov 11 21:24:40 2014 +++ src/sys/external/bsd/drm2/drm/drm_sysctl.c Tue Nov 11 22:14:00 2014 @@ -27,7 +27,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -__KERNEL_RCSID(0, "$NetBSD: drm_sysctl.c,v 1.1 2014/11/12 02:24:40 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: drm_sysctl.c,v 1.2 2014/11/12 03:14:00 christos Exp $"); #include #include @@ -41,9 +41,10 @@ __KERNEL_RCSID(0, "$NetBSD: drm_sysctl.c #include static const char * -drm_sysctl_get_description(const struct linux_module_param_info *p, const void **v) +drm_sysctl_get_description(const struct linux_module_param_info *p, +const struct drm_sysctl_def *def) { - const void * const *b = v[0], * const *e = v[1]; + const void * const *b = def->bd, * const *e = def->ed; for (; b < e; b++) { const struct linux_module_param_desc *d = *b; @@ -112,14 +113,14 @@ drm_sysctl_node(const char *name, const void -drm_sysctl_init(const void **v, struct sysctllog **log) +drm_sysctl_init(struct drm_sysctl_def *def) { - const void * const *b = v[0], * const *e = v[1]; + const void * const *b = def->bp, * const *e = def->ep; const struct sysctlnode *rnode = NULL, *cnode; const char *name = "drm2"; int error; - if ((error = sysctl_createv(log, 0, NULL, &rnode, + if ((error = sysctl_createv(&def->log, 0, NULL, &rnode, CTLFLAG_PERMANENT, CTLTYPE_NODE, name, SYSCTL_DESCR("DRM driver parameters"), NULL, 0, NULL, 0, CTL_HW, CTL_CREATE, CTL_EOL)) != 0) { @@ -135,17 +136,18 @@ drm_sysctl_init(const void **v, struct s cnode = rnode; for (n = copy; (nn = strchr(n, '.')) != NULL; n = nn) { *nn++ = '\0'; - if ((error = drm_sysctl_node(n, &cnode, log)) != 0) { + if ((error = drm_sysctl_node(n, &cnode, &def->log)) + != 0) { aprint_error("sysctl_createv returned %d, " "for %s ignoring\n", error, n); continue; } } - if ((error = sysctl_createv(log, 0, &cnode, + if ((error = sysctl_createv(&def->log, 0, &cnode, &cnode, p->mode == 0600 ? CTLFLAG_READWRITE : 0, drm_sysctl_get_type(p), n, - SYSCTL_DESCR(drm_sysctl_get_description(p, v + 2)), + SYSCTL_DESCR(drm_sysctl_get_description(p, def)), NULL, 0, p->ptr, 0, CTL_CREATE, CTL_EOL))
CVS commit: src/sys/dev/ic
Module Name:src Committed By: christos Date: Wed Nov 12 03:12:35 UTC 2014 Modified Files: src/sys/dev/ic: pcdisplayvar.h vgavar.h Log Message: more _KERNEL_OPT To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/sys/dev/ic/pcdisplayvar.h cvs rdiff -u -r1.31 -r1.32 src/sys/dev/ic/vgavar.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/ic/pcdisplayvar.h diff -u src/sys/dev/ic/pcdisplayvar.h:1.19 src/sys/dev/ic/pcdisplayvar.h:1.20 --- src/sys/dev/ic/pcdisplayvar.h:1.19 Sun Mar 15 11:52:12 2009 +++ src/sys/dev/ic/pcdisplayvar.h Tue Nov 11 22:12:35 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: pcdisplayvar.h,v 1.19 2009/03/15 15:52:12 cegger Exp $ */ +/* $NetBSD: pcdisplayvar.h,v 1.20 2014/11/12 03:12:35 christos Exp $ */ /* * Copyright (c) 1998 @@ -26,7 +26,9 @@ * */ +#ifdef _KERNEL_OPT #include "opt_pcdisplay.h" +#endif struct pcdisplayscreen { struct pcdisplay_handle *hdl; Index: src/sys/dev/ic/vgavar.h diff -u src/sys/dev/ic/vgavar.h:1.31 src/sys/dev/ic/vgavar.h:1.32 --- src/sys/dev/ic/vgavar.h:1.31 Thu Aug 21 09:52:22 2014 +++ src/sys/dev/ic/vgavar.h Tue Nov 11 22:12:35 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: vgavar.h,v 1.31 2014/08/21 13:52:22 macallan Exp $ */ +/* $NetBSD: vgavar.h,v 1.32 2014/11/12 03:12:35 christos Exp $ */ /* * Copyright (c) 1995, 1996 Carnegie-Mellon University. @@ -29,7 +29,9 @@ #include +#ifdef _KERNEL_OPT #include "opt_vga.h" +#endif struct vga_handle { struct pcdisplay_handle vh_ph;
CVS commit: src/sys/modules/drmkms
Module Name:src Committed By: christos Date: Wed Nov 12 03:03:01 UTC 2014 Modified Files: src/sys/modules/drmkms: Makefile Log Message: this module needs MKLDSCRIPT too now To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/modules/drmkms/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/modules/drmkms/Makefile diff -u src/sys/modules/drmkms/Makefile:1.5 src/sys/modules/drmkms/Makefile:1.6 --- src/sys/modules/drmkms/Makefile:1.5 Tue Nov 11 21:13:30 2014 +++ src/sys/modules/drmkms/Makefile Tue Nov 11 22:03:01 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.5 2014/11/12 02:13:30 christos Exp $ +# $NetBSD: Makefile,v 1.6 2014/11/12 03:03:01 christos Exp $ .include "../Makefile.inc" .include "Makefile.inc" @@ -7,6 +7,7 @@ .PATH: ${S}/external/bsd/drm2/pci .PATH: ${S}/external/bsd/drm2/dist/drm +MKLDSCRIPT=yes KMOD= drmkms # Upstream source files.
CVS commit: src/share/mk
Module Name:src Committed By: christos Date: Wed Nov 12 02:50:01 UTC 2014 Modified Files: src/share/mk: bsd.kmodule.mk Log Message: use ${HOST_SH} To generate a diff of this commit: cvs rdiff -u -r1.47 -r1.48 src/share/mk/bsd.kmodule.mk Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/mk/bsd.kmodule.mk diff -u src/share/mk/bsd.kmodule.mk:1.47 src/share/mk/bsd.kmodule.mk:1.48 --- src/share/mk/bsd.kmodule.mk:1.47 Tue Nov 11 21:19:28 2014 +++ src/share/mk/bsd.kmodule.mk Tue Nov 11 21:50:01 2014 @@ -1,4 +1,4 @@ -# $NetBSD: bsd.kmodule.mk,v 1.47 2014/11/12 02:19:28 christos Exp $ +# $NetBSD: bsd.kmodule.mk,v 1.48 2014/11/12 02:50:01 christos Exp $ # We are not building this with PIE MKPIE=no @@ -162,7 +162,7 @@ ${PROG}: ${OBJS} ${DPADD} ${_MKTARGET_LINK} .if ${MKLDSCRIPT} == "yes" @rm -f ${KMODSCRIPT} - @OBJDUMP=${OBJDUMP} $S/conf/mkldscript.sh ${KMODSCRIPTSRC} ${OBJS} \ + @OBJDUMP=${OBJDUMP} ${HOST_SH} $S/conf/mkldscript.sh ${KMODSCRIPTSRC} ${OBJS} \ > ${KMODSCRIPT} .endif ${CC} ${LDFLAGS} -nostdlib -r -Wl,-T,${KMODSCRIPT},-d \
CVS commit: src/sys/external/bsd/drm2
Module Name:src Committed By: christos Date: Wed Nov 12 02:24:40 UTC 2014 Modified Files: src/sys/external/bsd/drm2/drm: files.drmkms src/sys/external/bsd/drm2/i915drm: i915_module.c src/sys/external/bsd/drm2/include/linux: module.h moduleparam.h Added Files: src/sys/external/bsd/drm2/drm: drm_sysctl.c src/sys/external/bsd/drm2/include/drm: drm_sysctl.h Log Message: Add __link_set based code to automatically convert the linux module parameters into sysctls. To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/external/bsd/drm2/drm/drm_sysctl.c cvs rdiff -u -r1.8 -r1.9 src/sys/external/bsd/drm2/drm/files.drmkms cvs rdiff -u -r1.3 -r1.4 src/sys/external/bsd/drm2/i915drm/i915_module.c cvs rdiff -u -r0 -r1.1 src/sys/external/bsd/drm2/include/drm/drm_sysctl.h cvs rdiff -u -r1.4 -r1.5 src/sys/external/bsd/drm2/include/linux/module.h cvs rdiff -u -r1.2 -r1.3 \ src/sys/external/bsd/drm2/include/linux/moduleparam.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/external/bsd/drm2/drm/files.drmkms diff -u src/sys/external/bsd/drm2/drm/files.drmkms:1.8 src/sys/external/bsd/drm2/drm/files.drmkms:1.9 --- src/sys/external/bsd/drm2/drm/files.drmkms:1.8 Sun Sep 14 15:06:00 2014 +++ src/sys/external/bsd/drm2/drm/files.drmkms Tue Nov 11 21:24:40 2014 @@ -1,4 +1,4 @@ -# $NetBSD: files.drmkms,v 1.8 2014/09/14 19:06:00 riastradh Exp $ +# $NetBSD: files.drmkms,v 1.9 2014/11/12 02:24:40 christos Exp $ include "external/bsd/drm2/linux/files.drmkms_linux" @@ -65,5 +65,6 @@ file external/bsd/drm2/drm/drm_vma_manag file external/bsd/drm2/drm/drm_gem_vm.c drmkms file external/bsd/drm2/drm/drm_module.c drmkms +file external/bsd/drm2/drm/drm_sysctl.c drmkms include "external/bsd/drm2/ttm/files.ttm" Index: src/sys/external/bsd/drm2/i915drm/i915_module.c diff -u src/sys/external/bsd/drm2/i915drm/i915_module.c:1.3 src/sys/external/bsd/drm2/i915drm/i915_module.c:1.4 --- src/sys/external/bsd/drm2/i915drm/i915_module.c:1.3 Wed Jul 16 16:56:25 2014 +++ src/sys/external/bsd/drm2/i915drm/i915_module.c Tue Nov 11 21:24:40 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: i915_module.c,v 1.3 2014/07/16 20:56:25 riastradh Exp $ */ +/* $NetBSD: i915_module.c,v 1.4 2014/11/12 02:24:40 christos Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: i915_module.c,v 1.3 2014/07/16 20:56:25 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: i915_module.c,v 1.4 2014/11/12 02:24:40 christos Exp $"); #include #include @@ -40,6 +40,7 @@ __KERNEL_RCSID(0, "$NetBSD: i915_module. #include #include +#include #include "i915_drv.h" @@ -54,6 +55,10 @@ extern struct drm_driver *const i915_drm extern const struct pci_device_id *const i915_device_ids; extern const size_t i915_n_device_ids; +static struct sysctllog *i915_sysctllog; +__link_set_decl(linux_module_param_info, struct linux_module_param_info); +__link_set_decl(linux_module_param_desc, struct linux_module_param_desc); + static int i915drmkms_init(void) { @@ -74,6 +79,13 @@ i915drmkms_init(void) error); return error; } + const void *v[] = { + __link_set_start(linux_module_param_info), + __link_set_end(linux_module_param_info), + __link_set_start(linux_module_param_desc), + __link_set_end(linux_module_param_desc), + }; + drm_sysctl_init(v, &i915_sysctllog); return 0; } @@ -96,6 +108,7 @@ i915drmkms_fini(void) { drm_pci_exit(i915_drm_driver, NULL); + drm_sysctl_fini(&i915_sysctllog); } static int Index: src/sys/external/bsd/drm2/include/linux/module.h diff -u src/sys/external/bsd/drm2/include/linux/module.h:1.4 src/sys/external/bsd/drm2/include/linux/module.h:1.5 --- src/sys/external/bsd/drm2/include/linux/module.h:1.4 Wed Aug 6 09:49:33 2014 +++ src/sys/external/bsd/drm2/include/linux/module.h Tue Nov 11 21:24:40 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: module.h,v 1.4 2014/08/06 13:49:33 riastradh Exp $ */ +/* $NetBSD: module.h,v 1.5 2014/11/12 02:24:40 christos Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -43,7 +43,17 @@ #define MODULE_DEVICE_TABLE(DESCRIPTION, IDLIST) #define MODULE_FIRMWARE(FIRMWARE) #define MODULE_LICENSE(LICENSE) -#define MODULE_PARM_DESC(PARAMETER, DESCRIPTION) +struct linux_module_param_desc { + const char *name; + const char *description; +}; +#define MODULE_PARM_DESC(PARAMETER, DESCRIPTION) \ +static __attribute__((__used__)) \ +const struct linux_module_param_desc PARAMETER ## _desc = { \ +.name = # PARAMETER, \ +.description = DESCRIPTION, \ +}; \ +__link_set_add_rodata(linux_module_param_desc, PARAMETER ## _desc) #define THIS_MODULE 0 Index: src/sys/external/bsd/drm2/include/linux/moduleparam.h diff -u src/sys/external/bsd/drm2/include/linux/moduleparam.h:1.2 src/sys/external/bsd/drm2/include/linux/moduleparam.h:1.3 --- src/sys/externa
CVS commit: src/share/mk
Module Name:src Committed By: christos Date: Wed Nov 12 02:19:28 UTC 2014 Modified Files: src/share/mk: bsd.kmodule.mk Log Message: Enable dynamic link script generation to handle __{start,stop}_link_set_* via a variable; perhaps delete the variable and always do it? To generate a diff of this commit: cvs rdiff -u -r1.46 -r1.47 src/share/mk/bsd.kmodule.mk Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/mk/bsd.kmodule.mk diff -u src/share/mk/bsd.kmodule.mk:1.46 src/share/mk/bsd.kmodule.mk:1.47 --- src/share/mk/bsd.kmodule.mk:1.46 Thu Nov 6 07:05:44 2014 +++ src/share/mk/bsd.kmodule.mk Tue Nov 11 21:19:28 2014 @@ -1,4 +1,4 @@ -# $NetBSD: bsd.kmodule.mk,v 1.46 2014/11/06 12:05:44 uebayasi Exp $ +# $NetBSD: bsd.kmodule.mk,v 1.47 2014/11/12 02:19:28 christos Exp $ # We are not building this with PIE MKPIE=no @@ -11,6 +11,7 @@ MKPIE=no realinstall: kmodinstall KERN= $S/kern +MKLDSCRIPT?= no CFLAGS+= -ffreestanding ${COPTS} CPPFLAGS+= -nostdinc -I. -I${.CURDIR} -isystem $S -isystem $S/arch @@ -72,9 +73,14 @@ DPSRCS+= ${_YKMSRCS} CLEANFILES+= ${_YKMSRCS} .if exists($S/../sys/modules/xldscripts/kmodule) -KMODSCRIPT= $S/../sys/modules/xldscripts/kmodule +KMODSCRIPTSRC= $S/../sys/modules/xldscripts/kmodule .else -KMODSCRIPT= ${DESTDIR}/usr/libdata/ldscripts/kmodule +KMODSCRIPTSRC= ${DESTDIR}/usr/libdata/ldscripts/kmodule +.endif +.if ${MKLDSCRIPT} == "yes" +KMODSCRIPT= kldscript +.else +KMODSCRIPT= ${KMODSCRIPTSRC} .endif PROG?= ${KMOD}.kmod @@ -102,6 +108,9 @@ ${XOBJS}: ${DPSRCS} ${PROG}: ${XOBJS} ${XSRCS} ${DPSRCS} ${DPADD} ${_MKTARGET_LINK} +.if ${MKLDSCRIPT} == "yes" + $S/conf/mkldscript.sh ${KMODSCRIPTSRC} ${XOBJS} > ${KMODSCRIPT} +.endif ${CC} ${LDFLAGS} -nostdlib -MD -combine -r -Wl,-T,${KMODSCRIPT},-d \ -Wl,-Map=${.TARGET}.map \ -o ${.TARGET} ${CFLAGS} ${CPPFLAGS} ${XOBJS} \ @@ -151,6 +160,11 @@ ${PROG}: ${KMOD}_tmp.o ${KMOD}_tramp.o .else ${PROG}: ${OBJS} ${DPADD} ${_MKTARGET_LINK} +.if ${MKLDSCRIPT} == "yes" + @rm -f ${KMODSCRIPT} + @OBJDUMP=${OBJDUMP} $S/conf/mkldscript.sh ${KMODSCRIPTSRC} ${OBJS} \ + > ${KMODSCRIPT} +.endif ${CC} ${LDFLAGS} -nostdlib -r -Wl,-T,${KMODSCRIPT},-d \ -Wl,-Map=${.TARGET}.map \ -o ${.TARGET} ${OBJS} @@ -200,6 +214,9 @@ kmodinstall:: ${_PROG} # Clean rules CLEANFILES+= a.out [Ee]rrs mklog core *.core ${PROG} ${OBJS} ${LOBJS} CLEANFILES+= ${PROG}.map +.if ${MKLDSCRIPT} == "yes" +CLEANFILES+= kldscript +.endif # Custom rules lint: ${LOBJS}
CVS commit: src/sys/conf
Module Name:src Committed By: christos Date: Wed Nov 12 02:15:58 UTC 2014 Modified Files: src/sys/conf: mkldscript.sh Log Message: I don't know what was using this before (but it did not work since it did not produce valid LDSCRIPT code) and now it does. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/conf/mkldscript.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/conf/mkldscript.sh diff -u src/sys/conf/mkldscript.sh:1.1 src/sys/conf/mkldscript.sh:1.2 --- src/sys/conf/mkldscript.sh:1.1 Sat Mar 3 21:35:49 2007 +++ src/sys/conf/mkldscript.sh Tue Nov 11 21:15:58 2014 @@ -1,15 +1,21 @@ #!/bin/sh -# $NetBSD: mkldscript.sh,v 1.1 2007/03/04 02:35:49 tsutsui Exp $ +# $NetBSD: mkldscript.sh,v 1.2 2014/11/12 02:15:58 christos Exp $ -TEMPLATE=$1 +TEMPLATE="$1" shift -SETS=`$OBJDUMP -x $* | fgrep "RELOCATION RECORDS FOR [link_set" | \ -sort -u | sed 's/^.*\[\(.*\)\]:$/\1/'` +mksets() { +"${OBJDUMP:-objdump}" -x "$@" | fgrep "RELOCATION RECORDS FOR [link_set" | \ +sort -u | sed 's/^.*\[\(.*\)\]:$/\1/' +} +SETS=$(mksets "$@") + +grep -v '^}$' "$TEMPLATE" for s in $SETS; do -printf ". = ALIGN(4);\n" -printf "PROVIDE (__start_%s = .);\n" $s -printf "*(%s)\n" $s -printf "PROVIDE (__stop_%s = .);\n" $s -done +printf ' . = ALIGN(4);\n' +printf ' PROVIDE (__start_%s = .);\n' $s +printf ' %s : { *(%s) }\n' $s $s +printf ' PROVIDE (__stop_%s = .);\n' $s +done +printf '}\n'
CVS commit: src/sys/modules/i915drmkms
Module Name:src Committed By: christos Date: Wed Nov 12 02:15:16 UTC 2014 Modified Files: src/sys/modules/i915drmkms: Makefile Log Message: turn on dynamic ldscript creation to handle link set symbol definitions used in the automatic sysctl creation. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/modules/i915drmkms/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/modules/i915drmkms/Makefile diff -u src/sys/modules/i915drmkms/Makefile:1.5 src/sys/modules/i915drmkms/Makefile:1.6 --- src/sys/modules/i915drmkms/Makefile:1.5 Tue Nov 11 06:30:21 2014 +++ src/sys/modules/i915drmkms/Makefile Tue Nov 11 21:15:16 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.5 2014/11/11 11:30:21 nonaka Exp $ +# $NetBSD: Makefile,v 1.6 2014/11/12 02:15:16 christos Exp $ .include "../Makefile.inc" .include "../drmkms/Makefile.inc" @@ -11,6 +11,7 @@ CPPFLAGS+= -I${S}/external/bsd/drm2/i915 KMOD= i915drmkms IOCONF= i915drmkms.ioconf +MKLDSCRIPT=yes SRCS+= dvo_ch7017.c SRCS+= dvo_ch7xxx.c
CVS commit: src/sys/modules/drmkms_pci
Module Name:src Committed By: christos Date: Wed Nov 12 02:14:17 UTC 2014 Modified Files: src/sys/modules/drmkms_pci: Makefile Log Message: move agpsupport to drmkms to avoid circular dependencies. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/modules/drmkms_pci/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/modules/drmkms_pci/Makefile diff -u src/sys/modules/drmkms_pci/Makefile:1.2 src/sys/modules/drmkms_pci/Makefile:1.3 --- src/sys/modules/drmkms_pci/Makefile:1.2 Tue Mar 18 14:20:43 2014 +++ src/sys/modules/drmkms_pci/Makefile Tue Nov 11 21:14:17 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.2 2014/03/18 18:20:43 riastradh Exp $ +# $NetBSD: Makefile,v 1.3 2014/11/12 02:14:17 christos Exp $ .include "../Makefile.inc" .include "../drmkms/Makefile.inc" @@ -9,7 +9,7 @@ KMOD= drmkms_pci #SRCS+= ati_pcigart.c # XXX Restore for ATI support. -SRCS+= drm_agpsupport.c +#SRCS+= drm_agpsupport.c SRCS+= drm_pci.c SRCS+= drm_pci_module.c
CVS commit: src/sys/modules/drmkms
Module Name:src Committed By: christos Date: Wed Nov 12 02:13:30 UTC 2014 Modified Files: src/sys/modules/drmkms: Makefile Log Message: make this work: add agpsupport and sysctl code To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/modules/drmkms/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/modules/drmkms/Makefile diff -u src/sys/modules/drmkms/Makefile:1.4 src/sys/modules/drmkms/Makefile:1.5 --- src/sys/modules/drmkms/Makefile:1.4 Tue Nov 11 06:30:21 2014 +++ src/sys/modules/drmkms/Makefile Tue Nov 11 21:13:30 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.4 2014/11/11 11:30:21 nonaka Exp $ +# $NetBSD: Makefile,v 1.5 2014/11/12 02:13:30 christos Exp $ .include "../Makefile.inc" .include "Makefile.inc" @@ -11,7 +11,7 @@ KMOD= drmkms # Upstream source files. #SRCS+= ati_pcigart.c # Moved to drmkms_pci module. -#SRCS+= drm_agpsupport.c # Moved to drmkms_pci module. +SRCS+= drm_agpsupport.c # Moved to drmkms_pci module. SRCS+= drm_auth.c SRCS+= drm_buffer.c SRCS+= drm_bufs.c @@ -46,6 +46,7 @@ SRCS+= drm_probe_helper.c SRCS+= drm_rect.c SRCS+= drm_scatter.c SRCS+= drm_stub.c +SRCS+= drm_sysctl.c SRCS+= drm_sysfs.c SRCS+= drm_vm.c SRCS+= drm_vma_manager.c
CVS commit: src/sys/arch/macppc/dev
Module Name:src Committed By: macallan Date: Tue Nov 11 23:08:37 UTC 2014 Modified Files: src/sys/arch/macppc/dev: obio.c Log Message: appease gcc 4.8 To generate a diff of this commit: cvs rdiff -u -r1.40 -r1.41 src/sys/arch/macppc/dev/obio.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/arch/macppc/dev/obio.c diff -u src/sys/arch/macppc/dev/obio.c:1.40 src/sys/arch/macppc/dev/obio.c:1.41 --- src/sys/arch/macppc/dev/obio.c:1.40 Thu Apr 25 11:22:22 2013 +++ src/sys/arch/macppc/dev/obio.c Tue Nov 11 23:08:37 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: obio.c,v 1.40 2013/04/25 11:22:22 macallan Exp $ */ +/* $NetBSD: obio.c,v 1.41 2014/11/11 23:08:37 macallan Exp $ */ /*- * Copyright (C) 1998 Internet Research Institute, Inc. @@ -32,7 +32,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: obio.c,v 1.40 2013/04/25 11:22:22 macallan Exp $"); +__KERNEL_RCSID(0, "$NetBSD: obio.c,v 1.41 2014/11/11 23:08:37 macallan Exp $"); #include #include @@ -627,9 +627,7 @@ sysctl_cpuspeed_available(SYSCTLFN_ARGS) struct sysctlnode node = *rnode; struct obio_softc *sc = node.sysctl_data; char buf[128]; - int speed; - speed = obio_get_cpu_speed(sc); snprintf(buf, 128, "%d %d", sc->sc_spd_lo, sc->sc_spd_hi); node.sysctl_data = buf; return(sysctl_lookup(SYSCTLFN_CALL(&node)));
CVS commit: src/usr.sbin/postinstall
Module Name:src Committed By: martin Date: Tue Nov 11 19:41:39 UTC 2014 Modified Files: src/usr.sbin/postinstall: postinstall Log Message: Make check_ids take an additional argument (the corresponding source file) and grep that on error for the missing information, so the user gets all the info needed how to "FIX MANUALLY". To generate a diff of this commit: cvs rdiff -u -r1.180 -r1.181 src/usr.sbin/postinstall/postinstall Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/postinstall/postinstall diff -u src/usr.sbin/postinstall/postinstall:1.180 src/usr.sbin/postinstall/postinstall:1.181 --- src/usr.sbin/postinstall/postinstall:1.180 Thu Sep 11 13:10:04 2014 +++ src/usr.sbin/postinstall/postinstall Tue Nov 11 19:41:38 2014 @@ -1,6 +1,6 @@ #!/bin/sh # -# $NetBSD: postinstall,v 1.180 2014/09/11 13:10:04 roy Exp $ +# $NetBSD: postinstall,v 1.181 2014/11/11 19:41:38 martin Exp $ # # Copyright (c) 2002-2008 The NetBSD Foundation, Inc. # All rights reserved. @@ -229,12 +229,13 @@ check_dir() # check_ids() { - [ $# -ge 5 ] || err 3 "USAGE: checks_ids op type file start id [...]" + [ $# -ge 6 ] || err 3 "USAGE: checks_ids op type file start srcfile id [...]" _op="$1" _type="$2" _file="$3" _start="$4" - shift 4 + _srcfile="$5" + shift 5 #_ids="$@" if [ ! -f "${_file}" ]; then @@ -276,6 +277,14 @@ check_ids() ' "$@" < "${_file}")" || return 1 if [ -n "${_missing}" ]; then msg "Error ${_type}${_notfixed}:" $(echo ${_missing}) + msg "Use the following as a template:" + set -- ${_missing} + while [ $# -gt 0 ] + do + ${GREP} -E "^${1}:" ${_srcfile} + shift 2 + done + msg "and adjust if necessary." return 1 fi return 0 @@ -1019,6 +1028,7 @@ do_gid() [ -n "$1" ] || err 3 "USAGE: do_gid fix|check" check_ids "$1" groups "${DEST_DIR}/etc/group" 14 \ + "${SRC_DIR}/etc/group" \ named ntpd sshd SKIP _pflogd _rwhod staff _proxy _timedc \ _sdpd _httpd _mdnsd _tests _tcpdump _tss _gpio _rtadvd } @@ -1697,6 +1707,7 @@ do_uid() [ -n "$1" ] || err 3 "USAGE: do_uid fix|check" check_ids "$1" users "${DEST_DIR}/etc/master.passwd" 12 \ + "${SRC_DIR}/etc/master.passwd" \ postfix SKIP named ntpd sshd SKIP _pflogd _rwhod SKIP _proxy \ _timedc _sdpd _httpd _mdnsd _tests _tcpdump _tss SKIP _rtadvd }
CVS commit: src/sys/arch/arm/allwinner
Module Name:src Committed By: jmcneill Date: Tue Nov 11 19:22:32 UTC 2014 Modified Files: src/sys/arch/arm/allwinner: awin_debe.c awin_hdmi.c awin_tcon.c files.awin Log Message: defflag AWIN_HDMI_DEBUG, AWIN_TCON_DEBUG, AWIN_DEBE_DEBUG, and defparam AWIN_DEBE_VIDEOMEM To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/allwinner/awin_debe.c \ src/sys/arch/arm/allwinner/awin_tcon.c cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/allwinner/awin_hdmi.c cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/allwinner/files.awin Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/allwinner/awin_debe.c diff -u src/sys/arch/arm/allwinner/awin_debe.c:1.3 src/sys/arch/arm/allwinner/awin_debe.c:1.4 --- src/sys/arch/arm/allwinner/awin_debe.c:1.3 Mon Nov 10 17:55:25 2014 +++ src/sys/arch/arm/allwinner/awin_debe.c Tue Nov 11 19:22:32 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: awin_debe.c,v 1.3 2014/11/10 17:55:25 jmcneill Exp $ */ +/* $NetBSD: awin_debe.c,v 1.4 2014/11/11 19:22:32 jmcneill Exp $ */ /*- * Copyright (c) 2014 Jared D. McNeill @@ -26,14 +26,15 @@ * SUCH DAMAGE. */ +#include "opt_allwinner.h" +#include "genfb.h" + #ifndef AWIN_DEBE_VIDEOMEM #define AWIN_DEBE_VIDEOMEM (16 * 1024 * 1024) #endif -#include "genfb.h" - #include -__KERNEL_RCSID(0, "$NetBSD: awin_debe.c,v 1.3 2014/11/10 17:55:25 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: awin_debe.c,v 1.4 2014/11/11 19:22:32 jmcneill Exp $"); #include #include Index: src/sys/arch/arm/allwinner/awin_tcon.c diff -u src/sys/arch/arm/allwinner/awin_tcon.c:1.3 src/sys/arch/arm/allwinner/awin_tcon.c:1.4 --- src/sys/arch/arm/allwinner/awin_tcon.c:1.3 Mon Nov 10 17:55:25 2014 +++ src/sys/arch/arm/allwinner/awin_tcon.c Tue Nov 11 19:22:32 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: awin_tcon.c,v 1.3 2014/11/10 17:55:25 jmcneill Exp $ */ +/* $NetBSD: awin_tcon.c,v 1.4 2014/11/11 19:22:32 jmcneill Exp $ */ /*- * Copyright (c) 2014 Jared D. McNeill @@ -26,10 +26,10 @@ * SUCH DAMAGE. */ -//#define AWIN_TCON_DEBUG +#include "opt_allwinner.h" #include -__KERNEL_RCSID(0, "$NetBSD: awin_tcon.c,v 1.3 2014/11/10 17:55:25 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: awin_tcon.c,v 1.4 2014/11/11 19:22:32 jmcneill Exp $"); #include #include Index: src/sys/arch/arm/allwinner/awin_hdmi.c diff -u src/sys/arch/arm/allwinner/awin_hdmi.c:1.8 src/sys/arch/arm/allwinner/awin_hdmi.c:1.9 --- src/sys/arch/arm/allwinner/awin_hdmi.c:1.8 Tue Nov 11 17:27:12 2014 +++ src/sys/arch/arm/allwinner/awin_hdmi.c Tue Nov 11 19:22:32 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: awin_hdmi.c,v 1.8 2014/11/11 17:27:12 jmcneill Exp $ */ +/* $NetBSD: awin_hdmi.c,v 1.9 2014/11/11 19:22:32 jmcneill Exp $ */ /*- * Copyright (c) 2014 Jared D. McNeill @@ -26,14 +26,13 @@ * SUCH DAMAGE. */ -//#define AWIN_HDMI_DEBUG - +#include "opt_allwinner.h" #include "opt_ddb.h" #define AWIN_HDMI_PLL 3 /* PLL7 or PLL3 */ #include -__KERNEL_RCSID(0, "$NetBSD: awin_hdmi.c,v 1.8 2014/11/11 17:27:12 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: awin_hdmi.c,v 1.9 2014/11/11 19:22:32 jmcneill Exp $"); #include #include Index: src/sys/arch/arm/allwinner/files.awin diff -u src/sys/arch/arm/allwinner/files.awin:1.24 src/sys/arch/arm/allwinner/files.awin:1.25 --- src/sys/arch/arm/allwinner/files.awin:1.24 Tue Nov 11 17:00:59 2014 +++ src/sys/arch/arm/allwinner/files.awin Tue Nov 11 19:22:32 2014 @@ -1,4 +1,4 @@ -# $NetBSD: files.awin,v 1.24 2014/11/11 17:00:59 jmcneill Exp $ +# $NetBSD: files.awin,v 1.25 2014/11/11 19:22:32 jmcneill Exp $ # # Configuration info for Allwinner ARM Peripherals # @@ -28,6 +28,10 @@ defflag opt_allwinner.hALLWINNER_A20 defflag opt_allwinner.hALLWINNER_A31 defflag opt_allwinner.hALLWINNER_A80 defflag opt_allwinner.hAWIN_GPIO_IGNORE_FW +defflag opt_allwinner.hAWIN_HDMI_DEBUG +defflag opt_allwinner.hAWIN_TCON_DEBUG +defflag opt_allwinner.hAWIN_DEBE_DEBUG +defparam opt_allwinner.h AWIN_DEBE_VIDEOMEM # SoC I/O attach point device awinio { [port=-1] } : bus_space_generic
CVS commit: src/lib/libc/time
Module Name:src Committed By: christos Date: Tue Nov 11 18:46:54 UTC 2014 Modified Files: src/lib/libc/time: localtime.c Log Message: localtime did not set tm->tm_zone properly making pkgsrc emacs core-dump. Thanks to Masanori Kanaoka. To generate a diff of this commit: cvs rdiff -u -r1.91 -r1.92 src/lib/libc/time/localtime.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libc/time/localtime.c diff -u src/lib/libc/time/localtime.c:1.91 src/lib/libc/time/localtime.c:1.92 --- src/lib/libc/time/localtime.c:1.91 Thu Oct 23 14:45:58 2014 +++ src/lib/libc/time/localtime.c Tue Nov 11 13:46:54 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: localtime.c,v 1.91 2014/10/23 18:45:58 christos Exp $ */ +/* $NetBSD: localtime.c,v 1.92 2014/11/11 18:46:54 christos Exp $ */ /* ** This file is in the public domain, so clarified as of @@ -10,7 +10,7 @@ #if 0 static char elsieid[] = "@(#)localtime.c 8.17"; #else -__RCSID("$NetBSD: localtime.c,v 1.91 2014/10/23 18:45:58 christos Exp $"); +__RCSID("$NetBSD: localtime.c,v 1.92 2014/11/11 18:46:54 christos Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -290,6 +290,27 @@ settzname_z(timezone_t sp) } } +static char * +setzone(const struct state *sp, const struct ttinfo *ttisp, int_fast32_t offset) +{ + char *zn = __UNCONST(&sp->chars[ttisp->tt_abbrind]); + if (offset) { +#ifdef USG_COMPAT + if (ttisp->tt_isdst) + daylight = 1; + if (!ttisp->tt_isdst) + timezone = -(ttisp->tt_gmtoff); +#endif /* defined USG_COMPAT */ +#ifdef ALTZONE + if (ttisp->tt_isdst) + altzone = -(ttisp->tt_gmtoff); +#endif /* defined ALTZONE */ + } + + tzname[ttisp->tt_isdst] = zn; + return zn; +} + static void settzname(void) { @@ -312,21 +333,9 @@ settzname(void) /* ** And to get the latest zone names into tzname. . . */ - for (i = 0; i < sp->typecnt; ++i) { - const struct ttinfo * const ttisp = &sp->ttis[i]; + for (i = 0; i < sp->typecnt; ++i) + setzone(sp, &sp->ttis[i], -1); - tzname[ttisp->tt_isdst] = &sp->chars[ttisp->tt_abbrind]; -#ifdef USG_COMPAT - if (ttisp->tt_isdst) - daylight = 1; - if (!ttisp->tt_isdst) - timezone = -(ttisp->tt_gmtoff); -#endif /* defined USG_COMPAT */ -#ifdef ALTZONE - if (ttisp->tt_isdst) - altzone = -(ttisp->tt_gmtoff); -#endif /* defined ALTZONE */ - } settzname_z(sp); } @@ -1428,23 +1437,11 @@ localsub(struct state const *sp, time_t */ result = timesub(&t, ttisp->tt_gmtoff, sp, tmp); if (result) { - bool tm_isdst = ttisp->tt_isdst; - char *tm_zone = __UNCONST(&sp->chars[ttisp->tt_abbrind]); - result->tm_isdst = tm_isdst; - if (offset) { - /* Always set the tzname etc. vars whose values can easily - be determined, as it's too much trouble to tell whether - tzset has already done it correctly. */ - tzname[tm_isdst] = tm_zone; -#ifdef USG_COMPAT - if (!tm_isdst) -timezone = - ttisp->tt_gmtoff; -#endif -#ifdef ALTZONE - if (tm_isdst) -altzone = - ttisp->tt_gmtoff; -#endif - } + char *zn = setzone(sp, ttisp, offset); + result->tm_isdst = ttisp->tt_isdst; +#ifdef TM_ZONE + result->TM_ZONE = zn; +#endif /* defined TM_ZONE */ } return result; }
CVS commit: src/sys/arch/arm/allwinner
Module Name:src Committed By: jmcneill Date: Tue Nov 11 17:27:12 UTC 2014 Modified Files: src/sys/arch/arm/allwinner: awin_hdmi.c Log Message: only dump regs when enabling audio if AWIN_HDMI_DEBUG To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/sys/arch/arm/allwinner/awin_hdmi.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/arch/arm/allwinner/awin_hdmi.c diff -u src/sys/arch/arm/allwinner/awin_hdmi.c:1.7 src/sys/arch/arm/allwinner/awin_hdmi.c:1.8 --- src/sys/arch/arm/allwinner/awin_hdmi.c:1.7 Tue Nov 11 17:00:59 2014 +++ src/sys/arch/arm/allwinner/awin_hdmi.c Tue Nov 11 17:27:12 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: awin_hdmi.c,v 1.7 2014/11/11 17:00:59 jmcneill Exp $ */ +/* $NetBSD: awin_hdmi.c,v 1.8 2014/11/11 17:27:12 jmcneill Exp $ */ /*- * Copyright (c) 2014 Jared D. McNeill @@ -33,7 +33,7 @@ #define AWIN_HDMI_PLL 3 /* PLL7 or PLL3 */ #include -__KERNEL_RCSID(0, "$NetBSD: awin_hdmi.c,v 1.7 2014/11/11 17:00:59 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: awin_hdmi.c,v 1.8 2014/11/11 17:27:12 jmcneill Exp $"); #include #include @@ -727,7 +727,7 @@ awin_hdmi_set_audiomode(struct awin_hdmi val |= AWIN_HDMI_AUD_CTRL_EN; HDMI_WRITE(sc, AWIN_HDMI_AUD_CTRL_REG, val); -#if defined(DDB) +#if defined(AWIN_HDMI_DEBUG) && defined(DDB) awin_hdmi_dump_regs(); #endif }
CVS commit: src/doc
Module Name:src Committed By: jmcneill Date: Tue Nov 11 17:20:43 UTC 2014 Modified Files: src/doc: CHANGES Log Message: awinhdmiaudio(4): Add support for Allwinner A20/A31 HDMI audio controller. To generate a diff of this commit: cvs rdiff -u -r1.2015 -r1.2016 src/doc/CHANGES Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES diff -u src/doc/CHANGES:1.2015 src/doc/CHANGES:1.2016 --- src/doc/CHANGES:1.2015 Mon Nov 10 18:38:16 2014 +++ src/doc/CHANGES Tue Nov 11 17:20:43 2014 @@ -1,4 +1,4 @@ -# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.2015 $> +# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.2016 $> # # # [Note: This file does not mention every change made to the NetBSD source tree. @@ -99,3 +99,5 @@ Changes from NetBSD 7.0 to NetBSD 8.0: [jmcneill 20141110] awindebe(4): Add support for Allwinner A20/A31 Display engine backend (DE-BE). [jmcneill 20141110] + awinhdmiaudio(4): Add support for Allwinner A20/A31 HDMI audio + controller. [jmcneill 2014]
CVS commit: src/sys/arch/arm/allwinner
Module Name:src Committed By: jmcneill Date: Tue Nov 11 17:14:38 UTC 2014 Modified Files: src/sys/arch/arm/allwinner: awin_hdmiaudio.c Log Message: AWIN_HDMI_ADMA_CTRL_FIFO_CLEAR causes playback to stop working, dont set it To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/allwinner/awin_hdmiaudio.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/arch/arm/allwinner/awin_hdmiaudio.c diff -u src/sys/arch/arm/allwinner/awin_hdmiaudio.c:1.1 src/sys/arch/arm/allwinner/awin_hdmiaudio.c:1.2 --- src/sys/arch/arm/allwinner/awin_hdmiaudio.c:1.1 Tue Nov 11 17:00:59 2014 +++ src/sys/arch/arm/allwinner/awin_hdmiaudio.c Tue Nov 11 17:14:38 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: awin_hdmiaudio.c,v 1.1 2014/11/11 17:00:59 jmcneill Exp $ */ +/* $NetBSD: awin_hdmiaudio.c,v 1.2 2014/11/11 17:14:38 jmcneill Exp $ */ /*- * Copyright (c) 2014 Jared D. McNeill @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: awin_hdmiaudio.c,v 1.1 2014/11/11 17:00:59 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: awin_hdmiaudio.c,v 1.2 2014/11/11 17:14:38 jmcneill Exp $"); #include #include @@ -361,13 +361,6 @@ awin_hdmiaudio_close(void *priv) static int awin_hdmiaudio_drain(void *priv) { - struct awin_hdmiaudio_softc *sc = priv; - uint32_t val; - - val = HDMIAUDIO_READ(sc, AWIN_HDMI_ADMA_CTRL_REG); - val |= AWIN_HDMI_ADMA_CTRL_FIFO_CLEAR; - HDMIAUDIO_WRITE(sc, AWIN_HDMI_ADMA_CTRL_REG, val); - return 0; }
CVS commit: src/sys/arch/arm/allwinner
Module Name:src Committed By: jmcneill Date: Tue Nov 11 17:00:59 UTC 2014 Modified Files: src/sys/arch/arm/allwinner: awin_hdmi.c awin_io.c awin_reg.h files.awin Added Files: src/sys/arch/arm/allwinner: awin_hdmiaudio.c Log Message: add HDMI audio driver To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/allwinner/awin_hdmi.c cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/allwinner/awin_hdmiaudio.c cvs rdiff -u -r1.27 -r1.28 src/sys/arch/arm/allwinner/awin_io.c cvs rdiff -u -r1.47 -r1.48 src/sys/arch/arm/allwinner/awin_reg.h cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/allwinner/files.awin Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/allwinner/awin_hdmi.c diff -u src/sys/arch/arm/allwinner/awin_hdmi.c:1.6 src/sys/arch/arm/allwinner/awin_hdmi.c:1.7 --- src/sys/arch/arm/allwinner/awin_hdmi.c:1.6 Mon Nov 10 18:18:09 2014 +++ src/sys/arch/arm/allwinner/awin_hdmi.c Tue Nov 11 17:00:59 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: awin_hdmi.c,v 1.6 2014/11/10 18:18:09 jmcneill Exp $ */ +/* $NetBSD: awin_hdmi.c,v 1.7 2014/11/11 17:00:59 jmcneill Exp $ */ /*- * Copyright (c) 2014 Jared D. McNeill @@ -33,7 +33,7 @@ #define AWIN_HDMI_PLL 3 /* PLL7 or PLL3 */ #include -__KERNEL_RCSID(0, "$NetBSD: awin_hdmi.c,v 1.6 2014/11/10 18:18:09 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: awin_hdmi.c,v 1.7 2014/11/11 17:00:59 jmcneill Exp $"); #include #include @@ -102,6 +102,7 @@ static void awin_hdmi_thread(void *); #if 0 static int awin_hdmi_intr(void *); #endif + #if defined(DDB) void awin_hdmi_dump_regs(void); #endif @@ -533,7 +534,8 @@ awin_hdmi_video_enable(struct awin_hdmi_ } static void -awin_hdmi_set_videomode(struct awin_hdmi_softc *sc, const struct videomode *mode) +awin_hdmi_set_videomode(struct awin_hdmi_softc *sc, +const struct videomode *mode) { uint32_t val; const u_int dblscan_p = !!(mode->flags & VID_DBLSCAN); @@ -598,6 +600,8 @@ awin_hdmi_set_videomode(struct awin_hdmi #endif val = HDMI_READ(sc, AWIN_HDMI_VID_CTRL_REG); + val |= __SHIFTIN(AWIN_HDMI_VID_CTRL_HDMI_MODE_HDMI, + AWIN_HDMI_VID_CTRL_HDMI_MODE); if (dblscan_p) { val |= __SHIFTIN(AWIN_HDMI_VID_CTRL_REPEATER_SEL_2X, AWIN_HDMI_VID_CTRL_REPEATER_SEL); @@ -651,13 +655,81 @@ awin_hdmi_set_videomode(struct awin_hdmi val |= __SHIFTIN(AWIN_HDMI_VID_TIMING_4_TX_CLOCK_NORMAL, AWIN_HDMI_VID_TIMING_4_TX_CLOCK); HDMI_WRITE(sc, AWIN_HDMI_VID_TIMING_4_REG, val); + + /* Packet control */ + HDMI_WRITE(sc, AWIN_HDMI_PKT_CTRL0_REG, 0x5321); + HDMI_WRITE(sc, AWIN_HDMI_PKT_CTRL1_REG, 0x000f); } static void -awin_hdmi_set_audiomode(struct awin_hdmi_softc *sc, const struct videomode *mode) +awin_hdmi_set_audiomode(struct awin_hdmi_softc *sc, +const struct videomode *mode) { - /* TODO */ - HDMI_WRITE(sc, AWIN_HDMI_AUD_CTRL_REG, 0); + uint32_t cts, n, val; + + /* + * Before changing audio parameters, disable and reset the + * audio module. Wait for the soft reset bit to clear before + * configuring the audio parameters. + */ + val = HDMI_READ(sc, AWIN_HDMI_AUD_CTRL_REG); + val &= ~AWIN_HDMI_AUD_CTRL_EN; + val |= AWIN_HDMI_AUD_CTRL_RST; + HDMI_WRITE(sc, AWIN_HDMI_AUD_CTRL_REG, val); + do { + val = HDMI_READ(sc, AWIN_HDMI_AUD_CTRL_REG); + } while (val & AWIN_HDMI_AUD_CTRL_RST); + + /* DMA & FIFO control */ + val = HDMI_READ(sc, AWIN_HDMI_ADMA_CTRL_REG); + val |= AWIN_HDMI_ADMA_CTRL_SRC_DMA_MODE; /* NDMA */ + val &= ~AWIN_HDMI_ADMA_CTRL_SRC_DMA_SAMPLE_RATE; + val &= ~AWIN_HDMI_ADMA_CTRL_SRC_SAMPLE_LAYOUT; + val &= ~AWIN_HDMI_ADMA_CTRL_SRC_WORD_LEN; + val &= ~AWIN_HDMI_ADMA_CTRL_DATA_SEL; + HDMI_WRITE(sc, AWIN_HDMI_ADMA_CTRL_REG, val); + + /* Audio format control */ + val = HDMI_READ(sc, AWIN_HDMI_AUD_FMT_REG); + val &= ~AWIN_HDMI_AUD_FMT_SRC_SEL; + val &= ~AWIN_HDMI_AUD_FMT_SEL; + val &= ~AWIN_HDMI_AUD_FMT_DSD_FMT; + val &= ~AWIN_HDMI_AUD_FMT_LAYOUT; + val &= ~AWIN_HDMI_AUD_FMT_SRC_CH_CFG; + val |= __SHIFTIN(1, AWIN_HDMI_AUD_FMT_SRC_CH_CFG); + HDMI_WRITE(sc, AWIN_HDMI_AUD_FMT_REG, val); + + /* PCM control (channel map) */ + HDMI_WRITE(sc, AWIN_HDMI_AUD_PCM_CTRL_REG, 0x76543210); + + /* Clock setup */ + n = 6144; /* 48 kHz */ + cts = ((mode->dot_clock * 10) * (n / 128)) / 480; + HDMI_WRITE(sc, AWIN_HDMI_AUD_CTS_REG, cts); + HDMI_WRITE(sc, AWIN_HDMI_AUD_N_REG, n); + + /* Audio PCM channel status 0 */ + val = __SHIFTIN(AWIN_HDMI_AUD_CH_STATUS0_FS_FREQ_48, + AWIN_HDMI_AUD_CH_STATUS0_FS_FREQ); + HDMI_WRITE(sc, AWIN_HDMI_AUD_CH_STATUS0_REG, val); + + /* Audio PCM channel status 1 */ + val = HDMI_READ(sc, AWIN_HDMI_AUD_CH_STATUS1_REG); + val &= ~AWIN_HDMI_AUD_CH_STATUS1_CGMS_A; + val &= ~AWIN_HDMI_AUD_CH_STATUS1_ORIGINAL_FS; + val &= ~AWIN_HDMI_AUD_CH_STATUS1_WORD_LEN; + val |= __SHIFTIN(5, AWIN_HDMI_AUD_CH_STATUS1_WORD_LEN); + val |= AWIN_HDMI_AUD_CH_STATUS1_WORD_LEN_MAX; + HDMI_WRITE(sc, AWIN_HDMI_AUD_CH_STATUS1_REG, val); + + /* Re-enable */ +
CVS commit: src/sys/arch/evbarm/conf
Module Name:src Committed By: jmcneill Date: Tue Nov 11 17:01:27 UTC 2014 Modified Files: src/sys/arch/evbarm/conf: HUMMINGBIRD_A31 Log Message: enable awinhdmiaudio To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/arch/evbarm/conf/HUMMINGBIRD_A31 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/evbarm/conf/HUMMINGBIRD_A31 diff -u src/sys/arch/evbarm/conf/HUMMINGBIRD_A31:1.18 src/sys/arch/evbarm/conf/HUMMINGBIRD_A31:1.19 --- src/sys/arch/evbarm/conf/HUMMINGBIRD_A31:1.18 Mon Nov 10 17:56:22 2014 +++ src/sys/arch/evbarm/conf/HUMMINGBIRD_A31 Tue Nov 11 17:01:27 2014 @@ -1,4 +1,4 @@ -# $NetBSD: HUMMINGBIRD_A31,v 1.18 2014/11/10 17:56:22 jmcneill Exp $ +# $NetBSD: HUMMINGBIRD_A31,v 1.19 2014/11/11 17:01:27 jmcneill Exp $ # # HUMMINGBIRD_A31 - Merrii Hummingbird A31 # @@ -239,6 +239,8 @@ awge0 at awinio0 port ? # HDMI awinhdmi0 at awinio0 +awinhdmiaudio0 at awinio0 +audio1 at awinhdmiaudio0 # TCON awintcon0 at awinio0 port 0
CVS commit: src/sys/arch/evbarm/conf
Module Name:src Committed By: skrll Date: Tue Nov 11 15:12:52 UTC 2014 Modified Files: src/sys/arch/evbarm/conf: CUBIEBOARD Log Message: One awincnt0 is enough To generate a diff of this commit: cvs rdiff -u -r1.32 -r1.33 src/sys/arch/evbarm/conf/CUBIEBOARD Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/evbarm/conf/CUBIEBOARD diff -u src/sys/arch/evbarm/conf/CUBIEBOARD:1.32 src/sys/arch/evbarm/conf/CUBIEBOARD:1.33 --- src/sys/arch/evbarm/conf/CUBIEBOARD:1.32 Mon Nov 10 17:56:58 2014 +++ src/sys/arch/evbarm/conf/CUBIEBOARD Tue Nov 11 15:12:51 2014 @@ -1,5 +1,5 @@ # -# $NetBSD: CUBIEBOARD,v 1.32 2014/11/10 17:56:58 jmcneill Exp $ +# $NetBSD: CUBIEBOARD,v 1.33 2014/11/11 15:12:51 skrll Exp $ # # CUBIEBOARD -- Allwinner A10/A20 Eval Board Kernel # @@ -245,9 +245,6 @@ awinwdt* at awinio? # RTC awinrtc* at awinio? -# 64-bit counter -awincnt0 at awinio0 - # onboard audio codec awinac0 at awinio0 audio0 at awinac0
CVS commit: [netbsd-7] src/doc
Module Name:src Committed By: martin Date: Tue Nov 11 12:53:54 UTC 2014 Modified Files: src/doc [netbsd-7]: CHANGES-7.0 Log Message: Tickets #211 and #212 To generate a diff of this commit: cvs rdiff -u -r1.1.2.87 -r1.1.2.88 src/doc/CHANGES-7.0 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES-7.0 diff -u src/doc/CHANGES-7.0:1.1.2.87 src/doc/CHANGES-7.0:1.1.2.88 --- src/doc/CHANGES-7.0:1.1.2.87 Tue Nov 11 12:28:28 2014 +++ src/doc/CHANGES-7.0 Tue Nov 11 12:53:54 2014 @@ -1,4 +1,4 @@ -# $NetBSD: CHANGES-7.0,v 1.1.2.87 2014/11/11 12:28:28 martin Exp $ +# $NetBSD: CHANGES-7.0,v 1.1.2.88 2014/11/11 12:53:54 martin Exp $ A complete list of changes from the initial NetBSD 7.0 branch on 11 Aug 2014 until the 7.0 release: @@ -2316,3 +2316,14 @@ sys/net/if.c 1.292 parallel causes panic. [ozaki-r, ticket #205] +sys/arch/evbarm/awin/awin_machdep.c 1.27 + + get_bootconf_option doesnt return the value null-terminated, so + look for an awge0.mac-address value of exactly the correct length. + [jmcneill, ticket #211] + +sys/dev/wscons/wsdisplay_vcons.c 1.33 + + Allocate char and attr buffers with M_ZERO. + [jmcneill, ticket #212] +
CVS commit: [netbsd-7] src/sys/dev/wscons
Module Name:src Committed By: martin Date: Tue Nov 11 12:50:48 UTC 2014 Modified Files: src/sys/dev/wscons [netbsd-7]: wsdisplay_vcons.c Log Message: Pull up following revision(s) (requested by jmcneill in ticket #212): sys/dev/wscons/wsdisplay_vcons.c: revision 1.33 allocate char and attr buffers with M_ZERO To generate a diff of this commit: cvs rdiff -u -r1.32 -r1.32.4.1 src/sys/dev/wscons/wsdisplay_vcons.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/wscons/wsdisplay_vcons.c diff -u src/sys/dev/wscons/wsdisplay_vcons.c:1.32 src/sys/dev/wscons/wsdisplay_vcons.c:1.32.4.1 --- src/sys/dev/wscons/wsdisplay_vcons.c:1.32 Tue Mar 18 18:20:42 2014 +++ src/sys/dev/wscons/wsdisplay_vcons.c Tue Nov 11 12:50:48 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: wsdisplay_vcons.c,v 1.32 2014/03/18 18:20:42 riastradh Exp $ */ +/* $NetBSD: wsdisplay_vcons.c,v 1.32.4.1 2014/11/11 12:50:48 martin Exp $ */ /*- * Copyright (c) 2005, 2006 Michael Lorenz @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: wsdisplay_vcons.c,v 1.32 2014/03/18 18:20:42 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: wsdisplay_vcons.c,v 1.32.4.1 2014/11/11 12:50:48 martin Exp $"); #include #include @@ -314,8 +314,10 @@ vcons_init_screen(struct vcons_data *vd, if (vd->chars != NULL) free(vd->chars, M_DEVBUF); if (vd->attrs != NULL) free(vd->attrs, M_DEVBUF); vd->cells = size; - vd->chars = malloc(size * sizeof(uint32_t), M_DEVBUF, M_WAITOK); - vd->attrs = malloc(size * sizeof(long), M_DEVBUF, M_WAITOK); + vd->chars = malloc(size * sizeof(uint32_t), M_DEVBUF, + M_WAITOK|M_ZERO); + vd->attrs = malloc(size * sizeof(long), M_DEVBUF, + M_WAITOK|M_ZERO); vcons_invalidate_cache(vd); } #endif
CVS commit: [netbsd-7] src/sys/arch/evbarm/awin
Module Name:src Committed By: martin Date: Tue Nov 11 12:48:59 UTC 2014 Modified Files: src/sys/arch/evbarm/awin [netbsd-7]: awin_machdep.c Log Message: Pull up following revision(s) (requested by jmcneill in ticket #211): sys/arch/evbarm/awin/awin_machdep.c: revision 1.27 get_bootconf_option doesnt return the value null-terminated, so look for an awge0.mac-address value of exactly the correct length To generate a diff of this commit: cvs rdiff -u -r1.8.2.4 -r1.8.2.5 src/sys/arch/evbarm/awin/awin_machdep.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/arch/evbarm/awin/awin_machdep.c diff -u src/sys/arch/evbarm/awin/awin_machdep.c:1.8.2.4 src/sys/arch/evbarm/awin/awin_machdep.c:1.8.2.5 --- src/sys/arch/evbarm/awin/awin_machdep.c:1.8.2.4 Sun Nov 9 14:42:33 2014 +++ src/sys/arch/evbarm/awin/awin_machdep.c Tue Nov 11 12:48:59 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: awin_machdep.c,v 1.8.2.4 2014/11/09 14:42:33 martin Exp $ */ +/* $NetBSD: awin_machdep.c,v 1.8.2.5 2014/11/11 12:48:59 martin Exp $ */ /* * Machine dependent functions for kernel setup for TI OSK5912 board. @@ -125,7 +125,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: awin_machdep.c,v 1.8.2.4 2014/11/09 14:42:33 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: awin_machdep.c,v 1.8.2.5 2014/11/11 12:48:59 martin Exp $"); #include "opt_machdep.h" #include "opt_ddb.h" @@ -724,14 +724,18 @@ awin_device_register(device_t self, void char *mac_addr; snprintf(argname, sizeof(argname), "%s.mac-address", device_xname(self)); + if (get_bootconf_option(boot_args, argname, - BOOTOPT_TYPE_STRING, &mac_addr) && - ether_aton_r(enaddr, sizeof(enaddr), mac_addr) == 0) { - prop_data_t pd; - pd = prop_data_create_data(enaddr, sizeof(enaddr)); - KASSERT(pd != NULL); - prop_dictionary_set(dict, "mac-address", pd); - prop_object_release(pd); + BOOTOPT_TYPE_STRING, &mac_addr)) { + char mac[strlen("XX:XX:XX:XX:XX:XX") + 1]; + strlcpy(mac, mac_addr, sizeof(mac)); + if (!ether_aton_r(enaddr, sizeof(enaddr), mac)) { +prop_data_t pd; +pd = prop_data_create_data(enaddr, sizeof(enaddr)); +KASSERT(pd != NULL); +prop_dictionary_set(dict, "mac-address", pd); +prop_object_release(pd); + } } #if AWIN_board == AWIN_cubieboard
CVS commit: [netbsd-7] src/doc
Module Name:src Committed By: martin Date: Tue Nov 11 12:28:28 UTC 2014 Modified Files: src/doc [netbsd-7]: CHANGES-7.0 Log Message: Tickets #197 - #202, #205 To generate a diff of this commit: cvs rdiff -u -r1.1.2.86 -r1.1.2.87 src/doc/CHANGES-7.0 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES-7.0 diff -u src/doc/CHANGES-7.0:1.1.2.86 src/doc/CHANGES-7.0:1.1.2.87 --- src/doc/CHANGES-7.0:1.1.2.86 Mon Nov 10 19:59:24 2014 +++ src/doc/CHANGES-7.0 Tue Nov 11 12:28:28 2014 @@ -1,4 +1,4 @@ -# $NetBSD: CHANGES-7.0,v 1.1.2.86 2014/11/10 19:59:24 martin Exp $ +# $NetBSD: CHANGES-7.0,v 1.1.2.87 2014/11/11 12:28:28 martin Exp $ A complete list of changes from the initial NetBSD 7.0 branch on 11 Aug 2014 until the 7.0 release: @@ -2241,3 +2241,78 @@ sys/arch/arm/pic/pic.c1.25 Various ARM pmap/bus_dma fixes. [skrll, ticket #209] +sys/external/bsd/drm2/dist/drm/i915/i915_dma.c 1.12 +sys/external/bsd/drm2/dist/drm/i915/i915_drv.h 1.10 +sys/external/bsd/drm2/dist/drm/i915/intel_acpi.c 1.3-1.5 +sys/external/bsd/drm2/dist/drm/i915/intel_opregion.c 1.6-1.7 +sys/external/bsd/drm2/i915drm/files.i915drmkms 1.8 +sys/external/bsd/drm2/include/linux/acpi.h 1.3 +sys/external/bsd/drm2/include/linux/pci.h 1.10 + + i915drmkms(4): Enable CONFIG_ACPI if NACPICA > 0. + Now brightness can be adjusted via hotkey on Mouse Computer LB-J300X + (Clevo W330SU2). + + Fix debug build. + + pci_attach_args of pci_find_device and match function is not the + same thing - fix PR/49372. + [nonaka, ticket #197] + +sys/external/bsd/drm2/include/linux/sched.h 1.5 + + Return the correct remaining jiffies, fixes a X server hang when + screen blanking by DPMS. + [nonaka, ticket #198] + +sbin/fsck/fsck.c1.52 +sbin/newfs/newfs.c1.112 + + Add/fix named wedges support for fsck/newfs. + [mlelstv, ticket #199] + +sys/dev/dkwedge/dkwedge_bsdlabel.c 1.23 +sys/dev/dkwedge/dkwedge_gpt.c 1.14 +sys/dev/dkwedge/dkwedge_mbr.c 1.8 + + Handle disks with non DEV_BSIZE sectors. + Be less noisy when handling wedge name conflicts. + [mlelstv, ticket #200] + +sbin/dkctl/dkctl.81.24-1.25 +sbin/dkctl/dkctl.c1.21 +sys/dev/ata/wd.c1.415 +sys/dev/dksubr.c1.54 +sys/dev/dkwedge/dk.c1.74 +sys/dev/ld.c 1.78 +sys/dev/raidframe/rf_netbsdkintf.c 1.315 +sys/dev/scsipi/sd.c1.310 +sys/dev/vnd.c 1.234 +sys/sys/dkio.h 1.20 + + Implement DIOCMWEDGES ioctl that triggers wedge autodiscovery. + Also fix a reference counting bug and clean up some code. + + Add 'makewedges' option to dkctl(8) to autodiscover wedges from a + changed label. + [mlelstv, ticket #201] + +sys/dev/ccd.c 1.153-1.154 +sys/dev/dksubr.c1.52-1.53 +sys/dev/ld.c 1.77 +sys/dev/raidframe/rf_netbsdkintf.c 1.313-1.314 +sys/dev/vnd.c 1.233 + + Clamp total number of sectors to UINT32_MAX instead of providing the + lower 32bit of the 64bit number. + + No longer warn about differences bewteen disk size and total sector + count in disklabel when the latter is just clamped to the maximum. + [mlelstv, ticket #202] + +sys/net/if.c 1.292 + + PR/49373: Ryota Ozaki: Running if_clone_create and if_clone_destroy in + parallel causes panic. + [ozaki-r, ticket #205] +
CVS commit: [netbsd-7] src/sys/net
Module Name:src Committed By: martin Date: Tue Nov 11 12:20:28 UTC 2014 Modified Files: src/sys/net [netbsd-7]: if.c Log Message: Pull up following revision(s) (requested by ozaki-r in ticket #205): sys/net/if.c: revision 1.292 PR/49373: Ryota Ozaki: Running if_clone_create and if_clone_destroy in parallel causes panic XXX: Pullup 7. To generate a diff of this commit: cvs rdiff -u -r1.290 -r1.290.2.1 src/sys/net/if.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/net/if.c diff -u src/sys/net/if.c:1.290 src/sys/net/if.c:1.290.2.1 --- src/sys/net/if.c:1.290 Sat Aug 9 05:33:01 2014 +++ src/sys/net/if.c Tue Nov 11 12:20:28 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: if.c,v 1.290 2014/08/09 05:33:01 rtr Exp $ */ +/* $NetBSD: if.c,v 1.290.2.1 2014/11/11 12:20:28 martin Exp $ */ /*- * Copyright (c) 1999, 2000, 2001, 2008 The NetBSD Foundation, Inc. @@ -90,7 +90,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if.c,v 1.290 2014/08/09 05:33:01 rtr Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if.c,v 1.290.2.1 2014/11/11 12:20:28 martin Exp $"); #include "opt_inet.h" @@ -164,6 +164,7 @@ static u_int if_index = 1; static size_t if_indexlim = 0; static uint64_t index_gen; static kmutex_t index_gen_mtx; +static kmutex_t if_clone_mtx; static struct ifaddr ** ifnet_addrs = NULL; @@ -252,6 +253,7 @@ void ifinit1(void) { mutex_init(&index_gen_mtx, MUTEX_DEFAULT, IPL_NONE); + mutex_init(&if_clone_mtx, MUTEX_DEFAULT, IPL_NONE); TAILQ_INIT(&ifnet_list); if_indexlim = 8; @@ -1833,6 +1835,7 @@ doifioctl(struct socket *so, u_long cmd, struct ifreq ifrb; struct oifreq *oifr = NULL; #endif + int r; switch (cmd) { #ifdef COMPAT_OIFREQ @@ -1874,9 +1877,12 @@ doifioctl(struct socket *so, u_long cmd, if (error != 0) return error; } - return (cmd == SIOCIFCREATE) ? + mutex_enter(&if_clone_mtx); + r = (cmd == SIOCIFCREATE) ? if_clone_create(ifr->ifr_name) : if_clone_destroy(ifr->ifr_name); + mutex_exit(&if_clone_mtx); + return r; case SIOCIFGCLONERS: return if_clone_list((struct if_clonereq *)data);
CVS commit: src/external/mit/xorg/server/drivers/xf86-video-intel
Module Name:src Committed By: tron Date: Tue Nov 11 11:30:56 UTC 2014 Modified Files: src/external/mit/xorg/server/drivers/xf86-video-intel: Makefile Log Message: Fix build with "USE_SSP" set to "yes". To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 \ src/external/mit/xorg/server/drivers/xf86-video-intel/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/mit/xorg/server/drivers/xf86-video-intel/Makefile diff -u src/external/mit/xorg/server/drivers/xf86-video-intel/Makefile:1.18 src/external/mit/xorg/server/drivers/xf86-video-intel/Makefile:1.19 --- src/external/mit/xorg/server/drivers/xf86-video-intel/Makefile:1.18 Thu Nov 6 18:58:18 2014 +++ src/external/mit/xorg/server/drivers/xf86-video-intel/Makefile Tue Nov 11 11:30:55 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.18 2014/11/06 18:58:18 snj Exp $ +# $NetBSD: Makefile,v 1.19 2014/11/11 11:30:55 tron Exp $ .include @@ -196,4 +196,6 @@ LIBDPLIBS+= pthread ${NETBSDSRCDIR}/lib CWARNFLAGS.clang+= -Wno-parentheses -Wno-tautological-compare \ -Wno-empty-body -Wno-error +COPTS.sna_display.c= -Wno-stack-protector + .include
CVS commit: src/sys
Module Name:src Committed By: nonaka Date: Tue Nov 11 11:30:21 UTC 2014 Modified Files: src/sys/external/bsd/drm2/dist/drm/i915: i915_drv.h src/sys/external/bsd/drm2/include/linux: pci.h src/sys/modules/drmkms: Makefile src/sys/modules/i915drmkms: Makefile Log Message: fix build failure. > > /tmp/bracket/build/2014.11.10.22.43.46-i386/src/sys/external/bsd/drm2/include/linux/pci.h:36:20: > fatal error: acpica.h: No such file or directory To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h cvs rdiff -u -r1.10 -r1.11 src/sys/external/bsd/drm2/include/linux/pci.h cvs rdiff -u -r1.3 -r1.4 src/sys/modules/drmkms/Makefile cvs rdiff -u -r1.4 -r1.5 src/sys/modules/i915drmkms/Makefile 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/dist/drm/i915/i915_drv.h diff -u src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h:1.10 src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h:1.11 --- src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h:1.10 Wed Nov 5 23:46:09 2014 +++ src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h Tue Nov 11 11:30:21 2014 @@ -30,12 +30,16 @@ #ifndef _I915_DRV_H_ #define _I915_DRV_H_ -#if defined(__NetBSD__) && (defined(i386) || defined(amd64)) +#if defined(__NetBSD__) +#ifdef _KERNEL_OPT +#if defined(i386) || defined(amd64) #include "acpica.h" +#endif /* i386 || amd64 */ +#endif /* _KERNEL_OPT */ #if (NACPICA > 0) #define CONFIG_ACPI -#endif -#endif +#endif /* NACPICA > 0 */ +#endif /* __NetBSD__ */ #include Index: src/sys/external/bsd/drm2/include/linux/pci.h diff -u src/sys/external/bsd/drm2/include/linux/pci.h:1.10 src/sys/external/bsd/drm2/include/linux/pci.h:1.11 --- src/sys/external/bsd/drm2/include/linux/pci.h:1.10 Wed Nov 5 23:46:09 2014 +++ src/sys/external/bsd/drm2/include/linux/pci.h Tue Nov 11 11:30:21 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: pci.h,v 1.10 2014/11/05 23:46:09 nonaka Exp $ */ +/* $NetBSD: pci.h,v 1.11 2014/11/11 11:30:21 nonaka Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -32,11 +32,13 @@ #ifndef _LINUX_PCI_H_ #define _LINUX_PCI_H_ +#ifdef _KERNEL_OPT #if defined(i386) || defined(amd64) #include "acpica.h" #else /* !(i386 || amd64) */ #define NACPICA 0 #endif /* i386 || amd64 */ +#endif #include #include Index: src/sys/modules/drmkms/Makefile diff -u src/sys/modules/drmkms/Makefile:1.3 src/sys/modules/drmkms/Makefile:1.4 --- src/sys/modules/drmkms/Makefile:1.3 Wed Jul 16 20:56:25 2014 +++ src/sys/modules/drmkms/Makefile Tue Nov 11 11:30:21 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.3 2014/07/16 20:56:25 riastradh Exp $ +# $NetBSD: Makefile,v 1.4 2014/11/11 11:30:21 nonaka Exp $ .include "../Makefile.inc" .include "Makefile.inc" @@ -58,4 +58,6 @@ COPTS.drm_crtc.c+= -Wno-shadow COPTS.drm_crtc.c+= -Wno-missing-field-initializers COPTS.drm_edid.c+= -Wno-shadow +CPPFLAGS+= -DNACPICA=1 + .include Index: src/sys/modules/i915drmkms/Makefile diff -u src/sys/modules/i915drmkms/Makefile:1.4 src/sys/modules/i915drmkms/Makefile:1.5 --- src/sys/modules/i915drmkms/Makefile:1.4 Thu Jul 24 21:18:40 2014 +++ src/sys/modules/i915drmkms/Makefile Tue Nov 11 11:30:21 2014 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.4 2014/07/24 21:18:40 riastradh Exp $ +# $NetBSD: Makefile,v 1.5 2014/11/11 11:30:21 nonaka Exp $ .include "../Makefile.inc" .include "../drmkms/Makefile.inc" @@ -38,7 +38,7 @@ SRCS+= i915_params.c SRCS+= i915_suspend.c SRCS+= i915_sysfs.c # XXX No sysfs in NetBSD. SRCS+= i915_ums.c -#SRCS+= intel_acpi.c # XXX ACPI +SRCS+= intel_acpi.c SRCS+= intel_bios.c SRCS+= intel_crt.c SRCS+= intel_ddi.c @@ -53,7 +53,7 @@ SRCS+= intel_hdmi.c SRCS+= intel_i2c.c SRCS+= intel_lvds.c SRCS+= intel_modes.c -#SRCS+= intel_opregion.c # XXX ACPI +SRCS+= intel_opregion.c SRCS+= intel_overlay.c SRCS+= intel_panel.c SRCS+= intel_pm.c @@ -76,4 +76,7 @@ COPTS.intel_pm.c+= -Wno-shadow CPPFLAGS+= -DCONFIG_DRM_I915_FBDEV +CPPFLAGS+= -DNACPICA=1 +CPPFLAGS+= -DNVGA=1 + .include
CVS commit: src/distrib/sets/lists/modules
Module Name:src Committed By: nonaka Date: Tue Nov 11 11:23:25 UTC 2014 Modified Files: src/distrib/sets/lists/modules: md.amd64 md.i386 Log Message: fix drmkms module path for xen. To generate a diff of this commit: cvs rdiff -u -r1.46 -r1.47 src/distrib/sets/lists/modules/md.amd64 cvs rdiff -u -r1.49 -r1.50 src/distrib/sets/lists/modules/md.i386 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/modules/md.amd64 diff -u src/distrib/sets/lists/modules/md.amd64:1.46 src/distrib/sets/lists/modules/md.amd64:1.47 --- src/distrib/sets/lists/modules/md.amd64:1.46 Mon Nov 10 21:22:14 2014 +++ src/distrib/sets/lists/modules/md.amd64 Tue Nov 11 11:23:25 2014 @@ -1,4 +1,4 @@ -# $NetBSD: md.amd64,v 1.46 2014/11/10 21:22:14 christos Exp $ +# $NetBSD: md.amd64,v 1.47 2014/11/11 11:23:25 nonaka Exp $ # # NOTE that there are two sets of files here: # @MODULEDIR@ and amd64-xen @@ -260,12 +260,12 @@ ./stand/amd64-xen/@OSRELEASE@/modules/dm/dm.kmod base-kernel-modules kmod,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/drmbase-kernel-modules kmod,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/drm/drm.kmod base-kernel-modules kmod,compatmodules -./stand/amd64-xen/@OSRELEASE@/drmkmsbase-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/drmkms/drmkms.kmod base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/drmkms_linux base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/drmkms_pci base-kernel-modules kmod -./stand/amd64-xen/@OSRELEASE@/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod +./stand/amd64-xen/@OSRELEASE@/modules/drmkmsbase-kernel-modules kmod +./stand/amd64-xen/@OSRELEASE@/modules/drmkms/drmkms.kmod base-kernel-modules kmod +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_linux base-kernel-modules kmod +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_pci base-kernel-modules kmod +./stand/amd64-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod ./stand/amd64-xen/@OSRELEASE@/modules/dtracebase-kernel-modules kmod,dtrace,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/dtrace/dtrace.kmod base-kernel-modules kmod,dtrace,compatmodules ./stand/amd64-xen/@OSRELEASE@/modules/dtrace_fbt base-kernel-modules kmod,dtrace,compatmodules Index: src/distrib/sets/lists/modules/md.i386 diff -u src/distrib/sets/lists/modules/md.i386:1.49 src/distrib/sets/lists/modules/md.i386:1.50 --- src/distrib/sets/lists/modules/md.i386:1.49 Mon Nov 10 21:22:14 2014 +++ src/distrib/sets/lists/modules/md.i386 Tue Nov 11 11:23:25 2014 @@ -1,4 +1,4 @@ -# $NetBSD: md.i386,v 1.49 2014/11/10 21:22:14 christos Exp $ +# $NetBSD: md.i386,v 1.50 2014/11/11 11:23:25 nonaka Exp $ # # NOTE that there are three sets of files here: # @MODULEDIR@, i386-xen, and i386pae-xen @@ -288,12 +288,12 @@ ./stand/i386-xen/@OSRELEASE@/modules/dm/dm.kmodbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drmbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drm/drm.kmod base-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/drmkms base-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/drmkms/drmkms.kmodbase-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/drmkms_linuxbase-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/drmkms_pci base-kernel-modules kmod -./stand/i386-xen/@OSRELEASE@/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod +./stand/i386-xen/@OSRELEASE@/modules/drmkms base-kernel-modules kmod +./stand/i386-xen/@OSRELEASE@/modules/drmkms/drmkms.kmodbase-kernel-modules kmod +./stand/i386-xen/@OSRELEASE@/modules/drmkms_linuxbase-kernel-modules kmod +./stand/i386-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod +./stand/i386-xen/@OSRELEASE@/modules/drmkms_pci base-kernel-modules kmod +./stand/i386-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod ./stand/i386-xen/@OSRELEASE@/modules/dtvbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtv/dtv.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtv_mathbase-kernel-modules kmod,compatmodules @@ -677,12 +677,12 @@ ./stand/i386pae-xen/@OSRELEASE@/modules/dm/dm.kmod base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/drmbase-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/drm/drm.kmod base-kernel-modules kmod,compatmodules -./stand/i386pae-xen/@OSRELEASE@/drmkms base-kernel-modules kmod -./stand/i386pae-xen/@OSRELEASE@/drmkms/drmkms.km
CVS commit: [netbsd-7] src/sys/dev
Module Name:src Committed By: martin Date: Tue Nov 11 10:42:22 UTC 2014 Modified Files: src/sys/dev [netbsd-7]: ccd.c dksubr.c ld.c vnd.c src/sys/dev/raidframe [netbsd-7]: rf_netbsdkintf.c Log Message: Pull up following revision(s) (requested by mlelstv in ticket #202): sys/dev/ccd.c: revision 1.153 sys/dev/ccd.c: revision 1.154 sys/dev/raidframe/rf_netbsdkintf.c: revision 1.313 sys/dev/raidframe/rf_netbsdkintf.c: revision 1.314 sys/dev/ld.c: revision 1.77 sys/dev/vnd.c: revision 1.233 sys/dev/dksubr.c: revision 1.52 sys/dev/dksubr.c: revision 1.53 clamp total number of sectors to UINT32_MAX instead of providing the lower 32bit of the 64bit number. No longer warn about differences bewteen disk size and total sector count in disklabel when the latter is just clamped to the maximum. To generate a diff of this commit: cvs rdiff -u -r1.151.2.1 -r1.151.2.2 src/sys/dev/ccd.c cvs rdiff -u -r1.51.2.1 -r1.51.2.2 src/sys/dev/dksubr.c cvs rdiff -u -r1.75.2.1 -r1.75.2.2 src/sys/dev/ld.c cvs rdiff -u -r1.232.2.1 -r1.232.2.2 src/sys/dev/vnd.c cvs rdiff -u -r1.312.2.1 -r1.312.2.2 src/sys/dev/raidframe/rf_netbsdkintf.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/ccd.c diff -u src/sys/dev/ccd.c:1.151.2.1 src/sys/dev/ccd.c:1.151.2.2 --- src/sys/dev/ccd.c:1.151.2.1 Mon Aug 18 12:40:36 2014 +++ src/sys/dev/ccd.c Tue Nov 11 10:42:22 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: ccd.c,v 1.151.2.1 2014/08/18 12:40:36 martin Exp $ */ +/* $NetBSD: ccd.c,v 1.151.2.2 2014/11/11 10:42:22 martin Exp $ */ /*- * Copyright (c) 1996, 1997, 1998, 1999, 2007, 2009 The NetBSD Foundation, Inc. @@ -88,7 +88,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ccd.c,v 1.151.2.1 2014/08/18 12:40:36 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ccd.c,v 1.151.2.2 2014/11/11 10:42:22 martin Exp $"); #if defined(_KERNEL_OPT) #include "opt_compat_netbsd.h" @@ -1479,7 +1479,10 @@ ccdgetdefaultlabel(struct ccd_softc *cs, memset(lp, 0, sizeof(*lp)); - lp->d_secperunit = cs->sc_size; + if (cs->sc_size > UINT32_MAX) + lp->d_secperunit = UINT32_MAX; + else + lp->d_secperunit = cs->sc_size; lp->d_secsize = ccg->ccg_secsize; lp->d_nsectors = ccg->ccg_nsectors; lp->d_ntracks = ccg->ccg_ntracks; @@ -1494,7 +1497,7 @@ ccdgetdefaultlabel(struct ccd_softc *cs, lp->d_flags = 0; lp->d_partitions[RAW_PART].p_offset = 0; - lp->d_partitions[RAW_PART].p_size = cs->sc_size; + lp->d_partitions[RAW_PART].p_size = lp->d_secperunit; lp->d_partitions[RAW_PART].p_fstype = FS_UNUSED; lp->d_npartitions = RAW_PART + 1; @@ -1549,7 +1552,9 @@ ccdgetdisklabel(dev_t dev) * same componets are used, and old disklabel may used * if that is found. */ - if (lp->d_secperunit != cs->sc_size) + if (lp->d_secperunit < UINT32_MAX ? + lp->d_secperunit != cs->sc_size : + lp->d_secperunit > cs->sc_size) printf("WARNING: %s: " "total sector size in disklabel (%ju) != " "the size of ccd (%ju)\n", cs->sc_xname, Index: src/sys/dev/dksubr.c diff -u src/sys/dev/dksubr.c:1.51.2.1 src/sys/dev/dksubr.c:1.51.2.2 --- src/sys/dev/dksubr.c:1.51.2.1 Tue Nov 11 10:36:41 2014 +++ src/sys/dev/dksubr.c Tue Nov 11 10:42:22 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: dksubr.c,v 1.51.2.1 2014/11/11 10:36:41 martin Exp $ */ +/* $NetBSD: dksubr.c,v 1.51.2.2 2014/11/11 10:42:22 martin Exp $ */ /*- * Copyright (c) 1996, 1997, 1998, 1999, 2002, 2008 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: dksubr.c,v 1.51.2.1 2014/11/11 10:36:41 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: dksubr.c,v 1.51.2.2 2014/11/11 10:42:22 martin Exp $"); #include #include @@ -540,7 +540,10 @@ dk_getdefaultlabel(struct dk_intf *di, s memset(lp, 0, sizeof(*lp)); - lp->d_secperunit = dg->dg_secperunit; + if (dg->dg_secperunit > UINT32_MAX) + lp->d_secperunit = UINT32_MAX; + else + lp->d_secperunit = dg->dg_secperunit; lp->d_secsize = dg->dg_secsize; lp->d_nsectors = dg->dg_nsectors; lp->d_ntracks = dg->dg_ntracks; @@ -555,7 +558,7 @@ dk_getdefaultlabel(struct dk_intf *di, s lp->d_flags = 0; lp->d_partitions[RAW_PART].p_offset = 0; - lp->d_partitions[RAW_PART].p_size = dg->dg_secperunit; + lp->d_partitions[RAW_PART].p_size = lp->d_secperunit; lp->d_partitions[RAW_PART].p_fstype = FS_UNUSED; lp->d_npartitions = RAW_PART + 1; @@ -590,17 +593,21 @@ dk_getdisklabel(struct dk_intf *di, stru return; /* Sanity check */ - if (lp->d_secperunit != dg->dg_secperunit) - printf("WARNING: %s: total sector size in disklabel (%d) " - "!= the size of %s (%" PRId64 ")\n", dksc->sc_xname, - lp->d_secperunit, di->di_dkname, dg->dg_secperunit); + if (lp->d_secperunit < UINT32_MAX ? + lp->d_secperunit != dg->dg_secperunit : + lp->d_secperunit > dg->dg_secperunit) + printf("WARNING: %s: total sector size in disklabe
CVS commit: [netbsd-7] src
Module Name:src Committed By: martin Date: Tue Nov 11 10:36:41 UTC 2014 Modified Files: src/sbin/dkctl [netbsd-7]: dkctl.8 dkctl.c src/sys/dev [netbsd-7]: dksubr.c ld.c vnd.c src/sys/dev/ata [netbsd-7]: wd.c src/sys/dev/dkwedge [netbsd-7]: dk.c src/sys/dev/raidframe [netbsd-7]: rf_netbsdkintf.c src/sys/dev/scsipi [netbsd-7]: sd.c src/sys/sys [netbsd-7]: dkio.h Log Message: Pull up following revision(s) (requested by mlelstv in ticket #201): sbin/dkctl/dkctl.8: revision 1.24 sbin/dkctl/dkctl.8: revision 1.25 sys/dev/scsipi/sd.c: revision 1.310 sys/dev/ata/wd.c: revision 1.415 sbin/dkctl/dkctl.c: revision 1.21 sys/dev/raidframe/rf_netbsdkintf.c: revision 1.315 sys/dev/ld.c: revision 1.78 sys/dev/vnd.c: revision 1.234 sys/dev/dksubr.c: revision 1.54 sys/sys/dkio.h: revision 1.20 sys/dev/dkwedge/dk.c: revision 1.74 Add ioctl to autodiscover wedges. Implement DIOCMWEDGES ioctl that triggers wedge autodiscovery. Also fix a reference counting bug and clean up some code. support DIOCMWEDGES ioctl. Add 'makewedges' option to autodiscover wedges from a changed label. New sentence, new line. Bump date for previous. To generate a diff of this commit: cvs rdiff -u -r1.23 -r1.23.24.1 src/sbin/dkctl/dkctl.8 cvs rdiff -u -r1.20 -r1.20.20.1 src/sbin/dkctl/dkctl.c cvs rdiff -u -r1.51 -r1.51.2.1 src/sys/dev/dksubr.c cvs rdiff -u -r1.75 -r1.75.2.1 src/sys/dev/ld.c cvs rdiff -u -r1.232 -r1.232.2.1 src/sys/dev/vnd.c cvs rdiff -u -r1.412 -r1.412.2.1 src/sys/dev/ata/wd.c cvs rdiff -u -r1.72.2.1 -r1.72.2.2 src/sys/dev/dkwedge/dk.c cvs rdiff -u -r1.312 -r1.312.2.1 src/sys/dev/raidframe/rf_netbsdkintf.c cvs rdiff -u -r1.308 -r1.308.2.1 src/sys/dev/scsipi/sd.c cvs rdiff -u -r1.19 -r1.19.2.1 src/sys/sys/dkio.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sbin/dkctl/dkctl.8 diff -u src/sbin/dkctl/dkctl.8:1.23 src/sbin/dkctl/dkctl.8:1.23.24.1 --- src/sbin/dkctl/dkctl.8:1.23 Tue Jan 4 23:29:51 2011 +++ src/sbin/dkctl/dkctl.8 Tue Nov 11 10:36:40 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: dkctl.8,v 1.23 2011/01/04 23:29:51 wiz Exp $ +.\" $NetBSD: dkctl.8,v 1.23.24.1 2014/11/11 10:36:40 martin Exp $ .\" .\" Copyright 2002 Wasabi Systems, Inc. .\" All rights reserved. @@ -33,7 +33,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd January 5, 2011 +.Dd November 4, 2014 .Dt DKCTL 8 .Os .Sh NAME @@ -165,6 +165,12 @@ Display information about the specified in this case is the wedge name. .It Ic listwedges List all of the wedges configured on the specified disk. +.It Ic makewedges +Delete all wedges configured on the specified disk, and autodiscover +the wedges again. +Wedges that are in use are not deleted and conflicting +or overlapping wedges are not created. +You need to list wedges to find out what has changed. .It Ic strategy Op Ar name Get and set the disk I/O scheduler (buffer queue strategy) on the drive. Index: src/sbin/dkctl/dkctl.c diff -u src/sbin/dkctl/dkctl.c:1.20 src/sbin/dkctl/dkctl.c:1.20.20.1 --- src/sbin/dkctl/dkctl.c:1.20 Sat Aug 27 16:34:38 2011 +++ src/sbin/dkctl/dkctl.c Tue Nov 11 10:36:40 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: dkctl.c,v 1.20 2011/08/27 16:34:38 joerg Exp $ */ +/* $NetBSD: dkctl.c,v 1.20.20.1 2014/11/11 10:36:40 martin Exp $ */ /* * Copyright 2001 Wasabi Systems, Inc. @@ -41,7 +41,7 @@ #include #ifndef lint -__RCSID("$NetBSD: dkctl.c,v 1.20 2011/08/27 16:34:38 joerg Exp $"); +__RCSID("$NetBSD: dkctl.c,v 1.20.20.1 2014/11/11 10:36:40 martin Exp $"); #endif @@ -101,6 +101,7 @@ static void disk_addwedge(int, char *[]) static void disk_delwedge(int, char *[]); static void disk_getwedgeinfo(int, char *[]); static void disk_listwedges(int, char *[]); +static void disk_makewedges(int, char *[]); static void disk_strategy(int, char *[]); static struct command commands[] = { @@ -149,6 +150,11 @@ static struct command commands[] = { disk_listwedges, O_RDONLY }, + { "makewedges", + "", + disk_makewedges, + O_RDWR }, + { "strategy", "[name]", disk_strategy, @@ -666,6 +672,20 @@ disk_listwedges(int argc, char *argv[]) } } +static void +disk_makewedges(int argc, char *argv[]) +{ + int bits; + + if (argc != 0) + usage(); + + if (ioctl(fd, DIOCMWEDGES, &bits) == -1) + err(1, "%s: makewedges", dvname); + else + printf("successfully scanned %s.\n", dvname); +} + static int dkw_sort(const void *a, const void *b) { Index: src/sys/dev/dksubr.c diff -u src/sys/dev/dksubr.c:1.51 src/sys/dev/dksubr.c:1.51.2.1 --- src/sys/dev/dksubr.c:1.51 Sat Jun 14 07:39:00 2014 +++ src/sys/dev/dksubr.c Tue Nov 11 10:36:41 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: dksubr.c,v 1.51 2014/06/14 07:39:00 hannken Exp $ */ +/* $NetBSD: dksubr.c,v 1.51.2.1 2014/11/11 10
CVS commit: [netbsd-7] src/sys/dev/dkwedge
Module Name:src Committed By: martin Date: Tue Nov 11 10:31:16 UTC 2014 Modified Files: src/sys/dev/dkwedge [netbsd-7]: dkwedge_bsdlabel.c dkwedge_gpt.c dkwedge_mbr.c Log Message: Pull up following revision(s) (requested by mlelstv in ticket #200): sys/dev/dkwedge/dkwedge_bsdlabel.c: revision 1.23 sys/dev/dkwedge/dkwedge_mbr.c: revision 1.8 sys/dev/dkwedge/dkwedge_gpt.c: revision 1.14 Handle disks with non DEV_BSIZE sectors. get sector size from disk structure. Be less noisy when handling wedge name conflicts. To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.19.4.1 src/sys/dev/dkwedge/dkwedge_bsdlabel.c cvs rdiff -u -r1.12 -r1.12.34.1 src/sys/dev/dkwedge/dkwedge_gpt.c cvs rdiff -u -r1.7 -r1.7.14.1 src/sys/dev/dkwedge/dkwedge_mbr.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/dkwedge/dkwedge_bsdlabel.c diff -u src/sys/dev/dkwedge/dkwedge_bsdlabel.c:1.19 src/sys/dev/dkwedge/dkwedge_bsdlabel.c:1.19.4.1 --- src/sys/dev/dkwedge/dkwedge_bsdlabel.c:1.19 Mon Mar 31 11:25:49 2014 +++ src/sys/dev/dkwedge/dkwedge_bsdlabel.c Tue Nov 11 10:31:16 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: dkwedge_bsdlabel.c,v 1.19 2014/03/31 11:25:49 martin Exp $ */ +/* $NetBSD: dkwedge_bsdlabel.c,v 1.19.4.1 2014/11/11 10:31:16 martin Exp $ */ /*- * Copyright (c) 2004 The NetBSD Foundation, Inc. @@ -79,7 +79,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: dkwedge_bsdlabel.c,v 1.19 2014/03/31 11:25:49 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: dkwedge_bsdlabel.c,v 1.19.4.1 2014/11/11 10:31:16 martin Exp $"); #include #ifdef _KERNEL @@ -137,6 +137,7 @@ typedef struct mbr_args { struct vnode *vp; void *buf; int error; + uint32_t secsize; } mbr_args_t; static const char * @@ -283,7 +284,7 @@ validate_label(mbr_args_t *a, daddr_t la int error, swapped; uint16_t npartitions; - error = dkwedge_read(a->pdk, a->vp, label_sector, a->buf, DEV_BSIZE); + error = dkwedge_read(a->pdk, a->vp, label_sector, a->buf, a->secsize); if (error) { aprint_error("%s: unable to read BSD disklabel @ %" PRId64 ", error = %d\n", a->pdk->dk_name, label_sector, error); @@ -297,7 +298,7 @@ validate_label(mbr_args_t *a, daddr_t la * in the sector. */ lp = a->buf; - lp_lim = (char *)a->buf + DEV_BSIZE - DISKLABEL_MINSIZE; + lp_lim = (char *)a->buf + a->secsize - DISKLABEL_MINSIZE; for (;; lp = (void *)((char *)lp + sizeof(uint32_t))) { if ((char *)lp > (char *)lp_lim) return (SCAN_CONTINUE); @@ -316,7 +317,7 @@ validate_label(mbr_args_t *a, daddr_t la /* Validate label length. */ if ((char *)lp + DISKLABEL_SIZE(npartitions) > - (char *)a->buf + DEV_BSIZE) { + (char *)a->buf + a->secsize) { aprint_error("%s: BSD disklabel @ " "%" PRId64 "+%zd has bogus partition count (%u)\n", a->pdk->dk_name, label_sector, label_offset, @@ -360,7 +361,7 @@ scan_mbr(mbr_args_t *a, int (*actn)(mbr_ this_ext = 0; for (;;) { a->error = dkwedge_read(a->pdk, a->vp, this_ext, a->buf, - DEV_BSIZE); + a->secsize); if (a->error) { aprint_error("%s: unable to read MBR @ %u, " "error = %d\n", a->pdk->dk_name, this_ext, @@ -456,8 +457,9 @@ dkwedge_discover_bsdlabel(struct disk *p int rval; a.pdk = pdk; + a.secsize = DEV_BSIZE << pdk->dk_blkshift; a.vp = vp; - a.buf = DKW_MALLOC(DEV_BSIZE); + a.buf = DKW_MALLOC(a.secsize); a.error = 0; /* MBR search. */ Index: src/sys/dev/dkwedge/dkwedge_gpt.c diff -u src/sys/dev/dkwedge/dkwedge_gpt.c:1.12 src/sys/dev/dkwedge/dkwedge_gpt.c:1.12.34.1 --- src/sys/dev/dkwedge/dkwedge_gpt.c:1.12 Mon May 17 23:09:52 2010 +++ src/sys/dev/dkwedge/dkwedge_gpt.c Tue Nov 11 10:31:16 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: dkwedge_gpt.c,v 1.12 2010/05/17 23:09:52 jakllsch Exp $ */ +/* $NetBSD: dkwedge_gpt.c,v 1.12.34.1 2014/11/11 10:31:16 martin Exp $ */ /*- * Copyright (c) 2004 The NetBSD Foundation, Inc. @@ -34,7 +34,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: dkwedge_gpt.c,v 1.12 2010/05/17 23:09:52 jakllsch Exp $"); +__KERNEL_RCSID(0, "$NetBSD: dkwedge_gpt.c,v 1.12.34.1 2014/11/11 10:31:16 martin Exp $"); #include #include @@ -265,13 +265,15 @@ dkwedge_discover_gpt(struct disk *pdk, s * Try with the partition name first. If that fails, * use the GUID string. If that fails, punt. */ - if ((error = dkwedge_add(&dkw)) == EEXIST) { - aprint_error("%s: wedge named '%s' already exists, " - "trying '%s'\n", pdk->dk_name, - dkw.dkw_wname, /* XXX Unicode */ - ent_guid_str); + if ((error = dkwedge_add(&dkw)) == EEXIST && + strcmp(dkw.dkw_wname, ent_guid_str) != 0) { strcpy(dkw.dkw_wname, ent_guid_str); error = dkwedge_add(&dkw); + if (!error) +aprint_error("%s: wedge named '%s' already " +"existed, using '%s'\n", pdk->dk_name, +dkw.dkw_wname, /* XXX Unicode */ +ent_guid_str); } i
CVS commit: [netbsd-7] src/sbin
Module Name:src Committed By: martin Date: Tue Nov 11 10:21:26 UTC 2014 Modified Files: src/sbin/fsck [netbsd-7]: fsck.c src/sbin/newfs [netbsd-7]: newfs.c Log Message: Pull up following revision(s) (requested by mlelstv in ticket #199): sbin/newfs/newfs.c: revision 1.112 sbin/fsck/fsck.c: revision 1.52 fix logic that handles command line arguments. Now you can: fsck /mnt/point fsck dkX fsck rdkX fsck /dev/dkX fsck /dev/rdkX fsck NAME=wedge Support wedge names. before: newfs dk1- formats /dev/rdk1 newfs rdk1 - cannot open /dev/rrdk1 newfs /dev/dk1 - /dev/dk1 is a block-device, use raw device newfs /dev/rdk1 - formats /dev/rdk1 now: newfs dk1- formats /dev/rdk1 newfs rdk1 - cannot open /dev/rrdk1 newfs /dev/dk1 - formats /dev/rdk1 (*) newfs /dev/rdk1 - formats /dev/rdk1 newfs NAME=wedge - formats /dev/rdk1 (*) getfsspecname() returns the block device which must be translated. Passing a block device manually cannot be distinguished from this case. To generate a diff of this commit: cvs rdiff -u -r1.51 -r1.51.10.1 src/sbin/fsck/fsck.c cvs rdiff -u -r1.111 -r1.111.10.1 src/sbin/newfs/newfs.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sbin/fsck/fsck.c diff -u src/sbin/fsck/fsck.c:1.51 src/sbin/fsck/fsck.c:1.51.10.1 --- src/sbin/fsck/fsck.c:1.51 Sat Apr 7 04:52:20 2012 +++ src/sbin/fsck/fsck.c Tue Nov 11 10:21:26 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: fsck.c,v 1.51 2012/04/07 04:52:20 christos Exp $ */ +/* $NetBSD: fsck.c,v 1.51.10.1 2014/11/11 10:21:26 martin Exp $ */ /* * Copyright (c) 1996 Christos Zoulas. All rights reserved. @@ -36,7 +36,7 @@ #include #ifndef lint -__RCSID("$NetBSD: fsck.c,v 1.51 2012/04/07 04:52:20 christos Exp $"); +__RCSID("$NetBSD: fsck.c,v 1.51.10.1 2014/11/11 10:21:26 martin Exp $"); #endif /* not lint */ #include @@ -196,23 +196,30 @@ main(int argc, char *argv[]) for (; argc--; argv++) { - const char *spec, *type, *cp; + const char *spec, *spec2, *mntpt, *type, *cp; char device[MAXPATHLEN]; - spec = *argv; - cp = strrchr(spec, '/'); + spec = mntpt = *argv; + spec2 = getfsspecname(buf, sizeof(buf), spec); + if (spec2 == NULL) + spec2 = spec; + + cp = strrchr(spec2, '/'); if (cp == 0) { (void)snprintf(device, sizeof(device), "%s%s", -_PATH_DEV, spec); - spec = device; +_PATH_DEV, spec2); + spec2 = device; } - if ((fs = getfsfile(spec)) == NULL && - (fs = getfsspec(spec)) == NULL) { - if (vfstype == NULL) -vfstype = getfslab(spec); - type = vfstype; + + fs = getfsfile(spec); + if (fs == NULL) + fs = getfsspec(spec); + if (fs == NULL && spec != spec2) { + fs = getfsspec(spec2); + spec = spec2; } - else { + + if (fs) { spec = getfsspecname(buf, sizeof(buf), fs->fs_spec); if (spec == NULL) err(FSCK_EXIT_CHECK_FAILED, "%s", buf); @@ -221,6 +228,10 @@ main(int argc, char *argv[]) errx(FSCK_EXIT_CHECK_FAILED, "%s has unknown file system type.", spec); + } else { + if (vfstype == NULL) +vfstype = getfslab(spec); + type = vfstype; } rval = checkfs(type, blockcheck(spec), *argv, NULL, NULL); Index: src/sbin/newfs/newfs.c diff -u src/sbin/newfs/newfs.c:1.111 src/sbin/newfs/newfs.c:1.111.10.1 --- src/sbin/newfs/newfs.c:1.111 Sat Jun 30 15:34:01 2012 +++ src/sbin/newfs/newfs.c Tue Nov 11 10:21:25 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: newfs.c,v 1.111 2012/06/30 15:34:01 tsutsui Exp $ */ +/* $NetBSD: newfs.c,v 1.111.10.1 2014/11/11 10:21:25 martin Exp $ */ /* * Copyright (c) 1983, 1989, 1993, 1994 @@ -78,7 +78,7 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 19 #if 0 static char sccsid[] = "@(#)newfs.c 8.13 (Berkeley) 5/1/95"; #else -__RCSID("$NetBSD: newfs.c,v 1.111 2012/06/30 15:34:01 tsutsui Exp $"); +__RCSID("$NetBSD: newfs.c,v 1.111.10.1 2014/11/11 10:21:25 martin Exp $"); #endif #endif /* not lint */ @@ -242,7 +242,10 @@ main(int argc, char *argv[]) struct statvfs *mp; struct stat sb; int ch, fsi, fso, len, n, Fflag, Iflag, Zflag; - char *s1, *s2, *special; + const char *s1, *special, *raw; + char *s2; + char specname[MAXPATHLEN]; + char rawname[MAXPATHLEN]; const char *opstring; int byte_sized = 0; #ifdef MFS @@ -490,6 +493,11 @@ main(int argc, char *argv[]) fso = fsi; } } else { /* !Fflag && !mfs */ + special = getfsspecname(specname, sizeof(specname), special); + raw = getdiskrawname(rawname, sizeof(rawname), special); + if (raw != NULL) + special = raw; + fsi = opendisk(special, O_RDONLY, device, sizeof(device), 0); special = device; if (fsi < 0 || fstat(fsi, &sb) == -1)
CVS commit: [netbsd-7] src/sys/external/bsd/drm2/include/linux
Module Name:src Committed By: martin Date: Tue Nov 11 09:09:33 UTC 2014 Modified Files: src/sys/external/bsd/drm2/include/linux [netbsd-7]: sched.h Log Message: Pull up following revision(s) (requested by nonaka in ticket #198): sys/external/bsd/drm2/include/linux/sched.h: revision 1.5 return correct remaining jiffies. fix X server hang when screen blank by DPMS. To generate a diff of this commit: cvs rdiff -u -r1.3.2.1 -r1.3.2.2 \ src/sys/external/bsd/drm2/include/linux/sched.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/external/bsd/drm2/include/linux/sched.h diff -u src/sys/external/bsd/drm2/include/linux/sched.h:1.3.2.1 src/sys/external/bsd/drm2/include/linux/sched.h:1.3.2.2 --- src/sys/external/bsd/drm2/include/linux/sched.h:1.3.2.1 Thu Oct 30 09:20:47 2014 +++ src/sys/external/bsd/drm2/include/linux/sched.h Tue Nov 11 09:09:32 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: sched.h,v 1.3.2.1 2014/10/30 09:20:47 martin Exp $ */ +/* $NetBSD: sched.h,v 1.3.2.2 2014/11/11 09:09:32 martin Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -49,6 +49,7 @@ task_pid_nr(struct proc *p) static inline long schedule_timeout_uninterruptible(long timeout) { + long remain; int start, end; if (cold) { @@ -61,7 +62,8 @@ schedule_timeout_uninterruptible(long ti (void)kpause("loonix", false /*!intr*/, timeout, NULL); end = hardclock_ticks; - return (end - start) > 0 ? (end - start) : 0; + remain = timeout - (end - start); + return remain > 0 ? remain : 0; } #endif /* _LINUX_SCHED_H_ */
CVS commit: [netbsd-7] src/sys/external/bsd/drm2
Module Name:src Committed By: martin Date: Tue Nov 11 09:06:32 UTC 2014 Modified Files: src/sys/external/bsd/drm2/dist/drm/i915 [netbsd-7]: i915_dma.c i915_drv.h intel_acpi.c intel_opregion.c src/sys/external/bsd/drm2/i915drm [netbsd-7]: files.i915drmkms src/sys/external/bsd/drm2/include/linux [netbsd-7]: acpi.h pci.h Log Message: Pull up following revision(s) (requested by nonaka in ticket #197): sys/external/bsd/drm2/dist/drm/i915/i915_drv.h: revision 1.10 sys/external/bsd/drm2/include/linux/pci.h: revision 1.10 sys/external/bsd/drm2/dist/drm/i915/intel_acpi.c: revision 1.3 sys/external/bsd/drm2/dist/drm/i915/intel_acpi.c: revision 1.4 sys/external/bsd/drm2/dist/drm/i915/intel_acpi.c: revision 1.5 sys/external/bsd/drm2/dist/drm/i915/intel_opregion.c: revision 1.6 sys/external/bsd/drm2/dist/drm/i915/intel_opregion.c: revision 1.7 sys/external/bsd/drm2/include/linux/acpi.h: revision 1.3 sys/external/bsd/drm2/dist/drm/i915/i915_dma.c: revision 1.12 sys/external/bsd/drm2/i915drm/files.i915drmkms: revision 1.8 i915drmkms(4): Enable CONFIG_ACPI if NACPICA > 0. Now brightness can be adjusted via hotkey on Mouse Computer LB-J300X (Clevo W330SU2). Fix compilation (debug) pci_attach_args of pci_find_device and match function is not the same thing. fix PR/49372. To generate a diff of this commit: cvs rdiff -u -r1.10.2.1 -r1.10.2.2 \ src/sys/external/bsd/drm2/dist/drm/i915/i915_dma.c cvs rdiff -u -r1.7.2.2 -r1.7.2.3 \ src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h cvs rdiff -u -r1.2 -r1.2.4.1 \ src/sys/external/bsd/drm2/dist/drm/i915/intel_acpi.c cvs rdiff -u -r1.5 -r1.5.2.1 \ src/sys/external/bsd/drm2/dist/drm/i915/intel_opregion.c cvs rdiff -u -r1.5.2.1 -r1.5.2.2 \ src/sys/external/bsd/drm2/i915drm/files.i915drmkms cvs rdiff -u -r1.2 -r1.2.8.1 src/sys/external/bsd/drm2/include/linux/acpi.h cvs rdiff -u -r1.7.2.2 -r1.7.2.3 \ src/sys/external/bsd/drm2/include/linux/pci.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/external/bsd/drm2/dist/drm/i915/i915_dma.c diff -u src/sys/external/bsd/drm2/dist/drm/i915/i915_dma.c:1.10.2.1 src/sys/external/bsd/drm2/dist/drm/i915/i915_dma.c:1.10.2.2 --- src/sys/external/bsd/drm2/dist/drm/i915/i915_dma.c:1.10.2.1 Mon Nov 10 19:45:54 2014 +++ src/sys/external/bsd/drm2/dist/drm/i915/i915_dma.c Tue Nov 11 09:06:32 2014 @@ -1375,7 +1375,11 @@ static int i915_load_modeset_init(struct goto out; #endif +#ifdef __NetBSD__ + intel_register_dsm_handler(dev); +#else intel_register_dsm_handler(); +#endif #ifndef __NetBSD__ /* XXX vga */ ret = vga_switcheroo_register_client(dev->pdev, &i915_switcheroo_ops, false); Index: src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h diff -u src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h:1.7.2.2 src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h:1.7.2.3 --- src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h:1.7.2.2 Mon Nov 10 19:45:54 2014 +++ src/sys/external/bsd/drm2/dist/drm/i915/i915_drv.h Tue Nov 11 09:06:32 2014 @@ -30,6 +30,13 @@ #ifndef _I915_DRV_H_ #define _I915_DRV_H_ +#if defined(__NetBSD__) && (defined(i386) || defined(amd64)) +#include "acpica.h" +#if (NACPICA > 0) +#define CONFIG_ACPI +#endif +#endif + #include #include "i915_reg.h" @@ -2720,8 +2727,8 @@ extern void intel_i2c_reset(struct drm_d /* intel_opregion.c */ struct intel_encoder; -extern int intel_opregion_setup(struct drm_device *dev); #ifdef CONFIG_ACPI +extern int intel_opregion_setup(struct drm_device *dev); extern void intel_opregion_init(struct drm_device *dev); extern void intel_opregion_fini(struct drm_device *dev); extern void intel_opregion_asle_intr(struct drm_device *dev); @@ -2730,6 +2737,7 @@ extern int intel_opregion_notify_encoder extern int intel_opregion_notify_adapter(struct drm_device *dev, pci_power_t state); #else +static inline int intel_opregion_setup(struct drm_device *dev) { return 0; } static inline void intel_opregion_init(struct drm_device *dev) { return; } static inline void intel_opregion_fini(struct drm_device *dev) { return; } static inline void intel_opregion_asle_intr(struct drm_device *dev) { return; } @@ -2747,10 +2755,22 @@ intel_opregion_notify_adapter(struct drm /* intel_acpi.c */ #ifdef CONFIG_ACPI +#ifdef __NetBSD__ +extern void intel_register_dsm_handler(struct drm_device *); +#else extern void intel_register_dsm_handler(void); +#endif extern void intel_unregister_dsm_handler(void); #else +#ifdef __NetBSD__ +static inline void +intel_register_dsm_handler(struct drm_device *dev) +{ + return; +} +#else static inline void intel_register_dsm_handler(void) { return; } +#endif static inline void intel_unregister_dsm_handler(void) { return; } #endif /* CONFIG_ACPI */ Index: src/sys/external/bsd/drm2/dist/drm/i915/intel_acpi.c diff -
CVS commit: src/usr.sbin/cpuctl/arch
Module Name:src Committed By: skrll Date: Tue Nov 11 08:23:17 UTC 2014 Modified Files: src/usr.sbin/cpuctl/arch: i386.c Log Message: kern/49379: Hypervisor's name typo To generate a diff of this commit: cvs rdiff -u -r1.60 -r1.61 src/usr.sbin/cpuctl/arch/i386.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/cpuctl/arch/i386.c diff -u src/usr.sbin/cpuctl/arch/i386.c:1.60 src/usr.sbin/cpuctl/arch/i386.c:1.61 --- src/usr.sbin/cpuctl/arch/i386.c:1.60 Fri Nov 7 05:37:05 2014 +++ src/usr.sbin/cpuctl/arch/i386.c Tue Nov 11 08:23:17 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: i386.c,v 1.60 2014/11/07 05:37:05 msaitoh Exp $ */ +/* $NetBSD: i386.c,v 1.61 2014/11/11 08:23:17 skrll Exp $ */ /*- * Copyright (c) 1999, 2000, 2001, 2006, 2007, 2008 The NetBSD Foundation, Inc. @@ -57,7 +57,7 @@ #include #ifndef lint -__RCSID("$NetBSD: i386.c,v 1.60 2014/11/07 05:37:05 msaitoh Exp $"); +__RCSID("$NetBSD: i386.c,v 1.61 2014/11/11 08:23:17 skrll Exp $"); #endif /* not lint */ #include @@ -1579,7 +1579,7 @@ cpu_probe_hv_features(struct cpu_info *c if (strncmp(hv_sig, "KVMKVMKVM", 9) == 0) hv_name = "KVM"; else if (strncmp(hv_sig, "Microsoft Hv", 12) == 0) - hv_name = "Hypver-V"; + hv_name = "Hyper-V"; else if (strncmp(hv_sig, "VMwareVMware", 12) == 0) hv_name = "VMware"; else if (strncmp(hv_sig, "XenVMMXenVMM", 12) == 0)
CVS commit: src/lib/libc/sys
Module Name:src Committed By: njoly Date: Tue Nov 11 08:10:02 UTC 2014 Modified Files: src/lib/libc/sys: extattr_get_file.2 ktrace.2 revoke.2 undelete.2 Log Message: Do not hardcode values for ENAMETOOLONG, use symblic constants. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/lib/libc/sys/extattr_get_file.2 cvs rdiff -u -r1.17 -r1.18 src/lib/libc/sys/ktrace.2 cvs rdiff -u -r1.15 -r1.16 src/lib/libc/sys/revoke.2 \ src/lib/libc/sys/undelete.2 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libc/sys/extattr_get_file.2 diff -u src/lib/libc/sys/extattr_get_file.2:1.5 src/lib/libc/sys/extattr_get_file.2:1.6 --- src/lib/libc/sys/extattr_get_file.2:1.5 Wed Aug 3 09:48:12 2011 +++ src/lib/libc/sys/extattr_get_file.2 Tue Nov 11 08:10:02 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: extattr_get_file.2,v 1.5 2011/08/03 09:48:12 wiz Exp $ +.\" $NetBSD: extattr_get_file.2,v 1.6 2014/11/11 08:10:02 njoly Exp $ .\" .\" Copyright (c) 2001 Dima Dorfman .\" Copyright (c) 2003 Robert Watson @@ -231,8 +231,12 @@ calls may also fail due to the following .It Bq Er EACCES Search permission is denied for a component of the path prefix. .It Bq Er ENAMETOOLONG -A component of a pathname exceeded 255 characters, -or an entire path name exceeded 1023 characters. +A component of a pathname exceeded +.Brq Dv NAME_MAX +characters, +or an entire path name exceeded +.Brq Dv PATH_MAX +characters. .It Bq Er ENOENT A component of the path name that must exist does not exist. .It Bq Er ENOTDIR Index: src/lib/libc/sys/ktrace.2 diff -u src/lib/libc/sys/ktrace.2:1.17 src/lib/libc/sys/ktrace.2:1.18 --- src/lib/libc/sys/ktrace.2:1.17 Thu May 13 10:20:58 2004 +++ src/lib/libc/sys/ktrace.2 Tue Nov 11 08:10:02 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: ktrace.2,v 1.17 2004/05/13 10:20:58 wiz Exp $ +.\" $NetBSD: ktrace.2,v 1.18 2014/11/11 08:10:02 njoly Exp $ .\" .\" Copyright (c) 1993 .\" The Regents of the University of California. All rights reserved. @@ -152,8 +152,12 @@ A component of the path prefix is not a .It Bq Er EINVAL The pathname contains a character with the high-order bit set. .It Bq Er ENAMETOOLONG -A component of a pathname exceeded 255 characters, -or an entire path name exceeded 1023 characters. +A component of a pathname exceeded +.Brq Dv NAME_MAX +characters, +or an entire path name exceeded +.Brq Dv PATH_MAX +characters. .It Bq Er ENOENT The named tracefile does not exist. .It Bq Er EACCES Index: src/lib/libc/sys/revoke.2 diff -u src/lib/libc/sys/revoke.2:1.15 src/lib/libc/sys/revoke.2:1.16 --- src/lib/libc/sys/revoke.2:1.15 Fri Jul 8 19:26:19 2011 +++ src/lib/libc/sys/revoke.2 Tue Nov 11 08:10:02 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: revoke.2,v 1.15 2011/07/08 19:26:19 wiz Exp $ +.\" $NetBSD: revoke.2,v 1.16 2014/11/11 08:10:02 njoly Exp $ .\" .\" Copyright (c) 1993 .\" The Regents of the University of California. All rights reserved. @@ -84,8 +84,12 @@ points outside the process's allocated a .It Bq Er ELOOP Too many symbolic links were encountered in translating the pathname. .It Bq Er ENAMETOOLONG -A component of a pathname exceeded 255 characters, -or an entire path name exceeded 1024 characters. +A component of a pathname exceeded +.Brq Dv NAME_MAX +characters, +or an entire path name exceeded +.Brq Dv PATH_MAX +characters. .It Bq Er ENOENT The named file or a component of the path name does not exist. .It Bq Er ENOTDIR Index: src/lib/libc/sys/undelete.2 diff -u src/lib/libc/sys/undelete.2:1.15 src/lib/libc/sys/undelete.2:1.16 --- src/lib/libc/sys/undelete.2:1.15 Sun Jan 11 02:46:30 2009 +++ src/lib/libc/sys/undelete.2 Tue Nov 11 08:10:02 2014 @@ -1,4 +1,4 @@ -.\" $NetBSD: undelete.2,v 1.15 2009/01/11 02:46:30 christos Exp $ +.\" $NetBSD: undelete.2,v 1.16 2014/11/11 08:10:02 njoly Exp $ .\" .\" Copyright (c) 1994 .\" The Regents of the University of California. All rights reserved. @@ -106,8 +106,12 @@ An I/O error occurred while updating the .It Bq Er ELOOP Too many symbolic links were encountered in translating the pathname. .It Bq Er ENAMETOOLONG -A component of a pathname exceeded 255 characters, -or an entire path name exceeded 1023 characters. +A component of a pathname exceeded +.Brq Dv NAME_MAX +characters, +or an entire path name exceeded +.Brq Dv PATH_MAX +characters. .It Bq Er ENOENT The named whiteout does not exist. .It Bq Er ENOTDIR