From owner-p4-projects@FreeBSD.ORG Sun May 1 02:40:06 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2D12216A4D0; Sun, 1 May 2005 02:40:06 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EF35216A4CE for ; Sun, 1 May 2005 02:40:05 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9176943D53 for ; Sun, 1 May 2005 02:40:05 +0000 (GMT) (envelope-from peter@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j412e5iJ011931 for ; Sun, 1 May 2005 02:40:05 GMT (envelope-from peter@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j412e5Cq011928 for perforce@freebsd.org; Sun, 1 May 2005 02:40:05 GMT (envelope-from peter@freebsd.org) Date: Sun, 1 May 2005 02:40:05 GMT Message-Id: <200505010240.j412e5Cq011928@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to peter@freebsd.org using -f From: Peter Wemm To: Perforce Change Reviews Subject: PERFORCE change 76312 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 02:40:07 -0000 http://perforce.freebsd.org/chv.cgi?CH=76312 Change 76312 by peter@peter_daintree on 2005/05/01 02:40:00 IFC @76311 Affected files ... .. //depot/projects/hammer/lib/libthr/Makefile#10 integrate .. //depot/projects/hammer/lib/libthr/arch/i386/i386/pthread_md.c#4 integrate .. //depot/projects/hammer/lib/libthr/arch/i386/include/pthread_md.h#3 integrate .. //depot/projects/hammer/lib/libthr/support/Makefile.inc#1 branch .. //depot/projects/hammer/lib/libthr/thread/thr_create.c#16 integrate Differences ... ==== //depot/projects/hammer/lib/libthr/Makefile#10 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/lib/libthr/Makefile,v 1.11 2005/04/12 03:00:28 davidxu Exp $ +# $FreeBSD: src/lib/libthr/Makefile,v 1.12 2005/04/23 02:48:58 davidxu Exp $ # # All library objects contain FreeBSD revision strings by default; they may be # excluded as a space-saving measure. To produce a library that does @@ -30,6 +30,7 @@ PRECIOUSLIB= .include "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" +.include "${.CURDIR}/support/Makefile.inc" .include "${.CURDIR}/sys/Makefile.inc" .include "${.CURDIR}/thread/Makefile.inc" ==== //depot/projects/hammer/lib/libthr/arch/i386/i386/pthread_md.c#4 (text+ko) ==== @@ -24,7 +24,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libthr/arch/i386/i386/pthread_md.c,v 1.3 2005/04/23 02:14:38 davidxu Exp $ + * $FreeBSD: src/lib/libthr/arch/i386/i386/pthread_md.c,v 1.5 2005/04/23 03:34:43 davidxu Exp $ */ #include @@ -35,18 +35,11 @@ #include "pthread_md.h" -int _thr_using_setbase; - struct tcb * _tcb_ctor(struct pthread *thread, int initial) { -#ifndef COMPAT_32BIT - union descriptor ldt; - void *base; -#endif struct tcb *tcb; void *oldtls; - int error; if (initial) __asm __volatile("movl %%gs:0, %0" : "=r" (oldtls)); @@ -54,51 +47,15 @@ oldtls = NULL; tcb = _rtld_allocate_tls(oldtls, sizeof(struct tcb), 16); - if (tcb) { + if (tcb) tcb->tcb_thread = thread; -#ifndef COMPAT_32BIT - tcb->tcb_ldt = -1; - switch (_thr_using_setbase) { - case 1: /* use i386_set_gsbase() in _kcb_set */ - break; - case 0: /* Untested, try the get/set_gsbase routines once */ - error = i386_get_gsbase(&base); - if (error == 0) { - _thr_using_setbase = 1; - break; - } - /* fall through */ - case 2: /* Use the user_ldt code, we must have an old kernel */ - _thr_using_setbase = 2; - ldt.sd.sd_hibase = (unsigned int)tcb >> 24; - ldt.sd.sd_lobase = (unsigned int)tcb & 0xFFFFFF; - ldt.sd.sd_hilimit = (sizeof(struct tcb) >> 16) & 0xF; - ldt.sd.sd_lolimit = sizeof(struct tcb) & 0xFFFF; - ldt.sd.sd_type = SDT_MEMRWA; - ldt.sd.sd_dpl = SEL_UPL; - ldt.sd.sd_p = 1; - ldt.sd.sd_xx = 0; - ldt.sd.sd_def32 = 1; - ldt.sd.sd_gran = 0; /* no more than 1M */ - tcb->tcb_ldt = i386_set_ldt(LDT_AUTO_ALLOC, &ldt, 1); - if (tcb->tcb_ldt < 0) { - _rtld_free_tls(tcb, sizeof(struct tcb), 16); - tcb = NULL; - } - break; - } -#endif - } return (tcb); } void _tcb_dtor(struct tcb *tcb) { -#ifndef COMPAT_32BIT - if (tcb->tcb_ldt >= 0) - i386_set_ldt(tcb->tcb_ldt, NULL, 1); -#endif + _rtld_free_tls(tcb, sizeof(struct tcb), 16); } ==== //depot/projects/hammer/lib/libthr/arch/i386/include/pthread_md.h#3 (text+ko) ==== @@ -24,7 +24,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libthr/arch/i386/include/pthread_md.h,v 1.2 2005/04/14 00:44:07 peter Exp $ + * $FreeBSD: src/lib/libthr/arch/i386/include/pthread_md.h,v 1.4 2005/04/27 01:29:03 davidxu Exp $ */ /* @@ -49,7 +49,6 @@ struct tcb *tcb_self; /* required by rtld */ void *tcb_dtv; /* required by rtld */ struct pthread *tcb_thread; - int tcb_ldt; }; /* @@ -87,19 +86,7 @@ static __inline void _tcb_set(struct tcb *tcb) { -#ifndef COMPAT_32BIT - int val; - - if (_thr_using_setbase == 1) { - i386_set_gsbase(tcb); - } else { - val = (tcb->tcb_ldt << 3) | 7; - __asm __volatile("movl %0, %%gs" : : "r" (val)); - } -#else - _amd64_set_gsbase(tcb); -#endif - + i386_set_gsbase(tcb); } /* Get the current kcb. */ ==== //depot/projects/hammer/lib/libthr/thread/thr_create.c#16 (text+ko) ==== @@ -30,7 +30,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libthr/thread/thr_create.c,v 1.21 2005/04/12 03:00:28 davidxu Exp $ + * $FreeBSD: src/lib/libthr/thread/thr_create.c,v 1.22 2005/04/23 02:48:59 davidxu Exp $ */ #include @@ -53,9 +53,8 @@ _pthread_create(pthread_t * thread, const pthread_attr_t * attr, void *(*start_routine) (void *), void *arg) { - ucontext_t uc; - sigset_t sigmask, oldsigmask; struct pthread *curthread, *new_thread; + struct thr_param param; int ret = 0, locked; _thr_check_init(); @@ -70,6 +69,8 @@ if ((new_thread = _thr_alloc(curthread)) == NULL) return (EAGAIN); + memset(¶m, 0, sizeof(param)); + if (attr == NULL || *attr == NULL) /* Use the default thread attributes: */ new_thread->attr = _pthread_attr_default; @@ -108,12 +109,6 @@ new_thread->arg = arg; new_thread->cancelflags = PTHREAD_CANCEL_ENABLE | PTHREAD_CANCEL_DEFERRED; - getcontext(&uc); - SIGFILLSET(uc.uc_sigmask); - uc.uc_stack.ss_sp = new_thread->attr.stackaddr_attr; - uc.uc_stack.ss_size = new_thread->attr.stacksize_attr; - makecontext(&uc, (void (*)(void))thread_start, 1, new_thread); - /* * Check if this thread is to inherit the scheduling * attributes from its parent: @@ -146,15 +141,7 @@ if (new_thread->attr.suspend == THR_CREATE_SUSPENDED) new_thread->flags = THR_FLAGS_SUSPENDED; new_thread->state = PS_RUNNING; - /* - * Thread created by thr_create() inherits currrent thread - * sigmask, however, before new thread setup itself correctly, - * it can not handle signal, so we should masks all signals here. - */ - SIGFILLSET(sigmask); - SIGDELSET(sigmask, SIGTRAP); - __sys_sigprocmask(SIG_SETMASK, &sigmask, &oldsigmask); - new_thread->sigmask = oldsigmask; + /* Add the new thread. */ _thr_link(curthread, new_thread); /* Return thread pointer eariler so that new thread can use it. */ @@ -164,9 +151,19 @@ locked = 1; } else locked = 0; + param.start_func = (void (*)(void *)) thread_start; + param.arg = new_thread; + param.stack_base = new_thread->attr.stackaddr_attr; + param.stack_size = new_thread->attr.stacksize_attr; + param.tls_base = (char *)new_thread->tcb; + param.tls_size = sizeof(struct tcb); + param.child_tid = &new_thread->tid; + param.parent_tid = &new_thread->tid; + param.flags = 0; + if (new_thread->attr.flags & PTHREAD_SCOPE_SYSTEM) + param.flags |= THR_SYSTEM_SCOPE; /* Schedule the new thread. */ - ret = thr_create(&uc, &new_thread->tid, 0); - __sys_sigprocmask(SIG_SETMASK, &oldsigmask, NULL); + ret = thr_new(¶m, sizeof(param)); if (ret != 0) { if (locked) THR_THREAD_UNLOCK(curthread, new_thread); @@ -219,11 +216,6 @@ static void thread_start(struct pthread *curthread) { - _tcb_set(curthread->tcb); - - /* Thread was created with all signals blocked, unblock them. */ - __sys_sigprocmask(SIG_SETMASK, &curthread->sigmask, NULL); - if (curthread->flags & THR_FLAGS_NEED_SUSPEND) _thr_suspend_check(curthread); From owner-p4-projects@FreeBSD.ORG Sun May 1 02:58:29 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9F73716A4D0; Sun, 1 May 2005 02:58:28 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7B5AF16A4CE for ; Sun, 1 May 2005 02:58:28 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 36B4943D55 for ; Sun, 1 May 2005 02:58:28 +0000 (GMT) (envelope-from peter@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j412wSna012476 for ; Sun, 1 May 2005 02:58:28 GMT (envelope-from peter@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j412wR1k012473 for perforce@freebsd.org; Sun, 1 May 2005 02:58:27 GMT (envelope-from peter@freebsd.org) Date: Sun, 1 May 2005 02:58:27 GMT Message-Id: <200505010258.j412wR1k012473@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to peter@freebsd.org using -f From: Peter Wemm To: Perforce Change Reviews Subject: PERFORCE change 76313 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 02:58:29 -0000 http://perforce.freebsd.org/chv.cgi?CH=76313 Change 76313 by peter@peter_daintree on 2005/05/01 02:57:43 Integ -b i386_hammer Affected files ... .. //depot/projects/hammer/sys/amd64/amd64/local_apic.c#49 integrate .. //depot/projects/hammer/sys/amd64/amd64/mp_machdep.c#91 integrate .. //depot/projects/hammer/sys/amd64/amd64/support.S#28 integrate .. //depot/projects/hammer/sys/amd64/amd64/sys_machdep.c#21 integrate .. //depot/projects/hammer/sys/amd64/amd64/trap.c#59 integrate .. //depot/projects/hammer/sys/amd64/amd64/vm_machdep.c#71 integrate .. //depot/projects/hammer/sys/amd64/conf/NOTES#66 integrate .. //depot/projects/hammer/sys/amd64/include/bus.h#11 integrate .. //depot/projects/hammer/sys/amd64/include/smp.h#25 integrate Differences ... ==== //depot/projects/hammer/sys/amd64/amd64/local_apic.c#49 (text+ko) ==== @@ -109,7 +109,7 @@ { 1, 1, 0, 1, APIC_LVT_DM_NMI, 0 }, /* LINT1: NMI */ { 1, 1, 1, 1, APIC_LVT_DM_FIXED, APIC_TIMER_INT }, /* Timer */ { 1, 1, 1, 1, APIC_LVT_DM_FIXED, APIC_ERROR_INT }, /* Error */ - { 1, 1, 1, 1, APIC_LVT_DM_FIXED, 0 }, /* PMC */ + { 1, 1, 0, 1, APIC_LVT_DM_NMI, 0 }, /* PMC */ { 1, 1, 1, 1, APIC_LVT_DM_FIXED, APIC_THERMAL_INT }, /* Thermal */ }; @@ -302,6 +302,11 @@ /* Program LINT[01] LVT entries. */ lapic->lvt_lint0 = lvt_mode(la, LVT_LINT0, lapic->lvt_lint0); lapic->lvt_lint1 = lvt_mode(la, LVT_LINT1, lapic->lvt_lint1); +#ifdef HWPMC_HOOKS + /* Program the PMC LVT entry if present. */ + if (maxlvt >= LVT_PMC) + lapic->lvt_pcint = lvt_mode(la, LVT_PMC, lapic->lvt_pcint); +#endif /* Program timer LVT and setup handler. */ lapic->lvt_timer = lvt_mode(la, LVT_TIMER, lapic->lvt_timer); ==== //depot/projects/hammer/sys/amd64/amd64/mp_machdep.c#91 (text+ko) ==== ==== //depot/projects/hammer/sys/amd64/amd64/support.S#28 (text+ko) ==== ==== //depot/projects/hammer/sys/amd64/amd64/sys_machdep.c#21 (text+ko) ==== ==== //depot/projects/hammer/sys/amd64/amd64/trap.c#59 (text+ko) ==== ==== //depot/projects/hammer/sys/amd64/amd64/vm_machdep.c#71 (text+ko) ==== ==== //depot/projects/hammer/sys/amd64/conf/NOTES#66 (text+ko) ==== @@ -4,7 +4,7 @@ # This file contains machine dependent kernel configuration notes. For # machine independent notes, look in /sys/conf/NOTES. # -# (XXX from i386:NOTES,v 1.1193) +# (XXX from i386:NOTES,v 1.1198) # $FreeBSD: src/sys/amd64/conf/NOTES,v 1.34 2005/04/30 20:00:58 dwhite Exp $ # ==== //depot/projects/hammer/sys/amd64/include/bus.h#11 (text+ko) ==== @@ -122,9 +122,6 @@ #define AMD64_BUS_SPACE_IO 0 /* space is i/o space */ #define AMD64_BUS_SPACE_MEM 1 /* space is mem space */ -/* - * Bus address and size types - */ #define BUS_SPACE_MAXSIZE_24BIT 0xFFFFFF #define BUS_SPACE_MAXSIZE_32BIT 0xFFFFFFFF #define BUS_SPACE_MAXSIZE 0xFFFFFFFF ==== //depot/projects/hammer/sys/amd64/include/smp.h#25 (text+ko) ==== From owner-p4-projects@FreeBSD.ORG Sun May 1 05:30:33 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 689A816A4FC; Sun, 1 May 2005 05:30:33 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1BF5116A4DA for ; Sun, 1 May 2005 05:30:33 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D8DFD43D55 for ; Sun, 1 May 2005 05:30:30 +0000 (GMT) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j415UUlf023374 for ; Sun, 1 May 2005 05:30:30 GMT (envelope-from marcel@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j415UUo8023371 for perforce@freebsd.org; Sun, 1 May 2005 05:30:30 GMT (envelope-from marcel@freebsd.org) Date: Sun, 1 May 2005 05:30:30 GMT Message-Id: <200505010530.j415UUo8023371@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to marcel@freebsd.org using -f From: Marcel Moolenaar To: Perforce Change Reviews Subject: PERFORCE change 76314 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 05:30:34 -0000 http://perforce.freebsd.org/chv.cgi?CH=76314 Change 76314 by marcel@marcel_nfs on 2005/05/01 05:29:48 IFC @76311 Affected files ... .. //depot/projects/tty/Makefile.inc1#17 integrate .. //depot/projects/tty/bin/ps/ps.1#8 integrate .. //depot/projects/tty/contrib/bsnmp/snmpd/main.c#6 integrate .. //depot/projects/tty/contrib/ipfilter/lib/printstate.c#2 integrate .. //depot/projects/tty/contrib/ipfilter/tools/ippool.c#2 integrate .. //depot/projects/tty/etc/Makefile#13 integrate .. //depot/projects/tty/etc/pam.d/xdm#7 integrate .. //depot/projects/tty/etc/rc#6 integrate .. //depot/projects/tty/etc/rc.d/Makefile#10 integrate .. //depot/projects/tty/etc/rc.d/initdiskless#8 delete .. //depot/projects/tty/etc/rc.d/jail#8 integrate .. //depot/projects/tty/etc/rc.d/preseedrandom#4 delete .. //depot/projects/tty/etc/rc.d/rcconf.sh#3 integrate .. //depot/projects/tty/etc/rc.initdiskless#2 integrate .. //depot/projects/tty/lib/libc/net/getaddrinfo.3#8 integrate .. //depot/projects/tty/lib/libc/net/gethostbydns.c#7 integrate .. //depot/projects/tty/lib/libc/net/gethostbyht.c#4 integrate .. //depot/projects/tty/lib/libc/net/gethostbyname.3#7 integrate .. //depot/projects/tty/lib/libc/net/gethostbynis.c#4 integrate .. //depot/projects/tty/lib/libc/net/gethostnamadr.c#5 integrate .. //depot/projects/tty/lib/libc/net/getipnodebyname.3#5 integrate .. //depot/projects/tty/lib/libc/net/getnameinfo.3#7 integrate .. //depot/projects/tty/lib/libc/net/getnetbydns.c#3 integrate .. //depot/projects/tty/lib/libc/net/getnetbyht.c#4 integrate .. //depot/projects/tty/lib/libc/net/getnetbynis.c#2 integrate .. //depot/projects/tty/lib/libc/net/getnetent.3#3 integrate .. //depot/projects/tty/lib/libc/net/getnetnamadr.c#4 integrate .. //depot/projects/tty/lib/libc/net/getprotoent.c#4 integrate .. //depot/projects/tty/lib/libc/net/getservent.c#5 integrate .. //depot/projects/tty/lib/libc/net/map_v4v6.c#2 integrate .. //depot/projects/tty/lib/libc/net/name6.c#10 integrate .. //depot/projects/tty/lib/libc/net/netdb_private.h#3 integrate .. //depot/projects/tty/lib/libthr/Makefile#8 integrate .. //depot/projects/tty/lib/libthr/arch/i386/i386/pthread_md.c#2 integrate .. //depot/projects/tty/lib/libthr/arch/i386/include/pthread_md.h#2 integrate .. //depot/projects/tty/lib/libthr/support/Makefile.inc#1 branch .. //depot/projects/tty/lib/libthr/thread/thr_create.c#6 integrate .. //depot/projects/tty/lib/msun/src/s_ceill.c#3 integrate .. //depot/projects/tty/lib/msun/src/s_floorl.c#3 integrate .. //depot/projects/tty/lib/msun/src/s_truncl.c#2 integrate .. //depot/projects/tty/rescue/rescue/Makefile#9 integrate .. //depot/projects/tty/sbin/fdisk/fdisk.c#7 integrate .. //depot/projects/tty/sbin/geom/core/geom.c#5 integrate .. //depot/projects/tty/sbin/ipf/ipf/Makefile#2 integrate .. //depot/projects/tty/sbin/ipf/ipftest/Makefile#2 integrate .. //depot/projects/tty/sbin/ipf/ipmon/Makefile#2 integrate .. //depot/projects/tty/sbin/ipf/ipnat/Makefile#2 integrate .. //depot/projects/tty/sbin/ipf/ippool/Makefile#2 integrate .. //depot/projects/tty/sbin/ipf/ipresend/Makefile#2 integrate .. //depot/projects/tty/sbin/ipf/ipsend/Makefile#2 integrate .. //depot/projects/tty/sbin/ipf/libipf/Makefile#2 integrate .. //depot/projects/tty/share/man/man4/ath.4#7 integrate .. //depot/projects/tty/share/mk/sys.mk#10 integrate .. //depot/projects/tty/sys/amd64/amd64/mp_machdep.c#6 integrate .. //depot/projects/tty/sys/amd64/amd64/trap.c#10 integrate .. //depot/projects/tty/sys/amd64/conf/NOTES#6 integrate .. //depot/projects/tty/sys/amd64/include/smp.h#6 integrate .. //depot/projects/tty/sys/conf/NOTES#19 integrate .. //depot/projects/tty/sys/conf/files#22 integrate .. //depot/projects/tty/sys/conf/files.amd64#15 integrate .. //depot/projects/tty/sys/conf/files.i386#19 integrate .. //depot/projects/tty/sys/conf/files.pc98#15 integrate .. //depot/projects/tty/sys/conf/kern.post.mk#14 integrate .. //depot/projects/tty/sys/conf/options#18 integrate .. //depot/projects/tty/sys/conf/options.amd64#9 integrate .. //depot/projects/tty/sys/conf/options.i386#13 integrate .. //depot/projects/tty/sys/contrib/ipfilter/netinet/ip_compat.h#7 integrate .. //depot/projects/tty/sys/contrib/ipfilter/netinet/ip_frag.c#6 integrate .. //depot/projects/tty/sys/dev/arcmsr/arcmsr.c#2 integrate .. //depot/projects/tty/sys/dev/asr/asr.c#10 integrate .. //depot/projects/tty/sys/dev/ata/ata-all.c#17 integrate .. //depot/projects/tty/sys/dev/ata/ata-all.h#14 integrate .. //depot/projects/tty/sys/dev/ata/ata-card.c#13 integrate .. //depot/projects/tty/sys/dev/ata/ata-cbus.c#9 integrate .. //depot/projects/tty/sys/dev/ata/ata-chipset.c#15 integrate .. //depot/projects/tty/sys/dev/ata/ata-disk.c#14 integrate .. //depot/projects/tty/sys/dev/ata/ata-dma.c#11 integrate .. //depot/projects/tty/sys/dev/ata/ata-isa.c#11 integrate .. //depot/projects/tty/sys/dev/ata/ata-lowlevel.c#9 integrate .. //depot/projects/tty/sys/dev/ata/ata-pci.c#13 integrate .. //depot/projects/tty/sys/dev/ata/ata-pci.h#13 integrate .. //depot/projects/tty/sys/dev/ata/ata-queue.c#7 integrate .. //depot/projects/tty/sys/dev/ata/ata-raid.c#15 integrate .. //depot/projects/tty/sys/dev/ata/ata-raid.h#9 integrate .. //depot/projects/tty/sys/dev/ata/ata_if.m#2 integrate .. //depot/projects/tty/sys/dev/ata/atapi-cam.c#11 integrate .. //depot/projects/tty/sys/dev/ata/atapi-cd.c#13 integrate .. //depot/projects/tty/sys/dev/ata/atapi-fd.c#11 integrate .. //depot/projects/tty/sys/dev/ata/atapi-tape.c#11 integrate .. //depot/projects/tty/sys/dev/ciss/ciss.c#14 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_amd.c#2 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_mod.c#2 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_piv.c#2 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_ppro.c#2 integrate .. //depot/projects/tty/sys/dev/pci/pci.c#12 integrate .. //depot/projects/tty/sys/dev/pci/pci_pci.c#11 integrate .. //depot/projects/tty/sys/dev/pci/pcireg.h#7 integrate .. //depot/projects/tty/sys/dev/pci/pcivar.h#7 integrate .. //depot/projects/tty/sys/dev/twa/tw_osl_cam.c#2 integrate .. //depot/projects/tty/sys/fs/devfs/devfs_vfsops.c#9 integrate .. //depot/projects/tty/sys/fs/pseudofs/pseudofs_vnops.c#10 integrate .. //depot/projects/tty/sys/geom/vinum/geom_vinum_init.c#5 integrate .. //depot/projects/tty/sys/i386/conf/NOTES#19 integrate .. //depot/projects/tty/sys/i386/conf/PAE#8 integrate .. //depot/projects/tty/sys/i386/i386/mp_machdep.c#15 integrate .. //depot/projects/tty/sys/i386/i386/trap.c#14 integrate .. //depot/projects/tty/sys/i386/include/pmc_mdep.h#2 integrate .. //depot/projects/tty/sys/i386/include/smp.h#8 integrate .. //depot/projects/tty/sys/kern/subr_kdb.c#3 integrate .. //depot/projects/tty/sys/kern/subr_smp.c#11 integrate .. //depot/projects/tty/sys/kern/vfs_aio.c#11 integrate .. //depot/projects/tty/sys/kern/vfs_bio.c#15 integrate .. //depot/projects/tty/sys/kern/vfs_cluster.c#13 integrate .. //depot/projects/tty/sys/kern/vfs_subr.c#15 integrate .. //depot/projects/tty/sys/libkern/crc32.c#5 integrate .. //depot/projects/tty/sys/sys/pmc.h#2 integrate .. //depot/projects/tty/sys/sys/ptrace.h#6 integrate .. //depot/projects/tty/sys/sys/smp.h#7 integrate .. //depot/projects/tty/sys/ufs/ffs/ffs_rawread.c#9 integrate .. //depot/projects/tty/sys/vm/swap_pager.c#13 integrate .. //depot/projects/tty/sys/vm/uma_core.c#13 integrate .. //depot/projects/tty/sys/vm/uma_int.h#9 integrate .. //depot/projects/tty/tools/regression/usr.bin/make/README#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/all.sh#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t0/Makefile#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t0/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t0/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t0/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t0/libtest.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t0/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t1/Makefile#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t1/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t1/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t1/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t1/libtest.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t1/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t2/Makefile#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t2/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t2/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t2/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t2/libtest.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/archives/t2/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t0/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t0/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t0/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t0/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t1/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t1/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t1/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t1/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t2/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t2/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t2/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t2/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t3/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t3/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t3/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/basic/t3/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/common.sh#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t0/Makefile#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t0/TEST1.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t0/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t0/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t0/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t0/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t1/Makefile#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t1/TEST1.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t1/TEST2.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t1/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t1/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t1/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t1/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t2/Makefile#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t2/TEST1.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t2/TEST2.a#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t2/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t2/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t2/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/suffixes/t2/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t0/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t0/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t0/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t0/test.t#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t1/expected.status#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t1/expected.stderr#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t1/expected.stdout#1 branch .. //depot/projects/tty/tools/regression/usr.bin/make/variables/t1/test.t#1 branch .. //depot/projects/tty/tools/tools/tinderbox/etc/default.rc#4 integrate .. //depot/projects/tty/tools/tools/tinderbox/tinderbox.pl#11 integrate .. //depot/projects/tty/usr.bin/id/id.1#4 integrate .. //depot/projects/tty/usr.bin/id/id.c#5 integrate .. //depot/projects/tty/usr.bin/make/Makefile#5 integrate .. //depot/projects/tty/usr.bin/make/cond.c#6 integrate .. //depot/projects/tty/usr.bin/make/globals.h#2 integrate .. //depot/projects/tty/usr.bin/make/hash_tables.c#1 branch .. //depot/projects/tty/usr.bin/make/hash_tables.h#1 branch .. //depot/projects/tty/usr.bin/make/main.c#9 integrate .. //depot/projects/tty/usr.bin/make/make.h#5 integrate .. //depot/projects/tty/usr.bin/make/nonints.h#6 integrate .. //depot/projects/tty/usr.bin/make/parse.c#6 integrate .. //depot/projects/tty/usr.bin/rs/rs.c#3 integrate .. //depot/projects/tty/usr.sbin/adduser/adduser.sh#9 integrate .. //depot/projects/tty/usr.sbin/jail/jail.8#11 integrate .. //depot/projects/tty/usr.sbin/ppp/ppp.8.m4#10 integrate Differences ... ==== //depot/projects/tty/Makefile.inc1#17 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.492 2005/04/06 01:55:43 peter Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.493 2005/04/30 16:09:23 imp Exp $ # # Make command line options: # -DNO_DYNAMICROOT do not link /bin and /sbin dynamically @@ -337,6 +337,7 @@ @echo "--------------------------------------------------------------" @echo ">>> stage 2.1: cleaning up the object tree" @echo "--------------------------------------------------------------" + @rm -rf ${.OBJDIR}/sbin/ipf ${_+_}cd ${.CURDIR}; ${WMAKE} ${CLEANDIR:S/^/par-/} .endif _obj: ==== //depot/projects/tty/bin/ps/ps.1#8 (text+ko) ==== @@ -27,7 +27,7 @@ .\" SUCH DAMAGE. .\" .\" @(#)ps.1 8.3 (Berkeley) 4/18/94 -.\" $FreeBSD: src/bin/ps/ps.1,v 1.85 2005/03/20 10:40:36 pjd Exp $ +.\" $FreeBSD: src/bin/ps/ps.1,v 1.86 2005/04/29 11:10:27 maxim Exp $ .\" .Dd March 20, 2005 .Dt PS 1 @@ -103,7 +103,7 @@ .Bl -tag -width indent .It Fl a Display information about other users' processes as well as your own. -This will skip any processes which do not have a controlling teminal, +This will skip any processes which do not have a controlling terminal, unless the .Fl x option is also specified. ==== //depot/projects/tty/contrib/bsnmp/snmpd/main.c#6 (text+ko) ==== @@ -1634,9 +1634,7 @@ timer_start(u_int ticks, void (*func)(void *), void *udata, struct lmodule *mod) { struct timer *tp; -#ifdef USE_LIBBEGEMOT - struct timeval due; -#else +#ifndef USE_LIBBEGEMOT struct timespec due; #endif @@ -1644,15 +1642,8 @@ syslog(LOG_CRIT, "out of memory for timer"); exit(1); } -#ifdef USE_LIBBEGEMOT - (void)gettimeofday(&due, NULL); - due.tv_sec += ticks / 100; - due.tv_usec += (ticks % 100) * 10000; - if (due.tv_usec >= 1000000) { - due.tv_sec++; - due.tv_usec -= 1000000; - } -#else + +#ifndef USE_LIBBEGEMOT due = evAddTime(evNowTime(), evConsTime(ticks / 100, (ticks % 100) * 10000)); #endif @@ -1664,8 +1655,7 @@ LIST_INSERT_HEAD(&timer_list, tp, link); #ifdef USE_LIBBEGEMOT - if ((tp->id = poll_start_timer(due.tv_sec * 1000 + due.tv_usec / 1000, - 0, tfunc, tp)) < 0) { + if ((tp->id = poll_start_timer(ticks * 10, 0, tfunc, tp)) < 0) { syslog(LOG_ERR, "cannot set timer: %m"); exit(1); } ==== //depot/projects/tty/contrib/ipfilter/lib/printstate.c#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/contrib/ipfilter/lib/printstate.c,v 1.2 2005/04/25 18:20:12 darrenr Exp $ */ +/* $FreeBSD: src/contrib/ipfilter/lib/printstate.c,v 1.3 2005/04/28 21:36:30 darrenr Exp $ */ /* * Copyright (C) 2002 by Darren Reed. @@ -64,7 +64,7 @@ ips.is_icmp.ici_seq, ips.is_icmp.ici_type); #ifdef USE_QUAD_T - PRINTF("\tforward: pkts in %qd bytes in %qd pkts out %qd bytes out %qd\n\tbackward: pkts in %qd bytes in %qd pkts out %qd bytes out %qd\n", + PRINTF("\tforward: pkts in %lld bytes in %lld pkts out %lld bytes out %lld\n\tbackward: pkts in %lld bytes in %lld pkts out %lld bytes out %lld\n", ips.is_pkts[0], ips.is_bytes[0], ips.is_pkts[1], ips.is_bytes[1], ips.is_pkts[2], ips.is_bytes[2], ==== //depot/projects/tty/contrib/ipfilter/tools/ippool.c#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/contrib/ipfilter/tools/ippool.c,v 1.2 2005/04/25 18:20:15 darrenr Exp $ */ +/* $FreeBSD: src/contrib/ipfilter/tools/ippool.c,v 1.3 2005/04/28 16:26:33 darrenr Exp $ */ /* * Copyright (C) 2003 by Darren Reed. @@ -639,7 +639,7 @@ } } - printf("%u object%s flushed\n", flush.iplf_count, + printf("%zd object%s flushed\n", flush.iplf_count, (flush.iplf_count == 1) ? "" : "s"); return 0; ==== //depot/projects/tty/etc/Makefile#13 (text+ko) ==== @@ -1,5 +1,5 @@ # from: @(#)Makefile 5.11 (Berkeley) 5/21/91 -# $FreeBSD: src/etc/Makefile,v 1.342 2005/04/17 10:47:57 glebius Exp $ +# $FreeBSD: src/etc/Makefile,v 1.343 2005/04/29 23:02:56 brooks Exp $ .if !defined(NO_SENDMAIL) SUBDIR= sendmail @@ -12,7 +12,8 @@ inetd.conf login.access login.conf \ mac.conf motd netconfig network.subr networks newsyslog.conf \ pf.conf pf.os phones profile protocols \ - rc rc.bsdextended rc.firewall rc.firewall6 rc.sendmail rc.shutdown \ + rc rc.bsdextended rc.firewall rc.firewall6 rc.initdiskless \ + rc.sendmail rc.shutdown \ rc.subr remote rpc services shells \ snmpd.config sysctl.conf syslog.conf usbd.conf \ etc.${MACHINE_ARCH}/ttys \ ==== //depot/projects/tty/etc/pam.d/xdm#7 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/etc/pam.d/xdm,v 1.9 2004/02/20 21:59:51 des Exp $ +# $FreeBSD: src/etc/pam.d/xdm,v 1.10 2005/04/28 07:59:09 des Exp $ # # PAM configuration for the "xdm" service # @@ -16,7 +16,7 @@ # session #session required pam_ssh.so want_agent -session required pam_permit.so +session required pam_lastlog.so no_fail # password password required pam_deny.so ==== //depot/projects/tty/etc/rc#6 (text+ko) ==== @@ -25,7 +25,7 @@ # SUCH DAMAGE. # # @(#)rc 5.27 (Berkeley) 6/5/91 -# $FreeBSD: src/etc/rc,v 1.335 2004/10/08 14:23:49 mtm Exp $ +# $FreeBSD: src/etc/rc,v 1.336 2005/04/29 23:02:56 brooks Exp $ # # System startup script run by init on autoboot @@ -65,6 +65,11 @@ _boot="start" fi +dlv=`/sbin/sysctl -n vfs.nfs.diskless_valid 2> /dev/null` +if [ ${dlv:=0} -ne 0 -o -f /etc/diskless ]; then + sh /etc/rc.initdiskless +fi + skip="-s nostart" [ `/sbin/sysctl -n security.jail.jailed` -eq 1 ] && skip="$skip -s nojail" files=`rcorder ${skip} /etc/rc.d/* 2>/dev/null` ==== //depot/projects/tty/etc/rc.d/Makefile#10 (text+ko) ==== @@ -1,5 +1,5 @@ # $NetBSD: Makefile,v 1.16 2001/01/14 15:37:22 minoura Exp $ -# $FreeBSD: src/etc/rc.d/Makefile,v 1.51 2005/04/17 10:47:58 glebius Exp $ +# $FreeBSD: src/etc/rc.d/Makefile,v 1.52 2005/04/29 23:02:56 brooks Exp $ FILES= DAEMON LOGIN NETWORKING SERVERS \ abi accounting addswap adjkerntz amd \ @@ -13,7 +13,7 @@ gbde gbde_swap \ hostname \ ike \ - inetd initdiskless initrandom \ + inetd initrandom \ ip6addrctl ip6fw ipfilter ipfs ipfw ipmon \ ipnat ipsec ipxrouted isdnd \ jail \ @@ -26,7 +26,7 @@ nfslocking nfsserver nisdomain nsswitch ntpd ntpdate \ othermta \ pccard pcvt pf pflog \ - powerd power_profile ppp-user pppoed preseedrandom pwcheck \ + powerd power_profile ppp-user pppoed pwcheck \ quota \ ramdisk ramdisk-own random rarpd rcconf.sh resolv root \ route6d routed routing rpcbind rtadvd rwho \ ==== //depot/projects/tty/etc/rc.d/jail#8 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/jail,v 1.21 2005/01/16 03:12:03 obrien Exp $ +# $FreeBSD: src/etc/rc.d/jail,v 1.22 2005/04/30 00:16:00 csjp Exp $ # # PROVIDE: jail @@ -163,15 +163,18 @@ mount -a -F "${jail_fstab}" fi if checkyesno jail_devfs; then - info "Mounting devfs on ${jail_devdir}" - devfs_mount_jail "${jail_devdir}" ${jail_ruleset} - - # Transitional symlink for old binaries - if [ ! -L "${jail_devdir}/log" ]; then - __pwd="`pwd`" - cd "${jail_devdir}" - ln -sf ../var/run/log log - cd "$__pwd" + # If devfs is already mounted here, skip it. + df -t devfs "${jail_devdir}" >/dev/null + if [ $? -ne 0 ]; then + info "Mounting devfs on ${jail_devdir}" + devfs_mount_jail "${jail_devdir}" ${jail_ruleset} + # Transitional symlink for old binaries + if [ ! -L "${jail_devdir}/log" ]; then + __pwd="`pwd`" + cd "${jail_devdir}" + ln -sf ../var/run/log log + cd "$__pwd" + fi fi # XXX - It seems symlinks don't work when there ==== //depot/projects/tty/etc/rc.d/rcconf.sh#3 (text+ko) ==== @@ -1,10 +1,9 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/rcconf.sh,v 1.3 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/rcconf.sh,v 1.4 2005/04/29 23:02:56 brooks Exp $ # # PROVIDE: rcconf -# REQUIRE: initdiskless # BEFORE: disks initrandom . /etc/rc.subr ==== //depot/projects/tty/etc/rc.initdiskless#2 (text+ko) ==== @@ -24,14 +24,8 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.initdiskless,v 1.41 2004/12/12 08:04:26 obrien Exp $ -# -# PROVIDE: initdiskless -# REQUIRE: preseedrandom -# BEFORE: rcconf -# KEYWORD: nojail +# $FreeBSD: src/etc/rc.initdiskless,v 1.42 2005/04/29 23:02:56 brooks Exp $ - # On entry to this script the entire system consists of a read-only root # mounted via NFS. The kernel has run BOOTP and configured an interface # (otherwise it would not have been able to mount the NFS root!) @@ -125,7 +119,6 @@ # (end of documentation, now get to the real code) dlv=`/sbin/sysctl -n vfs.nfs.diskless_valid 2> /dev/null` -[ ${dlv:=0} -eq 0 ] && [ ! -f /etc/diskless ] && exit 0 # chkerr: # ==== //depot/projects/tty/lib/libc/net/getaddrinfo.3#8 (text+ko) ==== @@ -16,7 +16,7 @@ .\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR .\" PERFORMANCE OF THIS SOFTWARE. .\" -.\" $FreeBSD: src/lib/libc/net/getaddrinfo.3,v 1.30 2005/02/09 18:03:13 ru Exp $ +.\" $FreeBSD: src/lib/libc/net/getaddrinfo.3,v 1.31 2005/04/29 14:37:51 ume Exp $ .\" .Dd December 20, 2004 .Dt GETADDRINFO 3 @@ -430,7 +430,3 @@ draft specification and documented in .Dv "RFC 3493" , .Dq Basic Socket Interface Extensions for IPv6 . -.Sh BUGS -The implementation of -.Fn getaddrinfo -is not thread-safe. ==== //depot/projects/tty/lib/libc/net/gethostbydns.c#7 (text+ko) ==== @@ -58,7 +58,7 @@ static char fromrcsid[] = "From: Id: gethnamaddr.c,v 8.23 1998/04/07 04:59:46 vixie Exp $"; #endif /* LIBC_SCCS and not lint */ #include -__FBSDID("$FreeBSD: src/lib/libc/net/gethostbydns.c,v 1.50 2005/04/27 19:12:57 ume Exp $"); +__FBSDID("$FreeBSD: src/lib/libc/net/gethostbydns.c,v 1.54 2005/04/29 19:55:23 ume Exp $"); #include #include @@ -84,19 +84,9 @@ #define SPRINTF(x) ((size_t)sprintf x) -#define MAXALIASES 35 -#define MAXADDRS 35 - static const char AskedForGot[] = "gethostby*.gethostanswer: asked for \"%s\", got \"%s\""; -static char *h_addr_ptrs[MAXADDRS + 1]; - -static struct hostent host; -static char *host_aliases[MAXALIASES]; -static char hostbuf[8*1024]; -static u_char host_addr[16]; /* IPv4 or IPv6 */ - #ifdef RESOLVSORT static void addrsort(char **, int); #endif @@ -141,7 +131,7 @@ cp += x; \ if (cp > eom) { \ h_errno = NO_RECOVERY; \ - return (NULL); \ + return -1; \ } \ } while (0) @@ -149,16 +139,13 @@ do { \ if ((ptr) + (count) > eom) { \ h_errno = NO_RECOVERY; \ - return (NULL); \ + return -1; \ } \ } while (0) -static struct hostent * -gethostanswer(answer, anslen, qname, qtype) - const querybuf *answer; - int anslen; - const char *qname; - int qtype; +static int +gethostanswer(const querybuf *answer, int anslen, const char *qname, int qtype, + struct hostent *he, struct hostent_data *hed) { const HEADER *hp; const u_char *cp; @@ -173,7 +160,7 @@ int (*name_ok)(const char *); tname = qname; - host.h_name = NULL; + he->h_name = NULL; eom = answer->buf + anslen; switch (qtype) { case T_A: @@ -185,7 +172,7 @@ break; default: h_errno = NO_RECOVERY; - return (NULL); /* XXX should be abort(); */ + return -1; /* XXX should be abort(); */ } /* * find first satisfactory answer @@ -193,18 +180,18 @@ hp = &answer->hdr; ancount = ntohs(hp->ancount); qdcount = ntohs(hp->qdcount); - bp = hostbuf; - ep = hostbuf + sizeof hostbuf; + bp = hed->hostbuf; + ep = hed->hostbuf + sizeof hed->hostbuf; cp = answer->buf; BOUNDED_INCR(HFIXEDSZ); if (qdcount != 1) { h_errno = NO_RECOVERY; - return (NULL); + return -1; } n = dn_expand(answer->buf, eom, cp, bp, ep - bp); if ((n < 0) || !(*name_ok)(bp)) { h_errno = NO_RECOVERY; - return (NULL); + return -1; } BOUNDED_INCR(n + QFIXEDSZ); if (qtype == T_A || qtype == T_AAAA) { @@ -215,19 +202,19 @@ n = strlen(bp) + 1; /* for the \0 */ if (n >= MAXHOSTNAMELEN) { h_errno = NO_RECOVERY; - return (NULL); + return -1; } - host.h_name = bp; + he->h_name = bp; bp += n; /* The qname can be abbreviated, but h_name is now absolute. */ - qname = host.h_name; + qname = he->h_name; } - ap = host_aliases; + ap = hed->host_aliases; *ap = NULL; - host.h_aliases = host_aliases; - hap = h_addr_ptrs; + he->h_aliases = hed->host_aliases; + hap = hed->h_addr_ptrs; *hap = NULL; - host.h_addr_list = h_addr_ptrs; + he->h_addr_list = hed->h_addr_ptrs; haveanswer = 0; had_error = 0; _dns_ttl_ = -1; @@ -256,7 +243,7 @@ continue; /* XXX - had_error++ ? */ } if ((qtype == T_A || qtype == T_AAAA) && type == T_CNAME) { - if (ap >= &host_aliases[MAXALIASES-1]) + if (ap >= &hed->host_aliases[_MAXALIASES-1]) continue; n = dn_expand(answer->buf, eom, cp, tbuf, sizeof tbuf); if ((n < 0) || !(*name_ok)(tbuf)) { @@ -266,7 +253,7 @@ cp += n; if (cp != erdata) { h_errno = NO_RECOVERY; - return (NULL); + return -1; } /* Store alias. */ *ap++ = bp; @@ -283,7 +270,7 @@ continue; } strcpy(bp, tbuf); - host.h_name = bp; + he->h_name = bp; bp += n; continue; } @@ -296,7 +283,7 @@ cp += n; if (cp != erdata) { h_errno = NO_RECOVERY; - return (NULL); + return -1; } /* Get canonical name. */ n = strlen(tbuf) + 1; /* for the \0 */ @@ -335,11 +322,11 @@ cp += n; if (cp != erdata) { h_errno = NO_RECOVERY; - return (NULL); + return -1; } if (!haveanswer) - host.h_name = bp; - else if (ap < &host_aliases[MAXALIASES-1]) + he->h_name = bp; + else if (ap < &hed->host_aliases[_MAXALIASES-1]) *ap++ = bp; else n = -1; @@ -353,7 +340,7 @@ } break; #else - host.h_name = bp; + he->h_name = bp; if (_res.options & RES_USE_INET6) { n = strlen(bp) + 1; /* for the \0 */ if (n >= MAXHOSTNAMELEN) { @@ -361,27 +348,27 @@ break; } bp += n; - _map_v4v6_hostent(&host, &bp, &ep); + _map_v4v6_hostent(he, &bp, ep); } h_errno = NETDB_SUCCESS; - return (&host); + return 0; #endif case T_A: case T_AAAA: - if (strcasecmp(host.h_name, bp) != 0) { + if (strcasecmp(he->h_name, bp) != 0) { syslog(LOG_NOTICE|LOG_AUTH, - AskedForGot, host.h_name, bp); + AskedForGot, he->h_name, bp); cp += n; continue; /* XXX - had_error++ ? */ } - if (n != host.h_length) { + if (n != he->h_length) { cp += n; continue; } if (!haveanswer) { int nn; - host.h_name = bp; + he->h_name = bp; nn = strlen(bp) + 1; /* for the \0 */ bp += nn; } @@ -393,25 +380,25 @@ had_error++; continue; } - if (hap >= &h_addr_ptrs[MAXADDRS-1]) { + if (hap >= &hed->h_addr_ptrs[_MAXADDRS-1]) { if (!toobig++) dprintf("Too many addresses (%d)\n", - MAXADDRS); + _MAXADDRS); cp += n; continue; } - bcopy(cp, *hap++ = bp, n); + memcpy(*hap++ = bp, cp, n); bp += n; cp += n; if (cp != erdata) { h_errno = NO_RECOVERY; - return (NULL); + return -1; } break; default: dprintf("Impossible condition (type=%d)\n", type); h_errno = NO_RECOVERY; - return (NULL); + return -1; /* BIND has abort() here, too risky on bad data */ } if (!had_error) @@ -427,46 +414,52 @@ * address in that case, not some random one */ if (_res.nsort && haveanswer > 1 && qtype == T_A) - addrsort(h_addr_ptrs, haveanswer); + addrsort(hed->h_addr_ptrs, haveanswer); # endif /*RESOLVSORT*/ - if (!host.h_name) { + if (!he->h_name) { n = strlen(qname) + 1; /* for the \0 */ if (n > ep - bp || n >= MAXHOSTNAMELEN) goto no_recovery; strcpy(bp, qname); - host.h_name = bp; + he->h_name = bp; bp += n; } if (_res.options & RES_USE_INET6) - _map_v4v6_hostent(&host, &bp, &ep); + _map_v4v6_hostent(he, &bp, ep); h_errno = NETDB_SUCCESS; - return (&host); + return 0; } no_recovery: h_errno = NO_RECOVERY; - return (NULL); + return -1; } +/* XXX: for async DNS resolver in ypserv */ struct hostent * -__dns_getanswer(answer, anslen, qname, qtype) - const char *answer; - int anslen; - const char *qname; - int qtype; +__dns_getanswer(const char *answer, int anslen, const char *qname, int qtype) { - switch(qtype) { + struct hostdata *hd; + int error; + + if ((hd = __hostdata_init()) == NULL) { + h_errno = NETDB_INTERNAL; + return NULL; + } + switch (qtype) { case T_AAAA: - host.h_addrtype = AF_INET6; - host.h_length = IN6ADDRSZ; + hd->host.h_addrtype = AF_INET6; + hd->host.h_length = IN6ADDRSZ; break; case T_A: default: - host.h_addrtype = AF_INET; - host.h_length = INADDRSZ; + hd->host.h_addrtype = AF_INET; + hd->host.h_length = INADDRSZ; break; } - return(gethostanswer((const querybuf *)answer, anslen, qname, qtype)); + error = gethostanswer((const querybuf *)answer, anslen, qname, qtype, + &hd->host, &hd->data); + return (error == 0) ? &hd->host : NULL; } int @@ -474,12 +467,15 @@ { const char *name; int af; + struct hostent *he; + struct hostent_data *hed; querybuf *buf; - int n, size, type; + int n, size, type, error; name = va_arg(ap, const char *); af = va_arg(ap, int); - *(struct hostent **)rval = NULL; + he = va_arg(ap, struct hostent *); + hed = va_arg(ap, struct hostent_data *); switch (af) { case AF_INET: @@ -496,8 +492,8 @@ return NS_UNAVAIL; } - host.h_addrtype = af; - host.h_length = size; + he->h_addrtype = af; + he->h_length = size; if ((buf = malloc(sizeof(*buf))) == NULL) { h_errno = NETDB_INTERNAL; @@ -513,67 +509,39 @@ dprintf("static buffer is too small (%d)\n", n); return (0); } - *(struct hostent **)rval = gethostanswer(buf, n, name, type); + error = gethostanswer(buf, n, name, type, he, hed); free(buf); - return (*(struct hostent **)rval != NULL) ? NS_SUCCESS : NS_NOTFOUND; + return (error == 0) ? NS_SUCCESS : NS_NOTFOUND; } int _dns_gethostbyaddr(void *rval, void *cb_data, va_list ap) { - const char *addr; /* XXX should have been def'd as u_char! */ + const u_char *uaddr; int len, af; - const u_char *uaddr; - static const u_char mapped[] = { 0,0, 0,0, 0,0, 0,0, 0,0, 0xff,0xff }; - static const u_char tunnelled[] = { 0,0, 0,0, 0,0, 0,0, 0,0, 0,0 }; - int n, size; + struct hostent *he; + struct hostent_data *hed; + int n, error; querybuf *buf; - struct hostent *hp; char qbuf[MAXDNAME+1], *qp; #ifdef SUNSECURITY - struct hostent *rhp; + struct hostdata rhd; + struct hostent *rhe; char **haddr; u_long old_options; - char hname2[MAXDNAME+1]; + char hname2[MAXDNAME+1], numaddr[46]; #endif /*SUNSECURITY*/ - addr = va_arg(ap, const char *); - uaddr = (const u_char *)addr; + uaddr = va_arg(ap, const u_char *); len = va_arg(ap, int); af = va_arg(ap, int); - - *(struct hostent **)rval = NULL; - + he = va_arg(ap, struct hostent *); + hed = va_arg(ap, struct hostent_data *); + if ((_res.options & RES_INIT) == 0 && res_init() == -1) { h_errno = NETDB_INTERNAL; return NS_UNAVAIL; } - if (af == AF_INET6 && len == IN6ADDRSZ && - (!bcmp(uaddr, mapped, sizeof mapped) || - !bcmp(uaddr, tunnelled, sizeof tunnelled))) { - /* Unmap. */ - addr += sizeof mapped; - uaddr += sizeof mapped; - af = AF_INET; - len = INADDRSZ; - } - switch (af) { - case AF_INET: - size = INADDRSZ; - break; - case AF_INET6: - size = IN6ADDRSZ; - break; - default: - errno = EAFNOSUPPORT; - h_errno = NETDB_INTERNAL; - return NS_UNAVAIL; - } - if (size != len) { - errno = EINVAL; - h_errno = NETDB_INTERNAL; - return NS_UNAVAIL; - } switch (af) { case AF_INET: (void) sprintf(qbuf, "%u.%u.%u.%u.in-addr.arpa", @@ -609,7 +577,7 @@ dprintf("static buffer is too small (%d)\n", n); return NS_UNAVAIL; } - if (!(hp = gethostanswer(buf, n, qbuf, T_PTR))) { + if ((error = gethostanswer(buf, n, qbuf, T_PTR, he, hed)) != 0) { free(buf); return NS_NOTFOUND; /* h_errno was set by gethostanswer() */ } @@ -620,45 +588,49 @@ * turn off search as the name should be absolute, * 'localhost' should be matched by defnames */ - strncpy(hname2, hp->h_name, MAXDNAME); + strncpy(hname2, he->h_name, MAXDNAME); hname2[MAXDNAME] = '\0'; old_options = _res.options; _res.options &= ~RES_DNSRCH; _res.options |= RES_DEFNAMES; - if (!(rhp = gethostbyname(hname2))) { + memset(&rhd, 0, sizeof rhd); + if (!(rhe = gethostbyname_r(hname2, &rhd.host, &rhd.data))) { + if (inet_ntop(af, addr, numaddr, sizeof(numaddr)) == NULL) + strlcpy(numaddr, "UNKNOWN", sizeof(numaddr)); syslog(LOG_NOTICE|LOG_AUTH, "gethostbyaddr: No A record for %s (verifying [%s])", - hname2, inet_ntoa(*((struct in_addr *)addr))); + hname2, numaddr); _res.options = old_options; h_errno = HOST_NOT_FOUND; return NS_NOTFOUND; } _res.options = old_options; - for (haddr = rhp->h_addr_list; *haddr; haddr++) + for (haddr = rhe->h_addr_list; *haddr; haddr++) if (!memcmp(*haddr, addr, INADDRSZ)) break; if (!*haddr) { + if (inet_ntop(af, addr, numaddr, sizeof(numaddr)) == NULL) + strlcpy(numaddr, "UNKNOWN", sizeof(numaddr)); syslog(LOG_NOTICE|LOG_AUTH, "gethostbyaddr: A record of %s != PTR record [%s]", - hname2, inet_ntoa(*((struct in_addr *)addr))); + hname2, numaddr); >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Sun May 1 11:52:16 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 5DDCF16A4D0; Sun, 1 May 2005 11:52:16 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 052DE16A4CE for ; Sun, 1 May 2005 11:52:16 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id BEB0F43D41 for ; Sun, 1 May 2005 11:52:15 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41BqFBK042250 for ; Sun, 1 May 2005 11:52:15 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41BqFAH042247 for perforce@freebsd.org; Sun, 1 May 2005 11:52:15 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 11:52:15 GMT Message-Id: <200505011152.j41BqFAH042247@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76322 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 11:52:17 -0000 http://perforce.freebsd.org/chv.cgi?CH=76322 Change 76322 by rwatson@rwatson_paprika on 2005/05/01 11:51:25 Turn FreeBSD's endian.h into a compat endian.h. Affected files ... .. //depot/projects/trustedbsd/openbsm/sys/endian.h#2 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/sys/endian.h#2 (text+ko) ==== @@ -1,5 +1,6 @@ /*- * Copyright (c) 2002 Thomas Moestl + * Copyright (c) 2005 Robert N. M. Watson * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -26,34 +27,57 @@ * $FreeBSD: src/sys/sys/endian.h,v 1.6 2003/10/15 20:05:57 obrien Exp $ */ -#ifndef _SYS_ENDIAN_H_ -#define _SYS_ENDIAN_H_ +#ifndef _COMPAT_ENDIAN_H_ +#define _COMPAT_ENDIAN_H_ + +/* + * Some operating systems do not yet have the more recent endian APIs that + * permit encoding to and decoding from byte streams. For those systems, we + * implement local non-optimized versions. + */ + +static __inline uint16_t +bswap16(uint16_t int16) +{ + const char *p; + + p = &int16; + return (p[1] << 8 || p[0]); +} + +static __inline uint32_t +bswap32(uint32_t int32) +{ + const char *p; + + p = &int32; + return (p[3] << 24 || p[2] << 16 || p[1] << 8 || p[0]); +} + +static __inline uint64_t +bswap64(uint64_t int64) +{ + const char *p; -#include -#include -#include + p = &int64; + return (p[7] << 56 || p[6] << 48 || p[5] << 40 || p[4] << 32 || + p[3] << 24 || p[2] << 16 || p[1] << 8 || p[0]; +} -#ifndef _UINT16_T_DECLARED -typedef __uint16_t uint16_t; -#define _UINT16_T_DECLARED +#if defined(BYTE_ORDER) && !defined(_BYTE_ORDER) +#define _BYTE_ORDER BYTE_ORDER +#elsif defined(_BYTE_ORDER) +#else +#error "Neither _BYTE_ORDER nor BYTE_ORDER defined" #endif - -#ifndef _UINT32_T_DECLARED -typedef __uint32_t uint32_t; -#define _UINT32_T_DECLARED + +#if defined(BIG_ENDIAN) && !defined(_BIG_ENDIAN) +#define _BIG_ENDIAN BIG_ENDIAN #endif - -#ifndef _UINT64_T_DECLARED -typedef __uint64_t uint64_t; -#define _UINT64_T_DECLARED + +#if defined(LITTLE_ENDIAN) && !defined(_LITTLE_ENDIAN) +#define _LITTLE_ENDIAN LITTLE_ENDIAN #endif - -/* - * General byte order swapping functions. - */ -#define bswap16(x) __bswap16(x) -#define bswap32(x) __bswap32(x) -#define bswap64(x) __bswap64(x) /* * Host to big endian, host to little endian, big endian to host, and little @@ -197,4 +221,4 @@ le32enc(p + 4, u >> 32); } -#endif /* _SYS_ENDIAN_H_ */ +#endif /* _COMPAT_ENDIAN_H_ */ From owner-p4-projects@FreeBSD.ORG Sun May 1 11:53:18 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1061716A4E1; Sun, 1 May 2005 11:53:18 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AB11216A4D1 for ; Sun, 1 May 2005 11:53:17 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7C57D43D1F for ; Sun, 1 May 2005 11:53:17 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41BrHNL042281 for ; Sun, 1 May 2005 11:53:17 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41BrHmf042278 for perforce@freebsd.org; Sun, 1 May 2005 11:53:17 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 11:53:17 GMT Message-Id: <200505011153.j41BrHmf042278@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76323 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 11:53:19 -0000 http://perforce.freebsd.org/chv.cgi?CH=76323 Change 76323 by rwatson@rwatson_paprika on 2005/05/01 11:52:17 Rename sys/endian.h to compat/endian.h to make it more clear which is the local endian.h, and which is the system endian.h. That way on FreeBSD, we don't include the local one instead of the system one. Affected files ... .. //depot/projects/trustedbsd/openbsm/compat/endian.h#1 branch .. //depot/projects/trustedbsd/openbsm/sys/endian.h#3 delete Differences ... From owner-p4-projects@FreeBSD.ORG Sun May 1 11:55:21 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E354D16A4D0; Sun, 1 May 2005 11:55:20 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9157116A4CE for ; Sun, 1 May 2005 11:55:20 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7276A43D31 for ; Sun, 1 May 2005 11:55:20 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41BtKPp042431 for ; Sun, 1 May 2005 11:55:20 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41BtKc7042428 for perforce@freebsd.org; Sun, 1 May 2005 11:55:20 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 11:55:20 GMT Message-Id: <200505011155.j41BtKc7042428@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76324 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 11:55:21 -0000 http://perforce.freebsd.org/chv.cgi?CH=76324 Change 76324 by rwatson@rwatson_paprika on 2005/05/01 11:55:10 If running on __APPLE__, use compat/endian.h instead of sys/endian.h, which isn't present. Affected files ... .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#8 edit .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_token.c#12 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#8 (text+ko) ==== @@ -29,7 +29,11 @@ */ #include +#ifdef __APPLE__ +#include +#else /* !__APPLE__ */ #include +#endif /* __APPLE__*/ #include #include ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_token.c#12 (text+ko) ==== @@ -29,7 +29,11 @@ */ #include +#ifdef __APPLE__ +#include +#else /* !__APPLE__ */ #include +#endif /* __APPLE__*/ #include #include From owner-p4-projects@FreeBSD.ORG Sun May 1 12:22:54 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8E23B16A4D0; Sun, 1 May 2005 12:22:54 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 48F8016A4CE for ; Sun, 1 May 2005 12:22:54 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id F2DC143D46 for ; Sun, 1 May 2005 12:22:53 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41CMrgi043240 for ; Sun, 1 May 2005 12:22:53 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41CMrsD043237 for perforce@freebsd.org; Sun, 1 May 2005 12:22:53 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 12:22:53 GMT Message-Id: <200505011222.j41CMrsD043237@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76325 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 12:22:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=76325 Change 76325 by rwatson@rwatson_paprika on 2005/05/01 12:22:07 Much fixery: - Fix check and define of byte order defines. - Include machine/endian.h to pick up byte order definitions. - Avoid endian-sensitive arithmetic when combining endian- independent reads from an integer type. Affected files ... .. //depot/projects/trustedbsd/openbsm/compat/endian.h#2 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/compat/endian.h#2 (text+ko) ==== @@ -31,6 +31,11 @@ #define _COMPAT_ENDIAN_H_ /* + * Pick up value of BYTE_ORDER/_BYTE_ORDER if not yet included. + */ +#include + +/* * Some operating systems do not yet have the more recent endian APIs that * permit encoding to and decoding from byte streams. For those systems, we * implement local non-optimized versions. @@ -39,36 +44,65 @@ static __inline uint16_t bswap16(uint16_t int16) { - const char *p; + const unsigned char *from; + unsigned char *to; + uint16_t t; + + from = (const unsigned char *) &int16; + to = (unsigned char *) &t; + + to[0] = from[1]; + to[1] = from[0]; - p = &int16; - return (p[1] << 8 || p[0]); + return (t); } static __inline uint32_t bswap32(uint32_t int32) { - const char *p; + const unsigned char *from; + unsigned char *to; + uint32_t t; + + from = (const unsigned char *) &int32; + to = (unsigned char *) &t; + + to[0] = from[3]; + to[1] = from[2]; + to[2] = from[1]; + to[3] = from[0]; - p = &int32; - return (p[3] << 24 || p[2] << 16 || p[1] << 8 || p[0]); + return (t); } static __inline uint64_t bswap64(uint64_t int64) { - const char *p; + const unsigned char *from; + unsigned char *to; + uint64_t t; + + from = (const unsigned char *) &int64; + to = (unsigned char *) &t; + + to[0] = from[7]; + to[1] = from[6]; + to[2] = from[5]; + to[3] = from[4]; + to[4] = from[3]; + to[5] = from[2]; + to[6] = from[1]; + to[7] = from[0]; - p = &int64; - return (p[7] << 56 || p[6] << 48 || p[5] << 40 || p[4] << 32 || - p[3] << 24 || p[2] << 16 || p[1] << 8 || p[0]; + return (t); } #if defined(BYTE_ORDER) && !defined(_BYTE_ORDER) +#warning "Converting BYTE_ORDER to _BYTE_ORDER" #define _BYTE_ORDER BYTE_ORDER -#elsif defined(_BYTE_ORDER) -#else -#error "Neither _BYTE_ORDER nor BYTE_ORDER defined" +#endif +#if !defined(_BYTE_ORDER) +#error "Neither BYTE_ORDER nor _BYTE_ORDER defined" #endif #if defined(BIG_ENDIAN) && !defined(_BIG_ENDIAN) From owner-p4-projects@FreeBSD.ORG Sun May 1 12:27:00 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B1F0E16A4D0; Sun, 1 May 2005 12:26:59 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7582B16A4CE for ; Sun, 1 May 2005 12:26:59 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 593CA43D1F for ; Sun, 1 May 2005 12:26:59 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41CQxeJ043429 for ; Sun, 1 May 2005 12:26:59 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41CQx0M043426 for perforce@freebsd.org; Sun, 1 May 2005 12:26:59 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 12:26:59 GMT Message-Id: <200505011226.j41CQx0M043426@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76326 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 12:27:00 -0000 http://perforce.freebsd.org/chv.cgi?CH=76326 Change 76326 by rwatson@rwatson_paprika on 2005/05/01 12:26:00 Include stdint.h, as some systems won't have picked up the int defines as a result of the earlier include of types.h by the code including endian.h. Remove gratuitous warning from earlier debuggin. Affected files ... .. //depot/projects/trustedbsd/openbsm/compat/endian.h#3 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/compat/endian.h#3 (text+ko) ==== @@ -36,6 +36,12 @@ #include /* + * Some systems will have the uint/int types defined here already, others + * will need stdint.h. + */ +#include + +/* * Some operating systems do not yet have the more recent endian APIs that * permit encoding to and decoding from byte streams. For those systems, we * implement local non-optimized versions. @@ -98,7 +104,6 @@ } #if defined(BYTE_ORDER) && !defined(_BYTE_ORDER) -#warning "Converting BYTE_ORDER to _BYTE_ORDER" #define _BYTE_ORDER BYTE_ORDER #endif #if !defined(_BYTE_ORDER) From owner-p4-projects@FreeBSD.ORG Sun May 1 17:03:35 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7E5C516A4D0; Sun, 1 May 2005 17:03:35 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 290B016A4CE for ; Sun, 1 May 2005 17:03:35 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id DD3F543D31 for ; Sun, 1 May 2005 17:03:34 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41H3YXx064291 for ; Sun, 1 May 2005 17:03:34 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41H3YPi064288 for perforce@freebsd.org; Sun, 1 May 2005 17:03:34 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 17:03:34 GMT Message-Id: <200505011703.j41H3YPi064288@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76329 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 17:03:36 -0000 http://perforce.freebsd.org/chv.cgi?CH=76329 Change 76329 by rwatson@rwatson_paprika on 2005/05/01 17:03:27 s/1994/2004/, really. Affected files ... .. //depot/projects/trustedbsd/openbsm/man/audit.2#4 edit .. //depot/projects/trustedbsd/openbsm/man/auditctl.2#2 edit .. //depot/projects/trustedbsd/openbsm/man/getaudit.2#2 edit .. //depot/projects/trustedbsd/openbsm/man/getauid.2#2 edit .. //depot/projects/trustedbsd/openbsm/man/setaudit.2#2 edit .. //depot/projects/trustedbsd/openbsm/man/setauid.2#2 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/man/audit.2#4 (text+ko) ==== @@ -85,7 +85,7 @@ .An Tom Rhodes Aq trhodes@FreeBSD.org . .Sh HISTORY The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 1994. +division of McAfee Inc., under contract to Apple Computer Inc. in 2004. It was subsequently adopted by the TrustedBSD Project as the foundation for the OpenBSM distribution. .Pp ==== //depot/projects/trustedbsd/openbsm/man/auditctl.2#2 (text+ko) ==== @@ -63,7 +63,7 @@ stream format were defined by Sun Microsystems. .Sh HISTORY The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 1994. +division of McAfee Inc., under contract to Apple Computer Inc. in 2004. It was subsequently adopted by the TrustedBSD Project as the foundation for the OpenBSM distribution. .Sh BUGS ==== //depot/projects/trustedbsd/openbsm/man/getaudit.2#2 (text+ko) ==== @@ -72,6 +72,6 @@ stream format were defined by Sun Microsystems. .Sh HISTORY The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 1994. +division of McAfee Inc., under contract to Apple Computer Inc. in 2004. It was subsequently adopted by the TrustedBSD Project as the foundation for the OpenBSM distribution. ==== //depot/projects/trustedbsd/openbsm/man/getauid.2#2 (text+ko) ==== @@ -66,6 +66,6 @@ stream format were defined by Sun Microsystems. .Sh HISTORY The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 1994. +division of McAfee Inc., under contract to Apple Computer Inc. in 2004. It was subsequently adopted by the TrustedBSD Project as the foundation for the OpenBSM distribution. ==== //depot/projects/trustedbsd/openbsm/man/setaudit.2#2 (text+ko) ==== @@ -73,6 +73,6 @@ stream format were defined by Sun Microsystems. .Sh HISTORY The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 1994. +division of McAfee Inc., under contract to Apple Computer Inc. in 2004. It was subsequently adopted by the TrustedBSD Project as the foundation for the OpenBSM distribution. ==== //depot/projects/trustedbsd/openbsm/man/setauid.2#2 (text+ko) ==== @@ -66,6 +66,6 @@ stream format were defined by Sun Microsystems. .Sh HISTORY The OpenBSM implementation was created by McAfee Research, the security -division of McAfee Inc., under contract to Apple Computer Inc. in 1994. +division of McAfee Inc., under contract to Apple Computer Inc. in 2004. It was subsequently adopted by the TrustedBSD Project as the foundation for the OpenBSM distribution. From owner-p4-projects@FreeBSD.ORG Sun May 1 18:43:36 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id AE2B116A4D0; Sun, 1 May 2005 18:43:35 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4F72D16A4CE for ; Sun, 1 May 2005 18:43:35 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 25FD943D46 for ; Sun, 1 May 2005 18:43:35 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41IhZIK066734 for ; Sun, 1 May 2005 18:43:35 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41IhYrO066731 for perforce@freebsd.org; Sun, 1 May 2005 18:43:34 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 18:43:34 GMT Message-Id: <200505011843.j41IhYrO066731@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76330 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 18:43:36 -0000 http://perforce.freebsd.org/chv.cgi?CH=76330 Change 76330 by rwatson@rwatson_paprika on 2005/05/01 18:43:31 Reference au_to_ip() and au_to_header() better in our almost documentation. Affected files ... .. //depot/projects/trustedbsd/openbsm/libbsm/Makefile#6 edit .. //depot/projects/trustedbsd/openbsm/libbsm/au_token.3#2 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/libbsm/Makefile#6 (text+ko) ==== @@ -112,6 +112,7 @@ au_token.3 au_to_me.3 \ au_token.3 au_to_exec_args.3 \ au_token.3 au_to_exec_env.3 \ + au_token.3 au_to_header.3 \ au_token.3 au_to_header32.3 \ au_token.3 au_to_header64.3 \ au_token.3 au_to_trailer.3 ==== //depot/projects/trustedbsd/openbsm/libbsm/au_token.3#2 (text+ko) ==== @@ -72,6 +72,7 @@ .Nm au_to_me , .Nm au_to_exec_args , .Nm au_to_exec_env , +.Nm au_to_header , .Nm au_to_header32 , .Nm au_to_header64 , .Nm au_to_trailer . @@ -105,6 +106,8 @@ .Ft token_t * .Fn au_to_in_addr_ex "struct in6_addr *internet_addr" .Ft token_t * +.Fn au_to_ip "struct ip *ip" +.Ft token_t * .Fn au_to_ipc "char type" "int id" .Ft token_t * .Fn au_to_ipc_perm "struct ipc_perm *perm" @@ -167,6 +170,8 @@ .Ft token_t * .Fn au_to_exec_env "const char **env" .Ft token_t * +.Fn au_to_header "int rec_size" "au_event_t e_type" "au_emod_t emod" +.Ft token_t * .Fn au_to_header32 "int rec_size" "au_event_t e_type" "au_emod_t emod" .Ft token_t * .Fn au_to_header64 "int rec_size" "au_event_t e_type" "au_emod_t e_mod" From owner-p4-projects@FreeBSD.ORG Sun May 1 18:49:43 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 5C8C616A4D1; Sun, 1 May 2005 18:49:43 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1F88816A4CE for ; Sun, 1 May 2005 18:49:43 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0145543D45 for ; Sun, 1 May 2005 18:49:43 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41Ingix066864 for ; Sun, 1 May 2005 18:49:42 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41Ingd8066861 for perforce@freebsd.org; Sun, 1 May 2005 18:49:42 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 18:49:42 GMT Message-Id: <200505011849.j41Ingd8066861@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76331 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 18:49:44 -0000 http://perforce.freebsd.org/chv.cgi?CH=76331 Change 76331 by rwatson@rwatson_paprika on 2005/05/01 18:49:22 Correct error in au_to_iport() prototype: 16-bit field, not 32-bit. Affected files ... .. //depot/projects/trustedbsd/openbsm/libbsm/au_token.3#3 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/libbsm/au_token.3#3 (text+ko) ==== @@ -112,7 +112,7 @@ .Ft token_t * .Fn au_to_ipc_perm "struct ipc_perm *perm" .Ft token_t * -.Fn au_to_iport "u_int64_t iport" +.Fn au_to_iport "u_int16_t iport" .Ft token_t * .Fn au_to_opaque "char *data" "u_int64_t bytes" .Ft token_t * From owner-p4-projects@FreeBSD.ORG Sun May 1 19:14:13 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 26DCE16A4D0; Sun, 1 May 2005 19:14:13 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DD9A016A4CE for ; Sun, 1 May 2005 19:14:12 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C227643D1F for ; Sun, 1 May 2005 19:14:12 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41JECBm067508 for ; Sun, 1 May 2005 19:14:12 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41JECcD067505 for perforce@freebsd.org; Sun, 1 May 2005 19:14:12 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 19:14:12 GMT Message-Id: <200505011914.j41JECcD067505@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76332 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 19:14:13 -0000 http://perforce.freebsd.org/chv.cgi?CH=76332 Change 76332 by rwatson@rwatson_paprika on 2005/05/01 19:13:55 First 1/3 or so of audit.log.5, which describes the BSM file format. More to follow. Generated a number of interesting questions now sent to trustedbsd-discuss, more of them to follow also, no doubt. Affected files ... .. //depot/projects/trustedbsd/openbsm/man/Makefile#2 edit .. //depot/projects/trustedbsd/openbsm/man/audit.log.5#1 add Differences ... ==== //depot/projects/trustedbsd/openbsm/man/Makefile#2 (text+ko) ==== @@ -9,6 +9,7 @@ getauid.2 \ setaudit.2 \ setauid.2 \ + audit.log.5 \ audit_class.5 \ audit_control.5 \ audit_event.5 \ From owner-p4-projects@FreeBSD.ORG Sun May 1 20:27:42 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D576016A4D0; Sun, 1 May 2005 20:27:41 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9486816A4CE for ; Sun, 1 May 2005 20:27:41 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6A38443D39 for ; Sun, 1 May 2005 20:27:41 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41KRfsA069468 for ; Sun, 1 May 2005 20:27:41 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41KRfx8069465 for perforce@freebsd.org; Sun, 1 May 2005 20:27:41 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 20:27:41 GMT Message-Id: <200505012027.j41KRfx8069465@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76333 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 20:27:42 -0000 http://perforce.freebsd.org/chv.cgi?CH=76333 Change 76333 by rwatson@rwatson_paprika on 2005/05/01 20:26:59 Teach au_read_rec() to recognize file tokens and treat them as a "complete record" from the perspective of the caller. All other audit tokens occur only in the context of a record, so matching the record header is the right approach for them, just not the file token. Affected files ... .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#9 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#9 (text+ko) ==== @@ -2243,6 +2243,13 @@ * Rread a record from the file pointer, store data in buf * memory for buf is also allocated in this function * and has to be free'd outside this call + * + * au_read_rec() handles two possibilities: a stand-alone file token, or a + * complete audit record. + * + * XXXRW: Note that if we hit an error, we leave the stream in an unusable + * state, because it will be partly offset into a record. We should rewind + * or do something more intelligent. */ int au_read_rec(FILE *fp, u_char **buf) { @@ -2251,44 +2258,97 @@ u_int32_t bytestoread; u_char type; + u_int32_t sec, msec; + u_int16_t filenamelen; + type = fgetc(fp); - /* record must begin with a header token */ - if(type != AU_HEADER_32_TOKEN) { - errno = EINVAL; - return -1; - } + + switch (type) { + case AU_HEADER_32_TOKEN: + case AU_HEADER_EX_32_TOKEN: + case AU_HEADER_64_TOKEN: + case AU_HEADER_EX_64_TOKEN: + /* read the record size from the token */ + if (fread(&recsize, 1, sizeof(u_int32_t), fp) < + sizeof(u_int32_t)) { + errno = EINVAL; + return -1; + } + recsize = be32toh(recsize); + + /* Check for recsize sanity */ + if (recsize < (sizeof(u_int32_t) + sizeof(u_char))) { + errno = EINVAL; + return -1; + } + + *buf = (u_char *)malloc(recsize * sizeof(u_char)); + if (*buf == NULL) + return -1; + bptr = *buf; + memset(bptr, 0, recsize); + + /* store the token contents already read, back to the buffer*/ + *bptr = type; + bptr++; + be32enc(bptr, recsize); + bptr += sizeof(u_int32_t); - /* read the record size from the token */ - if(fread(&recsize, 1, sizeof(u_int32_t), fp) < sizeof(u_int32_t)) { - errno = EINVAL; - return -1; - } - recsize = be32toh(recsize); + /* now read remaining record bytes */ + bytestoread = recsize - sizeof(u_int32_t) - sizeof(u_char); - /* Check for recsize sanity */ - if(recsize < (sizeof(u_int32_t) + sizeof(u_char))) { - errno = EINVAL; - return -1; - } + if (fread(bptr, 1, bytestoread, fp) < bytestoread) { + free(*buf); + errno = EINVAL; + return -1; + } + break; - *buf = (u_char *)malloc(recsize * sizeof(u_char)); - if(*buf == NULL) { - return -1; - } - bptr = *buf; - memset(bptr, 0, recsize); + case AU_FILE_TOKEN: + /* + * The file token is variable-length, as it includes a + * pathname. As a result, we have to read incrementally + * until we know the total length, then allocate space and + * read the rest. + */ + if (fread(&sec, 1, sizeof(sec), fp) < sizeof(sec)) { + errno = EINVAL; + return -1; + } + if (fread(&msec, 1, sizeof(msec), fp) < sizeof(msec)) { + errno = EINVAL; + return -1; + } + if (fread(&filenamelen, 1, sizeof(filenamelen), fp) < + sizeof(filenamelen)) { + errno = EINVAL; + return -1; + } + recsize = sizeof(type) + sizeof(sec) + sizeof(msec) + + sizeof(filenamelen) + ntohs(filenamelen); + *buf = malloc(recsize); + if (*buf == NULL) + return -1; + bptr = *buf; - /* store the token contents already read, back to the buffer*/ - *bptr = type; - bptr++; - be32enc(bptr, recsize); - bptr += sizeof(u_int32_t); + bcopy(&type, bptr, sizeof(type)); + bptr += sizeof(type); + bcopy(&sec, bptr, sizeof(sec)); + bptr += sizeof(sec); + bcopy(&msec, bptr, sizeof(msec)); + bptr += sizeof(msec); + bcopy(&filenamelen, bptr, sizeof(filenamelen)); + bptr += sizeof(filenamelen); - /* now read remaining record bytes */ - bytestoread = recsize - sizeof(u_int32_t) - sizeof(u_char); + if (fread(bptr, 1, ntohs(filenamelen), fp) < + ntohs(filenamelen)) { + free(buf); + errno = EINVAL; + return -1; + } - if(fread(bptr, 1, bytestoread, fp) < bytestoread) { - free(*buf); + break; + default: errno = EINVAL; return -1; } From owner-p4-projects@FreeBSD.ORG Sun May 1 21:23:52 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 4874F16A4D0; Sun, 1 May 2005 21:23:52 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E7DD716A4CE for ; Sun, 1 May 2005 21:23:51 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7972D43D49 for ; Sun, 1 May 2005 21:23:51 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41LNpbp077766 for ; Sun, 1 May 2005 21:23:51 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41LNpOv077763 for perforce@freebsd.org; Sun, 1 May 2005 21:23:51 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 21:23:51 GMT Message-Id: <200505012123.j41LNpOv077763@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76336 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 21:23:53 -0000 http://perforce.freebsd.org/chv.cgi?CH=76336 Change 76336 by rwatson@rwatson_paprika on 2005/05/01 21:23:34 Rename print_sec() to print_sec32(); add a print_sec64() that truncates the value of a 64-bit second count since we assume that time_t is 32-bit. Rename print_msec() to print_msec32(); add a print_msec64() that truncates the value of a 64-bit millisecond count since that's silly. Implement fetch_header64_tok(), print_header64_tok(), fetch_attr64_tok(), print_attr64_tok(), fetch_subject64_tok(), print_subject64_tok(). It's now possible to print the basic 64-bit record types from a 64-bit Solaris BSM token stream. Affected files ... .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#10 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#10 (text+ko) ==== @@ -281,7 +281,7 @@ /* * Prints seconds in the ctime format */ -static void print_sec(FILE *fp, u_int32_t sec, char raw) +static void print_sec32(FILE *fp, u_int32_t sec, char raw) { time_t time; char timestr[26]; @@ -298,9 +298,29 @@ } /* + * XXXRW: 64-bit token streams make use of 64-bit time stamps; since we + * assume a 32-bit time_t, we simply truncate for now. + */ +static void print_sec64(FILE *fp, u_int64_t sec, char raw) +{ + time_t time; + char timestr[26]; + + if(raw) { + fprintf(fp, "%u", (u_int32_t)sec); + } + else { + time = (time_t)sec; + ctime_r(&time, timestr); + timestr[24] = '\0'; /* No new line */ + fprintf(fp, "%s", timestr); + } +} + +/* * Prints the excess milliseconds */ -static void print_msec(FILE *fp, u_int32_t msec, char raw) +static void print_msec32(FILE *fp, u_int32_t msec, char raw) { if(raw) { fprintf(fp, "%u", msec); @@ -310,7 +330,23 @@ } } +/* + * XXXRW: 64-bit token streams make use of 64-bit time stamps; since we + * assume a 32-bit msec, we simply truncate for now. + */ +static void print_msec64(FILE *fp, u_int64_t msec, char raw) +{ + msec &= 0xffffffff; + if(raw) { + fprintf(fp, "%u", (u_int32_t)msec); + } + else { + fprintf(fp, " + %u msec", (u_int32_t)msec); + } +} + + /* prints a dotted form for the IP addres */ static void print_ip_address(FILE *fp, u_int32_t ip) { @@ -448,9 +484,72 @@ print_delim(fp, del); print_evmod(fp, tok->tt.hdr32.e_mod, raw); print_delim(fp, del); - print_sec(fp, tok->tt.hdr32.s, raw); + print_sec32(fp, tok->tt.hdr32.s, raw); + print_delim(fp, del); + print_msec32(fp, tok->tt.hdr32.ms, raw); +} + +/* + * record byte count 4 bytes + * event type 2 bytes + * event modifier 2 bytes + * seconds of time 4 bytes/8 bytes (32-bit/64-bit value) + * milliseconds of time 4 bytes/8 bytes (32-bit/64-bit value) + * version # + */ +static int fetch_header64_tok(tokenstr_t *tok, char *buf, int len) +{ + int err = 0; + + READ_TOKEN_U_INT32(buf, len, tok->tt.hdr64.size, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_CHAR(buf, len, tok->tt.hdr64.version, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT16(buf, len, tok->tt.hdr64.e_type, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT16(buf, len, tok->tt.hdr64.e_mod, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT64(buf, len, tok->tt.hdr64.s, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT64(buf, len, tok->tt.hdr64.ms, tok->len, err); + if(err) { + return -1; + } + + return 0; +} + +static void print_header64_tok(FILE *fp, tokenstr_t *tok, char *del, + char raw, char sfrm) +{ + print_tok_type(fp, tok->id, "header", raw); + print_delim(fp, del); + print_4_bytes(fp, tok->tt.hdr64.size, "%u"); + print_delim(fp, del); + print_1_byte(fp, tok->tt.hdr64.version, "%u"); + print_delim(fp, del); + print_event(fp, tok->tt.hdr64.e_type, raw, sfrm); + print_delim(fp, del); + print_evmod(fp, tok->tt.hdr64.e_mod, raw); + print_delim(fp, del); + print_sec64(fp, tok->tt.hdr64.s, raw); print_delim(fp, del); - print_msec(fp, tok->tt.hdr32.ms, raw); + print_msec64(fp, tok->tt.hdr64.ms, raw); } /* @@ -763,6 +862,69 @@ } /* + * file access mode 4 bytes + * owner user ID 4 bytes + * owner group ID 4 bytes + * file system ID 4 bytes + * node ID 8 bytes + * device 4 bytes/8 bytes (32-bit/64-bit) + */ +static int fetch_attr64_tok(tokenstr_t *tok, char *buf, int len) +{ + int err = 0; + + READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.mode, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.uid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.gid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.fsid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT64(buf, len, tok->tt.attr64.nid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT64(buf, len, tok->tt.attr64.dev, tok->len, err); + if(err) { + return -1; + } + + return 0; +} + +static void print_attr64_tok(FILE *fp, tokenstr_t *tok, char *del, + char raw, char sfrm) +{ + print_tok_type(fp, tok->id, "attribute", raw); + print_delim(fp, del); + print_4_bytes(fp, tok->tt.attr64.mode, "%o"); + print_delim(fp, del); + print_user(fp, tok->tt.attr64.uid, raw); + print_delim(fp, del); + print_group(fp, tok->tt.attr64.gid, raw); + print_delim(fp, del); + print_4_bytes(fp, tok->tt.attr64.fsid, "%u"); + print_delim(fp, del); + print_8_bytes(fp, tok->tt.attr64.nid, "%lld"); + print_delim(fp, del); + print_8_bytes(fp, tok->tt.attr64.dev, "%llu"); +} + +/* * status 4 bytes * return value 4 bytes */ @@ -919,9 +1081,9 @@ { print_tok_type(fp, tok->id, "file", raw); print_delim(fp, del); - print_sec(fp, tok->tt.file.s, raw); + print_sec32(fp, tok->tt.file.s, raw); print_delim(fp, del); - print_msec(fp, tok->tt.file.ms, raw); + print_msec32(fp, tok->tt.file.ms, raw); print_delim(fp, del); print_string(fp, tok->tt.file.name, tok->tt.file.len); } @@ -1704,7 +1866,7 @@ * pid 4 bytes * sessid 4 bytes * terminal ID - * portid 4 bytes + * portid 4 bytes/8 bytes (32-bit/64-bit value) * machine id 4 bytes */ static int fetch_subject32_tok(tokenstr_t *tok, char *buf, int len) @@ -1792,6 +1954,94 @@ * pid 4 bytes * sessid 4 bytes * terminal ID + * portid 4 bytes/8 bytes (32-bit/64-bit value) + * machine id 4 bytes + */ +static int fetch_subject64_tok(tokenstr_t *tok, char *buf, int len) +{ + int err = 0; + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.auid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.euid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.egid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.ruid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.rgid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.pid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.sid, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT64(buf, len, tok->tt.subj64.tid.port, tok->len, err); + if(err) { + return -1; + } + + READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.tid.addr, tok->len, err); + if(err) { + return -1; + } + + return 0; +} + +static void print_subject64_tok(FILE *fp, tokenstr_t *tok, char *del, + char raw, char sfrm) +{ + print_tok_type(fp, tok->id, "subject", raw); + print_delim(fp, del); + print_user(fp, tok->tt.subj64.auid, raw); + print_delim(fp, del); + print_user(fp, tok->tt.subj64.euid, raw); + print_delim(fp, del); + print_group(fp, tok->tt.subj64.egid, raw); + print_delim(fp, del); + print_user(fp, tok->tt.subj64.ruid, raw); + print_delim(fp, del); + print_group(fp, tok->tt.subj64.rgid, raw); + print_delim(fp, del); + print_4_bytes(fp, tok->tt.subj64.pid, "%u"); + print_delim(fp, del); + print_4_bytes(fp, tok->tt.subj64.sid, "%u"); + print_delim(fp, del); + print_8_bytes(fp, tok->tt.subj64.tid.port, "%llu"); + print_delim(fp, del); + print_ip_address(fp, tok->tt.subj64.tid.addr); +} + +/* + * audit ID 4 bytes + * euid 4 bytes + * egid 4 bytes + * ruid 4 bytes + * rgid 4 bytes + * pid 4 bytes + * sessid 4 bytes + * terminal ID * portid 4 bytes * type 4 bytes * machine id 16 bytes @@ -2039,6 +2289,9 @@ case AU_HEADER_32_TOKEN : return fetch_header32_tok(tok, buf, len); + case AU_HEADER_64_TOKEN : + return fetch_header64_tok(tok, buf, len); + case AU_TRAILER_TOKEN : return fetch_trailer_tok(tok, buf, len); @@ -2051,6 +2304,9 @@ case AU_ATTR32_TOKEN : return fetch_attr32_tok(tok, buf, len); + case AU_ATTR64_TOKEN : + return fetch_attr64_tok(tok, buf, len); + case AU_EXIT_TOKEN : return fetch_exit_tok(tok, buf, len); @@ -2117,6 +2373,9 @@ case AU_SUBJECT_32_TOKEN : return fetch_subject32_tok(tok, buf, len); + case AU_SUBJECT_64_TOKEN : + return fetch_subject64_tok(tok, buf, len); + case AU_SUBJECT_32_EX_TOKEN : return fetch_subject32ex_tok(tok, buf, len); @@ -2144,6 +2403,9 @@ case AU_HEADER_32_TOKEN : return print_header32_tok(outfp, tok, del, raw, sfrm); + case AU_HEADER_64_TOKEN: + return print_header64_tok(outfp, tok, del, raw, sfrm); + case AU_TRAILER_TOKEN : return print_trailer_tok(outfp, tok, del, raw, sfrm); @@ -2159,6 +2421,9 @@ case AU_ATTR32_TOKEN : return print_attr32_tok(outfp, tok, del, raw, sfrm); + case AU_ATTR64_TOKEN : + return print_attr64_tok(outfp, tok, del, raw, sfrm); + case AU_EXIT_TOKEN : return print_exit_tok(outfp, tok, del, raw, sfrm); @@ -2225,6 +2490,9 @@ case AU_SUBJECT_32_TOKEN : return print_subject32_tok(outfp, tok, del, raw, sfrm); + case AU_SUBJECT_64_TOKEN : + return print_subject64_tok(outfp, tok, del, raw, sfrm); + case AU_SUBJECT_32_EX_TOKEN : return print_subject32ex_tok(outfp, tok, del, raw, sfrm); From owner-p4-projects@FreeBSD.ORG Sun May 1 21:49:26 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6C52F16A4D0; Sun, 1 May 2005 21:49:26 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4507B16A4CE for ; Sun, 1 May 2005 21:49:26 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4FE4843D41 for ; Sun, 1 May 2005 21:49:25 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41LnPgC078344 for ; Sun, 1 May 2005 21:49:25 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41LnM3Q078341 for perforce@freebsd.org; Sun, 1 May 2005 21:49:22 GMT (envelope-from sam@freebsd.org) Date: Sun, 1 May 2005 21:49:22 GMT Message-Id: <200505012149.j41LnM3Q078341@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76337 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 21:49:27 -0000 http://perforce.freebsd.org/chv.cgi?CH=76337 Change 76337 by sam@sam_ebb on 2005/05/01 21:48:33 IFC @ 76336 Affected files ... .. //depot/projects/wifi/Makefile.inc1#17 integrate .. //depot/projects/wifi/bin/csh/Makefile#2 integrate .. //depot/projects/wifi/bin/csh/config.h#4 integrate .. //depot/projects/wifi/bin/csh/config_p.h#1 branch .. //depot/projects/wifi/bin/ps/ps.1#8 integrate .. //depot/projects/wifi/contrib/bsnmp/NEWS#3 integrate .. //depot/projects/wifi/contrib/bsnmp/VERSION#3 integrate .. //depot/projects/wifi/contrib/bsnmp/gensnmptree/gensnmptree.c#3 integrate .. //depot/projects/wifi/contrib/bsnmp/oid-list#2 integrate .. //depot/projects/wifi/contrib/bsnmp/snmp_ntp/BEGEMOT-NTP-MIB.txt#1 branch .. //depot/projects/wifi/contrib/bsnmp/snmp_ntp/NTP-MIB.txt#1 branch .. //depot/projects/wifi/contrib/bsnmp/snmp_ntp/NTP-PROXY-MIB.txt#1 branch .. //depot/projects/wifi/contrib/bsnmp/snmp_ntp/ntp_tree.def#1 branch .. //depot/projects/wifi/contrib/bsnmp/snmp_ntp/snmp_ntp.c#1 branch .. //depot/projects/wifi/contrib/bsnmp/snmpd/main.c#3 integrate .. //depot/projects/wifi/contrib/cvs/src/login.c#2 integrate .. //depot/projects/wifi/contrib/cvs/src/patch.c#2 integrate .. //depot/projects/wifi/contrib/cvs/src/rcs.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/BNF#2 integrate .. //depot/projects/wifi/contrib/ipfilter/BSD/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/BSD/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/BSD/Makefile.ipsend#2 integrate .. //depot/projects/wifi/contrib/ipfilter/BSD/kupgrade#2 integrate .. //depot/projects/wifi/contrib/ipfilter/BSD/make-devices#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FWTK/fwtk-2.1-transparency.txt#2 delete .. //depot/projects/wifi/contrib/ipfilter/FWTK/fwtk_transparent.diff#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FWTK/fwtkp#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FWTK/tproxy.diff#2 delete .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-2.2/files.diffs#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-2.2/files.newconf.diffs#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-2.2/kinstall#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-3/INST.FreeBSD-3#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-3/kinstall#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-4.0/INST.FreeBSD-4#2 delete .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-4.0/ipv6-patch-4.0#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-4.0/ipv6-patch-4.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-4.0/ipv6-patch-4.2#1 branch .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-4.0/kinstall#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD-4.0/unkinstall#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD/files.diffs#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD/files.newconf.diffs#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD/files.oldconf.diffs#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD/filez.diffs#2 integrate .. //depot/projects/wifi/contrib/ipfilter/FreeBSD/kinstall#2 integrate .. //depot/projects/wifi/contrib/ipfilter/HISTORY#2 integrate .. //depot/projects/wifi/contrib/ipfilter/INST.FreeBSD-2.2#2 integrate .. //depot/projects/wifi/contrib/ipfilter/INSTALL.FreeBSD#2 integrate .. //depot/projects/wifi/contrib/ipfilter/IPFILTER.LICENCE#2 integrate .. //depot/projects/wifi/contrib/ipfilter/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/README#2 integrate .. //depot/projects/wifi/contrib/ipfilter/STYLE.TXT#1 branch .. //depot/projects/wifi/contrib/ipfilter/UPGRADE_NOTICE#2 delete .. //depot/projects/wifi/contrib/ipfilter/WhatsNew40.txt#1 branch .. //depot/projects/wifi/contrib/ipfilter/bpf-ipf.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/bpf.h#2 delete .. //depot/projects/wifi/contrib/ipfilter/bpf_filter.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/bsdinstall#2 integrate .. //depot/projects/wifi/contrib/ipfilter/common.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/etc/protocols#2 integrate .. //depot/projects/wifi/contrib/ipfilter/etc/services#2 integrate .. //depot/projects/wifi/contrib/ipfilter/facpri.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/facpri.h#2 delete .. //depot/projects/wifi/contrib/ipfilter/fils.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/inet_addr.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ip_fil.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_fil_freebsd.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_htable.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_htable.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_irc_pxy.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_lfil.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ip_lookup.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_lookup.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_msnrpc_pxy.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_pool.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_pool.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_pptp_pxy.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_rpcb_pxy.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_scan.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_scan.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_sfil.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ip_sync.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ip_sync.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/ipf.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipf.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipfs.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipft_ef.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipft_hx.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipft_pc.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipft_sn.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipft_td.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipft_tx.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/iplang/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/iplang/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/iplang/iplang.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/iplang/iplang_l.l#2 integrate .. //depot/projects/wifi/contrib/ipfilter/iplang/iplang_y.y#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipmon.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipmon.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/ipnat.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipsd/Celler/ip_compat.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/ipsd.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/ipsd.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/ipsdr.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/linux.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/sbpf.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/sdlpi.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/slinux.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsd/snit.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/.OLD/ip_compat.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/ipsend/44arp.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/arp.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/dlcommon.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/dltest.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/hpux.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/in_var.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ip.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ip_var.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ipresend.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ipresend.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ipsend.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ipsend.5#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ipsend.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ipsend.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ipsopt.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/iptest.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/iptest.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/iptests.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/larp.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/linux.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/lsock.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/resend.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/sbpf.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/sdlpi.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/sirix.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/slinux.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/snit.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/sock.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/sockraw.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/ipsend/tcpip.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/ipsend/ultrix.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipt.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ipt.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/kmem.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/kmem.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/l4check/http.ok#2 integrate .. //depot/projects/wifi/contrib/ipfilter/l4check/l4check.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/lib/Makefile#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/addicmp.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/addipopt.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/addkeep.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/bcopywrap.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/binprint.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/buildopts.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/checkrev.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/count4bits.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/count6bits.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/debug.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/extras.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/facpri.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/facpri.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/fill6bits.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/flags.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/genmask.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/gethost.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/getifname.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/getline.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/getnattype.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/getport.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/getportproto.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/getproto.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/getsumd.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/hexdump.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/hostmask.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/hostname.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/hostnum.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/icmpcode.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/inet_addr.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/initparse.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ionames.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipf_dotuning.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipft_ef.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipft_hx.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipft_pc.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipft_sn.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipft_td.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipft_tx.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ipoptsec.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/kmem.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/kmem.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/kmemcpywrap.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/kvatoname.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/load_hash.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/load_hashnode.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/load_pool.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/load_poolnode.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/loglevel.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/make_range.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/mutex_emul.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/nametokva.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/nat_setgroupmap.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/natparse.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ntomask.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/optname.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/optprint.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/optprintv6.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/optvalue.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/parse.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/portname.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/portnum.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ports.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/print_toif.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printactivenat.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printaps.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printbuf.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printfr.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printfraginfo.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printhash.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printhashnode.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printhostmap.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printhostmask.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printifname.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printip.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printlog.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printmask.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printnat.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printpacket.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printpacket6.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printpool.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printpoolnode.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printportcmp.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printsbuf.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printstate.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/printtunable.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ratoi.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/ratoui.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/remove_hash.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/remove_hashnode.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/remove_pool.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/remove_poolnode.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/resetlexer.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/rwlock_emul.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/tcp_flags.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/tcpflags.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/tcpoptnames.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/to_interface.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/v6ionames.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/v6optvalue.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/var.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/lib/verbose.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipf.4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipf.5#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipf.8#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipfilter.4#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/ipfilter.4.mandoc#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/ipfs.8#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipfstat.8#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipftest.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipl.4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipmon.5#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/ipmon.8#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipnat.5#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ipnat.8#2 integrate .. //depot/projects/wifi/contrib/ipfilter/man/ippool.5#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/ippool.8#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/ipscan.5#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/ipscan.8#1 branch .. //depot/projects/wifi/contrib/ipfilter/man/mkfilters.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/md5.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/md5.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/misc.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/ml_ipl.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/mlf_ipl.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/mlf_rule.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/mlfk_rule.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/mlh_rule.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/mli_ipl.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/mln_ipl.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/mls_ipl.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/natparse.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/net/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/opt.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/opts.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/parse.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/pcap-ipf.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/pcap.h#2 delete .. //depot/projects/wifi/contrib/ipfilter/perl/ipf-mrtg.pl#2 integrate .. //depot/projects/wifi/contrib/ipfilter/perl/ipfmeta.pl#1 branch .. //depot/projects/wifi/contrib/ipfilter/perl/logfilter.pl#2 integrate .. //depot/projects/wifi/contrib/ipfilter/printnat.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/printstate.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/radix.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/radix_ipf.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/relay.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/rules/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/rules/example.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.10#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.11#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.12#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.13#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.2#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.3#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.5#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.6#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.7#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.8#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.9#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/example.sr#2 integrate .. //depot/projects/wifi/contrib/ipfilter/rules/ip_rules#1 branch .. //depot/projects/wifi/contrib/ipfilter/rules/ipmon.conf#1 branch .. //depot/projects/wifi/contrib/ipfilter/rules/pool.conf#1 branch .. //depot/projects/wifi/contrib/ipfilter/samples/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/samples/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/samples/ipfilter-pb.gif#2 integrate .. //depot/projects/wifi/contrib/ipfilter/samples/proxy.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/samples/relay.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/samples/userauth.c#2 integrate .. //depot/projects/wifi/contrib/ipfilter/snoop.h#2 integrate .. //depot/projects/wifi/contrib/ipfilter/solaris.c#2 delete .. //depot/projects/wifi/contrib/ipfilter/test/.cvsignore#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/Makefile#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/bpftest#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/dotest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/dotest6#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/bpf-f1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/bpf1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/f17#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i11#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i12#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i13#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/i14#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/i15#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/i2#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i3#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i5#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i6#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i7#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/i9#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/in1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/in2#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/in5#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/in6#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ip1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/l1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/l1.b#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/n1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/n10#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/n11#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/n12#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/n4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/n5#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/n7#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/n8#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/n9#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni10#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni11#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni12#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni13#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni14#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni15#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni16#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni2#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni3#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni5#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni6#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni7#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni8#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/expected/ni9#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/p1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/p2#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/expected/p3#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/hextest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/f11#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/f12#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/f13#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/f17#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/ipv6.1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/l1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/n1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/n10#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/n11#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/n12#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/n4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/n8#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/n9#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/ni1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/ni10#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/ni12#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/ni13#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/ni14#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/ni15#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/ni16#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/ni6#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/ni7#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/input/ni9#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/p1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/p2#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/input/p3#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/intest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/iptest#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/itest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/logtest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/mhtest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/mtest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/natipftest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/nattest#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/ptest#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/bpf-f1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/bpf1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/i1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/i11#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/i12#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/i13#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/i14#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/i15#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/i2#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/i3#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/i4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/i6#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/i9#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/in1#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/in2#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/in5#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/in6#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ip1#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/n10#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/n11#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/n12#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/n4#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/n7#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/n8#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/n9#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni10.nat#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni11.nat#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni12.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni12.nat#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni13.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni13.nat#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni14.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni14.nat#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni15.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni15.nat#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni16.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni16.nat#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni6.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni6.nat#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni7.nat#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni8.nat#2 integrate .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni9.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/ni9.nat#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/p1.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/p1.pool#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/p2.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/p3.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/regress/p3.pool#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/test.format#1 branch .. //depot/projects/wifi/contrib/ipfilter/test/vfycksum.pl#2 integrate .. //depot/projects/wifi/contrib/ipfilter/todo#2 delete .. //depot/projects/wifi/contrib/ipfilter/tools/BNF.ipf#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/BNF.ipnat#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/Makefile#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipf.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipf_y.y#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipfcomp.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipfs.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipfstat.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipftest.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipmon.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipmon_y.y#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipnat.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipnat_y.y#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ippool.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ippool_y.y#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipscan_y.y#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipsyncm.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/ipsyncs.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/lex_var.h#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/lexer.c#1 branch .. //depot/projects/wifi/contrib/ipfilter/tools/lexer.h#1 branch .. //depot/projects/wifi/contrib/tcsh/Fixes#2 integrate .. //depot/projects/wifi/contrib/tcsh/Imakefile#2 integrate .. //depot/projects/wifi/contrib/tcsh/Makefile.in#2 integrate .. //depot/projects/wifi/contrib/tcsh/Makefile.std#2 integrate .. //depot/projects/wifi/contrib/tcsh/Makefile.vms#2 integrate .. //depot/projects/wifi/contrib/tcsh/README#2 integrate .. //depot/projects/wifi/contrib/tcsh/complete.tcsh#2 integrate .. //depot/projects/wifi/contrib/tcsh/config.h.in#2 integrate .. //depot/projects/wifi/contrib/tcsh/config/bsd4.4#2 integrate .. //depot/projects/wifi/contrib/tcsh/config_f.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/configure#2 integrate .. //depot/projects/wifi/contrib/tcsh/configure.in#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.chared.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.decls.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.defns.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.init.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.inputl.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.refresh.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.screen.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.term.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.term.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/ed.xmap.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/gethost.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/glob.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/glob.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/host.defs#2 integrate .. //depot/projects/wifi/contrib/tcsh/install-sh#2 integrate .. //depot/projects/wifi/contrib/tcsh/ma.setp.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/nls/C/set11#2 integrate .. //depot/projects/wifi/contrib/tcsh/nls/ja/set1#2 integrate .. //depot/projects/wifi/contrib/tcsh/nls/ja/set3#1 branch .. //depot/projects/wifi/contrib/tcsh/nls/ja/set4#1 branch .. //depot/projects/wifi/contrib/tcsh/nls/ja/set7#1 branch .. //depot/projects/wifi/contrib/tcsh/patchlevel.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.char.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.decls.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.dir.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.dol.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.err.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.exec.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.exp.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.file.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.func.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.glob.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.hist.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.init.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.lex.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.misc.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.parse.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.print.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.proc.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.proc.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.sem.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.set.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.time.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/sh.types.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.alloc.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.bind.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.const.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.decls.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.disc.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.func.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.nls.c#1 branch .. //depot/projects/wifi/contrib/tcsh/tc.nls.h#1 branch .. //depot/projects/wifi/contrib/tcsh/tc.os.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.os.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.printf.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.prompt.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.sched.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.sig.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.sig.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.str.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.vers.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.wait.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tc.who.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tcsh.man#2 integrate .. //depot/projects/wifi/contrib/tcsh/tcsh.man2html#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.color.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.comp.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.decls.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.h#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.help.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.init.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.parse.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/tw.spell.c#2 integrate .. //depot/projects/wifi/contrib/tcsh/vms.termcap.c#2 integrate .. //depot/projects/wifi/etc/Makefile#5 integrate .. //depot/projects/wifi/etc/pam.d/xdm#2 integrate .. //depot/projects/wifi/etc/rc#2 integrate .. //depot/projects/wifi/etc/rc.d/Makefile#8 integrate .. //depot/projects/wifi/etc/rc.d/initdiskless#4 delete .. //depot/projects/wifi/etc/rc.d/jail#5 integrate .. //depot/projects/wifi/etc/rc.d/named#5 integrate .. //depot/projects/wifi/etc/rc.d/preseedrandom#2 delete .. //depot/projects/wifi/etc/rc.d/rcconf.sh#2 integrate .. //depot/projects/wifi/etc/rc.initdiskless#2 integrate .. //depot/projects/wifi/games/factor/Makefile#3 integrate .. //depot/projects/wifi/games/fortune/datfiles/startrek#2 integrate .. //depot/projects/wifi/gnu/lib/libdialog/Makefile#3 integrate .. //depot/projects/wifi/gnu/lib/libstdc++/Makefile#4 integrate .. //depot/projects/wifi/include/Makefile#10 integrate .. //depot/projects/wifi/include/netdb.h#4 integrate .. //depot/projects/wifi/lib/libarchive/Makefile#9 integrate .. //depot/projects/wifi/lib/libarchive/archive_platform.h#3 integrate .. //depot/projects/wifi/lib/libarchive/archive_write_set_format_pax.c#7 integrate .. //depot/projects/wifi/lib/libarchive/configure.ac.in#3 integrate .. //depot/projects/wifi/lib/libatm/Makefile#2 integrate .. //depot/projects/wifi/lib/libc/amd64/string/strcpy.S#2 integrate .. //depot/projects/wifi/lib/libc/amd64/sys/cerror.S#2 integrate .. //depot/projects/wifi/lib/libc/i386/gen/_set_tp.c#4 integrate .. //depot/projects/wifi/lib/libc/i386/string/bcmp.S#2 integrate .. //depot/projects/wifi/lib/libc/i386/sys/Makefile.inc#4 integrate .. //depot/projects/wifi/lib/libc/i386/sys/_amd64_get_fsbase.c#3 delete .. //depot/projects/wifi/lib/libc/i386/sys/_amd64_get_gsbase.c#3 delete .. //depot/projects/wifi/lib/libc/i386/sys/_amd64_set_fsbase.c#2 delete .. //depot/projects/wifi/lib/libc/i386/sys/_amd64_set_gsbase.c#2 delete .. //depot/projects/wifi/lib/libc/net/getaddrinfo.3#4 integrate .. //depot/projects/wifi/lib/libc/net/gethostbydns.c#3 integrate .. //depot/projects/wifi/lib/libc/net/gethostbyht.c#3 integrate .. //depot/projects/wifi/lib/libc/net/gethostbyname.3#2 integrate .. //depot/projects/wifi/lib/libc/net/gethostbynis.c#2 integrate .. //depot/projects/wifi/lib/libc/net/gethostnamadr.c#2 integrate .. //depot/projects/wifi/lib/libc/net/getipnodebyname.3#3 integrate .. //depot/projects/wifi/lib/libc/net/getnameinfo.3#4 integrate .. //depot/projects/wifi/lib/libc/net/getnetbydns.c#2 integrate .. //depot/projects/wifi/lib/libc/net/getnetbyht.c#3 integrate .. //depot/projects/wifi/lib/libc/net/getnetbynis.c#2 integrate .. //depot/projects/wifi/lib/libc/net/getnetent.3#2 integrate .. //depot/projects/wifi/lib/libc/net/getnetnamadr.c#2 integrate .. //depot/projects/wifi/lib/libc/net/getprotoent.3#3 integrate .. //depot/projects/wifi/lib/libc/net/getprotoent.c#4 integrate .. //depot/projects/wifi/lib/libc/net/getservent.3#2 integrate .. //depot/projects/wifi/lib/libc/net/getservent.c#5 integrate .. //depot/projects/wifi/lib/libc/net/map_v4v6.c#2 integrate .. //depot/projects/wifi/lib/libc/net/name6.c#5 integrate .. //depot/projects/wifi/lib/libc/net/netdb_private.h#3 integrate .. //depot/projects/wifi/lib/libc/regex/cclass.h#2 delete .. //depot/projects/wifi/lib/libdevstat/devstat.c#2 integrate .. //depot/projects/wifi/lib/libnetgraph/debug.c#2 integrate .. //depot/projects/wifi/lib/libnetgraph/msg.c#3 integrate .. //depot/projects/wifi/lib/libnetgraph/sock.c#2 integrate .. //depot/projects/wifi/lib/libopie/Makefile#2 integrate .. //depot/projects/wifi/lib/libpmc/libpmc.c#3 integrate .. //depot/projects/wifi/lib/libpmc/pmc.3#2 integrate .. //depot/projects/wifi/lib/libpthread/arch/i386/i386/pthread_md.c#4 integrate .. //depot/projects/wifi/lib/libpthread/arch/i386/include/pthread_md.h#4 integrate .. //depot/projects/wifi/lib/libthr/Makefile#5 integrate .. //depot/projects/wifi/lib/libthr/arch/i386/i386/pthread_md.c#3 integrate .. //depot/projects/wifi/lib/libthr/arch/i386/include/pthread_md.h#3 integrate .. //depot/projects/wifi/lib/libthr/support/Makefile.inc#1 branch .. //depot/projects/wifi/lib/libthr/thread/thr_create.c#4 integrate .. //depot/projects/wifi/lib/libugidfw/ugidfw.c#4 integrate .. //depot/projects/wifi/lib/libutil/login_cap.c#2 integrate .. //depot/projects/wifi/lib/libz/ChangeLog#2 integrate .. //depot/projects/wifi/lib/libz/FAQ#2 integrate .. //depot/projects/wifi/lib/libz/README#2 integrate .. //depot/projects/wifi/lib/libz/gzio.c#2 integrate .. //depot/projects/wifi/lib/libz/zconf.h#2 integrate .. //depot/projects/wifi/lib/libz/zlib.h#2 integrate .. //depot/projects/wifi/lib/msun/src/s_ceill.c#2 integrate .. //depot/projects/wifi/lib/msun/src/s_floorl.c#2 integrate .. //depot/projects/wifi/lib/msun/src/s_truncl.c#2 integrate .. //depot/projects/wifi/libexec/rtld-elf/i386/reloc.c#4 integrate .. //depot/projects/wifi/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#11 integrate .. //depot/projects/wifi/release/doc/ru_RU.KOI8-R/hardware/common/artheader.sgml#2 integrate .. //depot/projects/wifi/release/doc/ru_RU.KOI8-R/hardware/common/dev.sgml#4 integrate .. //depot/projects/wifi/release/doc/ru_RU.KOI8-R/share/examples/dev-auto-translate.pl#2 integrate .. //depot/projects/wifi/release/doc/ru_RU.KOI8-R/share/sgml/dev-auto-ru.sgml#2 integrate .. //depot/projects/wifi/rescue/rescue/Makefile#12 integrate .. //depot/projects/wifi/sbin/Makefile#6 integrate .. //depot/projects/wifi/sbin/fdisk/fdisk.c#3 integrate .. //depot/projects/wifi/sbin/geom/class/mirror/gmirror.8#8 integrate .. //depot/projects/wifi/sbin/geom/class/stripe/gstripe.8#8 integrate .. //depot/projects/wifi/sbin/geom/core/geom.c#6 integrate .. //depot/projects/wifi/sbin/gpt/add.c#3 integrate .. //depot/projects/wifi/sbin/gpt/gpt.8#5 integrate .. //depot/projects/wifi/sbin/gpt/gpt.c#3 integrate .. //depot/projects/wifi/sbin/gpt/gpt.h#3 integrate .. //depot/projects/wifi/sbin/gpt/remove.c#3 integrate .. //depot/projects/wifi/sbin/ipf/Makefile#3 integrate .. //depot/projects/wifi/sbin/ipf/Makefile.inc#1 branch .. //depot/projects/wifi/sbin/ipf/ipf/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ipfs/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ipfstat/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ipftest/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ipmon/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ipnat/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ippool/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ipresend/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/ipsend/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/iptest/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/libipf/Makefile#1 branch .. //depot/projects/wifi/sbin/ipf/rules/Makefile#1 branch .. //depot/projects/wifi/sbin/ipfs/Makefile#3 delete .. //depot/projects/wifi/sbin/ipfstat/Makefile#2 delete .. //depot/projects/wifi/sbin/ipfw/ipfw2.c#9 integrate .. //depot/projects/wifi/sbin/ipmon/Makefile#3 delete .. //depot/projects/wifi/sbin/ipnat/Makefile#2 delete .. //depot/projects/wifi/share/man/man4/acpi.4#7 integrate .. //depot/projects/wifi/share/man/man4/ataraid.4#2 integrate .. //depot/projects/wifi/share/man/man4/ath.4#9 integrate .. //depot/projects/wifi/share/man/man4/faith.4#3 integrate .. //depot/projects/wifi/share/man/man4/sk.4#3 integrate .. //depot/projects/wifi/share/man/man5/nsswitch.conf.5#4 integrate .. //depot/projects/wifi/share/man/man5/rc.conf.5#14 integrate .. //depot/projects/wifi/share/mk/sys.mk#5 integrate .. //depot/projects/wifi/share/mklocale/be_BY.CP1131.src#2 integrate .. //depot/projects/wifi/sys/alpha/alpha/vm_machdep.c#6 integrate .. //depot/projects/wifi/sys/amd64/amd64/mp_machdep.c#6 integrate .. //depot/projects/wifi/sys/amd64/amd64/trap.c#4 integrate .. //depot/projects/wifi/sys/amd64/amd64/vm_machdep.c#8 integrate .. //depot/projects/wifi/sys/amd64/conf/NOTES#10 integrate .. //depot/projects/wifi/sys/amd64/include/smp.h#5 integrate .. //depot/projects/wifi/sys/arm/arm/fusu.S#5 integrate .. //depot/projects/wifi/sys/arm/arm/vm_machdep.c#7 integrate .. //depot/projects/wifi/sys/arm/xscale/i80321/iq31244_machdep.c#10 integrate .. //depot/projects/wifi/sys/boot/i386/boot0/Makefile#3 integrate .. //depot/projects/wifi/sys/compat/linux/linux_misc.c#7 integrate .. //depot/projects/wifi/sys/compat/ndis/kern_ndis.c#11 integrate .. //depot/projects/wifi/sys/compat/ndis/kern_windrv.c#6 integrate .. //depot/projects/wifi/sys/compat/ndis/ntoskrnl_var.h#11 integrate .. //depot/projects/wifi/sys/compat/ndis/subr_hal.c#9 integrate .. //depot/projects/wifi/sys/compat/ndis/subr_ndis.c#12 integrate .. //depot/projects/wifi/sys/compat/ndis/subr_ntoskrnl.c#13 integrate .. //depot/projects/wifi/sys/conf/NOTES#21 integrate .. //depot/projects/wifi/sys/conf/files#24 integrate .. //depot/projects/wifi/sys/conf/files.amd64#12 integrate .. //depot/projects/wifi/sys/conf/files.i386#17 integrate .. //depot/projects/wifi/sys/conf/files.ia64#4 integrate .. //depot/projects/wifi/sys/conf/files.pc98#9 integrate .. //depot/projects/wifi/sys/conf/kern.post.mk#7 integrate .. //depot/projects/wifi/sys/conf/kmod.mk#13 integrate .. //depot/projects/wifi/sys/conf/options#16 integrate .. //depot/projects/wifi/sys/conf/options.amd64#4 integrate .. //depot/projects/wifi/sys/conf/options.i386#6 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/fil.c#5 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_auth.c#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_auth.h#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_compat.h#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_fil.c#3 delete .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_fil.h#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_frag.c#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_frag.h#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_ftp_pxy.c#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_htable.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_htable.h#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_ipsec_pxy.c#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_irc_pxy.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_log.c#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_lookup.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_lookup.h#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_nat.c#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_nat.h#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_netbios_pxy.c#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_pool.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_pool.h#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_pptp_pxy.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_proxy.c#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_proxy.h#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_raudio_pxy.c#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_rcmd_pxy.c#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_rpcb_pxy.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_rules.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_rules.h#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_scan.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_scan.h#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_state.c#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_state.h#3 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_sync.c#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ip_sync.h#1 branch .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/ipl.h#2 integrate .. //depot/projects/wifi/sys/contrib/ipfilter/netinet/mlfk_ipl.c#4 integrate .. //depot/projects/wifi/sys/contrib/pf/net/pf.c#9 integrate .. //depot/projects/wifi/sys/dev/acpica/Osd/OsdSchedule.c#3 integrate .. //depot/projects/wifi/sys/dev/acpica/acpivar.h#9 integrate .. //depot/projects/wifi/sys/dev/arcmsr/arcmsr.c#3 integrate .. //depot/projects/wifi/sys/dev/asr/asr.c#5 integrate .. //depot/projects/wifi/sys/dev/ata/ata-all.c#9 integrate .. //depot/projects/wifi/sys/dev/ata/ata-all.h#7 integrate .. //depot/projects/wifi/sys/dev/ata/ata-card.c#7 integrate .. //depot/projects/wifi/sys/dev/ata/ata-cbus.c#6 integrate .. //depot/projects/wifi/sys/dev/ata/ata-chipset.c#10 integrate .. //depot/projects/wifi/sys/dev/ata/ata-disk.c#8 integrate .. //depot/projects/wifi/sys/dev/ata/ata-dma.c#5 integrate .. //depot/projects/wifi/sys/dev/ata/ata-isa.c#5 integrate .. //depot/projects/wifi/sys/dev/ata/ata-lowlevel.c#10 integrate .. //depot/projects/wifi/sys/dev/ata/ata-pci.c#6 integrate .. //depot/projects/wifi/sys/dev/ata/ata-pci.h#7 integrate .. //depot/projects/wifi/sys/dev/ata/ata-queue.c#6 integrate .. //depot/projects/wifi/sys/dev/ata/ata-raid.c#7 integrate .. //depot/projects/wifi/sys/dev/ata/ata-raid.h#5 integrate .. //depot/projects/wifi/sys/dev/ata/ata_if.m#3 integrate .. //depot/projects/wifi/sys/dev/ata/atapi-cam.c#4 integrate .. //depot/projects/wifi/sys/dev/ata/atapi-cd.c#7 integrate .. //depot/projects/wifi/sys/dev/ata/atapi-fd.c#5 integrate .. //depot/projects/wifi/sys/dev/ata/atapi-tape.c#6 integrate .. //depot/projects/wifi/sys/dev/bge/if_bge.c#8 integrate .. //depot/projects/wifi/sys/dev/ciss/ciss.c#7 integrate .. //depot/projects/wifi/sys/dev/drm/drm_bufs.c#2 integrate .. //depot/projects/wifi/sys/dev/esp/ncr53c9x.c#5 integrate .. //depot/projects/wifi/sys/dev/fxp/if_fxp.c#9 integrate .. //depot/projects/wifi/sys/dev/fxp/if_fxpreg.h#4 integrate .. //depot/projects/wifi/sys/dev/fxp/rcvbundl.h#3 integrate .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_amd.c#1 branch .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_intel.c#1 branch .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_mod.c#1 branch .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_pentium.c#1 branch .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_piv.c#1 branch .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_ppro.c#1 branch .. //depot/projects/wifi/sys/dev/if_ndis/if_ndis.c#15 integrate .. //depot/projects/wifi/sys/dev/if_ndis/if_ndis_pccard.c#5 integrate .. //depot/projects/wifi/sys/dev/if_ndis/if_ndis_pci.c#7 integrate .. //depot/projects/wifi/sys/dev/if_ndis/if_ndis_usb.c#2 integrate .. //depot/projects/wifi/sys/dev/if_ndis/if_ndisvar.h#7 integrate .. //depot/projects/wifi/sys/dev/ips/ips.c#3 integrate .. //depot/projects/wifi/sys/dev/musycc/musycc.c#3 delete .. //depot/projects/wifi/sys/dev/nve/if_nve.c#2 integrate .. //depot/projects/wifi/sys/dev/pci/pci.c#15 integrate .. //depot/projects/wifi/sys/dev/pci/pci_pci.c#4 integrate .. //depot/projects/wifi/sys/dev/pci/pcireg.h#5 integrate .. //depot/projects/wifi/sys/dev/pci/pcivar.h#3 integrate .. //depot/projects/wifi/sys/dev/puc/pucdata.c#6 integrate .. //depot/projects/wifi/sys/dev/sound/usb/uaudio.c#4 integrate .. //depot/projects/wifi/sys/dev/sound/usb/uaudio.h#4 integrate .. //depot/projects/wifi/sys/dev/sound/usb/uaudio_pcm.c#6 integrate .. //depot/projects/wifi/sys/dev/twa/tw_osl_cam.c#2 integrate .. //depot/projects/wifi/sys/dev/uart/uart_dev_z8530.c#5 integrate .. //depot/projects/wifi/sys/dev/vge/if_vge.c#5 integrate .. //depot/projects/wifi/sys/fs/devfs/devfs_vfsops.c#9 integrate .. //depot/projects/wifi/sys/fs/nullfs/null_vnops.c#11 integrate .. //depot/projects/wifi/sys/fs/pseudofs/pseudofs_vnops.c#8 integrate .. //depot/projects/wifi/sys/fs/unionfs/union_subr.c#8 integrate .. //depot/projects/wifi/sys/fs/unionfs/union_vfsops.c#7 integrate .. //depot/projects/wifi/sys/geom/mirror/g_mirror_ctl.c#7 integrate .. //depot/projects/wifi/sys/geom/vinum/geom_vinum_init.c#5 integrate .. //depot/projects/wifi/sys/hwpmc/hwpmc_amd.c#3 delete .. //depot/projects/wifi/sys/hwpmc/hwpmc_intel.c#3 delete .. //depot/projects/wifi/sys/hwpmc/hwpmc_mod.c#3 delete .. //depot/projects/wifi/sys/hwpmc/hwpmc_pentium.c#3 delete .. //depot/projects/wifi/sys/hwpmc/hwpmc_piv.c#3 delete .. //depot/projects/wifi/sys/hwpmc/hwpmc_ppro.c#3 delete .. //depot/projects/wifi/sys/i386/acpica/acpi_wakecode.S#2 integrate .. //depot/projects/wifi/sys/i386/conf/NOTES#15 integrate .. //depot/projects/wifi/sys/i386/conf/PAE#5 integrate .. //depot/projects/wifi/sys/i386/i386/mp_machdep.c#9 integrate .. //depot/projects/wifi/sys/i386/i386/support.s#3 integrate .. //depot/projects/wifi/sys/i386/i386/trap.c#5 integrate .. //depot/projects/wifi/sys/i386/i386/vm_machdep.c#12 integrate .. //depot/projects/wifi/sys/i386/ibcs2/imgact_coff.c#4 integrate .. //depot/projects/wifi/sys/i386/include/pmc_mdep.h#3 integrate .. //depot/projects/wifi/sys/i386/include/smp.h#5 integrate .. //depot/projects/wifi/sys/ia64/ia64/clock.c#3 integrate .. //depot/projects/wifi/sys/ia64/ia64/clock_if.m#3 delete .. //depot/projects/wifi/sys/ia64/ia64/eficlock.c#2 delete .. //depot/projects/wifi/sys/ia64/ia64/vm_machdep.c#6 integrate .. //depot/projects/wifi/sys/ia64/include/clockvar.h#3 delete .. //depot/projects/wifi/sys/kern/init_sysent.c#10 integrate .. //depot/projects/wifi/sys/kern/kern_exec.c#11 integrate .. //depot/projects/wifi/sys/kern/kern_exit.c#8 integrate .. //depot/projects/wifi/sys/kern/kern_kse.c#7 integrate .. //depot/projects/wifi/sys/kern/kern_mac.c#5 integrate .. //depot/projects/wifi/sys/kern/kern_thr.c#5 integrate .. //depot/projects/wifi/sys/kern/kern_thread.c#8 integrate .. //depot/projects/wifi/sys/kern/subr_kdb.c#3 integrate .. //depot/projects/wifi/sys/kern/subr_smp.c#3 integrate .. //depot/projects/wifi/sys/kern/subr_taskqueue.c#2 integrate .. //depot/projects/wifi/sys/kern/subr_witness.c#9 integrate .. //depot/projects/wifi/sys/kern/syscalls.c#10 integrate .. //depot/projects/wifi/sys/kern/syscalls.master#11 integrate .. //depot/projects/wifi/sys/kern/uipc_usrreq.c#9 integrate .. //depot/projects/wifi/sys/kern/vfs_aio.c#8 integrate .. //depot/projects/wifi/sys/kern/vfs_bio.c#11 integrate .. //depot/projects/wifi/sys/kern/vfs_cluster.c#9 integrate .. //depot/projects/wifi/sys/kern/vfs_subr.c#23 integrate .. //depot/projects/wifi/sys/kern/vfs_vnops.c#14 integrate .. //depot/projects/wifi/sys/libkern/crc32.c#3 integrate .. //depot/projects/wifi/sys/modules/Makefile#22 integrate .. //depot/projects/wifi/sys/modules/acpi/acpi/Makefile#3 integrate .. //depot/projects/wifi/sys/modules/hwpmc/Makefile#2 integrate .. //depot/projects/wifi/sys/modules/if_ndis/Makefile#2 integrate .. //depot/projects/wifi/sys/modules/ipfilter/Makefile#4 integrate .. //depot/projects/wifi/sys/modules/puc/Makefile#1 branch .. //depot/projects/wifi/sys/netinet/ip_fw2.c#10 integrate .. //depot/projects/wifi/sys/netinet/ip_icmp.c#4 integrate .. //depot/projects/wifi/sys/netinet/ip_icmp.h#3 integrate .. //depot/projects/wifi/sys/netinet/libalias/HISTORY#1 branch .. //depot/projects/wifi/sys/netinet/libalias/Makefile#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias.h#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_cuseeme.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_db.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_ftp.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_irc.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_local.h#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_nbt.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_old.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_pptp.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_proxy.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_skinny.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_smedia.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/alias_util.c#1 branch .. //depot/projects/wifi/sys/netinet/libalias/libalias.3#1 branch .. //depot/projects/wifi/sys/netinet/tcp_output.c#6 integrate .. //depot/projects/wifi/sys/netinet/tcp_sack.c#10 integrate .. //depot/projects/wifi/sys/netinet/tcp_subr.c#12 integrate .. //depot/projects/wifi/sys/netinet/tcp_syncache.c#5 integrate .. //depot/projects/wifi/sys/netinet/tcp_var.h#9 integrate .. //depot/projects/wifi/sys/nfs4client/nfs4_vnops.c#12 integrate .. //depot/projects/wifi/sys/nfsclient/bootp_subr.c#4 integrate .. //depot/projects/wifi/sys/nfsclient/nfs_diskless.c#3 integrate .. //depot/projects/wifi/sys/nfsclient/nfs_vfsops.c#9 integrate .. //depot/projects/wifi/sys/pci/if_sk.c#12 integrate .. //depot/projects/wifi/sys/powerpc/powerpc/vm_machdep.c#6 integrate .. //depot/projects/wifi/sys/security/mac_bsdextended/mac_bsdextended.c#2 integrate .. //depot/projects/wifi/sys/sparc64/pci/apb.c#2 integrate .. //depot/projects/wifi/sys/sparc64/sparc64/vm_machdep.c#6 integrate .. //depot/projects/wifi/sys/sys/_task.h#2 integrate .. //depot/projects/wifi/sys/sys/libkern.h#3 integrate .. //depot/projects/wifi/sys/sys/lock.h#3 integrate .. //depot/projects/wifi/sys/sys/mutex.h#5 integrate .. //depot/projects/wifi/sys/sys/namei.h#6 integrate .. //depot/projects/wifi/sys/sys/param.h#11 integrate .. //depot/projects/wifi/sys/sys/pcpu.h#3 integrate .. //depot/projects/wifi/sys/sys/pmc.h#3 integrate .. //depot/projects/wifi/sys/sys/proc.h#14 integrate .. //depot/projects/wifi/sys/sys/ptrace.h#2 integrate .. //depot/projects/wifi/sys/sys/smp.h#3 integrate .. //depot/projects/wifi/sys/sys/syscall.h#9 integrate .. //depot/projects/wifi/sys/sys/syscall.mk#9 integrate .. //depot/projects/wifi/sys/sys/sysproto.h#9 integrate .. //depot/projects/wifi/sys/sys/systm.h#13 integrate .. //depot/projects/wifi/sys/sys/taskqueue.h#2 integrate .. //depot/projects/wifi/sys/sys/thr.h#3 integrate .. //depot/projects/wifi/sys/sys/vnode.h#22 integrate .. //depot/projects/wifi/sys/ufs/ffs/ffs_rawread.c#8 integrate .. //depot/projects/wifi/sys/vm/swap_pager.c#7 integrate .. //depot/projects/wifi/sys/vm/uma_core.c#9 integrate .. //depot/projects/wifi/sys/vm/uma_int.h#6 integrate .. //depot/projects/wifi/sys/vm/vm_init.c#3 integrate .. //depot/projects/wifi/tools/regression/tls/Makefile#2 integrate .. //depot/projects/wifi/tools/regression/tls/ttls4/Makefile#1 branch .. //depot/projects/wifi/tools/regression/tls/ttls4/ttls4.c#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/README#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/all.sh#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t0/Makefile#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t0/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t0/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t0/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t0/libtest.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t0/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t1/Makefile#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t1/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t1/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t1/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t1/libtest.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t1/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t2/Makefile#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t2/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t2/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t2/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t2/libtest.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/archives/t2/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t0/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t0/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t0/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t0/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t1/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t1/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t1/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t1/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t2/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t2/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t2/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t2/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t3/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t3/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t3/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/basic/t3/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/common.sh#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t0/Makefile#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t0/TEST1.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t0/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t0/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t0/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t0/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t1/Makefile#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t1/TEST1.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t1/TEST2.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t1/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t1/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t1/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t1/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t2/Makefile#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t2/TEST1.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t2/TEST2.a#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t2/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t2/expected.stderr#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t2/expected.stdout#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/suffixes/t2/test.t#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/variables/t0/expected.status#1 branch .. //depot/projects/wifi/tools/regression/usr.bin/make/variables/t0/expected.stderr#1 branch >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Sun May 1 22:12:58 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id A112B16A4D0; Sun, 1 May 2005 22:12:57 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 648F616A4CE for ; Sun, 1 May 2005 22:12:57 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D8E1443D2F for ; Sun, 1 May 2005 22:12:56 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41MCuTw079616 for ; Sun, 1 May 2005 22:12:56 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41MCutH079613 for perforce@freebsd.org; Sun, 1 May 2005 22:12:56 GMT (envelope-from sam@freebsd.org) Date: Sun, 1 May 2005 22:12:56 GMT Message-Id: <200505012212.j41MCutH079613@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76346 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 22:12:58 -0000 http://perforce.freebsd.org/chv.cgi?CH=76346 Change 76346 by sam@sam_ebb on 2005/05/01 22:12:29 IFC @ 76340 Affected files ... .. //depot/projects/wifi/sys/conf/options.pc98#5 integrate .. //depot/projects/wifi/sys/dev/ata/ata-chipset.c#11 integrate .. //depot/projects/wifi/sys/dev/ata/ata-dma.c#6 integrate .. //depot/projects/wifi/sys/dev/ata/ata-lowlevel.c#11 integrate .. //depot/projects/wifi/sys/dev/ata/ata-pci.c#7 integrate .. //depot/projects/wifi/sys/dev/ata/ata-raid.h#6 integrate .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_amd.c#2 integrate .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_intel.c#2 integrate .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_mod.c#2 integrate .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_piv.c#2 integrate .. //depot/projects/wifi/sys/dev/hwpmc/hwpmc_ppro.c#2 integrate .. //depot/projects/wifi/sys/fs/devfs/devfs_vnops.c#21 integrate .. //depot/projects/wifi/sys/geom/geom_pc98_enc.c#2 integrate .. //depot/projects/wifi/sys/i386/include/pmc_mdep.h#4 integrate .. //depot/projects/wifi/sys/kern/kern_exec.c#12 integrate .. //depot/projects/wifi/sys/kern/subr_taskqueue.c#3 integrate .. //depot/projects/wifi/sys/kern/vfs_cluster.c#10 integrate .. //depot/projects/wifi/sys/kern/vfs_default.c#17 integrate .. //depot/projects/wifi/sys/kern/vfs_mount.c#20 integrate .. //depot/projects/wifi/sys/kern/vfs_subr.c#24 integrate .. //depot/projects/wifi/sys/netinet/tcp_usrreq.c#11 integrate .. //depot/projects/wifi/sys/pc98/conf/NOTES#10 integrate .. //depot/projects/wifi/sys/powerpc/powermac/ata_kauai.c#8 integrate .. //depot/projects/wifi/sys/powerpc/powermac/ata_macio.c#8 integrate .. //depot/projects/wifi/sys/sys/diskpc98.h#3 integrate .. //depot/projects/wifi/sys/sys/pmc.h#4 integrate .. //depot/projects/wifi/sys/sys/taskqueue.h#3 integrate Differences ... ==== //depot/projects/wifi/sys/conf/options.pc98#5 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/options.pc98,v 1.183 2005/04/15 14:24:49 nyan Exp $ +# $FreeBSD: src/sys/conf/options.pc98,v 1.184 2005/05/01 03:59:25 nyan Exp $ # Options specific to the pc98 platform kernels AUTO_EOI_1 opt_auto_eoi.h @@ -102,3 +102,6 @@ DEV_APIC opt_apic.h DEV_MECIA opt_mecia.h DEV_NPX opt_npx.h + +# Debugging +KDB_STOP_NMI opt_global.h ==== //depot/projects/wifi/sys/dev/ata/ata-chipset.c#11 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ata/ata-chipset.c,v 1.114 2005/04/30 16:22:06 sos Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ata/ata-chipset.c,v 1.115 2005/05/01 12:24:45 sos Exp $"); #include "opt_ata.h" #include @@ -2004,7 +2004,7 @@ static int ata_promise_mio_dmastart(device_t dev) { - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); ch->flags |= ATA_DMA_ACTIVE; return 0; @@ -2013,7 +2013,7 @@ static int ata_promise_mio_dmastop(device_t dev) { - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); ch->flags &= ~ATA_DMA_ACTIVE; /* get status XXX SOS */ @@ -2428,8 +2428,8 @@ static int ata_promise_new_dmastart(device_t dev) { - struct ata_pci_controller *ctlr = device_get_softc(GRANDPARENT(dev)); - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_pci_controller *ctlr = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); if (ch->flags & ATA_48BIT_ACTIVE) { ATA_OUTB(ctlr->r_res1, 0x11, @@ -2451,8 +2451,8 @@ static int ata_promise_new_dmastop(device_t dev) { - struct ata_pci_controller *ctlr = device_get_softc(GRANDPARENT(dev)); - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_pci_controller *ctlr = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); int error; if (ch->flags & ATA_48BIT_ACTIVE) { ==== //depot/projects/wifi/sys/dev/ata/ata-dma.c#6 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ata/ata-dma.c,v 1.135 2005/04/30 16:22:07 sos Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ata/ata-dma.c,v 1.136 2005/05/01 12:24:45 sos Exp $"); #include #include @@ -218,7 +218,7 @@ static int ata_dmaload(device_t dev, caddr_t data, int32_t count, int dir) { - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); struct ata_dmasetprd_args cba; if (ch->dma->flags & ATA_DMA_LOADED) { @@ -259,7 +259,7 @@ int ata_dmaunload(device_t dev) { - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); bus_dmamap_sync(ch->dma->sg_tag, ch->dma->sg_map, BUS_DMASYNC_POSTWRITE); bus_dmamap_sync(ch->dma->data_tag, ch->dma->data_map, ==== //depot/projects/wifi/sys/dev/ata/ata-lowlevel.c#11 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ata/ata-lowlevel.c,v 1.64 2005/04/30 16:22:07 sos Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ata/ata-lowlevel.c,v 1.65 2005/05/01 12:24:45 sos Exp $"); #include "opt_ata.h" #include @@ -129,7 +129,7 @@ /* ATA DMA data transfer commands */ case ATA_R_DMA: /* check sanity, setup SG list and DMA engine */ - if (ch->dma->load(request->dev, request->data, request->bytecount, + if (ch->dma->load(ch->dev, request->data, request->bytecount, request->flags & ATA_R_READ)) { device_printf(request->dev, "setting up DMA failed\n"); request->result = EIO; @@ -147,7 +147,7 @@ } /* start DMA engine */ - if (ch->dma->start(request->dev)) { + if (ch->dma->start(ch->dev)) { device_printf(request->dev, "error starting DMA\n"); request->result = EIO; goto begin_finished; @@ -218,7 +218,7 @@ } /* check sanity, setup SG list and DMA engine */ - if (ch->dma->load(request->dev, request->data, request->bytecount, + if (ch->dma->load(ch->dev, request->data, request->bytecount, request->flags & ATA_R_READ)) { device_printf(request->dev, "setting up DMA failed\n"); request->result = EIO; @@ -261,7 +261,7 @@ ATA_PROTO_ATAPI_12 ? 6 : 8); /* start DMA engine */ - if (ch->dma->start(request->dev)) { + if (ch->dma->start(ch->dev)) { request->result = EIO; goto begin_finished; } @@ -272,7 +272,7 @@ begin_finished: if (ch->dma && ch->dma->flags & ATA_DMA_LOADED) - ch->dma->unload(request->dev); + ch->dma->unload(ch->dev); return ATA_OP_FINISHED; begin_continue: @@ -390,7 +390,7 @@ /* stop DMA engine and get status */ if (ch->dma->stop) - request->dmastat = ch->dma->stop(request->dev); + request->dmastat = ch->dma->stop(ch->dev); /* did we get error or data */ if (request->status & ATA_S_ERROR) @@ -401,7 +401,7 @@ request->donecount = request->bytecount; /* release SG list etc */ - ch->dma->unload(request->dev); + ch->dma->unload(ch->dev); /* done with HW */ goto end_finished; @@ -502,7 +502,7 @@ /* stop the engine and get engine status */ if (ch->dma->stop) - request->dmastat = ch->dma->stop(request->dev); + request->dmastat = ch->dma->stop(ch->dev); /* did we get error or data */ if (request->status & (ATA_S_ERROR | ATA_S_DWF)) @@ -513,7 +513,7 @@ request->donecount = request->bytecount; /* release SG list etc */ - ch->dma->unload(request->dev); + ch->dma->unload(ch->dev); /* done with HW */ goto end_finished; ==== //depot/projects/wifi/sys/dev/ata/ata-pci.c#7 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ata/ata-pci.c,v 1.101 2005/04/30 16:22:07 sos Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ata/ata-pci.c,v 1.102 2005/05/01 12:24:45 sos Exp $"); #include "opt_ata.h" #include @@ -419,7 +419,7 @@ static int ata_pci_dmastart(device_t dev) { - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); ATA_IDX_OUTB(ch, ATA_BMSTAT_PORT, (ATA_IDX_INB(ch, ATA_BMSTAT_PORT) | (ATA_BMSTAT_INTERRUPT | ATA_BMSTAT_ERROR))); @@ -435,7 +435,7 @@ static int ata_pci_dmastop(device_t dev) { - struct ata_channel *ch = device_get_softc(device_get_parent(dev)); + struct ata_channel *ch = device_get_softc(dev); int error; ATA_IDX_OUTB(ch, ATA_BMCMD_PORT, ==== //depot/projects/wifi/sys/dev/ata/ata-raid.h#6 (text+ko) ==== @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/ata/ata-raid.h,v 1.32 2005/04/30 16:22:07 sos Exp $ + * $FreeBSD: src/sys/dev/ata/ata-raid.h,v 1.33 2005/05/01 08:45:12 sos Exp $ */ /* misc defines */ @@ -522,7 +522,7 @@ /* Promise FastTrak Metadata */ #define PR_LBA(dev) \ - (((struct ad_softc *)device_get_ivars(dev))->total_secs - 63) + (((((struct ad_softc *)device_get_ivars(dev))->total_secs / (((struct ad_softc *)device_get_ivars(dev))->heads * ((struct ad_softc *)device_get_ivars(dev))->sectors)) * ((struct ad_softc *)device_get_ivars(dev))->heads * ((struct ad_softc *)device_get_ivars(dev))->sectors) - ((struct ad_softc *)device_get_ivars(dev))->sectors) struct promise_raid_conf { char promise_id[24]; ==== //depot/projects/wifi/sys/dev/hwpmc/hwpmc_amd.c#2 (text+ko) ==== @@ -26,7 +26,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/hwpmc/hwpmc_amd.c,v 1.4 2005/04/28 08:13:18 jkoshy Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/hwpmc/hwpmc_amd.c,v 1.5 2005/05/01 14:11:48 jkoshy Exp $"); /* Support for the AMD K7 and later processors */ @@ -360,7 +360,7 @@ ("[amd,%d] No owner for HWPMC [cpu%d,pmc%d]", __LINE__, cpu, ri)); - mode = pm->pm_mode; + mode = PMC_TO_MODE(pm); PMCDBG(MDP,REA,1,"amd-read id=%d class=%d", ri, pd->pm_descr.pd_class); @@ -413,7 +413,7 @@ ("[amd,%d] PMC not owned (cpu%d,pmc%d)", __LINE__, cpu, ri)); - mode = pm->pm_mode; + mode = PMC_TO_MODE(pm); if (pd->pm_descr.pd_class == PMC_CLASS_TSC) return 0; @@ -461,6 +461,18 @@ } /* + * Retrieve a configured PMC pointer from hardware state. + */ + +static int +amd_get_config(int cpu, int ri, struct pmc **ppm) +{ + *ppm = pmc_pcpu[cpu]->pc_hwpmcs[ri]->phw_pmc; + + return 0; +} + +/* * Machine dependent actions taken during the context switch in of a * thread. */ @@ -471,10 +483,10 @@ (void) pc; PMCDBG(MDP,SWI,1, "pc=%p pp=%p enable-msr=%d", pc, pp, - (pp->pp_flags & PMC_FLAG_ENABLE_MSR_ACCESS) != 0); + (pp->pp_flags & PMC_PP_ENABLE_MSR_ACCESS) != 0); /* enable the RDPMC instruction if needed */ - if (pp->pp_flags & PMC_FLAG_ENABLE_MSR_ACCESS) + if (pp->pp_flags & PMC_PP_ENABLE_MSR_ACCESS) load_cr4(rcr4() | CR4_PCE); return 0; @@ -492,7 +504,7 @@ (void) pp; /* can be NULL */ PMCDBG(MDP,SWO,1, "pc=%p pp=%p enable-msr=%d", pc, pp, pp ? - (pp->pp_flags & PMC_FLAG_ENABLE_MSR_ACCESS) == 1 : 0); + (pp->pp_flags & PMC_PP_ENABLE_MSR_ACCESS) == 1 : 0); /* always turn off the RDPMC instruction */ load_cr4(rcr4() & ~CR4_PCE); @@ -523,7 +535,7 @@ pd = &amd_pmcdesc[ri].pm_descr; /* check class match */ - if (pd->pd_class != pm->pm_class) + if (pd->pd_class != a->pm_class) return EINVAL; caps = pm->pm_caps; @@ -765,7 +777,7 @@ continue; } - mode = pm->pm_mode; + mode = PMC_TO_MODE(pm); if (PMC_IS_SAMPLING_MODE(mode) && AMD_PMC_HAS_OVERFLOWED(perfctr)) { atomic_add_int(&pmc_stats.pm_intr_processed, 1); @@ -803,8 +815,6 @@ return error; pi->pm_class = pd->pm_descr.pd_class; - pi->pm_caps = pd->pm_descr.pd_caps; - pi->pm_width = pd->pm_descr.pd_width; if (phw->phw_state & PMC_PHW_FLAG_IS_ENABLED) { pi->pm_enabled = TRUE; @@ -982,8 +992,17 @@ /* this processor has two classes of usable PMCs */ pmc_mdep->pmd_nclass = 2; - pmc_mdep->pmd_classes[0] = PMC_CLASS_TSC; - pmc_mdep->pmd_classes[1] = AMD_PMC_CLASS; + + /* TSC */ + pmc_mdep->pmd_classes[0].pm_class = PMC_CLASS_TSC; + pmc_mdep->pmd_classes[0].pm_caps = PMC_CAP_READ; + pmc_mdep->pmd_classes[0].pm_width = 64; + + /* AMD K7/K8 PMCs */ + pmc_mdep->pmd_classes[1].pm_class = AMD_PMC_CLASS; + pmc_mdep->pmd_classes[1].pm_caps = AMD_PMC_CAPS; + pmc_mdep->pmd_classes[1].pm_width = 48; + pmc_mdep->pmd_nclasspmcs[0] = 1; pmc_mdep->pmd_nclasspmcs[1] = (AMD_NPMCS-1); @@ -994,6 +1013,7 @@ pmc_mdep->pmd_read_pmc = amd_read_pmc; pmc_mdep->pmd_write_pmc = amd_write_pmc; pmc_mdep->pmd_config_pmc = amd_config_pmc; + pmc_mdep->pmd_get_config = amd_get_config; pmc_mdep->pmd_allocate_pmc = amd_allocate_pmc; pmc_mdep->pmd_release_pmc = amd_release_pmc; pmc_mdep->pmd_start_pmc = amd_start_pmc; ==== //depot/projects/wifi/sys/dev/hwpmc/hwpmc_intel.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/hwpmc/hwpmc_intel.c,v 1.3 2005/04/27 05:51:13 jkoshy Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/hwpmc/hwpmc_intel.c,v 1.4 2005/05/01 14:11:48 jkoshy Exp $"); #include #include @@ -92,7 +92,9 @@ pmc_mdep->pmd_cputype = cputype; pmc_mdep->pmd_nclass = 2; - pmc_mdep->pmd_classes[0] = PMC_CLASS_TSC; + pmc_mdep->pmd_classes[0].pm_class = PMC_CLASS_TSC; + pmc_mdep->pmd_classes[0].pm_caps = PMC_CAP_READ; + pmc_mdep->pmd_classes[0].pm_width = 64; pmc_mdep->pmd_nclasspmcs[0] = 1; error = 0; ==== //depot/projects/wifi/sys/dev/hwpmc/hwpmc_mod.c#2 (text+ko) ==== @@ -26,7 +26,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/hwpmc/hwpmc_mod.c,v 1.6 2005/04/28 08:13:18 jkoshy Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/hwpmc/hwpmc_mod.c,v 1.7 2005/05/01 14:11:48 jkoshy Exp $"); #include #include @@ -151,12 +151,14 @@ static struct pmc *pmc_find_pmc_descriptor_in_process(struct pmc_owner *po, pmc_id_t pmc); static void pmc_release_pmc_descriptor(struct pmc *pmc); -static int pmc_can_allocate_rowindex(struct proc *p, unsigned int ri); +static int pmc_can_allocate_rowindex(struct proc *p, unsigned int ri, + int cpu); static struct pmc_process *pmc_find_process_descriptor(struct proc *p, uint32_t mode); static void pmc_remove_process_descriptor(struct pmc_process *pp); static struct pmc_owner *pmc_find_owner_descriptor(struct proc *p); static int pmc_find_pmc(pmc_id_t pmcid, struct pmc **pm); +static void pmc_force_context_switch(void); static void pmc_remove_owner(struct pmc_owner *po); static void pmc_maybe_remove_owner(struct pmc_owner *po); static void pmc_unlink_target_process(struct pmc *pmc, @@ -364,6 +366,7 @@ CMP_SET_FLAG_MIN("cfg", CFG); CMP_SET_FLAG_MIN("sta", STA); CMP_SET_FLAG_MIN("sto", STO); + CMP_SET_FLAG_MIN("int", INT); CMP_SET_FLAG_MIN("bnd", BND); CMP_SET_FLAG_MIN("sel", SEL); else /* unrecognized keyword */ @@ -573,6 +576,27 @@ } /* + * Force a context switch. + * + * We do this by tsleep'ing for 1 tick -- invoking mi_switch() is not + * guaranteed to force a context switch. + */ + +static void +pmc_force_context_switch(void) +{ + u_char curpri; + + mtx_lock_spin(&sched_lock); + curpri = curthread->td_priority; + mtx_unlock_spin(&sched_lock); + + (void) tsleep((void *) pmc_force_context_switch, curpri, + "pmcctx", 1); + +} + +/* * Update the per-pmc histogram */ @@ -671,7 +695,7 @@ * XXX rework needed. */ - if (po->po_flags & PMC_FLAG_OWNS_LOGFILE) + if (po->po_flags & PMC_PO_OWNS_LOGFILE) pmc_configure_log(po, -1); } @@ -693,7 +717,7 @@ */ if (LIST_EMPTY(&po->po_pmcs) && - ((po->po_flags & PMC_FLAG_OWNS_LOGFILE) == 0)) { + ((po->po_flags & PMC_PO_OWNS_LOGFILE) == 0)) { pmc_remove_owner(po); FREE(po, M_PMC); } @@ -718,7 +742,7 @@ ("[pmc,%d] Illegal reference count %d for process record %p", __LINE__, pp->pp_refcnt, (void *) pp)); - ri = pm->pm_rowindex; + ri = PMC_TO_ROWINDEX(pm); PMCDBG(PRC,TLK,1, "link-target pmc=%p ri=%d pmc-process=%p", pm, ri, pp); @@ -740,12 +764,10 @@ atomic_store_rel_ptr(&pp->pp_pmcs[ri].pp_pmc, pm); if (pm->pm_owner->po_owner == pp->pp_proc) - pp->pp_flags |= PMC_FLAG_ENABLE_MSR_ACCESS; + pm->pm_flags |= PMC_F_ATTACHED_TO_OWNER; pp->pp_refcnt++; - PMCDBG(PRC,TLK,2, "enable-msr %d", - (pp->pp_flags & PMC_FLAG_ENABLE_MSR_ACCESS) != 0); } /* @@ -767,7 +789,7 @@ ("[pmc,%d] Illegal ref count %d on process record %p", __LINE__, pp->pp_refcnt, (void *) pp)); - ri = pm->pm_rowindex; + ri = PMC_TO_ROWINDEX(pm); PMCDBG(PRC,TUL,1, "unlink-target pmc=%p ri=%d pmc-process=%p", pm, ri, pp); @@ -779,8 +801,11 @@ pp->pp_pmcs[ri].pp_pmc = NULL; pp->pp_pmcs[ri].pp_pmcval = (pmc_value_t) 0; - if (pm->pm_owner->po_owner == pp->pp_proc) - pp->pp_flags &= ~PMC_FLAG_ENABLE_MSR_ACCESS; + /* Remove owner-specific flags */ + if (pm->pm_owner->po_owner == pp->pp_proc) { + pp->pp_flags &= ~PMC_PP_ENABLE_MSR_ACCESS; + pm->pm_flags &= ~PMC_F_ATTACHED_TO_OWNER; + } pp->pp_refcnt--; @@ -792,9 +817,6 @@ KASSERT(ptgt != NULL, ("[pmc,%d] process %p (pp: %p) not found " "in pmc %p", __LINE__, pp->pp_proc, pp, pm)); - PMCDBG(PRC,TUL,4, "unlink ptgt=%p, enable-msr=%d", ptgt, - (pp->pp_flags & PMC_FLAG_ENABLE_MSR_ACCESS) != 0); - LIST_REMOVE(ptgt, pt_next); FREE(ptgt, M_PMC); } @@ -897,7 +919,7 @@ sx_assert(&pmc_sx, SX_XLOCKED); PMCDBG(PRC,ATT,2, "attach-one pm=%p ri=%d proc=%p (%d, %s)", pm, - pm->pm_rowindex, p, p->p_pid, p->p_comm); + PMC_TO_ROWINDEX(pm), p, p->p_pid, p->p_comm); /* * Locate the process descriptor corresponding to process 'p', @@ -910,7 +932,7 @@ * process descriptor and PMC. */ - ri = pm->pm_rowindex; + ri = PMC_TO_ROWINDEX(pm); if ((pp = pmc_find_process_descriptor(p, PMC_FLAG_ALLOCATE)) == NULL) return ENOMEM; @@ -944,7 +966,16 @@ sx_assert(&pmc_sx, SX_XLOCKED); PMCDBG(PRC,ATT,1, "attach pm=%p ri=%d proc=%p (%d, %s)", pm, - pm->pm_rowindex, p, p->p_pid, p->p_comm); + PMC_TO_ROWINDEX(pm), p, p->p_pid, p->p_comm); + + + /* + * If this PMC successfully allowed a GETMSR operation + * in the past, disallow further ATTACHes. + */ + + if ((pm->pm_flags & PMC_PP_ENABLE_MSR_ACCESS) != 0) + return EPERM; if ((pm->pm_flags & PMC_F_DESCENDANTS) == 0) return pmc_attach_one_process(p, pm); @@ -999,11 +1030,11 @@ KASSERT(pm != NULL, ("[pmc,%d] null pm pointer", __LINE__)); + ri = PMC_TO_ROWINDEX(pm); + PMCDBG(PRC,ATT,2, "detach-one pm=%p ri=%d proc=%p (%d, %s) flags=0x%x", - pm, pm->pm_rowindex, p, p->p_pid, p->p_comm, flags); + pm, ri, p, p->p_pid, p->p_comm, flags); - ri = pm->pm_rowindex; - if ((pp = pmc_find_process_descriptor(p, 0)) == NULL) return ESRCH; @@ -1049,7 +1080,7 @@ sx_assert(&pmc_sx, SX_XLOCKED); PMCDBG(PRC,ATT,1, "detach pm=%p ri=%d proc=%p (%d, %s)", pm, - pm->pm_rowindex, p, p->p_pid, p->p_comm); + PMC_TO_ROWINDEX(pm), p, p->p_pid, p->p_comm); if ((pm->pm_flags & PMC_F_DESCENDANTS) == 0) return pmc_detach_one_process(p, pm, PMC_FLAG_REMOVE); @@ -1131,7 +1162,6 @@ int cpu; unsigned int ri; struct pmc *pm; - struct pmc_hw *phw; struct pmc_process *pp; struct pmc_owner *po; struct proc *p; @@ -1183,22 +1213,22 @@ * state similar to the CSW_OUT code. */ - phw = pmc_pcpu[cpu]->pc_hwpmcs[ri]; - pm = phw->phw_pmc; + pm = NULL; + (void) (*md->pmd_get_config)(cpu, ri, &pm); PMCDBG(PRC,EXT,2, "ri=%d pm=%p", ri, pm); if (pm == NULL || - !PMC_IS_VIRTUAL_MODE(pm->pm_mode)) + !PMC_IS_VIRTUAL_MODE(PMC_TO_MODE(pm))) continue; PMCDBG(PRC,EXT,2, "ppmcs[%d]=%p pm=%p " "state=%d", ri, pp->pp_pmcs[ri].pp_pmc, pm, pm->pm_state); - KASSERT(pm->pm_rowindex == ri, + KASSERT(PMC_TO_ROWINDEX(pm) == ri, ("[pmc,%d] ri mismatch pmc(%d) ri(%d)", - __LINE__, pm->pm_rowindex, ri)); + __LINE__, PMC_TO_ROWINDEX(pm), ri)); KASSERT(pm == pp->pp_pmcs[ri].pp_pmc, ("[pmc,%d] pm %p != pp_pmcs[%d] %p", @@ -1222,10 +1252,11 @@ mtx_pool_unlock_spin(pmc_mtxpool, pm); } + atomic_subtract_rel_32(&pm->pm_runcount,1); + KASSERT((int) pm->pm_runcount >= 0, ("[pmc,%d] runcount is %d", __LINE__, ri)); - atomic_subtract_rel_32(&pm->pm_runcount,1); (void) md->pmd_config_pmc(cpu, ri, NULL); } @@ -1254,6 +1285,7 @@ FREE(pp, M_PMC); + } else critical_exit(); /* pp == NULL */ @@ -1445,13 +1477,13 @@ if ((pm = pp->pp_pmcs[ri].pp_pmc) == NULL) continue; - KASSERT(PMC_IS_VIRTUAL_MODE(pm->pm_mode), + KASSERT(PMC_IS_VIRTUAL_MODE(PMC_TO_MODE(pm)), ("[pmc,%d] Target PMC in non-virtual mode (%d)", - __LINE__, pm->pm_mode)); + __LINE__, PMC_TO_MODE(pm))); - KASSERT(pm->pm_rowindex == ri, + KASSERT(PMC_TO_ROWINDEX(pm) == ri, ("[pmc,%d] Row index mismatch pmc %d != ri %d", - __LINE__, pm->pm_rowindex, ri)); + __LINE__, PMC_TO_ROWINDEX(pm), ri)); /* * Only PMCs that are marked as 'RUNNING' need @@ -1510,7 +1542,6 @@ struct pmc *pm; struct proc *p; struct pmc_cpu *pc; - struct pmc_hw *phw; struct pmc_process *pp; pmc_value_t newvalue, tmp; @@ -1560,18 +1591,18 @@ for (ri = 0; ri < md->pmd_npmc; ri++) { - phw = pc->pc_hwpmcs[ri]; - pm = phw->phw_pmc; + pm = NULL; + (void) (*md->pmd_get_config)(cpu, ri, &pm); if (pm == NULL) /* nothing at this row index */ continue; - if (!PMC_IS_VIRTUAL_MODE(pm->pm_mode)) + if (!PMC_IS_VIRTUAL_MODE(PMC_TO_MODE(pm))) continue; /* not a process virtual PMC */ - KASSERT(pm->pm_rowindex == ri, + KASSERT(PMC_TO_ROWINDEX(pm) == ri, ("[pmc,%d] ri mismatch pmc(%d) ri(%d)", - __LINE__, pm->pm_rowindex, ri)); + __LINE__, PMC_TO_ROWINDEX(pm), ri)); /* Stop hardware */ md->pmd_stop_pmc(cpu, ri); @@ -1838,7 +1869,7 @@ volatile int maxloop; #endif u_int ri, cpu; - u_char curpri; + enum pmc_mode mode; struct pmc_hw *phw; struct pmc_process *pp; struct pmc_target *ptgt, *tmp; @@ -1848,16 +1879,17 @@ KASSERT(pm, ("[pmc,%d] null pmc", __LINE__)); - ri = pm->pm_rowindex; + ri = PMC_TO_ROWINDEX(pm); + mode = PMC_TO_MODE(pm); PMCDBG(PMC,REL,1, "release-pmc pmc=%p ri=%d mode=%d", pm, ri, - pm->pm_mode); + mode); /* * First, we take the PMC off hardware. */ cpu = 0; - if (PMC_IS_SYSTEM_MODE(pm->pm_mode)) { + if (PMC_IS_SYSTEM_MODE(mode)) { /* * A system mode PMC runs on a specific CPU. Switch @@ -1866,7 +1898,7 @@ pmc_save_cpu_binding(&pb); - cpu = pm->pm_gv.pm_cpu; + cpu = PMC_TO_CPU(pm); if (pm->pm_state == PMC_STATE_RUNNING) { @@ -1895,7 +1927,7 @@ pmc_restore_cpu_binding(&pb); - } else if (PMC_IS_VIRTUAL_MODE(pm->pm_mode)) { + } else if (PMC_IS_VIRTUAL_MODE(mode)) { /* * A virtual PMC could be running on multiple CPUs at @@ -1924,17 +1956,11 @@ maxloop--; KASSERT(maxloop > 0, ("[pmc,%d] (ri%d, rc%d) waiting too long for " - "pmc to be free", __LINE__, pm->pm_rowindex, - pm->pm_runcount)); + "pmc to be free", __LINE__, + PMC_TO_ROWINDEX(pm), pm->pm_runcount)); #endif - mtx_lock_spin(&sched_lock); - curpri = curthread->td_priority; - mtx_unlock_spin(&sched_lock); - - (void) tsleep((void *) pmc_release_pmc_descriptor, - curpri, "pmcrel", 1); - + pmc_force_context_switch(); } /* @@ -1977,7 +2003,7 @@ * Update row disposition */ - if (PMC_IS_SYSTEM_MODE(pm->pm_mode)) + if (PMC_IS_SYSTEM_MODE(PMC_TO_MODE(pm))) PMC_UNMARK_ROW_STANDALONE(ri); else PMC_UNMARK_ROW_THREAD(ri); @@ -2007,21 +2033,20 @@ if (pl == NULL) return ENOMEM; - if ((po = pmc_find_owner_descriptor(p)) == NULL) { + if ((po = pmc_find_owner_descriptor(p)) == NULL) if ((po = pmc_allocate_owner_descriptor(p)) == NULL) { FREE(pl, M_PMC); return ENOMEM; } - po->po_flags |= PMC_FLAG_IS_OWNER; /* real owner */ - } - if (pmc->pm_mode == PMC_MODE_TS) { + /* XXX is this too restrictive */ + if (PMC_ID_TO_MODE(pmc->pm_id) == PMC_MODE_TS) { /* can have only one TS mode PMC per process */ - if (po->po_flags & PMC_FLAG_HAS_TS_PMC) { + if (po->po_flags & PMC_PO_HAS_TS_PMC) { FREE(pl, M_PMC); return EINVAL; } - po->po_flags |= PMC_FLAG_HAS_TS_PMC; + po->po_flags |= PMC_PO_HAS_TS_PMC; } KASSERT(pmc->pm_owner == NULL, @@ -2067,22 +2092,41 @@ */ static int -pmc_can_allocate_rowindex(struct proc *p, unsigned int ri) +pmc_can_allocate_rowindex(struct proc *p, unsigned int ri, int cpu) { + enum pmc_mode mode; + struct pmc *pm; struct pmc_list *pl; struct pmc_owner *po; struct pmc_process *pp; - PMCDBG(PMC,ALR,1, "can-allocate-rowindex proc=%p (%d, %s) ri=%d", - p, p->p_pid, p->p_comm, ri); + PMCDBG(PMC,ALR,1, "can-allocate-rowindex proc=%p (%d, %s) ri=%d " + "cpu=%d", p, p->p_pid, p->p_comm, ri, cpu); - /* we shouldn't have allocated a PMC at row index 'ri' */ + /* + * We shouldn't have already allocated a process-mode PMC at + * row index 'ri'. + * + * We shouldn't have allocated a system-wide PMC on the same + * CPU and same RI. + */ if ((po = pmc_find_owner_descriptor(p)) != NULL) - LIST_FOREACH(pl, &po->po_pmcs, pl_next) - if (pl->pl_pmc->pm_rowindex == ri) - return EEXIST; + LIST_FOREACH(pl, &po->po_pmcs, pl_next) { + pm = pl->pl_pmc; + if (PMC_TO_ROWINDEX(pm) == ri) { + mode = PMC_TO_MODE(pm); + if (PMC_IS_VIRTUAL_MODE(mode)) + return EEXIST; + if (PMC_IS_SYSTEM_MODE(mode) && + (int) PMC_TO_CPU(pm) == cpu) + return EEXIST; + } + } - /* we shouldn't be the target of any PMC ourselves at this index */ + /* + * We also shouldn't be the target of any PMC at this index + * since otherwise a PMC_ATTACH to ourselves will fail. + */ if ((pp = pmc_find_process_descriptor(p, 0)) != NULL) if (pp->pp_pmcs[ri].pp_pmc) return EEXIST; @@ -2139,7 +2183,7 @@ } /* - * Find a PMC descriptor with user handle 'pmc' for thread 'td'. + * Find a PMC descriptor with user handle 'pmcid' for thread 'td'. */ static struct pmc * @@ -2147,12 +2191,12 @@ { struct pmc_list *pl; - KASSERT(pmcid < md->pmd_npmc, - ("[pmc,%d] Illegal pmc index %d (max %d)", __LINE__, pmcid, - md->pmd_npmc)); + KASSERT(PMC_ID_TO_ROWINDEX(pmcid) < md->pmd_npmc, + ("[pmc,%d] Illegal pmc index %d (max %d)", __LINE__, + PMC_ID_TO_ROWINDEX(pmcid), md->pmd_npmc)); LIST_FOREACH(pl, &po->po_pmcs, pl_next) - if (pl->pl_pmc->pm_rowindex == pmcid) + if (pl->pl_pmc->pm_id == pmcid) return pl->pl_pmc; return NULL; @@ -2187,17 +2231,21 @@ pmc_start(struct pmc *pm) { int error, cpu, ri; + enum pmc_mode mode; struct pmc_binding pb; KASSERT(pm != NULL, ("[pmc,%d] null pm", __LINE__)); - PMCDBG(PMC,OPS,1, "start pmc=%p mode=%d ri=%d", pm, pm->pm_mode, - pm->pm_rowindex); + mode = PMC_TO_MODE(pm); + ri = PMC_TO_ROWINDEX(pm); + error = 0; + + PMCDBG(PMC,OPS,1, "start pmc=%p mode=%d ri=%d", pm, mode, ri); pm->pm_state = PMC_STATE_RUNNING; - if (PMC_IS_VIRTUAL_MODE(pm->pm_mode)) { + if (PMC_IS_VIRTUAL_MODE(mode)) { /* * If a PMCATTACH hadn't been done on this @@ -2205,32 +2253,36 @@ */ if (LIST_EMPTY(&pm->pm_targets)) - return pmc_attach_process(pm->pm_owner->po_owner, pm); + error = pmc_attach_process(pm->pm_owner->po_owner, pm); + /* + * If the PMC is attached to its owner, then force a context + * switch to ensure that the MD state gets set correctly. + */ + if (error == 0 && (pm->pm_flags & PMC_F_ATTACHED_TO_OWNER)) + pmc_force_context_switch(); /* * Nothing further to be done; thread context switch code - * will start/stop the PMC as appropriate. + * will start/stop the hardware as appropriate. */ - return 0; + return error; } /* - * A system-mode PMC. Move to the CPU associated with this + * A system-wide PMC. Move to the CPU associated with this * PMC, and start the hardware. */ pmc_save_cpu_binding(&pb); - cpu = pm->pm_gv.pm_cpu; + cpu = PMC_TO_CPU(pm); if (pmc_cpu_is_disabled(cpu)) return ENXIO; - ri = pm->pm_rowindex; - pmc_select_cpu(cpu); /* @@ -2238,11 +2290,13 @@ * so write out the initial value and start the PMC. */ + critical_enter(); if ((error = md->pmd_write_pmc(cpu, ri, - PMC_IS_SAMPLING_MODE(pm->pm_mode) ? + PMC_IS_SAMPLING_MODE(mode) ? pm->pm_sc.pm_reloadcount : pm->pm_sc.pm_initial)) == 0) error = md->pmd_start_pmc(cpu, ri); + critical_exit(); pmc_restore_cpu_binding(&pb); @@ -2256,13 +2310,13 @@ static int pmc_stop(struct pmc *pm) { >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Sun May 1 22:37:27 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8BA6516A4D0; Sun, 1 May 2005 22:37:27 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 49F8616A4CE for ; Sun, 1 May 2005 22:37:27 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D766343D31 for ; Sun, 1 May 2005 22:37:26 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j41MbQId080708 for ; Sun, 1 May 2005 22:37:26 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j41MbQj2080705 for perforce@freebsd.org; Sun, 1 May 2005 22:37:26 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 1 May 2005 22:37:26 GMT Message-Id: <200505012237.j41MbQj2080705@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76347 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 May 2005 22:37:28 -0000 http://perforce.freebsd.org/chv.cgi?CH=76347 Change 76347 by rwatson@rwatson_paprika on 2005/05/01 22:36:36 When reading an IPv4 and IPv6 addresses in fetch_inaddr_ex_tok(), fetch_ip_tok(), fetch_process32ex_tok(), fetch_sock_inet32_tok(), fetch_socket_tok(), fetch_subject32_tok(), fetch_subject64_tok(), fetch_subject32ex_tok(), fetch_socketex32_tok(). This avoids converting the IPv4 addresses to local byte order, as we will later print them from network byte order using inet_ntoa(). Print IPv4 addresses using print_ip_address() in print_ip_tok(), rather than printing as a u_int32_t. Affected files ... .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#11 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#11 (text+ko) ==== @@ -1156,7 +1156,6 @@ static int fetch_inaddr_ex_tok(tokenstr_t *tok, char *buf, int len) { int err = 0; - int i; READ_TOKEN_U_INT32(buf, len, tok->tt.inaddr_ex.type, tok->len, err); if(err) { @@ -1164,19 +1163,17 @@ } if(tok->tt.inaddr_ex.type == AF_INET) { - READ_TOKEN_U_INT32(buf, len, tok->tt.inaddr_ex.addr[0], - tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.inaddr_ex.addr[0], + sizeof(tok->tt.inaddr_ex.addr[0]), tok->len, err); if(err) { return -1; } } else if (tok->tt.inaddr_ex.type == AF_INET6) { - for(i = 0; i < 4; i++) { - READ_TOKEN_U_INT32(buf, len, tok->tt.inaddr_ex.addr[i], - tok->len, err); - if(err) { - return -1; - } + READ_TOKEN_BYTES(buf, len, &tok->tt.inaddr_ex.addr, + sizeof(tok->tt.inaddr_ex.addr), tok->len, err); + if(err) { + return -1; } } else { @@ -1241,12 +1238,14 @@ return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.ip.src, tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.ip.src, sizeof(tok->tt.ip.src), + tok->len, err); if(err) { return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.ip.dest, tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.ip.dest, sizeof(tok->tt.ip.dest), + tok->len, err); if(err) { return -1; } @@ -1275,9 +1274,9 @@ print_delim(fp, del); print_2_bytes(fp, tok->tt.ip.chksm, "%u"); print_delim(fp, del); - print_4_bytes(fp, tok->tt.ip.src, "%#x"); + print_ip_address(fp, tok->tt.ip.src); print_delim(fp, del); - print_4_bytes(fp, tok->tt.ip.dest, "%#x"); + print_ip_address(fp, tok->tt.ip.dest); } /* @@ -1557,7 +1556,6 @@ static int fetch_process32ex_tok(tokenstr_t *tok, char *buf, int len) { int err = 0; - int i; READ_TOKEN_U_INT32(buf, len, tok->tt.proc32_ex.auid, tok->len, err); if(err) { @@ -1607,19 +1605,17 @@ } if(tok->tt.proc32_ex.tid.type == AF_INET) { - READ_TOKEN_U_INT32(buf, len, tok->tt.proc32_ex.tid.addr[0], - tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.proc32_ex.tid.addr[0], + sizeof(tok->tt.proc32_ex.tid.addr[0]), tok->len, err); if(err) { return -1; } } else if (tok->tt.proc32_ex.tid.type == AF_INET6) { - for(i = 0; i < 4; i++) { - READ_TOKEN_U_INT32(buf, len, - tok->tt.proc32_ex.tid.addr[i], tok->len, err); - if(err) { - return -1; - } + READ_TOKEN_BYTES(buf, len, &tok->tt.proc32_ex.tid.addr, + sizeof(tok->tt.proc32_ex.tid.addr), tok->len, err); + if(err) { + return -1; } } else { @@ -1756,7 +1752,8 @@ return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.sockinet32.addr, tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.sockinet32.addr, + sizeof(tok->tt.sockinet32.addr), tok->len, err); if(err) { return -1; } @@ -1826,7 +1823,8 @@ if(err) { return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.socket.l_addr, tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.socket.l_addr, + sizeof(tok->tt.socket.l_addr), tok->len, err); if(err) { return -1; } @@ -1834,7 +1832,8 @@ if(err) { return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.socket.r_addr, tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.socket.l_addr, + sizeof(tok->tt.socket.r_addr), tok->len, err); if(err) { return -1; } @@ -1913,7 +1912,8 @@ return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.subj32.tid.addr, tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.subj32.tid.addr, + sizeof(tok->tt.subj32.tid.addr), tok->len, err); if(err) { return -1; } @@ -2001,7 +2001,8 @@ return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.tid.addr, tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.subj64.tid.addr, + sizeof(tok->tt.subj64.tid.addr), tok->len, err); if(err) { return -1; } @@ -2049,7 +2050,6 @@ static int fetch_subject32ex_tok(tokenstr_t *tok, char *buf, int len) { int err = 0; - int i; READ_TOKEN_U_INT32(buf, len, tok->tt.subj32_ex.auid, tok->len, err); if(err) { @@ -2099,19 +2099,17 @@ } if(tok->tt.subj32_ex.tid.type == AF_INET) { - READ_TOKEN_U_INT32(buf, len, tok->tt.subj32_ex.tid.addr[0], - tok->len, err); + READ_TOKEN_BYTES(buf, len, &tok->tt.subj32_ex.tid.addr[0], + sizeof(tok->tt.subj32_ex.tid.addr[0]), tok->len, err); if(err) { return -1; } } else if (tok->tt.subj32_ex.tid.type == AF_INET6) { - for(i = 0; i < 4; i++) { - READ_TOKEN_U_INT32(buf, len, - tok->tt.subj32_ex.tid.addr[i], tok->len, err); - if(err) { - return -1; - } + READ_TOKEN_BYTES(buf, len, &tok->tt.subj32_ex.tid.addr, + sizeof(tok->tt.subj32_ex.tid.addr), tok->len, err); + if(err) { + return -1; } } else { @@ -2202,8 +2200,8 @@ if(err) { return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.socket_ex32.l_addr, tok->len, - err); + READ_TOKEN_BYTES(buf, len, &tok->tt.socket_ex32.l_addr, + sizeof(tok->tt.socket_ex32.l_addr), tok->len, err); if(err) { return -1; } @@ -2218,8 +2216,8 @@ if(err) { return -1; } - READ_TOKEN_U_INT32(buf, len, tok->tt.socket_ex32.r_addr, tok->len, - err); + READ_TOKEN_BYTES(buf, len, &tok->tt.socket_ex32.r_addr, + sizeof(tok->tt.socket_ex32.r_addr), tok->len, err); if(err) { return -1; } From owner-p4-projects@FreeBSD.ORG Mon May 2 01:10:32 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D929516A4D0; Mon, 2 May 2005 01:10:31 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7F51416A4CE for ; Mon, 2 May 2005 01:10:31 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 90BF243D2F for ; Mon, 2 May 2005 01:10:30 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j421AUqG092861 for ; Mon, 2 May 2005 01:10:30 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j421AUlQ092858 for perforce@freebsd.org; Mon, 2 May 2005 01:10:30 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Mon, 2 May 2005 01:10:30 GMT Message-Id: <200505020110.j421AUlQ092858@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76348 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2005 01:10:32 -0000 http://perforce.freebsd.org/chv.cgi?CH=76348 Change 76348 by rwatson@rwatson_paprika on 2005/05/02 01:09:58 Additional token types. Spell 'NULL-terminated' as 'nul-terminated'. Adjust column widths. Affected files ... .. //depot/projects/trustedbsd/openbsm/man/audit.log.5#2 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/man/audit.log.5#2 (text+ko) ==== @@ -78,13 +78,13 @@ .Dv file token can be created using .Xr au_to_file 3 . -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "Seconds" Ta "4 bytes" Ta "File time stamp" .It Li "Microseconds" Ta "4 bytes" Ta "File time stamp" .It Li "File name lengh" Ta "2 bytes" Ta "File name of audit trail" -.It Li "File pathname" Ta "N bytes + 1 NUL" Ta "File name of audit trail" +.It Li "File pathname" Ta "N bytes + 1 nul" Ta "File name of audit trail" .El .Ss Header Token The @@ -96,7 +96,7 @@ .Dv header token can be created using .Xr au_to_header32 3 . -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "Record Byte Count" Ta "4 bytes" Ta "Number of bytes in record" @@ -117,7 +117,7 @@ API cannot currently create an .Dv expanded header token. -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "Record Byte Count" Ta "4 bytes" Ta "Number of bytes in record" @@ -139,7 +139,7 @@ .Dv trailer token can be created using .Xr au_to_trailer 3 . -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "Trailer Magic" Ta "2 bytes" Ta "Trailer magic number" @@ -160,7 +160,7 @@ API cannot currently create an .Dv arbitrary data token. -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "How to Print" Ta "1 byte" Ta "User-defined printing information" @@ -182,7 +182,7 @@ .Pp See the BUGS section for information on the storage of this token. .Pp -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "IP Address Type" Ta "1 byte" Ta "Type of address" @@ -194,7 +194,7 @@ token ... .Pp See the BUGS section for information on the storage of this token. -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It XXXX @@ -207,7 +207,7 @@ .Dv ip token can be cread using .Xr au_to_ip 3 . -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "Version and IHL" Ta "1 byte" Ta "Version and IP header length" @@ -225,7 +225,7 @@ The .Dv expanded ip token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It XXXX @@ -238,7 +238,7 @@ .Dv iport token can be created using .Xr au_to_iport 3 . -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .It Li "Port Number" Ta "2 bytes" Ta "Port number in network byte order" @@ -246,40 +246,109 @@ .Ss Path Token The .Dv path -token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +token contains a pathname. +A +.Dv path +token can be created using +.Xr auto_path 3 . +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Path Length" Ta "2 bytes" Ta "Length of path in bytes" +.It Li "Path" Ta "N bytes + 1 nul" Ta "Path name" .El .Ss path_attr Token The .Dv path_attr -token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +token contains a set of nul-terminated path names. +The +.Xr libbsm 3 +API cannot currently create an +.Dv path_attr +token. +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Count" Ta "2 bytes" Ta "Number of nul-terminated string(s) in token" +.It Li "Path" Ta "Variable" Ta "count nul-terminated string(s)" .El .Ss Process Token The .Dv process -token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +token contains a description of the security properties of a process +involved in an audit event. +This includes both the traditional +.Ux +security properties, such as user IDs and group IDs, but also audit +information such as the audit user ID and sesion. +A +.Dv process +token can be created using +.Xr au_to_process32 3 +or +.Xr au_to_process64 3 . +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" +.It Sy "Field" Ta Sy Bytes Ta Sy Description +.It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Audit ID" Ta "4 bytes" Ta "Audit user ID" +.It Li "Effective User ID" Ta "4 bytes" Ta "Effective user ID" +.It Li "Effective Group ID "Ta "4 bytes" Ta "Effective group ID" +.It Li "Real User ID" Ta "4 bytes" Ta "Real user ID" +.It Li "Real Group ID" Ta "4 bytes" Ta "Real group ID" +.It Li "Process ID" Ta "4 bytes" Ta "Process ID" +.It Li "Session ID" Ta "4 bytes" Ta "Audit session ID" +.It Li "Terminal Port ID" Ta "4/8 bytes" Ta "Terminal port ID (32/64-bits)" +.It Li "Terminal Machine Address" Ta "4 bytes" Ta "IP address of machine" +.El +.Ss Expanded Process Token +The .Dv expanded process +token contains the contents of the +.Dv process +token, with the addition of a machine address type and variable length +address storage capable of containing IPv6 addresses. +A +.Dv expanded process +token can be created using +.Xr au_to_process32_ex 3 +or +.Xr au_to_process64 3 . +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Audit ID" Ta "4 bytes" Ta "Audit user ID" +.It Li "Effective User ID" Ta "4 bytes" Ta "Effective user ID" +.It Li "Effective Group ID "Ta "4 bytes" Ta "Effective group ID" +.It Li "Real User ID" Ta "4 bytes" Ta "Real user ID" +.It Li "Real Group ID" Ta "4 bytes" Ta "Real group ID" +.It Li "Process ID" Ta "4 bytes" Ta "Process ID" +.It Li "Session ID" Ta "4 bytes" Ta "Audit session ID" +.It Li "Terminal Port ID" Ta "4/8 bytes" Ta "Terminal port ID (32/64-bits)" +.It Li "Terminal Address Type/Length" Ta "1 byte" "Length of machine address" +.It Li "Terminal Machine Address" Ta "4 bytes" Ta "IPv4 or IPv6 address of machine" .El .Ss Return Token The .Dv return -token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +token contains a system call or library function return condition, including +return value and error number associated with the global variable +.Er errno . +A +.Dv return +token can be created using +.Xr au_to_return 3 +or +.Xr au_to_return64 3 . +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Error Number" Ta "1 byte" Ta "Errno value, or 0 if undefined" +.It Li "Return Value" Ta "4/8 bytes" Ta "Return value (32/64-bits)" .El .Ss Subject Token The .Dv subject token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -287,7 +356,7 @@ The .Dv expanded subject token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -295,7 +364,7 @@ The .Dv System V IPC token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -303,7 +372,7 @@ The .Dv text token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -311,7 +380,7 @@ The .Dv attribute token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -319,7 +388,7 @@ The .Dv groups token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -327,7 +396,7 @@ The .Dv System V IPC permission token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -335,7 +404,7 @@ The .Dv arg token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -343,7 +412,7 @@ The .Dv exec_args token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -351,7 +420,7 @@ The .Dv exec_env token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -359,7 +428,7 @@ The .Dv exit token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -367,7 +436,7 @@ The .Dv socket token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -375,7 +444,7 @@ The .Dv expanded socket token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -383,7 +452,7 @@ The .Dv seq token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -391,7 +460,7 @@ The .Dv privilege token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -399,7 +468,7 @@ The .Dv use-of-auth token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -407,7 +476,7 @@ The .Dv command token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -415,7 +484,7 @@ The .Dv ACL token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El @@ -423,7 +492,7 @@ The .Dv zonename token ... -.Bl -column -offset ind ".Sy Field Name Width" ".Sy XX Bytes XXXXX" ".Sy Description" +.Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" .El From owner-p4-projects@FreeBSD.ORG Mon May 2 02:44:27 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 99F2916A4D0; Mon, 2 May 2005 02:44:26 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5594216A4CE for ; Mon, 2 May 2005 02:44:26 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8B1C243D2F for ; Mon, 2 May 2005 02:44:25 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j422iPJQ098896 for ; Mon, 2 May 2005 02:44:25 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j422iPNE098893 for perforce@freebsd.org; Mon, 2 May 2005 02:44:25 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Mon, 2 May 2005 02:44:25 GMT Message-Id: <200505020244.j422iPNE098893@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76352 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2005 02:44:27 -0000 http://perforce.freebsd.org/chv.cgi?CH=76352 Change 76352 by rwatson@rwatson_paprika on 2005/05/02 02:44:01 Description of additional tokens. Affected files ... .. //depot/projects/trustedbsd/openbsm/man/audit.log.5#3 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/man/audit.log.5#3 (text+ko) ==== @@ -276,7 +276,11 @@ The .Dv process token contains a description of the security properties of a process -involved in an audit event. +involved as the target of an auditable event, such as the destination for +signal delivery. +It should not be confused with the +.Dv subject +token, which describes the subject performing an auditable event. This includes both the traditional .Ux security properties, such as user IDs and group IDs, but also audit @@ -347,18 +351,59 @@ .Ss Subject Token The .Dv subject -token ... +token contains information on the subject performing the operation described +by an audit record, and includes similar information to that found in the +.Dv process +and +.Dv expanded process +tokens. +However, those tokens are used where the process being described is the +target of the operation, not the authorizing party. +A +.Dv subject +token can be created using +.Xr au_to_subject32 3 +and +.Xr au_to_subject64 3 . .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Audit ID" Ta "4 bytes" Ta "Audit user ID" +.It Li "Effective User ID" Ta "4 bytes" Ta "Effective user ID" +.It Li "Effective Group ID "Ta "4 bytes" Ta "Effective group ID" +.It Li "Real User ID" Ta "4 bytes" Ta "Real user ID" +.It Li "Real Group ID" Ta "4 bytes" Ta "Real group ID" +.It Li "Process ID" Ta "4 bytes" Ta "Process ID" +.It Li "Session ID" Ta "4 bytes" Ta "Audit session ID" +.It Li "Terminal Port ID" Ta "4/8 bytes" Ta "Terminal port ID (32/64-bits)" +.It Li "Terminal Machine Address" Ta "4 bytes" Ta "IP address of machine" .El .Ss Expanded Subject Token The .Dv expanded subject -token ... +token consists of the same elements as the +.Dv subject +token, with the addition of type/length and variable size machine address +information in the terminal ID. +A +.Dv expanded subject +token can be created using +.Xr au_to_subject32_ex 3 +or +.Xr au_to_subject64_ex 3 . .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Audit ID" Ta "4 bytes" Ta "Audit user ID" +.It Li "Effective User ID" Ta "4 bytes" Ta "Effective user ID" +.It Li "Effective Group ID "Ta "4 bytes" Ta "Effective group ID" +.It Li "Real User ID" Ta "4 bytes" Ta "Real user ID" +.It Li "Real Group ID" Ta "4 bytes" Ta "Real group ID" +.It Li "Process ID" Ta "4 bytes" Ta "Process ID" +.It Li "Session ID" Ta "4 bytes" Ta "Audit session ID" +.It Li "Terminal Port ID" Ta "4/8 bytes" Ta "Terminal port ID (32/64-bits)" +.It Li "Terminal Address Type/Length" Ta "1 byte" "Length of machine address" +.It Li "Terminal Machine Address" Ta "4 bytes" Ta "IPv4 or IPv6 address of machine" .El .Ss System V IPC Token The @@ -367,30 +412,60 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Text Token The .Dv text -token ... +token contains a single nul-terminated text string. +A +.Dv text +token may be created using +.Xr au_to_text 3 . .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Text Length" Ta "2 bytes" Ta "Length of text string including nul" +.It Li "Text" Ta "N bytes + 1 nul" Ta "Text string including nul" .El .Ss Attribute Token The .Dv attribute -token ... +token describes the attributes of a file associated with the audit event. +As files may be identified by 0, 1, or many path names, a path name is not +included with the attribute block for a file; optional +.Dv path +tokens may also be present in an audit record indicating which path, if any, +was used to reach the object. +A +.Dv attribute +token can be created using +.Xr au_to_attr32 3 +or +.Xr au_to_attr64 3 . .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "File Access Mode" Ta "1 byte" Ta "mode_t associated with file" +.It Li "Owner User ID" Ta "4 bytes" Ta "uid_t associated with file" +.It Li "Owner Group ID" Ta "4 bytes" Ta "gid_t associated with file" +.It Li "File System ID" Ta "4 bytes" Ta "fsid_t associated with file" +.It Li "File System Node ID" Ta "8 bytes" Ta "ino_t associated with file" +.It Li "Device" Ta "4/8 bytes" Ta "Device major/minor number (32/64-bit)" .El .Ss Groups Token The .Dv groups -token ... +token contains a list of group IDs associated with the audit event. +A +.Dv groups +token can be created using +.Xr au_to_groups 3 . .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Number of Groups" Ta "2 bytes" Ta "Number of groups in token" +.It Li "Group List" Ta "N * 4 bytes" Ta "List of N group IDs" .El .Ss System V IPC Permission Token The @@ -399,6 +474,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Arg Token The @@ -407,6 +483,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss exec_args Token The @@ -415,6 +492,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss exec_env Token The @@ -423,14 +501,21 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Exit Token The .Dv exit -token ... +token contains process exit/return code information. +An +.Dv exit +token can be created using +.Xr au_to_exit 3 . .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Status" Ta "4 bytes" Ta "Process status on exit" +.It Li "Return Value" ta "4 bytes" Ta "Process return value on exit" .El .Ss Socket Token The @@ -439,6 +524,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Expanded Socket Token The @@ -447,14 +533,18 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Seq Token The .Dv seq -token ... +token contains a unique and monotonically increasing audit event sequence ID. +Due to the limited range (32 bits), serial number arithmetic (and caution) +should be used when comparing sequence numbers. .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li "Sequence Number" Ta "4 bytes" Ta "Audit event sequence number" .El .Ss privilege Token The @@ -463,6 +553,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Use-of-auth Token The @@ -471,6 +562,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Command Token The @@ -479,6 +571,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss ACL Token The @@ -487,6 +580,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Ss Zonename Token The @@ -495,6 +589,7 @@ .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" .It Sy "Field" Ta Sy Bytes Ta Sy Description .It Li "Token ID" Ta "1 byte" Ta "Token ID" +.It Li XXXXX .El .Sh SEE ALSO .Xr libbsm 3 From owner-p4-projects@FreeBSD.ORG Mon May 2 11:25:38 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 042E916A4D1; Mon, 2 May 2005 11:25:38 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9E4D216A4CE for ; Mon, 2 May 2005 11:25:37 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 72CFE43D39 for ; Mon, 2 May 2005 11:25:37 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j42BPb9c033344 for ; Mon, 2 May 2005 11:25:37 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j42BPb3G033341 for perforce@freebsd.org; Mon, 2 May 2005 11:25:37 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Mon, 2 May 2005 11:25:37 GMT Message-Id: <200505021125.j42BPb3G033341@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76370 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2005 11:25:38 -0000 http://perforce.freebsd.org/chv.cgi?CH=76370 Change 76370 by rwatson@rwatson_paprika on 2005/05/02 11:24:45 OpenBSM CHANGELOG. Affected files ... .. //depot/projects/trustedbsd/openbsm/CHANGELOG#1 add Differences ... From owner-p4-projects@FreeBSD.ORG Mon May 2 15:18:55 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id ABD7916A4D0; Mon, 2 May 2005 15:18:54 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 53FE116A4CE; Mon, 2 May 2005 15:18:54 +0000 (GMT) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 810F043D39; Mon, 2 May 2005 15:18:51 +0000 (GMT) (envelope-from arr@watson.org) Received: from fledge.watson.org (localhost.watson.org [127.0.0.1]) by fledge.watson.org (8.13.3/8.13.3) with ESMTP id j42FLx03091028; Mon, 2 May 2005 11:21:59 -0400 (EDT) (envelope-from arr@watson.org) Received: from localhost (arr@localhost)j42FLxq5091025; Mon, 2 May 2005 11:21:59 -0400 (EDT) (envelope-from arr@watson.org) X-Authentication-Warning: fledge.watson.org: arr owned process doing -bs Date: Mon, 2 May 2005 11:21:59 -0400 (EDT) From: "Andrew R. Reiter" To: Robert Watson In-Reply-To: <200505012123.j41LNpOv077763@repoman.freebsd.org> Message-ID: <20050502112106.R90331@fledge.watson.org> References: <200505012123.j41LNpOv077763@repoman.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: Perforce Change Reviews Subject: Re: PERFORCE change 76336 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2005 15:18:55 -0000 On Sun, 1 May 2005, Robert Watson wrote: :http://perforce.freebsd.org/chv.cgi?CH=76336 : :Change 76336 by rwatson@rwatson_paprika on 2005/05/01 21:23:34 : : Rename print_sec() to print_sec32(); add a print_sec64() that : truncates the value of a 64-bit second count since we assume that : time_t is 32-bit. : : Rename print_msec() to print_msec32(); add a print_msec64() that : truncates the value of a 64-bit millisecond count since that's : silly. : : Implement fetch_header64_tok(), print_header64_tok(), : fetch_attr64_tok(), print_attr64_tok(), fetch_subject64_tok(), : print_subject64_tok(). : : It's now possible to print the basic 64-bit record types from a : 64-bit Solaris BSM token stream. Ausome (he he, au* humor, ok, stupid ;)). Is there an audit log from 64bit solaris I could use to play around with this code base? : :Affected files ... : :.. //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#10 edit : :Differences ... : :==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#10 (text+ko) ==== : :@@ -281,7 +281,7 @@ : /* : * Prints seconds in the ctime format : */ :-static void print_sec(FILE *fp, u_int32_t sec, char raw) :+static void print_sec32(FILE *fp, u_int32_t sec, char raw) : { : time_t time; : char timestr[26]; :@@ -298,9 +298,29 @@ : } : : /* :+ * XXXRW: 64-bit token streams make use of 64-bit time stamps; since we :+ * assume a 32-bit time_t, we simply truncate for now. :+ */ :+static void print_sec64(FILE *fp, u_int64_t sec, char raw) :+{ :+ time_t time; :+ char timestr[26]; :+ :+ if(raw) { :+ fprintf(fp, "%u", (u_int32_t)sec); :+ } :+ else { :+ time = (time_t)sec; :+ ctime_r(&time, timestr); :+ timestr[24] = '\0'; /* No new line */ :+ fprintf(fp, "%s", timestr); :+ } :+} :+ :+/* : * Prints the excess milliseconds : */ :-static void print_msec(FILE *fp, u_int32_t msec, char raw) :+static void print_msec32(FILE *fp, u_int32_t msec, char raw) : { : if(raw) { : fprintf(fp, "%u", msec); :@@ -310,7 +330,23 @@ : } : } : :+/* :+ * XXXRW: 64-bit token streams make use of 64-bit time stamps; since we :+ * assume a 32-bit msec, we simply truncate for now. :+ */ :+static void print_msec64(FILE *fp, u_int64_t msec, char raw) :+{ : :+ msec &= 0xffffffff; :+ if(raw) { :+ fprintf(fp, "%u", (u_int32_t)msec); :+ } :+ else { :+ fprintf(fp, " + %u msec", (u_int32_t)msec); :+ } :+} :+ :+ : /* prints a dotted form for the IP addres */ : static void print_ip_address(FILE *fp, u_int32_t ip) : { :@@ -448,9 +484,72 @@ : print_delim(fp, del); : print_evmod(fp, tok->tt.hdr32.e_mod, raw); : print_delim(fp, del); :- print_sec(fp, tok->tt.hdr32.s, raw); :+ print_sec32(fp, tok->tt.hdr32.s, raw); :+ print_delim(fp, del); :+ print_msec32(fp, tok->tt.hdr32.ms, raw); :+} :+ :+/* :+ * record byte count 4 bytes :+ * event type 2 bytes :+ * event modifier 2 bytes :+ * seconds of time 4 bytes/8 bytes (32-bit/64-bit value) :+ * milliseconds of time 4 bytes/8 bytes (32-bit/64-bit value) :+ * version # :+ */ :+static int fetch_header64_tok(tokenstr_t *tok, char *buf, int len) :+{ :+ int err = 0; :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.hdr64.size, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_CHAR(buf, len, tok->tt.hdr64.version, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT16(buf, len, tok->tt.hdr64.e_type, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT16(buf, len, tok->tt.hdr64.e_mod, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT64(buf, len, tok->tt.hdr64.s, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT64(buf, len, tok->tt.hdr64.ms, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ return 0; :+} :+ :+static void print_header64_tok(FILE *fp, tokenstr_t *tok, char *del, :+ char raw, char sfrm) :+{ :+ print_tok_type(fp, tok->id, "header", raw); :+ print_delim(fp, del); :+ print_4_bytes(fp, tok->tt.hdr64.size, "%u"); :+ print_delim(fp, del); :+ print_1_byte(fp, tok->tt.hdr64.version, "%u"); :+ print_delim(fp, del); :+ print_event(fp, tok->tt.hdr64.e_type, raw, sfrm); :+ print_delim(fp, del); :+ print_evmod(fp, tok->tt.hdr64.e_mod, raw); :+ print_delim(fp, del); :+ print_sec64(fp, tok->tt.hdr64.s, raw); : print_delim(fp, del); :- print_msec(fp, tok->tt.hdr32.ms, raw); :+ print_msec64(fp, tok->tt.hdr64.ms, raw); : } : : /* :@@ -763,6 +862,69 @@ : } : : /* :+ * file access mode 4 bytes :+ * owner user ID 4 bytes :+ * owner group ID 4 bytes :+ * file system ID 4 bytes :+ * node ID 8 bytes :+ * device 4 bytes/8 bytes (32-bit/64-bit) :+ */ :+static int fetch_attr64_tok(tokenstr_t *tok, char *buf, int len) :+{ :+ int err = 0; :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.mode, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.uid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.gid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.attr64.fsid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT64(buf, len, tok->tt.attr64.nid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT64(buf, len, tok->tt.attr64.dev, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ return 0; :+} :+ :+static void print_attr64_tok(FILE *fp, tokenstr_t *tok, char *del, :+ char raw, char sfrm) :+{ :+ print_tok_type(fp, tok->id, "attribute", raw); :+ print_delim(fp, del); :+ print_4_bytes(fp, tok->tt.attr64.mode, "%o"); :+ print_delim(fp, del); :+ print_user(fp, tok->tt.attr64.uid, raw); :+ print_delim(fp, del); :+ print_group(fp, tok->tt.attr64.gid, raw); :+ print_delim(fp, del); :+ print_4_bytes(fp, tok->tt.attr64.fsid, "%u"); :+ print_delim(fp, del); :+ print_8_bytes(fp, tok->tt.attr64.nid, "%lld"); :+ print_delim(fp, del); :+ print_8_bytes(fp, tok->tt.attr64.dev, "%llu"); :+} :+ :+/* : * status 4 bytes : * return value 4 bytes : */ :@@ -919,9 +1081,9 @@ : { : print_tok_type(fp, tok->id, "file", raw); : print_delim(fp, del); :- print_sec(fp, tok->tt.file.s, raw); :+ print_sec32(fp, tok->tt.file.s, raw); : print_delim(fp, del); :- print_msec(fp, tok->tt.file.ms, raw); :+ print_msec32(fp, tok->tt.file.ms, raw); : print_delim(fp, del); : print_string(fp, tok->tt.file.name, tok->tt.file.len); : } :@@ -1704,7 +1866,7 @@ : * pid 4 bytes : * sessid 4 bytes : * terminal ID :- * portid 4 bytes :+ * portid 4 bytes/8 bytes (32-bit/64-bit value) : * machine id 4 bytes : */ : static int fetch_subject32_tok(tokenstr_t *tok, char *buf, int len) :@@ -1792,6 +1954,94 @@ : * pid 4 bytes : * sessid 4 bytes : * terminal ID :+ * portid 4 bytes/8 bytes (32-bit/64-bit value) :+ * machine id 4 bytes :+ */ :+static int fetch_subject64_tok(tokenstr_t *tok, char *buf, int len) :+{ :+ int err = 0; :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.auid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.euid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.egid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.ruid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.rgid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.pid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.sid, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT64(buf, len, tok->tt.subj64.tid.port, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ READ_TOKEN_U_INT32(buf, len, tok->tt.subj64.tid.addr, tok->len, err); :+ if(err) { :+ return -1; :+ } :+ :+ return 0; :+} :+ :+static void print_subject64_tok(FILE *fp, tokenstr_t *tok, char *del, :+ char raw, char sfrm) :+{ :+ print_tok_type(fp, tok->id, "subject", raw); :+ print_delim(fp, del); :+ print_user(fp, tok->tt.subj64.auid, raw); :+ print_delim(fp, del); :+ print_user(fp, tok->tt.subj64.euid, raw); :+ print_delim(fp, del); :+ print_group(fp, tok->tt.subj64.egid, raw); :+ print_delim(fp, del); :+ print_user(fp, tok->tt.subj64.ruid, raw); :+ print_delim(fp, del); :+ print_group(fp, tok->tt.subj64.rgid, raw); :+ print_delim(fp, del); :+ print_4_bytes(fp, tok->tt.subj64.pid, "%u"); :+ print_delim(fp, del); :+ print_4_bytes(fp, tok->tt.subj64.sid, "%u"); :+ print_delim(fp, del); :+ print_8_bytes(fp, tok->tt.subj64.tid.port, "%llu"); :+ print_delim(fp, del); :+ print_ip_address(fp, tok->tt.subj64.tid.addr); :+} :+ :+/* :+ * audit ID 4 bytes :+ * euid 4 bytes :+ * egid 4 bytes :+ * ruid 4 bytes :+ * rgid 4 bytes :+ * pid 4 bytes :+ * sessid 4 bytes :+ * terminal ID : * portid 4 bytes : * type 4 bytes : * machine id 16 bytes :@@ -2039,6 +2289,9 @@ : case AU_HEADER_32_TOKEN : : return fetch_header32_tok(tok, buf, len); : :+ case AU_HEADER_64_TOKEN : :+ return fetch_header64_tok(tok, buf, len); :+ : case AU_TRAILER_TOKEN : : return fetch_trailer_tok(tok, buf, len); : :@@ -2051,6 +2304,9 @@ : case AU_ATTR32_TOKEN : : return fetch_attr32_tok(tok, buf, len); : :+ case AU_ATTR64_TOKEN : :+ return fetch_attr64_tok(tok, buf, len); :+ : case AU_EXIT_TOKEN : : return fetch_exit_tok(tok, buf, len); : :@@ -2117,6 +2373,9 @@ : case AU_SUBJECT_32_TOKEN : : return fetch_subject32_tok(tok, buf, len); : :+ case AU_SUBJECT_64_TOKEN : :+ return fetch_subject64_tok(tok, buf, len); :+ : case AU_SUBJECT_32_EX_TOKEN : : return fetch_subject32ex_tok(tok, buf, len); : :@@ -2144,6 +2403,9 @@ : case AU_HEADER_32_TOKEN : : return print_header32_tok(outfp, tok, del, raw, sfrm); : :+ case AU_HEADER_64_TOKEN: :+ return print_header64_tok(outfp, tok, del, raw, sfrm); :+ : case AU_TRAILER_TOKEN : : return print_trailer_tok(outfp, tok, del, raw, sfrm); : :@@ -2159,6 +2421,9 @@ : case AU_ATTR32_TOKEN : : return print_attr32_tok(outfp, tok, del, raw, sfrm); : :+ case AU_ATTR64_TOKEN : :+ return print_attr64_tok(outfp, tok, del, raw, sfrm); :+ : case AU_EXIT_TOKEN : : return print_exit_tok(outfp, tok, del, raw, sfrm); : :@@ -2225,6 +2490,9 @@ : case AU_SUBJECT_32_TOKEN : : return print_subject32_tok(outfp, tok, del, raw, sfrm); : :+ case AU_SUBJECT_64_TOKEN : :+ return print_subject64_tok(outfp, tok, del, raw, sfrm); :+ : case AU_SUBJECT_32_EX_TOKEN : : return print_subject32ex_tok(outfp, tok, del, raw, sfrm); : : : -- Andrew R. Reiter arr@watson.org arr@FreeBSD.org From owner-p4-projects@FreeBSD.ORG Mon May 2 23:21:45 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7CAAA16A4D0; Mon, 2 May 2005 23:21:44 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4878816A4CE for ; Mon, 2 May 2005 23:21:44 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 753B443D5A for ; Mon, 2 May 2005 23:21:43 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j42NLhJx085361 for ; Mon, 2 May 2005 23:21:43 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j42NLhpv085358 for perforce@freebsd.org; Mon, 2 May 2005 23:21:43 GMT (envelope-from sam@freebsd.org) Date: Mon, 2 May 2005 23:21:43 GMT Message-Id: <200505022321.j42NLhpv085358@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76393 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2005 23:21:45 -0000 http://perforce.freebsd.org/chv.cgi?CH=76393 Change 76393 by sam@sam_ebb on 2005/05/02 23:21:33 IFC @ 76392 Affected files ... .. //depot/projects/wifi/Makefile.inc1#18 integrate .. //depot/projects/wifi/games/caesar/Makefile#2 integrate .. //depot/projects/wifi/games/caesar/caesar.c#2 integrate .. //depot/projects/wifi/games/pom/Makefile#2 integrate .. //depot/projects/wifi/games/pom/pom.c#2 integrate .. //depot/projects/wifi/gnu/lib/libobjc/Makefile#5 integrate .. //depot/projects/wifi/lib/libc/net/getaddrinfo.c#8 integrate .. //depot/projects/wifi/lib/libc/net/gethostbynis.c#3 integrate .. //depot/projects/wifi/lib/libc/net/name6.c#6 integrate .. //depot/projects/wifi/lib/libpmc/Makefile#2 integrate .. //depot/projects/wifi/lib/libpmc/libpmc.c#4 integrate .. //depot/projects/wifi/lib/libpmc/pmc.3#3 integrate .. //depot/projects/wifi/lib/libpmc/pmc.h#2 integrate .. //depot/projects/wifi/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#12 integrate .. //depot/projects/wifi/release/doc/zh_CN.GB2312/relnotes/common/new.sgml#5 integrate .. //depot/projects/wifi/sbin/atm/atm/atm.h#2 integrate .. //depot/projects/wifi/sbin/atm/atmconfig/atmconfig_device.h#2 integrate .. //depot/projects/wifi/sbin/atm/ilmid/ilmid.c#2 integrate .. //depot/projects/wifi/sbin/dump/traverse.c#2 integrate .. //depot/projects/wifi/sbin/fdisk/fdisk.c#4 integrate .. //depot/projects/wifi/sbin/fdisk_pc98/Makefile#2 integrate .. //depot/projects/wifi/sbin/fdisk_pc98/fdisk.c#3 integrate .. //depot/projects/wifi/sbin/ggate/shared/ggate.h#2 integrate .. //depot/projects/wifi/sbin/natd/natd.c#3 integrate .. //depot/projects/wifi/share/man/man4/hwpmc.4#2 integrate .. //depot/projects/wifi/share/man/man5/rc.conf.5#15 integrate .. //depot/projects/wifi/share/man/man9/taskqueue.9#6 integrate .. //depot/projects/wifi/sys/dev/aac/aac_disk.c#3 integrate .. //depot/projects/wifi/sys/dev/ata/ata-raid.c#8 integrate .. //depot/projects/wifi/sys/kern/vfs_subr.c#25 integrate .. //depot/projects/wifi/sys/nfsclient/nfs_vfsops.c#10 integrate .. //depot/projects/wifi/sys/vm/vm_map.c#6 integrate .. //depot/projects/wifi/usr.bin/Makefile#6 integrate .. //depot/projects/wifi/usr.bin/brandelf/brandelf.c#2 integrate .. //depot/projects/wifi/usr.bin/compress/zopen.c#2 integrate .. //depot/projects/wifi/usr.bin/mkuzip/Makefile#2 integrate .. //depot/projects/wifi/usr.bin/mkuzip/mkuzip.c#2 integrate .. //depot/projects/wifi/usr.bin/systat/pigs.c#2 integrate .. //depot/projects/wifi/usr.sbin/burncd/burncd.8#4 integrate .. //depot/projects/wifi/usr.sbin/faithd/ftp.c#3 integrate .. //depot/projects/wifi/usr.sbin/pmccontrol/pmccontrol.c#2 integrate .. //depot/projects/wifi/usr.sbin/pmcstat/pmcstat.c#2 integrate .. //depot/projects/wifi/usr.sbin/rpc.yppasswdd/yppasswdd_main.c#2 integrate .. //depot/projects/wifi/usr.sbin/sysinstall/dist.c#2 integrate .. //depot/projects/wifi/usr.sbin/sysinstall/menus.c#7 integrate .. //depot/projects/wifi/usr.sbin/ypserv/Makefile.yp#2 integrate .. //depot/projects/wifi/usr.sbin/ypserv/yp_dnslookup.c#3 integrate .. //depot/projects/wifi/usr.sbin/ypserv/yp_extern.h#2 integrate .. //depot/projects/wifi/usr.sbin/ypserv/yp_server.c#2 integrate Differences ... ==== //depot/projects/wifi/Makefile.inc1#18 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.493 2005/04/30 16:09:23 imp Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.494 2005/05/01 17:36:09 imp Exp $ # # Make command line options: # -DNO_DYNAMICROOT do not link /bin and /sbin dynamically @@ -337,7 +337,6 @@ @echo "--------------------------------------------------------------" @echo ">>> stage 2.1: cleaning up the object tree" @echo "--------------------------------------------------------------" - @rm -rf ${.OBJDIR}/sbin/ipf ${_+_}cd ${.CURDIR}; ${WMAKE} ${CLEANDIR:S/^/par-/} .endif _obj: ==== //depot/projects/wifi/games/caesar/Makefile#2 (text+ko) ==== @@ -1,5 +1,5 @@ # @(#)Makefile 8.1 (Berkeley) 5/31/93 -# $FreeBSD: src/games/caesar/Makefile,v 1.9 2001/06/22 21:38:27 dd Exp $ +# $FreeBSD: src/games/caesar/Makefile,v 1.10 2005/05/01 19:34:22 stefanf Exp $ PROG= caesar DPADD= ${LIBM} @@ -8,6 +8,6 @@ MAN= caesar.6 MLINKS= caesar.6 rot13.6 -WARNS?= 2 +WARNS?= 6 .include ==== //depot/projects/wifi/games/caesar/caesar.c#2 (text+ko) ==== @@ -51,7 +51,7 @@ #endif /* not lint */ #endif #include -__FBSDID("$FreeBSD: src/games/caesar/caesar.c,v 1.13 2003/05/05 09:52:25 obrien Exp $"); +__FBSDID("$FreeBSD: src/games/caesar/caesar.c,v 1.14 2005/05/01 19:34:22 stefanf Exp $"); #include #include @@ -80,9 +80,7 @@ void printit(char *); int -main(argc, argv) - int argc; - char **argv; +main(int argc, char **argv) { int ch, dot, i, nread, winnerdot = 0; char *inbuf; @@ -153,8 +151,8 @@ exit(0); } -void printit(arg) - char *arg; +void +printit(char *arg) { int ch, rot; ==== //depot/projects/wifi/games/pom/Makefile#2 (text+ko) ==== @@ -1,11 +1,11 @@ # @(#)Makefile 8.1 (Berkeley) 5/31/93 -# $FreeBSD: src/games/pom/Makefile,v 1.6 2001/06/22 21:38:27 dd Exp $ +# $FreeBSD: src/games/pom/Makefile,v 1.7 2005/05/01 19:34:22 stefanf Exp $ PROG= pom MAN= pom.6 DPADD= ${LIBM} LDADD= -lm -WARNS?= 2 +WARNS?= 6 .include ==== //depot/projects/wifi/games/pom/pom.c#2 (text+ko) ==== @@ -45,7 +45,7 @@ #endif /* not lint */ #endif #include -__FBSDID("$FreeBSD: src/games/pom/pom.c,v 1.12 2003/05/05 09:52:25 obrien Exp $"); +__FBSDID("$FreeBSD: src/games/pom/pom.c,v 1.13 2005/05/01 19:34:22 stefanf Exp $"); /* * Phase of the Moon. Calculates the current phase of the moon. @@ -78,7 +78,7 @@ static double potm(double); int -main() +main(void) { time_t tt; struct tm *GMT; @@ -122,8 +122,7 @@ * return phase of the moon */ static double -potm(days) - double days; +potm(double days) { double N, Msol, Ec, LambdaSol, l, Mm, Ev, Ac, A3, Mmprime; double A4, lprime, V, ldprime, D, Nm; @@ -159,8 +158,7 @@ * convert degrees to radians */ static double -dtor(deg) - double deg; +dtor(double deg) { return(deg * PI / 180); } @@ -170,8 +168,7 @@ * adjust value so 0 <= deg <= 360 */ static void -adj360(deg) - double *deg; +adj360(double *deg) { for (;;) if (*deg < 0) ==== //depot/projects/wifi/gnu/lib/libobjc/Makefile#5 (text+ko) ==== @@ -1,18 +1,13 @@ -# $FreeBSD: src/gnu/lib/libobjc/Makefile,v 1.25 2005/02/21 21:02:25 ru Exp $ +# $FreeBSD: src/gnu/lib/libobjc/Makefile,v 1.26 2005/05/01 01:59:48 peter Exp $ OBJCDIR=${.CURDIR}/../../../contrib/libobjc GCCDIR= ${.CURDIR}/../../../contrib/gcc .PATH: ${OBJCDIR}/objc ${OBJCDIR} -LIB= objc +LIB= objc +SHLIB_MAJOR= 1 NO_MAN= -.if ${MACHINE_ARCH} == "amd64" -SHLIB_MAJOR= 1 -.else -# XXX is this still correct? -NO_PIC= # works but method lookup slowdown is significant -.endif SRCS= archive.c class.c encoding.c gc.c hash.c init.c misc.c \ nil_method.c objects.c sarray.c selector.c sendmsg.c \ @@ -23,11 +18,6 @@ sarray.h thr.h typedstream.h NXConstStr.h Object.h Protocol.h INCSDIR=${INCLUDEDIR}/objc -# PR ia64/49081 -.if ${MACHINE_ARCH} == "ia64" -CFLAGS+= -fpic -.endif - OBJCFLAGS= -fgnu-runtime ${CFLAGS} CFLAGS+= -DHAVE_GTHR_DEFAULT -DIN_GCC -DIN_TARGET_LIBS CFLAGS+= -I. -I${.CURDIR}/../../usr.bin/cc/cc_tools ==== //depot/projects/wifi/lib/libc/net/getaddrinfo.c#8 (text+ko) ==== @@ -63,7 +63,7 @@ */ #include -__FBSDID("$FreeBSD: src/lib/libc/net/getaddrinfo.c,v 1.65 2005/04/15 18:15:12 ume Exp $"); +__FBSDID("$FreeBSD: src/lib/libc/net/getaddrinfo.c,v 1.66 2005/05/02 04:43:32 ume Exp $"); #include "namespace.h" #include @@ -781,7 +781,8 @@ { struct addrinfo ai = *aio->aio_ai; struct sockaddr_storage ss; - int s, srclen; + socklen_t srclen; + int s; /* set unspec ("no source is available"), just in case */ aio->aio_srcsa.sa_family = AF_UNSPEC; ==== //depot/projects/wifi/lib/libc/net/gethostbynis.c#3 (text+ko) ==== @@ -24,7 +24,7 @@ */ #include -__FBSDID("$FreeBSD: src/lib/libc/net/gethostbynis.c,v 1.24 2005/04/30 20:07:01 ume Exp $"); +__FBSDID("$FreeBSD: src/lib/libc/net/gethostbynis.c,v 1.25 2005/05/01 07:39:45 ume Exp $"); #include #include @@ -202,14 +202,18 @@ { #ifdef YP struct hostdata *hd; + u_long oresopt; + int error; if ((hd = __hostdata_init()) == NULL) { h_errno = NETDB_INTERNAL; return NULL; } - if (_gethostbynisname_r(name, af, &hd->host, &hd->data) != 0) - return NULL; - return &hd->host; + oresopt = _res.options; + _res.options &= ~RES_USE_INET6; + error = _gethostbynisname_r(name, af, &hd->host, &hd->data); + _res.options = oresopt; + return (error == 0) ? &hd->host : NULL; #else return NULL; #endif @@ -220,14 +224,18 @@ { #ifdef YP struct hostdata *hd; + u_long oresopt; + int error; if ((hd = __hostdata_init()) == NULL) { h_errno = NETDB_INTERNAL; return NULL; } - if (_gethostbynisaddr_r(addr, len, af, &hd->host, &hd->data) != 0) - return NULL; - return &hd->host; + oresopt = _res.options; + _res.options &= ~RES_USE_INET6; + error = _gethostbynisaddr_r(addr, len, af, &hd->host, &hd->data); + _res.options = oresopt; + return (error == 0) ? &hd->host : NULL; #else return NULL; #endif ==== //depot/projects/wifi/lib/libc/net/name6.c#6 (text+ko) ==== @@ -88,7 +88,7 @@ */ #include -__FBSDID("$FreeBSD: src/lib/libc/net/name6.c,v 1.48 2005/04/28 18:21:11 ume Exp $"); +__FBSDID("$FreeBSD: src/lib/libc/net/name6.c,v 1.51 2005/05/02 04:43:32 ume Exp $"); #include "namespace.h" #ifdef ICMPNL @@ -954,7 +954,8 @@ struct policyhead *ph; { struct sockaddr_storage ss = aio->aio_un.aiou_ss; - int s, srclen; + socklen_t srclen; + int s; /* set unspec ("no source is available"), just in case */ aio->aio_srcsa.sa_family = AF_UNSPEC; @@ -1369,7 +1370,7 @@ /* * NIS * - * XXX actually a hack, these are INET4 specific. + * XXX actually a hack. */ static int _nis_ghbyname(void *rval, void *cb_data, va_list ap) ==== //depot/projects/wifi/lib/libpmc/Makefile#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/lib/libpmc/Makefile,v 1.2 2005/04/19 14:43:59 jkoshy Exp $ +# $FreeBSD: src/lib/libpmc/Makefile,v 1.3 2005/05/01 14:11:47 jkoshy Exp $ LIB= pmc @@ -12,6 +12,7 @@ MLINKS+= \ pmc.3 pmc_allocate.3 \ pmc.3 pmc_attach.3 \ + pmc.3 pmc_capabilities.3 \ pmc.3 pmc_configure_logfile.3 \ pmc.3 pmc_cpuinfo.3 \ pmc.3 pmc_detach.3 \ @@ -35,6 +36,7 @@ pmc.3 pmc_set.3 \ pmc.3 pmc_start.3 \ pmc.3 pmc_stop.3 \ + pmc.3 pmc_width.3 \ pmc.3 pmc_write.3 \ pmc.3 pmc_x86_get_msr.3 ==== //depot/projects/wifi/lib/libpmc/libpmc.c#4 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/lib/libpmc/libpmc.c,v 1.4 2005/04/21 05:50:25 jkoshy Exp $"); +__FBSDID("$FreeBSD: src/lib/libpmc/libpmc.c,v 1.5 2005/05/01 14:11:47 jkoshy Exp $"); #include #include @@ -1981,6 +1981,36 @@ return 0; } +int +pmc_width(pmc_id_t pmcid, uint32_t *width) +{ + unsigned int i; + enum pmc_class cl; + + cl = PMC_ID_TO_CLASS(pmcid); + for (i = 0; i < cpu_info.pm_nclass; i++) + if (cpu_info.pm_classes[i].pm_class == cl) { + *width = cpu_info.pm_classes[i].pm_width; + return 0; + } + return EINVAL; +} + +int +pmc_capabilities(pmc_id_t pmcid, uint32_t *caps) +{ + unsigned int i; + enum pmc_class cl; + + cl = PMC_ID_TO_CLASS(pmcid); + for (i = 0; i < cpu_info.pm_nclass; i++) + if (cpu_info.pm_classes[i].pm_class == cl) { + *caps = cpu_info.pm_classes[i].pm_caps; + return 0; + } + return EINVAL; +} + const char * pmc_name_of_cputype(enum pmc_cputype cp) { ==== //depot/projects/wifi/lib/libpmc/pmc.3#3 (text+ko) ==== @@ -21,7 +21,7 @@ .\" out of the use of this software, even if advised of the possibility of .\" such damage. .\" -.\" $FreeBSD: src/lib/libpmc/pmc.3,v 1.2 2005/04/23 05:45:18 jkoshy Exp $ +.\" $FreeBSD: src/lib/libpmc/pmc.3,v 1.3 2005/05/01 14:11:47 jkoshy Exp $ .\" .Dd Apr 15, 2005 .Os @@ -29,6 +29,7 @@ .Sh NAME .Nm pmc_allocate , .Nm pmc_attach , +.Nm pmc_capabilities , .Nm pmc_configure_logfile , .Nm pmc_cpuinfo , .Nm pmc_detach , @@ -53,6 +54,7 @@ .Nm pmc_start , .Nm pmc_stop , .Nm pmc_write , +.Nm pmc_width , .Nm pmc_x86_get_msr .Nd programming API for using hardware performance monitoring counters .Sh LIBRARY @@ -73,6 +75,8 @@ .Fa "pid_t pid" .Fc .Ft int +.Fn pmc_capabilities "pmc_id_t pmc" "uint32_t *caps" +.Ft int .Fn pmc_configure_logfile "int fd" .Ft int .Fn pmc_cpuinfo "const struct pmc_op_getcpuinfo **cpu_info" @@ -130,6 +134,8 @@ .Ft int .Fn pmc_write "pmc_id_t pmc" "pmc_value_t value" .Ft int +.Fn pmc_width "pmc_id_t pmc" "uint32_t *width" +.Ft int .Fn pmc_x86_get_msr "int pmc" "uint32_t *msr" .Sh DESCRIPTION These functions implement a high-level library for using the @@ -252,6 +258,20 @@ The read and write operation may be combined using .Fn pmc_rw . .Pp +The function +.Fn pmc_capabilities +sets argument +.Fa caps +to a bitmask of capabilities supported by the PMC denoted by +argument +.Fa pmc . +The function +.Fn pmc_width +sets argument +.Fa width +to the width of the PMC denoted by argument +.Fa pmc . +.Pp The .Fn pmc_configure_logfile function causes the @@ -3011,13 +3031,15 @@ .El .Pp A call to +.Fn pmc_capabilities , .Fn pmc_name_of_capability , .Fn pmc_name_of_disposition , .Fn pmc_name_of_state , .Fn pmc_name_of_event , .Fn pmc_name_of_mode +.Fn pmc_name_of_class and -.Fn pmc_name_of_class +.Fn pmc_width may fail with the following error: .Bl -tag -width Er .It Bq Er EINVAL ==== //depot/projects/wifi/lib/libpmc/pmc.h#2 (text+ko) ==== @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libpmc/pmc.h,v 1.1 2005/04/19 04:01:21 jkoshy Exp $ + * $FreeBSD: src/lib/libpmc/pmc.h,v 1.2 2005/05/01 14:11:47 jkoshy Exp $ */ #ifndef _PMC_H_ @@ -38,6 +38,7 @@ int pmc_allocate(const char *_ctrspec, enum pmc_mode _mode, uint32_t _flags, int _cpu, pmc_id_t *_pmcid); int pmc_attach(pmc_id_t _pmcid, pid_t _pid); +int pmc_capabilities(pmc_id_t _pmc, uint32_t *_caps); int pmc_configure_logfile(int _fd); int pmc_detach(pmc_id_t _pmcid, pid_t _pid); int pmc_disable(int _cpu, int _pmc); @@ -50,6 +51,7 @@ int pmc_set(pmc_id_t _pmc, pmc_value_t _value); int pmc_start(pmc_id_t _pmc); int pmc_stop(pmc_id_t _pmc); +int pmc_width(pmc_id_t _pmc, uint32_t *_width); int pmc_write(pmc_id_t _pmc, pmc_value_t _value); int pmc_ncpu(void); ==== //depot/projects/wifi/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#12 (text+ko) ==== @@ -3,7 +3,7 @@ The &os; Project - $FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.849 2005/04/25 15:32:58 bmah Exp $ + $FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.852 2005/05/02 05:56:30 bmah Exp $ 2000 @@ -330,7 +330,7 @@ in the &man.acpi.4; driver. These can individually be disabled by setting device hints such as hint.ichss.0.disabled="1". - The &man.hwpmc.4;, hardware performance + The &man.hwpmc.4; hardware performance monitoring counter driver has been added. This driver virtualizes the hardware performance monitoring facilities in modern CPUs and provides support for using @@ -444,6 +444,18 @@ The &man.ixgb.4; driver is now MPSAFE. + The musycc driver, for the LanMedia LMC1504 T1/E1 + network interface card, has been removed due to + disuse. + + Drivers using the &man.ndis.4; device + driver wrapper mechanism are now built and loaded + differently. The &man.ndis.4; driver can now be pre-built + as module or statically compiled into a kernel. Individual + drivers can now be built with the &man.ndisgen.8; utility; + the result is a kernel module that can be loaded into a + running kernel using &man.kldload.8;. + The &man.ndis.4; device driver wrapper now supports &windows;/x86-64 binaries on amd64 systems. &merged; @@ -511,7 +523,7 @@ when the gid, jail, and/or uid rule options are used. &merged; - The &man.ipfw.4; and &man.dummynet.4; system now + The &man.ipfw.4; and &man.dummynet.4; systems now support IPv6. &man.ipfw.8; now supports classification and tagging @@ -549,7 +561,7 @@ The new sysctl net.link.tap.user_open has been implemented. This allows unprivileged access to - &man.tap.4; device nodes based on the file system permission. + &man.tap.4; device nodes based on file system permissions. A bug in TCP that sometimes caused RST packets to be ignored if the receive window was zero bytes has been @@ -602,16 +614,16 @@ debug.mpsafenet sysctl variable may be set to 1). - The Unix domain socket now supports + Unix domain sockets now support the LOCAL_CREDS and - LOCAL_CONNWAIT. + LOCAL_CONNWAIT options. The LOCAL_CREDS option provides a mechanism for the receiver to receive the credentials of the process as a &man.recvmsg.2; control message. The LOCAL_CONNWAIT option causes the &man.connect.2; function to block until &man.accept.2; has been called on the listening socket. - For more details, see &man.unix.4; manual page. + For more details, see the &man.unix.4; manual page. @@ -698,7 +710,7 @@ eject) to take place after fixating a disk. - The machine-specific optimized version of + Machine-specific optimized versions of &man.bcmp.3;, &man.bcopy.3;, &man.bzero.3;, &man.memcmp.3;, &man.memcpy.3;, &man.memmove.3;, &man.memset.3;, &man.strcat.3; and &man.strcpy.3; have been implemented. @@ -758,7 +770,7 @@ The on-disk format of LC_CTYPE files has been changed to be machine-independent. - The &man.mixer.8; utility now supports + The &man.mixer.8; utility now supports the option. This is the same as the option but does not output mixing field separators. @@ -975,10 +987,10 @@ run out of buffer space due to a local denial-of-service attack. &merged; - The &man.syslogd.8; now supports option + The &man.syslogd.8; now supports the option, which allows to change the pathname of the privileged - socket. This is useful when you do not want the daemon - to receive any messages from the local sockets + socket. This is useful for preventing the daemon + from receiving any messages from the local sockets (/var/run/log and /var/run/logpriv are used by default). &merged; @@ -1067,15 +1079,24 @@ BIND has been updated from version 9.3.0 to version 9.3.1. &merged; + bsnmp has been updated from 1.7 + to 1.9. + FILE has been updated from 4.10 to 4.12. GNU readline has been updated from version 4.3 to version 5.0. + IPFilter has been updated from + 3.4.35 to 4.1.18. + Heimdal has been updated from 0.6.1 to 0.6.3. &merged; + libz has been updated from 1.2.1 + to 1.2.2. + lukemftp has been updated from a 26 April 2004 snapshot from OpenBSD's sources to a snapshot as of 19 February 2005. @@ -1096,6 +1117,9 @@ sendmail has been updated from version 8.13.1 to version 8.13.3. &merged; + tcsh has been updated from + 6.13.00 to 6.14.00. + The timezone database has been updated from the tzdata2004e release to the tzdata2004g release. &merged; @@ -1206,8 +1230,8 @@ Documentation The &man.sched.4bsd.4; and &man.sched.ule.4; manual pages - have been added. These explain the kernel options SCHED_4BSD - and SCHED_ULE and some sysctls applicable. + have been added. These explain the kernel options SCHED_4BSD + and SCHED_ULE, as well as some applicable sysctl variables. The &man.ataraid.4; manual page has been added. It explains the &man.ata.4; software ==== //depot/projects/wifi/release/doc/zh_CN.GB2312/relnotes/common/new.sgml#5 (text+ko) ==== @@ -1,14 +1,14 @@ &os;/&arch; &release.current; ·¢ÐÐ˵Ã÷ The &os; Project - $FreeBSD: src/release/doc/zh_CN.GB2312/relnotes/common/new.sgml,v 1.4 2005/04/18 16:55:48 delphij Exp $ + $FreeBSD: src/release/doc/zh_CN.GB2312/relnotes/common/new.sgml,v 1.5 2005/05/01 15:07:58 delphij Exp $ 2000 @@ -143,6 +143,12 @@ FreeBSD-SA-05:04.ifconf¡£ &merged; + ÐÞÕýÁË &man.cvs.1; ÖеĶദ³ÌÐòÉè¼ÆÎÊÌ⣬ ÕâЩÎÊÌâ¿ÉÄܵ¼ÖÂÔÚ + CVS ·þÎñÆ÷ÉÏÖ´ÐÐÈÎÒâ´úÂë¡£ + ÒªÁ˽â¸ü¶àÐÅÏ¢£¬ Çë²Î¼û°²È«¹«¸æ + FreeBSD-SA-05:05.cvs¡£ + &merged; + @@ -297,6 +303,12 @@ hint.ichss.0.disabled="1" À´½ûÓᣠ+ ¼ÓÈëÁËÓÃÓÚÓ²¼þÐÔÄܼàÊÓ¼ÆÊýÆ÷µÄ &man.hwpmc.4; + Çý¶¯¡£ Õâ¸öÇý¶¯³éÏóÁËÐÂʽ CPU ÖÐÌṩµÄÓ²¼þÐÔÄܼàÊÓ»úÖÆ£¬ + ²¢ÌṩÁËÔÚÓû§½ø³ÌÖÐÀûÓÃÕâЩ»úÖƵÄÖ§³Ö¡£ ÒªÁ˽â¸ü¶àµÄϸ½Ú£¬ + Çë²Î¼û &man.hwpmc.4; µÄÁª»úÊֲᡢ Ïà¹ØÁªµÄº¯Êý¿â£¬ + ÒÔ¼°ÓйصÄÆäËû¹¤¾ß¡£ + ɾȥÁ˶ÔÓÚ OLDCARD ×ÓϵͳµÄÖ§³Ö¡£ ÏÖÔÚ£¬ NEWCARD ϵͳ±»ÓÃÓÚÖ§³ÖËùÓÐµÄ PCCARD É豸ÁË¡£ @@ -385,6 +397,12 @@ &man.hme.4; Çý¶¯ÏÖÔÚ MPSAFE ÁË¡£ &merged; + ¼ÓÈëÁË &man.ipw.4; (ÓÃÓÚ Intel PRO/Wireless 2100)£¬ + &man.iwi.4; (ÓÃÓÚ Intel PRO/Wireless 2200BG/2225BG/2915ABG)£¬ + &man.ral.4; (ÓÃÓÚ Ralink Technology RT2500)£¬ + ÒÔ¼° &man.ural.4; (ÓÃÓÚ Ralink Technology RT2500USB) + Çý¶¯¡£ + &man.ixgb.4; Çý¶¯ÏÖÔÚ MPSAFE ÁË¡£ ÏÖÔÚ &man.ndis.4; É豸Çý¶¯ wrapper @@ -450,6 +468,8 @@ µ±Ê¹ÓÃÁË gid, jail, ºÍ/»ò uid ¹æÔòÑ¡ÏîʱÕý³£¹¤×÷ÁË¡£ &merged; + &man.ipfw.4; ºÍ &man.dummynet.4; ϵͳÄܹ»Ö§³Ö IPv6 ÁË¡£ + &man.ipfw.8; ÏÖÔÚÖ§³Öͨ¹ýת·¢ socket£¬ ÒÔ¼° TCP Êý¾Ý³¤¶ÈÀ´Çø·Ö²¢±ê¼Ç &man.altq.4; °üÁË¡£ @@ -481,6 +501,10 @@ &man.sppp.4; Çý¶¯ÏÖÔÚ MPSAFE ÁË¡£ + ʵÏÖÁËÒ»¸öÐ嵀 sysctl net.link.tap.user_open¡£ + ËüÔÊÐí»ùÓÚÎļþϵͳȨÏÞ¶Ô + &man.tap.4; É豸½øÐзÇÌØȨ·ÃÎÊ¡£ + ÐÞÕýÁË TCP µÄÒ»´¦ÎÊÌ⣬ ÕâÒ»ÎÊÌâÓÐʱ»áµ¼Öµ±½ÓÊÕ´°¿Ú´óСΪÁãʱ£¬ RST °ü±»ºöÂÔµÄÎÊÌâ¡£ &merged; @@ -523,6 +547,15 @@ debug.mpsafenet sysctl ±äÁ¿ÉèÖÃΪ 1)¡£ + ÏÖÔÚ Unix domain socket ÌṩÁË + LOCAL_CREDS ºÍ + LOCAL_CONNWAIT¡£ + ÆäÖУ¬ LOCAL_CREDS Ñ¡ÏîÌṩÁËÒ»ÖÖ»úÖÆ£¬ + ʹµÃ½ÓÊÕ·½Äܹ»ÒÔ &man.recvmsg.2; ¿ØÖÆÏûÏ¢µÄÐÎʽ£¬ + ÊÕµ½·¢ËÍÕߵĽø³Ìƾ¾Ý¡£ + ¶ø LOCAL_CONNWAIT Ôò½«Èà &man.connect.2; + º¯Êý×èÈû£¬ Ö±µ½ÔÚ¼àÌý socket ÉÏÖ´ÐÐÁË &man.accept.2; Ϊֹ¡£ + ÓûÁ˽â½øÒ»²½µÄÇé¿ö£¬ Çë²Î¼û &man.unix.4; Áª»úÊֲᡣ @@ -555,6 +588,8 @@ ɾȥÁË¾ÉµÄ vinum(4) ×Óϵͳ£¬ еĻùÓÚ &man.geom.4; µÄ°æ±¾ÌṩÁ˸üºÃµÄ¹¦ÄÜ¡£ + &man.twa.4; Çý¶¯¸üе½ÁËÀ´×Ô 3ware ÍøÕ¾µÄ 9.2 °æ (ÓÃÓÚ &os; 5.2.1) + ɾȥÁË &man.wd.4; Çý¶¯¡£ &man.ata.4; Çý¶¯ÒѾ­Äܹ»ÔÚ pc98 ƽ̨ÉϺܺõŤ×÷£¬ Òò¶ø²»ÔÙÐèÒª¾ÉµÄ &man.wd.4; @@ -601,6 +636,11 @@ ÏÖÔÚ &man.burncd.8; ¹¤¾ßÄܹ»ÔÚ¹âÅ̶¨ÐÍÖ®ºóÖ´ÐÐÃüÁîÁË (ÀýÈç eject)¡£ + ʵÏÖÁËÕë¶Ô±¾Æ½Ì¨ÓÅ»¯µÄ + &man.bcmp.3;, &man.bcopy.3;, &man.bzero.3;, &man.memcmp.3;, + &man.memcpy.3;, &man.memmove.3;, &man.memset.3;, &man.strcat.3; + and &man.strcpy.3; °æ±¾¡£ + ÏÖÔÚ &man.ftpd.8; ³ÌÐò»áÕýÈ·µØΪĿ¼ºÍÎļþµÄ״̬ʹÓà 212 ºÍ 213 ״̬´úÂëÁË (¹ýÈ¥µÄ°æ±¾£¬ Ôø¾­³¤ÆÚʹÓà 211)¡£ @@ -628,6 +668,12 @@ ÒÔÇ¿ÖÆ´´½¨ GPT£¬ ¼´Ê¹´ÅÅÌÉÏÔ­ÏÈÒѾ­´æÔÚÁË MBR ¼Ç¼¡£ &merged; + ÏÖÔÚ &man.getprotoent.3;£¬ &man.getprotobyname.3;£¬ ÒÔ¼° + &man.getprotobynumber.3; º¯ÊýÊÇḬ̈߳²È«µÄÁË¡£ + + ÏÖÔÚ &man.getservent.3;£¬ &man.getservbyname.3;£¬ ÒÔ¼° + &man.getservbyport.3; º¯ÊýÊÇḬ̈߳²È«µÄÁË¡£ + gvinum(8) ¹¤¾ßÏÖÔÚÖ§³Ö checkparity¡¢ rebuildparity£¬ ÒÔ¼° @@ -645,6 +691,10 @@ ´ÅÅÌÉ쵀 LC_CTYPE Îļþ¸ñʽ£¬ ÏÖÔÚÒѾ­¸ÄΪ»úÆ÷Î޹صĸñʽÁË¡£ + &man.mixer.8; ¹¤¾ßÐÂÔöÁË + ²ÎÊý¡£ ËüµÄ¹¦ÄÜºÍ Ò»Ñù£¬ + µ«²¢²»Êä³ö»ìÒô×ֶμä¸ô·û¡£ + ÐÞÕýÁË libalias º¯Êý¿âÖеÄÒ»´¦ÎÊÌ⣬ ¸ÃÎÊÌâ¿ÉÄܵ¼ÖÂʹÓà &man.natd.8; µÄ Ñ¡Ïîʱ³öÏÖ core dump¡£ @@ -787,7 +837,7 @@ ÏÖÔÚʹÓà &man.bsdtar.1; ´úÌæÁË GNU tar¡£ &man.restore.8; ¹¤¾ßÓÖÄܹ»´¦Àí - &os; °æ±¾ 1 µÄת´¢´Å´øÁË¡£ + &os; °æ±¾ 1 µÄת´¢´Å´øÁË¡£ &merged; ÐÞÕýÁËÒ»¸öµ¼Ö &man.rexecd.8; ¹¤¾ß×ÜÊÇÒÔ ²ÎÊýÔËÐеÄÎÊÌâ¡£ &merged; @@ -804,6 +854,10 @@ ¼ÓÈëÁËÓÃÓÚ¼ì²é×Ö·û´®ÊÇ·ñÊǵ±Ç° locale µÄ±àÂëµÄ &man.rpmatch.3; ¿âº¯Êý¡£ + ÏÂÁÐ ISO/IEC 9899:1999 ±ê×¼º¯ÊýµÃÒÔʵÏÖ£º roundl()¡¢ + lroundl()¡¢ llroundl()¡¢ + truncl()£¬ ÒÔ¼° floorl()¡£ + &man.rtld.1; ¶¯Ì¬Á¬½ÓÆ÷ÏÖÔÚÖ§³Öͨ¹ý LD_LIBMAP »·¾³±äÁ¿À´Ö¸¶¨¿âÓ³Éä¹ØϵÁË¡£ ÕâһѡÏîÄܹ»¸²¸Ç &man.libmap.conf.5; µÄÉèÖᣠ&merged; @@ -824,9 +878,15 @@ Õß±ÜÃâÁË·¢Éú±¾µØµÄ¾Ü¾ø·þÎñ¹¥»÷ʱ£¬ ÌØȨ³ÌÐòÓÉÓÚÓò socket µÄ»º³åÇøºÄ¾¡¶øËÀËø¡£ &merged; + &man.syslogd.8; ÐÂÔöÁË Ñ¡Ï + ÓÃÒԸıäÌØȨ socket µÄ·¾¶Ãû¡£ Èç¹ûÄú²»Ï£Íû·þÎñ½ÓÊÜÀ´×Ô±¾µØ socket + µÄÏûÏ¢ (ĬÈÏʹÓõÄÊÇ /var/run/log ºÍ + /var/run/logpriv) ʱ£¬ Õâ¸öÑ¡Ïî¾ÍºÜÓÐÓÃÁË¡£ + &merged; + &man.syslogd.8; ¹¤¾ßÏÖÔÚÔÊÐíÔÚÖ÷»úÃû±êʶ·ûÖÐʹÓà : ºÍ % - ÕâÁ½¸ö×Ö·ûÁË¡£ ÕâЩ×Ö·û±» IPv6 µØÖ·ºÍ scope ID ʹÓᣠ+ ÕâÁ½¸ö×Ö·ûÁË¡£ ÕâЩ×Ö·û±» IPv6 µØÖ·ºÍ scope ID ʹÓᣠ&merged; ÏÖÔÚ &man.systat.1; µÄÏÔʾҲ°üÀ¨ÁË IPv6 µÄÊý¾Ý¡£ &merged; @@ -860,6 +920,9 @@ <filename>/etc/rc.d</filename> ½Å±¾ + ¼ÓÈëÁËÓÃÓÚÆô¶¯ &man.bsnmpd.1; µÄÆô¶¯½Å±¾£¬ + rc.d/bsnmpd¡£ + &man.rc.conf.5; ÏÖÔÚÖ§³ÖÔÚÒýµ¼Ê±ÐÞ¸ÄÍøÂç½Ó¿ÚµÄÃû×ÖÁË¡£ &merged; ÀýÈ磺 @@ -1026,6 +1089,12 @@ Îĵµ + ÐÂÔöÁË &man.sched.4bsd.4; ºÍ &man.sched.ule.4; Áª»úÊֲᡣ + ËüÃǽéÉÜÁËÄÚºËÑ¡Ïî SCHED_4BSD ºÍ SCHED_ULE ÒÔ¼°ËûÃǸ÷×ÔÊÊÓÃµÄ sysctl¡£ + + ÐÂÔöÁË &man.ataraid.4; Áª»úÊֲᡣ Ëü½éÉÜÁË &man.ata.4; Èí¼þ + RAID Çý¶¯¡£ + ¶ÔÓÚ»ù±¾ÏµÍ³µÄÁª»úÊÖ²áÖеÄÄÚÈݺͱí´ï·½Ê½½øÐÐÁË´óÁ¿µÄÕûÀí¡£ ½»²æÒýÓøü¼Ó׼ȷºÍÒ»Ö£¬ ±ê׼С½ÚµÄ±êÌâ¹á´©Ê¼ÖÕ£¬ ¶øʹÓõķûºÅÒ²½øÐÐÁËÇåÀí¡£ ==== //depot/projects/wifi/sbin/atm/atm/atm.h#2 (text+ko) ==== @@ -23,7 +23,7 @@ * Copies of this Software may be made, however, the above copyright * notice must be reproduced on all copies. * - * @(#) $FreeBSD: src/sbin/atm/atm/atm.h,v 1.8 2003/07/29 13:37:04 harti Exp $ + * @(#) $FreeBSD: src/sbin/atm/atm/atm.h,v 1.9 2005/05/02 10:31:27 delphij Exp $ * */ @@ -191,6 +191,5 @@ void check_netif_name(const char *); void sock_error(int); -extern const struct proto protos[]; extern const struct aal aals[]; extern const struct encaps encaps[]; ==== //depot/projects/wifi/sbin/atm/atmconfig/atmconfig_device.h#2 (text+ko) ==== @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sbin/atm/atmconfig/atmconfig_device.h,v 1.1 2004/08/12 12:31:43 harti Exp $ + * $FreeBSD: src/sbin/atm/atmconfig/atmconfig_device.h,v 1.2 2005/05/02 10:31:27 delphij Exp $ */ #ifndef ATMCONFIG_DEVICE_H_ #define ATMCONFIG_DEVICE_H_ @@ -45,7 +45,7 @@ TAILQ_ENTRY(atmif) link; uint64_t found; int32_t index; - u_char *ifname; + char *ifname; size_t ifnamelen; uint32_t pcr; int32_t media; ==== //depot/projects/wifi/sbin/atm/ilmid/ilmid.c#2 (text+ko) ==== @@ -71,7 +71,7 @@ #include #ifndef lint -__RCSID("@(#) $FreeBSD: src/sbin/atm/ilmid/ilmid.c,v 1.33 2004/02/10 20:48:08 cperciva Exp $"); +__RCSID("@(#) $FreeBSD: src/sbin/atm/ilmid/ilmid.c,v 1.34 2005/05/02 10:31:27 delphij Exp $"); #endif @@ -1875,7 +1875,7 @@ get_local_ip (int s, long *aval) { char intf_name[IFNAMSIZ]; - int namelen = IFNAMSIZ; + socklen_t namelen = IFNAMSIZ; struct air_netif_rsp *net_info = NULL; struct sockaddr_in *sain; @@ -2468,7 +2468,7 @@ close ( ilmi_fd[intf] ); ilmi_fd[intf] = -1; } else { - bpp = (caddr_t)&buf[1]; + bpp = &buf[1]; Hdr = asn_get_header(&bpp); if ( Log && Debug_Level > 1 ) ==== //depot/projects/wifi/sbin/dump/traverse.c#2 (text+ko) ==== @@ -32,7 +32,7 @@ static char sccsid[] = "@(#)traverse.c 8.7 (Berkeley) 6/15/95"; #endif static const char rcsid[] = - "$FreeBSD: src/sbin/dump/traverse.c,v 1.35 2004/07/28 05:54:38 kan Exp $"; + "$FreeBSD: src/sbin/dump/traverse.c,v 1.36 2005/05/02 10:00:39 delphij Exp $"; #endif /* not lint */ #include @@ -149,7 +149,7 @@ union dinode *dp; struct cg *cgp; ino_t ino; - char *cp; + u_char *cp; if ((cgp = malloc(sblock->fs_cgsize)) == NULL) quit("mapfiles: cannot allocate memory.\n"); ==== //depot/projects/wifi/sbin/fdisk/fdisk.c#4 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/fdisk/fdisk.c,v 1.77 2005/04/29 21:24:27 phk Exp $"); +__FBSDID("$FreeBSD: src/sbin/fdisk/fdisk.c,v 1.79 2005/05/01 09:50:02 nyan Exp $"); #include #include @@ -51,8 +51,6 @@ #define LBUF 100 static char lbuf[LBUF]; -#define MBRSIGOFF 510 - /* * * Ported to 386bsd by Julian Elischer Thu Oct 15 20:26:46 PDT 1992 @@ -76,15 +74,14 @@ struct mboot { unsigned char padding[2]; /* force the longs to be long aligned */ - unsigned char *bootinst; /* boot code */ >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Mon May 2 23:29:55 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B2DC116A4D3; Mon, 2 May 2005 23:29:54 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7325116A4CE for ; Mon, 2 May 2005 23:29:54 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id CF7DC43D66 for ; Mon, 2 May 2005 23:29:53 +0000 (GMT) (envelope-from wsalamon@computer.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j42NTrim085619 for ; Mon, 2 May 2005 23:29:53 GMT (envelope-from wsalamon@computer.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j42NTrgG085616 for perforce@freebsd.org; Mon, 2 May 2005 23:29:53 GMT (envelope-from wsalamon@computer.org) Date: Mon, 2 May 2005 23:29:53 GMT Message-Id: <200505022329.j42NTrgG085616@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to wsalamon@computer.org using -f From: Wayne Salamon To: Perforce Change Reviews Subject: PERFORCE change 76394 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2005 23:29:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=76394 Change 76394 by wsalamon@rickenbacker on 2005/05/02 23:29:28 Cleanup of test cases: remove redundant includes; rework the includes to match the current BSM installation scheme. Affected files ... .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tchroot.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tdir.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfileaccess.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfilecreate.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfileioctl.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfilemodify.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tmmap.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tsharedfile.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/include/audittest.h#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tipc.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tmsg.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tposix.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tsem.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tshm.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/syscall/tsysaudit.c#3 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/system/tadmin.c#2 edit .. //depot/projects/trustedbsd/audit3/tools/regression/audit/test/system/tsysctl.c#2 edit Differences ... ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tchroot.c#3 (text+ko) ==== @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tdir.c#3 (text+ko) ==== @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfileaccess.c#3 (text+ko) ==== @@ -27,8 +27,6 @@ */ #include #include -#include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfilecreate.c#3 (text+ko) ==== @@ -27,8 +27,6 @@ */ #include #include -#include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfileioctl.c#3 (text+ko) ==== @@ -26,7 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -#include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tfilemodify.c#3 (text+ko) ==== @@ -27,8 +27,6 @@ */ #include #include -#include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tmmap.c#3 (text+ko) ==== @@ -27,7 +27,6 @@ */ #include #include -#include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/file/tsharedfile.c#3 (text+ko) ==== @@ -26,8 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -#include -#include #include /* ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/include/audittest.h#3 (text+ko) ==== @@ -25,11 +25,13 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ +#include +#include + +#include #include #include #include -#include -#include #define AUDITLOGSUFFIX "audit.log" #define INITIAL_AUID 666 ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tipc.c#3 (text+ko) ==== @@ -26,7 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -#include #include /* ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tmsg.c#3 (text+ko) ==== @@ -26,7 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tposix.c#3 (text+ko) ==== @@ -28,7 +28,6 @@ #include #include #include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tsem.c#3 (text+ko) ==== @@ -26,7 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/ipc/tshm.c#3 (text+ko) ==== @@ -26,7 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -#include #include #include #include ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/syscall/tsysaudit.c#3 (text+ko) ==== @@ -27,8 +27,6 @@ */ #include #include -#include -#include #include /* ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/system/tadmin.c#2 (text+ko) ==== @@ -25,14 +25,13 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ +#include #include #include #include -#include #include -#include #include -#include +#include /* * Test the auditing of some of the admin-related system calls. ==== //depot/projects/trustedbsd/audit3/tools/regression/audit/test/system/tsysctl.c#2 (text+ko) ==== @@ -25,12 +25,11 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ +#include #include #include #include -#include #include -#include /* * Test the auditing of some of the sysctl() system call. From owner-p4-projects@FreeBSD.ORG Tue May 3 02:34:37 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id EE2DE16A4D0; Tue, 3 May 2005 02:34:36 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8CE8416A4CF for ; Tue, 3 May 2005 02:34:36 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2B30143D7B for ; Tue, 3 May 2005 02:34:36 +0000 (GMT) (envelope-from scottl@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j432YajQ098741 for ; Tue, 3 May 2005 02:34:36 GMT (envelope-from scottl@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j432YZkW098734 for perforce@freebsd.org; Tue, 3 May 2005 02:34:35 GMT (envelope-from scottl@freebsd.org) Date: Tue, 3 May 2005 02:34:35 GMT Message-Id: <200505030234.j432YZkW098734@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to scottl@freebsd.org using -f From: Scott Long To: Perforce Change Reviews Subject: PERFORCE change 76397 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 02:34:37 -0000 http://perforce.freebsd.org/chv.cgi?CH=76397 Change 76397 by scottl@scottl-x64 on 2005/05/03 02:34:30 Remove much of the GNU Make specific contructs. Affected files ... .. //depot/projects/trustedbsd/sebsd/contrib/sebsd/libsepol/src/Makefile#2 edit .. //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#17 edit Differences ... ==== //depot/projects/trustedbsd/sebsd/contrib/sebsd/libsepol/src/Makefile#2 (text+ko) ==== @@ -8,11 +8,11 @@ # Set to y for MLS MLS=n -ifeq ($(MLS),y) +.if $(MLS) == "y" OPTIONS = -DCONFIG_SECURITY_SELINUX_MLS -else +.else OPTIONS = -endif +.endif LIBA=libsepol.a TARGET=libsepol.so ==== //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#17 (text+ko) ==== @@ -20,7 +20,8 @@ LOADPOLICY = $(DESTDIR)/sbin/sebsd_loadpolicy CHECKPOLICY = $(DESTDIR)/sbin/sebsd_checkpolicy SETFILES = $(DESTDIR)/sbin/sebsd_setfiles -POLICYVER := policy.$(shell $(CHECKPOLICY) $(POLICYCOMPAT) -V |cut -f 1 -d ' ') +POLICYVERTMP != ($(CHECKPOLICY) $(POLICYCOMPAT) -V |cut -f 1 -d ' ') +POLICYVER := policy.$(POLICYVERTMP) INSTALLDIR = $(DESTDIR)/etc/security/sebsd POLICYPATH = $(INSTALLDIR)/policy SRCPATH = $(INSTALLDIR)/src @@ -28,18 +29,19 @@ LOADPATH = $(POLICYPATH)/$(POLICYVER) FCPATH = $(CONTEXTPATH)/files/file_contexts -ALL_PROGRAM_MACROS := $(wildcard macros/program/*.te) -ALL_MACROS := $(ALL_PROGRAM_MACROS) $(wildcard macros/*.te) -ALL_TYPES := $(wildcard types/*.te) -ALL_DOMAINS := $(wildcard domains/*.te domains/misc/*.te domains/program/*.te) +ALL_PROGRAM_MACROS := macros/program/*.te +ALL_MACROS := $(ALL_PROGRAM_MACROS) macros/*.te +ALL_TYPES := types/*.te +ALL_DOMAINS := domains/*.te domains/misc/*.te domains/program/*.te ALLTEFILES := attrib.te tmp/program_used_flags.te $(ALL_MACROS) $(ALL_TYPES) $(ALL_DOMAINS) assert.te TE_RBAC_FILES := $(ALLTEFILES) rbac -ALL_TUNABLES := $(wildcard tunables/*.tun ) +ALL_TUNABLES := tunables/*.tun +ALL_TUNABLES = -POLICYFILES = $(addprefix $(FLASKDIR),security_classes initial_sids access_vectors) -ifeq ($(MLS),y) +POLICYFILES = $(FLASKDIR)/security_classes $(FLASKDIR)/initial_sids $(FLASKDIR)/access_vectors +.if $(MLS) == "y" POLICYFILES += mls -endif +.endif POLICYFILES += $(ALL_TUNABLES) $(TE_RBAC_FILES) POLICYFILES += users serviceusers POLICYFILES += constraints initial_sid_contexts fs_use genfs_contexts net_contexts @@ -48,43 +50,47 @@ INSTALLCMD = install -c -o root -g wheel -m 400 APPCONFDIR = $(DESTDIR)/etc/security -MULTILABELMOUNTS = $(shell /sbin/mount -t ufs -p | \ +MULTILABELMOUNTS != ( /sbin/mount -t ufs -p | \ /usr/bin/awk '{if (match($$4, "multilabel")) {print $$2}}') -UNUSED_TE_FILES := $(wildcard domains/program/unused/*.te) +UNUSED_TE_FILES := domains/program/unused/*.te + +PROGRAMFILES := domains/program/*.te FC = file_contexts/file_contexts -FCFILES=file_contexts/types.fc $(wildcard file_contexts/misc/*.fc) $(patsubst domains/program/%.te,file_contexts/program/%.fc, $(wildcard domains/program/*.te)) +FCTEFILES := $(PROGRAMFILES:S/^domains\/program\//file_contexts\/program\//) +FCFILES = file_contexts/*.fc file_contexts/program/*.fc +FCFILES += $(FCTEFILES:.te=.fc) APPDIR=$(CONTEXTPATH) -APPFILES = $(addprefix $(APPDIR)/,default_contexts default_type initrc_context failsafe_context userhelper_context) -ROOTFILES = $(addprefix $(APPDIR)/users/,root) +APPFILES = $(APPDIR)/default_contexts $(APPDIR)/default_type $(APPDIR)/initrc_context # $(APPDIR)/userhelper_context $(APPDIR)/failsafe_context +ROOTFILES = # $(APPDIR)/users/root install: $(APPFILES) $(ROOTFILES) $(LOADPATH) $(FCPATH) $(APPDIR)/default_contexts: appconfig/default_contexts mkdir -p $(APPDIR) - install -m 644 $< $@ + install -m 644 appconfig/default_contexts $@ $(APPDIR)/default_type: appconfig/default_type mkdir -p $(APPDIR) - install -m 644 $< $@ + install -m 644 appconfig/default_type $@ $(APPDIR)/userhelper_context: appconfig/userhelper_context mkdir -p $(APPDIR) - install -m 644 $< $@ + install -m 644 appconfig/userhelper_context $@ $(APPDIR)/initrc_context: appconfig/initrc_context mkdir -p $(APPDIR) - install -m 644 $< $@ + install -m 644 appconfig/initrc_context $@ $(APPDIR)/failsafe_context: appconfig/failsafe_context mkdir -p $(APPDIR) - install -m 644 $< $@ + install -m 644 appconfig/failsafe_context $@ $(APPDIR)/users/root: appconfig/root_default_contexts mkdir -p $(APPDIR)/users - install -m 644 $< $@ + install -m 644 appconfig/root_default_contexts $@ $(LOADPATH): policy.conf $(CHECKPOLICY) @@ -110,7 +116,7 @@ policy.conf: $(POLICYFILES) mkdir -p tmp - m4 $(M4PARAM) -Imacros -s $^ > $@.tmp + m4 $(M4PARAM) -Imacros -s $(POLICYFILES) > $@.tmp mv $@.tmp $@ install-src: /etc/security/sebsd From owner-p4-projects@FreeBSD.ORG Tue May 3 10:57:55 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 067B016A4D0; Tue, 3 May 2005 10:57:55 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BCA2116A4CF for ; Tue, 3 May 2005 10:57:54 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6B15C43D41 for ; Tue, 3 May 2005 10:57:54 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43AvsSe032650 for ; Tue, 3 May 2005 10:57:54 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43AvqXh032647 for perforce@freebsd.org; Tue, 3 May 2005 10:57:52 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 3 May 2005 10:57:52 GMT Message-Id: <200505031057.j43AvqXh032647@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76416 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 10:57:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=76416 Change 76416 by rwatson@rwatson_paprika on 2005/05/03 10:57:38 Use au_return32() as the canonical name. Affected files ... .. //depot/projects/trustedbsd/openbsm/man/audit.log.5#4 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/man/audit.log.5#4 (text+ko) ==== @@ -339,7 +339,7 @@ A .Dv return token can be created using -.Xr au_to_return 3 +.Xr au_to_return32 3 or .Xr au_to_return64 3 . .Bl -column -offset ind ".Sy Field Name Width XX" ".Sy XX Bytes XXXX" ".Sy Description" From owner-p4-projects@FreeBSD.ORG Tue May 3 10:58:59 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 66D4D16A4D0; Tue, 3 May 2005 10:58:59 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 11D9216A4CE for ; Tue, 3 May 2005 10:58:59 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C045243D2F for ; Tue, 3 May 2005 10:58:58 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43Awuxg032794 for ; Tue, 3 May 2005 10:58:56 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43Awtgm032791 for perforce@freebsd.org; Tue, 3 May 2005 10:58:55 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 3 May 2005 10:58:55 GMT Message-Id: <200505031058.j43Awtgm032791@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76417 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 10:59:00 -0000 http://perforce.freebsd.org/chv.cgi?CH=76417 Change 76417 by rwatson@rwatson_paprika on 2005/05/03 10:58:55 Move from AU_.*_TOKEN to AUT_.*, with minor tweaks, to match the constant names used by Solaris; provide compatibility defines for Darwin's BSM that we will remove at some point in the future. This will allow token handling code written to Sun's API to compile with OpenBSM more easily. Most tools don't use the token defines, since that is only needed for direct frobbing of the binary audit stream, so this relatively non-disruptive for everything but libbsm itself. Internal function names are not yet renamed to match the new token names. Document a couple of cases where a #define was present in Darwin that is not easily google-able. Affected files ... .. //depot/projects/trustedbsd/openbsm/bsm/audit_record.h#9 edit .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#12 edit .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_token.c#13 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/bsm/audit_record.h#9 (text+ko) ==== @@ -35,116 +35,137 @@ * Values marked as XXX do not have a value defined in the BSM header files */ -/* - * Control token types - -#define AUT_OTHER_FILE ((char)0x11) -#define AUT_OTHER_FILE32 AUT_OTHER_FILE -#define AUT_OHEADER ((char)0x12) +#define AUT_INVALID 0x00 +#define AUT_OTHER_FILE32 0x11 +#define AUT_OHEADER 0x12 +#define AUT_TRAILER 0x13 +#define AUT_HEADER32 0x14 +#define AUT_HEADER32_EX 0x15 +#define AUT_DATA 0x21 +#define AUT_IPC 0x22 +#define AUT_PATH 0x23 +#define AUT_SUBJECT32 0x24 +#define AUT_SERVER32 0x25 +#define AUT_PROCESS32 0x26 +#define AUT_RETURN32 0x27 +#define AUT_TEXT 0x28 +#define AUT_OPAQUE 0x29 +#define AUT_IN_ADDR 0x2a +#define AUT_IP 0x2b +#define AUT_IPORT 0x2c +#define AUT_ARG32 0x2d +#define AUT_SOCKET 0x2e +#define AUT_SEQ 0x2f +#define AUT_ACL 0x30 +#define AUT_ATTR 0x31 +#define AUT_IPC_PERM 0x32 +#define AUT_LABEL 0x33 +#define AUT_GROUPS 0x34 +#define AUT_ILABEL 0x35 +#define AUT_SLABEL 0x36 +#define AUT_CLEAR 0x37 +#define AUT_PRIV 0x38 +#define AUT_UPRIV 0x39 +#define AUT_LIAISON 0x3a +#define AUT_NEWGROUPS 0x3b +#define AUT_EXEC_ARGS 0x3c +#define AUT_EXEC_ENV 0x3d +#define AUT_ATTR32 0x3e +/* #define AUT_???? 0x3f */ +#define AUT_XATOM 0x40 +#define AUT_XOBJ 0x41 +#define AUT_XPROTO 0x42 +#define AUT_XSELECT 0x43 +/* XXXRW: Additional X11 tokens not defined? */ +#define AUT_CMD 0x51 +#define AUT_EXIT 0x52 +/* XXXRW: OpenBSM AUT_HOST 0x70? */ +#define AUT_ARG64 0x71 +#define AUT_RETURN64 0x72 +#define AUT_ATTR64 0x73 +#define AUT_HEADER64 0x74 +#define AUT_SUBJECT64 0x75 +#define AUT_SERVER64 0x76 +#define AUT_PROCESS64 0x77 +#define AUT_OTHER_FILE64 0x78 +#define AUT_HEADER64_EX 0x79 +#define AUT_SUBJECT32_EX 0x7a +#define AUT_PROCESS32_EX 0x7b +#define AUT_SUBJECT64_EX 0x7c +#define AUT_PROCESS64_EX 0x7d +#define AUT_IN_ADDR_EX 0x7e +#define AUT_SOCKET_EX 0x7f - */ - -#define AUT_INVALID 0x00 -#define AU_FILE_TOKEN 0x11 -#define AU_TRAILER_TOKEN 0x13 -#define AU_HEADER_32_TOKEN 0x14 -#define AU_HEADER_EX_32_TOKEN 0x15 - /* - * Data token types -#define AUT_SERVER ((char)0x25) -#define AUT_SERVER32 AUT_SERVER + * Pre-64-bit BSM, 32-bit tokens weren't explicitly named as '32'. We have + * compatibility defines. */ +#define AUT_HEADER AUT_HEADER32 +#define AUT_ARG AUT_ARG32 +#define AUT_RETURN AUT_RETURN32 +#define AUT_SUBJECT AUT_SUBJECT32 +#define AUT_SERVER AUT_SERVER32 +#define AUT_PROCESS AUT_PROCESS32 +#define AUT_OTHER_FILE AUT_OTHER_FILE32 -#define AU_DATA_TOKEN 0x21 -#define AU_ARB_TOKEN AU_DATA_TOKEN -#define AU_IPC_TOKEN 0x22 -#define AU_PATH_TOKEN 0x23 -#define AU_SUBJECT_32_TOKEN 0x24 -#define AU_PROCESS_32_TOKEN 0x26 -#define AU_RETURN_32_TOKEN 0x27 -#define AU_TEXT_TOKEN 0x28 -#define AU_OPAQUE_TOKEN 0x29 -#define AU_IN_ADDR_TOKEN 0x2A -#define AU_IP_TOKEN 0x2B -#define AU_IPORT_TOKEN 0x2C -#define AU_ARG32_TOKEN 0x2D -#define AU_SOCK_TOKEN 0x2E -#define AU_SEQ_TOKEN 0x2F - /* - * Modifier token types - -#define AUT_ACL ((char)0x30) -#define AUT_LABEL ((char)0x33) -#define AUT_GROUPS ((char)0x34) -#define AUT_ILABEL ((char)0x35) -#define AUT_SLABEL ((char)0x36) -#define AUT_CLEAR ((char)0x37) -#define AUT_PRIV ((char)0x38) -#define AUT_UPRIV ((char)0x39) -#define AUT_LIAISON ((char)0x3A) - + * Darwin's bsm distribution uses the following non-BSM token name defines. + * We provide them for a single OpenBSM release for compatibility reasons. */ - -#define AU_ATTR_TOKEN 0x31 -#define AU_IPCPERM_TOKEN 0x32 -#define AU_NEWGROUPS_TOKEN 0x3B -#define AU_EXEC_ARG_TOKEN 0x3C -#define AU_EXEC_ENV_TOKEN 0x3D -#define AU_ATTR32_TOKEN 0x3E +#define AU_FILE_TOKEN AUT_OTHER_FILE32 +#define AU_TRAILER_TOKEN AUT_TRAILER +#define AU_HEADER_32_TOKEN AUT_HEADER32 +#define AU_DATA_TOKEN AUT_DATA +#define AU_ARB_TOKEN AUT_DATA +#define AU_IPC_TOKEN AUT_IPC +#define AU_PATH_TOKEN AUT_PATH +#define AU_SUBJECT_32_TOKEN AUT_SUBJECT32 +#define AU_PROCESS_32_TOKEN AUT_PROCESS32 +#define AU_RETURN_32_TOKEN AUT_RETURN32 +#define AU_TEXT_TOKEN AUT_TEXT +#define AU_OPAQUE_TOKEN AUT_OPAQUE +#define AU_IN_ADDR_TOKEN AUT_IN_ADDR +#define AU_IP_TOKEN AUT_IP +#define AU_IPORT_TOKEN AUT_IPORT +#define AU_ARG32_TOKEN AUT_ARG32 +#define AU_SOCK_TOKEN AUT_SOCKET +#define AU_SEQ_TOKEN AUT_SEQ +#define AU_ATTR_TOKEN AUT_ATTR +#define AU_IPCPERM_TOKEN AUT_IPC_PERM +#define AU_NEWGROUPS_TOKEN AUT_NEWGROUPS +#define AU_EXEC_ARG_TOKEN AUT_EXEC_ARGS +#define AU_EXEC_ENV_TOKEN AUT_EXEC_ENV +#define AU_ATTR32_TOKEN AUT_ATTR32 +#define AU_CMD_TOKEN AUT_CMD +#define AU_EXIT_TOKEN AUT_EXIT +#define AU_ARG64_TOKEN AUT_ARG64 +#define AU_RETURN_64_TOKEN AUT_RETURN64 +#define AU_ATTR64_TOKEN AUT_ATTR64 +#define AU_HEADER_64_TOKEN AUT_HEADER64 +#define AU_SUBJECT_64_TOKEN AUT_SUBJECT64 +#define AU_PROCESS_64_TOKEN AUT_PROCESS64 +#define AU_HEADER_64_EX_TOKEN AUT_HEADER64_EX +#define AU_SUBJECT_32_EX_TOKEN AUT_SUBJECT32_EX +#define AU_PROCESS_32_EX_TOKEN AUT_PROCESS32_EX +#define AU_SUBJECT_64_EX_TOKEN AUT_SUBJECT64_EX +#define AU_PROCESS_64_EX_TOKEN AUT_PROCESS64_EX +#define AU_IN_ADDR_EX_TOKEN AUT_IN_ADDR_EX +#define AU_SOCK_32_EX_TOKEN AUT_SOCKET_EX /* - * Command token types + * The values for the following token ids are not defined by BSM. + * + * XXXRW: Not sure how to andle these in OpenBSM yet, but I'll give them + * names more consistent with Sun's BSM. These originally came from Apple's + * BSM. */ - -#define AU_CMD_TOKEN 0x51 -#define AU_EXIT_TOKEN 0x52 - -/* - * Miscellaneous token types - -#define AUT_HOST ((char)0x70) - - */ - -/* - * 64bit token types +#define AUT_SOCKINET32 0x80 /* XXX */ +#define AUT_SOCKINET128 0x81 /* XXX */ +#define AUT_SOCKUNIX 0x82 /* XXX */ +#define AU_SOCK_INET_32_TOKEN AUT_SOCKINET32 +#define AU_SOCK_INET_128_TOKEN AUT_SOCKINET128 +#define AU_SOCK_UNIX_TOKEN AUT_SOCKUNIX -#define AUT_SERVER64 ((char)0x76) -#define AUT_OTHER_FILE64 ((char)0x78) - - */ - -#define AU_ARG64_TOKEN 0x71 -#define AU_RETURN_64_TOKEN 0x72 -#define AU_ATTR64_TOKEN 0x73 -#define AU_HEADER_64_TOKEN 0x74 -#define AU_SUBJECT_64_TOKEN 0x75 -#define AU_PROCESS_64_TOKEN 0x77 - -/* - * Extended network address token types - */ - -#define AU_HEADER_EX_64_TOKEN 0x79 -#define AU_SUBJECT_32_EX_TOKEN 0x7a -#define AU_PROCESS_32_EX_TOKEN 0x7b -#define AU_SUBJECT_64_EX_TOKEN 0x7c -#define AU_PROCESS_64_EX_TOKEN 0x7d -#define AU_IN_ADDR_EX_TOKEN 0x7e -#define AU_SOCK_EX32_TOKEN 0x7f -#define AU_SOCK_EX128_TOKEN AUT_INVALID /*XXX*/ -#define AU_IP_EX_TOKEN AUT_INVALID /*XXX*/ - -/* - * The values for the following token ids are not - * defined by BSM - */ -#define AU_SOCK_INET_32_TOKEN 0x80 /*XXX*/ -#define AU_SOCK_INET_128_TOKEN 0x81 /*XXX*/ -#define AU_SOCK_UNIX_TOKEN 0x82 /*XXX*/ - /* print values for the arbitrary token */ #define AUP_BINARY 0 #define AUP_OCTAL 1 @@ -169,7 +190,13 @@ #define BSM_MAX_GROUPS 16 #define HEADER_VERSION 1 -#define TRAILER_PAD_MAGIC 0xB105 + +/* + * BSM define is AUT_TRAILER_MAGIC; Apple BSM define is TRAILER_PAD_MAGIC; we + * split the difference, will remove the Apple define for the next release. + */ +#define AUT_TRAILER_MAGIC 0xb105 +#define TRAILER_PAD_MAGIC AUT_TRAILER_MAGIC /* BSM library calls */ ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_io.c#12 (text+ko) ==== @@ -2284,106 +2284,106 @@ switch(tok->id) { - case AU_HEADER_32_TOKEN : + case AUT_HEADER32: return fetch_header32_tok(tok, buf, len); - case AU_HEADER_64_TOKEN : + case AUT_HEADER64: return fetch_header64_tok(tok, buf, len); - case AU_TRAILER_TOKEN : + case AUT_TRAILER: return fetch_trailer_tok(tok, buf, len); - case AU_ARG32_TOKEN : + case AUT_ARG32: return fetch_arg32_tok(tok, buf, len); - case AU_ARG64_TOKEN : + case AUT_ARG64: return fetch_arg64_tok(tok, buf, len); - case AU_ATTR32_TOKEN : + case AUT_ATTR32: return fetch_attr32_tok(tok, buf, len); - case AU_ATTR64_TOKEN : + case AUT_ATTR64: return fetch_attr64_tok(tok, buf, len); - case AU_EXIT_TOKEN : + case AUT_EXIT: return fetch_exit_tok(tok, buf, len); - case AU_EXEC_ARG_TOKEN : + case AUT_EXEC_ARGS: return fetch_execarg_tok(tok, buf, len); - case AU_EXEC_ENV_TOKEN : + case AUT_EXEC_ENV: return fetch_execenv_tok(tok, buf, len); - case AU_FILE_TOKEN : + case AUT_OTHER_FILE32: return fetch_file_tok(tok, buf, len); - case AU_NEWGROUPS_TOKEN : + case AUT_NEWGROUPS: return fetch_newgroups_tok(tok, buf, len); - case AU_IN_ADDR_TOKEN : + case AUT_IN_ADDR: return fetch_inaddr_tok(tok, buf, len); - case AU_IN_ADDR_EX_TOKEN : + case AUT_IN_ADDR_EX: return fetch_inaddr_ex_tok(tok, buf, len); - case AU_IP_TOKEN : + case AUT_IP: return fetch_ip_tok(tok, buf, len); - case AU_IPC_TOKEN : + case AUT_IPC: return fetch_ipc_tok(tok, buf, len); - case AU_IPCPERM_TOKEN : + case AUT_IPC_PERM: return fetch_ipcperm_tok(tok, buf, len); - case AU_IPORT_TOKEN : + case AUT_IPORT: return fetch_iport_tok(tok, buf, len); - case AU_OPAQUE_TOKEN : + case AUT_OPAQUE: return fetch_opaque_tok(tok, buf, len); - case AU_PATH_TOKEN : + case AUT_PATH: return fetch_path_tok(tok, buf, len); - case AU_PROCESS_32_TOKEN : + case AUT_PROCESS32: return fetch_process32_tok(tok, buf, len); - case AU_PROCESS_32_EX_TOKEN : + case AUT_PROCESS32_EX: return fetch_process32ex_tok(tok, buf, len); - case AU_RETURN_32_TOKEN : + case AUT_RETURN32: return fetch_return32_tok(tok, buf, len); - case AU_RETURN_64_TOKEN : + case AUT_RETURN64: return fetch_return64_tok(tok, buf, len); - case AU_SEQ_TOKEN : + case AUT_SEQ: return fetch_seq_tok(tok, buf, len); - case AU_SOCK_TOKEN : + case AUT_SOCKET: return fetch_socket_tok(tok, buf, len); - case AU_SOCK_INET_32_TOKEN : + case AUT_SOCKINET32: return fetch_sock_inet32_tok(tok, buf, len); - case AU_SOCK_UNIX_TOKEN : + case AUT_SOCKUNIX: return fetch_sock_unix_tok(tok, buf, len); - case AU_SUBJECT_32_TOKEN : + case AUT_SUBJECT32: return fetch_subject32_tok(tok, buf, len); - case AU_SUBJECT_64_TOKEN : + case AUT_SUBJECT64: return fetch_subject64_tok(tok, buf, len); - case AU_SUBJECT_32_EX_TOKEN : + case AUT_SUBJECT32_EX: return fetch_subject32ex_tok(tok, buf, len); - case AU_TEXT_TOKEN : + case AUT_TEXT: return fetch_text_tok(tok, buf, len); - case AU_SOCK_EX32_TOKEN : + case AUT_SOCKET_EX: return fetch_socketex32_tok(tok, buf, len); - case AU_ARB_TOKEN : + case AUT_DATA: return fetch_arb_tok(tok, buf, len); default: @@ -2398,106 +2398,106 @@ { switch(tok->id) { - case AU_HEADER_32_TOKEN : + case AUT_HEADER32: return print_header32_tok(outfp, tok, del, raw, sfrm); - case AU_HEADER_64_TOKEN: + case AUT_HEADER64: return print_header64_tok(outfp, tok, del, raw, sfrm); - case AU_TRAILER_TOKEN : + case AUT_TRAILER: return print_trailer_tok(outfp, tok, del, raw, sfrm); - case AU_ARG32_TOKEN : + case AUT_ARG32: return print_arg32_tok(outfp, tok, del, raw, sfrm); - case AU_ARG64_TOKEN : + case AUT_ARG64: return print_arg64_tok(outfp, tok, del, raw, sfrm); - case AU_ARB_TOKEN : + case AUT_DATA: return print_arb_tok(outfp, tok, del, raw, sfrm); - case AU_ATTR32_TOKEN : + case AUT_ATTR32: return print_attr32_tok(outfp, tok, del, raw, sfrm); - case AU_ATTR64_TOKEN : + case AUT_ATTR64: return print_attr64_tok(outfp, tok, del, raw, sfrm); - case AU_EXIT_TOKEN : + case AUT_EXIT: return print_exit_tok(outfp, tok, del, raw, sfrm); - case AU_EXEC_ARG_TOKEN : + case AUT_EXEC_ARGS: return print_execarg_tok(outfp, tok, del, raw, sfrm); - case AU_EXEC_ENV_TOKEN : + case AUT_EXEC_ENV: return print_execenv_tok(outfp, tok, del, raw, sfrm); - case AU_FILE_TOKEN : + case AUT_OTHER_FILE32: return print_file_tok(outfp, tok, del, raw, sfrm); - case AU_NEWGROUPS_TOKEN : + case AUT_NEWGROUPS: return print_newgroups_tok(outfp, tok, del, raw, sfrm); - case AU_IN_ADDR_TOKEN : + case AUT_IN_ADDR: return print_inaddr_tok(outfp, tok, del, raw, sfrm); - case AU_IN_ADDR_EX_TOKEN : + case AUT_IN_ADDR_EX: return print_inaddr_ex_tok(outfp, tok, del, raw, sfrm); - case AU_IP_TOKEN : + case AUT_IP: return print_ip_tok(outfp, tok, del, raw, sfrm); - case AU_IPC_TOKEN : + case AUT_IPC: return print_ipc_tok(outfp, tok, del, raw, sfrm); - case AU_IPCPERM_TOKEN : + case AUT_IPC_PERM: return print_ipcperm_tok(outfp, tok, del, raw, sfrm); - case AU_IPORT_TOKEN : + case AUT_IPORT: return print_iport_tok(outfp, tok, del, raw, sfrm); - case AU_OPAQUE_TOKEN : + case AUT_OPAQUE: return print_opaque_tok(outfp, tok, del, raw, sfrm); - case AU_PATH_TOKEN : + case AUT_PATH: return print_path_tok(outfp, tok, del, raw, sfrm); - case AU_PROCESS_32_TOKEN : + case AUT_PROCESS32: return print_process32_tok(outfp, tok, del, raw, sfrm); - case AU_PROCESS_32_EX_TOKEN : + case AUT_PROCESS32_EX: return print_process32ex_tok(outfp, tok, del, raw, sfrm); - case AU_RETURN_32_TOKEN : + case AUT_RETURN32: return print_return32_tok(outfp, tok, del, raw, sfrm); - case AU_RETURN_64_TOKEN : + case AUT_RETURN64: return print_return64_tok(outfp, tok, del, raw, sfrm); - case AU_SEQ_TOKEN : + case AUT_SEQ: return print_seq_tok(outfp, tok, del, raw, sfrm); - case AU_SOCK_TOKEN : + case AUT_SOCKET: return print_socket_tok(outfp, tok, del, raw, sfrm); - case AU_SOCK_INET_32_TOKEN : + case AUT_SOCKINET32: return print_sock_inet32_tok(outfp, tok, del, raw, sfrm); - case AU_SOCK_UNIX_TOKEN : + case AUT_SOCKUNIX: return print_sock_unix_tok(outfp, tok, del, raw, sfrm); - case AU_SUBJECT_32_TOKEN : + case AUT_SUBJECT32: return print_subject32_tok(outfp, tok, del, raw, sfrm); - case AU_SUBJECT_64_TOKEN : + case AUT_SUBJECT64: return print_subject64_tok(outfp, tok, del, raw, sfrm); - case AU_SUBJECT_32_EX_TOKEN : + case AUT_SUBJECT32_EX: return print_subject32ex_tok(outfp, tok, del, raw, sfrm); - case AU_TEXT_TOKEN : + case AUT_TEXT: return print_text_tok(outfp, tok, del, raw, sfrm); - case AU_SOCK_EX32_TOKEN : + case AUT_SOCKET_EX: return print_socketex32_tok(outfp, tok, del, raw, sfrm); default: @@ -2530,10 +2530,10 @@ type = fgetc(fp); switch (type) { - case AU_HEADER_32_TOKEN: - case AU_HEADER_EX_32_TOKEN: - case AU_HEADER_64_TOKEN: - case AU_HEADER_EX_64_TOKEN: + case AUT_HEADER32: + case AUT_HEADER32_EX: + case AUT_HEADER64: + case AUT_HEADER64_EX: /* read the record size from the token */ if (fread(&recsize, 1, sizeof(u_int32_t), fp) < sizeof(u_int32_t)) { @@ -2570,7 +2570,7 @@ } break; - case AU_FILE_TOKEN: + case AUT_OTHER_FILE32: /* * The file token is variable-length, as it includes a * pathname. As a result, we have to read incrementally ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_token.c#13 (text+ko) ==== @@ -100,7 +100,7 @@ textlen += 1; - ADD_U_CHAR(dptr, AU_ARG32_TOKEN); + ADD_U_CHAR(dptr, AUT_ARG32); ADD_U_CHAR(dptr, n); ADD_U_INT32(dptr, v); ADD_U_INT16(dptr, textlen); @@ -129,7 +129,7 @@ textlen += 1; - ADD_U_CHAR(dptr, AU_ARG64_TOKEN); + ADD_U_CHAR(dptr, AUT_ARG64); ADD_U_CHAR(dptr, n); ADD_U_INT64(dptr, v); ADD_U_INT16(dptr, textlen); @@ -172,7 +172,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_ATTR32_TOKEN); + ADD_U_CHAR(dptr, AUT_ATTR32); /* * Darwin defines the size for the file mode @@ -260,7 +260,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_ARB_TOKEN); + ADD_U_CHAR(dptr, AUT_DATA); ADD_U_CHAR(dptr, unit_print); ADD_U_CHAR(dptr, unit_type); ADD_U_CHAR(dptr, unit_count); @@ -285,7 +285,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_EXIT_TOKEN); + ADD_U_CHAR(dptr, AUT_EXIT); ADD_U_INT32(dptr, err); ADD_U_INT32(dptr, retval); @@ -320,7 +320,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_NEWGROUPS_TOKEN); + ADD_U_CHAR(dptr, AUT_NEWGROUPS); ADD_U_INT16(dptr, n); for(i = 0; i < n; i++) { ADD_U_INT32(dptr, groups[i]); @@ -351,7 +351,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_IN_ADDR_TOKEN); + ADD_U_CHAR(dptr, AUT_IN_ADDR); ADD_U_INT32(dptr, internet_addr->s_addr); return t; @@ -378,7 +378,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_IN_ADDR_EX_TOKEN); + ADD_U_CHAR(dptr, AUT_IN_ADDR_EX); ADD_U_INT32(dptr, type); ADD_U_INT32(dptr, internet_addr->__u6_addr.__u6_addr32[0]); ADD_U_INT32(dptr, internet_addr->__u6_addr.__u6_addr32[1]); @@ -407,7 +407,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_IP_TOKEN); + ADD_U_CHAR(dptr, AUT_IP); /* * XXXRW: Any byte order work needed on the IP header before writing? */ @@ -432,7 +432,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_IPC_TOKEN); + ADD_U_CHAR(dptr, AUT_IPC); ADD_U_CHAR(dptr, type); ADD_U_INT32(dptr, id); @@ -466,7 +466,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_IPCPERM_TOKEN); + ADD_U_CHAR(dptr, AUT_IPC_PERM); /* @@ -512,7 +512,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_IPORT_TOKEN); + ADD_U_CHAR(dptr, AUT_IPORT); ADD_U_INT16(dptr, iport); return t; @@ -539,7 +539,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_OPAQUE_TOKEN); + ADD_U_CHAR(dptr, AUT_OPAQUE); ADD_U_INT16(dptr, bytes); ADD_MEM(dptr, data, bytes); @@ -579,7 +579,7 @@ filelen += 1; timems = tm.tv_usec/1000; - ADD_U_CHAR(dptr, AU_FILE_TOKEN); + ADD_U_CHAR(dptr, AUT_OTHER_FILE32); ADD_U_INT32(dptr, tm.tv_sec); ADD_U_INT32(dptr, timems); /* We need time in ms */ ADD_U_INT16(dptr, filelen); @@ -613,7 +613,7 @@ textlen += 1; - ADD_U_CHAR(dptr, AU_TEXT_TOKEN); + ADD_U_CHAR(dptr, AUT_TEXT); ADD_U_INT16(dptr, textlen); ADD_STRING(dptr, text, textlen); @@ -643,7 +643,7 @@ textlen += 1; - ADD_U_CHAR(dptr, AU_PATH_TOKEN); + ADD_U_CHAR(dptr, AUT_PATH); ADD_U_INT16(dptr, textlen); ADD_STRING(dptr, text, textlen); @@ -680,7 +680,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_PROCESS_32_TOKEN); + ADD_U_CHAR(dptr, AUT_PROCESS32); ADD_U_INT32(dptr, auid); ADD_U_INT32(dptr, euid); ADD_U_INT32(dptr, egid); @@ -742,7 +742,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_PROCESS_32_EX_TOKEN); + ADD_U_CHAR(dptr, AUT_PROCESS32_EX); ADD_U_INT32(dptr, auid); ADD_U_INT32(dptr, euid); ADD_U_INT32(dptr, egid); @@ -793,7 +793,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_RETURN_32_TOKEN); + ADD_U_CHAR(dptr, AUT_RETURN32); ADD_U_CHAR(dptr, status); ADD_U_INT32(dptr, ret); @@ -811,7 +811,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_RETURN_64_TOKEN); + ADD_U_CHAR(dptr, AUT_RETURN64); ADD_U_CHAR(dptr, status); ADD_U_INT64(dptr, ret); @@ -838,7 +838,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_SEQ_TOKEN); + ADD_U_CHAR(dptr, AUT_SEQ); ADD_U_INT32(dptr, audit_count); return t; @@ -906,7 +906,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_SOCK_INET_32_TOKEN); + ADD_U_CHAR(dptr, AUT_SOCKINET32); /* * In Darwin, sin_family is one octet, but BSM defines the token * to store two. So we copy in a 0 first. @@ -935,7 +935,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_SOCK_INET_128_TOKEN); + ADD_U_CHAR(dptr, AUT_SOCKINET128); /* * In Darwin, sin6_family is one octet, but BSM defines the token * to store two. So we copy in a 0 first. @@ -988,7 +988,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_SUBJECT_32_TOKEN); + ADD_U_CHAR(dptr, AUT_SUBJECT32); ADD_U_INT32(dptr, auid); ADD_U_INT32(dptr, euid); ADD_U_INT32(dptr, egid); @@ -1050,7 +1050,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_SUBJECT_32_EX_TOKEN); + ADD_U_CHAR(dptr, AUT_SUBJECT32_EX); ADD_U_INT32(dptr, auid); ADD_U_INT32(dptr, euid); ADD_U_INT32(dptr, egid); @@ -1139,7 +1139,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_EXEC_ARG_TOKEN); + ADD_U_CHAR(dptr, AUT_EXEC_ARGS); ADD_U_INT32(dptr, count); for(i =0; i< count; i++) { @@ -1186,7 +1186,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_EXEC_ENV_TOKEN); + ADD_U_CHAR(dptr, AUT_EXEC_ENV); ADD_U_INT32(dptr, count); for(i =0; i< count; i++) { @@ -1224,7 +1224,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_HEADER_32_TOKEN); + ADD_U_CHAR(dptr, AUT_HEADER32); ADD_U_INT32(dptr, rec_size); ADD_U_CHAR(dptr, HEADER_VERSION); ADD_U_INT16(dptr, e_type); @@ -1267,7 +1267,7 @@ return NULL; } - ADD_U_CHAR(dptr, AU_TRAILER_TOKEN); + ADD_U_CHAR(dptr, AUT_TRAILER); ADD_U_INT16(dptr, magic); ADD_U_INT32(dptr, rec_size); From owner-p4-projects@FreeBSD.ORG Tue May 3 11:32:47 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0F94616A4D0; Tue, 3 May 2005 11:32:47 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AB0FB16A4CF for ; Tue, 3 May 2005 11:32:46 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 890F243D7B for ; Tue, 3 May 2005 11:32:46 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43BWdA6034503 for ; Tue, 3 May 2005 11:32:39 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43BWdch034500 for perforce@freebsd.org; Tue, 3 May 2005 11:32:39 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 3 May 2005 11:32:39 GMT Message-Id: <200505031132.j43BWdch034500@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76422 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 11:32:47 -0000 http://perforce.freebsd.org/chv.cgi?CH=76422 Change 76422 by rwatson@rwatson_paprika on 2005/05/03 11:32:22 Update change log. Affected files ... .. //depot/projects/trustedbsd/openbsm/CHANGELOG#2 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/CHANGELOG#2 (text+ko) ==== @@ -39,3 +39,5 @@ are present in records, but need to be supported. - Implement HEADER64, ATTR64, SUBJECT64 token types, which make it possible to run praudit(1) on basic Solaris BSM streams. +- Switched to Solaris spelling of token names; Darwin spellings are now + deprecated and will be removed in a future version of OpenBSM. From owner-p4-projects@FreeBSD.ORG Tue May 3 15:19:37 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E71C916A4D0; Tue, 3 May 2005 15:19:36 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A6BE216A4CE for ; Tue, 3 May 2005 15:19:36 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 77E3E43D54 for ; Tue, 3 May 2005 15:19:36 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43FJTfl049879 for ; Tue, 3 May 2005 15:19:29 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43FJTLe049876 for perforce@freebsd.org; Tue, 3 May 2005 15:19:29 GMT (envelope-from csjp@freebsd.org) Date: Tue, 3 May 2005 15:19:29 GMT Message-Id: <200505031519.j43FJTLe049876@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to csjp@freebsd.org using -f From: "Christian S.J. Peron" To: Perforce Change Reviews Subject: PERFORCE change 76430 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 15:19:37 -0000 http://perforce.freebsd.org/chv.cgi?CH=76430 Change 76430 by csjp@csjp_xor on 2005/05/03 15:18:47 basic foot work for a "trusted execution" mechanism. This MAC policy will grant/deny access to the execution, linking of executables or shared objects based on their contents. This policy uses checksum algorithms like SHA1 or MD5 to verify the integrity of these objects. Affected files ... .. //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#1 add .. //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.h#1 add Differences ... From owner-p4-projects@FreeBSD.ORG Tue May 3 15:22:40 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8E0AA16A4D1; Tue, 3 May 2005 15:22:39 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3929216A4CE for ; Tue, 3 May 2005 15:22:39 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0C29743D4C for ; Tue, 3 May 2005 15:22:39 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43FMYF0050075 for ; Tue, 3 May 2005 15:22:34 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43FMXk3050072 for perforce@freebsd.org; Tue, 3 May 2005 15:22:33 GMT (envelope-from csjp@freebsd.org) Date: Tue, 3 May 2005 15:22:33 GMT Message-Id: <200505031522.j43FMXk3050072@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to csjp@freebsd.org using -f From: "Christian S.J. Peron" To: Perforce Change Reviews Subject: PERFORCE change 76431 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 15:22:40 -0000 http://perforce.freebsd.org/chv.cgi?CH=76431 Change 76431 by csjp@csjp_xor on 2005/05/03 15:22:25 Bring in a Makefile to build the mac_chkexec MAC policy Affected files ... .. //depot/projects/trustedbsd/mac/sys/modules/mac_chkexec/Makefile#1 add Differences ... From owner-p4-projects@FreeBSD.ORG Tue May 3 15:26:46 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0448B16A4D0; Tue, 3 May 2005 15:26:46 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BC68A16A4CE for ; Tue, 3 May 2005 15:26:45 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8DD9743D60 for ; Tue, 3 May 2005 15:26:45 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43FQd2Z050237 for ; Tue, 3 May 2005 15:26:39 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43FQdSb050234 for perforce@freebsd.org; Tue, 3 May 2005 15:26:39 GMT (envelope-from csjp@freebsd.org) Date: Tue, 3 May 2005 15:26:39 GMT Message-Id: <200505031526.j43FQdSb050234@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to csjp@freebsd.org using -f From: "Christian S.J. Peron" To: Perforce Change Reviews Subject: PERFORCE change 76432 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 15:26:46 -0000 http://perforce.freebsd.org/chv.cgi?CH=76432 Change 76432 by csjp@csjp_xor on 2005/05/03 15:26:33 Bring in userspace helper utilities to view/trigger the calculation and storage of checksums for objects. We will use one binary and just symlink setfhash to getfhash. setfhash can also be used to set object dependencies. Affected files ... .. //depot/projects/trustedbsd/mac/usr.sbin/getfhash/Makefile#1 add .. //depot/projects/trustedbsd/mac/usr.sbin/getfhash/getfhash.c#1 add Differences ... From owner-p4-projects@FreeBSD.ORG Tue May 3 15:49:15 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 313B016A4CF; Tue, 3 May 2005 15:49:15 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E312316A4CE for ; Tue, 3 May 2005 15:49:14 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9FF6343D66 for ; Tue, 3 May 2005 15:49:14 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43Fn9wY051169 for ; Tue, 3 May 2005 15:49:09 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43Fn9Os051166 for perforce@freebsd.org; Tue, 3 May 2005 15:49:09 GMT (envelope-from csjp@freebsd.org) Date: Tue, 3 May 2005 15:49:09 GMT Message-Id: <200505031549.j43Fn9Os051166@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to csjp@freebsd.org using -f From: "Christian S.J. Peron" To: Perforce Change Reviews Subject: PERFORCE change 76434 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 15:49:16 -0000 http://perforce.freebsd.org/chv.cgi?CH=76434 Change 76434 by csjp@csjp_xor on 2005/05/03 15:48:40 zero out checksum structure before writing it out to the extended attr. Affected files ... .. //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#2 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#2 (text+ko) ==== @@ -609,6 +609,7 @@ error = ha->crypto_hash(vp, cred, digest); if (error) return (error); + bzero(&vcsum, sizeof(vcsum)); memcpy(vcsum.vs_sum, digest, ha->hashsize); vcsum.vs_flags = ha->hashmask; error = mac_chkexec_set_vcsum(vp, &vcsum); @@ -630,6 +631,7 @@ match = (memcmp(digest, vcsum.vs_sum, ha->hashsize) == 0); if (!match && !mac_chkexec_enforce) { + bzero(&vcsum, sizeof(vcsum)); memcpy(vcsum.vs_sum, digest, ha->hashsize); vcsum.vs_flags = ha->hashmask; error = mac_chkexec_set_vcsum(vp, &vcsum); @@ -843,6 +845,7 @@ vput(nd.ni_vp); return (error); } + bzero(&vcsum, sizeof(vcsum)); memcpy(vcsum.vs_sum, digest, ha->hashsize); vcsum.vs_flags = ha->hashmask; error = mac_chkexec_set_vcsum(nd.ni_vp, &vcsum); From owner-p4-projects@FreeBSD.ORG Tue May 3 15:56:23 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2BC4F16A4D0; Tue, 3 May 2005 15:56:22 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8FB4C16A4CE for ; Tue, 3 May 2005 15:56:21 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 619C243D8D for ; Tue, 3 May 2005 15:56:21 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43FuJfY051535 for ; Tue, 3 May 2005 15:56:19 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43FuItA051532 for perforce@freebsd.org; Tue, 3 May 2005 15:56:18 GMT (envelope-from csjp@freebsd.org) Date: Tue, 3 May 2005 15:56:18 GMT Message-Id: <200505031556.j43FuItA051532@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to csjp@freebsd.org using -f From: "Christian S.J. Peron" To: Perforce Change Reviews Subject: PERFORCE change 76435 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 15:56:24 -0000 http://perforce.freebsd.org/chv.cgi?CH=76435 Change 76435 by csjp@csjp_xor on 2005/05/03 15:55:17 Add a comment to the code so we dont forget to break circular dependencies Affected files ... .. //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#3 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#3 (text+ko) ==== @@ -499,6 +499,7 @@ return (0); } +/* XXX we need to break circular dependencies here!! */ static int mac_chkexec_check_depends(struct vnode *vp, struct ucred *cred) { From owner-p4-projects@FreeBSD.ORG Tue May 3 16:20:52 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7452516A4D0; Tue, 3 May 2005 16:20:52 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 24D6916A4CF for ; Tue, 3 May 2005 16:20:52 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id DFEB343D66 for ; Tue, 3 May 2005 16:20:51 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43GKnqc052675 for ; Tue, 3 May 2005 16:20:49 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43GKmYK052672 for perforce@freebsd.org; Tue, 3 May 2005 16:20:48 GMT (envelope-from sam@freebsd.org) Date: Tue, 3 May 2005 16:20:48 GMT Message-Id: <200505031620.j43GKmYK052672@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76436 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 16:20:53 -0000 http://perforce.freebsd.org/chv.cgi?CH=76436 Change 76436 by sam@sam_ebb on 2005/05/03 16:20:33 use a private taskqueue Affected files ... .. //depot/projects/wifi/sys/dev/ath/if_ath.c#84 edit .. //depot/projects/wifi/sys/dev/ath/if_athvar.h#34 edit Differences ... ==== //depot/projects/wifi/sys/dev/ath/if_ath.c#84 (text+ko) ==== @@ -60,6 +60,8 @@ #include #include #include +#include +#include #include @@ -367,6 +369,10 @@ ATH_TXBUF_LOCK_INIT(sc); + sc->sc_tq = taskqueue_create("ath_taskq", M_NOWAIT, + taskqueue_thread_enqueue, &sc->sc_tq, &sc->sc_tqproc); + kthread_create(taskqueue_thread_loop, &sc->sc_tq, &sc->sc_tqproc, + 0, 0, "%s taskq", ifp->if_xname); TASK_INIT(&sc->sc_rxtask, 0, ath_rx_proc, sc); TASK_INIT(&sc->sc_rxorntask, 0, ath_rxorn_proc, sc); TASK_INIT(&sc->sc_fataltask, 0, ath_fatal_proc, sc); @@ -624,6 +630,7 @@ * Other than that, it's straightforward... */ ieee80211_ifdetach(&sc->sc_ic); + taskqueue_free(sc->sc_tq); ath_rate_detach(sc->sc_rc); ath_desc_free(sc); ath_tx_cleanup(sc); @@ -715,11 +722,11 @@ */ sc->sc_stats.ast_hardware++; ath_hal_intrset(ah, 0); /* disable intr's until reset */ - taskqueue_enqueue(taskqueue_swi, &sc->sc_fataltask); + taskqueue_enqueue(sc->sc_tq, &sc->sc_fataltask); } else if (status & HAL_INT_RXORN) { sc->sc_stats.ast_rxorn++; ath_hal_intrset(ah, 0); /* disable intr's until reset */ - taskqueue_enqueue(taskqueue_swi, &sc->sc_rxorntask); + taskqueue_enqueue(sc->sc_tq, &sc->sc_rxorntask); } else { if (status & HAL_INT_SWBA) { /* @@ -745,12 +752,12 @@ ath_hal_updatetxtriglevel(ah, AH_TRUE); } if (status & HAL_INT_RX) - taskqueue_enqueue(taskqueue_swi, &sc->sc_rxtask); + taskqueue_enqueue(sc->sc_tq, &sc->sc_rxtask); if (status & HAL_INT_TX) - taskqueue_enqueue(taskqueue_swi, &sc->sc_txtask); + taskqueue_enqueue(sc->sc_tq, &sc->sc_txtask); if (status & HAL_INT_BMISS) { sc->sc_stats.ast_bmiss++; - taskqueue_enqueue(taskqueue_swi, &sc->sc_bmisstask); + taskqueue_enqueue(sc->sc_tq, &sc->sc_bmisstask); } if (status & HAL_INT_MIB) { sc->sc_stats.ast_mib++; @@ -2225,7 +2232,7 @@ "%s: missed %u consecutive beacons\n", __func__, sc->sc_bmisscount); if (sc->sc_bmisscount > 3) /* NB: 3 is a guess */ - taskqueue_enqueue(taskqueue_swi, &sc->sc_bstucktask); + taskqueue_enqueue(sc->sc_tq, &sc->sc_bstucktask); return; } if (sc->sc_bmisscount != 0) { ==== //depot/projects/wifi/sys/dev/ath/if_athvar.h#34 (text+ko) ==== @@ -42,8 +42,6 @@ #ifndef _DEV_ATH_ATHVAR_H #define _DEV_ATH_ATHVAR_H -#include - #include #include #include @@ -61,6 +59,8 @@ #define ATH_FF_TXQMAX 50 /* maximum # of queued frames allowed */ #define ATH_FF_STAGEMAX 5 /* max waiting period for staged frame*/ +struct taskqueue; +struct kthread; struct ath_buf; /* driver-specific node state */ @@ -193,6 +193,8 @@ bus_space_handle_t sc_sh; /* bus space handle */ bus_dma_tag_t sc_dmat; /* bus DMA tag */ struct mtx sc_mtx; /* master lock (recursive) */ + struct taskqueue *sc_tq; /* private task queue */ + struct proc *sc_tqproc; /* thread handling sc_tq */ struct ath_hal *sc_ah; /* Atheros HAL */ struct ath_ratectrl *sc_rc; /* tx rate control support */ void (*sc_setdefantenna)(struct ath_softc *, u_int); From owner-p4-projects@FreeBSD.ORG Tue May 3 16:25:15 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0D1BC16A4F4; Tue, 3 May 2005 16:25:15 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CF4FB16A4D0 for ; Tue, 3 May 2005 16:25:14 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9B0EB43D4C for ; Tue, 3 May 2005 16:25:13 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43GP8i8052826 for ; Tue, 3 May 2005 16:25:08 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43GOsE6052760 for perforce@freebsd.org; Tue, 3 May 2005 16:24:54 GMT (envelope-from sam@freebsd.org) Date: Tue, 3 May 2005 16:24:54 GMT Message-Id: <200505031624.j43GOsE6052760@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76437 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 16:25:15 -0000 http://perforce.freebsd.org/chv.cgi?CH=76437 Change 76437 by sam@sam_ebb on 2005/05/03 16:24:43 IFC @ 76395 Affected files ... .. //depot/projects/vap/sys/Makefile#2 integrate .. //depot/projects/vap/sys/alpha/alpha/autoconf.c#2 integrate .. //depot/projects/vap/sys/alpha/alpha/busdma_machdep.c#2 integrate .. //depot/projects/vap/sys/alpha/alpha/critical.c#2 delete .. //depot/projects/vap/sys/alpha/alpha/dec_kn20aa.c#2 integrate .. //depot/projects/vap/sys/alpha/alpha/interrupt.c#2 integrate .. //depot/projects/vap/sys/alpha/alpha/machdep.c#2 integrate .. //depot/projects/vap/sys/alpha/alpha/mp_machdep.c#2 integrate .. //depot/projects/vap/sys/alpha/alpha/timerreg.h#2 integrate .. //depot/projects/vap/sys/alpha/alpha/trap.c#2 integrate .. //depot/projects/vap/sys/alpha/alpha/vm_machdep.c#2 integrate .. //depot/projects/vap/sys/alpha/conf/GENERIC#2 integrate .. //depot/projects/vap/sys/alpha/include/_bus.h#1 branch .. //depot/projects/vap/sys/alpha/include/_types.h#2 integrate .. //depot/projects/vap/sys/alpha/include/atomic.h#2 integrate .. //depot/projects/vap/sys/alpha/include/bus.h#2 integrate .. //depot/projects/vap/sys/alpha/include/bus_dma.h#1 branch .. //depot/projects/vap/sys/alpha/include/cpuconf.h#2 integrate .. //depot/projects/vap/sys/alpha/include/cpufunc.h#2 integrate .. //depot/projects/vap/sys/alpha/include/critical.h#2 delete .. //depot/projects/vap/sys/alpha/include/endian.h#2 integrate .. //depot/projects/vap/sys/alpha/include/exec.h#2 integrate .. //depot/projects/vap/sys/alpha/include/in_cksum.h#2 integrate .. //depot/projects/vap/sys/alpha/include/ioctl_bt848.h#2 integrate .. //depot/projects/vap/sys/alpha/include/ioctl_meteor.h#2 integrate .. //depot/projects/vap/sys/alpha/include/limits.h#2 integrate .. //depot/projects/vap/sys/alpha/include/pmc_mdep.h#1 branch .. //depot/projects/vap/sys/alpha/include/proc.h#2 integrate .. //depot/projects/vap/sys/alpha/include/stdarg.h#2 integrate .. //depot/projects/vap/sys/alpha/include/varargs.h#2 integrate .. //depot/projects/vap/sys/alpha/isa/isa_dma.c#2 integrate .. //depot/projects/vap/sys/alpha/linux/linux_machdep.c#2 integrate .. //depot/projects/vap/sys/alpha/linux/linux_proto.h#2 integrate .. //depot/projects/vap/sys/alpha/linux/linux_syscall.h#2 integrate .. //depot/projects/vap/sys/alpha/linux/linux_sysent.c#2 integrate .. //depot/projects/vap/sys/alpha/linux/linux_sysvec.c#2 integrate .. //depot/projects/vap/sys/alpha/linux/syscalls.master#2 integrate .. //depot/projects/vap/sys/alpha/osf1/imgact_osf1.c#2 integrate .. //depot/projects/vap/sys/alpha/osf1/osf1_misc.c#2 integrate .. //depot/projects/vap/sys/alpha/osf1/osf1_mount.c#2 integrate .. //depot/projects/vap/sys/alpha/osf1/osf1_signal.c#2 integrate .. //depot/projects/vap/sys/alpha/osf1/osf1_sysvec.c#2 integrate .. //depot/projects/vap/sys/alpha/osf1/osf1_util.h#2 integrate .. //depot/projects/vap/sys/alpha/pci/lca.c#2 integrate .. //depot/projects/vap/sys/alpha/pci/lcareg.h#2 integrate .. //depot/projects/vap/sys/amd64/acpica/madt.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/apic_vector.S#2 integrate .. //depot/projects/vap/sys/amd64/amd64/busdma_machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/critical.c#2 delete .. //depot/projects/vap/sys/amd64/amd64/db_disasm.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/db_trace.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/exception.S#2 integrate .. //depot/projects/vap/sys/amd64/amd64/fpu.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/identcpu.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/intr_machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/io_apic.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/legacy.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/local_apic.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/mp_machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/mp_watchdog.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/mptable.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/nexus.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/pmap.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/prof_machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/support.S#2 integrate .. //depot/projects/vap/sys/amd64/amd64/sys_machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/trap.c#2 integrate .. //depot/projects/vap/sys/amd64/amd64/vm_machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/conf/GENERIC#2 integrate .. //depot/projects/vap/sys/amd64/conf/NOTES#2 integrate .. //depot/projects/vap/sys/amd64/ia32/ia32_syscall.c#2 integrate .. //depot/projects/vap/sys/amd64/include/_bus.h#1 branch .. //depot/projects/vap/sys/amd64/include/_types.h#2 integrate .. //depot/projects/vap/sys/amd64/include/apicreg.h#2 integrate .. //depot/projects/vap/sys/amd64/include/apicvar.h#2 integrate .. //depot/projects/vap/sys/amd64/include/asm.h#2 integrate .. //depot/projects/vap/sys/amd64/include/atomic.h#2 integrate .. //depot/projects/vap/sys/amd64/include/bus.h#2 integrate .. //depot/projects/vap/sys/amd64/include/bus_amd64.h#2 delete .. //depot/projects/vap/sys/amd64/include/bus_dma.h#2 integrate .. //depot/projects/vap/sys/amd64/include/cpufunc.h#2 integrate .. //depot/projects/vap/sys/amd64/include/critical.h#2 delete .. //depot/projects/vap/sys/amd64/include/endian.h#2 integrate .. //depot/projects/vap/sys/amd64/include/exec.h#2 integrate .. //depot/projects/vap/sys/amd64/include/floatingpoint.h#2 integrate .. //depot/projects/vap/sys/amd64/include/ieeefp.h#2 integrate .. //depot/projects/vap/sys/amd64/include/in_cksum.h#2 integrate .. //depot/projects/vap/sys/amd64/include/intr_machdep.h#2 integrate .. //depot/projects/vap/sys/amd64/include/legacyvar.h#2 integrate .. //depot/projects/vap/sys/amd64/include/limits.h#2 integrate .. //depot/projects/vap/sys/amd64/include/param.h#2 integrate .. //depot/projects/vap/sys/amd64/include/pcpu.h#2 integrate .. //depot/projects/vap/sys/amd64/include/pmc_mdep.h#1 branch .. //depot/projects/vap/sys/amd64/include/proc.h#2 integrate .. //depot/projects/vap/sys/amd64/include/profile.h#2 integrate .. //depot/projects/vap/sys/amd64/include/sf_buf.h#2 integrate .. //depot/projects/vap/sys/amd64/include/smp.h#2 integrate .. //depot/projects/vap/sys/amd64/include/stdarg.h#2 integrate .. //depot/projects/vap/sys/amd64/include/sysarch.h#2 integrate .. //depot/projects/vap/sys/amd64/include/tss.h#2 integrate .. //depot/projects/vap/sys/amd64/include/varargs.h#2 integrate .. //depot/projects/vap/sys/amd64/isa/atpic.c#2 integrate .. //depot/projects/vap/sys/amd64/isa/clock.c#2 integrate .. //depot/projects/vap/sys/amd64/isa/elcr.c#2 integrate .. //depot/projects/vap/sys/amd64/isa/isa.c#2 integrate .. //depot/projects/vap/sys/amd64/isa/isa_dma.c#2 integrate .. //depot/projects/vap/sys/amd64/isa/timerreg.h#2 integrate .. //depot/projects/vap/sys/amd64/linux32/linux32_machdep.c#2 integrate .. //depot/projects/vap/sys/amd64/linux32/linux32_proto.h#2 integrate .. //depot/projects/vap/sys/amd64/linux32/linux32_syscall.h#2 integrate .. //depot/projects/vap/sys/amd64/linux32/linux32_sysent.c#2 integrate .. //depot/projects/vap/sys/amd64/linux32/linux32_sysvec.c#2 integrate .. //depot/projects/vap/sys/amd64/linux32/syscalls.master#2 integrate .. //depot/projects/vap/sys/amd64/pci/pci_cfgreg.c#2 integrate .. //depot/projects/vap/sys/arm/arm/busdma_machdep.c#2 integrate .. //depot/projects/vap/sys/arm/arm/cpufunc.c#2 integrate .. //depot/projects/vap/sys/arm/arm/cpufunc_asm.S#2 integrate .. //depot/projects/vap/sys/arm/arm/critical.c#2 delete .. //depot/projects/vap/sys/arm/arm/fiq.c#2 integrate .. //depot/projects/vap/sys/arm/arm/fusu.S#2 integrate .. //depot/projects/vap/sys/arm/arm/genassym.c#2 integrate .. //depot/projects/vap/sys/arm/arm/in_cksum.c#2 integrate .. //depot/projects/vap/sys/arm/arm/locore.S#2 integrate .. //depot/projects/vap/sys/arm/arm/machdep.c#2 integrate .. //depot/projects/vap/sys/arm/arm/pmap.c#2 integrate .. //depot/projects/vap/sys/arm/arm/support.S#2 integrate .. //depot/projects/vap/sys/arm/arm/swtch.S#2 integrate .. //depot/projects/vap/sys/arm/arm/sys_machdep.c#2 integrate .. //depot/projects/vap/sys/arm/arm/trap.c#2 integrate .. //depot/projects/vap/sys/arm/arm/undefined.c#2 integrate .. //depot/projects/vap/sys/arm/arm/vm_machdep.c#2 integrate .. //depot/projects/vap/sys/arm/include/_bus.h#1 branch .. //depot/projects/vap/sys/arm/include/_types.h#2 integrate .. //depot/projects/vap/sys/arm/include/asmacros.h#2 integrate .. //depot/projects/vap/sys/arm/include/atomic.h#2 integrate .. //depot/projects/vap/sys/arm/include/bus.h#2 integrate .. //depot/projects/vap/sys/arm/include/bus_dma.h#1 branch .. //depot/projects/vap/sys/arm/include/cpu.h#2 integrate .. //depot/projects/vap/sys/arm/include/critical.h#2 delete .. //depot/projects/vap/sys/arm/include/exec.h#2 integrate .. //depot/projects/vap/sys/arm/include/float.h#2 integrate .. //depot/projects/vap/sys/arm/include/intr.h#2 integrate .. //depot/projects/vap/sys/arm/include/limits.h#2 integrate .. //depot/projects/vap/sys/arm/include/machdep.h#2 integrate .. //depot/projects/vap/sys/arm/include/pmap.h#2 integrate .. //depot/projects/vap/sys/arm/include/pmc_mdep.h#1 branch .. //depot/projects/vap/sys/arm/include/proc.h#2 integrate .. //depot/projects/vap/sys/arm/include/stdarg.h#2 integrate .. //depot/projects/vap/sys/arm/include/sysarch.h#2 integrate .. //depot/projects/vap/sys/arm/sa11x0/sa11x0_io.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/i80321.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/i80321_space.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/i80321_timer.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/iq31244_machdep.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/iq80321.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/obio_space.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/std.i80321#2 integrate .. //depot/projects/vap/sys/arm/xscale/i80321/uart_cpu_i80321.c#2 integrate .. //depot/projects/vap/sys/arm/xscale/std.xscale#1 branch .. //depot/projects/vap/sys/boot/arc/include/arcfuncs.h#2 integrate .. //depot/projects/vap/sys/boot/common/loader.8#2 integrate .. //depot/projects/vap/sys/boot/common/ufsread.c#2 integrate .. //depot/projects/vap/sys/boot/efi/include/i386/efibind.h#2 integrate .. //depot/projects/vap/sys/boot/efi/include/ia64/efibind.h#2 integrate .. //depot/projects/vap/sys/boot/forth/loader.4th.8#2 integrate .. //depot/projects/vap/sys/boot/forth/loader.conf#2 integrate .. //depot/projects/vap/sys/boot/i386/Makefile.inc#2 integrate .. //depot/projects/vap/sys/boot/i386/boot0/Makefile#2 integrate .. //depot/projects/vap/sys/boot/i386/boot0/boot0.S#2 integrate .. //depot/projects/vap/sys/boot/i386/boot2/Makefile#2 integrate .. //depot/projects/vap/sys/boot/i386/libi386/biosacpi.c#2 integrate .. //depot/projects/vap/sys/boot/i386/libi386/pxe.c#2 integrate .. //depot/projects/vap/sys/boot/i386/libi386/vidconsole.c#2 integrate .. //depot/projects/vap/sys/boot/ofw/libofw/ofw_net.c#2 integrate .. //depot/projects/vap/sys/boot/pc98/boot2/Makefile#2 integrate .. //depot/projects/vap/sys/boot/pc98/libpc98/vidconsole.c#2 integrate .. //depot/projects/vap/sys/bsm/audit_kevents.h#1 branch .. //depot/projects/vap/sys/cam/cam_periph.c#2 integrate .. //depot/projects/vap/sys/cam/cam_xpt.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_all.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_cd.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_ch.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_da.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_low.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_pass.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_sa.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_ses.c#2 integrate .. //depot/projects/vap/sys/cam/scsi/scsi_target.c#2 integrate .. //depot/projects/vap/sys/coda/cnode.h#2 integrate .. //depot/projects/vap/sys/coda/coda_fbsd.c#2 integrate .. //depot/projects/vap/sys/coda/coda_psdev.c#2 integrate .. //depot/projects/vap/sys/coda/coda_subr.c#2 integrate .. //depot/projects/vap/sys/coda/coda_venus.c#2 integrate .. //depot/projects/vap/sys/coda/coda_vfsops.c#2 integrate .. //depot/projects/vap/sys/coda/coda_vfsops.h#2 integrate .. //depot/projects/vap/sys/coda/coda_vnops.c#2 integrate .. //depot/projects/vap/sys/coda/coda_vnops.h#2 integrate .. //depot/projects/vap/sys/compat/freebsd32/freebsd32_misc.c#2 integrate .. //depot/projects/vap/sys/compat/freebsd32/freebsd32_proto.h#2 integrate .. //depot/projects/vap/sys/compat/freebsd32/freebsd32_syscall.h#2 integrate .. //depot/projects/vap/sys/compat/freebsd32/freebsd32_syscalls.c#2 integrate .. //depot/projects/vap/sys/compat/freebsd32/freebsd32_sysent.c#2 integrate .. //depot/projects/vap/sys/compat/freebsd32/syscalls.master#2 integrate .. //depot/projects/vap/sys/compat/ia32/ia32_signal.h#2 integrate .. //depot/projects/vap/sys/compat/ia32/ia32_sysvec.c#2 integrate .. //depot/projects/vap/sys/compat/linprocfs/linprocfs.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_file.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_getcwd.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_ioctl.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_ipc.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_misc.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_signal.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_socket.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_stats.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_sysproto.h#1 branch .. //depot/projects/vap/sys/compat/linux/linux_util.c#2 integrate .. //depot/projects/vap/sys/compat/linux/linux_util.h#2 integrate .. //depot/projects/vap/sys/compat/ndis/hal_var.h#2 integrate .. //depot/projects/vap/sys/compat/ndis/kern_ndis.c#2 integrate .. //depot/projects/vap/sys/compat/ndis/kern_windrv.c#1 branch .. //depot/projects/vap/sys/compat/ndis/ndis_var.h#2 integrate .. //depot/projects/vap/sys/compat/ndis/ntoskrnl_var.h#2 integrate .. //depot/projects/vap/sys/compat/ndis/pe_var.h#2 integrate .. //depot/projects/vap/sys/compat/ndis/resource_var.h#2 integrate .. //depot/projects/vap/sys/compat/ndis/subr_hal.c#2 integrate .. //depot/projects/vap/sys/compat/ndis/subr_ndis.c#2 integrate .. //depot/projects/vap/sys/compat/ndis/subr_ntoskrnl.c#2 integrate .. //depot/projects/vap/sys/compat/ndis/subr_pe.c#2 integrate .. //depot/projects/vap/sys/compat/ndis/subr_usbd.c#1 branch .. //depot/projects/vap/sys/compat/ndis/usbd_var.h#1 branch .. //depot/projects/vap/sys/compat/ndis/winx32_wrap.S#1 branch .. //depot/projects/vap/sys/compat/ndis/winx64_wrap.S#1 branch .. //depot/projects/vap/sys/compat/pecoff/imgact_pecoff.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/imgact_svr4.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_fcntl.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_ipc.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_misc.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_signal.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_signal.h#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_stat.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_stream.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_sysvec.c#2 integrate .. //depot/projects/vap/sys/compat/svr4/svr4_util.h#2 integrate .. //depot/projects/vap/sys/conf/Makefile.alpha#2 integrate .. //depot/projects/vap/sys/conf/Makefile.amd64#2 integrate .. //depot/projects/vap/sys/conf/Makefile.arm#2 integrate .. //depot/projects/vap/sys/conf/Makefile.i386#2 integrate .. //depot/projects/vap/sys/conf/Makefile.ia64#2 integrate .. //depot/projects/vap/sys/conf/Makefile.pc98#2 integrate .. //depot/projects/vap/sys/conf/Makefile.powerpc#2 integrate .. //depot/projects/vap/sys/conf/Makefile.sparc64#2 integrate .. //depot/projects/vap/sys/conf/NOTES#2 integrate .. //depot/projects/vap/sys/conf/files#2 integrate .. //depot/projects/vap/sys/conf/files.alpha#2 integrate .. //depot/projects/vap/sys/conf/files.amd64#2 integrate .. //depot/projects/vap/sys/conf/files.arm#2 integrate .. //depot/projects/vap/sys/conf/files.i386#2 integrate .. //depot/projects/vap/sys/conf/files.ia64#2 integrate .. //depot/projects/vap/sys/conf/files.pc98#2 integrate .. //depot/projects/vap/sys/conf/files.powerpc#2 integrate .. //depot/projects/vap/sys/conf/files.sparc64#2 integrate .. //depot/projects/vap/sys/conf/kern.mk#2 integrate .. //depot/projects/vap/sys/conf/kern.post.mk#2 integrate .. //depot/projects/vap/sys/conf/kern.pre.mk#2 integrate .. //depot/projects/vap/sys/conf/kmod.mk#2 integrate .. //depot/projects/vap/sys/conf/majors#2 delete .. //depot/projects/vap/sys/conf/majors.awk#2 delete .. //depot/projects/vap/sys/conf/options#2 integrate .. //depot/projects/vap/sys/conf/options.amd64#2 integrate .. //depot/projects/vap/sys/conf/options.arm#2 integrate .. //depot/projects/vap/sys/conf/options.i386#2 integrate .. //depot/projects/vap/sys/conf/options.pc98#2 integrate .. //depot/projects/vap/sys/contrib/altq/altq/altq_subr.c#2 integrate .. //depot/projects/vap/sys/contrib/altq/altq/altq_var.h#2 integrate .. //depot/projects/vap/sys/contrib/dev/ath/freebsd/ah_osdep.c#2 integrate .. //depot/projects/vap/sys/contrib/dev/hptmv/access601.h#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/array.h#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/atapi.h#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/command.h#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/gui_lib.c#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/hptproc.c#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/i386-elf.raid.o.uu#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/ioctl.c#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/mvSata.h#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/mvStorageDev.h#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/raid5n.h#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/readme.txt#2 delete .. //depot/projects/vap/sys/contrib/dev/hptmv/vdevice.h#2 delete .. //depot/projects/vap/sys/contrib/dev/nve/adapter.h#1 branch .. //depot/projects/vap/sys/contrib/dev/nve/amd64/nvenetlib.o.bz2.uu#1 branch .. //depot/projects/vap/sys/contrib/dev/nve/basetype.h#1 branch .. //depot/projects/vap/sys/contrib/dev/nve/drvinfo.h#1 branch .. //depot/projects/vap/sys/contrib/dev/nve/i386/nvenetlib.o.bz2.uu#1 branch .. //depot/projects/vap/sys/contrib/dev/nve/os.h#1 branch .. //depot/projects/vap/sys/contrib/dev/nve/phy.h#1 branch .. //depot/projects/vap/sys/contrib/dev/oltr/if_oltr.c#2 integrate .. //depot/projects/vap/sys/contrib/dev/oltr/if_oltr_isa.c#1 branch .. //depot/projects/vap/sys/contrib/dev/oltr/if_oltr_pci.c#1 branch .. //depot/projects/vap/sys/contrib/dev/oltr/if_oltrvar.h#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/fil.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_auth.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_auth.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_compat.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_fil.c#2 delete .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_fil.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_fil_freebsd.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_frag.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_frag.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_ftp_pxy.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_htable.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_htable.h#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_ipsec_pxy.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_irc_pxy.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_log.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_lookup.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_lookup.h#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_nat.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_nat.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_netbios_pxy.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_pool.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_pool.h#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_pptp_pxy.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_proxy.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_proxy.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_raudio_pxy.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_rcmd_pxy.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_rpcb_pxy.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_rules.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_rules.h#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_scan.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_scan.h#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_state.c#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_state.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_sync.c#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ip_sync.h#1 branch .. //depot/projects/vap/sys/contrib/ipfilter/netinet/ipl.h#2 integrate .. //depot/projects/vap/sys/contrib/ipfilter/netinet/mlfk_ipl.c#2 integrate .. //depot/projects/vap/sys/contrib/pf/net/if_pflog.c#2 integrate .. //depot/projects/vap/sys/contrib/pf/net/if_pfsync.c#2 integrate .. //depot/projects/vap/sys/contrib/pf/net/pf.c#2 integrate .. //depot/projects/vap/sys/contrib/pf/net/pf_if.c#2 integrate .. //depot/projects/vap/sys/contrib/pf/net/pf_ioctl.c#2 integrate .. //depot/projects/vap/sys/crypto/cast128/cast128.c#2 delete .. //depot/projects/vap/sys/crypto/cast128/cast128.h#2 delete .. //depot/projects/vap/sys/crypto/cast128/cast128sb.h#2 delete .. //depot/projects/vap/sys/crypto/md5.c#2 delete .. //depot/projects/vap/sys/crypto/md5.h#2 delete .. //depot/projects/vap/sys/crypto/rijndael/rijndael-alg-fst.c#2 integrate .. //depot/projects/vap/sys/crypto/rijndael/rijndael-alg-fst.h#2 delete .. //depot/projects/vap/sys/crypto/rijndael/rijndael-api-fst.c#2 integrate .. //depot/projects/vap/sys/crypto/rijndael/rijndael-api-fst.h#2 integrate .. //depot/projects/vap/sys/crypto/rijndael/rijndael.h#2 integrate .. //depot/projects/vap/sys/ddb/db_print.c#2 integrate .. //depot/projects/vap/sys/ddb/db_run.c#2 integrate .. //depot/projects/vap/sys/ddb/ddb.h#2 integrate .. //depot/projects/vap/sys/dev/aac/aac.c#2 integrate .. //depot/projects/vap/sys/dev/aac/aac_cam.c#2 integrate .. //depot/projects/vap/sys/dev/aac/aac_disk.c#2 integrate .. //depot/projects/vap/sys/dev/aac/aac_pci.c#2 integrate .. //depot/projects/vap/sys/dev/aac/aacreg.h#2 integrate .. //depot/projects/vap/sys/dev/acpi_support/acpi_asus.c#2 integrate .. //depot/projects/vap/sys/dev/acpi_support/acpi_fujitsu.c#1 branch .. //depot/projects/vap/sys/dev/acpi_support/acpi_ibm.c#2 integrate .. //depot/projects/vap/sys/dev/acpi_support/acpi_sony.c#2 integrate .. //depot/projects/vap/sys/dev/acpi_support/acpi_toshiba.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/Osd/OsdSchedule.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_battery.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_button.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_cpu.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_ec.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_if.m#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_package.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_pcib.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_pcib_acpi.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_pcibvar.h#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_perf.c#1 branch .. //depot/projects/vap/sys/dev/acpica/acpi_quirks#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_resource.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_thermal.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_throttle.c#1 branch .. //depot/projects/vap/sys/dev/acpica/acpi_timer.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpi_video.c#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpiio.h#2 integrate .. //depot/projects/vap/sys/dev/acpica/acpivar.h#2 integrate .. //depot/projects/vap/sys/dev/adlink/adlink.c#2 integrate .. //depot/projects/vap/sys/dev/advansys/adv_pci.c#2 integrate .. //depot/projects/vap/sys/dev/advansys/adw_pci.c#2 integrate .. //depot/projects/vap/sys/dev/advansys/adwlib.c#2 integrate .. //depot/projects/vap/sys/dev/advansys/adwlib.h#2 integrate .. //depot/projects/vap/sys/dev/aha/aha_isa.c#2 integrate .. //depot/projects/vap/sys/dev/aha/aha_mca.c#2 integrate .. //depot/projects/vap/sys/dev/aha/ahareg.h#2 integrate .. //depot/projects/vap/sys/dev/aic/aic_cbus.c#2 integrate .. //depot/projects/vap/sys/dev/aic7xxx/ahc_pci.c#2 integrate .. //depot/projects/vap/sys/dev/aic7xxx/ahd_pci.c#2 integrate .. //depot/projects/vap/sys/dev/aic7xxx/aic79xx.c#2 integrate .. //depot/projects/vap/sys/dev/aic7xxx/aic79xx_osm.c#2 integrate .. //depot/projects/vap/sys/dev/aic7xxx/aic79xx_pci.c#2 integrate .. //depot/projects/vap/sys/dev/aic7xxx/aic7xxx.c#2 integrate .. //depot/projects/vap/sys/dev/amd/amd.c#2 integrate .. //depot/projects/vap/sys/dev/amr/amr.c#2 integrate .. //depot/projects/vap/sys/dev/amr/amr_cam.c#2 integrate .. //depot/projects/vap/sys/dev/amr/amr_pci.c#2 integrate .. //depot/projects/vap/sys/dev/amr/amrreg.h#2 integrate .. //depot/projects/vap/sys/dev/amr/amrvar.h#2 integrate .. //depot/projects/vap/sys/dev/ar/if_ar.c#2 integrate .. //depot/projects/vap/sys/dev/ar/if_ar_pci.c#2 integrate .. //depot/projects/vap/sys/dev/arcmsr/arcmsr.c#1 branch .. //depot/projects/vap/sys/dev/arcmsr/arcmsr.h#1 branch .. //depot/projects/vap/sys/dev/asr/asr.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-all.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-all.h#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-card.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-cbus.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-chipset.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-commands.h#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-disk.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-disk.h#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-dma.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-isa.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-lowlevel.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-pci.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-pci.h#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-queue.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-raid.c#2 integrate .. //depot/projects/vap/sys/dev/ata/ata-raid.h#2 integrate .. //depot/projects/vap/sys/dev/ata/ata_if.m#1 branch .. //depot/projects/vap/sys/dev/ata/atapi-cam.c#2 integrate .. //depot/projects/vap/sys/dev/ata/atapi-cd.c#2 integrate .. //depot/projects/vap/sys/dev/ata/atapi-cd.h#2 integrate .. //depot/projects/vap/sys/dev/ata/atapi-fd.c#2 integrate .. //depot/projects/vap/sys/dev/ata/atapi-fd.h#2 integrate .. //depot/projects/vap/sys/dev/ata/atapi-tape.c#2 integrate .. //depot/projects/vap/sys/dev/ata/atapi-tape.h#2 integrate .. //depot/projects/vap/sys/dev/bfe/if_bfe.c#2 integrate .. //depot/projects/vap/sys/dev/bge/if_bge.c#2 integrate .. //depot/projects/vap/sys/dev/bge/if_bgereg.h#2 integrate .. //depot/projects/vap/sys/dev/bktr/bktr_card.c#2 integrate .. //depot/projects/vap/sys/dev/bktr/bktr_mem.c#2 integrate .. //depot/projects/vap/sys/dev/bktr/bktr_os.c#2 integrate .. //depot/projects/vap/sys/dev/bktr/bktr_tuner.c#2 integrate .. //depot/projects/vap/sys/dev/bktr/bktr_tuner.h#2 integrate .. //depot/projects/vap/sys/dev/cardbus/cardbus.c#2 integrate .. //depot/projects/vap/sys/dev/cardbus/cardbus_cis.c#2 integrate .. //depot/projects/vap/sys/dev/cardbus/cardbus_cis.h#2 integrate .. //depot/projects/vap/sys/dev/cardbus/cardbusvar.h#2 integrate .. //depot/projects/vap/sys/dev/ciss/ciss.c#2 integrate .. //depot/projects/vap/sys/dev/ciss/cissreg.h#2 integrate .. //depot/projects/vap/sys/dev/ciss/cissvar.h#2 integrate .. //depot/projects/vap/sys/dev/cp/if_cp.c#2 integrate .. //depot/projects/vap/sys/dev/cpufreq/ichss.c#1 branch .. //depot/projects/vap/sys/dev/cs/if_cs.c#2 integrate .. //depot/projects/vap/sys/dev/cs/if_cs_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/cs/if_csvar.h#2 integrate .. //depot/projects/vap/sys/dev/ctau/if_ct.c#2 integrate .. //depot/projects/vap/sys/dev/cx/machdep.h#2 integrate .. //depot/projects/vap/sys/dev/cy/cy_pci.c#2 integrate .. //depot/projects/vap/sys/dev/digi/digi.c#2 integrate .. //depot/projects/vap/sys/dev/digi/digi_pci.c#2 integrate .. //depot/projects/vap/sys/dev/dpt/dpt_eisa.c#2 integrate .. //depot/projects/vap/sys/dev/dpt/dpt_pci.c#2 integrate .. //depot/projects/vap/sys/dev/drm/ati_pcigart.c#1 branch .. //depot/projects/vap/sys/dev/drm/ati_pcigart.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm.h#2 integrate .. //depot/projects/vap/sys/dev/drm/drmP.h#2 integrate .. //depot/projects/vap/sys/dev/drm/drm_agpsupport.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_agpsupport.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_atomic.h#1 branch .. //depot/projects/vap/sys/dev/drm/drm_auth.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_auth.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_bufs.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_bufs.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_context.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_context.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_dma.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_dma.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_drawable.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_drawable.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_drv.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_drv.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_fops.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_fops.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_ioctl.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_ioctl.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_irq.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_irq.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_linux_list.h#2 integrate .. //depot/projects/vap/sys/dev/drm/drm_lock.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_lock.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_memory.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_memory.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_memory_debug.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_os_freebsd.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_pci.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_pci.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_pciids.h#2 integrate .. //depot/projects/vap/sys/dev/drm/drm_sarea.h#2 integrate .. //depot/projects/vap/sys/dev/drm/drm_scatter.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_scatter.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_sysctl.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_sysctl.h#2 delete .. //depot/projects/vap/sys/dev/drm/drm_vm.c#1 branch .. //depot/projects/vap/sys/dev/drm/drm_vm.h#2 delete .. //depot/projects/vap/sys/dev/drm/i915_dma.c#1 branch .. //depot/projects/vap/sys/dev/drm/i915_drm.h#1 branch .. //depot/projects/vap/sys/dev/drm/i915_drv.c#1 branch .. //depot/projects/vap/sys/dev/drm/i915_drv.h#1 branch .. //depot/projects/vap/sys/dev/drm/i915_irq.c#1 branch .. //depot/projects/vap/sys/dev/drm/i915_mem.c#1 branch .. //depot/projects/vap/sys/dev/drm/mach64_dma.c#1 branch .. //depot/projects/vap/sys/dev/drm/mach64_drm.h#1 branch .. //depot/projects/vap/sys/dev/drm/mach64_drv.c#1 branch .. //depot/projects/vap/sys/dev/drm/mach64_drv.h#1 branch .. //depot/projects/vap/sys/dev/drm/mach64_irq.c#1 branch .. //depot/projects/vap/sys/dev/drm/mach64_state.c#1 branch .. //depot/projects/vap/sys/dev/drm/mga.h#2 delete .. //depot/projects/vap/sys/dev/drm/mga_dma.c#2 integrate .. //depot/projects/vap/sys/dev/drm/mga_drm.h#2 integrate .. //depot/projects/vap/sys/dev/drm/mga_drv.c#2 integrate .. //depot/projects/vap/sys/dev/drm/mga_drv.h#2 integrate .. //depot/projects/vap/sys/dev/drm/mga_irq.c#2 integrate .. //depot/projects/vap/sys/dev/drm/mga_state.c#2 integrate .. //depot/projects/vap/sys/dev/drm/mga_ucode.h#2 integrate .. //depot/projects/vap/sys/dev/drm/mga_warp.c#2 integrate .. //depot/projects/vap/sys/dev/drm/r128.h#2 delete .. //depot/projects/vap/sys/dev/drm/r128_cce.c#2 integrate .. //depot/projects/vap/sys/dev/drm/r128_drm.h#2 integrate .. //depot/projects/vap/sys/dev/drm/r128_drv.c#2 integrate .. //depot/projects/vap/sys/dev/drm/r128_drv.h#2 integrate .. //depot/projects/vap/sys/dev/drm/r128_irq.c#2 integrate .. //depot/projects/vap/sys/dev/drm/r128_state.c#2 integrate .. //depot/projects/vap/sys/dev/drm/radeon.h#2 delete .. //depot/projects/vap/sys/dev/drm/radeon_cp.c#2 integrate .. //depot/projects/vap/sys/dev/drm/radeon_drm.h#2 integrate .. //depot/projects/vap/sys/dev/drm/radeon_drv.c#2 integrate .. //depot/projects/vap/sys/dev/drm/radeon_drv.h#2 integrate .. //depot/projects/vap/sys/dev/drm/radeon_irq.c#2 integrate .. //depot/projects/vap/sys/dev/drm/radeon_mem.c#2 integrate .. //depot/projects/vap/sys/dev/drm/radeon_state.c#2 integrate .. //depot/projects/vap/sys/dev/drm/savage_bci.c#1 branch .. //depot/projects/vap/sys/dev/drm/savage_drm.h#1 branch .. //depot/projects/vap/sys/dev/drm/savage_drv.c#1 branch .. //depot/projects/vap/sys/dev/drm/savage_drv.h#1 branch .. //depot/projects/vap/sys/dev/drm/savage_state.c#1 branch .. //depot/projects/vap/sys/dev/drm/sis.h#2 delete .. //depot/projects/vap/sys/dev/drm/sis_drm.h#2 integrate .. //depot/projects/vap/sys/dev/drm/sis_drv.c#2 integrate .. //depot/projects/vap/sys/dev/drm/sis_drv.h#2 integrate .. //depot/projects/vap/sys/dev/drm/sis_ds.c#2 integrate .. //depot/projects/vap/sys/dev/drm/sis_ds.h#2 integrate .. //depot/projects/vap/sys/dev/drm/sis_mm.c#2 integrate .. //depot/projects/vap/sys/dev/drm/tdfx.h#2 delete .. //depot/projects/vap/sys/dev/drm/tdfx_drv.c#2 integrate .. //depot/projects/vap/sys/dev/drm/tdfx_drv.h#1 branch .. //depot/projects/vap/sys/dev/ed/if_ed.c#2 integrate .. //depot/projects/vap/sys/dev/ed/if_ed98.h#2 integrate .. //depot/projects/vap/sys/dev/ed/if_ed_3c503.c#1 branch .. //depot/projects/vap/sys/dev/ed/if_ed_cbus.c#2 integrate .. //depot/projects/vap/sys/dev/ed/if_ed_hpp.c#1 branch .. //depot/projects/vap/sys/dev/ed/if_ed_isa.c#2 integrate .. //depot/projects/vap/sys/dev/ed/if_ed_novell.c#1 branch .. //depot/projects/vap/sys/dev/ed/if_ed_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/ed/if_ed_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ed/if_ed_sic.c#1 branch .. //depot/projects/vap/sys/dev/ed/if_ed_wd80x3.c#1 branch .. //depot/projects/vap/sys/dev/ed/if_edreg.h#2 integrate .. //depot/projects/vap/sys/dev/ed/if_edvar.h#2 integrate .. //depot/projects/vap/sys/dev/eisa/eisaconf.c#2 integrate .. //depot/projects/vap/sys/dev/em/if_em.c#2 integrate .. //depot/projects/vap/sys/dev/en/if_en_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ep/if_ep.c#2 integrate .. //depot/projects/vap/sys/dev/ep/if_ep_eisa.c#2 integrate .. //depot/projects/vap/sys/dev/ep/if_ep_isa.c#2 integrate .. //depot/projects/vap/sys/dev/ep/if_ep_mca.c#2 integrate .. //depot/projects/vap/sys/dev/ep/if_ep_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/ep/if_epvar.h#2 integrate .. //depot/projects/vap/sys/dev/esp/esp_sbus.c#2 integrate .. //depot/projects/vap/sys/dev/esp/ncr53c9x.c#2 integrate .. //depot/projects/vap/sys/dev/esp/ncr53c9xreg.h#2 integrate .. //depot/projects/vap/sys/dev/esp/ncr53c9xvar.h#2 integrate .. //depot/projects/vap/sys/dev/ex/if_ex_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/fatm/if_fatm.c#2 integrate .. //depot/projects/vap/sys/dev/fb/s3_pci.c#2 integrate .. //depot/projects/vap/sys/dev/fb/vga.c#2 integrate .. //depot/projects/vap/sys/dev/fb/vgareg.h#2 integrate .. //depot/projects/vap/sys/dev/fdc/fdc.c#2 integrate .. //depot/projects/vap/sys/dev/fdc/fdc_isa.c#2 integrate .. //depot/projects/vap/sys/dev/fdc/fdc_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/fdc/fdcvar.h#2 integrate .. //depot/projects/vap/sys/dev/fe/if_fe.c#2 integrate .. //depot/projects/vap/sys/dev/fe/if_fe_cbus.c#2 integrate .. //depot/projects/vap/sys/dev/fe/if_fe_isa.c#2 integrate .. //depot/projects/vap/sys/dev/fe/if_fe_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/fe/if_fereg.h#2 integrate .. //depot/projects/vap/sys/dev/fe/if_fevar.h#2 integrate .. //depot/projects/vap/sys/dev/fe/mb86960.h#1 branch .. //depot/projects/vap/sys/dev/firewire/fwdev.c#2 integrate .. //depot/projects/vap/sys/dev/firewire/fwohci.c#2 integrate .. //depot/projects/vap/sys/dev/firewire/fwohci_pci.c#2 integrate .. //depot/projects/vap/sys/dev/fxp/if_fxp.c#2 integrate .. //depot/projects/vap/sys/dev/fxp/if_fxpreg.h#2 integrate .. //depot/projects/vap/sys/dev/fxp/if_fxpvar.h#2 integrate .. //depot/projects/vap/sys/dev/fxp/rcvbundl.h#2 integrate .. //depot/projects/vap/sys/dev/gem/if_gem_pci.c#2 integrate .. //depot/projects/vap/sys/dev/hatm/if_hatm.c#2 integrate .. //depot/projects/vap/sys/dev/hfa/hfa_pci.c#2 integrate .. //depot/projects/vap/sys/dev/hifn/hifn7751.c#2 integrate .. //depot/projects/vap/sys/dev/hifn/hifn7751reg.h#2 integrate .. //depot/projects/vap/sys/dev/hifn/hifn7751var.h#2 integrate .. //depot/projects/vap/sys/dev/hme/if_hme.c#2 integrate .. //depot/projects/vap/sys/dev/hme/if_hme_pci.c#2 integrate .. //depot/projects/vap/sys/dev/hme/if_hme_sbus.c#2 integrate .. //depot/projects/vap/sys/dev/hptmv/access601.h#1 branch .. //depot/projects/vap/sys/dev/hptmv/array.h#1 branch .. //depot/projects/vap/sys/dev/hptmv/atapi.h#1 branch .. //depot/projects/vap/sys/dev/hptmv/command.h#1 branch .. //depot/projects/vap/sys/dev/hptmv/entry.c#2 integrate .. //depot/projects/vap/sys/dev/hptmv/global.h#2 integrate .. //depot/projects/vap/sys/dev/hptmv/gui_lib.c#1 branch .. //depot/projects/vap/sys/dev/hptmv/hptproc.c#1 branch .. //depot/projects/vap/sys/dev/hptmv/i386-elf.raid.o.uu#1 branch .. //depot/projects/vap/sys/dev/hptmv/ioctl.c#1 branch .. //depot/projects/vap/sys/dev/hptmv/mvSata.h#1 branch .. //depot/projects/vap/sys/dev/hptmv/mvStorageDev.h#1 branch .. //depot/projects/vap/sys/dev/hptmv/raid5n.h#1 branch .. //depot/projects/vap/sys/dev/hptmv/readme.txt#1 branch .. //depot/projects/vap/sys/dev/hptmv/vdevice.h#1 branch .. //depot/projects/vap/sys/dev/hwpmc/hwpmc_amd.c#1 branch .. //depot/projects/vap/sys/dev/hwpmc/hwpmc_intel.c#1 branch .. //depot/projects/vap/sys/dev/hwpmc/hwpmc_mod.c#1 branch .. //depot/projects/vap/sys/dev/hwpmc/hwpmc_pentium.c#1 branch .. //depot/projects/vap/sys/dev/hwpmc/hwpmc_piv.c#1 branch .. //depot/projects/vap/sys/dev/hwpmc/hwpmc_ppro.c#1 branch .. //depot/projects/vap/sys/dev/ic/i8237.h#2 integrate .. //depot/projects/vap/sys/dev/ichsmb/ichsmb.c#2 integrate .. //depot/projects/vap/sys/dev/ichsmb/ichsmb_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ida/ida.c#2 integrate .. //depot/projects/vap/sys/dev/ida/ida_eisa.c#2 integrate .. //depot/projects/vap/sys/dev/ida/ida_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ida/idareg.h#2 integrate .. //depot/projects/vap/sys/dev/ida/idavar.h#2 integrate .. //depot/projects/vap/sys/dev/idt/idt_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ieee488/ibfoo.c#1 branch .. //depot/projects/vap/sys/dev/ieee488/ibfoo_int.h#1 branch .. //depot/projects/vap/sys/dev/ieee488/pcii.c#1 branch .. //depot/projects/vap/sys/dev/ieee488/ugpib.h#1 branch .. //depot/projects/vap/sys/dev/ieee488/upd7210.c#1 branch .. //depot/projects/vap/sys/dev/ieee488/upd7210.h#1 branch .. //depot/projects/vap/sys/dev/if_ndis/if_ndis.c#2 integrate .. //depot/projects/vap/sys/dev/if_ndis/if_ndis_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/if_ndis/if_ndis_pci.c#2 integrate .. //depot/projects/vap/sys/dev/if_ndis/if_ndis_usb.c#1 branch .. //depot/projects/vap/sys/dev/if_ndis/if_ndisvar.h#2 integrate .. //depot/projects/vap/sys/dev/iir/iir.h#2 integrate .. //depot/projects/vap/sys/dev/iir/iir_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ips/ips.c#2 integrate .. //depot/projects/vap/sys/dev/ips/ips.h#2 integrate .. //depot/projects/vap/sys/dev/ips/ips_commands.c#2 integrate .. //depot/projects/vap/sys/dev/ips/ips_disk.c#2 integrate .. //depot/projects/vap/sys/dev/ips/ips_ioctl.c#2 integrate .. //depot/projects/vap/sys/dev/ips/ips_pci.c#2 integrate .. //depot/projects/vap/sys/dev/isp/isp.c#2 integrate .. //depot/projects/vap/sys/dev/isp/isp_freebsd.c#2 integrate .. //depot/projects/vap/sys/dev/isp/isp_pci.c#2 integrate .. //depot/projects/vap/sys/dev/isp/isp_target.c#2 integrate .. //depot/projects/vap/sys/dev/isp/isp_target.h#2 integrate .. //depot/projects/vap/sys/dev/isp/ispvar.h#2 integrate .. //depot/projects/vap/sys/dev/ispfw/asm_2300.h#2 integrate .. //depot/projects/vap/sys/dev/ispfw/ispfw.c#2 integrate .. //depot/projects/vap/sys/dev/ixgb/if_ixgb.c#2 integrate .. //depot/projects/vap/sys/dev/ixgb/if_ixgb.h#2 integrate .. //depot/projects/vap/sys/dev/ixgb/if_ixgb_osdep.h#2 integrate .. //depot/projects/vap/sys/dev/kbd/atkbd.c#2 integrate .. //depot/projects/vap/sys/dev/kbd/atkbdc.c#2 integrate .. //depot/projects/vap/sys/dev/led/led.c#2 integrate .. //depot/projects/vap/sys/dev/lge/if_lge.c#2 integrate .. //depot/projects/vap/sys/dev/lnc/if_lnc_pci.c#2 integrate .. //depot/projects/vap/sys/dev/mcd/mcd.c#2 integrate .. //depot/projects/vap/sys/dev/mcd/mcdreg.h#2 integrate .. //depot/projects/vap/sys/dev/md/md.c#2 integrate .. //depot/projects/vap/sys/dev/mii/mii.c#2 integrate .. //depot/projects/vap/sys/dev/mii/mii_physubr.c#2 integrate .. //depot/projects/vap/sys/dev/mlx/mlx.c#2 integrate .. //depot/projects/vap/sys/dev/mlx/mlx_pci.c#2 integrate .. //depot/projects/vap/sys/dev/mly/mly.c#2 integrate .. //depot/projects/vap/sys/dev/mpt/mpilib/mpi_type.h#2 integrate .. //depot/projects/vap/sys/dev/mpt/mpt_pci.c#2 integrate .. //depot/projects/vap/sys/dev/mse/mse.c#2 integrate .. //depot/projects/vap/sys/dev/mse/mse_cbus.c#2 integrate .. //depot/projects/vap/sys/dev/mse/mse_isa.c#2 integrate .. //depot/projects/vap/sys/dev/mse/msevar.h#2 integrate .. //depot/projects/vap/sys/dev/musycc/musycc.c#2 delete .. //depot/projects/vap/sys/dev/my/if_my.c#2 integrate .. //depot/projects/vap/sys/dev/ncv/ncr53c500_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/nge/if_nge.c#2 integrate .. //depot/projects/vap/sys/dev/nmdm/nmdm.c#2 integrate .. //depot/projects/vap/sys/dev/nsp/nsp_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/null/null.c#2 integrate .. //depot/projects/vap/sys/dev/nve/if_nve.c#1 branch .. //depot/projects/vap/sys/dev/nve/if_nvereg.h#1 branch .. //depot/projects/vap/sys/dev/ofw/ofw_pci.h#2 integrate .. //depot/projects/vap/sys/dev/owi/if_owi_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/patm/if_patm_attach.c#2 integrate .. //depot/projects/vap/sys/dev/pbio/pbio.c#2 integrate .. //depot/projects/vap/sys/dev/pccard/card_if.m#2 integrate .. //depot/projects/vap/sys/dev/pccard/pccard.c#2 integrate .. //depot/projects/vap/sys/dev/pccard/pccard_cis.c#2 integrate .. //depot/projects/vap/sys/dev/pccard/pccard_cis.h#2 integrate .. //depot/projects/vap/sys/dev/pccard/pccard_cis_quirks.c#2 integrate .. //depot/projects/vap/sys/dev/pccard/pccarddevs#2 integrate .. //depot/projects/vap/sys/dev/pccard/pccardvar.h#2 integrate .. //depot/projects/vap/sys/dev/pccbb/pccbb_pci.c#2 integrate .. //depot/projects/vap/sys/dev/pci/pci.c#2 integrate .. //depot/projects/vap/sys/dev/pci/pci_pci.c#2 integrate .. //depot/projects/vap/sys/dev/pci/pci_private.h#2 integrate .. //depot/projects/vap/sys/dev/pci/pci_user.c#2 integrate .. //depot/projects/vap/sys/dev/pci/pcib_if.m#2 integrate .. //depot/projects/vap/sys/dev/pci/pcireg.h#2 integrate .. //depot/projects/vap/sys/dev/pci/pcivar.h#2 integrate .. //depot/projects/vap/sys/dev/pdq/if_fpa.c#2 integrate .. //depot/projects/vap/sys/dev/pdq/pdq_ifsubr.c#2 integrate .. //depot/projects/vap/sys/dev/ppbus/lpt.c#2 integrate .. //depot/projects/vap/sys/dev/ppbus/pps.c#2 integrate .. //depot/projects/vap/sys/dev/ppc/ppc.c#2 integrate .. //depot/projects/vap/sys/dev/pst/pst-pci.c#2 integrate .. //depot/projects/vap/sys/dev/puc/puc.c#2 integrate .. //depot/projects/vap/sys/dev/puc/puc_pci.c#2 integrate .. //depot/projects/vap/sys/dev/puc/puc_sbus.c#2 integrate .. //depot/projects/vap/sys/dev/puc/pucdata.c#2 integrate .. //depot/projects/vap/sys/dev/ral/if_ral.c#1 branch .. //depot/projects/vap/sys/dev/ral/if_ral_pccard.c#1 branch .. //depot/projects/vap/sys/dev/ral/if_ral_pci.c#1 branch .. //depot/projects/vap/sys/dev/ral/if_ralrate.c#1 branch .. //depot/projects/vap/sys/dev/ral/if_ralrate.h#1 branch .. //depot/projects/vap/sys/dev/ral/if_ralreg.h#1 branch .. //depot/projects/vap/sys/dev/ral/if_ralvar.h#1 branch .. //depot/projects/vap/sys/dev/random/hash.c#2 integrate .. //depot/projects/vap/sys/dev/random/nehemiah.c#2 integrate .. //depot/projects/vap/sys/dev/random/probe.c#2 integrate .. //depot/projects/vap/sys/dev/random/randomdev_soft.c#2 integrate .. //depot/projects/vap/sys/dev/random/yarrow.c#2 integrate .. //depot/projects/vap/sys/dev/ray/if_ray.c#2 integrate .. //depot/projects/vap/sys/dev/ray/if_rayvar.h#2 integrate .. //depot/projects/vap/sys/dev/re/if_re.c#2 integrate .. //depot/projects/vap/sys/dev/rp/rp_pci.c#2 integrate .. //depot/projects/vap/sys/dev/safe/safe.c#2 integrate .. //depot/projects/vap/sys/dev/sbsh/if_sbsh.c#2 integrate .. //depot/projects/vap/sys/dev/scd/scd.c#2 integrate .. //depot/projects/vap/sys/dev/scd/scdreg.h#2 integrate .. //depot/projects/vap/sys/dev/si/si_pci.c#2 integrate .. //depot/projects/vap/sys/dev/sio/sio.c#2 integrate .. //depot/projects/vap/sys/dev/sio/sio_pci.c#2 integrate .. //depot/projects/vap/sys/dev/sn/if_sn_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/snc/dp83932.c#2 integrate .. //depot/projects/vap/sys/dev/snc/if_snc_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/snp/snp.c#2 integrate .. //depot/projects/vap/sys/dev/sound/isa/ad1816.c#2 integrate .. //depot/projects/vap/sys/dev/sound/isa/mss.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/als4000.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/au88x0.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/aureal.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/cmi.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/cs4281.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/csa.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/ds1.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/emu10k1.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/es137x.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/fm801.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/ich.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/maestro.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/maestro3.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/solo.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/t4dwave.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/via8233.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/via82c686.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pci/vibes.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pcm/ac97.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pcm/dsp.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pcm/mixer.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pcm/sndstat.c#2 integrate .. //depot/projects/vap/sys/dev/sound/pcm/sound.h#2 integrate .. //depot/projects/vap/sys/dev/sound/sbus/cs4231.c#2 integrate .. //depot/projects/vap/sys/dev/sound/usb/uaudio.c#2 integrate .. //depot/projects/vap/sys/dev/sound/usb/uaudio.h#2 integrate .. //depot/projects/vap/sys/dev/sound/usb/uaudio_pcm.c#2 integrate .. //depot/projects/vap/sys/dev/sr/if_sr.c#2 integrate .. //depot/projects/vap/sys/dev/sr/if_sr_pci.c#2 integrate .. //depot/projects/vap/sys/dev/stg/tmc18c30_pci.c#2 integrate .. //depot/projects/vap/sys/dev/streams/streams.c#2 integrate .. //depot/projects/vap/sys/dev/sx/sx_pci.c#2 integrate .. //depot/projects/vap/sys/dev/sym/sym_hipd.c#2 integrate .. //depot/projects/vap/sys/dev/syscons/apm/apm_saver.c#2 integrate .. //depot/projects/vap/sys/dev/syscons/syscons.c#2 integrate .. //depot/projects/vap/sys/dev/syscons/sysmouse.c#2 integrate .. //depot/projects/vap/sys/dev/tdfx/tdfx_pci.c#2 integrate .. //depot/projects/vap/sys/dev/tga/tga_pci.c#2 integrate .. //depot/projects/vap/sys/dev/trm/trm.c#2 integrate .. //depot/projects/vap/sys/dev/twa/tw_cl.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_externs.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_fwif.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_fwimg.c#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_init.c#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_intr.c#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_io.c#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_ioctl.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_misc.c#1 branch .. //depot/projects/vap/sys/dev/twa/tw_cl_share.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl_cam.c#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl_externs.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl_freebsd.c#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl_includes.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl_ioctl.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl_share.h#1 branch .. //depot/projects/vap/sys/dev/twa/tw_osl_types.h#1 branch .. //depot/projects/vap/sys/dev/twa/twa.c#2 delete .. //depot/projects/vap/sys/dev/twa/twa.h#2 delete .. //depot/projects/vap/sys/dev/twa/twa_cam.c#2 delete .. //depot/projects/vap/sys/dev/twa/twa_externs.h#2 delete .. //depot/projects/vap/sys/dev/twa/twa_freebsd.c#2 delete .. //depot/projects/vap/sys/dev/twa/twa_fwimg.c#2 delete .. //depot/projects/vap/sys/dev/twa/twa_globals.c#2 delete .. //depot/projects/vap/sys/dev/twa/twa_includes.h#2 delete .. //depot/projects/vap/sys/dev/twa/twa_ioctl.h#2 delete .. //depot/projects/vap/sys/dev/twa/twa_reg.h#2 delete .. //depot/projects/vap/sys/dev/twe/twe.c#2 integrate .. //depot/projects/vap/sys/dev/twe/twe_freebsd.c#2 integrate .. //depot/projects/vap/sys/dev/twe/tweio.h#2 integrate .. //depot/projects/vap/sys/dev/tx/if_tx.c#2 integrate .. //depot/projects/vap/sys/dev/txp/if_txp.c#2 integrate .. //depot/projects/vap/sys/dev/uart/uart_core.c#2 integrate .. //depot/projects/vap/sys/dev/uart/uart_cpu_sparc64.c#2 integrate .. //depot/projects/vap/sys/dev/uart/uart_dev_sab82532.c#2 integrate .. //depot/projects/vap/sys/dev/uart/uart_dev_z8530.c#2 integrate .. //depot/projects/vap/sys/dev/uart/uart_kbd_sun.c#2 integrate .. //depot/projects/vap/sys/dev/ubsec/ubsec.c#2 integrate .. //depot/projects/vap/sys/dev/usb/ehci.c#2 integrate .. //depot/projects/vap/sys/dev/usb/ehci_pci.c#2 integrate .. //depot/projects/vap/sys/dev/usb/ehcivar.h#2 integrate .. //depot/projects/vap/sys/dev/usb/hid.c#2 integrate .. //depot/projects/vap/sys/dev/usb/if_aue.c#2 integrate .. //depot/projects/vap/sys/dev/usb/if_auereg.h#2 integrate .. //depot/projects/vap/sys/dev/usb/if_axe.c#2 integrate .. //depot/projects/vap/sys/dev/usb/if_axereg.h#2 integrate .. //depot/projects/vap/sys/dev/usb/if_cdce.c#1 branch .. //depot/projects/vap/sys/dev/usb/if_cdcereg.h#1 branch .. //depot/projects/vap/sys/dev/usb/if_cue.c#2 integrate .. //depot/projects/vap/sys/dev/usb/if_cuereg.h#2 integrate .. //depot/projects/vap/sys/dev/usb/if_kue.c#2 integrate .. //depot/projects/vap/sys/dev/usb/if_kuereg.h#2 integrate .. //depot/projects/vap/sys/dev/usb/if_rue.c#2 integrate .. //depot/projects/vap/sys/dev/usb/if_ruereg.h#2 integrate .. //depot/projects/vap/sys/dev/usb/if_udav.c#2 integrate .. //depot/projects/vap/sys/dev/usb/if_udavreg.h#2 integrate .. //depot/projects/vap/sys/dev/usb/if_ural.c#1 branch .. //depot/projects/vap/sys/dev/usb/if_uralreg.h#1 branch .. //depot/projects/vap/sys/dev/usb/if_uralvar.h#1 branch .. //depot/projects/vap/sys/dev/usb/ohci.c#2 integrate .. //depot/projects/vap/sys/dev/usb/ohci_pci.c#2 integrate .. //depot/projects/vap/sys/dev/usb/ohcivar.h#2 integrate .. //depot/projects/vap/sys/dev/usb/ubser.c#2 integrate .. //depot/projects/vap/sys/dev/usb/ubser.h#2 integrate .. //depot/projects/vap/sys/dev/usb/ucom.c#2 integrate .. //depot/projects/vap/sys/dev/usb/uftdi.c#2 integrate .. //depot/projects/vap/sys/dev/usb/uhci.c#2 integrate .. //depot/projects/vap/sys/dev/usb/uhci_pci.c#2 integrate .. //depot/projects/vap/sys/dev/usb/uhcivar.h#2 integrate .. //depot/projects/vap/sys/dev/usb/uhub.c#2 integrate .. //depot/projects/vap/sys/dev/usb/ukbd.c#2 integrate .. //depot/projects/vap/sys/dev/usb/umass.c#2 integrate .. //depot/projects/vap/sys/dev/usb/umodem.c#2 integrate .. //depot/projects/vap/sys/dev/usb/uplcom.c#2 integrate .. //depot/projects/vap/sys/dev/usb/usb.c#2 integrate .. //depot/projects/vap/sys/dev/usb/usb_ethersubr.c#2 integrate .. //depot/projects/vap/sys/dev/usb/usb_ethersubr.h#2 integrate .. //depot/projects/vap/sys/dev/usb/usb_port.h#2 integrate .. //depot/projects/vap/sys/dev/usb/usb_subr.c#2 integrate .. //depot/projects/vap/sys/dev/usb/usbcdc.h#2 integrate .. //depot/projects/vap/sys/dev/usb/usbdevs#2 integrate .. //depot/projects/vap/sys/dev/usb/usbdi.c#2 integrate .. //depot/projects/vap/sys/dev/usb/usbdi.h#2 integrate .. //depot/projects/vap/sys/dev/usb/usbdi_util.c#2 integrate .. //depot/projects/vap/sys/dev/usb/usbdi_util.h#2 integrate .. //depot/projects/vap/sys/dev/usb/uvscom.c#2 integrate .. //depot/projects/vap/sys/dev/utopia/idtphy.c#1 branch .. //depot/projects/vap/sys/dev/utopia/suni.c#1 branch .. //depot/projects/vap/sys/dev/utopia/utopia.c#2 integrate .. //depot/projects/vap/sys/dev/utopia/utopia.h#2 integrate .. //depot/projects/vap/sys/dev/utopia/utopia_priv.h#1 branch .. //depot/projects/vap/sys/dev/vge/if_vge.c#2 integrate .. //depot/projects/vap/sys/dev/vkbd/vkbd.c#2 integrate .. //depot/projects/vap/sys/dev/vx/if_vx.c#2 integrate .. //depot/projects/vap/sys/dev/vx/if_vx_pci.c#2 integrate .. //depot/projects/vap/sys/dev/wi/if_wi.c#4 integrate .. //depot/projects/vap/sys/dev/wi/if_wi_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/wi/if_wi_pci.c#2 integrate .. //depot/projects/vap/sys/dev/xe/if_xe_pccard.c#2 integrate .. //depot/projects/vap/sys/dev/zs/zs_sbus.c#2 delete .. //depot/projects/vap/sys/fs/deadfs/dead_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/devfs/devfs.h#2 integrate .. //depot/projects/vap/sys/fs/devfs/devfs_devs.c#2 integrate .. //depot/projects/vap/sys/fs/devfs/devfs_rule.c#2 integrate .. //depot/projects/vap/sys/fs/devfs/devfs_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/devfs/devfs_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/fdescfs/fdesc.h#2 integrate .. //depot/projects/vap/sys/fs/fdescfs/fdesc_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/fdescfs/fdesc_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/fifofs/fifo_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/hpfs/hpfs.h#2 integrate .. //depot/projects/vap/sys/fs/hpfs/hpfs_hash.c#2 delete .. //depot/projects/vap/sys/fs/hpfs/hpfs_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/hpfs/hpfs_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/msdosfs/denode.h#2 integrate .. //depot/projects/vap/sys/fs/msdosfs/msdosfs_conv.c#2 integrate .. //depot/projects/vap/sys/fs/msdosfs/msdosfs_denode.c#2 integrate .. //depot/projects/vap/sys/fs/msdosfs/msdosfs_lookup.c#2 integrate .. //depot/projects/vap/sys/fs/msdosfs/msdosfs_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/msdosfs/msdosfs_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/msdosfs/msdosfsmount.h#2 integrate .. //depot/projects/vap/sys/fs/ntfs/ntfs_subr.c#2 integrate .. //depot/projects/vap/sys/fs/ntfs/ntfs_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/ntfs/ntfs_vfsops.h#2 integrate .. //depot/projects/vap/sys/fs/ntfs/ntfs_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/nullfs/null.h#2 integrate .. //depot/projects/vap/sys/fs/nullfs/null_subr.c#2 integrate .. //depot/projects/vap/sys/fs/nullfs/null_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/nullfs/null_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/nwfs/nwfs_io.c#2 integrate .. //depot/projects/vap/sys/fs/nwfs/nwfs_node.c#2 integrate .. //depot/projects/vap/sys/fs/nwfs/nwfs_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/nwfs/nwfs_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/portalfs/portal_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/portalfs/portal_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/procfs/procfs_status.c#2 integrate .. //depot/projects/vap/sys/fs/pseudofs/pseudofs.c#2 integrate .. //depot/projects/vap/sys/fs/pseudofs/pseudofs.h#2 integrate .. //depot/projects/vap/sys/fs/pseudofs/pseudofs_fileno.c#2 integrate .. //depot/projects/vap/sys/fs/pseudofs/pseudofs_internal.h#2 integrate .. //depot/projects/vap/sys/fs/pseudofs/pseudofs_vncache.c#2 integrate .. //depot/projects/vap/sys/fs/pseudofs/pseudofs_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/smbfs/smbfs_io.c#2 integrate .. //depot/projects/vap/sys/fs/smbfs/smbfs_node.c#2 integrate .. //depot/projects/vap/sys/fs/smbfs/smbfs_subr.h#2 integrate .. //depot/projects/vap/sys/fs/smbfs/smbfs_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/smbfs/smbfs_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/udf/ecma167-udf.h#2 integrate .. //depot/projects/vap/sys/fs/udf/udf.h#2 integrate .. //depot/projects/vap/sys/fs/udf/udf_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/udf/udf_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/umapfs/umap_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/umapfs/umap_vnops.c#2 integrate .. //depot/projects/vap/sys/fs/unionfs/union_subr.c#2 integrate .. //depot/projects/vap/sys/fs/unionfs/union_vfsops.c#2 integrate .. //depot/projects/vap/sys/fs/unionfs/union_vnops.c#2 integrate .. //depot/projects/vap/sys/gdb/gdb_main.c#2 integrate .. //depot/projects/vap/sys/geom/bde/g_bde.c#2 integrate .. //depot/projects/vap/sys/geom/bde/g_bde_crypt.c#2 integrate .. //depot/projects/vap/sys/geom/bde/g_bde_lock.c#2 integrate .. //depot/projects/vap/sys/geom/bde/g_bde_work.c#2 integrate .. //depot/projects/vap/sys/geom/concat/g_concat.c#2 integrate .. //depot/projects/vap/sys/geom/concat/g_concat.h#2 integrate .. //depot/projects/vap/sys/geom/gate/g_gate.c#2 integrate .. //depot/projects/vap/sys/geom/gate/g_gate.h#2 integrate .. //depot/projects/vap/sys/geom/geom_aes.c#2 integrate .. //depot/projects/vap/sys/geom/geom_bsd.c#2 integrate .. //depot/projects/vap/sys/geom/geom_ctl.c#2 integrate .. //depot/projects/vap/sys/geom/geom_dev.c#2 integrate .. //depot/projects/vap/sys/geom/geom_disk.c#2 integrate .. //depot/projects/vap/sys/geom/geom_disk.h#2 integrate .. //depot/projects/vap/sys/geom/geom_gpt.c#2 integrate .. //depot/projects/vap/sys/geom/geom_kern.c#2 integrate .. //depot/projects/vap/sys/geom/geom_mbr.c#2 integrate .. //depot/projects/vap/sys/geom/geom_pc98.c#2 integrate .. //depot/projects/vap/sys/geom/geom_pc98_enc.c#2 integrate .. //depot/projects/vap/sys/geom/geom_subr.c#2 integrate .. //depot/projects/vap/sys/geom/geom_sunlabel.c#2 integrate .. //depot/projects/vap/sys/geom/geom_sunlabel_enc.c#2 integrate .. //depot/projects/vap/sys/geom/geom_vfs.c#2 integrate .. //depot/projects/vap/sys/geom/geom_vfs.h#2 integrate .. //depot/projects/vap/sys/geom/geom_vol_ffs.c#2 integrate .. //depot/projects/vap/sys/geom/label/g_label.c#2 integrate .. //depot/projects/vap/sys/geom/label/g_label.h#2 integrate .. //depot/projects/vap/sys/geom/label/g_label_ufs.c#2 integrate .. //depot/projects/vap/sys/geom/mirror/g_mirror.c#2 integrate .. //depot/projects/vap/sys/geom/mirror/g_mirror.h#2 integrate .. //depot/projects/vap/sys/geom/mirror/g_mirror_ctl.c#2 integrate .. //depot/projects/vap/sys/geom/raid3/g_raid3.c#2 integrate .. //depot/projects/vap/sys/geom/raid3/g_raid3.h#2 integrate .. //depot/projects/vap/sys/geom/raid3/g_raid3_ctl.c#2 integrate .. //depot/projects/vap/sys/geom/shsec/g_shsec.c#2 integrate .. //depot/projects/vap/sys/geom/shsec/g_shsec.h#2 integrate .. //depot/projects/vap/sys/geom/stripe/g_stripe.c#2 integrate >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Tue May 3 16:28:19 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7B1A116A4D0; Tue, 3 May 2005 16:28:19 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 548B416A4CE for ; Tue, 3 May 2005 16:28:19 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9F27643D39 for ; Tue, 3 May 2005 16:28:18 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43GSDZn052985 for ; Tue, 3 May 2005 16:28:13 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43GSDp2052979 for perforce@freebsd.org; Tue, 3 May 2005 16:28:13 GMT (envelope-from sam@freebsd.org) Date: Tue, 3 May 2005 16:28:13 GMT Message-Id: <200505031628.j43GSDp2052979@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76439 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 16:28:20 -0000 http://perforce.freebsd.org/chv.cgi?CH=76439 Change 76439 by sam@sam_ebb on 2005/05/03 16:28:08 IFC @ 76395 (remainder) Affected files ... .. //depot/projects/vap/sys/dev/an/if_an.c#2 integrate .. //depot/projects/vap/sys/dev/an/if_an_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ath/ath_rate/amrr/amrr.c#2 integrate .. //depot/projects/vap/sys/dev/ath/ath_rate/onoe/onoe.c#4 integrate .. //depot/projects/vap/sys/dev/ath/ath_rate/sample/sample.c#1 add .. //depot/projects/vap/sys/dev/ath/ath_rate/sample/sample.h#1 add .. //depot/projects/vap/sys/dev/ath/if_ath.c#6 edit .. //depot/projects/vap/sys/dev/ath/if_ath_pci.c#2 integrate .. //depot/projects/vap/sys/dev/ath/if_athioctl.h#2 integrate .. //depot/projects/vap/sys/dev/ath/if_athrate.h#3 integrate .. //depot/projects/vap/sys/dev/ath/if_athvar.h#4 integrate .. //depot/projects/vap/sys/dev/awi/awi.c#2 integrate .. //depot/projects/vap/sys/dev/ipw/if_ipw.c#1 branch .. //depot/projects/vap/sys/dev/ipw/if_ipwreg.h#1 branch .. //depot/projects/vap/sys/dev/ipw/if_ipwvar.h#1 branch .. //depot/projects/vap/sys/dev/iwi/if_iwi.c#4 integrate .. //depot/projects/vap/sys/dev/iwi/if_iwireg.h#2 integrate .. //depot/projects/vap/sys/dev/iwi/if_iwivar.h#3 integrate .. //depot/projects/vap/sys/net80211/_ieee80211.h#3 integrate .. //depot/projects/vap/sys/net80211/ieee80211.c#6 integrate .. //depot/projects/vap/sys/net80211/ieee80211_crypto.c#3 integrate .. //depot/projects/vap/sys/net80211/ieee80211_crypto.h#4 integrate .. //depot/projects/vap/sys/net80211/ieee80211_crypto_ccmp.c#3 integrate .. //depot/projects/vap/sys/net80211/ieee80211_crypto_none.c#3 integrate .. //depot/projects/vap/sys/net80211/ieee80211_crypto_tkip.c#3 integrate .. //depot/projects/vap/sys/net80211/ieee80211_crypto_wep.c#3 integrate .. //depot/projects/vap/sys/net80211/ieee80211_freebsd.c#6 integrate .. //depot/projects/vap/sys/net80211/ieee80211_freebsd.h#4 integrate .. //depot/projects/vap/sys/net80211/ieee80211_input.c#7 integrate .. //depot/projects/vap/sys/net80211/ieee80211_ioctl.c#5 integrate .. //depot/projects/vap/sys/net80211/ieee80211_ioctl.h#4 integrate .. //depot/projects/vap/sys/net80211/ieee80211_node.c#4 integrate .. //depot/projects/vap/sys/net80211/ieee80211_node.h#4 integrate .. //depot/projects/vap/sys/net80211/ieee80211_output.c#6 integrate .. //depot/projects/vap/sys/net80211/ieee80211_proto.c#5 integrate .. //depot/projects/vap/sys/net80211/ieee80211_proto.h#4 integrate .. //depot/projects/vap/sys/net80211/ieee80211_radiotap.h#2 integrate .. //depot/projects/vap/sys/net80211/ieee80211_var.h#7 integrate .. //depot/projects/vap/tools/tools/ath/80211stats.c#3 integrate .. //depot/projects/vap/tools/tools/ath/80211watch.c#2 integrate .. //depot/projects/vap/tools/tools/ath/athstats.c#3 integrate Differences ... ==== //depot/projects/vap/sys/dev/an/if_an.c#2 (text+ko) ==== @@ -38,7 +38,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/an/if_an.c,v 1.64 2005/01/06 01:42:28 imp Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/an/if_an.c,v 1.65 2005/03/28 17:52:12 sam Exp $"); /* * The Aironet 4500/4800 series cards come in PCMCIA, ISA and PCI form. @@ -2011,7 +2011,9 @@ case SIOCGPRIVATE_0: /* used by Cisco client utility */ if ((error = suser(td))) goto out; - copyin(ifr->ifr_data, &l_ioctl, sizeof(l_ioctl)); + error = copyin(ifr->ifr_data, &l_ioctl, sizeof(l_ioctl)); + if (error) + goto out; mode = l_ioctl.command; if (mode >= AIROGCAP && mode <= AIROGSTATSD32) { @@ -2023,18 +2025,20 @@ } else { error =-1; } - - /* copy out the updated command info */ - copyout(&l_ioctl, ifr->ifr_data, sizeof(l_ioctl)); - + if (!error) { + /* copy out the updated command info */ + error = copyout(&l_ioctl, ifr->ifr_data, sizeof(l_ioctl)); + } break; case SIOCGPRIVATE_1: /* used by Cisco client utility */ if ((error = suser(td))) goto out; - copyin(ifr->ifr_data, &l_ioctl, sizeof(l_ioctl)); + error = copyin(ifr->ifr_data, &l_ioctl, sizeof(l_ioctl)); + if (error) + goto out; l_ioctl.command = 0; error = AIROMAGIC; - copyout(&error, l_ioctl.data, sizeof(error)); + (void) copyout(&error, l_ioctl.data, sizeof(error)); error = 0; break; case SIOCG80211: @@ -3376,9 +3380,10 @@ sc->areq.an_type = rid; /* Just copy the data back */ - copyin((l_ioctl->data) + 2, &sc->areq.an_val, - l_ioctl->len); - + if (copyin((l_ioctl->data) + 2, &sc->areq.an_val, + l_ioctl->len)) { + return -EFAULT; + } an_cmd(sc, AN_CMD_DISABLE, 0); an_write_record(sc, (struct an_ltv_gen *)&sc->areq); an_cmd(sc, AN_CMD_ENABLE, 0); @@ -3689,15 +3694,18 @@ return ENOBUFS; break; case AIROFLSHGCHR: /* Get char from aux */ - copyin(l_ioctl->data, &sc->areq, l_ioctl->len); + status = copyin(l_ioctl->data, &sc->areq, l_ioctl->len); + if (status) + return status; z = *(int *)&sc->areq; if ((status = flashgchar(ifp, z, 8000)) == 1) return 0; else return -1; - break; case AIROFLSHPCHR: /* Send char to card. */ - copyin(l_ioctl->data, &sc->areq, l_ioctl->len); + status = copyin(l_ioctl->data, &sc->areq, l_ioctl->len); + if (status) + return status; z = *(int *)&sc->areq; if ((status = flashpchar(ifp, z, 8000)) == -1) return -EIO; @@ -3710,7 +3718,9 @@ l_ioctl->len, FLASH_SIZE); return -EINVAL; } - copyin(l_ioctl->data, sc->an_flash_buffer, l_ioctl->len); + status = copyin(l_ioctl->data, sc->an_flash_buffer, l_ioctl->len); + if (status) + return status; if ((status = flashputbuf(ifp)) != 0) return -EIO; ==== //depot/projects/vap/sys/dev/an/if_an_pci.c#2 (text+ko) ==== @@ -31,7 +31,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/an/if_an_pci.c,v 1.26 2003/12/30 01:07:12 ambrisko Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/an/if_an_pci.c,v 1.27 2005/03/05 19:06:11 imp Exp $"); /* * This is a PCI shim for the Aironet PC4500/4800 wireless network @@ -125,7 +125,7 @@ if (pci_get_vendor(dev) == t->an_vid && pci_get_device(dev) == t->an_did) { device_set_desc(dev, t->an_name); - return(0); + return(BUS_PROBE_DEFAULT); } t++; } @@ -133,7 +133,7 @@ if (pci_get_vendor(dev) == AIRONET_VENDORID && pci_get_device(dev) == AIRONET_DEVICEID_MPI350) { device_set_desc(dev, "Cisco Aironet MPI350"); - return(0); + return(BUS_PROBE_DEFAULT); } return(ENXIO); ==== //depot/projects/vap/sys/dev/ath/ath_rate/amrr/amrr.c#2 (text+ko) ==== @@ -37,7 +37,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ath/ath_rate/amrr/amrr.c,v 1.3 2004/12/31 22:41:45 sam Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ath/ath_rate/amrr/amrr.c,v 1.7 2005/04/02 18:54:30 sam Exp $"); /* * AMRR rate control. See: @@ -114,7 +114,7 @@ void ath_rate_findrate(struct ath_softc *sc, struct ath_node *an, - HAL_BOOL shortPreamble, size_t frameLen, + int shortPreamble, size_t frameLen, u_int8_t *rix, int *try0, u_int8_t *txrate) { struct amrr_node *amn = ATH_NODE_AMRR(an); @@ -129,7 +129,7 @@ void ath_rate_setupxtxdesc(struct ath_softc *sc, struct ath_node *an, - struct ath_desc *ds, HAL_BOOL shortPreamble, u_int8_t rix) + struct ath_desc *ds, int shortPreamble, u_int8_t rix) { struct amrr_node *amn = ATH_NODE_AMRR(an); @@ -141,8 +141,8 @@ } void -ath_rate_tx_complete(struct ath_softc *sc, - struct ath_node *an, const struct ath_desc *ds) +ath_rate_tx_complete(struct ath_softc *sc, struct ath_node *an, + const struct ath_desc *ds, const struct ath_desc *ds0) { struct amrr_node *amn = ATH_NODE_AMRR(an); int sr = ds->ds_txstat.ts_shortretry; @@ -326,7 +326,9 @@ static void ath_rate_cb(void *arg, struct ieee80211_node *ni) { - ath_rate_update(ni->ni_ic->ic_ifp->if_softc, ni, (int)(uintptr_t) arg); + struct ath_softc *sc = arg; + + ath_rate_update(sc, ni, 0); } /* @@ -361,7 +363,7 @@ * For any other operating mode we want to reset the * tx rate state of each node. */ - ieee80211_iterate_nodes(&ic->ic_sta, ath_rate_cb, 0); + ieee80211_iterate_nodes(&ic->ic_sta, ath_rate_cb, sc); ath_rate_update(sc, ic->ic_bss, 0); } if (ic->ic_fixed_rate == -1 && state == IEEE80211_S_RUN) { ==== //depot/projects/vap/sys/dev/ath/ath_rate/onoe/onoe.c#4 (text+ko) ==== @@ -35,7 +35,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ath/ath_rate/onoe/onoe.c,v 1.3 2004/12/31 22:41:45 sam Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ath/ath_rate/onoe/onoe.c,v 1.7 2005/04/02 18:54:30 sam Exp $"); /* * Atsushi Onoe's rate control algorithm. @@ -130,7 +130,7 @@ void ath_rate_findrate(struct ath_softc *sc, struct ath_node *an, - HAL_BOOL shortPreamble, size_t frameLen, + int shortPreamble, size_t frameLen, u_int8_t *rix, int *try0, u_int8_t *txrate) { struct onoe_node *on = ATH_NODE_ONOE(an); @@ -145,7 +145,7 @@ void ath_rate_setupxtxdesc(struct ath_softc *sc, struct ath_node *an, - struct ath_desc *ds, HAL_BOOL shortPreamble, u_int8_t rix) + struct ath_desc *ds, int shortPreamble, u_int8_t rix) { struct onoe_node *on = ATH_NODE_ONOE(an); @@ -157,8 +157,8 @@ } void -ath_rate_tx_complete(struct ath_softc *sc, - struct ath_node *an, const struct ath_desc *ds) +ath_rate_tx_complete(struct ath_softc *sc, struct ath_node *an, + const struct ath_desc *ds, const struct ath_desc *ds0) { struct onoe_node *on = ATH_NODE_ONOE(an); @@ -315,7 +315,9 @@ static void ath_rate_cb(void *arg, struct ieee80211_node *ni) { - ath_rate_update(ni->ni_ic->ic_ifp->if_softc, ni, (int)(uintptr_t) arg); + struct ath_softc *sc = arg; + + ath_rate_update(sc, ni, 0); } /* @@ -343,7 +345,7 @@ /* * Reset the tx rate state of each station/neighbor. */ - ieee80211_iterate_nodes(&ic->ic_sta, ath_rate_cb, 0); + ieee80211_iterate_nodes(&ic->ic_sta, ath_rate_cb, sc); ath_rate_update(sc, vap->iv_bss, 0); } } ==== //depot/projects/vap/sys/dev/ath/if_ath.c#6 (text+ko) ==== @@ -35,7 +35,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.66 2004/12/31 22:41:45 sam Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.88 2005/04/12 17:56:43 sam Exp $"); /* * Driver for the Atheros Wireless LAN controller. @@ -1792,6 +1792,35 @@ struct ath_softc *sc = ic->ic_ifp->if_softc; /* + * Group key allocation must be handled specially for + * parts that do not support multicast key cache search + * functionality. For those parts the key id must match + * the h/w key index so lookups find the right key. On + * parts w/ the key search facility we install the sender's + * mac address (with the high bit set) and let the hardware + * find the key w/o using the key id. This is preferred as + * it permits us to support multiple users for adhoc and/or + * multi-station operation. + */ + if ((k->wk_flags & IEEE80211_KEY_GROUP) && !sc->sc_mcastkey) { + u_int keyix; + + if (!(&vap->iv_nw_keys[0] <= k && + k < &vap->iv_nw_keys[IEEE80211_WEP_NKID])) { + /* should not happen */ + DPRINTF(sc, ATH_DEBUG_KEYCACHE, + "%s: bogus group key\n", __func__); + return IEEE80211_KEYIX_NONE; + } + keyix = k - vap->iv_nw_keys; + /* + * XXX we pre-allocate the global keys so + * have no way to check if they've already been allocated. + */ + return keyix; + } + + /* * We allocate two pair for TKIP when using the h/w to do * the MIC. For everything else, including software crypto, * we allocate a single entry. Note that s/w crypto requires @@ -1981,18 +2010,6 @@ __func__, rfilt, mfilt[0], mfilt[1]); } -static void -ath_mbuf_load_cb(void *arg, bus_dma_segment_t *seg, int nseg, bus_size_t mapsize, int error) -{ - struct ath_buf *bf = arg; - - KASSERT(nseg <= ATH_MAX_SCATTER, ("too many DMA segments %u", nseg)); - KASSERT(error == 0, ("error %u on bus_dma callback", error)); - bf->bf_mapsize = mapsize; - bf->bf_nseg = nseg; - bcopy(seg, bf->bf_segs, nseg * sizeof (seg[0])); -} - /* * Set the slot time based on the current setting. */ @@ -2074,8 +2091,8 @@ sc->sc_stats.ast_be_nombuf++; return ENOMEM; } - error = bus_dmamap_load_mbuf(sc->sc_dmat, bf->bf_dmamap, m, - ath_mbuf_load_cb, bf, + error = bus_dmamap_load_mbuf_sg(sc->sc_dmat, bf->bf_dmamap, m, + bf->bf_segs, &bf->bf_nseg, BUS_DMA_NOWAIT); if (error == 0) { bf->bf_m = m; @@ -2220,12 +2237,12 @@ if (ieee80211_beacon_update(ni, &sc->sc_boff, m, ncabq)) { /* XXX too conservative? */ bus_dmamap_unload(sc->sc_dmat, bf->bf_dmamap); - error = bus_dmamap_load_mbuf(sc->sc_dmat, bf->bf_dmamap, m, - ath_mbuf_load_cb, bf, + error = bus_dmamap_load_mbuf_sg(sc->sc_dmat, bf->bf_dmamap, m, + bf->bf_segs, &bf->bf_nseg, BUS_DMA_NOWAIT); if (error != 0) { if_printf(ic->ic_ifp, - "%s: bus_dmamap_load_mbuf failed, error %u\n", + "%s: bus_dmamap_load_mbuf_sg failed, error %u\n", __func__, error); return; } @@ -2340,7 +2357,6 @@ static void ath_beacon_config(struct ath_softc *sc) { -#define MS_TO_TU(x) (((x) * 1000) / 1024) struct ieee80211com *ic = &sc->sc_ic; struct ath_hal *ah = sc->sc_ah; struct ieee80211vap *vap = TAILQ_FIRST(&ic->ic_vaps); /*XXX*/ @@ -2395,7 +2411,8 @@ * * XXX fixed at 100ms */ - bs.bs_sleepduration = roundup(MS_TO_TU(100), bs.bs_intval); + bs.bs_sleepduration = + roundup(IEEE80211_MS_TO_TU(100), bs.bs_intval); if (bs.bs_sleepduration > bs.bs_dtimperiod) bs.bs_sleepduration = roundup(bs.bs_sleepduration, bs.bs_dtimperiod); @@ -2450,7 +2467,6 @@ if (ic->ic_opmode == IEEE80211_M_IBSS && sc->sc_hasveol) ath_beacon_proc(sc, 0); } -#undef MS_TO_TU } static void @@ -2726,14 +2742,14 @@ bf->bf_m = m; m->m_pkthdr.len = m->m_len = m->m_ext.ext_size; - error = bus_dmamap_load_mbuf(sc->sc_dmat, + error = bus_dmamap_load_mbuf_sg(sc->sc_dmat, bf->bf_dmamap, m, - ath_mbuf_load_cb, bf, + bf->bf_segs, &bf->bf_nseg, BUS_DMA_NOWAIT); if (error != 0) { DPRINTF(sc, ATH_DEBUG_ANY, - "%s: bus_dmamap_load_mbuf failed; error %d\n", - __func__, error); + "%s: bus_dmamap_load_mbuf_sg failed; error %d\n", + __func__, error); sc->sc_stats.ast_rx_busdma++; return error; } @@ -2772,6 +2788,21 @@ } /* + * Extend 15-bit time stamp from rx descriptor to + * a full 64-bit TSF using the current h/w TSF. + */ +static __inline u_int64_t +ath_extend_tsf(struct ath_hal *ah, u_int32_t rstamp) +{ + u_int64_t tsf; + + tsf = ath_hal_gettsf64(ah); + if ((tsf & 0x7fff) < rstamp) + tsf -= 0x8000; + return ((tsf &~ 0x7fff) | rstamp); +} + +/* * Intercept management frames to collect beacon rssi data * and to do ibss merges. */ @@ -2796,10 +2827,7 @@ vap = ni->ni_vap; if (vap->iv_opmode == IEEE80211_M_IBSS && vap->iv_state == IEEE80211_S_RUN) { - struct ath_hal *ah = sc->sc_ah; - /* XXX extend rstamp */ - u_int64_t tsf = ath_hal_gettsf64(ah); - + u_int64_t tsf = ath_extend_tsf(sc->sc_ah, rstamp); /* * Handle ibss merge as needed; check the tsf on the * frame before attempting the merge. The 802.11 spec @@ -2807,11 +2835,16 @@ * the oldest station with the same ssid, where oldest * is determined by the tsf. Note that hardware * reconfiguration happens through callback to - * ath_newstate as the state machine will be go - * from RUN -> RUN when this happens. + * ath_newstate as the state machine will go from + * RUN -> RUN when this happens. */ - if (le64toh(ni->ni_tstamp.tsf) >= tsf) + if (le64toh(ni->ni_tstamp.tsf) >= tsf) { + DPRINTF(sc, ATH_DEBUG_STATE, + "ibss merge, rstamp %u tsf %ju " + "tstamp %ju\n", rstamp, (uintmax_t)tsf, + (uintmax_t)ni->ni_tstamp.tsf); (void) ieee80211_ibss_merge(ni); + } } break; } @@ -2847,7 +2880,7 @@ struct ath_desc *ds; struct mbuf *m; struct ieee80211_node *ni; - int len; + int len, type; u_int phyerr; HAL_STATUS status; @@ -3026,14 +3059,14 @@ goto rx_next; } rix = ds->ds_rxstat.rs_rate; - sc->sc_rx_th.wr_flags = sc->sc_hwmap[rix].flags; + sc->sc_rx_th.wr_flags = sc->sc_hwmap[rix].rxflags; sc->sc_rx_th.wr_rate = sc->sc_hwmap[rix].ieeerate; sc->sc_rx_th.wr_antsignal = ds->ds_rxstat.rs_rssi; sc->sc_rx_th.wr_antenna = ds->ds_rxstat.rs_antenna; /* XXX TSF */ bpf_mtap2(sc->sc_drvbpf, - &sc->sc_rx, sc->sc_rx_rt_len, m); + &sc->sc_rx_th, sc->sc_rx_th_len, m); } /* @@ -3075,11 +3108,11 @@ struct ath_node *an = ATH_NODE(ni); ATH_RSSI_LPF(an->an_avgrssi, ds->ds_rxstat.rs_rssi); - ieee80211_input(ni, m, + type = ieee80211_input(ni, m, ds->ds_rxstat.rs_rssi, ds->ds_rxstat.rs_tstamp); ieee80211_free_node(ni); } else - ieee80211_input_all(ic, m, + type = ieee80211_input_all(ic, m, ds->ds_rxstat.rs_rssi, ds->ds_rxstat.rs_tstamp); if (sc->sc_diversity) { @@ -3102,8 +3135,7 @@ * is mainly for station mode where we depend on * periodic beacon frames to trigger the poll event. */ - if (sc->sc_ipackets != ifp->if_ipackets) { - sc->sc_ipackets = ifp->if_ipackets; + if (type == IEEE80211_FC0_TYPE_DATA) { sc->sc_rxrate = ds->ds_rxstat.rs_rate; ath_led_event(sc, ATH_LED_RX); } else if (ticks - sc->sc_ledevent >= sc->sc_ledidle) @@ -3283,14 +3315,106 @@ ath_tx_cleanupq(sc, &sc->sc_txq[i]); } +/* + * Defragment an mbuf chain, returning at most maxfrags separate + * mbufs+clusters. If this is not possible NULL is returned and + * the original mbuf chain is left in it's present (potentially + * modified) state. We use two techniques: collapsing consecutive + * mbufs and replacing consecutive mbufs by a cluster. + */ +static struct mbuf * +ath_defrag(struct mbuf *m0, int how, int maxfrags) +{ + struct mbuf *m, *n, *n2, **prev; + u_int curfrags; + + /* + * Calculate the current number of frags. + */ + curfrags = 0; + for (m = m0; m != NULL; m = m->m_next) + curfrags++; + /* + * First, try to collapse mbufs. Note that we always collapse + * towards the front so we don't need to deal with moving the + * pkthdr. This may be suboptimal if the first mbuf has much + * less data than the following. + */ + m = m0; +again: + for (;;) { + n = m->m_next; + if (n == NULL) + break; + if ((m->m_flags & M_RDONLY) == 0 && + n->m_len < M_TRAILINGSPACE(m)) { + bcopy(mtod(n, void *), mtod(m, char *) + m->m_len, + n->m_len); + m->m_len += n->m_len; + m->m_next = n->m_next; + m_free(n); + if (--curfrags <= maxfrags) + return m0; + } else + m = n; + } + KASSERT(maxfrags > 1, + ("maxfrags %u, but normal collapse failed", maxfrags)); + /* + * Collapse consecutive mbufs to a cluster. + */ + prev = &m0->m_next; /* NB: not the first mbuf */ + while ((n = *prev) != NULL) { + if ((n2 = n->m_next) != NULL && + n->m_len + n2->m_len < MCLBYTES) { + m = m_getcl(how, MT_DATA, 0); + if (m == NULL) + goto bad; + bcopy(mtod(n, void *), mtod(m, void *), n->m_len); + bcopy(mtod(n2, void *), mtod(m, char *) + n->m_len, + n2->m_len); + m->m_len = n->m_len + n2->m_len; + m->m_next = n2->m_next; + *prev = m; + m_free(n); + m_free(n2); + if (--curfrags <= maxfrags) /* +1 cl -2 mbufs */ + return m0; + /* + * Still not there, try the normal collapse + * again before we allocate another cluster. + */ + goto again; + } + prev = &n->m_next; + } + /* + * No place where we can collapse to a cluster; punt. + * This can occur if, for example, you request 2 frags + * but the packet requires that both be clusters (we + * never reallocate the first mbuf to avoid moving the + * packet header). + */ +bad: + return NULL; +} + static int ath_tx_start(struct ath_softc *sc, struct ieee80211_node *ni, struct ath_buf *bf, struct mbuf *m0) { +#define CTS_DURATION \ + ath_hal_computetxtime(ah, rt, IEEE80211_ACK_LEN, cix, AH_TRUE) +#define updateCTSForBursting(_ah, _ds, _txq) \ + ath_hal_updateCTSForBursting(_ah, _ds, \ + _txq->axq_linkbuf != NULL ? _txq->axq_linkbuf->bf_desc : NULL, \ + _txq->axq_lastdsWithCTS, _txq->axq_gatingds, \ + txopLimit, CTS_DURATION) struct ieee80211com *ic = ni->ni_ic; struct ieee80211vap *vap = ni->ni_vap; struct ath_hal *ah = sc->sc_ah; struct ifnet *ifp = &sc->sc_if; + const struct chanAccParams *cap = &ic->ic_wme.wme_chanParams; int i, error, iswep, ismcast, keyix, hdrlen, pktlen, try0; u_int8_t rix, txrate, ctsrate; u_int8_t cix = 0xff; /* NB: silence compiler */ @@ -3302,6 +3426,8 @@ const HAL_RATE_TABLE *rt; HAL_BOOL shortPreamble; struct ath_node *an; + struct mbuf *m; + u_int pri; wh = mtod(m0, struct ieee80211_frame *); iswep = wh->i_fc[1] & IEEE80211_FC1_WEP; @@ -3330,6 +3456,7 @@ * 802.11 layer counts failures and provides * debugging/diagnostics. */ + m_freem(m0); return EIO; } /* @@ -3358,8 +3485,8 @@ * Load the DMA map so any coalescing is done. This * also calculates the number of descriptors we need. */ - error = bus_dmamap_load_mbuf(sc->sc_dmat, bf->bf_dmamap, m0, - ath_mbuf_load_cb, bf, + error = bus_dmamap_load_mbuf_sg(sc->sc_dmat, bf->bf_dmamap, m0, + bf->bf_segs, &bf->bf_nseg, BUS_DMA_NOWAIT); if (error == EFBIG) { /* XXX packet requires too many descriptors */ @@ -3376,14 +3503,15 @@ */ if (bf->bf_nseg > ATH_TXDESC) { /* too many desc's, linearize */ sc->sc_stats.ast_tx_linear++; - m0 = m_defrag(m0, M_DONTWAIT); - if (m0 == NULL) { + m = ath_defrag(m0, M_DONTWAIT, ATH_TXDESC); + if (m == NULL) { + m_freem(m0); sc->sc_stats.ast_tx_nombuf++; - m_freem(m0); return ENOMEM; } - error = bus_dmamap_load_mbuf(sc->sc_dmat, bf->bf_dmamap, m0, - ath_mbuf_load_cb, bf, + m0 = m; + error = bus_dmamap_load_mbuf_sg(sc->sc_dmat, bf->bf_dmamap, m0, + bf->bf_segs, &bf->bf_nseg, BUS_DMA_NOWAIT); if (error != 0) { sc->sc_stats.ast_tx_busdma++; @@ -3446,9 +3574,9 @@ /* NB: force all management frames to highest queue */ if (ni->ni_flags & IEEE80211_NODE_QOS) { /* NB: force all management frames to highest queue */ - txq = sc->sc_ac2q[WME_AC_VO]; + pri = WME_AC_VO; } else - txq = sc->sc_ac2q[WME_AC_BE]; + pri = WME_AC_BE; flags |= HAL_TXDESC_INTREQ; /* force interrupt */ break; case IEEE80211_FC0_TYPE_CTL: @@ -3462,9 +3590,9 @@ /* NB: force all ctl frames to highest queue */ if (ni->ni_flags & IEEE80211_NODE_QOS) { /* NB: force all ctl frames to highest queue */ - txq = sc->sc_ac2q[WME_AC_VO]; + pri = WME_AC_VO; } else - txq = sc->sc_ac2q[WME_AC_BE]; + pri = WME_AC_BE; flags |= HAL_TXDESC_INTREQ; /* force interrupt */ break; case IEEE80211_FC0_TYPE_DATA: @@ -3480,14 +3608,13 @@ * Default all non-QoS traffic to the best-effort queue. */ if (wh->i_fc[0] & IEEE80211_FC0_SUBTYPE_QOS) { - u_int pri = M_WME_GETAC(m0); - txq = sc->sc_ac2q[pri]; - if (ic->ic_wme.wme_wmeChanParams.cap_wmeParams[pri].wmep_noackPolicy) { + pri = M_WME_GETAC(m0); + if (cap->cap_wmeParams[pri].wmep_noackPolicy) { flags |= HAL_TXDESC_NOACK; sc->sc_stats.ast_tx_noack++; } } else - txq = sc->sc_ac2q[WME_AC_BE]; + pri = WME_AC_BE; break; default: if_printf(ifp, "bogus frame type 0x%x (%s)\n", @@ -3496,6 +3623,7 @@ m_freem(m0); return EIO; } + txq = sc->sc_ac2q[pri]; /* * When servicing one or more stations in power-save mode @@ -3606,7 +3734,7 @@ if (vap->iv_rawbpf) bpf_mtap(vap->iv_rawbpf, m0); if (sc->sc_drvbpf) { - sc->sc_tx_th.wt_flags = sc->sc_hwmap[txrate].flags; + sc->sc_tx_th.wt_flags = sc->sc_hwmap[txrate].txflags; if (iswep) sc->sc_tx_th.wt_flags |= IEEE80211_RADIOTAP_F_WEP; sc->sc_tx_th.wt_rate = sc->sc_hwmap[txrate].ieeerate; @@ -3686,27 +3814,44 @@ __func__, i, ds->ds_link, ds->ds_data, ds->ds_ctl0, ds->ds_ctl1, ds->ds_hw[0], ds->ds_hw[1]); } -#if 0 - if ((flags & (HAL_TXDESC_RTSENA | HAL_TXDESC_CTSENA)) && - !ath_hal_updateCTSForBursting(ah, ds - , txq->axq_linkbuf != NULL ? - txq->axq_linkbuf->bf_desc : NULL - , txq->axq_lastdsWithCTS - , txq->axq_gatingds - , IEEE80211_TXOP_TO_US(ic->ic_chanParams.cap_wmeParams[skb->priority].wmep_txopLimit) - , ath_hal_computetxtime(ah, rt, IEEE80211_ACK_LEN, cix, AH_TRUE))) { - ATH_TXQ_LOCK(txq); - txq->axq_lastdsWithCTS = ds; - /* set gating Desc to final desc */ - txq->axq_gatingds = (struct ath_desc *)txq->axq_link; - ATH_TXQ_UNLOCK(txq); - } -#endif /* * Insert the frame on the outbound list and * pass it on to the hardware. */ ATH_TXQ_LOCK(txq); + if (flags & (HAL_TXDESC_RTSENA | HAL_TXDESC_CTSENA)) { + u_int32_t txopLimit = IEEE80211_TXOP_TO_US( + cap->cap_wmeParams[pri].wmep_txopLimit); + /* + * When bursting, potentially extend the CTS duration + * of a previously queued frame to cover this frame + * and not exceed the txopLimit. If that can be done + * then disable RTS/CTS on this frame since it's now + * covered (burst extension). Otherwise we must terminate + * the burst before this frame goes out so as not to + * violate the WME parameters. All this is complicated + * as we need to update the state of packets on the + * (live) hardware queue. The logic is buried in the hal + * because it's highly chip-specific. + */ + if (txopLimit != 0) { + sc->sc_stats.ast_tx_ctsburst++; + if (updateCTSForBursting(ah, ds0, txq) == 0) { + /* + * This frame was not covered by RTS/CTS from + * the previous frame in the burst; update the + * descriptor pointers so this frame is now + * treated as the last frame for extending a + * burst. + */ + txq->axq_lastdsWithCTS = ds0; + /* set gating Desc to final desc */ + txq->axq_gatingds = + (struct ath_desc *)txq->axq_link; + } else + sc->sc_stats.ast_tx_ctsext++; + } + } ATH_TXQ_INSERT_TAIL(txq, bf, bf_list); if (txq->axq_link == NULL) { ath_hal_puttxbuf(ah, txq->axq_qnum, bf->bf_daddr); @@ -3722,15 +3867,17 @@ (caddr_t)bf->bf_daddr, bf->bf_desc, txq->axq_depth); } txq->axq_link = &bf->bf_desc[bf->bf_nseg - 1].ds_link; - ATH_TXQ_UNLOCK(txq); - /* * The CAB queue is started from the SWBA handler since * frames only go out on DTIM and to avoid possible races. */ if (txq != sc->sc_cabq) ath_hal_txstart(ah, txq->axq_qnum); + ATH_TXQ_UNLOCK(txq); + return 0; +#undef updateCTSForBursting +#undef CTS_DURATION } /* @@ -3741,7 +3888,7 @@ { struct ath_hal *ah = sc->sc_ah; struct ath_buf *bf; - struct ath_desc *ds; + struct ath_desc *ds, *ds0; struct ieee80211_node *ni; struct ath_node *an; int sr, lr, pri; @@ -3760,7 +3907,7 @@ ATH_TXQ_UNLOCK(txq); break; } - /* only the last descriptor is needed */ + ds0 = &bf->bf_desc[0]; ds = &bf->bf_desc[bf->bf_nseg - 1]; status = ath_hal_txprocdesc(ah, ds); #ifdef AR_DEBUG @@ -3771,12 +3918,10 @@ ATH_TXQ_UNLOCK(txq); break; } -#if 0 - if (bf->bf_desc == txq->axq_lastdsWithCTS) + if (ds0 == txq->axq_lastdsWithCTS) txq->axq_lastdsWithCTS = NULL; if (ds == txq->axq_gatingds) txq->axq_gatingds = NULL; -#endif ATH_TXQ_REMOVE_HEAD(txq, bf_list); ATH_TXQ_UNLOCK(txq); @@ -3814,7 +3959,7 @@ /* * Hand the descriptor to the rate control algorithm. */ - ath_rate_tx_complete(sc, an, ds); + ath_rate_tx_complete(sc, an, ds, ds0); /* * Reclaim reference to node. * @@ -4617,9 +4762,13 @@ } sc->sc_hwmap[i].ieeerate = rt->info[ix].dot11Rate & IEEE80211_RATE_VAL; + sc->sc_hwmap[i].txflags = IEEE80211_RADIOTAP_F_DATAPAD; if (rt->info[ix].shortPreamble || rt->info[ix].phy == IEEE80211_T_OFDM) - sc->sc_hwmap[i].flags |= IEEE80211_RADIOTAP_F_SHORTPRE; + sc->sc_hwmap[i].txflags |= IEEE80211_RADIOTAP_F_SHORTPRE; + /* NB: receive frames include FCS */ + sc->sc_hwmap[i].rxflags = sc->sc_hwmap[i].txflags | + IEEE80211_RADIOTAP_F_FCS; /* setup blink rate table to avoid per-packet lookup */ for (j = 0; j < N(blinkrates)-1; j++) if (blinkrates[j].rate == sc->sc_hwmap[i].ieeerate) @@ -5056,8 +5205,8 @@ sc->sc_tx_th.wt_ihdr.it_len = htole16(sc->sc_tx_th_len); sc->sc_tx_th.wt_ihdr.it_present = htole32(ATH_TX_RADIOTAP_PRESENT); - sc->sc_rx_rt_len = roundup(sizeof(sc->sc_rx_th), sizeof(u_int32_t)); - sc->sc_rx_th.wr_ihdr.it_len = htole16(sc->sc_rx_rt_len); + sc->sc_rx_th_len = roundup(sizeof(sc->sc_rx_th), sizeof(u_int32_t)); + sc->sc_rx_th.wr_ihdr.it_len = htole16(sc->sc_rx_th_len); sc->sc_rx_th.wr_ihdr.it_present = htole32(ATH_RX_RADIOTAP_PRESENT); } ==== //depot/projects/vap/sys/dev/ath/if_ath_pci.c#2 (text+ko) ==== @@ -35,7 +35,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath_pci.c,v 1.11 2005/01/18 18:08:16 sam Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath_pci.c,v 1.12 2005/03/05 19:06:12 imp Exp $"); /* * PCI/Cardbus front-end for the Atheros Wireless LAN controller driver. @@ -90,7 +90,7 @@ devname = ath_hal_probe(pci_get_vendor(dev), pci_get_device(dev)); if (devname != NULL) { device_set_desc(dev, devname); - return 0; + return BUS_PROBE_DEFAULT; } return ENXIO; } ==== //depot/projects/vap/sys/dev/ath/if_athioctl.h#2 (text+ko) ==== @@ -33,7 +33,7 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF * THE POSSIBILITY OF SUCH DAMAGES. * - * $FreeBSD: src/sys/dev/ath/if_athioctl.h,v 1.9 2004/12/31 22:41:45 sam Exp $ + * $FreeBSD: src/sys/dev/ath/if_athioctl.h,v 1.10 2005/03/30 20:13:08 sam Exp $ */ /* @@ -75,6 +75,8 @@ u_int32_t ast_tx_shortpre;/* tx frames with short preamble */ u_int32_t ast_tx_altrate; /* tx frames with alternate rate */ u_int32_t ast_tx_protect; /* tx frames with protection */ + u_int32_t ast_tx_ctsburst;/* tx frames with cts and bursting */ + u_int32_t ast_tx_ctsext; /* tx frames with cts extension */ u_int32_t ast_rx_nombuf; /* rx setup failed 'cuz no mbuf */ u_int32_t ast_rx_busdma; /* rx setup failed for dma resrcs */ u_int32_t ast_rx_orn; /* rx failed 'cuz of desc overrun */ ==== //depot/projects/vap/sys/dev/ath/if_athrate.h#3 (text+ko) ==== @@ -34,7 +34,7 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF * THE POSSIBILITY OF SUCH DAMAGES. * - * $FreeBSD: src/sys/dev/ath/if_athrate.h,v 1.2 2004/12/31 22:41:45 sam Exp $ + * $FreeBSD: src/sys/dev/ath/if_athrate.h,v 1.4 2005/04/02 18:54:30 sam Exp $ */ #ifndef _ATH_RATECTRL_H_ #define _ATH_RATECTRL_H_ @@ -121,14 +121,14 @@ * can be transmitted with multi-rate retry. */ void ath_rate_findrate(struct ath_softc *, struct ath_node *, - HAL_BOOL shortPreamble, size_t frameLen, + int shortPreamble, size_t frameLen, u_int8_t *rix, int *try0, u_int8_t *txrate); /* * Setup any extended (multi-rate) descriptor state for a data packet. * The rate index returned by ath_rate_findrate is passed back in. */ void ath_rate_setupxtxdesc(struct ath_softc *, struct ath_node *, - struct ath_desc *, HAL_BOOL shortPreamble, u_int8_t rix); + struct ath_desc *, int shortPreamble, u_int8_t rix); /* * Update rate control state for a packet associated with the * supplied transmit descriptor. The routine is invoked both @@ -136,5 +136,5 @@ * failed (consult the descriptor for details). */ void ath_rate_tx_complete(struct ath_softc *, struct ath_node *, - const struct ath_desc *); + const struct ath_desc *last, const struct ath_desc *first); #endif /* _ATH_RATECTRL_H_ */ ==== //depot/projects/vap/sys/dev/ath/if_athvar.h#4 (text+ko) ==== @@ -33,7 +33,7 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF * THE POSSIBILITY OF SUCH DAMAGES. * - * $FreeBSD: src/sys/dev/ath/if_athvar.h,v 1.19 2005/01/18 19:42:17 sam Exp $ + * $FreeBSD: src/sys/dev/ath/if_athvar.h,v 1.23 2005/04/12 17:56:43 sam Exp $ */ /* @@ -205,6 +205,7 @@ sc_hastpc : 1, /* per-packet TPC support */ sc_ledstate: 1, /* LED on/off state */ sc_blinking: 1, /* LED blink operation active */ + sc_mcastkey: 1, /* mcast key cache search */ sc_beacons : 1; /* beacons running */ >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Tue May 3 17:52:03 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E517916A4D0; Tue, 3 May 2005 17:52:02 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 791B816A4CE for ; Tue, 3 May 2005 17:52:02 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5035943D46 for ; Tue, 3 May 2005 17:52:02 +0000 (GMT) (envelope-from areisse@nailabs.com) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43HpwZb063679 for ; Tue, 3 May 2005 17:51:58 GMT (envelope-from areisse@nailabs.com) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43Hpwwt063676 for perforce@freebsd.org; Tue, 3 May 2005 17:51:58 GMT (envelope-from areisse@nailabs.com) Date: Tue, 3 May 2005 17:51:58 GMT Message-Id: <200505031751.j43Hpwwt063676@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to areisse@nailabs.com using -f From: Andrew Reisse To: Perforce Change Reviews Subject: PERFORCE change 76446 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 17:52:03 -0000 http://perforce.freebsd.org/chv.cgi?CH=76446 Change 76446 by areisse@areisse_tislabs on 2005/05/03 17:51:02 Fix some problems with the sebsd policy makefile: -Don't require genhomedircon to be executable, it's a shell script -Make the default target just build the policy, not install it. -Use policy version 17, as the netlink classes are unused. Affected files ... .. //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#18 edit Differences ... ==== //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#18 (text+ko) ==== @@ -9,7 +9,7 @@ # relabel - relabel filesystems based on the file contexts configuration. # policy - compile the policy configuration locally for testing/development. # -# The default target is 'install'. +# The default target builds the policy and file_contexts, but doesn't install. # # Set to y if MLS is enabled in the module. @@ -20,7 +20,7 @@ LOADPOLICY = $(DESTDIR)/sbin/sebsd_loadpolicy CHECKPOLICY = $(DESTDIR)/sbin/sebsd_checkpolicy SETFILES = $(DESTDIR)/sbin/sebsd_setfiles -POLICYVERTMP != ($(CHECKPOLICY) $(POLICYCOMPAT) -V |cut -f 1 -d ' ') +POLICYVERTMP = 17 POLICYVER := policy.$(POLICYVERTMP) INSTALLDIR = $(DESTDIR)/etc/security/sebsd POLICYPATH = $(INSTALLDIR)/policy @@ -66,6 +66,8 @@ APPFILES = $(APPDIR)/default_contexts $(APPDIR)/default_type $(APPDIR)/initrc_context # $(APPDIR)/userhelper_context $(APPDIR)/failsafe_context ROOTFILES = # $(APPDIR)/users/root +default: $(POLICYVER) $(FC) + install: $(APPFILES) $(ROOTFILES) $(LOADPATH) $(FCPATH) $(APPDIR)/default_contexts: appconfig/default_contexts @@ -152,7 +154,7 @@ @echo "Building file_contexts ..." @m4 $(ALL_TUNABLES) $(FCFILES) > $@.tmp @grep -v "^/root" $@.tmp > $@.root - ./genhomedircon $@.root > $@ + @sh ./genhomedircon $@.root > $@ @grep "^/root" $@.tmp >> $@ @-rm $@.tmp $@.root From owner-p4-projects@FreeBSD.ORG Tue May 3 20:40:34 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id AEB9916A4D1; Tue, 3 May 2005 20:40:33 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3FE8716A4CE for ; Tue, 3 May 2005 20:40:33 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C098943D7C for ; Tue, 3 May 2005 20:40:32 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43KeR83071557 for ; Tue, 3 May 2005 20:40:27 GMT (envelope-from jhb@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43KeQlU071553 for perforce@freebsd.org; Tue, 3 May 2005 20:40:26 GMT (envelope-from jhb@freebsd.org) Date: Tue, 3 May 2005 20:40:26 GMT Message-Id: <200505032040.j43KeQlU071553@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to jhb@freebsd.org using -f From: John Baldwin To: Perforce Change Reviews Subject: PERFORCE change 76456 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 20:40:34 -0000 http://perforce.freebsd.org/chv.cgi?CH=76456 Change 76456 by jhb@jhb_slimer on 2005/05/03 20:40:16 Rework long support by casting the pointer to make gcc happy. Affected files ... .. //depot/projects/smpng/sys/i386/include/atomic.h#31 edit Differences ... ==== //depot/projects/smpng/sys/i386/include/atomic.h#31 (text+ko) ==== @@ -301,6 +301,17 @@ #define atomic_cmpset_acq_int atomic_cmpset_int #define atomic_cmpset_rel_int atomic_cmpset_int +#define atomic_set_acq_long atomic_set_long +#define atomic_set_rel_long atomic_set_long +#define atomic_clear_acq_long atomic_clear_long +#define atomic_clear_rel_long atomic_clear_long +#define atomic_add_acq_long atomic_add_long +#define atomic_add_rel_long atomic_add_long +#define atomic_subtract_acq_long atomic_subtract_long +#define atomic_subtract_rel_long atomic_subtract_long +#define atomic_cmpset_acq_long atomic_cmpset_long +#define atomic_cmpset_rel_long atomic_cmpset_long + /* Read the current value and store a zero in the destination. */ #ifdef __GNUCLIKE_ASM @@ -320,25 +331,8 @@ return (result); } -static __inline u_long -atomic_readandclear_long(volatile u_long *addr) -{ - u_long result; - - __asm __volatile ( - " xorl %0,%0 ; " - " xchgl %1,%0 ; " - "# atomic_readandclear_int" - : "=&r" (result), /* 0 (result) */ - "=m" (*addr) /* 1 (addr) */ - : "m" (*addr)); /* 2 (addr) */ - - return (result); -} - #else /* !__GNUCLIKE_ASM */ -extern u_long atomic_readandclear_long(volatile u_long *); extern u_int atomic_readandclear_int(volatile u_int *); #endif /* __GNUCLIKE_ASM */ @@ -396,24 +390,14 @@ #define atomic_readandclear_32 atomic_readandclear_int /* Operations on longs. */ -#define atomic_set_long atomic_set_int -#define atomic_set_acq_long atomic_set_acq_int -#define atomic_set_rel_long atomic_set_rel_int -#define atomic_clear_long atomic_clear_int -#define atomic_clear_acq_long atomic_clear_acq_int -#define atomic_clear_rel_long atomic_clear_rel_int -#define atomic_add_long atomic_add_int -#define atomic_add_acq_long atomic_add_acq_int -#define atomic_add_rel_long atomic_add_rel_int -#define atomic_subtract_long atomic_subtract_int -#define atomic_subtract_acq_long atomic_subtract_acq_int -#define atomic_subtract_rel_long atomic_subtract_rel_int -#define atomic_cmpset_long atomic_cmpset_int -#define atomic_cmpset_acq_long atomic_cmpset_acq_int -#define atomic_cmpset_rel_long atomic_cmpset_rel_int -#define atomic_load_acq_long atomic_load_acq_int -#define atomic_store_rel_long atomic_store_rel_int -#define atomic_readandclear_long atomic_readandclear_int +#define atomic_set_long(p, v) atomic_set_int((u_int *)(p), (v)) +#define atomic_clear_long(p, v) atomic_clear_int((u_int *)(p), (v)) +#define atomic_add_long(p, v) atomic_add_int((u_int *)(p), (v)) +#define atomic_subtract_long(p, v) atomic_subtract_int((u_int *)(p), (v)) +#define atomic_cmpset_long(d, e, s) atomic_cmpset_int((u_int *)(d), (e), (s)) +#define atomic_load_acq_long(p) atomic_load_acq_int((u_int *)(p)) +#define atomic_store_rel_long(p, v) atomic_store_rel_int((u_int *)(p), (v)) +#define atomic_readandclear_long(p) atomic_readandclear_int((u_int *)(p)) /* Operations on pointers. */ #define atomic_set_ptr atomic_set_int From owner-p4-projects@FreeBSD.ORG Tue May 3 20:41:38 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id F343616A4D0; Tue, 3 May 2005 20:41:37 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CD17316A4CE for ; Tue, 3 May 2005 20:41:37 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B2EF843D53 for ; Tue, 3 May 2005 20:41:37 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43KfSTn071616 for ; Tue, 3 May 2005 20:41:28 GMT (envelope-from jhb@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43KfSjr071613 for perforce@freebsd.org; Tue, 3 May 2005 20:41:28 GMT (envelope-from jhb@freebsd.org) Date: Tue, 3 May 2005 20:41:28 GMT Message-Id: <200505032041.j43KfSjr071613@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to jhb@freebsd.org using -f From: John Baldwin To: Perforce Change Reviews Subject: PERFORCE change 76457 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 20:41:38 -0000 http://perforce.freebsd.org/chv.cgi?CH=76457 Change 76457 by jhb@jhb_slimer on 2005/05/03 20:40:51 Catch up to new atomic_foo_ptr() parameter types. Affected files ... .. //depot/projects/smpng/sys/dev/hatm/if_hatm_intr.c#10 edit Differences ... ==== //depot/projects/smpng/sys/dev/hatm/if_hatm_intr.c#10 (text+ko) ==== @@ -115,7 +115,8 @@ { for (;;) { buf->link = *list; - if (atomic_cmpset_ptr(list, buf->link, buf)) + if (atomic_cmpset_ptr((uintptr_t *)list, (uintptr_t)buf->link, + (uintptr_t)buf)) break; } } @@ -128,7 +129,8 @@ for (;;) { if ((buf = sc->mbuf_list[g]) == NULL) break; - if (atomic_cmpset_ptr(&sc->mbuf_list[g], buf, buf->link)) + if (atomic_cmpset_ptr((uintptr_t *)&sc->mbuf_list[g], + (uintptr_t)buf, (uintptr_t)buf->link)) break; } if (buf == NULL) { @@ -136,7 +138,8 @@ for (;;) { if ((buf = sc->mbuf_list[g]) == NULL) break; - if (atomic_cmpset_ptr(&sc->mbuf_list[g], buf, buf->link)) + if (atomic_cmpset_ptr((uintptr_t *)&sc->mbuf_list[g], + (uintptr_t)buf, (uintptr_t)buf->link)) break; } } From owner-p4-projects@FreeBSD.ORG Tue May 3 21:34:44 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id DD31516A4CF; Tue, 3 May 2005 21:34:43 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 83D7216A4D2 for ; Tue, 3 May 2005 21:34:43 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9CF7143D79 for ; Tue, 3 May 2005 21:34:41 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43LYaSn080806 for ; Tue, 3 May 2005 21:34:36 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43LYZbQ080791 for perforce@freebsd.org; Tue, 3 May 2005 21:34:35 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 3 May 2005 21:34:35 GMT Message-Id: <200505032134.j43LYZbQ080791@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76463 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 21:34:45 -0000 http://perforce.freebsd.org/chv.cgi?CH=76463 Change 76463 by rwatson@rwatson_tislabs on 2005/05/03 21:34:07 pf update ipfilter update powerd ipi spin lock amd64 fix kdb stop nmi yet more ata much vfs locking ksem.h uma critical sections Affected files ... .. //depot/projects/trustedbsd/base/Makefile.inc1#60 integrate .. //depot/projects/trustedbsd/base/UPDATING#54 integrate .. //depot/projects/trustedbsd/base/bin/ps/ps.1#23 integrate .. //depot/projects/trustedbsd/base/contrib/bsnmp/snmpd/main.c#8 integrate .. //depot/projects/trustedbsd/base/contrib/ipfilter/lib/printstate.c#2 integrate .. //depot/projects/trustedbsd/base/contrib/ipfilter/tools/ippool.c#2 integrate .. //depot/projects/trustedbsd/base/contrib/pf/authpf/authpf.8#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/authpf/authpf.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/authpf/pathnames.h#2 integrate .. //depot/projects/trustedbsd/base/contrib/pf/ftp-proxy/ftp-proxy.8#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/ftp-proxy/ftp-proxy.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/ftp-proxy/getline.c#2 integrate .. //depot/projects/trustedbsd/base/contrib/pf/ftp-proxy/util.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/ftp-proxy/util.h#2 integrate .. //depot/projects/trustedbsd/base/contrib/pf/man/pf.4#7 integrate .. //depot/projects/trustedbsd/base/contrib/pf/man/pf.conf.5#6 integrate .. //depot/projects/trustedbsd/base/contrib/pf/man/pf.os.5#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/man/pflog.4#5 integrate .. //depot/projects/trustedbsd/base/contrib/pf/man/pfsync.4#6 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/parse.y#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pf_print_state.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl.8#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl.h#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_altq.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_optimize.c#1 branch .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_osfp.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_parser.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_parser.h#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_qstats.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_radix.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pfctl/pfctl_table.c#4 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pflogd/pflogd.8#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pflogd/pflogd.c#4 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pflogd/pidfile.c#3 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pflogd/privsep.c#2 integrate .. //depot/projects/trustedbsd/base/contrib/pf/pflogd/privsep_fdpass.c#2 integrate .. //depot/projects/trustedbsd/base/etc/Makefile#42 integrate .. //depot/projects/trustedbsd/base/etc/rc#27 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/Makefile#27 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/initdiskless#19 delete .. //depot/projects/trustedbsd/base/etc/rc.d/jail#9 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/preseedrandom#5 delete .. //depot/projects/trustedbsd/base/etc/rc.d/rcconf.sh#4 integrate .. //depot/projects/trustedbsd/base/etc/rc.initdiskless#2 integrate .. //depot/projects/trustedbsd/base/games/caesar/Makefile#2 integrate .. //depot/projects/trustedbsd/base/games/caesar/caesar.c#4 integrate .. //depot/projects/trustedbsd/base/games/pom/Makefile#2 integrate .. //depot/projects/trustedbsd/base/games/pom/pom.c#4 integrate .. //depot/projects/trustedbsd/base/gnu/lib/libobjc/Makefile#11 integrate .. //depot/projects/trustedbsd/base/lib/libc/gen/getbootfile.c#4 integrate .. //depot/projects/trustedbsd/base/lib/libc/gen/getgrouplist.c#7 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getaddrinfo.3#9 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getaddrinfo.c#19 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/gethostbydns.c#14 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/gethostbyht.c#6 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/gethostbyname.3#9 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/gethostbynis.c#7 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/gethostnamadr.c#7 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getipnodebyname.3#7 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getnameinfo.3#7 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getnameinfo.c#6 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getnetbydns.c#8 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getnetbyht.c#6 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getnetbynis.c#4 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getnetent.3#5 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getnetnamadr.c#5 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getprotoent.c#5 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/getservent.c#9 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/map_v4v6.c#4 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/name6.c#19 integrate .. //depot/projects/trustedbsd/base/lib/libc/net/netdb_private.h#4 integrate .. //depot/projects/trustedbsd/base/lib/libc/yp/yplib.c#9 integrate .. //depot/projects/trustedbsd/base/lib/libpmc/Makefile#2 integrate .. //depot/projects/trustedbsd/base/lib/libpmc/libpmc.c#2 integrate .. //depot/projects/trustedbsd/base/lib/libpmc/pmc.3#2 integrate .. //depot/projects/trustedbsd/base/lib/libpmc/pmc.h#2 integrate .. //depot/projects/trustedbsd/base/lib/libthr/Makefile#8 integrate .. //depot/projects/trustedbsd/base/lib/libthr/arch/i386/i386/pthread_md.c#3 integrate .. //depot/projects/trustedbsd/base/lib/libthr/arch/i386/include/pthread_md.h#2 integrate .. //depot/projects/trustedbsd/base/lib/libthr/support/Makefile.inc#1 branch .. //depot/projects/trustedbsd/base/lib/libthr/thread/thr_create.c#10 integrate .. //depot/projects/trustedbsd/base/lib/msun/src/s_ceill.c#3 integrate .. //depot/projects/trustedbsd/base/lib/msun/src/s_floorl.c#3 integrate .. //depot/projects/trustedbsd/base/lib/msun/src/s_truncl.c#3 integrate .. //depot/projects/trustedbsd/base/release/Makefile#64 integrate .. //depot/projects/trustedbsd/base/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#90 integrate .. //depot/projects/trustedbsd/base/release/doc/zh_CN.GB2312/relnotes/common/new.sgml#4 integrate .. //depot/projects/trustedbsd/base/release/scripts/package-split.py#3 integrate .. //depot/projects/trustedbsd/base/release/scripts/package-trees.sh#2 integrate .. //depot/projects/trustedbsd/base/rescue/rescue/Makefile#14 integrate .. //depot/projects/trustedbsd/base/sbin/atm/atm/atm.h#4 integrate .. //depot/projects/trustedbsd/base/sbin/atm/atmconfig/atmconfig_device.h#2 integrate .. //depot/projects/trustedbsd/base/sbin/atm/ilmid/ilmid.c#11 integrate .. //depot/projects/trustedbsd/base/sbin/dump/traverse.c#18 integrate .. //depot/projects/trustedbsd/base/sbin/fdisk/fdisk.c#22 integrate .. //depot/projects/trustedbsd/base/sbin/fdisk_pc98/Makefile#5 integrate .. //depot/projects/trustedbsd/base/sbin/fdisk_pc98/fdisk.c#11 integrate .. //depot/projects/trustedbsd/base/sbin/geom/core/geom.c#5 integrate .. //depot/projects/trustedbsd/base/sbin/ggate/shared/ggate.h#3 integrate .. //depot/projects/trustedbsd/base/sbin/ifconfig/ifpfsync.c#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/ipf/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/ipftest/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/ipmon/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/ipnat/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/ippool/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/ipresend/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/ipsend/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/ipf/libipf/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sbin/natd/natd.c#13 integrate .. //depot/projects/trustedbsd/base/sbin/pfctl/Makefile#4 integrate .. //depot/projects/trustedbsd/base/share/man/man4/ath.4#16 integrate .. //depot/projects/trustedbsd/base/share/man/man4/hwpmc.4#2 integrate .. //depot/projects/trustedbsd/base/share/man/man5/rc.conf.5#47 integrate .. //depot/projects/trustedbsd/base/share/man/man9/taskqueue.9#12 integrate .. //depot/projects/trustedbsd/base/share/mk/sys.mk#21 integrate .. //depot/projects/trustedbsd/base/sys/amd64/amd64/mp_machdep.c#9 integrate .. //depot/projects/trustedbsd/base/sys/amd64/amd64/trap.c#16 integrate .. //depot/projects/trustedbsd/base/sys/amd64/conf/NOTES#7 integrate .. //depot/projects/trustedbsd/base/sys/amd64/include/smp.h#6 integrate .. //depot/projects/trustedbsd/base/sys/conf/NOTES#59 integrate .. //depot/projects/trustedbsd/base/sys/conf/files#84 integrate .. //depot/projects/trustedbsd/base/sys/conf/files.amd64#20 integrate .. //depot/projects/trustedbsd/base/sys/conf/files.i386#51 integrate .. //depot/projects/trustedbsd/base/sys/conf/files.pc98#45 integrate .. //depot/projects/trustedbsd/base/sys/conf/kern.post.mk#41 integrate .. //depot/projects/trustedbsd/base/sys/conf/options#59 integrate .. //depot/projects/trustedbsd/base/sys/conf/options.amd64#9 integrate .. //depot/projects/trustedbsd/base/sys/conf/options.i386#27 integrate .. //depot/projects/trustedbsd/base/sys/conf/options.pc98#29 integrate .. //depot/projects/trustedbsd/base/sys/contrib/ipfilter/netinet/ip_compat.h#12 integrate .. //depot/projects/trustedbsd/base/sys/contrib/ipfilter/netinet/ip_frag.c#10 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/if_pflog.c#7 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/if_pflog.h#3 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/if_pfsync.c#7 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/if_pfsync.h#3 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pf.c#12 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pf_if.c#5 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pf_ioctl.c#8 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pf_norm.c#5 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pf_osfp.c#3 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pf_subr.c#2 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pf_table.c#3 integrate .. //depot/projects/trustedbsd/base/sys/contrib/pf/net/pfvar.h#4 integrate .. //depot/projects/trustedbsd/base/sys/dev/aac/aac_disk.c#20 integrate .. //depot/projects/trustedbsd/base/sys/dev/arcmsr/arcmsr.c#2 integrate .. //depot/projects/trustedbsd/base/sys/dev/asr/asr.c#24 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-all.c#44 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-all.h#25 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-card.c#26 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-cbus.c#15 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-chipset.c#24 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-disk.c#35 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-dma.c#34 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-isa.c#19 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-lowlevel.c#14 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-pci.c#38 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-pci.h#19 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-queue.c#14 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-raid.c#29 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata-raid.h#19 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/ata_if.m#2 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/atapi-cam.c#21 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/atapi-cd.c#34 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/atapi-fd.c#24 integrate .. //depot/projects/trustedbsd/base/sys/dev/ata/atapi-tape.c#24 integrate .. //depot/projects/trustedbsd/base/sys/dev/ciss/ciss.c#28 integrate .. //depot/projects/trustedbsd/base/sys/dev/hwpmc/hwpmc_amd.c#3 integrate .. //depot/projects/trustedbsd/base/sys/dev/hwpmc/hwpmc_intel.c#2 integrate .. //depot/projects/trustedbsd/base/sys/dev/hwpmc/hwpmc_mod.c#3 integrate .. //depot/projects/trustedbsd/base/sys/dev/hwpmc/hwpmc_piv.c#3 integrate .. //depot/projects/trustedbsd/base/sys/dev/hwpmc/hwpmc_ppro.c#3 integrate .. //depot/projects/trustedbsd/base/sys/dev/pci/pci.c#40 integrate .. //depot/projects/trustedbsd/base/sys/dev/pci/pci_pci.c#22 integrate .. //depot/projects/trustedbsd/base/sys/dev/pci/pcireg.h#8 integrate .. //depot/projects/trustedbsd/base/sys/dev/pci/pcivar.h#15 integrate .. //depot/projects/trustedbsd/base/sys/dev/twa/tw_osl_cam.c#2 integrate .. //depot/projects/trustedbsd/base/sys/fs/devfs/devfs_vfsops.c#19 integrate .. //depot/projects/trustedbsd/base/sys/fs/devfs/devfs_vnops.c#35 integrate .. //depot/projects/trustedbsd/base/sys/fs/pseudofs/pseudofs_vnops.c#26 integrate .. //depot/projects/trustedbsd/base/sys/fs/unionfs/union_vnops.c#24 integrate .. //depot/projects/trustedbsd/base/sys/geom/geom_pc98_enc.c#3 integrate .. //depot/projects/trustedbsd/base/sys/geom/vinum/geom_vinum_init.c#4 integrate .. //depot/projects/trustedbsd/base/sys/i386/conf/NOTES#55 integrate .. //depot/projects/trustedbsd/base/sys/i386/conf/PAE#10 integrate .. //depot/projects/trustedbsd/base/sys/i386/i386/mp_machdep.c#40 integrate .. //depot/projects/trustedbsd/base/sys/i386/i386/trap.c#38 integrate .. //depot/projects/trustedbsd/base/sys/i386/include/pmc_mdep.h#3 integrate .. //depot/projects/trustedbsd/base/sys/i386/include/smp.h#14 integrate .. //depot/projects/trustedbsd/base/sys/kern/imgact_aout.c#17 integrate .. //depot/projects/trustedbsd/base/sys/kern/imgact_elf.c#31 integrate .. //depot/projects/trustedbsd/base/sys/kern/kern_descrip.c#55 integrate .. //depot/projects/trustedbsd/base/sys/kern/kern_exec.c#51 integrate .. //depot/projects/trustedbsd/base/sys/kern/subr_devstat.c#13 integrate .. //depot/projects/trustedbsd/base/sys/kern/subr_kdb.c#5 integrate .. //depot/projects/trustedbsd/base/sys/kern/subr_smp.c#23 integrate .. //depot/projects/trustedbsd/base/sys/kern/subr_taskqueue.c#14 integrate .. //depot/projects/trustedbsd/base/sys/kern/uipc_sem.c#12 integrate .. //depot/projects/trustedbsd/base/sys/kern/vfs_aio.c#41 integrate .. //depot/projects/trustedbsd/base/sys/kern/vfs_bio.c#50 integrate .. //depot/projects/trustedbsd/base/sys/kern/vfs_cluster.c#30 integrate .. //depot/projects/trustedbsd/base/sys/kern/vfs_default.c#32 integrate .. //depot/projects/trustedbsd/base/sys/kern/vfs_mount.c#37 integrate .. //depot/projects/trustedbsd/base/sys/kern/vfs_subr.c#62 integrate .. //depot/projects/trustedbsd/base/sys/netinet/tcp_usrreq.c#26 integrate .. //depot/projects/trustedbsd/base/sys/nfsclient/nfs_vfsops.c#39 integrate .. //depot/projects/trustedbsd/base/sys/pc98/conf/NOTES#23 integrate .. //depot/projects/trustedbsd/base/sys/posix4/ksem.h#1 branch .. //depot/projects/trustedbsd/base/sys/powerpc/conf/GENERIC#26 integrate .. //depot/projects/trustedbsd/base/sys/powerpc/powermac/ata_kauai.c#9 integrate .. //depot/projects/trustedbsd/base/sys/powerpc/powermac/ata_macio.c#16 integrate .. //depot/projects/trustedbsd/base/sys/sys/diskpc98.h#9 integrate .. //depot/projects/trustedbsd/base/sys/sys/param.h#45 integrate .. //depot/projects/trustedbsd/base/sys/sys/pmc.h#3 integrate .. //depot/projects/trustedbsd/base/sys/sys/ptrace.h#9 integrate .. //depot/projects/trustedbsd/base/sys/sys/smp.h#11 integrate .. //depot/projects/trustedbsd/base/sys/sys/taskqueue.h#7 integrate .. //depot/projects/trustedbsd/base/sys/ufs/ffs/ffs_rawread.c#14 integrate .. //depot/projects/trustedbsd/base/sys/ufs/ffs/ffs_softdep.c#33 integrate .. //depot/projects/trustedbsd/base/sys/vm/swap_pager.c#38 integrate .. //depot/projects/trustedbsd/base/sys/vm/uma_core.c#36 integrate .. //depot/projects/trustedbsd/base/sys/vm/uma_int.h#17 integrate .. //depot/projects/trustedbsd/base/sys/vm/vm_fault.c#36 integrate .. //depot/projects/trustedbsd/base/sys/vm/vm_map.c#42 integrate .. //depot/projects/trustedbsd/base/sys/vm/vm_object.c#52 integrate .. //depot/projects/trustedbsd/base/sys/vm/vm_object.h#23 integrate .. //depot/projects/trustedbsd/base/sys/vm/vnode_pager.c#41 integrate .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/README#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/all.sh#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t0/Makefile#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t0/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t0/libtest.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t0/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t1/Makefile#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t1/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t1/libtest.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t1/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t2/Makefile#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t2/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t2/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t2/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t2/libtest.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/archives/t2/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t0/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t0/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t1/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t1/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t2/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t2/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t2/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t2/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t3/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t3/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t3/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/basic/t3/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/common.sh#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t0/Makefile#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t0/TEST1.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t0/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t0/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t1/Makefile#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t1/TEST1.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t1/TEST2.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t1/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t1/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t2/Makefile#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t2/TEST1.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t2/TEST2.a#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t2/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t2/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t2/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/suffixes/t2/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t0/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t0/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t1/expected.status#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/base/tools/regression/usr.bin/make/variables/t1/test.t#1 branch .. //depot/projects/trustedbsd/base/tools/tools/tinderbox/etc/default.rc#4 integrate .. //depot/projects/trustedbsd/base/tools/tools/tinderbox/tinderbox.pl#13 integrate .. //depot/projects/trustedbsd/base/usr.bin/Makefile#41 integrate .. //depot/projects/trustedbsd/base/usr.bin/brandelf/brandelf.c#5 integrate .. //depot/projects/trustedbsd/base/usr.bin/compress/zopen.c#6 integrate .. //depot/projects/trustedbsd/base/usr.bin/id/id.1#5 integrate .. //depot/projects/trustedbsd/base/usr.bin/id/id.c#10 integrate .. //depot/projects/trustedbsd/base/usr.bin/make/Makefile#14 integrate .. //depot/projects/trustedbsd/base/usr.bin/make/cond.c#13 integrate .. //depot/projects/trustedbsd/base/usr.bin/make/directive_hash.c#2 delete .. //depot/projects/trustedbsd/base/usr.bin/make/directive_hash.h#2 delete .. //depot/projects/trustedbsd/base/usr.bin/make/globals.h#3 integrate .. //depot/projects/trustedbsd/base/usr.bin/make/hash_tables.c#1 branch .. //depot/projects/trustedbsd/base/usr.bin/make/hash_tables.h#1 branch .. //depot/projects/trustedbsd/base/usr.bin/make/main.c#27 integrate .. //depot/projects/trustedbsd/base/usr.bin/make/make.h#8 integrate .. //depot/projects/trustedbsd/base/usr.bin/make/nonints.h#12 integrate .. //depot/projects/trustedbsd/base/usr.bin/make/parse.c#21 integrate .. //depot/projects/trustedbsd/base/usr.bin/mkuzip/Makefile#2 integrate .. //depot/projects/trustedbsd/base/usr.bin/mkuzip/mkuzip.c#2 integrate .. //depot/projects/trustedbsd/base/usr.bin/rs/rs.c#6 integrate .. //depot/projects/trustedbsd/base/usr.bin/systat/pigs.c#7 integrate .. //depot/projects/trustedbsd/base/usr.sbin/adduser/adduser.sh#11 integrate .. //depot/projects/trustedbsd/base/usr.sbin/authpf/Makefile#2 integrate .. //depot/projects/trustedbsd/base/usr.sbin/burncd/burncd.8#18 integrate .. //depot/projects/trustedbsd/base/usr.sbin/faithd/ftp.c#6 integrate .. //depot/projects/trustedbsd/base/usr.sbin/jail/jail.8#21 integrate .. //depot/projects/trustedbsd/base/usr.sbin/pmccontrol/pmccontrol.c#2 integrate .. //depot/projects/trustedbsd/base/usr.sbin/pmcstat/pmcstat.c#2 integrate .. //depot/projects/trustedbsd/base/usr.sbin/ppp/ppp.8.m4#21 integrate .. //depot/projects/trustedbsd/base/usr.sbin/rpc.yppasswdd/yppasswdd_main.c#7 integrate .. //depot/projects/trustedbsd/base/usr.sbin/sysinstall/dist.c#28 integrate .. //depot/projects/trustedbsd/base/usr.sbin/sysinstall/menus.c#40 integrate .. //depot/projects/trustedbsd/base/usr.sbin/ypserv/Makefile.yp#5 integrate .. //depot/projects/trustedbsd/base/usr.sbin/ypserv/yp_dnslookup.c#6 integrate .. //depot/projects/trustedbsd/base/usr.sbin/ypserv/yp_extern.h#3 integrate .. //depot/projects/trustedbsd/base/usr.sbin/ypserv/yp_server.c#5 integrate Differences ... ==== //depot/projects/trustedbsd/base/Makefile.inc1#60 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.492 2005/04/06 01:55:43 peter Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.494 2005/05/01 17:36:09 imp Exp $ # # Make command line options: # -DNO_DYNAMICROOT do not link /bin and /sbin dynamically ==== //depot/projects/trustedbsd/base/UPDATING#54 (text+ko) ==== @@ -21,6 +21,11 @@ developers choose to disable these features on build machines to maximize performance. +20050503: + The packet filter (pf) code has been updated to OpenBSD 3.7 + Please note the changed anchor syntax and the fact that + authpf(8) now needs a mounted fdescfs(5) to function. + 20050415: The NO_MIXED_MODE kernel option has been removed from the i386 amd64 platforms as its use has been superceded by the new local @@ -331,4 +336,4 @@ Contact Warner Losh if you have any questions about your use of this document. -$FreeBSD: src/UPDATING,v 1.401 2005/04/18 14:33:18 scottl Exp $ +$FreeBSD: src/UPDATING,v 1.402 2005/05/03 17:43:13 mlaier Exp $ ==== //depot/projects/trustedbsd/base/bin/ps/ps.1#23 (text+ko) ==== @@ -27,7 +27,7 @@ .\" SUCH DAMAGE. .\" .\" @(#)ps.1 8.3 (Berkeley) 4/18/94 -.\" $FreeBSD: src/bin/ps/ps.1,v 1.85 2005/03/20 10:40:36 pjd Exp $ +.\" $FreeBSD: src/bin/ps/ps.1,v 1.86 2005/04/29 11:10:27 maxim Exp $ .\" .Dd March 20, 2005 .Dt PS 1 @@ -103,7 +103,7 @@ .Bl -tag -width indent .It Fl a Display information about other users' processes as well as your own. -This will skip any processes which do not have a controlling teminal, +This will skip any processes which do not have a controlling terminal, unless the .Fl x option is also specified. ==== //depot/projects/trustedbsd/base/contrib/bsnmp/snmpd/main.c#8 (text+ko) ==== @@ -1634,9 +1634,7 @@ timer_start(u_int ticks, void (*func)(void *), void *udata, struct lmodule *mod) { struct timer *tp; -#ifdef USE_LIBBEGEMOT - struct timeval due; -#else +#ifndef USE_LIBBEGEMOT struct timespec due; #endif @@ -1644,15 +1642,8 @@ syslog(LOG_CRIT, "out of memory for timer"); exit(1); } -#ifdef USE_LIBBEGEMOT - (void)gettimeofday(&due, NULL); - due.tv_sec += ticks / 100; - due.tv_usec += (ticks % 100) * 10000; - if (due.tv_usec >= 1000000) { - due.tv_sec++; - due.tv_usec -= 1000000; - } -#else + +#ifndef USE_LIBBEGEMOT due = evAddTime(evNowTime(), evConsTime(ticks / 100, (ticks % 100) * 10000)); #endif @@ -1664,8 +1655,7 @@ LIST_INSERT_HEAD(&timer_list, tp, link); #ifdef USE_LIBBEGEMOT - if ((tp->id = poll_start_timer(due.tv_sec * 1000 + due.tv_usec / 1000, - 0, tfunc, tp)) < 0) { + if ((tp->id = poll_start_timer(ticks * 10, 0, tfunc, tp)) < 0) { syslog(LOG_ERR, "cannot set timer: %m"); exit(1); } ==== //depot/projects/trustedbsd/base/contrib/ipfilter/lib/printstate.c#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/contrib/ipfilter/lib/printstate.c,v 1.2 2005/04/25 18:20:12 darrenr Exp $ */ +/* $FreeBSD: src/contrib/ipfilter/lib/printstate.c,v 1.3 2005/04/28 21:36:30 darrenr Exp $ */ /* * Copyright (C) 2002 by Darren Reed. @@ -64,7 +64,7 @@ ips.is_icmp.ici_seq, ips.is_icmp.ici_type); #ifdef USE_QUAD_T - PRINTF("\tforward: pkts in %qd bytes in %qd pkts out %qd bytes out %qd\n\tbackward: pkts in %qd bytes in %qd pkts out %qd bytes out %qd\n", + PRINTF("\tforward: pkts in %lld bytes in %lld pkts out %lld bytes out %lld\n\tbackward: pkts in %lld bytes in %lld pkts out %lld bytes out %lld\n", ips.is_pkts[0], ips.is_bytes[0], ips.is_pkts[1], ips.is_bytes[1], ips.is_pkts[2], ips.is_bytes[2], ==== //depot/projects/trustedbsd/base/contrib/ipfilter/tools/ippool.c#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/contrib/ipfilter/tools/ippool.c,v 1.2 2005/04/25 18:20:15 darrenr Exp $ */ +/* $FreeBSD: src/contrib/ipfilter/tools/ippool.c,v 1.3 2005/04/28 16:26:33 darrenr Exp $ */ /* * Copyright (C) 2003 by Darren Reed. @@ -639,7 +639,7 @@ } } - printf("%u object%s flushed\n", flush.iplf_count, + printf("%zd object%s flushed\n", flush.iplf_count, (flush.iplf_count == 1) ? "" : "s"); return 0; ==== //depot/projects/trustedbsd/base/contrib/pf/authpf/authpf.8#3 (text+ko) ==== @@ -1,4 +1,4 @@ -.\" $OpenBSD: authpf.8,v 1.31 2003/12/10 04:10:37 beck Exp $ +.\" $OpenBSD: authpf.8,v 1.38 2005/01/04 09:57:04 jmc Exp $ .\" .\" Copyright (c) 2002 Bob Beck (beck@openbsd.org>. All rights reserved. .\" @@ -60,6 +60,10 @@ requires that the .Xr pf 4 system be enabled before use. +.Nm +can also maintain the list of IP address of connected users +in the "authpf_users" +.Pa table . .Pp .Nm is meant to be used with users who can connect via @@ -93,11 +97,16 @@ .Nm rules: .Bd -literal -offset indent -nat-anchor authpf -rdr-anchor authpf -binat-anchor authpf -anchor authpf +nat-anchor "authpf/*" +rdr-anchor "authpf/*" +binat-anchor "authpf/*" +anchor "authpf/*" .Ed +.Pp +The "/*" at the end of the anchor name is required for +.Xr pf 4 +to process the rulesets attached to the anchor by +.Nm authpf . .Sh FILTER AND TRANSLATION RULES Filter and translation rules for .Nm @@ -113,10 +122,14 @@ .Em user_id is assigned the user name. .Pp -Filter and nat rules will first be searched for in +Filter and translation rules are stored in a file called +.Pa authpf.rules . +This file will first be searched for in .Pa /etc/authpf/users/$USER/ and then in .Pa /etc/authpf/ . +Only one of these files will be used if both are present. +.Pp Per-user rules from the .Pa /etc/authpf/users/$USER/ directory are intended to be used when non-default rules @@ -124,21 +137,11 @@ It is important to ensure that a user can not write or change these configuration files. .Pp -Filter and translation rules are loaded from the file -.Pa /etc/authpf/users/$USER/authpf.rules . -If this file does not exist the file -.Pa /etc/authpf/authpf.rules -is used. The .Pa authpf.rules file must exist in one of the above locations for .Nm to run. -.Pp -Translation rules are also loaded from this file. -The use of translation rules in an -.Pa authpf.rules -file is optional. .Sh CONFIGURATION Options are controlled by the .Pa /etc/authpf/authpf.conf @@ -154,6 +157,10 @@ Use the specified .Pa anchor name instead of "authpf". +.It table=name +Use the specified +.Pa table +name instead of "authpf_users". .El .Sh USER MESSAGES On successful invocation, @@ -218,9 +225,15 @@ hijack the session. Note that TCP keepalives are not sufficient for this, since they are not secure. +Also note that +.Ar AllowTcpForwarding +should be disabled for +.Nm +users to prevent them from circumventing restrictions imposed by the +packet filter ruleset. .Pp .Nm -will remove statetable entries that were created during a user's +will remove state table entries that were created during a user's session. This ensures that there will be no unauthenticated traffic allowed to pass after the controlling @@ -391,15 +404,15 @@ # ssh and use us as a dns server. internal_if="fxp1" gateway_addr="10.0.1.1" -nat-anchor authpf -rdr-anchor authpf -binat-anchor authpf +nat-anchor "authpf/*" +rdr-anchor "authpf/*" +binat-anchor "authpf/*" block in on $internal_if from any to any pass in quick on $internal_if proto tcp from any to $gateway_addr \e port = ssh pass in quick on $internal_if proto udp from any to $gateway_addr \e port = domain -anchor authpf +anchor "authpf/*" .Ed .Pp .Sy For a switched, wired net @@ -465,6 +478,33 @@ 129.128.11.10.60539 > 198.137.240.92.22: S 2131494121:2131494121(0) win \e 16384 (DF) .Ed +.Pp +.Sy Using the authpf_users table +\- Simple +.Nm +settings can be implemented without an anchor by just using the "authpf_users" +.Pa table . +For example, the following +.Xr pf.conf 5 +lines will give SMTP and IMAP access to logged in users: +.Bd -literal +table persist +pass in on $ext_if proto tcp from \e + to port { smtp imap } keep state +.Ed +.Pp +It is also possible to use the "authpf_users" +.Pa table +in combination with anchors. +For example, +.Xr pf 4 +processing can be sped up by looking up the anchor +only for packets coming from logged in users: +.Bd -literal +table persist +anchor "authpf/*" from +rdr-anchor "authpf/*" from +.Ed .Sh FILES .Bl -tag -width "/etc/authpf/authpf.conf" -compact .It Pa /etc/authpf/authpf.conf ==== //depot/projects/trustedbsd/base/contrib/pf/authpf/authpf.c#3 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $OpenBSD: authpf.c,v 1.75 2004/01/29 01:55:10 deraadt Exp $ */ +/* $OpenBSD: authpf.c,v 1.89 2005/02/10 04:24:15 joel Exp $ */ /* * Copyright (C) 1998 - 2002 Bob Beck (beck@openbsd.org). @@ -26,13 +26,15 @@ */ #include -__FBSDID("$FreeBSD: src/contrib/pf/authpf/authpf.c,v 1.5 2004/06/16 23:39:30 mlaier Exp $"); +__FBSDID("$FreeBSD: src/contrib/pf/authpf/authpf.c,v 1.6 2005/05/03 16:55:19 mlaier Exp $"); #include #include #include #include +#include #include +#include #include #include @@ -40,6 +42,7 @@ #include #include +#include #include #include #include @@ -48,9 +51,6 @@ #include #include -#include -#include - #include "pathnames.h" extern int symset(const char *, const char *, int); @@ -61,11 +61,13 @@ static int check_luser(char *, char *); static int remove_stale_rulesets(void); static int change_filter(int, const char *, const char *); +static int change_table(int, const char *, const char *); static void authpf_kill_states(void); int dev; /* pf device */ char anchorname[PF_ANCHOR_NAME_SIZE] = "authpf"; -char rulesetname[PF_RULESET_NAME_SIZE]; +char rulesetname[MAXPATHLEN - PF_ANCHOR_NAME_SIZE - 2]; +char tablename[PF_TABLE_NAME_SIZE] = "authpf_users"; FILE *pidfp; char *infile; /* file name printed by yyerror() in parse.y */ @@ -94,10 +96,12 @@ { int lockcnt = 0, n, pidfd; FILE *config; - struct in_addr ina; + struct in6_addr ina; struct passwd *pw; char *cp; uid_t uid; + char *shell; + login_cap_t *lc; config = fopen(PATH_CONFFILE, "r"); @@ -121,7 +125,8 @@ exit(1); } *cp = '\0'; - if (inet_pton(AF_INET, ipsrc, &ina) != 1) { + if (inet_pton(AF_INET, ipsrc, &ina) != 1 && + inet_pton(AF_INET6, ipsrc, &ina) != 1) { syslog(LOG_ERR, "cannot determine IP from SSH_CLIENT %s", ipsrc); exit(1); @@ -135,16 +140,31 @@ uid = getuid(); pw = getpwuid(uid); + endpwent(); if (pw == NULL) { syslog(LOG_ERR, "cannot find user for uid %u", uid); goto die; } - if (strcmp(pw->pw_shell, PATH_AUTHPF_SHELL)) { + + if ((lc = login_getclass(pw->pw_class)) != NULL) + shell = (char *)login_getcapstr(lc, "shell", pw->pw_shell, + pw->pw_shell); + else + shell = pw->pw_shell; + + login_close(lc); + + if (strcmp(shell, PATH_AUTHPF_SHELL)) { syslog(LOG_ERR, "wrong shell for user %s, uid %u", pw->pw_name, pw->pw_uid); + if (shell != pw->pw_shell) + free(shell); goto die; } + if (shell != pw->pw_shell) + free(shell); + /* * Paranoia, but this data _does_ come from outside authpf, and * truncation would be bad. @@ -155,11 +175,11 @@ } if ((n = snprintf(rulesetname, sizeof(rulesetname), "%s(%ld)", - luser, (long)getpid())) < 0 || n >= sizeof(rulesetname)) { + luser, (long)getpid())) < 0 || (u_int)n >= sizeof(rulesetname)) { syslog(LOG_INFO, "%s(%ld) too large, ruleset name will be %ld", luser, (long)getpid(), (long)getpid()); if ((n = snprintf(rulesetname, sizeof(rulesetname), "%ld", - (long)getpid())) < 0 || n >= sizeof(rulesetname)) { + (long)getpid())) < 0 || (u_int)n >= sizeof(rulesetname)) { syslog(LOG_ERR, "pid too large for ruleset name"); goto die; } @@ -269,12 +289,17 @@ rewind(pidfp); fprintf(pidfp, "%ld\n%s\n", (long)getpid(), luser); fflush(pidfp); - (void) ftruncate(fileno(pidfp), ftell(pidfp)); + (void) ftruncate(fileno(pidfp), ftello(pidfp)); if (change_filter(1, luser, ipsrc) == -1) { printf("Unable to modify filters\r\n"); do_death(0); } + if (change_table(1, luser, ipsrc) == -1) { + printf("Unable to modify table\r\n"); + change_filter(0, luser, ipsrc); + do_death(0); + } signal(SIGTERM, need_death); signal(SIGINT, need_death); @@ -284,7 +309,7 @@ signal(SIGSTOP, need_death); signal(SIGTSTP, need_death); while (1) { - printf("\r\nHello %s, ", luser); + printf("\r\nHello %s. ", luser); printf("You are authenticated from host \"%s\"\r\n", ipsrc); setproctitle("%s@%s", luser, ipsrc); print_message(PATH_MESSAGE); @@ -359,6 +384,11 @@ sizeof(anchorname)) >= sizeof(anchorname)) goto parse_error; } + if (strcasecmp(pair[0], "table") == 0) { + if (!pair[1][0] || strlcpy(tablename, pair[1], + sizeof(tablename)) >= sizeof(tablename)) + goto parse_error; + } } while (!feof(f) && !ferror(f)); fclose(f); return (0); @@ -542,12 +572,10 @@ remove_stale_rulesets(void) { struct pfioc_ruleset prs; - const int action[PF_RULESET_MAX] = { PF_SCRUB, - PF_PASS, PF_NAT, PF_BINAT, PF_RDR }; u_int32_t nr, mnr; memset(&prs, 0, sizeof(prs)); - strlcpy(prs.anchor, anchorname, sizeof(prs.anchor)); + strlcpy(prs.path, anchorname, sizeof(prs.path)); if (ioctl(dev, DIOCGETRULESETS, &prs)) { if (errno == EINVAL) return (0); @@ -574,20 +602,25 @@ (*s && (t == prs.name || *s != ')'))) return (1); if (kill(pid, 0) && errno != EPERM) { - int i; + int i; + struct pfioc_trans_e t_e[PF_RULESET_MAX+1]; + struct pfioc_trans t; - for (i = 0; i < PF_RULESET_MAX; ++i) { - struct pfioc_rule pr; - - memset(&pr, 0, sizeof(pr)); - memcpy(pr.anchor, prs.anchor, sizeof(pr.anchor)); - memcpy(pr.ruleset, prs.name, sizeof(pr.ruleset)); - pr.rule.action = action[i]; - if ((ioctl(dev, DIOCBEGINRULES, &pr) || - ioctl(dev, DIOCCOMMITRULES, &pr)) && - errno != EINVAL) - return (1); + bzero(&t, sizeof(t)); + bzero(t_e, sizeof(t_e)); + t.size = PF_RULESET_MAX+1; + t.esize = sizeof(t_e[0]); + t.array = t_e; + for (i = 0; i < PF_RULESET_MAX+1; ++i) { + t_e[i].rs_num = i; + snprintf(t_e[i].anchor, sizeof(t_e[i].anchor), + "%s/%s", anchorname, prs.name); } + t_e[PF_RULESET_MAX].rs_num = PF_RULESET_TABLE; + if ((ioctl(dev, DIOCXBEGIN, &t) || + ioctl(dev, DIOCXCOMMIT, &t)) && + errno != EINVAL) + return (1); mnr--; } else nr++; @@ -601,85 +634,67 @@ static int change_filter(int add, const char *luser, const char *ipsrc) { - char fn[MAXPATHLEN]; - FILE *f = NULL; - struct pfctl pf; - struct pfr_buffer t; - int i; + char *pargv[13] = { + "pfctl", "-p", "/dev/pf", "-q", "-a", "anchor/ruleset", + "-D", "user_ip=X", "-D", "user_id=X", "-f", + "file", NULL + }; + char *fdpath = NULL, *userstr = NULL, *ipstr = NULL; + char *rsn = NULL, *fn = NULL; + pid_t pid; + int s; if (luser == NULL || !luser[0] || ipsrc == NULL || !ipsrc[0]) { syslog(LOG_ERR, "invalid luser/ipsrc"); goto error; } + if (asprintf(&rsn, "%s/%s", anchorname, rulesetname) == -1) + goto no_mem; + if (asprintf(&fdpath, "/dev/fd/%d", dev) == -1) + goto no_mem; + if (asprintf(&ipstr, "user_ip=%s", ipsrc) == -1) + goto no_mem; + if (asprintf(&userstr, "user_id=%s", luser) == -1) + goto no_mem; + if (add) { - if ((i = snprintf(fn, sizeof(fn), "%s/%s/authpf.rules", - PATH_USER_DIR, luser)) < 0 || i >= sizeof(fn)) { - syslog(LOG_ERR, "user rule path too long"); - goto error; - } - if ((f = fopen(fn, "r")) == NULL && errno != ENOENT) { - syslog(LOG_ERR, "cannot open %s (%m)", fn); - goto error; - } - if (f == NULL) { - if (strlcpy(fn, PATH_PFRULES, sizeof(fn)) >= - sizeof(fn)) { - syslog(LOG_ERR, "rule path too long"); - goto error; - } - if ((f = fopen(fn, "r")) == NULL) { - syslog(LOG_ERR, "cannot open %s (%m)", fn); - goto error; - } + struct stat sb; + + if (asprintf(&fn, "%s/%s/authpf.rules", PATH_USER_DIR, luser) + == -1) + goto no_mem; + if (stat(fn, &sb) == -1) { + free(fn); + if ((fn = strdup(PATH_PFRULES)) == NULL) + goto no_mem; } } + pargv[2] = fdpath; + pargv[5] = rsn; + pargv[7] = userstr; + pargv[9] = ipstr; + if (!add) + pargv[11] = "/dev/null"; + else + pargv[11] = fn; - if (pfctl_load_fingerprints(dev, 0)) { - syslog(LOG_ERR, "unable to load kernel's OS fingerprints"); - goto error; - } - bzero(&t, sizeof(t)); - t.pfrb_type = PFRB_TRANS; - memset(&pf, 0, sizeof(pf)); - for (i = 0; i < PF_RULESET_MAX; ++i) { - if (pfctl_add_trans(&t, i, anchorname, rulesetname)) { - syslog(LOG_ERR, "pfctl_add_trans %m"); - goto error; - } - } - if (pfctl_trans(dev, &t, DIOCXBEGIN, 0)) { - syslog(LOG_ERR, "DIOCXBEGIN (%s) %m", add?"add":"remove"); - goto error; + switch (pid = fork()) { + case -1: + err(1, "fork failed"); + case 0: + execvp(PATH_PFCTL, pargv); + warn("exec of %s failed", PATH_PFCTL); + _exit(1); } - if (add) { - if (symset("user_ip", ipsrc, 0) || - symset("user_id", luser, 0)) { - syslog(LOG_ERR, "symset"); - goto error; - } - - pf.dev = dev; - pf.trans = &t; - pf.anchor = anchorname; - pf.ruleset = rulesetname; - - infile = fn; - if (parse_rules(f, &pf) < 0) { - syslog(LOG_ERR, "syntax error in rule file: " - "authpf rules not loaded"); + /* parent */ + waitpid(pid, &s, 0); + if (s != 0) { + if (WIFEXITED(s)) { + syslog(LOG_ERR, "pfctl exited abnormally"); goto error; } - - infile = NULL; - fclose(f); - f = NULL; - } - - if (pfctl_trans(dev, &t, DIOCXCOMMIT, 0)) { - syslog(LOG_ERR, "DIOCXCOMMIT (%s) %m", add?"add":"remove"); - goto error; } if (add) { @@ -691,18 +706,63 @@ ipsrc, luser, Tend.tv_sec - Tstart.tv_sec); } return (0); - +no_mem: + syslog(LOG_ERR, "malloc failed"); error: - if (f != NULL) >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Tue May 3 22:02:17 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9589A16A4D0; Tue, 3 May 2005 22:02:16 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 52BF416A4CE for ; Tue, 3 May 2005 22:02:16 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 25F7F43D7C for ; Tue, 3 May 2005 22:02:16 +0000 (GMT) (envelope-from scottl@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43M2Bht084761 for ; Tue, 3 May 2005 22:02:11 GMT (envelope-from scottl@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43M2AEq084758 for perforce@freebsd.org; Tue, 3 May 2005 22:02:10 GMT (envelope-from scottl@freebsd.org) Date: Tue, 3 May 2005 22:02:10 GMT Message-Id: <200505032202.j43M2AEq084758@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to scottl@freebsd.org using -f From: Scott Long To: Perforce Change Reviews Subject: PERFORCE change 76466 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 22:02:17 -0000 http://perforce.freebsd.org/chv.cgi?CH=76466 Change 76466 by scottl@scottl-x64 on 2005/05/03 22:02:01 Add some plumbing to allow compatibility policy versions to be used. Affected files ... .. //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#19 edit Differences ... ==== //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#19 (text+ko) ==== @@ -14,13 +14,19 @@ # Set to y if MLS is enabled in the module. MLS= n +POLICYVERCOMPAT = 17 FLASKDIR = flask/ PREFIX = /usr LOADPOLICY = $(DESTDIR)/sbin/sebsd_loadpolicy CHECKPOLICY = $(DESTDIR)/sbin/sebsd_checkpolicy SETFILES = $(DESTDIR)/sbin/sebsd_setfiles -POLICYVERTMP = 17 +.if (POLICYVERCOMPAT) +POLICYVERTMP = $(POLICYVERCOMPAT) +POLICYVERCOMPATARGS = -c $(POLICYVERCOMPAT) +.else +POLICYVERTMP != ($(CHECKPOLICY) $(POLICYCOMPAT) -V |cut -f 1 -d ' ') +.endif POLICYVER := policy.$(POLICYVERTMP) INSTALLDIR = $(DESTDIR)/etc/security/sebsd POLICYPATH = $(INSTALLDIR)/policy @@ -97,14 +103,14 @@ $(LOADPATH): policy.conf $(CHECKPOLICY) mkdir -p $(POLICYPATH) - $(CHECKPOLICY) -o $@ policy.conf + $(CHECKPOLICY) $(POLICYVERCOMPATARGS) -o $@ policy.conf # Note: Can't use install, so not sure how to deal with mode, user, and group # other than by default. policy: $(POLICYVER) $(POLICYVER): policy.conf $(CHECKPOLICY) - $(CHECKPOLICY) -o $@ policy.conf + $(CHECKPOLICY) $(POLICYVERCOMPATARGS) -o $@ policy.conf reload tmp/load: $(LOADPATH) $(FCPATH) $(LOADPOLICY) $(POLICYPATH)/$(POLICYVER) From owner-p4-projects@FreeBSD.ORG Tue May 3 22:42:16 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6E9E316A4D0; Tue, 3 May 2005 22:42:15 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 25C2816A4CF for ; Tue, 3 May 2005 22:42:15 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id E43B743D8B for ; Tue, 3 May 2005 22:42:13 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43Mg3bw086160 for ; Tue, 3 May 2005 22:42:03 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43Mg1VS086157 for perforce@freebsd.org; Tue, 3 May 2005 22:42:01 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 3 May 2005 22:42:01 GMT Message-Id: <200505032242.j43Mg1VS086157@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76467 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 22:42:16 -0000 http://perforce.freebsd.org/chv.cgi?CH=76467 Change 76467 by rwatson@rwatson_tislabs on 2005/05/03 22:41:13 Integrated TrustedBSD MAC branch: pf update ipfilter update powerd ipi spin lock amd64 fix kdb stop nmi yet more ata much vfs locking ksem.h uma critical sections Affected files ... .. //depot/projects/trustedbsd/mac/Makefile.inc1#55 integrate .. //depot/projects/trustedbsd/mac/UPDATING#46 integrate .. //depot/projects/trustedbsd/mac/bin/ps/ps.1#24 integrate .. //depot/projects/trustedbsd/mac/contrib/bsnmp/snmpd/main.c#7 integrate .. //depot/projects/trustedbsd/mac/contrib/ipfilter/lib/printstate.c#2 integrate .. //depot/projects/trustedbsd/mac/contrib/ipfilter/tools/ippool.c#2 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/authpf/authpf.8#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/authpf/authpf.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/authpf/pathnames.h#2 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/ftp-proxy/ftp-proxy.8#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/ftp-proxy/ftp-proxy.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/ftp-proxy/getline.c#2 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/ftp-proxy/util.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/ftp-proxy/util.h#2 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/man/pf.4#5 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/man/pf.conf.5#5 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/man/pf.os.5#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/man/pflog.4#4 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/man/pfsync.4#5 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/parse.y#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pf_print_state.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl.8#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl.h#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_altq.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_optimize.c#1 branch .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_osfp.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_parser.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_parser.h#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_qstats.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_radix.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pfctl/pfctl_table.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pflogd/pflogd.8#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pflogd/pflogd.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pflogd/pidfile.c#3 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pflogd/privsep.c#2 integrate .. //depot/projects/trustedbsd/mac/contrib/pf/pflogd/privsep_fdpass.c#2 integrate .. //depot/projects/trustedbsd/mac/etc/Makefile#43 integrate .. //depot/projects/trustedbsd/mac/etc/rc#28 integrate .. //depot/projects/trustedbsd/mac/etc/rc.d/Makefile#25 integrate .. //depot/projects/trustedbsd/mac/etc/rc.d/initdiskless#17 delete .. //depot/projects/trustedbsd/mac/etc/rc.d/jail#9 integrate .. //depot/projects/trustedbsd/mac/etc/rc.d/preseedrandom#3 delete .. //depot/projects/trustedbsd/mac/etc/rc.d/rcconf.sh#4 integrate .. //depot/projects/trustedbsd/mac/etc/rc.initdiskless#2 integrate .. //depot/projects/trustedbsd/mac/games/caesar/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/games/caesar/caesar.c#4 integrate .. //depot/projects/trustedbsd/mac/games/pom/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/games/pom/pom.c#4 integrate .. //depot/projects/trustedbsd/mac/gnu/lib/libobjc/Makefile#9 integrate .. //depot/projects/trustedbsd/mac/lib/libc/gen/getbootfile.c#4 integrate .. //depot/projects/trustedbsd/mac/lib/libc/gen/getgrouplist.c#7 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getaddrinfo.3#9 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getaddrinfo.c#18 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/gethostbydns.c#14 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/gethostbyht.c#6 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/gethostbyname.3#9 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/gethostbynis.c#7 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/gethostnamadr.c#7 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getipnodebyname.3#6 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getnameinfo.3#7 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getnameinfo.c#6 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getnetbydns.c#8 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getnetbyht.c#6 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getnetbynis.c#4 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getnetent.3#5 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getnetnamadr.c#5 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getprotoent.c#5 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/getservent.c#9 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/map_v4v6.c#4 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/name6.c#17 integrate .. //depot/projects/trustedbsd/mac/lib/libc/net/netdb_private.h#4 integrate .. //depot/projects/trustedbsd/mac/lib/libc/yp/yplib.c#9 integrate .. //depot/projects/trustedbsd/mac/lib/libpmc/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/lib/libpmc/libpmc.c#2 integrate .. //depot/projects/trustedbsd/mac/lib/libpmc/pmc.3#2 integrate .. //depot/projects/trustedbsd/mac/lib/libpmc/pmc.h#2 integrate .. //depot/projects/trustedbsd/mac/lib/libthr/Makefile#8 integrate .. //depot/projects/trustedbsd/mac/lib/libthr/arch/i386/i386/pthread_md.c#3 integrate .. //depot/projects/trustedbsd/mac/lib/libthr/arch/i386/include/pthread_md.h#2 integrate .. //depot/projects/trustedbsd/mac/lib/libthr/support/Makefile.inc#1 branch .. //depot/projects/trustedbsd/mac/lib/libthr/thread/thr_create.c#8 integrate .. //depot/projects/trustedbsd/mac/lib/msun/src/s_ceill.c#3 integrate .. //depot/projects/trustedbsd/mac/lib/msun/src/s_floorl.c#3 integrate .. //depot/projects/trustedbsd/mac/lib/msun/src/s_truncl.c#3 integrate .. //depot/projects/trustedbsd/mac/release/Makefile#61 integrate .. //depot/projects/trustedbsd/mac/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#77 integrate .. //depot/projects/trustedbsd/mac/release/doc/zh_CN.GB2312/relnotes/common/new.sgml#4 integrate .. //depot/projects/trustedbsd/mac/release/scripts/package-split.py#3 integrate .. //depot/projects/trustedbsd/mac/release/scripts/package-trees.sh#2 integrate .. //depot/projects/trustedbsd/mac/rescue/rescue/Makefile#12 integrate .. //depot/projects/trustedbsd/mac/sbin/atm/atm/atm.h#4 integrate .. //depot/projects/trustedbsd/mac/sbin/atm/atmconfig/atmconfig_device.h#2 integrate .. //depot/projects/trustedbsd/mac/sbin/atm/ilmid/ilmid.c#11 integrate .. //depot/projects/trustedbsd/mac/sbin/dump/traverse.c#16 integrate .. //depot/projects/trustedbsd/mac/sbin/fdisk/fdisk.c#20 integrate .. //depot/projects/trustedbsd/mac/sbin/fdisk_pc98/Makefile#5 integrate .. //depot/projects/trustedbsd/mac/sbin/fdisk_pc98/fdisk.c#11 integrate .. //depot/projects/trustedbsd/mac/sbin/geom/core/geom.c#4 integrate .. //depot/projects/trustedbsd/mac/sbin/ggate/shared/ggate.h#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ifconfig/ifpfsync.c#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/ipf/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/ipftest/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/ipmon/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/ipnat/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/ippool/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/ipresend/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/ipsend/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/ipf/libipf/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sbin/natd/natd.c#11 integrate .. //depot/projects/trustedbsd/mac/sbin/pfctl/Makefile#3 integrate .. //depot/projects/trustedbsd/mac/share/man/man4/ath.4#12 integrate .. //depot/projects/trustedbsd/mac/share/man/man4/hwpmc.4#2 integrate .. //depot/projects/trustedbsd/mac/share/man/man5/rc.conf.5#39 integrate .. //depot/projects/trustedbsd/mac/share/man/man9/taskqueue.9#11 integrate .. //depot/projects/trustedbsd/mac/share/mk/sys.mk#19 integrate .. //depot/projects/trustedbsd/mac/sys/amd64/amd64/mp_machdep.c#8 integrate .. //depot/projects/trustedbsd/mac/sys/amd64/amd64/trap.c#14 integrate .. //depot/projects/trustedbsd/mac/sys/amd64/conf/NOTES#6 integrate .. //depot/projects/trustedbsd/mac/sys/amd64/include/smp.h#6 integrate .. //depot/projects/trustedbsd/mac/sys/conf/NOTES#61 integrate .. //depot/projects/trustedbsd/mac/sys/conf/files#114 integrate .. //depot/projects/trustedbsd/mac/sys/conf/files.amd64#16 integrate .. //depot/projects/trustedbsd/mac/sys/conf/files.i386#45 integrate .. //depot/projects/trustedbsd/mac/sys/conf/files.pc98#38 integrate .. //depot/projects/trustedbsd/mac/sys/conf/kern.post.mk#36 integrate .. //depot/projects/trustedbsd/mac/sys/conf/options#72 integrate .. //depot/projects/trustedbsd/mac/sys/conf/options.amd64#9 integrate .. //depot/projects/trustedbsd/mac/sys/conf/options.i386#25 integrate .. //depot/projects/trustedbsd/mac/sys/conf/options.pc98#26 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/ipfilter/netinet/ip_compat.h#12 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/ipfilter/netinet/ip_frag.c#12 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/if_pflog.c#5 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/if_pflog.h#3 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/if_pfsync.c#5 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/if_pfsync.h#3 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pf.c#10 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pf_if.c#4 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pf_ioctl.c#6 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pf_norm.c#4 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pf_osfp.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pf_subr.c#2 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pf_table.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/contrib/pf/net/pfvar.h#3 integrate .. //depot/projects/trustedbsd/mac/sys/dev/aac/aac_disk.c#18 integrate .. //depot/projects/trustedbsd/mac/sys/dev/arcmsr/arcmsr.c#2 integrate .. //depot/projects/trustedbsd/mac/sys/dev/asr/asr.c#20 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-all.c#38 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-all.h#23 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-card.c#23 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-cbus.c#13 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-chipset.c#20 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-disk.c#30 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-dma.c#31 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-isa.c#18 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-lowlevel.c#11 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-pci.c#33 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-pci.h#16 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-queue.c#11 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-raid.c#25 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata-raid.h#18 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/ata_if.m#2 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/atapi-cam.c#18 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/atapi-cd.c#30 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/atapi-fd.c#20 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ata/atapi-tape.c#20 integrate .. //depot/projects/trustedbsd/mac/sys/dev/ciss/ciss.c#25 integrate .. //depot/projects/trustedbsd/mac/sys/dev/hwpmc/hwpmc_amd.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/dev/hwpmc/hwpmc_intel.c#2 integrate .. //depot/projects/trustedbsd/mac/sys/dev/hwpmc/hwpmc_mod.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/dev/hwpmc/hwpmc_piv.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/dev/hwpmc/hwpmc_ppro.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/dev/pci/pci.c#35 integrate .. //depot/projects/trustedbsd/mac/sys/dev/pci/pci_pci.c#20 integrate .. //depot/projects/trustedbsd/mac/sys/dev/pci/pcireg.h#8 integrate .. //depot/projects/trustedbsd/mac/sys/dev/pci/pcivar.h#12 integrate .. //depot/projects/trustedbsd/mac/sys/dev/twa/tw_osl_cam.c#2 integrate .. //depot/projects/trustedbsd/mac/sys/fs/devfs/devfs_vfsops.c#25 integrate .. //depot/projects/trustedbsd/mac/sys/fs/devfs/devfs_vnops.c#56 integrate .. //depot/projects/trustedbsd/mac/sys/fs/pseudofs/pseudofs_vnops.c#33 integrate .. //depot/projects/trustedbsd/mac/sys/fs/unionfs/union_vnops.c#23 integrate .. //depot/projects/trustedbsd/mac/sys/geom/geom_pc98_enc.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/geom/vinum/geom_vinum_init.c#3 integrate .. //depot/projects/trustedbsd/mac/sys/i386/conf/NOTES#53 integrate .. //depot/projects/trustedbsd/mac/sys/i386/conf/PAE#9 integrate .. //depot/projects/trustedbsd/mac/sys/i386/i386/mp_machdep.c#36 integrate .. //depot/projects/trustedbsd/mac/sys/i386/i386/trap.c#34 integrate .. //depot/projects/trustedbsd/mac/sys/i386/include/pmc_mdep.h#3 integrate .. //depot/projects/trustedbsd/mac/sys/i386/include/smp.h#14 integrate .. //depot/projects/trustedbsd/mac/sys/kern/imgact_aout.c#20 integrate .. //depot/projects/trustedbsd/mac/sys/kern/imgact_elf.c#35 integrate .. //depot/projects/trustedbsd/mac/sys/kern/kern_descrip.c#57 integrate .. //depot/projects/trustedbsd/mac/sys/kern/kern_exec.c#77 integrate .. //depot/projects/trustedbsd/mac/sys/kern/subr_devstat.c#12 integrate .. //depot/projects/trustedbsd/mac/sys/kern/subr_kdb.c#4 integrate .. //depot/projects/trustedbsd/mac/sys/kern/subr_smp.c#21 integrate .. //depot/projects/trustedbsd/mac/sys/kern/subr_taskqueue.c#13 integrate .. //depot/projects/trustedbsd/mac/sys/kern/uipc_sem.c#25 integrate .. //depot/projects/trustedbsd/mac/sys/kern/vfs_aio.c#41 integrate .. //depot/projects/trustedbsd/mac/sys/kern/vfs_bio.c#44 integrate .. //depot/projects/trustedbsd/mac/sys/kern/vfs_cluster.c#28 integrate .. //depot/projects/trustedbsd/mac/sys/kern/vfs_default.c#33 integrate .. //depot/projects/trustedbsd/mac/sys/kern/vfs_mount.c#37 integrate .. //depot/projects/trustedbsd/mac/sys/kern/vfs_subr.c#73 integrate .. //depot/projects/trustedbsd/mac/sys/netinet/tcp_usrreq.c#26 integrate .. //depot/projects/trustedbsd/mac/sys/nfsclient/nfs_vfsops.c#38 integrate .. //depot/projects/trustedbsd/mac/sys/pc98/conf/NOTES#20 integrate .. //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#6 integrate .. //depot/projects/trustedbsd/mac/sys/powerpc/conf/GENERIC#25 integrate .. //depot/projects/trustedbsd/mac/sys/powerpc/powermac/ata_kauai.c#8 integrate .. //depot/projects/trustedbsd/mac/sys/powerpc/powermac/ata_macio.c#15 integrate .. //depot/projects/trustedbsd/mac/sys/sys/diskpc98.h#8 integrate .. //depot/projects/trustedbsd/mac/sys/sys/param.h#39 integrate .. //depot/projects/trustedbsd/mac/sys/sys/pmc.h#3 integrate .. //depot/projects/trustedbsd/mac/sys/sys/ptrace.h#7 integrate .. //depot/projects/trustedbsd/mac/sys/sys/smp.h#10 integrate .. //depot/projects/trustedbsd/mac/sys/sys/taskqueue.h#7 integrate .. //depot/projects/trustedbsd/mac/sys/ufs/ffs/ffs_rawread.c#14 integrate .. //depot/projects/trustedbsd/mac/sys/ufs/ffs/ffs_softdep.c#29 integrate .. //depot/projects/trustedbsd/mac/sys/vm/swap_pager.c#33 integrate .. //depot/projects/trustedbsd/mac/sys/vm/uma_core.c#32 integrate .. //depot/projects/trustedbsd/mac/sys/vm/uma_int.h#16 integrate .. //depot/projects/trustedbsd/mac/sys/vm/vm_fault.c#30 integrate .. //depot/projects/trustedbsd/mac/sys/vm/vm_map.c#39 integrate .. //depot/projects/trustedbsd/mac/sys/vm/vm_object.c#44 integrate .. //depot/projects/trustedbsd/mac/sys/vm/vm_object.h#21 integrate .. //depot/projects/trustedbsd/mac/sys/vm/vnode_pager.c#35 integrate .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/README#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/all.sh#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t0/Makefile#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t0/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t0/libtest.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t0/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t1/Makefile#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t1/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t1/libtest.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t1/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t2/Makefile#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t2/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t2/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t2/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t2/libtest.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/archives/t2/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t0/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t0/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t1/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t1/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t2/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t2/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t2/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t2/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t3/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t3/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t3/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/basic/t3/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/common.sh#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t0/Makefile#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t0/TEST1.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t0/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t0/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t1/Makefile#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t1/TEST1.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t1/TEST2.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t1/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t1/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t2/Makefile#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t2/TEST1.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t2/TEST2.a#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t2/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t2/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t2/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/suffixes/t2/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t0/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t0/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t0/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t0/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t1/expected.status#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t1/expected.stderr#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t1/expected.stdout#1 branch .. //depot/projects/trustedbsd/mac/tools/regression/usr.bin/make/variables/t1/test.t#1 branch .. //depot/projects/trustedbsd/mac/tools/tools/tinderbox/etc/default.rc#4 integrate .. //depot/projects/trustedbsd/mac/tools/tools/tinderbox/tinderbox.pl#11 integrate .. //depot/projects/trustedbsd/mac/usr.bin/Makefile#33 integrate .. //depot/projects/trustedbsd/mac/usr.bin/brandelf/brandelf.c#5 integrate .. //depot/projects/trustedbsd/mac/usr.bin/compress/zopen.c#6 integrate .. //depot/projects/trustedbsd/mac/usr.bin/id/id.1#6 integrate .. //depot/projects/trustedbsd/mac/usr.bin/id/id.c#10 integrate .. //depot/projects/trustedbsd/mac/usr.bin/make/Makefile#13 integrate .. //depot/projects/trustedbsd/mac/usr.bin/make/cond.c#12 integrate .. //depot/projects/trustedbsd/mac/usr.bin/make/directive_hash.c#2 delete .. //depot/projects/trustedbsd/mac/usr.bin/make/directive_hash.h#2 delete .. //depot/projects/trustedbsd/mac/usr.bin/make/globals.h#3 integrate .. //depot/projects/trustedbsd/mac/usr.bin/make/hash_tables.c#1 branch .. //depot/projects/trustedbsd/mac/usr.bin/make/hash_tables.h#1 branch .. //depot/projects/trustedbsd/mac/usr.bin/make/main.c#25 integrate .. //depot/projects/trustedbsd/mac/usr.bin/make/make.h#8 integrate .. //depot/projects/trustedbsd/mac/usr.bin/make/nonints.h#11 integrate .. //depot/projects/trustedbsd/mac/usr.bin/make/parse.c#19 integrate .. //depot/projects/trustedbsd/mac/usr.bin/mkuzip/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/usr.bin/mkuzip/mkuzip.c#2 integrate .. //depot/projects/trustedbsd/mac/usr.bin/rs/rs.c#6 integrate .. //depot/projects/trustedbsd/mac/usr.bin/systat/pigs.c#6 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/adduser/adduser.sh#9 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/authpf/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/burncd/burncd.8#17 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/faithd/ftp.c#6 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/jail/jail.8#19 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/pmccontrol/pmccontrol.c#2 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/pmcstat/pmcstat.c#2 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/ppp/ppp.8.m4#20 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/rpc.yppasswdd/yppasswdd_main.c#7 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/sysinstall/dist.c#24 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/sysinstall/menus.c#36 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/ypserv/Makefile.yp#5 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/ypserv/yp_dnslookup.c#6 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/ypserv/yp_extern.h#3 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/ypserv/yp_server.c#5 integrate Differences ... ==== //depot/projects/trustedbsd/mac/Makefile.inc1#55 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.492 2005/04/06 01:55:43 peter Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.494 2005/05/01 17:36:09 imp Exp $ # # Make command line options: # -DNO_DYNAMICROOT do not link /bin and /sbin dynamically ==== //depot/projects/trustedbsd/mac/UPDATING#46 (text+ko) ==== @@ -21,6 +21,11 @@ developers choose to disable these features on build machines to maximize performance. +20050503: + The packet filter (pf) code has been updated to OpenBSD 3.7 + Please note the changed anchor syntax and the fact that + authpf(8) now needs a mounted fdescfs(5) to function. + 20050415: The NO_MIXED_MODE kernel option has been removed from the i386 amd64 platforms as its use has been superceded by the new local @@ -331,4 +336,4 @@ Contact Warner Losh if you have any questions about your use of this document. -$FreeBSD: src/UPDATING,v 1.401 2005/04/18 14:33:18 scottl Exp $ +$FreeBSD: src/UPDATING,v 1.402 2005/05/03 17:43:13 mlaier Exp $ ==== //depot/projects/trustedbsd/mac/bin/ps/ps.1#24 (text+ko) ==== @@ -27,7 +27,7 @@ .\" SUCH DAMAGE. .\" .\" @(#)ps.1 8.3 (Berkeley) 4/18/94 -.\" $FreeBSD: src/bin/ps/ps.1,v 1.85 2005/03/20 10:40:36 pjd Exp $ +.\" $FreeBSD: src/bin/ps/ps.1,v 1.86 2005/04/29 11:10:27 maxim Exp $ .\" .Dd March 20, 2005 .Dt PS 1 @@ -103,7 +103,7 @@ .Bl -tag -width indent .It Fl a Display information about other users' processes as well as your own. -This will skip any processes which do not have a controlling teminal, +This will skip any processes which do not have a controlling terminal, unless the .Fl x option is also specified. ==== //depot/projects/trustedbsd/mac/contrib/bsnmp/snmpd/main.c#7 (text+ko) ==== @@ -1634,9 +1634,7 @@ timer_start(u_int ticks, void (*func)(void *), void *udata, struct lmodule *mod) { struct timer *tp; -#ifdef USE_LIBBEGEMOT - struct timeval due; -#else +#ifndef USE_LIBBEGEMOT struct timespec due; #endif @@ -1644,15 +1642,8 @@ syslog(LOG_CRIT, "out of memory for timer"); exit(1); } -#ifdef USE_LIBBEGEMOT - (void)gettimeofday(&due, NULL); - due.tv_sec += ticks / 100; - due.tv_usec += (ticks % 100) * 10000; - if (due.tv_usec >= 1000000) { - due.tv_sec++; - due.tv_usec -= 1000000; - } -#else + +#ifndef USE_LIBBEGEMOT due = evAddTime(evNowTime(), evConsTime(ticks / 100, (ticks % 100) * 10000)); #endif @@ -1664,8 +1655,7 @@ LIST_INSERT_HEAD(&timer_list, tp, link); #ifdef USE_LIBBEGEMOT - if ((tp->id = poll_start_timer(due.tv_sec * 1000 + due.tv_usec / 1000, - 0, tfunc, tp)) < 0) { + if ((tp->id = poll_start_timer(ticks * 10, 0, tfunc, tp)) < 0) { syslog(LOG_ERR, "cannot set timer: %m"); exit(1); } ==== //depot/projects/trustedbsd/mac/contrib/ipfilter/lib/printstate.c#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/contrib/ipfilter/lib/printstate.c,v 1.2 2005/04/25 18:20:12 darrenr Exp $ */ +/* $FreeBSD: src/contrib/ipfilter/lib/printstate.c,v 1.3 2005/04/28 21:36:30 darrenr Exp $ */ /* * Copyright (C) 2002 by Darren Reed. @@ -64,7 +64,7 @@ ips.is_icmp.ici_seq, ips.is_icmp.ici_type); #ifdef USE_QUAD_T - PRINTF("\tforward: pkts in %qd bytes in %qd pkts out %qd bytes out %qd\n\tbackward: pkts in %qd bytes in %qd pkts out %qd bytes out %qd\n", + PRINTF("\tforward: pkts in %lld bytes in %lld pkts out %lld bytes out %lld\n\tbackward: pkts in %lld bytes in %lld pkts out %lld bytes out %lld\n", ips.is_pkts[0], ips.is_bytes[0], ips.is_pkts[1], ips.is_bytes[1], ips.is_pkts[2], ips.is_bytes[2], ==== //depot/projects/trustedbsd/mac/contrib/ipfilter/tools/ippool.c#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/contrib/ipfilter/tools/ippool.c,v 1.2 2005/04/25 18:20:15 darrenr Exp $ */ +/* $FreeBSD: src/contrib/ipfilter/tools/ippool.c,v 1.3 2005/04/28 16:26:33 darrenr Exp $ */ /* * Copyright (C) 2003 by Darren Reed. @@ -639,7 +639,7 @@ } } - printf("%u object%s flushed\n", flush.iplf_count, + printf("%zd object%s flushed\n", flush.iplf_count, (flush.iplf_count == 1) ? "" : "s"); return 0; ==== //depot/projects/trustedbsd/mac/contrib/pf/authpf/authpf.8#3 (text+ko) ==== @@ -1,4 +1,4 @@ -.\" $OpenBSD: authpf.8,v 1.31 2003/12/10 04:10:37 beck Exp $ +.\" $OpenBSD: authpf.8,v 1.38 2005/01/04 09:57:04 jmc Exp $ .\" .\" Copyright (c) 2002 Bob Beck (beck@openbsd.org>. All rights reserved. .\" @@ -60,6 +60,10 @@ requires that the .Xr pf 4 system be enabled before use. +.Nm +can also maintain the list of IP address of connected users +in the "authpf_users" +.Pa table . .Pp .Nm is meant to be used with users who can connect via @@ -93,11 +97,16 @@ .Nm rules: .Bd -literal -offset indent -nat-anchor authpf -rdr-anchor authpf -binat-anchor authpf -anchor authpf +nat-anchor "authpf/*" +rdr-anchor "authpf/*" +binat-anchor "authpf/*" +anchor "authpf/*" .Ed +.Pp +The "/*" at the end of the anchor name is required for +.Xr pf 4 +to process the rulesets attached to the anchor by +.Nm authpf . .Sh FILTER AND TRANSLATION RULES Filter and translation rules for .Nm @@ -113,10 +122,14 @@ .Em user_id is assigned the user name. .Pp -Filter and nat rules will first be searched for in +Filter and translation rules are stored in a file called +.Pa authpf.rules . +This file will first be searched for in .Pa /etc/authpf/users/$USER/ and then in .Pa /etc/authpf/ . +Only one of these files will be used if both are present. +.Pp Per-user rules from the .Pa /etc/authpf/users/$USER/ directory are intended to be used when non-default rules @@ -124,21 +137,11 @@ It is important to ensure that a user can not write or change these configuration files. .Pp -Filter and translation rules are loaded from the file -.Pa /etc/authpf/users/$USER/authpf.rules . -If this file does not exist the file -.Pa /etc/authpf/authpf.rules -is used. The .Pa authpf.rules file must exist in one of the above locations for .Nm to run. -.Pp -Translation rules are also loaded from this file. -The use of translation rules in an -.Pa authpf.rules -file is optional. .Sh CONFIGURATION Options are controlled by the .Pa /etc/authpf/authpf.conf @@ -154,6 +157,10 @@ Use the specified .Pa anchor name instead of "authpf". +.It table=name +Use the specified +.Pa table +name instead of "authpf_users". .El .Sh USER MESSAGES On successful invocation, @@ -218,9 +225,15 @@ hijack the session. Note that TCP keepalives are not sufficient for this, since they are not secure. +Also note that +.Ar AllowTcpForwarding +should be disabled for +.Nm +users to prevent them from circumventing restrictions imposed by the +packet filter ruleset. .Pp .Nm -will remove statetable entries that were created during a user's +will remove state table entries that were created during a user's session. This ensures that there will be no unauthenticated traffic allowed to pass after the controlling @@ -391,15 +404,15 @@ # ssh and use us as a dns server. internal_if="fxp1" gateway_addr="10.0.1.1" -nat-anchor authpf -rdr-anchor authpf -binat-anchor authpf +nat-anchor "authpf/*" +rdr-anchor "authpf/*" +binat-anchor "authpf/*" block in on $internal_if from any to any pass in quick on $internal_if proto tcp from any to $gateway_addr \e port = ssh pass in quick on $internal_if proto udp from any to $gateway_addr \e port = domain -anchor authpf +anchor "authpf/*" .Ed .Pp .Sy For a switched, wired net @@ -465,6 +478,33 @@ 129.128.11.10.60539 > 198.137.240.92.22: S 2131494121:2131494121(0) win \e 16384 (DF) .Ed +.Pp +.Sy Using the authpf_users table +\- Simple +.Nm +settings can be implemented without an anchor by just using the "authpf_users" +.Pa table . +For example, the following +.Xr pf.conf 5 +lines will give SMTP and IMAP access to logged in users: +.Bd -literal +table persist +pass in on $ext_if proto tcp from \e + to port { smtp imap } keep state +.Ed +.Pp +It is also possible to use the "authpf_users" +.Pa table +in combination with anchors. +For example, +.Xr pf 4 +processing can be sped up by looking up the anchor +only for packets coming from logged in users: +.Bd -literal +table persist +anchor "authpf/*" from +rdr-anchor "authpf/*" from +.Ed .Sh FILES .Bl -tag -width "/etc/authpf/authpf.conf" -compact .It Pa /etc/authpf/authpf.conf ==== //depot/projects/trustedbsd/mac/contrib/pf/authpf/authpf.c#3 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $OpenBSD: authpf.c,v 1.75 2004/01/29 01:55:10 deraadt Exp $ */ +/* $OpenBSD: authpf.c,v 1.89 2005/02/10 04:24:15 joel Exp $ */ /* * Copyright (C) 1998 - 2002 Bob Beck (beck@openbsd.org). @@ -26,13 +26,15 @@ */ #include -__FBSDID("$FreeBSD: src/contrib/pf/authpf/authpf.c,v 1.5 2004/06/16 23:39:30 mlaier Exp $"); +__FBSDID("$FreeBSD: src/contrib/pf/authpf/authpf.c,v 1.6 2005/05/03 16:55:19 mlaier Exp $"); #include #include #include #include +#include #include +#include #include #include @@ -40,6 +42,7 @@ #include #include +#include #include #include #include @@ -48,9 +51,6 @@ #include #include -#include -#include - #include "pathnames.h" extern int symset(const char *, const char *, int); @@ -61,11 +61,13 @@ static int check_luser(char *, char *); static int remove_stale_rulesets(void); static int change_filter(int, const char *, const char *); +static int change_table(int, const char *, const char *); static void authpf_kill_states(void); int dev; /* pf device */ char anchorname[PF_ANCHOR_NAME_SIZE] = "authpf"; -char rulesetname[PF_RULESET_NAME_SIZE]; +char rulesetname[MAXPATHLEN - PF_ANCHOR_NAME_SIZE - 2]; +char tablename[PF_TABLE_NAME_SIZE] = "authpf_users"; FILE *pidfp; char *infile; /* file name printed by yyerror() in parse.y */ @@ -94,10 +96,12 @@ { int lockcnt = 0, n, pidfd; FILE *config; - struct in_addr ina; + struct in6_addr ina; struct passwd *pw; char *cp; uid_t uid; + char *shell; + login_cap_t *lc; config = fopen(PATH_CONFFILE, "r"); @@ -121,7 +125,8 @@ exit(1); } *cp = '\0'; - if (inet_pton(AF_INET, ipsrc, &ina) != 1) { + if (inet_pton(AF_INET, ipsrc, &ina) != 1 && + inet_pton(AF_INET6, ipsrc, &ina) != 1) { syslog(LOG_ERR, "cannot determine IP from SSH_CLIENT %s", ipsrc); exit(1); @@ -135,16 +140,31 @@ uid = getuid(); pw = getpwuid(uid); + endpwent(); if (pw == NULL) { syslog(LOG_ERR, "cannot find user for uid %u", uid); goto die; } - if (strcmp(pw->pw_shell, PATH_AUTHPF_SHELL)) { + + if ((lc = login_getclass(pw->pw_class)) != NULL) + shell = (char *)login_getcapstr(lc, "shell", pw->pw_shell, + pw->pw_shell); + else + shell = pw->pw_shell; + + login_close(lc); + + if (strcmp(shell, PATH_AUTHPF_SHELL)) { syslog(LOG_ERR, "wrong shell for user %s, uid %u", pw->pw_name, pw->pw_uid); + if (shell != pw->pw_shell) + free(shell); goto die; } + if (shell != pw->pw_shell) + free(shell); + /* * Paranoia, but this data _does_ come from outside authpf, and * truncation would be bad. @@ -155,11 +175,11 @@ } if ((n = snprintf(rulesetname, sizeof(rulesetname), "%s(%ld)", - luser, (long)getpid())) < 0 || n >= sizeof(rulesetname)) { + luser, (long)getpid())) < 0 || (u_int)n >= sizeof(rulesetname)) { syslog(LOG_INFO, "%s(%ld) too large, ruleset name will be %ld", luser, (long)getpid(), (long)getpid()); if ((n = snprintf(rulesetname, sizeof(rulesetname), "%ld", - (long)getpid())) < 0 || n >= sizeof(rulesetname)) { + (long)getpid())) < 0 || (u_int)n >= sizeof(rulesetname)) { syslog(LOG_ERR, "pid too large for ruleset name"); goto die; } @@ -269,12 +289,17 @@ rewind(pidfp); fprintf(pidfp, "%ld\n%s\n", (long)getpid(), luser); fflush(pidfp); - (void) ftruncate(fileno(pidfp), ftell(pidfp)); + (void) ftruncate(fileno(pidfp), ftello(pidfp)); if (change_filter(1, luser, ipsrc) == -1) { printf("Unable to modify filters\r\n"); do_death(0); } + if (change_table(1, luser, ipsrc) == -1) { + printf("Unable to modify table\r\n"); + change_filter(0, luser, ipsrc); + do_death(0); + } signal(SIGTERM, need_death); signal(SIGINT, need_death); @@ -284,7 +309,7 @@ signal(SIGSTOP, need_death); signal(SIGTSTP, need_death); while (1) { - printf("\r\nHello %s, ", luser); + printf("\r\nHello %s. ", luser); printf("You are authenticated from host \"%s\"\r\n", ipsrc); setproctitle("%s@%s", luser, ipsrc); print_message(PATH_MESSAGE); @@ -359,6 +384,11 @@ sizeof(anchorname)) >= sizeof(anchorname)) goto parse_error; } + if (strcasecmp(pair[0], "table") == 0) { + if (!pair[1][0] || strlcpy(tablename, pair[1], + sizeof(tablename)) >= sizeof(tablename)) + goto parse_error; + } } while (!feof(f) && !ferror(f)); fclose(f); return (0); @@ -542,12 +572,10 @@ remove_stale_rulesets(void) { struct pfioc_ruleset prs; - const int action[PF_RULESET_MAX] = { PF_SCRUB, - PF_PASS, PF_NAT, PF_BINAT, PF_RDR }; u_int32_t nr, mnr; memset(&prs, 0, sizeof(prs)); - strlcpy(prs.anchor, anchorname, sizeof(prs.anchor)); + strlcpy(prs.path, anchorname, sizeof(prs.path)); if (ioctl(dev, DIOCGETRULESETS, &prs)) { if (errno == EINVAL) return (0); @@ -574,20 +602,25 @@ (*s && (t == prs.name || *s != ')'))) return (1); if (kill(pid, 0) && errno != EPERM) { - int i; + int i; + struct pfioc_trans_e t_e[PF_RULESET_MAX+1]; + struct pfioc_trans t; - for (i = 0; i < PF_RULESET_MAX; ++i) { - struct pfioc_rule pr; - - memset(&pr, 0, sizeof(pr)); - memcpy(pr.anchor, prs.anchor, sizeof(pr.anchor)); - memcpy(pr.ruleset, prs.name, sizeof(pr.ruleset)); - pr.rule.action = action[i]; - if ((ioctl(dev, DIOCBEGINRULES, &pr) || - ioctl(dev, DIOCCOMMITRULES, &pr)) && - errno != EINVAL) - return (1); + bzero(&t, sizeof(t)); + bzero(t_e, sizeof(t_e)); + t.size = PF_RULESET_MAX+1; + t.esize = sizeof(t_e[0]); + t.array = t_e; + for (i = 0; i < PF_RULESET_MAX+1; ++i) { + t_e[i].rs_num = i; + snprintf(t_e[i].anchor, sizeof(t_e[i].anchor), + "%s/%s", anchorname, prs.name); } + t_e[PF_RULESET_MAX].rs_num = PF_RULESET_TABLE; + if ((ioctl(dev, DIOCXBEGIN, &t) || + ioctl(dev, DIOCXCOMMIT, &t)) && + errno != EINVAL) + return (1); mnr--; } else nr++; @@ -601,85 +634,67 @@ static int change_filter(int add, const char *luser, const char *ipsrc) { - char fn[MAXPATHLEN]; - FILE *f = NULL; - struct pfctl pf; - struct pfr_buffer t; - int i; + char *pargv[13] = { + "pfctl", "-p", "/dev/pf", "-q", "-a", "anchor/ruleset", + "-D", "user_ip=X", "-D", "user_id=X", "-f", + "file", NULL + }; + char *fdpath = NULL, *userstr = NULL, *ipstr = NULL; + char *rsn = NULL, *fn = NULL; + pid_t pid; + int s; if (luser == NULL || !luser[0] || ipsrc == NULL || !ipsrc[0]) { syslog(LOG_ERR, "invalid luser/ipsrc"); goto error; } + if (asprintf(&rsn, "%s/%s", anchorname, rulesetname) == -1) + goto no_mem; + if (asprintf(&fdpath, "/dev/fd/%d", dev) == -1) + goto no_mem; + if (asprintf(&ipstr, "user_ip=%s", ipsrc) == -1) + goto no_mem; + if (asprintf(&userstr, "user_id=%s", luser) == -1) + goto no_mem; + if (add) { - if ((i = snprintf(fn, sizeof(fn), "%s/%s/authpf.rules", - PATH_USER_DIR, luser)) < 0 || i >= sizeof(fn)) { - syslog(LOG_ERR, "user rule path too long"); - goto error; - } - if ((f = fopen(fn, "r")) == NULL && errno != ENOENT) { - syslog(LOG_ERR, "cannot open %s (%m)", fn); - goto error; - } - if (f == NULL) { - if (strlcpy(fn, PATH_PFRULES, sizeof(fn)) >= - sizeof(fn)) { - syslog(LOG_ERR, "rule path too long"); - goto error; - } - if ((f = fopen(fn, "r")) == NULL) { - syslog(LOG_ERR, "cannot open %s (%m)", fn); - goto error; - } + struct stat sb; + + if (asprintf(&fn, "%s/%s/authpf.rules", PATH_USER_DIR, luser) + == -1) + goto no_mem; + if (stat(fn, &sb) == -1) { + free(fn); + if ((fn = strdup(PATH_PFRULES)) == NULL) + goto no_mem; } } + pargv[2] = fdpath; + pargv[5] = rsn; + pargv[7] = userstr; + pargv[9] = ipstr; + if (!add) + pargv[11] = "/dev/null"; + else + pargv[11] = fn; - if (pfctl_load_fingerprints(dev, 0)) { - syslog(LOG_ERR, "unable to load kernel's OS fingerprints"); - goto error; - } - bzero(&t, sizeof(t)); - t.pfrb_type = PFRB_TRANS; - memset(&pf, 0, sizeof(pf)); - for (i = 0; i < PF_RULESET_MAX; ++i) { - if (pfctl_add_trans(&t, i, anchorname, rulesetname)) { - syslog(LOG_ERR, "pfctl_add_trans %m"); - goto error; - } - } - if (pfctl_trans(dev, &t, DIOCXBEGIN, 0)) { - syslog(LOG_ERR, "DIOCXBEGIN (%s) %m", add?"add":"remove"); - goto error; + switch (pid = fork()) { + case -1: + err(1, "fork failed"); + case 0: + execvp(PATH_PFCTL, pargv); + warn("exec of %s failed", PATH_PFCTL); + _exit(1); } - if (add) { - if (symset("user_ip", ipsrc, 0) || - symset("user_id", luser, 0)) { - syslog(LOG_ERR, "symset"); - goto error; - } - - pf.dev = dev; - pf.trans = &t; - pf.anchor = anchorname; - pf.ruleset = rulesetname; - - infile = fn; - if (parse_rules(f, &pf) < 0) { - syslog(LOG_ERR, "syntax error in rule file: " - "authpf rules not loaded"); + /* parent */ + waitpid(pid, &s, 0); + if (s != 0) { + if (WIFEXITED(s)) { + syslog(LOG_ERR, "pfctl exited abnormally"); goto error; } - - infile = NULL; - fclose(f); - f = NULL; - } - - if (pfctl_trans(dev, &t, DIOCXCOMMIT, 0)) { - syslog(LOG_ERR, "DIOCXCOMMIT (%s) %m", add?"add":"remove"); - goto error; } if (add) { @@ -691,18 +706,63 @@ ipsrc, luser, Tend.tv_sec - Tstart.tv_sec); } return (0); - +no_mem: + syslog(LOG_ERR, "malloc failed"); >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Tue May 3 23:09:39 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8903E16A4D0; Tue, 3 May 2005 23:09:39 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4BA5016A4CE for ; Tue, 3 May 2005 23:09:39 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2788E43D1F for ; Tue, 3 May 2005 23:09:39 +0000 (GMT) (envelope-from trhodes@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43N9btZ090046 for ; Tue, 3 May 2005 23:09:37 GMT (envelope-from trhodes@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43N9aW9090043 for perforce@freebsd.org; Tue, 3 May 2005 23:09:36 GMT (envelope-from trhodes@freebsd.org) Date: Tue, 3 May 2005 23:09:36 GMT Message-Id: <200505032309.j43N9aW9090043@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to trhodes@freebsd.org using -f From: Tom Rhodes To: Perforce Change Reviews Subject: PERFORCE change 76468 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 23:09:40 -0000 http://perforce.freebsd.org/chv.cgi?CH=76468 Change 76468 by trhodes@trhodes_local on 2005/05/03 23:08:52 Move documented event codes from bsm_wrappers.c into a manual page. Add the manual page to the Makefile. This is slightly incomplete and could use review. Affected files ... .. //depot/projects/trustedbsd/openbsm/man/Makefile#3 edit .. //depot/projects/trustedbsd/openbsm/man/event_code.5#1 add Differences ... ==== //depot/projects/trustedbsd/openbsm/man/Makefile#3 (text+ko) ==== @@ -14,6 +14,7 @@ audit_control.5 \ audit_event.5 \ audit_user.5 \ - audit_warn.5 + audit_warn.5 \ + event_code.5 .include From owner-p4-projects@FreeBSD.ORG Tue May 3 23:15:46 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3F0C016A4D0; Tue, 3 May 2005 23:15:46 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 03F4B16A4CE for ; Tue, 3 May 2005 23:15:46 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B8C6943D54 for ; Tue, 3 May 2005 23:15:45 +0000 (GMT) (envelope-from trhodes@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j43NFi6V090413 for ; Tue, 3 May 2005 23:15:45 GMT (envelope-from trhodes@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j43NFiNr090410 for perforce@freebsd.org; Tue, 3 May 2005 23:15:44 GMT (envelope-from trhodes@freebsd.org) Date: Tue, 3 May 2005 23:15:44 GMT Message-Id: <200505032315.j43NFiNr090410@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to trhodes@freebsd.org using -f From: Tom Rhodes To: Perforce Change Reviews Subject: PERFORCE change 76469 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 May 2005 23:15:46 -0000 http://perforce.freebsd.org/chv.cgi?CH=76469 Change 76469 by trhodes@trhodes_local on 2005/05/03 23:15:07 Remove stale XXX comment, this file is named bsm_wrappers.c not lib_wrappers.c and I doubt the new name will change. Remove event codes, now in event_code.5. Use C99 integer identifiers. Affected files ... .. //depot/projects/trustedbsd/openbsm/libbsm/bsm_wrappers.c#7 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/libbsm/bsm_wrappers.c#7 (text+ko) ==== @@ -26,9 +26,6 @@ * POSSIBILITY OF SUCH DAMAGE. */ -/* - * XXX lib_wrappers.c is a provisional name - */ #include #include #include @@ -39,36 +36,9 @@ #include #include -/* - * XXX Write up in a separate white paper. - * -Event code Token type; contents - -AUE_create_user text; "New user [, , , ]" -(In the following, if the short name is changing, use the old shortname -following "Modify user.") -AUE_modify_user text; "Modify user : old = , new = " -AUE_modify_password text; "Modify password for user " -AUE_delete_user text; "Delete user [, , , ]" -AUE_enable_user text; ??? -AUE_disable_user text; ??? -AUE_create_group text; "Add group [, ]" -AUE_delete_group text; "Delete group [, ]" -(In the following, if the name is changing, use the old name following -"Modify group.") -AUE_modify_group text; "Modify group : old = , new = " -AUE_add_to_group text; "Add user to group " -AUE_remove_from_group text; "Removed user from group " -AUE_revoke_obj text; ??? - - -DirectoryServices and netinfod "subatomic" events: -AUE_auth_user text: "Authenticated user " - */ - /* These are not advertised in libbsm.h */ int audit_set_terminal_port(dev_t *p); -int audit_set_terminal_host(u_int32_t *m); +int audit_set_terminal_host(uint32_t *m); int audit_set_terminal_port(dev_t *p) @@ -99,7 +69,7 @@ } int -audit_set_terminal_host(u_int32_t *m) +audit_set_terminal_host(uint32_t *m) { int name[2] = { CTL_KERN, KERN_HOSTID }; size_t len; From owner-p4-projects@FreeBSD.ORG Wed May 4 05:42:16 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0F86D16A4D0; Wed, 4 May 2005 05:42:16 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AD18116A4CE for ; Wed, 4 May 2005 05:42:15 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7BF8543D1D for ; Wed, 4 May 2005 05:42:15 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j445fUde018034 for ; Wed, 4 May 2005 05:41:30 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j445fUJf018031 for perforce@freebsd.org; Wed, 4 May 2005 05:41:30 GMT (envelope-from csjp@freebsd.org) Date: Wed, 4 May 2005 05:41:30 GMT Message-Id: <200505040541.j445fUJf018031@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to csjp@freebsd.org using -f From: "Christian S.J. Peron" To: Perforce Change Reviews Subject: PERFORCE change 76475 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 05:42:17 -0000 http://perforce.freebsd.org/chv.cgi?CH=76475 Change 76475 by csjp@csjp_xor on 2005/05/04 05:41:26 -define constant for the dependency namespace -s/error/error != 0 for logic clarity -add various debug printfs to assist with debugging -move dependency check. This accomplishes two things, first there is no point in wasting the overhead associated with processing dependencies if the initial binary will not pass integrity tests, secondly the return value of the dependency test can clobber the error associated with retrieving checksums. -update userspace bits to use the constant instead of the string Affected files ... .. //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#4 edit .. //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.h#2 edit .. //depot/projects/trustedbsd/mac/usr.sbin/getfhash/getfhash.c#2 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#4 (text+ko) ==== @@ -509,15 +509,15 @@ size_t alen; ASSERT_VOP_LOCKED(vp, "no vlock held"); - error = VOP_GETEXTATTR(vp, MAC_CHKEXEC_ATTRN, "chkexec_depend", + error = VOP_GETEXTATTR(vp, MAC_CHKEXEC_ATTRN, MAC_CHKEXEC_DEP, NULL, &alen, NOCRED, curthread); - if (error && error == ENOATTR) + if (error != 0 && error == ENOATTR) return (0); else if (error) return (error); depends = malloc(alen + 1, M_CHKEXEC, M_WAITOK | M_ZERO); error = vn_extattr_get(vp, IO_NODELOCKED, MAC_CHKEXEC_ATTRN, - "chkexec_depend", &alen, depends, curthread); + MAC_CHKEXEC_DEP, &alen, depends, curthread); for (npaths = 0, ap = paths; (*ap = strsep(&depends, ":")) != NULL; npaths++) if (**ap != '\0') @@ -564,8 +564,12 @@ if ((mp->mnt_flag & MNT_RDONLY) == 1 && !mac_chkexec_enforce) return (0); /* We are only interested in the execution of regular files */ - if (vp->v_type != VREG) + if (vp->v_type != VREG) { +#ifdef DEBUG + printf("mac_chkexec_check: File is not VREG, skipping\n"); +#endif return (0); + } /* * Retrieve the algorithm specified in the sysctl OID. By default * we leave this as SHA1. If the algorithm is invalid, deny access @@ -584,10 +588,7 @@ * Thus we will deny access to this file, erroring on the side of security. */ error = mac_chkexec_get_vcsum(vp, &vcsum); - if (error && error != ENOATTR) - return (error); - error = mac_chkexec_check_depends(vp, cred); - if (error && mac_chkexec_enforce) + if (error != 0 && error != ENOATTR) return (error); /* * If no checksum is present in the file, and we are ignoring @@ -638,6 +639,14 @@ error = mac_chkexec_set_vcsum(vp, &vcsum); return (error); } + /* If the binary itself checks out, then we should check for any + * dependencies it may have. + */ + if (match) { + error = mac_chkexec_check_depends(vp, cred); + if (error && mac_chkexec_enforce) + return (error); + } #ifdef DEBUG if (!match) printf("mac_chkexec: checksum mismatch, denying\n"); ==== //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.h#2 (text+ko) ==== @@ -30,6 +30,7 @@ #define MAC_VCSUM_SHA1 0x00000002 #define MAC_CHKEXEC_ATTRN EXTATTR_NAMESPACE_SYSTEM #define MAC_CHKEXEC "chkexec" +#define MAC_CHKEXEC_DEP "chkexec_depend" #define MAXCSUMSIZE 32 #ifdef _KERNEL ==== //depot/projects/trustedbsd/mac/usr.sbin/getfhash/getfhash.c#2 (text+ko) ==== @@ -58,7 +58,7 @@ ssize_t nbytes; nbytes = extattr_get_file(pathname, MAC_CHKEXEC_ATTRN, - "chkexec_depend", NULL, 0); + MAC_CHKEXEC_DEP, NULL, 0); if (nbytes < 0 && errno == ENOATTR) return; else if (nbytes < 0) { @@ -71,7 +71,7 @@ return; } error = extattr_get_file(pathname, MAC_CHKEXEC_ATTRN, - "chkexec_depend", dependlist, nbytes); + MAC_CHKEXEC_DEP, dependlist, nbytes); dependlist[nbytes] = '\0'; for (ndeps = 0, av = depends; (*av = strsep(&dependlist, ":")) != NULL; ndeps++) @@ -95,7 +95,7 @@ if (rflag) { error = extattr_delete_file(pathname, MAC_CHKEXEC_ATTRN, - "chkexec_depend"); + MAC_CHKEXEC_DEP); if (error < 0) warn("extattr_delete_file failed"); } @@ -105,7 +105,7 @@ return; slen = strlen(mflag); error = extattr_set_file(pathname, MAC_CHKEXEC_ATTRN, - "chkexec_depend", mflag, slen); + MAC_CHKEXEC_DEP, mflag, slen); if (error < 0) warn("extattr_set_file failed"); } From owner-p4-projects@FreeBSD.ORG Wed May 4 09:29:24 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3774A16A4D0; Wed, 4 May 2005 09:29:24 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E261B16A4CE for ; Wed, 4 May 2005 09:29:23 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B6A9F43D8C for ; Wed, 4 May 2005 09:29:23 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j449T32f033178 for ; Wed, 4 May 2005 09:29:03 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j449T3ca033175 for perforce@freebsd.org; Wed, 4 May 2005 09:29:03 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 4 May 2005 09:29:03 GMT Message-Id: <200505040929.j449T3ca033175@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76476 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 09:29:24 -0000 http://perforce.freebsd.org/chv.cgi?CH=76476 Change 76476 by rwatson@rwatson_paprika on 2005/05/04 09:28:24 Synchronize to version of ksem.h committed to CVS. Affected files ... .. //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#7 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#7 (text+ko) ==== @@ -1,13 +1,7 @@ /*- * Copyright (c) 2002 Alfred Perlstein - * Copyright (c) 2003 Networks Associates Technology, Inc. * All rights reserved. * - * This software was developed for the FreeBSD Project in part by Network - * Associates Laboratories, the Security Research Division of Network - * Associates, Inc. under DARPA/SPAWAR contract N66001-01-C-8035 ("CBOSS"), - * as part of the DARPA CHATS research program. - * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -28,24 +22,17 @@ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. + * + * $FreeBSD: src/sys/posix4/ksem.h,v 1.1 2005/05/03 20:21:24 rwatson Exp $ */ -/* - * ksem.h: kernel structure supporing global/inter-process - * POSIX 1003.1b semaphores. This structure was originally a part of the - * src/sys/kern/uipc_sem.c source. It had to be separated to be used with - * the MAC framework and policies. - */ +#ifndef _POSIX4_KSEM_H_ +#define _POSIX4_KSEM_H_ -#ifndef _KSEM_H_ -#define _KSEM_H_ +#ifndef _KERNEL +#error "no user-servicable parts inside" +#endif -#include -#include -#include - -#ifdef _KERNEL - struct kuser { pid_t ku_pid; LIST_ENTRY(kuser) ku_next; @@ -68,5 +55,4 @@ struct label *ks_label; /* MAC label */ }; -#endif /* _KERNEL */ -#endif /* !_KSEM_H */ +#endif /* !_POSIX4_KSEM_H_ */ From owner-p4-projects@FreeBSD.ORG Wed May 4 09:30:27 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6C98C16A4D0; Wed, 4 May 2005 09:30:27 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3208716A4CE for ; Wed, 4 May 2005 09:30:27 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 17B5A43D62 for ; Wed, 4 May 2005 09:30:27 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j449U5o1033228 for ; Wed, 4 May 2005 09:30:05 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j449U5qu033225 for perforce@freebsd.org; Wed, 4 May 2005 09:30:05 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 4 May 2005 09:30:05 GMT Message-Id: <200505040930.j449U5qu033225@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76477 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 09:30:28 -0000 http://perforce.freebsd.org/chv.cgi?CH=76477 Change 76477 by rwatson@rwatson_paprika on 2005/05/04 09:29:05 Remove now-unused ks_mtx. Affected files ... .. //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#8 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#8 (text+ko) ==== @@ -50,7 +50,6 @@ struct cv ks_cv; /* waiters sleep here */ int ks_waiters; /* number of waiters */ LIST_HEAD(, kuser) ks_users; /* pids using this sem */ - struct mtx ks_mtx; /* mutex protecting this semaphore */ int ks_unlinked; /* Whether the named sem is unlinked */ struct label *ks_label; /* MAC label */ }; From owner-p4-projects@FreeBSD.ORG Wed May 4 10:08:34 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id F381A16A4D0; Wed, 4 May 2005 10:08:33 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B148E16A4CE for ; Wed, 4 May 2005 10:08:33 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 801F343D62 for ; Wed, 4 May 2005 10:08:33 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44A7q6E034564 for ; Wed, 4 May 2005 10:07:52 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44A7pNG034561 for perforce@freebsd.org; Wed, 4 May 2005 10:07:51 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 4 May 2005 10:07:51 GMT Message-Id: <200505041007.j44A7pNG034561@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76479 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 10:08:34 -0000 http://perforce.freebsd.org/chv.cgi?CH=76479 Change 76479 by rwatson@rwatson_paprika on 2005/05/04 10:07:40 Remove unused field. Affected files ... .. //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#9 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#9 (text+ko) ==== @@ -50,7 +50,6 @@ struct cv ks_cv; /* waiters sleep here */ int ks_waiters; /* number of waiters */ LIST_HEAD(, kuser) ks_users; /* pids using this sem */ - int ks_unlinked; /* Whether the named sem is unlinked */ struct label *ks_label; /* MAC label */ }; From owner-p4-projects@FreeBSD.ORG Wed May 4 10:09:30 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id BB3E216A4D0; Wed, 4 May 2005 10:09:29 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7F55D16A4CE for ; Wed, 4 May 2005 10:09:29 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5EDC143D39 for ; Wed, 4 May 2005 10:09:29 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44A8sVl034670 for ; Wed, 4 May 2005 10:08:54 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44A8r8a034667 for perforce@freebsd.org; Wed, 4 May 2005 10:08:53 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 4 May 2005 10:08:53 GMT Message-Id: <200505041008.j44A8r8a034667@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76480 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 10:09:30 -0000 http://perforce.freebsd.org/chv.cgi?CH=76480 Change 76480 by rwatson@rwatson_paprika on 2005/05/04 10:08:33 Clean up copyrights. Affected files ... .. //depot/projects/trustedbsd/mac/sys/kern/uipc_sem.c#26 edit .. //depot/projects/trustedbsd/mac/sys/security/mac/mac_posix_sem.c#12 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/kern/uipc_sem.c#26 (text+ko) ==== @@ -1,7 +1,7 @@ /*- * Copyright (c) 2002 Alfred Perlstein + * Copyright (c) 2003-2005 SPARTA, Inc. * Copyright (c) 2005 Robert N. M. Watson - * Copyright (c) 2003-2005 Networks Associates Technology, Inc. * All rights reserved. * * This software was developed for the FreeBSD Project in part by Network ==== //depot/projects/trustedbsd/mac/sys/security/mac/mac_posix_sem.c#12 (text+ko) ==== @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2003-2005 Networks Associates Technology, Inc. + * Copyright (c) 2003-2005 SPARTA, Inc. * All rights reserved. * * This software was developed for the FreeBSD Project in part by Network From owner-p4-projects@FreeBSD.ORG Wed May 4 10:53:10 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B872C16A4D0; Wed, 4 May 2005 10:53:09 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 64ADB16A4CE for ; Wed, 4 May 2005 10:53:09 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id A1B4D43D41 for ; Wed, 4 May 2005 10:53:08 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44AqlA0036574 for ; Wed, 4 May 2005 10:52:47 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44AqlO3036571 for perforce@freebsd.org; Wed, 4 May 2005 10:52:47 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 4 May 2005 10:52:47 GMT Message-Id: <200505041052.j44AqlO3036571@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76482 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 10:53:10 -0000 http://perforce.freebsd.org/chv.cgi?CH=76482 Change 76482 by rwatson@rwatson_tislabs on 2005/05/04 10:52:03 Integrate TrustedBSD base branch, primarily to loop back the merge of POSIX semaphore labeling and access control from FreeBSD CVS. Affected files ... .. //depot/projects/trustedbsd/base/lib/libc/stdio/fopen.3#7 integrate .. //depot/projects/trustedbsd/base/sys/conf/files#85 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/uvisor.c#16 integrate .. //depot/projects/trustedbsd/base/sys/kern/uipc_sem.c#13 integrate .. //depot/projects/trustedbsd/base/sys/modules/sem/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sys/net/bpf.c#33 integrate .. //depot/projects/trustedbsd/base/sys/posix4/ksem.h#2 integrate .. //depot/projects/trustedbsd/base/sys/security/mac/mac_posix_sem.c#1 branch .. //depot/projects/trustedbsd/base/sys/security/mac_biba/mac_biba.c#44 integrate .. //depot/projects/trustedbsd/base/sys/security/mac_mls/mac_mls.c#40 integrate .. //depot/projects/trustedbsd/base/sys/security/mac_stub/mac_stub.c#12 integrate .. //depot/projects/trustedbsd/base/sys/security/mac_test/mac_test.c#36 integrate .. //depot/projects/trustedbsd/base/sys/sys/mac.h#43 integrate .. //depot/projects/trustedbsd/base/sys/sys/mac_policy.h#41 integrate .. //depot/projects/trustedbsd/base/usr.sbin/authpf/Makefile#3 integrate Differences ... ==== //depot/projects/trustedbsd/base/lib/libc/stdio/fopen.3#7 (text+ko) ==== @@ -34,7 +34,7 @@ .\" SUCH DAMAGE. .\" .\" @(#)fopen.3 8.1 (Berkeley) 6/4/93 -.\" $FreeBSD: src/lib/libc/stdio/fopen.3,v 1.18 2003/01/26 10:01:59 tjr Exp $ +.\" $FreeBSD: src/lib/libc/stdio/fopen.3,v 1.19 2005/05/04 08:12:44 des Exp $ .\" .Dd January 26, 2003 .Dt FOPEN 3 @@ -74,7 +74,7 @@ Open for reading and writing. The stream is positioned at the beginning of the file. .It Dq Li w -Truncate file to zero length or create text file for writing. +Truncate to zero length or create text file for writing. The stream is positioned at the beginning of the file. .It Dq Li w+ Open for reading and writing. ==== //depot/projects/trustedbsd/base/sys/conf/files#85 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/files,v 1.1019 2005/04/29 02:40:15 scottl Exp $ +# $FreeBSD: src/sys/conf/files,v 1.1020 2005/05/04 10:39:13 rwatson Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -1733,6 +1733,7 @@ security/mac/mac_label.c optional mac security/mac/mac_net.c optional mac security/mac/mac_pipe.c optional mac +security/mac/mac_posix_sem.c optional mac security/mac/mac_process.c optional mac security/mac/mac_socket.c optional mac security/mac/mac_system.c optional mac ==== //depot/projects/trustedbsd/base/sys/dev/usb/uvisor.c#16 (text+ko) ==== @@ -1,5 +1,5 @@ /* $NetBSD: uvisor.c,v 1.9 2001/01/23 14:04:14 augustss Exp $ */ -/* $FreeBSD: src/sys/dev/usb/uvisor.c,v 1.23 2005/01/06 01:43:29 imp Exp $ */ +/* $FreeBSD: src/sys/dev/usb/uvisor.c,v 1.24 2005/05/04 00:46:24 julian Exp $ */ /* Also already merged from NetBSD: * $NetBSD: uvisor.c,v 1.12 2001/11/13 06:24:57 lukem Exp $ @@ -142,7 +142,19 @@ * Unknown PalmOS stuff. */ #define UVISOR_GET_PALM_INFORMATION 0x04 -#define UVISOR_GET_PALM_INFORMATION_LEN 0x14 +#define UVISOR_GET_PALM_INFORMATION_LEN 0x44 + +struct uvisor_palm_connection_info { + uByte num_ports; + uByte endpoint_numbers_different; + uWord reserved1; + struct { + uDWord port_function_id; + uByte port; + uByte end_point_info; + uWord reserved; + } connections[UVISOR_MAX_CONN]; +}; /* @@ -165,7 +177,7 @@ Static usbd_status uvisor_init(struct uvisor_softc *); -Static usbd_status clie_3_5_init(struct uvisor_softc *); +/*Static usbd_status clie_3_5_init(struct uvisor_softc *);*/ Static void uvisor_close(void *, int); @@ -207,9 +219,11 @@ struct usb_devno uv_dev; u_int16_t uv_flags; #define PALM4 0x0001 +#define VISOR 0x0002 +#define PALM35 0x0004 }; static const struct uvisor_type uvisor_devs[] = { - {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_VISOR }, 0 }, + {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_VISOR }, VISOR }, {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_TREO }, PALM4 }, {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_TREO600 }, PALM4 }, {{ USB_VENDOR_PALM, USB_PRODUCT_PALM_M500 }, PALM4 }, @@ -226,7 +240,7 @@ {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_41 }, PALM4 }, {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_S360 }, PALM4 }, {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_NX60 }, PALM4 }, - {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_35 }, 0 }, + {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_35 }, PALM35 }, /* {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_25 }, PALM4 },*/ }; #define uvisor_lookup(v, p) ((const struct uvisor_type *)usb_lookup(uvisor_devs, v, p)) @@ -342,10 +356,12 @@ ucom->sc_opkthdrlen = 0; ucom->sc_callback = &uvisor_callback; +#if 0 if (uaa->vendor == USB_VENDOR_SONY && uaa->product == USB_PRODUCT_SONY_CLIE_35) err = clie_3_5_init(sc); else +#endif err = uvisor_init(sc); if (err) { @@ -413,22 +429,24 @@ usbd_status err; usb_device_request_t req; struct uvisor_connection_info coninfo; + struct uvisor_palm_connection_info pconinfo; int actlen; uWord avail; char buffer[256]; - DPRINTF(("uvisor_init: getting connection info\n")); - req.bmRequestType = UT_READ_VENDOR_ENDPOINT; - req.bRequest = UVISOR_GET_CONNECTION_INFORMATION; - USETW(req.wValue, 0); - USETW(req.wIndex, 0); - USETW(req.wLength, UVISOR_CONNECTION_INFO_SIZE); - err = usbd_do_request_flags(sc->sc_ucom.sc_udev, &req, &coninfo, - USBD_SHORT_XFER_OK, &actlen, - USBD_DEFAULT_TIMEOUT); - if (err) - return (err); - + if (sc->sc_flags & VISOR) { + DPRINTF(("uvisor_init: getting connection info\n")); + req.bmRequestType = UT_READ_VENDOR_ENDPOINT; + req.bRequest = UVISOR_GET_CONNECTION_INFORMATION; + USETW(req.wValue, 0); + USETW(req.wIndex, 0); + USETW(req.wLength, UVISOR_CONNECTION_INFO_SIZE); + err = usbd_do_request_flags(sc->sc_ucom.sc_udev, &req, &coninfo, + USBD_SHORT_XFER_OK, &actlen, + USBD_DEFAULT_TIMEOUT); + if (err) + return (err); + } #ifdef USB_DEBUG { int i, np; @@ -462,15 +480,29 @@ #endif if (sc->sc_flags & PALM4) { + int port; /* Palm OS 4.0 Hack */ req.bmRequestType = UT_READ_VENDOR_ENDPOINT; req.bRequest = UVISOR_GET_PALM_INFORMATION; USETW(req.wValue, 0); USETW(req.wIndex, 0); USETW(req.wLength, UVISOR_GET_PALM_INFORMATION_LEN); - err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); + err = usbd_do_request_flags(sc->sc_ucom.sc_udev, &req, &pconinfo, + USBD_SHORT_XFER_OK, &actlen, + USBD_DEFAULT_TIMEOUT); if (err) return (err); + + if (pconinfo.endpoint_numbers_different) { + port = pconinfo.connections[0].end_point_info; + sc->sc_ucom.sc_bulkin_no = (port >> 4) | UE_DIR_IN; + sc->sc_ucom.sc_bulkout_no = (port & 0xf) | UE_DIR_OUT; + } else { + port = pconinfo.connections[0].port; + sc->sc_ucom.sc_bulkin_no = port | UE_DIR_IN; + sc->sc_ucom.sc_bulkout_no = port | UE_DIR_OUT; + } +#if 0 req.bmRequestType = UT_READ_VENDOR_ENDPOINT; req.bRequest = UVISOR_GET_PALM_INFORMATION; USETW(req.wValue, 0); @@ -479,8 +511,33 @@ err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); if (err) return (err); +#endif } + if (sc->sc_flags & PALM35) { + /* get the config number */ + DPRINTF(("clie_3_5_init: getting config info\n")); + req.bmRequestType = UT_READ; + req.bRequest = UR_GET_CONFIG; + USETW(req.wValue, 0); + USETW(req.wIndex, 0); + USETW(req.wLength, 1); + err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); + if (err) + return (err); + + /* get the interface number */ + DPRINTF(("clie_3_5_init: get the interface number\n")); + req.bmRequestType = UT_READ_DEVICE; + req.bRequest = UR_GET_INTERFACE; + USETW(req.wValue, 0); + USETW(req.wIndex, 0); + USETW(req.wLength, 1); + err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); + if (err) + return (err); + } + DPRINTF(("uvisor_init: getting available bytes\n")); req.bmRequestType = UT_READ_VENDOR_ENDPOINT; req.bRequest = UVISOR_REQUEST_BYTES_AVAILABLE; @@ -496,6 +553,7 @@ return (err); } +#if 0 usbd_status clie_3_5_init(struct uvisor_softc *sc) { @@ -565,6 +623,7 @@ DPRINTF(("clie_3_5_init: done\n")); return (err); } +#endif void uvisor_close(void *addr, int portno) ==== //depot/projects/trustedbsd/base/sys/kern/uipc_sem.c#13 (text+ko) ==== @@ -1,8 +1,14 @@ /*- * Copyright (c) 2002 Alfred Perlstein + * Copyright (c) 2003-2005 SPARTA, Inc. * Copyright (c) 2005 Robert N. M. Watson * All rights reserved. * + * This software was developed for the FreeBSD Project in part by Network + * Associates Laboratories, the Security Research Division of Network + * Associates, Inc. under DARPA/SPAWAR contract N66001-01-C-8035 ("CBOSS"), + * as part of the DARPA CHATS research program. + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -26,8 +32,9 @@ */ #include -__FBSDID("$FreeBSD: src/sys/kern/uipc_sem.c,v 1.18 2005/05/03 20:21:24 rwatson Exp $"); +__FBSDID("$FreeBSD: src/sys/kern/uipc_sem.c,v 1.19 2005/05/04 10:39:13 rwatson Exp $"); +#include "opt_mac.h" #include "opt_posix.h" #include @@ -47,6 +54,7 @@ #include #include #include +#include #include #include @@ -210,6 +218,10 @@ ret->ks_onlist = 0; cv_init(&ret->ks_cv, "sem"); LIST_INIT(&ret->ks_users); +#ifdef MAC + mac_init_posix_sem(ret); + mac_create_posix_sem(uc, ret); +#endif if (name != NULL) sem_enter(td->td_proc, ret); *ksret = ret; @@ -385,17 +397,20 @@ ksnew->ks_onlist = 1; DP(("sem_create: done, about to unlock...\n")); } - mtx_unlock(&sem_lock); } else { +#ifdef MAC + error = mac_check_posix_sem_open(td->td_ucred, ks); + if (error) + goto err_open; +#endif /* * if we aren't the creator, then enforce permissions. */ error = sem_perm(td, ks); - if (!error) - sem_ref(ks); + if (error) + goto err_open; + sem_ref(ks); mtx_unlock(&sem_lock); - if (error) - return (error); id = SEM_TO_ID(ks); if (dir == UIO_USERSPACE) { error = copyout(&id, idp, sizeof(id)); @@ -411,8 +426,9 @@ sem_enter(td->td_proc, ks); mtx_lock(&sem_lock); sem_rel(ks); - mtx_unlock(&sem_lock); } +err_open: + mtx_unlock(&sem_lock); return (error); } @@ -545,10 +561,17 @@ mtx_lock(&sem_lock); ks = sem_lookup_byname(name); - if (ks == NULL) + if (ks != NULL) { +#ifdef MAC + error = mac_check_posix_sem_unlink(td->td_ucred, ks); + if (error) { + mtx_unlock(&sem_lock); + return (error); + } +#endif + error = sem_perm(td, ks); + } else error = ENOENT; - else - error = sem_perm(td, ks); DP(("sem_unlink: '%s' ks = %p, error = %d\n", name, ks, error)); if (error == 0) { LIST_REMOVE(ks, ks_entry); @@ -620,6 +643,11 @@ error = EINVAL; goto err; } +#ifdef MAC + error = mac_check_posix_sem_post(td->td_ucred, ks); + if (error) + goto err; +#endif if (ks->ks_value == SEM_VALUE_MAX) { error = EOVERFLOW; goto err; @@ -720,6 +748,13 @@ error = EINVAL; goto err; } +#ifdef MAC + error = mac_check_posix_sem_wait(td->td_ucred, ks); + if (error) { + DP(("kern_sem_wait mac failed\n")); + goto err; + } +#endif DP(("kern_sem_wait value = %d, tryflag %d\n", ks->ks_value, tryflag)); if (ks->ks_value == 0) { ks->ks_waiters++; @@ -778,6 +813,13 @@ mtx_unlock(&sem_lock); return (EINVAL); } +#ifdef MAC + error = mac_check_posix_sem_getvalue(td->td_ucred, ks); + if (error) { + mtx_unlock(&sem_lock); + return (error); + } +#endif val = ks->ks_value; mtx_unlock(&sem_lock); error = copyout(&val, uap->val, sizeof(val)); @@ -805,6 +847,11 @@ error = EINVAL; goto err; } +#ifdef MAC + error = mac_check_posix_sem_destroy(td->td_ucred, ks); + if (error) + goto err; +#endif if (ks->ks_waiters != 0) { error = EBUSY; goto err; ==== //depot/projects/trustedbsd/base/sys/modules/sem/Makefile#2 (text+ko) ==== @@ -1,8 +1,8 @@ -# $FreeBSD: src/sys/modules/sem/Makefile,v 1.1 2002/09/19 00:43:32 alfred Exp $ +# $FreeBSD: src/sys/modules/sem/Makefile,v 1.2 2005/05/04 10:39:14 rwatson Exp $ .PATH: ${.CURDIR}/../../kern KMOD= sem -SRCS= uipc_sem.c opt_posix.h +SRCS= uipc_sem.c opt_mac.h opt_posix.h .include ==== //depot/projects/trustedbsd/base/sys/net/bpf.c#33 (text+ko) ==== @@ -33,7 +33,7 @@ * * @(#)bpf.c 8.4 (Berkeley) 1/9/95 * - * $FreeBSD: src/sys/net/bpf.c,v 1.148 2005/03/31 12:19:43 phk Exp $ + * $FreeBSD: src/sys/net/bpf.c,v 1.149 2005/05/04 03:09:28 csjp Exp $ */ #include "opt_bpf.h" @@ -81,12 +81,13 @@ /* * The default read buffer size is patchable. */ +SYSCTL_NODE(_net, OID_AUTO, bpf, CTLFLAG_RW, 0, "bpf sysctl"); static int bpf_bufsize = 4096; -SYSCTL_INT(_debug, OID_AUTO, bpf_bufsize, CTLFLAG_RW, - &bpf_bufsize, 0, ""); +SYSCTL_INT(_net_bpf, OID_AUTO, bufsize, CTLFLAG_RW, + &bpf_bufsize, 0, ""); static int bpf_maxbufsize = BPF_MAXBUFSIZE; -SYSCTL_INT(_debug, OID_AUTO, bpf_maxbufsize, CTLFLAG_RW, - &bpf_maxbufsize, 0, ""); +SYSCTL_INT(_net_bpf, OID_AUTO, maxbufsize, CTLFLAG_RW, + &bpf_maxbufsize, 0, ""); /* * bpf_iflist is a list of BPF interface structures, each corresponding to a @@ -116,6 +117,8 @@ static int bpf_setdlt(struct bpf_d *, u_int); static void filt_bpfdetach(struct knote *); static int filt_bpfread(struct knote *, long); +static void bpf_drvinit(void *); +static void bpf_clone(void *, char *, int, struct cdev **); static d_open_t bpfopen; static d_close_t bpfclose; @@ -523,6 +526,8 @@ bpf_wakeup(d) struct bpf_d *d; { + + BPFD_LOCK_ASSERT(d); if (d->bd_state == BPF_WAITING) { callout_stop(&d->bd_callout); d->bd_state = BPF_IDLE; @@ -1313,6 +1318,7 @@ int hdrlen = d->bd_bif->bif_hdrlen; int do_wakeup = 0; + BPFD_LOCK_ASSERT(d); /* * Figure out how many bytes to move. If the packet is * greater or equal to the snapshot length, transfer that @@ -1586,10 +1592,6 @@ return (bp == NULL ? EINVAL : 0); } -static void bpf_drvinit(void *unused); - -static void bpf_clone(void *arg, char *name, int namelen, struct cdev **dev); - static void bpf_clone(arg, name, namelen, dev) void *arg; ==== //depot/projects/trustedbsd/base/sys/posix4/ksem.h#2 (text+ko) ==== @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/posix4/ksem.h,v 1.1 2005/05/03 20:21:24 rwatson Exp $ + * $FreeBSD: src/sys/posix4/ksem.h,v 1.2 2005/05/04 10:39:14 rwatson Exp $ */ #ifndef _POSIX4_KSEM_H_ @@ -33,6 +33,9 @@ #error "no user-servicable parts inside" #endif +#include +#include + struct kuser { pid_t ku_pid; LIST_ENTRY(kuser) ku_next; @@ -50,6 +53,7 @@ struct cv ks_cv; /* waiters sleep here */ int ks_waiters; /* number of waiters */ LIST_HEAD(, kuser) ks_users; /* pids using this sem */ + struct label *ks_label; /* MAC label */ }; #endif /* !_POSIX4_KSEM_H_ */ ==== //depot/projects/trustedbsd/base/sys/security/mac_biba/mac_biba.c#44 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_biba/mac_biba.c,v 1.84 2005/04/14 16:03:29 csjp Exp $ + * $FreeBSD: src/sys/security/mac_biba/mac_biba.c,v 1.85 2005/05/04 10:39:14 rwatson Exp $ */ /* @@ -65,6 +65,8 @@ #include #include +#include + #include #include @@ -1035,6 +1037,18 @@ } static void +mac_biba_create_posix_sem(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + struct mac_biba *source, *dest; + + source = SLOT(cred->cr_label); + dest = SLOT(ks_label); + + mac_biba_copy_effective(source, dest); +} + +static void mac_biba_create_socket_from_socket(struct socket *oldsocket, struct label *oldsocketlabel, struct socket *newsocket, struct label *newsocketlabel) @@ -2088,6 +2102,42 @@ } static int +mac_biba_check_posix_sem_write(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + struct mac_biba *subj, *obj; + + if (!mac_biba_enabled) + return (0); + + subj = SLOT(cred->cr_label); + obj = SLOT(ks_label); + + if (!mac_biba_dominate_effective(subj, obj)) + return (EACCES); + + return (0); +} + +static int +mac_biba_check_posix_sem_rdonly(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + struct mac_biba *subj, *obj; + + if (!mac_biba_enabled) + return (0); + + subj = SLOT(cred->cr_label); + obj = SLOT(ks_label); + + if (!mac_biba_dominate_effective(obj, subj)) + return (EACCES); + + return (0); +} + +static int mac_biba_check_proc_debug(struct ucred *cred, struct proc *proc) { struct mac_biba *subj, *obj; @@ -3014,6 +3064,7 @@ .mpo_init_mount_label = mac_biba_init_label, .mpo_init_mount_fs_label = mac_biba_init_label, .mpo_init_pipe_label = mac_biba_init_label, + .mpo_init_posix_sem_label = mac_biba_init_label, .mpo_init_socket_label = mac_biba_init_label_waitcheck, .mpo_init_socket_peer_label = mac_biba_init_label_waitcheck, .mpo_init_vnode_label = mac_biba_init_label, @@ -3031,6 +3082,7 @@ .mpo_destroy_mount_label = mac_biba_destroy_label, .mpo_destroy_mount_fs_label = mac_biba_destroy_label, .mpo_destroy_pipe_label = mac_biba_destroy_label, + .mpo_destroy_posix_sem_label = mac_biba_destroy_label, .mpo_destroy_socket_label = mac_biba_destroy_label, .mpo_destroy_socket_peer_label = mac_biba_destroy_label, .mpo_destroy_vnode_label = mac_biba_destroy_label, @@ -3065,6 +3117,7 @@ .mpo_setlabel_vnode_extattr = mac_biba_setlabel_vnode_extattr, .mpo_create_mbuf_from_socket = mac_biba_create_mbuf_from_socket, .mpo_create_pipe = mac_biba_create_pipe, + .mpo_create_posix_sem = mac_biba_create_posix_sem, .mpo_create_socket = mac_biba_create_socket, .mpo_create_socket_from_socket = mac_biba_create_socket_from_socket, .mpo_relabel_pipe = mac_biba_relabel_pipe, @@ -3126,6 +3179,12 @@ .mpo_check_pipe_relabel = mac_biba_check_pipe_relabel, .mpo_check_pipe_stat = mac_biba_check_pipe_stat, .mpo_check_pipe_write = mac_biba_check_pipe_write, + .mpo_check_posix_sem_destroy = mac_biba_check_posix_sem_write, + .mpo_check_posix_sem_getvalue = mac_biba_check_posix_sem_rdonly, + .mpo_check_posix_sem_open = mac_biba_check_posix_sem_write, + .mpo_check_posix_sem_post = mac_biba_check_posix_sem_write, + .mpo_check_posix_sem_unlink = mac_biba_check_posix_sem_write, + .mpo_check_posix_sem_wait = mac_biba_check_posix_sem_write, .mpo_check_proc_debug = mac_biba_check_proc_debug, .mpo_check_proc_sched = mac_biba_check_proc_sched, .mpo_check_proc_signal = mac_biba_check_proc_signal, ==== //depot/projects/trustedbsd/base/sys/security/mac_mls/mac_mls.c#40 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_mls/mac_mls.c,v 1.69 2005/04/14 16:03:29 csjp Exp $ + * $FreeBSD: src/sys/security/mac_mls/mac_mls.c,v 1.70 2005/05/04 10:39:15 rwatson Exp $ */ /* @@ -65,6 +65,8 @@ #include #include +#include + #include #include @@ -1004,6 +1006,18 @@ } static void +mac_mls_create_posix_sem(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + struct mac_mls *source, *dest; + + source = SLOT(cred->cr_label); + dest = SLOT(ks_label); + + mac_mls_copy_effective(source, dest); +} + +static void mac_mls_create_socket_from_socket(struct socket *oldsocket, struct label *oldsocketlabel, struct socket *newsocket, struct label *newsocketlabel) @@ -1975,6 +1989,42 @@ } static int +mac_mls_check_posix_sem_write(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + struct mac_mls *subj, *obj; + + if (!mac_mls_enabled) + return (0); + + subj = SLOT(cred->cr_label); + obj = SLOT(ks_label); + + if (!mac_mls_dominate_effective(obj, subj)) + return (EACCES); + + return (0); +} + +static int +mac_mls_check_posix_sem_rdonly(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + struct mac_mls *subj, *obj; + + if (!mac_mls_enabled) + return (0); + + subj = SLOT(cred->cr_label); + obj = SLOT(ks_label); + + if (!mac_mls_dominate_effective(subj, obj)) + return (EACCES); + + return (0); +} + +static int mac_mls_check_proc_debug(struct ucred *cred, struct proc *proc) { struct mac_mls *subj, *obj; @@ -2788,6 +2838,7 @@ .mpo_init_mount_label = mac_mls_init_label, .mpo_init_mount_fs_label = mac_mls_init_label, .mpo_init_pipe_label = mac_mls_init_label, + .mpo_init_posix_sem_label = mac_mls_init_label, .mpo_init_socket_label = mac_mls_init_label_waitcheck, .mpo_init_socket_peer_label = mac_mls_init_label_waitcheck, .mpo_init_vnode_label = mac_mls_init_label, @@ -2805,6 +2856,7 @@ .mpo_destroy_mount_label = mac_mls_destroy_label, .mpo_destroy_mount_fs_label = mac_mls_destroy_label, .mpo_destroy_pipe_label = mac_mls_destroy_label, + .mpo_destroy_posix_sem_label = mac_mls_destroy_label, .mpo_destroy_socket_label = mac_mls_destroy_label, .mpo_destroy_socket_peer_label = mac_mls_destroy_label, .mpo_destroy_vnode_label = mac_mls_destroy_label, @@ -2839,6 +2891,7 @@ .mpo_setlabel_vnode_extattr = mac_mls_setlabel_vnode_extattr, .mpo_create_mbuf_from_socket = mac_mls_create_mbuf_from_socket, .mpo_create_pipe = mac_mls_create_pipe, + .mpo_create_posix_sem = mac_mls_create_posix_sem, .mpo_create_socket = mac_mls_create_socket, .mpo_create_socket_from_socket = mac_mls_create_socket_from_socket, .mpo_relabel_pipe = mac_mls_relabel_pipe, @@ -2898,6 +2951,12 @@ .mpo_check_pipe_relabel = mac_mls_check_pipe_relabel, .mpo_check_pipe_stat = mac_mls_check_pipe_stat, .mpo_check_pipe_write = mac_mls_check_pipe_write, + .mpo_check_posix_sem_destroy = mac_mls_check_posix_sem_write, + .mpo_check_posix_sem_getvalue = mac_mls_check_posix_sem_rdonly, + .mpo_check_posix_sem_open = mac_mls_check_posix_sem_write, + .mpo_check_posix_sem_post = mac_mls_check_posix_sem_write, + .mpo_check_posix_sem_unlink = mac_mls_check_posix_sem_write, + .mpo_check_posix_sem_wait = mac_mls_check_posix_sem_write, .mpo_check_proc_debug = mac_mls_check_proc_debug, .mpo_check_proc_sched = mac_mls_check_proc_sched, .mpo_check_proc_signal = mac_mls_check_proc_signal, ==== //depot/projects/trustedbsd/base/sys/security/mac_stub/mac_stub.c#12 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_stub/mac_stub.c,v 1.48 2005/04/18 13:36:57 rwatson Exp $ + * $FreeBSD: src/sys/security/mac_stub/mac_stub.c,v 1.49 2005/05/04 10:39:15 rwatson Exp $ */ /* @@ -63,6 +63,8 @@ #include #include +#include + #include #include @@ -273,6 +275,13 @@ } static void +stub_create_posix_sem(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + +} + +static void stub_create_socket_from_socket(struct socket *oldsocket, struct label *oldsocketlabel, struct socket *newsocket, struct label *newsocketlabel) @@ -821,6 +830,54 @@ } static int +stub_check_posix_sem_destroy(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + + return (0); +} + +static int +stub_check_posix_sem_getvalue(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + + return (0); +} + +static int +stub_check_posix_sem_open(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + + return (0); +} + +static int +stub_check_posix_sem_post(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + + return (0); +} + +static int +stub_check_posix_sem_unlink(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + + return (0); +} + +static int +stub_check_posix_sem_wait(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ + + return (0); +} + +static int stub_check_proc_debug(struct ucred *cred, struct proc *proc) { @@ -1326,6 +1383,7 @@ .mpo_init_mount_label = stub_init_label, .mpo_init_mount_fs_label = stub_init_label, .mpo_init_pipe_label = stub_init_label, + .mpo_init_posix_sem_label = stub_init_label, .mpo_init_socket_label = stub_init_label_waitcheck, .mpo_init_socket_peer_label = stub_init_label_waitcheck, .mpo_init_vnode_label = stub_init_label, @@ -1343,6 +1401,7 @@ .mpo_destroy_mount_label = stub_destroy_label, .mpo_destroy_mount_fs_label = stub_destroy_label, .mpo_destroy_pipe_label = stub_destroy_label, + .mpo_destroy_posix_sem_label = stub_destroy_label, .mpo_destroy_socket_label = stub_destroy_label, .mpo_destroy_socket_peer_label = stub_destroy_label, .mpo_destroy_vnode_label = stub_destroy_label, @@ -1381,6 +1440,7 @@ .mpo_update_devfsdirent = stub_update_devfsdirent, .mpo_create_mbuf_from_socket = stub_create_mbuf_from_socket, .mpo_create_pipe = stub_create_pipe, + .mpo_create_posix_sem = stub_create_posix_sem, .mpo_create_socket = stub_create_socket, .mpo_create_socket_from_socket = stub_create_socket_from_socket, .mpo_relabel_pipe = stub_relabel_pipe, @@ -1451,6 +1511,12 @@ .mpo_check_pipe_relabel = stub_check_pipe_relabel, .mpo_check_pipe_stat = stub_check_pipe_stat, .mpo_check_pipe_write = stub_check_pipe_write, + .mpo_check_posix_sem_destroy = stub_check_posix_sem_destroy, + .mpo_check_posix_sem_getvalue = stub_check_posix_sem_getvalue, + .mpo_check_posix_sem_open = stub_check_posix_sem_open, + .mpo_check_posix_sem_post = stub_check_posix_sem_post, + .mpo_check_posix_sem_unlink = stub_check_posix_sem_unlink, + .mpo_check_posix_sem_wait = stub_check_posix_sem_wait, .mpo_check_proc_debug = stub_check_proc_debug, .mpo_check_proc_sched = stub_check_proc_sched, .mpo_check_proc_setuid = stub_check_proc_setuid, ==== //depot/projects/trustedbsd/base/sys/security/mac_test/mac_test.c#36 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_test/mac_test.c,v 1.57 2005/04/18 13:36:57 rwatson Exp $ + * $FreeBSD: src/sys/security/mac_test/mac_test.c,v 1.58 2005/05/04 10:39:15 rwatson Exp $ */ /* @@ -62,6 +62,8 @@ #include #include +#include + #include #include @@ -130,6 +132,8 @@ SLOT(x) == 0, ("%s: Bad SYSVIPCSHM label", __func__ )) #define ASSERT_PIPE_LABEL(x) KASSERT(SLOT(x) == PIPEMAGIC || \ SLOT(x) == 0, ("%s: Bad PIPE label", __func__ )) +#define ASSERT_POSIX_LABEL(x) KASSERT(SLOT(x) == POSIXSEMMAGIC || \ + SLOT(x) == 0, ("%s: Bad POSIX ksem label", __func__ )) #define ASSERT_PROC_LABEL(x) KASSERT(SLOT(x) == PROCMAGIC || \ SLOT(x) == 0, ("%s: Bad PROC label", __func__ )) #define ASSERT_CRED_LABEL(x) KASSERT(SLOT(x) == CREDMAGIC || \ @@ -190,6 +194,9 @@ static int init_count_pipe; SYSCTL_INT(_security_mac_test, OID_AUTO, init_count_pipe, CTLFLAG_RD, &init_count_pipe, 0, "pipe init calls"); +static int init_count_posixsems; +SYSCTL_INT(_security_mac_test, OID_AUTO, init_count_posixsems, CTLFLAG_RD, + &init_count_posixsems, 0, "posix sems init calls"); static int init_count_proc; SYSCTL_INT(_security_mac_test, OID_AUTO, init_count_proc, CTLFLAG_RD, &init_count_proc, 0, "proc init calls"); @@ -247,6 +254,9 @@ static int destroy_count_pipe; SYSCTL_INT(_security_mac_test, OID_AUTO, destroy_count_pipe, CTLFLAG_RD, &destroy_count_pipe, 0, "pipe destroy calls"); +static int destroy_count_posixsems; +SYSCTL_INT(_security_mac_test, OID_AUTO, destroy_count_posixsems, CTLFLAG_RD, + &destroy_count_posixsems, 0, "posix sems destroy calls"); static int destroy_count_proc; SYSCTL_INT(_security_mac_test, OID_AUTO, destroy_count_proc, CTLFLAG_RD, &destroy_count_proc, 0, "proc destroy calls"); @@ -447,6 +457,14 @@ } static void +mac_test_init_posix_sem_label(struct label *label) +{ + + SLOT(label) = POSIXSEMMAGIC; + atomic_add_int(&init_count_posixsems, 1); +} + +static void mac_test_init_proc_label(struct label *label) { @@ -697,6 +715,20 @@ } static void +mac_test_destroy_posix_sem_label(struct label *label) +{ + + if ((SLOT(label) == POSIXSEMMAGIC || SLOT(label) == 0)) { + atomic_add_int(&destroy_count_posixsems, 1); + SLOT(label) = EXMAGIC; + } else if (SLOT(label) == EXMAGIC) { + DEBUGGER("mac_test_destroy_posix_sem: dup destroy"); + } else { + DEBUGGER("mac_test_destroy_posix_sem: corrupted label"); + } +} + +static void mac_test_destroy_proc_label(struct label *label) { @@ -954,6 +986,15 @@ } static void +mac_test_create_posix_sem(struct ucred *cred, struct ksem *ksem, + struct label *posixlabel) +{ + + ASSERT_CRED_LABEL(cred->cr_label); + ASSERT_POSIX_LABEL(posixlabel); +} + +static void mac_test_create_socket_from_socket(struct socket *oldsocket, struct label *oldsocketlabel, struct socket *newsocket, struct label *newsocketlabel) @@ -1677,6 +1718,17 @@ } static int +mac_test_check_posix_sem(struct ucred *cred, struct ksem *ksemptr, + struct label *ks_label) +{ >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Wed May 4 10:56:31 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id BAFFF16A4D0; Wed, 4 May 2005 10:56:30 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7F1A816A4CF for ; Wed, 4 May 2005 10:56:30 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id BEFF043D5C for ; Wed, 4 May 2005 10:56:29 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44AtqFU036971 for ; Wed, 4 May 2005 10:55:52 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44AtpgH036968 for perforce@freebsd.org; Wed, 4 May 2005 10:55:51 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 4 May 2005 10:55:51 GMT Message-Id: <200505041055.j44AtpgH036968@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76483 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 10:56:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=76483 Change 76483 by rwatson@rwatson_tislabs on 2005/05/04 10:55:24 Integrate TrustedBSD MAC branch, primarily to loop back the merge of POSIX semaphore labeling and access control from FreeBSD CVS. Affected files ... .. //depot/projects/trustedbsd/mac/lib/libc/stdio/fopen.3#7 integrate .. //depot/projects/trustedbsd/mac/sys/conf/files#115 integrate .. //depot/projects/trustedbsd/mac/sys/dev/usb/uvisor.c#16 integrate .. //depot/projects/trustedbsd/mac/sys/kern/uipc_sem.c#27 integrate .. //depot/projects/trustedbsd/mac/sys/modules/sem/Makefile#2 integrate .. //depot/projects/trustedbsd/mac/sys/net/bpf.c#37 integrate .. //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#10 integrate .. //depot/projects/trustedbsd/mac/sys/security/mac_biba/mac_biba.c#253 integrate .. //depot/projects/trustedbsd/mac/sys/security/mac_mls/mac_mls.c#206 integrate .. //depot/projects/trustedbsd/mac/sys/security/mac_stub/mac_stub.c#33 integrate .. //depot/projects/trustedbsd/mac/sys/security/mac_test/mac_test.c#146 integrate .. //depot/projects/trustedbsd/mac/sys/sys/mac.h#272 integrate .. //depot/projects/trustedbsd/mac/sys/sys/mac_policy.h#229 integrate .. //depot/projects/trustedbsd/mac/usr.sbin/authpf/Makefile#3 integrate Differences ... ==== //depot/projects/trustedbsd/mac/lib/libc/stdio/fopen.3#7 (text+ko) ==== @@ -34,7 +34,7 @@ .\" SUCH DAMAGE. .\" .\" @(#)fopen.3 8.1 (Berkeley) 6/4/93 -.\" $FreeBSD: src/lib/libc/stdio/fopen.3,v 1.18 2003/01/26 10:01:59 tjr Exp $ +.\" $FreeBSD: src/lib/libc/stdio/fopen.3,v 1.19 2005/05/04 08:12:44 des Exp $ .\" .Dd January 26, 2003 .Dt FOPEN 3 @@ -74,7 +74,7 @@ Open for reading and writing. The stream is positioned at the beginning of the file. .It Dq Li w -Truncate file to zero length or create text file for writing. +Truncate to zero length or create text file for writing. The stream is positioned at the beginning of the file. .It Dq Li w+ Open for reading and writing. ==== //depot/projects/trustedbsd/mac/sys/conf/files#115 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/files,v 1.1019 2005/04/29 02:40:15 scottl Exp $ +# $FreeBSD: src/sys/conf/files,v 1.1020 2005/05/04 10:39:13 rwatson Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and ==== //depot/projects/trustedbsd/mac/sys/dev/usb/uvisor.c#16 (text+ko) ==== @@ -1,5 +1,5 @@ /* $NetBSD: uvisor.c,v 1.9 2001/01/23 14:04:14 augustss Exp $ */ -/* $FreeBSD: src/sys/dev/usb/uvisor.c,v 1.23 2005/01/06 01:43:29 imp Exp $ */ +/* $FreeBSD: src/sys/dev/usb/uvisor.c,v 1.24 2005/05/04 00:46:24 julian Exp $ */ /* Also already merged from NetBSD: * $NetBSD: uvisor.c,v 1.12 2001/11/13 06:24:57 lukem Exp $ @@ -142,7 +142,19 @@ * Unknown PalmOS stuff. */ #define UVISOR_GET_PALM_INFORMATION 0x04 -#define UVISOR_GET_PALM_INFORMATION_LEN 0x14 +#define UVISOR_GET_PALM_INFORMATION_LEN 0x44 + +struct uvisor_palm_connection_info { + uByte num_ports; + uByte endpoint_numbers_different; + uWord reserved1; + struct { + uDWord port_function_id; + uByte port; + uByte end_point_info; + uWord reserved; + } connections[UVISOR_MAX_CONN]; +}; /* @@ -165,7 +177,7 @@ Static usbd_status uvisor_init(struct uvisor_softc *); -Static usbd_status clie_3_5_init(struct uvisor_softc *); +/*Static usbd_status clie_3_5_init(struct uvisor_softc *);*/ Static void uvisor_close(void *, int); @@ -207,9 +219,11 @@ struct usb_devno uv_dev; u_int16_t uv_flags; #define PALM4 0x0001 +#define VISOR 0x0002 +#define PALM35 0x0004 }; static const struct uvisor_type uvisor_devs[] = { - {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_VISOR }, 0 }, + {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_VISOR }, VISOR }, {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_TREO }, PALM4 }, {{ USB_VENDOR_HANDSPRING, USB_PRODUCT_HANDSPRING_TREO600 }, PALM4 }, {{ USB_VENDOR_PALM, USB_PRODUCT_PALM_M500 }, PALM4 }, @@ -226,7 +240,7 @@ {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_41 }, PALM4 }, {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_S360 }, PALM4 }, {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_NX60 }, PALM4 }, - {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_35 }, 0 }, + {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_35 }, PALM35 }, /* {{ USB_VENDOR_SONY, USB_PRODUCT_SONY_CLIE_25 }, PALM4 },*/ }; #define uvisor_lookup(v, p) ((const struct uvisor_type *)usb_lookup(uvisor_devs, v, p)) @@ -342,10 +356,12 @@ ucom->sc_opkthdrlen = 0; ucom->sc_callback = &uvisor_callback; +#if 0 if (uaa->vendor == USB_VENDOR_SONY && uaa->product == USB_PRODUCT_SONY_CLIE_35) err = clie_3_5_init(sc); else +#endif err = uvisor_init(sc); if (err) { @@ -413,22 +429,24 @@ usbd_status err; usb_device_request_t req; struct uvisor_connection_info coninfo; + struct uvisor_palm_connection_info pconinfo; int actlen; uWord avail; char buffer[256]; - DPRINTF(("uvisor_init: getting connection info\n")); - req.bmRequestType = UT_READ_VENDOR_ENDPOINT; - req.bRequest = UVISOR_GET_CONNECTION_INFORMATION; - USETW(req.wValue, 0); - USETW(req.wIndex, 0); - USETW(req.wLength, UVISOR_CONNECTION_INFO_SIZE); - err = usbd_do_request_flags(sc->sc_ucom.sc_udev, &req, &coninfo, - USBD_SHORT_XFER_OK, &actlen, - USBD_DEFAULT_TIMEOUT); - if (err) - return (err); - + if (sc->sc_flags & VISOR) { + DPRINTF(("uvisor_init: getting connection info\n")); + req.bmRequestType = UT_READ_VENDOR_ENDPOINT; + req.bRequest = UVISOR_GET_CONNECTION_INFORMATION; + USETW(req.wValue, 0); + USETW(req.wIndex, 0); + USETW(req.wLength, UVISOR_CONNECTION_INFO_SIZE); + err = usbd_do_request_flags(sc->sc_ucom.sc_udev, &req, &coninfo, + USBD_SHORT_XFER_OK, &actlen, + USBD_DEFAULT_TIMEOUT); + if (err) + return (err); + } #ifdef USB_DEBUG { int i, np; @@ -462,15 +480,29 @@ #endif if (sc->sc_flags & PALM4) { + int port; /* Palm OS 4.0 Hack */ req.bmRequestType = UT_READ_VENDOR_ENDPOINT; req.bRequest = UVISOR_GET_PALM_INFORMATION; USETW(req.wValue, 0); USETW(req.wIndex, 0); USETW(req.wLength, UVISOR_GET_PALM_INFORMATION_LEN); - err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); + err = usbd_do_request_flags(sc->sc_ucom.sc_udev, &req, &pconinfo, + USBD_SHORT_XFER_OK, &actlen, + USBD_DEFAULT_TIMEOUT); if (err) return (err); + + if (pconinfo.endpoint_numbers_different) { + port = pconinfo.connections[0].end_point_info; + sc->sc_ucom.sc_bulkin_no = (port >> 4) | UE_DIR_IN; + sc->sc_ucom.sc_bulkout_no = (port & 0xf) | UE_DIR_OUT; + } else { + port = pconinfo.connections[0].port; + sc->sc_ucom.sc_bulkin_no = port | UE_DIR_IN; + sc->sc_ucom.sc_bulkout_no = port | UE_DIR_OUT; + } +#if 0 req.bmRequestType = UT_READ_VENDOR_ENDPOINT; req.bRequest = UVISOR_GET_PALM_INFORMATION; USETW(req.wValue, 0); @@ -479,8 +511,33 @@ err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); if (err) return (err); +#endif } + if (sc->sc_flags & PALM35) { + /* get the config number */ + DPRINTF(("clie_3_5_init: getting config info\n")); + req.bmRequestType = UT_READ; + req.bRequest = UR_GET_CONFIG; + USETW(req.wValue, 0); + USETW(req.wIndex, 0); + USETW(req.wLength, 1); + err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); + if (err) + return (err); + + /* get the interface number */ + DPRINTF(("clie_3_5_init: get the interface number\n")); + req.bmRequestType = UT_READ_DEVICE; + req.bRequest = UR_GET_INTERFACE; + USETW(req.wValue, 0); + USETW(req.wIndex, 0); + USETW(req.wLength, 1); + err = usbd_do_request(sc->sc_ucom.sc_udev, &req, buffer); + if (err) + return (err); + } + DPRINTF(("uvisor_init: getting available bytes\n")); req.bmRequestType = UT_READ_VENDOR_ENDPOINT; req.bRequest = UVISOR_REQUEST_BYTES_AVAILABLE; @@ -496,6 +553,7 @@ return (err); } +#if 0 usbd_status clie_3_5_init(struct uvisor_softc *sc) { @@ -565,6 +623,7 @@ DPRINTF(("clie_3_5_init: done\n")); return (err); } +#endif void uvisor_close(void *addr, int portno) ==== //depot/projects/trustedbsd/mac/sys/kern/uipc_sem.c#27 (text+ko) ==== @@ -32,7 +32,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/kern/uipc_sem.c,v 1.18 2005/05/03 20:21:24 rwatson Exp $"); +__FBSDID("$FreeBSD: src/sys/kern/uipc_sem.c,v 1.19 2005/05/04 10:39:13 rwatson Exp $"); #include "opt_mac.h" #include "opt_posix.h" ==== //depot/projects/trustedbsd/mac/sys/modules/sem/Makefile#2 (text+ko) ==== @@ -1,8 +1,8 @@ -# $FreeBSD: src/sys/modules/sem/Makefile,v 1.1 2002/09/19 00:43:32 alfred Exp $ +# $FreeBSD: src/sys/modules/sem/Makefile,v 1.2 2005/05/04 10:39:14 rwatson Exp $ .PATH: ${.CURDIR}/../../kern KMOD= sem -SRCS= uipc_sem.c opt_posix.h +SRCS= uipc_sem.c opt_mac.h opt_posix.h .include ==== //depot/projects/trustedbsd/mac/sys/net/bpf.c#37 (text+ko) ==== @@ -33,7 +33,7 @@ * * @(#)bpf.c 8.4 (Berkeley) 1/9/95 * - * $FreeBSD: src/sys/net/bpf.c,v 1.148 2005/03/31 12:19:43 phk Exp $ + * $FreeBSD: src/sys/net/bpf.c,v 1.149 2005/05/04 03:09:28 csjp Exp $ */ #include "opt_bpf.h" @@ -81,12 +81,13 @@ /* * The default read buffer size is patchable. */ +SYSCTL_NODE(_net, OID_AUTO, bpf, CTLFLAG_RW, 0, "bpf sysctl"); static int bpf_bufsize = 4096; -SYSCTL_INT(_debug, OID_AUTO, bpf_bufsize, CTLFLAG_RW, - &bpf_bufsize, 0, ""); +SYSCTL_INT(_net_bpf, OID_AUTO, bufsize, CTLFLAG_RW, + &bpf_bufsize, 0, ""); static int bpf_maxbufsize = BPF_MAXBUFSIZE; -SYSCTL_INT(_debug, OID_AUTO, bpf_maxbufsize, CTLFLAG_RW, - &bpf_maxbufsize, 0, ""); +SYSCTL_INT(_net_bpf, OID_AUTO, maxbufsize, CTLFLAG_RW, + &bpf_maxbufsize, 0, ""); /* * bpf_iflist is a list of BPF interface structures, each corresponding to a @@ -116,6 +117,8 @@ static int bpf_setdlt(struct bpf_d *, u_int); static void filt_bpfdetach(struct knote *); static int filt_bpfread(struct knote *, long); +static void bpf_drvinit(void *); +static void bpf_clone(void *, char *, int, struct cdev **); static d_open_t bpfopen; static d_close_t bpfclose; @@ -523,6 +526,8 @@ bpf_wakeup(d) struct bpf_d *d; { + + BPFD_LOCK_ASSERT(d); if (d->bd_state == BPF_WAITING) { callout_stop(&d->bd_callout); d->bd_state = BPF_IDLE; @@ -1313,6 +1318,7 @@ int hdrlen = d->bd_bif->bif_hdrlen; int do_wakeup = 0; + BPFD_LOCK_ASSERT(d); /* * Figure out how many bytes to move. If the packet is * greater or equal to the snapshot length, transfer that @@ -1586,10 +1592,6 @@ return (bp == NULL ? EINVAL : 0); } -static void bpf_drvinit(void *unused); - -static void bpf_clone(void *arg, char *name, int namelen, struct cdev **dev); - static void bpf_clone(arg, name, namelen, dev) void *arg; ==== //depot/projects/trustedbsd/mac/sys/posix4/ksem.h#10 (text+ko) ==== @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/posix4/ksem.h,v 1.1 2005/05/03 20:21:24 rwatson Exp $ + * $FreeBSD: src/sys/posix4/ksem.h,v 1.2 2005/05/04 10:39:14 rwatson Exp $ */ #ifndef _POSIX4_KSEM_H_ @@ -33,6 +33,9 @@ #error "no user-servicable parts inside" #endif +#include +#include + struct kuser { pid_t ku_pid; LIST_ENTRY(kuser) ku_next; ==== //depot/projects/trustedbsd/mac/sys/security/mac_biba/mac_biba.c#253 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_biba/mac_biba.c,v 1.84 2005/04/14 16:03:29 csjp Exp $ + * $FreeBSD: src/sys/security/mac_biba/mac_biba.c,v 1.85 2005/05/04 10:39:14 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/mac/sys/security/mac_mls/mac_mls.c#206 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_mls/mac_mls.c,v 1.69 2005/04/14 16:03:29 csjp Exp $ + * $FreeBSD: src/sys/security/mac_mls/mac_mls.c,v 1.70 2005/05/04 10:39:15 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/mac/sys/security/mac_stub/mac_stub.c#33 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_stub/mac_stub.c,v 1.48 2005/04/18 13:36:57 rwatson Exp $ + * $FreeBSD: src/sys/security/mac_stub/mac_stub.c,v 1.49 2005/05/04 10:39:15 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/mac/sys/security/mac_test/mac_test.c#146 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/security/mac_test/mac_test.c,v 1.57 2005/04/18 13:36:57 rwatson Exp $ + * $FreeBSD: src/sys/security/mac_test/mac_test.c,v 1.58 2005/05/04 10:39:15 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/mac/sys/sys/mac.h#272 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/sys/mac.h,v 1.63 2005/04/18 13:36:57 rwatson Exp $ + * $FreeBSD: src/sys/sys/mac.h,v 1.64 2005/05/04 10:39:14 rwatson Exp $ */ /* * Userland/kernel interface for Mandatory Access Control. ==== //depot/projects/trustedbsd/mac/sys/sys/mac_policy.h#229 (text+ko) ==== @@ -31,7 +31,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/sys/mac_policy.h,v 1.62 2005/04/18 13:36:57 rwatson Exp $ + * $FreeBSD: src/sys/sys/mac_policy.h,v 1.63 2005/05/04 10:39:14 rwatson Exp $ */ /* * Kernel interface for MAC policy modules. ==== //depot/projects/trustedbsd/mac/usr.sbin/authpf/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/usr.sbin/authpf/Makefile,v 1.2 2005/05/03 16:57:38 mlaier Exp $ +# $FreeBSD: src/usr.sbin/authpf/Makefile,v 1.3 2005/05/04 08:57:12 mlaier Exp $ .PATH: ${.CURDIR}/../../contrib/pf/authpf .PATH: ${.CURDIR}/../../contrib/pf/pfctl @@ -17,6 +17,6 @@ CFLAGS+= -DENABLE_ALTQ LDADD+= -lm -lmd -lutil -DPADD+= ${LIBM} ${LIBMD} +DPADD+= ${LIBM} ${LIBMD} ${LIBUTIL} .include From owner-p4-projects@FreeBSD.ORG Wed May 4 12:37:25 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9347F16A4D0; Wed, 4 May 2005 12:37:24 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4D0FE16A4CE for ; Wed, 4 May 2005 12:37:24 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0E7DF43D73 for ; Wed, 4 May 2005 12:37:24 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44CZqXc042866 for ; Wed, 4 May 2005 12:35:53 GMT (envelope-from davidxu@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44CZqI8042863 for perforce@freebsd.org; Wed, 4 May 2005 12:35:52 GMT (envelope-from davidxu@freebsd.org) Date: Wed, 4 May 2005 12:35:52 GMT Message-Id: <200505041235.j44CZqI8042863@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to davidxu@freebsd.org using -f From: David Xu To: Perforce Change Reviews Subject: PERFORCE change 76485 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 12:37:25 -0000 http://perforce.freebsd.org/chv.cgi?CH=76485 Change 76485 by davidxu@davidxu_alona on 2005/05/04 12:35:17 Allocate enough TCB space for libthr, on Variant II platforms, orignal code only initializes basic tcb, while thread libraries at least need extra pointer to store its per-thread info. Add the extra space to allow libthr to unconditionally access %gs on i386 for its _get_curthread() inline function, this reduces target code size about 1K on i386. Affected files ... .. //depot/projects/davidxu_thread/src/lib/libc/gen/tls.c#5 edit .. //depot/projects/davidxu_thread/src/libexec/rtld-elf/amd64/reloc.c#2 edit .. //depot/projects/davidxu_thread/src/libexec/rtld-elf/i386/reloc.c#3 edit .. //depot/projects/davidxu_thread/src/libexec/rtld-elf/powerpc/reloc.c#2 edit .. //depot/projects/davidxu_thread/src/libexec/rtld-elf/rtld.c#8 edit .. //depot/projects/davidxu_thread/src/libexec/rtld-elf/sparc64/reloc.c#2 edit Differences ... ==== //depot/projects/davidxu_thread/src/lib/libc/gen/tls.c#5 (text+ko) ==== @@ -132,6 +132,7 @@ size = tcbsize; tls = malloc(size); + bzero(tls, size); dtv = malloc(3 * sizeof(Elf_Addr)); *(Elf_Addr **) tls = dtv; @@ -203,6 +204,7 @@ assert(tcbsize >= 2*sizeof(Elf_Addr)); tls = malloc(size + tcbsize); + bzero(tls, size + tcbsize); dtv = malloc(3 * sizeof(Elf_Addr)); segbase = (Elf_Addr)(tls + size); @@ -309,7 +311,13 @@ } } - tls = _rtld_allocate_tls(NULL, 2*sizeof(Elf_Addr), + /* + * Here we allocate large enough tcb for libthr, libthr + * needs another field in tcb to store pthread pointer + * on Variant II tcb, while on Variant I, the size is already + * in tls_static_space. + */ + tls = _rtld_allocate_tls(NULL, 3*sizeof(Elf_Addr), sizeof(Elf_Addr)); _set_tp(tls); ==== //depot/projects/davidxu_thread/src/libexec/rtld-elf/amd64/reloc.c#2 (text+ko) ==== @@ -382,7 +382,7 @@ */ tls_static_space = tls_last_offset + RTLD_STATIC_TLS_EXTRA; amd64_set_fsbase(allocate_tls(objs, 0, - 2*sizeof(Elf_Addr), sizeof(Elf_Addr))); + 3*sizeof(Elf_Addr), sizeof(Elf_Addr))); } void *__tls_get_addr(tls_index *ti) ==== //depot/projects/davidxu_thread/src/libexec/rtld-elf/i386/reloc.c#3 (text+ko) ==== @@ -338,7 +338,7 @@ * use. */ tls_static_space = tls_last_offset + RTLD_STATIC_TLS_EXTRA; - tls = allocate_tls(objs, NULL, 2*sizeof(Elf_Addr), sizeof(Elf_Addr)); + tls = allocate_tls(objs, NULL, 3*sizeof(Elf_Addr), sizeof(Elf_Addr)); #ifndef COMPAT_32BIT error = i386_set_gsbase(tls); ==== //depot/projects/davidxu_thread/src/libexec/rtld-elf/powerpc/reloc.c#2 (text+ko) ==== @@ -556,7 +556,7 @@ tls_static_space = tls_last_offset + tls_last_size + RTLD_STATIC_TLS_EXTRA; - _tp = (Elf_Addr **) ((char *) allocate_tls(list, 0, 8, 8) + _tp = (Elf_Addr **) ((char *) allocate_tls(list, 0, 12, 8) + TLS_TP_OFFSET + TLS_TCB_SIZE); /* ==== //depot/projects/davidxu_thread/src/libexec/rtld-elf/rtld.c#8 (text+ko) ==== @@ -2560,6 +2560,7 @@ size = tls_static_space; tls = malloc(size); + bzero(tls, size); dtv = calloc(1, (tls_max_index + 2) * sizeof(Elf_Addr)); *(Elf_Addr**) tls = dtv; @@ -2657,6 +2658,7 @@ assert(tcbsize >= 2*sizeof(Elf_Addr)); tls = malloc(size + tcbsize); + bzero(tls, size + tcbsize); dtv = calloc(1, (tls_max_index + 2) * sizeof(Elf_Addr)); segbase = (Elf_Addr)(tls + size); ==== //depot/projects/davidxu_thread/src/libexec/rtld-elf/sparc64/reloc.c#2 (text+ko) ==== @@ -729,7 +729,7 @@ * use. */ tls_static_space = tls_last_offset + RTLD_STATIC_TLS_EXTRA; - tp = allocate_tls(objs, NULL, 2*sizeof(Elf_Addr), sizeof(Elf_Addr)); + tp = allocate_tls(objs, NULL, 3*sizeof(Elf_Addr), sizeof(Elf_Addr)); } void *__tls_get_addr(tls_index *ti) From owner-p4-projects@FreeBSD.ORG Wed May 4 12:44:41 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E4D4D16A4D9; Wed, 4 May 2005 12:44:40 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1EFDA16A4E6 for ; Wed, 4 May 2005 12:44:40 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id F084D43D68 for ; Wed, 4 May 2005 12:44:39 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44Ci4nJ043330 for ; Wed, 4 May 2005 12:44:04 GMT (envelope-from davidxu@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44Ci3tH043327 for perforce@freebsd.org; Wed, 4 May 2005 12:44:03 GMT (envelope-from davidxu@freebsd.org) Date: Wed, 4 May 2005 12:44:03 GMT Message-Id: <200505041244.j44Ci3tH043327@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to davidxu@freebsd.org using -f From: David Xu To: Perforce Change Reviews Subject: PERFORCE change 76487 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 12:44:41 -0000 http://perforce.freebsd.org/chv.cgi?CH=76487 Change 76487 by davidxu@davidxu_alona on 2005/05/04 12:43:12 Unconditionally access thread pointer register. Affected files ... .. //depot/projects/davidxu_thread/src/lib/libthr/arch/amd64/include/pthread_md.h#2 edit .. //depot/projects/davidxu_thread/src/lib/libthr/arch/i386/include/pthread_md.h#3 edit .. //depot/projects/davidxu_thread/src/lib/libthr/arch/sparc64/include/pthread_md.h#2 edit Differences ... ==== //depot/projects/davidxu_thread/src/lib/libthr/arch/amd64/include/pthread_md.h#2 (text+ko) ==== @@ -91,13 +91,9 @@ return (TCB_GET64(tcb_self)); } -extern struct pthread *_thr_initial; - static __inline struct pthread * _get_curthread(void) { - if (_thr_initial) - return (TCB_GET64(tcb_thread)); - return (NULL); + return (TCB_GET64(tcb_thread)); } #endif ==== //depot/projects/davidxu_thread/src/lib/libthr/arch/i386/include/pthread_md.h#3 (text+ko) ==== @@ -109,14 +109,10 @@ return (TCB_GET32(tcb_self)); } -extern struct pthread *_thr_initial; - /* Get the current thread. */ static __inline struct pthread * _get_curthread(void) { - if (_thr_initial) - return (TCB_GET32(tcb_thread)); - return (NULL); + return (TCB_GET32(tcb_thread)); } #endif ==== //depot/projects/davidxu_thread/src/lib/libthr/arch/sparc64/include/pthread_md.h#2 (text+ko) ==== @@ -74,14 +74,10 @@ return (_tcb); } -extern struct pthread *_thr_initial; - static __inline struct pthread * _get_curthread(void) { - if (_thr_initial) - return (_tcb->tcb_thread); - return (NULL); + return (_tcb->tcb_thread); } #endif /* _PTHREAD_MD_H_ */ From owner-p4-projects@FreeBSD.ORG Wed May 4 12:49:21 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1349016A4D0; Wed, 4 May 2005 12:49:21 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A32B316A4CE for ; Wed, 4 May 2005 12:49:20 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 590E943D72 for ; Wed, 4 May 2005 12:49:20 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44CnAeG050322 for ; Wed, 4 May 2005 12:49:10 GMT (envelope-from davidxu@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44CnAbI050319 for perforce@freebsd.org; Wed, 4 May 2005 12:49:10 GMT (envelope-from davidxu@freebsd.org) Date: Wed, 4 May 2005 12:49:10 GMT Message-Id: <200505041249.j44CnAbI050319@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to davidxu@freebsd.org using -f From: David Xu To: Perforce Change Reviews Subject: PERFORCE change 76488 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 12:49:21 -0000 http://perforce.freebsd.org/chv.cgi?CH=76488 Change 76488 by davidxu@davidxu_alona on 2005/05/04 12:48:21 Backout tcb size change for powerpc since it is Variant I, no need to change. Affected files ... .. //depot/projects/davidxu_thread/src/libexec/rtld-elf/powerpc/reloc.c#3 edit Differences ... ==== //depot/projects/davidxu_thread/src/libexec/rtld-elf/powerpc/reloc.c#3 (text+ko) ==== @@ -556,7 +556,7 @@ tls_static_space = tls_last_offset + tls_last_size + RTLD_STATIC_TLS_EXTRA; - _tp = (Elf_Addr **) ((char *) allocate_tls(list, 0, 12, 8) + _tp = (Elf_Addr **) ((char *) allocate_tls(list, 0, 8, 8) + TLS_TP_OFFSET + TLS_TCB_SIZE); /* From owner-p4-projects@FreeBSD.ORG Wed May 4 17:15:08 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E606A16A4D0; Wed, 4 May 2005 17:15:07 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A73C616A4CE for ; Wed, 4 May 2005 17:15:07 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6D8A343D5F for ; Wed, 4 May 2005 17:15:07 +0000 (GMT) (envelope-from scottl@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44HEhif072039 for ; Wed, 4 May 2005 17:14:43 GMT (envelope-from scottl@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44HEhL4072036 for perforce@freebsd.org; Wed, 4 May 2005 17:14:43 GMT (envelope-from scottl@freebsd.org) Date: Wed, 4 May 2005 17:14:43 GMT Message-Id: <200505041714.j44HEhL4072036@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to scottl@freebsd.org using -f From: Scott Long To: Perforce Change Reviews Subject: PERFORCE change 76512 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 17:15:08 -0000 http://perforce.freebsd.org/chv.cgi?CH=76512 Change 76512 by scottl@scottl-x64 on 2005/05/04 17:14:40 Remove debugging options from the MAC kernel. Affected files ... .. //depot/projects/trustedbsd/sebsd/sys/i386/conf/MAC#15 edit Differences ... ==== //depot/projects/trustedbsd/sebsd/sys/i386/conf/MAC#15 (text+ko) ==== @@ -2,10 +2,8 @@ ident MAC options BREAK_TO_DEBUGGER +options KDB_UNATTENDED options MAC -#options MAC_ALWAYS_LABEL_MBUF -options MAC_DEBUG -options MAC_TEST -#options MAC_STATIC -options UFS_EXTATTR -options UFS_EXTATTR_AUTOSTART + +nooption INVARIANTS +nooption WITNESS From owner-p4-projects@FreeBSD.ORG Wed May 4 21:56:08 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 87EE816A4D0; Wed, 4 May 2005 21:56:07 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5D29116A4CE for ; Wed, 4 May 2005 21:56:07 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 334EC43D4C for ; Wed, 4 May 2005 21:56:07 +0000 (GMT) (envelope-from peter@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44LtPQ0089766 for ; Wed, 4 May 2005 21:55:25 GMT (envelope-from peter@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44LtPkH089763 for perforce@freebsd.org; Wed, 4 May 2005 21:55:25 GMT (envelope-from peter@freebsd.org) Date: Wed, 4 May 2005 21:55:25 GMT Message-Id: <200505042155.j44LtPkH089763@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to peter@freebsd.org using -f From: Peter Wemm To: Perforce Change Reviews Subject: PERFORCE change 76522 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 21:56:08 -0000 http://perforce.freebsd.org/chv.cgi?CH=76522 Change 76522 by peter@peter_hammer on 2005/05/04 21:54:57 Fix file(1) for all 64 bit freebsd's. Sigh. Affected files ... .. //depot/projects/hammer/contrib/file/readelf.c#6 edit Differences ... ==== //depot/projects/hammer/contrib/file/readelf.c#6 (text+ko) ==== @@ -176,6 +176,7 @@ }; size_t prpsoffsets64[] = { + 16, /* FreeBSD, 64-bit */ 120, /* SunOS 5.x, 64-bit */ }; From owner-p4-projects@FreeBSD.ORG Wed May 4 22:02:10 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3DAF416A4D0; Wed, 4 May 2005 22:02:10 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 032AC16A4CE for ; Wed, 4 May 2005 22:02:10 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D0E2943D72 for ; Wed, 4 May 2005 22:02:09 +0000 (GMT) (envelope-from peter@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j44M1Xi9089998 for ; Wed, 4 May 2005 22:01:33 GMT (envelope-from peter@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j44M1Wiv089995 for perforce@freebsd.org; Wed, 4 May 2005 22:01:32 GMT (envelope-from peter@freebsd.org) Date: Wed, 4 May 2005 22:01:32 GMT Message-Id: <200505042201.j44M1Wiv089995@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to peter@freebsd.org using -f From: Peter Wemm To: Perforce Change Reviews Subject: PERFORCE change 76523 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 May 2005 22:02:11 -0000 http://perforce.freebsd.org/chv.cgi?CH=76523 Change 76523 by peter@peter_hammer on 2005/05/04 22:00:55 Do valid 32 bit coredumps for 32 bit apps so that gdb can read them. Affected files ... .. //depot/projects/hammer/sys/amd64/ia32/ia32_reg.c#1 add .. //depot/projects/hammer/sys/compat/ia32/ia32_reg.h#1 add .. //depot/projects/hammer/sys/conf/files.amd64#68 edit .. //depot/projects/hammer/sys/kern/imgact_elf.c#27 edit Differences ... ==== //depot/projects/hammer/sys/conf/files.amd64#68 (text+ko) ==== @@ -185,6 +185,7 @@ # IA32 binary support # #amd64/ia32/ia32_exception.S optional compat_ia32 +amd64/ia32/ia32_reg.c optional compat_ia32 amd64/ia32/ia32_signal.c optional compat_ia32 amd64/ia32/ia32_sigtramp.S optional compat_ia32 amd64/ia32/ia32_syscall.c optional compat_ia32 ==== //depot/projects/hammer/sys/kern/imgact_elf.c#27 (text+ko) ==== @@ -66,6 +66,11 @@ #include #include +#if defined(__amd64__) && __ELF_WORD_SIZE == 32 +#include +#include +#endif + #define OLD_EI_BRAND 8 static int __elfN(check_header)(const Elf_Ehdr *hdr); @@ -1124,17 +1129,31 @@ td)); /* XXXKSE */ } +#if defined(__amd64__) && __ELF_WORD_SIZE == 32 +typedef struct prstatus32 elf_prstatus_t; +typedef struct prpsinfo32 elf_prpsinfo_t; +typedef struct fpreg32 elf_prfpregset_t; +typedef struct fpreg32 elf_fpregset_t; +typedef struct reg32 elf_gregset_t; +#else +typedef prstatus_t elf_prstatus_t; +typedef prpsinfo_t elf_prpsinfo_t; +typedef prfpregset_t elf_prfpregset_t; +typedef prfpregset_t elf_fpregset_t; +typedef gregset_t elf_gregset_t; +#endif + static void __elfN(puthdr)(struct thread *td, void *dst, size_t *off, int numsegs) { struct { - prstatus_t status; - prfpregset_t fpregset; - prpsinfo_t psinfo; + elf_prstatus_t status; + elf_prfpregset_t fpregset; + elf_prpsinfo_t psinfo; } *tempdata; - prstatus_t *status; - prfpregset_t *fpregset; - prpsinfo_t *psinfo; + elf_prstatus_t *status; + elf_prfpregset_t *fpregset; + elf_prpsinfo_t *psinfo; struct proc *p; struct thread *thr; size_t ehoff, noteoff, notesz, phoff; @@ -1166,7 +1185,7 @@ if (dst != NULL) { psinfo->pr_version = PRPSINFO_VERSION; - psinfo->pr_psinfosz = sizeof(prpsinfo_t); + psinfo->pr_psinfosz = sizeof(elf_prpsinfo_t); strlcpy(psinfo->pr_fname, p->p_comm, sizeof(psinfo->pr_fname)); /* * XXX - We don't fill in the command line arguments properly @@ -1188,14 +1207,19 @@ while (thr != NULL) { if (dst != NULL) { status->pr_version = PRSTATUS_VERSION; - status->pr_statussz = sizeof(prstatus_t); - status->pr_gregsetsz = sizeof(gregset_t); - status->pr_fpregsetsz = sizeof(fpregset_t); + status->pr_statussz = sizeof(elf_prstatus_t); + status->pr_gregsetsz = sizeof(elf_gregset_t); + status->pr_fpregsetsz = sizeof(elf_fpregset_t); status->pr_osreldate = osreldate; status->pr_cursig = p->p_sig; status->pr_pid = thr->td_tid; +#if defined(__amd64__) && __ELF_WORD_SIZE == 32 + fill_regs32(thr, &status->pr_reg); + fill_fpregs32(thr, fpregset); +#else fill_regs(thr, &status->pr_reg); fill_fpregs(thr, fpregset); +#endif } __elfN(putnote)(dst, off, "FreeBSD", NT_PRSTATUS, status, sizeof *status); @@ -1241,7 +1265,11 @@ ehdr->e_ident[EI_ABIVERSION] = 0; ehdr->e_ident[EI_PAD] = 0; ehdr->e_type = ET_CORE; +#if defined(__amd64__) && __ELF_WORD_SIZE == 32 + ehdr->e_machine = EM_386; +#else ehdr->e_machine = ELF_ARCH; +#endif ehdr->e_version = EV_CURRENT; ehdr->e_entry = 0; ehdr->e_phoff = phoff; From owner-p4-projects@FreeBSD.ORG Thu May 5 03:09:53 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 4F45016A4D0; Thu, 5 May 2005 03:09:53 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0189416A4CE for ; Thu, 5 May 2005 03:09:53 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0627C43D39 for ; Thu, 5 May 2005 03:09:52 +0000 (GMT) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j4530dcI008318 for ; Thu, 5 May 2005 03:00:39 GMT (envelope-from marcel@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j4530cpB008315 for perforce@freebsd.org; Thu, 5 May 2005 03:00:38 GMT (envelope-from marcel@freebsd.org) Date: Thu, 5 May 2005 03:00:38 GMT Message-Id: <200505050300.j4530cpB008315@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to marcel@freebsd.org using -f From: Marcel Moolenaar To: Perforce Change Reviews Subject: PERFORCE change 76534 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 03:09:54 -0000 http://perforce.freebsd.org/chv.cgi?CH=76534 Change 76534 by marcel@marcel_nfs on 2005/05/05 03:00:15 IFC @76533 Affected files ... .. //depot/projects/tty/Makefile.inc1#18 integrate .. //depot/projects/tty/UPDATING#15 integrate .. //depot/projects/tty/bin/csh/config.h#5 integrate .. //depot/projects/tty/contrib/pf/authpf/authpf.8#3 integrate .. //depot/projects/tty/contrib/pf/authpf/authpf.c#3 integrate .. //depot/projects/tty/contrib/pf/authpf/pathnames.h#2 integrate .. //depot/projects/tty/contrib/pf/ftp-proxy/ftp-proxy.8#3 integrate .. //depot/projects/tty/contrib/pf/ftp-proxy/ftp-proxy.c#3 integrate .. //depot/projects/tty/contrib/pf/ftp-proxy/getline.c#2 integrate .. //depot/projects/tty/contrib/pf/ftp-proxy/util.c#3 integrate .. //depot/projects/tty/contrib/pf/ftp-proxy/util.h#2 integrate .. //depot/projects/tty/contrib/pf/man/pf.4#5 integrate .. //depot/projects/tty/contrib/pf/man/pf.conf.5#5 integrate .. //depot/projects/tty/contrib/pf/man/pf.os.5#3 integrate .. //depot/projects/tty/contrib/pf/man/pflog.4#3 integrate .. //depot/projects/tty/contrib/pf/man/pfsync.4#4 integrate .. //depot/projects/tty/contrib/pf/pfctl/parse.y#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pf_print_state.c#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl.8#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl.c#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl.h#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl_altq.c#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl_optimize.c#1 branch .. //depot/projects/tty/contrib/pf/pfctl/pfctl_osfp.c#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl_parser.c#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl_parser.h#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl_qstats.c#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl_radix.c#3 integrate .. //depot/projects/tty/contrib/pf/pfctl/pfctl_table.c#3 integrate .. //depot/projects/tty/contrib/pf/pflogd/pflogd.8#3 integrate .. //depot/projects/tty/contrib/pf/pflogd/pflogd.c#4 integrate .. //depot/projects/tty/contrib/pf/pflogd/pidfile.c#3 integrate .. //depot/projects/tty/contrib/pf/pflogd/privsep.c#2 integrate .. //depot/projects/tty/contrib/pf/pflogd/privsep_fdpass.c#2 integrate .. //depot/projects/tty/contrib/smbfs/lib/smb/ctx.c#4 integrate .. //depot/projects/tty/games/caesar/Makefile#2 integrate .. //depot/projects/tty/games/caesar/caesar.c#3 integrate .. //depot/projects/tty/games/pom/Makefile#2 integrate .. //depot/projects/tty/games/pom/pom.c#3 integrate .. //depot/projects/tty/gnu/lib/libobjc/Makefile#8 integrate .. //depot/projects/tty/lib/libalias/HISTORY#2 delete .. //depot/projects/tty/lib/libalias/Makefile#8 integrate .. //depot/projects/tty/lib/libalias/alias.c#7 delete .. //depot/projects/tty/lib/libalias/alias.h#6 delete .. //depot/projects/tty/lib/libalias/alias_cuseeme.c#4 delete .. //depot/projects/tty/lib/libalias/alias_db.c#7 delete .. //depot/projects/tty/lib/libalias/alias_ftp.c#4 delete .. //depot/projects/tty/lib/libalias/alias_irc.c#4 delete .. //depot/projects/tty/lib/libalias/alias_local.h#5 delete .. //depot/projects/tty/lib/libalias/alias_nbt.c#4 delete .. //depot/projects/tty/lib/libalias/alias_old.c#4 delete .. //depot/projects/tty/lib/libalias/alias_pptp.c#4 delete .. //depot/projects/tty/lib/libalias/alias_proxy.c#4 delete .. //depot/projects/tty/lib/libalias/alias_skinny.c#5 delete .. //depot/projects/tty/lib/libalias/alias_smedia.c#4 delete .. //depot/projects/tty/lib/libalias/alias_util.c#4 delete .. //depot/projects/tty/lib/libalias/libalias.3#8 delete .. //depot/projects/tty/lib/libc/gen/getbootfile.c#3 integrate .. //depot/projects/tty/lib/libc/gen/getgrouplist.c#3 integrate .. //depot/projects/tty/lib/libc/net/getaddrinfo.c#11 integrate .. //depot/projects/tty/lib/libc/net/gethostbynis.c#5 integrate .. //depot/projects/tty/lib/libc/net/getnameinfo.c#4 integrate .. //depot/projects/tty/lib/libc/net/name6.c#11 integrate .. //depot/projects/tty/lib/libc/stdio/fopen.3#3 integrate .. //depot/projects/tty/lib/libc/sys/accept.2#5 integrate .. //depot/projects/tty/lib/libc/yp/yplib.c#4 integrate .. //depot/projects/tty/lib/libpmc/Makefile#2 integrate .. //depot/projects/tty/lib/libpmc/libpmc.c#2 integrate .. //depot/projects/tty/lib/libpmc/pmc.3#2 integrate .. //depot/projects/tty/lib/libpmc/pmc.h#2 integrate .. //depot/projects/tty/release/Makefile#16 integrate .. //depot/projects/tty/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#20 integrate .. //depot/projects/tty/release/doc/zh_CN.GB2312/relnotes/common/new.sgml#3 integrate .. //depot/projects/tty/release/scripts/package-split.py#2 integrate .. //depot/projects/tty/release/scripts/package-trees.sh#2 integrate .. //depot/projects/tty/sbin/atm/atm/atm.h#3 integrate .. //depot/projects/tty/sbin/atm/atmconfig/atmconfig_device.h#2 integrate .. //depot/projects/tty/sbin/atm/ilmid/ilmid.c#5 integrate .. //depot/projects/tty/sbin/dump/traverse.c#6 integrate .. //depot/projects/tty/sbin/fdisk/fdisk.c#8 integrate .. //depot/projects/tty/sbin/fdisk_pc98/Makefile#4 integrate .. //depot/projects/tty/sbin/fdisk_pc98/fdisk.c#5 integrate .. //depot/projects/tty/sbin/ggate/shared/ggate.h#2 integrate .. //depot/projects/tty/sbin/ifconfig/ifpfsync.c#2 integrate .. //depot/projects/tty/sbin/ipfw/ipfw.8#13 integrate .. //depot/projects/tty/sbin/kldstat/kldstat.8#3 integrate .. //depot/projects/tty/sbin/kldstat/kldstat.c#4 integrate .. //depot/projects/tty/sbin/natd/natd.c#8 integrate .. //depot/projects/tty/sbin/pfctl/Makefile#4 integrate .. //depot/projects/tty/share/dict/freebsd#4 integrate .. //depot/projects/tty/share/man/man4/hwpmc.4#2 integrate .. //depot/projects/tty/share/man/man5/rc.conf.5#17 integrate .. //depot/projects/tty/share/man/man9/taskqueue.9#7 integrate .. //depot/projects/tty/sys/amd64/amd64/machdep.c#12 integrate .. //depot/projects/tty/sys/conf/files#23 integrate .. //depot/projects/tty/sys/conf/options.pc98#12 integrate .. //depot/projects/tty/sys/contrib/pf/net/if_pflog.c#4 integrate .. //depot/projects/tty/sys/contrib/pf/net/if_pflog.h#3 integrate .. //depot/projects/tty/sys/contrib/pf/net/if_pfsync.c#5 integrate .. //depot/projects/tty/sys/contrib/pf/net/if_pfsync.h#3 integrate .. //depot/projects/tty/sys/contrib/pf/net/pf.c#5 integrate .. //depot/projects/tty/sys/contrib/pf/net/pf_if.c#4 integrate .. //depot/projects/tty/sys/contrib/pf/net/pf_ioctl.c#5 integrate .. //depot/projects/tty/sys/contrib/pf/net/pf_norm.c#3 integrate .. //depot/projects/tty/sys/contrib/pf/net/pf_osfp.c#3 integrate .. //depot/projects/tty/sys/contrib/pf/net/pf_subr.c#2 integrate .. //depot/projects/tty/sys/contrib/pf/net/pf_table.c#3 integrate .. //depot/projects/tty/sys/contrib/pf/net/pfvar.h#4 integrate .. //depot/projects/tty/sys/dev/aac/aac_disk.c#9 integrate .. //depot/projects/tty/sys/dev/arcmsr/arcmsr.c#3 integrate .. //depot/projects/tty/sys/dev/ata/ata-all.c#18 integrate .. //depot/projects/tty/sys/dev/ata/ata-all.h#15 integrate .. //depot/projects/tty/sys/dev/ata/ata-chipset.c#16 integrate .. //depot/projects/tty/sys/dev/ata/ata-dma.c#12 integrate .. //depot/projects/tty/sys/dev/ata/ata-lowlevel.c#10 integrate .. //depot/projects/tty/sys/dev/ata/ata-pci.c#14 integrate .. //depot/projects/tty/sys/dev/ata/ata-queue.c#8 integrate .. //depot/projects/tty/sys/dev/ata/ata-raid.c#16 integrate .. //depot/projects/tty/sys/dev/ata/ata-raid.h#10 integrate .. //depot/projects/tty/sys/dev/ata/atapi-cd.c#14 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_amd.c#3 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_intel.c#2 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_mod.c#3 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_piv.c#3 integrate .. //depot/projects/tty/sys/dev/hwpmc/hwpmc_ppro.c#3 integrate .. //depot/projects/tty/sys/dev/usb/uvisor.c#10 integrate .. //depot/projects/tty/sys/fs/devfs/devfs_vnops.c#11 integrate .. //depot/projects/tty/sys/fs/smbfs/smbfs_smb.c#6 integrate .. //depot/projects/tty/sys/fs/smbfs/smbfs_subr.c#5 integrate .. //depot/projects/tty/sys/fs/smbfs/smbfs_subr.h#4 integrate .. //depot/projects/tty/sys/fs/unionfs/union_vnops.c#9 integrate .. //depot/projects/tty/sys/geom/geom_pc98_enc.c#3 integrate .. //depot/projects/tty/sys/i386/include/pmc_mdep.h#3 integrate .. //depot/projects/tty/sys/kern/imgact_aout.c#7 integrate .. //depot/projects/tty/sys/kern/imgact_elf.c#10 integrate .. //depot/projects/tty/sys/kern/kern_descrip.c#13 integrate .. //depot/projects/tty/sys/kern/kern_exec.c#16 integrate .. //depot/projects/tty/sys/kern/subr_devstat.c#9 integrate .. //depot/projects/tty/sys/kern/subr_taskqueue.c#9 integrate .. //depot/projects/tty/sys/kern/uipc_mbuf.c#10 integrate .. //depot/projects/tty/sys/kern/uipc_sem.c#8 integrate .. //depot/projects/tty/sys/kern/uipc_syscalls.c#15 integrate .. //depot/projects/tty/sys/kern/vfs_cluster.c#14 integrate .. //depot/projects/tty/sys/kern/vfs_default.c#14 integrate .. //depot/projects/tty/sys/kern/vfs_mount.c#13 integrate .. //depot/projects/tty/sys/kern/vfs_subr.c#16 integrate .. //depot/projects/tty/sys/modules/sem/Makefile#2 integrate .. //depot/projects/tty/sys/net/bpf.c#12 integrate .. //depot/projects/tty/sys/net/if_tap.c#10 integrate .. //depot/projects/tty/sys/net/if_tun.c#11 integrate .. //depot/projects/tty/sys/netgraph/ng_device.c#8 integrate .. //depot/projects/tty/sys/netinet/ip_dummynet.c#11 integrate .. //depot/projects/tty/sys/netinet/ip_fastfwd.c#6 integrate .. //depot/projects/tty/sys/netinet/ip_fw.h#9 integrate .. //depot/projects/tty/sys/netinet/ip_fw2.c#13 integrate .. //depot/projects/tty/sys/netinet/ip_icmp.c#12 integrate .. //depot/projects/tty/sys/netinet/ip_icmp.h#7 integrate .. //depot/projects/tty/sys/netinet/ip_input.c#15 integrate .. //depot/projects/tty/sys/netinet/libalias/Makefile#2 delete .. //depot/projects/tty/sys/netinet/libalias/alias_db.c#2 integrate .. //depot/projects/tty/sys/netinet/tcp_subr.c#14 integrate .. //depot/projects/tty/sys/netinet/tcp_usrreq.c#10 integrate .. //depot/projects/tty/sys/nfsclient/nfs_socket.c#13 integrate .. //depot/projects/tty/sys/nfsclient/nfs_vfsops.c#14 integrate .. //depot/projects/tty/sys/pc98/conf/NOTES#12 integrate .. //depot/projects/tty/sys/posix4/ksem.h#1 branch .. //depot/projects/tty/sys/powerpc/conf/GENERIC#10 integrate .. //depot/projects/tty/sys/powerpc/powermac/ata_kauai.c#5 integrate .. //depot/projects/tty/sys/powerpc/powermac/ata_macio.c#10 integrate .. //depot/projects/tty/sys/security/mac/mac_posix_sem.c#1 branch .. //depot/projects/tty/sys/security/mac_biba/mac_biba.c#13 integrate .. //depot/projects/tty/sys/security/mac_mls/mac_mls.c#13 integrate .. //depot/projects/tty/sys/security/mac_stub/mac_stub.c#7 integrate .. //depot/projects/tty/sys/security/mac_test/mac_test.c#10 integrate .. //depot/projects/tty/sys/sys/diskpc98.h#5 integrate .. //depot/projects/tty/sys/sys/mac.h#12 integrate .. //depot/projects/tty/sys/sys/mac_policy.h#10 integrate .. //depot/projects/tty/sys/sys/mbuf.h#14 integrate .. //depot/projects/tty/sys/sys/param.h#16 integrate .. //depot/projects/tty/sys/sys/pmc.h#3 integrate .. //depot/projects/tty/sys/sys/taskqueue.h#8 integrate .. //depot/projects/tty/sys/ufs/ffs/ffs_softdep.c#11 integrate .. //depot/projects/tty/sys/vm/vm_fault.c#10 integrate .. //depot/projects/tty/sys/vm/vm_map.c#12 integrate .. //depot/projects/tty/sys/vm/vm_object.c#15 integrate .. //depot/projects/tty/sys/vm/vm_object.h#14 integrate .. //depot/projects/tty/sys/vm/vnode_pager.c#12 integrate .. //depot/projects/tty/tools/regression/lib/libc/resolv/Makefile#1 branch .. //depot/projects/tty/tools/regression/lib/libc/resolv/mach#1 branch .. //depot/projects/tty/tools/regression/lib/libc/resolv/resolv.c#1 branch .. //depot/projects/tty/usr.bin/Makefile#14 integrate .. //depot/projects/tty/usr.bin/brandelf/brandelf.c#2 integrate .. //depot/projects/tty/usr.bin/compress/zopen.c#2 integrate .. //depot/projects/tty/usr.bin/mkuzip/Makefile#2 integrate .. //depot/projects/tty/usr.bin/mkuzip/mkuzip.c#2 integrate .. //depot/projects/tty/usr.bin/smbutil/Makefile#2 integrate .. //depot/projects/tty/usr.bin/systat/pigs.c#4 integrate .. //depot/projects/tty/usr.sbin/authpf/Makefile#2 integrate .. //depot/projects/tty/usr.sbin/burncd/burncd.8#8 integrate .. //depot/projects/tty/usr.sbin/faithd/ftp.c#4 integrate .. //depot/projects/tty/usr.sbin/mount_smbfs/Makefile#4 integrate .. //depot/projects/tty/usr.sbin/pmccontrol/pmccontrol.c#2 integrate .. //depot/projects/tty/usr.sbin/pmcstat/pmcstat.c#2 integrate .. //depot/projects/tty/usr.sbin/rpc.yppasswdd/yppasswdd_main.c#4 integrate .. //depot/projects/tty/usr.sbin/sysinstall/dist.c#9 integrate .. //depot/projects/tty/usr.sbin/sysinstall/menus.c#15 integrate .. //depot/projects/tty/usr.sbin/ypserv/Makefile.yp#4 integrate .. //depot/projects/tty/usr.sbin/ypserv/yp_dnslookup.c#4 integrate .. //depot/projects/tty/usr.sbin/ypserv/yp_extern.h#2 integrate .. //depot/projects/tty/usr.sbin/ypserv/yp_server.c#3 integrate Differences ... ==== //depot/projects/tty/Makefile.inc1#18 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.493 2005/04/30 16:09:23 imp Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.494 2005/05/01 17:36:09 imp Exp $ # # Make command line options: # -DNO_DYNAMICROOT do not link /bin and /sbin dynamically @@ -337,7 +337,6 @@ @echo "--------------------------------------------------------------" @echo ">>> stage 2.1: cleaning up the object tree" @echo "--------------------------------------------------------------" - @rm -rf ${.OBJDIR}/sbin/ipf ${_+_}cd ${.CURDIR}; ${WMAKE} ${CLEANDIR:S/^/par-/} .endif _obj: ==== //depot/projects/tty/UPDATING#15 (text+ko) ==== @@ -21,6 +21,11 @@ developers choose to disable these features on build machines to maximize performance. +20050503: + The packet filter (pf) code has been updated to OpenBSD 3.7 + Please note the changed anchor syntax and the fact that + authpf(8) now needs a mounted fdescfs(5) to function. + 20050415: The NO_MIXED_MODE kernel option has been removed from the i386 amd64 platforms as its use has been superceded by the new local @@ -331,4 +336,4 @@ Contact Warner Losh if you have any questions about your use of this document. -$FreeBSD: src/UPDATING,v 1.401 2005/04/18 14:33:18 scottl Exp $ +$FreeBSD: src/UPDATING,v 1.402 2005/05/03 17:43:13 mlaier Exp $ ==== //depot/projects/tty/bin/csh/config.h#5 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/bin/csh/config.h,v 1.11 2005/04/24 19:50:22 mp Exp $ */ +/* $FreeBSD: src/bin/csh/config.h,v 1.12 2005/05/04 20:21:57 mp Exp $ */ /* config.h. Generated by configure. */ /* config.h.in. Generated from configure.in by autoheader. */ @@ -99,7 +99,7 @@ #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1 /* Define to 1 if `ut_host' is member of `struct utmp'. */ -/* #undef HAVE_STRUCT_UTMP_UT_HOST */ +#define HAVE_STRUCT_UTMP_UT_HOST 1 /* Define to 1 if `ut_tv' is member of `struct utmp'. */ /* #undef HAVE_STRUCT_UTMP_UT_TV */ ==== //depot/projects/tty/contrib/pf/authpf/authpf.8#3 (text+ko) ==== @@ -1,4 +1,4 @@ -.\" $OpenBSD: authpf.8,v 1.31 2003/12/10 04:10:37 beck Exp $ +.\" $OpenBSD: authpf.8,v 1.38 2005/01/04 09:57:04 jmc Exp $ .\" .\" Copyright (c) 2002 Bob Beck (beck@openbsd.org>. All rights reserved. .\" @@ -60,6 +60,10 @@ requires that the .Xr pf 4 system be enabled before use. +.Nm +can also maintain the list of IP address of connected users +in the "authpf_users" +.Pa table . .Pp .Nm is meant to be used with users who can connect via @@ -93,11 +97,16 @@ .Nm rules: .Bd -literal -offset indent -nat-anchor authpf -rdr-anchor authpf -binat-anchor authpf -anchor authpf +nat-anchor "authpf/*" +rdr-anchor "authpf/*" +binat-anchor "authpf/*" +anchor "authpf/*" .Ed +.Pp +The "/*" at the end of the anchor name is required for +.Xr pf 4 +to process the rulesets attached to the anchor by +.Nm authpf . .Sh FILTER AND TRANSLATION RULES Filter and translation rules for .Nm @@ -113,10 +122,14 @@ .Em user_id is assigned the user name. .Pp -Filter and nat rules will first be searched for in +Filter and translation rules are stored in a file called +.Pa authpf.rules . +This file will first be searched for in .Pa /etc/authpf/users/$USER/ and then in .Pa /etc/authpf/ . +Only one of these files will be used if both are present. +.Pp Per-user rules from the .Pa /etc/authpf/users/$USER/ directory are intended to be used when non-default rules @@ -124,21 +137,11 @@ It is important to ensure that a user can not write or change these configuration files. .Pp -Filter and translation rules are loaded from the file -.Pa /etc/authpf/users/$USER/authpf.rules . -If this file does not exist the file -.Pa /etc/authpf/authpf.rules -is used. The .Pa authpf.rules file must exist in one of the above locations for .Nm to run. -.Pp -Translation rules are also loaded from this file. -The use of translation rules in an -.Pa authpf.rules -file is optional. .Sh CONFIGURATION Options are controlled by the .Pa /etc/authpf/authpf.conf @@ -154,6 +157,10 @@ Use the specified .Pa anchor name instead of "authpf". +.It table=name +Use the specified +.Pa table +name instead of "authpf_users". .El .Sh USER MESSAGES On successful invocation, @@ -218,9 +225,15 @@ hijack the session. Note that TCP keepalives are not sufficient for this, since they are not secure. +Also note that +.Ar AllowTcpForwarding +should be disabled for +.Nm +users to prevent them from circumventing restrictions imposed by the +packet filter ruleset. .Pp .Nm -will remove statetable entries that were created during a user's +will remove state table entries that were created during a user's session. This ensures that there will be no unauthenticated traffic allowed to pass after the controlling @@ -391,15 +404,15 @@ # ssh and use us as a dns server. internal_if="fxp1" gateway_addr="10.0.1.1" -nat-anchor authpf -rdr-anchor authpf -binat-anchor authpf +nat-anchor "authpf/*" +rdr-anchor "authpf/*" +binat-anchor "authpf/*" block in on $internal_if from any to any pass in quick on $internal_if proto tcp from any to $gateway_addr \e port = ssh pass in quick on $internal_if proto udp from any to $gateway_addr \e port = domain -anchor authpf +anchor "authpf/*" .Ed .Pp .Sy For a switched, wired net @@ -465,6 +478,33 @@ 129.128.11.10.60539 > 198.137.240.92.22: S 2131494121:2131494121(0) win \e 16384 (DF) .Ed +.Pp +.Sy Using the authpf_users table +\- Simple +.Nm +settings can be implemented without an anchor by just using the "authpf_users" +.Pa table . +For example, the following +.Xr pf.conf 5 +lines will give SMTP and IMAP access to logged in users: +.Bd -literal +table persist +pass in on $ext_if proto tcp from \e + to port { smtp imap } keep state +.Ed +.Pp +It is also possible to use the "authpf_users" +.Pa table +in combination with anchors. +For example, +.Xr pf 4 +processing can be sped up by looking up the anchor +only for packets coming from logged in users: +.Bd -literal +table persist +anchor "authpf/*" from +rdr-anchor "authpf/*" from +.Ed .Sh FILES .Bl -tag -width "/etc/authpf/authpf.conf" -compact .It Pa /etc/authpf/authpf.conf ==== //depot/projects/tty/contrib/pf/authpf/authpf.c#3 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $OpenBSD: authpf.c,v 1.75 2004/01/29 01:55:10 deraadt Exp $ */ +/* $OpenBSD: authpf.c,v 1.89 2005/02/10 04:24:15 joel Exp $ */ /* * Copyright (C) 1998 - 2002 Bob Beck (beck@openbsd.org). @@ -26,13 +26,15 @@ */ #include -__FBSDID("$FreeBSD: src/contrib/pf/authpf/authpf.c,v 1.5 2004/06/16 23:39:30 mlaier Exp $"); +__FBSDID("$FreeBSD: src/contrib/pf/authpf/authpf.c,v 1.6 2005/05/03 16:55:19 mlaier Exp $"); #include #include #include #include +#include #include +#include #include #include @@ -40,6 +42,7 @@ #include #include +#include #include #include #include @@ -48,9 +51,6 @@ #include #include -#include -#include - #include "pathnames.h" extern int symset(const char *, const char *, int); @@ -61,11 +61,13 @@ static int check_luser(char *, char *); static int remove_stale_rulesets(void); static int change_filter(int, const char *, const char *); +static int change_table(int, const char *, const char *); static void authpf_kill_states(void); int dev; /* pf device */ char anchorname[PF_ANCHOR_NAME_SIZE] = "authpf"; -char rulesetname[PF_RULESET_NAME_SIZE]; +char rulesetname[MAXPATHLEN - PF_ANCHOR_NAME_SIZE - 2]; +char tablename[PF_TABLE_NAME_SIZE] = "authpf_users"; FILE *pidfp; char *infile; /* file name printed by yyerror() in parse.y */ @@ -94,10 +96,12 @@ { int lockcnt = 0, n, pidfd; FILE *config; - struct in_addr ina; + struct in6_addr ina; struct passwd *pw; char *cp; uid_t uid; + char *shell; + login_cap_t *lc; config = fopen(PATH_CONFFILE, "r"); @@ -121,7 +125,8 @@ exit(1); } *cp = '\0'; - if (inet_pton(AF_INET, ipsrc, &ina) != 1) { + if (inet_pton(AF_INET, ipsrc, &ina) != 1 && + inet_pton(AF_INET6, ipsrc, &ina) != 1) { syslog(LOG_ERR, "cannot determine IP from SSH_CLIENT %s", ipsrc); exit(1); @@ -135,16 +140,31 @@ uid = getuid(); pw = getpwuid(uid); + endpwent(); if (pw == NULL) { syslog(LOG_ERR, "cannot find user for uid %u", uid); goto die; } - if (strcmp(pw->pw_shell, PATH_AUTHPF_SHELL)) { + + if ((lc = login_getclass(pw->pw_class)) != NULL) + shell = (char *)login_getcapstr(lc, "shell", pw->pw_shell, + pw->pw_shell); + else + shell = pw->pw_shell; + + login_close(lc); + + if (strcmp(shell, PATH_AUTHPF_SHELL)) { syslog(LOG_ERR, "wrong shell for user %s, uid %u", pw->pw_name, pw->pw_uid); + if (shell != pw->pw_shell) + free(shell); goto die; } + if (shell != pw->pw_shell) + free(shell); + /* * Paranoia, but this data _does_ come from outside authpf, and * truncation would be bad. @@ -155,11 +175,11 @@ } if ((n = snprintf(rulesetname, sizeof(rulesetname), "%s(%ld)", - luser, (long)getpid())) < 0 || n >= sizeof(rulesetname)) { + luser, (long)getpid())) < 0 || (u_int)n >= sizeof(rulesetname)) { syslog(LOG_INFO, "%s(%ld) too large, ruleset name will be %ld", luser, (long)getpid(), (long)getpid()); if ((n = snprintf(rulesetname, sizeof(rulesetname), "%ld", - (long)getpid())) < 0 || n >= sizeof(rulesetname)) { + (long)getpid())) < 0 || (u_int)n >= sizeof(rulesetname)) { syslog(LOG_ERR, "pid too large for ruleset name"); goto die; } @@ -269,12 +289,17 @@ rewind(pidfp); fprintf(pidfp, "%ld\n%s\n", (long)getpid(), luser); fflush(pidfp); - (void) ftruncate(fileno(pidfp), ftell(pidfp)); + (void) ftruncate(fileno(pidfp), ftello(pidfp)); if (change_filter(1, luser, ipsrc) == -1) { printf("Unable to modify filters\r\n"); do_death(0); } + if (change_table(1, luser, ipsrc) == -1) { + printf("Unable to modify table\r\n"); + change_filter(0, luser, ipsrc); + do_death(0); + } signal(SIGTERM, need_death); signal(SIGINT, need_death); @@ -284,7 +309,7 @@ signal(SIGSTOP, need_death); signal(SIGTSTP, need_death); while (1) { - printf("\r\nHello %s, ", luser); + printf("\r\nHello %s. ", luser); printf("You are authenticated from host \"%s\"\r\n", ipsrc); setproctitle("%s@%s", luser, ipsrc); print_message(PATH_MESSAGE); @@ -359,6 +384,11 @@ sizeof(anchorname)) >= sizeof(anchorname)) goto parse_error; } + if (strcasecmp(pair[0], "table") == 0) { + if (!pair[1][0] || strlcpy(tablename, pair[1], + sizeof(tablename)) >= sizeof(tablename)) + goto parse_error; + } } while (!feof(f) && !ferror(f)); fclose(f); return (0); @@ -542,12 +572,10 @@ remove_stale_rulesets(void) { struct pfioc_ruleset prs; - const int action[PF_RULESET_MAX] = { PF_SCRUB, - PF_PASS, PF_NAT, PF_BINAT, PF_RDR }; u_int32_t nr, mnr; memset(&prs, 0, sizeof(prs)); - strlcpy(prs.anchor, anchorname, sizeof(prs.anchor)); + strlcpy(prs.path, anchorname, sizeof(prs.path)); if (ioctl(dev, DIOCGETRULESETS, &prs)) { if (errno == EINVAL) return (0); @@ -574,20 +602,25 @@ (*s && (t == prs.name || *s != ')'))) return (1); if (kill(pid, 0) && errno != EPERM) { - int i; + int i; + struct pfioc_trans_e t_e[PF_RULESET_MAX+1]; + struct pfioc_trans t; - for (i = 0; i < PF_RULESET_MAX; ++i) { - struct pfioc_rule pr; - - memset(&pr, 0, sizeof(pr)); - memcpy(pr.anchor, prs.anchor, sizeof(pr.anchor)); - memcpy(pr.ruleset, prs.name, sizeof(pr.ruleset)); - pr.rule.action = action[i]; - if ((ioctl(dev, DIOCBEGINRULES, &pr) || - ioctl(dev, DIOCCOMMITRULES, &pr)) && - errno != EINVAL) - return (1); + bzero(&t, sizeof(t)); + bzero(t_e, sizeof(t_e)); + t.size = PF_RULESET_MAX+1; + t.esize = sizeof(t_e[0]); + t.array = t_e; + for (i = 0; i < PF_RULESET_MAX+1; ++i) { + t_e[i].rs_num = i; + snprintf(t_e[i].anchor, sizeof(t_e[i].anchor), + "%s/%s", anchorname, prs.name); } + t_e[PF_RULESET_MAX].rs_num = PF_RULESET_TABLE; + if ((ioctl(dev, DIOCXBEGIN, &t) || + ioctl(dev, DIOCXCOMMIT, &t)) && + errno != EINVAL) + return (1); mnr--; } else nr++; @@ -601,85 +634,67 @@ static int change_filter(int add, const char *luser, const char *ipsrc) { - char fn[MAXPATHLEN]; - FILE *f = NULL; - struct pfctl pf; - struct pfr_buffer t; - int i; + char *pargv[13] = { + "pfctl", "-p", "/dev/pf", "-q", "-a", "anchor/ruleset", + "-D", "user_ip=X", "-D", "user_id=X", "-f", + "file", NULL + }; + char *fdpath = NULL, *userstr = NULL, *ipstr = NULL; + char *rsn = NULL, *fn = NULL; + pid_t pid; + int s; if (luser == NULL || !luser[0] || ipsrc == NULL || !ipsrc[0]) { syslog(LOG_ERR, "invalid luser/ipsrc"); goto error; } + if (asprintf(&rsn, "%s/%s", anchorname, rulesetname) == -1) + goto no_mem; + if (asprintf(&fdpath, "/dev/fd/%d", dev) == -1) + goto no_mem; + if (asprintf(&ipstr, "user_ip=%s", ipsrc) == -1) + goto no_mem; + if (asprintf(&userstr, "user_id=%s", luser) == -1) + goto no_mem; + if (add) { - if ((i = snprintf(fn, sizeof(fn), "%s/%s/authpf.rules", - PATH_USER_DIR, luser)) < 0 || i >= sizeof(fn)) { - syslog(LOG_ERR, "user rule path too long"); - goto error; - } - if ((f = fopen(fn, "r")) == NULL && errno != ENOENT) { - syslog(LOG_ERR, "cannot open %s (%m)", fn); - goto error; - } - if (f == NULL) { - if (strlcpy(fn, PATH_PFRULES, sizeof(fn)) >= - sizeof(fn)) { - syslog(LOG_ERR, "rule path too long"); - goto error; - } - if ((f = fopen(fn, "r")) == NULL) { - syslog(LOG_ERR, "cannot open %s (%m)", fn); - goto error; - } + struct stat sb; + + if (asprintf(&fn, "%s/%s/authpf.rules", PATH_USER_DIR, luser) + == -1) + goto no_mem; + if (stat(fn, &sb) == -1) { + free(fn); + if ((fn = strdup(PATH_PFRULES)) == NULL) + goto no_mem; } } + pargv[2] = fdpath; + pargv[5] = rsn; + pargv[7] = userstr; + pargv[9] = ipstr; + if (!add) + pargv[11] = "/dev/null"; + else + pargv[11] = fn; - if (pfctl_load_fingerprints(dev, 0)) { - syslog(LOG_ERR, "unable to load kernel's OS fingerprints"); - goto error; - } - bzero(&t, sizeof(t)); - t.pfrb_type = PFRB_TRANS; - memset(&pf, 0, sizeof(pf)); - for (i = 0; i < PF_RULESET_MAX; ++i) { - if (pfctl_add_trans(&t, i, anchorname, rulesetname)) { - syslog(LOG_ERR, "pfctl_add_trans %m"); - goto error; - } - } - if (pfctl_trans(dev, &t, DIOCXBEGIN, 0)) { - syslog(LOG_ERR, "DIOCXBEGIN (%s) %m", add?"add":"remove"); - goto error; + switch (pid = fork()) { + case -1: + err(1, "fork failed"); + case 0: + execvp(PATH_PFCTL, pargv); + warn("exec of %s failed", PATH_PFCTL); + _exit(1); } - if (add) { - if (symset("user_ip", ipsrc, 0) || - symset("user_id", luser, 0)) { - syslog(LOG_ERR, "symset"); - goto error; - } - - pf.dev = dev; - pf.trans = &t; - pf.anchor = anchorname; - pf.ruleset = rulesetname; - - infile = fn; - if (parse_rules(f, &pf) < 0) { - syslog(LOG_ERR, "syntax error in rule file: " - "authpf rules not loaded"); + /* parent */ + waitpid(pid, &s, 0); + if (s != 0) { + if (WIFEXITED(s)) { + syslog(LOG_ERR, "pfctl exited abnormally"); goto error; } - - infile = NULL; - fclose(f); - f = NULL; - } - - if (pfctl_trans(dev, &t, DIOCXCOMMIT, 0)) { - syslog(LOG_ERR, "DIOCXCOMMIT (%s) %m", add?"add":"remove"); - goto error; } if (add) { @@ -691,18 +706,63 @@ ipsrc, luser, Tend.tv_sec - Tstart.tv_sec); } return (0); - +no_mem: + syslog(LOG_ERR, "malloc failed"); error: - if (f != NULL) - fclose(f); - if (pfctl_trans(dev, &t, DIOCXROLLBACK, 0)) - syslog(LOG_ERR, "DIOCXROLLBACK (%s) %m", add?"add":"remove"); - + free(fdpath); + fdpath = NULL; + free(rsn); + rsn = NULL; + free(userstr); + userstr = NULL; + free(ipstr); + ipstr = NULL; + free(fn); + fn = NULL; infile = NULL; return (-1); } /* + * Add/remove this IP from the "authpf_users" table. + */ +static int +change_table(int add, const char *luser, const char *ipsrc) +{ + struct pfioc_table io; + struct pfr_addr addr; + + bzero(&io, sizeof(io)); + strlcpy(io.pfrio_table.pfrt_name, tablename, sizeof(io.pfrio_table)); + io.pfrio_buffer = &addr; + io.pfrio_esize = sizeof(addr); + io.pfrio_size = 1; + + bzero(&addr, sizeof(addr)); + if (ipsrc == NULL || !ipsrc[0]) + return (-1); + if (inet_pton(AF_INET, ipsrc, &addr.pfra_ip4addr) == 1) { + addr.pfra_af = AF_INET; + addr.pfra_net = 32; + } else if (inet_pton(AF_INET6, ipsrc, &addr.pfra_ip6addr) == 1) { + addr.pfra_af = AF_INET6; + addr.pfra_net = 128; + } else { + syslog(LOG_ERR, "invalid ipsrc"); + return (-1); + } + + if (ioctl(dev, add ? DIOCRADDADDRS : DIOCRDELADDRS, &io) && + errno != ESRCH) { + syslog(LOG_ERR, "cannot %s %s from table %s: %s", + add ? "add" : "remove", ipsrc, tablename, + strerror(errno)); + return (-1); + } + return (0); +} + +/* * This is to kill off states that would otherwise be left behind stateful * rules. This means we don't need to allow in more traffic than we really * want to, since we don't have to worry about any luser sessions lasting @@ -713,24 +773,32 @@ authpf_kill_states(void) { struct pfioc_state_kill psk; - struct in_addr target; + struct pf_addr target; memset(&psk, 0, sizeof(psk)); - psk.psk_af = AF_INET; + memset(&target, 0, sizeof(target)); - inet_pton(AF_INET, ipsrc, &target); + if (inet_pton(AF_INET, ipsrc, &target.v4) == 1) + psk.psk_af = AF_INET; + else if (inet_pton(AF_INET6, ipsrc, &target.v6) == 1) + psk.psk_af = AF_INET6; + else { + syslog(LOG_ERR, "inet_pton(%s) failed", ipsrc); + return; + } /* Kill all states from ipsrc */ - psk.psk_src.addr.v.a.addr.v4 = target; + memcpy(&psk.psk_src.addr.v.a.addr, &target, + sizeof(psk.psk_src.addr.v.a.addr)); memset(&psk.psk_src.addr.v.a.mask, 0xff, sizeof(psk.psk_src.addr.v.a.mask)); if (ioctl(dev, DIOCKILLSTATES, &psk)) syslog(LOG_ERR, "DIOCKILLSTATES failed (%m)"); /* Kill all states to ipsrc */ - psk.psk_af = AF_INET; memset(&psk.psk_src, 0, sizeof(psk.psk_src)); - psk.psk_dst.addr.v.a.addr.v4 = target; + memcpy(&psk.psk_dst.addr.v.a.addr, &target, + sizeof(psk.psk_dst.addr.v.a.addr)); memset(&psk.psk_dst.addr.v.a.mask, 0xff, sizeof(psk.psk_dst.addr.v.a.mask)); if (ioctl(dev, DIOCKILLSTATES, &psk)) @@ -758,6 +826,7 @@ if (active) { change_filter(0, luser, ipsrc); + change_table(0, luser, ipsrc); authpf_kill_states(); remove_stale_rulesets(); } @@ -768,157 +837,3 @@ syslog(LOG_ERR, "cannot unlink %s (%m)", pidfile); exit(ret); } - -/* - * callbacks for parse_rules(void) - */ - -int -pfctl_add_rule(struct pfctl *pf, struct pf_rule *r) -{ - u_int8_t rs_num; - struct pfioc_rule pr; - - switch (r->action) { - case PF_PASS: - case PF_DROP: - rs_num = PF_RULESET_FILTER; - break; - case PF_SCRUB: - rs_num = PF_RULESET_SCRUB; - break; - case PF_NAT: - case PF_NONAT: - rs_num = PF_RULESET_NAT; - break; - case PF_RDR: - case PF_NORDR: - rs_num = PF_RULESET_RDR; - break; - case PF_BINAT: - case PF_NOBINAT: - rs_num = PF_RULESET_BINAT; - break; - default: - syslog(LOG_ERR, "invalid rule action %d", r->action); - return (1); - } - - bzero(&pr, sizeof(pr)); - strlcpy(pr.anchor, pf->anchor, sizeof(pr.anchor)); - strlcpy(pr.ruleset, pf->ruleset, sizeof(pr.ruleset)); - if (pfctl_add_pool(pf, &r->rpool, r->af)) - return (1); - pr.ticket = pfctl_get_ticket(pf->trans, rs_num, pf->anchor, - pf->ruleset); - pr.pool_ticket = pf->paddr.ticket; - memcpy(&pr.rule, r, sizeof(pr.rule)); - if (ioctl(pf->dev, DIOCADDRULE, &pr)) { - syslog(LOG_ERR, "DIOCADDRULE %m"); - return (1); - } - pfctl_clear_pool(&r->rpool); - return (0); -} - -int -pfctl_add_pool(struct pfctl *pf, struct pf_pool *p, sa_family_t af) -{ - struct pf_pooladdr *pa; - - if (ioctl(pf->dev, DIOCBEGINADDRS, &pf->paddr)) { - syslog(LOG_ERR, "DIOCBEGINADDRS %m"); - return (1); - } - pf->paddr.af = af; - TAILQ_FOREACH(pa, &p->list, entries) { - memcpy(&pf->paddr.addr, pa, sizeof(struct pf_pooladdr)); - if (ioctl(pf->dev, DIOCADDADDR, &pf->paddr)) { - syslog(LOG_ERR, "DIOCADDADDR %m"); - return (1); - } - } - return (0); -} - -void -pfctl_clear_pool(struct pf_pool *pool) -{ - struct pf_pooladdr *pa; - - while ((pa = TAILQ_FIRST(&pool->list)) != NULL) { - TAILQ_REMOVE(&pool->list, pa, entries); - free(pa); - } -} - -int -pfctl_add_altq(struct pfctl *pf, struct pf_altq *a) -{ - fprintf(stderr, "altq rules not supported in authpf\n"); >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Thu May 5 11:50:27 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 510DA16A4D0; Thu, 5 May 2005 11:50:27 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1443116A4CE for ; Thu, 5 May 2005 11:50:27 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id DE47543D4C for ; Thu, 5 May 2005 11:50:26 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j45BoQgb044292 for ; Thu, 5 May 2005 11:50:26 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j45BoQHT044289 for perforce@freebsd.org; Thu, 5 May 2005 11:50:26 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Thu, 5 May 2005 11:50:26 GMT Message-Id: <200505051150.j45BoQHT044289@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76552 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 11:50:28 -0000 http://perforce.freebsd.org/chv.cgi?CH=76552 Change 76552 by rwatson@rwatson_paprika on 2005/05/05 11:49:52 Correct merge-o. Affected files ... .. //depot/projects/trustedbsd/mac/sys/kern/sysv_shm.c#30 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/kern/sysv_shm.c#30 (text+ko) ==== @@ -332,7 +332,6 @@ * XXX: It might be useful to move this into the shm_delete_mapping * function */ - struct shmid_kernel *shmsegptr; shmsegptr = &shmsegs[IPCID_TO_IX(shmmap_s->shmid)]; error = mac_check_sysv_shmdt(td->td_ucred, shmsegptr); if (error != 0) { From owner-p4-projects@FreeBSD.ORG Thu May 5 14:33:46 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E97A416A4D0; Thu, 5 May 2005 14:33:45 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8EC6A16A4CE for ; Thu, 5 May 2005 14:33:45 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 61DD243DCA for ; Thu, 5 May 2005 14:33:45 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j45EXjHf058094 for ; Thu, 5 May 2005 14:33:45 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j45EXj90058091 for perforce@freebsd.org; Thu, 5 May 2005 14:33:45 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Thu, 5 May 2005 14:33:45 GMT Message-Id: <200505051433.j45EXj90058091@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76557 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 14:33:46 -0000 http://perforce.freebsd.org/chv.cgi?CH=76557 Change 76557 by rwatson@rwatson_paprika on 2005/05/05 14:33:43 Merge dev_clone_cred event handler from trustedbsd_sebsd to trustedbsd_mac for eventual delivery to FreeBSD CVS. This introduces a new devfs event handler for cloning, which provides the credential associated with the device lookup to the device driver and MAC Framework. This allows device drivers to create nodes with owner/permissions/etc based on elements of the credential performing the lookup, and allows the MAC Framework and its policies to create an initial device node label based on that same credential. Due to the way in which events occur and data structures are passed around, storing a reference to the lookup-time credential in the cdev is necessary to usefully re-expose the credential when passing the device node from devfs to the MAC Framework when the devfsdirent is created. However, we do expose the credential explicitly to policies to avoid building in assumptions about the location/source of the credential. In this change, the policies are not modified. Note that the credential pointer will be NULL in non-clone scenarios. Affected files ... .. //depot/projects/trustedbsd/mac/sys/fs/devfs/devfs_devs.c#20 edit .. //depot/projects/trustedbsd/mac/sys/fs/devfs/devfs_vnops.c#57 edit .. //depot/projects/trustedbsd/mac/sys/kern/kern_conf.c#25 edit .. //depot/projects/trustedbsd/mac/sys/kern/tty_pty.c#20 edit .. //depot/projects/trustedbsd/mac/sys/security/mac/mac_vfs.c#14 edit .. //depot/projects/trustedbsd/mac/sys/security/mac_biba/mac_biba.c#254 edit .. //depot/projects/trustedbsd/mac/sys/security/mac_lomac/mac_lomac.c#93 edit .. //depot/projects/trustedbsd/mac/sys/security/mac_mls/mac_mls.c#207 edit .. //depot/projects/trustedbsd/mac/sys/security/mac_stub/mac_stub.c#34 edit .. //depot/projects/trustedbsd/mac/sys/security/mac_test/mac_test.c#147 edit .. //depot/projects/trustedbsd/mac/sys/sys/conf.h#26 edit .. //depot/projects/trustedbsd/mac/sys/sys/mac.h#273 edit .. //depot/projects/trustedbsd/mac/sys/sys/mac_policy.h#230 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/fs/devfs/devfs_devs.c#20 (text+ko) ==== @@ -325,8 +325,8 @@ de->de_dirent->d_type = DT_CHR; } #ifdef MAC - mac_create_devfs_device(dm->dm_mount, dev, de, - dev->si_name); + mac_create_devfs_device(dev->si_cred, dm->dm_mount, + dev, de, dev->si_name); #endif *dep = de; de->de_dir = dd; ==== //depot/projects/trustedbsd/mac/sys/fs/devfs/devfs_vnops.c#57 (text+ko) ==== @@ -648,9 +648,13 @@ goto notfound; cdev = NULL; - EVENTHANDLER_INVOKE(dev_clone, pname, strlen(pname), &cdev); - if (cdev == NULL) - goto notfound; + EVENTHANDLER_INVOKE(dev_clone_cred, td->td_ucred, pname, + strlen(pname), &cdev); + if (cdev == NULL) { + EVENTHANDLER_INVOKE(dev_clone, pname, strlen(pname), &cdev); + if (cdev == NULL) + goto notfound; + } devfs_populate(dmp); ==== //depot/projects/trustedbsd/mac/sys/kern/kern_conf.c#25 (text+ko) ==== @@ -42,6 +42,7 @@ #include #include #include +#include #include static MALLOC_DEFINE(M_DEVT, "cdev", "cdev storage"); @@ -51,6 +52,9 @@ static struct mtx devmtx; static void freedev(struct cdev *dev); static void destroy_devl(struct cdev *dev); +static struct cdev *make_dev_credv(struct cdevsw *devsw, int minornr, + struct ucred *cr, uid_t uid, gid_t gid, int mode, const char *fmt, + va_list ap); void dev_lock(void) @@ -300,6 +304,8 @@ freedev(struct cdev *dev) { + if (dev->si_cred != NULL) + crfree(dev->si_cred); free(dev, M_DEVT); } @@ -370,11 +376,11 @@ dev_unlock(); } -struct cdev * -make_dev(struct cdevsw *devsw, int minornr, uid_t uid, gid_t gid, int mode, const char *fmt, ...) +static struct cdev * +make_dev_credv(struct cdevsw *devsw, int minornr, struct ucred *cr, uid_t uid, + gid_t gid, int mode, const char *fmt, va_list ap) { struct cdev *dev; - va_list ap; int i; KASSERT((minornr & ~MAXMINOR) == 0, @@ -400,16 +406,18 @@ ("make_dev() by driver %s on pre-existing device (min=%x, name=%s)", devsw->d_name, minor(dev), devtoname(dev))); - va_start(ap, fmt); i = vsnrprintf(dev->__si_namebuf, sizeof dev->__si_namebuf, 32, fmt, ap); if (i > (sizeof dev->__si_namebuf - 1)) { printf("WARNING: Device name truncated! (%s)\n", dev->__si_namebuf); } - va_end(ap); dev->si_devsw = devsw; dev->si_flags |= SI_NAMED; + if (cr != NULL) + dev->si_cred = crhold(cr); + else + dev->si_cred = NULL; dev->si_uid = uid; dev->si_gid = gid; dev->si_mode = mode; @@ -419,6 +427,33 @@ return (dev); } +struct cdev * +make_dev(struct cdevsw *devsw, int minornr, uid_t uid, gid_t gid, int mode, + const char *fmt, ...) +{ + struct cdev *dev; + va_list ap; + + va_start(ap, fmt); + dev = make_dev_credv(devsw, minornr, NULL, uid, gid, mode, fmt, ap); + va_end(ap); + return (dev); +} + +struct cdev * +make_dev_cred(struct cdevsw *devsw, int minornr, struct ucred *cr, uid_t uid, + gid_t gid, int mode, const char *fmt, ...) +{ + struct cdev *dev; + va_list ap; + + va_start(ap, fmt); + dev = make_dev_credv(devsw, minornr, cr, uid, gid, mode, fmt, ap); + va_end(ap); + + return (dev); +} + int dev_named(struct cdev *pdev, const char *name) { ==== //depot/projects/trustedbsd/mac/sys/kern/tty_pty.c#20 (text+ko) ==== @@ -63,7 +63,7 @@ static void ptsstart(struct tty *tp); static void ptsstop(struct tty *tp, int rw); static void ptcwakeup(struct tty *tp, int flag); -static struct cdev *ptyinit(struct cdev *cdev); +static struct cdev *ptyinit(struct cdev *cdev, struct thread *td); static d_open_t ptsopen; static d_close_t ptsclose; @@ -132,7 +132,7 @@ * than 256 ptys. */ static struct cdev * -ptyinit(struct cdev *devc) +ptyinit(struct cdev *devc, struct thread *td) { struct cdev *devs; struct ptsc *pt; @@ -146,7 +146,7 @@ devc->si_flags &= ~SI_CHEAPCLONE; pt = malloc(sizeof(*pt), M_PTY, M_WAITOK | M_ZERO); - pt->devs = devs = make_dev(&pts_cdevsw, n, + pt->devs = devs = make_dev_cred(&pts_cdevsw, n, td->td_ucred, UID_ROOT, GID_WHEEL, 0666, "tty%c%r", names[n / 32], n % 32); pt->devc = devc; @@ -272,7 +272,7 @@ struct ptsc *pt; if (!dev->si_drv1) - ptyinit(dev); + ptyinit(dev, td); if (!dev->si_drv1) return(ENXIO); tp = dev->si_tty; @@ -681,7 +681,8 @@ } static void -pty_clone(void *arg, char *name, int namelen, struct cdev **dev) +pty_clone(void *arg, struct ucred *cr, char *name, int namelen, + struct cdev **dev) { int u; @@ -708,7 +709,7 @@ u += name[4] - 'a' + 10; else return; - *dev = make_dev(&ptc_cdevsw, u, + *dev = make_dev_cred(&ptc_cdevsw, u, cr, UID_ROOT, GID_WHEEL, 0666, "pty%c%r", names[u / 32], u % 32); dev_ref(*dev); (*dev)->si_flags |= SI_CHEAPCLONE; @@ -719,7 +720,7 @@ ptc_drvinit(void *unused) { - EVENTHANDLER_REGISTER(dev_clone, pty_clone, 0, 1000); + EVENTHANDLER_REGISTER(dev_clone_cred, pty_clone, 0, 1000); } SYSINIT(ptcdev,SI_SUB_DRIVERS,SI_ORDER_MIDDLE,ptc_drvinit,NULL) ==== //depot/projects/trustedbsd/mac/sys/security/mac/mac_vfs.c#14 (text+ko) ==== @@ -939,11 +939,11 @@ } void -mac_create_devfs_device(struct mount *mp, struct cdev *dev, - struct devfs_dirent *de, const char *fullpath) +mac_create_devfs_device(struct ucred *cred, struct mount *mp, + struct cdev *dev, struct devfs_dirent *de, const char *fullpath) { - MAC_PERFORM(create_devfs_device, mp, dev, de, de->de_label, + MAC_PERFORM(create_devfs_device, cred, mp, dev, de, de->de_label, fullpath); } ==== //depot/projects/trustedbsd/mac/sys/security/mac_biba/mac_biba.c#254 (text+ko) ==== @@ -858,8 +858,8 @@ * a lot like file system objects. */ static void -mac_biba_create_devfs_device(struct mount *mp, struct cdev *dev, - struct devfs_dirent *devfs_dirent, struct label *label, +mac_biba_create_devfs_device(struct ucred *cred, struct mount *mp, + struct cdev *dev, struct devfs_dirent *devfs_dirent, struct label *label, const char *fullpath) { struct mac_biba *mac_biba; ==== //depot/projects/trustedbsd/mac/sys/security/mac_lomac/mac_lomac.c#93 (text+ko) ==== @@ -916,8 +916,8 @@ * a lot like file system objects. */ static void -mac_lomac_create_devfs_device(struct mount *mp, struct cdev *dev, - struct devfs_dirent *devfs_dirent, struct label *label, +mac_lomac_create_devfs_device(struct ucred *cred, struct mount *mp, + struct cdev *dev, struct devfs_dirent *devfs_dirent, struct label *label, const char *fullpath) { struct mac_lomac *mac_lomac; ==== //depot/projects/trustedbsd/mac/sys/security/mac_mls/mac_mls.c#207 (text+ko) ==== @@ -822,8 +822,8 @@ * a lot like file system objects. */ static void -mac_mls_create_devfs_device(struct mount *mp, struct cdev *dev, - struct devfs_dirent *devfs_dirent, struct label *label, +mac_mls_create_devfs_device(struct ucred *cred, struct mount *mp, + struct cdev *dev, struct devfs_dirent *devfs_dirent, struct label *label, const char *fullpath) { struct mac_mls *mac_mls; ==== //depot/projects/trustedbsd/mac/sys/security/mac_stub/mac_stub.c#34 (text+ko) ==== @@ -183,8 +183,8 @@ } static void -stub_create_devfs_device(struct mount *mp, struct cdev *dev, - struct devfs_dirent *devfs_dirent, struct label *label, +stub_create_devfs_device(struct ucred *cred, struct mount *mp, + struct cdev *dev, struct devfs_dirent *devfs_dirent, struct label *label, const char *fullpath) { ==== //depot/projects/trustedbsd/mac/sys/security/mac_test/mac_test.c#147 (text+ko) ==== @@ -865,8 +865,8 @@ } static void -mac_test_create_devfs_device(struct mount *mp, struct cdev *dev, - struct devfs_dirent *devfs_dirent, struct label *label, +mac_test_create_devfs_device(struct ucred *cred, struct mount *mp, + struct cdev *dev, struct devfs_dirent *devfs_dirent, struct label *label, const char *fullpath) { ==== //depot/projects/trustedbsd/mac/sys/sys/conf.h#26 (text+ko) ==== @@ -68,6 +68,7 @@ uid_t si_uid; gid_t si_gid; mode_t si_mode; + struct ucred *si_cred; u_int si_drv0; int si_refcount; LIST_ENTRY(cdev) si_list; @@ -253,6 +254,9 @@ void dev_strategy(struct cdev *dev, struct buf *bp); struct cdev *make_dev(struct cdevsw *_devsw, int _minor, uid_t _uid, gid_t _gid, int _perms, const char *_fmt, ...) __printflike(6, 7); +struct cdev *make_dev_cred(struct cdevsw *_devsw, int _minor, + struct ucred *_cr, uid_t _uid, gid_t _gid, int _perms, + const char *_fmt, ...) __printflike(7, 8); struct cdev *make_dev_alias(struct cdev *_pdev, const char *_fmt, ...) __printflike(2, 3); int dev2unit(struct cdev *_dev); void dev_lock(void); @@ -280,6 +284,10 @@ int dev_stdclone(char *_name, char **_namep, const char *_stem, int *_unit); EVENTHANDLER_DECLARE(dev_clone, dev_clone_fn); +typedef void (*dev_clone_cred_fn)(void *arg, struct ucred *cred, char *name, + int namelen, struct cdev **result); +EVENTHANDLER_DECLARE(dev_clone_cred, dev_clone_cred_fn); + /* Stuff relating to kernel-dump */ struct dumperinfo { ==== //depot/projects/trustedbsd/mac/sys/sys/mac.h#273 (text+ko) ==== @@ -195,8 +195,8 @@ struct vnode *vp); int mac_associate_vnode_extattr(struct mount *mp, struct vnode *vp); void mac_associate_vnode_singlelabel(struct mount *mp, struct vnode *vp); -void mac_create_devfs_device(struct mount *mp, struct cdev *dev, - struct devfs_dirent *de, const char *fullpath); +void mac_create_devfs_device(struct ucred *cred, struct mount *mp, + struct cdev *dev, struct devfs_dirent *de, const char *fullpath); void mac_create_devfs_directory(struct mount *mp, char *dirname, int dirnamelen, struct devfs_dirent *de, const char *fullpath); void mac_create_devfs_symlink(struct ucred *cred, struct mount *mp, ==== //depot/projects/trustedbsd/mac/sys/sys/mac_policy.h#230 (text+ko) ==== @@ -190,7 +190,8 @@ void (*mpo_associate_vnode_singlelabel)(struct mount *mp, struct label *fslabel, struct vnode *vp, struct label *vlabel); - void (*mpo_create_devfs_device)(struct mount *mp, struct cdev *dev, + void (*mpo_create_devfs_device)(struct ucred *cred, + struct mount *mp, struct cdev *dev, struct devfs_dirent *de, struct label *label, const char *fullpath); void (*mpo_create_devfs_directory)(struct mount *mp, char *dirname, From owner-p4-projects@FreeBSD.ORG Thu May 5 16:06:41 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 295BC16A4D0; Thu, 5 May 2005 16:06:41 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E1A2616A4CE for ; Thu, 5 May 2005 16:06:40 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id AE87243DC2 for ; Thu, 5 May 2005 16:06:40 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j45G6eOc061804 for ; Thu, 5 May 2005 16:06:40 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j45G6e5W061801 for perforce@freebsd.org; Thu, 5 May 2005 16:06:40 GMT (envelope-from csjp@freebsd.org) Date: Thu, 5 May 2005 16:06:40 GMT Message-Id: <200505051606.j45G6e5W061801@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to csjp@freebsd.org using -f From: "Christian S.J. Peron" To: Perforce Change Reviews Subject: PERFORCE change 76561 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 16:06:41 -0000 http://perforce.freebsd.org/chv.cgi?CH=76561 Change 76561 by csjp@csjp_xor on 2005/05/05 16:05:39 Fix long standing kernel panic associated with NFS. The problem stems from dispatching VOP_GETATTR from the kernel using NOCRED. The NFS subsystem will dereference ucred when forming the NFS request resulting in a panic. I have changed the code to use the calling credential of the user in order to retrieve information about the file. However this in itself is fairly futile in that NFS does not support extended attributes. While this change should not do any harm, a more long term fix would be to implement an efficient way to check the capabilities of the files system. Affected files ... .. //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#5 edit Differences ... ==== //depot/projects/trustedbsd/mac/sys/security/mac_chkexec/mac_chkexec.c#5 (text+ko) ==== @@ -204,10 +204,11 @@ struct vcache_fs *vfc; struct vattr va, *vap; int error; + struct thread *td = curthread; /* XXX */ ASSERT_VOP_LOCKED(vp, "mac_chkexec_get_fs_cache: no vlock held"); vap = &va; - error = VOP_GETATTR(vp, vap, NOCRED, curthread); + error = VOP_GETATTR(vp, vap, td->td_ucred, td); if (error) return (NULL); mtx_lock(&cache_mtx); @@ -239,6 +240,7 @@ struct vcache *vcp; int error; struct vattr *vap, va; + struct thread *td = curthread; ASSERT_VOP_LOCKED(vp, "no vlock held"); if (!mac_chkexec_cache) @@ -249,7 +251,7 @@ if (vfc == NULL) return; vap = &va; - error = VOP_GETATTR(vp, vap, NOCRED, curthread); + error = VOP_GETATTR(vp, vap, td->td_ucred, td); if (error) return; vcp = uma_zalloc(cache_zone, M_WAITOK); @@ -284,13 +286,14 @@ struct vcache_fs *vfc; struct vattr *vap, va; int error; + struct thread *td = curthread; ASSERT_VOP_LOCKED(vp, "no vlock held"); vfc = mac_chkexec_get_fs_cache(vp); if (vfc == NULL) return; vap = &va; - error = VOP_GETATTR(vp, vap, NOCRED, curthread); + error = VOP_GETATTR(vp, vap, td->td_ucred, td); if (error) return; vc.fileid = vap->va_fileid; @@ -319,12 +322,13 @@ int error; struct vcache_fs *vfc; struct vattr va, *vap; + struct thread *td = curthread; if (!mac_chkexec_cache) return (NULL); ASSERT_VOP_LOCKED(vp, "no vlock held"); vap = &va; - error = VOP_GETATTR(vp, &va, NOCRED, curthread); + error = VOP_GETATTR(vp, &va, td->td_ucred, td); if (error) return (NULL); vfc = mac_chkexec_get_fs_cache(vp); From owner-p4-projects@FreeBSD.ORG Thu May 5 18:21:34 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 72EE216A4D0; Thu, 5 May 2005 18:21:34 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 36D9216A4CE for ; Thu, 5 May 2005 18:21:34 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 231AF43D2D for ; Thu, 5 May 2005 18:21:34 +0000 (GMT) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j45ILSNx073957 for ; Thu, 5 May 2005 18:21:28 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j45ILS6r073954 for perforce@freebsd.org; Thu, 5 May 2005 18:21:28 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Thu, 5 May 2005 18:21:28 GMT Message-Id: <200505051821.j45ILS6r073954@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson To: Perforce Change Reviews Subject: PERFORCE change 76571 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 18:21:35 -0000 http://perforce.freebsd.org/chv.cgi?CH=76571 Change 76571 by rwatson@rwatson_paprika on 2005/05/05 18:20:49 OpenBSM should look for shared libraries in the local libbsm build tree first. Affected files ... .. //depot/projects/trustedbsd/openbsm/bin/auditreduce/Makefile#3 edit .. //depot/projects/trustedbsd/openbsm/bin/praudit/Makefile#3 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/bin/auditreduce/Makefile#3 (text+ko) ==== @@ -2,7 +2,7 @@ # $FreeBSD$ # -CFLAGS+= -I- -I ../.. -I ../../libbsm -I. +CFLAGS+= -I- -I ../.. -I ../../libbsm -L ../../libbsm -I. PROG= auditreduce MAN= auditreduce.1 DPADD= /usr/lib/libbsm.a ==== //depot/projects/trustedbsd/openbsm/bin/praudit/Makefile#3 (text+ko) ==== @@ -2,7 +2,7 @@ # $FreeBSD$ # -CFLAGS+= -I- -I ../.. -I ../../libbsm -I. +CFLAGS+= -I- -I ../.. -I ../../libbsm -L ../../libbsm -I. PROG= praudit MAN= praudit.1 DPADD= /usr/lib/libbsm.a From owner-p4-projects@FreeBSD.ORG Thu May 5 20:30:09 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9B5A516A4D0; Thu, 5 May 2005 20:30:09 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5FFF316A4CE for ; Thu, 5 May 2005 20:30:09 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4E4B743D2D for ; Thu, 5 May 2005 20:30:09 +0000 (GMT) (envelope-from scottl@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j45KU9hc080155 for ; Thu, 5 May 2005 20:30:09 GMT (envelope-from scottl@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j45KU8Nm080152 for perforce@freebsd.org; Thu, 5 May 2005 20:30:08 GMT (envelope-from scottl@freebsd.org) Date: Thu, 5 May 2005 20:30:08 GMT Message-Id: <200505052030.j45KU8Nm080152@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to scottl@freebsd.org using -f From: Scott Long To: Perforce Change Reviews Subject: PERFORCE change 76579 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 20:30:10 -0000 http://perforce.freebsd.org/chv.cgi?CH=76579 Change 76579 by scottl@scottl-x64 on 2005/05/05 20:29:46 Enable loading the policy by default, and look for it as 'policy.bin' instead of 'policy.16' Affected files ... .. //depot/projects/trustedbsd/sebsd/sys/boot/forth/loader.conf#10 edit .. //depot/projects/trustedbsd/sebsd/sys/boot/forth/loader.conf.sebsd#3 edit Differences ... ==== //depot/projects/trustedbsd/sebsd/sys/boot/forth/loader.conf#10 (text+ko) ==== @@ -352,7 +352,7 @@ sebsd_load="NO" # Security-Enhanced BSD module sebsdpolicy_load="NO" sebsdpolicy_type="sebsd_policy" -sebsdpolicy_name="/etc/security/sebsd/policy.16" +sebsdpolicy_name="/etc/security/sebsd/policy.bin" ############################################################## ### Module loading syntax example ########################## ==== //depot/projects/trustedbsd/sebsd/sys/boot/forth/loader.conf.sebsd#3 (text+ko) ==== @@ -9,4 +9,4 @@ sebsdpolicy_load="YES" # Default SEBSD policy location: -#sebsdpolicy_name="/etc/security/sebsd/policy.16" +sebsdpolicy_name="/etc/security/sebsd/policy.bin" From owner-p4-projects@FreeBSD.ORG Thu May 5 20:47:31 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0733B16A4D0; Thu, 5 May 2005 20:47:31 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A0F8E16A4CE for ; Thu, 5 May 2005 20:47:30 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8B87F43DB1 for ; Thu, 5 May 2005 20:47:30 +0000 (GMT) (envelope-from scottl@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j45KlU8m087611 for ; Thu, 5 May 2005 20:47:30 GMT (envelope-from scottl@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j45KlUVQ087608 for perforce@freebsd.org; Thu, 5 May 2005 20:47:30 GMT (envelope-from scottl@freebsd.org) Date: Thu, 5 May 2005 20:47:30 GMT Message-Id: <200505052047.j45KlUVQ087608@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to scottl@freebsd.org using -f From: Scott Long To: Perforce Change Reviews Subject: PERFORCE change 76580 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 20:47:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=76580 Change 76580 by scottl@scottl-x64 on 2005/05/05 20:46:50 policy.bin is a symlink to the real compiled policy file that will make it easy for the bootloader to find it without being sensitive to name changes. Add appropriate makefile targets. Affected files ... .. //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#20 edit Differences ... ==== //depot/projects/trustedbsd/sebsd/contrib/sebsd/policy/Makefile#20 (text+ko) ==== @@ -72,7 +72,7 @@ APPFILES = $(APPDIR)/default_contexts $(APPDIR)/default_type $(APPDIR)/initrc_context # $(APPDIR)/userhelper_context $(APPDIR)/failsafe_context ROOTFILES = # $(APPDIR)/users/root -default: $(POLICYVER) $(FC) +default: policy $(FC) install: $(APPFILES) $(ROOTFILES) $(LOADPATH) $(FCPATH) @@ -107,7 +107,10 @@ # Note: Can't use install, so not sure how to deal with mode, user, and group # other than by default. -policy: $(POLICYVER) +policy: policy.bin + +policy.bin: $(POLICYVER) + ln -s $(POLICYVER) $@ $(POLICYVER): policy.conf $(CHECKPOLICY) $(CHECKPOLICY) $(POLICYVERCOMPATARGS) -o $@ policy.conf @@ -165,6 +168,7 @@ @-rm $@.tmp $@.root clean: + rm -f policy.bin $(POLICYVER) rm -f policy.conf rm -f tmp/* rm -f $(FC) From owner-p4-projects@FreeBSD.ORG Thu May 5 20:55:48 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 11B9716A4D0; Thu, 5 May 2005 20:55:48 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BEC3716A4CE for ; Thu, 5 May 2005 20:55:47 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8F21343D58 for ; Thu, 5 May 2005 20:55:47 +0000 (GMT) (envelope-from scottl@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j45Kte76087980 for ; Thu, 5 May 2005 20:55:40 GMT (envelope-from scottl@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j45KteMS087977 for perforce@freebsd.org; Thu, 5 May 2005 20:55:40 GMT (envelope-from scottl@freebsd.org) Date: Thu, 5 May 2005 20:55:40 GMT Message-Id: <200505052055.j45KteMS087977@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to scottl@freebsd.org using -f From: Scott Long To: Perforce Change Reviews Subject: PERFORCE change 76581 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 20:55:48 -0000 http://perforce.freebsd.org/chv.cgi?CH=76581 Change 76581 by scottl@scottl-x64 on 2005/05/05 20:54:52 Update the SEBSD install instructions to match the recent changes. Affected files ... .. //depot/projects/trustedbsd/sebsd/SEBSD-Installation.txt#2 edit Differences ... ==== //depot/projects/trustedbsd/sebsd/SEBSD-Installation.txt#2 (text+ko) ==== @@ -1,9 +1,9 @@ Instructions for installing Security-Enhanced BSD -SEBSD ships as a kernel loadable module that loads into a FreeBSD 5.1 +SEBSD ships as a kernel loadable module that loads into a FreeBSD 6.0 kernel supporting the TrustedBSD MAC framework (http://www.trustedbsd.org/). The SEBSD installation CD contains a -modified FreeBSD 5.1 distribution and a MAC kernel. The installation +modified FreeBSD 6.0 distribution and a MAC kernel. The installation process installs the FreeBSD operating system, including full source code and MAC-aware programs. @@ -16,7 +16,7 @@ the FreeBSD operating system or the installation process, refer to the FreeBSD handbook available at the project website: http://www.freebsd.org/. -1. Boot the FreeBSD 5.1-SEBSD installation CD; this CD will install +1. Boot the FreeBSD 6.0-SEBSD installation CD; this CD will install the complete operating system, including kernels, user applications, and complete source code. A series of menus will prompt the user how to proceed. @@ -72,7 +72,7 @@ 4. Inspect the SEBSD policy. The system comes pre-installed with a sample policy, but local changes might be required. The policy source is located in /etc/security/sebsd/policy and the compiled - (binary) version is installed in /etc/security/sebsd/policy.16 by + (binary) version is installed in /etc/security/sebsd/policy.bin by default. Only the binary version is loaded by the SEBSD module at boot time. An alternate location for the binary policy file may be specified at the boot loader or in /boot/loader.conf. @@ -89,7 +89,11 @@ loaded into the kernel. The /sbin/sebsd_loadpolicy program can be used instead of a reboot: - /sbin/sebsd_loadpolicy /etc/security/sebsd/policy.16 + /sbin/sebsd_loadpolicy /etc/security/sebsd/policy.bin + + Note that policy.bin is installed by default as a symlink to another + file. If you plan to generate your own policy file then you might + need to adjust this. 5. Label the file system. By default, extended attribute support was enabled during the install, but the individual files were not From owner-p4-projects@FreeBSD.ORG Fri May 6 13:44:14 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0611D16A4D5; Fri, 6 May 2005 13:44:14 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BCA8516A4D3 for ; Fri, 6 May 2005 13:44:13 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 91A2843D9B for ; Fri, 6 May 2005 13:44:13 +0000 (GMT) (envelope-from areisse@nailabs.com) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j46DiDg7068136 for ; Fri, 6 May 2005 13:44:13 GMT (envelope-from areisse@nailabs.com) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j46DiDhR068133 for perforce@freebsd.org; Fri, 6 May 2005 13:44:13 GMT (envelope-from areisse@nailabs.com) Date: Fri, 6 May 2005 13:44:13 GMT Message-Id: <200505061344.j46DiDhR068133@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to areisse@nailabs.com using -f From: Andrew Reisse To: Perforce Change Reviews Subject: PERFORCE change 76611 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 May 2005 13:44:14 -0000 http://perforce.freebsd.org/chv.cgi?CH=76611 Change 76611 by areisse@areisse_ibook on 2005/05/06 13:43:37 Bring over changes from selinux version 2004081908 (through sebsd). This adds support for conditional rules (booleans). This change is merging only, it does not work yet. Affected files ... .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/avc-selinux.c#1 branch .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/avc.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/avc.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/avc_ss.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask_types.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/linux-compat.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd.c#4 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_labels.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_syscall.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_syscalls.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_sysctl.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/avtab.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/avtab.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/conditional.c#1 branch .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/conditional.h#1 branch .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/constraint.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/context.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/ebitmap.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/ebitmap.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/fileutils.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/fileutils.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/global.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/hashtab.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/hashtab.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/init.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/policydb.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/policydb.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/queue.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/queue.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/security.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/services.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/services.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/services_private.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/sidtab.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/sidtab.h#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/symtab.c#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/symtab.h#2 integrate Differences ... ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/avc.c#2 (text+ko) ==== @@ -83,7 +83,76 @@ return (ssid ^ (tsid<<2) ^ (tclass<<4)) & (AVC_CACHE_SLOTS - 1); } +#ifdef AVC_CACHE_STATS +static inline void avc_cache_stats_incr(int type) +{ + avc_cache_stats[type]++; +} + +static inline void avc_cache_stats_add(int type, unsigned val) + + avc_cache_stats[type] += val; +} +#else +static inline void avc_cache_stats_incr(int type) +{ } + if (rc) +static inline void avc_cache_stats_add(int type, unsigned val) +{ } +#endif + /** + * avc_dump_av - Display an access vector in human-readable form. + * @tclass: target security class + * @av: access vector + */ +void avc_dump_av(security_class_t tclass, access_vector_t av) +{ + char **common_pts = 0; + access_vector_t common_base = 0, perm; + int i, i2; + + if (av == 0) { + printk(" null"); + return; + } + + for (i = 0; i < ARRAY_SIZE(av_inherit); i++) { + if (av_inherit[i].tclass == tclass) { + common_pts = av_inherit[i].common_pts; + common_base = av_inherit[i].common_base; + break; + } + } + + printk(" {"); + i = 0; + perm = 1; + while (perm < common_base) { + if (perm & av) + printk(" %s", common_pts[i]); + i++; + perm <<= 1; + } + + while (i < sizeof(av) * 8) { + if (perm & av) { + for (i2 = 0; i2 < ARRAY_SIZE(av_perm_to_string); i2++) { + if ((av_perm_to_string[i2].tclass == tclass) && + (av_perm_to_string[i2].value == perm)) + break; + } + if (i2 < ARRAY_SIZE(av_perm_to_string)) + printk(" %s", av_perm_to_string[i2].name); + } + i++; + perm <<= 1; + } + + printk(" }"); +} + +/** * avc_dump_query - Display a SID pair and a class in human-readable form. * @ssid: source security identifier * @tsid: target security identifier @@ -139,7 +208,7 @@ "%d entries\n", i); break; } - bzero(new, sizeof(*new)); + memset(new, 0, sizeof(*new)); new->next = avc_node_freelist; avc_node_freelist = new; } @@ -931,13 +1000,13 @@ denied = requested & ~(ae->avd.allowed); - if (/*!requested || */denied) { + if (!requested || denied) { if (selinux_enforcing) { spin_unlock_irqrestore(&avc_lock,flags); rc = EACCES; goto out; } else { - /*ae->avd.allowed |= requested;*/ + ae->avd.allowed |= requested; spin_unlock_irqrestore(&avc_lock,flags); goto out; } ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/avc.h#2 (text+ko) ==== @@ -77,13 +77,9 @@ }; /* Initialize an AVC audit data structure. */ -#ifdef __APPLE__ -#define AVC_AUDIT_DATA_INIT(_d,_t) \ - { bzero((_d), sizeof(struct avc_audit_data)); (_d)->type = AVC_AUDIT_DATA_##_t; } -#else #define AVC_AUDIT_DATA_INIT(_d,_t) \ { memset((_d), 0, sizeof(struct avc_audit_data)); (_d)->type = AVC_AUDIT_DATA_##_t; } -#endif + /* * AVC statistics */ @@ -96,26 +92,7 @@ #define AVC_CAV_PROBES 6 #define AVC_CAV_MISSES 7 #define AVC_NSTATS 8 -extern unsigned avc_cache_stats[AVC_NSTATS]; - -#ifdef AVC_CACHE_STATS -static inline void avc_cache_stats_incr(int type) -{ - avc_cache_stats[type]++; -} - -static inline void avc_cache_stats_add(int type, unsigned val) -{ - avc_cache_stats[type] += val; -} -#else -static inline void avc_cache_stats_incr(int type) -{ } -static inline void avc_cache_stats_add(int type, unsigned val) -{ } -#endif - /* * AVC display support */ @@ -134,6 +111,7 @@ * AVC operations */ +/* Initialize the AVC */ void avc_init(void); int avc_lookup( @@ -185,5 +163,5 @@ u32 events, security_id_t ssid, security_id_t tsid, security_class_t tclass, access_vector_t perms); -#endif /* _SELINUX_AVC_H_ */ +#endif /* _LINUX_AVC_H_ */ ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/avc_ss.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask_types.h#2 (text+ko) ==== @@ -56,7 +56,7 @@ * for permissions are defined in the automatically generated * header file av_permissions.h. */ -typedef u64 access_vector_t; +typedef u32 access_vector_t; /* * Each object class is identified by a fixed-size value. ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/linux-compat.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd.c#4 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_labels.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_syscall.c#2 (text+ko) ==== @@ -208,6 +208,20 @@ int *outlen; }; +static int +sebsd_get_bools(struct thread *td, struct sebsd_get_bools *gb) +{ + char *out = NULL; + if (gb->out) + out = malloc(gb->len, M_SEBSD, M_WAITOK); + int err = security_get_bool_string(&gb->len, out); + if (out && err == 0) + err = copyout(out, gb->out, gb->len); + if (out) + free(out, M_SEBSD); + return (err); +} + int sebsd_syscall(struct proc *td, int call, void *args) { @@ -286,6 +300,58 @@ } break; + + case SEBSDCALL_GET_BOOLS: + if (copyin(args, &gb, sizeof (struct sebsd_get_bools))) + return (EFAULT); + err = sebsd_get_bools(td, &gb); + if (copyout(&gb, args, sizeof (struct sebsd_get_bools))) + return (EFAULT); + break; + + case SEBSDCALL_GET_BOOL: + { + char str[128]; + int active, pending; + err = copyinstr(args,str, 128, NULL); + if (err) + return (err); + security_get_bool(str, &active, &pending); + *td->td_retval = active | (pending << 1); + return (0); + } + + case SEBSDCALL_SET_BOOL: + { + char *str; + + err = thread_has_security(td, SECURITY__SETBOOL); + if (err) + return (err); + + if (copyin(args, &p, sizeof (struct lp_args))) + return (EFAULT); + str = malloc(p.len, M_SEBSD, M_WAITOK); + if (!str) + return (ENOMEM); + if (copyin(p.data, str, p.len)) { + free(str, M_SEBSD); + return (EFAULT); + } + + str[p.len-1] = 0; + err = security_set_bool(str+1, str[0]-'0'); + free(str, M_SEBSD); + break; + } + + case SEBSDCALL_COMMIT_BOOLS: + err = thread_has_security(td, SECURITY__SETBOOL); + if (err) + return (err); + + return security_commit_pending_bools(); + default: err = EINVAL; break; ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_syscalls.h#2 (text+ko) ==== @@ -5,6 +5,10 @@ * TBD: Should we really try to line up with SELinux? */ #define SEBSDCALL_LOAD_POLICY 7 +#define SEBSDCALL_GET_BOOLS 8 +#define SEBSDCALL_GET_BOOL 9 +#define SEBSDCALL_SET_BOOL 10 +#define SEBSDCALL_COMMIT_BOOLS 11 #define SEBSDCALL_GETUSERSIDS 6 #define SEBSDCALL_GETFILESIDS 5 #define SEBSDCALL_CHANGE_SID 4 @@ -28,6 +32,10 @@ u32 seqno; }; +struct sebsd_get_bools { + int len; + char *out; +}; #endif /* _SEBSD_SYSCALLS_H_ */ ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd_sysctl.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/avtab.c#2 (text+ko) ==== @@ -4,6 +4,16 @@ * Author : Stephen Smalley, */ +/* Updated: Frank Mayer and Karl MacMillan + * + * Added conditional policy language extensions + * + * Copyright (C) 2003 Tresys Technology, LLC + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 2. + */ + #ifdef _KERNEL #include #include @@ -22,6 +32,29 @@ (keyp->source_type << 9)) & \ AVTAB_HASH_MASK) +static struct avtab_node* +avtab_insert_node(struct avtab *h, int hvalue, struct avtab_node * prev, struct avtab_node * cur, + struct avtab_key *key, struct avtab_datum *datum) +{ + struct avtab_node * newnode; + newnode = kmalloc(sizeof(*newnode), GFP_KERNEL); + if (newnode == NULL) + return NULL; + memset(newnode, 0, sizeof(struct avtab_node)); + newnode->key = *key; + newnode->datum = *datum; + if (prev) { + newnode->next = prev->next; + prev->next = newnode; + } else { + newnode->next = h->htable[hvalue]; + h->htable[hvalue] = newnode; + } + + h->nel++; + return newnode; +} + int avtab_insert(struct avtab *h, struct avtab_key *key, struct avtab_datum *datum) { int hvalue; @@ -50,25 +83,49 @@ break; } - newnode = kmalloc(sizeof(*newnode), GFP_KERNEL); - if (newnode == NULL) + newnode = avtab_insert_node(h, hvalue, prev, cur, key, datum); + if(!newnode) return ENOMEM; - memset(newnode, 0, sizeof(*newnode)); - newnode->key = *key; - newnode->datum = *datum; - if (prev) { - newnode->next = prev->next; - prev->next = newnode; - } else { - newnode->next = h->htable[hvalue]; - h->htable[hvalue] = newnode; - } - h->nel++; return 0; } +/* Unlike avtab_insert(), this function allow multiple insertions of the same + * key/specified mask into the table, as needed by the conditional avtab. + * It also returns a pointer to the node inserted. + */ +struct avtab_node * +avtab_insert_nonunique(struct avtab * h, struct avtab_key * key, struct avtab_datum * datum) +{ + int hvalue; + struct avtab_node *prev, *cur, *newnode; + if (!h) + return NULL; + hvalue = AVTAB_HASH(key); + for (prev = NULL, cur = h->htable[hvalue]; + cur; + prev = cur, cur = cur->next) { + if (key->source_type == cur->key.source_type && + key->target_type == cur->key.target_type && + key->target_class == cur->key.target_class && + (datum->specified & cur->datum.specified)) + break; + if (key->source_type < cur->key.source_type) + break; + if (key->source_type == cur->key.source_type && + key->target_type < cur->key.target_type) + break; + if (key->source_type == cur->key.source_type && + key->target_type == cur->key.target_type && + key->target_class < cur->key.target_class) + break; + } + newnode = avtab_insert_node(h, hvalue, prev, cur, key, datum); + + return newnode; +} + struct avtab_datum *avtab_search(struct avtab *h, struct avtab_key *key, int specified) { int hvalue; @@ -99,12 +156,73 @@ return NULL; } +/* This search function returns a node pointer, and can be used in + * conjunction with avtab_search_next_node() + */ +struct avtab_node* +avtab_search_node(struct avtab *h, struct avtab_key *key, int specified) +{ + int hvalue; + struct avtab_node *cur; + + if (!h) + return NULL; + + hvalue = AVTAB_HASH(key); + for (cur = h->htable[hvalue]; cur; cur = cur->next) { + if (key->source_type == cur->key.source_type && + key->target_type == cur->key.target_type && + key->target_class == cur->key.target_class && + (specified & cur->datum.specified)) + return cur; + + if (key->source_type < cur->key.source_type) + break; + if (key->source_type == cur->key.source_type && + key->target_type < cur->key.target_type) + break; + if (key->source_type == cur->key.source_type && + key->target_type == cur->key.target_type && + key->target_class < cur->key.target_class) + break; + } + return NULL; +} + +struct avtab_node* +avtab_search_node_next(struct avtab_node *node, int specified) +{ + struct avtab_node *cur; + + if (!node) + return NULL; + + for (cur = node->next; cur; cur = cur->next) { + if (node->key.source_type == cur->key.source_type && + node->key.target_type == cur->key.target_type && + node->key.target_class == cur->key.target_class && + (specified & cur->datum.specified)) + return cur; + + if (node->key.source_type < cur->key.source_type) + break; + if (node->key.source_type == cur->key.source_type && + node->key.target_type < cur->key.target_type) + break; + if (node->key.source_type == cur->key.source_type && + node->key.target_type == cur->key.target_type && + node->key.target_class < cur->key.target_class) + break; + } + return NULL; +} + void avtab_destroy(struct avtab *h) { int i; struct avtab_node *cur, *temp; - if (!h) + if (!h || !h->htable) return; for (i = 0; i < AVTAB_SIZE; i++) { @@ -117,6 +235,7 @@ h->htable[i] = NULL; } kfree(h->htable); + h->htable = NULL; } @@ -184,6 +303,67 @@ max_chain_len); } +int avtab_read_item(void *fp, struct avtab_datum *avdatum, struct avtab_key *avkey) +{ + u32 *buf; + u32 items, items2; + + memset(avkey, 0, sizeof(struct avtab_key)); + memset(avdatum, 0, sizeof(struct avtab_datum)); + + buf = next_entry(fp, sizeof(u32)); + if (!buf) { + printk(KERN_ERR "security: avtab: truncated entry\n"); + goto bad; + } + items2 = le32_to_cpu(buf[0]); + buf = next_entry(fp, sizeof(u32)*items2); + if (!buf) { + printk(KERN_ERR "security: avtab: truncated entry\n"); + goto bad; + } + items = 0; + avkey->source_type = le32_to_cpu(buf[items++]); + avkey->target_type = le32_to_cpu(buf[items++]); + avkey->target_class = le32_to_cpu(buf[items++]); + avdatum->specified = le32_to_cpu(buf[items++]); + if (!(avdatum->specified & (AVTAB_AV | AVTAB_TYPE))) { + printk(KERN_ERR "security: avtab: null entry\n"); + goto bad; + } + if ((avdatum->specified & AVTAB_AV) && + (avdatum->specified & AVTAB_TYPE)) { + printk(KERN_ERR "security: avtab: entry has both access vectors and types\n"); + goto bad; + } + + + if (avdatum->specified & AVTAB_AV) { + if (avdatum->specified & AVTAB_ALLOWED) + avtab_allowed(avdatum) = le32_to_cpu(buf[items++]); + if (avdatum->specified & AVTAB_AUDITDENY) + avtab_auditdeny(avdatum) = le32_to_cpu(buf[items++]); + if (avdatum->specified & AVTAB_AUDITALLOW) + avtab_auditallow(avdatum) = le32_to_cpu(buf[items++]); + } else { + if (avdatum->specified & AVTAB_TRANSITION) + avtab_transition(avdatum) = le32_to_cpu(buf[items++]); + if (avdatum->specified & AVTAB_CHANGE) + avtab_change(avdatum) = le32_to_cpu(buf[items++]); + if (avdatum->specified & AVTAB_MEMBER) + avtab_member(avdatum) = le32_to_cpu(buf[items++]); + } + if (items != items2) { + printk(KERN_ERR "security: avtab: entry only had %d items, expected %d\n", + items2, items); + goto bad; + } + + return 0; +bad: + return -1; +} + int avtab_read(struct avtab *a, void *fp, u32 config) { int i, rc = EINVAL; @@ -204,67 +384,8 @@ goto bad; } for (i = 0; i < nel; i++) { - memset(&avkey, 0, sizeof(avkey)); - memset(&avdatum, 0, sizeof(avdatum)); - - buf = next_entry(fp, sizeof(u32)); - if (!buf) { - printk(KERN_ERR "security: avtab: truncated entry\n"); - goto bad; - } - items2 = le32_to_cpu(buf[0]); - buf = next_entry(fp, sizeof(u32)*items2); - if (!buf) { - printk(KERN_ERR "security: avtab: truncated entry\n"); - goto bad; - } - items = 0; - avkey.source_type = le32_to_cpu(buf[items++]); - avkey.target_type = le32_to_cpu(buf[items++]); - avkey.target_class = le32_to_cpu(buf[items++]); - avdatum.specified = le32_to_cpu(buf[items++]); - if (!(avdatum.specified & (AVTAB_AV | AVTAB_TYPE))) { - printk(KERN_ERR "security: avtab: null entry\n"); - goto bad; - } - if ((avdatum.specified & AVTAB_AV) && - (avdatum.specified & AVTAB_TYPE)) { - printk(KERN_ERR "security: avtab: entry has both " - "access vectors and types\n"); + if (avtab_read_item(fp, &avdatum, &avkey)) goto bad; - } - if (avdatum.specified & AVTAB_AV) { - if (avdatum.specified & AVTAB_ALLOWED) - { - u32 b1 = le32_to_cpu (buf[items++]); - u32 b2 = le32_to_cpu (buf[items++]); - avtab_allowed(&avdatum) = (((u64) b1) << 32) | b2; - } - if (avdatum.specified & AVTAB_AUDITDENY) - { - u32 b1 = le32_to_cpu (buf[items++]); - u32 b2 = le32_to_cpu (buf[items++]); - avtab_auditdeny(&avdatum) = (((u64) b1) << 32) | b2; - } - if (avdatum.specified & AVTAB_AUDITALLOW) - { - u32 b1 = le32_to_cpu (buf[items++]); - u32 b2 = le32_to_cpu (buf[items++]); - avtab_auditallow(&avdatum) = (((u64) b1) << 32) | b2; - } - } else { - if (avdatum.specified & AVTAB_TRANSITION) - avtab_transition(&avdatum) = le32_to_cpu(buf[items++]); - if (avdatum.specified & AVTAB_CHANGE) - avtab_change(&avdatum) = le32_to_cpu(buf[items++]); - if (avdatum.specified & AVTAB_MEMBER) - avtab_member(&avdatum) = le32_to_cpu(buf[items++]); - } - if (items != items2) { - printk(KERN_ERR "security: avtab: entry only had %d " - "items, expected %d\n", items2, items); - goto bad; - } rc = avtab_insert(a, &avkey, &avdatum); if (rc) { if (rc == ENOMEM) ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/avtab.h#2 (text+ko) ==== @@ -7,6 +7,16 @@ * * Author : Stephen Smalley, */ + +/* Updated: Frank Mayer and Karl MacMillan + * + * Added conditional policy language extensions + * + * Copyright (C) 2003 Tresys Technology, LLC + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 2. + */ #ifndef _SS_AVTAB_H_ #define _SS_AVTAB_H_ @@ -27,6 +37,7 @@ #define AVTAB_MEMBER 32 #define AVTAB_CHANGE 64 #define AVTAB_TYPE (AVTAB_TRANSITION | AVTAB_MEMBER | AVTAB_CHANGE) +#define AVTAB_ENABLED 0x80000000 /* reserved for used in cond_avtab */ u32 specified; /* what fields are specified */ access_vector_t data[3]; /* access vectors or types */ #define avtab_allowed(x) (x)->data[0] @@ -58,8 +69,19 @@ void *args), void *args); void avtab_hash_eval(struct avtab *h, char *tag); + +int avtab_read_item(void *fp, struct avtab_datum *avdatum, struct avtab_key *avkey); int avtab_read(struct avtab *a, void *fp, u32 config); +struct avtab_node *avtab_insert_nonunique(struct avtab *h, struct avtab_key *key, + struct avtab_datum *datum); + +struct avtab_node *avtab_search_node(struct avtab *h, struct avtab_key *key, int specified); + +struct avtab_node *avtab_search_node_next(struct avtab_node *node, int specified); + +void avtab_cache_init(void); + #define AVTAB_HASH_BITS 15 #define AVTAB_HASH_BUCKETS (1 << AVTAB_HASH_BITS) #define AVTAB_HASH_MASK (AVTAB_HASH_BUCKETS-1) ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/constraint.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/context.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/ebitmap.c#2 (text+ko) ==== @@ -21,7 +21,7 @@ n1 = e1->node; n2 = e2->node; - prev = 0; + prev = NULL; while (n1 || n2) { new = kmalloc(sizeof(*new), GFP_ATOMIC); if (!new) { @@ -44,7 +44,7 @@ n2 = n2->next; } - new->next = 0; + new->next = NULL; if (prev) prev->next = new; else @@ -94,7 +94,7 @@ memset(new, 0, sizeof(*new)); new->startbit = n->startbit; new->map = n->map; - new->next = 0; + new->next = NULL; if (prev) prev->next = new; else @@ -159,7 +159,7 @@ { struct ebitmap_node *n, *prev, *new; - prev = 0; + prev = NULL; n = e->node; while (n && n->startbit <= bit) { if ((n->startbit + MAPSIZE) > bit) { @@ -235,7 +235,7 @@ } e->highbit = 0; - e->node = 0; + e->node = NULL; return; } @@ -257,8 +257,8 @@ count = le32_to_cpu(buf[2]); if (mapsize != MAPSIZE) { - printk(KERN_ERR "security: ebitmap: map size %d does not " - "match my size %d (high bit was %d)\n", mapsize, + printk(KERN_ERR "security: ebitmap: map size %u does not " + "match my size %Zd (high bit was %d)\n", mapsize, MAPSIZE, e->highbit); goto out; } @@ -268,7 +268,7 @@ } if (e->highbit & (MAPSIZE - 1)) { printk(KERN_ERR "security: ebitmap: high bit (%d) is not a " - "multiple of the map size (%d)\n", e->highbit, MAPSIZE); + "multiple of the map size (%Zd)\n", e->highbit, MAPSIZE); goto bad; } l = NULL; @@ -290,13 +290,13 @@ if (n->startbit & (MAPSIZE - 1)) { printk(KERN_ERR "security: ebitmap start bit (%d) is " - "not a multiple of the map size (%d)\n", + "not a multiple of the map size (%Zd)\n", n->startbit, MAPSIZE); goto bad_free; } if (n->startbit > (e->highbit - MAPSIZE)) { printk(KERN_ERR "security: ebitmap start bit (%d) is " - "beyond the end of the bitmap (%d)\n", + "beyond the end of the bitmap (%Zd)\n", n->startbit, (e->highbit - MAPSIZE)); goto bad_free; } ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/ebitmap.h#2 (text+ko) ==== @@ -56,7 +56,7 @@ static inline void ebitmap_init(struct ebitmap *e) { - bzero(e, sizeof(*e)); + memset(e, 0, sizeof(*e)); } int ebitmap_cmp(struct ebitmap *e1, struct ebitmap *e2); ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/fileutils.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/fileutils.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/global.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/hashtab.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/hashtab.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/init.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/ss/policydb.c#2 (text+ko) ==== @@ -4,6 +4,16 @@ * Author : Stephen Smalley, */ +/* Updated: Frank Mayer and Karl MacMillan + * + * Added conditional policy language extensions + * + * Copyright (C) 2003 - 2004 Tresys Technology, LLC + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 2. + */ + #if defined(__FreeBSD__) && defined(_KERNEL) #include #include @@ -26,26 +36,74 @@ "classes", "roles", "types", - "users" + "users", mls_symtab_names + "bools" }; #endif +int policydb_loaded_version; + static unsigned int symtab_sizes[SYM_NUM] = { 2, 32, 16, 512, - 128 + 128, mls_symtab_sizes + 16 +}; + +struct policydb_compat_info { + int version; + int sym_num; + int ocon_num; +}; + +/* These need to be updated if SYM_NUM or OCON_NUM changes */ +static struct policydb_compat_info policydb_compat[] = { + { + .version = POLICYDB_VERSION_BASE, + .sym_num = SYM_NUM - 1, + .ocon_num = OCON_NUM - 1, + }, + { + .version = POLICYDB_VERSION_BOOL, + .sym_num = SYM_NUM, + .ocon_num = OCON_NUM - 1, + }, + { + .version = POLICYDB_VERSION_IPV6, + .sym_num = SYM_NUM, + .ocon_num = OCON_NUM, + }, + { + .version = POLICYDB_VERSION_NLCLASS, + .sym_num = SYM_NUM, + .ocon_num = OCON_NUM, + }, }; +static struct policydb_compat_info *policydb_lookup_compat(int version) +{ + int i; + struct policydb_compat_info *info = NULL; + + for (i = 0; i < sizeof(policydb_compat)/sizeof(*info); i++) { + if (policydb_compat[i].version == version) { + info = &policydb_compat[i]; + break; + } + } + return info; +} + /* * Initialize the role table. */ int roles_init(struct policydb *p) { - char *key = 0; + char *key = NULL; int rc; struct role_datum *role; @@ -102,6 +160,10 @@ if (rc) goto out_free_avtab; + rc = cond_policydb_init(p); + if (rc) + goto out_free_avtab; + out: return rc; @@ -131,6 +193,8 @@ comdatum = datum; p = datap; + if (!comdatum->value || comdatum->value > p->p_commons.nprim) + return EINVAL; p->p_common_val_to_name[comdatum->value - 1] = key; return 0; } @@ -142,6 +206,8 @@ cladatum = datum; p = datap; + if (!cladatum->value || cladatum->value > p->p_classes.nprim) + return EINVAL; p->p_class_val_to_name[cladatum->value - 1] = key; p->class_val_to_struct[cladatum->value - 1] = cladatum; return 0; @@ -154,6 +220,8 @@ role = datum; p = datap; + if (!role->value || role->value > p->p_roles.nprim) + return EINVAL; p->p_role_val_to_name[role->value - 1] = key; p->role_val_to_struct[role->value - 1] = role; return 0; @@ -167,8 +235,11 @@ typdatum = datum; p = datap; - if (typdatum->primary) + if (typdatum->primary) { + if (!typdatum->value || typdatum->value > p->p_types.nprim) + return EINVAL; p->p_type_val_to_name[typdatum->value - 1] = key; + } return 0; >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Fri May 6 14:33:16 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8685A16A4D5; Fri, 6 May 2005 14:33:15 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3045516A4D3 for ; Fri, 6 May 2005 14:33:15 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0377C43D7E for ; Fri, 6 May 2005 14:33:15 +0000 (GMT) (envelope-from areisse@nailabs.com) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j46EXECp070049 for ; Fri, 6 May 2005 14:33:14 GMT (envelope-from areisse@nailabs.com) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j46EXEVr070046 for perforce@freebsd.org; Fri, 6 May 2005 14:33:14 GMT (envelope-from areisse@nailabs.com) Date: Fri, 6 May 2005 14:33:14 GMT Message-Id: <200505061433.j46EXEVr070046@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to areisse@nailabs.com using -f From: Andrew Reisse To: Perforce Change Reviews Subject: PERFORCE change 76615 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 May 2005 14:33:16 -0000 http://perforce.freebsd.org/chv.cgi?CH=76615 Change 76615 by areisse@areisse_ibook on 2005/05/06 14:32:21 Bring over flask configuration changes from selinux version 2004081908 (networking changes, booleans). Affected files ... .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/av_perm_to_string.h#2 edit .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/av_permissions.h#2 edit .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/class_to_string.h#2 edit .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/initial_sid_to_string.h#2 edit .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask.h#3 edit .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask/access_vectors#2 integrate .. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask/initial_sids#2 integrate Differences ... ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/av_perm_to_string.h#2 (text+ko) ==== @@ -31,6 +31,9 @@ { SECCLASS_TCP_SOCKET, TCP_SOCKET__CONNECTTO, "connectto" }, { SECCLASS_TCP_SOCKET, TCP_SOCKET__NEWCONN, "newconn" }, { SECCLASS_TCP_SOCKET, TCP_SOCKET__ACCEPTFROM, "acceptfrom" }, + { SECCLASS_TCP_SOCKET, TCP_SOCKET__NODE_BIND, "node_bind" }, + { SECCLASS_UDP_SOCKET, UDP_SOCKET__NODE_BIND, "node_bind" }, + { SECCLASS_RAWIP_SOCKET, RAWIP_SOCKET__NODE_BIND, "node_bind" }, { SECCLASS_NODE, NODE__TCP_RECV, "tcp_recv" }, { SECCLASS_NODE, NODE__TCP_SEND, "tcp_send" }, { SECCLASS_NODE, NODE__UDP_RECV, "udp_recv" }, @@ -54,6 +57,7 @@ { SECCLASS_PROCESS, PROCESS__SIGCHLD, "sigchld" }, { SECCLASS_PROCESS, PROCESS__SIGKILL, "sigkill" }, { SECCLASS_PROCESS, PROCESS__SIGSTOP, "sigstop" }, + { SECCLASS_PROCESS, PROCESS__SIGNULL, "signull" }, { SECCLASS_PROCESS, PROCESS__SIGNAL, "signal" }, { SECCLASS_PROCESS, PROCESS__PTRACE, "ptrace" }, { SECCLASS_PROCESS, PROCESS__GETSCHED, "getsched" }, @@ -64,30 +68,28 @@ { SECCLASS_PROCESS, PROCESS__GETCAP, "getcap" }, { SECCLASS_PROCESS, PROCESS__SETCAP, "setcap" }, { SECCLASS_PROCESS, PROCESS__SHARE, "share" }, + { SECCLASS_PROCESS, PROCESS__GETATTR, "getattr" }, + { SECCLASS_PROCESS, PROCESS__SETEXEC, "setexec" }, + { SECCLASS_PROCESS, PROCESS__SETFSCREATE, "setfscreate" }, { SECCLASS_PROCESS, PROCESS__NOATSECURE, "noatsecure" }, + { SECCLASS_PROCESS, PROCESS__SIGINH, "siginh" }, + { SECCLASS_PROCESS, PROCESS__SETRLIMIT, "setrlimit" }, + { SECCLASS_PROCESS, PROCESS__RLIMITINH, "rlimitinh" }, { SECCLASS_MSGQ, MSGQ__ENQUEUE, "enqueue" }, { SECCLASS_MSG, MSG__SEND, "send" }, { SECCLASS_MSG, MSG__RECEIVE, "receive" }, + { SECCLASS_MSG, MSG__DESTROY, "destroy" }, { SECCLASS_SHM, SHM__LOCK, "lock" }, { SECCLASS_SECURITY, SECURITY__COMPUTE_AV, "compute_av" }, - { SECCLASS_SECURITY, SECURITY__NOTIFY_PERM, "notify_perm" }, - { SECCLASS_SECURITY, SECURITY__TRANSITION_SID, "transition_sid" }, - { SECCLASS_SECURITY, SECURITY__MEMBER_SID, "member_sid" }, - { SECCLASS_SECURITY, SECURITY__SID_TO_CONTEXT, "sid_to_context" }, - { SECCLASS_SECURITY, SECURITY__CONTEXT_TO_SID, "context_to_sid" }, + { SECCLASS_SECURITY, SECURITY__COMPUTE_CREATE, "compute_create" }, + { SECCLASS_SECURITY, SECURITY__COMPUTE_MEMBER, "compute_member" }, + { SECCLASS_SECURITY, SECURITY__CHECK_CONTEXT, "check_context" }, { SECCLASS_SECURITY, SECURITY__LOAD_POLICY, "load_policy" }, - { SECCLASS_SECURITY, SECURITY__GET_SIDS, "get_sids" }, - { SECCLASS_SECURITY, SECURITY__REGISTER_AVC, "register_avc" }, - { SECCLASS_SECURITY, SECURITY__CHANGE_SID, "change_sid" }, - { SECCLASS_SECURITY, SECURITY__GET_USER_SIDS, "get_user_sids" }, - { SECCLASS_SYSTEM, SYSTEM__NET_IO_CONTROL, "net_io_control" }, - { SECCLASS_SYSTEM, SYSTEM__ROUTE_CONTROL, "route_control" }, - { SECCLASS_SYSTEM, SYSTEM__ARP_CONTROL, "arp_control" }, - { SECCLASS_SYSTEM, SYSTEM__RARP_CONTROL, "rarp_control" }, + { SECCLASS_SECURITY, SECURITY__COMPUTE_RELABEL, "compute_relabel" }, + { SECCLASS_SECURITY, SECURITY__COMPUTE_USER, "compute_user" }, + { SECCLASS_SECURITY, SECURITY__SETENFORCE, "setenforce" }, + { SECCLASS_SECURITY, SECURITY__SETBOOL, "setbool" }, { SECCLASS_SYSTEM, SYSTEM__IPC_INFO, "ipc_info" }, - { SECCLASS_SYSTEM, SYSTEM__AVC_TOGGLE, "avc_toggle" }, - { SECCLASS_SYSTEM, SYSTEM__NFSD_CONTROL, "nfsd_control" }, - { SECCLASS_SYSTEM, SYSTEM__BDFLUSH, "bdflush" }, { SECCLASS_SYSTEM, SYSTEM__SYSLOG_READ, "syslog_read" }, { SECCLASS_SYSTEM, SYSTEM__SYSLOG_MOD, "syslog_mod" }, { SECCLASS_SYSTEM, SYSTEM__SYSLOG_CONSOLE, "syslog_console" }, @@ -98,23 +100,11 @@ { SECCLASS_CAPABILITY, CAPABILITY__FOWNER, "fowner" }, { SECCLASS_CAPABILITY, CAPABILITY__FSETID, "fsetid" }, { SECCLASS_CAPABILITY, CAPABILITY__KILL, "kill" }, - { SECCLASS_CAPABILITY, CAPABILITY__LINK_DIR, "link_dir" }, { SECCLASS_CAPABILITY, CAPABILITY__SETFCAP, "setfcap" }, { SECCLASS_CAPABILITY, CAPABILITY__SETGID, "setgid" }, { SECCLASS_CAPABILITY, CAPABILITY__SETUID, "setuid" }, - { SECCLASS_CAPABILITY, CAPABILITY__MAC_DOWNGRADE, "mac_downgrade" }, - { SECCLASS_CAPABILITY, CAPABILITY__MAC_READ, "mac_read" }, - { SECCLASS_CAPABILITY, CAPABILITY__MAC_RELABEL_SUBJ, "mac_relabel_subj" }, - { SECCLASS_CAPABILITY, CAPABILITY__MAC_UPGRADE, "mac_upgrade" }, - { SECCLASS_CAPABILITY, CAPABILITY__MAC_WRITE, "mac_write" }, - { SECCLASS_CAPABILITY, CAPABILITY__INF_NOFLOAT_OBJ, "inf_nofloat_obj" }, - { SECCLASS_CAPABILITY, CAPABILITY__INF_NOFLOAT_SUBJ, "inf_nofloat_subj" }, - { SECCLASS_CAPABILITY, CAPABILITY__INF_RELABEL_OBJ, "inf_relabel_obj" }, - { SECCLASS_CAPABILITY, CAPABILITY__INF_RELABEL_SUBJ, "inf_relabel_subj" }, { SECCLASS_CAPABILITY, CAPABILITY__AUDIT_CONTROL, "audit_control" }, { SECCLASS_CAPABILITY, CAPABILITY__AUDIT_WRITE, "audit_write" }, - { SECCLASS_CAPABILITY, CAPABILITY__SETPCAP, "setpcap" }, - { SECCLASS_CAPABILITY, CAPABILITY__XXX_INVALID1, "xxx_invalid1" }, { SECCLASS_CAPABILITY, CAPABILITY__LINUX_IMMUTABLE, "linux_immutable" }, { SECCLASS_CAPABILITY, CAPABILITY__NET_BIND_SERVICE, "net_bind_service" }, { SECCLASS_CAPABILITY, CAPABILITY__NET_BROADCAST, "net_broadcast" }, ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/av_permissions.h#2 (text+ko) ==== @@ -280,6 +280,7 @@ #define TCP_SOCKET__CONNECTTO 0x0000000001000000UL #define TCP_SOCKET__NEWCONN 0x0000000002000000UL #define TCP_SOCKET__ACCEPTFROM 0x0000000004000000UL +#define TCP_SOCKET__NODE_BIND 0x0000000008000000UL #define UDP_SOCKET__TRANSITION 0x0000000000000400UL #define UDP_SOCKET__SHUTDOWN 0x0000000000040000UL @@ -306,6 +307,8 @@ #define UDP_SOCKET__IOCTL 0x0000000000000002UL #define UDP_SOCKET__RELABELTO 0x0000000000000200UL +#define UDP_SOCKET__NODE_BIND 0x0000000001000000UL + #define RAWIP_SOCKET__TRANSITION 0x0000000000000400UL #define RAWIP_SOCKET__SHUTDOWN 0x0000000000040000UL #define RAWIP_SOCKET__POLL 0x0000000000000001UL @@ -331,6 +334,8 @@ #define RAWIP_SOCKET__IOCTL 0x0000000000000002UL #define RAWIP_SOCKET__RELABELTO 0x0000000000000200UL +#define RAWIP_SOCKET__NODE_BIND 0x0000000001000000UL + #define NODE__TCP_RECV 0x0000000000000001UL #define NODE__TCP_SEND 0x0000000000000002UL #define NODE__UDP_RECV 0x0000000000000004UL @@ -482,17 +487,24 @@ #define PROCESS__SIGCHLD 0x0000000000000004UL #define PROCESS__SIGKILL 0x0000000000000008UL #define PROCESS__SIGSTOP 0x0000000000000010UL -#define PROCESS__SIGNAL 0x0000000000000020UL -#define PROCESS__PTRACE 0x0000000000000040UL -#define PROCESS__GETSCHED 0x0000000000000080UL -#define PROCESS__SETSCHED 0x0000000000000100UL -#define PROCESS__GETSESSION 0x0000000000000200UL -#define PROCESS__GETPGID 0x0000000000000400UL -#define PROCESS__SETPGID 0x0000000000000800UL -#define PROCESS__GETCAP 0x0000000000001000UL -#define PROCESS__SETCAP 0x0000000000002000UL -#define PROCESS__SHARE 0x0000000000004000UL -#define PROCESS__NOATSECURE 0x0000000000008000UL +#define PROCESS__SIGNULL 0x0000000000000020UL +#define PROCESS__SIGNAL 0x0000000000000040UL +#define PROCESS__PTRACE 0x0000000000000080UL +#define PROCESS__GETSCHED 0x0000000000000100UL +#define PROCESS__SETSCHED 0x0000000000000200UL +#define PROCESS__GETSESSION 0x0000000000000400UL +#define PROCESS__GETPGID 0x0000000000000800UL +#define PROCESS__SETPGID 0x0000000000001000UL +#define PROCESS__GETCAP 0x0000000000002000UL +#define PROCESS__SETCAP 0x0000000000004000UL +#define PROCESS__SHARE 0x0000000000008000UL +#define PROCESS__GETATTR 0x0000000000010000UL +#define PROCESS__SETEXEC 0x0000000000020000UL +#define PROCESS__SETFSCREATE 0x0000000000040000UL +#define PROCESS__NOATSECURE 0x0000000000080000UL +#define PROCESS__SIGINH 0x0000000000100000UL +#define PROCESS__SETRLIMIT 0x0000000000200000UL +#define PROCESS__RLIMITINH 0x0000000000400000UL #define IPC__WRITE 0x0000000000000020UL #define IPC__UNIX_WRITE 0x0000000000000100UL @@ -528,6 +540,7 @@ #define MSG__SEND 0x0000000000000001UL #define MSG__RECEIVE 0x0000000000000002UL +#define MSG__DESTROY 0x0000000000000004UL #define SHM__WRITE 0x0000000000000020UL #define SHM__UNIX_WRITE 0x0000000000000100UL @@ -542,28 +555,19 @@ #define SHM__LOCK 0x0000000000000200UL #define SECURITY__COMPUTE_AV 0x0000000000000001UL -#define SECURITY__NOTIFY_PERM 0x0000000000000002UL -#define SECURITY__TRANSITION_SID 0x0000000000000004UL -#define SECURITY__MEMBER_SID 0x0000000000000008UL -#define SECURITY__SID_TO_CONTEXT 0x0000000000000010UL -#define SECURITY__CONTEXT_TO_SID 0x0000000000000020UL -#define SECURITY__LOAD_POLICY 0x0000000000000040UL -#define SECURITY__GET_SIDS 0x0000000000000080UL -#define SECURITY__REGISTER_AVC 0x0000000000000100UL -#define SECURITY__CHANGE_SID 0x0000000000000200UL -#define SECURITY__GET_USER_SIDS 0x0000000000000400UL +#define SECURITY__COMPUTE_CREATE 0x0000000000000002UL +#define SECURITY__COMPUTE_MEMBER 0x0000000000000004UL +#define SECURITY__CHECK_CONTEXT 0x0000000000000008UL +#define SECURITY__LOAD_POLICY 0x0000000000000010UL +#define SECURITY__COMPUTE_RELABEL 0x0000000000000020UL +#define SECURITY__COMPUTE_USER 0x0000000000000040UL +#define SECURITY__SETENFORCE 0x0000000000000080UL +#define SECURITY__SETBOOL 0x0000000000000100UL -#define SYSTEM__NET_IO_CONTROL 0x0000000000000001UL -#define SYSTEM__ROUTE_CONTROL 0x0000000000000002UL -#define SYSTEM__ARP_CONTROL 0x0000000000000004UL -#define SYSTEM__RARP_CONTROL 0x0000000000000008UL -#define SYSTEM__IPC_INFO 0x0000000000000010UL -#define SYSTEM__AVC_TOGGLE 0x0000000000000020UL -#define SYSTEM__NFSD_CONTROL 0x0000000000000040UL -#define SYSTEM__BDFLUSH 0x0000000000000080UL -#define SYSTEM__SYSLOG_READ 0x0000000000000100UL -#define SYSTEM__SYSLOG_MOD 0x0000000000000200UL -#define SYSTEM__SYSLOG_CONSOLE 0x0000000000000400UL +#define SYSTEM__IPC_INFO 0x0000000000000001UL +#define SYSTEM__SYSLOG_READ 0x0000000000000002UL +#define SYSTEM__SYSLOG_MOD 0x0000000000000004UL +#define SYSTEM__SYSLOG_CONSOLE 0x0000000000000008UL #define CAPABILITY__CHOWN 0x0000000000000001UL #define CAPABILITY__DAC_EXECUTE 0x0000000000000002UL @@ -572,43 +576,31 @@ #define CAPABILITY__FOWNER 0x0000000000000010UL #define CAPABILITY__FSETID 0x0000000000000020UL #define CAPABILITY__KILL 0x0000000000000040UL -#define CAPABILITY__LINK_DIR 0x0000000000000080UL -#define CAPABILITY__SETFCAP 0x0000000000000100UL -#define CAPABILITY__SETGID 0x0000000000000200UL -#define CAPABILITY__SETUID 0x0000000000000400UL -#define CAPABILITY__MAC_DOWNGRADE 0x0000000000000800UL -#define CAPABILITY__MAC_READ 0x0000000000001000UL -#define CAPABILITY__MAC_RELABEL_SUBJ 0x0000000000002000UL -#define CAPABILITY__MAC_UPGRADE 0x0000000000004000UL -#define CAPABILITY__MAC_WRITE 0x0000000000008000UL -#define CAPABILITY__INF_NOFLOAT_OBJ 0x0000000000010000UL -#define CAPABILITY__INF_NOFLOAT_SUBJ 0x0000000000020000UL -#define CAPABILITY__INF_RELABEL_OBJ 0x0000000000040000UL -#define CAPABILITY__INF_RELABEL_SUBJ 0x0000000000080000UL -#define CAPABILITY__AUDIT_CONTROL 0x0000000000100000UL -#define CAPABILITY__AUDIT_WRITE 0x0000000000200000UL -#define CAPABILITY__SETPCAP 0x0000000000400000UL -#define CAPABILITY__XXX_INVALID1 0x0000000000800000UL -#define CAPABILITY__LINUX_IMMUTABLE 0x0000000001000000UL -#define CAPABILITY__NET_BIND_SERVICE 0x0000000002000000UL -#define CAPABILITY__NET_BROADCAST 0x0000000004000000UL -#define CAPABILITY__NET_ADMIN 0x0000000008000000UL -#define CAPABILITY__NET_RAW 0x0000000010000000UL -#define CAPABILITY__IPC_LOCK 0x0000000020000000UL -#define CAPABILITY__IPC_OWNER 0x0000000040000000UL -#define CAPABILITY__SYS_MODULE 0x000000007fffffffUL -#define CAPABILITY__SYS_RAWIO 0x0000000100000000UL -#define CAPABILITY__SYS_CHROOT 0x0000000200000000UL -#define CAPABILITY__SYS_PTRACE 0x0000000400000000UL -#define CAPABILITY__SYS_PACCT 0x0000000800000000UL -#define CAPABILITY__SYS_ADMIN 0x0000001000000000UL -#define CAPABILITY__SYS_BOOT 0x0000002000000000UL -#define CAPABILITY__SYS_NICE 0x0000004000000000UL -#define CAPABILITY__SYS_RESOURCE 0x0000008000000000UL -#define CAPABILITY__SYS_TIME 0x0000010000000000UL -#define CAPABILITY__SYS_TTY_CONFIG 0x0000020000000000UL -#define CAPABILITY__MKNOD 0x0000040000000000UL -#define CAPABILITY__LEASE 0x0000080000000000UL +#define CAPABILITY__SETFCAP 0x0000000000000080UL +#define CAPABILITY__SETGID 0x0000000000000100UL +#define CAPABILITY__SETUID 0x0000000000000200UL +#define CAPABILITY__AUDIT_CONTROL 0x0000000000000400UL +#define CAPABILITY__AUDIT_WRITE 0x0000000000000800UL +#define CAPABILITY__LINUX_IMMUTABLE 0x0000000000001000UL +#define CAPABILITY__NET_BIND_SERVICE 0x0000000000002000UL +#define CAPABILITY__NET_BROADCAST 0x0000000000004000UL +#define CAPABILITY__NET_ADMIN 0x0000000000008000UL +#define CAPABILITY__NET_RAW 0x0000000000010000UL +#define CAPABILITY__IPC_LOCK 0x0000000000020000UL +#define CAPABILITY__IPC_OWNER 0x0000000000040000UL +#define CAPABILITY__SYS_MODULE 0x0000000000080000UL +#define CAPABILITY__SYS_RAWIO 0x0000000000100000UL +#define CAPABILITY__SYS_CHROOT 0x0000000000200000UL +#define CAPABILITY__SYS_PTRACE 0x0000000000400000UL +#define CAPABILITY__SYS_PACCT 0x0000000000800000UL +#define CAPABILITY__SYS_ADMIN 0x0000000001000000UL +#define CAPABILITY__SYS_BOOT 0x0000000002000000UL +#define CAPABILITY__SYS_NICE 0x0000000004000000UL +#define CAPABILITY__SYS_RESOURCE 0x0000000008000000UL +#define CAPABILITY__SYS_TIME 0x0000000010000000UL +#define CAPABILITY__SYS_TTY_CONFIG 0x0000000020000000UL +#define CAPABILITY__MKNOD 0x0000000040000000UL +#define CAPABILITY__LEASE 0x000000007fffffffUL #define MACH_PORT__RELABELFROM 0x0000000000000001UL #define MACH_PORT__RELABELTO 0x0000000000000002UL ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/class_to_string.h#2 (text+ko) ==== @@ -35,6 +35,10 @@ "shm", "ipc", "mach_port", + "port_methods1", + "port_methods2", + "port_methods3", + "port_methods4", "mach_task", }; ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/avc/initial_sid_to_string.h#2 (text+ko) ==== @@ -30,6 +30,8 @@ "devpts", "nfs", "policy", + "scmp_packet", + "devnull", "tmpfs", }; ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask.h#3 (text+ko) ==== @@ -74,8 +74,10 @@ #define SECINITSID_DEVPTS 26 #define SECINITSID_NFS 27 #define SECINITSID_POLICY 28 -#define SECINITSID_TMPFS 29 +#define SECINITSID_SCMP_PACKET 29 +#define SECINITSID_DEVNULL 30 +#define SECINITSID_TMPFS 31 -#define SECINITSID_NUM 29 +#define SECINITSID_NUM 31 #endif ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask/access_vectors#2 (text+ko) ==== @@ -160,13 +160,20 @@ connectto newconn acceptfrom + node_bind } class udp_socket inherits socket +{ + node_bind +} class rawip_socket inherits socket +{ + node_bind +} class node { @@ -220,10 +227,11 @@ { fork transition - sigchld - sigkill - sigstop - signal + sigchld # commonly granted from child to parent + sigkill # cannot be caught or ignored + sigstop # cannot be caught or ignored + signull # for kill(pid, 0) + signal # all other signals ptrace getsched setsched @@ -233,7 +241,13 @@ getcap setcap share + getattr + setexec + setfscreate noatsecure + siginh + setrlimit + rlimitinh } @@ -257,6 +271,7 @@ { send receive + destroy } class shm @@ -265,7 +280,6 @@ lock } - # # Define the access vector interpretation for the security server. # @@ -273,16 +287,14 @@ class security { compute_av - notify_perm - transition_sid - member_sid - sid_to_context - context_to_sid + compute_create + compute_member + check_context load_policy - get_sids - register_avc - change_sid - get_user_sids + compute_relabel + compute_user + setenforce # was avc_toggle in system class + setbool } @@ -292,15 +304,8 @@ class system { - net_io_control - route_control - arp_control - rarp_control ipc_info - avc_toggle - nfsd_control - bdflush - syslog_read + syslog_read syslog_mod syslog_console } @@ -322,23 +327,11 @@ fowner fsetid kill - link_dir setfcap setgid setuid - mac_downgrade - mac_read - mac_relabel_subj - mac_upgrade - mac_write - inf_nofloat_obj - inf_nofloat_subj - inf_relabel_obj - inf_relabel_subj audit_control audit_write - setpcap - xxx_invalid1 linux_immutable net_bind_service net_broadcast ==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/flask/initial_sids#2 (text+ko) ==== @@ -32,6 +32,8 @@ sid devpts sid nfs sid policy +sid scmp_packet +sid devnull sid tmpfs # FLASK From owner-p4-projects@FreeBSD.ORG Fri May 6 21:04:15 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id AA88616A4D8; Fri, 6 May 2005 21:04:14 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6D7D016A4D4 for ; Fri, 6 May 2005 21:04:14 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 379F143D8A for ; Fri, 6 May 2005 21:04:13 +0000 (GMT) (envelope-from wsalamon@computer.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j46L4D4F099879 for ; Fri, 6 May 2005 21:04:13 GMT (envelope-from wsalamon@computer.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j46L4DbV099876 for perforce@freebsd.org; Fri, 6 May 2005 21:04:13 GMT (envelope-from wsalamon@computer.org) Date: Fri, 6 May 2005 21:04:13 GMT Message-Id: <200505062104.j46L4DbV099876@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to wsalamon@computer.org using -f From: Wayne Salamon To: Perforce Change Reviews Subject: PERFORCE change 76633 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 May 2005 21:04:15 -0000 http://perforce.freebsd.org/chv.cgi?CH=76633 Change 76633 by wsalamon@rickenbacker on 2005/05/06 21:03:40 Fix the KPATH2_VNODE2_TOKENS macro to use the second vnode argument structure. Reported by Scott Long. Affected files ... .. //depot/projects/trustedbsd/audit3/sys/security/audit/kern_bsm_audit.c#8 edit Differences ... ==== //depot/projects/trustedbsd/audit3/sys/security/audit/kern_bsm_audit.c#8 (text+ko) ==== @@ -237,7 +237,7 @@ kau_write(rec, tok); \ } \ if (ar->ar_valid_arg & ARG_VNODE1) { \ - tok = kau_to_attr32(&ar->ar_arg_vnode1);\ + tok = au_to_attr32(&ar->ar_arg_vnode1);\ kau_write(rec, tok); \ } \ } while (0) @@ -251,7 +251,7 @@ UPATH1_TOKENS; \ } \ if (ar->ar_valid_arg & ARG_VNODE1) { \ - tok = kau_to_attr32(&ar->ar_arg_vnode1);\ + tok = au_to_attr32(&ar->ar_arg_vnode1);\ kau_write(rec, tok); \ } \ } while (0) @@ -263,7 +263,7 @@ kau_write(rec, tok); \ } \ if (ar->ar_valid_arg & ARG_VNODE2) { \ - tok = kau_to_attr32(&ar->ar_arg_vnode1);\ + tok = au_to_attr32(&ar->ar_arg_vnode2);\ kau_write(rec, tok); \ } \ } while (0) @@ -274,7 +274,7 @@ tok = au_to_path(ar->ar_arg_kpath1); \ kau_write(rec, tok); \ if (ar->ar_valid_arg & ARG_VNODE1) { \ - tok = kau_to_attr32(&ar->ar_arg_vnode1);\ + tok = au_to_attr32(&ar->ar_arg_vnode1);\ kau_write(rec, tok); \ } \ } else { \ From owner-p4-projects@FreeBSD.ORG Fri May 6 21:27:44 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1A27B16A4D9; Fri, 6 May 2005 21:27:44 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D189316A4D4 for ; Fri, 6 May 2005 21:27:43 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id AD55C43D73 for ; Fri, 6 May 2005 21:27:43 +0000 (GMT) (envelope-from wsalamon@computer.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j46LRhZY000883 for ; Fri, 6 May 2005 21:27:43 GMT (envelope-from wsalamon@computer.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j46LRhum000880 for perforce@freebsd.org; Fri, 6 May 2005 21:27:43 GMT (envelope-from wsalamon@computer.org) Date: Fri, 6 May 2005 21:27:43 GMT Message-Id: <200505062127.j46LRhum000880@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to wsalamon@computer.org using -f From: Wayne Salamon To: Perforce Change Reviews Subject: PERFORCE change 76636 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 May 2005 21:27:44 -0000 http://perforce.freebsd.org/chv.cgi?CH=76636 Change 76636 by wsalamon@rickenbacker on 2005/05/06 21:27:32 Undo a change we're not ready for yet, the renaming of the tokenizer functions. Specifically, kau_to_attr32(). Affected files ... .. //depot/projects/trustedbsd/audit3/sys/security/audit/kern_bsm_audit.c#9 edit Differences ... ==== //depot/projects/trustedbsd/audit3/sys/security/audit/kern_bsm_audit.c#9 (text+ko) ==== @@ -237,7 +237,7 @@ kau_write(rec, tok); \ } \ if (ar->ar_valid_arg & ARG_VNODE1) { \ - tok = au_to_attr32(&ar->ar_arg_vnode1);\ + tok = kau_to_attr32(&ar->ar_arg_vnode1);\ kau_write(rec, tok); \ } \ } while (0) @@ -251,7 +251,7 @@ UPATH1_TOKENS; \ } \ if (ar->ar_valid_arg & ARG_VNODE1) { \ - tok = au_to_attr32(&ar->ar_arg_vnode1);\ + tok = kau_to_attr32(&ar->ar_arg_vnode1);\ kau_write(rec, tok); \ } \ } while (0) @@ -263,7 +263,7 @@ kau_write(rec, tok); \ } \ if (ar->ar_valid_arg & ARG_VNODE2) { \ - tok = au_to_attr32(&ar->ar_arg_vnode2);\ + tok = kau_to_attr32(&ar->ar_arg_vnode2);\ kau_write(rec, tok); \ } \ } while (0) @@ -274,7 +274,7 @@ tok = au_to_path(ar->ar_arg_kpath1); \ kau_write(rec, tok); \ if (ar->ar_valid_arg & ARG_VNODE1) { \ - tok = au_to_attr32(&ar->ar_arg_vnode1);\ + tok = kau_to_attr32(&ar->ar_arg_vnode1);\ kau_write(rec, tok); \ } \ } else { \ From owner-p4-projects@FreeBSD.ORG Fri May 6 22:46:20 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D77C816A4D8; Fri, 6 May 2005 22:46:19 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A98D416A4D4 for ; Fri, 6 May 2005 22:46:19 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7435843DA6 for ; Fri, 6 May 2005 22:46:19 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j46MkJ56003611 for ; Fri, 6 May 2005 22:46:19 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j46MkJb2003608 for perforce@freebsd.org; Fri, 6 May 2005 22:46:19 GMT (envelope-from sam@freebsd.org) Date: Fri, 6 May 2005 22:46:19 GMT Message-Id: <200505062246.j46MkJb2003608@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76639 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 May 2005 22:46:20 -0000 http://perforce.freebsd.org/chv.cgi?CH=76639 Change 76639 by sam@sam_ebb on 2005/05/06 22:46:01 fixup default device names Affected files ... .. //depot/projects/vap/tools/tools/ath/80211debug.c#3 edit .. //depot/projects/vap/tools/tools/ath/athstats.c#4 edit Differences ... ==== //depot/projects/vap/tools/tools/ath/80211debug.c#3 (text+ko) ==== @@ -139,7 +139,7 @@ int main(int argc, char *argv[]) { - const char *ifname = "ath0"; + const char *ifname = "wlan0"; const char *cp, *tp; const char *sep; int c, op, i; ==== //depot/projects/vap/tools/tools/ath/athstats.c#4 (text+ko) ==== @@ -248,7 +248,7 @@ strncpy(ifr.ifr_name, argv[2], sizeof (ifr.ifr_name)); argc -= 2, argv += 2; } else - strncpy(ifr.ifr_name, "wlan0", sizeof (ifr.ifr_name)); + strncpy(ifr.ifr_name, "ath0", sizeof (ifr.ifr_name)); if (argc > 1) { u_long interval = strtoul(argv[1], NULL, 0); int line, omask; From owner-p4-projects@FreeBSD.ORG Fri May 6 22:53:29 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E502216A4D8; Fri, 6 May 2005 22:53:28 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A2E5D16A4D4 for ; Fri, 6 May 2005 22:53:28 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 90C6F43D6A for ; Fri, 6 May 2005 22:53:28 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j46MrSVw003828 for ; Fri, 6 May 2005 22:53:28 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j46MrSl1003825 for perforce@freebsd.org; Fri, 6 May 2005 22:53:28 GMT (envelope-from sam@freebsd.org) Date: Fri, 6 May 2005 22:53:28 GMT Message-Id: <200505062253.j46MrSl1003825@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76640 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 May 2005 22:53:29 -0000 http://perforce.freebsd.org/chv.cgi?CH=76640 Change 76640 by sam@sam_ebb on 2005/05/06 22:53:24 add to branch Affected files ... .. //depot/projects/vap/sbin/ifconfig/Makefile#1 branch .. //depot/projects/vap/sbin/ifconfig/af_atalk.c#1 branch .. //depot/projects/vap/sbin/ifconfig/af_inet.c#1 branch .. //depot/projects/vap/sbin/ifconfig/af_inet6.c#1 branch .. //depot/projects/vap/sbin/ifconfig/af_ipx.c#1 branch .. //depot/projects/vap/sbin/ifconfig/af_link.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifcarp.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifclone.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifconfig.8#1 branch .. //depot/projects/vap/sbin/ifconfig/ifconfig.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifconfig.h#1 branch .. //depot/projects/vap/sbin/ifconfig/ifieee80211.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifmac.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifmedia.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifpfsync.c#1 branch .. //depot/projects/vap/sbin/ifconfig/ifvlan.c#1 branch Differences ... From owner-p4-projects@FreeBSD.ORG Fri May 6 23:49:37 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3044016A4D8; Fri, 6 May 2005 23:49:37 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0AB7016A4D4 for ; Fri, 6 May 2005 23:49:37 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id CEB2D43D49 for ; Fri, 6 May 2005 23:49:36 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j46NnaHL005943 for ; Fri, 6 May 2005 23:49:36 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j46Nna27005940 for perforce@freebsd.org; Fri, 6 May 2005 23:49:36 GMT (envelope-from sam@freebsd.org) Date: Fri, 6 May 2005 23:49:36 GMT Message-Id: <200505062349.j46Nna27005940@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76642 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 May 2005 23:49:37 -0000 http://perforce.freebsd.org/chv.cgi?CH=76642 Change 76642 by sam@sam_ebb on 2005/05/06 23:48:53 o update for channel changes o cleanup err/errx confusion Affected files ... .. //depot/projects/vap/sbin/ifconfig/ifieee80211.c#2 edit Differences ... ==== //depot/projects/vap/sbin/ifconfig/ifieee80211.c#2 (text+ko) ==== @@ -803,7 +803,7 @@ ireq.i_data = buf; ireq.i_len = sizeof(buf); if (ioctl(s, SIOCG80211, &ireq) < 0) - errx(1, "unable to get scan results"); + err(1, "unable to get scan results"); len = ireq.i_len; if (len < sizeof(struct ieee80211req_scan_result)) return; @@ -898,7 +898,7 @@ ireq.i_data = buf; ireq.i_len = sizeof(buf); if (ioctl(s, SIOCG80211, &ireq) < 0) - errx(1, "unable to get station information"); + err(1, "unable to get station information"); len = ireq.i_len; if (len < sizeof(struct ieee80211req_sta_info)) return; @@ -952,13 +952,11 @@ strlcat(buf, " FHSS", sizeof(buf)); if (IEEE80211_IS_CHAN_A(c)) strlcat(buf, " 11a", sizeof(buf)); - /* XXX 11g schizophrenia */ - if (IEEE80211_IS_CHAN_G(c) || - IEEE80211_IS_CHAN_PUREG(c)) + if (IEEE80211_IS_CHAN_ANYG(c)) strlcat(buf, " 11g", sizeof(buf)); else if (IEEE80211_IS_CHAN_B(c)) strlcat(buf, " 11b", sizeof(buf)); - if (IEEE80211_IS_CHAN_T(c)) + if (IEEE80211_IS_CHAN_TURBO(c)) strlcat(buf, " Turbo", sizeof(buf)); printf("Channel %3u : %u%c Mhz%-14.14s", ieee80211_mhz2ieee(c->ic_freq), c->ic_freq, @@ -981,7 +979,7 @@ ireq.i_data = &chans; ireq.i_len = sizeof(chans); if (ioctl(s, SIOCG80211, &ireq) < 0) - errx(1, "unable to get channel information"); + err(1, "unable to get channel information"); if (!allchans) { struct ieee80211req_chanlist active; @@ -989,7 +987,7 @@ ireq.i_data = &active; ireq.i_len = sizeof(active); if (ioctl(s, SIOCG80211, &ireq) < 0) - errx(1, "unable to get active channel list"); + err(1, "unable to get active channel list"); memset(&achans, 0, sizeof(achans)); for (i = 0; i < chans.ic_nchans; i++) { c = &chans.ic_chans[i]; @@ -1032,7 +1030,7 @@ (void) strncpy(ireq.i_name, name, sizeof(ireq.i_name)); ireq.i_type = IEEE80211_IOC_DRIVER_CAPS; if (ioctl(s, SIOCG80211, &ireq) < 0) - errx(1, "unable to get driver capabilities"); + err(1, "unable to get driver capabilities"); caps = (((u_int16_t) ireq.i_val) << 16) | ((u_int16_t) ireq.i_len); printb(name, caps, IEEE80211_C_BITS); putchar('\n'); @@ -1197,7 +1195,7 @@ ireq.i_data = &chans; ireq.i_len = sizeof(chans); if (ioctl(s, SIOCG80211, &ireq) < 0) - errx(1, "unable to get channel information"); + err(1, "unable to get channel information"); freq = ieee80211_ieee2mhz(chan); for (i = 0; i < chans.ic_nchans; i++) { c = &chans.ic_chans[i]; From owner-p4-projects@FreeBSD.ORG Sat May 7 03:17:49 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0328D16A4D9; Sat, 7 May 2005 03:17:49 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AB62C16A4D6 for ; Sat, 7 May 2005 03:17:48 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7D99943D96 for ; Sat, 7 May 2005 03:17:48 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j473Hm3J020841 for ; Sat, 7 May 2005 03:17:48 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j473Hlmb020838 for perforce@freebsd.org; Sat, 7 May 2005 03:17:47 GMT (envelope-from sam@freebsd.org) Date: Sat, 7 May 2005 03:17:47 GMT Message-Id: <200505070317.j473Hlmb020838@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76646 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 May 2005 03:17:49 -0000 http://perforce.freebsd.org/chv.cgi?CH=76646 Change 76646 by sam@sam_ebb on 2005/05/07 03:17:28 checkpoint backport Affected files ... .. //depot/projects/vap/sys/conf/files#3 edit .. //depot/projects/vap/sys/dev/ath/ath_rate/onoe/onoe.c#5 edit .. //depot/projects/vap/sys/dev/ath/ath_rate/sample/sample.c#2 edit .. //depot/projects/vap/sys/dev/ath/if_ath.c#7 edit .. //depot/projects/vap/sys/dev/ath/if_athvar.h#5 edit .. //depot/projects/vap/sys/dev/wi/if_wi.c#5 edit .. //depot/projects/vap/sys/modules/Makefile#3 edit .. //depot/projects/vap/sys/modules/wlan/Makefile#2 edit .. //depot/projects/vap/sys/net80211/_ieee80211.h#4 edit .. //depot/projects/vap/sys/net80211/ieee80211.c#7 edit .. //depot/projects/vap/sys/net80211/ieee80211.h#2 edit .. //depot/projects/vap/sys/net80211/ieee80211_crypto.c#4 edit .. //depot/projects/vap/sys/net80211/ieee80211_crypto.h#5 edit .. //depot/projects/vap/sys/net80211/ieee80211_crypto_ccmp.c#4 edit .. //depot/projects/vap/sys/net80211/ieee80211_crypto_none.c#4 edit .. //depot/projects/vap/sys/net80211/ieee80211_crypto_tkip.c#4 edit .. //depot/projects/vap/sys/net80211/ieee80211_crypto_wep.c#4 edit .. //depot/projects/vap/sys/net80211/ieee80211_freebsd.c#7 edit .. //depot/projects/vap/sys/net80211/ieee80211_freebsd.h#5 edit .. //depot/projects/vap/sys/net80211/ieee80211_input.c#8 edit .. //depot/projects/vap/sys/net80211/ieee80211_ioctl.c#6 edit .. //depot/projects/vap/sys/net80211/ieee80211_ioctl.h#5 edit .. //depot/projects/vap/sys/net80211/ieee80211_node.c#5 edit .. //depot/projects/vap/sys/net80211/ieee80211_node.h#5 edit .. //depot/projects/vap/sys/net80211/ieee80211_output.c#7 edit .. //depot/projects/vap/sys/net80211/ieee80211_proto.c#6 edit .. //depot/projects/vap/sys/net80211/ieee80211_proto.h#5 edit .. //depot/projects/vap/sys/net80211/ieee80211_regdomain.c#1 add .. //depot/projects/vap/sys/net80211/ieee80211_regdomain.h#1 add .. //depot/projects/vap/sys/net80211/ieee80211_scan.c#1 add .. //depot/projects/vap/sys/net80211/ieee80211_scan.h#1 add .. //depot/projects/vap/sys/net80211/ieee80211_scan_ap.c#1 add .. //depot/projects/vap/sys/net80211/ieee80211_scan_sta.c#1 add .. //depot/projects/vap/sys/net80211/ieee80211_var.h#8 edit Differences ... ==== //depot/projects/vap/sys/conf/files#3 (text+ko) ==== @@ -1385,6 +1385,10 @@ net80211/ieee80211_node.c optional wlan net80211/ieee80211_output.c optional wlan net80211/ieee80211_proto.c optional wlan +net80211/ieee80211_regdomain.c optional wlan +net80211/ieee80211_scan.c optional wlan +net80211/ieee80211_scan_ap.c optional wlan_scan_ap +net80211/ieee80211_scan_sta.c optional wlan_scan_sta net80211/ieee80211_xauth.c optional wlan_xauth netatalk/aarp.c optional netatalk netatalk/at_control.c optional netatalk ==== //depot/projects/vap/sys/dev/ath/ath_rate/onoe/onoe.c#5 (text+ko) ==== @@ -198,9 +198,6 @@ (ni->ni_rates.rs_rates[rate] & IEEE80211_RATE_VAL) / 2 : 0); ni->ni_txrate = rate; - /* XXX management/control frames always go at the lowest speed */ - an->an_tx_mgtrate = rt->info[0].rateCode; - an->an_tx_mgtratesp = an->an_tx_mgtrate | rt->info[0].shortPreamble; /* * Before associating a node has no rate set setup * so we can't calculate any transmit codes to use. @@ -247,7 +244,7 @@ /* NB: only do this if we didn't already do it above */ on->on_tx_rate3 = rt->info[0].rateCode; on->on_tx_rate3sp = - an->an_tx_mgtrate | rt->info[0].shortPreamble; + on->on_tx_rate3 | rt->info[0].shortPreamble; } else { on->on_tx_rate3 = on->on_tx_rate3sp = 0; } ==== //depot/projects/vap/sys/dev/ath/ath_rate/sample/sample.c#2 (text+ko) ==== @@ -139,28 +139,11 @@ return -1; } -/* - * Setup rate codes for management/control frames. We force - * all such frames to the lowest rate. - */ -static void -ath_rate_setmgtrates(struct ath_softc *sc, struct ath_node *an) -{ - const HAL_RATE_TABLE *rt = sc->sc_currates; - - /* setup rates for management frames */ - /* XXX management/control frames always go at lowest speed */ - an->an_tx_mgtrate = rt->info[0].rateCode; - an->an_tx_mgtratesp = an->an_tx_mgtrate - | rt->info[0].shortPreamble; -} - void ath_rate_node_init(struct ath_softc *sc, struct ath_node *an) { DPRINTF(sc, "%s:\n", __func__); /* NB: assumed to be zero'd by caller */ - ath_rate_setmgtrates(sc, an); } void @@ -696,7 +679,7 @@ * rate set is checked when the station associates. */ const struct ieee80211_rateset *rs = - &ic->ic_sup_rates[ic->ic_curmode]; + &ic->ic_sup_rates[ieee80211_chan2mode(ic->ic_bsschan)]; int r = rs->rs_rates[vap->iv_fixed_rate] & IEEE80211_RATE_VAL; /* NB: the rate set is assumed sorted */ srate = ni->ni_rates.rs_nrates - 1; ==== //depot/projects/vap/sys/dev/ath/if_ath.c#7 (text+ko) ==== @@ -93,6 +93,21 @@ ((((u_int8_t *)(p))[0] ) | (((u_int8_t *)(p))[1] << 8) | \ (((u_int8_t *)(p))[2] << 16) | (((u_int8_t *)(p))[3] << 24))) +/* + * MAC addresses for multiple BSS on the same radio. + * The very first VAP will just use the MAC address from the EEPROM. + * For the next 3 VAPs, we set the U/L bit (bit 1) in MAC address, + * and use the next two bits as the index of the VAP. + */ +#define ATH_SET_VAP_BSSID_MASK(bssid_mask) \ + ((bssid_mask)[0] &= ~(((ATH_BCBUF-1)<<2)|0x02)) +#define ATH_GET_VAP_ID(bssid) \ + ((bssid)[0] >> 2) +#define ATH_SET_VAP_BSSID(bssid, id) do { \ + if (id) \ + (bssid)[0] |= (((id)<<2)|0x02); \ +} while(0) + enum { ATH_LED_TX, ATH_LED_RX, @@ -100,35 +115,39 @@ }; static struct ieee80211vap *ath_vap_create(struct ieee80211com *, - const char name[IFNAMSIZ], int unit, int opmode); + const char name[IFNAMSIZ], int unit, + int opmode, int flags); static void ath_vap_delete(struct ieee80211vap *); static void ath_init(void *); static void ath_stop_locked(struct ifnet *); static void ath_stop(struct ifnet *); static void ath_start(struct ifnet *); static int ath_reset(struct ifnet *); -static int ath_reset_vap(struct ifnet *); static void ath_watchdog(struct ifnet *); static int ath_ioctl(struct ifnet *, u_long, caddr_t); static void ath_fatal_proc(void *, int); static void ath_rxorn_proc(void *, int); static void ath_bmiss_proc(void *, int); -static int ath_key_alloc(struct ieee80211com *, +static int ath_key_alloc(struct ieee80211vap *, const struct ieee80211_key *); -static int ath_key_delete(struct ieee80211com *, +static int ath_key_delete(struct ieee80211vap *, const struct ieee80211_key *); -static int ath_key_set(struct ieee80211com *, const struct ieee80211_key *, +static int ath_key_set(struct ieee80211vap *, const struct ieee80211_key *, const u_int8_t mac[IEEE80211_ADDR_LEN]); -static void ath_key_update_begin(struct ieee80211com *); -static void ath_key_update_end(struct ieee80211com *); +static void ath_key_update_begin(struct ieee80211vap *); +static void ath_key_update_end(struct ieee80211vap *); static void ath_mode_init(struct ath_softc *); static void ath_setslottime(struct ath_softc *); static void ath_updateslot(struct ifnet *); +static void ath_beacon_dturbo_config(struct ath_softc *, u_int32_t ); +static void ath_beacon_dturbo_update(struct ath_softc *); +static void ath_turbo_switch(void *); static int ath_beaconq_setup(struct ath_hal *); static int ath_beacon_alloc(struct ath_softc *, struct ieee80211_node *); static void ath_beacon_setup(struct ath_softc *, struct ath_buf *); static void ath_beacon_proc(void *, int); static void ath_bstuck_proc(void *, int); +static void ath_beacon_return(struct ath_softc *, struct ath_buf *); static void ath_beacon_free(struct ath_softc *); static void ath_beacon_config(struct ath_softc *); static void ath_descdma_cleanup(struct ath_softc *sc, @@ -151,6 +170,7 @@ static int ath_tx_start(struct ath_softc *, struct ieee80211_node *, struct ath_buf *, struct mbuf *); static void ath_tx_proc_q0(void *, int); +static void ath_tx_draintxq(struct ath_softc *, struct ath_txq *); static void ath_tx_proc_q0123(void *, int); static void ath_tx_proc(void *, int); static int ath_chan_set(struct ath_softc *, struct ieee80211_channel *); @@ -158,9 +178,12 @@ static void ath_stoprecv(struct ath_softc *); static int ath_startrecv(struct ath_softc *); static void ath_chan_change(struct ath_softc *, struct ieee80211_channel *); -static void ath_next_scan(void *); static void ath_calibrate(void *); +static void ath_scan_start(struct ieee80211com *); +static void ath_scan_end(struct ieee80211com *); +static void ath_set_channel(struct ieee80211com *); static int ath_newstate(struct ieee80211vap *, enum ieee80211_state, int); +static void ath_setup_stationkey(struct ieee80211_node *); static void ath_newassoc(struct ieee80211_node *, int); static int ath_getchannels(struct ath_softc *, u_int cc, HAL_BOOL outdoor, HAL_BOOL xchanmode); @@ -257,6 +280,7 @@ struct ath_hal *ah; HAL_STATUS status; int error = 0, i; + u_int cc; DPRINTF(sc, ATH_DEBUG_ANY, "%s: devid 0x%x\n", __func__, devid); @@ -302,11 +326,11 @@ * Get the hardware key cache size. */ sc->sc_keymax = ath_hal_keycachesize(ah); - if (sc->sc_keymax > sizeof(sc->sc_keymap) * NBBY) { + if (sc->sc_keymax > ATH_KEYMAX) { if_printf(ifp, "Warning, using only %zu of %u key cache slots\n", - sizeof(sc->sc_keymap) * NBBY, sc->sc_keymax); - sc->sc_keymax = sizeof(sc->sc_keymap) * NBBY; + ATH_KEYMAX, sc->sc_keymax); + sc->sc_keymax = ATH_KEYMAX; } /* * Reset the key cache since some parts do not @@ -362,8 +386,8 @@ if_printf(ifp, "failed to allocate descriptors: %d\n", error); goto bad; } - callout_init(&sc->sc_scan_ch, debug_mpsafenet ? CALLOUT_MPSAFE : 0); callout_init(&sc->sc_cal_ch, CALLOUT_MPSAFE); + callout_init(&sc->sc_dt_cb, CALLOUT_MPSAFE); ATH_TXBUF_LOCK_INIT(sc); @@ -476,12 +500,13 @@ IFQ_SET_READY(&ifp->if_snd); ic->ic_ifp = ifp; - ic->ic_reset = ath_reset_vap; + ic->ic_reset = ath_reset; ic->ic_newassoc = ath_newassoc; ic->ic_updateslot = ath_updateslot; ic->ic_wme.wme_update = ath_wme_update; /* XXX not right but it's not used anywhere important */ ic->ic_phytype = IEEE80211_T_OFDM; + ic->ic_opmode = IEEE80211_M_STA; ic->ic_caps = IEEE80211_C_IBSS /* ibss, nee adhoc, mode */ | IEEE80211_C_HOSTAP /* hostap mode */ @@ -513,6 +538,7 @@ if (ath_hal_tkipsplit(ah)) sc->sc_splitmic = 1; } + sc->sc_mcastkey = ath_hal_hasmcastkeysearch(ah); /* * TPC support can be done either with a global cap or * per-packet support. The latter is not available on @@ -536,10 +562,11 @@ ic->ic_caps |= IEEE80211_C_BURST; if (ath_hal_hasfastframes(ah)) ic->ic_caps |= IEEE80211_C_FF; -#ifdef notyet - if (ath_hal_getwirelessmodes(ah) & (HAL_MODE_108G|HAL_MODE_TURBO)) + ath_hal_getcountrycode(ah, &cc); + if (ath_hal_getwirelessmodes(ah, cc) & (HAL_MODE_108G|HAL_MODE_108A)) ic->ic_caps |= IEEE80211_C_TURBOP; -#endif + sc->sc_hasbmask = ath_hal_hasbssidmask(ah); + sc->sc_hastsfadd = ath_hal_hastsfadjust(ah); /* * Indicate we need the 802.11 header padded to a @@ -564,6 +591,11 @@ /* get mac address from hardware */ ath_hal_getmac(ah, ic->ic_myaddr); + if (sc->sc_hasbmask) { + ath_hal_getbssidmask(ah, sc->sc_bssidmask); + ATH_SET_VAP_BSSID_MASK(sc->sc_bssidmask); + ath_hal_setbssidmask(ah, sc->sc_bssidmask); + } /* XXX required for arp, yech */ IEEE80211_ADDR_COPY(IFP2AC(ifp)->ac_enaddr, ic->ic_myaddr); @@ -576,15 +608,14 @@ ic->ic_node_getrssi = ath_node_getrssi; sc->sc_recv_mgmt = ic->ic_recv_mgmt; ic->ic_recv_mgmt = ath_recv_mgmt; - ic->ic_key_alloc = ath_key_alloc; - ic->ic_key_delete = ath_key_delete; - ic->ic_key_set = ath_key_set; - ic->ic_key_update_begin = ath_key_update_begin; - ic->ic_key_update_end = ath_key_update_end; ic->ic_vap_create = ath_vap_create; ic->ic_vap_delete = ath_vap_delete; + ic->ic_scan_start = ath_scan_start; + ic->ic_scan_end = ath_scan_end; + ic->ic_set_channel = ath_set_channel; + ath_bpfattach(sc); if (bootverbose) @@ -635,41 +666,45 @@ static struct ieee80211vap * ath_vap_create(struct ieee80211com *ic, - const char name[IFNAMSIZ], int unit, int opmode) + const char name[IFNAMSIZ], int unit, int opmode, int flags) { struct ath_softc *sc = ic->ic_ifp->if_softc; struct ieee80211vap *vap; + struct ath_vap *avp; + int newopmode; /* XXX ic unlocked and race against add */ + newopmode = opmode; switch (opmode) { case IEEE80211_M_STA: - /* XXX sta+ap for repeater application */ - if (!TAILQ_EMPTY(&ic->ic_vaps)) /* only one for now */ + /* if using h/w station beacons, must be first vap created */ + if ((flags & IEEE80211_CLONE_NOBEACONS) == 0 && sc->sc_nvaps) return NULL; - ic->ic_opmode = opmode; + if (flags & IEEE80211_CLONE_NOBEACONS) { + /* operate chip in AP mode */ + newopmode = IEEE80211_M_HOSTAP; + } break; case IEEE80211_M_IBSS: case IEEE80211_M_AHDEMO: if ((ic->ic_caps & (IEEE80211_C_IBSS << opmode)) == 0) return NULL; - if (!TAILQ_EMPTY(&ic->ic_vaps)) /* only one for now */ + if (sc->sc_nvaps != 0) /* only one for now */ return NULL; - ic->ic_opmode = opmode; break; case IEEE80211_M_HOSTAP: case IEEE80211_M_WDS: /* permit multiple ap's and/or wds links */ /* XXX device capability */ - /* XXX max count */ - /* XXX sta+ap for repeater/bridge application */ - if (!TAILQ_EMPTY(&ic->ic_vaps) && - ic->ic_opmode != IEEE80211_M_HOSTAP) + if (sc->sc_nvaps != 0 && ic->ic_opmode != IEEE80211_M_HOSTAP) return NULL; + if (opmode == IEEE80211_M_HOSTAP && STAILQ_EMPTY(&sc->sc_bbuf)) + return NULL; /* * XXX Not sure if this is correct when operating only * with WDS links. */ - ic->ic_opmode = IEEE80211_M_HOSTAP; + newopmode = IEEE80211_M_HOSTAP; break; case IEEE80211_M_MONITOR: /* XXX always allow, is that ok? */ @@ -679,31 +714,197 @@ default: return NULL; } - MALLOC(vap, struct ieee80211vap *, sizeof(struct ieee80211vap), + MALLOC(avp, struct ath_vap *, sizeof(struct ath_vap), M_80211_VAP, M_NOWAIT | M_ZERO); - if (vap == NULL) { + if (avp == NULL) { /* XXX msg */ return NULL; } + vap = &avp->av_vap; ieee80211_vap_setup(ic, vap, name, unit, opmode); /* override with driver methods */ - sc->sc_newstate = vap->iv_newstate; /* XXX per-vap */ + avp->av_newstate = vap->iv_newstate; /* XXX per-vap */ vap->iv_newstate = ath_newstate; - /* XXX multi-bssid */ + vap->iv_key_alloc = ath_key_alloc; + vap->iv_key_delete = ath_key_delete; + vap->iv_key_set = ath_key_set; + vap->iv_key_update_begin = ath_key_update_begin; + vap->iv_key_update_end = ath_key_update_end; + + if ((flags & IEEE80211_CLONE_BSSID) && + sc->sc_nvaps != 0 && opmode != IEEE80211_M_WDS && sc->sc_hasbmask) { + struct ieee80211vap *v; + int id_mask, id; - /* XXX allocate+setup beacon state for hostap/ibss */ + /* + * Hardware supports the bssid mask and a unique + * bssid was requested. Assign a new mac address + * and expand our bssid mask to cover the active + * virtual ap's with distinct addresses. + */ + KASSERT(sc->sc_nvaps <= ATH_BCBUF, + ("too many virtual ap's: %d", sc->sc_nvaps)); + /* do a full search to mark all the allocated vaps */ + id_mask = 0; + TAILQ_FOREACH(v, &ic->ic_vaps, iv_next) + id_mask |= (1 << ATH_GET_VAP_ID(v->iv_myaddr)); + for (id = 0; id < ATH_BCBUF; id++) { + /* get the first available slot */ + if ((id_mask & (1 << id)) == 0) { + ATH_SET_VAP_BSSID(vap->iv_myaddr, id); + break; + } + } + } + avp->av_bslot = -1; + switch (opmode) { + case IEEE80211_M_HOSTAP: + case IEEE80211_M_IBSS: + /* + * Setup queue for buffering multicast traffic. + */ + STAILQ_INIT(&avp->av_mcastq.axq_q); + ATH_TXQ_LOCK_INIT(sc, &avp->av_mcastq); + /* + * Allocate beacon state for hostap/ibss. We know + * a buffer is available because of the check above. + */ + avp->av_bcbuf = STAILQ_FIRST(&sc->sc_bbuf); + STAILQ_REMOVE_HEAD(&sc->sc_bbuf, bf_list); + if (opmode == IEEE80211_M_HOSTAP || !sc->sc_hasveol) { + int slot; + /* + * Assign the vap to a beacon xmit slot. As + * above, this cannot fail to find one. + */ + avp->av_bslot = 0; + for (slot = 0; slot < ATH_BCBUF; slot++) + if (sc->sc_bslot[slot] == NULL) { + /* + * XXX hack, space out slots to better + * deal with misses + */ + if (slot+1 < ATH_BCBUF && + sc->sc_bslot[slot+1] == NULL) { + avp->av_bslot = slot+1; + break; + } + avp->av_bslot = slot; + /* NB: keep looking for a double slot */ + } + KASSERT(sc->sc_bslot[avp->av_bslot] == NULL, + ("beacon slot %u not empty?", avp->av_bslot)); + sc->sc_bslot[avp->av_bslot] = vap; + } + if (sc->sc_hastsfadd) + ath_hal_settsfadjust(sc->sc_ah, 1); + break; + case IEEE80211_M_STA: + /* + * If we're to operate in station mode and TSF + * adjust support is available, turn it off. + */ + if (newopmode == IEEE80211_M_STA && sc->sc_hastsfadd) + ath_hal_settsfadjust(sc->sc_ah, 0); + sc->sc_nstavaps++; + if (flags & IEEE80211_CLONE_NOBEACONS) { + avp->av_nobeacons = 1; + sc->sc_rxbeacons++; + } + break; + case IEEE80211_M_MONITOR: + case IEEE80211_M_WDS: + /* XXX does WDS need beacons for state changes? */ + avp->av_nobeacons = 1; /* no need for beacon setup */ + break; + } + /* complete setup */ (void) ieee80211_vap_attach(vap, ieee80211_media_change, ieee80211_media_status); + ic->ic_opmode = newopmode; + sc->sc_nvaps++; + return vap; } void ath_vap_delete(struct ieee80211vap *vap) { + struct ifnet *parent = vap->iv_ic->ic_ifp; + struct ath_softc *sc = parent->if_softc; + struct ath_hal *ah = sc->sc_ah; + struct ath_vap *avp = ATH_VAP(vap); + int i; + + KASSERT(vap->iv_state == IEEE80211_S_INIT, ("vap not stopped")); + + if (parent->if_flags & IFF_RUNNING) { + /* + * Quiesce the hardware while we remove the vap. In + * particular we need to reclaim all references to the + * vap state by any frames pending on the tx queues. + * + * XXX can we do this w/o affecting other vap's? + */ + ath_hal_intrset(ah, 0); /* disable interrupts */ + ath_draintxq(sc); /* stop xmit side */ + ath_stoprecv(sc); /* stop recv side */ + } + + if (vap->iv_opmode == IEEE80211_M_HOSTAP || + vap->iv_opmode == IEEE80211_M_IBSS) { + /* + * Reclaim any pending mcast bufs on the vap. + */ + ath_tx_draintxq(sc, &avp->av_mcastq); + ATH_TXQ_LOCK_DESTROY(&avp->av_mcastq); + + /* + * Reclaim beacon state. Note this must be done before + * vap instance is reclaimed as we may have a reference + * to it in the buffer for the beacon frame. + */ + if (avp->av_bcbuf != NULL) { + if (avp->av_bslot != -1) + sc->sc_bslot[avp->av_bslot] = NULL; + ath_beacon_return(sc, avp->av_bcbuf); + avp->av_bcbuf = NULL; + } + } ieee80211_vap_detach(vap); - FREE(vap, M_80211_VAP); + if (vap->iv_opmode == IEEE80211_M_STA) { + sc->sc_nstavaps--; + if (avp->av_nobeacons) + sc->sc_rxbeacons--; + } + sc->sc_nvaps--; + if (sc->sc_bmaster == vap) { + sc->sc_bmaster = NULL; + /* XXX pick a new master for restarting beacons */ + /* XXX not right, need to restart w/ current/adjusted TSF? */ + for (i = 0; i < ATH_BCBUF; i++) { + struct ieee80211vap *v = sc->sc_bslot[i]; + if (v != NULL && !ATH_VAP(v)->av_nobeacons) { + sc->sc_bmaster = v; + break; + } + } + } + FREE(avp, M_80211_VAP); + + if (parent->if_flags & IFF_RUNNING) { + /* + * Restart rx+tx machines if device is still running. + */ + if (ath_startrecv(sc) != 0) /* restart recv */ + if_printf(parent, "%s: unable to start recv logic\n", + __func__); + if (sc->sc_bmaster != NULL) + ath_beacon_config(sc); /* restart beacons */ + ath_hal_intrset(ah, sc->sc_imask); + } } void @@ -799,7 +1000,13 @@ * Handle beacon transmission directly; deferring * this is too slow to meet timing constraints * under load. + * + * If we are using dynamic turbo, update the + * capability info and arrange for a mode change + * if needed. */ + if (sc->sc_dturbo) + ath_beacon_dturbo_update(sc); ath_beacon_proc(sc, 0); } if (status & HAL_INT_RXEOL) { @@ -818,8 +1025,26 @@ } if (status & HAL_INT_RX) taskqueue_enqueue(taskqueue_swi, &sc->sc_rxtask); - if (status & HAL_INT_TX) + if (status & HAL_INT_TX) { + /* + * Check the beacon queue when a dynamic turbo switch + * is pending so we can initiate the change once the + * beacon announcing the switch has gone out. + * XXX must wait for all vap's beacons + */ + if (sc->sc_dt_switch && + ath_hal_numtxpending(ah, sc->sc_bhalq) == 0) { + sc->sc_dt_switch = 0; + /* + * Hack: defer switch for 10ms to permit slow + * clients time to track us. This especially + * noticeable with Windows clients. + */ + callout_reset(&sc->sc_dt_cb, + (hz*10)/1000, ath_turbo_switch, ifp); + } taskqueue_enqueue(taskqueue_swi, &sc->sc_txtask); + } if (status & HAL_INT_BMISS) { sc->sc_stats.ast_bmiss++; taskqueue_enqueue(taskqueue_swi, &sc->sc_bmisstask); @@ -871,7 +1096,7 @@ } static u_int -ath_chan2flags(struct ieee80211com *ic, struct ieee80211_channel *chan) +ath_chan2flags(struct ieee80211_channel *chan) { #define N(a) (sizeof(a) / sizeof(a[0])) static const u_int modeflags[] = { @@ -880,10 +1105,10 @@ CHANNEL_B, /* IEEE80211_MODE_11B */ CHANNEL_PUREG, /* IEEE80211_MODE_11G */ 0, /* IEEE80211_MODE_FH */ - CHANNEL_T, /* IEEE80211_MODE_TURBO_A */ + CHANNEL_108A, /* IEEE80211_MODE_TURBO_A */ CHANNEL_108G /* IEEE80211_MODE_TURBO_G */ }; - enum ieee80211_phymode mode = ieee80211_chan2mode(ic, chan); + enum ieee80211_phymode mode = ieee80211_chan2mode(chan); KASSERT(mode < N(modeflags), ("unexpected phy mode %u", mode)); KASSERT(modeflags[mode] != 0, ("mode %u undefined", mode)); @@ -917,8 +1142,8 @@ * be followed by initialization of the appropriate bits * and then setup of the interrupt mask. */ - sc->sc_curchan.channel = ic->ic_ibss_chan->ic_freq; - sc->sc_curchan.channelFlags = ath_chan2flags(ic, ic->ic_ibss_chan); + sc->sc_curchan.channel = ic->ic_curchan->ic_freq; + sc->sc_curchan.channelFlags = ath_chan2flags(ic->ic_curchan); if (!ath_hal_reset(ah, ic->ic_opmode, &sc->sc_curchan, AH_FALSE, &status)) { if_printf(ifp, "unable to reset hardware; hal status %u\n", status); @@ -965,7 +1190,7 @@ * to kick the 802.11 state machine as it's likely to * immediately call back to us to send mgmt frames. */ - ath_chan_change(sc, ic->ic_ibss_chan); + ath_chan_change(sc, ic->ic_curchan); ieee80211_start_running(ic); /* NB: marks IFF_RUNNING */ done: ATH_UNLOCK(sc); @@ -1061,9 +1286,9 @@ * Convert to a HAL channel description with the flags * constrained to reflect the current operating mode. */ - c = ic->ic_ibss_chan; + c = ic->ic_curchan; sc->sc_curchan.channel = c->ic_freq; - sc->sc_curchan.channelFlags = ath_chan2flags(ic, c); + sc->sc_curchan.channelFlags = ath_chan2flags(c); ath_hal_intrset(ah, 0); /* disable interrupts */ ath_draintxq(sc); /* stop xmit side */ @@ -1081,7 +1306,7 @@ * might change as a result. */ ath_chan_change(sc, c); - if (sc->sc_beacons) + if (sc->sc_bmaster != NULL) ath_beacon_config(sc); /* restart beacons */ ath_hal_intrset(ah, sc->sc_imask); @@ -1089,14 +1314,6 @@ return 0; } -static int -ath_reset_vap(struct ifnet *ifp) -{ - struct ieee80211vap *vap = ifp->if_softc; - - return ath_reset(vap->iv_ic->ic_ifp); -} - static int ath_ff_always(struct ath_txq *txq, struct ath_buf *bf) { @@ -1486,6 +1703,7 @@ sc->sc_stats.ast_tx_encap++; goto bad; } + /* XXX deal with tx frags */ } else { /* * Hack! The referenced node pointer is in the @@ -1621,7 +1839,8 @@ */ static int ath_keyset(struct ath_softc *sc, const struct ieee80211_key *k, - const u_int8_t mac[IEEE80211_ADDR_LEN]) + const u_int8_t mac0[IEEE80211_ADDR_LEN], + struct ieee80211_node *bss) { #define N(a) (sizeof(a)/sizeof(a[0])) static const u_int8_t ciphermap[] = { @@ -1635,6 +1854,8 @@ }; struct ath_hal *ah = sc->sc_ah; const struct ieee80211_cipher *cip = k->wk_cipher; + u_int8_t gmac[IEEE80211_ADDR_LEN]; + const u_int8_t *mac; HAL_KEYVAL hk; memset(&hk, 0, sizeof(hk)); @@ -1652,6 +1873,18 @@ } else hk.kv_type = HAL_CIPHER_CLR; + if ((k->wk_flags & IEEE80211_KEY_GROUP) && sc->sc_mcastkey) { + /* + * Group keys on hardware that supports multicast frame + * key search use a mac that is the sender's address with + * the high bit set instead of the app-specified address. + */ + IEEE80211_ADDR_COPY(gmac, bss->ni_macaddr); + gmac[0] |= 0x80; + mac = gmac; + } else + mac = mac0; + if (hk.kv_type == HAL_CIPHER_TKIP && (k->wk_flags & IEEE80211_KEY_SWMIC) == 0 && sc->sc_splitmic) { @@ -1787,9 +2020,10 @@ * 64 entries. */ static int -ath_key_alloc(struct ieee80211com *ic, const struct ieee80211_key *k) +ath_key_alloc(struct ieee80211vap *vap, const struct ieee80211_key *k) { - struct ath_softc *sc = ic->ic_ifp->if_softc; + struct ifnet *ifp = vap->iv_ic->ic_ifp; + struct ath_softc *sc = ifp->if_softc; /* * Group key allocation must be handled specially for @@ -1842,22 +2076,38 @@ * Delete an entry in the key cache allocated by ath_key_alloc. */ static int -ath_key_delete(struct ieee80211com *ic, const struct ieee80211_key *k) +ath_key_delete(struct ieee80211vap *vap, const struct ieee80211_key *k) { - struct ath_softc *sc = ic->ic_ifp->if_softc; + struct ifnet *ifp = vap->iv_ic->ic_ifp; + struct ath_softc *sc = ifp->if_softc; struct ath_hal *ah = sc->sc_ah; const struct ieee80211_cipher *cip = k->wk_cipher; u_int keyix = k->wk_keyix; + struct ieee80211_node *ni; DPRINTF(sc, ATH_DEBUG_KEYCACHE, "%s: delete key %u\n", __func__, keyix); ath_hal_keyreset(ah, keyix); /* + * Check the key->node map and flush any ref. + */ + ni = sc->sc_keyixmap[keyix]; + if (ni != NULL) { + ieee80211_free_node(ni); + sc->sc_keyixmap[keyix] = NULL; + } + /* * Handle split tx/rx keying required for TKIP with h/w MIC. */ if (cip->ic_cipher == IEEE80211_CIPHER_TKIP && - (k->wk_flags & IEEE80211_KEY_SWMIC) == 0 && sc->sc_splitmic) + (k->wk_flags & IEEE80211_KEY_SWMIC) == 0 && sc->sc_splitmic) { ath_hal_keyreset(ah, keyix+32); /* RX key */ + ni = sc->sc_keyixmap[keyix+32]; + if (ni != NULL) { /* as above... */ + ieee80211_free_node(ni); + sc->sc_keyixmap[keyix+32] = NULL; + } + } if (keyix >= IEEE80211_WEP_NKID) { /* * Don't touch keymap entries for global keys so @@ -1880,12 +2130,13 @@ * slot(s) must already have been allocated by ath_key_alloc. */ static int -ath_key_set(struct ieee80211com *ic, const struct ieee80211_key *k, +ath_key_set(struct ieee80211vap *vap, const struct ieee80211_key *k, const u_int8_t mac[IEEE80211_ADDR_LEN]) { - struct ath_softc *sc = ic->ic_ifp->if_softc; + struct ifnet *ifp = vap->iv_ic->ic_ifp; + struct ath_softc *sc = ifp->if_softc; - return ath_keyset(sc, k, mac); + return ath_keyset(sc, k, mac, vap->iv_bss); } /* @@ -1895,9 +2146,9 @@ * uses that originate in the driver. */ static void -ath_key_update_begin(struct ieee80211com *ic) +ath_key_update_begin(struct ieee80211vap *vap) { - struct ifnet *ifp = ic->ic_ifp; + struct ifnet *ifp = vap->iv_ic->ic_ifp; struct ath_softc *sc = ifp->if_softc; DPRINTF(sc, ATH_DEBUG_KEYCACHE, "%s:\n", __func__); @@ -1908,9 +2159,9 @@ } static void -ath_key_update_end(struct ieee80211com *ic) +ath_key_update_end(struct ieee80211vap *vap) { - struct ifnet *ifp = ic->ic_ifp; + struct ifnet *ifp = vap->iv_ic->ic_ifp; struct ath_softc *sc = ifp->if_softc; DPRINTF(sc, ATH_DEBUG_KEYCACHE, "%s:\n", __func__); @@ -1935,17 +2186,19 @@ * node table entries for peers, * - when operating in station mode for collecting rssi data when * the station is otherwise quiet, or + * - when operating as a repeater so we see repeater-sta beacons * - when scanning */ static u_int32_t ath_calcrxfilter(struct ath_softc *sc) { +#define RX_FILTER_PRESERVE (HAL_RX_FILTER_PHYERR | HAL_RX_FILTER_PHYRADAR) struct ieee80211com *ic = &sc->sc_ic; struct ath_hal *ah = sc->sc_ah; struct ifnet *ifp = &sc->sc_if; u_int32_t rfilt; - rfilt = (ath_hal_getrxfilter(ah) & HAL_RX_FILTER_PHYERR) + rfilt = (ath_hal_getrxfilter(ah) & RX_FILTER_PRESERVE) | HAL_RX_FILTER_UCAST | HAL_RX_FILTER_BCAST | HAL_RX_FILTER_MCAST; if (ic->ic_opmode != IEEE80211_M_STA) rfilt |= HAL_RX_FILTER_PROBEREQ; @@ -1954,9 +2207,45 @@ rfilt |= HAL_RX_FILTER_PROM; if (ic->ic_opmode == IEEE80211_M_STA || ic->ic_opmode == IEEE80211_M_IBSS || - (ic->ic_flags & IEEE80211_F_SCAN)) + sc->sc_rxbeacons || sc->sc_scanning) rfilt |= HAL_RX_FILTER_BEACON; return rfilt; +#undef RX_FILTER_PRESERVE +} + +/* + * Merge multicast addresses from all vap's to form the + * hardware filter. Ideally we should only inspect our + * own list and the 802.11 layer would merge for us but + * that's a bit difficult so for now we put the onus on + * the driver. + */ +static void +ath_merge_mcast(struct ath_softc *sc, u_int32_t mfilt[2]) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct ieee80211vap *vap; + u_int32_t val; + u_int8_t pos; + struct ifmultiaddr *ifma; + + mfilt[0] = mfilt[1] = 0; + /* XXX locking */ + TAILQ_FOREACH(vap, &ic->ic_vaps, iv_next) { + struct ifnet *ifp = &vap->iv_if; + TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { + caddr_t dl; + + /* calculate XOR of eight 6bit values */ + dl = LLADDR((struct sockaddr_dl *) ifma->ifma_addr); + val = LE_READ_4(dl + 0); + pos = (val >> 18) ^ (val >> 12) ^ (val >> 6) ^ val; + val = LE_READ_4(dl + 3); + pos ^= (val >> 18) ^ (val >> 12) ^ (val >> 6) ^ val; + pos &= 0x3f; + mfilt[pos / 32] |= (1 << (pos % 32)); + } + } } static void @@ -1965,9 +2254,7 @@ struct ath_hal *ah = sc->sc_ah; struct ieee80211com *ic = &sc->sc_ic; struct ifnet *ifp = &sc->sc_if; - u_int32_t rfilt, mfilt[2], val; - u_int8_t pos; - struct ifmultiaddr *ifma; + u_int32_t rfilt, mfilt[2]; /* configure rx filter */ rfilt = ath_calcrxfilter(sc); @@ -1989,19 +2276,7 @@ /* calculate and install multicast filter */ if ((ifp->if_flags & IFF_ALLMULTI) == 0) { - mfilt[0] = mfilt[1] = 0; - TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) { - caddr_t dl; - - /* calculate XOR of eight 6bit values */ - dl = LLADDR((struct sockaddr_dl *) ifma->ifma_addr); - val = LE_READ_4(dl + 0); - pos = (val >> 18) ^ (val >> 12) ^ (val >> 6) ^ val; - val = LE_READ_4(dl + 3); - pos ^= (val >> 18) ^ (val >> 12) ^ (val >> 6) ^ val; - pos &= 0x3f; - mfilt[pos / 32] |= (1 << (pos % 32)); - } + ath_merge_mcast(sc, mfilt); } else { mfilt[0] = mfilt[1] = ~0; } @@ -2043,11 +2318,163 @@ */ if (ic->ic_opmode == IEEE80211_M_HOSTAP) sc->sc_updateslot = UPDATE; - else + else if (ifp->if_flags & IFF_RUNNING) ath_setslottime(sc); } /* + * Dynamic turbo support. + * XXX much of this could be moved up to the net80211 layer. + */ + +/* + * Configure dynamic turbo state on beacon setup. + */ +static void +ath_beacon_dturbo_config(struct ath_softc *sc, u_int32_t intval) +{ +#define IS_CAPABLE(ic) \ + (ic->ic_caps & IEEE80211_C_TURBOP) + struct ieee80211com *ic = &sc->sc_ic; + + if (ic->ic_opmode == IEEE80211_M_HOSTAP && + IS_CAPABLE(ic) && IEEE80211_IS_CHAN_DTURBO(ic->ic_bsschan)) { + /* Dynamic Turbo is supported on this channel. */ + sc->sc_dturbo = 1; + sc->sc_dt_tcount = 0; + sc->sc_dt_switch = 0; + sc->sc_ignore_ar = 0; + + /* Set the initial ATHC_BOOST capability. */ + if (ic->ic_bsschan->ic_flags & CHANNEL_TURBO) + ic->ic_flags |= IEEE80211_F_BOOST; + else + ic->ic_flags &= ~IEEE80211_F_BOOST; + + /* + * Calculate time & bandwidth thresholds + * + * sc_dt_base_tmin : ~70 seconds + * sc_dt_turbo_tmax : ~120 seconds + * + * NB: scale calculated values to account for staggered + * beacon handling + */ + sc->sc_dt_base_tmin = 70 * 1024 * ATH_BCBUF / intval; + sc->sc_dt_turbo_tmax = 120 * 1024 * ATH_BCBUF / intval; + sc->sc_dt_base_bw = 0; /* XXX: TBD */ + sc->sc_dt_turbo_bw = 0; /* XXX: TBD */ + } else { + sc->sc_dturbo = 0; + ic->ic_flags &= ~IEEE80211_F_BOOST; + } +#undef IS_CAPABLE +} + +/* + * Update dynamic turbo state at SWBA. We assume we care + * called only if dynamic turbo has been enabled (sc_turbo). >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Sat May 7 03:39:15 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0219816A4D9; Sat, 7 May 2005 03:39:15 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CA8B416A4D6 for ; Sat, 7 May 2005 03:39:14 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B3EDF43D79 for ; Sat, 7 May 2005 03:39:14 +0000 (GMT) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j473dEZo021637 for ; Sat, 7 May 2005 03:39:14 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j473dEX5021634 for perforce@freebsd.org; Sat, 7 May 2005 03:39:14 GMT (envelope-from sam@freebsd.org) Date: Sat, 7 May 2005 03:39:14 GMT Message-Id: <200505070339.j473dEX5021634@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Subject: PERFORCE change 76647 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 May 2005 03:39:15 -0000 http://perforce.freebsd.org/chv.cgi?CH=76647 Change 76647 by sam@sam_ebb on 2005/05/07 03:38:53 remove more remnants of ic_curmode Affected files ... .. //depot/projects/vap/sys/net80211/ieee80211_ioctl.c#7 edit .. //depot/projects/vap/sys/net80211/ieee80211_output.c#8 edit Differences ... ==== //depot/projects/vap/sys/net80211/ieee80211_ioctl.c#7 (text+ko) ==== @@ -297,12 +297,13 @@ wreq.wi_len = IEEE80211_ADDR_LEN / 2; break; case WI_RID_TX_RATE: - if (vap->iv_fixed_rate == -1) + if (vap->iv_fixed_rate != -1 && + ic->ic_bsschan != IEEE80211_CHAN_ANYC) { + i = ieee80211_chan2mode(ic->ic_bsschan); + j = ic->ic_sup_rates[i].rs_rates[vap->iv_fixed_rate] & IEEE80211_RATE_VAL; + wreq.wi_val[0] = htole16(j / 2); + } else wreq.wi_val[0] = 0; /* auto */ - else - wreq.wi_val[0] = htole16( - (ic->ic_sup_rates[ic->ic_curmode].rs_rates[vap->iv_fixed_rate] & - IEEE80211_RATE_VAL) / 2); wreq.wi_len = 1; break; case WI_RID_CUR_TX_RATE: @@ -2209,7 +2210,8 @@ return EINVAL; ic->ic_protmode = ireq->i_val; /* NB: if not operating in 11g this can wait */ - if (ic->ic_curmode == IEEE80211_MODE_11G) + if (ic->ic_bsschan != IEEE80211_CHAN_ANYC && + IEEE80211_IS_CHAN_ANYG(ic->ic_bsschan)) error = IS_UP(vap) ? ic->ic_reset(ifp) : 0; break; case IEEE80211_IOC_TXPOWER: ==== //depot/projects/vap/sys/net80211/ieee80211_output.c#8 (text+ko) ==== @@ -2041,7 +2041,7 @@ } if (vap->iv_flags & IEEE80211_F_WPA) frm = ieee80211_add_wpa(frm, vap); - if (ic->ic_curmode == IEEE80211_MODE_11G) + if (IEEE80211_IS_CHAN_ANYG(ic->ic_bsschan)) frm = ieee80211_add_erp(frm, ic); efrm = ieee80211_add_xrates(frm, rs); bo->bo_trailer_len = efrm - bo->bo_trailer; From owner-p4-projects@FreeBSD.ORG Sat May 7 21:42:05 2005 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id CBAA316A4DF; Sat, 7 May 2005 21:42:04 +0000 (GMT) Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9B66D16A4DD for ; Sat, 7 May 2005 21:42:04 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7220F43D9F for ; Sat, 7 May 2005 21:42:04 +0000 (GMT) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j47Lg443098804 for ; Sat, 7 May 2005 21:42:04 GMT (envelope-from marcel@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j47Lg4JE098801 for perforce@freebsd.org; Sat, 7 May 2005 21:42:04 GMT (envelope-from marcel@freebsd.org) Date: Sat, 7 May 2005 21:42:04 GMT Message-Id: <200505072142.j47Lg4JE098801@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to marcel@freebsd.org using -f From: Marcel Moolenaar To: Perforce Change Reviews Subject: PERFORCE change 76664 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 May 2005 21:42:05 -0000 http://perforce.freebsd.org/chv.cgi?CH=76664 Change 76664 by marcel@marcel_nfs on 2005/05/07 21:41:29 A bunch of changes. Most importantly: o Add dev/ic/vga.h for register definitions and the likes. o Design the hardware interface around bitblt. The vtc(4) driver will deal with cursors, fonts and the likes. o Revamp the vga(4) driver accordingly. This change makes the vtc(4) and vga(4) code non-functional, but instead paves the way towards the final goal. Compiles on: ia64. Affected files ... .. //depot/projects/tty/sys/conf/files#24 edit .. //depot/projects/tty/sys/dev/ic/vga.h#1 add .. //depot/projects/tty/sys/dev/vga/vga.c#4 edit .. //depot/projects/tty/sys/dev/vga/vga.h#4 edit .. //depot/projects/tty/sys/dev/vga/vga_bus_isa.c#2 edit .. //depot/projects/tty/sys/dev/vga/vga_bus_pci.c#2 edit .. //depot/projects/tty/sys/dev/vga/vga_con.c#1 add .. //depot/projects/tty/sys/dev/vga/vga_cons.c#6 delete .. //depot/projects/tty/sys/dev/vga/vga_cpu_alpha.c#3 edit .. //depot/projects/tty/sys/dev/vga/vga_cpu_amd64.c#3 edit .. //depot/projects/tty/sys/dev/vga/vga_cpu_i386.c#4 edit .. //depot/projects/tty/sys/dev/vga/vga_cpu_ia64.c#3 edit .. //depot/projects/tty/sys/dev/vga/vga_cpu_sparc64.c#2 edit .. //depot/projects/tty/sys/dev/vga/vga_vid.c#3 delete .. //depot/projects/tty/sys/dev/vtc/vtc_con.c#1 add .. //depot/projects/tty/sys/dev/vtc/vtc_con.h#1 add .. //depot/projects/tty/sys/dev/vtc/vtc_core.c#2 edit .. //depot/projects/tty/sys/dev/vtc/vtc_tty.c#1 add Differences ... ==== //depot/projects/tty/sys/conf/files#24 (text+ko) ==== @@ -916,9 +916,10 @@ dev/vga/vga.c optional vga dev/vga/vga_bus_isa.c optional vga isa dev/vga/vga_bus_pci.c optional vga pci -dev/vga/vga_cons.c optional vga +dev/vga/vga_con.c optional vga dev/vge/if_vge.c optional vge dev/vkbd/vkbd.c optional vkbd +dev/vtc/vtc_con.c optional vtc dev/vtc/vtc_core.c optional vtc dev/vx/if_vx.c optional vx dev/vx/if_vx_eisa.c optional vx eisa ==== //depot/projects/tty/sys/dev/vga/vga.c#4 (text+ko) ==== @@ -34,158 +34,60 @@ #include #include +#include #include struct vga_softc vga_console; devclass_t vga_devclass; char vga_device_name[] = "vga"; -int vga_curcol; -int vga_currow; - -static void -vga_write(struct vga_softc *sc, int y, int x, int ascii, int color) +int +vga_probe(struct vga_softc *sc) { - uint32_t ofs; - uint16_t w; - ofs = y * 160 + x * 2; - w = color * 256 + ascii; - bus_space_write_2(sc->vga_screen.bst, sc->vga_screen.bsh, ofs, w); + return (1); } -static void -vga_scrollup(struct vga_softc *sc) +int +vga_init(struct vga_softc *sc) { - uint32_t count, ofs; - uint16_t w; + int error; - ofs = 0; + sc->vga_screen = sc->vga_fb; + error = bus_space_subregion(sc->vga_fb.bst, sc->vga_fb.bsh, + (sc->vga_mono) ? 0x10000 : 0x18000, 4096, &sc->vga_screen.bsh); + if (error) + return (error); - /* Copy data on lower 24 lines 1 line up. */ - count = 24*80; - while (count--) { - w = bus_space_read_2(sc->vga_screen.bst, sc->vga_screen.bsh, - ofs + 160); - bus_space_write_2(sc->vga_screen.bst, sc->vga_screen.bsh, - ofs, w); - ofs += 2; - } + /* TODO -- set the VGA adapter in 640x480x16 mode */ - /* Clear bottom line. Use BG color of last character copied. */ - count = 80; - w = (w & 0xff00) | 0x20; - while (count--) { - bus_space_write_2(sc->vga_screen.bst, sc->vga_screen.bsh, - ofs, w); - ofs += 2; - } + sc->vga_enable = 1; + return (0); } -void -vga_setpos(struct vga_softc *sc, int row, int col) +int +vga_bitblt(struct vga_softc *sc, int x, int y) { - uint16_t ofs; - ofs = row * 80 + col; - bus_space_write_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 0, 14); - bus_space_write_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 1, ofs >> 8); - bus_space_write_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 0, 15); - bus_space_write_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 1, ofs & 0xff); -} - -void -vga_getpos(struct vga_softc *sc, int *row, int *col) -{ - uint16_t ofs; - - bus_space_write_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 0, 14); - ofs = bus_space_read_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 1) << 8; - bus_space_write_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 0, 15); - ofs |= bus_space_read_1(sc->vga_crtc.bst, sc->vga_crtc.bsh, 1) & 0xff; - *row = ofs / 80; - *col = ofs % 80; + return (0); } -void -vga_putc(struct vga_softc *sc, int c) -{ - int d; - - d = 1; - switch (c) { - case 0x07: /* bell */ - return; - case 0x08: /* backspace */ - c = ' '; - if (vga_curcol) - vga_curcol--; - d = 0; - break; - case 0x09: /* tab */ - vga_curcol = (vga_curcol + 8) & ~7; - if (vga_curcol < 80) { - vga_setpos(sc, vga_currow, vga_curcol); - return; - } - /* FALLTHOUGH */ - case 0x0a: /* linefeed */ - if (vga_currow == 24) - vga_scrollup(sc); - else - vga_currow++; - /* FALLTHROUGH */ - case 0x0d: /* carriage return */ - vga_curcol = 0; - vga_setpos(sc, vga_currow, vga_curcol); - return; - } - vga_write(sc, vga_currow, vga_curcol, c, 0x0f); - vga_curcol += d; - if (vga_curcol >= 80) { - vga_curcol = 0; - if (vga_currow == 24) - vga_scrollup(sc); - else - vga_currow++; - } - vga_setpos(sc, vga_currow, vga_curcol); -} - -void -vga_puts(struct vga_softc *sc, const char *s) -{ - - while (*s) - vga_putc(sc, *s++); -} - int vga_attach(device_t dev) { struct vga_softc *sc; int error; - uint32_t x, y; sc = device_get_softc(dev); - sc->vga_screen = sc->vga_fb; - error = bus_space_subregion(sc->vga_fb.bst, sc->vga_fb.bsh, - (sc->vga_mono) ? 0x10000 : 0x18000, 4096, &sc->vga_screen.bsh); - if (error) - return (error); - - sc->vga_enable = 1; - if (sc->vga_console) return (0); - for (y = 0; y < 25; y++) - for (x = 0; x < 80; x++) - vga_write(sc, y, x, ' ', 7); + error = vga_init(sc); + if (error) + return (error); - vga_currow = vga_curcol = 0; - vga_puts(sc, "Please wait...\r"); + /* TODO -- show beastie logo */ return (0); } ==== //depot/projects/tty/sys/dev/vga/vga.h#4 (text+ko) ==== @@ -29,9 +29,7 @@ #ifndef _DEV_VGA_VGA_H_ #define _DEV_VGA_VGA_H_ -#define VGA_REG_MISC 0x1c /* 0x3CC */ - -struct vga_space +struct vga_spc { bus_space_tag_t bst; bus_space_handle_t bsh; @@ -39,35 +37,34 @@ struct vga_softc { - struct consdev * vga_consdev; - device_t vga_dev; - dev_t vga_node; + device_t vga_dev; + dev_t vga_node; /* Device flags and state. */ - int vga_bustype:2; + int vga_bustype:2; #define VGA_BUSTYPE_ISA 1 #define VGA_BUSTYPE_PCI 2 - int vga_console:1; - int vga_enable:1; - int vga_mono:1; + int vga_console:1; + int vga_enable:1; + int vga_mono:1; /* Bus spaces */ - struct vga_space vga_space[4]; + struct vga_spc vga_spc[4]; #define VGA_RES_FB 0 #define VGA_RES_SCREEN 1 #define VGA_RES_REG 2 #define VGA_RES_CRTC 3 }; -#define vga_fb vga_space[VGA_RES_FB] -#define vga_screen vga_space[VGA_RES_SCREEN] -#define vga_reg vga_space[VGA_RES_REG] -#define vga_crtc vga_space[VGA_RES_CRTC] +#define vga_fb vga_spc[VGA_RES_FB] +#define vga_screen vga_spc[VGA_RES_SCREEN] +#define vga_reg vga_spc[VGA_RES_REG] +#define vga_crtc vga_spc[VGA_RES_CRTC] struct vga_consdata { - struct vga_space fb; - struct vga_space reg; - struct vga_space crtc; + struct vga_spc fb; + struct vga_spc reg; + struct vga_spc crtc; }; int vga_get_console(struct vga_consdata*); @@ -76,14 +73,18 @@ extern devclass_t vga_devclass; extern char vga_device_name[]; -extern int vga_curcol; -extern int vga_currow; +static __inline int +vga_is_mono(struct vga_spc *sp) +{ + uint8_t misc; + + misc = bus_space_read_1(sp->bst, sp->bsh, VGA_GEN_MISC_OUTPUT_R); + return ((misc & VGA_GEN_MO_IOA) ? 0 : 1); +} int vga_attach(device_t); - -void vga_getpos(struct vga_softc *, int *, int *); -void vga_putc(struct vga_softc *, int); -void vga_puts(struct vga_softc *, const char *); -void vga_setpos(struct vga_softc *, int, int); +int vga_bitblt(struct vga_softc *, int, int); +int vga_init(struct vga_softc *); +int vga_probe(struct vga_softc *); #endif /* _DEV_VGA_VGA_H_ */ ==== //depot/projects/tty/sys/dev/vga/vga_bus_isa.c#2 (text+ko) ==== @@ -39,6 +39,7 @@ #include #include +#include #include static int vga_isa_attach(device_t); ==== //depot/projects/tty/sys/dev/vga/vga_bus_pci.c#2 (text+ko) ==== @@ -39,6 +39,7 @@ #include #include +#include #include static int vga_pci_attach(device_t dev); @@ -66,8 +67,8 @@ if (res == NULL) return (ENXIO); - sc->vga_space[rid].bsh = rman_get_bushandle(res); - sc->vga_space[rid].bst = rman_get_bustag(res); + sc->vga_spc[rid].bsh = rman_get_bushandle(res); + sc->vga_spc[rid].bst = rman_get_bustag(res); return (0); } @@ -76,8 +77,6 @@ { struct vga_softc *sc; int error; - uint32_t crtc; - uint8_t x; /* * If VGA is the console, this device must be it. If not, then @@ -90,8 +89,10 @@ sc->vga_bustype = VGA_BUSTYPE_PCI; /* Set the legacy resources */ - bus_set_resource(dev, SYS_RES_MEMORY, VGA_RES_FB, 0xA0000, 0x20000); - bus_set_resource(dev, SYS_RES_IOPORT, VGA_RES_REG, 0x3c0, 0x10); + bus_set_resource(dev, SYS_RES_MEMORY, VGA_RES_FB, VGA_MEM_BASE, + VGA_MEM_SIZE); + bus_set_resource(dev, SYS_RES_IOPORT, VGA_RES_REG, VGA_IO0_BASE, + VGA_IO0_SIZE); error = vga_pci_alloc(dev, sc, SYS_RES_MEMORY, VGA_RES_FB); if (error) @@ -100,12 +101,11 @@ if (error) return (error); - /* Determine if the VGA controller is in colour or monochrome mode. */ - x = bus_space_read_1(sc->vga_reg.bst, sc->vga_reg.bsh, VGA_REG_MISC); - sc->vga_mono = (x & 1) ? 0 : 1; + /* Determine if the VGA controller is in color or monochrome mode. */ + sc->vga_mono = vga_is_mono(&sc->vga_reg); - crtc = (sc->vga_mono) ? 0x3b0 : 0x3d0; - bus_set_resource(dev, SYS_RES_IOPORT, VGA_RES_CRTC, crtc, 0x0c); + bus_set_resource(dev, SYS_RES_IOPORT, VGA_RES_CRTC, + (sc->vga_mono) ? VGA_IO1_MONO : VGA_IO1_COLOR, VGA_IO1_SIZE); error = vga_pci_alloc(dev, sc, SYS_RES_IOPORT, VGA_RES_CRTC); if (error) return (error); ==== //depot/projects/tty/sys/dev/vga/vga_cpu_alpha.c#3 (text+ko) ==== @@ -32,28 +32,18 @@ #include +#include #include int vga_get_console(struct vga_consdata *cd) { - int mono; - uint8_t misc; cd->fb.bst = busspace_isa_mem; - cd->fb.bsh = 0xA0000; + cd->fb.bsh = VGA_MEM_BASE; cd->reg.bst = busspace_isa_io; - cd->reg.bsh = 0x3c0; - - /* - * Determine if the VGA controller is in colour or monochrome mode. - * That way we know where the CRTC registers are. - */ - misc = bus_space_read_1(cd->reg.bst, cd->reg.bsh, VGA_REG_MISC); - mono = (misc & 1) ? 0 : 1; - + cd->reg.bsh = VGA_IO0_BASE; cd->crtc.bst = busspace_isa_io; - cd->crtc.bsh = (mono) ? 0x3b4 : 0x3d4; - + cd->crtc.bsh = (vga_is_mono(&cd->reg)) ? VGA_IO1_MONO : VGA_IO1_COLOR; return (0); } ==== //depot/projects/tty/sys/dev/vga/vga_cpu_amd64.c#3 (text+ko) ==== @@ -38,28 +38,18 @@ #include #include +#include #include int vga_get_console(struct vga_consdata *cd) { - int mono; - uint8_t misc; cd->fb.bst = AMD64_BUS_SPACE_MEM; - cd->fb.bsh = 0xA0000 + KERNBASE; + cd->fb.bsh = KERNBASE + VGA_MEM_BASE; cd->reg.bst = AMD64_BUS_SPACE_IO; - cd->reg.bsh = 0x3c0; - - /* - * Determine if the VGA controller is in colour or monochrome mode. - * That way we know where the CRTC registers are. - */ - misc = bus_space_read_1(cd->reg.bst, cd->reg.bsh, VGA_REG_MISC); - mono = (misc & 1) ? 0 : 1; - + cd->reg.bsh = VGA_IO0_BASE; cd->crtc.bst = AMD64_BUS_SPACE_IO; - cd->crtc.bsh = (mono) ? 0x3b4 : 0x3d4; - + cd->crtc.bsh = (vga_is_mono(&cd->reg)) ? VGA_IO1_MONO : VGA_IO1_COLOR; return (0); } ==== //depot/projects/tty/sys/dev/vga/vga_cpu_i386.c#4 (text+ko) ==== @@ -38,28 +38,18 @@ #include #include +#include #include int vga_get_console(struct vga_consdata *cd) { - int mono; - uint8_t misc; cd->fb.bst = I386_BUS_SPACE_MEM; - cd->fb.bsh = 0xA0000 + KERNBASE; + cd->fb.bsh = KERNBASE + VGA_MEM_BASE; cd->reg.bst = I386_BUS_SPACE_IO; - cd->reg.bsh = 0x3c0; - - /* - * Determine if the VGA controller is in colour or monochrome mode. - * That way we know where the CRTC registers are. - */ - misc = bus_space_read_1(cd->reg.bst, cd->reg.bsh, VGA_REG_MISC); - mono = (misc & 1) ? 0 : 1; - + cd->reg.bsh = VGA_IO0_BASE; cd->crtc.bst = I386_BUS_SPACE_IO; - cd->crtc.bsh = (mono) ? 0x3b4 : 0x3d4; - + cd->crtc.bsh = (vga_is_mono(&cd->reg)) ? VGA_IO1_MONO : VGA_IO1_COLOR; return (0); } ==== //depot/projects/tty/sys/dev/vga/vga_cpu_ia64.c#3 (text+ko) ==== @@ -32,28 +32,18 @@ #include +#include #include int vga_get_console(struct vga_consdata *cd) { - int mono; - uint8_t misc; cd->fb.bst = IA64_BUS_SPACE_MEM; - cd->fb.bsh = IA64_PHYS_TO_RR6(0xA0000); /* XXX */ + cd->fb.bsh = IA64_PHYS_TO_RR6(VGA_MEM_BASE); cd->reg.bst = IA64_BUS_SPACE_IO; - cd->reg.bsh = 0x3c0; - - /* - * Determine if the VGA controller is in colour or monochrome mode. - * That way we know where the CRTC registers are. - */ - misc = bus_space_read_1(cd->reg.bst, cd->reg.bsh, VGA_REG_MISC); - mono = (misc & 1) ? 0 : 1; - + cd->reg.bsh = VGA_IO0_BASE; cd->crtc.bst = IA64_BUS_SPACE_IO; - cd->crtc.bsh = (mono) ? 0x3b4 : 0x3d4; - + cd->crtc.bsh = (vga_is_mono(&cd->reg)) ? VGA_IO1_MONO : VGA_IO1_COLOR; return (0); } ==== //depot/projects/tty/sys/dev/vga/vga_cpu_sparc64.c#2 (text+ko) ==== @@ -28,15 +28,56 @@ __FBSDID("$FreeBSD$"); #include -#include +#include #include +#include + +#include +#include +#include #include int vga_get_console(struct vga_consdata *cd) { + static struct bus_space_tag bst_store[3]; + char odev[32]; + ihandle_t stdout; + phandle_t chosen, oh, options; - return (ENXIO); + /* + * Query OFW to see if we have a graphical console and whether + * it's actually a VGA. + */ + if ((options = OF_finddevice("/options")) == -1) + return (ENXIO); + if (OF_getprop(options, "output-device", odev, sizeof(odev)) == -1) + return (ENXIO); + if (strcmp(odev, "screen") != 0) + return (ENODEV); + if ((oh = OF_finddevice(odev)) == -1) + return (ENXIO); + if ((chosen = OF_finddevice("/chosen")) == -1) + return (ENXIO); + if (OF_getprop(chosen, "stdout", &stdout, sizeof(stdout)) == -1) + return (ENXIO); + if (OF_instance_to_package(stdout) != oh) + return (ENODEV); + + /* XXX check if it's a VGA. */ + + /* Construct the bus tags and handles. */ + cd->fb.bst = &bst_store[0]; + cd->fb.bsh = sparc64_fake_bustag(PCI_MEMORY_BUS_SPACE, 0x1ff000a0000, + cd->fb.bst); + cd->reg.bst = &bst_store[1]; + cd->reg.bsh = sparc64_fake_bustag(PCI_IO_BUS_SPACE, 0x1fe020003c0, + cd->reg.bst); + cd->crtc.bst = &bst_store[2]; + cd->crtc.bsh = (vga_is_mono(&cd->reg)) ? + sparc64_fake_bustag(PCI_IO_BUS_SPACE, 0x1fe020003b0, cd->crtc.bst) : + sparc64_fake_bustag(PCI_IO_BUS_SPACE, 0x1fe020003d0, cd->crtc.bst); + return (0); } ==== //depot/projects/tty/sys/dev/vtc/vtc_core.c#2 (text+ko) ==== @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2004 Marcel Moolenaar + * Copyright (c) 2003-2005 Marcel Moolenaar * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -30,154 +30,19 @@ #include #include #include -#include #include -#include #include -#include -#include -#include -#include -#include - -static d_close_t vtc_close; -static d_ioctl_t vtc_ioctl; -static d_mmap_t vtc_mmap; -static d_open_t vtc_open; - -static struct cdevsw vtc_cdevsw = { - .d_version = D_VERSION, - .d_open = vtc_open; - .d_close = vtc_close; - .d_ioctl = vtc_ioctl; - .d_mmap = vtc_mmap; - .d_name = "vtc", - .d_flags = D_TTY | D_NEEDGIANT, -}; - -static dev_t vtc_console; static int -vtc_open(dev_t dev, int flag, int mode, struct thread *td) -{ - struct uart_softc *sc; - struct tty *tp; - int error; - - sc = dev->si_drv1; - if (sc == NULL || sc->sc_leaving) - return (ENODEV); - - tp = dev->si_tty; - - loop: - if (sc->sc_opened) { - KASSERT(tp->t_state & TS_ISOPEN, ("foo")); - /* - * The device is open, so everything has been initialized. - * Handle conflicts. - */ - if (minor(dev) & UART_MINOR_CALLOUT) { - if (!sc->sc_callout) - return (EBUSY); - } else { - if (sc->sc_callout) { - if (flags & O_NONBLOCK) - return (EBUSY); - error = tsleep(sc, TTIPRI|PCATCH, "uartbi", 0); - if (error) - return (error); - sc = dev->si_drv1; - if (sc == NULL || sc->sc_leaving) - return (ENODEV); - goto loop; - } - } - if (tp->t_state & TS_XCLUDE && suser(td) != 0) - return (EBUSY); - } else { - KASSERT(!(tp->t_state & TS_ISOPEN), ("foo")); - /* - * The device isn't open, so there are no conflicts. - * Initialize it. Initialization is done twice in many - * cases: to preempt sleeping callin opens if we are - * callout, and to complete a callin open after DCD rises. - */ - sc->sc_callout = (minor(dev) & UART_MINOR_CALLOUT) ? 1 : 0; - tp->t_dev = dev; - - tp->t_cflag = TTYDEF_CFLAG; - tp->t_iflag = TTYDEF_IFLAG; - tp->t_lflag = TTYDEF_LFLAG; - tp->t_oflag = TTYDEF_OFLAG; - tp->t_ispeed = tp->t_ospeed = TTYDEF_SPEED; - ttychars(tp); - error = uart_tty_param(tp, &tp->t_termios); - if (error) - return (error); - /* - * Handle initial DCD. - */ - if ((sc->sc_hwsig & UART_SIG_DCD) || sc->sc_callout) - ttyld_modem(tp, 1); - } - /* - * Wait for DCD if necessary. - */ - if (!(tp->t_state & TS_CARR_ON) && !sc->sc_callout && - !(tp->t_cflag & CLOCAL) && !(flags & O_NONBLOCK)) { - error = tsleep(TSA_CARR_ON(tp), TTIPRI|PCATCH, "uartdcd", 0); - if (error) - return (error); - sc = dev->si_drv1; - if (sc == NULL || sc->sc_leaving) - return (ENODEV); - goto loop; - } - error = ttyopen(dev, tp); - if (error) - return (error); - error = ttyld_open(tp, dev); - if (error) - return (error); - - KASSERT(tp->t_state & TS_ISOPEN, ("foo")); - sc->sc_opened = 1; - return (0); -} - -static int -vtc_close(dev_t dev, int flag, int mode, struct thread *td) -{ -} - -static int -vtc_ioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct thread *td) -{ - - return (ttyioctl(dev, cmd, data, flag, td)); -} - -static int -vtc_mmap(dev_t dev, vm_offset_t offset, vm_paddr_t *paddr, int nprot) -{ - - return (-1); -} - -static int vtc_modevent(module_t mod, int type, void *data) { - switch(type) { + switch (type) { case MOD_LOAD: - printf("vtc: \n"); - vtc_console = make_dev(&vtc_cdevsw, 0, UID_ROOT, GID_WHEEL, - 0666, "console"); + printf("vtc: \n"); return (0); case MOD_UNLOAD: - destroy_dev(vtc_console); return (0); case MOD_SHUTDOWN: