CVS commit: src/sys/secmodel/suser
Module Name:src Committed By: stacktic Date: Wed Nov 18 09:47:18 UTC 2009 Modified Files: src/sys/secmodel/suser: secmodel_suser.c Log Message: Fixed security.models.suser.curtain to deny when uid does not match. OK pooka@ To generate a diff of this commit: cvs rdiff -u -r1.31 -r1.32 src/sys/secmodel/suser/secmodel_suser.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/secmodel/suser/secmodel_suser.c diff -u src/sys/secmodel/suser/secmodel_suser.c:1.31 src/sys/secmodel/suser/secmodel_suser.c:1.32 --- src/sys/secmodel/suser/secmodel_suser.c:1.31 Sat Nov 14 18:36:56 2009 +++ src/sys/secmodel/suser/secmodel_suser.c Wed Nov 18 09:47:18 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: secmodel_suser.c,v 1.31 2009/11/14 18:36:56 elad Exp $ */ +/* $NetBSD: secmodel_suser.c,v 1.32 2009/11/18 09:47:18 stacktic Exp $ */ /*- * Copyright (c) 2006 Elad Efrat * All rights reserved. @@ -38,7 +38,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: secmodel_suser.c,v 1.31 2009/11/14 18:36:56 elad Exp $"); +__KERNEL_RCSID(0, "$NetBSD: secmodel_suser.c,v 1.32 2009/11/18 09:47:18 stacktic Exp $"); #include #include @@ -537,7 +537,7 @@ } if (secmodel_suser_curtain) { -if (kauth_cred_uidmatch(cred, p->p_cred) != 0) +if (!kauth_cred_uidmatch(cred, p->p_cred)) result = KAUTH_RESULT_DENY; }
CVS commit: othersrc/lib/libfsu_utils
Module Name:othersrc Committed By: stacktic Date: Wed Nov 18 10:02:26 UTC 2009 Modified Files: othersrc/lib/libfsu_utils: fsu_dir.c Log Message: Free the right pointer on fsu_getcwd To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 othersrc/lib/libfsu_utils/fsu_dir.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: othersrc/lib/libfsu_utils/fsu_dir.c diff -u othersrc/lib/libfsu_utils/fsu_dir.c:1.5 othersrc/lib/libfsu_utils/fsu_dir.c:1.6 --- othersrc/lib/libfsu_utils/fsu_dir.c:1.5 Tue Nov 17 15:10:13 2009 +++ othersrc/lib/libfsu_utils/fsu_dir.c Wed Nov 18 10:02:26 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: fsu_dir.c,v 1.5 2009/11/17 15:10:13 stacktic Exp $ */ +/* $NetBSD: fsu_dir.c,v 1.6 2009/11/18 10:02:26 stacktic Exp $ */ /* * Copyright (c) 2008,2009 Arnaud Ysmal. All Rights Reserved. @@ -244,7 +244,7 @@ dirname[0] = '/'; dirname[1] = '\0'; - free(names[0]); + free(names[i]); for (--i; i >= 0; --i) { rv = strlcat(dirname, names[i], len); free(names[i]);
CVS commit: src/sys/compat/linux32/common
Module Name:src Committed By: njoly Date: Wed Nov 18 12:01:26 UTC 2009 Modified Files: src/sys/compat/linux32/common: linux32_ipccall.c Log Message: Kill noisy debug printf. To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/compat/linux32/common/linux32_ipccall.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/compat/linux32/common/linux32_ipccall.c diff -u src/sys/compat/linux32/common/linux32_ipccall.c:1.6 src/sys/compat/linux32/common/linux32_ipccall.c:1.7 --- src/sys/compat/linux32/common/linux32_ipccall.c:1.6 Mon Nov 16 13:32:40 2009 +++ src/sys/compat/linux32/common/linux32_ipccall.c Wed Nov 18 12:01:25 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: linux32_ipccall.c,v 1.6 2009/11/16 13:32:40 joerg Exp $ */ +/* $NetBSD: linux32_ipccall.c,v 1.7 2009/11/18 12:01:25 njoly Exp $ */ /* * Copyright (c) 2008 Nicolas Joly @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: linux32_ipccall.c,v 1.6 2009/11/16 13:32:40 joerg Exp $"); +__KERNEL_RCSID(0, "$NetBSD: linux32_ipccall.c,v 1.7 2009/11/18 12:01:25 njoly Exp $"); #if defined(_KERNEL_OPT) #include "opt_sysv.h" @@ -376,8 +376,6 @@ SCARG(&bma, msgsz) = SCARG(uap, a2); SCARG(&bma, msgflg) = SCARG(uap, a3); - printf("linux32_msgsnd: %d %zu\n", SCARG(&bma, msqid), SCARG(&bma, msgsz)); - return sys_msgsnd(l, &bma, retval); } @@ -406,8 +404,6 @@ SCARG(&bma, msgtyp) = kluge.type; SCARG(&bma, msgflg) = SCARG(uap, a3); - printf("linux32_msgrcv: %d %zu\n", SCARG(&bma, msqid), SCARG(&bma, msgsz)); - return sys_msgrcv(l, &bma, retval); }
CVS commit: src/sys/ufs/ufs
Module Name:src Committed By: yamt Date: Wed Nov 18 12:22:48 UTC 2009 Modified Files: src/sys/ufs/ufs: ufs_wapbl.h Log Message: use NULL instead of 0 for pointers To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/ufs/ufs/ufs_wapbl.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/ufs/ufs/ufs_wapbl.h diff -u src/sys/ufs/ufs/ufs_wapbl.h:1.5 src/sys/ufs/ufs/ufs_wapbl.h:1.6 --- src/sys/ufs/ufs/ufs_wapbl.h:1.5 Wed Oct 8 22:58:56 2008 +++ src/sys/ufs/ufs/ufs_wapbl.h Wed Nov 18 12:22:48 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: ufs_wapbl.h,v 1.5 2008/10/08 22:58:56 pooka Exp $ */ +/* $NetBSD: ufs_wapbl.h,v 1.6 2009/11/18 12:22:48 yamt Exp $ */ /*- * Copyright (c) 2003,2006,2008 The NetBSD Foundation, Inc. @@ -135,11 +135,11 @@ } #define UFS_WAPBL_BEGIN(mp) \ - ufs_wapbl_begin2(mp, 0, 0, __FUNCTION__, __LINE__) + ufs_wapbl_begin2(mp, NULL, NULL, __FUNCTION__, __LINE__) #define UFS_WAPBL_BEGIN1(mp, v1) \ - ufs_wapbl_begin2(mp, v1, 0, __FUNCTION__, __LINE__) -#define UFS_WAPBL_END(mp) ufs_wapbl_end2(mp, 0, 0) -#define UFS_WAPBL_END1(mp, v1) ufs_wapbl_end2(mp, v1, 0) + ufs_wapbl_begin2(mp, v1, NULL, __FUNCTION__, __LINE__) +#define UFS_WAPBL_END(mp) ufs_wapbl_end2(mp, NULL, NULL) +#define UFS_WAPBL_END1(mp, v1) ufs_wapbl_end2(mp, v1, NULL) #define UFS_WAPBL_UPDATE(vp, access, modify, flags) \ if ((vp)->v_mount->mnt_wapbl) { \
CVS commit: src/sys/dev/tprof
Module Name:src Committed By: yamt Date: Wed Nov 18 12:24:05 UTC 2009 Modified Files: src/sys/dev/tprof: tprof.h Log Message: comment To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/sys/dev/tprof/tprof.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/tprof/tprof.h diff -u src/sys/dev/tprof/tprof.h:1.3 src/sys/dev/tprof/tprof.h:1.4 --- src/sys/dev/tprof/tprof.h:1.3 Wed Mar 11 13:48:47 2009 +++ src/sys/dev/tprof/tprof.h Wed Nov 18 12:24:05 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: tprof.h,v 1.3 2009/03/11 13:48:47 yamt Exp $ */ +/* $NetBSD: tprof.h,v 1.4 2009/11/18 12:24:05 yamt Exp $ */ /*- * Copyright (c)2008,2009 YAMAMOTO Takashi, @@ -32,7 +32,7 @@ typedef struct tprof_backend_cookie tprof_backend_cookie_t; typedef struct tprof_backend_ops { - uint64_t (*tbo_estimate_freq)(void); + uint64_t (*tbo_estimate_freq)(void); /* samples per second */ int (*tbo_start)(tprof_backend_cookie_t *); void (*tbo_stop)(tprof_backend_cookie_t *); } tprof_backend_ops_t;
CVS commit: src/sys/kern
Module Name:src Committed By: yamt Date: Wed Nov 18 12:25:15 UTC 2009 Modified Files: src/sys/kern: kern_turnstile.c Log Message: turnstile_block: turn a comment into KASSERTs. To generate a diff of this commit: cvs rdiff -u -r1.26 -r1.27 src/sys/kern/kern_turnstile.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/kern/kern_turnstile.c diff -u src/sys/kern/kern_turnstile.c:1.26 src/sys/kern/kern_turnstile.c:1.27 --- src/sys/kern/kern_turnstile.c:1.26 Wed Oct 21 21:12:06 2009 +++ src/sys/kern/kern_turnstile.c Wed Nov 18 12:25:15 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_turnstile.c,v 1.26 2009/10/21 21:12:06 rmind Exp $ */ +/* $NetBSD: kern_turnstile.c,v 1.27 2009/11/18 12:25:15 yamt Exp $ */ /*- * Copyright (c) 2002, 2006, 2007, 2009 The NetBSD Foundation, Inc. @@ -60,7 +60,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_turnstile.c,v 1.26 2009/10/21 21:12:06 rmind Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_turnstile.c,v 1.27 2009/11/18 12:25:15 yamt Exp $"); #include #include @@ -253,7 +253,6 @@ sq = &ts->ts_sleepq[q]; ts->ts_waiters[q]++; sleepq_enter(sq, l, tc->tc_mutex); - /* now tc->tc_mutex is also cur->l_mutex and l->l_mutex */ LOCKDEBUG_BARRIER(tc->tc_mutex, 1); l->l_kpriority = true; obase = l->l_kpribase; @@ -276,7 +275,8 @@ * compiling a kernel with LOCKDEBUG to pinpoint the problem. */ prio = lwp_eprio(l); - + KASSERT(cur == l); + KASSERT(tc->tc_mutex == cur->l_mutex); for (;;) { bool dolock;
CVS commit: src/sys/kern
Module Name:src Committed By: yamt Date: Wed Nov 18 12:26:22 UTC 2009 Modified Files: src/sys/kern: kern_turnstile.c Log Message: turnstile_block: reduce code duplication. To generate a diff of this commit: cvs rdiff -u -r1.27 -r1.28 src/sys/kern/kern_turnstile.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/kern/kern_turnstile.c diff -u src/sys/kern/kern_turnstile.c:1.27 src/sys/kern/kern_turnstile.c:1.28 --- src/sys/kern/kern_turnstile.c:1.27 Wed Nov 18 12:25:15 2009 +++ src/sys/kern/kern_turnstile.c Wed Nov 18 12:26:22 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_turnstile.c,v 1.27 2009/11/18 12:25:15 yamt Exp $ */ +/* $NetBSD: kern_turnstile.c,v 1.28 2009/11/18 12:26:22 yamt Exp $ */ /*- * Copyright (c) 2002, 2006, 2007, 2009 The NetBSD Foundation, Inc. @@ -60,7 +60,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_turnstile.c,v 1.27 2009/11/18 12:25:15 yamt Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_turnstile.c,v 1.28 2009/11/18 12:26:22 yamt Exp $"); #include #include @@ -295,21 +295,11 @@ */ break; } - - if (l == owner) { - /* owner has changed, restart from curlwp */ - lwp_unlock(l); - l = cur; - lwp_lock(l); - prio = lwp_eprio(l); - continue; - } - if (l->l_mutex != owner->l_mutex) dolock = true; else dolock = false; - if (dolock && !lwp_trylock(owner)) { + if (l == owner || (dolock && !lwp_trylock(owner))) { /* * restart from curlwp. * Note that there may be a livelock here:
CVS commit: src/sys/compat/linux32/common
Module Name:src Committed By: njoly Date: Wed Nov 18 12:27:58 UTC 2009 Modified Files: src/sys/compat/linux32/common: linux32_ipccall.c Log Message: Make linux32 msgsnd/msgrcv use the netbsd32 syscalls instead of native ones, to ensure that msgbuf mtype member will be of the right type. To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/sys/compat/linux32/common/linux32_ipccall.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/compat/linux32/common/linux32_ipccall.c diff -u src/sys/compat/linux32/common/linux32_ipccall.c:1.7 src/sys/compat/linux32/common/linux32_ipccall.c:1.8 --- src/sys/compat/linux32/common/linux32_ipccall.c:1.7 Wed Nov 18 12:01:25 2009 +++ src/sys/compat/linux32/common/linux32_ipccall.c Wed Nov 18 12:27:58 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: linux32_ipccall.c,v 1.7 2009/11/18 12:01:25 njoly Exp $ */ +/* $NetBSD: linux32_ipccall.c,v 1.8 2009/11/18 12:27:58 njoly Exp $ */ /* * Copyright (c) 2008 Nicolas Joly @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: linux32_ipccall.c,v 1.7 2009/11/18 12:01:25 njoly Exp $"); +__KERNEL_RCSID(0, "$NetBSD: linux32_ipccall.c,v 1.8 2009/11/18 12:27:58 njoly Exp $"); #if defined(_KERNEL_OPT) #include "opt_sysv.h" @@ -42,6 +42,7 @@ #include #include +#include #include #include @@ -369,14 +370,14 @@ static int linux32_msgsnd(struct lwp *l, const struct linux32_sys_ipc_args *uap, register_t *retval) { - struct sys_msgsnd_args bma; + struct netbsd32_msgsnd_args bma; SCARG(&bma, msqid) = SCARG(uap, a1); - SCARG(&bma, msgp) = SCARG_P32(uap, ptr); + SCARG(&bma, msgp) = SCARG(uap, ptr); SCARG(&bma, msgsz) = SCARG(uap, a2); SCARG(&bma, msgflg) = SCARG(uap, a3); - return sys_msgsnd(l, &bma, retval); + return netbsd32_msgsnd(l, &bma, retval); } /* @@ -391,7 +392,7 @@ static int linux32_msgrcv(struct lwp *l, const struct linux32_sys_ipc_args *uap, register_t *retval) { - struct sys_msgrcv_args bma; + struct netbsd32_msgrcv_args bma; struct linux32_msgrcv_msgarg kluge; int error; @@ -399,12 +400,12 @@ return error; SCARG(&bma, msqid) = SCARG(uap, a1); - SCARG(&bma, msgp) = NETBSD32PTR64(kluge.msg); + SCARG(&bma, msgp) = kluge.msg; SCARG(&bma, msgsz) = SCARG(uap, a2); SCARG(&bma, msgtyp) = kluge.type; SCARG(&bma, msgflg) = SCARG(uap, a3); - return sys_msgrcv(l, &bma, retval); + return netbsd32_msgrcv(l, &bma, retval); } static int
CVS commit: src/sys/sys
Module Name:src Committed By: yamt Date: Wed Nov 18 12:29:22 UTC 2009 Modified Files: src/sys/sys: ucontext.h Log Message: comment which bits of uc_flags are used by MD code. + * if your port needs more MD bits, please try to choose bits from _UC_MD + * first, rather than picking random unused bits. To generate a diff of this commit: cvs rdiff -u -r1.11 -r1.12 src/sys/sys/ucontext.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/sys/ucontext.h diff -u src/sys/sys/ucontext.h:1.11 src/sys/sys/ucontext.h:1.12 --- src/sys/sys/ucontext.h:1.11 Wed Oct 15 06:51:21 2008 +++ src/sys/sys/ucontext.h Wed Nov 18 12:29:22 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: ucontext.h,v 1.11 2008/10/15 06:51:21 wrstuden Exp $ */ +/* $NetBSD: ucontext.h,v 1.12 2009/11/18 12:29:22 yamt Exp $ */ /*- * Copyright (c) 1999, 2003 The NetBSD Foundation, Inc. @@ -57,6 +57,22 @@ #define _UC_STACK 0x02 /* valid uc_stack */ #define _UC_CPU 0x04 /* valid GPR context in uc_mcontext */ #define _UC_FPU 0x08 /* valid FPU context in uc_mcontext */ +#define _UC_MD 0x40070020 /* MD bits. see below */ + +/* + * _UC_MD includes: + * _UC_SETSTACK 0x0001 (many ports) and 0x0002 (arm) + * _UC_CLRSTACK 0x0002 (many ports) and 0x0004 (arm) + * _UC_POWERPC_VEC 0x0001 (powerpc) + * _UC_M68K_UC_USER 0x4000 (m68k) + * _UC_UNIQUE 0x0020 (alpha) + * _UC_ARM_VFP 0x0001 (arm) + * _UC_VM 0x0004 (i386) + * _UC_FXSAVE 0x0020 (i386) + * + * if your port needs more MD bits, please try to choose bits from _UC_MD + * first, rather than picking random unused bits. + */ #ifdef _KERNEL struct lwp;
CVS commit: src/sys/compat
Module Name:src Committed By: njoly Date: Wed Nov 18 15:19:24 UTC 2009 Modified Files: src/sys/compat/linux/common: linux_msg.h src/sys/compat/linux32/common: linux32_ipccall.c Log Message: Make compat linux/linux32 msgrcv_msgarg type member of type long/netbsd32_long to match linux definition. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.13 src/sys/compat/linux/common/linux_msg.h cvs rdiff -u -r1.8 -r1.9 src/sys/compat/linux32/common/linux32_ipccall.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/compat/linux/common/linux_msg.h diff -u src/sys/compat/linux/common/linux_msg.h:1.12 src/sys/compat/linux/common/linux_msg.h:1.13 --- src/sys/compat/linux/common/linux_msg.h:1.12 Tue Dec 9 11:09:11 2008 +++ src/sys/compat/linux/common/linux_msg.h Wed Nov 18 15:19:24 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: linux_msg.h,v 1.12 2008/12/09 11:09:11 njoly Exp $ */ +/* $NetBSD: linux_msg.h,v 1.13 2009/11/18 15:19:24 njoly Exp $ */ /*- * Copyright (c) 1995, 1998 The NetBSD Foundation, Inc. @@ -95,7 +95,7 @@ */ struct linux_msgrcv_msgarg { struct linux_mymsg *msg; - int type; + long type; }; /* * For msgctl calls. Index: src/sys/compat/linux32/common/linux32_ipccall.c diff -u src/sys/compat/linux32/common/linux32_ipccall.c:1.8 src/sys/compat/linux32/common/linux32_ipccall.c:1.9 --- src/sys/compat/linux32/common/linux32_ipccall.c:1.8 Wed Nov 18 12:27:58 2009 +++ src/sys/compat/linux32/common/linux32_ipccall.c Wed Nov 18 15:19:24 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: linux32_ipccall.c,v 1.8 2009/11/18 12:27:58 njoly Exp $ */ +/* $NetBSD: linux32_ipccall.c,v 1.9 2009/11/18 15:19:24 njoly Exp $ */ /* * Copyright (c) 2008 Nicolas Joly @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: linux32_ipccall.c,v 1.8 2009/11/18 12:27:58 njoly Exp $"); +__KERNEL_RCSID(0, "$NetBSD: linux32_ipccall.c,v 1.9 2009/11/18 15:19:24 njoly Exp $"); #if defined(_KERNEL_OPT) #include "opt_sysv.h" @@ -386,7 +386,7 @@ */ struct linux32_msgrcv_msgarg { netbsd32_pointer_t msg; - int type; + netbsd32_long type; }; static int
CVS commit: src/lib/libpam/modules/pam_unix
Module Name:src Committed By: drochner Date: Wed Nov 18 17:06:23 UTC 2009 Modified Files: src/lib/libpam/modules/pam_unix: pam_unix.c Log Message: if changing the password, don't clear PAM_AUTHTOK at the beginning -- this sabotages external password strength checkers To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/lib/libpam/modules/pam_unix/pam_unix.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/libpam/modules/pam_unix/pam_unix.c diff -u src/lib/libpam/modules/pam_unix/pam_unix.c:1.13 src/lib/libpam/modules/pam_unix/pam_unix.c:1.14 --- src/lib/libpam/modules/pam_unix/pam_unix.c:1.13 Sun Jun 14 23:23:54 2009 +++ src/lib/libpam/modules/pam_unix/pam_unix.c Wed Nov 18 17:06:23 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: pam_unix.c,v 1.13 2009/06/14 23:23:54 tonnerre Exp $ */ +/* $NetBSD: pam_unix.c,v 1.14 2009/11/18 17:06:23 drochner Exp $ */ /*- * Copyright 1998 Juniper Networks, Inc. @@ -40,7 +40,7 @@ #ifdef __FreeBSD__ __FBSDID("$FreeBSD: src/lib/libpam/modules/pam_unix/pam_unix.c,v 1.49 2004/02/10 10:13:21 des Exp $"); #else -__RCSID("$NetBSD: pam_unix.c,v 1.13 2009/06/14 23:23:54 tonnerre Exp $"); +__RCSID("$NetBSD: pam_unix.c,v 1.14 2009/11/18 17:06:23 drochner Exp $"); #endif @@ -557,7 +557,6 @@ /* Get the new password. */ for (tries = 0;;) { - pam_set_item(pamh, PAM_AUTHTOK, NULL); retval = pam_get_authtok(pamh, PAM_AUTHTOK, &new_pass, NULL); if (retval == PAM_TRY_AGAIN) { @@ -576,12 +575,12 @@ } if (min_pw_len > 0 && strlen(new_pass) < (size_t)min_pw_len) { pam_error(pamh, "Password is too short."); -continue; +goto retry; } if (strlen(new_pass) <= 5 && ++tries < 2) { pam_error(pamh, "Please enter a longer password."); -continue; +goto retry; } for (p = new_pass; *p && islower((unsigned char)*p); ++p); if (!*p && ++tries < 2) { @@ -590,10 +589,12 @@ "password.\nUnusual capitalization, " "control characters or digits are " "suggested."); -continue; +goto retry; } /* Password is OK. */ break; +retry: + pam_set_item(pamh, PAM_AUTHTOK, NULL); } pw_getpwconf(option, sizeof(option), pwd, #ifdef YP
CVS commit: src/sys
Module Name:src Committed By: pooka Date: Wed Nov 18 17:40:45 UTC 2009 Modified Files: src/sys/conf: files src/sys/kern: kern_module.c src/sys/sys: module.h Added Files: src/sys/kern: kern_module_vfs.c Log Message: * make it possible to include kern_module in a kernel without vfs support, i.e. move vfs functionality to a separate module (kern_module_vfs.c) * make module proplist size an MI constant (now 8k) instead of PAGE_SIZE * change some error values to something else than the karmic EINVAL To generate a diff of this commit: cvs rdiff -u -r1.963 -r1.964 src/sys/conf/files cvs rdiff -u -r1.53 -r1.54 src/sys/kern/kern_module.c cvs rdiff -u -r0 -r1.1 src/sys/kern/kern_module_vfs.c cvs rdiff -u -r1.17 -r1.18 src/sys/sys/module.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/conf/files diff -u src/sys/conf/files:1.963 src/sys/conf/files:1.964 --- src/sys/conf/files:1.963 Thu Nov 12 18:37:10 2009 +++ src/sys/conf/files Wed Nov 18 17:40:45 2009 @@ -1,4 +1,4 @@ -# $NetBSD: files,v 1.963 2009/11/12 18:37:10 snj Exp $ +# $NetBSD: files,v 1.964 2009/11/18 17:40:45 pooka Exp $ # @(#)files.newconf 7.5 (Berkeley) 5/10/93 version 20090313 @@ -1438,6 +1438,7 @@ file kern/kern_malloc_stdtype.c file kern/kern_malloc_debug.c malloc_debug file kern/kern_module.c +file kern/kern_module_vfs.c file kern/kern_mutex.c file kern/kern_mutex_obj.c file kern/kern_fileassoc.c fileassoc Index: src/sys/kern/kern_module.c diff -u src/sys/kern/kern_module.c:1.53 src/sys/kern/kern_module.c:1.54 --- src/sys/kern/kern_module.c:1.53 Thu Nov 5 14:09:14 2009 +++ src/sys/kern/kern_module.c Wed Nov 18 17:40:45 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_module.c,v 1.53 2009/11/05 14:09:14 pooka Exp $ */ +/* $NetBSD: kern_module.c,v 1.54 2009/11/18 17:40:45 pooka Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -34,7 +34,9 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_module.c,v 1.53 2009/11/05 14:09:14 pooka Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_module.c,v 1.54 2009/11/18 17:40:45 pooka Exp $"); + +#define _MODULE_INTERNAL #ifdef _KERNEL_OPT #include "opt_ddb.h" @@ -44,7 +46,6 @@ #include #include #include -#include #include #include #include @@ -53,21 +54,18 @@ #include #include #include -#include #include -#include -#include #include #include struct vm_map *module_map; +char module_base[MODULE_BASE_SIZE]; struct modlist module_list = TAILQ_HEAD_INITIALIZER(module_list); struct modlist module_bootlist = TAILQ_HEAD_INITIALIZER(module_bootlist); static module_t *module_active; -static char module_base[64]; static int module_verbose_on; static int module_autoload_on = 1; u_int module_count; @@ -87,23 +85,28 @@ static int module_do_load(const char *, bool, int, prop_dictionary_t, module_t **, modclass_t class, bool); static int module_do_unload(const char *); -static void module_error(const char *, ...) - __attribute__((__format__(__printf__,1,2))); -static void module_print(const char *, ...) - __attribute__((__format__(__printf__,1,2))); static int module_do_builtin(const char *, module_t **); static int module_fetch_info(module_t *); static void module_thread(void *); -static int module_load_plist_file(const char *, const bool, void **, - size_t *); + static bool module_merge_dicts(prop_dictionary_t, const prop_dictionary_t); +int module_eopnotsupp(void); + +int +module_eopnotsupp(void) +{ + + return EOPNOTSUPP; +} +__weak_alias(module_load_vfs,module_eopnotsupp); + /* * module_error: * * Utility function: log an error. */ -static void +void module_error(const char *fmt, ...) { va_list ap; @@ -120,7 +123,7 @@ * * Utility function: log verbose output. */ -static void +void module_print(const char *fmt, ...) { va_list ap; @@ -601,19 +604,15 @@ modinfo_t *mi; module_t *mod, *mod2; prop_dictionary_t filedict; - void *plist; - char buf[MAXMODNAME], *path; + char buf[MAXMODNAME]; const char *s, *p; int error; - size_t len, plistlen; - bool nochroot; + size_t len; KASSERT(mutex_owned(&module_lock)); filedict = NULL; - path = NULL; error = 0; - nochroot = false; /* * Avoid recursing too far. @@ -664,33 +663,16 @@ depth--; return ENOMEM; } - path = PNBUF_GET(); - if (!autoload) { - nochroot = false; - snprintf(path, MAXPATHLEN, "%s", name); - error = kobj_load_file(&mod->mod_kobj, path, nochroot); - } - if (autoload || (error == ENOENT)) { - nochroot = true; - snprintf(path, MAXPATHLEN, "%s/%s/%s.kmod", - module_base, name, name); - error = kobj_load_file(&mod->mod_kobj, path, nochroot); - } + + error = module_load_vfs(name, flags, autoload, mod, &filedict); if (error != 0) { kmem_free(mod, sizeof(*mod)); depth--; - PNBUF_PUT(path); - if (autoload) { -module_print("Cannot load kernel
CVS commit: src/sys/gdbscripts
Module Name:src Committed By: eeh Date: Wed Nov 18 18:02:00 UTC 2009 Modified Files: src/sys/gdbscripts: vdump Log Message: Get gdb to document the command. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/gdbscripts/vdump Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/gdbscripts/vdump diff -u src/sys/gdbscripts/vdump:1.4 src/sys/gdbscripts/vdump:1.5 --- src/sys/gdbscripts/vdump:1.4 Sat Nov 4 20:33:17 2006 +++ src/sys/gdbscripts/vdump Wed Nov 18 18:02:00 2009 @@ -1,8 +1,7 @@ -# $NetBSD: vdump,v 1.4 2006/11/04 20:33:17 pooka Exp $ +# $NetBSD: vdump,v 1.5 2009/11/18 18:02:00 eeh Exp $ # @(#)vdump 8.1 (Berkeley) 6/10/93 # -# dump the vnode list define dumpvnodes @@ -12,3 +11,7 @@ set $vp = (struct vnode *)$vp->v_freelist.tqe_next end end + +document dumpvnodes +dump the vnode list +end \ No newline at end of file
CVS commit: src/sys/gdbscripts
Module Name:src Committed By: eeh Date: Wed Nov 18 18:04:26 UTC 2009 Modified Files: src/sys/gdbscripts: vchain Log Message: Print out all 64-bits of 64-bit values on 64-bit machines and add documentation of these commands to gdb. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/gdbscripts/vchain Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/gdbscripts/vchain diff -u src/sys/gdbscripts/vchain:1.5 src/sys/gdbscripts/vchain:1.6 --- src/sys/gdbscripts/vchain:1.5 Sat Nov 4 20:33:17 2006 +++ src/sys/gdbscripts/vchain Wed Nov 18 18:04:26 2009 @@ -1,32 +1,39 @@ -# $NetBSD: vchain,v 1.5 2006/11/04 20:33:17 pooka Exp $ +# $NetBSD: vchain,v 1.6 2009/11/18 18:04:26 eeh Exp $ # @(#)vchain 8.1 (Berkeley) 6/10/93 # -# Given a vnode, follow its mount pointers + define vchain set $num = 0 set $vp=(struct vnode *)$arg0 while ($vp) - printf "vp: 0x%x freelist_next: 0x%x usecount: %d flags: 0x%x\n", $vp, $vp->v_freelist.tqe_next, $vp->v_uobj.uo_refs, $vp->v_flag + printf "vp: 0x%lx freelist_next: 0x%lx usecount: %d flags: i:0x%x v:0x%x u:0x%x\n",\ + $vp, $vp->v_freelist.tqe_next, $vp->v_uobj.uo_refs, \ + $vp->v_iflag, $vp->v_vflag, $vp->v_uflag set $num++ set $vp = $vp->v_mntvnodes.tqe_next end printf "Number of vnodes: %d\n", $num end +document vchain +Given a vnode, follow its mount pointers +end + define vprint set $vp=(struct vnode *)$arg0 set $ip=(struct inode *)$vp->v_data end -# print the vnode chain for a given mount point define mp_vchain set $mp = (struct mount *)$arg0 vchain $mp->mnt_vnodelist.tqh_first end +document mp_vchain +print the vnode chain for a given mount point +end -# print vnode chains for all mount points define vall set $mp=mountlist.cqh_first while ($mp) @@ -40,6 +47,9 @@ end end end +document vall +print vnode chains for all mount points +end define mountdump set $mp=mountlist.cqh_first @@ -52,3 +62,4 @@ set $mp = 0 end end +end \ No newline at end of file
CVS commit: src
Module Name:src Committed By: pooka Date: Wed Nov 18 18:05:19 UTC 2009 Modified Files: src: build.sh Log Message: Add rumptest command for testing rump linkage. To generate a diff of this commit: cvs rdiff -u -r1.218 -r1.219 src/build.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/build.sh diff -u src/build.sh:1.218 src/build.sh:1.219 --- src/build.sh:1.218 Tue Nov 17 20:49:34 2009 +++ src/build.sh Wed Nov 18 18:05:19 2009 @@ -1,5 +1,5 @@ #! /usr/bin/env sh -# $NetBSD: build.sh,v 1.218 2009/11/17 20:49:34 apb Exp $ +# $NetBSD: build.sh,v 1.219 2009/11/18 18:05:19 pooka Exp $ # # Copyright (c) 2001-2009 The NetBSD Foundation, Inc. # All rights reserved. @@ -242,6 +242,7 @@ do_iso_image=false do_iso_image_source=false do_params=false + do_rump=false # done_{operation}=true if given operation has been done. # @@ -569,6 +570,7 @@ kernel=conf Build kernel with config file \`conf' releasekernel=conf Install kernel built by kernel=conf to RELEASEDIR. modules Build and install kernel modules. +rumptestDo a linktest for rump (for developers). setsCreate binary sets in RELEASEDIR/RELEASEMACHINEDIR/binary/sets. DESTDIR should be populated beforehand. @@ -854,6 +856,10 @@ bomb "Must supply a directory with \`install=...'" ;; + rump|rumptest) + op=${op} + ;; + *) usage "Unknown operation \`${op}'" ;; @@ -1317,7 +1323,7 @@ eval cat <&1 | awk ' + /undefined reference/ && + !/more undefined references.*follow/{ +if (match($NF, "`rumpuser_") == 0) + fails[NR] = $0 +} + END{ +for (x in fails) + print fails[x] +exit x!=0 + }' + [ $? -ne 0 ] && bomb "Testlink of rump failed: ${set}" + done + statusmsg "Rump build&link tests successful" +} main() { @@ -1568,6 +1647,10 @@ installworld "${arg}" ;; + rump|rumptest) + dorump "${op}" + ;; + *) bomb "Unknown operation \`${op}'" ;;
CVS commit: src/sys/gdbscripts
Module Name:src Committed By: eeh Date: Wed Nov 18 18:05:51 UTC 2009 Modified Files: src/sys/gdbscripts: procs Log Message: Add the lwp address so you don't have to leave gdb and use ps to grab an lwp's stack. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/gdbscripts/procs Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/gdbscripts/procs diff -u src/sys/gdbscripts/procs:1.1 src/sys/gdbscripts/procs:1.2 --- src/sys/gdbscripts/procs:1.1 Wed Feb 20 20:56:35 2008 +++ src/sys/gdbscripts/procs Wed Nov 18 18:05:51 2009 @@ -1,4 +1,4 @@ -# $NetBSD: procs,v 1.1 2008/02/20 20:56:35 ad Exp $ +# $NetBSD: procs,v 1.2 2009/11/18 18:05:51 eeh Exp $ define procs set $i = 0 @@ -8,12 +8,12 @@ set $p = allproc.lh_first end if ($p) - printf "proc pid flag stat nlwps comm\n" + printf "proc pid flag stat nlwpslwp comm\n" end while ($p) - printf "%16lx %5d %8x %4x %5d %s", \ + printf "%16lx %5d %8x %4x %5d %16lx %s", \ $p, $p->p_pid, \ -$p->p_flag, $p->p_stat, $p->p_nlwps, \ +$p->p_flag, $p->p_stat, $p->p_nlwps, $p->p_lwps.lh_first, \ (char *) $p->p_comm printf "\n" set $p = $p->p_list.le_next
CVS commit: src/sys/gdbscripts
Module Name:src Committed By: eeh Date: Wed Nov 18 18:12:00 UTC 2009 Modified Files: src/sys/gdbscripts: lwps Log Message: Add a command to dump all thread stacks in the system and a command to dump lockdebug state. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/gdbscripts/lwps Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/gdbscripts/lwps diff -u src/sys/gdbscripts/lwps:1.2 src/sys/gdbscripts/lwps:1.3 --- src/sys/gdbscripts/lwps:1.2 Tue Jul 28 10:38:20 2009 +++ src/sys/gdbscripts/lwps Wed Nov 18 18:12:00 2009 @@ -1,4 +1,4 @@ -# $NetBSD: lwps,v 1.2 2009/07/28 10:38:20 skrll Exp $ +# $NetBSD: lwps,v 1.3 2009/11/18 18:12:00 eeh Exp $ define lwps set $i = 0 @@ -14,10 +14,12 @@ set $l = $p->p_lwps.lh_first set $j = 0 while ($j < $p->p_nlwps) -printf "%16lx %5d %5d %8x %16lx", \ +printf "0x%16lx %5d %5d %8x 0x%16lx", \ $l, $p->p_pid, $l->l_lid, $l->l_flag, $l->l_wchan if ($l->l_wmesg) printf " (%s)", (char *)$l->l_wmesg +# If the preceding command cannot dereference the pointer, use this instead: +# printf " (%lx)", $l->l_wmesg end set $l = $l->l_sibling.le_next printf "\n" @@ -28,3 +30,95 @@ set $i++ end end +document lwps +ps for lwps +end + +define threadlist + set $i = 0 + + while ($i < 2) + if ($i == 0) + set $p = allproc.lh_first + end + while ($p) + set $l = $p->p_lwps.lh_first + set $j = 0 + while ($j < $p->p_nlwps) + printf "\n" + printf "proc: %16lx %5d %8x %4x %5d %16lx %s", \ +$p, $p->p_pid, \ +$p->p_flag, $p->p_stat, $p->p_nlwps, $p->p_lwps.lh_first, \ +(char *) $p->p_comm + printf "\n" +printf "Thread: %16lx %5d %5d %8x %16lx\n", \ + $l, $p->p_pid, $l->l_lid, $l->l_flag, $l->l_wchan + kvm proc $l +where + printf "\n" + printf "\n" +set $l = $l->l_sibling.le_next +set $j++ + end + set $p = $p->p_list.le_next + end + set $i++ + end +end +document threadlist +Print out the stack of all threads in the system. +end + +define lock + set $ld = (struct lockdebug *)ld_rb_tree + set $a = $ld->ld_lock + set $b = (volatile void *)$arg0 + + while ($ld && $a != $b) + if ($a < $b) + set $ld = (struct lockdebug *)$ld->ld_rb_node.rb_nodes[1] + end + if ($a > $b) + set $ld = (struct lockdebug *)$ld->ld_rb_node.rb_nodes[0] + end + if ($ld == 0) + loop_break + end + set $a = $ld->ld_lock +# printf "a=%lx b=%lx ld=%lx ab %d\n", $a, $b, $ld, ($a < $b), ($a > $b) + end + if ($ld) + printf "lock address : %#018lx type : ", \ + (long)$ld->ld_lock + if ($ld->ld_flags & 0x2) + printf "sleep/adaptive\n" + else + printf "spin\n" + end + printf "initialized : %#018lx", \ + (long)$ld->ld_initaddr + if ($ld->ld_lockops->lo_type == 0x2) + printf " interlock: %#018lx\n", $ld->ld_locked + else + printf "\n" + printf "shared holds : %18u exclusive: ", \ +$ld->ld_shares + if (($ld->ld_flags & 0x1) != 0) +printf "1\n" + else +printf "0\n" + end + printf "shares wanted: %18u exclusive: %18u\n", \ +(unsigned)$ld->ld_shwant, (unsigned)$ld->ld_exwant + printf "cpu last held: %18u\n", \ +(unsigned)$ld->ld_cpu + printf "current lwp : %#018lx last held: %#018lx\n", \ +(long)0, (long)$ld->ld_lwp + printf "last locked : %#018lx unlocked : %#018lx\n", \ +(long)$ld->ld_locked, (long)$ld->ld_unlocked + end + end +end +document lock +Print out lockdebug info like ddb does. +end
CVS commit: src/sys/dev/pci
Module Name:src Committed By: jakllsch Date: Wed Nov 18 18:42:09 UTC 2009 Modified Files: src/sys/dev/pci: pcidevs Log Message: Drop unused/duplicate VIATECH VT8237_PCIB entry. While here, drop "(Apollo KT600)" from VIATECH VT8237, and s/ISA/LPC/. Additionally, add LPC Bridge ID for VT8251 from PR/37517. To generate a diff of this commit: cvs rdiff -u -r1.999 -r1.1000 src/sys/dev/pci/pcidevs Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/pcidevs diff -u src/sys/dev/pci/pcidevs:1.999 src/sys/dev/pci/pcidevs:1.1000 --- src/sys/dev/pci/pcidevs:1.999 Tue Oct 13 11:55:54 2009 +++ src/sys/dev/pci/pcidevs Wed Nov 18 18:42:08 2009 @@ -1,4 +1,4 @@ -$NetBSD: pcidevs,v 1.999 2009/10/13 11:55:54 cegger Exp $ +$NetBSD: pcidevs,v 1.1000 2009/11/18 18:42:08 jakllsch Exp $ /* * Copyright (c) 1995, 1996 Christopher G. Demetriou @@ -4119,7 +4119,6 @@ product VIATECH VT8233A 0x3147 VT8233A PCI-ISA Bridge product VIATECH VT8237_SATA 0x3149 VT8237 Integrated SATA Controller product VIATECH K8HTB 0x3188 K8HTB Host -product VIATECH VT8237_PCIB 0x3227 VT8237 PCI-ISA Bridge product VIATECH VT6421_RAID 0x3249 VT6421 Serial RAID Controller product VIATECH VT3314_IG 0x3344 VT3314 CN900 UniChrome Integrated Graphics product VIATECH VT8237R_SATA 0x3349 VT8237R Integrated SATA Controller @@ -4128,7 +4127,8 @@ product VIATECH VT8235 0x3177 VT8235 (Apollo KT400) PCI-ISA Bridge product VIATECH VT8377 0x3189 VT8377 Apollo KT400 CPU to PCI Bridge product VIATECH VT8378 0x3205 VT8378 Apollo KM400 CPU to PCI Bridge -product VIATECH VT8237 0x3227 VT8237 (Apollo KT600) PCI-ISA Bridge +product VIATECH VT8237 0x3227 VT8237 PCI-LPC Bridge +product VIATECH VT8251 0x3287 VT8251 PCI-LPC Bridge product VIATECH VT8237A_HDA 0x3288 VT8237A/VT8251 High Definition Audio Controller product VIATECH VT8237A_ISA 0x3337 VT8237A/VT82C586A PCI-ISA Bridge product VIATECH VT8237S_ISA 0x3372 VT8237S PCI-ISA Bridge
CVS commit: src/sys/dev/pci
Module Name:src Committed By: jakllsch Date: Wed Nov 18 18:44:56 UTC 2009 Modified Files: src/sys/dev/pci: pcidevs.h pcidevs_data.h Log Message: regen. To generate a diff of this commit: cvs rdiff -u -r1.999 -r1.1000 src/sys/dev/pci/pcidevs.h cvs rdiff -u -r1.998 -r1.999 src/sys/dev/pci/pcidevs_data.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/pci/pcidevs.h diff -u src/sys/dev/pci/pcidevs.h:1.999 src/sys/dev/pci/pcidevs.h:1.1000 --- src/sys/dev/pci/pcidevs.h:1.999 Tue Oct 13 11:56:16 2009 +++ src/sys/dev/pci/pcidevs.h Wed Nov 18 18:44:55 2009 @@ -1,10 +1,10 @@ -/* $NetBSD: pcidevs.h,v 1.999 2009/10/13 11:56:16 cegger Exp $ */ +/* $NetBSD: pcidevs.h,v 1.1000 2009/11/18 18:44:55 jakllsch Exp $ */ /* * THIS FILE AUTOMATICALLY GENERATED. DO NOT EDIT. * * generated from: - * NetBSD: pcidevs,v 1.999 2009/10/13 11:55:54 cegger Exp + * NetBSD: pcidevs,v 1.1000 2009/11/18 18:42:08 jakllsch Exp */ /* @@ -4126,7 +4126,6 @@ #define PCI_PRODUCT_VIATECH_VT8233A 0x3147 /* VT8233A PCI-ISA Bridge */ #define PCI_PRODUCT_VIATECH_VT8237_SATA 0x3149 /* VT8237 Integrated SATA Controller */ #define PCI_PRODUCT_VIATECH_K8HTB 0x3188 /* K8HTB Host */ -#define PCI_PRODUCT_VIATECH_VT8237_PCIB 0x3227 /* VT8237 PCI-ISA Bridge */ #define PCI_PRODUCT_VIATECH_VT6421_RAID 0x3249 /* VT6421 Serial RAID Controller */ #define PCI_PRODUCT_VIATECH_VT3314_IG 0x3344 /* VT3314 CN900 UniChrome Integrated Graphics */ #define PCI_PRODUCT_VIATECH_VT8237R_SATA 0x3349 /* VT8237R Integrated SATA Controller */ @@ -4135,7 +4134,8 @@ #define PCI_PRODUCT_VIATECH_VT8235 0x3177 /* VT8235 (Apollo KT400) PCI-ISA Bridge */ #define PCI_PRODUCT_VIATECH_VT8377 0x3189 /* VT8377 Apollo KT400 CPU to PCI Bridge */ #define PCI_PRODUCT_VIATECH_VT8378 0x3205 /* VT8378 Apollo KM400 CPU to PCI Bridge */ -#define PCI_PRODUCT_VIATECH_VT8237 0x3227 /* VT8237 (Apollo KT600) PCI-ISA Bridge */ +#define PCI_PRODUCT_VIATECH_VT8237 0x3227 /* VT8237 PCI-LPC Bridge */ +#define PCI_PRODUCT_VIATECH_VT8251 0x3287 /* VT8251 PCI-LPC Bridge */ #define PCI_PRODUCT_VIATECH_VT8237A_HDA 0x3288 /* VT8237A/VT8251 High Definition Audio Controller */ #define PCI_PRODUCT_VIATECH_VT8237A_ISA 0x3337 /* VT8237A/VT82C586A PCI-ISA Bridge */ #define PCI_PRODUCT_VIATECH_VT8237S_ISA 0x3372 /* VT8237S PCI-ISA Bridge */ Index: src/sys/dev/pci/pcidevs_data.h diff -u src/sys/dev/pci/pcidevs_data.h:1.998 src/sys/dev/pci/pcidevs_data.h:1.999 --- src/sys/dev/pci/pcidevs_data.h:1.998 Tue Oct 13 11:56:16 2009 +++ src/sys/dev/pci/pcidevs_data.h Wed Nov 18 18:44:56 2009 @@ -1,10 +1,10 @@ -/* $NetBSD: pcidevs_data.h,v 1.998 2009/10/13 11:56:16 cegger Exp $ */ +/* $NetBSD: pcidevs_data.h,v 1.999 2009/11/18 18:44:56 jakllsch Exp $ */ /* * THIS FILE AUTOMATICALLY GENERATED. DO NOT EDIT. * * generated from: - * NetBSD: pcidevs,v 1.999 2009/10/13 11:55:54 cegger Exp + * NetBSD: pcidevs,v 1.1000 2009/11/18 18:42:08 jakllsch Exp */ /* @@ -6607,8 +6607,6 @@ 24242, 692, 7775, 6013, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_K8HTB, 23790, 6430, 0, - PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237_PCIB, - 24242, 6314, 6116, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT6421_RAID, 24297, 9689, 6008, 6013, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT3314_IG, @@ -6626,13 +6624,15 @@ PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8378, 24369, 24356, 24376, 2560, 6480, 615, 6116, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237, - 24242, 23803, 24382, 6314, 6116, 0, + 24242, 19704, 6116, 0, + PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8251, + 24097, 19704, 6116, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237A_HDA, - 24389, 16236, 16241, 6503, 6013, 0, + 24382, 16236, 16241, 6503, 6013, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237A_ISA, - 24404, 6314, 6116, 0, + 24397, 6314, 6116, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237S_ISA, - 24422, 6314, 6116, 0, + 24415, 6314, 6116, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237A_PPB, 23928, 7573, 6116, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237A_HB, @@ -6642,15 +6642,15 @@ PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT3351_HB_4351, 23818, 6430, 6116, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_CX700M2_IDE, - 24430, 6179, 6013, 0, + 24423, 6179, 6013, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237A_SATA_2, 23928, 692, 7775, 6013, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT3351_IOAPIC, - 23818, 7733, 2, 15448, 6013, 0, + 23818, 7733, 24437, 15448, 6013, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT8237S_SATA, - 24422, 692, 7775, 6013, 0, + 24415, 692, 7775, 6013, 0, PCI_VENDOR_VIATECH, PCI_PRODUCT_VIATECH_VT86C100A, - 24449, 24459, 5390, 5288, 0, + 24442,
CVS commit: src/sys/dev/pci
Module Name:src Committed By: jakllsch Date: Wed Nov 18 19:42:19 UTC 2009 Modified Files: src/sys/dev/pci: viaide.c Log Message: Match VT8251 IDE controller and enable UDMA Mode 6 thereon. Should fix PATA speed issue in PR/37517. Due to lack of hardware, only compile tested at this point. To generate a diff of this commit: cvs rdiff -u -r1.61 -r1.62 src/sys/dev/pci/viaide.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/viaide.c diff -u src/sys/dev/pci/viaide.c:1.61 src/sys/dev/pci/viaide.c:1.62 --- src/sys/dev/pci/viaide.c:1.61 Mon Oct 19 18:41:16 2009 +++ src/sys/dev/pci/viaide.c Wed Nov 18 19:42:18 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: viaide.c,v 1.61 2009/10/19 18:41:16 bouyer Exp $ */ +/* $NetBSD: viaide.c,v 1.62 2009/11/18 19:42:18 jakllsch Exp $ */ /* * Copyright (c) 1999, 2000, 2001 Manuel Bouyer. @@ -26,7 +26,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: viaide.c,v 1.61 2009/10/19 18:41:16 bouyer Exp $"); +__KERNEL_RCSID(0, "$NetBSD: viaide.c,v 1.62 2009/11/18 19:42:18 jakllsch Exp $"); #include #include @@ -523,6 +523,10 @@ aprint_normal("CX700M2/VX700 ATA133 controller\n"); sc->sc_wdcdev.sc_atac.atac_udma_cap = 6; break; + case PCI_PRODUCT_VIATECH_VT8251: + aprint_normal("VT8251 ATA133 controller\n"); + sc->sc_wdcdev.sc_atac.atac_udma_cap = 6; + break; default: unknown: aprint_normal("unknown VIA ATA controller\n");
CVS commit: src/sys/arch/i386/stand/boot
Module Name:src Committed By: dsl Date: Wed Nov 18 20:33:39 UTC 2009 Modified Files: src/sys/arch/i386/stand/boot: Makefile.boot Log Message: Keep the output of 'ld' prior to extracting the image. Useful for debugging (etc) since it contains the symbols. To generate a diff of this commit: cvs rdiff -u -r1.40 -r1.41 src/sys/arch/i386/stand/boot/Makefile.boot 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/i386/stand/boot/Makefile.boot diff -u src/sys/arch/i386/stand/boot/Makefile.boot:1.40 src/sys/arch/i386/stand/boot/Makefile.boot:1.41 --- src/sys/arch/i386/stand/boot/Makefile.boot:1.40 Mon Mar 30 09:22:52 2009 +++ src/sys/arch/i386/stand/boot/Makefile.boot Wed Nov 18 20:33:39 2009 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.boot,v 1.40 2009/03/30 09:22:52 tsutsui Exp $ +# $NetBSD: Makefile.boot,v 1.41 2009/11/18 20:33:39 dsl Exp $ S= ${.CURDIR}/../../../../.. @@ -145,7 +145,7 @@ # explicitly pull in the required objects before any other library code. ${PROG}: ${OBJS} ${LIBLIST} ${.CURDIR}/../Makefile.boot ${_MKTARGET_LINK} - bb="$$( ${CC} -o ${PROG}.tmp ${LDFLAGS} -Wl,-Ttext,0 -Wl,-cref \ + bb="$$( ${CC} -o ${PROG}.syms ${LDFLAGS} -Wl,-Ttext,0 -Wl,-cref \ ${OBJS} ${LIBLIST} | ( \ while read symbol file; do \ [ -z "$$file" ] && continue; \ @@ -161,9 +161,8 @@ do :; \ done; \ ) )"; \ - ${CC} -o ${PROG}.tmp ${LDFLAGS} -Wl,-Ttext,0 \ + ${CC} -o ${PROG}.syms ${LDFLAGS} -Wl,-Ttext,0 \ -Wl,-Map,${PROG}.map -Wl,-cref ${OBJS} $$bb ${LIBLIST} - ${OBJCOPY} -O binary ${PROG}.tmp ${PROG} - rm -f ${PROG}.tmp + ${OBJCOPY} -O binary ${PROG}.syms ${PROG} .include
CVS commit: src/sys/arch/i386/stand/mbr
Module Name:src Committed By: dsl Date: Wed Nov 18 20:51:22 UTC 2009 Modified Files: src/sys/arch/i386/stand/mbr: mbr.S Log Message: Adjust the way references to the unrelocated addresses are done so that the address doesn't have to be passed in. Adjust #ifdef so that only one item is checked - at it is the one used. To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/sys/arch/i386/stand/mbr/mbr.S 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/i386/stand/mbr/mbr.S diff -u src/sys/arch/i386/stand/mbr/mbr.S:1.20 src/sys/arch/i386/stand/mbr/mbr.S:1.21 --- src/sys/arch/i386/stand/mbr/mbr.S:1.20 Fri Nov 28 18:18:16 2008 +++ src/sys/arch/i386/stand/mbr/mbr.S Wed Nov 18 20:51:22 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: mbr.S,v 1.20 2008/11/28 18:18:16 dsl Exp $ */ +/* $NetBSD: mbr.S,v 1.21 2009/11/18 20:51:22 dsl Exp $ */ /* * Copyright (c) 1999-2004 The NetBSD Foundation, Inc. @@ -63,6 +63,8 @@ #if !defined(COM_FREQ) #define COM_FREQ 1843200 #endif +#else +#undef COM_BAUD #endif #ifdef BOOTSEL @@ -72,8 +74,7 @@ #include #include -#define BOOTADDR 0x7c00 -#define LOADADDR 0x0600 /* address were are linked to */ +#define BOOTADDR 0x7c00 /* where we get loaded to */ #define TABENTRYSIZE (MBR_BS_PARTNAMESIZE + 1) #define NAMETABSIZE (MBR_PART_COUNT * TABENTRYSIZE) @@ -130,7 +131,7 @@ mov %ax, %es mov %ax, %ds movw $mbr, %di - mov $mbr - LOADADDR + BOOTADDR, %si + mov $BOOTADDR + (mbr - start), %si push %ax /* zero for %cs of lret */ push %di movw $(bss_start - mbr), %cx @@ -153,7 +154,7 @@ push %dx /* save drive number */ push %dx /* twice - for err_msg loop */ -#if defined(COM_PORT) && defined(COM_BAUD) +#if defined(COM_BAUD) mov $com_args, %si mov $num_com_args, %cl /* %ch is zero from above */ mov COM_PORT_VAL, %dx @@ -258,7 +259,7 @@ pop %dx /* recover drive # */ push %dx /* save drive */ int $0x13 - movw $nametab - LOADADDR + BOOTADDR, %bx + movw $BOOTADDR + (nametab - start), %bx jnc next_extended /* abort menu on read fail */ #endif @@ -284,7 +285,7 @@ int $0x1a mov %dx, %di /* start time to di */ 3: -#ifdef COM_PORT +#ifdef COM_PORT_VAL mov COM_PORT_VAL, %dx push %dx add $5, %dx @@ -391,7 +392,7 @@ pop %dx /* original drive number */ push %dx push %dx -#ifdef COM_PORT +#ifdef COM_PORT_VAL jmp wait_key /* Read with timeout (again) */ #else jmp get_key /* Blocking read */ @@ -514,7 +515,7 @@ */ movl %ebp, %esi pop %dx /* recover drive # */ - jmp start - LOADADDR + BOOTADDR + jmp BOOTADDR #ifndef NO_CHS @@ -552,7 +553,7 @@ #ifndef NO_BANNER #ifdef BOOTSEL -#ifdef COM_PORT +#ifdef COM_PORT_VAL banner: .asciz "a: disk" #else banner: .asciz "Fn: diskn" @@ -578,7 +579,7 @@ #endif #endif -#if defined(COM_PORT) && defined(COM_BAUD) +#if defined(COM_BAUD) #define COM_DIVISOR (((COM_FREQ / COM_BAUD) + 8) / 16) com_args: .byte 0x80 /* divisor latch enable */ @@ -601,7 +602,7 @@ message_crlf: call message movw $crlf, %si -#ifdef COM_PORT +#ifdef COM_PORT_VAL message: pusha message_1:
CVS commit: src/sys/arch/i386/stand/bootxx
Module Name:src Committed By: dsl Date: Wed Nov 18 21:02:16 UTC 2009 Modified Files: src/sys/arch/i386/stand/bootxx: boot1.c src/sys/arch/i386/stand/bootxx/bootxx_ustarfs: Makefile Log Message: Reinstate the 'banner'. It is a useful diagnostic that the boot sequence is proceeding. To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/sys/arch/i386/stand/bootxx/boot1.c cvs rdiff -u -r1.2 -r1.3 \ src/sys/arch/i386/stand/bootxx/bootxx_ustarfs/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/arch/i386/stand/bootxx/boot1.c diff -u src/sys/arch/i386/stand/bootxx/boot1.c:1.17 src/sys/arch/i386/stand/bootxx/boot1.c:1.18 --- src/sys/arch/i386/stand/bootxx/boot1.c:1.17 Wed Apr 30 16:18:26 2008 +++ src/sys/arch/i386/stand/bootxx/boot1.c Wed Nov 18 21:02:16 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: boot1.c,v 1.17 2008/04/30 16:18:26 ad Exp $ */ +/* $NetBSD: boot1.c,v 1.18 2009/11/18 21:02:16 dsl Exp $ */ /*- * Copyright (c) 2003 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__RCSID("$NetBSD: boot1.c,v 1.17 2008/04/30 16:18:26 ad Exp $"); +__RCSID("$NetBSD: boot1.c,v 1.18 2009/11/18 21:02:16 dsl Exp $"); #include #include @@ -62,15 +62,13 @@ const char * boot1(uint32_t biosdev, uint32_t *sector) { -struct stat sb; + struct stat sb; int fd; bios_sector = *sector; d.dev = biosdev; -#ifdef SHOW_BANNER -putstr("\r\nNetBSD/x86 " STR(FS) " Primary Bootstrap\r\n"); -#endif + putstr("\r\nNetBSD/x86 " STR(FS) " Primary Bootstrap\r\n"); if (set_geometry(&d, NULL)) return "set_geometry\r\n"; Index: src/sys/arch/i386/stand/bootxx/bootxx_ustarfs/Makefile diff -u src/sys/arch/i386/stand/bootxx/bootxx_ustarfs/Makefile:1.2 src/sys/arch/i386/stand/bootxx/bootxx_ustarfs/Makefile:1.3 --- src/sys/arch/i386/stand/bootxx/bootxx_ustarfs/Makefile:1.2 Wed Apr 30 16:18:26 2008 +++ src/sys/arch/i386/stand/bootxx/bootxx_ustarfs/Makefile Wed Nov 18 21:02:16 2009 @@ -1,8 +1,7 @@ -# $NetBSD: Makefile,v 1.2 2008/04/30 16:18:26 ad Exp $ +# $NetBSD: Makefile,v 1.3 2009/11/18 21:02:16 dsl Exp $ FS=ustarfs BOOTXX_SECTORS=16 -CPPFLAGS+= -DSHOW_BANNER .include <../Makefile.bootxx>
CVS commit: src/sys/arch/i386/stand/mbr/mbr
Module Name:src Committed By: dsl Date: Wed Nov 18 21:04:12 UTC 2009 Modified Files: src/sys/arch/i386/stand/mbr/mbr: Makefile Log Message: Reinstate the banner. This was added to detect problems when the mbr code gets written into the pbr. (When the code loops reading the pbr!) It is also a useful diagnosting that the boot it proceeding normally. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/arch/i386/stand/mbr/mbr/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/arch/i386/stand/mbr/mbr/Makefile diff -u src/sys/arch/i386/stand/mbr/mbr/Makefile:1.2 src/sys/arch/i386/stand/mbr/mbr/Makefile:1.3 --- src/sys/arch/i386/stand/mbr/mbr/Makefile:1.2 Wed Apr 30 16:18:26 2008 +++ src/sys/arch/i386/stand/mbr/mbr/Makefile Wed Nov 18 21:04:12 2009 @@ -1,6 +1,5 @@ -# $NetBSD: Makefile,v 1.2 2008/04/30 16:18:26 ad Exp $ +# $NetBSD: Makefile,v 1.3 2009/11/18 21:04:12 dsl Exp $ PROG= mbr -CPPFLAGS+= -DNO_BANNER .include <../Makefile.mbr>
CVS commit: src/sys/dev/ic
Module Name:src Committed By: macallan Date: Wed Nov 18 21:59:38 UTC 2009 Modified Files: src/sys/dev/ic: igsfb.c igsfb_subr.c igsfbvar.h Log Message: Make colour depths higher than 8bit work in X. Now igsfb will switch to 16 or 32 bit colour when entering graphics mode, depending on available video memory and the given mode. While there re-initialize the colour map etc. when leaving graphics mode. To generate a diff of this commit: cvs rdiff -u -r1.46 -r1.47 src/sys/dev/ic/igsfb.c cvs rdiff -u -r1.11 -r1.12 src/sys/dev/ic/igsfb_subr.c cvs rdiff -u -r1.18 -r1.19 src/sys/dev/ic/igsfbvar.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/igsfb.c diff -u src/sys/dev/ic/igsfb.c:1.46 src/sys/dev/ic/igsfb.c:1.47 --- src/sys/dev/ic/igsfb.c:1.46 Wed Nov 11 17:01:17 2009 +++ src/sys/dev/ic/igsfb.c Wed Nov 18 21:59:38 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: igsfb.c,v 1.46 2009/11/11 17:01:17 macallan Exp $ */ +/* $NetBSD: igsfb.c,v 1.47 2009/11/18 21:59:38 macallan Exp $ */ /* * Copyright (c) 2002, 2003 Valeriy E. Ushakov @@ -31,7 +31,7 @@ * Integraphics Systems IGA 168x and CyberPro series. */ #include -__KERNEL_RCSID(0, "$NetBSD: igsfb.c,v 1.46 2009/11/11 17:01:17 macallan Exp $"); +__KERNEL_RCSID(0, "$NetBSD: igsfb.c,v 1.47 2009/11/18 21:59:38 macallan Exp $"); #include #include @@ -201,7 +201,8 @@ ? "hardware bswap, " : "software bswap, " : "", dc->dc_width, dc->dc_height, dc->dc_depth); - + printf("%s: using %dbpp for X\n", device_xname(&sc->sc_dev), + dc->dc_maxdepth); ri = &dc->dc_console.scr_ri; ri->ri_ops.eraserows(ri, 0, ri->ri_rows, defattr); @@ -613,13 +614,13 @@ #define wsd_fbip ((struct wsdisplay_fbinfo *)data) wsd_fbip->height = dc->dc_height; wsd_fbip->width = dc->dc_width; - wsd_fbip->depth = dc->dc_depth; + wsd_fbip->depth = dc->dc_maxdepth; wsd_fbip->cmsize = IGS_CMAP_SIZE; #undef wsd_fbip return 0; case WSDISPLAYIO_LINEBYTES: - *(int *)data = dc->dc_stride; + *(int *)data = dc->dc_width * (dc->dc_maxdepth >> 3); return 0; case WSDISPLAYIO_SMODE: @@ -632,8 +633,14 @@ igsfb_update_cursor(dc, WSDISPLAY_CURSOR_DOCUR); } + if ((dc->dc_mode != NULL) && (dc->dc_maxdepth != 8)) +igsfb_set_mode(dc, dc->dc_mode, +dc->dc_maxdepth); } else { dc->dc_mapped = 0; + if ((dc->dc_mode != NULL) && (dc->dc_maxdepth != 8)) +igsfb_set_mode(dc, dc->dc_mode, 8); + igsfb_init_cmap(dc); /* reinit sprite for text cursor */ if (dc->dc_hwflags & IGSFB_HW_TEXT_CURSOR) { igsfb_make_text_cursor(dc, dc->dc_vd.active); @@ -1170,6 +1177,7 @@ int timo = 10; uint8_t reg; + bus_space_write_1(t, h, IGS_COP_MAP_FMT_REG, (dc->dc_depth >> 3) - 1); while (timo--) { reg = bus_space_read_1(t, h, IGS_COP_CTL_REG); if ((reg & IGS_COP_CTL_BUSY) == 0) Index: src/sys/dev/ic/igsfb_subr.c diff -u src/sys/dev/ic/igsfb_subr.c:1.11 src/sys/dev/ic/igsfb_subr.c:1.12 --- src/sys/dev/ic/igsfb_subr.c:1.11 Wed Nov 18 06:10:50 2009 +++ src/sys/dev/ic/igsfb_subr.c Wed Nov 18 21:59:38 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: igsfb_subr.c,v 1.11 2009/11/18 06:10:50 macallan Exp $ */ +/* $NetBSD: igsfb_subr.c,v 1.12 2009/11/18 21:59:38 macallan Exp $ */ /* * Copyright (c) 2002 Valeriy E. Ushakov @@ -32,7 +32,7 @@ * Integraphics Systems IGA 168x and CyberPro series. */ #include -__KERNEL_RCSID(0, "$NetBSD: igsfb_subr.c,v 1.11 2009/11/18 06:10:50 macallan Exp $"); +__KERNEL_RCSID(0, "$NetBSD: igsfb_subr.c,v 1.12 2009/11/18 21:59:38 macallan Exp $"); #include #include @@ -427,7 +427,7 @@ igsfb_hw_setup(struct igsfb_devconfig *dc) { const struct videomode *mode = NULL; - int i; + int i, size, d; igsfb_init_seq(dc); igsfb_init_crtc(dc); @@ -443,20 +443,36 @@ } if (i < videomode_count) { + size = videomode_list[i].hdisplay * videomode_list[i].vdisplay; /* found a mode, now let's see if we can display it */ if ((videomode_list[i].dot_clock <= IGS_MAX_CLOCK) && (videomode_list[i].hdisplay <= 2048) && (videomode_list[i].hdisplay >= 320) && (videomode_list[i].vdisplay <= 2048) && - (videomode_list[i].vdisplay >= 200)) { + (videomode_list[i].vdisplay >= 200) && + (size <= (dc->dc_memsz - 0x1000))) { mode = &videomode_list[i]; + /* + * now let's see which maximum depth we can support + * in that mode + */ + d = (dc->dc_vmemsz - 0x1000) / size; + if (d >= 4) { +dc->dc_maxdepth = 32; + } else if (d >= 2) { +dc->dc_maxdepth = 16; + } else +dc->dc_maxdepth = 8; } } + dc->dc_mode = mode; if (mode != NULL) { igsfb_set_mode(dc, mode, 8); - } else + } else { igsfb_1024x768_8bpp_60Hz(dc); + dc->dc_maxdepth = 8; + } igsfb_video_on(dc); } @@ -470,30 +486,32 @@ int i, m, n, p, hoffset, bytes_per_pixel, memfetch; int vsync_start, hsync_start, vsync_end, hsync_end; int vblank_s
CVS commit: src/sys/arch/macppc/dev
Module Name:src Committed By: dyoung Date: Wed Nov 18 22:51:07 UTC 2009 Modified Files: src/sys/arch/macppc/dev: kauai.c wdc_obio.c Log Message: wdcactivate() is gone, don't use it. To generate a diff of this commit: cvs rdiff -u -r1.26 -r1.27 src/sys/arch/macppc/dev/kauai.c cvs rdiff -u -r1.51 -r1.52 src/sys/arch/macppc/dev/wdc_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/kauai.c diff -u src/sys/arch/macppc/dev/kauai.c:1.26 src/sys/arch/macppc/dev/kauai.c:1.27 --- src/sys/arch/macppc/dev/kauai.c:1.26 Mon Jul 28 16:54:49 2008 +++ src/sys/arch/macppc/dev/kauai.c Wed Nov 18 22:51:07 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: kauai.c,v 1.26 2008/07/28 16:54:49 macallan Exp $ */ +/* $NetBSD: kauai.c,v 1.27 2009/11/18 22:51:07 dyoung Exp $ */ /*- * Copyright (c) 2003 Tsubai Masanari. All rights reserved. @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kauai.c,v 1.26 2008/07/28 16:54:49 macallan Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kauai.c,v 1.27 2009/11/18 22:51:07 dyoung Exp $"); #include #include @@ -82,7 +82,7 @@ static void calc_timing_kauai(struct kauai_softc *, int); CFATTACH_DECL_NEW(kauai, sizeof(struct kauai_softc), -kauai_match, kauai_attach, NULL, wdcactivate); +kauai_match, kauai_attach, NULL, NULL); int kauai_match(device_t parent, cfdata_t match, void *aux) Index: src/sys/arch/macppc/dev/wdc_obio.c diff -u src/sys/arch/macppc/dev/wdc_obio.c:1.51 src/sys/arch/macppc/dev/wdc_obio.c:1.52 --- src/sys/arch/macppc/dev/wdc_obio.c:1.51 Mon Apr 28 20:23:27 2008 +++ src/sys/arch/macppc/dev/wdc_obio.c Wed Nov 18 22:51:07 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: wdc_obio.c,v 1.51 2008/04/28 20:23:27 martin Exp $ */ +/* $NetBSD: wdc_obio.c,v 1.52 2009/11/18 22:51:07 dyoung Exp $ */ /*- * Copyright (c) 1998, 2003 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: wdc_obio.c,v 1.51 2008/04/28 20:23:27 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: wdc_obio.c,v 1.52 2009/11/18 22:51:07 dyoung Exp $"); #include #include @@ -87,7 +87,7 @@ static void ata4_adjust_timing(struct ata_channel *); CFATTACH_DECL_NEW(wdc_obio, sizeof(struct wdc_obio_softc), -wdc_obio_match, wdc_obio_attach, wdc_obio_detach, wdcactivate); +wdc_obio_match, wdc_obio_attach, wdc_obio_detach, NULL); static const char * const ata_names[] = { "heathrow-ata",
CVS commit: src/sys/dev/pci
Module Name:src Committed By: bouyer Date: Wed Nov 18 22:57:38 UTC 2009 Modified Files: src/sys/dev/pci: pcidevs Log Message: Complete BROADCOM BCM5709 family, and add BCM5716 family. To generate a diff of this commit: cvs rdiff -u -r1.1000 -r1.1001 src/sys/dev/pci/pcidevs Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/pcidevs diff -u src/sys/dev/pci/pcidevs:1.1000 src/sys/dev/pci/pcidevs:1.1001 --- src/sys/dev/pci/pcidevs:1.1000 Wed Nov 18 18:42:08 2009 +++ src/sys/dev/pci/pcidevs Wed Nov 18 22:57:38 2009 @@ -1,4 +1,4 @@ -$NetBSD: pcidevs,v 1.1000 2009/11/18 18:42:08 jakllsch Exp $ +$NetBSD: pcidevs,v 1.1001 2009/11/18 22:57:38 bouyer Exp $ /* * Copyright (c) 1995, 1996 Christopher G. Demetriou @@ -1446,6 +1446,9 @@ product BROADCOM BCM5752 0x1600 BCM5752 10/100/1000 Ethernet product BROADCOM BCM5752M 0x1601 BCM5752M 10/100/1000 Ethernet product BROADCOM BCM5709 0x1639 BCM5709 NetXtreme II 1000baseT Ethernet +product BROADCOM BCM5709S 0x163a BCM5709 NetXtreme II 1000baseSX Ethernet +product BROADCOM BCM5716 0x163b BCM5716 NetXtreme II 1000baseT Ethernet +product BROADCOM BCM5716S 0x163c BCM5716 NetXtreme II 1000baseSX Ethernet product BROADCOM BCM5700 0x1644 BCM5700 10/100/1000 Ethernet product BROADCOM BCM5701 0x1645 BCM5701 10/100/1000 Ethernet product BROADCOM BCM5702 0x1646 BCM5702 10/100/1000 Ethernet
CVS commit: src/sys/dev/mii
Module Name:src Committed By: bouyer Date: Wed Nov 18 23:00:46 UTC 2009 Modified Files: src/sys/dev/mii: miidevs Log Message: Add BCM5709CAX and BCM5709C PHYs. To generate a diff of this commit: cvs rdiff -u -r1.89 -r1.90 src/sys/dev/mii/miidevs 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/mii/miidevs diff -u src/sys/dev/mii/miidevs:1.89 src/sys/dev/mii/miidevs:1.90 --- src/sys/dev/mii/miidevs:1.89 Wed Aug 12 13:33:02 2009 +++ src/sys/dev/mii/miidevs Wed Nov 18 23:00:46 2009 @@ -1,4 +1,4 @@ -$NetBSD: miidevs,v 1.89 2009/08/12 13:33:02 simonb Exp $ +$NetBSD: miidevs,v 1.90 2009/11/18 23:00:46 bouyer Exp $ /*- * Copyright (c) 1998, 1999 The NetBSD Foundation, Inc. @@ -164,7 +164,9 @@ model BROADCOM2 BCM5906 0x0004 BCM5906 10/100baseTX media interface model BROADCOM2 BCM5755 0x000c BCM5755 1000BASE-T media interface model BROADCOM2 BCM5754 0x000e BCM5754/5787 1000BASE-T media interface +model BROADCOM2 BCM5709CAX 0x002c BCM5709CAX 10/100/1000baseT PHY model BROADCOM2 BCM5722 0x002d BCM5722 1000BASE-T media interface +model BROADCOM2 BCM5709C 0x003c BCM5709 10/100/1000baseT PHY model xxBROADCOM_ALT1 BCM5906 0x0004 BCM5906 10/100baseTX media interface /* Cicada Semiconductor PHYs (now owned by Vitesse?) */
CVS commit: src/sys/dev/mii
Module Name:src Committed By: bouyer Date: Wed Nov 18 23:01:47 UTC 2009 Modified Files: src/sys/dev/mii: miidevs.h miidevs_data.h Log Message: Regen: Add BCM5709CAX and BCM5709C PHYs. To generate a diff of this commit: cvs rdiff -u -r1.91 -r1.92 src/sys/dev/mii/miidevs.h cvs rdiff -u -r1.81 -r1.82 src/sys/dev/mii/miidevs_data.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/mii/miidevs.h diff -u src/sys/dev/mii/miidevs.h:1.91 src/sys/dev/mii/miidevs.h:1.92 --- src/sys/dev/mii/miidevs.h:1.91 Wed Aug 12 13:33:42 2009 +++ src/sys/dev/mii/miidevs.h Wed Nov 18 23:01:47 2009 @@ -1,10 +1,10 @@ -/* $NetBSD: miidevs.h,v 1.91 2009/08/12 13:33:42 simonb Exp $ */ +/* $NetBSD: miidevs.h,v 1.92 2009/11/18 23:01:47 bouyer Exp $ */ /* * THIS FILE AUTOMATICALLY GENERATED. DO NOT EDIT. * * generated from: - * NetBSD: miidevs,v 1.89 2009/08/12 13:33:02 simonb Exp + * NetBSD: miidevs,v 1.90 2009/11/18 23:00:46 bouyer Exp */ /*- @@ -211,8 +211,12 @@ #define MII_STR_BROADCOM2_BCM5755 "BCM5755 1000BASE-T media interface" #define MII_MODEL_BROADCOM2_BCM5754 0x000e #define MII_STR_BROADCOM2_BCM5754 "BCM5754/5787 1000BASE-T media interface" +#define MII_MODEL_BROADCOM2_BCM5709CAX 0x002c +#define MII_STR_BROADCOM2_BCM5709CAX "BCM5709CAX 10/100/1000baseT PHY" #define MII_MODEL_BROADCOM2_BCM5722 0x002d #define MII_STR_BROADCOM2_BCM5722 "BCM5722 1000BASE-T media interface" +#define MII_MODEL_BROADCOM2_BCM5709C 0x003c +#define MII_STR_BROADCOM2_BCM5709C "BCM5709 10/100/1000baseT PHY" #define MII_MODEL_xxBROADCOM_ALT1_BCM5906 0x0004 #define MII_STR_xxBROADCOM_ALT1_BCM5906 "BCM5906 10/100baseTX media interface" Index: src/sys/dev/mii/miidevs_data.h diff -u src/sys/dev/mii/miidevs_data.h:1.81 src/sys/dev/mii/miidevs_data.h:1.82 --- src/sys/dev/mii/miidevs_data.h:1.81 Wed Aug 12 13:33:42 2009 +++ src/sys/dev/mii/miidevs_data.h Wed Nov 18 23:01:47 2009 @@ -1,10 +1,10 @@ -/* $NetBSD: miidevs_data.h,v 1.81 2009/08/12 13:33:42 simonb Exp $ */ +/* $NetBSD: miidevs_data.h,v 1.82 2009/11/18 23:01:47 bouyer Exp $ */ /* * THIS FILE AUTOMATICALLY GENERATED. DO NOT EDIT. * * generated from: - * NetBSD: miidevs,v 1.89 2009/08/12 13:33:02 simonb Exp + * NetBSD: miidevs,v 1.90 2009/11/18 23:00:46 bouyer Exp */ /*- @@ -77,7 +77,9 @@ { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5906, MII_STR_BROADCOM2_BCM5906 }, { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5755, MII_STR_BROADCOM2_BCM5755 }, { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5754, MII_STR_BROADCOM2_BCM5754 }, + { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5709CAX, MII_STR_BROADCOM2_BCM5709CAX }, { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5722, MII_STR_BROADCOM2_BCM5722 }, + { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5709C, MII_STR_BROADCOM2_BCM5709C }, { MII_OUI_xxBROADCOM_ALT1, MII_MODEL_xxBROADCOM_ALT1_BCM5906, MII_STR_xxBROADCOM_ALT1_BCM5906 }, { MII_OUI_CICADA, MII_MODEL_CICADA_CS8201, MII_STR_CICADA_CS8201 }, { MII_OUI_CICADA, MII_MODEL_CICADA_CS8204, MII_STR_CICADA_CS8204 },
CVS commit: src/sys/dev/mii
Module Name:src Committed By: bouyer Date: Wed Nov 18 23:02:13 UTC 2009 Modified Files: src/sys/dev/mii: brgphy.c Log Message: Support BCM5709CAX and BCM5709C PHYs. To generate a diff of this commit: cvs rdiff -u -r1.50 -r1.51 src/sys/dev/mii/brgphy.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/mii/brgphy.c diff -u src/sys/dev/mii/brgphy.c:1.50 src/sys/dev/mii/brgphy.c:1.51 --- src/sys/dev/mii/brgphy.c:1.50 Mon Oct 19 18:41:13 2009 +++ src/sys/dev/mii/brgphy.c Wed Nov 18 23:02:12 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: brgphy.c,v 1.50 2009/10/19 18:41:13 bouyer Exp $ */ +/* $NetBSD: brgphy.c,v 1.51 2009/11/18 23:02:12 bouyer Exp $ */ /*- * Copyright (c) 1998, 1999, 2000, 2001 The NetBSD Foundation, Inc. @@ -62,7 +62,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: brgphy.c,v 1.50 2009/10/19 18:41:13 bouyer Exp $"); +__KERNEL_RCSID(0, "$NetBSD: brgphy.c,v 1.51 2009/11/18 23:02:12 bouyer Exp $"); #include #include @@ -168,6 +168,12 @@ { MII_OUI_BROADCOM, MII_MODEL_BROADCOM_BCM5708C, MII_STR_BROADCOM_BCM5708C }, + { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5709C, + MII_STR_BROADCOM2_BCM5709C }, + + { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5709CAX, + MII_STR_BROADCOM2_BCM5709CAX }, + { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5722, MII_STR_BROADCOM2_BCM5722 }, @@ -303,8 +309,8 @@ } PHY_WRITE(sc, MII_100T2CR, 0); - PHY_WRITE(sc, MII_BMCR, speed); PHY_WRITE(sc, MII_ANAR, ANAR_CSMA); + PHY_WRITE(sc, MII_BMCR, speed); if (IFM_SUBTYPE(ife->ifm_media) != IFM_1000_T) break;
CVS commit: src/doc
Module Name:src Committed By: bouyer Date: Wed Nov 18 23:13:09 UTC 2009 Modified Files: src/doc: CHANGES Log Message: bnx(4): Added support for Broadcom BCM5709 and BCM5716 chips. To generate a diff of this commit: cvs rdiff -u -r1.1317 -r1.1318 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.1317 src/doc/CHANGES:1.1318 --- src/doc/CHANGES:1.1317 Tue Nov 17 19:19:21 2009 +++ src/doc/CHANGES Wed Nov 18 23:13:09 2009 @@ -1,4 +1,4 @@ -# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.1317 $> +# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.1318 $> # # # [Note: This file does not mention every change made to the NetBSD source tree. @@ -440,3 +440,5 @@ raid(4): RAIDframe parity maps, which greatly improve parity rewrite times after unclean shutdown; jld's GSoC 2009 project. [jld 20091117] + bnx(4): Added support for Broadcom BCM5709 and BCM5716 chips. + [bouyer 20091118]
CVS commit: src/usr.bin/make
Module Name:src Committed By: sjg Date: Thu Nov 19 00:30:25 UTC 2009 Modified Files: src/usr.bin/make: make.1 nonints.h parse.c var.c src/usr.bin/make/unit-tests: Makefile test.exp Added Files: src/usr.bin/make/unit-tests: unexport unexport-env Log Message: PR: make.unexport Reviewed by: To generate a diff of this commit: cvs rdiff -u -r1.164 -r1.165 src/usr.bin/make/make.1 cvs rdiff -u -r1.56 -r1.57 src/usr.bin/make/nonints.h cvs rdiff -u -r1.159 -r1.160 src/usr.bin/make/parse.c cvs rdiff -u -r1.154 -r1.155 src/usr.bin/make/var.c cvs rdiff -u -r1.24 -r1.25 src/usr.bin/make/unit-tests/Makefile cvs rdiff -u -r1.29 -r1.30 src/usr.bin/make/unit-tests/test.exp cvs rdiff -u -r0 -r1.1 src/usr.bin/make/unit-tests/unexport \ src/usr.bin/make/unit-tests/unexport-env 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/make/make.1 diff -u src/usr.bin/make/make.1:1.164 src/usr.bin/make/make.1:1.165 --- src/usr.bin/make/make.1:1.164 Thu Oct 15 02:27:44 2009 +++ src/usr.bin/make/make.1 Thu Nov 19 00:30:24 2009 @@ -1,4 +1,4 @@ -.\" $NetBSD: make.1,v 1.164 2009/10/15 02:27:44 joerg Exp $ +.\" $NetBSD: make.1,v 1.165 2009/11/19 00:30:24 sjg Exp $ .\" .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. @@ -29,7 +29,7 @@ .\" .\" from: @(#)make.1 8.4 (Berkeley) 3/19/94 .\" -.Dd October 1, 2009 +.Dd November 15, 2009 .Dt MAKE 1 .Os .Sh NAME @@ -1274,17 +1274,53 @@ character of a line. The possible conditionals are as follows: .Bl -tag -width Ds -.It Ic .export Ar variable +.It Ic .export Ar variable ... Export the specified global variable. -If no variable is provided, all globals are exported +If no variable list is provided, all globals are exported except for internal variables (those that start with .Ql \&. ) . This is not affected by the .Fl X flag, so should be used with caution. +.Pp Appending a variable name to .Va .MAKE.EXPORTED is equivalent to exporting a variable. +.It Ic .unexport Ar variable ... +The opposite of +.Ql .export . +The specified global +.Va variable +will be removed from +.Va .MAKE.EXPORTED . +If no variable list is provided, all globals are unexported, +and +.Va .MAKE.EXPORTED +deleted. +.It Ic .unexport-env +Unexport all globals previously exported and +clear the environment inherited from the parent. +This operation will cause a memory leak of the original environment, +so should be used sparingly. Testing for +.Va .MAKE.LEVEL +being 0, would make sense. +Also note that any variables which originated in the parent environment +should be explicitly preserved if desired. +For example: +.Bd -literal -offset indent +.Li .if ${.MAKE.LEVEL} == 0 +PATH := ${PATH} +.Li .unexport-env +.Li .export PATH +.Li .endif +.Pp +.Ed +Would result in an environment containing only +.Ql Ev PATH , +which is the minimal useful environment. +Actually +.Ql Ev .MAKE.LEVEL +will also be pushed into the new environment. .It Ic .undef Ar variable Un-define the specified global variable. Only global variables may be un-defined. Index: src/usr.bin/make/nonints.h diff -u src/usr.bin/make/nonints.h:1.56 src/usr.bin/make/nonints.h:1.57 --- src/usr.bin/make/nonints.h:1.56 Wed Jan 28 21:38:13 2009 +++ src/usr.bin/make/nonints.h Thu Nov 19 00:30:24 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: nonints.h,v 1.56 2009/01/28 21:38:13 dsl Exp $ */ +/* $NetBSD: nonints.h,v 1.57 2009/11/19 00:30:24 sjg Exp $ */ /*- * Copyright (c) 1988, 1989, 1990, 1993 @@ -193,3 +193,4 @@ void Var_Dump(GNode *); void Var_ExportVars(void); void Var_Export(char *, int); +void Var_UnExport(char *); Index: src/usr.bin/make/parse.c diff -u src/usr.bin/make/parse.c:1.159 src/usr.bin/make/parse.c:1.160 --- src/usr.bin/make/parse.c:1.159 Fri Nov 6 20:20:56 2009 +++ src/usr.bin/make/parse.c Thu Nov 19 00:30:25 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: parse.c,v 1.159 2009/11/06 20:20:56 dsl Exp $ */ +/* $NetBSD: parse.c,v 1.160 2009/11/19 00:30:25 sjg Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1993 @@ -69,14 +69,14 @@ */ #ifndef MAKE_NATIVE -static char rcsid[] = "$NetBSD: parse.c,v 1.159 2009/11/06 20:20:56 dsl Exp $"; +static char rcsid[] = "$NetBSD: parse.c,v 1.160 2009/11/19 00:30:25 sjg Exp $"; #else #include #ifndef lint #if 0 static char sccsid[] = "@(#)parse.c 8.3 (Berkeley) 3/19/94"; #else -__RCSID("$NetBSD: parse.c,v 1.159 2009/11/06 20:20:56 dsl Exp $"); +__RCSID("$NetBSD: parse.c,v 1.160 2009/11/19 00:30:25 sjg Exp $"); #endif #endif /* not lint */ #endif @@ -2510,6 +2510,9 @@ continue; Var_Export(cp, 1); continue; + } else if (strncmp(cp, "unexport", 8) == 0) { + Var_UnExport(cp); + continue; } } Index: src/usr.bin/make/var.c diff -u src/usr.bin/make/var.c:1.154 src/usr.bin/make/var.c:1.155 --- src/usr.bin/make/var.c:1.154 Tue Sep 8 17:29:20 2009 +++ src/usr.bin/make/var.c Th
CVS commit: src/usr.sbin/pstat
Module Name:src Committed By: enami Date: Thu Nov 19 02:52:54 UTC 2009 Modified Files: src/usr.sbin/pstat: pstat.c Log Message: Prevent sign extension when reading device number in ufs1 on disk inode so that devname(3) correctly converts it to device filename. To generate a diff of this commit: cvs rdiff -u -r1.115 -r1.116 src/usr.sbin/pstat/pstat.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/pstat/pstat.c diff -u src/usr.sbin/pstat/pstat.c:1.115 src/usr.sbin/pstat/pstat.c:1.116 --- src/usr.sbin/pstat/pstat.c:1.115 Wed Sep 16 07:27:41 2009 +++ src/usr.sbin/pstat/pstat.c Thu Nov 19 02:52:54 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: pstat.c,v 1.115 2009/09/16 07:27:41 mlelstv Exp $ */ +/* $NetBSD: pstat.c,v 1.116 2009/11/19 02:52:54 enami Exp $ */ /*- * Copyright (c) 1980, 1991, 1993, 1994 @@ -39,7 +39,7 @@ #if 0 static char sccsid[] = "@(#)pstat.c 8.16 (Berkeley) 5/9/95"; #else -__RCSID("$NetBSD: pstat.c,v 1.115 2009/09/16 07:27:41 mlelstv Exp $"); +__RCSID("$NetBSD: pstat.c,v 1.116 2009/11/19 02:52:54 enami Exp $"); #endif #endif /* not lint */ @@ -491,7 +491,7 @@ if (ump.um_fstype == UFS1) { KGETRET(ip->i_din.ffs1_din, &dip, sizeof (struct ufs1_dinode), "inode's dinode"); - rdev = dip.dp1.di_rdev; + rdev = (uint32_t)dip.dp1.di_rdev; } else { KGETRET(ip->i_din.ffs2_din, &dip, sizeof (struct ufs2_dinode), "inode's UFS2 dinode");
CVS commit: src/sys/kern
Module Name:src Committed By: enami Date: Thu Nov 19 02:59:34 UTC 2009 Modified Files: src/sys/kern: vfs_subr.c Log Message: Add missing vfs_unbusy() call in error path of sysctl_kern_vnode(). This allows us to reboot machine successfully even if pstat -v fails once. To generate a diff of this commit: cvs rdiff -u -r1.387 -r1.388 src/sys/kern/vfs_subr.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/kern/vfs_subr.c diff -u src/sys/kern/vfs_subr.c:1.387 src/sys/kern/vfs_subr.c:1.388 --- src/sys/kern/vfs_subr.c:1.387 Tue Nov 17 22:20:14 2009 +++ src/sys/kern/vfs_subr.c Thu Nov 19 02:59:33 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_subr.c,v 1.387 2009/11/17 22:20:14 bouyer Exp $ */ +/* $NetBSD: vfs_subr.c,v 1.388 2009/11/19 02:59:33 enami Exp $ */ /*- * Copyright (c) 1997, 1998, 2004, 2005, 2007, 2008 The NetBSD Foundation, Inc. @@ -91,7 +91,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: vfs_subr.c,v 1.387 2009/11/17 22:20:14 bouyer Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_subr.c,v 1.388 2009/11/19 02:59:33 enami Exp $"); #include "opt_ddb.h" #include "opt_compat_netbsd.h" @@ -2208,6 +2208,7 @@ (void)vunmark(mvp); mutex_exit(&mntvnode_lock); vnfree(mvp); +vfs_unbusy(mp, false, NULL); sysctl_relock(); *sizep = bp - where; return (ENOMEM); @@ -2220,6 +2221,7 @@ (void)vunmark(mvp); mutex_exit(&mntvnode_lock); vnfree(mvp); +vfs_unbusy(mp, false, NULL); sysctl_relock(); return (error); }
CVS commit: src/sys/kern
Module Name:src Committed By: enami Date: Thu Nov 19 03:01:06 UTC 2009 Modified Files: src/sys/kern: vfs_subr.c Log Message: Fix indentation, wrap long line and remove unused variable. To generate a diff of this commit: cvs rdiff -u -r1.388 -r1.389 src/sys/kern/vfs_subr.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/kern/vfs_subr.c diff -u src/sys/kern/vfs_subr.c:1.388 src/sys/kern/vfs_subr.c:1.389 --- src/sys/kern/vfs_subr.c:1.388 Thu Nov 19 02:59:33 2009 +++ src/sys/kern/vfs_subr.c Thu Nov 19 03:01:05 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_subr.c,v 1.388 2009/11/19 02:59:33 enami Exp $ */ +/* $NetBSD: vfs_subr.c,v 1.389 2009/11/19 03:01:05 enami Exp $ */ /*- * Copyright (c) 1997, 1998, 2004, 2005, 2007, 2008 The NetBSD Foundation, Inc. @@ -91,7 +91,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: vfs_subr.c,v 1.388 2009/11/19 02:59:33 enami Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_subr.c,v 1.389 2009/11/19 03:01:05 enami Exp $"); #include "opt_ddb.h" #include "opt_compat_netbsd.h" @@ -2165,7 +2165,7 @@ size_t *sizep = oldlenp; struct mount *mp, *nmp; vnode_t *vp, *mvp, vbuf; - char *bp = where, *savebp; + char *bp = where; char *ewhere; int error; @@ -2185,17 +2185,17 @@ sysctl_unlock(); mutex_enter(&mountlist_lock); for (mp = CIRCLEQ_FIRST(&mountlist); mp != (void *)&mountlist; - mp = nmp) { + mp = nmp) { if (vfs_busy(mp, &nmp)) { continue; } - savebp = bp; /* Allocate a marker vnode. */ mvp = vnalloc(mp); /* Should never fail for mp != NULL */ KASSERT(mvp != NULL); mutex_enter(&mntvnode_lock); - for (vp = TAILQ_FIRST(&mp->mnt_vnodelist); vp; vp = vunmark(mvp)) { + for (vp = TAILQ_FIRST(&mp->mnt_vnodelist); vp; + vp = vunmark(mvp)) { vmark(mvp, vp); /* * Check that the vp is still associated with @@ -2216,7 +2216,7 @@ memcpy(&vbuf, vp, VNODESZ); mutex_exit(&mntvnode_lock); if ((error = copyout(&vp, bp, VPTRSZ)) || - (error = copyout(&vbuf, bp + VPTRSZ, VNODESZ))) { + (error = copyout(&vbuf, bp + VPTRSZ, VNODESZ))) { mutex_enter(&mntvnode_lock); (void)vunmark(mvp); mutex_exit(&mntvnode_lock);
CVS commit: src/usr.bin/make
Module Name:src Committed By: wiz Date: Thu Nov 19 06:48:38 UTC 2009 Modified Files: src/usr.bin/make: make.1 Log Message: New sentence, new line; remove trailing whitespace. To generate a diff of this commit: cvs rdiff -u -r1.165 -r1.166 src/usr.bin/make/make.1 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/make/make.1 diff -u src/usr.bin/make/make.1:1.165 src/usr.bin/make/make.1:1.166 --- src/usr.bin/make/make.1:1.165 Thu Nov 19 00:30:24 2009 +++ src/usr.bin/make/make.1 Thu Nov 19 06:48:37 2009 @@ -1,4 +1,4 @@ -.\" $NetBSD: make.1,v 1.165 2009/11/19 00:30:24 sjg Exp $ +.\" $NetBSD: make.1,v 1.166 2009/11/19 06:48:37 wiz Exp $ .\" .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. @@ -1290,21 +1290,22 @@ The opposite of .Ql .export . The specified global -.Va variable -will be removed from +.Va variable +will be removed from .Va .MAKE.EXPORTED . If no variable list is provided, all globals are unexported, and -.Va .MAKE.EXPORTED +.Va .MAKE.EXPORTED deleted. .It Ic .unexport-env Unexport all globals previously exported and clear the environment inherited from the parent. -This operation will cause a memory leak of the original environment, -so should be used sparingly. Testing for +This operation will cause a memory leak of the original environment, +so should be used sparingly. +Testing for .Va .MAKE.LEVEL being 0, would make sense. -Also note that any variables which originated in the parent environment +Also note that any variables which originated in the parent environment should be explicitly preserved if desired. For example: .Bd -literal -offset indent @@ -1315,11 +1316,11 @@ .Li .endif .Pp .Ed -Would result in an environment containing only +Would result in an environment containing only .Ql Ev PATH , which is the minimal useful environment. Actually -.Ql Ev .MAKE.LEVEL +.Ql Ev .MAKE.LEVEL will also be pushed into the new environment. .It Ic .undef Ar variable Un-define the specified global variable.