From owner-p4-projects@FreeBSD.ORG Sun Sep 24 12:10:44 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E978016A412; Sun, 24 Sep 2006 12:10:43 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 C4DE916A47B for ; Sun, 24 Sep 2006 12:10:43 +0000 (UTC) (envelope-from als@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id BE4A143D7C for ; Sun, 24 Sep 2006 12:10:40 +0000 (GMT) (envelope-from als@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8OCAe0g014010 for ; Sun, 24 Sep 2006 12:10:40 GMT (envelope-from als@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OCAe0W014007 for perforce@freebsd.org; Sun, 24 Sep 2006 12:10:40 GMT (envelope-from als@FreeBSD.org) Date: Sun, 24 Sep 2006 12:10:40 GMT Message-Id: <200609241210.k8OCAe0W014007@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to als@FreeBSD.org using -f From: Alex Lyashkov To: Perforce Change Reviews Cc: Subject: PERFORCE change 106595 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 12:10:44 -0000 http://perforce.freebsd.org/chv.cgi?CH=106595 Change 106595 by als@als_head on 2006/09/24 12:10:08 restore set prison ip via old jail api Affected files ... .. //depot/projects/jail2/sys/kern/kern_jail.c#8 edit Differences ... ==== //depot/projects/jail2/sys/kern/kern_jail.c#8 (text+ko) ==== @@ -66,7 +66,7 @@ static int sysctl_jail_list(SYSCTL_HANDLER_ARGS); static int find_empty_prid(void); -#define jprint(a...) +#define jprint(a...) /* printf(a) */ static void @@ -118,6 +118,7 @@ if (error) goto e_dropref; + pr->pr_network.pr_ip = htonl(j.ip_number); JAIL_SET_STARTED(pr); error = jail_migrate(td, pr); if (error) From owner-p4-projects@FreeBSD.ORG Sun Sep 24 12:18:55 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3652716A40F; Sun, 24 Sep 2006 12:18:55 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 0917716A403 for ; Sun, 24 Sep 2006 12:18:55 +0000 (UTC) (envelope-from als@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id DAB4C43D46 for ; Sun, 24 Sep 2006 12:18:52 +0000 (GMT) (envelope-from als@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8OCIqsi014419 for ; Sun, 24 Sep 2006 12:18:52 GMT (envelope-from als@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OCIpIo014416 for perforce@freebsd.org; Sun, 24 Sep 2006 12:18:51 GMT (envelope-from als@FreeBSD.org) Date: Sun, 24 Sep 2006 12:18:51 GMT Message-Id: <200609241218.k8OCIpIo014416@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to als@FreeBSD.org using -f From: Alex Lyashkov To: Perforce Change Reviews Cc: Subject: PERFORCE change 106596 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 12:18:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=106596 Change 106596 by als@als_head on 2006/09/24 12:18:28 merge HEAD Affected files ... .. //depot/projects/jail2/sys/amd64/conf/NOTES#4 integrate .. //depot/projects/jail2/sys/amd64/ia32/ia32_sigtramp.S#2 integrate .. //depot/projects/jail2/sys/compat/freebsd32/freebsd32_proto.h#6 integrate .. //depot/projects/jail2/sys/compat/freebsd32/freebsd32_syscall.h#6 integrate .. //depot/projects/jail2/sys/compat/freebsd32/freebsd32_syscalls.c#6 integrate .. //depot/projects/jail2/sys/compat/freebsd32/freebsd32_sysent.c#6 integrate .. //depot/projects/jail2/sys/compat/freebsd32/syscalls.master#6 integrate .. //depot/projects/jail2/sys/compat/linux/linux_file.c#4 integrate .. //depot/projects/jail2/sys/compat/linux/linux_socket.c#3 integrate .. //depot/projects/jail2/sys/conf/files.amd64#5 integrate .. //depot/projects/jail2/sys/conf/files.i386#4 integrate .. //depot/projects/jail2/sys/dev/acpica/Osd/OsdHardware.c#2 integrate .. //depot/projects/jail2/sys/dev/bge/if_bge.c#6 integrate .. //depot/projects/jail2/sys/dev/exca/exca.c#2 integrate .. //depot/projects/jail2/sys/dev/ipmi/ipmi.c#2 integrate .. //depot/projects/jail2/sys/dev/ipmi/ipmi_acpi.c#1 branch .. //depot/projects/jail2/sys/dev/ipmi/ipmi_isa.c#1 branch .. //depot/projects/jail2/sys/dev/ipmi/ipmi_kcs.c#1 branch .. //depot/projects/jail2/sys/dev/ipmi/ipmi_pci.c#2 integrate .. //depot/projects/jail2/sys/dev/ipmi/ipmi_smbios.c#2 integrate .. //depot/projects/jail2/sys/dev/ipmi/ipmi_smbus.c#1 branch .. //depot/projects/jail2/sys/dev/ipmi/ipmi_smic.c#1 branch .. //depot/projects/jail2/sys/dev/ipmi/ipmi_ssif.c#1 branch .. //depot/projects/jail2/sys/dev/ipmi/ipmivars.h#2 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/buffer.c#3 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/buffer.h#3 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/channel.c#2 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/channel.h#2 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/channel_if.m#2 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/dsp.c#2 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/dsp.h#2 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/mixer.c#2 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/mixer.h#3 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/sound.c#4 integrate .. //depot/projects/jail2/sys/dev/sound/pcm/sound.h#3 integrate .. //depot/projects/jail2/sys/i386/conf/NOTES#5 integrate .. //depot/projects/jail2/sys/kern/kern_descrip.c#8 integrate .. //depot/projects/jail2/sys/kern/kern_event.c#2 integrate .. //depot/projects/jail2/sys/kern/kern_proc.c#4 integrate .. //depot/projects/jail2/sys/kern/tty.c#4 integrate .. //depot/projects/jail2/sys/kern/tty_pty.c#2 integrate .. //depot/projects/jail2/sys/kern/tty_tty.c#2 integrate .. //depot/projects/jail2/sys/kern/vfs_aio.c#4 integrate .. //depot/projects/jail2/sys/modules/ipmi/Makefile#2 integrate .. //depot/projects/jail2/sys/net/if_bridge.c#6 integrate .. //depot/projects/jail2/sys/netinet/if_ether.c#3 integrate .. //depot/projects/jail2/sys/netinet/tcp_input.c#5 integrate .. //depot/projects/jail2/sys/sys/event.h#2 integrate .. //depot/projects/jail2/sys/sys/ipmi.h#2 integrate .. //depot/projects/jail2/sys/sys/mbuf.h#4 integrate .. //depot/projects/jail2/sys/sys/param.h#4 integrate .. //depot/projects/jail2/sys/sys/soundcard.h#2 integrate Differences ... ==== //depot/projects/jail2/sys/amd64/conf/NOTES#4 (text+ko) ==== @@ -4,7 +4,7 @@ # This file contains machine dependent kernel configuration notes. For # machine independent notes, look in /sys/conf/NOTES. # -# $FreeBSD: src/sys/amd64/conf/NOTES,v 1.58 2006/07/29 18:38:53 marcel Exp $ +# $FreeBSD: src/sys/amd64/conf/NOTES,v 1.59 2006/09/22 22:11:28 jhb Exp $ # # @@ -346,6 +346,7 @@ # # Miscellaneous hardware: # +# ipmi: Intelligent Platform Management Interface # smbios: DMI/SMBIOS entry point # vpd: Vital Product Data kernel interface # cy: Cyclades serial driver @@ -368,6 +369,7 @@ device digi_Xe device digi_Xem device digi_Xr +device ipmi # Parallel (8255 PPI) basic I/O (mode 0) port (e.g. Advantech PCL-724) device pbio hint.pbio.0.at="isa" ==== //depot/projects/jail2/sys/amd64/ia32/ia32_sigtramp.S#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/amd64/ia32/ia32_sigtramp.S,v 1.2 2003/08/22 23:19:02 peter Exp $ + * $FreeBSD: src/sys/amd64/ia32/ia32_sigtramp.S,v 1.3 2006/09/23 13:42:09 davidxu Exp $ */ #include "opt_compat.h" @@ -45,8 +45,6 @@ calll *IA32_SIGF_HANDLER(%esp) leal IA32_SIGF_UC(%esp),%eax /* get ucontext */ pushl %eax - movl IA32_UC_GS(%eax),%gs /* restore %gs */ - movl IA32_UC_FS(%eax),%fs /* restore %fs */ movl IA32_UC_ES(%eax),%es /* restore %es */ movl IA32_UC_DS(%eax),%ds /* restore %ds */ movl $SYS_sigreturn,%eax @@ -62,8 +60,6 @@ calll *IA32_SIGF_HANDLER(%esp) leal IA32_SIGF_UC4(%esp),%eax/* get ucontext */ pushl %eax - movl IA32_UC4_GS(%eax),%gs /* restore %gs */ - movl IA32_UC4_FS(%eax),%fs /* restore %fs */ movl IA32_UC4_ES(%eax),%es /* restore %es */ movl IA32_UC4_DS(%eax),%ds /* restore %ds */ movl $344,%eax /* 4.x SYS_sigreturn */ ==== //depot/projects/jail2/sys/compat/freebsd32/freebsd32_proto.h#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call prototypes. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_proto.h,v 1.65 2006/09/22 15:05:33 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_proto.h,v 1.66 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ #ifndef _FREEBSD32_SYSPROTO_H_ ==== //depot/projects/jail2/sys/compat/freebsd32/freebsd32_syscall.h#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscall.h,v 1.63 2006/09/22 15:05:33 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscall.h,v 1.64 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ #define FREEBSD32_SYS_syscall 0 @@ -300,6 +300,7 @@ #define FREEBSD32_SYS_freebsd32_getcontext 421 #define FREEBSD32_SYS_freebsd32_setcontext 422 #define FREEBSD32_SYS_freebsd32_swapcontext 423 +#define FREEBSD32_SYS_sigwait 429 #define FREEBSD32_SYS_thr_exit 431 #define FREEBSD32_SYS_thr_self 432 #define FREEBSD32_SYS_thr_kill 433 ==== //depot/projects/jail2/sys/compat/freebsd32/freebsd32_syscalls.c#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call names. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscalls.c,v 1.54 2006/09/22 15:05:33 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscalls.c,v 1.55 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ const char *freebsd32_syscallnames[] = { @@ -436,7 +436,7 @@ "#426", /* 426 = __acl_set_link */ "#427", /* 427 = __acl_delete_link */ "#428", /* 428 = __acl_aclcheck_link */ - "#429", /* 429 = sigwait */ + "sigwait", /* 429 = sigwait */ "#430", /* 430 = thr_create; */ "thr_exit", /* 431 = thr_exit */ "thr_self", /* 432 = thr_self */ ==== //depot/projects/jail2/sys/compat/freebsd32/freebsd32_sysent.c#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call switch table. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_sysent.c,v 1.64 2006/09/22 15:05:34 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_sysent.c,v 1.65 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ #include "opt_compat.h" @@ -461,7 +461,7 @@ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 426 = __acl_set_link */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 427 = __acl_delete_link */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 428 = __acl_aclcheck_link */ - { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 429 = sigwait */ + { AS(sigwait_args), (sy_call_t *)sigwait, AUE_SIGWAIT, NULL, 0, 0 }, /* 429 = sigwait */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 430 = thr_create; */ { AS(thr_exit_args), (sy_call_t *)thr_exit, AUE_NULL, NULL, 0, 0 }, /* 431 = thr_exit */ { AS(thr_self_args), (sy_call_t *)thr_self, AUE_NULL, NULL, 0, 0 }, /* 432 = thr_self */ ==== //depot/projects/jail2/sys/compat/freebsd32/syscalls.master#6 (text+ko) ==== @@ -1,4 +1,4 @@ - $FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp $ + $FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp $ ; from: @(#)syscalls.master 8.2 (Berkeley) 1/13/94 ; from: src/sys/kern/syscalls.master 1.107 ; @@ -714,7 +714,8 @@ 427 AUE_NULL UNIMPL __acl_delete_link 428 AUE_NULL UNIMPL __acl_aclcheck_link ; XXX implement -429 AUE_SIGWAIT UNIMPL sigwait +429 AUE_SIGWAIT NOPROTO { int sigwait(const sigset_t *set, \ + int *sig); } 430 AUE_NULL UNIMPL thr_create; 431 AUE_NULL NOPROTO { void thr_exit(long *state); } 432 AUE_NULL NOPROTO { int thr_self(long *id); } ==== //depot/projects/jail2/sys/compat/linux/linux_file.c#4 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/compat/linux/linux_file.c,v 1.97 2006/09/10 13:47:56 netchild Exp $"); +__FBSDID("$FreeBSD: src/sys/compat/linux/linux_file.c,v 1.98 2006/09/23 19:06:54 netchild Exp $"); #include "opt_compat.h" #include "opt_mac.h" @@ -49,6 +49,7 @@ #include #include #include +#include #include #include @@ -480,6 +481,10 @@ char *path; int error; + /* linux convention */ + if (args->flags & ~(F_OK | X_OK | W_OK | R_OK)) + return (EINVAL); + LCONVPATHEXIST(td, args->path, &path); #ifdef DEBUG @@ -488,6 +493,7 @@ #endif error = kern_access(td, path, UIO_SYSSPACE, args->flags); LFREEPATH(path); + return (error); } @@ -724,12 +730,28 @@ struct linux_pread_args *uap; { struct pread_args bsd; + struct vnode *vp; + int error; bsd.fd = uap->fd; bsd.buf = uap->buf; bsd.nbyte = uap->nbyte; bsd.offset = uap->offset; - return pread(td, &bsd); + + error = pread(td, &bsd); + + if (error == 0) { + /* This seems to violate POSIX but linux does it */ + if ((error = fgetvp(td, uap->fd, &vp)) != 0) + return (error); + if (vp->v_type == VDIR) { + vrele(vp); + return (EISDIR); + } + vrele(vp); + } + + return (error); } int ==== //depot/projects/jail2/sys/compat/linux/linux_socket.c#3 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/compat/linux/linux_socket.c,v 1.70 2006/07/19 18:28:52 jhb Exp $"); +__FBSDID("$FreeBSD: src/sys/compat/linux/linux_socket.c,v 1.71 2006/09/23 19:06:54 netchild Exp $"); /* XXX we use functions that might not exist. */ #include "opt_compat.h" @@ -611,6 +611,8 @@ error = kern_bind(td, linux_args.s, sa); free(sa, M_SONAME); + if (error == EADDRNOTAVAIL && linux_args.namelen != sizeof(struct sockaddr_in)) + return (EINVAL); return (error); } @@ -719,8 +721,11 @@ bsd_args.anamelen = PTRIN(linux_args.namelen);/* XXX */ error = accept(td, &bsd_args); bsd_to_linux_sockaddr((struct sockaddr *)bsd_args.name); - if (error) + if (error) { + if (error == EFAULT && linux_args.namelen != sizeof(struct sockaddr_in)) + return (EINVAL); return (error); + } if (linux_args.addr) { error = linux_sa_put(PTRIN(linux_args.addr)); if (error) { @@ -1135,7 +1140,7 @@ break; } if (name == -1) - return (EINVAL); + return (ENOPROTOOPT); bsd_args.name = name; bsd_args.val = PTRIN(linux_args.optval); ==== //depot/projects/jail2/sys/conf/files.amd64#5 (text+ko) ==== @@ -1,7 +1,7 @@ # This file tells config what files go into building a kernel, # files marked standard are always included. # -# $FreeBSD: src/sys/conf/files.amd64,v 1.93 2006/09/05 16:55:12 anholt Exp $ +# $FreeBSD: src/sys/conf/files.amd64,v 1.94 2006/09/22 22:11:28 jhb Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -161,7 +161,13 @@ dev/if_ndis/if_ndis_usb.c optional ndis usb dev/io/iodev.c optional io dev/ipmi/ipmi.c optional ipmi -dev/ipmi/ipmi_smbios.c optional ipmi isa +dev/ipmi/ipmi_acpi.c optional ipmi acpi +dev/ipmi/ipmi_isa.c optional ipmi isa +dev/ipmi/ipmi_kcs.c optional ipmi +dev/ipmi/ipmi_smic.c optional ipmi +dev/ipmi/ipmi_smbus.c optional ipmi smbus +dev/ipmi/ipmi_smbios.c optional ipmi +dev/ipmi/ipmi_ssif.c optional ipmi smbus dev/ipmi/ipmi_pci.c optional ipmi pci dev/fdc/fdc.c optional fdc dev/fdc/fdc_acpi.c optional fdc ==== //depot/projects/jail2/sys/conf/files.i386#4 (text+ko) ==== @@ -1,7 +1,7 @@ # This file tells config what files go into building a kernel, # files marked standard are always included. # -# $FreeBSD: src/sys/conf/files.i386,v 1.565 2006/08/15 12:54:28 netchild Exp $ +# $FreeBSD: src/sys/conf/files.i386,v 1.566 2006/09/22 22:11:28 jhb Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -196,7 +196,13 @@ dev/if_ndis/if_ndis_usb.c optional ndis usb dev/io/iodev.c optional io dev/ipmi/ipmi.c optional ipmi -dev/ipmi/ipmi_smbios.c optional ipmi isa +dev/ipmi/ipmi_acpi.c optional ipmi acpi +dev/ipmi/ipmi_isa.c optional ipmi isa +dev/ipmi/ipmi_kcs.c optional ipmi +dev/ipmi/ipmi_smic.c optional ipmi +dev/ipmi/ipmi_smbus.c optional ipmi smbus +dev/ipmi/ipmi_smbios.c optional ipmi +dev/ipmi/ipmi_ssif.c optional ipmi smbus dev/ipmi/ipmi_pci.c optional ipmi pci dev/kbd/kbd.c optional atkbd | sc | ukbd | vt dev/le/if_le_isa.c optional le isa ==== //depot/projects/jail2/sys/dev/acpica/Osd/OsdHardware.c#2 (text+ko) ==== @@ -30,7 +30,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/acpica/Osd/OsdHardware.c,v 1.20 2006/04/04 02:22:38 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/Osd/OsdHardware.c,v 1.21 2006/09/24 09:39:17 hrs Exp $"); #include @@ -126,7 +126,9 @@ error = acpi_os_check_port(InPort, Width); if (error != 0) { - printf("acpi: bad read from port 0x%03x (%d)\n", (int)InPort, Width); + if (bootverbose) + printf("acpi: bad read from port 0x%03x (%d)\n", + (int)InPort, Width); if (error == -1) return (AE_BAD_PARAMETER); } @@ -159,8 +161,9 @@ error = acpi_os_check_port(OutPort, Width); if (error != 0) { - printf("acpi: bad write to port 0x%03x (%d), val %#x\n", (int)OutPort, - Width, Value); + if (bootverbose) + printf("acpi: bad write to port 0x%03x (%d), val %#x\n", + (int)OutPort, Width, Value); if (error == -1) return (AE_BAD_PARAMETER); } ==== //depot/projects/jail2/sys/dev/bge/if_bge.c#6 (text+ko) ==== @@ -32,7 +32,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/bge/if_bge.c,v 1.148 2006/09/18 22:18:21 jkim Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/bge/if_bge.c,v 1.149 2006/09/23 18:55:49 scottl Exp $"); /* * Broadcom BCM570x family gigabit ethernet driver for FreeBSD. @@ -79,6 +79,7 @@ #include #include #include +#include #include #include @@ -419,7 +420,16 @@ DRIVER_MODULE(miibus, bge, miibus_driver, miibus_devclass, 0, 0); static int bge_fake_autoneg = 0; +static int bge_allow_asf = 1; + TUNABLE_INT("hw.bge.fake_autoneg", &bge_fake_autoneg); +TUNABLE_INT("hw.bge.allow_asf", &bge_allow_asf); + +SYSCTL_NODE(_hw, OID_AUTO, bge, CTLFLAG_RD, 0, "BGE driver parameters"); +SYSCTL_INT(_hw_bge, OID_AUTO, fake_autoneg, CTLFLAG_RD, &bge_fake_autoneg, 0, + "Enable fake autonegotiation for certain blade systems"); +SYSCTL_INT(_hw_bge, OID_AUTO, allow_asf, CTLFLAG_RD, &bge_allow_asf, 0, + "Allow ASF mode if available"); static uint32_t bge_readmem_ind(struct bge_softc *sc, int off) @@ -2179,8 +2189,8 @@ } sc->bge_asf_mode = 0; - if (bge_readmem_ind(sc, BGE_SOFTWARE_GENCOMM_SIG) - == BGE_MAGIC_NUMBER) { + if (bge_allow_asf && (bge_readmem_ind(sc, BGE_SOFTWARE_GENCOMM_SIG) + == BGE_MAGIC_NUMBER)) { if (bge_readmem_ind(sc, BGE_SOFTWARE_GENCOMM_NICCFG) & BGE_HWCFG_ASF) { sc->bge_asf_mode |= ASF_ENABLE; ==== //depot/projects/jail2/sys/dev/exca/exca.c#2 (text+ko) ==== @@ -53,7 +53,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/exca/exca.c,v 1.24 2006/03/09 16:28:24 imp Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/exca/exca.c,v 1.25 2006/09/24 00:26:33 imp Exp $"); #include #include @@ -179,11 +179,7 @@ struct mem_map_index_st *map; struct pccard_mem_handle *mem; uint32_t offset; -#if 0 - int mem8 = (mem->kind == PCCARD_A_MEM_ATTR); -#else - int mem8 = 1; -#endif + int mem8 = 1 /* mem->kind == PCCARD_A_MEM_ATTR */; map = &mem_map_index[win]; mem = &sc->mem[win]; ==== //depot/projects/jail2/sys/dev/ipmi/ipmi.c#2 (text) ==== @@ -25,24 +25,21 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ipmi/ipmi.c,v 1.3 2006/05/16 14:36:26 phk Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ipmi/ipmi.c,v 1.4 2006/09/22 22:11:29 jhb Exp $"); #include #include +#include +#include +#include #include #include +#include #include +#include #include - -#include -#include -#include - -#include -#include -#include +#include #include -#include #ifdef LOCAL_MODULE #include @@ -52,29 +49,7 @@ #include #endif -struct ipmi_done_list { - u_char *data; - int channel; - int msgid; - int len; - TAILQ_ENTRY(ipmi_done_list) list; -}; - -#define MAX_TIMEOUT 3 * hz - -static int ipmi_wait_for_ibf(device_t, int); -static int ipmi_wait_for_obf(device_t, int); -static void ipmi_clear_obf(device_t, int); -static void ipmi_error(device_t); -static void ipmi_check_read(device_t); -static int ipmi_write(device_t, u_char *, int); -static void ipmi_wait_for_tx_okay(device_t); -static void ipmi_wait_for_rx_okay(device_t); -static void ipmi_wait_for_not_busy(device_t); -static void ipmi_set_busy(device_t); -static int ipmi_ready_to_read(device_t); #ifdef IPMB -static int ipmi_handle_attn(device_t dev); static int ipmi_ipmb_checksum(u_char, int); static int ipmi_ipmb_send_message(device_t, u_char, u_char, u_char, u_char, u_char, int) @@ -92,11 +67,10 @@ static int on = 1; SYSCTL_NODE(_hw, OID_AUTO, ipmi, CTLFLAG_RD, 0, "IPMI driver parameters"); SYSCTL_INT(_hw_ipmi, OID_AUTO, on, CTLFLAG_RW, - &on, 0, ""); + &on, 0, ""); static struct cdevsw ipmi_cdevsw = { .d_version = D_VERSION, - .d_flags = D_NEEDGIANT, .d_open = ipmi_open, .d_close = ipmi_close, .d_ioctl = ipmi_ioctl, @@ -106,60 +80,126 @@ MALLOC_DEFINE(M_IPMI, "ipmi", "ipmi"); -static int -ipmi_open(struct cdev *dev, int flags, int fmt, struct thread *td) +static int +ipmi_open(struct cdev *cdev, int flags, int fmt, struct thread *td) { + struct ipmi_device *dev; struct ipmi_softc *sc; if (!on) - return ENOENT; + return (ENOENT); - sc = dev->si_drv1; - if (sc->ipmi_refcnt) { - return EBUSY; + dev = cdev->si_drv1; + sc = dev->ipmi_softc; + IPMI_LOCK(sc); + if (dev->ipmi_open) { + IPMI_UNLOCK(sc); + return (EBUSY); } - sc->ipmi_refcnt = 1; + dev->ipmi_open = 1; + IPMI_UNLOCK(sc); - return 0; + return (0); } -static int -ipmi_poll(struct cdev *dev, int poll_events, struct thread *td) +static int +ipmi_poll(struct cdev *cdev, int poll_events, struct thread *td) { + struct ipmi_device *dev; struct ipmi_softc *sc; int revents = 0; - sc = dev->si_drv1; + dev = cdev->si_drv1; + sc = dev->ipmi_softc; - ipmi_check_read(sc->ipmi_dev); - + IPMI_LOCK(sc); if (poll_events & (POLLIN | POLLRDNORM)) { - if (!TAILQ_EMPTY(&sc->ipmi_done)) + if (!TAILQ_EMPTY(&dev->ipmi_completed_requests)) revents |= poll_events & (POLLIN | POLLRDNORM); - if (TAILQ_EMPTY(&sc->ipmi_done) && sc->ipmi_requests == 0) { + if (dev->ipmi_requests == 0) revents |= POLLERR; - } } if (revents == 0) { if (poll_events & (POLLIN | POLLRDNORM)) - selrecord(td, &sc->ipmi_select); + selrecord(td, &dev->ipmi_select); } + IPMI_UNLOCK(sc); + + return (revents); +} + +static void +ipmi_purge_completed_requests(struct ipmi_device *dev) +{ + struct ipmi_request *req; - return revents; + while (!TAILQ_EMPTY(&dev->ipmi_completed_requests)) { + req = TAILQ_FIRST(&dev->ipmi_completed_requests); + TAILQ_REMOVE(&dev->ipmi_completed_requests, req, ir_link); + dev->ipmi_requests--; + ipmi_free_request(req); + } } -static int -ipmi_close(struct cdev *dev, int flags, int fmt, struct thread *td) +static int +ipmi_close(struct cdev *cdev, int flags, int fmt, struct thread *td) { + struct ipmi_request *req, *nreq; + struct ipmi_device *dev; struct ipmi_softc *sc; - int error = 0; +#ifdef CLONING + int bit; +#endif + + dev = cdev->si_drv1; + sc = dev->ipmi_softc; + + IPMI_LOCK(sc); + if (dev->ipmi_requests) { + /* Throw away any pending requests for this device. */ + TAILQ_FOREACH_SAFE(req, &sc->ipmi_pending_requests, ir_link, + nreq) { + if (req->ir_owner == dev) { + TAILQ_REMOVE(&sc->ipmi_pending_requests, req, + ir_link); + dev->ipmi_requests--; + ipmi_free_request(req); + } + } + + /* Throw away any pending completed requests for this device. */ + ipmi_purge_completed_requests(dev); + + /* + * If we still have outstanding requests, they must be stuck + * in an interface driver, so wait for those to drain. + */ + dev->ipmi_closing = 1; + while (dev->ipmi_requests > 0) { + msleep(&dev->ipmi_requests, &sc->ipmi_lock, PWAIT, + "ipmidrain", 0); + ipmi_purge_completed_requests(dev); + } + } - sc = dev->si_drv1; +#ifdef CLONING + /* Detach this sub-device from the main driver. */ + bit = minor(cdev) % 32; + sc->ipmi_cdev_mask &= ~(1 << bit); + TAILQ_REMOVE(&sc->ipmi_cdevs, dev, ipmi_link); + IPMI_UNLOCK(sc); - sc->ipmi_refcnt = 0; + /* Cleanup. */ + cdev->si_drv1 = NULL; + free(dev, M_IPMI); + destroy_dev(cdev); +#else + dev->ipmi_open = 0; + IPMI_UNLOCK(sc); +#endif - return error; + return (0); } #ifdef IPMB @@ -171,707 +211,384 @@ for (; len; len--) { sum += *data++; } - return -sum; + return (-sum); } +/* XXX: Needs work */ static int ipmi_ipmb_send_message(device_t dev, u_char channel, u_char netfn, u_char command, u_char seq, u_char *data, int data_len) { - u_char *temp; struct ipmi_softc *sc = device_get_softc(dev); + struct ipmi_request *req; + u_char slave_addr = 0x52; int error; - u_char slave_addr = 0x52; - temp = malloc(data_len + 10, M_IPMI, M_WAITOK); - bzero(temp, data_len + 10); - temp[0] = IPMI_APP_REQUEST << 2; - temp[1] = IPMI_SEND_MSG; - temp[2] = channel; - temp[3] = slave_addr; - temp[4] = netfn << 2; - temp[5] = ipmi_ipmb_check_sum(&temp[3], 2); - temp[6] = sc->ipmi_address; - temp[7] = seq << 2 | sc->ipmi_lun; - temp[8] = command; + req = ipmi_alloc_driver_request(IPMI_ADDR(IPMI_APP_REQUEST, 0), + IPMI_SEND_MSG, data_len + 8, 0); + req->ir_request[0] = channel; + req->ir_request[1] = slave_addr; + req->ir_request[2] = IPMI_ADDR(netfn, 0); + req->ir_request[3] = ipmi_ipmb_checksum(&req->ir_request[1], 2); + req->ir_request[4] = sc->ipmi_address; + req->ir_request[5] = IPMI_ADDR(seq, sc->ipmi_lun); + req->ir_request[6] = command; - bcopy(data, &temp[9], data_len); - temp[data_len + 9] = ipmi_ipmb_check(&temp[6], data_len + 3); - ipmi_write(sc->ipmi_dev, temp, data_len + 9); - free(temp, M_IPMI); + bcopy(data, &req->ir_request[7], data_len); + temp[data_len + 7] = ipmi_ipmb_checksum(&req->ir_request[4], + data_len + 3); - while (!ipmi_ready_to_read(dev)) - DELAY(1000); - temp = malloc(IPMI_MAX_RX, M_IPMI, M_WAITOK); - bzero(temp, IPMI_MAX_RX); - error = ipmi_read(dev, temp, IPMI_MAX_RX); - free(temp, M_IPMI); + ipmi_submit_driver_request(sc, req); + error = req->ir_error; + ipmi_free_request(req); - return error; + return (error); } static int -ipmi_handle_attn(device_t dev) +ipmi_handle_attn(struct ipmi_softc *sc) { - u_char temp[IPMI_MAX_RX]; - struct ipmi_softc *sc = device_get_softc(dev); + struct ipmi_request *req; int error; device_printf(sc->ipmi_dev, "BMC has a message\n"); - temp[0] = IPMI_APP_REQUEST << 2; - temp[1] = IPMI_GET_MSG_FLAGS; - ipmi_write(sc->ipmi_dev, temp, 2); - while (!ipmi_ready_to_read(dev)) - DELAY(1000); - bzero(temp, IPMI_MAX_RX); - error = ipmi_read(dev, temp, IPMI_MAX_RX); + req = ipmi_alloc_driver_request(IPMI_ADDR(IPMI_APP_REQUEST, 0), + IPMI_GET_MSG_FLAGS, 0, 1); + + ipmi_submit_driver_request(sc, req); - if (temp[2] == 0) { - if (temp[3] & IPMI_MSG_BUFFER_FULL) { + if (req->ir_error == 0 && req->ir_compcode == 0) { + if (req->ir_reply[0] & IPMI_MSG_BUFFER_FULL) { device_printf(sc->ipmi_dev, "message buffer full"); } - if (temp[3] & IPMI_WDT_PRE_TIMEOUT) { + if (req->ir_reply[0] & IPMI_WDT_PRE_TIMEOUT) { device_printf(sc->ipmi_dev, "watchdog about to go off"); } - if (temp[3] & IPMI_MSG_AVAILABLE) { - temp[0] = IPMI_APP_REQUEST << 2; - temp[1] = IPMI_GET_MSG; - ipmi_write(sc->ipmi_dev, temp, 2); - while (!ipmi_ready_to_read(dev)) - DELAY(1000); - bzero(temp, IPMI_MAX_RX); - error = ipmi_read(dev, temp, IPMI_MAX_RX); + if (req->ir_reply[0] & IPMI_MSG_AVAILABLE) { + ipmi_free_request(req); + + req = ipmi_alloc_driver_request( + IPMI_ADDR(IPMI_APP_REQUEST, 0), IPMI_GET_MSG, 0, + 16); device_printf(sc->ipmi_dev, "throw out message "); dump_buf(temp, 16); } - } else - return -1; - return error; + } + error = req->ir_error; + ipmi_free_request(req); + + return (error); } #endif -static int -ipmi_ready_to_read(device_t dev) -{ - struct ipmi_softc *sc = device_get_softc(dev); - int status, flags; - - if (sc->ipmi_bios_info.smic_mode) { - flags = INB(sc, sc->ipmi_smic_flags); -#ifdef IPMB - if (flags & SMIC_STATUS_SMS_ATN) { - ipmi_handle_attn(dev); - return 0; - } -#endif - if (flags & SMIC_STATUS_RX_RDY) - return 1; - } else if (sc->ipmi_bios_info.kcs_mode) { - status = INB(sc, sc->ipmi_kcs_status_reg); -#ifdef IPMB - if (status & KCS_STATUS_SMS_ATN) { - ipmi_handle_attn(dev); - return 0; - } +#ifdef IPMICTL_SEND_COMMAND_32 +#define PTRIN(p) ((void *)(uintptr_t)(p)) +#define PTROUT(p) ((uintptr_t)(p)) #endif - if (status & KCS_STATUS_OBF) - return 1; - } else { - device_printf(dev,"Unsupported mode\n"); - } - - return 0; -} -void -ipmi_intr(void *arg) { - device_t dev = arg; - - ipmi_check_read(dev); -} - -static void -ipmi_check_read(device_t dev){ - struct ipmi_softc *sc = device_get_softc(dev); - struct ipmi_done_list *item; - int status; - u_char *temp; - - if (!sc->ipmi_requests) - return; - - untimeout((timeout_t *)ipmi_check_read, dev, sc->ipmi_timeout_handle); - - if(ipmi_ready_to_read(dev)) { - sc->ipmi_requests--; - temp = malloc(IPMI_MAX_RX, M_IPMI, M_WAITOK); - bzero(temp, IPMI_MAX_RX); - status = ipmi_read(dev, temp, IPMI_MAX_RX); - item = malloc(sizeof(struct ipmi_done_list), M_IPMI, M_WAITOK); - bzero(item, sizeof(struct ipmi_done_list)); - item->data = temp; - item->len = status; - if (ticks - sc->ipmi_timestamp > MAX_TIMEOUT) { - device_printf(dev, "read timeout when ready\n"); - TAILQ_INSERT_TAIL(&sc->ipmi_done, item, list); - selwakeup(&sc->ipmi_select); - } else if (status) { - TAILQ_INSERT_TAIL(&sc->ipmi_done, item, list); - selwakeup(&sc->ipmi_select); - } - } else { - if (ticks - sc->ipmi_timestamp > MAX_TIMEOUT) { - sc->ipmi_requests--; - device_printf(dev, "read timeout when not ready\n"); - temp = malloc(IPMI_MAX_RX, M_IPMI, M_WAITOK); - bzero(temp, IPMI_MAX_RX); - sc->ipmi_busy = 0; - wakeup(&sc->ipmi_busy); - status = -1; - item = malloc(sizeof(struct ipmi_done_list), - M_IPMI, M_WAITOK); - bzero(item, sizeof(struct ipmi_done_list)); - item->data = temp; - item->len = status; - TAILQ_INSERT_TAIL(&sc->ipmi_done, item, list); - selwakeup(&sc->ipmi_select); - } - } - if (sc->ipmi_requests) - sc->ipmi_timeout_handle - = timeout((timeout_t *)ipmi_check_read, dev, hz/30); -} - static int -ipmi_ioctl(struct cdev *dev __unused, u_long cmd, caddr_t data, +ipmi_ioctl(struct cdev *cdev, u_long cmd, caddr_t data, int flags, struct thread *td) { struct ipmi_softc *sc; + struct ipmi_device *dev; + struct ipmi_request *kreq; struct ipmi_req *req = (struct ipmi_req *)data; struct ipmi_recv *recv = (struct ipmi_recv *)data; struct ipmi_addr addr; - struct ipmi_done_list *item; - u_char *temp; +#ifdef IPMICTL_SEND_COMMAND_32 + struct ipmi_req32 *req32 = (struct ipmi_req32 *)data; + struct ipmi_recv32 *recv32 = (struct ipmi_recv32 *)data; + union { + struct ipmi_req req; + struct ipmi_recv recv; + } thunk32; +#endif int error, len; - sc = dev->si_drv1; + dev = cdev->si_drv1; + sc = dev->ipmi_softc; + +#ifdef IPMICTL_SEND_COMMAND_32 + /* Convert 32-bit structures to native. */ + switch (cmd) { + case IPMICTL_SEND_COMMAND_32: + req = &thunk32.req; + req->addr = PTRIN(req32->addr); + req->addr_len = req32->addr_len; + req->msgid = req32->msgid; + req->msg.netfn = req32->msg.netfn; + req->msg.cmd = req32->msg.cmd; + req->msg.data_len = req32->msg.data_len; + req->msg.data = PTRIN(req32->msg.data); + break; + case IPMICTL_RECEIVE_MSG_TRUNC_32: + case IPMICTL_RECEIVE_MSG_32: + recv = &thunk32.recv; + recv->addr = PTRIN(recv32->addr); + recv->addr_len = recv32->addr_len; + recv->msg.data_len = recv32->msg.data_len; + recv->msg.data = PTRIN(recv32->msg.data); + break; + } +#endif switch (cmd) { +#ifdef IPMICTL_SEND_COMMAND_32 + case IPMICTL_SEND_COMMAND_32: +#endif case IPMICTL_SEND_COMMAND: + /* + * XXX: Need to add proper handling of this. >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Sun Sep 24 15:36:03 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1E79716A40F; Sun, 24 Sep 2006 15:36:03 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 C807616A415 for ; Sun, 24 Sep 2006 15:36:02 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9304343D45 for ; Sun, 24 Sep 2006 15:36:02 +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.6/8.13.6) with ESMTP id k8OFa2UI036499 for ; Sun, 24 Sep 2006 15:36:02 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OFa2vf036496 for perforce@freebsd.org; Sun, 24 Sep 2006 15:36:02 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 15:36:02 GMT Message-Id: <200609241536.k8OFa2vf036496@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 Cc: Subject: PERFORCE change 106602 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 15:36:03 -0000 http://perforce.freebsd.org/chv.cgi?CH=106602 Change 106602 by rwatson@rwatson_peppercorn on 2006/09/24 15:35:32 Remove audit_warn todo item for generating an event on rotate, it's done; add one for documenting the list of events audit_warn will see. Affected files ... .. //depot/projects/trustedbsd/openbsm/TODO#8 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/TODO#8 (text+ko) ==== @@ -17,10 +17,7 @@ just at the beginning of a record. This will make it easier to use praudit in test suites processing single-token files without header and trailer context. -- Teach auditd how to notify a script when it is done with trail files so - that the script can archive them, compress them, delete them, whatever. - It should walk any trail files found at startup also, assuming it - successfully registers. - Put hostname in trail file name. +- Document audit_warn event arguments. -$P4: //depot/projects/trustedbsd/openbsm/TODO#7 $ +$P4: //depot/projects/trustedbsd/openbsm/TODO#8 $ From owner-p4-projects@FreeBSD.ORG Sun Sep 24 15:37:05 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1146516A40F; Sun, 24 Sep 2006 15:37:05 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 E183116A417 for ; Sun, 24 Sep 2006 15:37:04 +0000 (UTC) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7598D43D45 for ; Sun, 24 Sep 2006 15:37:04 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8OFb4N7036651 for ; Sun, 24 Sep 2006 15:37:04 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OFb4MB036648 for perforce@freebsd.org; Sun, 24 Sep 2006 15:37:04 GMT (envelope-from csjp@freebsd.org) Date: Sun, 24 Sep 2006 15:37:04 GMT Message-Id: <200609241537.k8OFb4MB036648@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 Cc: Subject: PERFORCE change 106603 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 15:37:05 -0000 http://perforce.freebsd.org/chv.cgi?CH=106603 Change 106603 by csjp@csjp_xor on 2006/09/24 15:36:33 Add support for regular expression based pathname matching. This should be functionally equivalent to how the Solaris auditreduce handles things. Affected files ... .. //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.1#12 edit .. //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#17 edit .. //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.h#5 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.1#12 (text+ko) ==== @@ -25,7 +25,7 @@ .\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.1#11 $ +.\" $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.1#12 $ .\" .Dd January 24, 2004 .Dt AUDITREDUCE 1 @@ -105,12 +105,17 @@ .It Fl o Ar object=value .Bl -tag -width Ds .It Nm file -Select records containing the given path name. -file="/usr" matches paths -starting with -.Pa usr . -file="~/usr" matches paths not starting with -.Pa usr . +Select records containing path tokens, where the pathname matches +one of the comma delimited extended regular expression contained in +given specification. +Regular expressions which are prefixed with a tilde (~) are excluded +from the search results. +These extended regular expressions are processed from left to right, +and a path will either be selected or deslected based on the first match. +.Pp +Since commas are used to delimit the regular expressions, a backslash (\\) +character should be used to escape the comma if it's a part of the search +pattern. .It Nm msgqid Select records containing the given message queue id. .It Nm pid @@ -141,6 +146,25 @@ file, or via standard output to the .Xr praudit 1 command. +.Pp +Select all records containing a path token where the pathname contains +.Pa /etc/master.passwd +.Pp +.Nm +-ofile="/etc/master.passwd" /var/audit/20031016184719.20031017122634 +.Pp +Select all records containing path tokens, where the pathname is a TTY +device: +.Pp +.Nm +-ofile="/dev/tty[a-zA-Z][0-9]+" /var/audit/20031016184719.20031017122634 +.Pp +Select all records containing path tokens, where the pathname is a TTY +except for +.Pa /dev/ttyp2 +.Pp +.Nm +-ofile="~/dev/ttyp2,/dev/tty[a-zA-Z][0-9]+" /var/audit/20031016184719.20031017122634 .Sh SEE ALSO .Xr praudit 1 , .Xr audit_control 5 , ==== //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#17 (text+ko) ==== @@ -26,7 +26,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#16 $ + * $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#17 $ */ /* @@ -40,6 +40,7 @@ * XXX the records present within the file and between the files themselves */ +#include #include #include @@ -51,9 +52,14 @@ #include #include #include +#include +#include #include "auditreduce.h" +static TAILQ_HEAD(tailhead, re_entry) re_head = + TAILQ_HEAD_INITIALIZER(re_head); + extern char *optarg; extern int optind, optopt, opterr,optreset; @@ -81,6 +87,53 @@ static uint32_t opttochk = 0; static void +parse_regexp(char *re_string) +{ + char *orig, *copy, re_error[64]; + struct re_entry *rep; + int error, nstrs, i, len; + + copy = strdup(re_string); + orig = copy; + len = strlen(copy); + for (nstrs = 0, i = 0; i < len; i++) { + if (copy[i] == ',' && i > 0) { + if (copy[i - 1] == '\\') + strcpy(©[i - 1], ©[i]); + else { + nstrs++; + copy[i] = '\0'; + } + } + } + TAILQ_INIT(&re_head); + for (i = 0; i < nstrs + 1; i++) { + rep = calloc(1, sizeof(*rep)); + if (rep == NULL) { + (void) fprintf(stderr, "calloc: %s\n", + strerror(errno)); + exit(1); + } + if (*copy == '~') { + copy++; + rep->re_negate = 1; + } + rep->re_pattern = strdup(copy); + error = regcomp(&rep->re_regexp, rep->re_pattern, + REG_EXTENDED | REG_NOSUB); + if (error != 0) { + regerror(error, &rep->re_regexp, re_error, 64); + (void) fprintf(stderr, "regcomp: %s\n", re_error); + exit(1); + } + TAILQ_INSERT_TAIL(&re_head, rep, re_glue); + len = strlen(copy); + copy += len + 1; + } + free(orig); +} + +static void usage(const char *msg) { fprintf(stderr, "%s\n", msg); @@ -258,23 +311,20 @@ static int select_filepath(char *path, uint32_t *optchkd) { - char *loc; + struct re_entry *rep; + int match; SETOPT((*optchkd), OPT_of); + match = 1; if (ISOPTSET(opttochk, OPT_of)) { - if (p_fileobj[0] == '~') { - /* Object should not be in path. */ - loc = strstr(path, p_fileobj + 1); - if ((loc != NULL) && (loc == path)) - return (0); - } else { - /* Object should be in path. */ - loc = strstr(path, p_fileobj); - if ((loc == NULL) || (loc != path)) - return (0); + match = 0; + TAILQ_FOREACH(rep, &re_head, re_glue) { + if (regexec(&rep->re_regexp, path, 0, NULL, + 0) != REG_NOMATCH) + return (!rep->re_negate); } } - return (1); + return (match); } /* @@ -525,6 +575,7 @@ if (!strcmp(name, FILEOBJ)) { p_fileobj = val; + parse_regexp(val); SETOPT(opttochk, OPT_of); } else if (!strcmp(name, MSGQIDOBJ)) { p_msgqobj = val; ==== //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.h#5 (text+ko) ==== @@ -26,13 +26,20 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.h#4 $ + * $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.h#5 $ */ #ifndef _AUDITREDUCE_H_ #define _AUDITREDUCE_H_ +struct re_entry { + char *re_pattern; + int re_negate; + regex_t re_regexp; + TAILQ_ENTRY(re_entry) re_glue; +}; + #define OPT_a 0x00000001 #define OPT_b 0x00000002 #define OPT_c 0x00000004 From owner-p4-projects@FreeBSD.ORG Sun Sep 24 15:41:10 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 442F616A40F; Sun, 24 Sep 2006 15:41:10 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 07B1E16A407 for ; Sun, 24 Sep 2006 15:41:10 +0000 (UTC) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C8CBB43D49 for ; Sun, 24 Sep 2006 15:41:09 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8OFf933036912 for ; Sun, 24 Sep 2006 15:41:09 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OFf9SL036909 for perforce@freebsd.org; Sun, 24 Sep 2006 15:41:09 GMT (envelope-from csjp@freebsd.org) Date: Sun, 24 Sep 2006 15:41:09 GMT Message-Id: <200609241541.k8OFf9SL036909@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 Cc: Subject: PERFORCE change 106604 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 15:41:10 -0000 http://perforce.freebsd.org/chv.cgi?CH=106604 Change 106604 by csjp@csjp_xor on 2006/09/24 15:41:03 Update HISTORY with the new auditreduce pathname functionality. Affected files ... .. //depot/projects/trustedbsd/openbsm/HISTORY#38 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/HISTORY#38 (text+ko) ==== @@ -11,6 +11,10 @@ line; this was the documented behavior previously, but it was not implemented. Be more specific in auditreduce(1)'s examples section about what might be done with the output of auditreduce. +- auditreduce(1) now uses regular expressions for pathname matching. Users can + now supply one or more (comma delimited) regular expressions for searching + the pathnames. If one of the regular expressions is prefixed with a tilde + (~), and a path matches, it will be excluded from the search results. OpenBSM 1.0 alpha 11 @@ -257,4 +261,4 @@ to support reloading of kernel event table. - Allow comments in /etc/security configuration files. -$P4: //depot/projects/trustedbsd/openbsm/HISTORY#37 $ +$P4: //depot/projects/trustedbsd/openbsm/HISTORY#38 $ From owner-p4-projects@FreeBSD.ORG Sun Sep 24 15:46:17 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id F270416A417; Sun, 24 Sep 2006 15:46:16 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 C564116A403 for ; Sun, 24 Sep 2006 15:46:16 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 902AB43D4C for ; Sun, 24 Sep 2006 15:46:16 +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.6/8.13.6) with ESMTP id k8OFkG9I037362 for ; Sun, 24 Sep 2006 15:46:16 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OFkGDq037359 for perforce@freebsd.org; Sun, 24 Sep 2006 15:46:16 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 15:46:16 GMT Message-Id: <200609241546.k8OFkGDq037359@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 Cc: Subject: PERFORCE change 106605 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 15:46:17 -0000 http://perforce.freebsd.org/chv.cgi?CH=106605 Change 106605 by rwatson@rwatson_lethe on 2006/09/24 15:45:34 Use config.h to determine which queue.h to include; this allows auditreduce's regexp code to compile on Linux again. Affected files ... .. //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#18 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#18 (text+ko) ==== @@ -26,7 +26,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#17 $ + * $P4: //depot/projects/trustedbsd/openbsm/bin/auditreduce/auditreduce.c#18 $ */ /* @@ -40,7 +40,13 @@ * XXX the records present within the file and between the files themselves */ +#include +#ifdef HAVE_FULL_QUEUE_H #include +#else +#include +#endif + #include #include From owner-p4-projects@FreeBSD.ORG Sun Sep 24 18:19:31 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 5DE1616A415; Sun, 24 Sep 2006 18:19:31 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 205B516A40F for ; Sun, 24 Sep 2006 18:19:31 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id DD17B43D58 for ; Sun, 24 Sep 2006 18:19: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.6/8.13.6) with ESMTP id k8OIJUr2056632 for ; Sun, 24 Sep 2006 18:19:30 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OIJUQv056629 for perforce@freebsd.org; Sun, 24 Sep 2006 18:19:30 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 18:19:30 GMT Message-Id: <200609241819.k8OIJUQv056629@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 Cc: Subject: PERFORCE change 106609 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 18:19:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=106609 Change 106609 by rwatson@rwatson_fledge on 2006/09/24 18:19:09 Add history item about new audit_warn event. Affected files ... .. //depot/projects/trustedbsd/openbsm/HISTORY#39 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/HISTORY#39 (text+ko) ==== @@ -11,6 +11,9 @@ line; this was the documented behavior previously, but it was not implemented. Be more specific in auditreduce(1)'s examples section about what might be done with the output of auditreduce. +- Add audit_warn(5) closefile event so that administrators can hook + termination of an audit trail file. For example, this might be used to + compress the trail file after it is closed. - auditreduce(1) now uses regular expressions for pathname matching. Users can now supply one or more (comma delimited) regular expressions for searching the pathnames. If one of the regular expressions is prefixed with a tilde @@ -261,4 +264,4 @@ to support reloading of kernel event table. - Allow comments in /etc/security configuration files. -$P4: //depot/projects/trustedbsd/openbsm/HISTORY#38 $ +$P4: //depot/projects/trustedbsd/openbsm/HISTORY#39 $ From owner-p4-projects@FreeBSD.ORG Sun Sep 24 19:23:55 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2CACC16A415; Sun, 24 Sep 2006 19:23:55 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 01D1A16A40F for ; Sun, 24 Sep 2006 19:23:55 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id A815143D46 for ; Sun, 24 Sep 2006 19:23:54 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8OJNsd4062951 for ; Sun, 24 Sep 2006 19:23:54 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OJNs6Q062948 for perforce@freebsd.org; Sun, 24 Sep 2006 19:23:54 GMT (envelope-from mjacob@freebsd.org) Date: Sun, 24 Sep 2006 19:23:54 GMT Message-Id: <200609241923.k8OJNs6Q062948@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106612 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 19:23:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=106612 Change 106612 by mjacob@newisp on 2006/09/24 19:23:24 Fix compile errors at least. Affected files ... .. //depot/projects/newisp/dev/isp/isp_sbus.c#4 edit Differences ... ==== //depot/projects/newisp/dev/isp/isp_sbus.c#4 (text+ko) ==== @@ -51,8 +51,10 @@ #include -static uint32_t isp_sbus_rd_reg(ispsoftc_t *, int); -static void isp_sbus_wr_reg(ispsoftc_t *, int, uint32_t); +static uint32_t +isp_sbus_rd_reg(ispsoftc_t *, int); +static void +isp_sbus_wr_reg(ispsoftc_t *, int, uint32_t); static int isp_sbus_rd_isr(ispsoftc_t *, uint32_t *, uint32_t *, uint32_t *); static int isp_sbus_mbxdma(ispsoftc_t *); @@ -394,7 +396,7 @@ isp_sbus_intr(void *arg) { ispsoftc_t *isp = arg; - uint16_t isr, sema, mbox; + uint32_t isr, sema, mbox; ISP_LOCK(isp); isp->isp_intcnt++; @@ -417,8 +419,7 @@ bus_space_read_2(sbc->sbus_st, sbc->sbus_sh, off) static int -isp_sbus_rd_isr(ispsoftc_t *isp, uint16_t *isrp, - uint16_t *semap, uint16_t *mbp) +isp_sbus_rd_isr(ispsoftc_t *isp, uint32_t *isrp, uint32_t *semap, uint32_t *mbp) { struct isp_sbussoftc *sbc = (struct isp_sbussoftc *) isp; uint16_t isr, sema; @@ -438,7 +439,7 @@ return (1); } -static uint16_t +static uint32_t isp_sbus_rd_reg(ispsoftc_t *isp, int regoff) { uint16_t rval; @@ -452,7 +453,7 @@ } static void -isp_sbus_wr_reg(ispsoftc_t *isp, int regoff, uint16_t val) +isp_sbus_wr_reg(ispsoftc_t *isp, int regoff, uint32_t val) { struct isp_sbussoftc *sbs = (struct isp_sbussoftc *) isp; int offset = sbs->sbus_poff[(regoff & _BLK_REG_MASK) >> _BLK_REG_SHFT]; @@ -605,8 +606,8 @@ ispsoftc_t *isp; void *cmd_token; void *rq; - uint16_t *nxtip; - uint16_t optr; + uint32_t *nxtip; + uint32_t optr; int error; } mush_t; @@ -721,7 +722,7 @@ static int isp_sbus_dmasetup(ispsoftc_t *isp, struct ccb_scsiio *csio, ispreq_t *rq, - uint16_t *nxtip, uint16_t optr) + uint32_t *nxtip, uint32_t optr) { struct isp_sbussoftc *sbs = (struct isp_sbussoftc *)isp; ispreq_t *qep; @@ -822,7 +823,7 @@ } static void -isp_sbus_dmateardown(ispsoftc_t *isp, XS_T *xs, uint16_t handle) +isp_sbus_dmateardown(ispsoftc_t *isp, XS_T *xs, uint32_t handle) { struct isp_sbussoftc *sbs = (struct isp_sbussoftc *)isp; bus_dmamap_t *dp = &sbs->dmaps[isp_handle_index(handle)]; From owner-p4-projects@FreeBSD.ORG Sun Sep 24 20:28:17 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 86AC016A415; Sun, 24 Sep 2006 20:28:17 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 3B2D316A403 for ; Sun, 24 Sep 2006 20:28:17 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 01C0943D4C for ; Sun, 24 Sep 2006 20:28: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.6/8.13.6) with ESMTP id k8OKSGEa067658 for ; Sun, 24 Sep 2006 20:28:16 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OKSGWp067655 for perforce@freebsd.org; Sun, 24 Sep 2006 20:28:16 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 20:28:16 GMT Message-Id: <200609242028.k8OKSGWp067655@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 Cc: Subject: PERFORCE change 106616 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 20:28:17 -0000 http://perforce.freebsd.org/chv.cgi?CH=106616 Change 106616 by rwatson@rwatson_fledge on 2006/09/24 20:27:29 OpenBSM 1.0 alpha 12 on the web site. Affected files ... .. //depot/projects/trustedbsd/www/downloads/openbsm-1.0-alpha12.tgz#1 add .. //depot/projects/trustedbsd/www/openbsm.page#17 edit Differences ... ==== //depot/projects/trustedbsd/www/openbsm.page#17 (text+ko) ==== @@ -29,7 +29,7 @@ - $P4: //depot/projects/trustedbsd/www/openbsm.page#16 $ + $P4: //depot/projects/trustedbsd/www/openbsm.page#17 $ @@ -120,6 +120,17 @@ Please see the file README present in the OpenBSM distribution for build and installation instructions.

+

2006-09-24 - OpenBSM 1.0 alpha 12 release is a test release of the + OpenBSM code base, and matches what is present in FreeBSD CVS at + this date. + In this revision, an audit_control(5) filesz configuration + parameter is added in order to support automated rotation of audit + trails based on file size, regular expression matching for paths is + added to auditreduce, an audit_warn event is generated on rotation, + and a number of other bug fixes and documentation improvements are + present. + Download (480K).

+

2006-09-20 - OpenBSM 1.0 alpha 11 release is a test release of the OpenBSM code base, and matches what is present in FreeBSD CVS at this date. From owner-p4-projects@FreeBSD.ORG Sun Sep 24 20:31:26 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id CD45516A47E; Sun, 24 Sep 2006 20:31:25 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 8ABA716A407 for ; Sun, 24 Sep 2006 20:31:25 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 369F943D6D for ; Sun, 24 Sep 2006 20:31:22 +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.6/8.13.6) with ESMTP id k8OKVM69067855 for ; Sun, 24 Sep 2006 20:31:22 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OKVL4X067852 for perforce@freebsd.org; Sun, 24 Sep 2006 20:31:21 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 20:31:21 GMT Message-Id: <200609242031.k8OKVL4X067852@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 Cc: Subject: PERFORCE change 106617 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 20:31:26 -0000 http://perforce.freebsd.org/chv.cgi?CH=106617 Change 106617 by rwatson@rwatson_zoo on 2006/09/24 20:30:27 Integrate OpenBSM 1.0 alpha 12 into TrustedBSD audit3 branch. Affected files ... .. //depot/projects/trustedbsd/audit3/contrib/openbsm/HISTORY#16 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/TODO#11 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/VERSION#14 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/audit_warn.c#5 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.c#16 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.h#5 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.1#8 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.c#9 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.h#4 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bsm/libbsm.h#19 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/configure#14 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/configure.ac#15 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_control#7 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_event#17 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/au_control.3#6 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/bsm_control.c#11 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/libbsm.3#9 integrate .. //depot/projects/trustedbsd/audit3/contrib/openbsm/man/audit_control.5#9 integrate .. //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#29 integrate Differences ... ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/HISTORY#16 (text+ko) ==== @@ -1,3 +1,24 @@ +OpenBSM 1.0 alpha 12 + +- Correct bug in auditreduce which prevented the -c option from working + correctly when the user specifies to process successful or failed events. + The problem stemmed from not having access to the return token at the time + the initial preselection occurred, but now a second preselection process + occurs while processing the return token. +- getacfilesz(3) API added to read new audit_control(5) filesz setting, + which auditd(8) now sets the kernel audit trail rotation size to. +- auditreduce(1) now uses stdin if no file names are specified on the command + line; this was the documented behavior previously, but it was not + implemented. Be more specific in auditreduce(1)'s examples section about + what might be done with the output of auditreduce. +- Add audit_warn(5) closefile event so that administrators can hook + termination of an audit trail file. For example, this might be used to + compress the trail file after it is closed. +- auditreduce(1) now uses regular expressions for pathname matching. Users can + now supply one or more (comma delimited) regular expressions for searching + the pathnames. If one of the regular expressions is prefixed with a tilde + (~), and a path matches, it will be excluded from the search results. + OpenBSM 1.0 alpha 11 - Reclassify certain read/write operations as having no class rather than the @@ -243,4 +264,4 @@ to support reloading of kernel event table. - Allow comments in /etc/security configuration files. -$P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/HISTORY#15 $ +$P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/HISTORY#16 $ ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/TODO#11 (text+ko) ==== @@ -17,10 +17,7 @@ just at the beginning of a record. This will make it easier to use praudit in test suites processing single-token files without header and trailer context. -- Teach auditd how to notify a script when it is done with trail files so - that the script can archive them, compress them, delete them, whatever. - It should walk any trail files found at startup also, assuming it - successfully registers. - Put hostname in trail file name. +- Document audit_warn event arguments. -$P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/TODO#10 $ +$P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/TODO#11 $ ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/VERSION#14 (text+ko) ==== @@ -1,1 +1,1 @@ -OPENBSM_1_0_ALPHA_11 +OPENBSM_1_0_ALPHA_12 ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/audit_warn.c#5 (text+ko) ==== @@ -30,7 +30,7 @@ * * @APPLE_BSD_LICENSE_HEADER_END@ * - * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/audit_warn.c#4 $ + * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/audit_warn.c#5 $ */ #include @@ -125,6 +125,21 @@ } /* + * Indicate that a trail file has been closed, so can now be post-processed. + */ +int +audit_warn_closefile(char *filename) +{ + char *args[3]; + + args[0] = CLOSEFILE_WARN; + args[1] = filename; + args[2] = NULL; + + return (auditwarnlog(args)); +} + +/* * Indicates that the audit deammn is already running */ int ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.c#16 (text+ko) ==== @@ -30,7 +30,7 @@ * * @APPLE_BSD_LICENSE_HEADER_END@ * - * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.c#15 $ + * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.c#16 $ */ #include @@ -163,9 +163,11 @@ syslog(LOG_ERR, "Could not rename %s to %s: %m", oldname, lastfile); - else + else { syslog(LOG_INFO, "renamed %s to %s", oldname, lastfile); + audit_warn_closefile(lastfile); + } } free(lastfile); free(oldname); @@ -727,6 +729,8 @@ char naeventstr[NA_EVENT_STR_SIZE]; char polstr[POL_STR_SIZE]; long policy; + au_fstat_t au_fstat; + size_t filesz; /* * Process the audit event file, obtaining a class mapping for each @@ -806,6 +810,17 @@ "Failed to set default audit policy: %m"); } + /* + * Set trail rotation size. + */ + if (getacfilesz(&filesz) == 0) { + bzero(&au_fstat, sizeof(au_fstat)); + au_fstat.af_filesz = filesz; + if (auditon(A_SETFSIZE, &au_fstat, sizeof(au_fstat)) < 0) + syslog(LOG_ERR, "Failed to set filesz: %m"); + } else + syslog(LOG_ERR, "Failed to obtain filesz: %m"); + return (0); } ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.h#5 (text+ko) ==== @@ -30,7 +30,7 @@ * * @APPLE_BSD_LICENSE_HEADER_END@ * - * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.h#4 $ + * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditd/auditd.h#5 $ */ #ifndef _AUDITD_H_ @@ -62,6 +62,7 @@ #define HARDLIM_ALL_WARN "allhard" #define SOFTLIM_ALL_WARN "allsoft" #define AUDITOFF_WARN "auditoff" +#define CLOSEFILE_WARN "closefile" #define EBUSY_WARN "ebusy" #define GETACDIR_WARN "getacdir" #define HARDLIM_WARN "hard" @@ -76,6 +77,7 @@ int audit_warn_allhard(int count); int audit_warn_allsoft(void); int audit_warn_auditoff(void); +int audit_warn_closefile(char *filename); int audit_warn_ebusy(void); int audit_warn_getacdir(char *filename); int audit_warn_hard(char *filename); ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.1#8 (text+ko) ==== @@ -25,7 +25,7 @@ .\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.1#7 $ +.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.1#8 $ .\" .Dd January 24, 2004 .Dt AUDITREDUCE 1 @@ -105,12 +105,17 @@ .It Fl o Ar object=value .Bl -tag -width Ds .It Nm file -Select records containing the given path name. -file="/usr" matches paths -starting with -.Pa usr . -file="~/usr" matches paths not starting with -.Pa usr . +Select records containing path tokens, where the pathname matches +one of the comma delimited extended regular expression contained in +given specification. +Regular expressions which are prefixed with a tilde (~) are excluded +from the search results. +These extended regular expressions are processed from left to right, +and a path will either be selected or deslected based on the first match. +.Pp +Since commas are used to delimit the regular expressions, a backslash (\\) +character should be used to escape the comma if it's a part of the search +pattern. .It Nm msgqid Select records containing the given message queue id. .It Nm pid @@ -136,6 +141,30 @@ .Pp .Nm -m AUE_SETLOGIN /var/audit/20031016184719.20031017122634 +.Pp +Output from the above command lines will typically be piped to a new trail +file, or via standard output to the +.Xr praudit 1 +command. +.Pp +Select all records containing a path token where the pathname contains +.Pa /etc/master.passwd +.Pp +.Nm +-ofile="/etc/master.passwd" /var/audit/20031016184719.20031017122634 +.Pp +Select all records containing path tokens, where the pathname is a TTY +device: +.Pp +.Nm +-ofile="/dev/tty[a-zA-Z][0-9]+" /var/audit/20031016184719.20031017122634 +.Pp +Select all records containing path tokens, where the pathname is a TTY +except for +.Pa /dev/ttyp2 +.Pp +.Nm +-ofile="~/dev/ttyp2,/dev/tty[a-zA-Z][0-9]+" /var/audit/20031016184719.20031017122634 .Sh SEE ALSO .Xr praudit 1 , .Xr audit_control 5 , ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.c#9 (text+ko) ==== @@ -26,7 +26,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.c#8 $ + * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.c#9 $ */ /* @@ -40,6 +40,13 @@ * XXX the records present within the file and between the files themselves */ +#include +#ifdef HAVE_FULL_QUEUE_H +#include +#else +#include +#endif + #include #include @@ -51,9 +58,14 @@ #include #include #include +#include +#include #include "auditreduce.h" +static TAILQ_HEAD(tailhead, re_entry) re_head = + TAILQ_HEAD_INITIALIZER(re_head); + extern char *optarg; extern int optind, optopt, opterr,optreset; @@ -81,10 +93,57 @@ static uint32_t opttochk = 0; static void +parse_regexp(char *re_string) +{ + char *orig, *copy, re_error[64]; + struct re_entry *rep; + int error, nstrs, i, len; + + copy = strdup(re_string); + orig = copy; + len = strlen(copy); + for (nstrs = 0, i = 0; i < len; i++) { + if (copy[i] == ',' && i > 0) { + if (copy[i - 1] == '\\') + strcpy(©[i - 1], ©[i]); + else { + nstrs++; + copy[i] = '\0'; + } + } + } + TAILQ_INIT(&re_head); + for (i = 0; i < nstrs + 1; i++) { + rep = calloc(1, sizeof(*rep)); + if (rep == NULL) { + (void) fprintf(stderr, "calloc: %s\n", + strerror(errno)); + exit(1); + } + if (*copy == '~') { + copy++; + rep->re_negate = 1; + } + rep->re_pattern = strdup(copy); + error = regcomp(&rep->re_regexp, rep->re_pattern, + REG_EXTENDED | REG_NOSUB); + if (error != 0) { + regerror(error, &rep->re_regexp, re_error, 64); + (void) fprintf(stderr, "regcomp: %s\n", re_error); + exit(1); + } + TAILQ_INSERT_TAIL(&re_head, rep, re_glue); + len = strlen(copy); + copy += len + 1; + } + free(orig); +} + +static void usage(const char *msg) { fprintf(stderr, "%s\n", msg); - fprintf(stderr, "Usage: auditreduce [options] audit-trail-file [....] \n"); + fprintf(stderr, "Usage: auditreduce [options] [file ...]\n"); fprintf(stderr, "\tOptions are : \n"); fprintf(stderr, "\t-A : all records\n"); fprintf(stderr, "\t-a YYYYMMDD[HH[[MM[SS]]] : after date\n"); @@ -258,23 +317,20 @@ static int select_filepath(char *path, uint32_t *optchkd) { - char *loc; + struct re_entry *rep; + int match; SETOPT((*optchkd), OPT_of); + match = 1; if (ISOPTSET(opttochk, OPT_of)) { - if (p_fileobj[0] == '~') { - /* Object should not be in path. */ - loc = strstr(path, p_fileobj + 1); - if ((loc != NULL) && (loc == path)) - return (0); - } else { - /* Object should be in path. */ - loc = strstr(path, p_fileobj); - if ((loc == NULL) || (loc != path)) - return (0); + match = 0; + TAILQ_FOREACH(rep, &re_head, re_glue) { + if (regexec(&rep->re_regexp, path, 0, NULL, + 0) != REG_NOMATCH) + return (!rep->re_negate); } } - return (1); + return (match); } /* @@ -328,6 +384,24 @@ return (1); } +static int +select_return32(tokenstr_t tok_ret32, tokenstr_t tok_hdr32, uint32_t *optchkd) +{ + int sorf; + + SETOPT((*optchkd), (OPT_c)); + if (tok_ret32.tt.ret32.status == 0) + sorf = AU_PRS_SUCCESS; + else + sorf = AU_PRS_FAILURE; + if (ISOPTSET(opttochk, OPT_c)) { + if (au_preselect(tok_hdr32.tt.hdr32.e_type, &maskp, sorf, + AU_PRS_USECACHE) != 1) + return (0); + } + return (1); +} + /* * Return 1 if checks for the the following succeed * auid, @@ -395,6 +469,7 @@ static int select_records(FILE *fp) { + tokenstr_t tok_hdr32_copy; u_char *buf; tokenstr_t tok; int reclen; @@ -423,6 +498,8 @@ case AU_HEADER_32_TOKEN: selected = select_hdr32(tok, &optchkd); + bcopy(&tok, &tok_hdr32_copy, + sizeof(tok)); break; case AU_PROCESS_32_TOKEN: @@ -451,6 +528,11 @@ tok.tt.path.path, &optchkd); break; + case AU_RETURN_32_TOKEN: + selected = select_return32(tok, + tok_hdr32_copy, &optchkd); + break; + /* * The following tokens dont have any relevant * attributes that we can select upon. @@ -465,7 +547,6 @@ case AU_IPCPERM_TOKEN: case AU_IPORT_TOKEN: case AU_OPAQUE_TOKEN: - case AU_RETURN_32_TOKEN: case AU_SEQ_TOKEN: case AU_TEXT_TOKEN: case AU_ARB_TOKEN: @@ -500,6 +581,7 @@ if (!strcmp(name, FILEOBJ)) { p_fileobj = val; + parse_regexp(val); SETOPT(opttochk, OPT_of); } else if (!strcmp(name, MSGQIDOBJ)) { p_msgqobj = val; @@ -679,8 +761,12 @@ argv += optind; argc -= optind; - if (argc == 0) - usage("Filename needed"); + if (argc == 0) { + if (select_records(stdin) == -1) + errx(EXIT_FAILURE, + "Couldn't select records from stdin"); + exit(EXIT_SUCCESS); + } /* * XXX: We should actually be merging records here. ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.h#4 (text+ko) ==== @@ -26,13 +26,20 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.h#3 $ + * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bin/auditreduce/auditreduce.h#4 $ */ #ifndef _AUDITREDUCE_H_ #define _AUDITREDUCE_H_ +struct re_entry { + char *re_pattern; + int re_negate; + regex_t re_regexp; + TAILQ_ENTRY(re_entry) re_glue; +}; + #define OPT_a 0x00000001 #define OPT_b 0x00000002 #define OPT_c 0x00000004 ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/bsm/libbsm.h#19 (text+ko) ==== @@ -26,7 +26,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bsm/libbsm.h#18 $ + * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/bsm/libbsm.h#19 $ */ #ifndef _LIBBSM_H_ @@ -78,6 +78,7 @@ #define DIR_CONTROL_ENTRY "dir" #define MINFREE_CONTROL_ENTRY "minfree" +#define FILESZ_CONTROL_ENTRY "filesz" #define FLAGS_CONTROL_ENTRY "flags" #define NA_CONTROL_ENTRY "naflags" #define POLICY_CONTROL_ENTRY "policy" @@ -719,6 +720,7 @@ void endac(void); int getacdir(char *name, int len); int getacmin(int *min_val); +int getacfilesz(size_t *size_val); int getacflg(char *auditstr, int len); int getacna(char *auditstr, int len); int getacpol(char *auditstr, size_t len); ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/configure#14 (xtext) ==== @@ -1,7 +1,7 @@ #! /bin/sh -# From configure.ac P4: //depot/projects/trustedbsd/openbsm/configure.ac#31 . +# From configure.ac P4: //depot/projects/trustedbsd/openbsm/configure.ac#32 . # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.59 for OpenBSM 1.0a11. +# Generated by GNU Autoconf 2.59 for OpenBSM 1.0a12. # # Report bugs to . # @@ -424,8 +424,8 @@ # Identity of this package. PACKAGE_NAME='OpenBSM' PACKAGE_TARNAME='openbsm' -PACKAGE_VERSION='1.0a11' -PACKAGE_STRING='OpenBSM 1.0a11' +PACKAGE_VERSION='1.0a12' +PACKAGE_STRING='OpenBSM 1.0a12' PACKAGE_BUGREPORT='trustedbsd-audit@TrustesdBSD.org' ac_unique_file="bin/auditreduce/auditreduce.c" @@ -955,7 +955,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures OpenBSM 1.0a11 to adapt to many kinds of systems. +\`configure' configures OpenBSM 1.0a12 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1021,7 +1021,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of OpenBSM 1.0a11:";; + short | recursive ) echo "Configuration of OpenBSM 1.0a12:";; esac cat <<\_ACEOF @@ -1162,7 +1162,7 @@ test -n "$ac_init_help" && exit 0 if $ac_init_version; then cat <<\_ACEOF -OpenBSM configure 1.0a11 +OpenBSM configure 1.0a12 generated by GNU Autoconf 2.59 Copyright (C) 2003 Free Software Foundation, Inc. @@ -1176,7 +1176,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by OpenBSM $as_me 1.0a11, which was +It was created by OpenBSM $as_me 1.0a12, which was generated by GNU Autoconf 2.59. Invocation command line was $ $0 $@ @@ -19278,7 +19278,7 @@ # Define the identity of the package. PACKAGE=OpenBSM - VERSION=1.0a11 + VERSION=1.0a12 cat >>confdefs.h <<_ACEOF @@ -23479,7 +23479,7 @@ } >&5 cat >&5 <<_CSEOF -This file was extended by OpenBSM $as_me 1.0a11, which was +This file was extended by OpenBSM $as_me 1.0a12, which was generated by GNU Autoconf 2.59. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -23542,7 +23542,7 @@ cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -OpenBSM config.status 1.0a11 +OpenBSM config.status 1.0a12 configured by $0, generated by GNU Autoconf 2.59, with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/configure.ac#15 (text+ko) ==== @@ -2,8 +2,8 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.59) -AC_INIT([OpenBSM], [1.0a11], [trustedbsd-audit@TrustesdBSD.org],[openbsm]) -AC_REVISION([$P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/configure.ac#14 $]) +AC_INIT([OpenBSM], [1.0a12], [trustedbsd-audit@TrustesdBSD.org],[openbsm]) +AC_REVISION([$P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/configure.ac#15 $]) AC_CONFIG_SRCDIR([bin/auditreduce/auditreduce.c]) AC_CONFIG_AUX_DIR(config) AC_CONFIG_HEADER([config/config.h]) ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_control#7 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_control#6 $ +# $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_control#7 $ # $FreeBSD: src/contrib/openbsm/etc/audit_control,v 1.2 2006/03/26 01:44:35 rwatson Exp $ # dir:/var/audit @@ -7,3 +7,4 @@ minfree:20 naflags:lo policy:cnt +filesz:0 ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_event#17 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_event#16 $ +# $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/etc/audit_event#17 $ # $FreeBSD: src/contrib/openbsm/etc/audit_event,v 1.3 2006/06/27 18:09:54 rwatson Exp $ # 0:AUE_NULL:indir system call:no @@ -419,6 +419,10 @@ 43114:AUE_KENV:kenv(8):ad 43115:AUE_JAIL_ATTACH:jail_attach(2):ad 43116:AUE_SYSCTL_WRITE:sysctl(3):ad +43117:AUE_IOPERM:linux ioperm:ad +43118:AUE_READDIR:readdir(3):no +43119:AUE_IOPL:linux iopl:ad +43120:AUE_VM86:linux vm86:pc # # User space system events. # ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/au_control.3#6 (text+ko) ==== @@ -1,5 +1,5 @@ .\"- -.\" Copyright (c) 2005 Robert N. M. Watson +.\" Copyright (c) 2005-2006 Robert N. M. Watson .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/au_control.3#5 $ +.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/au_control.3#6 $ .\" .Dd April 19, 2005 .Dt AU_CONTROL 3 @@ -33,6 +33,7 @@ .Nm endac , .Nm getacdir , .Nm getacmin , +.Nm getacfilesz , .Nm getacflg , .Nm getacna , .Nm getacpol , @@ -52,6 +53,8 @@ .Ft int .Fn getacmin "int *min_val" .Ft int +.Fn getacfilesz "size_t *size_val" +.Ft int .Fn getacflg "char *auditstr" "int len" .Ft int .Fn getacna "char *auditstr" "int len" @@ -88,6 +91,10 @@ .Va min_val variable. .Pp +.Fn getacfilesz +returns the audit trail rotation size in the passed size_t buffer +.Fa size_val . +.Pp .Fn getacflg returns the audit system flags via the the passed character buffer .Va auditstr ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/bsm_control.c#11 (text+ko) ==== @@ -27,7 +27,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/bsm_control.c#10 $ + * $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/bsm_control.c#11 $ */ #include @@ -396,6 +396,46 @@ } /* + * Return the desired trail rotation size from the audit control file. + */ +int +getacfilesz(size_t *filesz_val) +{ + char *filesz, *dummy; + long long ll; + + pthread_mutex_lock(&mutex); + setac_locked(); + if (getstrfromtype_locked(FILESZ_CONTROL_ENTRY, &filesz) < 0) { + pthread_mutex_unlock(&mutex); + return (-2); + } + if (filesz == NULL) { + pthread_mutex_unlock(&mutex); + errno = EINVAL; + return (1); + } + ll = strtoll(filesz, &dummy, 10); + if (*dummy != '\0') { + pthread_mutex_unlock(&mutex); + errno = EINVAL; + return (-1); + } + /* + * The file size must either be 0 or >= MIN_AUDIT_FILE_SIZE. 0 + * indicates no rotation size. + */ + if (ll < 0 || (ll > 0 && ll < MIN_AUDIT_FILE_SIZE)) { + pthread_mutex_unlock(&mutex); + errno = EINVAL; + return (-1); + } + *filesz_val = ll; + pthread_mutex_unlock(&mutex); + return (0); +} + +/* * Return the system audit value from the audit contol file. */ int ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/libbsm.3#9 (text+ko) ==== @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/libbsm.3#8 $ +.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/libbsm/libbsm.3#9 $ .\" .Dd April 19, 2005 .Dt LIBBSM 3 @@ -84,6 +84,7 @@ .Xr endac 3 , .Xr setac 3 , .Xr getacdir 3 , +.Xr getacfilesz 3 , .Xr getacflg 3 , .Xr getacmin 3 , .Xr getacna 3 , ==== //depot/projects/trustedbsd/audit3/contrib/openbsm/man/audit_control.5#9 (text+ko) ==== @@ -1,4 +1,5 @@ .\" Copyright (c) 2004 Apple Computer, Inc. +.\" Copyright (c) 2006 Robert N. M. Watson .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -25,7 +26,7 @@ .\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/man/audit_control.5#8 $ +.\" $P4: //depot/projects/trustedbsd/audit3/contrib/openbsm/man/audit_control.5#9 $ .\" .Dd January 4, 2006 .Dt AUDIT_CONTROL 5 @@ -66,6 +67,12 @@ .It Va policy A list of global audit policy flags specifying various behaviors, such as fail stop, auditing of paths and arguments, etc. +.It Va filesz +Maximum trail size in bytes; if set to a non-0 value, the audit daemon will +rotate the audit trail file at around this size. +Sizes less than the minimum trail size (default of 512K) will be rejected as +invalid. +If 0, trail files will not be automatically rotated based on file size. .El .Sh AUDIT FLAGS Audit flags are a comma-delimited list of audit classes as defined in the @@ -78,12 +85,14 @@ The following prefixes may be used for each class: .Pp .Bl -tag -width Ds -compact -offset indent +.It (none) +Record both successful and failed events .It + Record successful events .It - Record failed events .It ^ -Record both successful and failed events +Record neither successful nor failed events .It ^+ Do not record successful events .It ^- @@ -146,6 +155,7 @@ minfree:20 naflags:lo policy:cnt +filesz:0 .Ed .Pp The @@ -156,7 +166,8 @@ .Va policy parameter specifies that the system should neither fail stop nor suspend processes when the audit store fills. -will be audited. +The trail file will not be automatically rotated by the audit daemon based on +file size. .Sh FILES .Bl -tag -width "/etc/security/audit_control" -compact .It Pa /etc/security/audit_control ==== //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#29 (text+ko) ==== @@ -30,7 +30,7 @@ * * @APPLE_BSD_LICENSE_HEADER_END@ * - * $P4: //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#28 $ + * $P4: //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#29 $ * $FreeBSD: src/sys/bsm/audit_kevents.h,v 1.7 2006/08/26 08:17:58 rwatson Exp $ */ @@ -471,6 +471,10 @@ #define AUE_KENV 43114 /* FreeBSD. */ #define AUE_JAIL_ATTACH 43115 /* FreeBSD. */ #define AUE_SYSCTL_WRITE 43116 /* FreeBSD. */ +#define AUE_IOPERM 43117 /* Linux. */ +#define AUE_READDIR 43118 /* Linux. */ +#define AUE_IOPL 43119 /* Linux. */ +#define AUE_VM86 43120 /* Linux. */ /* * Darwin BSM uses a number of AUE_O_* definitions, which are aliased to the From owner-p4-projects@FreeBSD.ORG Sun Sep 24 20:32:24 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 91F5916A415; Sun, 24 Sep 2006 20:32:24 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 586B216A403 for ; Sun, 24 Sep 2006 20:32:24 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0C29943D46 for ; Sun, 24 Sep 2006 20:32:24 +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.6/8.13.6) with ESMTP id k8OKWN07068100 for ; Sun, 24 Sep 2006 20:32:23 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OKWNaV068097 for perforce@freebsd.org; Sun, 24 Sep 2006 20:32:23 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 20:32:23 GMT Message-Id: <200609242032.k8OKWNaV068097@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 Cc: Subject: PERFORCE change 106618 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 20:32:24 -0000 http://perforce.freebsd.org/chv.cgi?CH=106618 Change 106618 by rwatson@rwatson_zoo on 2006/09/24 20:32:18 Match set of vendor deleted files in CVS for OpenBSM: don't replicate some include files in both src/sys/bsm and contrib/openbsm/bsm. Affected files ... .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bsm/audit.h#19 delete .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bsm/audit_internal.h#13 delete .. //depot/projects/trustedbsd/audit3/contrib/openbsm/bsm/audit_kevents.h#28 delete Differences ... From owner-p4-projects@FreeBSD.ORG Sun Sep 24 21:07:09 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id C78D916A412; Sun, 24 Sep 2006 21:07:09 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 A439A16A407 for ; Sun, 24 Sep 2006 21:07:09 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 58AFB43D45 for ; Sun, 24 Sep 2006 21:07:09 +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.6/8.13.6) with ESMTP id k8OL79gD082751 for ; Sun, 24 Sep 2006 21:07:09 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8OL79LB082748 for perforce@freebsd.org; Sun, 24 Sep 2006 21:07:09 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 21:07:09 GMT Message-Id: <200609242107.k8OL79LB082748@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 Cc: Subject: PERFORCE change 106620 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 21:07:10 -0000 http://perforce.freebsd.org/chv.cgi?CH=106620 Change 106620 by rwatson@rwatson_peppercorn on 2006/09/24 21:06:34 auditreduce now relies on the OpenBSM config.h so needs a pointer to the OpenBSM tree. Affected files ... .. //depot/projects/trustedbsd/audit3/usr.sbin/auditreduce/Makefile#4 edit Differences ... ==== //depot/projects/trustedbsd/audit3/usr.sbin/auditreduce/Makefile#4 (text+ko) ==== @@ -5,6 +5,8 @@ OPENBSMDIR=${.CURDIR}/../../contrib/openbsm .PATH: ${OPENBSMDIR}/bin/auditreduce +CFLAGS+= -I${OPENBSMDIR} + PROG= auditreduce MAN= auditreduce.1 From owner-p4-projects@FreeBSD.ORG Sun Sep 24 23:26:06 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2C48A16A412; Sun, 24 Sep 2006 23:26:06 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 D43FD16A407 for ; Sun, 24 Sep 2006 23:26:05 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9C1EE43D45 for ; Sun, 24 Sep 2006 23:26:05 +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.6/8.13.6) with ESMTP id k8ONQ5Kd096327 for ; Sun, 24 Sep 2006 23:26:05 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8ONQ4aL096324 for perforce@freebsd.org; Sun, 24 Sep 2006 23:26:04 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 23:26:04 GMT Message-Id: <200609242326.k8ONQ4aL096324@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 Cc: Subject: PERFORCE change 106621 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 23:26:06 -0000 http://perforce.freebsd.org/chv.cgi?CH=106621 Change 106621 by rwatson@rwatson_peppercorn on 2006/09/24 23:25:19 Submit untested Mac OS X clock_gettime() compat code so that it's in the tree where csjp can get to it. Affected files ... .. //depot/projects/trustedbsd/openbsm/bin/auditfilterd/auditfilterd.c#10 edit .. //depot/projects/trustedbsd/openbsm/compat/clock_gettime.h#1 add Differences ... ==== //depot/projects/trustedbsd/openbsm/bin/auditfilterd/auditfilterd.c#10 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/openbsm/bin/auditfilterd/auditfilterd.c#9 $ + * $P4: //depot/projects/trustedbsd/openbsm/bin/auditfilterd/auditfilterd.c#10 $ */ /* @@ -48,6 +48,10 @@ #include #endif +#ifndef HAVE_CLOCK_GETTIME +#include +#endif + #include #include From owner-p4-projects@FreeBSD.ORG Sun Sep 24 23:27:08 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id F001C16A47E; Sun, 24 Sep 2006 23:27:07 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 CE92016A407 for ; Sun, 24 Sep 2006 23:27:07 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 68B2C43D49 for ; Sun, 24 Sep 2006 23:27:07 +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.6/8.13.6) with ESMTP id k8ONR74t096463 for ; Sun, 24 Sep 2006 23:27:07 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8ONR727096460 for perforce@freebsd.org; Sun, 24 Sep 2006 23:27:07 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 23:27:07 GMT Message-Id: <200609242327.k8ONR727096460@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 Cc: Subject: PERFORCE change 106622 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 23:27:08 -0000 http://perforce.freebsd.org/chv.cgi?CH=106622 Change 106622 by rwatson@rwatson_sesame on 2006/09/24 23:26:29 Now we're working on OpenBSM 1.0 alpha 13. Affected files ... .. //depot/projects/trustedbsd/openbsm/HISTORY#40 edit .. //depot/projects/trustedbsd/openbsm/VERSION#14 edit .. //depot/projects/trustedbsd/openbsm/configure.ac#33 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/HISTORY#40 (text+ko) ==== @@ -1,3 +1,5 @@ +OpenBSM 1.0 alpha 13 + OpenBSM 1.0 alpha 12 - Correct bug in auditreduce which prevented the -c option from working @@ -264,4 +266,4 @@ to support reloading of kernel event table. - Allow comments in /etc/security configuration files. -$P4: //depot/projects/trustedbsd/openbsm/HISTORY#39 $ +$P4: //depot/projects/trustedbsd/openbsm/HISTORY#40 $ ==== //depot/projects/trustedbsd/openbsm/VERSION#14 (text+ko) ==== @@ -1,1 +1,1 @@ -OPENBSM_1_0_ALPHA_12 +OPENBSM_1_0_ALPHA_13 ==== //depot/projects/trustedbsd/openbsm/configure.ac#33 (text+ko) ==== @@ -2,8 +2,8 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.59) -AC_INIT([OpenBSM], [1.0a12], [trustedbsd-audit@TrustesdBSD.org],[openbsm]) -AC_REVISION([$P4: //depot/projects/trustedbsd/openbsm/configure.ac#32 $]) +AC_INIT([OpenBSM], [1.0a13], [trustedbsd-audit@TrustesdBSD.org],[openbsm]) +AC_REVISION([$P4: //depot/projects/trustedbsd/openbsm/configure.ac#33 $]) AC_CONFIG_SRCDIR([bin/auditreduce/auditreduce.c]) AC_CONFIG_AUX_DIR(config) AC_CONFIG_HEADER([config/config.h]) From owner-p4-projects@FreeBSD.ORG Sun Sep 24 23:28:09 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id C054116A415; Sun, 24 Sep 2006 23:28:09 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 86CAE16A40F for ; Sun, 24 Sep 2006 23:28:09 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4293643D46 for ; Sun, 24 Sep 2006 23:28:09 +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.6/8.13.6) with ESMTP id k8ONS9RA096576 for ; Sun, 24 Sep 2006 23:28:09 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8ONS8VW096573 for perforce@freebsd.org; Sun, 24 Sep 2006 23:28:08 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 23:28:08 GMT Message-Id: <200609242328.k8ONS8VW096573@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 Cc: Subject: PERFORCE change 106623 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 23:28:10 -0000 http://perforce.freebsd.org/chv.cgi?CH=106623 Change 106623 by rwatson@rwatson_sesame on 2006/09/24 23:27:29 Regenerate. Affected files ... .. //depot/projects/trustedbsd/openbsm/configure#30 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/configure#30 (xtext) ==== @@ -1,7 +1,7 @@ #! /bin/sh -# From configure.ac P4: //depot/projects/trustedbsd/openbsm/configure.ac#32 . +# From configure.ac P4: //depot/projects/trustedbsd/openbsm/configure.ac#33 . # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.59 for OpenBSM 1.0a12. +# Generated by GNU Autoconf 2.59 for OpenBSM 1.0a13. # # Report bugs to . # @@ -424,8 +424,8 @@ # Identity of this package. PACKAGE_NAME='OpenBSM' PACKAGE_TARNAME='openbsm' -PACKAGE_VERSION='1.0a12' -PACKAGE_STRING='OpenBSM 1.0a12' +PACKAGE_VERSION='1.0a13' +PACKAGE_STRING='OpenBSM 1.0a13' PACKAGE_BUGREPORT='trustedbsd-audit@TrustesdBSD.org' ac_unique_file="bin/auditreduce/auditreduce.c" @@ -955,7 +955,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures OpenBSM 1.0a12 to adapt to many kinds of systems. +\`configure' configures OpenBSM 1.0a13 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1021,7 +1021,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of OpenBSM 1.0a12:";; + short | recursive ) echo "Configuration of OpenBSM 1.0a13:";; esac cat <<\_ACEOF @@ -1162,7 +1162,7 @@ test -n "$ac_init_help" && exit 0 if $ac_init_version; then cat <<\_ACEOF -OpenBSM configure 1.0a12 +OpenBSM configure 1.0a13 generated by GNU Autoconf 2.59 Copyright (C) 2003 Free Software Foundation, Inc. @@ -1176,7 +1176,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by OpenBSM $as_me 1.0a12, which was +It was created by OpenBSM $as_me 1.0a13, which was generated by GNU Autoconf 2.59. Invocation command line was $ $0 $@ @@ -19278,7 +19278,7 @@ # Define the identity of the package. PACKAGE=OpenBSM - VERSION=1.0a12 + VERSION=1.0a13 cat >>confdefs.h <<_ACEOF @@ -23479,7 +23479,7 @@ } >&5 cat >&5 <<_CSEOF -This file was extended by OpenBSM $as_me 1.0a12, which was +This file was extended by OpenBSM $as_me 1.0a13, which was generated by GNU Autoconf 2.59. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -23542,7 +23542,7 @@ cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ -OpenBSM config.status 1.0a12 +OpenBSM config.status 1.0a13 configured by $0, generated by GNU Autoconf 2.59, with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" From owner-p4-projects@FreeBSD.ORG Sun Sep 24 23:38:22 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id C036216A415; Sun, 24 Sep 2006 23:38:22 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 9884416A407 for ; Sun, 24 Sep 2006 23:38:22 +0000 (UTC) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 65E8743D46 for ; Sun, 24 Sep 2006 23:38:22 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8ONcMCJ097053 for ; Sun, 24 Sep 2006 23:38:22 GMT (envelope-from csjp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8ONcMjX097050 for perforce@freebsd.org; Sun, 24 Sep 2006 23:38:22 GMT (envelope-from csjp@freebsd.org) Date: Sun, 24 Sep 2006 23:38:22 GMT Message-Id: <200609242338.k8ONcMjX097050@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 Cc: Subject: PERFORCE change 106624 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 23:38:23 -0000 http://perforce.freebsd.org/chv.cgi?CH=106624 Change 106624 by csjp@csjp_xor on 2006/09/24 23:38:03 Fix build on Darwin: s,tv_msec,tv_usec,g Affected files ... .. //depot/projects/trustedbsd/openbsm/compat/clock_gettime.h#2 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/compat/clock_gettime.h#2 (text+ko) ==== @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $P4: //depot/projects/trustedbsd/openbsm/compat/clock_gettime.h#1 $ + * $P4: //depot/projects/trustedbsd/openbsm/compat/clock_gettime.h#2 $ */ /* @@ -49,6 +49,6 @@ if (gettimeofday(&tv, NULL) < 0) return (-1); ts->tv_sec = tv.tv_sec; - ts->tv_nsec = tv.tv_msec * 1000; + ts->tv_nsec = tv.tv_usec * 1000; return (0); } From owner-p4-projects@FreeBSD.ORG Sun Sep 24 23:46:35 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1031F16A518; Sun, 24 Sep 2006 23:46:35 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 DF29116A500 for ; Sun, 24 Sep 2006 23:46:34 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id A55F443D45 for ; Sun, 24 Sep 2006 23:46: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.6/8.13.6) with ESMTP id k8ONkYe6097482 for ; Sun, 24 Sep 2006 23:46:34 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8ONkYHb097479 for perforce@freebsd.org; Sun, 24 Sep 2006 23:46:34 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 24 Sep 2006 23:46:34 GMT Message-Id: <200609242346.k8ONkYHb097479@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 Cc: Subject: PERFORCE change 106625 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 23:46:35 -0000 http://perforce.freebsd.org/chv.cgi?CH=106625 Change 106625 by rwatson@rwatson_peppercorn on 2006/09/24 23:46:12 We now build on Mac OS X again. Affected files ... .. //depot/projects/trustedbsd/openbsm/HISTORY#41 edit Differences ... ==== //depot/projects/trustedbsd/openbsm/HISTORY#41 (text+ko) ==== @@ -1,5 +1,8 @@ OpenBSM 1.0 alpha 13 +- compat/clock_gettime.h now provides a compatibility implementation of + clock_gettime(), which fixes building on Mac OS X. + OpenBSM 1.0 alpha 12 - Correct bug in auditreduce which prevented the -c option from working @@ -266,4 +269,4 @@ to support reloading of kernel event table. - Allow comments in /etc/security configuration files. -$P4: //depot/projects/trustedbsd/openbsm/HISTORY#40 $ +$P4: //depot/projects/trustedbsd/openbsm/HISTORY#41 $ From owner-p4-projects@FreeBSD.ORG Mon Sep 25 05:13:25 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E578E16A412; Mon, 25 Sep 2006 05:13:24 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 A44F116A403 for ; Mon, 25 Sep 2006 05:13:24 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5B14643D45 for ; Mon, 25 Sep 2006 05:13:24 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8P5DOMW039578 for ; Mon, 25 Sep 2006 05:13:24 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8P5DOD7039575 for perforce@freebsd.org; Mon, 25 Sep 2006 05:13:24 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 05:13:24 GMT Message-Id: <200609250513.k8P5DOD7039575@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106630 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 05:13:25 -0000 http://perforce.freebsd.org/chv.cgi?CH=106630 Change 106630 by imp@imp_lighthouse on 2006/09/25 05:13:09 Add mmc bus. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#3 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#3 (text+ko) ==== @@ -166,9 +166,8 @@ AT91_MCI_LOCK_DESTROY(sc); goto out; } - - AT91_MCI_UNLOCK(sc); - + device_add_child(dev, "mmc", 0); + err = bus_generic_attach(dev); out:; if (err) at91_mci_deactivate(dev); From owner-p4-projects@FreeBSD.ORG Mon Sep 25 05:26:41 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id AC8F816A416; Mon, 25 Sep 2006 05:26:41 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 89CC216A403 for ; Mon, 25 Sep 2006 05:26:41 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 42EFF43D46 for ; Mon, 25 Sep 2006 05:26:41 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8P5QfAc040213 for ; Mon, 25 Sep 2006 05:26:41 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8P5Qf0e040210 for perforce@freebsd.org; Mon, 25 Sep 2006 05:26:41 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 05:26:41 GMT Message-Id: <200609250526.k8P5Qf0e040210@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106631 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 05:26:41 -0000 http://perforce.freebsd.org/chv.cgi?CH=106631 Change 106631 by imp@imp_lighthouse on 2006/09/25 05:26:03 oops. Let's call a .m file a .m file. Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmcbus_if.h#2 delete .. //depot/projects/arm/src/sys/dev/mmc/mmcbus_if.m#1 branch Differences ... From owner-p4-projects@FreeBSD.ORG Mon Sep 25 06:51:30 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9154B16A416; Mon, 25 Sep 2006 06:51:30 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 DF29816A40F for ; Mon, 25 Sep 2006 06:51:29 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 85AD143D79 for ; Mon, 25 Sep 2006 06:51:29 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8P6pTVi046010 for ; Mon, 25 Sep 2006 06:51:29 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8P6pTwu046007 for perforce@freebsd.org; Mon, 25 Sep 2006 06:51:29 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 06:51:29 GMT Message-Id: <200609250651.k8P6pTwu046007@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106636 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 06:51:30 -0000 http://perforce.freebsd.org/chv.cgi?CH=106636 Change 106636 by imp@imp_lighthouse on 2006/09/25 06:51:28 Flesh out the host adapter concept a little. Fill in the right default values for the atmel device. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#4 edit .. //depot/projects/arm/src/sys/dev/mmc/bridge.h#2 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#4 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#4 (text+ko) ==== @@ -53,6 +53,8 @@ #include #include #include +#include +#include struct at91_mci_softc { void *intrhand; /* Interrupt handle */ @@ -62,9 +64,7 @@ struct mtx sc_mtx; bus_dma_tag_t dmatag; bus_dmamap_t map; - struct disk *disk; /* XXX support only one card for */ - int nb_cards; - struct proc *p; + struct mmc_host host; }; static inline uint32_t @@ -133,6 +133,7 @@ /* XXX: asumes MCK = 60MHz */ struct at91_mci_softc *sc = device_get_softc(dev); int err; + device_t child; sc->dev = dev; err = at91_mci_activate(dev); @@ -166,7 +167,12 @@ AT91_MCI_LOCK_DESTROY(sc); goto out; } - device_add_child(dev, "mmc", 0); + sc->host.f_min = 375000; + sc->host.f_max = 25000000; + sc->host.host_ocr = MMC_OCR_320_330 | MMC_OCR_330_340; + sc->host.caps = MMC_CAP_4_BIT_DATA; + child = device_add_child(dev, "mmc", 0); + device_set_ivars(dev, &sc->host); err = bus_generic_attach(dev); out:; if (err) ==== //depot/projects/arm/src/sys/dev/mmc/bridge.h#2 (text+ko) ==== @@ -73,16 +73,24 @@ struct mmc_ios { uint32_t clock; /* Speed of the clock in Hz to move data */ - enum mmc_vdd vdd; /* Voltage to apply to the power pins */ + enum mmc_vdd vdd; /* Voltage to apply to the power pins/ */ enum mmc_bus_mode bus_mode; enum mmc_chip_select chip_select; enum mmc_bus_width bus_width; }; -#define MMC_CAP_4_BIT_DATA (1UL << 0) /* Host can do 4-bit xfers */ - enum mmc_card_mode { mode_mmc, mode_sd }; +struct mmc_host { + int f_min; + int f_max; + uint32_t host_ocr; + uint32_t caps; +#define MMC_CAP_4_BIT_DATA (1 << 0) /* Can do 4-bit data transfers */ +#define MMC_CAP_8_BIT_DATA (1 << 1) /* Can do 8-bit data transfers */ + enum mmc_card_mode mode; +}; + #endif /* DEV_MMC_BRIDGE_H */ ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#4 (text+ko) ==== @@ -389,4 +389,31 @@ //////////////////////////////////////////////////////////////////////////////// +/* OCR bits */ +#define MMC_OCR_145_150 (1U << 0) /* Vdd voltage 1.45 ~ 1.50 */ +#define MMC_OCR_150_155 (1U << 1) /* Vdd voltage 1.50 ~ 1.50 */ +#define MMC_OCR_155_160 (1U << 2) /* Vdd voltage 1.55 ~ 1.60 */ +#define MMC_OCR_160_165 (1U << 3) /* Vdd voltage 1.60 ~ 1.65 */ +#define MMC_OCR_165_170 (1U << 4) /* Vdd voltage 1.65 ~ 1.70 */ +#define MMC_OCR_170_180 (1U << 5) /* Vdd voltage 1.70 ~ 1.80 */ +#define MMC_OCR_180_190 (1U << 6) /* Vdd voltage 1.80 ~ 1.90 */ +#define MMC_OCR_190_200 (1U << 7) /* Vdd voltage 1.90 ~ 2.00 */ +#define MMC_OCR_200_210 (1U << 8) /* Vdd voltage 2.00 ~ 2.10 */ +#define MMC_OCR_210_220 (1U << 9) /* Vdd voltage 2.10 ~ 2.20 */ +#define MMC_OCR_220_230 (1U << 10) /* Vdd voltage 2.20 ~ 2.30 */ +#define MMC_OCR_230_240 (1U << 11) /* Vdd voltage 2.30 ~ 2.40 */ +#define MMC_OCR_240_250 (1U << 12) /* Vdd voltage 2.40 ~ 2.50 */ +#define MMC_OCR_250_260 (1U << 13) /* Vdd voltage 2.50 ~ 2.60 */ +#define MMC_OCR_260_270 (1U << 14) /* Vdd voltage 2.60 ~ 2.70 */ +#define MMC_OCR_270_280 (1U << 15) /* Vdd voltage 2.70 ~ 2.80 */ +#define MMC_OCR_280_290 (1U << 16) /* Vdd voltage 2.80 ~ 2.90 */ +#define MMC_OCR_290_300 (1U << 17) /* Vdd voltage 2.90 ~ 3.00 */ +#define MMC_OCR_300_310 (1U << 18) /* Vdd voltage 3.00 ~ 3.10 */ +#define MMC_OCR_310_320 (1U << 19) /* Vdd voltage 3.10 ~ 3.20 */ +#define MMC_OCR_320_330 (1U << 20) /* Vdd voltage 3.20 ~ 3.30 */ +#define MMC_OCR_330_340 (1U << 21) /* Vdd voltage 3.30 ~ 3.40 */ +#define MMC_OCR_340_350 (1U << 22) /* Vdd voltage 3.40 ~ 3.50 */ +#define MMC_OCR_350_360 (1U << 23) /* Vdd voltage 3.50 ~ 3.60 */ +#define MMC_OCR_CARD_BUSY (1U << 31) /* Card Power up status */ + #endif /* DEV_MMCREG_H */ From owner-p4-projects@FreeBSD.ORG Mon Sep 25 06:53:33 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id AFB1F16A415; Mon, 25 Sep 2006 06:53:33 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 5492E16A412 for ; Mon, 25 Sep 2006 06:53:33 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B4B2043D7B for ; Mon, 25 Sep 2006 06:53:32 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8P6rWUi046072 for ; Mon, 25 Sep 2006 06:53:32 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8P6rWHo046069 for perforce@freebsd.org; Mon, 25 Sep 2006 06:53:32 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 06:53:32 GMT Message-Id: <200609250653.k8P6rWHo046069@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106637 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 06:53:33 -0000 http://perforce.freebsd.org/chv.cgi?CH=106637 Change 106637 by imp@imp_lighthouse on 2006/09/25 06:52:50 stub out the mmc bus and mmc/sd flash card drivers. More to follow. Affected files ... .. //depot/projects/arm/src/sys/arm/conf/TSC4370#9 edit .. //depot/projects/arm/src/sys/conf/files#44 edit .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#1 add .. //depot/projects/arm/src/sys/dev/mmc/mmcsd.c#1 add Differences ... ==== //depot/projects/arm/src/sys/arm/conf/TSC4370#9 (text+ko) ==== @@ -95,9 +95,8 @@ device at91_ssc device at91_tc device at91_mci -#device mmcsd # mmc/sd bus -#device mmc # mmc flash card -#device sd # sd flash card +device mmc # mmc/sd bus +device mmcsd # mmc/sd flash cards # iic device iic device iicbus ==== //depot/projects/arm/src/sys/conf/files#44 (text+ko) ==== @@ -752,6 +752,8 @@ dev/mlx/mlx_disk.c optional mlx dev/mlx/mlx_pci.c optional mlx pci dev/mly/mly.c optional mly +dev/mmc/mmc.c optional mmc +dev/mmc/mmcsd.c optional mmcsd dev/mpt/mpt.c optional mpt dev/mpt/mpt_cam.c optional mpt dev/mpt/mpt_debug.c optional mpt From owner-p4-projects@FreeBSD.ORG Mon Sep 25 08:38:57 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D72A016A416; Mon, 25 Sep 2006 08:38:56 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 90B8B16A40F for ; Mon, 25 Sep 2006 08:38:56 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4A60543D4C for ; Mon, 25 Sep 2006 08:38:56 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8P8cu7q054061 for ; Mon, 25 Sep 2006 08:38:56 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8P8ctcP054058 for perforce@freebsd.org; Mon, 25 Sep 2006 08:38:55 GMT (envelope-from soc-andrew@freebsd.org) Date: Mon, 25 Sep 2006 08:38:55 GMT Message-Id: <200609250838.k8P8ctcP054058@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106641 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 08:38:57 -0000 http://perforce.freebsd.org/chv.cgi?CH=106641 Change 106641 by soc-andrew@soc-andrew_serv on 2006/09/25 08:38:51 Rename the BSDInstaller backend Lua modules to the new upstream names Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Bitwise.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Capacity.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/CmdChain.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/ConfigFile.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Disk.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Flow.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/FlowStep.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Installation.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/InstallationUI.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Menu.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/MenuItem.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/NavContainer.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/NavLeaf.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Network.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/NetworkUI.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Package.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageGraph.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageList.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageSet.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageUI.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Partition.lua#1 add .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/StorageSystem.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/StorageSystemUI.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Subpartition.lua#1 branch .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/bitwise.lua#3 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/cmdchain.lua#4 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/configvars.lua#3 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/flow.lua#3 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/menu.lua#3 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/network.lua#5 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/network_ui.lua#3 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/package.lua#6 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/package_ui.lua#3 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/storage.lua#7 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/storage_ui.lua#3 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/target_system.lua#10 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/target_system_ui.lua#4 delete .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/uinav.lua#5 delete Differences ... From owner-p4-projects@FreeBSD.ORG Mon Sep 25 12:36:16 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 5AC7316A417; Mon, 25 Sep 2006 12:36:16 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 2FA9416A403 for ; Mon, 25 Sep 2006 12:36:16 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C966C43D62 for ; Mon, 25 Sep 2006 12:36:06 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PCa6op096381 for ; Mon, 25 Sep 2006 12:36:06 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PCa3JQ096378 for perforce@freebsd.org; Mon, 25 Sep 2006 12:36:03 GMT (envelope-from soc-andrew@freebsd.org) Date: Mon, 25 Sep 2006 12:36:03 GMT Message-Id: <200609251236.k8PCa3JQ096378@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106658 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 12:36:16 -0000 http://perforce.freebsd.org/chv.cgi?CH=106658 Change 106658 by soc-andrew@soc-andrew_serv on 2006/09/25 12:35:07 Update the BSDInstaller backend to a recent CVS snapshot Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/200_install.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/400_configure.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/500_create_geom_mirror.lua#1 add .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/600_upgrade.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/800_netboot.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/950_reboot.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/Makefile#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/BSDInstaller.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/DragonFly.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/FreeBSD.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/NetBSD.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/OpenBSD.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/100_choose_where_from.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/200_select_disk.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/300_select_part.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/400_mount_target_system.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/450_init_configuration.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/500_menu.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/550_write_configuration.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/600_unmount_target_system.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/main.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/menu/100_set_root_password.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/menu/200_add_user.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/menu/300_set_timezone.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/menu/350_set_datetime.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/menu/400_change_console_settings.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/menu/500_install_packages.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/menu/550_remove_packages.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/100_welcome.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/200_select_disk.lua#5 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/220_format_disk.lua#6 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/250_partition_disk.lua#7 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/270_install_bootblocks.lua#5 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/300_select_part.lua#5 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/400_select_subparts.lua#5 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/405_warn_omitted_subparts.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/407_create_subparts.lua#4 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/410_select_additional_filesystems.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/420_preselect_packages.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/450_select_packages.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/490_confirm_install_os.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/500_install_os.lua#10 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/800_finished.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/900_reboot.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/install/main.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Bitwise.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Capacity.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/CmdChain.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/ConfigFile.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Disk.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Flow.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/FlowStep.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Installation.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/InstallationUI.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Menu.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/MenuItem.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/NavContainer.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/NavLeaf.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Network.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/NetworkUI.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Package.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageGraph.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageList.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageSet.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/PackageUI.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Partition.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/StorageSystem.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/StorageSystemUI.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/lib/Subpartition.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/main.lua#4 edit Differences ... ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/200_install.lua#3 (text+ko) ==== @@ -1,30 +1,34 @@ --- $Id: 200_install.lua,v 1.12 2005/08/30 00:39:05 cpressey Exp $ +-- $Id: 200_install.lua,v 1.13 2006/09/13 23:43:25 cpressey Exp $ -- --- Menu.Item scriptlet that generates the install menu item. +-- MenuItem scriptlet that generates the install menu item. -- Note that, if we detect that we weren't started from the -- installation media, we don't provide this menu item. -- -if not App.conf.booted_from_install_media then - return nil, "not booted from install media" +id = "install_os" +name = _("Install %s", App.conf.product.name) +short_desc = _("Install %s on this computer system", + App.conf.product.name) + +condition = function() + if not App.conf.booted_from_install_media then + return false, "not booted from install media" + end + return true end -return { - id = "install_os", - name = _("Install %s", App.conf.product.name), - short_desc = _("Install %s on this computer system", - App.conf.product.name), - effect = function() - -- - -- Make a recording of the install session. - -- XXX this might make more sense elsewhere, like as - -- Flow.Steps during the install itself? - -- - CmdChain.record_to(App.expand("${tmp}install-session.sh")) - App.descend("install") - CmdChain.stop_recording() +effect = function() + -- + -- Make a recording of the install session. + -- + -- XXX this might make more sense elsewhere, like as + -- a pair of FlowSteps at the beginning and end of the + -- install sequence itself? + -- + CmdChain.record_to(App.expand("${tmp}install-session.sh")) + App.descend("install") + CmdChain.stop_recording() - return Menu.CONTINUE - end -} + return Menu.CONTINUE +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/400_configure.lua#3 (text+ko) ==== @@ -1,26 +1,25 @@ --- $Id: 400_configure.lua,v 1.7 2005/08/26 04:25:24 cpressey Exp $ +-- $Id: 400_configure.lua,v 1.8 2006/09/13 23:43:25 cpressey Exp $ + +id = "configure_installed_system" +name = _("Configure an Installed System") +short_desc = _("Configure an existing %s installation", + App.conf.product.name) -return { - id = "configure_installed_system", - name = _("Configure an Installed System"), - short_desc = _("Configure an existing %s installation", - App.conf.product.name), - effect = function() - -- - -- If there is currently a target system mounted, - -- unmount it before starting. - -- - if App.state.target ~= nil and App.state.target:is_mounted() then - if not App.state.target:unmount() then - App.ui:inform( - _("Warning: already-mounted target system could " .. - "not be correctly unmounted first.") - ) - return step:prev() - end +effect = function() + -- + -- If there is currently a target system mounted, + -- unmount it before starting. + -- + if App.state.target ~= nil and App.state.target:is_mounted() then + if not App.state.target:unmount() then + App.ui:inform( + _("Warning: already-mounted target system could " .. + "not be correctly unmounted first.") + ) + return step:prev() end + end - App.descend("configure") - return Menu.CONTINUE - end -} + App.descend("configure") + return Menu.CONTINUE +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/600_upgrade.lua#3 (text+ko) ==== @@ -1,11 +1,10 @@ --- $Id: 600_upgrade.lua,v 1.2 2005/04/09 19:04:20 cpressey Exp $ +-- $Id: 600_upgrade.lua,v 1.3 2006/09/13 23:43:25 cpressey Exp $ + +id = "upgrade_installed_system" +name = _("Upgrade an Installed System") +short_desc = _("Upgrade a system with to the newest available version") -return { - id = "upgrade_installed_system", - name = _("Upgrade an Installed System"), - short_desc = _("Upgrade a system with to the newest available version"), - effect = function() - App.descend("upgrade") - return Menu.CONTINUE - end -} +effect = function() + App.descend("upgrade") + return Menu.CONTINUE +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/800_netboot.lua#3 (text+ko) ==== @@ -1,12 +1,11 @@ --- $Id: 800_netboot.lua,v 1.3 2005/04/12 13:28:31 den Exp $ +-- $Id: 800_netboot.lua,v 1.4 2006/09/13 23:43:25 cpressey Exp $ + +id = "set_up_netboot" +name = _("Set Up NetBoot Server") +short_desc = _("Make this computer a boot server " .. + "for other machines on the network") -return { - id = "set_up_netboot", - name = _("Set Up NetBoot Server"), - short_desc = _("Make this computer a boot server " .. - "for other machines on the network"), - effect = function() - App.descend("netboot") - return Menu.CONTINUE - end -} +effect = function() + App.descend("netboot") + return Menu.CONTINUE +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/950_reboot.lua#2 (text+ko) ==== @@ -1,17 +1,16 @@ --- $Id: 950_reboot.lua,v 1.2 2005/08/13 18:46:09 cpressey Exp $ +-- $Id: 950_reboot.lua,v 1.4 2006/09/13 23:43:25 cpressey Exp $ + +id = "reboot" +name = _("Reboot") +short_desc = _("Reboot this computer") -return { - id = "reboot", - name = _("Reboot"), - short_desc = _("Reboot this computer"), - effect = function() - if TargetSystemUI.ask_reboot{ - cancel_desc = _("Return to Select Task") -- XXX this_menu_name - } then - App.state.do_reboot = true - return nil - else - return Menu.CONTINUE - end +effect = function() + if App.state.source:ask_reboot{ + cancel_desc = _("Return to Select Task") -- XXX this_menu_name + } then + App.state.do_reboot = true + return nil + else + return Menu.CONTINUE end -} +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/Makefile#3 (text+ko) ==== @@ -1,5 +1,5 @@ # Makefile for dfuibe_lua. -# $Id: Makefile,v 1.55 2005/08/27 08:04:49 cpressey Exp $ +# $Id: Makefile,v 1.56 2006/07/29 18:02:50 cpressey Exp $ BASE?=../.. include ${BASE}/Config @@ -37,7 +37,7 @@ test: su root -c "env LD_LIBRARY_PATH='../../lib/libaura:../../lib/libdfui:$(LUA)/lib' \ - LUA_PATH='../../lib/lua/?/?.lua;../../lib/lua/luasocket/lua/?.lua' \ + LUA_PATH='../../lib/lua/?/?.lua;../../lib/lua/luasocket/lua/?.lua;./lib/?.lua' \ LUA_CPATH='../../lib/lua/posix/?.so;../../lib/lua/pty/?.so;../../lib/lua/dfui/?.so;../../lib/lua/luasocket/?.so' \ $(LUA)/bin/lua -lcompat-5.1 main.lua \ ./conf/BSDInstaller.lua ./conf/${OSNAME}.lua \ ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/BSDInstaller.lua#3 (text+ko) ==== @@ -1,6 +1,6 @@ -- -- conf/BSDInstaller.lua --- $Id: BSDInstaller.lua,v 1.13 2005/10/05 21:29:03 cpressey Exp $ +-- $Id: BSDInstaller.lua,v 1.20 2006/09/04 18:01:33 cpressey Exp $ -- -- The monolithic default configuration file for the BSD Installer. -- @@ -154,7 +154,7 @@ ["usr/local"] = "etc/mtree/BSD.local.dist", ["usr/X11R6"] = "etc/mtree/BSD.x11-4.dist" } - + -- -- upgrade_items: similar to "install_items", except for upgrading purposes -- instead of initial installation. @@ -219,24 +219,29 @@ -- space on the device to install anything at all. -- -mountpoints = function(part_cap, ram_cap) +mountpoints = function(part_megs, ram_megs) -- -- First, calculate suggested swap size: -- - local swap = 2 * ram_cap - if ram_cap > (part_cap / 2) or part_cap < 4096 then - swap = ram_cap + local swap_megs = 2 * ram_megs + if ram_megs > (part_megs / 2) or part_megs < 4096 then + swap_megs = ram_megs end - swap = tostring(swap) .. "M" + swap = tostring(swap_megs) .. "M" + + -- + -- The megabytes available on disk for non-swap use. + -- + local avail_megs = part_megs - swap_megs -- -- Now, based on the capacity of the partition, -- return an appropriate list of suggested mountpoints. -- - if part_cap < 300 then + if avail_megs < 300 then return {} - elseif part_cap < 523 then + elseif avail_megs < 523 then return { { mountpoint = "/", capstring = "70M" }, { mountpoint = "swap", capstring = swap }, @@ -245,7 +250,7 @@ { mountpoint = "/usr", capstring = "174M" }, { mountpoint = "/home", capstring = "*" } } - elseif part_cap < 1024 then + elseif avail_megs < 1024 then return { { mountpoint = "/", capstring = "96M" }, { mountpoint = "swap", capstring = swap }, @@ -254,7 +259,7 @@ { mountpoint = "/usr", capstring = "256M" }, { mountpoint = "/home", capstring = "*" } } - elseif part_cap < 4096 then + elseif avail_megs < 4096 then return { { mountpoint = "/", capstring = "128M" }, { mountpoint = "swap", capstring = swap }, @@ -263,7 +268,7 @@ { mountpoint = "/usr", capstring = "512M" }, { mountpoint = "/home", capstring = "*" } } - elseif part_cap < 10240 then + elseif avail_megs < 10240 then return { { mountpoint = "/", capstring = "256M" }, { mountpoint = "swap", capstring = swap }, @@ -309,7 +314,7 @@ } -- --- limits: Limiting values specified by the installation; the most +-- limits: Limiting values specified by the installation; the most -- significant of these is the minimum disk space required to -- install the software. -- @@ -447,6 +452,7 @@ KLDLOAD = "sbin/kldload", KLDUNLOAD = "sbin/kldunload", KLDSTAT = "sbin/kldstat", + TUNEFS = "sbin/tunefs", TOUCH = "usr/bin/touch", YES = "usr/bin/yes", @@ -577,6 +583,16 @@ offlimits_devices = { "fd%d+", "md%d+", "cd%d+" } -- +-- extra_devices: devices which the installer should consider installing +-- onto, even though it might not detect them through normal means. This +-- should not generally be needed, and should be reserved for debugging. +-- These are not Lua regexps; they are plain device names that include the +-- device number (e.g. "vn0".) +-- + +extra_devices = { } + +-- -- has_softupdates: whether the operating system supports creating -- a filesystem with softupdates, i.e. the -U flag to newfs. -- @@ -592,6 +608,33 @@ window_subpartitions = { "c" } +-- +-- offlimits_mounts: BSDInstaller will ignore these mount points. +-- +-- example: offlimits_mounts = { "unionfs" } +-- + +offlimits_mounts = { } + +-- +-- needs_makedev: if true, the operating system needs to run the MAKEDEV +-- script for accessing a device node to ensure that it exists. If false, +-- the OS has a devfs or similar and doesn't need to run MAKEDEV. +-- + +needs_makedev = true + +-- +-- disklabel_offset: the number of sectors away from the beginning of the +-- disk (or partition) that the disklabel should start at. Different OSes +-- have different preferred values for this: +-- +-- DragonFlyBSD starts at an offset of 0, whereas bsdlabel on FreeBSD +-- suggests a starting point of 16. Net/Open starts at an offset of 32. +-- + +disklabel_offset = 0 + ------------------------------------------------------------------- -- Natural Language Services (NLS) ------------------------------------------------------------------- @@ -652,4 +695,3 @@ -- fatal_errors = false - ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/DragonFly.lua#3 (text+ko) ==== @@ -1,6 +1,6 @@ -- -- conf/DragonFly.lua --- $Id: DragonFly.lua,v 1.8 2005/12/21 22:49:26 cpressey Exp $ +-- $Id: DragonFly.lua,v 1.11 2006/09/04 18:01:33 cpressey Exp $ -- -- This file contains DragonFly-specific overrides to BSDInstaller.lua. -- @@ -60,4 +60,6 @@ disklabel_on_disk = false has_softupdates = true window_subpartitions = { "c" } +needs_makedev = true +disklabel_offset = 0 use_cpdup = true ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/FreeBSD.lua#2 (text+ko) ==== @@ -1,6 +1,6 @@ -- -- conf/FreeBSD.lua --- $Id: FreeBSD.lua,v 1.7 2005/09/16 22:41:10 cpressey Exp $ +-- $Id: FreeBSD.lua,v 1.11 2006/09/04 18:01:33 cpressey Exp $ -- -- This file contains FreeBSD-specific overrides to BSDInstaller.lua. -- @@ -50,7 +50,7 @@ } sysids = { - { "FreeBSD/DragonFly", 165 }, + { "FreeBSD", 165 }, { "OpenBSD", 166 }, { "NetBSD", 169 }, { "MS-DOS", 15 }, @@ -65,4 +65,6 @@ disklabel_on_disk = false has_softupdates = true window_subpartitions = { "c" } +needs_makedev = false +disklabel_offset = 16 use_cpdup = false ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/NetBSD.lua#2 (text+ko) ==== @@ -1,6 +1,6 @@ -- -- conf/NetBSD.lua --- $Id: NetBSD.lua,v 1.8 2005/08/27 20:24:59 cpressey Exp $ +-- $Id: NetBSD.lua,v 1.11 2006/09/04 18:01:33 cpressey Exp $ -- -- This file contains NetBSD-specific overrides to conf/BSDInstaller.lua. -- @@ -61,4 +61,6 @@ has_softupdates = false window_subpartitions = { "c", "d" } enable_crashdumps = false +needs_makedev = true +disklabel_offset = 32 use_cpdup = false ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/conf/OpenBSD.lua#2 (text+ko) ==== @@ -1,6 +1,6 @@ -- -- conf/OpenBSD.lua --- $Id: OpenBSD.lua,v 1.5 2005/08/27 20:24:59 cpressey Exp $ +-- $Id: OpenBSD.lua,v 1.8 2006/09/04 18:01:33 cpressey Exp $ -- -- This file contains OpenBSD-specific overrides to conf/BSDInstaller.lua. -- @@ -31,4 +31,6 @@ disklabel_on_disk = true has_softupdates = false window_subpartitions = { "c", "d" } +needs_makedev = true +disklabel_offset = 32 use_cpdup = false ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/100_choose_where_from.lua#3 (text+ko) ==== @@ -1,4 +1,4 @@ --- $Id: 100_choose_where_from.lua,v 1.16 2005/08/30 00:39:05 cpressey Exp $ +-- $Id: 100_choose_where_from.lua,v 1.18 2006/09/13 23:43:25 cpressey Exp $ -- -- Allow the user to select which system to configure. @@ -9,57 +9,61 @@ -- we skip straight to selecting which disk/partition to configure. -- -if App.conf.booted_from_install_media then - return nil, "was booted from install media" + +id = "choose_target_system" +name = _("Choose Target System") + +condition = function() + if App.conf.booted_from_install_media then + return false, "was booted from install media" + else + return true + end end -return { - id = "choose_target_system", - name = _("Choose Target System"), - effect = function(step) - -- - -- If the user has already selected a TargetSystem (e.g. they are - -- coming here directly from the end of an install,) skip ahead. - -- - if App.state.target ~= nil then - return step:next() - end +effect = function(step) + -- + -- If the user has already selected an Installation (e.g. they are + -- coming here directly from the end of an install,) skip ahead. + -- + if App.state.target ~= nil then + return step:next() + end - -- - -- Ask the user where to configure. - -- - local action_id = App.ui:present({ - id = "choose_target_system", - name = _("Choose Target System"), - short_desc = _( - "Please choose which installed system you want to configure." - ), - actions = { - { - id = "this", - name = _("Configure the Running System") - }, - { - id = "disk", - name = _("Configure a System on Disk") - }, - { - id = "cancel", - accelerator = "ESC", - name = _("Return to %s", step:get_prev_name()), - } - }, - role = "menu" - }).action_id + -- + -- Ask the user where to configure. + -- + local action_id = App.ui:present({ + id = "choose_target_system", + name = _("Choose Target System"), + short_desc = _( + "Please choose which installed system you want to configure." + ), + actions = { + { + id = "this", + name = _("Configure the Running System") + }, + { + id = "disk", + name = _("Configure a System on Disk") + }, + { + id = "cancel", + accelerator = "ESC", + name = _("Return to %s", step:get_prev_name()), + } + }, + role = "menu" + }).action_id - if action_id == "cancel" then - return step:prev() - elseif action_id == "disk" then - return step:next() - else -- "this" - App.state.target = App.state.source - -- Jump straight to the menu. - return "configuration_menu" - end + if action_id == "cancel" then + return step:prev() + elseif action_id == "disk" then + return step:next() + else -- "this" + App.state.target = App.state.source + -- Jump straight to the menu. + return "configuration_menu" end -} +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/200_select_disk.lua#3 (text+ko) ==== @@ -1,57 +1,56 @@ --- $Id: 200_select_disk.lua,v 1.15 2005/08/26 04:25:24 cpressey Exp $ +-- $Id: 200_select_disk.lua,v 1.18 2006/09/13 23:43:25 cpressey Exp $ -- -- Allow the user to select the disk where the OS installation -- they want to configure resides. -- -return { - id = "select_disk", - name = _("Select Disk"), - req_state = { "storage" }, - effect = function(step) - -- - -- If the user has already selected a TargetSystem (e.g. they are - -- coming here directly from the end of an install,) skip ahead. - -- - if App.state.target ~= nil then - return step:next() - end +id = "select_disk" +name = _("Select Disk") +req_state = { "storage" } + +effect = function(step) + -- + -- If the user has already selected an Installation (e.g. they are + -- coming here directly from the end of an install,) skip ahead. + -- + if App.state.target ~= nil then + return step:next() + end - -- - -- Allow the user to select a disk. - -- - App.state.sel_disk = nil - App.state.sel_part = nil + -- + -- Allow the user to select a disk. + -- + App.state.sel_disk = nil + App.state.sel_part = nil - -- XXX there might be a better place to handle this. - if App.state.storage:get_disk_count() == 0 then - App.ui:inform(_( - "The installer could not find any suitable disks " .. - "attached to this computer. If you wish to " .. - "configure an installation of %s " .. - "on an unorthodox storage device, you will have to " .. - "exit to a %s command prompt and configure it " .. - "manually, using the file /README as a guide.", - App.conf.product.name, App.conf.media_name) - ) - return nil - end + -- XXX there might be a better place to handle this. + if App.state.storage:get_disk_count() == 0 then + App.ui:inform(_( + "The installer could not find any suitable disks " .. + "attached to this computer. If you wish to " .. + "configure an installation of %s " .. + "on an unorthodox storage device, you will have to " .. + "exit to a %s command prompt and configure it " .. + "manually, using the file /README as a guide.", + App.conf.product.name, App.conf.media_name) + ) + return nil + end - local dd = StorageUI.select_disk({ - sd = App.state.storage, - short_desc = _( - "Select the disk on which the installation of %s " .. - "that you wish to configure resides.", - App.conf.product.name), - cancel_desc = _("Return to %s", step:get_prev_name()) - }) + local dd = App.state.storage:select_disk{ + short_desc = _( + "Select the disk on which the installation of %s " .. + "that you wish to configure resides.", + App.conf.product.name + ), + cancel_desc = _("Return to %s", step:get_prev_name()) + } - if dd then - App.state.sel_disk = dd - return step:next() - else - return step:prev() - end + if dd then + App.state.sel_disk = dd + return step:next() + else + return step:prev() end -} +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/300_select_part.lua#3 (text+ko) ==== @@ -1,52 +1,51 @@ --- $Id: 300_select_part.lua,v 1.13 2005/08/26 04:25:24 cpressey Exp $ +-- $Id: 300_select_part.lua,v 1.17 2006/09/13 23:43:25 cpressey Exp $ -- -- Allow the user to select the BIOS partition where the OS -- they want to configure resides. -- -return { - id = "select_part", - name = _("Select Partition"), - req_state = { "storage", "sel_disk" }, - effect = function(step) - -- - -- If the user has already selected a TargetSystem (e.g. they are - -- coming here directly from the end of an install,) skip ahead. - -- - if App.state.target ~= nil then - return step:next() - end +id = "select_part" +name = _("Select Partition") +req_state = { "storage", "sel_disk" } - -- - -- Allow the user to select a partition. - -- - App.state.sel_part = nil - local pd = StorageUI.select_part({ - dd = App.state.sel_disk, - short_desc = _( - "Select the primary partition of %s " .. - "on which the installation of %s resides.", - App.state.sel_disk:get_name(), - App.conf.product.name), - cancel_desc = _("Return to %s", step:get_prev_name()) - }) +effect = function(step) + -- + -- If the user has already selected an Installation (e.g. they are + -- coming here directly from the end of an install,) skip ahead. + -- + if App.state.target ~= nil then + return step:next() + end - if pd then - if pd:is_mounted() then - App.ui:inform(_( - "One or more subpartitions on the selected " .. - "primary partition already in use (they are " .. - "currently mounted in the filesystem.) " .. - "You should unmount them before proceeding." - )) - return step - end + -- + -- Allow the user to select a partition. + -- + App.state.sel_part = nil + local pd = App.state.sel_disk:select_part{ + short_desc = _( + "Select the primary partition of %s " .. + "on which the installation of %s resides.", + App.state.sel_disk:get_name(), + App.conf.product.name + ), + cancel_desc = _("Return to %s", step:get_prev_name()) + } - App.state.sel_part = pd - return step:next() - else - return step:prev() + if pd then + if pd:is_mounted() then + App.ui:inform(_( + "One or more subpartitions on the selected " .. + "primary partition already in use (they are " .. + "currently mounted in the filesystem.) " .. + "You should unmount them before proceeding." + )) + return step end + + App.state.sel_part = pd + return step:next() + else + return step:prev() end -} +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/400_mount_target_system.lua#3 (text+ko) ==== @@ -1,48 +1,47 @@ --- $Id: 400_mount_target_system.lua,v 1.22 2005/08/04 22:00:40 cpressey Exp $ +-- $Id: 400_mount_target_system.lua,v 1.24 2006/09/13 23:43:25 cpressey Exp $ -- -- Mount the chosen system as the target system for configuration. -- -return { - id = "mount_target_system", - name = _("Mount Target System"), - interactive = false, - req_state = { "storage", "sel_disk", "sel_part" }, - effect = function(step) - -- - -- If the user has already mounted a TargetSystem (e.g. they are - -- coming here directly from the end of an install,) skip ahead. - -- - if App.state.target ~= nil and App.state.target:is_mounted() then - return step:next() - end +id = "mount_target_system" +name = _("Mount Target System") +interactive = false +req_state = { "storage", "sel_disk", "sel_part" } - App.state.target = TargetSystem.new{ - partition = App.state.sel_part, - base = "mnt" - } - local ok, errmsg = App.state.target:probe() - if not ok then - App.log(errmsg) - App.ui:inform(_( - "The target system could not be successfully probed:\n\n%s", - errmsg - )) - App.state.target = nil - return step:prev() - end - local ok, errmsg = App.state.target:mount() - if not ok then - App.log(errmsg) - App.ui:inform(_( - "The target system could not be successfully mounted:\n\n%s", - errmsg - )) - App.state.target = nil - return step:prev() - end +effect = function(step) + -- + -- If the user has already mounted an Installation (e.g. they are + -- coming here directly from the end of an install,) skip ahead. + -- + if App.state.target ~= nil and App.state.target:is_mounted() then + return step:next() + end - return step:next() + App.state.target = InstallationUI.new{ + partition = App.state.sel_part, + base = "mnt" + } + local ok, errmsg = App.state.target:probe() + if not ok then + App.log(errmsg) + App.ui:inform(_( + "The target system could not be successfully probed:\n\n%s", + errmsg + )) + App.state.target = nil + return step:prev() + end + local ok, errmsg = App.state.target:mount() + if not ok then + App.log(errmsg) + App.ui:inform(_( + "The target system could not be successfully mounted:\n\n%s", + errmsg + )) + App.state.target = nil + return step:prev() end -} + + return step:next() +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/450_init_configuration.lua#2 (text+ko) ==== @@ -1,18 +1,15 @@ --- $Id: 450_init_configuration.lua,v 1.1 2005/07/12 21:15:05 cpressey Exp $ +-- $Id: 450_init_configuration.lua,v 1.3 2006/09/13 23:43:25 cpressey Exp $ -- -- Initialize the configuration variables. -- -return { - id = "init_configuation", - name = _("Initialize Configuration"), - interactive = false, - req_state = { "storage", "sel_disk", "sel_part" }, - effect = function(step) +id = "init_configuation" +name = _("Initialize Configuration") +interactive = false +req_state = { "storage", "sel_disk", "sel_part" } - App.state.rc_conf = ConfigVars.new() - - return step:next() - end -} +effect = function(step) + App.state.rc_conf = ConfigFile.new() + return step:next() +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/configure/500_menu.lua#3 (text+ko) ==== @@ -1,15 +1,14 @@ --- $Id: 500_menu.lua,v 1.8 2005/07/08 21:24:09 cpressey Exp $ +-- $Id: 500_menu.lua,v 1.9 2006/09/13 23:43:25 cpressey Exp $ -- -- Display the configuration menu. -- -return { - id = "configuration_menu", - name = _("Configuration Menu"), - req_state = { "target" }, - effect = function(step) - App.descend("menu") - return step:next() - end -} +id = "configuration_menu" +name = _("Configuration Menu") +req_state = { "target" } + +effect = function(step) >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Mon Sep 25 12:40:21 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 516CB16A4DA; Mon, 25 Sep 2006 12:40:21 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 1227616A4C8 for ; Mon, 25 Sep 2006 12:40:21 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6860043D69 for ; Mon, 25 Sep 2006 12:40:12 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PCeCIX096584 for ; Mon, 25 Sep 2006 12:40:12 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PCeC9g096581 for perforce@freebsd.org; Mon, 25 Sep 2006 12:40:12 GMT (envelope-from soc-andrew@freebsd.org) Date: Mon, 25 Sep 2006 12:40:12 GMT Message-Id: <200609251240.k8PCeC9g096581@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106659 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 12:40:21 -0000 http://perforce.freebsd.org/chv.cgi?CH=106659 Change 106659 by soc-andrew@soc-andrew_serv on 2006/09/25 12:39:37 IFC Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/release/Makefile#52 integrate .. //depot/projects/soc2005/bsdinstaller/src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#19 integrate .. //depot/projects/soc2005/bsdinstaller/src/release/picobsd/bridge/PICOBSD#3 integrate Differences ... ==== //depot/projects/soc2005/bsdinstaller/src/release/Makefile#52 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/release/Makefile,v 1.913 2006/09/08 19:54:36 ru Exp $ +# $FreeBSD: src/release/Makefile,v 1.914 2006/09/11 13:15:09 ru Exp $ # # make release [BUILDNAME=somename] CHROOTDIR=/some/dir CVSROOT=/cvs/dir \ # [RELEASETAG=tag] @@ -592,7 +592,7 @@ # Install the system into the various distributions. release.2: - cd ${.CURDIR}/.. && make distrib-dirs DESTDIR=${RD}/trees/base + cd ${.CURDIR}/.. && ${CROSSMAKE} distrib-dirs DESTDIR=${RD}/trees/base cd ${.CURDIR}/.. && ${CROSSMAKE} ${WORLD_FLAGS} distributeworld \ DISTDIR=${RD}/trees touch ${.TARGET} ==== //depot/projects/soc2005/bsdinstaller/src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#19 (text+ko) ==== @@ -3,7 +3,7 @@ The &os; Project - $FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.974 2006/09/07 23:49:26 bmah Exp $ + $FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.975 2006/09/16 03:58:07 bmah Exp $ 2000 @@ -1023,7 +1023,7 @@ disk. Note that the encryption algorithm is now specified to the &man.geli.8; control program using the option; the option is now used to specify - the authentication algorithm + the authentication algorithm. &merged; The &man.umass.4; driver now supports PLAY_MSF, @@ -1329,7 +1329,7 @@ late keyword in &man.fstab.5;, along with a corresponding command-line option to specify that these late file systems should be - mounted. + mounted. &merged; The &man.moused.8; daemon now supports an flag to enable horizontal virtual scrolling similar to the ==== //depot/projects/soc2005/bsdinstaller/src/release/picobsd/bridge/PICOBSD#3 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/release/picobsd/bridge/PICOBSD,v 1.18 2005/09/27 18:10:43 mlaier Exp $ +# $FreeBSD: src/release/picobsd/bridge/PICOBSD,v 1.19 2006/09/18 06:34:51 marck Exp $ # # Line starting with #PicoBSD contains PicoBSD build parameters #marker def_sz init MFS_inodes floppy_inodes @@ -41,7 +41,6 @@ options DUMMYNET device if_bridge options HZ=1000 -#options NMBCLUSTERS=4096 device isa device pci From owner-p4-projects@FreeBSD.ORG Mon Sep 25 12:42:55 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id C6D1316A4AB; Mon, 25 Sep 2006 12:42:55 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 A10E416A4DA for ; Mon, 25 Sep 2006 12:42:55 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id DE83643DC4 for ; Mon, 25 Sep 2006 12:42:17 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PCgFkk096785 for ; Mon, 25 Sep 2006 12:42:15 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PCgFa1096782 for perforce@freebsd.org; Mon, 25 Sep 2006 12:42:15 GMT (envelope-from soc-andrew@freebsd.org) Date: Mon, 25 Sep 2006 12:42:15 GMT Message-Id: <200609251242.k8PCgFa1096782@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106661 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 12:42:56 -0000 http://perforce.freebsd.org/chv.cgi?CH=106661 Change 106661 by soc-andrew@soc-andrew_serv on 2006/09/25 12:42:11 Fix release Makefile to be closer to the CVS version Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/release/Makefile#53 edit Differences ... ==== //depot/projects/soc2005/bsdinstaller/src/release/Makefile#53 (text+ko) ==== @@ -617,7 +617,8 @@ rm -rf ${j}_crunch mkdir ${j}_crunch cd ${j}_crunch; ${WMAKEENV} MAKEFLAGS="-m ${.CURDIR}/../share/mk" \ - crunchgen -o ${.CURDIR}/${TARGET}/${j}_crunch.conf + crunchgen -o \ + ${.CURDIR}/${TARGET}/${j}_crunch.conf cd ${j}_crunch; ${WMAKE} -f ${j}_crunch.mk subclean cd ${.CURDIR}/..; ${BINMAKE} -f Makefile.inc1 _build-tools cd ${j}_crunch; CFLAGS="-Os -pipe" ${WMAKE} -f ${j}_crunch.mk \ From owner-p4-projects@FreeBSD.ORG Mon Sep 25 12:43:49 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 420C216A47B; Mon, 25 Sep 2006 12:43:49 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 D4C0316A412 for ; Mon, 25 Sep 2006 12:43:48 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 032DC43D46 for ; Mon, 25 Sep 2006 12:43: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.6/8.13.6) with ESMTP id k8PChH7W096833 for ; Mon, 25 Sep 2006 12:43:17 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PChHeU096830 for perforce@freebsd.org; Mon, 25 Sep 2006 12:43:17 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Mon, 25 Sep 2006 12:43:17 GMT Message-Id: <200609251243.k8PChHeU096830@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 Cc: Subject: PERFORCE change 106662 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 12:43:49 -0000 http://perforce.freebsd.org/chv.cgi?CH=106662 Change 106662 by rwatson@rwatson_peppercorn on 2006/09/25 12:42:16 Integrate TrustedBSD priv6 branch from FreeBSD CVS RELENG_6 branch to work on a backport of the priv(9) API to FreeBSD 6.x. Affected files ... .. //depot/projects/trustedbsd/priv6/src/sys/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/api_up1000.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/atomic.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/autoconf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/busdma_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/busspace.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/clock.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/clock_if.m#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/cpuconf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/db_disasm.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/db_instruction.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/db_interface.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/db_trace.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_1000a.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_2100_a50.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_2100_a500.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_3000_300.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_3000_500.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_axppci_33.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_eb164.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_eb64plus.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_kn20aa.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_kn300.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_kn8ae.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_st550.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dec_st6600.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/divrem.m4#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/dump_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/elf_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/exception.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/fp_emulate.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/gdb_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/genassym.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/ieee_float.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/ieee_float.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/in_cksum.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/interrupt.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/locore.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/mem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/mp_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/pal.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/pmap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/prom.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/prom_disp.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/promcons.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/sgmap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/support.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/swtch.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/sys_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/trap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/uio_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/uma_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/alpha/vm_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/compile/.cvsignore#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/conf/.cvsignore#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/conf/GENERIC#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/conf/GENERIC.hints#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/conf/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/conf/NOTES#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/_bus.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/_inttypes.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/_limits.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/_stdint.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/_types.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/alpha_cpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/asm.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/atomic.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/bootinfo.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/bus.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/bus_dma.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/bwx.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/chipset.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/clock.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/clockvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/cpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/cpuconf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/cpufunc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/db_machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/elf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/endian.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/exec.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/float.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/floatingpoint.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/fpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/frame.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/gdb_machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/ieee.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/ieeefp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/in_cksum.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/inst.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/intr.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/intrcnt.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/ioctl_bt848.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/ioctl_meteor.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/kdb.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/limits.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/md_var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/memdev.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/mutex.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pal.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/param.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pc/bios.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pc/display.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pc/vesa.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pcb.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pcpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pmap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pmc_mdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/ppireg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/proc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/profile.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/prom.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/pte.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/ptrace.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/reloc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/resource.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/rpb.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/runq.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/setjmp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/sf_buf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/sgmap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/sigframe.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/signal.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/smp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/stdarg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/swiz.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/sysarch.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/timerreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/ucontext.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/varargs.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/include/vmparam.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/isa/isa.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/isa/isa_dma.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/isa/isavar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/isa/mcclock_isa.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_dummy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_genassym.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_ipc64.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_locore.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_proto.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_syscall.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_sysent.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/linux_sysvec.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/syscalls.conf#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/linux/syscalls.master#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/mcbus/mcbus.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/mcbus/mcbusreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/mcbus/mcbusvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/mcbus/mcmem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/mcbus/mcpcia.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/mcbus/mcpciareg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/mcbus/mcpciavar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/README.mach-traps#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/exec_ecoff.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/imgact_osf1.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_ioctl.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_misc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_mount.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_proto.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_signal.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_signal.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_syscall.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_sysent.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_sysvec.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/osf1_util.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/syscalls.conf#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/osf1/syscalls.master#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/alphapci_if.m#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/apecs.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/apecs_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/apecsreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/apecsvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/bwx.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/cia.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/cia_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/ciareg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/ciavar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/irongate.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/irongate_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/irongatereg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/irongatevar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/lca.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/lca_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/lcareg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/lcavar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/pci_eb164_intr.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/pci_eb64plus_intr.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/pcibus.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/pcibus.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/swiz.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/t2.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/t2_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/t2reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/t2var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/tsunami.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/tsunami_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/tsunamireg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/pci/tsunamivar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/dwlpx.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/dwlpxreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/dwlpxvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/gbus.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/gbusreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/gbusvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/kftxx.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/kftxxreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/kftxxvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/mcclock_tlsb.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/tlsb.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/tlsbcpu.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/tlsbmem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/tlsbreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/tlsbvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/zs_tlsb.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/zsreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/alpha/tlsb/zsvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/acpica/OsdEnvironment.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/acpica/acpi_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/acpica/acpi_wakeup.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/acpica/madt.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/amd64_mem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/apic_vector.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/atomic.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/autoconf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/bios.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/busdma_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/cpu_switch.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/db_disasm.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/db_interface.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/db_trace.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/dump_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/elf_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/exception.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/fpu.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/gdb_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/genassym.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/identcpu.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/in_cksum.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/initcpu.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/intr_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/io.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/io_apic.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/legacy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/local_apic.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/locore.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/mem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/minidump_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/mp_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/mp_watchdog.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/mpboot.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/mptable.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/mptable_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/nexus.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/pmap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/prof_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/sigtramp.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/support.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/sys_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/trap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/tsc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/uio_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/uma_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/amd64/vm_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/compile/.cvsignore#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/conf/.cvsignore#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/conf/DEFAULTS#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/conf/GENERIC#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/conf/GENERIC.hints#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/conf/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/conf/NOTES#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/conf/SMP#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/ia32/ia32_exception.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/ia32/ia32_reg.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/ia32/ia32_signal.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/ia32/ia32_sigtramp.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/ia32/ia32_syscall.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/_bus.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/_inttypes.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/_limits.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/_stdint.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/_types.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/acpica_machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/apicreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/apicvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/asm.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/asmacros.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/atomic.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/bus.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/bus_dma.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/clock.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/cpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/cpufunc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/cputypes.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/db_machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/elf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/endian.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/exec.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/float.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/floatingpoint.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/fpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/frame.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/gdb_machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/ieeefp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/in_cksum.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/intr_machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/iodev.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/kdb.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/legacyvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/limits.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/md_var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/memdev.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/metadata.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/minidump.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/mp_watchdog.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/mptable.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/mutex.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/param.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pc/bios.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pc/display.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pcb.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pcb_ext.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pci_cfgreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pcpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pmap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/pmc_mdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/ppireg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/proc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/profile.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/psl.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/ptrace.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/reloc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/resource.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/runq.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/segments.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/setjmp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/sf_buf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/sigframe.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/signal.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/smp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/specialreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/stdarg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/sysarch.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/timerreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/trap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/tss.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/ucontext.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/varargs.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/include/vmparam.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/atpic.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/atpic_vector.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/clock.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/elcr.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/icu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/isa.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/isa.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/isa_dma.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/isa/nmi.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_dummy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_genassym.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_ipc64.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_locore.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_proto.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_syscall.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_sysent.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/linux32_sysvec.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/syscalls.conf#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/linux32/syscalls.master#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/pci/pci_bus.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/amd64/pci/pci_cfgreg.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/autoconf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/bcopy_page.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/bcopyinout.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/bcopyinout_xscale.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/blockio.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/bootconfig.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/bus_space_asm_generic.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/busdma_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/copystr.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_arm10.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_arm7tdmi.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_arm8.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_arm9.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_armv4.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_ixp12x0.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_sa1.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_sa11x0.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/cpufunc_asm_xscale.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/db_disasm.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/db_interface.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/db_trace.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/disassem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/dump_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/elf_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/elf_trampoline.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/exception.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/fiq.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/fiq_subr.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/fusu.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/genassym.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/identcpu.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/in_cksum.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/in_cksum_arm.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/inckern.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/intr.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/irq_dispatch.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/locore.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/mem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/nexus.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/nexus_io.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/nexus_io_asm.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/pmap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/setcpsr.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/setstack.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/support.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/swtch.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/sys_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/trap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/uio_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/undefined.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/vectors.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/arm/vm_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_pdcreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_pio.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_pio_rm9200.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_pioreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_piovar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_pmc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_pmcreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_pmcvar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_rtc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_rtcreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_spi.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_spiio.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_spireg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_ssc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_sscreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_st.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_streg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_twi.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_twiio.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_twireg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91_usartreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91rm92reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/at91var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/files.at91#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/files.kb920x#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/hints.at91rm9200#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/hints.at91sam9261#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/if_ate.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/if_atereg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/kb920x_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/ohci_atmelarm.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/std.at91#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/std.kb920x#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/uart_bus_at91usart.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/uart_cpu_at91rm9200usart.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/at91/uart_dev_at91usart.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/compile/.cvsignore#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/conf/.cvsignore#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/conf/IQ31244#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/conf/KB920X#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/conf/SIMICS#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/conf/SKYEYE#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/_bus.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/_inttypes.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/_limits.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/_stdint.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/_types.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/armreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/asm.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/asmacros.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/atomic.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/blockio.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/bootconfig.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/bus.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/bus_dma.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/clock.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/cpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/cpuconf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/cpufunc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/db_machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/disassem.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/elf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/endian.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/exec.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/fiq.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/float.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/floatingpoint.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/fp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/frame.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/ieee.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/ieeefp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/in_cksum.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/intr.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/katelib.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/kdb.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/limits.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/machdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/md_var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/memdev.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/metadata.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/mutex.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/param.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/pcb.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/pcpu.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/pmap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/pmc_mdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/proc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/profile.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/psl.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/pte.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/ptrace.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/reloc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/resource.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/runq.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/setjmp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/sf_buf.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/sigframe.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/signal.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/smp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/stdarg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/swi.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/sysarch.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/trap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/ucontext.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/undefined.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/utrap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/include/vmparam.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/assabet_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/files.sa11x0#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_dmacreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_gpioreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_io.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_io_asm.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_irq.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_irqhandler.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_ost.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_ostreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_ppcreg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/sa11x0_var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/std.sa11x0#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/uart_bus_sa1110.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/uart_cpu_sa1110.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/uart_dev_sa1110.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/sa11x0/uart_dev_sa1110.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/files.i80321#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/files.iq31244#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321_intr.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321_mcu.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321_pci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321_space.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321_timer.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321_wdog.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/i80321var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/iq31244_7seg.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/iq31244_machdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/iq80321.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/iq80321reg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/iq80321var.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/obio.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/obio_space.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/obiovar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/std.i80321#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/std.iq31244#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/uart_bus_i80321.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/i80321/uart_cpu_i80321.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/std.xscale#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/xscalereg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/arm/xscale/xscalevar.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/README#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/boot1/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/boot1/boot1.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/cdboot/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/cdboot/version#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/common/Makefile.common#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/common/conf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/common/help.alpha#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/common/ldscript#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/common/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/OSFpal.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/alpha_copy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/alpha_module.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/bbinfo.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/bootinfo.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/common.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/delay.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/devicename.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/elf_freebsd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/getsecs.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/libalpha.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/pal.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/prom.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/prom_disp.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/prom_swpal.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/reboot.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/srmdisk.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/srmnet.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/start.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/libalpha/time.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/loader/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/loader/version#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/netboot/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/alpha/netboot/version#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/include/arcfuncs.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/include/arctypes.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/include/libarc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/abort.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/arcconsole.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/arcdisk.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/arch/alpha/copy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/arch/alpha/rpb.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/arch/alpha/setjmp.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/arch/alpha/start.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/bootinfo.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/delay.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/devicename.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/elf_freebsd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/module.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/prom.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/setjmperr.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/lib/time.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/loader/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/loader/conf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/loader/help.alpha#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/loader/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arc/loader/version#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0/README#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0/arm_init.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0/linker.cfg#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0iic/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0iic/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0spi/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/boot0spi/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/README#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/arm_init.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/env_vars.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/env_vars.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/loader_prompt.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/loader_prompt.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootiic/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/README#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/arm_init.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/env_vars.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/env_vars.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/loader_prompt.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/loader_prompt.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/bootspi/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/at91rm9200.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/at91rm9200_lowlevel.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/delay.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/eeprom.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/emac.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/emac.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/emac_init.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/getc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/lib.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/lib_AT91RM9200.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/mci_device.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/mci_device.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/p_string.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/printf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/putchar.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/reset.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/sd-card.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/sd-card.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/spi_flash.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/spi_flash.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/tag_list.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/tag_list.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/libat91/xmodem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/arm/at91/linker.cfg#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/bcache.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/boot.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/bootstrap.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/commands.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/console.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/dev_net.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/dev_net.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/devopen.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/help.common#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/interp.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/interp_backslash.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/interp_forth.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/interp_parse.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/isapnp.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/isapnp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/load.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/load_elf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/load_elf32.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/load_elf32_obj.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/load_elf64.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/load_elf64_obj.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/load_elf_obj.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/loader.8#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/ls.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/merge_help.awk#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/misc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/module.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/newvers.sh#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/panic.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/pnp.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/pnpdata#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/reloc_elf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/reloc_elf32.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/reloc_elf64.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/common/ufsread.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/README#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efi.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efi_nii.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efiapi.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/eficon.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efidebug.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efidef.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efidevp.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efierr.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efifpswa.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efifs.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efilib.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efinet.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efipart.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efiprot.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efipxebc.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efiser.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/efistdarg.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/i386/efibind.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/i386/pe.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/ia64/efibind.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/include/ia64/pe.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/bootinfo.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/copy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/delay.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/devicename.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/efi_console.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/efiboot.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/efifpswa.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/efifs.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/efinet.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/elf_freebsd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/libefi.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/module.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/efi/libefi/time.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/alpha/sysdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/alpha/sysdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/dict.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/ficl.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/ficl.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/fileaccess.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/float.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/i386/sysdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/i386/sysdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/ia64/sysdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/ia64/sysdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/loader.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/math64.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/math64.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/powerpc/sysdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/powerpc/sysdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/prefix.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/search.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/classes.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/ficlclass.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/ficllocal.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/fileaccess.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/forml.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/freebsd.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/ifbrack.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/jhlocal.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/marker.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/oo.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/prefix.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/softcore.awk#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/softcore.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/softwords/string.fr#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/sparc64/sysdep.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/sparc64/sysdep.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/stack.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/testmain.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/tools.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/unix.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/vm.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ficl/words.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/beastie.4th#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/frames.4th#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/loader.4th#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/loader.4th.8#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/loader.conf#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/loader.conf.5#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/loader.rc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/pnp.4th#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/screen.4th#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/forth/support.4th#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot0/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot0/boot0.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot0/boot0ext.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot0ext/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot0sio/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot2/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot2/boot1.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot2/boot2.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot2/lib.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/boot2/sio.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/btx/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/btx/btx.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/btxldr/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/btxldr/btxldr.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/lib/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/lib/btxcsu.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/lib/btxsys.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/lib/btxv86.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/btx/lib/btxv86.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/cdboot/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/cdboot/cdboot.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/kgzldr/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/kgzldr/boot.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/kgzldr/crt.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/kgzldr/kgzldr.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/kgzldr/lib.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/kgzldr/sio.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/kgzldr/start.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/amd64_tramp.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/biosacpi.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/bioscd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/biosdisk.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/biosmem.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/biospci.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/biospnp.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/biossmap.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/bootinfo.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/bootinfo32.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/bootinfo64.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/comconsole.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/devicename.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/elf32_freebsd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/elf64_freebsd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/gatea20.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/i386_copy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/i386_module.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/libi386.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/nullconsole.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/pread.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/pxe.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/pxe.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/pxetramp.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/smbios.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/time.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/libi386/vidconsole.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/loader/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/loader/conf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/loader/help.i386#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/loader/loader.rc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/loader/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/loader/version#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/mbr/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/mbr/mbr.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/pxeldr/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/pxeldr/pxeboot.8#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/i386/pxeldr/pxeldr.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/efi/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/efi/conf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/efi/efimd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/efi/ldscript.ia64#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/efi/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/efi/start.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/efi/version#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/acpi_stub.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/bootinfo.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/conf.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/copy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/delay.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/devicename.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/efi_stub.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/elf_freebsd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/exit.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/ldscript.ia64#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/libski.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/pal_stub.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/sal_stub.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/skiconsole.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/skifs.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/skiload.cmd#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/ssc.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/start.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/time.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ia64/ski/version#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/common/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/common/main.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/devicename.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/elf_freebsd.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/libofw.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_console.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_copy.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_disk.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_memory.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_module.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_net.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_reboot.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/ofw_time.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/openfirm.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/ofw/libofw/openfirm.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/boot.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/boot0.5.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/disk.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/selector.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/start.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/support.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0.5/syscons.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot0/boot0.s#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/README.serial.98#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/asm.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/asm.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/bios.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/boot.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/boot.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/boot2.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/dinode.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/disk.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/fs.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/inode.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/io.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/probe_keyboard.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/quota.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/serial.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/serial_16550.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/serial_8251.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/start.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/sys.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/boot2/table.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/btx/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/btx/Makefile.inc#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/btx/btx/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/btx/btx/btx.S#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/btx/btxldr/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/boot/pc98/btx/btxldr/btxldr.S#1 branch >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Mon Sep 25 13:00:39 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 39C8816A415; Mon, 25 Sep 2006 13:00:39 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 10ED316A47C for ; Mon, 25 Sep 2006 13:00:39 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B462843D45 for ; Mon, 25 Sep 2006 13:00:38 +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.6/8.13.6) with ESMTP id k8PD0cZQ026698 for ; Mon, 25 Sep 2006 13:00:38 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PD0cTK026686 for perforce@freebsd.org; Mon, 25 Sep 2006 13:00:38 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Mon, 25 Sep 2006 13:00:38 GMT Message-Id: <200609251300.k8PD0cTK026686@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 Cc: Subject: PERFORCE change 106663 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 13:00:39 -0000 http://perforce.freebsd.org/chv.cgi?CH=106663 Change 106663 by rwatson@rwatson_peppercorn on 2006/09/25 12:59:52 Integrate various new files for priv(9) from the TrustedBSD priv (7.x) branch into the priv6 (6.x) branch. Affected files ... .. //depot/projects/trustedbsd/priv6/src/sys/kern/kern_priv.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/modules/mac_privs/Makefile#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/security/mac/mac_priv.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/security/mac_privs/mac_privs.c#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/security/mac_privs/mac_privs.h#1 branch .. //depot/projects/trustedbsd/priv6/src/sys/sys/priv.h#1 branch Differences ... From owner-p4-projects@FreeBSD.ORG Mon Sep 25 19:05:25 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 760FC16A416; Mon, 25 Sep 2006 19:05:25 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 39DF416A403 for ; Mon, 25 Sep 2006 19:05:25 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id A44DE43D60 for ; Mon, 25 Sep 2006 19:05:24 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PJ5Ow4001155 for ; Mon, 25 Sep 2006 19:05:24 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PJ5Oft001152 for perforce@freebsd.org; Mon, 25 Sep 2006 19:05:24 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 19:05:24 GMT Message-Id: <200609251905.k8PJ5Oft001152@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106678 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 19:05:25 -0000 http://perforce.freebsd.org/chv.cgi?CH=106678 Change 106678 by imp@imp_lighthouse on 2006/09/25 19:05:23 mop-up cutNpaste Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmcsd.c#2 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmcsd.c#2 (text+ko) ==== @@ -97,4 +97,4 @@ static devclass_t mmcsd_devclass; -DRIVER_MODULE(mmc, at91_mci, mmcsd_driver, mmcsd_devclass, 0, 0); +DRIVER_MODULE(mmcsd, mmc, mmcsd_driver, mmcsd_devclass, 0, 0); From owner-p4-projects@FreeBSD.ORG Mon Sep 25 19:06:28 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 83EC316A416; Mon, 25 Sep 2006 19:06:28 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 62EFB16A403 for ; Mon, 25 Sep 2006 19:06:28 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 31B8243D70 for ; Mon, 25 Sep 2006 19:06:27 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PJ6R3Z001241 for ; Mon, 25 Sep 2006 19:06:27 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PJ6RGX001238 for perforce@freebsd.org; Mon, 25 Sep 2006 19:06:27 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 19:06:27 GMT Message-Id: <200609251906.k8PJ6RGX001238@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106679 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 19:06:28 -0000 http://perforce.freebsd.org/chv.cgi?CH=106679 Change 106679 by imp@imp_lighthouse on 2006/09/25 19:05:44 Defer probing of mmc bus til we have a sane system running. Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#2 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#2 (text+ko) ==== @@ -40,6 +40,7 @@ struct mmc_softc { device_t dev; struct mtx sc_mtx; + struct intr_config_hook config_intrhook; }; /* bus entry points */ @@ -56,6 +57,8 @@ #define MMC_ASSERT_LOCKED(_sc) mtx_assert(&_sc->sc_mtx, MA_OWNED); #define MMC_ASSERT_UNLOCKED(_sc) mtx_assert(&_sc->sc_mtx, MA_NOTOWNED); +static void mmc_delayed_attach(void *); + static int mmc_probe(device_t dev) { @@ -73,6 +76,11 @@ sc->dev = dev; MMC_LOCK_INIT(sc); + /* We'll probe and attach our children later, but before / mount */ + sc->config_intrhook.ich_func = mmc_delayed_attach; + sc->config_intrhook.ich_arg = sc; + if (config_intrhook_establish(&sc->config_intrhook) != 0) + device_printf(dev, "config_intrhook_establish failed\n"); return (0); } @@ -82,6 +90,15 @@ return (EBUSY); /* XXX */ } +static void +mmc_delayed_attach(void *xsc) +{ + struct mmc_softc *sc = xsc; + + device_printf(sc->dev, "insert mmc/sd probe code here\n"); + config_intrhook_disestablish(&sc->config_intrhook); +} + static device_method_t mmc_methods[] = { DEVMETHOD(device_probe, mmc_probe), DEVMETHOD(device_attach, mmc_attach), From owner-p4-projects@FreeBSD.ORG Mon Sep 25 19:39:09 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 35F0616A415; Mon, 25 Sep 2006 19:39:09 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 EA97F16A403 for ; Mon, 25 Sep 2006 19:39:08 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 23FE743D67 for ; Mon, 25 Sep 2006 19:39:08 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PJd8QE002920 for ; Mon, 25 Sep 2006 19:39:08 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PJd7Mn002917 for perforce@freebsd.org; Mon, 25 Sep 2006 19:39:07 GMT (envelope-from rdivacky@FreeBSD.org) Date: Mon, 25 Sep 2006 19:39:07 GMT Message-Id: <200609251939.k8PJd7Mn002917@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106680 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 19:39:09 -0000 http://perforce.freebsd.org/chv.cgi?CH=106680 Change 106680 by rdivacky@rdivacky_witten on 2006/09/25 19:38:40 Style fixes. Submitted by: Li, Xiao Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linux/linux_aio.c#6 edit .. //depot/projects/linuxolator/src/sys/compat/linux/linux_aio.h#3 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_aio.c#6 (text+ko) ==== @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2006 Intron . All rights reserved. + * Copyright (c) 2006 Li, Xiao . All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -23,7 +23,7 @@ * SUCH DAMAGE. */ #include -__FBSDID("$FreeBSD$"); +__FBSDID("$FreeBSD: src/linuxaio/linux_aio.c,v 1.91 2006/09/25 19:12:31 admin Exp $"); #include "opt_compat.h" @@ -269,7 +269,7 @@ break; } - return nerr; + return (nerr); } /* Allocate memory in user space */ @@ -298,7 +298,7 @@ td->td_retval[0] = r; - return nerr; + return (nerr); } /* Free memory in user space */ @@ -318,7 +318,7 @@ td->td_retval[0] = r; DPPRINTF("%lu bytes at %p", (unsigned long)s, p); - return nerr; + return (nerr); } #ifdef LINUX_AIO_DEBUG @@ -356,8 +356,6 @@ DPPRINTF("aio_sigevent.sigev_signo: %d", pcb->aio_sigevent.sigev_signo); } - - return; } #define DUMP_FREEBSD_AIOCB(p, isu) linux_aio_dump_freebsd_aiocb((p), (isu)); @@ -413,29 +411,28 @@ if (nerr != 0) { DPPRINTF("Unsupported aio_lio_opcode: %u", (unsigned)plnx->aio_lio_opcode); - return nerr; + return (nerr); } pbsd->aio_reqprio = plnx->aio_reqprio; /* Request priority */ pbsd->aio_sigevent.sigev_notify = SIGEV_NONE; /* No signal to deliver */ pbsd->aio_sigevent.sigev_signo = 0; /* No signal to deliver */ - return nerr; + return (nerr); } static int link_to_native_aio_module(struct thread *td) { int nerr; - if (native_aio_module_handle != NULL) - { /* Linking has been done successfully. */ - - return 0; + if (native_aio_module_handle != NULL) { + /* Linking has been done successfully. */ + return (0); } nerr = linker_reference_module(NATIVE_AIO_MODULE_NAME, &native_aio_module_depend, &native_aio_module_handle); if (nerr) - return nerr; + return (nerr); do { nerr = EINVAL; @@ -453,18 +450,17 @@ nerr = 0; } while (0); - if (nerr) - { + if (nerr) { linker_release_module(NULL, NULL, native_aio_module_handle); native_aio_module_handle = NULL; printf(LMSG("Unable to link to the native module \"" NATIVE_AIO_MODULE_NAME "\" correctly.")); - return nerr; + return (nerr); } - return 0; + return (0); } #define LINK_TO_NATIVE_AIO_MODULE() \ @@ -473,7 +469,7 @@ NATIVE_AIO_MODULE_NAME "\" correctly " \ "to provide FreeBSD " \ "native Asynchronous I/O support.")); \ - return ENOSYS; \ + return (ENOSYS); \ } static int mirror_native_aio_sysctl(struct thread *td) @@ -486,21 +482,21 @@ &native_aio_capacity_proc, &l, NULL, 0, NULL ,0); if (nerr) - return nerr; + return (nerr); l = sizeof(native_aio_capacity_sys); nerr = kernel_sysctlbyname(td, NATIVE_AIO_SYSCTL_CAPACITY_SYS, &native_aio_capacity_sys, &l, NULL, 0, NULL ,0); if (nerr) - return nerr; + return (nerr); DPRINTF(NATIVE_AIO_SYSCTL_CAPACITY_PROC "=%d, " NATIVE_AIO_SYSCTL_CAPACITY_SYS "=%d", native_aio_capacity_proc, native_aio_capacity_sys); - return nerr; + return (nerr); } /* Linux system call io_setup(2) */ @@ -515,44 +511,42 @@ DARGPRINTF("%u, %p", args->nr_reqs, args->ctxp); LINK_TO_NATIVE_AIO_MODULE(); nerr = mirror_native_aio_sysctl(td); - if (nerr) - { + if (nerr) { printf(LMSG("linux_io_setup(): Unable to query sysctls " NATIVE_AIO_SYSCTL_CAPACITY_PROC " and/or " NATIVE_AIO_SYSCTL_CAPACITY_SYS " .")); - return nerr; + return (nerr); } /* Signed integer is a little safer than unsigned */ arg_nr_reqs = args->nr_reqs; if (arg_nr_reqs <= 0) - return EINVAL; + return (EINVAL); if (arg_nr_reqs > native_aio_capacity_proc - || arg_nr_reqs > native_aio_capacity_sys) - { + || arg_nr_reqs > native_aio_capacity_sys) { printf(LMSG("linux_io_setup(): Please increase sysctls " NATIVE_AIO_SYSCTL_CAPACITY_PROC " and/or " NATIVE_AIO_SYSCTL_CAPACITY_SYS " .")); - return ENOMEM; + return (ENOMEM); } nerr = user_mem_rw_verify(args->ctxp, sizeof(*(args->ctxp))); if (nerr != 0) - return nerr; + return (nerr); copyin(args->ctxp, &ctx_id, sizeof(ctx_id)); if (ctx_id != 0) /* "Not initialized", described by io_setup(2) */ - return EINVAL; + return (EINVAL); p = td->td_proc; /* Get a new "ring" */ nerr = user_malloc(td, (void **)&pring, sizeof(*pring)); if (nerr != 0) - return nerr; + return (nerr); /* Get a new context */ pctx = uma_zalloc(linux_aio_context_zone, M_WAITOK); @@ -591,7 +585,7 @@ DPRINTF("Free context %p", pctx); uma_zfree(linux_aio_context_zone, pctx); user_free(td, pring, sizeof(*pring)); - return ENOMEM; + return (ENOMEM); } /* Initialize the new context */ @@ -625,7 +619,7 @@ copyout(&ctx_id, args->ctxp, sizeof(ctx_id)); DPRINTF("returned context: %lx -> %p", (unsigned long)ctx_id, pctx); - return nerr; + return (nerr); } /* Linux system call io_destroy(2) */ @@ -671,7 +665,7 @@ /* Unable to find the context */ if (pctx == NULL) { LINUX_AIO_UNLOCK(p); - return EINVAL; + return (EINVAL); } DPRINTF("Found the context: %lx -> %p", (unsigned long)args->ctx, pctx); @@ -738,7 +732,7 @@ /* Free destroyed context */ uma_zfree(linux_aio_context_zone, pctx); - return nerr; + return (nerr); } /* Linux system call io_getevents(2) */ @@ -764,20 +758,20 @@ LINK_TO_NATIVE_AIO_MODULE(); if (args->nr <= 0) - return EINVAL; + return (EINVAL); if (args->min_nr < 0) - return EINVAL; + return (EINVAL); nerr = user_mem_rw_verify(args->events, sizeof(*(args->events)) * args->nr); if (nerr != 0) - return nerr; + return (nerr); if (args->timeout != NULL) { nerr = copyin(args->timeout, &l_timeout, sizeof(l_timeout)); if (nerr != 0) - return nerr; + return (nerr); timeout.tv_sec = l_timeout.tv_sec; timeout.tv_nsec = l_timeout.tv_nsec; DUMP_TIMESPEC("User specified timeout: ", &timeout, ""); @@ -813,7 +807,7 @@ /* Unable to find the context */ if (pctx == NULL) { LINUX_AIO_UNLOCK(p); - return EINVAL; + return (EINVAL); } DPRINTF("Found the context: %lx -> %p", (unsigned long)args->ctx_id, pctx); @@ -1020,7 +1014,7 @@ LINUX_AIO_CTX_UNLOCK(pctx); - return nerr; + return (nerr); } /* Linux system call io_submit(2) */ @@ -1037,8 +1031,8 @@ (long)args->nr, args->iocbpp); LINK_TO_NATIVE_AIO_MODULE(); - if(args->nr <= 0) - return EINVAL; + if (args->nr <= 0) + return (EINVAL); p = td->td_proc; @@ -1070,7 +1064,7 @@ /* Unable to find the context */ if (pctx == NULL) { LINUX_AIO_UNLOCK(p); - return EINVAL; + return (EINVAL); } DPRINTF("Found the context: %lx -> %p", (unsigned long)args->ctx_id, pctx); @@ -1132,7 +1126,7 @@ if (i == 0 && nerr == 0) nerr = EAGAIN; /* No request is successfully submitted */ - return nerr; + return (nerr); } /* Linux system call io_cancel(2) */ @@ -1152,11 +1146,11 @@ nerr = copyin(args->iocb, &lcb, sizeof(lcb)); if (nerr != 0) - return nerr; + return (nerr); nerr = user_mem_rw_verify(args->result, sizeof(*(args->result))); if (nerr != 0) - return nerr; + return (nerr); p = td->td_proc; @@ -1188,7 +1182,7 @@ /* Unable to find the context */ if (pctx == NULL) { LINUX_AIO_UNLOCK(p); - return EINVAL; + return (EINVAL); } DPRINTF("Found the context: %lx -> %p", (unsigned long)args->ctx_id, pctx); @@ -1247,7 +1241,7 @@ LINUX_AIO_CTX_UNLOCK(pctx); - return nerr; + return (nerr); } static void linux_aio_proc_rundown(void *arg, struct proc *p) @@ -1289,8 +1283,6 @@ } LINUX_AIO_CTX_LIST_UNLOCK(); - - return; } /* @@ -1330,8 +1322,7 @@ mtx_destroy(&linux_aio_context_list_mtx); uma_zdestroy(linux_aio_request_zone); uma_zdestroy(linux_aio_context_zone); - if (native_aio_module_handle != NULL) - { + if (native_aio_module_handle != NULL) { /* * linker_release_module() cannot be used here. * It tries to hold "kld_sx", conflicting against ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_aio.h#3 (text+ko) ==== @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2006 Intron . All rights reserved. + * Copyright (c) 2006 Li, Xiao . All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -22,7 +22,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/linuxaio/linux_aio.h,v 1.8 2006/09/25 19:12:31 admin Exp $ */ /* From owner-p4-projects@FreeBSD.ORG Mon Sep 25 22:10:20 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0BEB716A47B; Mon, 25 Sep 2006 22:10:20 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 DC26F16A416 for ; Mon, 25 Sep 2006 22:10:19 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8885E43D53 for ; Mon, 25 Sep 2006 22:10:19 +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.6/8.13.6) with ESMTP id k8PMAJkB025610 for ; Mon, 25 Sep 2006 22:10:19 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PMAJGo025607 for perforce@freebsd.org; Mon, 25 Sep 2006 22:10:19 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Mon, 25 Sep 2006 22:10:19 GMT Message-Id: <200609252210.k8PMAJGo025607@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 Cc: Subject: PERFORCE change 106685 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 22:10:20 -0000 http://perforce.freebsd.org/chv.cgi?CH=106685 Change 106685 by rwatson@rwatson_fledge on 2006/09/25 22:09:55 Update TrustedBSD documentation list to reflect FreeBSD handbook change. Affected files ... .. //depot/projects/trustedbsd/www/docs.bib#5 edit Differences ... ==== //depot/projects/trustedbsd/www/docs.bib#5 (text+ko) ==== @@ -35,7 +35,7 @@ - $P4: //depot/projects/trustedbsd/www/docs.bib#4 $ + $P4: //depot/projects/trustedbsd/www/docs.bib#5 $ @@ -205,8 +205,12 @@ Tom Rhodes + FreeBSD Project + - FreeBSD Project + + Robert Watson + TrustedBSD Project From owner-p4-projects@FreeBSD.ORG Mon Sep 25 22:37:55 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 966A416A4A0; Mon, 25 Sep 2006 22:37:55 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 7263416A492 for ; Mon, 25 Sep 2006 22:37:55 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1F35A43D55 for ; Mon, 25 Sep 2006 22:37:55 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PMbtFN027985 for ; Mon, 25 Sep 2006 22:37:55 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PMbsUk027982 for perforce@freebsd.org; Mon, 25 Sep 2006 22:37:54 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 22:37:54 GMT Message-Id: <200609252237.k8PMbsUk027982@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106687 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 22:37:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=106687 Change 106687 by imp@imp_lighthouse on 2006/09/25 22:37:41 Make these compile Affected files ... .. //depot/projects/arm/src/sys/conf/files#45 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#2 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcbus_if.m#2 edit Differences ... ==== //depot/projects/arm/src/sys/conf/files#45 (text+ko) ==== @@ -753,6 +753,8 @@ dev/mlx/mlx_pci.c optional mlx pci dev/mly/mly.c optional mly dev/mmc/mmc.c optional mmc +dev/mmc/mmcbr_if.m optional mmc +dev/mmc/mmcbus_if.m optional mmc dev/mmc/mmcsd.c optional mmcsd dev/mpt/mpt.c optional mpt dev/mpt/mpt_cam.c optional mpt ==== //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#2 (text+ko) ==== @@ -26,23 +26,24 @@ # $FreeBSD$ # +#include #include +#include # # This is the interface that a mmc bridge chip gives to the mmc bus # that attaches to the mmc bridge. # -INTERFACE mmcbr +INTERFACE mmcbr; # # Called by the mmcbus to setup the IO pins correctly, the voltage to use # for the card, the type of selects, power modes and bus width. # -METHOD int set_ios { +METHOD int update_ios { device_t brdev; device_t reqdev; - struct mmc_ios *iostate; }; # @@ -54,7 +55,7 @@ METHOD int request { device_t brdev; device_t reqdev; - struct mmc_req *req; + struct mmc_request *req; }; # @@ -66,23 +67,6 @@ }; # -# Called by mmcbus to get the capabilities of this bridge. These are defined -# with names starting as MMC_CAP_*. -# -METHOD uint32_t get_cap { - device_t brdev; - device_t reqdev; -}; - -# -# Get the current card mode of this bridge. -# -METHOD enum mmc_card_mode get_card_mode { - device_t brdev; - device_t reqdev; -}; - -# # Claim the current bridge, blocking the current thread until the host # is no longer busy. The method is called claim_host because the # Linux interface has a mmc_claim_host function. ==== //depot/projects/arm/src/sys/dev/mmc/mmcbus_if.m#2 (text+ko) ==== @@ -34,7 +34,7 @@ # that mmc/sd card drivers call to make requests. # -INTERFACE mmcbus +INTERFACE mmcbus; # # Called by the mmcbr devices when a mmc_request has completed @@ -42,6 +42,6 @@ METHOD int xfer_done { device_t brdev; device_t reqdev; - struct mmc_req *req; + struct mmc_request *req; int status; }; From owner-p4-projects@FreeBSD.ORG Mon Sep 25 22:57:19 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id CC17E16A4A7; Mon, 25 Sep 2006 22:57:19 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 9067C16A494 for ; Mon, 25 Sep 2006 22:57:19 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 615EF43D49 for ; Mon, 25 Sep 2006 22:57:19 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PMvJ2W029045 for ; Mon, 25 Sep 2006 22:57:19 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PMvJDp029042 for perforce@freebsd.org; Mon, 25 Sep 2006 22:57:19 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 22:57:19 GMT Message-Id: <200609252257.k8PMvJDp029042@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106688 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 22:57:20 -0000 http://perforce.freebsd.org/chv.cgi?CH=106688 Change 106688 by imp@imp_lighthouse on 2006/09/25 22:56:59 Tweak Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#3 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcbus_if.m#3 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#3 (text+ko) ==== @@ -68,17 +68,15 @@ # # Claim the current bridge, blocking the current thread until the host -# is no longer busy. The method is called claim_host because the -# Linux interface has a mmc_claim_host function. +# is no longer busy. # -METHOD int claim_host { +METHOD int aquire_host { device_t brdev; device_t reqdev; } # -# Release the current bridge. The method is called release_host because the -# Linux interface has a mmc_release_host function. +# Release the current bridge. # METHOD int release_host { device_t brdev; ==== //depot/projects/arm/src/sys/dev/mmc/mmcbus_if.m#3 (text+ko) ==== @@ -45,3 +45,20 @@ struct mmc_request *req; int status; }; + +# +# Claim the current bridge, blocking the current thread until the host +# is no longer busy. +# +METHOD int aquire_bus { + device_t brdev; + device_t reqdev; +} + +# +# Release the current bridge. +# +METHOD int release_bus { + device_t brdev; + device_t reqdev; +} From owner-p4-projects@FreeBSD.ORG Mon Sep 25 22:58:21 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id BBCEC16A412; Mon, 25 Sep 2006 22:58:21 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 8207616A403 for ; Mon, 25 Sep 2006 22:58:21 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4BC6743D46 for ; Mon, 25 Sep 2006 22:58:21 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8PMwL95029102 for ; Mon, 25 Sep 2006 22:58:21 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8PMwKRc029099 for perforce@freebsd.org; Mon, 25 Sep 2006 22:58:20 GMT (envelope-from imp@freebsd.org) Date: Mon, 25 Sep 2006 22:58:20 GMT Message-Id: <200609252258.k8PMwKRc029099@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106689 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Sep 2006 22:58:22 -0000 http://perforce.freebsd.org/chv.cgi?CH=106689 Change 106689 by imp@imp_lighthouse on 2006/09/25 22:57:32 checkpoint Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/bridge.h#3 edit .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#3 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcbrvar.h#1 add Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/bridge.h#3 (text+ko) ==== @@ -59,6 +59,10 @@ vdd_330, vdd_340, vdd_350, vdd_360 }; +enum mmc_poewr_mode { + power_off = 0, power_up, power_on +}; + enum mmc_bus_mode { opendrain = 1, pushpull }; @@ -68,7 +72,7 @@ }; enum mmc_bus_width { - bus_width_1 = 0, bus_width_4 = 2 + bus_width_1 = 0, bus_width_4 = 2, bus_width_8 = 3 }; struct mmc_ios { @@ -91,6 +95,7 @@ #define MMC_CAP_4_BIT_DATA (1 << 0) /* Can do 4-bit data transfers */ #define MMC_CAP_8_BIT_DATA (1 << 1) /* Can do 8-bit data transfers */ enum mmc_card_mode mode; + struct mmc_ios ios; /* Current state of the host */ }; #endif /* DEV_MMC_BRIDGE_H */ ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#3 (text+ko) ==== @@ -36,6 +36,9 @@ #include #include +#include +#include "mmcbr_if.h" +#include "mmcbus_if.h" struct mmc_softc { device_t dev; @@ -90,12 +93,109 @@ return (EBUSY); /* XXX */ } +static int +mmcbr_update_ios(device_t dev) +{ + return (MMCBR_UPDATE_IOS(device_get_parent(dev), dev)); +} + +static void +mmc_rescan_cards(struct mmc_softc *sc) +{ + /* XXX: Look at the children and see if they respond to status */ +} + +static void +mmc_power_up(struct mmc_softc *sc) +{ + device_t dev; + + dev = sc->dev; + mmcbr_set_vdd(dev, mmc_highest_voltage(mmcbr_get_host_ocr(dev))); + mmcbr_set_bus_mode(dev, opendrain); + mmcbr_set_chip_select(dev, cs_dontcare); + mmcbr_set_bus_width(dev, bus_width_1); + mmcbr_set_power_mode(dev, power_up); + mmcbr_set_clock(dev, 0); + mmcbr_update_ios(dev); + + // delay 1ms ? + + mmcbr_set_clock(dev, mmcbr_get_f_min(sc->dev)); + mmcbr_set_power_mode(dev, power_on); + mmcbr_update_ios(dev); + + // delay 2ms ? +} + +static void +mmc_go_discovery(struct mmc_softc *sc) +{ + uint32_t ocr; + device_t dev; + + dev = sc->dev; + if (mmcbr_get_power_mode(dev) != power_on) { + // First, try SD modes + mmcbr_set_mode(dev, mode_sd); + mmc_power_up(sc); + mmc_idle_cards(sc); + if (mmc_send_app_op_cond(sc, 0, &ocr)) { + // Failed, try MMC + mmcbr_set_mode(dev, mode_mmc); + if (mmc_send_op_cond(sc, 0, &ocr)) + return; // Failed both, punt! XXX power down? + } + mmcbr_set_ocr(dev, mmc_select_vdd(sc, ocr)); + if (mmcbr_get_ocr(dev) != 0) + mmc_idle_cards(sc); + } else { + mmcbr_set_bus_mode(dev, opendrain); + mmcbr_set_clock(dev, mmcbr_get_f_min(dev)); + mmcbr_update_ios(dev); + // XXX recompute vdd based on new cards? + } + /* + * Make sure that we have a mutually agreeable voltage to at least + * one card on the bus. + */ + if (mmcbr_get_ocr(dev) == 0) + return; + /* XXX Linux re-sends op_cond command here */ + mmc_discover_cards(sc); + + mmcbr_set_bus_mode(dev, pushpull); + mmcbr_update_ios(dev); + mmc_read_csds(sc); + if (mmcbr_get_mode(dev) == mode_sd) + mmc_read_scrs(sc); +} + static void +mmc_scan(struct mmc_softc *sc) +{ + device_t dev; + + dev = sc->dev; + mmc_aquire_bus(sc); + + if (mmcbr_get_power_mode(dev) == power_on) + mmc_rescan_cards(sc); + mmc_go_discovery(sc); + mmcbr_set_clock(dev, mmc_calculate_clock(sc)); + mmcbr_update_ios(dev); + + mmc_release_bus(sc); + // XXX probe/attach/detach children? +} + +static void mmc_delayed_attach(void *xsc) { struct mmc_softc *sc = xsc; device_printf(sc->dev, "insert mmc/sd probe code here\n"); + mmc_scan(sc); config_intrhook_disestablish(&sc->config_intrhook); } From owner-p4-projects@FreeBSD.ORG Tue Sep 26 03:27:16 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id A387916A416; Tue, 26 Sep 2006 03:27:16 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 65E5616A40F for ; Tue, 26 Sep 2006 03:27:16 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1ABC243D58 for ; Tue, 26 Sep 2006 03:27:16 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8Q3RFpP059810 for ; Tue, 26 Sep 2006 03:27:15 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8Q3RFJ8059807 for perforce@freebsd.org; Tue, 26 Sep 2006 03:27:15 GMT (envelope-from mjacob@freebsd.org) Date: Tue, 26 Sep 2006 03:27:15 GMT Message-Id: <200609260327.k8Q3RFJ8059807@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106697 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 03:27:16 -0000 http://perforce.freebsd.org/chv.cgi?CH=106697 Change 106697 by mjacob@newisp on 2006/09/26 03:27:01 Add plogx CMD FLag definitions for some vague notion of program clarity. Affected files ... .. //depot/projects/newisp/dev/isp/ispmbox.h#6 edit Differences ... ==== //depot/projects/newisp/dev/isp/ispmbox.h#6 (text+ko) ==== @@ -201,6 +201,8 @@ #define ASYNC_PDB_CHANGED 0x8014 #define ASYNC_CHANGE_NOTIFY 0x8015 #define ASYNC_LIP_F8 0x8016 +#define ASYNC_LIP_ERROR 0x8017 +#define ASYNC_SECURITY_UPDATE 0x801B #define ASYNC_CMD_CMPLT 0x8020 #define ASYNC_CTIO_DONE 0x8021 #define ASYNC_IP_XMIT_DONE 0x8022 @@ -223,11 +225,16 @@ #define ISP_CONN_LOOPBACK 5 #define ASYNC_RIO_RESP 0x8040 #define ASYNC_RIO_COMP 0x8042 +#define ASYNC_RCV_ERR 0x8048 /* * 2.01.31 2200 Only. Need Bit 13 in Mailbox 1 for Set Firmware Options * mailbox command to enable this. */ #define ASYNC_QFULL_SENT 0x8049 +/* + * 24XX only + */ +#define ASYNC_RJT_SENT 0x8049 /* * Mailbox Usages @@ -1129,6 +1136,7 @@ #define PLOGX_STATUS_UNAVAIL 0x28 #define PLOGX_STATUS_LOGOUT 0x29 #define PLOGX_STATUS_IOCBERR 0x31 + #define PLOGX_IOCBERR_NOLINK 0x01 #define PLOGX_IOCBERR_NOIOCB 0x02 #define PLOGX_IOCBERR_NOXGHG 0x03 @@ -1144,6 +1152,25 @@ #define PLOGX_IOCBERR_NOHANDLE 0x1c #define PLOGX_IOCBERR_NOFLOGI 0x1f /* further info in IOPARM 1 */ +#define PLOGX_FLG_CMD_MASK 0xf +#define PLOGX_FLG_CMD_PLOGI 0 +#define PLOGX_FLG_CMD_PRLI 1 +#define PLOGX_FLG_CMD_PDISC 2 +#define PLOGX_FLG_CMD_LOGO 8 +#define PLOGX_FLG_CMD_PRLO 9 +#define PLOGX_FLG_CMD_TPRLO 10 + +#define PLOGX_FLG_COND_PLOGI 0x10 /* if with PLOGI */ +#define PLOGX_FLG_IMPLICIT 0x10 /* if with LOGO, PRLO, TPRLO */ +#define PLOGX_FLG_SKIP_PRLI 0x20 /* if with PLOGI */ +#define PLOGX_FLG_IMPLICIT_LOGO_ALL 0x20 /* if with LOGO */ +#define PLOGX_FLG_EXPLICIT_LOGO 0x40 /* if with LOGO */ +#define PLOGX_FLG_COMMON_FEATURES 0x80 /* if with PLOGI */ +#define PLOGX_FLG_FREE_NPHDL 0x80 /* if with with LOGO */ + +#define PLOGX_FLG_CLASS2 0x100 /* if with PLOGI */ +#define PLOGX_FLG_FCP2_OVERRIDE 0x200 /* if with PRLOG, PRLI */ + /* * Simple Name Server Data Structures */ From owner-p4-projects@FreeBSD.ORG Tue Sep 26 03:28:18 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 4E61516A4EC; Tue, 26 Sep 2006 03:28:18 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 2CB2516A407 for ; Tue, 26 Sep 2006 03:28:18 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id EE7D743D46 for ; Tue, 26 Sep 2006 03:28:17 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8Q3SHhg059850 for ; Tue, 26 Sep 2006 03:28:17 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8Q3SHb4059847 for perforce@freebsd.org; Tue, 26 Sep 2006 03:28:17 GMT (envelope-from mjacob@freebsd.org) Date: Tue, 26 Sep 2006 03:28:17 GMT Message-Id: <200609260328.k8Q3SHb4059847@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106698 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 03:28:18 -0000 http://perforce.freebsd.org/chv.cgi?CH=106698 Change 106698 by mjacob@newisp on 2006/09/26 03:27:33 Add data direction bit definitions for FCP CMND IU. Affected files ... .. //depot/projects/newisp/dev/isp/isp_stds.h#3 edit Differences ... ==== //depot/projects/newisp/dev/isp/isp_stds.h#3 (text+ko) ==== @@ -61,7 +61,8 @@ * * Notes: * When additional cdb length is defined in fcp_cmnd_alen_datadir, - * bits 2..7, the actual cdb length is 16 + ((fcp_cmnd_alen_datadir>>2)*4), * with the datalength following in MSB format just after. + * bits 2..7, the actual cdb length is 16 + ((fcp_cmnd_alen_datadir>>2)*4), + * with the datalength following in MSB format just after. */ typedef struct { uint8_t fcp_cmnd_lun[8]; @@ -88,6 +89,9 @@ #define FCP_CMND_TASK_ATTR_ACA 0x04 #define FCP_CMND_TASK_ATTR_UNTAGGED 0x05 +#define FCP_CMND_DATA_WRITE 0x01 +#define FCP_CMND_DATA_READ 0x02 + #define FCP_CMND_TMF_ABORT_CLEAR_ACA 0x40 #define FCP_CMND_TMF_ABORT_TGT_RESET 0x20 #define FCP_CMND_TMF_ABORT_LUN_RESET 0x10 From owner-p4-projects@FreeBSD.ORG Tue Sep 26 03:28:19 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id CAA2316A57E; Tue, 26 Sep 2006 03:28:18 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 8E3B816A57C for ; Tue, 26 Sep 2006 03:28:18 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4F10A43D46 for ; Tue, 26 Sep 2006 03:28:18 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8Q3SIfN059856 for ; Tue, 26 Sep 2006 03:28:18 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8Q3SHO5059853 for perforce@freebsd.org; Tue, 26 Sep 2006 03:28:17 GMT (envelope-from mjacob@freebsd.org) Date: Tue, 26 Sep 2006 03:28:17 GMT Message-Id: <200609260328.k8Q3SHO5059853@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106699 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 03:28:19 -0000 http://perforce.freebsd.org/chv.cgi?CH=106699 Change 106699 by mjacob@newisp on 2006/09/26 03:28:12 Make Fabric device chattiness fit within 80 columns. Affected files ... .. //depot/projects/newisp/dev/isp/isp_freebsd.c#8 edit Differences ... ==== //depot/projects/newisp/dev/isp/isp_freebsd.c#8 (text+ko) ==== @@ -2886,10 +2886,10 @@ "(none)", "Target", "Initiator", "Target/Initiator" }; static const char prom[] = - "PortID 0x%06x N-port Handle %u pdb_idx %lu role %s %s\n" + "PortID 0x%06x N-port Handle %u role %s %s\n" " WWNN 0x%08x%08x WWPN 0x%08x%08x"; static const char prom2[] = - "PortID 0x%06x N-port Handle %u pdb_idx %lu role %s %s tgt %u\n" + "PortID 0x%06x N-port Handle %u role %s %s tgt %u\n" " WWNN 0x%08x%08x WWPN 0x%08x%08x"; target_id_t tgt; fcportdb_t *lp; @@ -3034,7 +3034,6 @@ tgt = lp->ini_map_idx - 1; isp_prt(isp, ISP_LOGCONFIG, prom2, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "arrived at", tgt, (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, @@ -3055,7 +3054,6 @@ } else { isp_prt(isp, ISP_LOGCONFIG, prom, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "arrived", (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, @@ -3069,7 +3067,6 @@ tgt = lp->ini_map_idx - 1; isp_prt(isp, ISP_LOGCONFIG, prom2, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "changed at", tgt, (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, @@ -3078,7 +3075,6 @@ } else { isp_prt(isp, ISP_LOGCONFIG, prom, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "changed", (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, @@ -3092,7 +3088,6 @@ tgt = lp->ini_map_idx - 1; isp_prt(isp, ISP_LOGCONFIG, prom2, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "stayed at", tgt, (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, @@ -3101,7 +3096,6 @@ } else { isp_prt(isp, ISP_LOGCONFIG, prom, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "stayed", (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, @@ -3115,7 +3109,6 @@ tgt = lp->ini_map_idx - 1; isp_prt(isp, ISP_LOGCONFIG, prom2, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "departed from", tgt, (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, @@ -3136,7 +3129,6 @@ } else { isp_prt(isp, ISP_LOGCONFIG, prom, lp->portid, lp->handle, - (unsigned long) (lp - FCPARAM(isp)->portdb), roles[lp->roles & 0x3], "departed", (uint32_t) (lp->node_wwn >> 32), (uint32_t) lp->node_wwn, From owner-p4-projects@FreeBSD.ORG Tue Sep 26 03:32:24 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 621F616A412; Tue, 26 Sep 2006 03:32:24 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 083ED16A407 for ; Tue, 26 Sep 2006 03:32:24 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C8BED43D53 for ; Tue, 26 Sep 2006 03:32:23 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8Q3WNG2060136 for ; Tue, 26 Sep 2006 03:32:23 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8Q3WNnH060133 for perforce@freebsd.org; Tue, 26 Sep 2006 03:32:23 GMT (envelope-from imp@freebsd.org) Date: Tue, 26 Sep 2006 03:32:23 GMT Message-Id: <200609260332.k8Q3WNnH060133@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106700 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 03:32:24 -0000 http://perforce.freebsd.org/chv.cgi?CH=106700 Change 106700 by imp@imp_lighthouse on 2006/09/26 03:32:20 Compile Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#4 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#4 (text+ko) ==== @@ -93,6 +93,16 @@ return (EBUSY); /* XXX */ } +static void +mmc_acquire_bus(struct mmc_softc *sc) +{ +} + +static void +mmc_release_bus(struct mmc_softc *sc) +{ +} + static int mmcbr_update_ios(device_t dev) { @@ -105,6 +115,42 @@ /* XXX: Look at the children and see if they respond to status */ } +static uint32_t +mmc_select_vdd(struct mmc_softc *sc, uint32_t ocr) +{ +} + +static int +mmc_highest_voltage(uint32_t ocr) +{ + int i; + + for (i = 30; i >= 0; i--) + if (ocr & (1 << i)) + return i; + return (-1); +} + +static void +mmc_idle_cards(struct mmc_softc *sc) +{ + // XXX write me +} + +static int +mmc_send_app_op_cond(struct mmc_softc *sc, uint32_t rca, uint32_t *ocr) +{ + // XXX write me + return EIO; +} + +static int +mmc_send_op_cond(struct mmc_softc *sc, uint32_t rca, uint32_t *ocr) +{ + // XXX write me + return EIO; +} + static void mmc_power_up(struct mmc_softc *sc) { @@ -129,6 +175,21 @@ } static void +mmc_discover_cards(struct mmc_softc *sc) +{ +} + +static void +mmc_read_csds(struct mmc_softc *sc) +{ +} + +static void +mmc_read_scrs(struct mmc_softc *sc) +{ +} + +static void mmc_go_discovery(struct mmc_softc *sc) { uint32_t ocr; @@ -171,13 +232,20 @@ mmc_read_scrs(sc); } +static int +mmc_calculate_clock(struct mmc_softc *sc) +{ + // XXX write me + return 0; +} + static void mmc_scan(struct mmc_softc *sc) { device_t dev; dev = sc->dev; - mmc_aquire_bus(sc); + mmc_acquire_bus(sc); if (mmcbr_get_power_mode(dev) == power_on) mmc_rescan_cards(sc); From owner-p4-projects@FreeBSD.ORG Tue Sep 26 03:33:29 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id EFE3616A412; Tue, 26 Sep 2006 03:33:28 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 C8E6C16A407 for ; Tue, 26 Sep 2006 03:33:28 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id E780043D64 for ; Tue, 26 Sep 2006 03:33:25 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8Q3XPpu060213 for ; Tue, 26 Sep 2006 03:33:25 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8Q3XPXW060210 for perforce@freebsd.org; Tue, 26 Sep 2006 03:33:25 GMT (envelope-from mjacob@freebsd.org) Date: Tue, 26 Sep 2006 03:33:25 GMT Message-Id: <200609260333.k8Q3XPXW060210@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106701 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 03:33:29 -0000 http://perforce.freebsd.org/chv.cgi?CH=106701 Change 106701 by mjacob@newisp on 2006/09/26 03:32:36 Make the 24XX port login/logout function less chatty. Make both 24XX and other port login routines return the handle for MBOX_PORT_ID_USED failures in the top 16 bits because .... ... When we're scanning a fabric and we try and log a port id into a handle and get back an error that says "this port id is using this other handle already", we should just use that handle. We may need to do some cleanup later. When thinking about logging into a port, see if we're already logged in. Make a function that gives you the next possible handle you could use, based upon the previously used handle (0xffff being the 'start' handle) and the hardware. There is no reason to limit ourselves for 2K logins. When cleaning out old handles in isp_pdb_sync and we have a ISP_24XX, do *implicit* LOGO with FREE NPHDL- no need to go out on the wire. Limit timeout to 8191 seconds for the 24XX part. *Shrug*. Affected files ... .. //depot/projects/newisp/dev/isp/isp.c#13 edit Differences ... ==== //depot/projects/newisp/dev/isp/isp.c#13 (text+ko) ==== @@ -124,6 +124,7 @@ static int isp_scan_fabric(ispsoftc_t *); static int isp_register_fc4_type(ispsoftc_t *); static int isp_register_fc4_type_24xx(ispsoftc_t *); +static uint16_t isp_nxt_handle(ispsoftc_t *, uint16_t); static void isp_fw_state(ispsoftc_t *); static void isp_mboxcmd_qnw(ispsoftc_t *, mbreg_t *, int); static void isp_mboxcmd(ispsoftc_t *, mbreg_t *, int); @@ -2153,10 +2154,10 @@ "PLOGX failed: invalid parameter at offset 0x%x", parm1); break; case PLOGX_IOCBERR_PORTUSED: - isp_prt(isp, ISP_LOGERR, + isp_prt(isp, ISP_LOGDEBUG0, "portid 0x%x already logged in with N-port handle 0x%x", portid, parm1); - *log_ret = MBOX_PORT_ID_USED; + *log_ret = MBOX_PORT_ID_USED | (handle << 16); break; case PLOGX_IOCBERR_HNDLUSED: isp_prt(isp, ISP_LOGDEBUG0, @@ -2198,10 +2199,10 @@ switch (mbs.param[0]) { case MBOX_PORT_ID_USED: - isp_prt(isp, ISP_LOGERR, + isp_prt(isp, ISP_LOGDEBUG0, "isp_port_login: portid 0x%06x already logged in as %u", portid, mbs.param[1]); - return (MBOX_PORT_ID_USED); + return (MBOX_PORT_ID_USED | (mbs.param[1] << 16)); break; case MBOX_LOOP_ID_USED: @@ -2226,7 +2227,8 @@ default: isp_prt(isp, ISP_LOGERR, - "isp_port_login: error 0x%x on port login", mbs.param[0]); + "isp_port_login: error 0x%x on port login of 0x%06x@0x%0x", + mbs.param[0], portid, handle); return (mbs.param[0]); } } @@ -2662,9 +2664,13 @@ lp->state = FC_PORTDB_STATE_NIL; if (lp->autologin == 0) { if (IS_24XX(isp)) { + int action = + PLOGX_FLG_CMD_LOGO | + PLOGX_FLG_IMPLICIT | + PLOGX_FLG_FREE_NPHDL; FC_SCRATCH_ACQUIRE(isp); isp_plogx_24xx(isp, lp->handle, - lp->portid, NULL); + lp->portid, &action); FC_SCRATCH_RELEASE(isp); } else { isp_port_logout(isp, lp->handle, @@ -3160,6 +3166,7 @@ { fcparam *fcp = FCPARAM(isp); uint32_t portid; + uint16_t handle, oldhandle; int portidx, portlim, r; sns_gid_ft_rsp_t *rs0, *rs1; @@ -3227,6 +3234,11 @@ fcp->portdb[FL_ID].state = FC_PORTDB_STATE_PENDING_VALID; /* + * Prime the handle we will start using. + */ + oldhandle = 0xffff; + + /* * Okay, we now have a list of Port IDs for all FC4 SCSI devices * that the Fabric Name server knows about. Go through the list * and remove duplicate port ids. @@ -3294,12 +3306,12 @@ * WWNN/WWPN duple, we enter the device into our database. */ + for (portidx = 0; portidx < portlim; portidx++) { fcportdb_t *lp; - uint16_t handle; isp_pdb_t pdb; uint64_t wwnn, wwpn; - int base, dbidx, r, nr; + int base, dbidx, r, nr, lim; portid = ((rs1->snscb_ports[portidx].portid[0]) << 16) | @@ -3471,43 +3483,50 @@ if (dbidx == MAX_FC_TARG) { isp_prt(isp, ISP_LOGERR, - "port database too small to login fabric device"); + "port database too small to login fabric device" + "- increase MAX_FC_TARG"); continue; } - /* - * Start the handle at the database index and search for - * a handle that the f/w will like us to use. - */ - handle = dbidx; - for (r = 0; r < MAX_FC_TARG; r++) { + if (IS_24XX(isp)) { + lim = 0xffff; + } else { + lim = MAX_FC_TARG; + } + handle = isp_nxt_handle(isp, oldhandle); + for (r = 0; r < lim; r++) { int logval; - if (handle >= FL_ID && handle <= SNS_ID) { - if (++handle == MAX_FC_TARG) { - handle = 0; - } - continue; - } /* - * Try and log out of the device first. + * See if we're still logged into something with + * this handle and that something agrees with this + * port id. */ - if (IS_24XX(isp)) { - logval = 0xc8; - isp_plogx_24xx(isp, handle, portid, &logval); - } else { - isp_port_logout(isp, handle, portid); + r = isp_getpdb(isp, handle, &pdb, 0); + if (r == 0 && pdb.portid != portid) { + if (IS_24XX(isp)) { + logval = + PLOGX_FLG_CMD_LOGO | + PLOGX_FLG_IMPLICIT; + isp_plogx_24xx(isp, handle, portid, + &logval); + } else { + isp_port_logout(isp, handle, portid); + } + } else if (r == 0) { + break; } if (fcp->isp_loopstate != LOOP_SCANNING_FABRIC) { FC_SCRATCH_RELEASE(isp); isp_mark_portdb(isp, 1); return (-1); } + /* - * Try and log into the device. + * Now try and log into the device */ if (IS_24XX(isp)) { - logval = 0; + logval = PLOGX_FLG_CMD_PLOGI; isp_plogx_24xx(isp, handle, portid, &logval); } else { logval = isp_port_login(isp, handle, portid); @@ -3518,20 +3537,21 @@ return (-1); } if (logval == 0) { + oldhandle = handle; + break; + } else if ((logval & 0xffff) == MBOX_PORT_ID_USED) { + handle = logval >> 16; break; - } - if (logval == MBOX_LOOP_ID_USED) { - if (++handle == MAX_FC_TARG) { - handle = 0; - } - continue; + } else if (logval != MBOX_LOOP_ID_USED) { + r = lim; + break; } else { - r = MAX_FC_TARG; - break; + oldhandle = handle; + handle = isp_nxt_handle(isp, oldhandle); } } - if (r == MAX_FC_TARG) { + if (r == lim) { isp_prt(isp, ISP_LOGERR, "could not log PortID 0x%06x in", portid); continue; @@ -3550,22 +3570,15 @@ } if (r != 0) { isp_prt(isp, ISP_LOGERR, - "newly logged in device disappeared"); + "new device 0x%06x@0x%x disappeared", + portid, handle); continue; } if (pdb.handle != handle || pdb.portid != portid) { isp_prt(isp, ISP_LOGERR, - "newly logged in device changed already"); - isp_prt(isp, ISP_LOGERR, - "handle %x portid %x pdb.handle %x pdb.portid %x", - handle, portid, pdb.handle, pdb.portid); - if (IS_24XX(isp)) { - isp_plogx_24xx(isp, pdb.handle, pdb.portid, - NULL); - } else { - isp_port_logout(isp, pdb.handle, pdb.portid); - } + "new device 0x%06x@0x%x changed (0x%06x@0x%0x", + portid, handle, pdb.portid, pdb.handle); if (fcp->isp_loopstate != LOOP_SCANNING_FABRIC) { FC_SCRATCH_RELEASE(isp); isp_mark_portdb(isp, 1); @@ -3580,7 +3593,7 @@ /* * And go through the database *one* more time to make sure - * that we do not make more thane one entry that has the same + * that we do not make more than one entry that has the same * WWNN/WWPN duple */ lp = &fcp->portdb[dbidx]; @@ -3767,6 +3780,36 @@ } } +static uint16_t +isp_nxt_handle(ispsoftc_t *isp, uint16_t handle) +{ + if (handle == 0xffff) { + if (FCPARAM(isp)->isp_topo == TOPO_F_PORT) { + handle = 0; + } else { + handle = SNS_ID+1; + } + } else { + handle += 1; + if (handle >= FL_ID && handle <= SNS_ID) { + handle = SNS_ID+1; + } else if (IS_24XX(isp)) { + if (handle == 0xffff) { + handle = 0; + } + } else { + if (handle == MAX_FC_TARG) { + handle = 0; + } + } + } + if (handle == FCPARAM(isp)->isp_loopid) { + return (isp_nxt_handle(isp, handle)); + } else { + return (handle); + } +} + /* * Start a command. Locking is assumed done in the caller. */ @@ -3999,6 +4042,9 @@ if (*tptr == 0 && XS_TIME(xs)) { *tptr = 1; } + if (IS_24XX(isp) && *tptr > 0x1999) { + *tptr = 0x1999; + } if (isp_save_xs(isp, xs, &handle)) { isp_prt(isp, ISP_LOGDEBUG0, "out of xflist pointers"); @@ -4534,11 +4580,13 @@ */ } if (sp->req_header.rqs_flags & RQSFLAG_BADHEADER) { - isp_prt(isp, ISP_LOGERR, "bad header flag"); + isp_print_bytes(isp, "bad header flag", + QENTRY_LEN, sp); buddaboom++; } if (sp->req_header.rqs_flags & RQSFLAG_BADPACKET) { - isp_prt(isp, ISP_LOGERR, "bad request packet"); + isp_print_bytes(isp, "bad request packet", + QENTRY_LEN, sp); buddaboom++; } } From owner-p4-projects@FreeBSD.ORG Tue Sep 26 03:42:40 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1013216A417; Tue, 26 Sep 2006 03:42:40 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 C5C0516A403 for ; Tue, 26 Sep 2006 03:42:39 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6251743D49 for ; Tue, 26 Sep 2006 03:42:39 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8Q3gdLu060804 for ; Tue, 26 Sep 2006 03:42:39 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8Q3gcjL060801 for perforce@freebsd.org; Tue, 26 Sep 2006 03:42:38 GMT (envelope-from mjacob@freebsd.org) Date: Tue, 26 Sep 2006 03:42:38 GMT Message-Id: <200609260342.k8Q3gcjL060801@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106702 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 03:42:40 -0000 http://perforce.freebsd.org/chv.cgi?CH=106702 Change 106702 by mjacob@newisp on 2006/09/26 03:42:06 IFC Affected files ... .. //depot/projects/newisp/amd64/conf/NOTES#2 integrate .. //depot/projects/newisp/amd64/ia32/ia32_sigtramp.S#2 integrate .. //depot/projects/newisp/bsm/audit_kevents.h#3 integrate .. //depot/projects/newisp/compat/freebsd32/freebsd32_proto.h#6 integrate .. //depot/projects/newisp/compat/freebsd32/freebsd32_syscall.h#6 integrate .. //depot/projects/newisp/compat/freebsd32/freebsd32_syscalls.c#6 integrate .. //depot/projects/newisp/compat/freebsd32/freebsd32_sysent.c#6 integrate .. //depot/projects/newisp/compat/freebsd32/syscalls.master#6 integrate .. //depot/projects/newisp/compat/linux/linux_file.c#3 integrate .. //depot/projects/newisp/compat/linux/linux_socket.c#2 integrate .. //depot/projects/newisp/conf/NOTES#4 integrate .. //depot/projects/newisp/conf/files#3 integrate .. //depot/projects/newisp/conf/files.amd64#3 integrate .. //depot/projects/newisp/conf/files.i386#2 integrate .. //depot/projects/newisp/dev/acpica/Osd/OsdHardware.c#2 integrate .. //depot/projects/newisp/dev/ata/ata-chipset.c#6 integrate .. //depot/projects/newisp/dev/bge/if_bge.c#6 integrate .. //depot/projects/newisp/dev/exca/exca.c#2 integrate .. //depot/projects/newisp/dev/ipmi/ipmi.c#2 integrate .. //depot/projects/newisp/dev/ipmi/ipmi_acpi.c#1 branch .. //depot/projects/newisp/dev/ipmi/ipmi_isa.c#1 branch .. //depot/projects/newisp/dev/ipmi/ipmi_kcs.c#1 branch .. //depot/projects/newisp/dev/ipmi/ipmi_pci.c#2 integrate .. //depot/projects/newisp/dev/ipmi/ipmi_smbios.c#2 integrate .. //depot/projects/newisp/dev/ipmi/ipmi_smbus.c#1 branch .. //depot/projects/newisp/dev/ipmi/ipmi_smic.c#1 branch .. //depot/projects/newisp/dev/ipmi/ipmi_ssif.c#1 branch .. //depot/projects/newisp/dev/ipmi/ipmivars.h#2 integrate .. //depot/projects/newisp/dev/mfi/mfi.c#5 integrate .. //depot/projects/newisp/dev/mfi/mfi_debug.c#1 branch .. //depot/projects/newisp/dev/mfi/mfivar.h#3 integrate .. //depot/projects/newisp/dev/sound/pcm/buffer.c#2 integrate .. //depot/projects/newisp/dev/sound/pcm/buffer.h#2 integrate .. //depot/projects/newisp/dev/sound/pcm/channel.c#2 integrate .. //depot/projects/newisp/dev/sound/pcm/channel.h#2 integrate .. //depot/projects/newisp/dev/sound/pcm/channel_if.m#2 integrate .. //depot/projects/newisp/dev/sound/pcm/dsp.c#2 integrate .. //depot/projects/newisp/dev/sound/pcm/dsp.h#2 integrate .. //depot/projects/newisp/dev/sound/pcm/mixer.c#2 integrate .. //depot/projects/newisp/dev/sound/pcm/mixer.h#2 integrate .. //depot/projects/newisp/dev/sound/pcm/sound.c#2 integrate .. //depot/projects/newisp/dev/sound/pcm/sound.h#2 integrate .. //depot/projects/newisp/i386/conf/NOTES#3 integrate .. //depot/projects/newisp/i386/i386/busdma_machdep.c#4 integrate .. //depot/projects/newisp/kern/init_main.c#2 integrate .. //depot/projects/newisp/kern/kern_descrip.c#2 integrate .. //depot/projects/newisp/kern/kern_event.c#2 integrate .. //depot/projects/newisp/kern/kern_proc.c#3 integrate .. //depot/projects/newisp/kern/tty.c#4 integrate .. //depot/projects/newisp/kern/tty_pty.c#2 integrate .. //depot/projects/newisp/kern/tty_tty.c#2 integrate .. //depot/projects/newisp/kern/vfs_aio.c#3 integrate .. //depot/projects/newisp/modules/ipmi/Makefile#2 integrate .. //depot/projects/newisp/modules/mfi/Makefile#2 integrate .. //depot/projects/newisp/net/if_bridge.c#3 integrate .. //depot/projects/newisp/netinet/if_ether.c#2 integrate .. //depot/projects/newisp/netinet/in_var.h#2 integrate .. //depot/projects/newisp/netinet/ip_carp.c#2 integrate .. //depot/projects/newisp/netinet/ip_output.c#4 integrate .. //depot/projects/newisp/netinet/ip_var.h#2 integrate .. //depot/projects/newisp/netinet/tcp_input.c#5 integrate .. //depot/projects/newisp/netinet/tcp_timer.h#3 integrate .. //depot/projects/newisp/security/audit/audit_worker.c#4 integrate .. //depot/projects/newisp/sys/copyright.h#2 integrate .. //depot/projects/newisp/sys/event.h#2 integrate .. //depot/projects/newisp/sys/ipmi.h#2 integrate .. //depot/projects/newisp/sys/mbuf.h#5 integrate .. //depot/projects/newisp/sys/param.h#5 integrate .. //depot/projects/newisp/sys/soundcard.h#2 integrate Differences ... ==== //depot/projects/newisp/amd64/conf/NOTES#2 (text+ko) ==== @@ -4,7 +4,7 @@ # This file contains machine dependent kernel configuration notes. For # machine independent notes, look in /sys/conf/NOTES. # -# $FreeBSD: src/sys/amd64/conf/NOTES,v 1.58 2006/07/29 18:38:53 marcel Exp $ +# $FreeBSD: src/sys/amd64/conf/NOTES,v 1.59 2006/09/22 22:11:28 jhb Exp $ # # @@ -346,6 +346,7 @@ # # Miscellaneous hardware: # +# ipmi: Intelligent Platform Management Interface # smbios: DMI/SMBIOS entry point # vpd: Vital Product Data kernel interface # cy: Cyclades serial driver @@ -368,6 +369,7 @@ device digi_Xe device digi_Xem device digi_Xr +device ipmi # Parallel (8255 PPI) basic I/O (mode 0) port (e.g. Advantech PCL-724) device pbio hint.pbio.0.at="isa" ==== //depot/projects/newisp/amd64/ia32/ia32_sigtramp.S#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/amd64/ia32/ia32_sigtramp.S,v 1.2 2003/08/22 23:19:02 peter Exp $ + * $FreeBSD: src/sys/amd64/ia32/ia32_sigtramp.S,v 1.3 2006/09/23 13:42:09 davidxu Exp $ */ #include "opt_compat.h" @@ -45,8 +45,6 @@ calll *IA32_SIGF_HANDLER(%esp) leal IA32_SIGF_UC(%esp),%eax /* get ucontext */ pushl %eax - movl IA32_UC_GS(%eax),%gs /* restore %gs */ - movl IA32_UC_FS(%eax),%fs /* restore %fs */ movl IA32_UC_ES(%eax),%es /* restore %es */ movl IA32_UC_DS(%eax),%ds /* restore %ds */ movl $SYS_sigreturn,%eax @@ -62,8 +60,6 @@ calll *IA32_SIGF_HANDLER(%esp) leal IA32_SIGF_UC4(%esp),%eax/* get ucontext */ pushl %eax - movl IA32_UC4_GS(%eax),%gs /* restore %gs */ - movl IA32_UC4_FS(%eax),%fs /* restore %fs */ movl IA32_UC4_ES(%eax),%es /* restore %es */ movl IA32_UC4_DS(%eax),%ds /* restore %ds */ movl $344,%eax /* 4.x SYS_sigreturn */ ==== //depot/projects/newisp/bsm/audit_kevents.h#3 (text) ==== @@ -30,8 +30,8 @@ * * @APPLE_BSD_LICENSE_HEADER_END@ * - * $P4: //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#28 $ - * $FreeBSD: src/sys/bsm/audit_kevents.h,v 1.8 2006/09/21 07:27:02 rwatson Exp $ + * $P4: //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#29 $ + * $FreeBSD: src/sys/bsm/audit_kevents.h,v 1.9 2006/09/25 12:22:07 rwatson Exp $ */ #ifndef _BSM_AUDIT_KEVENTS_H_ @@ -471,6 +471,10 @@ #define AUE_KENV 43114 /* FreeBSD. */ #define AUE_JAIL_ATTACH 43115 /* FreeBSD. */ #define AUE_SYSCTL_WRITE 43116 /* FreeBSD. */ +#define AUE_IOPERM 43117 /* Linux. */ +#define AUE_READDIR 43118 /* Linux. */ +#define AUE_IOPL 43119 /* Linux. */ +#define AUE_VM86 43120 /* Linux. */ /* * Darwin BSM uses a number of AUE_O_* definitions, which are aliased to the ==== //depot/projects/newisp/compat/freebsd32/freebsd32_proto.h#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call prototypes. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_proto.h,v 1.65 2006/09/22 15:05:33 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_proto.h,v 1.66 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ #ifndef _FREEBSD32_SYSPROTO_H_ ==== //depot/projects/newisp/compat/freebsd32/freebsd32_syscall.h#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscall.h,v 1.63 2006/09/22 15:05:33 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscall.h,v 1.64 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ #define FREEBSD32_SYS_syscall 0 @@ -300,6 +300,7 @@ #define FREEBSD32_SYS_freebsd32_getcontext 421 #define FREEBSD32_SYS_freebsd32_setcontext 422 #define FREEBSD32_SYS_freebsd32_swapcontext 423 +#define FREEBSD32_SYS_sigwait 429 #define FREEBSD32_SYS_thr_exit 431 #define FREEBSD32_SYS_thr_self 432 #define FREEBSD32_SYS_thr_kill 433 ==== //depot/projects/newisp/compat/freebsd32/freebsd32_syscalls.c#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call names. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscalls.c,v 1.54 2006/09/22 15:05:33 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_syscalls.c,v 1.55 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ const char *freebsd32_syscallnames[] = { @@ -436,7 +436,7 @@ "#426", /* 426 = __acl_set_link */ "#427", /* 427 = __acl_delete_link */ "#428", /* 428 = __acl_aclcheck_link */ - "#429", /* 429 = sigwait */ + "sigwait", /* 429 = sigwait */ "#430", /* 430 = thr_create; */ "thr_exit", /* 431 = thr_exit */ "thr_self", /* 432 = thr_self */ ==== //depot/projects/newisp/compat/freebsd32/freebsd32_sysent.c#6 (text+ko) ==== @@ -2,8 +2,8 @@ * System call switch table. * * DO NOT EDIT-- this file is automatically generated. - * $FreeBSD: src/sys/compat/freebsd32/freebsd32_sysent.c,v 1.64 2006/09/22 15:05:34 davidxu Exp $ - * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp + * $FreeBSD: src/sys/compat/freebsd32/freebsd32_sysent.c,v 1.65 2006/09/23 00:27:53 davidxu Exp $ + * created from FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp */ #include "opt_compat.h" @@ -461,7 +461,7 @@ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 426 = __acl_set_link */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 427 = __acl_delete_link */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 428 = __acl_aclcheck_link */ - { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 429 = sigwait */ + { AS(sigwait_args), (sy_call_t *)sigwait, AUE_SIGWAIT, NULL, 0, 0 }, /* 429 = sigwait */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 430 = thr_create; */ { AS(thr_exit_args), (sy_call_t *)thr_exit, AUE_NULL, NULL, 0, 0 }, /* 431 = thr_exit */ { AS(thr_self_args), (sy_call_t *)thr_self, AUE_NULL, NULL, 0, 0 }, /* 432 = thr_self */ ==== //depot/projects/newisp/compat/freebsd32/syscalls.master#6 (text+ko) ==== @@ -1,4 +1,4 @@ - $FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.78 2006/09/22 15:04:28 davidxu Exp $ + $FreeBSD: src/sys/compat/freebsd32/syscalls.master,v 1.79 2006/09/23 00:27:11 davidxu Exp $ ; from: @(#)syscalls.master 8.2 (Berkeley) 1/13/94 ; from: src/sys/kern/syscalls.master 1.107 ; @@ -714,7 +714,8 @@ 427 AUE_NULL UNIMPL __acl_delete_link 428 AUE_NULL UNIMPL __acl_aclcheck_link ; XXX implement -429 AUE_SIGWAIT UNIMPL sigwait +429 AUE_SIGWAIT NOPROTO { int sigwait(const sigset_t *set, \ + int *sig); } 430 AUE_NULL UNIMPL thr_create; 431 AUE_NULL NOPROTO { void thr_exit(long *state); } 432 AUE_NULL NOPROTO { int thr_self(long *id); } ==== //depot/projects/newisp/compat/linux/linux_file.c#3 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/compat/linux/linux_file.c,v 1.97 2006/09/10 13:47:56 netchild Exp $"); +__FBSDID("$FreeBSD: src/sys/compat/linux/linux_file.c,v 1.98 2006/09/23 19:06:54 netchild Exp $"); #include "opt_compat.h" #include "opt_mac.h" @@ -49,6 +49,7 @@ #include #include #include +#include #include #include @@ -480,6 +481,10 @@ char *path; int error; + /* linux convention */ + if (args->flags & ~(F_OK | X_OK | W_OK | R_OK)) + return (EINVAL); + LCONVPATHEXIST(td, args->path, &path); #ifdef DEBUG @@ -488,6 +493,7 @@ #endif error = kern_access(td, path, UIO_SYSSPACE, args->flags); LFREEPATH(path); + return (error); } @@ -724,12 +730,28 @@ struct linux_pread_args *uap; { struct pread_args bsd; + struct vnode *vp; + int error; bsd.fd = uap->fd; bsd.buf = uap->buf; bsd.nbyte = uap->nbyte; bsd.offset = uap->offset; - return pread(td, &bsd); + + error = pread(td, &bsd); + + if (error == 0) { + /* This seems to violate POSIX but linux does it */ + if ((error = fgetvp(td, uap->fd, &vp)) != 0) + return (error); + if (vp->v_type == VDIR) { + vrele(vp); + return (EISDIR); + } + vrele(vp); + } + + return (error); } int ==== //depot/projects/newisp/compat/linux/linux_socket.c#2 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/compat/linux/linux_socket.c,v 1.70 2006/07/19 18:28:52 jhb Exp $"); +__FBSDID("$FreeBSD: src/sys/compat/linux/linux_socket.c,v 1.71 2006/09/23 19:06:54 netchild Exp $"); /* XXX we use functions that might not exist. */ #include "opt_compat.h" @@ -611,6 +611,8 @@ error = kern_bind(td, linux_args.s, sa); free(sa, M_SONAME); + if (error == EADDRNOTAVAIL && linux_args.namelen != sizeof(struct sockaddr_in)) + return (EINVAL); return (error); } @@ -719,8 +721,11 @@ bsd_args.anamelen = PTRIN(linux_args.namelen);/* XXX */ error = accept(td, &bsd_args); bsd_to_linux_sockaddr((struct sockaddr *)bsd_args.name); - if (error) + if (error) { + if (error == EFAULT && linux_args.namelen != sizeof(struct sockaddr_in)) + return (EINVAL); return (error); + } if (linux_args.addr) { error = linux_sa_put(PTRIN(linux_args.addr)); if (error) { @@ -1135,7 +1140,7 @@ break; } if (name == -1) - return (EINVAL); + return (ENOPROTOOPT); bsd_args.name = name; bsd_args.val = PTRIN(linux_args.optval); ==== //depot/projects/newisp/conf/NOTES#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/NOTES,v 1.1381 2006/09/20 13:33:40 rwatson Exp $ +# $FreeBSD: src/sys/conf/NOTES,v 1.1382 2006/09/25 11:40:14 scottl Exp $ # # NOTES -- Lines that can be cut/pasted into kernel and hints configs. # @@ -1544,6 +1544,7 @@ device mlx # Mylex DAC960 device amr # AMI MegaRAID device mfi # LSI MegaRAID SAS +options MFI_DEBUG # # 3ware ATA RAID ==== //depot/projects/newisp/conf/files#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/files,v 1.1142 2006/09/18 17:23:35 sam Exp $ +# $FreeBSD: src/sys/conf/files,v 1.1143 2006/09/25 11:40:14 scottl Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -713,6 +713,7 @@ dev/md/md.c optional md dev/mem/memdev.c optional mem dev/mfi/mfi.c optional mfi +dev/mfi/mfi_debug.c optional mfi dev/mfi/mfi_pci.c optional mfi pci dev/mfi/mfi_disk.c optional mfi dev/mfi/mfi_linux.c optional mfi compat_linux ==== //depot/projects/newisp/conf/files.amd64#3 (text+ko) ==== @@ -1,7 +1,7 @@ # This file tells config what files go into building a kernel, # files marked standard are always included. # -# $FreeBSD: src/sys/conf/files.amd64,v 1.93 2006/09/05 16:55:12 anholt Exp $ +# $FreeBSD: src/sys/conf/files.amd64,v 1.94 2006/09/22 22:11:28 jhb Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -161,7 +161,13 @@ dev/if_ndis/if_ndis_usb.c optional ndis usb dev/io/iodev.c optional io dev/ipmi/ipmi.c optional ipmi -dev/ipmi/ipmi_smbios.c optional ipmi isa +dev/ipmi/ipmi_acpi.c optional ipmi acpi +dev/ipmi/ipmi_isa.c optional ipmi isa +dev/ipmi/ipmi_kcs.c optional ipmi +dev/ipmi/ipmi_smic.c optional ipmi +dev/ipmi/ipmi_smbus.c optional ipmi smbus +dev/ipmi/ipmi_smbios.c optional ipmi +dev/ipmi/ipmi_ssif.c optional ipmi smbus dev/ipmi/ipmi_pci.c optional ipmi pci dev/fdc/fdc.c optional fdc dev/fdc/fdc_acpi.c optional fdc ==== //depot/projects/newisp/conf/files.i386#2 (text+ko) ==== @@ -1,7 +1,7 @@ # This file tells config what files go into building a kernel, # files marked standard are always included. # -# $FreeBSD: src/sys/conf/files.i386,v 1.565 2006/08/15 12:54:28 netchild Exp $ +# $FreeBSD: src/sys/conf/files.i386,v 1.566 2006/09/22 22:11:28 jhb Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -196,7 +196,13 @@ dev/if_ndis/if_ndis_usb.c optional ndis usb dev/io/iodev.c optional io dev/ipmi/ipmi.c optional ipmi -dev/ipmi/ipmi_smbios.c optional ipmi isa +dev/ipmi/ipmi_acpi.c optional ipmi acpi +dev/ipmi/ipmi_isa.c optional ipmi isa +dev/ipmi/ipmi_kcs.c optional ipmi +dev/ipmi/ipmi_smic.c optional ipmi +dev/ipmi/ipmi_smbus.c optional ipmi smbus +dev/ipmi/ipmi_smbios.c optional ipmi +dev/ipmi/ipmi_ssif.c optional ipmi smbus dev/ipmi/ipmi_pci.c optional ipmi pci dev/kbd/kbd.c optional atkbd | sc | ukbd | vt dev/le/if_le_isa.c optional le isa ==== //depot/projects/newisp/dev/acpica/Osd/OsdHardware.c#2 (text+ko) ==== @@ -30,7 +30,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/acpica/Osd/OsdHardware.c,v 1.20 2006/04/04 02:22:38 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/Osd/OsdHardware.c,v 1.21 2006/09/24 09:39:17 hrs Exp $"); #include @@ -126,7 +126,9 @@ error = acpi_os_check_port(InPort, Width); if (error != 0) { - printf("acpi: bad read from port 0x%03x (%d)\n", (int)InPort, Width); + if (bootverbose) + printf("acpi: bad read from port 0x%03x (%d)\n", + (int)InPort, Width); if (error == -1) return (AE_BAD_PARAMETER); } @@ -159,8 +161,9 @@ error = acpi_os_check_port(OutPort, Width); if (error != 0) { - printf("acpi: bad write to port 0x%03x (%d), val %#x\n", (int)OutPort, - Width, Value); + if (bootverbose) + printf("acpi: bad write to port 0x%03x (%d), val %#x\n", + (int)OutPort, Width, Value); if (error == -1) return (AE_BAD_PARAMETER); } ==== //depot/projects/newisp/dev/ata/ata-chipset.c#6 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ata/ata-chipset.c,v 1.175 2006/09/12 22:06:39 sos Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ata/ata-chipset.c,v 1.176 2006/09/25 11:26:29 sos Exp $"); #include "opt_ata.h" #include @@ -985,6 +985,13 @@ ctlr->allocate = ata_ali_sata_allocate; ctlr->setmode = ata_sata_setmode; + /* if we have a memory resource we can likely do AHCI */ + ctlr->r_type2 = SYS_RES_MEMORY; + ctlr->r_rid2 = PCIR_BAR(5); + if ((ctlr->r_res2 = bus_alloc_resource_any(dev, ctlr->r_type2, + &ctlr->r_rid2, RF_ACTIVE))) + return ata_ahci_chipinit(dev); + /* enable PCI interrupt */ pci_write_config(dev, PCIR_COMMAND, pci_read_config(dev, PCIR_COMMAND, 2) & ~0x0400, 2); ==== //depot/projects/newisp/dev/bge/if_bge.c#6 (text+ko) ==== @@ -32,7 +32,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/bge/if_bge.c,v 1.148 2006/09/18 22:18:21 jkim Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/bge/if_bge.c,v 1.149 2006/09/23 18:55:49 scottl Exp $"); /* * Broadcom BCM570x family gigabit ethernet driver for FreeBSD. @@ -79,6 +79,7 @@ #include #include #include +#include #include #include @@ -419,7 +420,16 @@ DRIVER_MODULE(miibus, bge, miibus_driver, miibus_devclass, 0, 0); static int bge_fake_autoneg = 0; +static int bge_allow_asf = 1; + TUNABLE_INT("hw.bge.fake_autoneg", &bge_fake_autoneg); +TUNABLE_INT("hw.bge.allow_asf", &bge_allow_asf); + +SYSCTL_NODE(_hw, OID_AUTO, bge, CTLFLAG_RD, 0, "BGE driver parameters"); +SYSCTL_INT(_hw_bge, OID_AUTO, fake_autoneg, CTLFLAG_RD, &bge_fake_autoneg, 0, + "Enable fake autonegotiation for certain blade systems"); +SYSCTL_INT(_hw_bge, OID_AUTO, allow_asf, CTLFLAG_RD, &bge_allow_asf, 0, + "Allow ASF mode if available"); static uint32_t bge_readmem_ind(struct bge_softc *sc, int off) @@ -2179,8 +2189,8 @@ } sc->bge_asf_mode = 0; - if (bge_readmem_ind(sc, BGE_SOFTWARE_GENCOMM_SIG) - == BGE_MAGIC_NUMBER) { + if (bge_allow_asf && (bge_readmem_ind(sc, BGE_SOFTWARE_GENCOMM_SIG) + == BGE_MAGIC_NUMBER)) { if (bge_readmem_ind(sc, BGE_SOFTWARE_GENCOMM_NICCFG) & BGE_HWCFG_ASF) { sc->bge_asf_mode |= ASF_ENABLE; ==== //depot/projects/newisp/dev/exca/exca.c#2 (text+ko) ==== @@ -53,7 +53,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/exca/exca.c,v 1.24 2006/03/09 16:28:24 imp Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/exca/exca.c,v 1.25 2006/09/24 00:26:33 imp Exp $"); #include #include @@ -179,11 +179,7 @@ struct mem_map_index_st *map; struct pccard_mem_handle *mem; uint32_t offset; -#if 0 - int mem8 = (mem->kind == PCCARD_A_MEM_ATTR); -#else - int mem8 = 1; -#endif + int mem8 = 1 /* mem->kind == PCCARD_A_MEM_ATTR */; map = &mem_map_index[win]; mem = &sc->mem[win]; ==== //depot/projects/newisp/dev/ipmi/ipmi.c#2 (text) ==== @@ -25,24 +25,21 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ipmi/ipmi.c,v 1.3 2006/05/16 14:36:26 phk Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ipmi/ipmi.c,v 1.4 2006/09/22 22:11:29 jhb Exp $"); #include #include +#include +#include +#include #include #include +#include #include +#include #include - -#include -#include -#include - -#include -#include -#include +#include #include -#include #ifdef LOCAL_MODULE #include @@ -52,29 +49,7 @@ #include #endif -struct ipmi_done_list { - u_char *data; - int channel; - int msgid; - int len; - TAILQ_ENTRY(ipmi_done_list) list; -}; - -#define MAX_TIMEOUT 3 * hz - -static int ipmi_wait_for_ibf(device_t, int); -static int ipmi_wait_for_obf(device_t, int); -static void ipmi_clear_obf(device_t, int); -static void ipmi_error(device_t); -static void ipmi_check_read(device_t); -static int ipmi_write(device_t, u_char *, int); -static void ipmi_wait_for_tx_okay(device_t); -static void ipmi_wait_for_rx_okay(device_t); -static void ipmi_wait_for_not_busy(device_t); -static void ipmi_set_busy(device_t); -static int ipmi_ready_to_read(device_t); #ifdef IPMB -static int ipmi_handle_attn(device_t dev); static int ipmi_ipmb_checksum(u_char, int); static int ipmi_ipmb_send_message(device_t, u_char, u_char, u_char, u_char, u_char, int) @@ -92,11 +67,10 @@ static int on = 1; SYSCTL_NODE(_hw, OID_AUTO, ipmi, CTLFLAG_RD, 0, "IPMI driver parameters"); SYSCTL_INT(_hw_ipmi, OID_AUTO, on, CTLFLAG_RW, - &on, 0, ""); + &on, 0, ""); static struct cdevsw ipmi_cdevsw = { .d_version = D_VERSION, - .d_flags = D_NEEDGIANT, .d_open = ipmi_open, .d_close = ipmi_close, .d_ioctl = ipmi_ioctl, @@ -106,60 +80,126 @@ MALLOC_DEFINE(M_IPMI, "ipmi", "ipmi"); -static int -ipmi_open(struct cdev *dev, int flags, int fmt, struct thread *td) +static int +ipmi_open(struct cdev *cdev, int flags, int fmt, struct thread *td) { + struct ipmi_device *dev; struct ipmi_softc *sc; if (!on) - return ENOENT; + return (ENOENT); - sc = dev->si_drv1; - if (sc->ipmi_refcnt) { - return EBUSY; + dev = cdev->si_drv1; + sc = dev->ipmi_softc; + IPMI_LOCK(sc); + if (dev->ipmi_open) { + IPMI_UNLOCK(sc); + return (EBUSY); } - sc->ipmi_refcnt = 1; + dev->ipmi_open = 1; + IPMI_UNLOCK(sc); - return 0; + return (0); } -static int -ipmi_poll(struct cdev *dev, int poll_events, struct thread *td) +static int +ipmi_poll(struct cdev *cdev, int poll_events, struct thread *td) { + struct ipmi_device *dev; struct ipmi_softc *sc; int revents = 0; - sc = dev->si_drv1; + dev = cdev->si_drv1; + sc = dev->ipmi_softc; - ipmi_check_read(sc->ipmi_dev); - + IPMI_LOCK(sc); if (poll_events & (POLLIN | POLLRDNORM)) { - if (!TAILQ_EMPTY(&sc->ipmi_done)) + if (!TAILQ_EMPTY(&dev->ipmi_completed_requests)) revents |= poll_events & (POLLIN | POLLRDNORM); - if (TAILQ_EMPTY(&sc->ipmi_done) && sc->ipmi_requests == 0) { + if (dev->ipmi_requests == 0) revents |= POLLERR; - } } if (revents == 0) { if (poll_events & (POLLIN | POLLRDNORM)) - selrecord(td, &sc->ipmi_select); + selrecord(td, &dev->ipmi_select); } + IPMI_UNLOCK(sc); + + return (revents); +} + +static void +ipmi_purge_completed_requests(struct ipmi_device *dev) +{ + struct ipmi_request *req; - return revents; + while (!TAILQ_EMPTY(&dev->ipmi_completed_requests)) { + req = TAILQ_FIRST(&dev->ipmi_completed_requests); + TAILQ_REMOVE(&dev->ipmi_completed_requests, req, ir_link); + dev->ipmi_requests--; + ipmi_free_request(req); + } } -static int -ipmi_close(struct cdev *dev, int flags, int fmt, struct thread *td) +static int +ipmi_close(struct cdev *cdev, int flags, int fmt, struct thread *td) { + struct ipmi_request *req, *nreq; + struct ipmi_device *dev; struct ipmi_softc *sc; - int error = 0; +#ifdef CLONING + int bit; +#endif + + dev = cdev->si_drv1; + sc = dev->ipmi_softc; + + IPMI_LOCK(sc); + if (dev->ipmi_requests) { + /* Throw away any pending requests for this device. */ + TAILQ_FOREACH_SAFE(req, &sc->ipmi_pending_requests, ir_link, + nreq) { + if (req->ir_owner == dev) { + TAILQ_REMOVE(&sc->ipmi_pending_requests, req, + ir_link); + dev->ipmi_requests--; + ipmi_free_request(req); + } + } + + /* Throw away any pending completed requests for this device. */ + ipmi_purge_completed_requests(dev); + + /* + * If we still have outstanding requests, they must be stuck + * in an interface driver, so wait for those to drain. + */ + dev->ipmi_closing = 1; + while (dev->ipmi_requests > 0) { + msleep(&dev->ipmi_requests, &sc->ipmi_lock, PWAIT, + "ipmidrain", 0); + ipmi_purge_completed_requests(dev); + } + } - sc = dev->si_drv1; +#ifdef CLONING + /* Detach this sub-device from the main driver. */ + bit = minor(cdev) % 32; + sc->ipmi_cdev_mask &= ~(1 << bit); + TAILQ_REMOVE(&sc->ipmi_cdevs, dev, ipmi_link); + IPMI_UNLOCK(sc); - sc->ipmi_refcnt = 0; + /* Cleanup. */ + cdev->si_drv1 = NULL; + free(dev, M_IPMI); + destroy_dev(cdev); +#else + dev->ipmi_open = 0; + IPMI_UNLOCK(sc); +#endif - return error; + return (0); } #ifdef IPMB @@ -171,707 +211,384 @@ for (; len; len--) { sum += *data++; } - return -sum; + return (-sum); } +/* XXX: Needs work */ static int ipmi_ipmb_send_message(device_t dev, u_char channel, u_char netfn, u_char command, u_char seq, u_char *data, int data_len) { - u_char *temp; struct ipmi_softc *sc = device_get_softc(dev); + struct ipmi_request *req; + u_char slave_addr = 0x52; int error; - u_char slave_addr = 0x52; - temp = malloc(data_len + 10, M_IPMI, M_WAITOK); - bzero(temp, data_len + 10); - temp[0] = IPMI_APP_REQUEST << 2; - temp[1] = IPMI_SEND_MSG; - temp[2] = channel; - temp[3] = slave_addr; - temp[4] = netfn << 2; - temp[5] = ipmi_ipmb_check_sum(&temp[3], 2); - temp[6] = sc->ipmi_address; - temp[7] = seq << 2 | sc->ipmi_lun; - temp[8] = command; + req = ipmi_alloc_driver_request(IPMI_ADDR(IPMI_APP_REQUEST, 0), + IPMI_SEND_MSG, data_len + 8, 0); + req->ir_request[0] = channel; + req->ir_request[1] = slave_addr; + req->ir_request[2] = IPMI_ADDR(netfn, 0); + req->ir_request[3] = ipmi_ipmb_checksum(&req->ir_request[1], 2); + req->ir_request[4] = sc->ipmi_address; + req->ir_request[5] = IPMI_ADDR(seq, sc->ipmi_lun); + req->ir_request[6] = command; - bcopy(data, &temp[9], data_len); - temp[data_len + 9] = ipmi_ipmb_check(&temp[6], data_len + 3); - ipmi_write(sc->ipmi_dev, temp, data_len + 9); - free(temp, M_IPMI); + bcopy(data, &req->ir_request[7], data_len); + temp[data_len + 7] = ipmi_ipmb_checksum(&req->ir_request[4], + data_len + 3); - while (!ipmi_ready_to_read(dev)) - DELAY(1000); - temp = malloc(IPMI_MAX_RX, M_IPMI, M_WAITOK); - bzero(temp, IPMI_MAX_RX); - error = ipmi_read(dev, temp, IPMI_MAX_RX); - free(temp, M_IPMI); + ipmi_submit_driver_request(sc, req); + error = req->ir_error; + ipmi_free_request(req); - return error; + return (error); } static int -ipmi_handle_attn(device_t dev) +ipmi_handle_attn(struct ipmi_softc *sc) { - u_char temp[IPMI_MAX_RX]; - struct ipmi_softc *sc = device_get_softc(dev); + struct ipmi_request *req; int error; device_printf(sc->ipmi_dev, "BMC has a message\n"); - temp[0] = IPMI_APP_REQUEST << 2; - temp[1] = IPMI_GET_MSG_FLAGS; - ipmi_write(sc->ipmi_dev, temp, 2); - while (!ipmi_ready_to_read(dev)) - DELAY(1000); - bzero(temp, IPMI_MAX_RX); - error = ipmi_read(dev, temp, IPMI_MAX_RX); + req = ipmi_alloc_driver_request(IPMI_ADDR(IPMI_APP_REQUEST, 0), + IPMI_GET_MSG_FLAGS, 0, 1); + + ipmi_submit_driver_request(sc, req); - if (temp[2] == 0) { - if (temp[3] & IPMI_MSG_BUFFER_FULL) { + if (req->ir_error == 0 && req->ir_compcode == 0) { + if (req->ir_reply[0] & IPMI_MSG_BUFFER_FULL) { device_printf(sc->ipmi_dev, "message buffer full"); } - if (temp[3] & IPMI_WDT_PRE_TIMEOUT) { + if (req->ir_reply[0] & IPMI_WDT_PRE_TIMEOUT) { device_printf(sc->ipmi_dev, "watchdog about to go off"); } - if (temp[3] & IPMI_MSG_AVAILABLE) { - temp[0] = IPMI_APP_REQUEST << 2; - temp[1] = IPMI_GET_MSG; - ipmi_write(sc->ipmi_dev, temp, 2); - while (!ipmi_ready_to_read(dev)) - DELAY(1000); - bzero(temp, IPMI_MAX_RX); - error = ipmi_read(dev, temp, IPMI_MAX_RX); + if (req->ir_reply[0] & IPMI_MSG_AVAILABLE) { + ipmi_free_request(req); + + req = ipmi_alloc_driver_request( + IPMI_ADDR(IPMI_APP_REQUEST, 0), IPMI_GET_MSG, 0, + 16); device_printf(sc->ipmi_dev, "throw out message "); dump_buf(temp, 16); } - } else - return -1; - return error; + } + error = req->ir_error; + ipmi_free_request(req); + + return (error); } #endif -static int -ipmi_ready_to_read(device_t dev) -{ - struct ipmi_softc *sc = device_get_softc(dev); - int status, flags; - - if (sc->ipmi_bios_info.smic_mode) { - flags = INB(sc, sc->ipmi_smic_flags); -#ifdef IPMB - if (flags & SMIC_STATUS_SMS_ATN) { - ipmi_handle_attn(dev); - return 0; - } -#endif - if (flags & SMIC_STATUS_RX_RDY) - return 1; - } else if (sc->ipmi_bios_info.kcs_mode) { - status = INB(sc, sc->ipmi_kcs_status_reg); -#ifdef IPMB - if (status & KCS_STATUS_SMS_ATN) { - ipmi_handle_attn(dev); - return 0; - } +#ifdef IPMICTL_SEND_COMMAND_32 +#define PTRIN(p) ((void *)(uintptr_t)(p)) +#define PTROUT(p) ((uintptr_t)(p)) #endif - if (status & KCS_STATUS_OBF) - return 1; - } else { - device_printf(dev,"Unsupported mode\n"); - } - - return 0; -} -void -ipmi_intr(void *arg) { - device_t dev = arg; - - ipmi_check_read(dev); -} - -static void -ipmi_check_read(device_t dev){ - struct ipmi_softc *sc = device_get_softc(dev); - struct ipmi_done_list *item; - int status; - u_char *temp; - - if (!sc->ipmi_requests) >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Tue Sep 26 05:01:21 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 760F016A4AB; Tue, 26 Sep 2006 05:01:21 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 513D716A49E for ; Tue, 26 Sep 2006 05:01:21 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B749243D62 for ; Tue, 26 Sep 2006 05:01:20 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8Q51KKn076047 for ; Tue, 26 Sep 2006 05:01:20 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8Q51Kfl076044 for perforce@freebsd.org; Tue, 26 Sep 2006 05:01:20 GMT (envelope-from mjacob@freebsd.org) Date: Tue, 26 Sep 2006 05:01:20 GMT Message-Id: <200609260501.k8Q51Kfl076044@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106708 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 05:01:21 -0000 http://perforce.freebsd.org/chv.cgi?CH=106708 Change 106708 by mjacob@newisp on 2006/09/26 05:00:36 Add sysctl stuff for WWNN/WWPN and Initiator ID. Affected files ... .. //depot/projects/newisp/dev/isp/isp_freebsd.c#9 edit Differences ... ==== //depot/projects/newisp/dev/isp/isp_freebsd.c#9 (text+ko) ==== @@ -38,6 +38,9 @@ #include #include #include +#if __FreeBSD_version >= 500000 +#include +#endif MODULE_VERSION(isp, 1); @@ -76,6 +79,7 @@ /* psize */ nopsize, /* flags */ D_TAPE, }; +#define isp_sysctl_update(x) do { ; } while (0) #else static struct cdevsw isp_cdevsw = { .d_version = D_VERSION, @@ -83,6 +87,7 @@ .d_ioctl = ispioctl, .d_name = "isp", }; +static void isp_sysctl_update(ispsoftc_t *); #endif static ispsoftc_t *isplist = NULL; @@ -251,7 +256,7 @@ } tmp->isp_osinfo.next = isp; } - + isp_sysctl_update(isp); } static __inline void @@ -618,6 +623,38 @@ return (retval); } +#if __FreeBSD_version >= 500000 +static void +isp_sysctl_update(ispsoftc_t *isp) +{ + struct sysctl_ctx_list *ctx = + device_get_sysctl_ctx(isp->isp_osinfo.dev); + struct sysctl_oid *tree = device_get_sysctl_tree(isp->isp_osinfo.dev); + + if (IS_SCSI(isp)) { + isp->isp_osinfo.sysctl_info.spi.iid = DEFAULT_IID(isp); + SYSCTL_ADD_INT(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, "iid", + CTLFLAG_RD, &isp->isp_osinfo.sysctl_info.spi.iid, 0, + "Initiator ID"); + return; + } + snprintf(isp->isp_osinfo.sysctl_info.fc.wwnn, + sizeof (isp->isp_osinfo.sysctl_info.fc.wwnn), "0x%08x%08x", + (uint32_t) (ISP_NODEWWN(isp) >> 32), (uint32_t) ISP_NODEWWN(isp)); + + snprintf(isp->isp_osinfo.sysctl_info.fc.wwpn, + sizeof (isp->isp_osinfo.sysctl_info.fc.wwpn), "0x%08x%08x", + (uint32_t) (ISP_PORTWWN(isp) >> 32), (uint32_t) ISP_PORTWWN(isp)); + + SYSCTL_ADD_STRING(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, + "wwnn", CTLFLAG_RD, isp->isp_osinfo.sysctl_info.fc.wwnn, 0, + "World Wide Node Name"); + SYSCTL_ADD_STRING(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, + "wwpn", CTLFLAG_RD, isp->isp_osinfo.sysctl_info.fc.wwpn, 0, + "World Wide Port Name"); +} +#endif + static void isp_intr_enable(void *arg) { From owner-p4-projects@FreeBSD.ORG Tue Sep 26 12:24:37 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 4CF0516A416; Tue, 26 Sep 2006 12:24:37 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 EA17E16A415 for ; Tue, 26 Sep 2006 12:24:36 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2CBD043D69 for ; Tue, 26 Sep 2006 12:24:36 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QCOanB017371 for ; Tue, 26 Sep 2006 12:24:36 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QCOaJ1017368 for perforce@freebsd.org; Tue, 26 Sep 2006 12:24:36 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 12:24:36 GMT Message-Id: <200609261224.k8QCOaJ1017368@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106715 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 12:24:37 -0000 http://perforce.freebsd.org/chv.cgi?CH=106715 Change 106715 by attilio@attilio_laptop on 2006/09/26 12:24:02 It applies style(9) for header. This is a starting point for a complete style(9)-ization of USB new stack. Affected files ... .. //depot/projects/usb/src/sys/dev/usb/ehci.h#5 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/ehci.h#5 (text+ko) ==== @@ -37,377 +37,353 @@ #ifndef _EHCI_H_ #define _EHCI_H_ -/*** PCI config registers ***/ +/* PCI config registers */ +#define PCI_CBMEM 0x10 /* configuration base MEM */ +#define PCI_INTERFACE_EHCI 0x20 +#define PCI_USBREV 0x60 /* RO USB protocol revision */ +#define PCI_USBREV_MASK 0xff +#define PCI_USBREV_PRE_1_0 0x00 +#define PCI_USBREV_1_0 0x10 +#define PCI_USBREV_1_1 0x11 +#define PCI_USBREV_2_0 0x20 +#define PCI_EHCI_FLADJ 0x61 /* RW Frame len adj, SOF=59488+6*fladj */ +#define PCI_EHCI_PORTWAKECAP 0x62 /* RW Port wake caps (opt) */ -#define PCI_CBMEM 0x10 /* configuration base MEM */ - -#define PCI_INTERFACE_EHCI 0x20 - -#define PCI_USBREV 0x60 /* RO USB protocol revision */ -#define PCI_USBREV_MASK 0xff -#define PCI_USBREV_PRE_1_0 0x00 -#define PCI_USBREV_1_0 0x10 -#define PCI_USBREV_1_1 0x11 -#define PCI_USBREV_2_0 0x20 - -#define PCI_EHCI_FLADJ 0x61 /* RW Frame len adj, SOF=59488+6*fladj */ - -#define PCI_EHCI_PORTWAKECAP 0x62 /* RW Port wake caps (opt) */ - /* EHCI Extended Capabilities */ -#define EHCI_EC_LEGSUP 0x01 - -#define EHCI_EECP_NEXT(x) (((x) >> 8) & 0xff) -#define EHCI_EECP_ID(x) ((x) & 0xff) +#define EHCI_EC_LEGSUP 0x01 +#define EHCI_EECP_NEXT(x) (((x) >> 8) & 0xff) +#define EHCI_EECP_ID(x) ((x) & 0xff) /* Legacy support extended capability */ -#define EHCI_LEGSUP_LEGSUP 0x01 -#define EHCI_LEGSUP_OSOWNED 0x01000000 /* OS owned semaphore */ -#define EHCI_LEGSUP_BIOSOWNED 0x00010000 /* BIOS owned semaphore */ -#define EHCI_LEGSUP_USBLEGCTLSTS 0x04 +#define EHCI_LEGSUP_LEGSUP 0x01 +#define EHCI_LEGSUP_OSOWNED 0x01000000 /* OS owned semaphore */ +#define EHCI_LEGSUP_BIOSOWNED 0x00010000 /* BIOS owned semaphore */ +#define EHCI_LEGSUP_USBLEGCTLSTS 0x04 -/*** EHCI capability registers ***/ - -#define EHCI_CAPLENGTH 0x00 /* RO Capability register length field */ +/* EHCI capability registers */ +#define EHCI_CAPLENGTH 0x00 /* RO Capability register length field */ /* reserved 0x01 */ -#define EHCI_HCIVERSION 0x02 /* RO Interface version number */ - -#define EHCI_HCSPARAMS 0x04 /* RO Structural parameters */ -#define EHCI_HCS_DEBUGPORT(x) (((x) >> 20) & 0xf) -#define EHCI_HCS_P_INDICATOR(x) ((x) & 0x10000) -#define EHCI_HCS_N_CC(x) (((x) >> 12) & 0xf) /* # of companion ctlrs */ -#define EHCI_HCS_N_PCC(x) (((x) >> 8) & 0xf) /* # of ports per comp. */ -#define EHCI_HCS_PPC(x) ((x) & 0x10) /* port power control */ -#define EHCI_HCS_N_PORTS(x) ((x) & 0xf) /* # of ports */ - -#define EHCI_HCCPARAMS 0x08 /* RO Capability parameters */ -#define EHCI_HCC_EECP(x) (((x) >> 8) & 0xff) /* extended ports caps */ -#define EHCI_HCC_IST(x) (((x) >> 4) & 0xf) /* isoc sched threshold */ -#define EHCI_HCC_ASPC(x) ((x) & 0x4) /* async sched park cap */ -#define EHCI_HCC_PFLF(x) ((x) & 0x2) /* prog frame list flag */ -#define EHCI_HCC_64BIT(x) ((x) & 0x1) /* 64 bit address cap */ - -#define EHCI_HCSP_PORTROUTE 0x0c /*RO Companion port route description */ +#define EHCI_HCIVERSION 0x02 /* RO Interface version number */ +#define EHCI_HCSPARAMS 0x04 /* RO Structural parameters */ +#define EHCI_HCS_DEBUGPORT(x) (((x) >> 20) & 0xf) +#define EHCI_HCS_P_INDICATOR(x) ((x) & 0x10000) +#define EHCI_HCS_N_CC(x) (((x) >> 12) & 0xf) /* # of companion ctlrs */ +#define EHCI_HCS_N_PCC(x) (((x) >> 8) & 0xf) /* # of ports per comp. */ +#define EHCI_HCS_PPC(x) ((x) & 0x10) /* port power control */ +#define EHCI_HCS_N_PORTS(x) ((x) & 0xf) /* # of ports */ +#define EHCI_HCCPARAMS 0x08 /* RO Capability parameters */ +#define EHCI_HCC_EECP(x) (((x) >> 8) & 0xff) /* extended ports caps */ +#define EHCI_HCC_IST(x) (((x) >> 4) & 0xf) /* isoc sched threshold */ +#define EHCI_HCC_ASPC(x) ((x) & 0x4) /* async sched park cap */ +#define EHCI_HCC_PFLF(x) ((x) & 0x2) /* prog frame list flag */ +#define EHCI_HCC_64BIT(x) ((x) & 0x1) /* 64 bit address cap */ +#define EHCI_HCSP_PORTROUTE 0x0c /* RO Companion port route description */ /* EHCI operational registers. Offset given by EHCI_CAPLENGTH register */ -#define EHCI_USBCMD 0x00 /* RO, RW, WO Command register */ -#define EHCI_CMD_ITC_M 0x00ff0000 /* RW interrupt threshold ctrl */ -#define EHCI_CMD_ITC_1 0x00010000 -#define EHCI_CMD_ITC_2 0x00020000 -#define EHCI_CMD_ITC_4 0x00040000 -#define EHCI_CMD_ITC_8 0x00080000 -#define EHCI_CMD_ITC_16 0x00100000 -#define EHCI_CMD_ITC_32 0x00200000 -#define EHCI_CMD_ITC_64 0x00400000 -#define EHCI_CMD_ASPME 0x00000800 /* RW/RO async park enable */ -#define EHCI_CMD_ASPMC 0x00000300 /* RW/RO async park count */ -#define EHCI_CMD_LHCR 0x00000080 /* RW light host ctrl reset */ -#define EHCI_CMD_IAAD 0x00000040 /* RW intr on async adv door bell */ -#define EHCI_CMD_ASE 0x00000020 /* RW async sched enable */ -#define EHCI_CMD_PSE 0x00000010 /* RW periodic sched enable */ -#define EHCI_CMD_FLS_M 0x0000000c /* RW/RO frame list size */ -#define EHCI_CMD_FLS(x) (((x) >> 2) & 3) /* RW/RO frame list size */ -#define EHCI_CMD_HCRESET 0x00000002 /* RW reset */ -#define EHCI_CMD_RS 0x00000001 /* RW run/stop */ +#define EHCI_USBCMD 0x00 /* RO, RW, WO Command register */ +#define EHCI_CMD_ITC_M 0x00ff0000 /* RW interrupt threshold ctrl */ +#define EHCI_CMD_ITC_1 0x00010000 +#define EHCI_CMD_ITC_2 0x00020000 +#define EHCI_CMD_ITC_4 0x00040000 +#define EHCI_CMD_ITC_8 0x00080000 +#define EHCI_CMD_ITC_16 0x00100000 +#define EHCI_CMD_ITC_32 0x00200000 +#define EHCI_CMD_ITC_64 0x00400000 +#define EHCI_CMD_ASPME 0x00000800 /* RW/RO async park enable */ +#define EHCI_CMD_ASPMC 0x00000300 /* RW/RO async park count */ +#define EHCI_CMD_LHCR 0x00000080 /* RW light host ctrl reset */ +#define EHCI_CMD_IAAD 0x00000040 /* RW intr on async adv door bell */ +#define EHCI_CMD_ASE 0x00000020 /* RW async sched enable */ +#define EHCI_CMD_PSE 0x00000010 /* RW periodic sched enable */ +#define EHCI_CMD_FLS_M 0x0000000c /* RW/RO frame list size */ +#define EHCI_CMD_FLS(x) (((x) >> 2) & 3) /* RW/RO frame list size */ +#define EHCI_CMD_HCRESET 0x00000002 /* RW reset */ +#define EHCI_CMD_RS 0x00000001 /* RW run/stop */ +#define EHCI_USBSTS 0x04 /* RO, RW, RWC Status register */ +#define EHCI_STS_ASS 0x00008000 /* RO async sched status */ +#define EHCI_STS_PSS 0x00004000 /* RO periodic sched status */ +#define EHCI_STS_REC 0x00002000 /* RO reclamation */ +#define EHCI_STS_HCH 0x00001000 /* RO host controller halted */ +#define EHCI_STS_IAA 0x00000020 /* RWC interrupt on async adv */ +#define EHCI_STS_HSE 0x00000010 /* RWC host system error */ +#define EHCI_STS_FLR 0x00000008 /* RWC frame list rollover */ +#define EHCI_STS_PCD 0x00000004 /* RWC port change detect */ +#define EHCI_STS_ERRINT 0x00000002 /* RWC error interrupt */ +#define EHCI_STS_INT 0x00000001 /* RWC interrupt */ +#define EHCI_STS_INTRS(x) ((x) & 0x3f) -#define EHCI_USBSTS 0x04 /* RO, RW, RWC Status register */ -#define EHCI_STS_ASS 0x00008000 /* RO async sched status */ -#define EHCI_STS_PSS 0x00004000 /* RO periodic sched status */ -#define EHCI_STS_REC 0x00002000 /* RO reclamation */ -#define EHCI_STS_HCH 0x00001000 /* RO host controller halted */ -#define EHCI_STS_IAA 0x00000020 /* RWC interrupt on async adv */ -#define EHCI_STS_HSE 0x00000010 /* RWC host system error */ -#define EHCI_STS_FLR 0x00000008 /* RWC frame list rollover */ -#define EHCI_STS_PCD 0x00000004 /* RWC port change detect */ -#define EHCI_STS_ERRINT 0x00000002 /* RWC error interrupt */ -#define EHCI_STS_INT 0x00000001 /* RWC interrupt */ -#define EHCI_STS_INTRS(x) ((x) & 0x3f) +#define EHCI_NORMAL_INTRS (/* EHCI_STS_IAA | */ EHCI_STS_HSE | \ + EHCI_STS_PCD | EHCI_STS_ERRINT | \ + EHCI_STS_INT) -#define EHCI_NORMAL_INTRS (/* EHCI_STS_IAA | */EHCI_STS_HSE | EHCI_STS_PCD | EHCI_STS_ERRINT | EHCI_STS_INT) +#define EHCI_USBINTR 0x08 /* RW Interrupt register */ +#define EHCI_INTR_IAAE 0x00000020 /* interrupt on async advance ena */ +#define EHCI_INTR_HSEE 0x00000010 /* host system error ena */ +#define EHCI_INTR_FLRE 0x00000008 /* frame list rollover ena */ +#define EHCI_INTR_PCIE 0x00000004 /* port change ena */ +#define EHCI_INTR_UEIE 0x00000002 /* USB error intr ena */ +#define EHCI_INTR_UIE 0x00000001 /* USB intr ena */ -#define EHCI_USBINTR 0x08 /* RW Interrupt register */ -#define EHCI_INTR_IAAE 0x00000020 /* interrupt on async advance ena */ -#define EHCI_INTR_HSEE 0x00000010 /* host system error ena */ -#define EHCI_INTR_FLRE 0x00000008 /* frame list rollover ena */ -#define EHCI_INTR_PCIE 0x00000004 /* port change ena */ -#define EHCI_INTR_UEIE 0x00000002 /* USB error intr ena */ -#define EHCI_INTR_UIE 0x00000001 /* USB intr ena */ +#define EHCI_FRINDEX 0x0c /* RW Frame Index register */ -#define EHCI_FRINDEX 0x0c /* RW Frame Index register */ +#define EHCI_CTRLDSSEGMENT 0x10 /* RW Control Data Structure Segment */ -#define EHCI_CTRLDSSEGMENT 0x10 /* RW Control Data Structure Segment */ +#define EHCI_PERIODICLISTBASE 0x14 /* RW Periodic List Base */ +#define EHCI_ASYNCLISTADDR 0x18 /* RW Async List Base */ -#define EHCI_PERIODICLISTBASE 0x14 /* RW Periodic List Base */ -#define EHCI_ASYNCLISTADDR 0x18 /* RW Async List Base */ +#define EHCI_CONFIGFLAG 0x40 /* RW Configure Flag register */ +#define EHCI_CONF_CF 0x00000001 /* RW configure flag */ -#define EHCI_CONFIGFLAG 0x40 /* RW Configure Flag register */ -#define EHCI_CONF_CF 0x00000001 /* RW configure flag */ +#define EHCI_PORTSC(n) (0x40+(4*(n))) /* RO, RW, RWC Port Status reg */ +#define EHCI_PS_WKOC_E 0x00400000 /* RW wake on over current ena */ +#define EHCI_PS_WKDSCNNT_E 0x00200000 /* RW wake on disconnect ena */ +#define EHCI_PS_WKCNNT_E 0x00100000 /* RW wake on connect ena */ +#define EHCI_PS_PTC 0x000f0000 /* RW port test control */ +#define EHCI_PS_PIC 0x0000c000 /* RW port indicator control */ +#define EHCI_PS_PO 0x00002000 /* RW port owner */ +#define EHCI_PS_PP 0x00001000 /* RW,RO port power */ +#define EHCI_PS_LS 0x00000c00 /* RO line status */ +#define EHCI_PS_IS_LOWSPEED(x) (((x) & EHCI_PS_LS) == 0x00000400) +#define EHCI_PS_PR 0x00000100 /* RW port reset */ +#define EHCI_PS_SUSP 0x00000080 /* RW suspend */ +#define EHCI_PS_FPR 0x00000040 /* RW force port resume */ +#define EHCI_PS_OCC 0x00000020 /* RWC over current change */ +#define EHCI_PS_OCA 0x00000010 /* RO over current active */ +#define EHCI_PS_PEC 0x00000008 /* RWC port enable change */ +#define EHCI_PS_PE 0x00000004 /* RW port enable */ +#define EHCI_PS_CSC 0x00000002 /* RWC connect status change */ +#define EHCI_PS_CS 0x00000001 /* RO connect status */ +#define EHCI_PS_CLEAR (EHCI_PS_OCC | EHCI_PS_PEC | EHCI_PS_CSC) -#define EHCI_PORTSC(n) (0x40+(4*(n))) /* RO, RW, RWC Port Status reg */ -#define EHCI_PS_WKOC_E 0x00400000 /* RW wake on over current ena */ -#define EHCI_PS_WKDSCNNT_E 0x00200000 /* RW wake on disconnect ena */ -#define EHCI_PS_WKCNNT_E 0x00100000 /* RW wake on connect ena */ -#define EHCI_PS_PTC 0x000f0000 /* RW port test control */ -#define EHCI_PS_PIC 0x0000c000 /* RW port indicator control */ -#define EHCI_PS_PO 0x00002000 /* RW port owner */ -#define EHCI_PS_PP 0x00001000 /* RW,RO port power */ -#define EHCI_PS_LS 0x00000c00 /* RO line status */ -#define EHCI_PS_IS_LOWSPEED(x) (((x) & EHCI_PS_LS) == 0x00000400) -#define EHCI_PS_PR 0x00000100 /* RW port reset */ -#define EHCI_PS_SUSP 0x00000080 /* RW suspend */ -#define EHCI_PS_FPR 0x00000040 /* RW force port resume */ -#define EHCI_PS_OCC 0x00000020 /* RWC over current change */ -#define EHCI_PS_OCA 0x00000010 /* RO over current active */ -#define EHCI_PS_PEC 0x00000008 /* RWC port enable change */ -#define EHCI_PS_PE 0x00000004 /* RW port enable */ -#define EHCI_PS_CSC 0x00000002 /* RWC connect status change */ -#define EHCI_PS_CS 0x00000001 /* RO connect status */ -#define EHCI_PS_CLEAR (EHCI_PS_OCC|EHCI_PS_PEC|EHCI_PS_CSC) +#define EHCI_PORT_RESET_COMPLETE 2 /* ms */ -#define EHCI_PORT_RESET_COMPLETE 2 /* ms */ +/* + * Alignment NOTE: structures must be aligned so that the hardware can index + * without performing addition. + */ +#define EHCI_FRAMELIST_ALIGN 0x1000 /* bytes */ +#define EHCI_FRAMELIST_COUNT 1024 /* units */ +#define EHCI_VIRTUAL_FRAMELIST_COUNT 128 /* units */ -/* alignment NOTE: - * structures must be aligned so that - * the hardware can index without - * performing addition ! - */ -#define EHCI_FRAMELIST_ALIGN 0x1000 /* bytes */ -#define EHCI_FRAMELIST_COUNT 1024 /* units */ -#define EHCI_VIRTUAL_FRAMELIST_COUNT 128 /* units */ +/* Link types */ +#define EHCI_LINK_TERMINATE 0x00000001 +#define EHCI_LINK_TYPE(x) ((x) & 0x00000006) +#define EHCI_LINK_ITD 0x0 +#define EHCI_LINK_QH 0x2 +#define EHCI_LINK_SITD 0x4 +#define EHCI_LINK_FSTN 0x6 +#define EHCI_LINK_ADDR(x) ((x) &~ 0x1f) -/* data buffers are divided into one or more pages */ -#define EHCI_PAGE_SIZE 0x1000 +/* Structures alignment (bytes) */ +#define EHCI_ITD_ALIGN 128 +#define EHCI_SITD_ALIGN 64 +#define EHCI_QTD_ALIGN 64 +#define EHCI_QH_ALIGN 128 +#define EHCI_FSTN_ALIGN 32 +/* Data buffers are divided into one or more pages */ +#define EHCI_PAGE_SIZE 0x1000 +#if ((USB_PAGE_SIZE < EHCI_PAGE_SIZE) || (EHCI_PAGE_SIZE == 0) || \ + (USB_PAGE_SIZE < EHCI_ITD_ALIGN) || (EHCI_ITD_ALIGN == 0) || \ + (USB_PAGE_SIZE < EHCI_SITD_ALIGN) || (EHCI_SITD_ALIGN == 0) || \ + (USB_PAGE_SIZE < EHCI_QTD_ALIGN) || (EHCI_QTD_ALIGN == 0) || \ + (USB_PAGE_SIZE < EHCI_QH_ALIGN) || (EHCI_QH_ALIGN == 0) || \ + (USB_PAGE_SIZE < EHCI_FSTN_ALIGN) || (EHCI_FSTN_ALIGN == 0)) +#error "Invalid USB page size!" +#endif -/* link types */ -#define EHCI_LINK_TERMINATE 0x00000001 -#define EHCI_LINK_TYPE(x) ((x) & 0x00000006) -#define EHCI_LINK_ITD 0x0 -#define EHCI_LINK_QH 0x2 -#define EHCI_LINK_SITD 0x4 -#define EHCI_LINK_FSTN 0x6 -#define EHCI_LINK_ADDR(x) ((x) &~ 0x1f) -/* Isochronous Transfer Descriptor - * this descriptor is used for high speed transfers only +/* + * Isochronous Transfer Descriptor. This descriptor is used for high speed + * transfers only. */ -#define EHCI_ITD_ALIGN 128 /* bytes */ typedef struct ehci_itd { - __volatile__ u_int32_t itd_next; - __volatile__ u_int32_t itd_status[8]; -#define EHCI_ITD_SET_LEN(x) ((x) << 16) -#define EHCI_ITD_GET_LEN(x) (((x) >> 16) & 0xFFF) -#define EHCI_ITD_IOC (1 << 15) -#define EHCI_ITD_SET_PG(x) ((x) << 12) -#define EHCI_ITD_GET_PG(x) (((x) >> 12) & 0x7) -#define EHCI_ITD_SET_OFFS(x) (x) -#define EHCI_ITD_GET_OFFS(x) (((x) >> 0) & 0xFFF) -#define EHCI_ITD_ACTIVE (1 << 31) -#define EHCI_ITD_DATABUFERR (1 << 30) -#define EHCI_ITD_BABBLE (1 << 29) -#define EHCI_ITD_XACTERR (1 << 28) - __volatile__ u_int32_t itd_bp[7]; - /* itd_bp[0] */ -#define EHCI_ITD_SET_ADDR(x) (x) -#define EHCI_ITD_GET_ADDR(x) (((x) >> 0) & 0x7F) -#define EHCI_ITD_SET_ENDPT(x) ((x) << 8) -#define EHCI_ITD_GET_ENDPT(x) (((x) >> 8) & 0xF) - /* itd_bp[1] */ -#define EHCI_ITD_SET_DIR_IN (1 << 11) -#define EHCI_ITD_SET_DIR_OUT (0 << 11) -#define EHCI_ITD_SET_MPL(x) (x) -#define EHCI_ITD_GET_MPL(x) (((x) >> 0) & 0x7FF) + volatile uint32_t itd_next; + volatile uint32_t itd_status[8]; +#define EHCI_ITD_SET_LEN(x) ((x) << 16) +#define EHCI_ITD_GET_LEN(x) (((x) >> 16) & 0xFFF) +#define EHCI_ITD_IOC (1 << 15) +#define EHCI_ITD_SET_PG(x) ((x) << 12) +#define EHCI_ITD_GET_PG(x) (((x) >> 12) & 0x7) +#define EHCI_ITD_SET_OFFS(x) (x) +#define EHCI_ITD_GET_OFFS(x) (((x) >> 0) & 0xFFF) +#define EHCI_ITD_ACTIVE (1 << 31) +#define EHCI_ITD_DATABUFERR (1 << 30) +#define EHCI_ITD_BABBLE (1 << 29) +#define EHCI_ITD_XACTERR (1 << 28) + volatile uint32_t itd_bp[7]; + /* itd_bp[0] */ +#define EHCI_ITD_SET_ADDR(x) (x) +#define EHCI_ITD_GET_ADDR(x) (((x) >> 0) & 0x7F) +#define EHCI_ITD_SET_ENDPT(x) ((x) << 8) +#define EHCI_ITD_GET_ENDPT(x) (((x) >> 8) & 0xF) + /* itd_bp[1] */ +#define EHCI_ITD_SET_DIR_IN (1 << 11) +#define EHCI_ITD_SET_DIR_OUT (0 << 11) +#define EHCI_ITD_SET_MPL(x) (x) +#define EHCI_ITD_GET_MPL(x) (((x) >> 0) & 0x7FF) + volatile uint32_t itd_bp_hi[7]; +/* + * Extra information needed: + */ + uint32_t itd_self; + struct ehci_itd *next; + struct ehci_itd *prev; + struct ehci_itd *obj_next; +} __aligned(EHCI_ITD_ALIGN) ehci_itd_t; - __volatile__ u_int32_t itd_bp_hi[7]; - - /* - * extra information needed: - */ - u_int32_t itd_self; - - struct ehci_itd *next; - struct ehci_itd *prev; - struct ehci_itd *obj_next; - -} __attribute__((__aligned__(EHCI_ITD_ALIGN))) ehci_itd_t; - -/* Split Transaction Isochronous Transfer Descriptor - * this descriptor is used for full speed transfers only +/* + * Split Transaction Isochronous Transfer Descriptor. This descriptor is used + * for full speed transfers only. */ -#define EHCI_SITD_ALIGN 64 /* bytes */ typedef struct ehci_sitd { - __volatile__ u_int32_t sitd_next; - __volatile__ u_int32_t sitd_portaddr; -#define EHCI_SITD_SET_DIR_OUT (0 << 31) -#define EHCI_SITD_SET_DIR_IN (1 << 31) -#define EHCI_SITD_SET_ADDR(x) (x) -#define EHCI_SITD_GET_ADDR(x) ((x) & 0x7F) -#define EHCI_SITD_SET_ENDPT(x) ((x) << 8) -#define EHCI_SITD_GET_ENDPT(x) (((x) >> 8) & 0xF) -#define EHCI_SITD_GET_DIR(x) ((x) >> 31) -#define EHCI_SITD_SET_PORT(x) ((x) << 24) -#define EHCI_SITD_GET_PORT(x) (((x) >> 24) & 0x7F) -#define EHCI_SITD_SET_HUBA(x) ((x) << 16) -#define EHCI_SITD_GET_HUBA(x) (((x) >> 16) & 0x7F) - __volatile__ u_int32_t sitd_mask; -#define EHCI_SITD_SET_SMASK(x) (x) -#define EHCI_SITD_SET_CMASK(x) ((x) << 8) - __volatile__ u_int32_t sitd_status; -#define EHCI_SITD_COMPLETE_SPLIT (1<<1) -#define EHCI_SITD_START_SPLIT (0<<1) -#define EHCI_SITD_MISSED_MICRO_FRAME (1<<2) -#define EHCI_SITD_XACTERR (1<<3) -#define EHCI_SITD_BABBLE (1<<4) -#define EHCI_SITD_DATABUFERR (1<<5) -#define EHCI_SITD_ERROR (1<<6) -#define EHCI_SITD_ACTIVE (1<<7) -#define EHCI_SITD_IOC (1<<31) -#define EHCI_SITD_SET_LEN(len) ((len)<<16) -#define EHCI_SITD_GET_LEN(x) (((x)>>16) & 0x3FF) - __volatile__ u_int32_t sitd_bp[2]; - __volatile__ u_int32_t sitd_back; + volatile uint32_t sitd_next; + volatile uint32_t sitd_portaddr; +#define EHCI_SITD_SET_DIR_OUT (0 << 31) +#define EHCI_SITD_SET_DIR_IN (1 << 31) +#define EHCI_SITD_SET_ADDR(x) (x) +#define EHCI_SITD_GET_ADDR(x) ((x) & 0x7F) +#define EHCI_SITD_SET_ENDPT(x) ((x) << 8) +#define EHCI_SITD_GET_ENDPT(x) (((x) >> 8) & 0xF) +#define EHCI_SITD_GET_DIR(x) ((x) >> 31) +#define EHCI_SITD_SET_PORT(x) ((x) << 24) +#define EHCI_SITD_GET_PORT(x) (((x) >> 24) & 0x7F) +#define EHCI_SITD_SET_HUBA(x) ((x) << 16) +#define EHCI_SITD_GET_HUBA(x) (((x) >> 16) & 0x7F) + volatile uint32_t sitd_mask; +#define EHCI_SITD_SET_SMASK(x) (x) +#define EHCI_SITD_SET_CMASK(x) ((x) << 8) + volatile uint32_t sitd_status; +#define EHCI_SITD_COMPLETE_SPLIT (1<<1) +#define EHCI_SITD_START_SPLIT (0<<1) +#define EHCI_SITD_MISSED_MICRO_FRAME (1<<2) +#define EHCI_SITD_XACTERR (1<<3) +#define EHCI_SITD_BABBLE (1<<4) +#define EHCI_SITD_DATABUFERR (1<<5) +#define EHCI_SITD_ERROR (1<<6) +#define EHCI_SITD_ACTIVE (1<<7) +#define EHCI_SITD_IOC (1<<31) +#define EHCI_SITD_SET_LEN(len) ((len)<<16) +#define EHCI_SITD_GET_LEN(x) (((x)>>16) & 0x3FF) + volatile uint32_t sitd_bp[2]; + volatile uint32_t sitd_back; + volatile uint32_t sitd_bp_hi[2]; +/* + * Extra information needed: + */ + uint32_t sitd_self; + struct ehci_sitd *next; + struct ehci_sitd *prev; + struct ehci_sitd *obj_next; +} __aligned(EHCI_SITD_ALIGN) ehci_sitd_t; - __volatile__ u_int32_t sitd_bp_hi[2]; - - /* - * extra information needed: - */ - u_int32_t sitd_self; - - struct ehci_sitd *next; - struct ehci_sitd *prev; - struct ehci_sitd *obj_next; - -} __attribute__((__aligned__(EHCI_SITD_ALIGN))) ehci_sitd_t; - /* Queue Element Transfer Descriptor */ -#define EHCI_QTD_NBUFFERS 5 -#define EHCI_QTD_ALIGN 64 /* bytes */ typedef struct ehci_qtd { - __volatile__ u_int32_t qtd_next; - __volatile__ u_int32_t qtd_altnext; - __volatile__ u_int32_t qtd_status; -#define EHCI_QTD_GET_STATUS(x) (((x) >> 0) & 0xff) -#define EHCI_QTD_SET_STATUS(x) ((x) << 0) -#define EHCI_QTD_ACTIVE 0x80 -#define EHCI_QTD_HALTED 0x40 -#define EHCI_QTD_BUFERR 0x20 -#define EHCI_QTD_BABBLE 0x10 -#define EHCI_QTD_XACTERR 0x08 -#define EHCI_QTD_MISSEDMICRO 0x04 -#define EHCI_QTD_SPLITXSTATE 0x02 -#define EHCI_QTD_PINGSTATE 0x01 -#define EHCI_QTD_STATERRS 0x74 -#define EHCI_QTD_GET_PID(x) (((x) >> 8) & 0x3) -#define EHCI_QTD_SET_PID(x) ((x) << 8) -#define EHCI_QTD_PID_OUT 0x0 -#define EHCI_QTD_PID_IN 0x1 -#define EHCI_QTD_PID_SETUP 0x2 -#define EHCI_QTD_GET_CERR(x) (((x) >> 10) & 0x3) -#define EHCI_QTD_SET_CERR(x) ((x) << 10) -#define EHCI_QTD_GET_C_PAGE(x) (((x) >> 12) & 0x7) -#define EHCI_QTD_SET_C_PAGE(x) ((x) << 12) -#define EHCI_QTD_GET_IOC(x) (((x) >> 15) & 0x1) -#define EHCI_QTD_IOC 0x00008000 -#define EHCI_QTD_GET_BYTES(x) (((x) >> 16) & 0x7fff) -#define EHCI_QTD_SET_BYTES(x) ((x) << 16) -#define EHCI_QTD_GET_TOGGLE(x) (((x) >> 31) & 0x1) + volatile uint32_t qtd_next; + volatile uint32_t qtd_altnext; + volatile uint32_t qtd_status; +#define EHCI_QTD_GET_STATUS(x) (((x) >> 0) & 0xff) +#define EHCI_QTD_SET_STATUS(x) ((x) << 0) +#define EHCI_QTD_ACTIVE 0x80 +#define EHCI_QTD_HALTED 0x40 +#define EHCI_QTD_BUFERR 0x20 +#define EHCI_QTD_BABBLE 0x10 +#define EHCI_QTD_XACTERR 0x08 +#define EHCI_QTD_MISSEDMICRO 0x04 +#define EHCI_QTD_SPLITXSTATE 0x02 +#define EHCI_QTD_PINGSTATE 0x01 +#define EHCI_QTD_STATERRS 0x74 +#define EHCI_QTD_GET_PID(x) (((x) >> 8) & 0x3) +#define EHCI_QTD_SET_PID(x) ((x) << 8) +#define EHCI_QTD_PID_OUT 0x0 +#define EHCI_QTD_PID_IN 0x1 +#define EHCI_QTD_PID_SETUP 0x2 +#define EHCI_QTD_GET_CERR(x) (((x) >> 10) & 0x3) +#define EHCI_QTD_SET_CERR(x) ((x) << 10) +#define EHCI_QTD_GET_C_PAGE(x) (((x) >> 12) & 0x7) +#define EHCI_QTD_SET_C_PAGE(x) ((x) << 12) +#define EHCI_QTD_GET_IOC(x) (((x) >> 15) & 0x1) +#define EHCI_QTD_IOC 0x00008000 +#define EHCI_QTD_GET_BYTES(x) (((x) >> 16) & 0x7fff) +#define EHCI_QTD_SET_BYTES(x) ((x) << 16) +#define EHCI_QTD_GET_TOGGLE(x) (((x) >> 31) & 0x1) #define EHCI_QTD_SET_TOGGLE(x) ((x) << 31) -#define EHCI_QTD_TOGGLE_MASK 0x80000000 - __volatile__ u_int32_t qtd_buffer[EHCI_QTD_NBUFFERS]; - __volatile__ u_int32_t qtd_buffer_hi[EHCI_QTD_NBUFFERS]; - - /* - * extra information needed: - */ - struct ehci_qtd *obj_next; - - u_int32_t qtd_self; - - u_int16_t len; - -} __attribute__((__aligned__(EHCI_QTD_ALIGN))) ehci_qtd_t; +#define EHCI_QTD_TOGGLE_MASK 0x80000000 +#define EHCI_QTD_NBUFFERS 5 + volatile uint32_t qtd_buffer[EHCI_QTD_NBUFFERS]; + volatile uint32_t qtd_buffer_hi[EHCI_QTD_NBUFFERS]; +/* + * Extra information needed: + */ + struct ehci_qtd *obj_next; + uint32_t qtd_self; + uint16_t len; +} __aligned(EHCI_QTD_ALIGN) ehci_qtd_t; /* Queue Head */ -#define EHCI_QH_ALIGN 128 /* bytes */ typedef struct ehci_qh { - __volatile__ u_int32_t qh_link; - __volatile__ u_int32_t qh_endp; -#define EHCI_QH_GET_ADDR(x) (((x) >> 0) & 0x7f) /* endpoint addr */ -#define EHCI_QH_SET_ADDR(x) (x) -#define EHCI_QH_ADDRMASK 0x0000007f -#define EHCI_QH_GET_INACT(x) (((x) >> 7) & 0x01) /* inactivate on next */ -#define EHCI_QH_INACT 0x00000080 -#define EHCI_QH_GET_ENDPT(x) (((x) >> 8) & 0x0f) /* endpoint no */ -#define EHCI_QH_SET_ENDPT(x) ((x) << 8) -#define EHCI_QH_GET_EPS(x) (((x) >> 12) & 0x03) /* endpoint speed */ -#define EHCI_QH_SET_EPS(x) ((x) << 12) -#define EHCI_QH_SPEED_FULL 0x0 -#define EHCI_QH_SPEED_LOW 0x1 -#define EHCI_QH_SPEED_HIGH 0x2 -#define EHCI_QH_GET_DTC(x) (((x) >> 14) & 0x01) /* data toggle control */ -#define EHCI_QH_DTC 0x00004000 -#define EHCI_QH_GET_HRECL(x) (((x) >> 15) & 0x01) /* head of reclamation */ -#define EHCI_QH_HRECL 0x00008000 -#define EHCI_QH_GET_MPL(x) (((x) >> 16) & 0x7ff) /* max packet len */ -#define EHCI_QH_SET_MPL(x) ((x) << 16) -#define EHCI_QH_MPLMASK 0x07ff0000 -#define EHCI_QH_GET_CTL(x) (((x) >> 27) & 0x01) /* control endpoint */ -#define EHCI_QH_CTL 0x08000000 -#define EHCI_QH_GET_NRL(x) (((x) >> 28) & 0x0f) /* NAK reload */ -#define EHCI_QH_SET_NRL(x) ((x) << 28) - __volatile__ u_int32_t qh_endphub; -#define EHCI_QH_GET_SMASK(x) (((x) >> 0) & 0xff) /* intr sched mask */ -#define EHCI_QH_SET_SMASK(x) ((x) << 0) -#define EHCI_QH_GET_CMASK(x) (((x) >> 8) & 0xff) /* split completion mask */ -#define EHCI_QH_SET_CMASK(x) ((x) << 8) -#define EHCI_QH_GET_HUBA(x) (((x) >> 16) & 0x7f) /* hub address */ -#define EHCI_QH_SET_HUBA(x) ((x) << 16) -#define EHCI_QH_GET_PORT(x) (((x) >> 23) & 0x7f) /* hub port */ -#define EHCI_QH_SET_PORT(x) ((x) << 23) -#define EHCI_QH_GET_MULT(x) (((x) >> 30) & 0x03) /* pipe multiplier */ -#define EHCI_QH_SET_MULT(x) ((x) << 30) - __volatile__ u_int32_t qh_curqtd; + volatile uint32_t qh_link; + volatile uint32_t qh_endp; +#define EHCI_QH_GET_ADDR(x) (((x) >> 0) & 0x7f) /* endpoint addr */ +#define EHCI_QH_SET_ADDR(x) (x) +#define EHCI_QH_ADDRMASK 0x0000007f +#define EHCI_QH_GET_INACT(x) (((x) >> 7) & 0x01) /* inactivate on next */ +#define EHCI_QH_INACT 0x00000080 +#define EHCI_QH_GET_ENDPT(x) (((x) >> 8) & 0x0f) /* endpoint no */ +#define EHCI_QH_SET_ENDPT(x) ((x) << 8) +#define EHCI_QH_GET_EPS(x) (((x) >> 12) & 0x03) /* endpoint speed */ +#define EHCI_QH_SET_EPS(x) ((x) << 12) +#define EHCI_QH_SPEED_FULL 0x0 +#define EHCI_QH_SPEED_LOW 0x1 +#define EHCI_QH_SPEED_HIGH 0x2 +#define EHCI_QH_GET_DTC(x) (((x) >> 14) & 0x01) /* data toggle control */ +#define EHCI_QH_DTC 0x00004000 +#define EHCI_QH_GET_HRECL(x) (((x) >> 15) & 0x01) /* head of reclamation */ +#define EHCI_QH_HRECL 0x00008000 +#define EHCI_QH_GET_MPL(x) (((x) >> 16) & 0x7ff) /* max packet len */ +#define EHCI_QH_SET_MPL(x) ((x) << 16) +#define EHCI_QH_MPLMASK 0x07ff0000 +#define EHCI_QH_GET_CTL(x) (((x) >> 27) & 0x01) /* control endpoint */ +#define EHCI_QH_CTL 0x08000000 +#define EHCI_QH_GET_NRL(x) (((x) >> 28) & 0x0f) /* NAK reload */ +#define EHCI_QH_SET_NRL(x) ((x) << 28) + volatile uint32_t qh_endphub; +#define EHCI_QH_GET_SMASK(x) (((x) >> 0) & 0xff) /* intr sched mask */ +#define EHCI_QH_SET_SMASK(x) ((x) << 0) +#define EHCI_QH_GET_CMASK(x) (((x) >> 8) & 0xff) /* split completion mask */ +#define EHCI_QH_SET_CMASK(x) ((x) << 8) +#define EHCI_QH_GET_HUBA(x) (((x) >> 16) & 0x7f) /* hub address */ +#define EHCI_QH_SET_HUBA(x) ((x) << 16) +#define EHCI_QH_GET_PORT(x) (((x) >> 23) & 0x7f) /* hub port */ +#define EHCI_QH_SET_PORT(x) ((x) << 23) +#define EHCI_QH_GET_MULT(x) (((x) >> 30) & 0x03) /* pipe multiplier */ +#define EHCI_QH_SET_MULT(x) ((x) << 30) + volatile uint32_t qh_curqtd; struct { - __volatile__ u_int32_t qtd_next; - __volatile__ u_int32_t qtd_altnext; - __volatile__ u_int32_t qtd_status; - __volatile__ u_int32_t qtd_buffer[EHCI_QTD_NBUFFERS]; - __volatile__ u_int32_t qtd_buffer_hi[EHCI_QTD_NBUFFERS]; - } __attribute__((__aligned__(4))) qh_qtd; - - /* - * extra information needed: - */ - struct ehci_qh *next; - struct ehci_qh *prev; - struct ehci_qh *obj_next; - - u_int32_t qh_self; + volatile uint32_t qtd_next; + volatile uint32_t qtd_altnext; + volatile uint32_t qtd_status; + volatile uint32_t qtd_buffer[EHCI_QTD_NBUFFERS]; + volatile uint32_t qtd_buffer_hi[EHCI_QTD_NBUFFERS]; + } __aligned(4) qh_qtd; +/* + * Extra information needed: + */ + struct ehci_qh *next; + struct ehci_qh *prev; + struct ehci_qh *obj_next; + uint32_t qh_self; +} __aligned(EHCI_QH_ALIGN) ehci_qh_t; -} __attribute__((__aligned__(EHCI_QH_ALIGN))) ehci_qh_t; - /* Periodic Frame Span Traversal Node */ -#define EHCI_FSTN_ALIGN 32 /* bytes */ typedef struct { - __volatile__ u_int32_t fstn_link; - __volatile__ u_int32_t fstn_back; + volatile uint32_t fstn_link; + volatile uint32_t fstn_back; +} __aligned(EHCI_FSTN_ALIGN) ehci_fstn_t; -} __attribute__((__aligned__(EHCI_FSTN_ALIGN))) ehci_fstn_t; - -#if ((USB_PAGE_SIZE < EHCI_PAGE_SIZE) || (EHCI_PAGE_SIZE == 0) || \ - (USB_PAGE_SIZE < EHCI_ITD_ALIGN) || (EHCI_ITD_ALIGN == 0) || \ - (USB_PAGE_SIZE < EHCI_SITD_ALIGN) || (EHCI_SITD_ALIGN == 0) || \ - (USB_PAGE_SIZE < EHCI_QTD_ALIGN) || (EHCI_QTD_ALIGN == 0) || \ - (USB_PAGE_SIZE < EHCI_QH_ALIGN) || (EHCI_QH_ALIGN == 0) || \ - (USB_PAGE_SIZE < EHCI_FSTN_ALIGN) || (EHCI_FSTN_ALIGN == 0)) -#error "Invalid USB page size!" -#endif struct ehci_hw_softc { u_int32_t pframes[EHCI_FRAMELIST_COUNT]; /* start TD pointer */ - /* structures with highest alignment are first */ - ehci_qh_t async_start; ehci_qh_t intr_start[EHCI_VIRTUAL_FRAMELIST_COUNT]; ehci_itd_t isoc_hs_start[EHCI_VIRTUAL_FRAMELIST_COUNT]; @@ -415,84 +391,78 @@ }; typedef struct ehci_softc { - struct ehci_hw_softc sc_hw; /* hardware structures first */ + struct ehci_hw_softc sc_hw; /* hardware structures first */ - ehci_qh_t * sc_async_p_last; - ehci_qh_t * sc_intr_p_last[EHCI_VIRTUAL_FRAMELIST_COUNT]; + ehci_qh_t *sc_async_p_last; + ehci_qh_t *sc_intr_p_last[EHCI_VIRTUAL_FRAMELIST_COUNT]; u_int16_t sc_intr_stat[EHCI_VIRTUAL_FRAMELIST_COUNT]; - ehci_sitd_t * sc_isoc_fs_p_last[EHCI_VIRTUAL_FRAMELIST_COUNT]; - ehci_itd_t * sc_isoc_hs_p_last[EHCI_VIRTUAL_FRAMELIST_COUNT]; - - u_int32_t sc_physaddr; - + ehci_sitd_t *sc_isoc_fs_p_last[EHCI_VIRTUAL_FRAMELIST_COUNT]; + ehci_itd_t *sc_isoc_hs_p_last[EHCI_VIRTUAL_FRAMELIST_COUNT]; + uint32_t sc_physaddr; struct usbd_bus sc_bus; /* base device */ bus_space_tag_t iot; bus_space_handle_t ioh; bus_size_t sc_size; - void * ih; + void *ih; - struct resource * io_res; - struct resource * irq_res; + struct resource *io_res; + struct resource *irq_res; device_t sc_dev; - u_int8_t sc_offs; /* offset to operational registers */ - u_int8_t sc_doorbell_disable; /* set on doorbell failure */ + uint8_t sc_offs; /* offset to operational registers */ + uint8_t sc_doorbell_disable; /* set on doorbell failure */ - char sc_vendor[16]; /* vendor string for root hub */ - int sc_id_vendor; /* vendor ID for root hub */ + char sc_vendor[16]; /* vendor string for root hub */ + int sc_id_vendor; /* vendor ID for root hub */ -#if defined(__NetBSD__) || defined(__OpenBSD__) - void *sc_powerhook; /* cookie from power hook */ - void *sc_shutdownhook; /* cookie from shutdown hook */ +#if defined(__NetBSD__) + void *sc_powerhook; /* cookie from power hook */ + void *sc_shutdownhook; /* cookie from shutdown hook */ #endif - LIST_HEAD(, usbd_xfer) sc_interrupt_list_head; - u_int8_t sc_noport; - u_int8_t sc_addr; /* device address */ - u_int8_t sc_conf; /* device configuration */ - struct usbd_xfer * sc_intrxfer; - u_int8_t sc_isreset; + uint8_t sc_noport; + uint8_t sc_addr; /* device address */ + uint8_t sc_conf; /* device configuration */ + struct usbd_xfer *sc_intrxfer; + uint8_t sc_isreset; - u_int32_t sc_eintrs; - u_int32_t sc_cmd; /* shadow of cmd register during suspend */ + uint32_t sc_eintrs; + uint32_t sc_cmd; /* shadow of cmd register during suspend */ struct __callout sc_tmo_pcd; - } ehci_softc_t; -#define EREAD1(sc, a) bus_space_read_1((sc)->iot, (sc)->ioh, (a)) -#define EREAD2(sc, a) bus_space_read_2((sc)->iot, (sc)->ioh, (a)) -#define EREAD4(sc, a) bus_space_read_4((sc)->iot, (sc)->ioh, (a)) -#define EWRITE1(sc, a, x) bus_space_write_1((sc)->iot, (sc)->ioh, (a), (x)) -#define EWRITE2(sc, a, x) bus_space_write_2((sc)->iot, (sc)->ioh, (a), (x)) -#define EWRITE4(sc, a, x) bus_space_write_4((sc)->iot, (sc)->ioh, (a), (x)) -#define EOREAD1(sc, a) bus_space_read_1((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a)) -#define EOREAD2(sc, a) bus_space_read_2((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a)) -#define EOREAD4(sc, a) bus_space_read_4((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a)) -#define EOWRITE1(sc, a, x) bus_space_write_1((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a), (x)) -#define EOWRITE2(sc, a, x) bus_space_write_2((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a), (x)) -#define EOWRITE4(sc, a, x) bus_space_write_4((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a), (x)) +#define EREAD1(sc, a) bus_space_read_1((sc)->iot, (sc)->ioh, (a)) +#define EREAD2(sc, a) bus_space_read_2((sc)->iot, (sc)->ioh, (a)) +#define EREAD4(sc, a) bus_space_read_4((sc)->iot, (sc)->ioh, (a)) +#define EWRITE1(sc, a, x) \ + bus_space_write_1((sc)->iot, (sc)->ioh, (a), (x)) +#define EWRITE2(sc, a, x) \ + bus_space_write_2((sc)->iot, (sc)->ioh, (a), (x)) +#define EWRITE4(sc, a, x) \ + bus_space_write_4((sc)->iot, (sc)->ioh, (a), (x)) +#define EOREAD1(sc, a) \ + bus_space_read_1((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a)) +#define EOREAD2(sc, a) \ + bus_space_read_2((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a)) +#define EOREAD4(sc, a) \ + bus_space_read_4((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a)) +#define EOWRITE1(sc, a, x) \ + bus_space_write_1((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a), (x)) +#define EOWRITE2(sc, a, x) \ + bus_space_write_2((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a), (x)) +#define EOWRITE4(sc, a, x) \ + bus_space_write_4((sc)->iot, (sc)->ioh, (sc)->sc_offs+(a), (x)) -usbd_status -ehci_init(ehci_softc_t *sc); - -void -ehci_detach(struct ehci_softc *sc); - -void -ehci_suspend(struct ehci_softc *sc); - -void -ehci_resume(struct ehci_softc *sc); - -void -ehci_shutdown(ehci_softc_t *sc); - -void -ehci_interrupt(ehci_softc_t *sc); +usbd_status ehci_init(ehci_softc_t *sc); +void ehci_detach(struct ehci_softc *sc); +void ehci_suspend(struct ehci_softc *sc); +void ehci_resume(struct ehci_softc *sc); +void ehci_shutdown(ehci_softc_t *sc); +void ehci_interrupt(ehci_softc_t *sc); #endif /* _EHCI_H_ */ From owner-p4-projects@FreeBSD.ORG Tue Sep 26 12:34:00 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D448F16A698; Tue, 26 Sep 2006 12:33:59 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 7EEC416A64A for ; Tue, 26 Sep 2006 12:33:59 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2ED2A43D6B for ; Tue, 26 Sep 2006 12:33:48 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QCXmIG018032 for ; Tue, 26 Sep 2006 12:33:48 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QCXlXp018026 for perforce@freebsd.org; Tue, 26 Sep 2006 12:33:47 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 12:33:47 GMT Message-Id: <200609261233.k8QCXlXp018026@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106716 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 12:34:00 -0000 http://perforce.freebsd.org/chv.cgi?CH=106716 Change 106716 by attilio@attilio_laptop on 2006/09/26 12:32:49 It change BSDish u_* with ANSI C u* and generically applies style(9). Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_auereg.h#7 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_auereg.h#7 (text+ko) ==== @@ -172,18 +172,18 @@ #define AUE_GPIO_SEL1 0x20 struct aue_intrpkt { - u_int8_t aue_txstat0; - u_int8_t aue_txstat1; - u_int8_t aue_rxstat; - u_int8_t aue_rxlostpkt0; - u_int8_t aue_rxlostpkt1; - u_int8_t aue_wakeupstat; - u_int8_t aue_rsvd; + uint8_t aue_txstat0; + uint8_t aue_txstat1; + uint8_t aue_rxstat; + uint8_t aue_rxlostpkt0; + uint8_t aue_rxlostpkt1; + uint8_t aue_wakeupstat; + uint8_t aue_rsvd; } __packed; struct aue_rxpkt { - u_int16_t aue_pktlen; - u_int8_t aue_rxstat; + uint16_t aue_pktlen; + uint8_t aue_rxstat; } __packed; #define AUE_RXSTAT_MCAST 0x01 @@ -193,7 +193,7 @@ #define AUE_RXSTAT_DRIBBLE 0x10 #define AUE_RXSTAT_MASK 0x1E -#define GET_MII(sc) ((sc)->sc_miibus ? \ +#define GET_MII(sc) ((sc)->sc_miibus ? \ device_get_softc((sc)->sc_miibus) : NULL) struct aue_softc { @@ -203,37 +203,37 @@ struct mtx sc_mtx; struct aue_rxpkt sc_rxpkt; - struct ifnet * sc_ifp; - struct usbd_device * sc_udev; - struct usbd_xfer * sc_xfer[AUE_ENDPT_MAX]; + struct ifnet *sc_ifp; + struct usbd_device *sc_udev; + struct usbd_xfer *sc_xfer[AUE_ENDPT_MAX]; device_t sc_miibus; device_t sc_dev; - u_int32_t sc_unit; - u_int32_t sc_media_active; - u_int32_t sc_media_status; + uint32_t sc_unit; + uint32_t sc_media_active; + uint32_t sc_media_status; - u_int16_t sc_vendor; - u_int16_t sc_product; - u_int16_t sc_flags; -#define AUE_FLAG_LSYS 0x0001 /* use Linksys reset */ -#define AUE_FLAG_PNA 0x0002 /* has Home PNA */ -#define AUE_FLAG_PII 0x0004 /* Pegasus II chip */ -#define AUE_FLAG_WAIT_LINK 0x0008 /* wait for link to come up */ -#define AUE_FLAG_READ_STALL 0x0010 /* wait for clearing of stall */ -#define AUE_FLAG_WRITE_STALL 0x0020 /* wait for clearing of stall */ -#define AUE_FLAG_LL_READY 0x0040 /* Lower Layer Ready */ -#define AUE_FLAG_HL_READY 0x0080 /* Higher Layer Ready */ -#define AUE_FLAG_INTR_STALL 0x0100 /* wait for clearing of stall */ + uint16_t sc_vendor; + uint16_t sc_product; + uint16_t sc_flags; +#define AUE_FLAG_LSYS 0x0001 /* use Linksys reset */ +#define AUE_FLAG_PNA 0x0002 /* has Home PNA */ +#define AUE_FLAG_PII 0x0004 /* Pegasus II chip */ +#define AUE_FLAG_WAIT_LINK 0x0008 /* wait for link to come up */ +#define AUE_FLAG_READ_STALL 0x0010 /* wait for clearing of stall */ +#define AUE_FLAG_WRITE_STALL 0x0020 /* wait for clearing of stall */ +#define AUE_FLAG_LL_READY 0x0040 /* Lower Layer Ready */ +#define AUE_FLAG_HL_READY 0x0080 /* Higher Layer Ready */ +#define AUE_FLAG_INTR_STALL 0x0100 /* wait for clearing of stall */ - u_int8_t sc_name[16]; + uint8_t sc_name[16]; }; #define AUE_TIMEOUT 100 /* 10*ms */ #define AUE_MIN_FRAMELEN 60 struct aue_config_copy { - u_int32_t if_flags; - u_int8_t if_lladdr[ETHER_ADDR_LEN]; - u_int8_t if_hash[8]; + uint32_t if_flags; + uint8_t if_lladdr[ETHER_ADDR_LEN]; + uint8_t if_hash[8]; }; From owner-p4-projects@FreeBSD.ORG Tue Sep 26 13:16:44 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id F3BD816A494; Tue, 26 Sep 2006 13:16:43 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 CFF7C16A416 for ; Tue, 26 Sep 2006 13:16:43 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8FCCE43D6E for ; Tue, 26 Sep 2006 13:16:43 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QDGhCP030449 for ; Tue, 26 Sep 2006 13:16:43 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QDGh4K030446 for perforce@freebsd.org; Tue, 26 Sep 2006 13:16:43 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 13:16:43 GMT Message-Id: <200609261316.k8QDGh4K030446@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106719 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 13:16:44 -0000 http://perforce.freebsd.org/chv.cgi?CH=106719 Change 106719 by attilio@attilio_laptop on 2006/09/26 13:15:47 Style-ize it Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_axereg.h#7 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_axereg.h#7 (text+ko) ==== @@ -38,84 +38,79 @@ /* - * Vendor specific commands - * ASIX conveniently doesn't document the 'set NODEID' command in their - * datasheet (thanks a lot guys). - * To make handling these commands easier, I added some extra data - * which is decided by the axe_cmd() routine. Commands are encoded - * in 16 bites, with the format: LDCC. L and D are both nibbles in - * the high byte. L represents the data length (0 to 15) and D - * represents the direction (0 for vendor read, 1 for vendor write). - * CC is the command byte, as specified in the manual. + * Vendor specific commands. ASIX conveniently doesn't document the 'set + * NODEID' command in their datasheet (thanks a lot guys). + * To make handling these commands easier, I added some extra data which is + * decided by the axe_cmd() routine. Commands are encoded in 16 bytes, with + * the format: LDCC. L and D are both nibbles in the high byte. L represents + * the data length (0 to 15) and D represents the direction (0 for vendor read, + * 1 for vendor write). CC is the command byte, as specified in the manual. */ -#define AXE_CMD_IS_WRITE(x) (((x) & 0x0F00) >> 8) -#define AXE_CMD_LEN(x) (((x) & 0xF000) >> 12) -#define AXE_CMD_CMD(x) ((x) & 0x00FF) +#define AXE_CMD_IS_WRITE(x) (((x) & 0x0F00) >> 8) +#define AXE_CMD_LEN(x) (((x) & 0xF000) >> 12) +#define AXE_CMD_CMD(x) ((x) & 0x00FF) -#define AXE_CMD_READ_RXTX_SRAM 0x2002 -#define AXE_CMD_WRITE_RX_SRAM 0x0103 -#define AXE_CMD_WRITE_TX_SRAM 0x0104 -#define AXE_CMD_MII_OPMODE_SW 0x0106 -#define AXE_CMD_MII_READ_REG 0x2007 -#define AXE_CMD_MII_WRITE_REG 0x2108 -#define AXE_CMD_MII_READ_OPMODE 0x1009 -#define AXE_CMD_MII_OPMODE_HW 0x010A +#define AXE_CMD_READ_RXTX_SRAM 0x2002 +#define AXE_CMD_WRITE_RX_SRAM 0x0103 +#define AXE_CMD_WRITE_TX_SRAM 0x0104 +#define AXE_CMD_MII_OPMODE_SW 0x0106 +#define AXE_CMD_MII_READ_REG 0x2007 +#define AXE_CMD_MII_WRITE_REG 0x2108 +#define AXE_CMD_MII_READ_OPMODE 0x1009 +#define AXE_CMD_MII_OPMODE_HW 0x010A #define AXE_CMD_SROM_READ 0x200B -#define AXE_CMD_SROM_WRITE 0x010C -#define AXE_CMD_SROM_WR_ENABLE 0x010D -#define AXE_CMD_SROM_WR_DISABLE 0x010E -#define AXE_CMD_RXCTL_READ 0x200F -#define AXE_CMD_RXCTL_WRITE 0x0110 -#define AXE_CMD_READ_IPG012 0x3011 -#define AXE_CMD_WRITE_IPG0 0x0112 -#define AXE_CMD_WRITE_IPG1 0x0113 -#define AXE_CMD_WRITE_IPG2 0x0114 -#define AXE_CMD_READ_MCAST 0x8015 -#define AXE_CMD_WRITE_MCAST 0x8116 -#define AXE_CMD_READ_NODEID 0x6017 -#define AXE_CMD_WRITE_NODEID 0x6118 -#define AXE_CMD_READ_PHYID 0x2019 -#define AXE_CMD_READ_MEDIA 0x101A -#define AXE_CMD_WRITE_MEDIA 0x011B -#define AXE_CMD_READ_MONITOR_MODE 0x101C -#define AXE_CMD_WRITE_MONITOR_MODE 0x011D -#define AXE_CMD_READ_GPIO 0x101E -#define AXE_CMD_WRITE_GPIO 0x011F +#define AXE_CMD_SROM_WRITE 0x010C +#define AXE_CMD_SROM_WR_ENABLE 0x010D +#define AXE_CMD_SROM_WR_DISABLE 0x010E +#define AXE_CMD_RXCTL_READ 0x200F +#define AXE_CMD_RXCTL_WRITE 0x0110 +#define AXE_CMD_READ_IPG012 0x3011 +#define AXE_CMD_WRITE_IPG0 0x0112 +#define AXE_CMD_WRITE_IPG1 0x0113 +#define AXE_CMD_WRITE_IPG2 0x0114 +#define AXE_CMD_READ_MCAST 0x8015 +#define AXE_CMD_WRITE_MCAST 0x8116 +#define AXE_CMD_READ_NODEID 0x6017 +#define AXE_CMD_WRITE_NODEID 0x6118 +#define AXE_CMD_READ_PHYID 0x2019 +#define AXE_CMD_READ_MEDIA 0x101A +#define AXE_CMD_WRITE_MEDIA 0x011B +#define AXE_CMD_READ_MONITOR_MODE 0x101C +#define AXE_CMD_WRITE_MONITOR_MODE 0x011D +#define AXE_CMD_READ_GPIO 0x101E +#define AXE_CMD_WRITE_GPIO 0x011F -#define AXE_RXCMD_PROMISC 0x0001 -#define AXE_RXCMD_ALLMULTI 0x0002 -#define AXE_RXCMD_UNICAST 0x0004 -#define AXE_RXCMD_BROADCAST 0x0008 -#define AXE_RXCMD_MULTICAST 0x0010 -#define AXE_RXCMD_ENABLE 0x0080 +#define AXE_RXCMD_PROMISC 0x0001 +#define AXE_RXCMD_ALLMULTI 0x0002 +#define AXE_RXCMD_UNICAST 0x0004 +#define AXE_RXCMD_BROADCAST 0x0008 +#define AXE_RXCMD_MULTICAST 0x0010 +#define AXE_RXCMD_ENABLE 0x0080 -#define AXE_NOPHY 0xE0 +#define AXE_NOPHY 0xE0 -#define AXE_TIMEOUT 1000 -#define AXE_MIN_FRAMELEN 60 -#define AXE_RX_FRAMES 1 -#define AXE_TX_FRAMES 1 +#define AXE_TIMEOUT 1000 +#define AXE_MIN_FRAMELEN 60 +#define AXE_RX_FRAMES 1 +#define AXE_TX_FRAMES 1 -#define AXE_CTL_READ 0x01 -#define AXE_CTL_WRITE 0x02 +#define AXE_CTL_READ 0x01 +#define AXE_CTL_WRITE 0x02 -#define AXE_CONFIG_NO 1 -#define AXE_IFACE_IDX 0 +#define AXE_CONFIG_NO 1 +#define AXE_IFACE_IDX 0 -/* - * The interrupt endpoint is currently unused - * by the ASIX part. - */ -#define AXE_ENDPT_MAX 6 +/* The interrupt endpoint is currently unused by the ASIX part. */ +#define AXE_ENDPT_MAX 6 struct axe_type { - u_int16_t axe_vid; - u_int16_t axe_did; + uint16_t axe_vid; + uint16_t axe_did; }; -#define GET_MII(sc) ((sc)->sc_miibus ? \ - device_get_softc((sc)->sc_miibus) : NULL) +#define GET_MII(sc) ((sc)->sc_miibus ? \ + device_get_softc((sc)->sc_miibus) : NULL) struct axe_softc { struct usbd_config_td sc_config_td; @@ -123,32 +118,32 @@ struct __callout sc_watchdog; struct mtx sc_mtx; - struct ifnet * sc_ifp; - struct usbd_device * sc_udev; - struct usbd_xfer * sc_xfer[AXE_ENDPT_MAX]; + struct ifnet *sc_ifp; + struct usbd_device *sc_udev; + struct usbd_xfer *sc_xfer[AXE_ENDPT_MAX]; device_t sc_miibus; device_t sc_dev; - u_int32_t sc_unit; - u_int32_t sc_media_active; - u_int32_t sc_media_status; + uint32_t sc_unit; + uint32_t sc_media_active; + uint32_t sc_media_status; - u_int16_t sc_flags; -#define AXE_FLAG_WAIT_LINK 0x0001 -#define AXE_FLAG_INTR_STALL 0x0002 -#define AXE_FLAG_READ_STALL 0x0004 -#define AXE_FLAG_WRITE_STALL 0x0008 -#define AXE_FLAG_LL_READY 0x0010 -#define AXE_FLAG_HL_READY 0x0020 + uint16_t sc_flags; +#define AXE_FLAG_WAIT_LINK 0x0001 +#define AXE_FLAG_INTR_STALL 0x0002 +#define AXE_FLAG_READ_STALL 0x0004 +#define AXE_FLAG_WRITE_STALL 0x0008 +#define AXE_FLAG_LL_READY 0x0010 +#define AXE_FLAG_HL_READY 0x0020 - u_int8_t sc_ipgs[3]; - u_int8_t sc_phyaddrs[2]; + uint8_t sc_ipgs[3]; + uint8_t sc_phyaddrs[2]; - u_int8_t sc_name[16]; + uint8_t sc_name[16]; }; struct axe_config_copy { - u_int32_t if_flags; - u_int8_t if_lladdr[ETHER_ADDR_LEN]; - u_int8_t if_hash[8]; + uint32_t if_flags; + uint8_t if_lladdr[ETHER_ADDR_LEN]; + uint8_t if_hash[8]; }; From owner-p4-projects@FreeBSD.ORG Tue Sep 26 13:25:56 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1CC6A16A417; Tue, 26 Sep 2006 13:25:56 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 D3D9516A412 for ; Tue, 26 Sep 2006 13:25:55 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8E00243D49 for ; Tue, 26 Sep 2006 13:25:55 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QDPtUf031872 for ; Tue, 26 Sep 2006 13:25:55 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QDPtPp031869 for perforce@freebsd.org; Tue, 26 Sep 2006 13:25:55 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 13:25:55 GMT Message-Id: <200609261325.k8QDPtPp031869@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106720 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 13:25:56 -0000 http://perforce.freebsd.org/chv.cgi?CH=106720 Change 106720 by attilio@attilio_laptop on 2006/09/26 13:25:27 Style-ize it Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_cdcereg.h#6 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_cdcereg.h#6 (text+ko) ==== @@ -35,36 +35,36 @@ #ifndef _USB_IF_CDCEREG_H_ #define _USB_IF_CDCEREG_H_ +#define CDCE_ENDPT_MAX 4 + struct cdce_type { - struct usb_devno cdce_dev; - u_int16_t cdce_flags; + struct usb_devno cdce_dev; + u_int16_t cdce_flags; }; -#define CDCE_ENDPT_MAX 4 - struct cdce_softc { struct usbd_memory_wait sc_mem_wait; struct ifmedia sc_ifmedia; struct mtx sc_mtx; - struct ifnet * sc_ifp; - struct usbd_xfer * sc_xfer[CDCE_ENDPT_MAX]; - struct usbd_device * sc_udev; + struct ifnet *sc_ifp; + struct usbd_xfer *sc_xfer[CDCE_ENDPT_MAX]; + struct usbd_device *sc_udev; device_t sc_dev; - u_int32_t sc_unit; + uint32_t sc_unit; - u_int16_t sc_flags; -#define CDCE_FLAG_ZAURUS 0x0001 -#define CDCE_FLAG_NO_UNION 0x0002 -#define CDCE_FLAG_LL_READY 0x0004 -#define CDCE_FLAG_HL_READY 0x0008 -#define CDCE_FLAG_WRITE_STALL 0x0010 -#define CDCE_FLAG_READ_STALL 0x0020 + uint16_t sc_flags; +#define CDCE_FLAG_ZAURUS 0x0001 +#define CDCE_FLAG_NO_UNION 0x0002 +#define CDCE_FLAG_LL_READY 0x0004 +#define CDCE_FLAG_HL_READY 0x0008 +#define CDCE_FLAG_WRITE_STALL 0x0010 +#define CDCE_FLAG_READ_STALL 0x0020 - u_int8_t sc_name[16]; - u_int8_t sc_data_iface_no; - u_int8_t sc_data_iface_index; + uint8_t sc_name[16]; + uint8_t sc_data_iface_no; + uint8_t sc_data_iface_index; }; #endif /* _USB_IF_CDCEREG_H_ */ From owner-p4-projects@FreeBSD.ORG Tue Sep 26 13:40:15 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E2D6C16A412; Tue, 26 Sep 2006 13:40:14 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 A654E16A40F for ; Tue, 26 Sep 2006 13:40:14 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4AD1743D45 for ; Tue, 26 Sep 2006 13:40:14 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QDeEr6032526 for ; Tue, 26 Sep 2006 13:40:14 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QDeDvD032523 for perforce@freebsd.org; Tue, 26 Sep 2006 13:40:13 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 13:40:13 GMT Message-Id: <200609261340.k8QDeDvD032523@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106721 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 13:40:15 -0000 http://perforce.freebsd.org/chv.cgi?CH=106721 Change 106721 by attilio@attilio_laptop on 2006/09/26 13:39:51 Make some modifies I missed Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_auereg.h#8 edit .. //depot/projects/usb/src/sys/dev/usb/if_axereg.h#8 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_auereg.h#8 (text+ko) ==== @@ -42,134 +42,144 @@ * are 8 bits wide. * * Packet transfer is done in 64 byte chunks. The last chunk in a - * transfer is denoted by having a length less that 64 bytes. For + * transfer is denoted by having a length less that 64 bytes. For * the RX case, the data includes an optional RX status word. */ -#define AUE_UR_READREG 0xF0 -#define AUE_UR_WRITEREG 0xF1 +#define AUE_UR_READREG 0xF0 +#define AUE_UR_WRITEREG 0xF1 -#define AUE_CONFIG_NO 1 -#define AUE_IFACE_IDX 0 +#define AUE_CONFIG_NO 1 +#define AUE_IFACE_IDX 0 /* - * Note that while the ADMtek technically has four - * endpoints, the control endpoint (endpoint 0) is - * regarded as special by the USB code and drivers - * don't have direct access to it. (We access it - * using usbd_do_request() when reading/writing - * registers.) Consequently, our endpoint indexes - * don't match those in the ADMtek Pegasus manual: - * we consider the RX data endpoint to be index 0 - * and work up from there. + * Note that while the ADMtek technically has four endpoints, the control + * endpoint (endpoint 0) is regarded as special by the USB code and drivers + * don't have direct access to it (we access it using usbd_do_request() + * when reading/writing registers. Consequently, our endpoint indexes + * don't match those in the ADMtek Pegasus manual: we consider the RX data + * endpoint to be index 0 and work up from there. */ -#define AUE_ENDPT_MAX 6 +#define AUE_ENDPT_MAX 6 + +#define AUE_INTR_PKTLEN 0x8 + +#define AUE_CTL0 0x00 +#define AUE_CTL1 0x01 +#define AUE_CTL2 0x02 +#define AUE_MAR0 0x08 +#define AUE_MAR1 0x09 +#define AUE_MAR2 0x0A +#define AUE_MAR3 0x0B +#define AUE_MAR4 0x0C +#define AUE_MAR5 0x0D +#define AUE_MAR6 0x0E +#define AUE_MAR7 0x0F +#define AUE_MAR AUE_MAR0 +#define AUE_PAR0 0x10 +#define AUE_PAR1 0x11 +#define AUE_PAR2 0x12 +#define AUE_PAR3 0x13 +#define AUE_PAR4 0x14 +#define AUE_PAR5 0x15 +#define AUE_PAR AUE_PAR0 +#define AUE_PAUSE0 0x18 +#define AUE_PAUSE1 0x19 +#define AUE_PAUSE AUE_PAUSE0 +#define AUE_RX_FLOWCTL_CNT 0x1A +#define AUE_RX_FLOWCTL_FIFO 0x1B +#define AUE_REG_1D 0x1D +#define AUE_EE_REG 0x20 +#define AUE_EE_DATA0 0x21 +#define AUE_EE_DATA1 0x22 +#define AUE_EE_DATA AUE_EE_DATA0 +#define AUE_EE_CTL 0x23 +#define AUE_PHY_ADDR 0x25 +#define AUE_PHY_DATA0 0x26 +#define AUE_PHY_DATA1 0x27 +#define AUE_PHY_DATA AUE_PHY_DATA0 +#define AUE_PHY_CTL 0x28 +#define AUE_USB_STS 0x2A +#define AUE_TXSTAT0 0x2B +#define AUE_TXSTAT1 0x2C +#define AUE_TXSTAT AUE_TXSTAT0 +#define AUE_RXSTAT 0x2D +#define AUE_PKTLOST0 0x2E +#define AUE_PKTLOST1 0x2F +#define AUE_PKTLOST AUE_PKTLOST0 + +#define AUE_REG_7B 0x7B +#define AUE_GPIO0 0x7E +#define AUE_GPIO1 0x7F +#define AUE_REG_81 0x81 -#define AUE_INTR_PKTLEN 0x8 +#define AUE_CTL0_INCLUDE_RXCRC 0x01 +#define AUE_CTL0_ALLMULTI 0x02 +#define AUE_CTL0_STOP_BACKOFF 0x04 +#define AUE_CTL0_RXSTAT_APPEND 0x08 +#define AUE_CTL0_WAKEON_ENB 0x10 +#define AUE_CTL0_RXPAUSE_ENB 0x20 +#define AUE_CTL0_RX_ENB 0x40 +#define AUE_CTL0_TX_ENB 0x80 -#define AUE_CTL0 0x00 -#define AUE_CTL1 0x01 -#define AUE_CTL2 0x02 -#define AUE_MAR0 0x08 -#define AUE_MAR1 0x09 -#define AUE_MAR2 0x0A -#define AUE_MAR3 0x0B -#define AUE_MAR4 0x0C -#define AUE_MAR5 0x0D -#define AUE_MAR6 0x0E -#define AUE_MAR7 0x0F -#define AUE_MAR AUE_MAR0 -#define AUE_PAR0 0x10 -#define AUE_PAR1 0x11 -#define AUE_PAR2 0x12 -#define AUE_PAR3 0x13 -#define AUE_PAR4 0x14 -#define AUE_PAR5 0x15 -#define AUE_PAR AUE_PAR0 -#define AUE_PAUSE0 0x18 -#define AUE_PAUSE1 0x19 -#define AUE_PAUSE AUE_PAUSE0 -#define AUE_RX_FLOWCTL_CNT 0x1A -#define AUE_RX_FLOWCTL_FIFO 0x1B -#define AUE_REG_1D 0x1D -#define AUE_EE_REG 0x20 -#define AUE_EE_DATA0 0x21 -#define AUE_EE_DATA1 0x22 -#define AUE_EE_DATA AUE_EE_DATA0 -#define AUE_EE_CTL 0x23 -#define AUE_PHY_ADDR 0x25 -#define AUE_PHY_DATA0 0x26 -#define AUE_PHY_DATA1 0x27 -#define AUE_PHY_DATA AUE_PHY_DATA0 -#define AUE_PHY_CTL 0x28 -#define AUE_USB_STS 0x2A -#define AUE_TXSTAT0 0x2B -#define AUE_TXSTAT1 0x2C -#define AUE_TXSTAT AUE_TXSTAT0 -#define AUE_RXSTAT 0x2D -#define AUE_PKTLOST0 0x2E -#define AUE_PKTLOST1 0x2F -#define AUE_PKTLOST AUE_PKTLOST0 +#define AUE_CTL1_HOMELAN 0x04 +#define AUE_CTL1_RESETMAC 0x08 +#define AUE_CTL1_SPEEDSEL 0x10 /* 0 = 10mbps, 1 = 100mbps */ +#define AUE_CTL1_DUPLEX 0x20 /* 0 = half, 1 = full */ +#define AUE_CTL1_DELAYHOME 0x40 -#define AUE_REG_7B 0x7B -#define AUE_GPIO0 0x7E -#define AUE_GPIO1 0x7F -#define AUE_REG_81 0x81 +#define AUE_CTL2_EP3_CLR 0x01 /* reading EP3 clrs status regs */ +#define AUE_CTL2_RX_BADFRAMES 0x02 +#define AUE_CTL2_RX_PROMISC 0x04 +#define AUE_CTL2_LOOPBACK 0x08 +#define AUE_CTL2_EEPROMWR_ENB 0x10 +#define AUE_CTL2_EEPROM_LOAD 0x20 -#define AUE_CTL0_INCLUDE_RXCRC 0x01 -#define AUE_CTL0_ALLMULTI 0x02 -#define AUE_CTL0_STOP_BACKOFF 0x04 -#define AUE_CTL0_RXSTAT_APPEND 0x08 -#define AUE_CTL0_WAKEON_ENB 0x10 -#define AUE_CTL0_RXPAUSE_ENB 0x20 -#define AUE_CTL0_RX_ENB 0x40 -#define AUE_CTL0_TX_ENB 0x80 +#define AUE_EECTL_WRITE 0x01 +#define AUE_EECTL_READ 0x02 +#define AUE_EECTL_DONE 0x04 -#define AUE_CTL1_HOMELAN 0x04 -#define AUE_CTL1_RESETMAC 0x08 -#define AUE_CTL1_SPEEDSEL 0x10 /* 0 = 10mbps, 1 = 100mbps */ -#define AUE_CTL1_DUPLEX 0x20 /* 0 = half, 1 = full */ -#define AUE_CTL1_DELAYHOME 0x40 +#define AUE_PHYCTL_PHYREG 0x1F +#define AUE_PHYCTL_WRITE 0x20 +#define AUE_PHYCTL_READ 0x40 +#define AUE_PHYCTL_DONE 0x80 -#define AUE_CTL2_EP3_CLR 0x01 /* reading EP3 clrs status regs */ -#define AUE_CTL2_RX_BADFRAMES 0x02 -#define AUE_CTL2_RX_PROMISC 0x04 -#define AUE_CTL2_LOOPBACK 0x08 -#define AUE_CTL2_EEPROMWR_ENB 0x10 -#define AUE_CTL2_EEPROM_LOAD 0x20 +#define AUE_USBSTS_SUSPEND 0x01 +#define AUE_USBSTS_RESUME 0x02 -#define AUE_EECTL_WRITE 0x01 -#define AUE_EECTL_READ 0x02 -#define AUE_EECTL_DONE 0x04 +#define AUE_TXSTAT0_JABTIMO 0x04 +#define AUE_TXSTAT0_CARLOSS 0x08 +#define AUE_TXSTAT0_NOCARRIER 0x10 +#define AUE_TXSTAT0_LATECOLL 0x20 +#define AUE_TXSTAT0_EXCESSCOLL 0x40 +#define AUE_TXSTAT0_UNDERRUN 0x80 -#define AUE_PHYCTL_PHYREG 0x1F -#define AUE_PHYCTL_WRITE 0x20 -#define AUE_PHYCTL_READ 0x40 -#define AUE_PHYCTL_DONE 0x80 +#define AUE_TXSTAT1_PKTCNT 0x0F +#define AUE_TXSTAT1_FIFO_EMPTY 0x40 +#define AUE_TXSTAT1_FIFO_FULL 0x80 -#define AUE_USBSTS_SUSPEND 0x01 -#define AUE_USBSTS_RESUME 0x02 +#define AUE_RXSTAT_OVERRUN 0x01 +#define AUE_RXSTAT_PAUSE 0x02 -#define AUE_TXSTAT0_JABTIMO 0x04 -#define AUE_TXSTAT0_CARLOSS 0x08 -#define AUE_TXSTAT0_NOCARRIER 0x10 -#define AUE_TXSTAT0_LATECOLL 0x20 -#define AUE_TXSTAT0_EXCESSCOLL 0x40 -#define AUE_TXSTAT0_UNDERRUN 0x80 +#define AUE_GPIO_IN0 0x01 +#define AUE_GPIO_OUT0 0x02 +#define AUE_GPIO_SEL0 0x04 +#define AUE_GPIO_IN1 0x08 +#define AUE_GPIO_OUT1 0x10 +#define AUE_GPIO_SEL1 0x20 -#define AUE_TXSTAT1_PKTCNT 0x0F -#define AUE_TXSTAT1_FIFO_EMPTY 0x40 -#define AUE_TXSTAT1_FIFO_FULL 0x80 +#define AUE_TIMEOUT 100 /* 10*ms */ +#define AUE_MIN_FRAMELEN 60 -#define AUE_RXSTAT_OVERRUN 0x01 -#define AUE_RXSTAT_PAUSE 0x02 +#define AUE_RXSTAT_MCAST 0x01 +#define AUE_RXSTAT_GIANT 0x02 +#define AUE_RXSTAT_RUNT 0x04 +#define AUE_RXSTAT_CRCERR 0x08 +#define AUE_RXSTAT_DRIBBLE 0x10 +#define AUE_RXSTAT_MASK 0x1E -#define AUE_GPIO_IN0 0x01 -#define AUE_GPIO_OUT0 0x02 -#define AUE_GPIO_SEL0 0x04 -#define AUE_GPIO_IN1 0x08 -#define AUE_GPIO_OUT1 0x10 -#define AUE_GPIO_SEL1 0x20 +#define GET_MII(sc) ((sc)->sc_miibus ? \ + device_get_softc((sc)->sc_miibus) : NULL) struct aue_intrpkt { uint8_t aue_txstat0; @@ -186,15 +196,6 @@ uint8_t aue_rxstat; } __packed; -#define AUE_RXSTAT_MCAST 0x01 -#define AUE_RXSTAT_GIANT 0x02 -#define AUE_RXSTAT_RUNT 0x04 -#define AUE_RXSTAT_CRCERR 0x08 -#define AUE_RXSTAT_DRIBBLE 0x10 -#define AUE_RXSTAT_MASK 0x1E - -#define GET_MII(sc) ((sc)->sc_miibus ? \ - device_get_softc((sc)->sc_miibus) : NULL) struct aue_softc { struct usbd_config_td sc_config_td; @@ -229,9 +230,6 @@ uint8_t sc_name[16]; }; -#define AUE_TIMEOUT 100 /* 10*ms */ -#define AUE_MIN_FRAMELEN 60 - struct aue_config_copy { uint32_t if_flags; uint8_t if_lladdr[ETHER_ADDR_LEN]; ==== //depot/projects/usb/src/sys/dev/usb/if_axereg.h#8 (text+ko) ==== From owner-p4-projects@FreeBSD.ORG Tue Sep 26 14:45:37 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D3F5916A417; Tue, 26 Sep 2006 14:45:36 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 943B916A412 for ; Tue, 26 Sep 2006 14:45:36 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4C48843D45 for ; Tue, 26 Sep 2006 14:45:36 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QEjaec037215 for ; Tue, 26 Sep 2006 14:45:36 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QEjZC9037211 for perforce@freebsd.org; Tue, 26 Sep 2006 14:45:35 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 14:45:35 GMT Message-Id: <200609261445.k8QEjZC9037211@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106723 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 14:45:37 -0000 http://perforce.freebsd.org/chv.cgi?CH=106723 Change 106723 by attilio@attilio_laptop on 2006/09/26 14:45:23 Style-ize them Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_cdcereg.h#7 edit .. //depot/projects/usb/src/sys/dev/usb/if_cuereg.h#5 edit .. //depot/projects/usb/src/sys/dev/usb/if_kuereg.h#5 edit .. //depot/projects/usb/src/sys/dev/usb/if_ruereg.h#5 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_cdcereg.h#7 (text+ko) ==== @@ -39,7 +39,7 @@ struct cdce_type { struct usb_devno cdce_dev; - u_int16_t cdce_flags; + uint16_t cdce_flags; }; struct cdce_softc { ==== //depot/projects/usb/src/sys/dev/usb/if_cuereg.h#5 (text+ko) ==== @@ -36,105 +36,88 @@ * Definitions for the CATC Netmate II USB to ethernet controller. */ - -/* - * Vendor specific control commands. - */ -#define CUE_CMD_RESET 0xF4 -#define CUE_CMD_GET_MACADDR 0xF2 -#define CUE_CMD_WRITEREG 0xFA -#define CUE_CMD_READREG 0xFB -#define CUE_CMD_READSRAM 0xF1 -#define CUE_CMD_WRITESRAM 0xFC - -/* - * Internal registers - */ -#define CUE_TX_BUFCNT 0x20 -#define CUE_RX_BUFCNT 0x21 -#define CUE_ADVANCED_OPMODES 0x22 -#define CUE_TX_BUFPKTS 0x23 -#define CUE_RX_BUFPKTS 0x24 -#define CUE_RX_MAXCHAIN 0x25 - -#define CUE_ETHCTL 0x60 -#define CUE_ETHSTS 0x61 -#define CUE_PAR5 0x62 -#define CUE_PAR4 0x63 -#define CUE_PAR3 0x64 -#define CUE_PAR2 0x65 -#define CUE_PAR1 0x66 -#define CUE_PAR0 0x67 - +/* Vendor specific control commands. */ +#define CUE_CMD_RESET 0xF4 +#define CUE_CMD_GET_MACADDR 0xF2 +#define CUE_CMD_WRITEREG 0xFA +#define CUE_CMD_READREG 0xFB +#define CUE_CMD_READSRAM 0xF1 +#define CUE_CMD_WRITESRAM 0xFC +/* Internal registers. */ +#define CUE_TX_BUFCNT 0x20 +#define CUE_RX_BUFCNT 0x21 +#define CUE_ADVANCED_OPMODES 0x22 +#define CUE_TX_BUFPKTS 0x23 +#define CUE_RX_BUFPKTS 0x24 +#define CUE_RX_MAXCHAIN 0x25 +#define CUE_ETHCTL 0x60 +#define CUE_ETHSTS 0x61 +#define CUE_PAR5 0x62 +#define CUE_PAR4 0x63 +#define CUE_PAR3 0x64 +#define CUE_PAR2 0x65 +#define CUE_PAR1 0x66 +#define CUE_PAR0 0x67 /* Error counters, all 16 bits wide. */ -#define CUE_TX_SINGLECOLL 0x69 -#define CUE_TX_MULTICOLL 0x6B -#define CUE_TX_EXCESSCOLL 0x6D -#define CUE_RX_FRAMEERR 0x6F +#define CUE_TX_SINGLECOLL 0x69 +#define CUE_TX_MULTICOLL 0x6B +#define CUE_TX_EXCESSCOLL 0x6D +#define CUE_RX_FRAMEERR 0x6F +#define CUE_LEDCTL 0x81 +/* Advenced operating mode register. */ +#define CUE_AOP_SRAMWAITS 0x03 +#define CUE_AOP_EMBED_RXLEN 0x08 +#define CUE_AOP_RXCOMBINE 0x10 +#define CUE_AOP_TXCOMBINE 0x20 +#define CUE_AOP_EVEN_PKT_READS 0x40 +#define CUE_AOP_LOOPBK 0x80 +/* Ethernet control register. */ +#define CUE_ETHCTL_RX_ON 0x01 +#define CUE_ETHCTL_LINK_POLARITY 0x02 +#define CUE_ETHCTL_LINK_FORCE_OK 0x04 +#define CUE_ETHCTL_MCAST_ON 0x08 +#define CUE_ETHCTL_PROMISC 0x10 +/* Ethernet status register. */ +#define CUE_ETHSTS_NO_CARRIER 0x01 +#define CUE_ETHSTS_LATECOLL 0x02 +#define CUE_ETHSTS_EXCESSCOLL 0x04 +#define CUE_ETHSTS_TXBUF_AVAIL 0x08 +#define CUE_ETHSTS_BAD_POLARITY 0x10 +#define CUE_ETHSTS_LINK_OK 0x20 +/* LED control register. */ +#define CUE_LEDCTL_BLINK_1X 0x00 +#define CUE_LEDCTL_BLINK_2X 0x01 +#define CUE_LEDCTL_BLINK_QUARTER_ON 0x02 +#define CUE_LEDCTL_BLINK_QUARTER_OFF 0x03 +#define CUE_LEDCTL_OFF 0x04 +#define CUE_LEDCTL_FOLLOW_LINK 0x08 -#define CUE_LEDCTL 0x81 - -/* Advenced operating mode register */ -#define CUE_AOP_SRAMWAITS 0x03 -#define CUE_AOP_EMBED_RXLEN 0x08 -#define CUE_AOP_RXCOMBINE 0x10 -#define CUE_AOP_TXCOMBINE 0x20 -#define CUE_AOP_EVEN_PKT_READS 0x40 -#define CUE_AOP_LOOPBK 0x80 - -/* Ethernet control register */ -#define CUE_ETHCTL_RX_ON 0x01 -#define CUE_ETHCTL_LINK_POLARITY 0x02 -#define CUE_ETHCTL_LINK_FORCE_OK 0x04 -#define CUE_ETHCTL_MCAST_ON 0x08 -#define CUE_ETHCTL_PROMISC 0x10 - -/* Ethernet status register */ -#define CUE_ETHSTS_NO_CARRIER 0x01 -#define CUE_ETHSTS_LATECOLL 0x02 -#define CUE_ETHSTS_EXCESSCOLL 0x04 -#define CUE_ETHSTS_TXBUF_AVAIL 0x08 -#define CUE_ETHSTS_BAD_POLARITY 0x10 -#define CUE_ETHSTS_LINK_OK 0x20 - -/* LED control register */ -#define CUE_LEDCTL_BLINK_1X 0x00 -#define CUE_LEDCTL_BLINK_2X 0x01 -#define CUE_LEDCTL_BLINK_QUARTER_ON 0x02 -#define CUE_LEDCTL_BLINK_QUARTER_OFF 0x03 -#define CUE_LEDCTL_OFF 0x04 -#define CUE_LEDCTL_FOLLOW_LINK 0x08 - /* - * Address in ASIC's internal SRAM where the - * multicast hash table lives. The table is 64 bytes long, - * giving us a 512-bit table. We have to set the bit that - * corresponds to the broadcast address in order to enable + * Address in ASIC's internal SRAM where the multicast hash table lives. + * The table is 64 bytes long, giving us a 512-bit table. We have to set + * the bit that corresponds to the broadcast address in order to enable * reception of broadcast frames. */ -#define CUE_MCAST_TABLE_ADDR 0xFA80 -#define CUE_MCAST_TABLE_LEN 64 +#define CUE_MCAST_TABLE_ADDR 0xFA80 +#define CUE_MCAST_TABLE_LEN 64 -#define CUE_TIMEOUT 1000 -#define CUE_MIN_FRAMELEN 60 -#define CUE_RX_FRAMES 1 -#define CUE_TX_FRAMES 1 +#define CUE_TIMEOUT 1000 +#define CUE_MIN_FRAMELEN 60 +#define CUE_RX_FRAMES 1 +#define CUE_TX_FRAMES 1 -#define CUE_CTL_READ 0x01 -#define CUE_CTL_WRITE 0x02 +#define CUE_CTL_READ 0x01 +#define CUE_CTL_WRITE 0x02 -#define CUE_CONFIG_NO 1 -#define CUE_IFACE_IDX 0 +#define CUE_CONFIG_NO 1 +#define CUE_IFACE_IDX 0 -/* - * The interrupt endpoint is currently unused - * by the KLSI part. - */ -#define CUE_ENDPT_MAX 4 +/* The interrupt endpoint is currently unused by the KLSI part. */ +#define CUE_ENDPT_MAX 4 struct cue_type { - u_int16_t cue_vid; - u_int16_t cue_did; + uint16_t cue_vid; + uint16_t cue_did; }; struct cue_softc { @@ -143,23 +126,23 @@ struct __callout sc_watchdog; struct mtx sc_mtx; - struct ifnet * sc_ifp; + struct ifnet *sc_ifp; device_t sc_dev; - struct usbd_device * sc_udev; - struct usbd_xfer * sc_xfer[CUE_ENDPT_MAX]; + struct usbd_device *sc_udev; + struct usbd_xfer *sc_xfer[CUE_ENDPT_MAX]; - u_int32_t sc_unit; + uint32_t sc_unit; - u_int16_t sc_flags; -#define CUE_FLAG_READ_STALL 0x0010 /* wait for clearing of stall */ -#define CUE_FLAG_WRITE_STALL 0x0020 /* wait for clearing of stall */ -#define CUE_FLAG_LL_READY 0x0040 /* Lower Layer Ready */ -#define CUE_FLAG_HL_READY 0x0080 /* Higher Layer Ready */ -#define CUE_FLAG_INTR_STALL 0x0100 /* wait for clearing of stall */ + uint16_t sc_flags; +#define CUE_FLAG_READ_STALL 0x0010 /* wait for clearing of stall */ +#define CUE_FLAG_WRITE_STALL 0x0020 /* wait for clearing of stall */ +#define CUE_FLAG_LL_READY 0x0040 /* Lower Layer Ready */ +#define CUE_FLAG_HL_READY 0x0080 /* Higher Layer Ready */ +#define CUE_FLAG_INTR_STALL 0x0100 /* wait for clearing of stall */ }; struct cue_config_copy { - u_int32_t if_flags; - u_int8_t if_lladdr[ETHER_ADDR_LEN]; - u_int8_t if_hash[CUE_MCAST_TABLE_LEN]; + uint32_t if_flags; + uint8_t if_lladdr[ETHER_ADDR_LEN]; + uint8_t if_hash[CUE_MCAST_TABLE_LEN]; }; ==== //depot/projects/usb/src/sys/dev/usb/if_kuereg.h#5 (text+ko) ==== @@ -36,102 +36,93 @@ * Definitions for the KLSI KL5KUSB101B USB to ethernet controller. * The KLSI part is controlled via vendor control requests, the structure * of which depend a bit on the firmware running on the internal - * microcontroller. The one exception is the 'send scan data' command, + * microcontroller. The one exception is the 'send scan data' command, * which is used to load the firmware. */ -#define KUE_CMD_GET_ETHER_DESCRIPTOR 0x00 -#define KUE_CMD_SET_MCAST_FILTERS 0x01 -#define KUE_CMD_SET_PKT_FILTER 0x02 -#define KUE_CMD_GET_ETHERSTATS 0x03 -#define KUE_CMD_GET_GPIO 0x04 -#define KUE_CMD_SET_GPIO 0x05 -#define KUE_CMD_SET_MAC 0x06 -#define KUE_CMD_GET_MAC 0x07 -#define KUE_CMD_SET_URB_SIZE 0x08 -#define KUE_CMD_SET_SOFS 0x09 -#define KUE_CMD_SET_EVEN_PKTS 0x0A -#define KUE_CMD_SEND_SCAN 0xFF +#define KUE_CMD_GET_ETHER_DESCRIPTOR 0x00 +#define KUE_CMD_SET_MCAST_FILTERS 0x01 +#define KUE_CMD_SET_PKT_FILTER 0x02 +#define KUE_CMD_GET_ETHERSTATS 0x03 +#define KUE_CMD_GET_GPIO 0x04 +#define KUE_CMD_SET_GPIO 0x05 +#define KUE_CMD_SET_MAC 0x06 +#define KUE_CMD_GET_MAC 0x07 +#define KUE_CMD_SET_URB_SIZE 0x08 +#define KUE_CMD_SET_SOFS 0x09 +#define KUE_CMD_SET_EVEN_PKTS 0x0A +#define KUE_CMD_SEND_SCAN 0xFF struct kue_ether_desc { - u_int8_t kue_len; - u_int8_t kue_rsvd0; - u_int8_t kue_rsvd1; - u_int8_t kue_macaddr[ETHER_ADDR_LEN]; - u_int8_t kue_etherstats[4]; - u_int8_t kue_maxseg[2]; - u_int8_t kue_mcastfilt[2]; - u_int8_t kue_rsvd2; -} UPACKED; + uint8_t kue_len; + uint8_t kue_rsvd0; + uint8_t kue_rsvd1; + uint8_t kue_macaddr[ETHER_ADDR_LEN]; + uint8_t kue_etherstats[4]; + uint8_t kue_maxseg[2]; + uint8_t kue_mcastfilt[2]; + uint8_t kue_rsvd2; +} __packed; -#define KUE_ETHERSTATS(x) \ - UGETDW((x)->sc_desc.kue_etherstats) +#define KUE_ETHERSTATS(x) UGETDW((x)->sc_desc.kue_etherstats) +#define KUE_MAXSEG(x) UGETW((x)->sc_desc.kue_maxseg) +#define KUE_MCFILTCNT(x) (UGETW((x)->sc_desc.kue_mcastfilt) & 0x7FFF) +#define KUE_MCFILT(x, y) \ + ((x)->sc_mcfilters + ((y) * ETHER_ADDR_LEN)) -#define KUE_MAXSEG(x) \ - UGETW((x)->sc_desc.kue_maxseg) +#define KUE_MCFILT_MAX 64 -#define KUE_MCFILTCNT(x) \ - (UGETW((x)->sc_desc.kue_mcastfilt) & 0x7FFF) +#define KUE_STAT_TX_OK 0x00000001 +#define KUE_STAT_RX_OK 0x00000002 +#define KUE_STAT_TX_ERR 0x00000004 +#define KUE_STAT_RX_ERR 0x00000008 +#define KUE_STAT_RX_NOBUF 0x00000010 +#define KUE_STAT_TX_UCAST_BYTES 0x00000020 +#define KUE_STAT_TX_UCAST_FRAMES 0x00000040 +#define KUE_STAT_TX_MCAST_BYTES 0x00000080 +#define KUE_STAT_TX_MCAST_FRAMES 0x00000100 +#define KUE_STAT_TX_BCAST_BYTES 0x00000200 +#define KUE_STAT_TX_BCAST_FRAMES 0x00000400 +#define KUE_STAT_RX_UCAST_BYTES 0x00000800 +#define KUE_STAT_RX_UCAST_FRAMES 0x00001000 +#define KUE_STAT_RX_MCAST_BYTES 0x00002000 +#define KUE_STAT_RX_MCAST_FRAMES 0x00004000 +#define KUE_STAT_RX_BCAST_BYTES 0x00008000 +#define KUE_STAT_RX_BCAST_FRAMES 0x00010000 +#define KUE_STAT_RX_CRCERR 0x00020000 +#define KUE_STAT_TX_QUEUE_LENGTH 0x00040000 +#define KUE_STAT_RX_ALIGNERR 0x00080000 +#define KUE_STAT_TX_SINGLECOLL 0x00100000 +#define KUE_STAT_TX_MULTICOLL 0x00200000 +#define KUE_STAT_TX_DEFERRED 0x00400000 +#define KUE_STAT_TX_MAXCOLLS 0x00800000 +#define KUE_STAT_RX_OVERRUN 0x01000000 +#define KUE_STAT_TX_UNDERRUN 0x02000000 +#define KUE_STAT_TX_SQE_ERR 0x04000000 +#define KUE_STAT_TX_CARRLOSS 0x08000000 +#define KUE_STAT_RX_LATECOLL 0x10000000 -#define KUE_MCFILT(x, y) \ - ((x)->sc_mcfilters + ((y) * ETHER_ADDR_LEN)) +#define KUE_RXFILT_PROMISC 0x0001 +#define KUE_RXFILT_ALLMULTI 0x0002 +#define KUE_RXFILT_UNICAST 0x0004 +#define KUE_RXFILT_BROADCAST 0x0008 +#define KUE_RXFILT_MULTICAST 0x0010 -#define KUE_MCFILT_MAX 64 +#define KUE_TIMEOUT 1000 +#define KUE_MIN_FRAMELEN 60 -#define KUE_STAT_TX_OK 0x00000001 -#define KUE_STAT_RX_OK 0x00000002 -#define KUE_STAT_TX_ERR 0x00000004 -#define KUE_STAT_RX_ERR 0x00000008 -#define KUE_STAT_RX_NOBUF 0x00000010 -#define KUE_STAT_TX_UCAST_BYTES 0x00000020 -#define KUE_STAT_TX_UCAST_FRAMES 0x00000040 -#define KUE_STAT_TX_MCAST_BYTES 0x00000080 -#define KUE_STAT_TX_MCAST_FRAMES 0x00000100 -#define KUE_STAT_TX_BCAST_BYTES 0x00000200 -#define KUE_STAT_TX_BCAST_FRAMES 0x00000400 -#define KUE_STAT_RX_UCAST_BYTES 0x00000800 -#define KUE_STAT_RX_UCAST_FRAMES 0x00001000 -#define KUE_STAT_RX_MCAST_BYTES 0x00002000 -#define KUE_STAT_RX_MCAST_FRAMES 0x00004000 -#define KUE_STAT_RX_BCAST_BYTES 0x00008000 -#define KUE_STAT_RX_BCAST_FRAMES 0x00010000 -#define KUE_STAT_RX_CRCERR 0x00020000 -#define KUE_STAT_TX_QUEUE_LENGTH 0x00040000 -#define KUE_STAT_RX_ALIGNERR 0x00080000 -#define KUE_STAT_TX_SINGLECOLL 0x00100000 -#define KUE_STAT_TX_MULTICOLL 0x00200000 -#define KUE_STAT_TX_DEFERRED 0x00400000 -#define KUE_STAT_TX_MAXCOLLS 0x00800000 -#define KUE_STAT_RX_OVERRUN 0x01000000 -#define KUE_STAT_TX_UNDERRUN 0x02000000 -#define KUE_STAT_TX_SQE_ERR 0x04000000 -#define KUE_STAT_TX_CARRLOSS 0x08000000 -#define KUE_STAT_RX_LATECOLL 0x10000000 +#define KUE_CTL_READ 0x01 +#define KUE_CTL_WRITE 0x02 -#define KUE_RXFILT_PROMISC 0x0001 -#define KUE_RXFILT_ALLMULTI 0x0002 -#define KUE_RXFILT_UNICAST 0x0004 -#define KUE_RXFILT_BROADCAST 0x0008 -#define KUE_RXFILT_MULTICAST 0x0010 +#define KUE_CONFIG_NO 1 +#define KUE_IFACE_IDX 0 -#define KUE_TIMEOUT 1000 -#define KUE_MIN_FRAMELEN 60 - -#define KUE_CTL_READ 0x01 -#define KUE_CTL_WRITE 0x02 - -#define KUE_CONFIG_NO 1 -#define KUE_IFACE_IDX 0 - -/* - * The interrupt endpoint is currently unused - * by the KLSI part. - */ -#define KUE_ENDPT_MAX 4 +/* The interrupt endpoint is currently unused by the KLSI part. */ +#define KUE_ENDPT_MAX 4 struct kue_type { - u_int16_t kue_vid; - u_int16_t kue_did; + uint16_t kue_vid; + uint16_t kue_did; }; struct kue_softc { @@ -142,26 +133,26 @@ struct mtx sc_mtx; struct kue_ether_desc sc_desc; - struct ifnet * sc_ifp; + struct ifnet *sc_ifp; device_t sc_dev; - struct usbd_device * sc_udev; - struct usbd_xfer * sc_xfer[KUE_ENDPT_MAX]; + struct usbd_device *sc_udev; + struct usbd_xfer *sc_xfer[KUE_ENDPT_MAX]; - u_int32_t sc_unit; + uint32_t sc_unit; - u_int16_t sc_mcfilt_max; - u_int16_t sc_flags; -#define KUE_FLAG_READ_STALL 0x0010 /* wait for clearing of stall */ -#define KUE_FLAG_WRITE_STALL 0x0020 /* wait for clearing of stall */ -#define KUE_FLAG_LL_READY 0x0040 /* Lower Layer Ready */ -#define KUE_FLAG_HL_READY 0x0080 /* Higher Layer Ready */ -#define KUE_FLAG_INTR_STALL 0x0100 /* wait for clearing of stall */ + uint16_t sc_mcfilt_max; + uint16_t sc_flags; +#define KUE_FLAG_READ_STALL 0x0010 /* wait for clearing of stall */ +#define KUE_FLAG_WRITE_STALL 0x0020 /* wait for clearing of stall */ +#define KUE_FLAG_LL_READY 0x0040 /* Lower Layer Ready */ +#define KUE_FLAG_HL_READY 0x0080 /* Higher Layer Ready */ +#define KUE_FLAG_INTR_STALL 0x0100 /* wait for clearing of stall */ }; struct kue_config_copy { - u_int32_t if_flags; - u_int16_t if_rxfilt; - u_int16_t if_nhash; - u_int8_t if_lladdr[ETHER_ADDR_LEN]; - u_int8_t if_hash[KUE_MCFILT_MAX * ETHER_ADDR_LEN]; + uint32_t if_flags; + uint16_t if_rxfilt; + uint16_t if_nhash; + uint8_t if_lladdr[ETHER_ADDR_LEN]; + uint8_t if_hash[KUE_MCFILT_MAX * ETHER_ADDR_LEN]; }; ==== //depot/projects/usb/src/sys/dev/usb/if_ruereg.h#5 (text+ko) ==== @@ -26,152 +26,148 @@ * $FreeBSD: src/sys/dev/usb/if_ruereg.h,v 1.6 2005/06/10 16:49:15 brooks Exp $ */ -#define RUE_CONFIG_NO 1 -#define RUE_IFACE_IDX 0 +#ifndef _IF_RUEREG_H_ +#define _IF_RUEREG_H_ -#define RUE_ENDPT_MAX 6 +#define RUE_CONFIG_NO 1 +#define RUE_IFACE_IDX 0 -#define RUE_INTR_PKTLEN 0x8 +#define RUE_ENDPT_MAX 6 -#define RUE_TIMEOUT 50 -#define RUE_MIN_FRAMELEN 60 +#define RUE_INTR_PKTLEN 0x8 -/* - * Registers - */ +#define RUE_TIMEOUT 50 +#define RUE_MIN_FRAMELEN 60 -#define RUE_IDR0 0x0120 -#define RUE_IDR1 0x0121 -#define RUE_IDR2 0x0122 -#define RUE_IDR3 0x0123 -#define RUE_IDR4 0x0124 -#define RUE_IDR5 0x0125 +/* Registers. */ +#define RUE_IDR0 0x0120 +#define RUE_IDR1 0x0121 +#define RUE_IDR2 0x0122 +#define RUE_IDR3 0x0123 +#define RUE_IDR4 0x0124 +#define RUE_IDR5 0x0125 -#define RUE_MAR0 0x0126 -#define RUE_MAR1 0x0127 -#define RUE_MAR2 0x0128 -#define RUE_MAR3 0x0129 -#define RUE_MAR4 0x012A -#define RUE_MAR5 0x012B -#define RUE_MAR6 0x012C -#define RUE_MAR7 0x012D +#define RUE_MAR0 0x0126 +#define RUE_MAR1 0x0127 +#define RUE_MAR2 0x0128 +#define RUE_MAR3 0x0129 +#define RUE_MAR4 0x012A +#define RUE_MAR5 0x012B +#define RUE_MAR6 0x012C +#define RUE_MAR7 0x012D -#define RUE_CR 0x012E /* B, R/W */ -#define RUE_CR_SOFT_RST 0x10 -#define RUE_CR_RE 0x08 -#define RUE_CR_TE 0x04 -#define RUE_CR_EP3CLREN 0x02 +#define RUE_CR 0x012E /* B, R/W */ +#define RUE_CR_SOFT_RST 0x10 +#define RUE_CR_RE 0x08 +#define RUE_CR_TE 0x04 +#define RUE_CR_EP3CLREN 0x02 -#define RUE_TCR 0x012F /* B, R/W */ -#define RUE_TCR_TXRR1 0x80 -#define RUE_TCR_TXRR0 0x40 -#define RUE_TCR_IFG1 0x10 -#define RUE_TCR_IFG0 0x08 -#define RUE_TCR_NOCRC 0x01 -#define RUE_TCR_CONFIG (RUE_TCR_TXRR1|RUE_TCR_TXRR0|RUE_TCR_IFG1|RUE_TCR_IFG0) +#define RUE_TCR 0x012F /* B, R/W */ +#define RUE_TCR_TXRR1 0x80 +#define RUE_TCR_TXRR0 0x40 +#define RUE_TCR_IFG1 0x10 +#define RUE_TCR_IFG0 0x08 +#define RUE_TCR_NOCRC 0x01 +#define RUE_TCR_CONFIG (RUE_TCR_TXRR1 | RUE_TCR_TXRR0 | \ + RUE_TCR_IFG1 | RUE_TCR_IFG0) -#define RUE_RCR 0x0130 /* W, R/W */ -#define RUE_RCR_TAIL 0x80 -#define RUE_RCR_AER 0x40 -#define RUE_RCR_AR 0x20 -#define RUE_RCR_AM 0x10 -#define RUE_RCR_AB 0x08 -#define RUE_RCR_AD 0x04 -#define RUE_RCR_AAM 0x02 -#define RUE_RCR_AAP 0x01 -#define RUE_RCR_CONFIG (RUE_RCR_TAIL|RUE_RCR_AD) +#define RUE_RCR 0x0130 /* W, R/W */ +#define RUE_RCR_TAIL 0x80 +#define RUE_RCR_AER 0x40 +#define RUE_RCR_AR 0x20 +#define RUE_RCR_AM 0x10 +#define RUE_RCR_AB 0x08 +#define RUE_RCR_AD 0x04 +#define RUE_RCR_AAM 0x02 +#define RUE_RCR_AAP 0x01 +#define RUE_RCR_CONFIG (RUE_RCR_TAIL | RUE_RCR_AD) -#define RUE_TSR 0x0132 -#define RUE_RSR 0x0133 -#define RUE_CON0 0x0135 -#define RUE_CON1 0x0136 -#define RUE_MSR 0x0137 -#define RUE_PHYADD 0x0138 -#define RUE_PHYDAT 0x0139 +#define RUE_TSR 0x0132 +#define RUE_RSR 0x0133 +#define RUE_CON0 0x0135 +#define RUE_CON1 0x0136 +#define RUE_MSR 0x0137 +#define RUE_PHYADD 0x0138 +#define RUE_PHYDAT 0x0139 -#define RUE_PHYCNT 0x013B /* B, R/W */ -#define RUE_PHYCNT_PHYOWN 0x40 -#define RUE_PHYCNT_RWCR 0x20 +#define RUE_PHYCNT 0x013B /* B, R/W */ +#define RUE_PHYCNT_PHYOWN 0x40 +#define RUE_PHYCNT_RWCR 0x20 -#define RUE_GPPC 0x013D -#define RUE_WAKECNT 0x013E +#define RUE_GPPC 0x013D +#define RUE_WAKECNT 0x013E -#define RUE_BMCR 0x0140 -#define RUE_BMCR_SPD_SET 0x2000 -#define RUE_BMCR_DUPLEX 0x0100 +#define RUE_BMCR 0x0140 +#define RUE_BMCR_SPD_SET 0x2000 +#define RUE_BMCR_DUPLEX 0x0100 -#define RUE_BMSR 0x0142 +#define RUE_BMSR 0x0142 -#define RUE_ANAR 0x0144 /* W, R/W */ -#define RUE_ANAR_PAUSE 0x0400 +#define RUE_ANAR 0x0144 /* W, R/W */ +#define RUE_ANAR_PAUSE 0x0400 -#define RUE_ANLP 0x0146 /* W, R/O */ -#define RUE_ANLP_PAUSE 0x0400 +#define RUE_ANLP 0x0146 /* W, R/O */ +#define RUE_ANLP_PAUSE 0x0400 -#define RUE_AER 0x0148 +#define RUE_AER 0x0148 -#define RUE_NWAYT 0x014A -#define RUE_CSCR 0x014C +#define RUE_NWAYT 0x014A +#define RUE_CSCR 0x014C -#define RUE_CRC0 0x014E -#define RUE_CRC1 0x0150 -#define RUE_CRC2 0x0152 -#define RUE_CRC3 0x0154 -#define RUE_CRC4 0x0156 +#define RUE_CRC0 0x014E +#define RUE_CRC1 0x0150 +#define RUE_CRC2 0x0152 +#define RUE_CRC3 0x0154 +#define RUE_CRC4 0x0156 -#define RUE_BYTEMASK0 0x0158 -#define RUE_BYTEMASK1 0x0160 -#define RUE_BYTEMASK2 0x0168 -#define RUE_BYTEMASK3 0x0170 -#define RUE_BYTEMASK4 0x0178 +#define RUE_BYTEMASK0 0x0158 +#define RUE_BYTEMASK1 0x0160 +#define RUE_BYTEMASK2 0x0168 +#define RUE_BYTEMASK3 0x0170 +#define RUE_BYTEMASK4 0x0178 -#define RUE_PHY1 0x0180 -#define RUE_PHY2 0x0184 +#define RUE_PHY1 0x0180 +#define RUE_PHY2 0x0184 -#define RUE_TW1 0x0186 +#define RUE_TW1 0x0186 -#define RUE_REG_MIN 0x0120 -#define RUE_REG_MAX 0x0189 +#define RUE_REG_MIN 0x0120 +#define RUE_REG_MAX 0x0189 -/* - * EEPROM address declarations - */ +/* EEPROM address declarations. */ +#define RUE_EEPROM_BASE 0x1200 +#define RUE_EEPROM_IDR0 (RUE_EEPROM_BASE + 0x02) +#define RUE_EEPROM_IDR1 (RUE_EEPROM_BASE + 0x03) +#define RUE_EEPROM_IDR2 (RUE_EEPROM_BASE + 0x03) +#define RUE_EEPROM_IDR3 (RUE_EEPROM_BASE + 0x03) +#define RUE_EEPROM_IDR4 (RUE_EEPROM_BASE + 0x03) +#define RUE_EEPROM_IDR5 (RUE_EEPROM_BASE + 0x03) +#define RUE_EEPROM_INTERVAL (RUE_EEPROM_BASE + 0x17) -#define RUE_EEPROM_BASE 0x1200 +#define RUE_RXSTAT_VALID (0x01 << 12) +#define RUE_RXSTAT_RUNT (0x02 << 12) +#define RUE_RXSTAT_PMATCH (0x04 << 12) +#define RUE_RXSTAT_MCAST (0x08 << 12) -#define RUE_EEPROM_IDR0 (RUE_EEPROM_BASE + 0x02) -#define RUE_EEPROM_IDR1 (RUE_EEPROM_BASE + 0x03) -#define RUE_EEPROM_IDR2 (RUE_EEPROM_BASE + 0x03) -#define RUE_EEPROM_IDR3 (RUE_EEPROM_BASE + 0x03) -#define RUE_EEPROM_IDR4 (RUE_EEPROM_BASE + 0x03) -#define RUE_EEPROM_IDR5 (RUE_EEPROM_BASE + 0x03) - -#define RUE_EEPROM_INTERVAL (RUE_EEPROM_BASE + 0x17) +#define GET_MII(sc) ((sc)->sc_miibus ? \ + device_get_softc((sc)->sc_miibus) : NULL) struct rue_intrpkt { - u_int8_t rue_tsr; - u_int8_t rue_rsr; - u_int8_t rue_gep_msr; - u_int8_t rue_waksr; - u_int8_t rue_txok_cnt; - u_int8_t rue_rxlost_cnt; - u_int8_t rue_crcerr_cnt; - u_int8_t rue_col_cnt; -} UPACKED; + uint8_t rue_tsr; + uint8_t rue_rsr; + uint8_t rue_gep_msr; + uint8_t rue_waksr; + uint8_t rue_txok_cnt; + uint8_t rue_rxlost_cnt; + uint8_t rue_crcerr_cnt; + uint8_t rue_col_cnt; +} __packed; -#define RUE_RXSTAT_VALID (0x01 << 12) -#define RUE_RXSTAT_RUNT (0x02 << 12) -#define RUE_RXSTAT_PMATCH (0x04 << 12) -#define RUE_RXSTAT_MCAST (0x08 << 12) - struct rue_type { - u_int16_t rue_vid; - u_int16_t rue_did; + uint16_t rue_vid; + uint16_t rue_did; }; -#define GET_MII(sc) ((sc)->sc_miibus ? \ - device_get_softc((sc)->sc_miibus) : NULL) - struct rue_softc { struct usbd_config_td sc_config_td; @@ -179,29 +175,31 @@ struct __callout sc_watchdog; struct mtx sc_mtx; - struct ifnet * sc_ifp; - struct usbd_device * sc_udev; - struct usbd_xfer * sc_xfer[RUE_ENDPT_MAX]; + struct ifnet *sc_ifp; + struct usbd_device *sc_udev; + struct usbd_xfer *sc_xfer[RUE_ENDPT_MAX]; device_t sc_miibus; device_t sc_dev; - u_int32_t sc_unit; - u_int32_t sc_media_active; - u_int32_t sc_media_status; + uint32_t sc_unit; + uint32_t sc_media_active; + uint32_t sc_media_status; - u_int16_t sc_flags; -#define RUE_FLAG_WAIT_LINK 0x0001 -#define RUE_FLAG_INTR_STALL 0x0002 -#define RUE_FLAG_READ_STALL 0x0004 -#define RUE_FLAG_WRITE_STALL 0x0008 -#define RUE_FLAG_LL_READY 0x0010 -#define RUE_FLAG_HL_READY 0x0020 + uint16_t sc_flags; +#define RUE_FLAG_WAIT_LINK 0x0001 +#define RUE_FLAG_INTR_STALL 0x0002 +#define RUE_FLAG_READ_STALL 0x0004 +#define RUE_FLAG_WRITE_STALL 0x0008 +#define RUE_FLAG_LL_READY 0x0010 +#define RUE_FLAG_HL_READY 0x0020 - u_int8_t sc_name[16]; + uint8_t sc_name[16]; }; struct rue_config_copy { - u_int32_t if_flags; - u_int32_t if_hashes[2]; - u_int8_t if_lladdr[ETHER_ADDR_LEN]; + uint32_t if_flags; + uint32_t if_hashes[2]; + uint8_t if_lladdr[ETHER_ADDR_LEN]; }; + +#endif /* _IF_RUEREG_H_ */ From owner-p4-projects@FreeBSD.ORG Tue Sep 26 14:48:41 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6DAAD16A47B; Tue, 26 Sep 2006 14:48:41 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 3AEE016A40F for ; Tue, 26 Sep 2006 14:48:41 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C56F143D46 for ; Tue, 26 Sep 2006 14:48:40 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QEme7s037432 for ; Tue, 26 Sep 2006 14:48:40 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QEmebu037427 for perforce@freebsd.org; Tue, 26 Sep 2006 14:48:40 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 14:48:40 GMT Message-Id: <200609261448.k8QEmebu037427@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106724 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 14:48:41 -0000 http://perforce.freebsd.org/chv.cgi?CH=106724 Change 106724 by attilio@attilio_laptop on 2006/09/26 14:48:29 Remove erroneus change Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_ruereg.h#6 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_ruereg.h#6 (text+ko) ==== @@ -26,9 +26,6 @@ * $FreeBSD: src/sys/dev/usb/if_ruereg.h,v 1.6 2005/06/10 16:49:15 brooks Exp $ */ -#ifndef _IF_RUEREG_H_ -#define _IF_RUEREG_H_ - #define RUE_CONFIG_NO 1 #define RUE_IFACE_IDX 0 @@ -201,5 +198,3 @@ uint32_t if_hashes[2]; uint8_t if_lladdr[ETHER_ADDR_LEN]; }; - -#endif /* _IF_RUEREG_H_ */ From owner-p4-projects@FreeBSD.ORG Tue Sep 26 15:31:03 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1B8B316A59F; Tue, 26 Sep 2006 15:31:03 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 E7B1A16A58C for ; Tue, 26 Sep 2006 15:31:02 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7BEBE43D5C for ; Tue, 26 Sep 2006 15:30:33 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QFUXZ9040684 for ; Tue, 26 Sep 2006 15:30:33 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QFUX0M040681 for perforce@freebsd.org; Tue, 26 Sep 2006 15:30:33 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 15:30:33 GMT Message-Id: <200609261530.k8QFUX0M040681@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106725 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 15:31:03 -0000 http://perforce.freebsd.org/chv.cgi?CH=106725 Change 106725 by attilio@attilio_laptop on 2006/09/26 15:30:18 Style-ize them Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_udavreg.h#6 edit .. //depot/projects/usb/src/sys/dev/usb/if_uralreg.h#6 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_udavreg.h#6 (text+ko) ==== @@ -34,7 +34,7 @@ #define UDAV_IFACE_INDEX 0 #define UDAV_CONFIG_NO 1 -#define UDAV_ENDPT_MAX 6 /* units */ +#define UDAV_ENDPT_MAX 6 /* units */ /* Packet length */ #define UDAV_MIN_FRAME_LEN 60 @@ -50,49 +50,49 @@ /* Registers */ #define UDAV_NCR 0x00 /* Network Control Register */ -#define UDAV_NCR_EXT_PHY (1<<7) /* Select External PHY */ -#define UDAV_NCR_WAKEEN (1<<6) /* Wakeup Event Enable */ -#define UDAV_NCR_FCOL (1<<4) /* Force Collision Mode */ -#define UDAV_NCR_FDX (1<<3) /* Full-Duplex Mode (RO on Int. PHY) */ -#define UDAV_NCR_LBK1 (1<<2) /* Lookback Mode */ -#define UDAV_NCR_LBK0 (1<<1) /* Lookback Mode */ -#define UDAV_NCR_RST (1<<0) /* Software reset */ +#define UDAV_NCR_EXT_PHY (1<<7) /* Select External PHY */ +#define UDAV_NCR_WAKEEN (1<<6) /* Wakeup Event Enable */ +#define UDAV_NCR_FCOL (1<<4) /* Force Collision Mode */ +#define UDAV_NCR_FDX (1<<3) /* Full-Duplex Mode (RO on Int. PHY) */ +#define UDAV_NCR_LBK1 (1<<2) /* Lookback Mode */ +#define UDAV_NCR_LBK0 (1<<1) /* Lookback Mode */ +#define UDAV_NCR_RST (1<<0) /* Software reset */ #define UDAV_RCR 0x05 /* RX Control Register */ -#define UDAV_RCR_WTDIS (1<<6) /* Watchdog Timer Disable */ -#define UDAV_RCR_DIS_LONG (1<<5) /* Discard Long Packet(over 1522Byte) */ -#define UDAV_RCR_DIS_CRC (1<<4) /* Discard CRC Error Packet */ -#define UDAV_RCR_ALL (1<<3) /* Pass All Multicast */ -#define UDAV_RCR_RUNT (1<<2) /* Pass Runt Packet */ -#define UDAV_RCR_PRMSC (1<<1) /* Promiscuous Mode */ -#define UDAV_RCR_RXEN (1<<0) /* RX Enable */ +#define UDAV_RCR_WTDIS (1<<6) /* Watchdog Timer Disable */ +#define UDAV_RCR_DIS_LONG (1<<5) /* Discard Long Packet(over 1522Byte) */ +#define UDAV_RCR_DIS_CRC (1<<4) /* Discard CRC Error Packet */ +#define UDAV_RCR_ALL (1<<3) /* Pass All Multicast */ +#define UDAV_RCR_RUNT (1<<2) /* Pass Runt Packet */ +#define UDAV_RCR_PRMSC (1<<1) /* Promiscuous Mode */ +#define UDAV_RCR_RXEN (1<<0) /* RX Enable */ #define UDAV_RSR 0x06 /* RX Status Register */ -#define UDAV_RSR_RF (1<<7) /* Runt Frame */ -#define UDAV_RSR_MF (1<<6) /* Multicast Frame */ -#define UDAV_RSR_LCS (1<<5) /* Late Collision Seen */ -#define UDAV_RSR_RWTO (1<<4) /* Receive Watchdog Time-Out */ -#define UDAV_RSR_PLE (1<<3) /* Physical Layer Error */ -#define UDAV_RSR_AE (1<<2) /* Alignment Error */ -#define UDAV_RSR_CE (1<<1) /* CRC Error */ -#define UDAV_RSR_FOE (1<<0) /* FIFO Overflow Error */ -#define UDAV_RSR_ERR (UDAV_RSR_RF | UDAV_RSR_LCS | UDAV_RSR_RWTO |\ - UDAV_RSR_PLE | UDAV_RSR_AE | UDAV_RSR_CE |\ - UDAV_RSR_FOE) +#define UDAV_RSR_RF (1<<7) /* Runt Frame */ +#define UDAV_RSR_MF (1<<6) /* Multicast Frame */ +#define UDAV_RSR_LCS (1<<5) /* Late Collision Seen */ +#define UDAV_RSR_RWTO (1<<4) /* Receive Watchdog Time-Out */ +#define UDAV_RSR_PLE (1<<3) /* Physical Layer Error */ +#define UDAV_RSR_AE (1<<2) /* Alignment Error */ +#define UDAV_RSR_CE (1<<1) /* CRC Error */ +#define UDAV_RSR_FOE (1<<0) /* FIFO Overflow Error */ +#define UDAV_RSR_ERR (UDAV_RSR_RF | UDAV_RSR_LCS | \ + UDAV_RSR_RWTO | UDAV_RSR_PLE | \ + UDAV_RSR_AE | UDAV_RSR_CE | UDAV_RSR_FOE) #define UDAV_EPCR 0x0b /* EEPROM & PHY Control Register */ -#define UDAV_EPCR_REEP (1<<5) /* Reload EEPROM */ -#define UDAV_EPCR_WEP (1<<4) /* Write EEPROM enable */ -#define UDAV_EPCR_EPOS (1<<3) /* EEPROM or PHY Operation Select */ -#define UDAV_EPCR_ERPRR (1<<2) /* EEPROM/PHY Register Read Command */ -#define UDAV_EPCR_ERPRW (1<<1) /* EEPROM/PHY Register Write Command */ -#define UDAV_EPCR_ERRE (1<<0) /* EEPROM/PHY Access Status */ +#define UDAV_EPCR_REEP (1<<5) /* Reload EEPROM */ +#define UDAV_EPCR_WEP (1<<4) /* Write EEPROM enable */ +#define UDAV_EPCR_EPOS (1<<3) /* EEPROM or PHY Operation Select */ +#define UDAV_EPCR_ERPRR (1<<2) /* EEPROM/PHY Register Read Command */ +#define UDAV_EPCR_ERPRW (1<<1) /* EEPROM/PHY Register Write Command */ +#define UDAV_EPCR_ERRE (1<<0) /* EEPROM/PHY Access Status */ #define UDAV_EPAR 0x0c /* EEPROM & PHY Control Register */ -#define UDAV_EPAR_PHY_ADR1 (1<<7) /* PHY Address bit 1 */ -#define UDAV_EPAR_PHY_ADR0 (1<<6) /* PHY Address bit 0 */ -#define UDAV_EPAR_EROA (1<<0) /* EEPROM Word/PHY Register Address */ -#define UDAV_EPAR_EROA_MASK (0x1f) /* [5:0] */ +#define UDAV_EPAR_PHY_ADR1 (1<<7) /* PHY Address bit 1 */ +#define UDAV_EPAR_PHY_ADR0 (1<<6) /* PHY Address bit 0 */ +#define UDAV_EPAR_EROA (1<<0) /* EEPROM Word/PHY Register Address */ +#define UDAV_EPAR_EROA_MASK (0x1f) /* [5:0] */ #define UDAV_EPDRL 0x0d /* EEPROM & PHY Data Register */ #define UDAV_EPDRH 0x0e /* EEPROM & PHY Data Register */ @@ -116,25 +116,25 @@ #define UDAV_MAR UDAV_MAR0 #define UDAV_GPCR 0x1e /* General purpose control register */ -#define UDAV_GPCR_GEP_CNTL6 (1<<6) /* General purpose control 6 */ -#define UDAV_GPCR_GEP_CNTL5 (1<<5) /* General purpose control 5 */ -#define UDAV_GPCR_GEP_CNTL4 (1<<4) /* General purpose control 4 */ -#define UDAV_GPCR_GEP_CNTL3 (1<<3) /* General purpose control 3 */ -#define UDAV_GPCR_GEP_CNTL2 (1<<2) /* General purpose control 2 */ -#define UDAV_GPCR_GEP_CNTL1 (1<<1) /* General purpose control 1 */ -#define UDAV_GPCR_GEP_CNTL0 (1<<0) /* General purpose control 0 */ +#define UDAV_GPCR_GEP_CNTL6 (1<<6) /* General purpose control 6 */ +#define UDAV_GPCR_GEP_CNTL5 (1<<5) /* General purpose control 5 */ +#define UDAV_GPCR_GEP_CNTL4 (1<<4) /* General purpose control 4 */ +#define UDAV_GPCR_GEP_CNTL3 (1<<3) /* General purpose control 3 */ +#define UDAV_GPCR_GEP_CNTL2 (1<<2) /* General purpose control 2 */ +#define UDAV_GPCR_GEP_CNTL1 (1<<1) /* General purpose control 1 */ +#define UDAV_GPCR_GEP_CNTL0 (1<<0) /* General purpose control 0 */ #define UDAV_GPR 0x1f /* General purpose register */ -#define UDAV_GPR_GEPIO6 (1<<6) /* General purpose 6 */ -#define UDAV_GPR_GEPIO5 (1<<5) /* General purpose 5 */ -#define UDAV_GPR_GEPIO4 (1<<4) /* General purpose 4 */ -#define UDAV_GPR_GEPIO3 (1<<3) /* General purpose 3 */ -#define UDAV_GPR_GEPIO2 (1<<2) /* General purpose 2 */ -#define UDAV_GPR_GEPIO1 (1<<1) /* General purpose 1 */ -#define UDAV_GPR_GEPIO0 (1<<0) /* General purpose 0 */ +#define UDAV_GPR_GEPIO6 (1<<6) /* General purpose 6 */ +#define UDAV_GPR_GEPIO5 (1<<5) /* General purpose 5 */ +#define UDAV_GPR_GEPIO4 (1<<4) /* General purpose 4 */ +#define UDAV_GPR_GEPIO3 (1<<3) /* General purpose 3 */ +#define UDAV_GPR_GEPIO2 (1<<2) /* General purpose 2 */ +#define UDAV_GPR_GEPIO1 (1<<1) /* General purpose 1 */ +#define UDAV_GPR_GEPIO0 (1<<0) /* General purpose 0 */ -#define GET_MII(sc) ((sc)->sc_miibus ? \ - device_get_softc((sc)->sc_miibus) : NULL) +#define GET_MII(sc) ((sc)->sc_miibus ? \ + device_get_softc((sc)->sc_miibus) : NULL) struct udav_softc { struct usbd_config_td sc_config_td; @@ -148,24 +148,24 @@ device_t sc_miibus; device_t sc_dev; - u_int32_t sc_unit; - u_int32_t sc_media_active; - u_int32_t sc_media_status; + uint32_t sc_unit; + uint32_t sc_media_active; + uint32_t sc_media_status; - u_int16_t sc_flags; -#define UDAV_FLAG_WAIT_LINK 0x0001 -#define UDAV_FLAG_INTR_STALL 0x0002 -#define UDAV_FLAG_READ_STALL 0x0004 -#define UDAV_FLAG_WRITE_STALL 0x0008 -#define UDAV_FLAG_LL_READY 0x0010 -#define UDAV_FLAG_HL_READY 0x0020 -#define UDAV_FLAG_EXT_PHY 0x0040 + uint16_t sc_flags; +#define UDAV_FLAG_WAIT_LINK 0x0001 +#define UDAV_FLAG_INTR_STALL 0x0002 +#define UDAV_FLAG_READ_STALL 0x0004 +#define UDAV_FLAG_WRITE_STALL 0x0008 +#define UDAV_FLAG_LL_READY 0x0010 +#define UDAV_FLAG_HL_READY 0x0020 +#define UDAV_FLAG_EXT_PHY 0x0040 - u_int8_t sc_name[16]; + uint8_t sc_name[16]; }; struct udav_config_copy { - u_int32_t if_flags; - u_int8_t if_lladdr[ETHER_ADDR_LEN]; - u_int8_t if_hashes[8]; + uint32_t if_flags; + uint8_t if_lladdr[ETHER_ADDR_LEN]; + uint8_t if_hashes[8]; }; ==== //depot/projects/usb/src/sys/dev/usb/if_uralreg.h#6 (text+ko) ==== @@ -17,191 +17,174 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#define RAL_RX_DESC_SIZE (sizeof (struct ural_rx_desc)) -#define RAL_TX_DESC_SIZE (sizeof (struct ural_tx_desc)) +#define RAL_RX_DESC_SIZE (sizeof (struct ural_rx_desc)) +#define RAL_TX_DESC_SIZE (sizeof (struct ural_tx_desc)) -#define RAL_CONFIG_NO 1 -#define RAL_IFACE_INDEX 0 +#define RAL_CONFIG_NO 1 +#define RAL_IFACE_INDEX 0 -#define RAL_VENDOR_REQUEST 0x01 -#define RAL_WRITE_MAC 0x02 -#define RAL_READ_MAC 0x03 -#define RAL_WRITE_MULTI_MAC 0x06 -#define RAL_READ_MULTI_MAC 0x07 -#define RAL_READ_EEPROM 0x09 +#define RAL_VENDOR_REQUEST 0x01 +#define RAL_WRITE_MAC 0x02 +#define RAL_READ_MAC 0x03 +#define RAL_WRITE_MULTI_MAC 0x06 +#define RAL_READ_MULTI_MAC 0x07 +#define RAL_READ_EEPROM 0x09 -/* - * MAC registers. - */ -#define RAL_MAC_CSR0 0x0400 /* ASIC Version */ -#define RAL_MAC_CSR1 0x0402 /* System control */ -#define RAL_MAC_CSR2 0x0404 /* MAC addr0 */ -#define RAL_MAC_CSR3 0x0406 /* MAC addr1 */ -#define RAL_MAC_CSR4 0x0408 /* MAC addr2 */ -#define RAL_MAC_CSR5 0x040a /* BSSID0 */ -#define RAL_MAC_CSR6 0x040c /* BSSID1 */ -#define RAL_MAC_CSR7 0x040e /* BSSID2 */ -#define RAL_MAC_CSR8 0x0410 /* Max frame length */ -#define RAL_MAC_CSR9 0x0412 /* Timer control */ -#define RAL_MAC_CSR10 0x0414 /* Slot time */ -#define RAL_MAC_CSR11 0x0416 /* IFS */ -#define RAL_MAC_CSR12 0x0418 /* EIFS */ -#define RAL_MAC_CSR13 0x041a /* Power mode0 */ -#define RAL_MAC_CSR14 0x041c /* Power mode1 */ -#define RAL_MAC_CSR15 0x041e /* Power saving transition0 */ -#define RAL_MAC_CSR16 0x0420 /* Power saving transition1 */ -#define RAL_MAC_CSR17 0x0422 /* Power state control */ -#define RAL_MAC_CSR18 0x0424 /* Auto wake-up control */ -#define RAL_MAC_CSR19 0x0426 /* GPIO control */ -#define RAL_MAC_CSR20 0x0428 /* LED control0 */ -#define RAL_MAC_CSR22 0x042c /* XXX not documented */ +/* MAC registers. */ +#define RAL_MAC_CSR0 0x0400 /* ASIC Version */ +#define RAL_MAC_CSR1 0x0402 /* System control */ +#define RAL_MAC_CSR2 0x0404 /* MAC addr0 */ +#define RAL_MAC_CSR3 0x0406 /* MAC addr1 */ +#define RAL_MAC_CSR4 0x0408 /* MAC addr2 */ +#define RAL_MAC_CSR5 0x040a /* BSSID0 */ +#define RAL_MAC_CSR6 0x040c /* BSSID1 */ +#define RAL_MAC_CSR7 0x040e /* BSSID2 */ +#define RAL_MAC_CSR8 0x0410 /* Max frame length */ +#define RAL_MAC_CSR9 0x0412 /* Timer control */ +#define RAL_MAC_CSR10 0x0414 /* Slot time */ +#define RAL_MAC_CSR11 0x0416 /* IFS */ +#define RAL_MAC_CSR12 0x0418 /* EIFS */ +#define RAL_MAC_CSR13 0x041a /* Power mode0 */ +#define RAL_MAC_CSR14 0x041c /* Power mode1 */ +#define RAL_MAC_CSR15 0x041e /* Power saving transition0 */ +#define RAL_MAC_CSR16 0x0420 /* Power saving transition1 */ +#define RAL_MAC_CSR17 0x0422 /* Power state control */ +#define RAL_MAC_CSR18 0x0424 /* Auto wake-up control */ +#define RAL_MAC_CSR19 0x0426 /* GPIO control */ +#define RAL_MAC_CSR20 0x0428 /* LED control0 */ +#define RAL_MAC_CSR22 0x042c /* XXX not documented */ -/* - * Tx/Rx Registers. - */ -#define RAL_TXRX_CSR0 0x0440 /* Security control */ -#define RAL_TXRX_CSR2 0x0444 /* Rx control */ -#define RAL_TXRX_CSR5 0x044a /* CCK Tx BBP ID0 */ -#define RAL_TXRX_CSR6 0x044c /* CCK Tx BBP ID1 */ -#define RAL_TXRX_CSR7 0x044e /* OFDM Tx BBP ID0 */ -#define RAL_TXRX_CSR8 0x0450 /* OFDM Tx BBP ID1 */ -#define RAL_TXRX_CSR10 0x0454 /* Auto responder control */ -#define RAL_TXRX_CSR11 0x0456 /* Auto responder basic rate */ -#define RAL_TXRX_CSR18 0x0464 /* Beacon interval */ -#define RAL_TXRX_CSR19 0x0466 /* Beacon/sync control */ -#define RAL_TXRX_CSR20 0x0468 /* Beacon alignment */ -#define RAL_TXRX_CSR21 0x046a /* XXX not documented */ +/* Tx/Rx Registers. */ +#define RAL_TXRX_CSR0 0x0440 /* Security control */ +#define RAL_TXRX_CSR2 0x0444 /* Rx control */ +#define RAL_TXRX_CSR5 0x044a /* CCK Tx BBP ID0 */ +#define RAL_TXRX_CSR6 0x044c /* CCK Tx BBP ID1 */ +#define RAL_TXRX_CSR7 0x044e /* OFDM Tx BBP ID0 */ +#define RAL_TXRX_CSR8 0x0450 /* OFDM Tx BBP ID1 */ +#define RAL_TXRX_CSR10 0x0454 /* Auto responder control */ +#define RAL_TXRX_CSR11 0x0456 /* Auto responder basic rate */ +#define RAL_TXRX_CSR18 0x0464 /* Beacon interval */ +#define RAL_TXRX_CSR19 0x0466 /* Beacon/sync control */ +#define RAL_TXRX_CSR20 0x0468 /* Beacon alignment */ +#define RAL_TXRX_CSR21 0x046a /* XXX not documented */ -/* - * Security registers. - */ -#define RAL_SEC_CSR0 0x0480 /* Shared key 0, word 0 */ +/* Security registers. */ +#define RAL_SEC_CSR0 0x0480 /* Shared key 0, word 0 */ -/* - * PHY registers. - */ -#define RAL_PHY_CSR2 0x04c4 /* Tx MAC configuration */ -#define RAL_PHY_CSR4 0x04c8 /* Interface configuration */ -#define RAL_PHY_CSR5 0x04ca /* BBP Pre-Tx CCK */ -#define RAL_PHY_CSR6 0x04cc /* BBP Pre-Tx OFDM */ -#define RAL_PHY_CSR7 0x04ce /* BBP serial control */ -#define RAL_PHY_CSR8 0x04d0 /* BBP serial status */ -#define RAL_PHY_CSR9 0x04d2 /* RF serial control0 */ -#define RAL_PHY_CSR10 0x04d4 /* RF serial control1 */ +/* PHY registers. */ +#define RAL_PHY_CSR2 0x04c4 /* Tx MAC configuration */ +#define RAL_PHY_CSR4 0x04c8 /* Interface configuration */ +#define RAL_PHY_CSR5 0x04ca /* BBP Pre-Tx CCK */ +#define RAL_PHY_CSR6 0x04cc /* BBP Pre-Tx OFDM */ +#define RAL_PHY_CSR7 0x04ce /* BBP serial control */ +#define RAL_PHY_CSR8 0x04d0 /* BBP serial status */ +#define RAL_PHY_CSR9 0x04d2 /* RF serial control0 */ +#define RAL_PHY_CSR10 0x04d4 /* RF serial control1 */ -/* - * Statistics registers. - */ -#define RAL_STA_CSR0 0x04e0 /* FCS error */ +/* Statistics registers. */ +#define RAL_STA_CSR0 0x04e0 /* FCS error */ +#define RAL_DISABLE_RX (1 << 0) +#define RAL_DROP_CRC (1 << 1) +#define RAL_DROP_PHY (1 << 2) +#define RAL_DROP_CTL (1 << 3) +#define RAL_DROP_NOT_TO_ME (1 << 4) +#define RAL_DROP_TODS (1 << 5) +#define RAL_DROP_BAD_VERSION (1 << 6) +#define RAL_DROP_MULTICAST (1 << 9) +#define RAL_DROP_BROADCAST (1 << 10) -#define RAL_DISABLE_RX (1 << 0) -#define RAL_DROP_CRC (1 << 1) -#define RAL_DROP_PHY (1 << 2) -#define RAL_DROP_CTL (1 << 3) -#define RAL_DROP_NOT_TO_ME (1 << 4) -#define RAL_DROP_TODS (1 << 5) -#define RAL_DROP_BAD_VERSION (1 << 6) -#define RAL_DROP_MULTICAST (1 << 9) -#define RAL_DROP_BROADCAST (1 << 10) +#define RAL_SHORT_PREAMBLE (1 << 2) -#define RAL_SHORT_PREAMBLE (1 << 2) +#define RAL_RESET_ASIC (1 << 0) +#define RAL_RESET_BBP (1 << 1) +#define RAL_HOST_READY (1 << 2) -#define RAL_RESET_ASIC (1 << 0) -#define RAL_RESET_BBP (1 << 1) -#define RAL_HOST_READY (1 << 2) +#define RAL_ENABLE_TSF (1 << 0) +#define RAL_ENABLE_TSF_SYNC(x) (((x) & 0x3) << 1) +#define RAL_ENABLE_TBCN (1 << 3) +#define RAL_ENABLE_BEACON_GENERATOR (1 << 4) -#define RAL_ENABLE_TSF (1 << 0) -#define RAL_ENABLE_TSF_SYNC(x) (((x) & 0x3) << 1) -#define RAL_ENABLE_TBCN (1 << 3) -#define RAL_ENABLE_BEACON_GENERATOR (1 << 4) +#define RAL_RF_AWAKE (3 << 7) +#define RAL_BBP_AWAKE (3 << 5) -#define RAL_RF_AWAKE (3 << 7) -#define RAL_BBP_AWAKE (3 << 5) +#define RAL_BBP_WRITE (1 << 15) +#define RAL_BBP_BUSY (1 << 0) -#define RAL_BBP_WRITE (1 << 15) -#define RAL_BBP_BUSY (1 << 0) +#define RAL_RF1_AUTOTUNE 0x08000 +#define RAL_RF3_AUTOTUNE 0x00040 -#define RAL_RF1_AUTOTUNE 0x08000 -#define RAL_RF3_AUTOTUNE 0x00040 - -#define RAL_RF_2522 0x00 -#define RAL_RF_2523 0x01 -#define RAL_RF_2524 0x02 -#define RAL_RF_2525 0x03 -#define RAL_RF_2525E 0x04 -#define RAL_RF_2526 0x05 +#define RAL_RF_2522 0x00 +#define RAL_RF_2523 0x01 +#define RAL_RF_2524 0x02 +#define RAL_RF_2525 0x03 +#define RAL_RF_2525E 0x04 +#define RAL_RF_2526 0x05 /* dual-band RF */ -#define RAL_RF_5222 0x10 +#define RAL_RF_5222 0x10 -#define RAL_BBP_VERSION 0 -#define RAL_BBP_TX 2 -#define RAL_BBP_RX 14 +#define RAL_BBP_VERSION 0 +#define RAL_BBP_TX 2 +#define RAL_BBP_RX 14 -#define RAL_BBP_ANTA 0x00 -#define RAL_BBP_DIVERSITY 0x01 -#define RAL_BBP_ANTB 0x02 -#define RAL_BBP_ANTMASK 0x03 -#define RAL_BBP_FLIPIQ 0x04 +#define RAL_BBP_ANTA 0x00 +#define RAL_BBP_DIVERSITY 0x01 +#define RAL_BBP_ANTB 0x02 +#define RAL_BBP_ANTMASK 0x03 +#define RAL_BBP_FLIPIQ 0x04 -#define RAL_JAPAN_FILTER 0x08 +#define RAL_JAPAN_FILTER 0x08 -struct ural_tx_desc { - u_int32_t flags; -#define RAL_TX_RETRY(x) ((x) << 4) -#define RAL_TX_MORE_FRAG (1 << 8) -#define RAL_TX_ACK (1 << 9) -#define RAL_TX_TIMESTAMP (1 << 10) -#define RAL_TX_OFDM (1 << 11) -#define RAL_TX_NEWSEQ (1 << 12) +#define RAL_RF_LOBUSY (1 << 15) +#define RAL_RF_BUSY (1 << 31) +#define RAL_RF_20BIT (20 << 24) -#define RAL_TX_IFS_MASK 0x00006000 -#define RAL_TX_IFS_BACKOFF (0 << 13) -#define RAL_TX_IFS_SIFS (1 << 13) -#define RAL_TX_IFS_NEWBACKOFF (2 << 13) -#define RAL_TX_IFS_NONE (3 << 13) +#define RAL_RF1 0 +#define RAL_RF2 2 +#define RAL_RF3 1 +#define RAL_RF4 3 - u_int16_t wme; -#define RAL_LOGCWMAX(x) (((x) & 0xf) << 12) -#define RAL_LOGCWMIN(x) (((x) & 0xf) << 8) -#define RAL_AIFSN(x) (((x) & 0x3) << 6) -#define RAL_IVOFFSET(x) (((x) & 0x3f)) +#define RAL_EEPROM_ADDRESS 0x0004 +#define RAL_EEPROM_TXPOWER 0x003c +#define RAL_EEPROM_CONFIG0 0x0016 +#define RAL_EEPROM_BBP_BASE 0x001c - u_int16_t reserved1; - u_int8_t plcp_signal; - u_int8_t plcp_service; -#define RAL_PLCP_LENGEXT 0x80 - - u_int8_t plcp_length_lo; - u_int8_t plcp_length_hi; - u_int32_t iv; - u_int32_t eiv; +struct ural_tx_desc { + uint32_t flags; +#define RAL_TX_RETRY(x) ((x) << 4) +#define RAL_TX_MORE_FRAG (1 << 8) +#define RAL_TX_ACK (1 << 9) +#define RAL_TX_TIMESTAMP (1 << 10) +#define RAL_TX_OFDM (1 << 11) +#define RAL_TX_NEWSEQ (1 << 12) +#define RAL_TX_IFS_MASK 0x00006000 +#define RAL_TX_IFS_BACKOFF (0 << 13) +#define RAL_TX_IFS_SIFS (1 << 13) +#define RAL_TX_IFS_NEWBACKOFF (2 << 13) +#define RAL_TX_IFS_NONE (3 << 13) + uint16_t wme; +#define RAL_LOGCWMAX(x) (((x) & 0xf) << 12) +#define RAL_LOGCWMIN(x) (((x) & 0xf) << 8) +#define RAL_AIFSN(x) (((x) & 0x3) << 6) +#define RAL_IVOFFSET(x) (((x) & 0x3f)) + uint16_t reserved1; + uint8_t plcp_signal; + uint8_t plcp_service; +#define RAL_PLCP_LENGEXT 0x80 + uint8_t plcp_length_lo; + uint8_t plcp_length_hi; + uint32_t iv; + uint32_t eiv; } __packed; struct ural_rx_desc { - u_int32_t flags; -#define RAL_RX_CRC_ERROR (1 << 5) -#define RAL_RX_OFDM (1 << 6) -#define RAL_RX_PHY_ERROR (1 << 7) - - u_int8_t rssi; - u_int8_t rate; - u_int16_t reserved; - - u_int32_t iv; - u_int32_t eiv; + uint32_t flags; +#define RAL_RX_CRC_ERROR (1 << 5) +#define RAL_RX_OFDM (1 << 6) +#define RAL_RX_PHY_ERROR (1 << 7) + uint8_t rssi; + uint8_t rate; + uint16_t reserved; + uint32_t iv; + uint32_t eiv; } __packed; - -#define RAL_RF_LOBUSY (1 << 15) -#define RAL_RF_BUSY (1 << 31) -#define RAL_RF_20BIT (20 << 24) - -#define RAL_RF1 0 -#define RAL_RF2 2 -#define RAL_RF3 1 -#define RAL_RF4 3 - -#define RAL_EEPROM_ADDRESS 0x0004 -#define RAL_EEPROM_TXPOWER 0x003c -#define RAL_EEPROM_CONFIG0 0x0016 -#define RAL_EEPROM_BBP_BASE 0x001c From owner-p4-projects@FreeBSD.ORG Tue Sep 26 15:43:51 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id BCFB916A5CD; Tue, 26 Sep 2006 15:43:51 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 79C8716A5C5 for ; Tue, 26 Sep 2006 15:43:51 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0168043D45 for ; Tue, 26 Sep 2006 15:41:58 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QFflb8041393 for ; Tue, 26 Sep 2006 15:41:47 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QFfldr041390 for perforce@freebsd.org; Tue, 26 Sep 2006 15:41:47 GMT (envelope-from attilio@FreeBSD.org) Date: Tue, 26 Sep 2006 15:41:47 GMT Message-Id: <200609261541.k8QFfldr041390@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106726 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 15:43:52 -0000 http://perforce.freebsd.org/chv.cgi?CH=106726 Change 106726 by attilio@attilio_laptop on 2006/09/26 15:41:42 Style-ize it Affected files ... .. //depot/projects/usb/src/sys/dev/usb/if_uralvar.h#8 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/if_uralvar.h#8 (text+ko) ==== @@ -17,70 +17,72 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +#define URAL_N_TRANSFER 4 + struct ural_config_copy { struct { - u_int32_t chan_to_ieee; - u_int8_t chan_is_2ghz; + uint32_t chan_to_ieee; + uint8_t chan_is_2ghz; } ic_curchan; struct { - struct { - u_int8_t chan_is_5ghz; - } ni_chan; + struct { + uint8_t chan_is_5ghz; + } ni_chan; - u_int16_t ni_intval; - u_int8_t ni_bssid[IEEE80211_ADDR_LEN]; + uint16_t ni_intval; + uint8_t ni_bssid[IEEE80211_ADDR_LEN]; } ic_bss; struct { - struct { - ieee80211_keyix wk_keyix; - u_int8_t wk_key[IEEE80211_KEYBUF_SIZE]; - } cs_nw_keys[IEEE80211_WEP_NKID]; + struct { + ieee80211_keyix wk_keyix; + uint8_t wk_key[IEEE80211_KEYBUF_SIZE]; + } cs_nw_keys[IEEE80211_WEP_NKID]; } ic_crypto; enum ieee80211_opmode ic_opmode; enum ieee80211_state ic_state; - u_int32_t ic_flags; - u_int32_t if_flags; + uint32_t ic_flags; + uint32_t if_flags; - u_int16_t ic_txpowlimit; - u_int16_t ic_curmode; + uint16_t ic_txpowlimit; + uint16_t ic_curmode; - u_int8_t ic_myaddr[IEEE80211_ADDR_LEN]; + uint8_t ic_myaddr[IEEE80211_ADDR_LEN]; }; struct ural_rx_radiotap_header { struct ieee80211_radiotap_header wr_ihdr; - u_int8_t wr_flags; - u_int8_t wr_rate; - u_int16_t wr_chan_freq; - u_int16_t wr_chan_flags; - u_int8_t wr_antenna; - u_int8_t wr_antsignal; + uint8_t wr_flags; + uint8_t wr_rate; + uint16_t wr_chan_freq; + uint16_t wr_chan_flags; + uint8_t wr_antenna; + uint8_t wr_antsignal; }; #define RAL_RX_RADIOTAP_PRESENT \ - ((1 << IEEE80211_RADIOTAP_FLAGS) | \ - (1 << IEEE80211_RADIOTAP_RATE) | \ - (1 << IEEE80211_RADIOTAP_CHANNEL) | \ - (1 << IEEE80211_RADIOTAP_ANTENNA) | \ - (1 << IEEE80211_RADIOTAP_DB_ANTSIGNAL)) + ((1 << IEEE80211_RADIOTAP_FLAGS) | \ + (1 << IEEE80211_RADIOTAP_RATE) | \ + (1 << IEEE80211_RADIOTAP_CHANNEL) | \ + (1 << IEEE80211_RADIOTAP_ANTENNA) | \ + (1 << IEEE80211_RADIOTAP_DB_ANTSIGNAL)) struct ural_tx_radiotap_header { struct ieee80211_radiotap_header wt_ihdr; - u_int8_t wt_flags; - u_int8_t wt_rate; - u_int16_t wt_chan_freq; - u_int16_t wt_chan_flags; - u_int8_t wt_antenna; + uint8_t wt_flags; + uint8_t wt_rate; + uint16_t wt_chan_freq; + uint16_t wt_chan_flags; + uint8_t wt_antenna; }; #define RAL_TX_RADIOTAP_PRESENT \ - ((1 << IEEE80211_RADIOTAP_FLAGS) | \ - (1 << IEEE80211_RADIOTAP_RATE) | \ - (1 << IEEE80211_RADIOTAP_CHANNEL) | \ - (1 << IEEE80211_RADIOTAP_ANTENNA)) + ((1 << IEEE80211_RADIOTAP_FLAGS) | \ + (1 << IEEE80211_RADIOTAP_RATE) | \ + (1 << IEEE80211_RADIOTAP_CHANNEL) | \ + (1 << IEEE80211_RADIOTAP_ANTENNA)) struct ural_amrr { int txcnt; @@ -92,21 +94,19 @@ union ural_rxtap { struct ural_rx_radiotap_header h; - u_int8_t pad[64]; + uint8_t pad[64]; }; union ural_txtap { struct ural_tx_radiotap_header h; - u_int8_t pad[64]; + uint8_t pad[64]; }; struct ural_bbp_prom { - u_int8_t val; - u_int8_t reg; + uint8_t val; + uint8_t reg; } __packed; -#define URAL_N_TRANSFER 4 - struct ural_softc { struct usbd_config_td sc_config_td; @@ -129,41 +129,41 @@ struct usbd_device *sc_udev; int (*sc_newstate) - (struct ieee80211com *, enum ieee80211_state, int); + (struct ieee80211com *, enum ieee80211_state, int); enum ieee80211_state sc_state; - u_int32_t sc_bcn_flags; - u_int32_t sc_unit; - u_int32_t sc_asic_rev; - u_int32_t sc_rf_regs[4]; + uint32_t sc_bcn_flags; + uint32_t sc_unit; + uint32_t sc_asic_rev; + uint32_t sc_rf_regs[4]; - u_int16_t sc_flags; -#define URAL_FLAG_READ_STALL 0x0001 -#define URAL_FLAG_WRITE_STALL 0x0002 -#define URAL_FLAG_SEND_BYTE_FRAME 0x0004 -#define URAL_FLAG_SEND_BCN_FRAME 0x0008 -#define URAL_FLAG_LL_READY 0x0010 -#define URAL_FLAG_HL_READY 0x0020 -#define URAL_FLAG_WAIT_COMMAND 0x0040 - u_int16_t sc_txtap_len; - u_int16_t sc_rxtap_len; - u_int16_t sc_sta[11]; - u_int16_t sc_bcn_rate; + uint16_t sc_flags; +#define URAL_FLAG_READ_STALL 0x0001 +#define URAL_FLAG_WRITE_STALL 0x0002 +#define URAL_FLAG_SEND_BYTE_FRAME 0x0004 +#define URAL_FLAG_SEND_BCN_FRAME 0x0008 +#define URAL_FLAG_LL_READY 0x0010 +#define URAL_FLAG_HL_READY 0x0020 +#define URAL_FLAG_WAIT_COMMAND 0x0040 + uint16_t sc_txtap_len; + uint16_t sc_rxtap_len; + uint16_t sc_sta[11]; + uint16_t sc_bcn_rate; - u_int8_t sc_rf_rev; - u_int8_t sc_txpow[14]; - u_int8_t sc_led_mode; - u_int8_t sc_hw_radio; - u_int8_t sc_rx_ant; - u_int8_t sc_tx_ant; - u_int8_t sc_nb_ant; - u_int8_t sc_if_timer; - u_int8_t sc_tx_timer; - u_int8_t sc_scan_timer; - u_int8_t sc_amrr_timer; - u_int8_t sc_name[32]; + uint8_t sc_rf_rev; + uint8_t sc_txpow[14]; + uint8_t sc_led_mode; + uint8_t sc_hw_radio; + uint8_t sc_rx_ant; + uint8_t sc_tx_ant; + uint8_t sc_nb_ant; + uint8_t sc_if_timer; + uint8_t sc_tx_timer; + uint8_t sc_scan_timer; + uint8_t sc_amrr_timer; + uint8_t sc_name[32]; - u_int8_t sc_wakeup_bcn; + uint8_t sc_wakeup_bcn; }; From owner-p4-projects@FreeBSD.ORG Tue Sep 26 15:49:32 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id F3BEE16A51B; Tue, 26 Sep 2006 15:49:28 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 8661D16A5D5 for ; Tue, 26 Sep 2006 15:49:28 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 49B4C43D67 for ; Tue, 26 Sep 2006 15:49:04 +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.6/8.13.6) with ESMTP id k8QFmwtV041897 for ; Tue, 26 Sep 2006 15:48:58 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QFmwvJ041892 for perforce@freebsd.org; Tue, 26 Sep 2006 15:48:58 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 26 Sep 2006 15:48:58 GMT Message-Id: <200609261548.k8QFmwvJ041892@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 Cc: Subject: PERFORCE change 106729 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 15:49:32 -0000 http://perforce.freebsd.org/chv.cgi?CH=106729 Change 106729 by rwatson@rwatson_sesame on 2006/09/26 15:48:10 Loop back integration of privilege regression tests to TrustedBSD priv branch after CVS commit; no functional change. Affected files ... .. //depot/projects/trustedbsd/priv/tools/regression/priv/Makefile#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/main.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/main.h#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_acct.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_adjtime.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_clock_settime.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_io.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_set.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_unset.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setlogin.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setrlimit.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_rtprio.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_setpriority.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_settimeofday.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sysctl_write.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_admin.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chown.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chroot.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_clearsugid.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_extattr_system.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhopen.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstat.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstatfs.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_generation.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_getfh.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_read_write.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_setgid.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_stickyfile.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_madv_protect.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_mlock.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_munlock.c#2 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/test_utimes.c#2 integrate Differences ... ==== //depot/projects/trustedbsd/priv/tools/regression/priv/Makefile#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/main.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/main.h#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_acct.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_adjtime.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_clock_settime.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_io.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_set.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_unset.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setlogin.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setrlimit.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_rtprio.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_setpriority.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_settimeofday.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sysctl_write.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_admin.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chown.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chroot.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_clearsugid.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_extattr_system.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhopen.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstat.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstatfs.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_generation.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_getfh.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_read_write.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_setgid.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_stickyfile.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_madv_protect.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_mlock.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_munlock.c#2 (text+ko) ==== ==== //depot/projects/trustedbsd/priv/tools/regression/priv/test_utimes.c#2 (text+ko) ==== From owner-p4-projects@FreeBSD.ORG Tue Sep 26 15:50:31 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 93C9316A47E; Tue, 26 Sep 2006 15:50:31 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 59AC516A40F for ; Tue, 26 Sep 2006 15:50:31 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2E4DA43DB4 for ; Tue, 26 Sep 2006 15:50:03 +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.6/8.13.6) with ESMTP id k8QFo0Au041940 for ; Tue, 26 Sep 2006 15:50:00 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QFo0Zl041925 for perforce@freebsd.org; Tue, 26 Sep 2006 15:50:00 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Tue, 26 Sep 2006 15:50:00 GMT Message-Id: <200609261550.k8QFo0Zl041925@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 Cc: Subject: PERFORCE change 106730 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 15:50:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=106730 Change 106730 by rwatson@rwatson_sesame on 2006/09/26 15:49:36 Re-integ trustedbsd_priv regression tree, forcing merge of expanded $FreeBSD$ missed in last integ. Affected files ... .. //depot/projects/trustedbsd/priv/tools/regression/priv/Makefile#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/main.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/main.h#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_acct.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_adjtime.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_clock_settime.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_io.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_set.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_unset.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setlogin.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setrlimit.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_rtprio.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_setpriority.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_settimeofday.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sysctl_write.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_admin.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chown.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chroot.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_clearsugid.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_extattr_system.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhopen.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstat.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstatfs.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_generation.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_getfh.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_read_write.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_setgid.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_stickyfile.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_madv_protect.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_mlock.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_munlock.c#3 integrate .. //depot/projects/trustedbsd/priv/tools/regression/priv/test_utimes.c#3 integrate Differences ... ==== //depot/projects/trustedbsd/priv/tools/regression/priv/Makefile#3 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD$ +# $FreeBSD: src/tools/regression/priv/Makefile,v 1.1 2006/09/13 09:05:39 rwatson Exp $ # PROG= main ==== //depot/projects/trustedbsd/priv/tools/regression/priv/main.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/main.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/main.h#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/main.h,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ #define UID_ROOT 0 ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_acct.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_acct.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_adjtime.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_adjtime.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_clock_settime.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_clock_settime.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_io.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_io.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_set.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_kenv_set.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_kenv_unset.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_kenv_unset.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setlogin.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_proc_setlogin.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_proc_setrlimit.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_proc_setrlimit.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_rtprio.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_sched_rtprio.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sched_setpriority.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_sched_setpriority.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_settimeofday.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_settimeofday.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_sysctl_write.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_sysctl_write.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_admin.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_admin.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chown.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_chown.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_chroot.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_chroot.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_clearsugid.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_clearsugid.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_extattr_system.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_extattr_system.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhopen.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_fhopen.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstat.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_fhstat.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_fhstatfs.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_fhstatfs.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_generation.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_generation.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_getfh.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_getfh.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_read_write.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_read_write.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_setgid.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_setgid.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vfs_stickyfile.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vfs_stickyfile.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_madv_protect.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vm_madv_protect.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_mlock.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vm_mlock.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/priv_vm_munlock.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/priv_vm_munlock.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* ==== //depot/projects/trustedbsd/priv/tools/regression/priv/test_utimes.c#3 (text+ko) ==== @@ -26,7 +26,7 @@ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD$ + * $FreeBSD: src/tools/regression/priv/test_utimes.c,v 1.1 2006/09/13 09:05:39 rwatson Exp $ */ /* From owner-p4-projects@FreeBSD.ORG Tue Sep 26 17:25:08 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7FADB16A415; Tue, 26 Sep 2006 17:25:08 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 42F3116A403 for ; Tue, 26 Sep 2006 17:25:08 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 183CC43D5A for ; Tue, 26 Sep 2006 17:25:04 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QHP4cJ057058 for ; Tue, 26 Sep 2006 17:25:04 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QHP3gt057055 for perforce@freebsd.org; Tue, 26 Sep 2006 17:25:03 GMT (envelope-from imp@freebsd.org) Date: Tue, 26 Sep 2006 17:25:03 GMT Message-Id: <200609261725.k8QHP3gt057055@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106735 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 17:25:08 -0000 http://perforce.freebsd.org/chv.cgi?CH=106735 Change 106735 by imp@imp_lighthouse on 2006/09/26 17:24:56 Move some stuff back. Commonization will have to wait. Affected files ... .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/mci_device.h#9 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#5 edit Differences ... ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/mci_device.h#9 (text+ko) ==== @@ -50,7 +50,7 @@ typedef unsigned int AT91S_MCIDeviceStatus; -///////////////////////////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// #define AT91C_CARD_REMOVED 0 #define AT91C_MMC_CARD_INSERTED 1 @@ -79,9 +79,9 @@ -//////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// // MMC & SDCard Structures -//////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// /*-----------------------------------------------*/ /* SDCard Device Descriptor Structure Definition */ @@ -123,9 +123,9 @@ #include -///////////////////////////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// // Functions returnals -///////////////////////////////////////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////////////// #define AT91C_CMD_SEND_OK 0 // Command ok #define AT91C_CMD_SEND_ERROR -1 // Command failed #define AT91C_INIT_OK 2 // Init Successfull @@ -143,6 +143,314 @@ AT91C_MCI_DCRCE | AT91C_MCI_RTOE | AT91C_MCI_RENDE | AT91C_MCI_RCRCE | \ AT91C_MCI_RDIRE | AT91C_MCI_RINDE) +#define MMC_CMDNB (0x1Fu << 0) // Command Number +#define MMC_RSPTYP (0x3u << 6) // Response Type +#define MMC_RSPTYP_NO (0x0u << 6) // No response +#define MMC_RSPTYP_48 (0x1u << 6) // 48-bit response +#define MMC_RSPTYP_136 (0x2u << 6) // 136-bit response +#define MMC_SPCMD (0x7u << 8) // Special CMD +#define MMC_SPCMD_NONE (0x0u << 8) // Not a special CMD +#define MMC_SPCMD_INIT (0x1u << 8) // Initialization CMD +#define MMC_SPCMD_SYNC (0x2u << 8) // Synchronized CMD +#define MMC_SPCMD_IT_CMD (0x4u << 8) // Interrupt command +#define MMC_SPCMD_IT_REP (0x5u << 8) // Interrupt response +#define MMC_OPDCMD (0x1u << 11) // Open Drain Command +#define MMC_MAXLAT (0x1u << 12) // Maximum Latency for Command to respond +#define MMC_TRCMD (0x3u << 16) // Transfer CMD +#define MMC_TRCMD_NO (0x0u << 16) // No transfer +#define MMC_TRCMD_START (0x1u << 16) // Start transfer +#define MMC_TRCMD_STOP (0x2u << 16) // Stop transfer +#define MMC_TRDIR (0x1u << 18) // Transfer Direction +#define MMC_TRTYP (0x3u << 19) // Transfer Type +#define MMC_TRTYP_BLOCK (0x0u << 19) // Block Transfer type +#define MMC_TRTYP_MULTIPLE (0x1u << 19) // Multiple Block transfer type +#define MMC_TRTYP_STREAM (0x2u << 19) // Stream transfer type + +/////////////////////////////////////////////////////////////////////////////// +// MCI_CMD Register Value +/////////////////////////////////////////////////////////////////////////////// +#define POWER_ON_INIT \ + (0 | MMC_TRCMD_NO | MMC_SPCMD_INIT | MMC_OPDCMD) + +///////////////////////////////////////////////////////////////// +// Class 0 & 1 commands: Basic commands and Read Stream commands +///////////////////////////////////////////////////////////////// + +#define GO_IDLE_STATE_CMD \ + (0 | MMC_TRCMD_NO | MMC_SPCMD_NONE ) +#define MMC_GO_IDLE_STATE_CMD \ + (0 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_OPDCMD) +#define MMC_SEND_OP_COND_CMD \ + (1 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ + MMC_OPDCMD) + +#define ALL_SEND_CID_CMD \ + (2 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136) +#define MMC_ALL_SEND_CID_CMD \ + (2 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136 | \ + MMC_OPDCMD) + +#define SET_RELATIVE_ADDR_CMD \ + (3 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ + MMC_MAXLAT) +#define MMC_SET_RELATIVE_ADDR_CMD \ + (3 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ + MMC_MAXLAT | MMC_OPDCMD) + +#define SET_DSR_CMD \ + (4 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_NO | \ + MMC_MAXLAT) // no tested + +#define SEL_DESEL_CARD_CMD \ + (7 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ + MMC_MAXLAT) +#define SEND_CSD_CMD \ + (9 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136 | \ + MMC_MAXLAT) +#define SEND_CID_CMD \ + (10 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136 | \ + MMC_MAXLAT) +#define MMC_READ_DAT_UNTIL_STOP_CMD \ + (11 | MMC_TRTYP_STREAM | MMC_SPCMD_NONE | \ + MMC_RSPTYP_48 | MMC_TRDIR | MMC_TRCMD_START | \ + MMC_MAXLAT) + +#define STOP_TRANSMISSION_CMD \ + (12 | MMC_TRCMD_STOP | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ + MMC_MAXLAT) +#define STOP_TRANSMISSION_SYNC_CMD \ + (12 | MMC_TRCMD_STOP | MMC_SPCMD_SYNC | MMC_RSPTYP_48 | \ + MMC_MAXLAT) +#define SEND_STATUS_CMD \ + (13 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ + MMC_MAXLAT) +#define GO_INACTIVE_STATE_CMD \ + (15 | MMC_RSPTYP_NO) + +//*------------------------------------------------ +//* Class 2 commands: Block oriented Read commands +//*------------------------------------------------ + +#define SET_BLOCKLEN_CMD (16 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_MAXLAT ) +#define READ_SINGLE_BLOCK_CMD (17 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | MMC_TRTYP_BLOCK | MMC_TRDIR | MMC_MAXLAT) +#define READ_MULTIPLE_BLOCK_CMD (18 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | MMC_TRTYP_MULTIPLE | MMC_TRDIR | MMC_MAXLAT) + +//*-------------------------------------------- +//* Class 3 commands: Sequential write commands +//*-------------------------------------------- + +#define MMC_WRITE_DAT_UNTIL_STOP_CMD (20 | MMC_TRTYP_STREAM| MMC_SPCMD_NONE | MMC_RSPTYP_48 & ~(MMC_TRDIR) | MMC_TRCMD_START | MMC_MAXLAT ) // MMC + +//*------------------------------------------------ +//* Class 4 commands: Block oriented write commands +//*------------------------------------------------ + +#define WRITE_BLOCK_CMD (24 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | (MMC_TRTYP_BLOCK & ~(MMC_TRDIR)) | MMC_MAXLAT) +#define WRITE_MULTIPLE_BLOCK_CMD (25 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | (MMC_TRTYP_MULTIPLE & ~(MMC_TRDIR)) | MMC_MAXLAT) +#define PROGRAM_CSD_CMD (27 | MMC_RSPTYP_48 ) + + +//*---------------------------------------- +//* Class 6 commands: Group Write protect +//*---------------------------------------- + +#define SET_WRITE_PROT_CMD (28 | MMC_RSPTYP_48 ) +#define CLR_WRITE_PROT_CMD (29 | MMC_RSPTYP_48 ) +#define SEND_WRITE_PROT_CMD (30 | MMC_RSPTYP_48 ) + + +//*---------------------------------------- +//* Class 5 commands: Erase commands +//*---------------------------------------- + +#define TAG_SECTOR_START_CMD (32 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define TAG_SECTOR_END_CMD (33 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define MMC_UNTAG_SECTOR_CMD (34 | MMC_RSPTYP_48 ) +#define MMC_TAG_ERASE_GROUP_START_CMD (35 | MMC_RSPTYP_48 ) +#define MMC_TAG_ERASE_GROUP_END_CMD (36 | MMC_RSPTYP_48 ) +#define MMC_UNTAG_ERASE_GROUP_CMD (37 | MMC_RSPTYP_48 ) +#define ERASE_CMD (38 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT ) + +//*---------------------------------------- +//* Class 7 commands: Lock commands +//*---------------------------------------- + +#define LOCK_UNLOCK (42 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) // no tested + +//*----------------------------------------------- +// Class 8 commands: Application specific commands +//*----------------------------------------------- + +#define APP_CMD (55 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define GEN_CMD (56 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) // no tested + +#define SDCARD_SET_BUS_WIDTH_CMD (6 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define SDCARD_STATUS_CMD (13 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define SDCARD_SEND_NUM_WR_BLOCKS_CMD (22 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define SDCARD_SET_WR_BLK_ERASE_COUNT_CMD (23 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define SDCARD_APP_OP_COND_CMD (41 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO ) +#define SDCARD_SET_CLR_CARD_DETECT_CMD (42 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) +#define SDCARD_SEND_SCR_CMD (51 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) + +#define SDCARD_APP_ALL_CMD (SDCARD_SET_BUS_WIDTH_CMD +\ + SDCARD_STATUS_CMD +\ + SDCARD_SEND_NUM_WR_BLOCKS_CMD +\ + SDCARD_SET_WR_BLK_ERASE_COUNT_CMD +\ + SDCARD_APP_OP_COND_CMD +\ + SDCARD_SET_CLR_CARD_DETECT_CMD +\ + SDCARD_SEND_SCR_CMD) + +//*---------------------------------------- +//* Class 9 commands: IO Mode commands +//*---------------------------------------- + +#define MMC_FAST_IO_CMD (39 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_MAXLAT) +#define MMC_GO_IRQ_STATE_CMD (40 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) + +/////////////////////////////////////////////////////////////////////////////// +// OCR Register +/////////////////////////////////////////////////////////////////////////////// +#define AT91C_VDD_16_17 (1 << 4) +#define AT91C_VDD_17_18 (1 << 5) +#define AT91C_VDD_18_19 (1 << 6) +#define AT91C_VDD_19_20 (1 << 7) +#define AT91C_VDD_20_21 (1 << 8) +#define AT91C_VDD_21_22 (1 << 9) +#define AT91C_VDD_22_23 (1 << 10) +#define AT91C_VDD_23_24 (1 << 11) +#define AT91C_VDD_24_25 (1 << 12) +#define AT91C_VDD_25_26 (1 << 13) +#define AT91C_VDD_26_27 (1 << 14) +#define AT91C_VDD_27_28 (1 << 15) +#define AT91C_VDD_28_29 (1 << 16) +#define AT91C_VDD_29_30 (1 << 17) +#define AT91C_VDD_30_31 (1 << 18) +#define AT91C_VDD_31_32 (1 << 19) +#define AT91C_VDD_32_33 (1 << 20) +#define AT91C_VDD_33_34 (1 << 21) +#define AT91C_VDD_34_35 (1 << 22) +#define AT91C_VDD_35_36 (1 << 23) +#define AT91C_CARD_POWER_UP_BUSY (1 << 31) + +#define AT91C_MMC_HOST_VOLTAGE_RANGE (AT91C_VDD_27_28 | AT91C_VDD_28_29 | \ + AT91C_VDD_29_30 | AT91C_VDD_30_31 | AT91C_VDD_31_32 | AT91C_VDD_32_33) + +/////////////////////////////////////////////////////////////////////////////// +// CURRENT_STATE & READY_FOR_DATA in SDCard Status Register definition (response type R1) +/////////////////////////////////////////////////////////////////////////////// +#define AT91C_SR_READY_FOR_DATA (1 << 8) // corresponds to buffer empty signalling on the bus +#define AT91C_SR_IDLE (0 << 9) +#define AT91C_SR_READY (1 << 9) +#define AT91C_SR_IDENT (2 << 9) +#define AT91C_SR_STBY (3 << 9) +#define AT91C_SR_TRAN (4 << 9) +#define AT91C_SR_DATA (5 << 9) +#define AT91C_SR_RCV (6 << 9) +#define AT91C_SR_PRG (7 << 9) +#define AT91C_SR_DIS (8 << 9) + +#define AT91C_SR_CARD_SELECTED (AT91C_SR_READY_FOR_DATA + AT91C_SR_TRAN) + +#define MMC_FIRST_RCA 0xCAFE + +/////////////////////////////////////////////////////////////////////////////// +// MMC CSD register header File +// CSD_x_xxx_S for shift value for word x +// CSD_x_xxx_M for mask value for word x +/////////////////////////////////////////////////////////////////////////////// + +// First Response INT <=> CSD[3] : bits 0 to 31 +#define CSD_3_BIT0_S 0 // [0:0] +#define CSD_3_BIT0_M 0x01 +#define CSD_3_CRC_S 1 // [7:1] +#define CSD_3_CRC_M 0x7F +#define CSD_3_MMC_ECC_S 8 // [9:8] reserved for MMC compatibility +#define CSD_3_MMC_ECC_M 0x03 +#define CSD_3_FILE_FMT_S 10 // [11:10] +#define CSD_3_FILE_FMT_M 0x03 +#define CSD_3_TMP_WP_S 12 // [12:12] +#define CSD_3_TMP_WP_M 0x01 +#define CSD_3_PERM_WP_S 13 // [13:13] +#define CSD_3_PERM_WP_M 0x01 +#define CSD_3_COPY_S 14 // [14:14] +#define CSD_3_COPY_M 0x01 +#define CSD_3_FILE_FMT_GRP_S 15 // [15:15] +#define CSD_3_FILE_FMT_GRP_M 0x01 +// reserved 16 // [20:16] +// reserved 0x1F +#define CSD_3_WBLOCK_P_S 21 // [21:21] +#define CSD_3_WBLOCK_P_M 0x01 +#define CSD_3_WBLEN_S 22 // [25:22] +#define CSD_3_WBLEN_M 0x0F +#define CSD_3_R2W_F_S 26 // [28:26] +#define CSD_3_R2W_F_M 0x07 +#define CSD_3_MMC_DEF_ECC_S 29 // [30:29] reserved for MMC compatibility +#define CSD_3_MMC_DEF_ECC_M 0x03 +#define CSD_3_WP_GRP_EN_S 31 // [31:31] +#define CSD_3_WP_GRP_EN_M 0x01 + +// Seconde Response INT <=> CSD[2] : bits 32 to 63 +#define CSD_2_v21_WP_GRP_SIZE_S 0 // [38:32] +#define CSD_2_v21_WP_GRP_SIZE_M 0x7F +#define CSD_2_v21_SECT_SIZE_S 7 // [45:39] +#define CSD_2_v21_SECT_SIZE_M 0x7F +#define CSD_2_v21_ER_BLEN_EN_S 14 // [46:46] +#define CSD_2_v21_ER_BLEN_EN_M 0x01 + +#define CSD_2_v22_WP_GRP_SIZE_S 0 // [36:32] +#define CSD_2_v22_WP_GRP_SIZE_M 0x1F +#define CSD_2_v22_ER_GRP_SIZE_S 5 // [41:37] +#define CSD_2_v22_ER_GRP_SIZE_M 0x1F +#define CSD_2_v22_SECT_SIZE_S 10 // [46:42] +#define CSD_2_v22_SECT_SIZE_M 0x1F + +#define CSD_2_C_SIZE_M_S 15 // [49:47] +#define CSD_2_C_SIZE_M_M 0x07 +#define CSD_2_VDD_WMAX_S 18 // [52:50] +#define CSD_2_VDD_WMAX_M 0x07 +#define CSD_2_VDD_WMIN_S 21 // [55:53] +#define CSD_2_VDD_WMIN_M 0x07 +#define CSD_2_RCUR_MAX_S 24 // [58:56] +#define CSD_2_RCUR_MAX_M 0x07 +#define CSD_2_RCUR_MIN_S 27 // [61:59] +#define CSD_2_RCUR_MIN_M 0x07 +#define CSD_2_CSIZE_L_S 30 // [63:62] <=> 2 LSB of CSIZE +#define CSD_2_CSIZE_L_M 0x03 + +// Third Response INT <=> CSD[1] : bits 64 to 95 +#define CSD_1_CSIZE_H_S 0 // [73:64] <=> 10 MSB of CSIZE +#define CSD_1_CSIZE_H_M 0x03FF +// reserved 10 // [75:74] +// reserved 0x03 +#define CSD_1_DSR_I_S 12 // [76:76] +#define CSD_1_DSR_I_M 0x01 +#define CSD_1_RD_B_MIS_S 13 // [77:77] +#define CSD_1_RD_B_MIS_M 0x01 +#define CSD_1_WR_B_MIS_S 14 // [78:78] +#define CSD_1_WR_B_MIS_M 0x01 +#define CSD_1_RD_B_PAR_S 15 // [79:79] +#define CSD_1_RD_B_PAR_M 0x01 +#define CSD_1_RD_B_LEN_S 16 // [83:80] +#define CSD_1_RD_B_LEN_M 0x0F +#define CSD_1_CCC_S 20 // [95:84] +#define CSD_1_CCC_M 0x0FFF + +// Fourth Response INT <=> CSD[0] : bits 96 to 127 +#define CSD_0_TRANS_SPEED_S 0 // [103:96] +#define CSD_0_TRANS_SPEED_M 0xFF +#define CSD_0_NSAC_S 8 // [111:104] +#define CSD_0_NSAC_M 0xFF +#define CSD_0_TAAC_S 16 // [119:112] +#define CSD_0_TAAC_M 0xFF +// reserved 24 // [121:120] +// reserved 0x03 +#define CSD_0_MMC_SPEC_VERS_S 26 // [125:122] reserved for MMC compatibility +#define CSD_0_MMC_SPEC_VERS_M 0x0F +#define CSD_0_STRUCT_S 30 // [127:126] +#define CSD_0_STRUCT_M 0x03 + +/////////////////////////////////////////////////////////////////////////////// + void AT91F_MCI_Device_Handler(AT91PS_MciDevice,unsigned int); AT91S_MCIDeviceStatus AT91F_MCI_SDCard_Init (AT91PS_MciDevice); AT91S_MCIDeviceStatus AT91F_MCI_SetBlocklength(unsigned int); ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#5 (text+ko) ==== @@ -81,314 +81,6 @@ void *done_data; /* requestor set data */ }; -#define MMC_CMDNB (0x1Fu << 0) // Command Number -#define MMC_RSPTYP (0x3u << 6) // Response Type -#define MMC_RSPTYP_NO (0x0u << 6) // No response -#define MMC_RSPTYP_48 (0x1u << 6) // 48-bit response -#define MMC_RSPTYP_136 (0x2u << 6) // 136-bit response -#define MMC_SPCMD (0x7u << 8) // Special CMD -#define MMC_SPCMD_NONE (0x0u << 8) // Not a special CMD -#define MMC_SPCMD_INIT (0x1u << 8) // Initialization CMD -#define MMC_SPCMD_SYNC (0x2u << 8) // Synchronized CMD -#define MMC_SPCMD_IT_CMD (0x4u << 8) // Interrupt command -#define MMC_SPCMD_IT_REP (0x5u << 8) // Interrupt response -#define MMC_OPDCMD (0x1u << 11) // Open Drain Command -#define MMC_MAXLAT (0x1u << 12) // Maximum Latency for Command to respond -#define MMC_TRCMD (0x3u << 16) // Transfer CMD -#define MMC_TRCMD_NO (0x0u << 16) // No transfer -#define MMC_TRCMD_START (0x1u << 16) // Start transfer -#define MMC_TRCMD_STOP (0x2u << 16) // Stop transfer -#define MMC_TRDIR (0x1u << 18) // Transfer Direction -#define MMC_TRTYP (0x3u << 19) // Transfer Type -#define MMC_TRTYP_BLOCK (0x0u << 19) // Block Transfer type -#define MMC_TRTYP_MULTIPLE (0x1u << 19) // Multiple Block transfer type -#define MMC_TRTYP_STREAM (0x2u << 19) // Stream transfer type - -/////////////////////////////////////////////////////////////////////////////// -// MCI_CMD Register Value -/////////////////////////////////////////////////////////////////////////////// -#define POWER_ON_INIT \ - (0 | MMC_TRCMD_NO | MMC_SPCMD_INIT | MMC_OPDCMD) - -///////////////////////////////////////////////////////////////// -// Class 0 & 1 commands: Basic commands and Read Stream commands -///////////////////////////////////////////////////////////////// - -#define GO_IDLE_STATE_CMD \ - (0 | MMC_TRCMD_NO | MMC_SPCMD_NONE ) -#define MMC_GO_IDLE_STATE_CMD \ - (0 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_OPDCMD) -#define MMC_SEND_OP_COND_CMD \ - (1 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ - MMC_OPDCMD) - -#define ALL_SEND_CID_CMD \ - (2 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136) -#define MMC_ALL_SEND_CID_CMD \ - (2 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136 | \ - MMC_OPDCMD) - -#define SET_RELATIVE_ADDR_CMD \ - (3 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ - MMC_MAXLAT) -#define MMC_SET_RELATIVE_ADDR_CMD \ - (3 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ - MMC_MAXLAT | MMC_OPDCMD) - -#define SET_DSR_CMD \ - (4 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_NO | \ - MMC_MAXLAT) // no tested - -#define SEL_DESEL_CARD_CMD \ - (7 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ - MMC_MAXLAT) -#define SEND_CSD_CMD \ - (9 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136 | \ - MMC_MAXLAT) -#define SEND_CID_CMD \ - (10 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_136 | \ - MMC_MAXLAT) -#define MMC_READ_DAT_UNTIL_STOP_CMD \ - (11 | MMC_TRTYP_STREAM | MMC_SPCMD_NONE | \ - MMC_RSPTYP_48 | MMC_TRDIR | MMC_TRCMD_START | \ - MMC_MAXLAT) - -#define STOP_TRANSMISSION_CMD \ - (12 | MMC_TRCMD_STOP | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ - MMC_MAXLAT) -#define STOP_TRANSMISSION_SYNC_CMD \ - (12 | MMC_TRCMD_STOP | MMC_SPCMD_SYNC | MMC_RSPTYP_48 | \ - MMC_MAXLAT) -#define SEND_STATUS_CMD \ - (13 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | \ - MMC_MAXLAT) -#define GO_INACTIVE_STATE_CMD \ - (15 | MMC_RSPTYP_NO) - -//*------------------------------------------------ -//* Class 2 commands: Block oriented Read commands -//*------------------------------------------------ - -#define SET_BLOCKLEN_CMD (16 | MMC_TRCMD_NO | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_MAXLAT ) -#define READ_SINGLE_BLOCK_CMD (17 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | MMC_TRTYP_BLOCK | MMC_TRDIR | MMC_MAXLAT) -#define READ_MULTIPLE_BLOCK_CMD (18 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | MMC_TRTYP_MULTIPLE | MMC_TRDIR | MMC_MAXLAT) - -//*-------------------------------------------- -//* Class 3 commands: Sequential write commands -//*-------------------------------------------- - -#define MMC_WRITE_DAT_UNTIL_STOP_CMD (20 | MMC_TRTYP_STREAM| MMC_SPCMD_NONE | MMC_RSPTYP_48 & ~(MMC_TRDIR) | MMC_TRCMD_START | MMC_MAXLAT ) // MMC - -//*------------------------------------------------ -//* Class 4 commands: Block oriented write commands -//*------------------------------------------------ - -#define WRITE_BLOCK_CMD (24 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | (MMC_TRTYP_BLOCK & ~(MMC_TRDIR)) | MMC_MAXLAT) -#define WRITE_MULTIPLE_BLOCK_CMD (25 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_START | (MMC_TRTYP_MULTIPLE & ~(MMC_TRDIR)) | MMC_MAXLAT) -#define PROGRAM_CSD_CMD (27 | MMC_RSPTYP_48 ) - - -//*---------------------------------------- -//* Class 6 commands: Group Write protect -//*---------------------------------------- - -#define SET_WRITE_PROT_CMD (28 | MMC_RSPTYP_48 ) -#define CLR_WRITE_PROT_CMD (29 | MMC_RSPTYP_48 ) -#define SEND_WRITE_PROT_CMD (30 | MMC_RSPTYP_48 ) - - -//*---------------------------------------- -//* Class 5 commands: Erase commands -//*---------------------------------------- - -#define TAG_SECTOR_START_CMD (32 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define TAG_SECTOR_END_CMD (33 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define MMC_UNTAG_SECTOR_CMD (34 | MMC_RSPTYP_48 ) -#define MMC_TAG_ERASE_GROUP_START_CMD (35 | MMC_RSPTYP_48 ) -#define MMC_TAG_ERASE_GROUP_END_CMD (36 | MMC_RSPTYP_48 ) -#define MMC_UNTAG_ERASE_GROUP_CMD (37 | MMC_RSPTYP_48 ) -#define ERASE_CMD (38 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT ) - -//*---------------------------------------- -//* Class 7 commands: Lock commands -//*---------------------------------------- - -#define LOCK_UNLOCK (42 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) // no tested - -//*----------------------------------------------- -// Class 8 commands: Application specific commands -//*----------------------------------------------- - -#define APP_CMD (55 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define GEN_CMD (56 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) // no tested - -#define SDCARD_SET_BUS_WIDTH_CMD (6 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define SDCARD_STATUS_CMD (13 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define SDCARD_SEND_NUM_WR_BLOCKS_CMD (22 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define SDCARD_SET_WR_BLK_ERASE_COUNT_CMD (23 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define SDCARD_APP_OP_COND_CMD (41 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO ) -#define SDCARD_SET_CLR_CARD_DETECT_CMD (42 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) -#define SDCARD_SEND_SCR_CMD (51 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) - -#define SDCARD_APP_ALL_CMD (SDCARD_SET_BUS_WIDTH_CMD +\ - SDCARD_STATUS_CMD +\ - SDCARD_SEND_NUM_WR_BLOCKS_CMD +\ - SDCARD_SET_WR_BLK_ERASE_COUNT_CMD +\ - SDCARD_APP_OP_COND_CMD +\ - SDCARD_SET_CLR_CARD_DETECT_CMD +\ - SDCARD_SEND_SCR_CMD) - -//*---------------------------------------- -//* Class 9 commands: IO Mode commands -//*---------------------------------------- - -#define MMC_FAST_IO_CMD (39 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_MAXLAT) -#define MMC_GO_IRQ_STATE_CMD (40 | MMC_SPCMD_NONE | MMC_RSPTYP_48 | MMC_TRCMD_NO | MMC_MAXLAT) - -//////////////////////////////////////////////////////////////////////////////// -// OCR Register -//////////////////////////////////////////////////////////////////////////////// -#define AT91C_VDD_16_17 (1 << 4) -#define AT91C_VDD_17_18 (1 << 5) -#define AT91C_VDD_18_19 (1 << 6) -#define AT91C_VDD_19_20 (1 << 7) -#define AT91C_VDD_20_21 (1 << 8) -#define AT91C_VDD_21_22 (1 << 9) -#define AT91C_VDD_22_23 (1 << 10) -#define AT91C_VDD_23_24 (1 << 11) -#define AT91C_VDD_24_25 (1 << 12) -#define AT91C_VDD_25_26 (1 << 13) -#define AT91C_VDD_26_27 (1 << 14) -#define AT91C_VDD_27_28 (1 << 15) -#define AT91C_VDD_28_29 (1 << 16) -#define AT91C_VDD_29_30 (1 << 17) -#define AT91C_VDD_30_31 (1 << 18) -#define AT91C_VDD_31_32 (1 << 19) -#define AT91C_VDD_32_33 (1 << 20) -#define AT91C_VDD_33_34 (1 << 21) -#define AT91C_VDD_34_35 (1 << 22) -#define AT91C_VDD_35_36 (1 << 23) -#define AT91C_CARD_POWER_UP_BUSY (1 << 31) - -#define AT91C_MMC_HOST_VOLTAGE_RANGE (AT91C_VDD_27_28 | AT91C_VDD_28_29 | \ - AT91C_VDD_29_30 | AT91C_VDD_30_31 | AT91C_VDD_31_32 | AT91C_VDD_32_33) - -//////////////////////////////////////////////////////////////////////////////// -// CURRENT_STATE & READY_FOR_DATA in SDCard Status Register definition (response type R1) -//////////////////////////////////////////////////////////////////////////////// -#define AT91C_SR_READY_FOR_DATA (1 << 8) // corresponds to buffer empty signalling on the bus -#define AT91C_SR_IDLE (0 << 9) -#define AT91C_SR_READY (1 << 9) -#define AT91C_SR_IDENT (2 << 9) -#define AT91C_SR_STBY (3 << 9) -#define AT91C_SR_TRAN (4 << 9) -#define AT91C_SR_DATA (5 << 9) -#define AT91C_SR_RCV (6 << 9) -#define AT91C_SR_PRG (7 << 9) -#define AT91C_SR_DIS (8 << 9) - -#define AT91C_SR_CARD_SELECTED (AT91C_SR_READY_FOR_DATA + AT91C_SR_TRAN) - -#define MMC_FIRST_RCA 0xCAFE - -//////////////////////////////////////////////////////////////////////////////// -// MMC CSD register header File -// CSD_x_xxx_S for shift value for word x -// CSD_x_xxx_M for mask value for word x -//////////////////////////////////////////////////////////////////////////////// - -// First Response INT <=> CSD[3] : bits 0 to 31 -#define CSD_3_BIT0_S 0 // [0:0] -#define CSD_3_BIT0_M 0x01 -#define CSD_3_CRC_S 1 // [7:1] -#define CSD_3_CRC_M 0x7F -#define CSD_3_MMC_ECC_S 8 // [9:8] reserved for MMC compatibility -#define CSD_3_MMC_ECC_M 0x03 -#define CSD_3_FILE_FMT_S 10 // [11:10] -#define CSD_3_FILE_FMT_M 0x03 -#define CSD_3_TMP_WP_S 12 // [12:12] -#define CSD_3_TMP_WP_M 0x01 -#define CSD_3_PERM_WP_S 13 // [13:13] -#define CSD_3_PERM_WP_M 0x01 -#define CSD_3_COPY_S 14 // [14:14] -#define CSD_3_COPY_M 0x01 -#define CSD_3_FILE_FMT_GRP_S 15 // [15:15] -#define CSD_3_FILE_FMT_GRP_M 0x01 -// reserved 16 // [20:16] -// reserved 0x1F -#define CSD_3_WBLOCK_P_S 21 // [21:21] -#define CSD_3_WBLOCK_P_M 0x01 -#define CSD_3_WBLEN_S 22 // [25:22] -#define CSD_3_WBLEN_M 0x0F -#define CSD_3_R2W_F_S 26 // [28:26] -#define CSD_3_R2W_F_M 0x07 -#define CSD_3_MMC_DEF_ECC_S 29 // [30:29] reserved for MMC compatibility -#define CSD_3_MMC_DEF_ECC_M 0x03 -#define CSD_3_WP_GRP_EN_S 31 // [31:31] -#define CSD_3_WP_GRP_EN_M 0x01 - -// Seconde Response INT <=> CSD[2] : bits 32 to 63 -#define CSD_2_v21_WP_GRP_SIZE_S 0 // [38:32] -#define CSD_2_v21_WP_GRP_SIZE_M 0x7F -#define CSD_2_v21_SECT_SIZE_S 7 // [45:39] -#define CSD_2_v21_SECT_SIZE_M 0x7F -#define CSD_2_v21_ER_BLEN_EN_S 14 // [46:46] -#define CSD_2_v21_ER_BLEN_EN_M 0x01 - -#define CSD_2_v22_WP_GRP_SIZE_S 0 // [36:32] -#define CSD_2_v22_WP_GRP_SIZE_M 0x1F -#define CSD_2_v22_ER_GRP_SIZE_S 5 // [41:37] -#define CSD_2_v22_ER_GRP_SIZE_M 0x1F -#define CSD_2_v22_SECT_SIZE_S 10 // [46:42] -#define CSD_2_v22_SECT_SIZE_M 0x1F - -#define CSD_2_C_SIZE_M_S 15 // [49:47] -#define CSD_2_C_SIZE_M_M 0x07 -#define CSD_2_VDD_WMAX_S 18 // [52:50] -#define CSD_2_VDD_WMAX_M 0x07 -#define CSD_2_VDD_WMIN_S 21 // [55:53] -#define CSD_2_VDD_WMIN_M 0x07 -#define CSD_2_RCUR_MAX_S 24 // [58:56] -#define CSD_2_RCUR_MAX_M 0x07 -#define CSD_2_RCUR_MIN_S 27 // [61:59] -#define CSD_2_RCUR_MIN_M 0x07 -#define CSD_2_CSIZE_L_S 30 // [63:62] <=> 2 LSB of CSIZE -#define CSD_2_CSIZE_L_M 0x03 - -// Third Response INT <=> CSD[1] : bits 64 to 95 -#define CSD_1_CSIZE_H_S 0 // [73:64] <=> 10 MSB of CSIZE -#define CSD_1_CSIZE_H_M 0x03FF -// reserved 10 // [75:74] -// reserved 0x03 -#define CSD_1_DSR_I_S 12 // [76:76] -#define CSD_1_DSR_I_M 0x01 -#define CSD_1_RD_B_MIS_S 13 // [77:77] -#define CSD_1_RD_B_MIS_M 0x01 -#define CSD_1_WR_B_MIS_S 14 // [78:78] -#define CSD_1_WR_B_MIS_M 0x01 -#define CSD_1_RD_B_PAR_S 15 // [79:79] -#define CSD_1_RD_B_PAR_M 0x01 -#define CSD_1_RD_B_LEN_S 16 // [83:80] -#define CSD_1_RD_B_LEN_M 0x0F -#define CSD_1_CCC_S 20 // [95:84] -#define CSD_1_CCC_M 0x0FFF - -// Fourth Response INT <=> CSD[0] : bits 96 to 127 -#define CSD_0_TRANS_SPEED_S 0 // [103:96] -#define CSD_0_TRANS_SPEED_M 0xFF -#define CSD_0_NSAC_S 8 // [111:104] -#define CSD_0_NSAC_M 0xFF -#define CSD_0_TAAC_S 16 // [119:112] -#define CSD_0_TAAC_M 0xFF -// reserved 24 // [121:120] -// reserved 0x03 -#define CSD_0_MMC_SPEC_VERS_S 26 // [125:122] reserved for MMC compatibility -#define CSD_0_MMC_SPEC_VERS_M 0x0F -#define CSD_0_STRUCT_S 30 // [127:126] -#define CSD_0_STRUCT_M 0x03 - -//////////////////////////////////////////////////////////////////////////////// - /* OCR bits */ #define MMC_OCR_145_150 (1U << 0) /* Vdd voltage 1.45 ~ 1.50 */ #define MMC_OCR_150_155 (1U << 1) /* Vdd voltage 1.50 ~ 1.50 */ From owner-p4-projects@FreeBSD.ORG Tue Sep 26 18:48:06 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 4D7C916A417; Tue, 26 Sep 2006 18:48:06 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 24EF516A403 for ; Tue, 26 Sep 2006 18:48:06 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: from wx-out-0506.google.com (wx-out-0506.google.com [66.249.82.239]) by mx1.FreeBSD.org (Postfix) with ESMTP id C085543D93 for ; Tue, 26 Sep 2006 18:47:47 +0000 (GMT) (envelope-from asmrookie@gmail.com) Received: by wx-out-0506.google.com with SMTP id i27so2321535wxd for ; Tue, 26 Sep 2006 11:47:47 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:sender:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=ihb0an4UcNxN9RoJ0DGFnpe/K63xFzb7iDWQom7VGMxLCH7Jo15Xk7D0dApoJ2jGxdlmOQmVN/9xMlJhr5RoT3KqePDR9jkRxIKKTJykxbtgDW8waH7yGrUYo17FXfMYUUKBsodsTQsu3ypJf1iUwnGU47prQNtGh0G18UslXVE= Received: by 10.70.118.4 with SMTP id q4mr1256064wxc; Tue, 26 Sep 2006 11:47:47 -0700 (PDT) Received: by 10.70.37.19 with HTTP; Tue, 26 Sep 2006 11:47:47 -0700 (PDT) Message-ID: <3bbf2fe10609261147k146be9cah2e008735d29af852@mail.gmail.com> Date: Tue, 26 Sep 2006 20:47:47 +0200 From: "Attilio Rao" Sender: asmrookie@gmail.com To: "Sam Leffler" In-Reply-To: <45196D98.7020803@errno.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <45196D98.7020803@errno.com> X-Google-Sender-Auth: a70c8468dac9aacf Cc: perforce@freebsd.org Subject: Re: [Fwd: PERFORCE change 106715 for review] X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 18:48:06 -0000 2006/9/26, Sam Leffler : > > > > > > -------- Original Message -------- > > Subject: PERFORCE change 106715 for review > > Date: Tue, 26 Sep 2006 12:24:36 GMT > > From: Attilio Rao > > To: Perforce Change Reviews > > > > http://perforce.freebsd.org/chv.cgi?CH=106715 > > > > Change 106715 by attilio@attilio_laptop on 2006/09/26 12:24:02 > > > > It applies style(9) for header. This is a starting point for a complete > > style(9)-ization of USB new stack. > > > > Can someone please fill me in on what's going on? I've been heckling > Hans about making gratuitous changes to the "new usb stack" before it > goes into cvs and now Attilio comes along and smacks the code. Are > folks sufficiently comfortable with the code that they don't care about > being able to track work on other BSD systems and/or compare the code > against what is currently in CVS? (which was the point of my original > complaints). > > I will happily shut up if this has all been hammered out... Well, first of all, maybe you would cc other people (me, tom@ and imp@) that are currently working on this branch about your ideas on USB changes (since in the way you did I'm completely obscure of discussions between you and hans about this...). Than, it is unclear how USB stack might (and please I would point out the word 'might') be included into the kernel. Since the new stack is reasonably different from the previous I assume it might be replaced totally after a good testing period respect a gradual inclusion. In this view, since Hans' code completely miss style(9), I was only stylizing the code. If there is something unclear please mail me. Attilio -- Peace can only be achieved by understanding - A. Einstein From owner-p4-projects@FreeBSD.ORG Tue Sep 26 20:50:34 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B73E516A47C; Tue, 26 Sep 2006 20:50:33 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 6ACB816A417 for ; Tue, 26 Sep 2006 20:50:33 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 70A3843D5A for ; Tue, 26 Sep 2006 20:50:32 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QKoWsN081642 for ; Tue, 26 Sep 2006 20:50:32 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QKoPZC081623 for perforce@freebsd.org; Tue, 26 Sep 2006 20:50:25 GMT (envelope-from piso@freebsd.org) Date: Tue, 26 Sep 2006 20:50:25 GMT Message-Id: <200609262050.k8QKoPZC081623@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 106743 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 20:50:34 -0000 http://perforce.freebsd.org/chv.cgi?CH=106743 Change 106743 by piso@piso_newluxor on 2006/09/26 20:49:27 IFC@106742 Affected files ... .. //depot/projects/soc2005/libalias/ObsoleteFiles.inc#6 integrate .. //depot/projects/soc2005/libalias/bin/df/df.c#3 integrate .. //depot/projects/soc2005/libalias/contrib/gcc/cccp.1#2 delete .. //depot/projects/soc2005/libalias/contrib/gcc/cpp.1#2 delete .. //depot/projects/soc2005/libalias/contrib/gcc/doc/cpp.1#2 integrate .. //depot/projects/soc2005/libalias/contrib/gcc/doc/gcc.1#2 integrate .. //depot/projects/soc2005/libalias/contrib/gcc/doc/gcov.1#2 integrate .. //depot/projects/soc2005/libalias/contrib/gcc/gcc.1#2 delete .. //depot/projects/soc2005/libalias/contrib/openbsm/HISTORY#5 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/TODO#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/VERSION#4 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/audit/audit.c#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/auditd/audit_warn.c#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/auditd/auditd.8#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/auditd/auditd.c#4 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/auditd/auditd.h#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/auditreduce/auditreduce.1#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/auditreduce/auditreduce.c#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bin/auditreduce/auditreduce.h#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/bsm/libbsm.h#4 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/compat/strlcat.h#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/config/config.h#3 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/config/config.h.in#3 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/configure#5 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/configure.ac#5 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/etc/audit_control#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/etc/audit_event#4 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/libbsm/au_control.3#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/libbsm/au_open.3#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/libbsm/bsm_control.c#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/libbsm/bsm_io.c#3 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/libbsm/bsm_token.c#6 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/libbsm/libbsm.3#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/man/audit_control.5#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/man/auditon.2#2 integrate .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/arg32_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/arg32_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/data_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/data_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/file_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/file_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/header32_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/in_addr_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/in_addr_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/ip_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/ip_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/ipc_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/ipc_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/iport_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/iport_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/opaque_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/opaque_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/path_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/path_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/process32_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/process32_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/process32ex_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/process32ex_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/return32_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/return32_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/seq_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/seq_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/subject32_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/subject32_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/subject32ex_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/subject32ex_token-IPv4#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/subject32ex_token-IPv6#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/text_record#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/text_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/reference/trailer_token#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/test/samples/execve-long-args.trail#1 branch .. //depot/projects/soc2005/libalias/contrib/openbsm/tools/audump.c#2 integrate .. //depot/projects/soc2005/libalias/etc/defaults/rc.conf#6 integrate .. //depot/projects/soc2005/libalias/etc/network.subr#3 integrate .. //depot/projects/soc2005/libalias/etc/pccard_ether#3 integrate .. //depot/projects/soc2005/libalias/etc/rc.d/auditd#2 integrate .. //depot/projects/soc2005/libalias/etc/rc.d/devd#2 integrate .. //depot/projects/soc2005/libalias/gnu/lib/libstdc++/config.h#2 integrate .. //depot/projects/soc2005/libalias/gnu/usr.bin/cc/cc/Makefile#2 integrate .. //depot/projects/soc2005/libalias/gnu/usr.bin/cc/cc_tools/freebsd-native.h#2 integrate .. //depot/projects/soc2005/libalias/gnu/usr.bin/cc/cpp/Makefile#3 integrate .. //depot/projects/soc2005/libalias/lib/libbsm/Makefile#4 integrate .. //depot/projects/soc2005/libalias/lib/libc/isc/eventlib_p.h#2 integrate .. //depot/projects/soc2005/libalias/lib/libc/stdio/vfprintf.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libc/stdio/vfwprintf.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libc/stdlib/getopt_long.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libc/sys/Symbol.map#3 integrate .. //depot/projects/soc2005/libalias/lib/libc/sys/aio_error.2#2 integrate .. //depot/projects/soc2005/libalias/lib/libkvm/kvm.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libncp/ncpl_file.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libncp/ncpl_misc.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libncp/ncpl_msg.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libncp/ncpl_nls.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libncp/ncpl_queue.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libncp/ncpl_rpc.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libthr/thread/thr_create.c#4 integrate .. //depot/projects/soc2005/libalias/lib/libthr/thread/thr_getschedparam.c#3 integrate .. //depot/projects/soc2005/libalias/lib/libthr/thread/thr_init.c#6 integrate .. //depot/projects/soc2005/libalias/lib/libthr/thread/thr_kern.c#2 integrate .. //depot/projects/soc2005/libalias/lib/libthr/thread/thr_private.h#6 integrate .. //depot/projects/soc2005/libalias/lib/libthr/thread/thr_setprio.c#4 integrate .. //depot/projects/soc2005/libalias/lib/libthr/thread/thr_setschedparam.c#4 integrate .. //depot/projects/soc2005/libalias/libexec/rtld-elf/rtld.c#6 integrate .. //depot/projects/soc2005/libalias/sbin/dhclient/bpf.c#2 integrate .. //depot/projects/soc2005/libalias/sbin/ifconfig/af_inet6.c#2 integrate .. //depot/projects/soc2005/libalias/sbin/ifconfig/ifconfig.c#4 integrate .. //depot/projects/soc2005/libalias/share/man/man4/bge.4#2 integrate .. //depot/projects/soc2005/libalias/share/man/man4/divert.4#2 integrate .. //depot/projects/soc2005/libalias/share/man/man9/Makefile#3 integrate .. //depot/projects/soc2005/libalias/share/man/man9/config_intrhook.9#1 branch .. //depot/projects/soc2005/libalias/sys/amd64/conf/GENERIC#3 integrate .. //depot/projects/soc2005/libalias/sys/amd64/conf/NOTES#4 integrate .. //depot/projects/soc2005/libalias/sys/amd64/ia32/ia32_sigtramp.S#2 integrate .. //depot/projects/soc2005/libalias/sys/amd64/include/stdarg.h#2 integrate .. //depot/projects/soc2005/libalias/sys/amd64/isa/atpic_vector.S#2 integrate .. //depot/projects/soc2005/libalias/sys/arm/include/stdarg.h#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/pc98/boot2/inode.h#2 integrate .. //depot/projects/soc2005/libalias/sys/bsm/audit.h#3 integrate .. //depot/projects/soc2005/libalias/sys/bsm/audit_internal.h#4 integrate .. //depot/projects/soc2005/libalias/sys/bsm/audit_kevents.h#4 integrate .. //depot/projects/soc2005/libalias/sys/bsm/audit_record.h#5 integrate .. //depot/projects/soc2005/libalias/sys/compat/freebsd32/freebsd32.h#3 integrate .. //depot/projects/soc2005/libalias/sys/compat/freebsd32/freebsd32_misc.c#4 integrate .. //depot/projects/soc2005/libalias/sys/compat/freebsd32/freebsd32_proto.h#8 integrate .. //depot/projects/soc2005/libalias/sys/compat/freebsd32/freebsd32_syscall.h#8 integrate .. //depot/projects/soc2005/libalias/sys/compat/freebsd32/freebsd32_syscalls.c#8 integrate .. //depot/projects/soc2005/libalias/sys/compat/freebsd32/freebsd32_sysent.c#8 integrate .. //depot/projects/soc2005/libalias/sys/compat/freebsd32/syscalls.master#8 integrate .. //depot/projects/soc2005/libalias/sys/compat/linux/linux_file.c#4 integrate .. //depot/projects/soc2005/libalias/sys/compat/linux/linux_socket.c#3 integrate .. //depot/projects/soc2005/libalias/sys/conf/NOTES#7 integrate .. //depot/projects/soc2005/libalias/sys/conf/files#8 integrate .. //depot/projects/soc2005/libalias/sys/conf/files.amd64#6 integrate .. //depot/projects/soc2005/libalias/sys/conf/files.i386#5 integrate .. //depot/projects/soc2005/libalias/sys/conf/options#6 integrate .. //depot/projects/soc2005/libalias/sys/dev/acpica/Osd/OsdHardware.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/acpica/acpi.c#4 integrate .. //depot/projects/soc2005/libalias/sys/dev/ata/ata-chipset.c#8 integrate .. //depot/projects/soc2005/libalias/sys/dev/bce/if_bce.c#5 integrate .. //depot/projects/soc2005/libalias/sys/dev/bge/if_bge.c#9 integrate .. //depot/projects/soc2005/libalias/sys/dev/em/if_em.c#10 integrate .. //depot/projects/soc2005/libalias/sys/dev/exca/exca.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_acpi.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_isa.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_kcs.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_pci.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_smbios.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_smbus.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_smic.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmi_ssif.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/ipmi/ipmivars.h#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/isp/isp_freebsd.c#5 integrate .. //depot/projects/soc2005/libalias/sys/dev/isp/isp_freebsd.h#4 integrate .. //depot/projects/soc2005/libalias/sys/dev/kbdmux/kbdmux.c#4 integrate .. //depot/projects/soc2005/libalias/sys/dev/mfi/mfi.c#4 integrate .. //depot/projects/soc2005/libalias/sys/dev/mfi/mfi_debug.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/mfi/mfivar.h#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/mpt/mpt_cam.c#4 integrate .. //depot/projects/soc2005/libalias/sys/dev/pci/pci.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/smbus/smb.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/buffer.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/buffer.h#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/channel.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/channel.h#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/channel_if.m#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/dsp.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/dsp.h#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/mixer.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/mixer.h#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/sound.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/sound.h#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/usb/if_cdce.c#3 integrate .. //depot/projects/soc2005/libalias/sys/fs/devfs/devfs_vfsops.c#4 integrate .. //depot/projects/soc2005/libalias/sys/fs/hpfs/hpfs_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/fs/msdosfs/msdosfs_vfsops.c#3 integrate .. //depot/projects/soc2005/libalias/sys/fs/ntfs/ntfs_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/fs/nullfs/null_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/fs/nwfs/nwfs_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/fs/portalfs/portal_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/fs/smbfs/smbfs_vfsops.c#3 integrate .. //depot/projects/soc2005/libalias/sys/fs/udf/udf_vfsops.c#3 integrate .. //depot/projects/soc2005/libalias/sys/fs/umapfs/umap_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/fs/unionfs/union_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/gnu/fs/ext2fs/ext2_inode.c#2 integrate .. //depot/projects/soc2005/libalias/sys/gnu/fs/ext2fs/ext2_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/gnu/fs/reiserfs/reiserfs_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/i386/conf/GENERIC#3 integrate .. //depot/projects/soc2005/libalias/sys/i386/conf/NOTES#5 integrate .. //depot/projects/soc2005/libalias/sys/i386/i386/busdma_machdep.c#3 integrate .. //depot/projects/soc2005/libalias/sys/i386/include/stdarg.h#2 integrate .. //depot/projects/soc2005/libalias/sys/i386/isa/atpic_vector.s#2 integrate .. //depot/projects/soc2005/libalias/sys/i386/linux/linux_machdep.c#5 integrate .. //depot/projects/soc2005/libalias/sys/i386/linux/linux_proto.h#6 integrate .. //depot/projects/soc2005/libalias/sys/i386/linux/linux_syscall.h#6 integrate .. //depot/projects/soc2005/libalias/sys/i386/linux/linux_sysent.c#6 integrate .. //depot/projects/soc2005/libalias/sys/i386/linux/syscalls.master#6 integrate .. //depot/projects/soc2005/libalias/sys/ia64/conf/GENERIC#3 integrate .. //depot/projects/soc2005/libalias/sys/ia64/include/stdarg.h#2 integrate .. //depot/projects/soc2005/libalias/sys/isofs/cd9660/cd9660_vfsops.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/init_main.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/init_sysent.c#8 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_descrip.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_event.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_mac.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_proc.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_resource.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_thr.c#5 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_umtx.c#6 integrate .. //depot/projects/soc2005/libalias/sys/kern/syscalls.c#8 integrate .. //depot/projects/soc2005/libalias/sys/kern/syscalls.master#9 integrate .. //depot/projects/soc2005/libalias/sys/kern/systrace_args.c#5 integrate .. //depot/projects/soc2005/libalias/sys/kern/sysv_msg.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/sysv_sem.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/sysv_shm.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/tty.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/tty_pty.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/tty_tty.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/uipc_mbuf.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/uipc_mqueue.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/uipc_socket.c#6 integrate .. //depot/projects/soc2005/libalias/sys/kern/vfs_aio.c#4 integrate .. //depot/projects/soc2005/libalias/sys/kern/vfs_cluster.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/vfs_default.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/vfs_export.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/vfs_mount.c#5 integrate .. //depot/projects/soc2005/libalias/sys/kern/vfs_subr.c#5 integrate .. //depot/projects/soc2005/libalias/sys/kern/vfs_syscalls.c#6 integrate .. //depot/projects/soc2005/libalias/sys/modules/ipmi/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/modules/mfi/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/modules/wlan/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/net/if_bridge.c#9 integrate .. //depot/projects/soc2005/libalias/sys/net/if_loop.c#3 integrate .. //depot/projects/soc2005/libalias/sys/net80211/ieee80211_ioctl.c#4 integrate .. //depot/projects/soc2005/libalias/sys/netinet/if_ether.c#3 integrate .. //depot/projects/soc2005/libalias/sys/netinet/in_var.h#2 integrate .. //depot/projects/soc2005/libalias/sys/netinet/ip_carp.c#3 integrate .. //depot/projects/soc2005/libalias/sys/netinet/ip_output.c#5 integrate .. //depot/projects/soc2005/libalias/sys/netinet/ip_var.h#2 integrate .. //depot/projects/soc2005/libalias/sys/netinet/tcp_input.c#5 integrate .. //depot/projects/soc2005/libalias/sys/netinet/tcp_timer.h#4 integrate .. //depot/projects/soc2005/libalias/sys/netinet6/in6.c#4 integrate .. //depot/projects/soc2005/libalias/sys/nfsclient/nfs_vfsops.c#4 integrate .. //depot/projects/soc2005/libalias/sys/nfsclient/nfs_vnops.c#4 integrate .. //depot/projects/soc2005/libalias/sys/pc98/conf/GENERIC#3 integrate .. //depot/projects/soc2005/libalias/sys/powerpc/conf/GENERIC#5 integrate .. //depot/projects/soc2005/libalias/sys/powerpc/include/stdarg.h#2 integrate .. //depot/projects/soc2005/libalias/sys/security/audit/audit_bsm.c#7 integrate .. //depot/projects/soc2005/libalias/sys/security/audit/audit_bsm_token.c#4 integrate .. //depot/projects/soc2005/libalias/sys/security/audit/audit_worker.c#3 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_inet.c#3 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_internal.h#3 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_net.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_pipe.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_posix_sem.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_process.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_socket.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_sysv_msg.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_sysv_sem.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_sysv_shm.c#2 integrate .. //depot/projects/soc2005/libalias/sys/security/mac/mac_vfs.c#3 integrate .. //depot/projects/soc2005/libalias/sys/sparc64/conf/GENERIC#3 integrate .. //depot/projects/soc2005/libalias/sys/sparc64/include/stdarg.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sparc64/sparc64/pmap.c#3 integrate .. //depot/projects/soc2005/libalias/sys/sparc64/sparc64/tsb.c#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/cdefs.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/copyright.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/event.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/ipmi.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/mbuf.h#5 integrate .. //depot/projects/soc2005/libalias/sys/sys/mount.h#3 integrate .. //depot/projects/soc2005/libalias/sys/sys/param.h#7 integrate .. //depot/projects/soc2005/libalias/sys/sys/rtprio.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/soundcard.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/syscall.h#8 integrate .. //depot/projects/soc2005/libalias/sys/sys/syscall.mk#8 integrate .. //depot/projects/soc2005/libalias/sys/sys/sysproto.h#8 integrate .. //depot/projects/soc2005/libalias/sys/sys/thr.h#3 integrate .. //depot/projects/soc2005/libalias/sys/sys/umtx.h#4 integrate .. //depot/projects/soc2005/libalias/sys/ufs/ffs/ffs_snapshot.c#3 integrate .. //depot/projects/soc2005/libalias/sys/ufs/ffs/ffs_softdep.c#2 integrate .. //depot/projects/soc2005/libalias/sys/ufs/ffs/ffs_vfsops.c#3 integrate .. //depot/projects/soc2005/libalias/sys/ufs/ufs/inode.h#2 integrate .. //depot/projects/soc2005/libalias/sys/ufs/ufs/ufs_quota.c#3 integrate .. //depot/projects/soc2005/libalias/tools/tools/README#2 integrate .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/CHANGES#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/README#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/bridge/TINYBSD#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/bridge/etc/fstab#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/bridge/etc/rc.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/bridge/etc/sysctl.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/bridge/tinybsd.basefiles#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/default/TINYBSD#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/default/etc/fstab#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/default/etc/rc.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/default/tinybsd.basefiles#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/TINYBSD#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/authpf/authpf.rules#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/fstab#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/natd.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/pf.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/pf.os#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/rc.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/rc.firewall#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/etc/sysctl.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/firewall/tinybsd.basefiles#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/minimal/TINYBSD#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/minimal/etc/fstab#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/minimal/etc/rc.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/minimal/tinybsd.basefiles#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/vpn/TINYBSD#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/vpn/etc/fstab#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/vpn/etc/rc.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/vpn/etc/setkey.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/vpn/tinybsd.basefiles#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/TINYBSD#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/etc/authpf/authpf.rules#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/etc/fstab#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/etc/natd.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/etc/pf.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/etc/pf.os#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/etc/rc.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/etc/rc.firewall#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wireless/tinybsd.basefiles#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wrap/TINYBSD#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wrap/etc/fstab#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wrap/etc/rc.conf#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wrap/etc/ttys#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/conf/wrap/tinybsd.basefiles#1 branch .. //depot/projects/soc2005/libalias/tools/tools/tinybsd/tinybsd#1 branch .. //depot/projects/soc2005/libalias/usr.bin/chpass/chpass.c#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/column/column.c#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/id/Makefile#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/id/id.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/id/id.c#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/netstat/inet.c#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/xlint/xlint/xlint.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/IPXrouted/main.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/auditreduce/Makefile#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/authpf/Makefile#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/bthidd/client.c#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/bthidd/parser.y#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/bthidd/server.c#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/hccontrol/hccontrol.h#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/hccontrol/link_control.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/hccontrol/util.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/hcsecd/hcsecd.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/rfcomm_pppd/rfcomm_pppd.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/bluetooth/sdpd/server.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/cron/lib/entry.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/ndiscvt/ndiscvt.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/ngctl/msg.c#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/pkg_install/add/main.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/rip6query/rip6query.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/sendmail/Makefile#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/Makefile#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/tcpslice/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/tcpslice/gwtm2secs.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/tcpslice/search.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/tcpslice/tcpslice.1#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/tcpslice/tcpslice.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/tcpslice/tcpslice.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/tcpdump/tcpslice/util.c#2 delete Differences ... ==== //depot/projects/soc2005/libalias/ObsoleteFiles.inc#6 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/ObsoleteFiles.inc,v 1.50 2006/09/05 01:17:51 matusita Exp $ +# $FreeBSD: src/ObsoleteFiles.inc,v 1.51 2006/09/24 10:57:34 simon Exp $ # # This file lists old files (OLD_FILES), libraries (OLD_LIBS) and # directories (OLD_DIRS) which should get removed at an update. Recently @@ -14,6 +14,9 @@ # The file is partitioned: OLD_FILES first, then OLD_LIBS and OLD_DIRS last. # +# 20060924: tcpslice removed +OLD_FILES+=usr/sbin/tcpslice +OLD_FILES+=usr/share/man/man1/tcpslice.1.gz # 20060822: ramdisk{,-own} have been replaced by mdconfig{,2} OLD_FILES+=etc/rc.d/ramdisk OLD_FILES+=etc/rc.d/ramdisk-own ==== //depot/projects/soc2005/libalias/bin/df/df.c#3 (text+ko) ==== @@ -44,7 +44,7 @@ #endif /* not lint */ #endif #include -__FBSDID("$FreeBSD: src/bin/df/df.c,v 1.65 2006/08/20 06:32:40 imp Exp $"); +__FBSDID("$FreeBSD: src/bin/df/df.c,v 1.66 2006/09/20 20:55:02 csjp Exp $"); #include #include @@ -93,7 +93,7 @@ return (a > b ? a : b); } -static int aflag = 0, cflag, hflag, iflag, nflag; +static int aflag = 0, cflag, hflag, iflag, kflag, nflag; static struct ufs_args mdev; int @@ -123,6 +123,14 @@ case 'b': /* FALLTHROUGH */ case 'P': + /* + * POSIX specifically discusses the the behavior of + * both -k and -P. It states that the blocksize should + * be set to 1024. Thus, if this occurs, simply break + * rather than clobbering the old blocksize. + */ + if (kflag) + break; putenv("BLOCKSIZE=512"); hflag = 0; break; @@ -143,7 +151,8 @@ iflag = 1; break; case 'k': - putenv("BLOCKSIZE=1k"); + kflag++; + putenv("BLOCKSIZE=1024"); hflag = 0; break; case 'l': ==== //depot/projects/soc2005/libalias/contrib/gcc/doc/cpp.1#2 (text+ko) ==== @@ -1,8 +1,7 @@ -.\" Automatically generated by Pod::Man version 1.15 -.\" Wed Feb 5 03:13:55 2003 +.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14 .\" .\" Standard preamble: -.\" ====================================================================== +.\" ======================================================================== .de Sh \" Subsection heading .br .if t .Sp @@ -15,12 +14,6 @@ .if t .sp .5v .if n .sp .. -.de Ip \" List item -.br -.ie \\n(.$>=3 .ne \\$3 -.el .ne 3 -.IP "\\$1" \\$2 -.. .de Vb \" Begin verbatim text .ft CW .nf @@ -28,15 +21,14 @@ .. .de Ve \" End verbatim text .ft R - .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. | will give a -.\" real vertical bar. \*(C+ will give a nicer C++. Capital omega is used -.\" to do unbreakable dashes and therefore won't be available. \*(C` and -.\" \*(C' expand to `' in nroff, nothing in troff, for use with C<> +.\" real vertical bar. \*(C+ will give a nicer C++. Capital omega is used to +.\" do unbreakable dashes and therefore won't be available. \*(C` and \*(C' +.\" expand to `' in nroff, nothing in troff, for use with C<>. .tr \(*W-|\(bv\*(Tr .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ @@ -56,10 +48,10 @@ . ds R" '' 'br\} .\" -.\" If the F register is turned on, we'll generate index entries on stderr -.\" for titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and -.\" index entries marked with X<> in POD. Of course, you'll have to process -.\" the output yourself in some meaningful fashion. +.\" If the F register is turned on, we'll generate index entries on stderr for +.\" titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and index +.\" entries marked with X<> in POD. Of course, you'll have to process the +.\" output yourself in some meaningful fashion. .if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" @@ -68,14 +60,13 @@ . rr F .\} .\" -.\" For nroff, turn off justification. Always turn off hyphenation; it -.\" makes way too many mistakes in technical documents. +.\" For nroff, turn off justification. Always turn off hyphenation; it makes +.\" way too many mistakes in technical documents. .hy 0 .if n .na .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. -.bd B 3 . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 @@ -135,11 +126,10 @@ . ds Ae AE .\} .rm #[ #] #H #V #F C -.\" ====================================================================== +.\" ======================================================================== .\" .IX Title "CPP 1" -.TH CPP 1 "gcc-3.2.2" "2003-02-05" "GNU" -.UC +.TH CPP 1 "2006-03-06" "gcc-3.4.6" "GNU" .SH "NAME" cpp \- The C Preprocessor .SH "SYNOPSIS" @@ -147,7 +137,9 @@ cpp [\fB\-D\fR\fImacro\fR[=\fIdefn\fR]...] [\fB\-U\fR\fImacro\fR] [\fB\-I\fR\fIdir\fR...] [\fB\-W\fR\fIwarn\fR...] [\fB\-M\fR|\fB\-MM\fR] [\fB\-MG\fR] [\fB\-MF\fR \fIfilename\fR] - [\fB\-MP\fR] [\fB\-MQ\fR \fItarget\fR...] [\fB\-MT\fR \fItarget\fR...] + [\fB\-MP\fR] [\fB\-MQ\fR \fItarget\fR...] + [\fB\-MT\fR \fItarget\fR...] + [\fB\-P\fR] [\fB\-fno\-working\-directory\fR] [\fB\-x\fR \fIlanguage\fR] [\fB\-std=\fR\fIstandard\fR] \fIinfile\fR \fIoutfile\fR .PP @@ -166,12 +158,12 @@ rules. For example, apostrophes will be interpreted as the beginning of character constants, and cause errors. Also, you cannot rely on it preserving characteristics of the input which are not significant to -C-family languages. If a Makefile is preprocessed, all the hard tabs +C\-family languages. If a Makefile is preprocessed, all the hard tabs will be removed, and the Makefile will not work. .PP Having said that, you can often get away with using cpp on things which are not C. Other Algol-ish programming languages are often safe -(Pascal, Ada, etc.) So is assembly, with caution. \fB\-traditional\fR +(Pascal, Ada, etc.) So is assembly, with caution. \fB\-traditional\-cpp\fR mode preserves more white space, and is otherwise more permissive. Many of the problems can be avoided by writing C or \*(C+ style comments instead of native language comments, and keeping macros simple. @@ -191,6 +183,16 @@ you should use the \fB\-std=c89\fR or \fB\-std=c99\fR options, depending on which version of the standard you want. To get all the mandatory diagnostics, you must also use \fB\-pedantic\fR. +.PP +This manual describes the behavior of the \s-1ISO\s0 preprocessor. To +minimize gratuitous differences, where the \s-1ISO\s0 preprocessor's +behavior does not conflict with traditional semantics, the +traditional preprocessor should behave the same way. The various +differences that do exist are detailed in the section \fBTraditional +Mode\fR. +.PP +For clarity, unless noted otherwise, references to \fB\s-1CPP\s0\fR in this +manual refer to \s-1GNU\s0 \s-1CPP\s0. .SH "OPTIONS" .IX Header "OPTIONS" The C preprocessor expects two file names as arguments, \fIinfile\fR and @@ -198,10 +200,10 @@ other files it specifies with \fB#include\fR. All the output generated by the combined input files is written in \fIoutfile\fR. .PP -Either \fIinfile\fR or \fIoutfile\fR may be \fB-\fR, which as +Either \fIinfile\fR or \fIoutfile\fR may be \fB\-\fR, which as \&\fIinfile\fR means to read from standard input and as \fIoutfile\fR means to write to standard output. Also, if either file is omitted, it -means the same as if \fB-\fR had been specified for that file. +means the same as if \fB\-\fR had been specified for that file. .PP Unless otherwise noted, or the option ends in \fB=\fR, all options which take an argument may have that argument appear either immediately @@ -211,16 +213,20 @@ Many options have multi-letter names; therefore multiple single-letter options may \fInot\fR be grouped: \fB\-dM\fR is very different from \&\fB\-d\ \-M\fR. -.Ip "\fB\-D\fR \fIname\fR" 4 +.IP "\fB\-D\fR \fIname\fR" 4 .IX Item "-D name" -Predefine \fIname\fR as a macro, with definition \f(CW\*(C`1\*(C'\fR. -.Ip "\fB\-D\fR \fIname\fR\fB=\fR\fIdefinition\fR" 4 +Predefine \fIname\fR as a macro, with definition \f(CW1\fR. +.IP "\fB\-D\fR \fIname\fR\fB=\fR\fIdefinition\fR" 4 .IX Item "-D name=definition" Predefine \fIname\fR as a macro, with definition \fIdefinition\fR. -There are no restrictions on the contents of \fIdefinition\fR, but if -you are invoking the preprocessor from a shell or shell-like program you -may need to use the shell's quoting syntax to protect characters such as -spaces that have a meaning in the shell syntax. +The contents of \fIdefinition\fR are tokenized and processed as if +they appeared during translation phase three in a \fB#define\fR +directive. In particular, the definition will be truncated by +embedded newline characters. +.Sp +If you are invoking the preprocessor from a shell or shell-like +program you may need to use the shell's quoting syntax to protect +characters such as spaces that have a meaning in the shell syntax. .Sp If you wish to define a function-like macro on the command line, write its argument list with surrounding parentheses before the equals sign @@ -232,90 +238,132 @@ are given on the command line. All \fB\-imacros\fR \fIfile\fR and \&\fB\-include\fR \fIfile\fR options are processed after all \&\fB\-D\fR and \fB\-U\fR options. -.Ip "\fB\-U\fR \fIname\fR" 4 +.IP "\fB\-U\fR \fIname\fR" 4 .IX Item "-U name" Cancel any previous definition of \fIname\fR, either built in or provided with a \fB\-D\fR option. -.Ip "\fB\-undef\fR" 4 +.IP "\fB\-undef\fR" 4 .IX Item "-undef" -Do not predefine any system-specific macros. The common predefined -macros remain defined. -.Ip "\fB\-I\fR \fIdir\fR" 4 +Do not predefine any system-specific or GCC-specific macros. The +standard predefined macros remain defined. +.IP "\fB\-I\fR \fIdir\fR" 4 .IX Item "-I dir" Add the directory \fIdir\fR to the list of directories to be searched for header files. .Sp Directories named by \fB\-I\fR are searched before the standard -system include directories. -.Sp -It is dangerous to specify a standard system include directory in an -\&\fB\-I\fR option. This defeats the special treatment of system -headers -\&. It can also defeat the repairs to buggy system headers which \s-1GCC\s0 -makes when it is installed. -.Ip "\fB\-o\fR \fIfile\fR" 4 +system include directories. If the directory \fIdir\fR is a standard +system include directory, the option is ignored to ensure that the +default search order for system directories and the special treatment +of system headers are not defeated +\&. +.IP "\fB\-o\fR \fIfile\fR" 4 .IX Item "-o file" Write output to \fIfile\fR. This is the same as specifying \fIfile\fR as the second non-option argument to \fBcpp\fR. \fBgcc\fR has a different interpretation of a second non-option argument, so you must use \fB\-o\fR to specify the output file. -.Ip "\fB\-Wall\fR" 4 +.IP "\fB\-Wall\fR" 4 .IX Item "-Wall" -Turns on all optional warnings which are desirable for normal code. At -present this is \fB\-Wcomment\fR and \fB\-Wtrigraphs\fR. Note that -many of the preprocessor's warnings are on by default and have no -options to control them. -.Ip "\fB\-Wcomment\fR" 4 +Turns on all optional warnings which are desirable for normal code. +At present this is \fB\-Wcomment\fR, \fB\-Wtrigraphs\fR, +\&\fB\-Wmultichar\fR and a warning about integer promotion causing a +change of sign in \f(CW\*(C`#if\*(C'\fR expressions. Note that many of the +preprocessor's warnings are on by default and have no options to +control them. +.IP "\fB\-Wcomment\fR" 4 .IX Item "-Wcomment" .PD 0 -.Ip "\fB\-Wcomments\fR" 4 +.IP "\fB\-Wcomments\fR" 4 .IX Item "-Wcomments" .PD Warn whenever a comment-start sequence \fB/*\fR appears in a \fB/*\fR comment, or whenever a backslash-newline appears in a \fB//\fR comment. (Both forms have the same effect.) -.Ip "\fB\-Wtrigraphs\fR" 4 +.IP "\fB\-Wtrigraphs\fR" 4 .IX Item "-Wtrigraphs" -Warn if any trigraphs are encountered. This option used to take effect -only if \fB\-trigraphs\fR was also specified, but now works -independently. Warnings are not given for trigraphs within comments, as -they do not affect the meaning of the program. -.Ip "\fB\-Wtraditional\fR" 4 +@anchor{Wtrigraphs} +Most trigraphs in comments cannot affect the meaning of the program. +However, a trigraph that would form an escaped newline (\fB??/\fR at +the end of a line) can, by changing where the comment begins or ends. +Therefore, only trigraphs that would form escaped newlines produce +warnings inside a comment. +.Sp +This option is implied by \fB\-Wall\fR. If \fB\-Wall\fR is not +given, this option is still enabled unless trigraphs are enabled. To +get trigraph conversion without warnings, but get the other +\&\fB\-Wall\fR warnings, use \fB\-trigraphs \-Wall \-Wno\-trigraphs\fR. +.IP "\fB\-Wtraditional\fR" 4 .IX Item "-Wtraditional" Warn about certain constructs that behave differently in traditional and \&\s-1ISO\s0 C. Also warn about \s-1ISO\s0 C constructs that have no traditional C equivalent, and problematic constructs which should be avoided. -.Ip "\fB\-Wimport\fR" 4 +.IP "\fB\-Wimport\fR" 4 .IX Item "-Wimport" Warn the first time \fB#import\fR is used. -.Ip "\fB\-Wundef\fR" 4 +.IP "\fB\-Wundef\fR" 4 .IX Item "-Wundef" Warn whenever an identifier which is not a macro is encountered in an \&\fB#if\fR directive, outside of \fBdefined\fR. Such identifiers are replaced with zero. -.Ip "\fB\-Werror\fR" 4 +.IP "\fB\-Wunused\-macros\fR" 4 +.IX Item "-Wunused-macros" +Warn about macros defined in the main file that are unused. A macro +is \fIused\fR if it is expanded or tested for existence at least once. +The preprocessor will also warn if the macro has not been used at the +time it is redefined or undefined. +.Sp +Built-in macros, macros defined on the command line, and macros +defined in include files are not warned about. +.Sp +\&\fBNote:\fR If a macro is actually used, but only used in skipped +conditional blocks, then \s-1CPP\s0 will report it as unused. To avoid the +warning in such a case, you might improve the scope of the macro's +definition by, for example, moving it into the first skipped block. +Alternatively, you could provide a dummy use with something like: +.Sp +.Vb 2 +\& #if defined the_macro_causing_the_warning +\& #endif +.Ve +.IP "\fB\-Wendif\-labels\fR" 4 +.IX Item "-Wendif-labels" +Warn whenever an \fB#else\fR or an \fB#endif\fR are followed by text. +This usually happens in code of the form +.Sp +.Vb 5 +\& #if FOO +\& ... +\& #else FOO +\& ... +\& #endif FOO +.Ve +.Sp +The second and third \f(CW\*(C`FOO\*(C'\fR should be in comments, but often are not +in older programs. This warning is on by default. +.IP "\fB\-Werror\fR" 4 .IX Item "-Werror" Make all warnings into hard errors. Source code which triggers warnings will be rejected. -.Ip "\fB\-Wsystem-headers\fR" 4 +.IP "\fB\-Wsystem\-headers\fR" 4 .IX Item "-Wsystem-headers" Issue warnings for code in system headers. These are normally unhelpful in finding bugs in your own code, therefore suppressed. If you are responsible for the system library, you may want to see them. -.Ip "\fB\-w\fR" 4 +.IP "\fB\-w\fR" 4 .IX Item "-w" Suppress all warnings, including those which \s-1GNU\s0 \s-1CPP\s0 issues by default. -.Ip "\fB\-pedantic\fR" 4 +.IP "\fB\-pedantic\fR" 4 .IX Item "-pedantic" Issue all the mandatory diagnostics listed in the C standard. Some of them are left out by default, since they trigger frequently on harmless code. -.Ip "\fB\-pedantic-errors\fR" 4 +.IP "\fB\-pedantic\-errors\fR" 4 .IX Item "-pedantic-errors" Issue all the mandatory diagnostics, and make all mandatory diagnostics into errors. This includes mandatory diagnostics that \s-1GCC\s0 issues without \fB\-pedantic\fR but treats as warnings. -.Ip "\fB\-M\fR" 4 +.IP "\fB\-M\fR" 4 .IX Item "-M" Instead of outputting the result of preprocessing, output a rule suitable for \fBmake\fR describing the dependencies of the main @@ -337,8 +385,9 @@ \&\fB\s-1DEPENDENCIES_OUTPUT\s0\fR. Debug output will still be sent to the regular output stream as normal. .Sp -Passing \fB\-M\fR to the driver implies \fB\-E\fR. -.Ip "\fB\-MM\fR" 4 +Passing \fB\-M\fR to the driver implies \fB\-E\fR, and suppresses +warnings with an implicit \fB\-w\fR. +.IP "\fB\-MM\fR" 4 .IX Item "-MM" Like \fB\-M\fR but do not mention header files that are found in system header directories, nor header files that are included, @@ -348,9 +397,10 @@ \&\fB#include\fR directive does not in itself determine whether that header will appear in \fB\-MM\fR dependency output. This is a slight change in semantics from \s-1GCC\s0 versions 3.0 and earlier. -.Ip "\fB\-MF\fR \fIfile\fR" 4 +.Sp +@anchor{dashMF} +.IP "\fB\-MF\fR \fIfile\fR" 4 .IX Item "-MF file" -@anchor{\-MF} When used with \fB\-M\fR or \fB\-MM\fR, specifies a file to write the dependencies to. If no \fB\-MF\fR switch is given the preprocessor sends the rules to the same place it would have sent @@ -358,15 +408,18 @@ .Sp When used with the driver options \fB\-MD\fR or \fB\-MMD\fR, \&\fB\-MF\fR overrides the default dependency output file. -.Ip "\fB\-MG\fR" 4 +.IP "\fB\-MG\fR" 4 .IX Item "-MG" -When used with \fB\-M\fR or \fB\-MM\fR, \fB\-MG\fR says to treat missing -header files as generated files and assume they live in the same -directory as the source file. It suppresses preprocessed output, as a -missing header file is ordinarily an error. +In conjunction with an option such as \fB\-M\fR requesting +dependency generation, \fB\-MG\fR assumes missing header files are +generated files and adds them to the dependency list without raising +an error. The dependency filename is taken directly from the +\&\f(CW\*(C`#include\*(C'\fR directive without prepending any path. \fB\-MG\fR +also suppresses preprocessed output, as a missing header file renders +this useless. .Sp This feature is used in automatic updating of makefiles. -.Ip "\fB\-MP\fR" 4 +.IP "\fB\-MP\fR" 4 .IX Item "-MP" This option instructs \s-1CPP\s0 to add a phony target for each dependency other than the main file, causing each to depend on nothing. These @@ -378,10 +431,11 @@ .Vb 1 \& test.o: test.c test.h .Ve +.Sp .Vb 1 \& test.h: .Ve -.Ip "\fB\-MT\fR \fItarget\fR" 4 +.IP "\fB\-MT\fR \fItarget\fR" 4 .IX Item "-MT target" Change the target of the rule emitted by dependency generation. By default \s-1CPP\s0 takes the name of the main input file, including any path, @@ -397,7 +451,7 @@ .Vb 1 \& $(objpfx)foo.o: foo.c .Ve -.Ip "\fB\-MQ\fR \fItarget\fR" 4 +.IP "\fB\-MQ\fR \fItarget\fR" 4 .IX Item "-MQ target" Same as \fB\-MT\fR, but it quotes any characters which are special to Make. \fB\-MQ\ '$(objpfx)foo.o'\fR gives @@ -405,9 +459,10 @@ .Vb 1 \& $$(objpfx)foo.o: foo.c .Ve +.Sp The default target is automatically quoted, as if it were given with \&\fB\-MQ\fR. -.Ip "\fB\-MD\fR" 4 +.IP "\fB\-MD\fR" 4 .IX Item "-MD" \&\fB\-MD\fR is equivalent to \fB\-M \-MF\fR \fIfile\fR, except that \&\fB\-E\fR is not implied. The driver determines \fIfile\fR based on @@ -417,26 +472,26 @@ .Sp If \fB\-MD\fR is used in conjunction with \fB\-E\fR, any \&\fB\-o\fR switch is understood to specify the dependency output file -(but \f(CW@pxref\fR{\-MF}), but if used without \fB\-E\fR, each \fB\-o\fR +(but \f(CW@pxref\fR{dashMF,,\-MF}), but if used without \fB\-E\fR, each \fB\-o\fR is understood to specify a target object file. .Sp Since \fB\-E\fR is not implied, \fB\-MD\fR can be used to generate a dependency output file as a side-effect of the compilation process. -.Ip "\fB\-MMD\fR" 4 +.IP "\fB\-MMD\fR" 4 .IX Item "-MMD" Like \fB\-MD\fR except mention only user header files, not system \&\-header files. -.Ip "\fB\-x c\fR" 4 +.IP "\fB\-x c\fR" 4 .IX Item "-x c" .PD 0 -.Ip "\fB\-x c++\fR" 4 +.IP "\fB\-x c++\fR" 4 .IX Item "-x c++" -.Ip "\fB\-x objective-c\fR" 4 +.IP "\fB\-x objective-c\fR" 4 .IX Item "-x objective-c" -.Ip "\fB\-x assembler-with-cpp\fR" 4 +.IP "\fB\-x assembler-with-cpp\fR" 4 .IX Item "-x assembler-with-cpp" .PD -Specify the source language: C, \*(C+, Objective-C, or assembly. This has +Specify the source language: C, \*(C+, Objective\-C, or assembly. This has nothing to do with standards conformance or extensions; it merely selects which base syntax to expect. If you give none of these options, cpp will deduce the language from the extension of the source file: @@ -449,89 +504,97 @@ which selected both the language and the standards conformance level. This option has been removed, because it conflicts with the \fB\-l\fR option. -.Ip "\fB\-std=\fR\fIstandard\fR" 4 +.IP "\fB\-std=\fR\fIstandard\fR" 4 .IX Item "-std=standard" .PD 0 -.Ip "\fB\-ansi\fR" 4 +.IP "\fB\-ansi\fR" 4 .IX Item "-ansi" .PD -Specify the standard to which the code should conform. Currently cpp -only knows about the standards for C; other language standards will be -added in the future. +Specify the standard to which the code should conform. Currently \s-1CPP\s0 +knows about C and \*(C+ standards; others may be added in the future. .Sp \&\fIstandard\fR may be one of: .RS 4 -.if n .Ip "\f(CW""""iso9899:1990""""\fR" 4 -.el .Ip "\f(CWiso9899:1990\fR" 4 +.ie n .IP """iso9899:1990""" 4 +.el .IP "\f(CWiso9899:1990\fR" 4 .IX Item "iso9899:1990" .PD 0 -.if n .Ip "\f(CW""""c89""""\fR" 4 -.el .Ip "\f(CWc89\fR" 4 +.ie n .IP """c89""" 4 +.el .IP "\f(CWc89\fR" 4 .IX Item "c89" .PD The \s-1ISO\s0 C standard from 1990. \fBc89\fR is the customary shorthand for this version of the standard. .Sp The \fB\-ansi\fR option is equivalent to \fB\-std=c89\fR. -.if n .Ip "\f(CW""""iso9899:199409""""\fR" 4 -.el .Ip "\f(CWiso9899:199409\fR" 4 +.ie n .IP """iso9899:199409""" 4 +.el .IP "\f(CWiso9899:199409\fR" 4 .IX Item "iso9899:199409" The 1990 C standard, as amended in 1994. -.if n .Ip "\f(CW""""iso9899:1999""""\fR" 4 -.el .Ip "\f(CWiso9899:1999\fR" 4 +.ie n .IP """iso9899:1999""" 4 +.el .IP "\f(CWiso9899:1999\fR" 4 .IX Item "iso9899:1999" .PD 0 -.if n .Ip "\f(CW""""c99""""\fR" 4 -.el .Ip "\f(CWc99\fR" 4 +.ie n .IP """c99""" 4 +.el .IP "\f(CWc99\fR" 4 .IX Item "c99" -.if n .Ip "\f(CW""""iso9899:199x""""\fR" 4 -.el .Ip "\f(CWiso9899:199x\fR" 4 +.ie n .IP """iso9899:199x""" 4 +.el .IP "\f(CWiso9899:199x\fR" 4 .IX Item "iso9899:199x" -.if n .Ip "\f(CW""""c9x""""\fR" 4 -.el .Ip "\f(CWc9x\fR" 4 +.ie n .IP """c9x""" 4 +.el .IP "\f(CWc9x\fR" 4 .IX Item "c9x" .PD The revised \s-1ISO\s0 C standard, published in December 1999. Before publication, this was known as C9X. -.if n .Ip "\f(CW""""gnu89""""\fR" 4 -.el .Ip "\f(CWgnu89\fR" 4 +.ie n .IP """gnu89""" 4 +.el .IP "\f(CWgnu89\fR" 4 .IX Item "gnu89" The 1990 C standard plus \s-1GNU\s0 extensions. This is the default. -.if n .Ip "\f(CW""""gnu99""""\fR" 4 -.el .Ip "\f(CWgnu99\fR" 4 +.ie n .IP """gnu99""" 4 +.el .IP "\f(CWgnu99\fR" 4 .IX Item "gnu99" .PD 0 -.if n .Ip "\f(CW""""gnu9x""""\fR" 4 -.el .Ip "\f(CWgnu9x\fR" 4 +.ie n .IP """gnu9x""" 4 +.el .IP "\f(CWgnu9x\fR" 4 .IX Item "gnu9x" .PD The 1999 C standard plus \s-1GNU\s0 extensions. +.ie n .IP """c++98""" 4 +.el .IP "\f(CWc++98\fR" 4 +.IX Item "c++98" +The 1998 \s-1ISO\s0 \*(C+ standard plus amendments. +.ie n .IP """gnu++98""" 4 +.el .IP "\f(CWgnu++98\fR" 4 +.IX Item "gnu++98" +The same as \fB\-std=c++98\fR plus \s-1GNU\s0 extensions. This is the +default for \*(C+ code. .RE .RS 4 .RE -.Ip "\fB\-I-\fR" 4 +.IP "\fB\-I\-\fR" 4 .IX Item "-I-" Split the include path. Any directories specified with \fB\-I\fR >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Tue Sep 26 20:50:34 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 06F5516A546; Tue, 26 Sep 2006 20:50:34 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 5C3CF16A412 for ; Tue, 26 Sep 2006 20:50:33 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id E2CB143D5C for ; Tue, 26 Sep 2006 20:50:32 +0000 (GMT) (envelope-from gonzo@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QKoWrT081650 for ; Tue, 26 Sep 2006 20:50:32 GMT (envelope-from gonzo@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QKoW6O081645 for perforce@freebsd.org; Tue, 26 Sep 2006 20:50:32 GMT (envelope-from gonzo@FreeBSD.org) Date: Tue, 26 Sep 2006 20:50:32 GMT Message-Id: <200609262050.k8QKoW6O081645@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to gonzo@FreeBSD.org using -f From: Oleksandr Tymoshenko To: Perforce Change Reviews Cc: Subject: PERFORCE change 106744 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 20:50:34 -0000 http://perforce.freebsd.org/chv.cgi?CH=106744 Change 106744 by gonzo@gonzo_hq on 2006/09/26 20:50:17 o Make tlb_update and tlb_invalidate_page ASID-aware. o Add some *very* initial ASID initialization. Affected files ... .. //depot/projects/mips2/src/sys/mips/include/tlb.h#5 edit .. //depot/projects/mips2/src/sys/mips/mips/pmap.c#11 edit .. //depot/projects/mips2/src/sys/mips/mips/tlb.c#9 edit .. //depot/projects/mips2/src/sys/mips/mips/trap.c#8 edit Differences ... ==== //depot/projects/mips2/src/sys/mips/include/tlb.h#5 (text+ko) ==== @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $P4: //depot/projects/mips2/src/sys/mips/include/tlb.h#4 $ + * $P4: //depot/projects/mips2/src/sys/mips/include/tlb.h#5 $ */ #ifndef _MACHINE_TLB_H_ @@ -39,11 +39,11 @@ void tlb_enter(pmap_t, vm_offset_t, vm_paddr_t, pt_entry_t); void tlb_invalidate_all(void); void tlb_invalidate_one(int); -void tlb_invalidate_page(vm_offset_t); +void tlb_invalidate_page(vm_offset_t, uint32_t); void tlb_modified(pmap_t, void *); void tlb_remove(pmap_t, vm_offset_t); void tlb_remove_pages(pmap_t, vm_offset_t, int); void tlb_remove_range(pmap_t, vm_offset_t, vm_offset_t); -void tlb_update(vm_offset_t, pt_entry_t, pt_entry_t); +void tlb_update(vm_offset_t, uint32_t, pt_entry_t, pt_entry_t); #endif /* _MACHINE_TLB_H_ */ ==== //depot/projects/mips2/src/sys/mips/mips/pmap.c#11 (text+ko) ==== @@ -455,7 +455,7 @@ { if (pmap->pm_active) { - tlb_invalidate_page(va); + tlb_invalidate_page(va, pmap->pm_asid); /* XXX ensure coherency? */ } else { pmap_invalidate_asid(pmap); @@ -758,8 +758,9 @@ pmap->pm_ptphint = NULL; pmap->pm_active = 0; - pmap->pm_asid = 0; - pmap->pm_asidgen = 0; + /* XXXMIPS: put proper asid generation here */ + pmap->pm_asid = 1; + pmap->pm_asidgen = 1; TAILQ_INIT(&pmap->pm_pvlist); bzero(&pmap->pm_stats, sizeof pmap->pm_stats); mtx_lock_spin(&allpmaps_lock); ==== //depot/projects/mips2/src/sys/mips/mips/tlb.c#9 (text+ko) ==== @@ -136,7 +136,7 @@ pte = pmap_pte(pmap, va); if (pte_valid(pte)) - tlb_invalidate_page(va); + tlb_invalidate_page(va, pmap->pm_asid); else mips_dcache_wbinv_range_index(va, PAGE_SIZE); if ((bits & PG_V) == 0) @@ -147,9 +147,9 @@ *pte |= PG_C_UNCACHED; if ((va >> PAGE_SHIFT) & 1) - tlb_update(va, pte[-1], pte[0]); + tlb_update(va, pmap->pm_asid, pte[-1], pte[0]); else - tlb_update(va, pte[0], pte[1]); + tlb_update(va, pmap->pm_asid, pte[0], pte[1]); } void @@ -161,7 +161,7 @@ pte = pmap_pte(pmap, va); pte_clear(pte, PG_V); - tlb_invalidate_page(va); + tlb_invalidate_page(va, pmap->pm_asid); } void @@ -181,13 +181,13 @@ } void -tlb_update(vm_offset_t va, pt_entry_t pte0, pt_entry_t pte1) +tlb_update(vm_offset_t va, uint32_t asid, pt_entry_t pte0, pt_entry_t pte1) { u_long ehi; int i; va &= ~PAGE_MASK; - ehi = MIPS_HI_ENTRY(va, /*asid*/0); + ehi = MIPS_HI_ENTRY(va, asid); mips_wr_entryhi(ehi); mips_tlbp(); i = mips_rd_index(); @@ -227,13 +227,13 @@ } void -tlb_invalidate_page(vm_offset_t va) +tlb_invalidate_page(vm_offset_t va, uint32_t asid) { u_long ehi; int i; va &= ~PAGE_MASK; - ehi = MIPS_HI_ENTRY(va, /*asid*/0); + ehi = MIPS_HI_ENTRY(va, asid); mips_wr_entryhi(ehi); mips_tlbp(); i = mips_rd_index(); @@ -270,8 +270,8 @@ *pte |= PG_D; if ((va >> PAGE_SHIFT) & 1) { - tlb_update(va, pte[-1], pte[0]); + tlb_update(va, pmap->pm_asid, pte[-1], pte[0]); } else { - tlb_update(va, pte[0], pte[1]); + tlb_update(va, pmap->pm_asid, pte[0], pte[1]); } } ==== //depot/projects/mips2/src/sys/mips/mips/trap.c#8 (text+ko) ==== @@ -144,9 +144,11 @@ } if ((va >> PAGE_SHIFT) & 1) - tlb_update(va, pte[-1], pte[0]); + tlb_update(va, kernel_pmap->pm_asid, + pte[-1], pte[0]); else - tlb_update(va, pte[0], pte[1]); + tlb_update(va, kernel_pmap->pm_asid, + pte[0], pte[1]); goto done; } else map = &td->td_proc->p_vmspace->vm_map; From owner-p4-projects@FreeBSD.ORG Tue Sep 26 20:52:37 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 260AE16A40F; Tue, 26 Sep 2006 20:52:37 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 CC51016A403 for ; Tue, 26 Sep 2006 20:52:36 +0000 (UTC) (envelope-from m@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9B24D43D46 for ; Tue, 26 Sep 2006 20:52:36 +0000 (GMT) (envelope-from m@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QKqa0X081824 for ; Tue, 26 Sep 2006 20:52:36 GMT (envelope-from m@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QKqagB081821 for perforce@freebsd.org; Tue, 26 Sep 2006 20:52:36 GMT (envelope-from m@FreeBSD.org) Date: Tue, 26 Sep 2006 20:52:36 GMT Message-Id: <200609262052.k8QKqagB081821@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to m@FreeBSD.org using -f From: Markus Boelter To: Perforce Change Reviews Cc: Subject: PERFORCE change 106745 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 20:52:37 -0000 http://perforce.freebsd.org/chv.cgi?CH=106745 Change 106745 by m@m_jana on 2006/09/26 20:51:35 added 10-sec-counter before wiping all data on the disk Affected files ... .. //depot/projects/soc2006/m_netboot_server/freesbie/extra/autoinstall/autoinstall.rc#2 edit Differences ... ==== //depot/projects/soc2006/m_netboot_server/freesbie/extra/autoinstall/autoinstall.rc#2 (text+ko) ==== @@ -129,6 +129,16 @@ autoinstall() { if [ -f /etc/autoinstall.conf ]; then + echo "Starting FreeBSD autoinstall in 10 seconds." + echo "ALL DATA ON THE DRIVE WILL BE LOST" + echo + echo "Press Ctrl-C to abort." + + for i in 10 9 8 7 6 5 4 3 2 1; do + echo -n "." + sleep 1 + done + . /etc/autoinstall.conf fi } From owner-p4-projects@FreeBSD.ORG Tue Sep 26 21:26:19 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9ACAD16A412; Tue, 26 Sep 2006 21:26:19 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 7802016A403 for ; Tue, 26 Sep 2006 21:26:19 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 181F243D53 for ; Tue, 26 Sep 2006 21:26:19 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QLQIV6084511 for ; Tue, 26 Sep 2006 21:26:18 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QLQIrj084508 for perforce@freebsd.org; Tue, 26 Sep 2006 21:26:18 GMT (envelope-from rdivacky@FreeBSD.org) Date: Tue, 26 Sep 2006 21:26:18 GMT Message-Id: <200609262126.k8QLQIrj084508@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106746 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 21:26:19 -0000 http://perforce.freebsd.org/chv.cgi?CH=106746 Change 106746 by rdivacky@rdivacky_witten on 2006/09/26 21:25:42 Replace homegrown check for FIFO with S_ISFIFO. Inspired by: NetBSD Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linux/linux_misc.c#3 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_misc.c#3 (text+ko) ==== @@ -880,7 +880,7 @@ printf(ARGS(mknod, "%s, %d, %d"), path, args->mode, args->dev); #endif - if (args->mode & S_IFIFO) + if (S_ISFIFO(args->mode)) error = kern_mkfifo(td, path, UIO_SYSSPACE, args->mode); else error = kern_mknod(td, path, UIO_SYSSPACE, args->mode, From owner-p4-projects@FreeBSD.ORG Tue Sep 26 23:27:06 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D964416A51E; Tue, 26 Sep 2006 23:27:05 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 4371116A412 for ; Tue, 26 Sep 2006 23:27:04 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4900643D46 for ; Tue, 26 Sep 2006 23:26:59 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8QNQxxR098039 for ; Tue, 26 Sep 2006 23:26:59 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8QNQwpW098036 for perforce@freebsd.org; Tue, 26 Sep 2006 23:26:58 GMT (envelope-from mjacob@freebsd.org) Date: Tue, 26 Sep 2006 23:26:58 GMT Message-Id: <200609262326.k8QNQwpW098036@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106749 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Sep 2006 23:27:06 -0000 http://perforce.freebsd.org/chv.cgi?CH=106749 Change 106749 by mjacob@newisp on 2006/09/26 23:26:45 IFC Affected files ... .. //depot/projects/newisp/amd64/conf/GENERIC#2 integrate .. //depot/projects/newisp/boot/pc98/boot2/inode.h#2 integrate .. //depot/projects/newisp/conf/NOTES#5 integrate .. //depot/projects/newisp/conf/options#3 integrate .. //depot/projects/newisp/dev/ipmi/ipmi.c#3 integrate .. //depot/projects/newisp/dev/isp/isp_freebsd.c#10 integrate .. //depot/projects/newisp/dev/isp/isp_freebsd.h#6 integrate .. //depot/projects/newisp/dev/smbus/smb.c#3 integrate .. //depot/projects/newisp/fs/devfs/devfs_vfsops.c#3 integrate .. //depot/projects/newisp/fs/hpfs/hpfs_vfsops.c#2 integrate .. //depot/projects/newisp/fs/msdosfs/msdosfs_vfsops.c#2 integrate .. //depot/projects/newisp/fs/ntfs/ntfs_vfsops.c#2 integrate .. //depot/projects/newisp/fs/nullfs/null_vfsops.c#2 integrate .. //depot/projects/newisp/fs/nwfs/nwfs_vfsops.c#2 integrate .. //depot/projects/newisp/fs/portalfs/portal_vfsops.c#2 integrate .. //depot/projects/newisp/fs/smbfs/smbfs_vfsops.c#2 integrate .. //depot/projects/newisp/fs/udf/udf_vfsops.c#2 integrate .. //depot/projects/newisp/fs/umapfs/umap_vfsops.c#2 integrate .. //depot/projects/newisp/fs/unionfs/union_vfsops.c#2 integrate .. //depot/projects/newisp/gnu/fs/ext2fs/ext2_inode.c#2 integrate .. //depot/projects/newisp/gnu/fs/ext2fs/ext2_vfsops.c#2 integrate .. //depot/projects/newisp/gnu/fs/reiserfs/reiserfs_vfsops.c#2 integrate .. //depot/projects/newisp/i386/conf/GENERIC#2 integrate .. //depot/projects/newisp/ia64/conf/GENERIC#2 integrate .. //depot/projects/newisp/isofs/cd9660/cd9660_vfsops.c#2 integrate .. //depot/projects/newisp/kern/uipc_mqueue.c#2 integrate .. //depot/projects/newisp/kern/vfs_cluster.c#2 integrate .. //depot/projects/newisp/kern/vfs_export.c#2 integrate .. //depot/projects/newisp/kern/vfs_mount.c#3 integrate .. //depot/projects/newisp/kern/vfs_subr.c#3 integrate .. //depot/projects/newisp/kern/vfs_syscalls.c#4 integrate .. //depot/projects/newisp/modules/wlan/Makefile#2 integrate .. //depot/projects/newisp/net80211/ieee80211_ioctl.c#2 integrate .. //depot/projects/newisp/nfsclient/nfs_vfsops.c#3 integrate .. //depot/projects/newisp/nfsclient/nfs_vnops.c#3 integrate .. //depot/projects/newisp/pc98/conf/GENERIC#2 integrate .. //depot/projects/newisp/powerpc/conf/GENERIC#2 integrate .. //depot/projects/newisp/sparc64/conf/GENERIC#2 integrate .. //depot/projects/newisp/sys/copyright.h#3 integrate .. //depot/projects/newisp/sys/mount.h#3 integrate .. //depot/projects/newisp/ufs/ffs/ffs_snapshot.c#2 integrate .. //depot/projects/newisp/ufs/ffs/ffs_softdep.c#3 integrate .. //depot/projects/newisp/ufs/ffs/ffs_vfsops.c#2 integrate .. //depot/projects/newisp/ufs/ufs/inode.h#2 integrate .. //depot/projects/newisp/ufs/ufs/ufs_quota.c#3 integrate Differences ... ==== //depot/projects/newisp/amd64/conf/GENERIC#2 (text+ko) ==== @@ -16,7 +16,7 @@ # If you are in doubt as to the purpose or necessity of a line, check first # in NOTES. # -# $FreeBSD: src/sys/amd64/conf/GENERIC,v 1.464 2006/07/09 16:39:21 mjacob Exp $ +# $FreeBSD: src/sys/amd64/conf/GENERIC,v 1.465 2006/09/26 12:36:33 ru Exp $ cpu HAMMER ident GENERIC @@ -49,6 +49,7 @@ options COMPAT_IA32 # Compatible with i386 binaries options COMPAT_FREEBSD4 # Compatible with FreeBSD4 options COMPAT_FREEBSD5 # Compatible with FreeBSD5 +options COMPAT_FREEBSD6 # Compatible with FreeBSD6 options SCSI_DELAY=5000 # Delay (in ms) before probing SCSI options KTRACE # ktrace(1) support options SYSVSHM # SYSV-style shared memory ==== //depot/projects/newisp/boot/pc98/boot2/inode.h#2 (text+ko) ==== @@ -33,7 +33,7 @@ * * @(#)inode.h 8.9 (Berkeley) 5/14/95 * %FreeBSD: src/sys/ufs/ufs/inode.h,v 1.28.2.2 2001/09/29 12:52:52 iedowse Exp % - * $FreeBSD: src/sys/boot/pc98/boot2/inode.h,v 1.4 2004/06/16 18:21:22 phk Exp $ + * $FreeBSD: src/sys/boot/pc98/boot2/inode.h,v 1.5 2006/09/26 04:15:57 tegge Exp $ */ #ifndef _UFS_UFS_INODE_H_ @@ -147,7 +147,7 @@ /* Determine if soft dependencies are being done */ #define DOINGSOFTDEP(vp) ((vp)->v_mount->mnt_flag & MNT_SOFTDEP) -#define DOINGASYNC(vp) ((vp)->v_mount->mnt_flag & MNT_ASYNC) +#define DOINGASYNC(vp) ((vp)->v_mount->mnt_kern_flag & MNTK_ASYNC) /* This overlays the fid structure (see mount.h). */ struct ufid { ==== //depot/projects/newisp/conf/NOTES#5 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/NOTES,v 1.1382 2006/09/25 11:40:14 scottl Exp $ +# $FreeBSD: src/sys/conf/NOTES,v 1.1383 2006/09/26 12:36:33 ru Exp $ # # NOTES -- Lines that can be cut/pasted into kernel and hints configs. # @@ -273,6 +273,9 @@ # Enable FreeBSD5 compatibility syscalls options COMPAT_FREEBSD5 +# Enable FreeBSD6 compatibility syscalls +options COMPAT_FREEBSD6 + # # These three options provide support for System V Interface # Definition-style interprocess communication, in the form of shared ==== //depot/projects/newisp/conf/options#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/options,v 1.558 2006/09/20 13:33:40 rwatson Exp $ +# $FreeBSD: src/sys/conf/options,v 1.559 2006/09/26 12:36:33 ru Exp $ # # On the handling of kernel options # @@ -67,6 +67,7 @@ COMPAT_43TTY opt_compat.h COMPAT_FREEBSD4 opt_compat.h COMPAT_FREEBSD5 opt_compat.h +COMPAT_FREEBSD6 opt_compat.h COMPILING_LINT opt_global.h CY_PCI_FASTINTR DIRECTIO ==== //depot/projects/newisp/dev/ipmi/ipmi.c#3 (text) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ipmi/ipmi.c,v 1.4 2006/09/22 22:11:29 jhb Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ipmi/ipmi.c,v 1.5 2006/09/26 15:48:13 jhb Exp $"); #include #include @@ -949,9 +949,11 @@ int count; int i; - devclass_get_devices(ipmi_devclass, &devs, &count); + if (devclass_get_devices(ipmi_devclass, &devs, &count) != 0) + return; for (i = 0; i < count; i++) device_delete_child(device_get_parent(devs[i]), devs[i]); + free(devs, M_TEMP); } SYSUNINIT(ipmi_unload, SI_SUB_DRIVERS, SI_ORDER_FIRST, ipmi_unload, NULL); ==== //depot/projects/newisp/dev/isp/isp_freebsd.c#10 (text+ko) ==== @@ -29,7 +29,7 @@ * Platform (FreeBSD) dependent common attachment code for Qlogic adapters. */ #include -__FBSDID("$FreeBSD: src/sys/dev/isp/isp_freebsd.c,v 1.122 2006/09/01 04:57:14 mjacob Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/isp/isp_freebsd.c,v 1.123 2006/09/26 04:59:52 mjacob Exp $"); #include #include #include ==== //depot/projects/newisp/dev/isp/isp_freebsd.h#6 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/sys/dev/isp/isp_freebsd.h,v 1.92 2006/09/01 05:03:42 mjacob Exp $ */ +/* $FreeBSD: src/sys/dev/isp/isp_freebsd.h,v 1.93 2006/09/26 04:59:52 mjacob Exp $ */ /*- * Qlogic ISP SCSI Host Adapter FreeBSD Wrapper Definitions * @@ -164,6 +164,15 @@ struct firmware * fw; struct mtx lock; struct cv kthread_cv; + union { + struct { + char wwnn[17]; + char wwpn[17]; + } fc; + struct { + int iid; + } spi; + } sysctl_info; #endif struct proc *kproc; bus_dma_tag_t cdmat; ==== //depot/projects/newisp/dev/smbus/smb.c#3 (text+ko) ==== @@ -23,9 +23,13 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/smbus/smb.c,v 1.37 2006/09/11 20:52:41 jhb Exp $ + * $FreeBSD: src/sys/dev/smbus/smb.c,v 1.38 2006/09/26 14:38:56 jhb Exp $ */ +#ifdef HAVE_KERNEL_OPTION_HEADERS +#include "opt_compat.h" +#endif + #include #include #include @@ -270,7 +274,9 @@ } break; +#if defined(COMPAT_FREEBSD4) || defined(COMPAT_FREEBSD5) || defined(COMPAT_FREEBSD6) case SMB_OLD_BREAD: +#endif case SMB_BREAD: if (s->count && s->data.byte_ptr) { count = min(s->count, SMB_MAXBLOCKSIZE); ==== //depot/projects/newisp/fs/devfs/devfs_vfsops.c#3 (text+ko) ==== @@ -31,7 +31,7 @@ * @(#)kernfs_vfsops.c 8.10 (Berkeley) 5/14/95 * From: FreeBSD: src/sys/miscfs/kernfs/kernfs_vfsops.c 1.36 * - * $FreeBSD: src/sys/fs/devfs/devfs_vfsops.c,v 1.51 2006/09/18 13:23:08 kib Exp $ + * $FreeBSD: src/sys/fs/devfs/devfs_vfsops.c,v 1.52 2006/09/26 04:12:45 tegge Exp $ */ #include @@ -79,11 +79,13 @@ sx_init(&fmp->dm_lock, "devfsmount"); fmp->dm_holdcnt = 1; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; mp->mnt_kern_flag |= MNTK_MPSAFE; #ifdef MAC mp->mnt_flag |= MNT_MULTILABEL; #endif + MNT_IUNLOCK(mp); fmp->dm_mount = mp; mp->mnt_data = (void *) fmp; vfs_getnewfsid(mp); ==== //depot/projects/newisp/fs/hpfs/hpfs_vfsops.c#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/fs/hpfs/hpfs_vfsops.c,v 1.57 2005/10/31 15:41:20 rwatson Exp $ + * $FreeBSD: src/sys/fs/hpfs/hpfs_vfsops.c,v 1.58 2006/09/26 04:12:45 tegge Exp $ */ @@ -315,7 +315,9 @@ mp->mnt_stat.f_fsid.val[0] = (long)dev2udev(dev); mp->mnt_stat.f_fsid.val[1] = mp->mnt_vfc->vfc_typenum; mp->mnt_maxsymlinklen = 0; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); return (0); failed: @@ -359,7 +361,9 @@ hpfs_cpdeinit(hpmp); hpfs_bmdeinit(hpmp); mp->mnt_data = (qaddr_t)0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); FREE(hpmp, M_HPFSMNT); return (0); ==== //depot/projects/newisp/fs/msdosfs/msdosfs_vfsops.c#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/sys/fs/msdosfs/msdosfs_vfsops.c,v 1.152 2006/08/03 03:55:52 delphij Exp $ */ +/* $FreeBSD: src/sys/fs/msdosfs/msdosfs_vfsops.c,v 1.153 2006/09/26 04:12:45 tegge Exp $ */ /* $NetBSD: msdosfs_vfsops.c,v 1.51 1997/11/17 15:36:58 ws Exp $ */ /*- @@ -706,7 +706,9 @@ mp->mnt_data = (qaddr_t) pmp; mp->mnt_stat.f_fsid.val[0] = dev2udev(dev); mp->mnt_stat.f_fsid.val[1] = mp->mnt_vfc->vfc_typenum; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); #ifdef MSDOSFS_LARGE msdosfs_fileno_init(mp); @@ -798,7 +800,9 @@ #endif free(pmp, M_MSDOSFSMNT); mp->mnt_data = (qaddr_t)0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); return (error); } ==== //depot/projects/newisp/fs/ntfs/ntfs_vfsops.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/fs/ntfs/ntfs_vfsops.c,v 1.83 2006/05/26 00:32:20 rodrigc Exp $ + * $FreeBSD: src/sys/fs/ntfs/ntfs_vfsops.c,v 1.84 2006/09/26 04:12:45 tegge Exp $ */ @@ -430,7 +430,9 @@ mp->mnt_stat.f_fsid.val[0] = dev2udev(dev); mp->mnt_stat.f_fsid.val[1] = mp->mnt_vfc->vfc_typenum; mp->mnt_maxsymlinklen = 0; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); return (0); out1: @@ -507,7 +509,9 @@ ntfs_u28_uninit(ntmp); ntfs_82u_uninit(ntmp); mp->mnt_data = (qaddr_t)0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); FREE(ntmp->ntm_ad, M_NTFSMNT); FREE(ntmp, M_NTFSMNT); return (error); ==== //depot/projects/newisp/fs/nullfs/null_vfsops.c#2 (text+ko) ==== @@ -32,7 +32,7 @@ * @(#)null_vfsops.c 8.2 (Berkeley) 1/21/94 * * @(#)lofs_vfsops.c 1.2 (Berkeley) 6/18/92 - * $FreeBSD: src/sys/fs/nullfs/null_vfsops.c,v 1.79 2006/05/28 22:45:52 rodrigc Exp $ + * $FreeBSD: src/sys/fs/nullfs/null_vfsops.c,v 1.80 2006/09/26 04:12:45 tegge Exp $ */ /* @@ -179,9 +179,14 @@ */ VOP_UNLOCK(vp, 0, td); - if (NULLVPTOLOWERVP(nullm_rootvp)->v_mount->mnt_flag & MNT_LOCAL) + if (NULLVPTOLOWERVP(nullm_rootvp)->v_mount->mnt_flag & MNT_LOCAL) { + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); + } + MNT_ILOCK(mp); mp->mnt_kern_flag |= lowerrootvp->v_mount->mnt_kern_flag & MNTK_MPSAFE; + MNT_IUNLOCK(mp); mp->mnt_data = (qaddr_t) xmp; vfs_getnewfsid(mp); ==== //depot/projects/newisp/fs/nwfs/nwfs_vfsops.c#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/sys/fs/nwfs/nwfs_vfsops.c,v 1.43 2005/12/14 00:49:51 des Exp $ + * $FreeBSD: src/sys/fs/nwfs/nwfs_vfsops.c,v 1.44 2006/09/26 04:12:46 tegge Exp $ */ #include @@ -267,7 +267,9 @@ if (nmp->m.flags & NWFS_MOUNT_HAVE_NLS) free(nmp->m.nls.to_lower, M_NWFSDATA); free(nmp, M_NWFSDATA); + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); return (error); } ==== //depot/projects/newisp/fs/portalfs/portal_vfsops.c#2 (text+ko) ==== @@ -31,7 +31,7 @@ * * @(#)portal_vfsops.c 8.11 (Berkeley) 5/14/95 * - * $FreeBSD: src/sys/fs/portalfs/portal_vfsops.c,v 1.58 2005/10/31 15:41:21 rwatson Exp $ + * $FreeBSD: src/sys/fs/portalfs/portal_vfsops.c,v 1.59 2006/09/26 04:12:46 tegge Exp $ */ /* @@ -146,7 +146,9 @@ fhold(fp); fmp->pm_server = fp; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); mp->mnt_data = (qaddr_t) fmp; vfs_getnewfsid(mp); ==== //depot/projects/newisp/fs/smbfs/smbfs_vfsops.c#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/sys/fs/smbfs/smbfs_vfsops.c,v 1.40 2006/07/17 16:13:42 jhb Exp $ + * $FreeBSD: src/sys/fs/smbfs/smbfs_vfsops.c,v 1.41 2006/09/26 04:12:46 tegge Exp $ */ #include @@ -318,7 +318,9 @@ #else free(smp, M_SMBFSDATA); #endif + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); return error; } ==== //depot/projects/newisp/fs/udf/udf_vfsops.c#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/fs/udf/udf_vfsops.c,v 1.43 2006/07/25 14:15:50 yar Exp $ + * $FreeBSD: src/sys/fs/udf/udf_vfsops.c,v 1.44 2006/09/26 04:12:46 tegge Exp $ */ /* udf_vfsops.c */ @@ -201,7 +201,9 @@ /* * Unconditionally mount as read-only. */ + MNT_ILOCK(mp); mp->mnt_flag |= MNT_RDONLY; + MNT_IUNLOCK(mp); /* * No root filesystem support. Probably not a big deal, since the @@ -341,7 +343,9 @@ mp->mnt_data = (qaddr_t)udfmp; mp->mnt_stat.f_fsid.val[0] = dev2udev(devvp->v_rdev); mp->mnt_stat.f_fsid.val[1] = mp->mnt_vfc->vfc_typenum; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); udfmp->im_mountp = mp; udfmp->im_dev = devvp->v_rdev; udfmp->im_devvp = devvp; @@ -532,7 +536,9 @@ FREE(udfmp, M_UDFMOUNT); mp->mnt_data = (qaddr_t)0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); return (0); } ==== //depot/projects/newisp/fs/umapfs/umap_vfsops.c#2 (text+ko) ==== @@ -31,7 +31,7 @@ * * @(#)umap_vfsops.c 8.8 (Berkeley) 5/14/95 * - * $FreeBSD: src/sys/fs/umapfs/umap_vfsops.c,v 1.64 2005/10/31 15:41:21 rwatson Exp $ + * $FreeBSD: src/sys/fs/umapfs/umap_vfsops.c,v 1.65 2006/09/26 04:12:46 tegge Exp $ */ /* @@ -216,8 +216,11 @@ umapm_rootvp = vp; umapm_rootvp->v_vflag |= VV_ROOT; amp->umapm_rootvp = umapm_rootvp; - if (UMAPVPTOLOWERVP(umapm_rootvp)->v_mount->mnt_flag & MNT_LOCAL) + if (UMAPVPTOLOWERVP(umapm_rootvp)->v_mount->mnt_flag & MNT_LOCAL) { + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); + } mp->mnt_data = (qaddr_t) amp; vfs_getnewfsid(mp); ==== //depot/projects/newisp/fs/unionfs/union_vfsops.c#2 (text+ko) ==== @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)union_vfsops.c 8.20 (Berkeley) 5/20/95 - * $FreeBSD: src/sys/fs/unionfs/union_vfsops.c,v 1.77 2005/10/31 15:41:22 rwatson Exp $ + * $FreeBSD: src/sys/fs/unionfs/union_vfsops.c,v 1.78 2006/09/26 04:12:46 tegge Exp $ */ /* @@ -86,7 +86,9 @@ /* * Disable clustered write, otherwise system becomes unstable. */ + MNT_ILOCK(mp); mp->mnt_flag |= MNT_NOCLUSTERW; + MNT_IUNLOCK(mp); if (mp->mnt_flag & MNT_ROOTFS) return (EOPNOTSUPP); @@ -246,8 +248,11 @@ if (um->um_op == UNMNT_ABOVE) { if (((um->um_lowervp == NULLVP) || (um->um_lowervp->v_mount->mnt_flag & MNT_LOCAL)) && - (um->um_uppervp->v_mount->mnt_flag & MNT_LOCAL)) + (um->um_uppervp->v_mount->mnt_flag & MNT_LOCAL)) { + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); + } } /* @@ -257,7 +262,9 @@ * mount of the underlying filesystem to go from rdonly to rdwr * will leave the unioned view as read-only. */ + MNT_ILOCK(mp); mp->mnt_flag |= (um->um_uppervp->v_mount->mnt_flag & MNT_RDONLY); + MNT_IUNLOCK(mp); mp->mnt_data = (qaddr_t) um; vfs_getnewfsid(mp); ==== //depot/projects/newisp/gnu/fs/ext2fs/ext2_inode.c#2 (text+ko) ==== @@ -33,7 +33,7 @@ * SUCH DAMAGE. * * @(#)ffs_inode.c 8.5 (Berkeley) 12/30/93 - * $FreeBSD: src/sys/gnu/fs/ext2fs/ext2_inode.c,v 1.57 2005/12/05 11:58:33 ru Exp $ + * $FreeBSD: src/sys/gnu/fs/ext2fs/ext2_inode.c,v 1.58 2006/09/26 04:15:58 tegge Exp $ */ #include @@ -92,7 +92,7 @@ } ext2_i2ei(ip, (struct ext2_inode *)((char *)bp->b_data + EXT2_INODE_SIZE * ino_to_fsbo(fs, ip->i_number))); - if (waitfor && (vp->v_mount->mnt_flag & MNT_ASYNC) == 0) + if (waitfor && (vp->v_mount->mnt_kern_flag & MNTK_ASYNC) == 0) return (bwrite(bp)); else { bdwrite(bp); ==== //depot/projects/newisp/gnu/fs/ext2fs/ext2_vfsops.c#2 (text+ko) ==== @@ -33,7 +33,7 @@ * SUCH DAMAGE. * * @(#)ffs_vfsops.c 8.8 (Berkeley) 4/18/94 - * $FreeBSD: src/sys/gnu/fs/ext2fs/ext2_vfsops.c,v 1.157 2006/05/26 00:32:20 rodrigc Exp $ + * $FreeBSD: src/sys/gnu/fs/ext2fs/ext2_vfsops.c,v 1.158 2006/09/26 04:12:47 tegge Exp $ */ /*- @@ -230,7 +230,9 @@ fs->s_es->s_state &= ~EXT2_VALID_FS; ext2_sbupdate(ump, MNT_WAIT); fs->s_rd_only = 0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_RDONLY; + MNT_IUNLOCK(mp); } if (vfs_flagopt(opts, "export", NULL, 0)) { /* Process export requests in vfs_mount.c. */ @@ -683,7 +685,9 @@ mp->mnt_stat.f_fsid.val[0] = dev2udev(dev); mp->mnt_stat.f_fsid.val[1] = mp->mnt_vfc->vfc_typenum; mp->mnt_maxsymlinklen = EXT2_MAXSYMLINKLEN; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); ump->um_mountp = mp; ump->um_dev = dev; ump->um_devvp = devvp; @@ -771,7 +775,9 @@ bsd_free(fs, M_EXT2MNT); bsd_free(ump, M_EXT2MNT); mp->mnt_data = (qaddr_t)0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); return (error); } ==== //depot/projects/newisp/gnu/fs/reiserfs/reiserfs_vfsops.c#2 (text+ko) ==== @@ -4,7 +4,7 @@ * * Ported to FreeBSD by Jean-Sébastien Pédron * - * $FreeBSD: src/sys/gnu/fs/reiserfs/reiserfs_vfsops.c,v 1.5 2006/05/26 11:58:30 rodrigc Exp $ + * $FreeBSD: src/sys/gnu/fs/reiserfs/reiserfs_vfsops.c,v 1.6 2006/09/26 04:12:47 tegge Exp $ */ #include @@ -241,7 +241,9 @@ } mp->mnt_data = (qaddr_t)0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); reiserfs_log(LOG_DEBUG, "done\n"); return (error); @@ -624,7 +626,9 @@ mp->mnt_data = (qaddr_t)rmp; mp->mnt_stat.f_fsid.val[0] = dev2udev(dev); mp->mnt_stat.f_fsid.val[1] = mp->mnt_vfc->vfc_typenum; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); #if defined(si_mountpoint) devvp->v_rdev->si_mountpoint = mp; #endif ==== //depot/projects/newisp/i386/conf/GENERIC#2 (text+ko) ==== @@ -16,7 +16,7 @@ # If you are in doubt as to the purpose or necessity of a line, check first # in NOTES. # -# $FreeBSD: src/sys/i386/conf/GENERIC,v 1.455 2006/07/25 01:06:32 yongari Exp $ +# $FreeBSD: src/sys/i386/conf/GENERIC,v 1.456 2006/09/26 12:36:34 ru Exp $ cpu I486_CPU cpu I586_CPU @@ -49,6 +49,7 @@ options COMPAT_43TTY # BSD 4.3 TTY compat [KEEP THIS!] options COMPAT_FREEBSD4 # Compatible with FreeBSD4 options COMPAT_FREEBSD5 # Compatible with FreeBSD5 +options COMPAT_FREEBSD6 # Compatible with FreeBSD6 options SCSI_DELAY=5000 # Delay (in ms) before probing SCSI options KTRACE # ktrace(1) support options SYSVSHM # SYSV-style shared memory ==== //depot/projects/newisp/ia64/conf/GENERIC#2 (text+ko) ==== @@ -18,7 +18,7 @@ # # For hardware specific information check HARDWARE.TXT # -# $FreeBSD: src/sys/ia64/conf/GENERIC,v 1.82 2006/07/09 16:39:37 mjacob Exp $ +# $FreeBSD: src/sys/ia64/conf/GENERIC,v 1.83 2006/09/26 12:36:34 ru Exp $ cpu ITANIUM ident GENERIC @@ -28,6 +28,7 @@ options CD9660 # ISO 9660 Filesystem options COMPAT_43TTY # BSD 4.3 TTY compat [KEEP THIS!] options COMPAT_FREEBSD5 # Compatible with FreeBSD5 +options COMPAT_FREEBSD6 # Compatible with FreeBSD6 options DDB # Support DDB options FFS # Berkeley Fast Filesystem options GDB # Support remote GDB ==== //depot/projects/newisp/isofs/cd9660/cd9660_vfsops.c#2 (text+ko) ==== @@ -35,7 +35,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/isofs/cd9660/cd9660_vfsops.c,v 1.145 2006/05/26 00:32:20 rodrigc Exp $"); +__FBSDID("$FreeBSD: src/sys/isofs/cd9660/cd9660_vfsops.c,v 1.146 2006/09/26 04:12:47 tegge Exp $"); #include #include @@ -137,7 +137,9 @@ /* * Unconditionally mount as read-only. */ + MNT_ILOCK(mp); mp->mnt_flag |= MNT_RDONLY; + MNT_IUNLOCK(mp); fspec = vfs_getopts(mp->mnt_optnew, "from", &error); if (error) @@ -378,7 +380,9 @@ mp->mnt_stat.f_fsid.val[0] = dev2udev(dev); mp->mnt_stat.f_fsid.val[1] = mp->mnt_vfc->vfc_typenum; mp->mnt_maxsymlinklen = 0; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; + MNT_IUNLOCK(mp); isomp->im_mountp = mp; isomp->im_dev = dev; isomp->im_devvp = devvp; @@ -528,7 +532,9 @@ vrele(isomp->im_devvp); free((caddr_t)isomp, M_ISOFSMNT); mp->mnt_data = (qaddr_t)0; + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_LOCAL; + MNT_IUNLOCK(mp); return (error); } ==== //depot/projects/newisp/kern/uipc_mqueue.c#2 (text+ko) ==== @@ -43,7 +43,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/kern/uipc_mqueue.c,v 1.15 2006/04/17 18:20:37 jhb Exp $"); +__FBSDID("$FreeBSD: src/sys/kern/uipc_mqueue.c,v 1.16 2006/09/26 04:12:47 tegge Exp $"); #include #include @@ -561,8 +561,10 @@ return (EOPNOTSUPP); mp->mnt_data = &mqfs_data; + MNT_ILOCK(mp); mp->mnt_flag |= MNT_LOCAL; mp->mnt_kern_flag |= MNTK_MPSAFE; + MNT_IUNLOCK(mp); vfs_getnewfsid(mp); sbp = &mp->mnt_stat; ==== //depot/projects/newisp/kern/vfs_cluster.c#2 (text+ko) ==== @@ -32,7 +32,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/kern/vfs_cluster.c,v 1.172 2006/03/21 01:04:24 tegge Exp $"); +__FBSDID("$FreeBSD: src/sys/kern/vfs_cluster.c,v 1.173 2006/09/26 04:15:58 tegge Exp $"); #include "opt_debug_cluster.h" @@ -595,7 +595,7 @@ int async; if (vp->v_type == VREG) { - async = vp->v_mount->mnt_flag & MNT_ASYNC; + async = vp->v_mount->mnt_kern_flag & MNTK_ASYNC; lblocksize = vp->v_mount->mnt_stat.f_iosize; } else { async = 0; ==== //depot/projects/newisp/kern/vfs_export.c#2 (text+ko) ==== @@ -35,7 +35,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/kern/vfs_export.c,v 1.335 2005/10/31 15:41:25 rwatson Exp $"); +__FBSDID("$FreeBSD: src/sys/kern/vfs_export.c,v 1.336 2006/09/26 04:12:47 tegge Exp $"); #include #include @@ -117,7 +117,9 @@ bcopy(argp->ex_anon.cr_groups, np->netc_anon.cr_groups, sizeof(np->netc_anon.cr_groups)); refcount_init(&np->netc_anon.cr_ref, 1); + MNT_ILOCK(mp); mp->mnt_flag |= MNT_DEFEXPORTED; + MNT_IUNLOCK(mp); return (0); } @@ -236,13 +238,17 @@ return (ENOENT); if (mp->mnt_flag & MNT_EXPUBLIC) { vfs_setpublicfs(NULL, NULL, NULL); + MNT_ILOCK(mp); mp->mnt_flag &= ~MNT_EXPUBLIC; + MNT_IUNLOCK(mp); } vfs_free_addrlist(nep); mp->mnt_export = NULL; free(nep, M_MOUNT); nep = NULL; + MNT_ILOCK(mp); mp->mnt_flag &= ~(MNT_EXPORTED | MNT_DEFEXPORTED); + MNT_IUNLOCK(mp); } if (argp->ex_flags & MNT_EXPORTED) { if (nep == NULL) { @@ -252,11 +258,15 @@ if (argp->ex_flags & MNT_EXPUBLIC) { if ((error = vfs_setpublicfs(mp, nep, argp)) != 0) return (error); + MNT_ILOCK(mp); mp->mnt_flag |= MNT_EXPUBLIC; + MNT_IUNLOCK(mp); } if ((error = vfs_hang_addrlist(mp, nep, argp))) return (error); + MNT_ILOCK(mp); mp->mnt_flag |= MNT_EXPORTED; + MNT_IUNLOCK(mp); } return (0); } ==== //depot/projects/newisp/kern/vfs_mount.c#3 (text+ko) ==== @@ -35,7 +35,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/kern/vfs_mount.c,v 1.233 2006/09/19 14:04:12 kib Exp $"); +__FBSDID("$FreeBSD: src/sys/kern/vfs_mount.c,v 1.238 2006/09/26 04:20:08 tegge Exp $"); #include #include @@ -471,7 +471,9 @@ mp->mnt_vfc = vfsp; vfsp->vfc_refcount++; /* XXX Unlocked */ mp->mnt_stat.f_type = vfsp->vfc_typenum; + MNT_ILOCK(mp); mp->mnt_flag |= vfsp->vfc_flags & MNT_VISFLAGMASK; + MNT_IUNLOCK(mp); strlcpy(mp->mnt_stat.f_fstypename, vfsp->vfc_name, MFSNAMELEN); mp->mnt_vnodecovered = vp; mp->mnt_cred = crdup(td->td_ucred); @@ -788,7 +790,7 @@ struct mount *mp; struct vfsconf *vfsp; struct export_args export; - int error, flag = 0, kern_flag = 0; + int error, flag = 0; struct vattr va; struct nameidata nd; @@ -848,17 +850,19 @@ return (EINVAL); } mp = vp->v_mount; + MNT_ILOCK(mp); flag = mp->mnt_flag; - kern_flag = mp->mnt_kern_flag; /* * We only allow the filesystem to be reloaded if it * is currently mounted read-only. */ if ((fsflags & MNT_RELOAD) && ((mp->mnt_flag & MNT_RDONLY) == 0)) { + MNT_IUNLOCK(mp); vput(vp); return (EOPNOTSUPP); /* Needs translation */ } + MNT_IUNLOCK(mp); /* * Only privileged root, or (if MNT_USER is set) the user that * did the original mount is permitted to update it. @@ -882,8 +886,10 @@ } vp->v_iflag |= VI_MOUNT; VI_UNLOCK(vp); + MNT_ILOCK(mp); mp->mnt_flag |= fsflags & (MNT_RELOAD | MNT_FORCE | MNT_UPDATE | MNT_SNAPSHOT | MNT_ROOTFS); + MNT_IUNLOCK(mp); VOP_UNLOCK(vp, 0, td); mp->mnt_optnew = fsdata; vfs_mergeopts(mp->mnt_optnew, mp->mnt_opt); @@ -935,10 +941,13 @@ /* * Set the mount level flags. */ - if (fsflags & MNT_RDONLY) - mp->mnt_flag |= MNT_RDONLY; - mp->mnt_flag &=~ MNT_UPDATEMASK; - mp->mnt_flag |= fsflags & (MNT_UPDATEMASK | MNT_FORCE | MNT_ROOTFS); + MNT_ILOCK(mp); + mp->mnt_flag = (mp->mnt_flag & ~MNT_UPDATEMASK) | + (fsflags & (MNT_UPDATEMASK | MNT_FORCE | MNT_ROOTFS | + MNT_RDONLY)); + if ((mp->mnt_flag & MNT_ASYNC) == 0) + mp->mnt_kern_flag &= ~MNTK_ASYNC; + MNT_IUNLOCK(mp); /* * Mount the filesystem. * XXX The final recipients of VFS_MOUNT just overwrite the ndp they @@ -968,12 +977,18 @@ */ mp->mnt_optnew = NULL; if (mp->mnt_flag & MNT_UPDATE) { - mp->mnt_flag &= - ~(MNT_UPDATE | MNT_RELOAD | MNT_FORCE | MNT_SNAPSHOT); - if (error) { - mp->mnt_flag = flag; - mp->mnt_kern_flag = kern_flag; - } + MNT_ILOCK(mp); + if (error) + mp->mnt_flag = (mp->mnt_flag & MNT_QUOTA) | + (flag & ~MNT_QUOTA); + else + mp->mnt_flag &= ~(MNT_UPDATE | MNT_RELOAD | + MNT_FORCE | MNT_SNAPSHOT); + if ((mp->mnt_flag & MNT_ASYNC) != 0 && mp->mnt_noasync == 0) + mp->mnt_kern_flag |= MNTK_ASYNC; + else + mp->mnt_kern_flag &= ~MNTK_ASYNC; + MNT_IUNLOCK(mp); if ((mp->mnt_flag & MNT_RDONLY) == 0) { if (mp->mnt_syncer == NULL) error = vfs_allocate_syncvnode(mp); @@ -989,6 +1004,12 @@ vrele(vp); return (error); } + MNT_ILOCK(mp); + if ((mp->mnt_flag & MNT_ASYNC) != 0 && mp->mnt_noasync == 0) + mp->mnt_kern_flag |= MNTK_ASYNC; + else + mp->mnt_kern_flag &= ~MNTK_ASYNC; + MNT_IUNLOCK(mp); vn_lock(vp, LK_EXCLUSIVE | LK_RETRY, td); /* * Put the new filesystem on the mount list after root. @@ -1185,8 +1206,11 @@ vfs_setpublicfs(NULL, NULL, NULL); vfs_msync(mp, MNT_WAIT); + MNT_ILOCK(mp); async_flag = mp->mnt_flag & MNT_ASYNC; mp->mnt_flag &= ~MNT_ASYNC; + mp->mnt_kern_flag &= ~MNTK_ASYNC; + MNT_IUNLOCK(mp); cache_purgevfs(mp); /* remove cache entries for this file sys */ if (mp->mnt_syncer != NULL) vrele(mp->mnt_syncer); @@ -1228,6 +1252,8 @@ MNT_ILOCK(mp); mp->mnt_kern_flag &= ~(MNTK_UNMOUNT | MNTK_UNMOUNTF); mp->mnt_flag |= async_flag; + if ((mp->mnt_flag & MNT_ASYNC) != 0 && mp->mnt_noasync == 0) + mp->mnt_kern_flag |= MNTK_ASYNC; lockmgr(&mp->mnt_lock, LK_RELEASE, NULL, td); if (mp->mnt_kern_flag & MNTK_MWAIT) wakeup(mp); ==== //depot/projects/newisp/kern/vfs_subr.c#3 (text+ko) ==== @@ -39,7 +39,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/kern/vfs_subr.c,v 1.682 2006/09/04 22:15:44 pjd Exp $"); +__FBSDID("$FreeBSD: src/sys/kern/vfs_subr.c,v 1.684 2006/09/26 04:15:58 tegge Exp $"); #include "opt_ddb.h" #include "opt_mac.h" @@ -3051,7 +3051,7 @@ struct vnode *syncvp = ap->a_vp; struct mount *mp = syncvp->v_mount; struct thread *td = ap->a_td; - int error, asyncflag; + int error; struct bufobj *bo; /* @@ -3081,12 +3081,17 @@ vfs_unbusy(mp, td); return (0); } - asyncflag = mp->mnt_flag & MNT_ASYNC; - mp->mnt_flag &= ~MNT_ASYNC; + MNT_ILOCK(mp); + mp->mnt_noasync++; + mp->mnt_kern_flag &= ~MNTK_ASYNC; + MNT_IUNLOCK(mp); vfs_msync(mp, MNT_NOWAIT); error = VFS_SYNC(mp, MNT_LAZY, td); - if (asyncflag) - mp->mnt_flag |= MNT_ASYNC; + MNT_ILOCK(mp); + mp->mnt_noasync--; + if ((mp->mnt_flag & MNT_ASYNC) != 0 && mp->mnt_noasync == 0) >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Wed Sep 27 00:13:00 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9A89A16A492; Wed, 27 Sep 2006 00:13:00 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 5BC2416A47B for ; Wed, 27 Sep 2006 00:13:00 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5EAD043D5C for ; Wed, 27 Sep 2006 00:12:59 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8R0Cx2B001554 for ; Wed, 27 Sep 2006 00:12:59 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8R0Cwsj001551 for perforce@freebsd.org; Wed, 27 Sep 2006 00:12:58 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 00:12:58 GMT Message-Id: <200609270012.k8R0Cwsj001551@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106752 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 00:13:00 -0000 http://perforce.freebsd.org/chv.cgi?CH=106752 Change 106752 by imp@imp_lighthouse on 2006/09/27 00:12:25 queue mmc commands to mmc bridge parts. now, to make the bridge part grok it... Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#5 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#4 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#6 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#5 (text+ko) ==== @@ -62,6 +62,12 @@ static void mmc_delayed_attach(void *); +static void +mmc_ms_delay(int ms) +{ + DELAY(1000 * ms); /* XXX BAD */ +} + static int mmc_probe(device_t dev) { @@ -132,9 +138,61 @@ } static void +mmc_wakeup(struct mmc_request *req) +{ + wakeup(req); +} + +static int +mmc_wait_for_req(struct mmc_softc *sc, struct mmc_request *req) +{ + int err; + + req->done = mmc_wakeup; + MMCBR_REQUEST(device_get_parent(sc->dev), sc->dev, req); + MMC_LOCK(sc); + do { + err = msleep(req, &sc->sc_mtx, PZERO | PCATCH, "mmcreq", + hz / 10); + } while (!(req->flags & MMC_REQ_DONE) && err == 0); + MMC_UNLOCK(sc); + return (err); +} + +static int +mmc_wait_for_cmd(struct mmc_softc *sc, struct mmc_command *cmd, int retries) +{ + struct mmc_request mreq; + + memset(&mreq, 0, sizeof(mreq)); + memset(cmd->resp, 0, sizeof(cmd->resp)); + cmd->retries = retries; + cmd->data = NULL; + mreq.cmd = cmd; + mmc_wait_for_req(sc, &mreq); + return (cmd->error); +} + +static void mmc_idle_cards(struct mmc_softc *sc) { - // XXX write me + device_t dev; + struct mmc_command cmd; + + dev = sc->dev; + mmcbr_set_chip_select(dev, cs_high); + mmcbr_update_ios(dev); + mmc_ms_delay(1); + + cmd.opcode = MMC_GO_IDLE_STATE; + cmd.arg = 0; + cmd.flags = MMC_RSP_NONE | MMC_CMD_BC; + mmc_wait_for_cmd(sc, &cmd, 0); + mmc_ms_delay(1); + + mmcbr_set_chip_select(dev, cs_dontcare); + mmcbr_update_ios(dev); + mmc_ms_delay(1); } static int @@ -164,14 +222,12 @@ mmcbr_set_power_mode(dev, power_up); mmcbr_set_clock(dev, 0); mmcbr_update_ios(dev); - - // delay 1ms ? + mmc_ms_delay(1); mmcbr_set_clock(dev, mmcbr_get_f_min(sc->dev)); mmcbr_set_power_mode(dev, power_on); mmcbr_update_ios(dev); - - // delay 2ms ? + mmc_ms_delay(2); } static void ==== //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#4 (text+ko) ==== ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#6 (text+ko) ==== @@ -25,7 +25,7 @@ */ #ifndef DEV_MMC_MMCREG_H -#define DEV_MMC_MMCREG_H +#define DEV_MMC_MMCREG_H /* * This file contains the register definitions for the mmc and sd busses. @@ -40,36 +40,44 @@ uint32_t arg; uint32_t resp[4]; uint32_t flags; /* Expected responses */ -#define MMC_RSP_NONE (0UL << 0) -#define MMC_RSP_SHORT (1UL << 0) -#define MMC_RSP_LONG (2UL << 0) -#define MMC_RSP_MASK (3UL << 0) -#define MMC_RSP_CRC (1UL << 3) /* Expect valid crc */ -#define MMC_RSP_BUSY (1UL << 4) /* Card may send busy */ +#define MMC_RSP_PRESENT (1ul << 0) /* Response */ +#define MMC_RSP_136 (1ul << 1) /* 136 bit response */ +#define MMC_RSP_CRC (1ul << 2) /* Expect valid crc */ +#define MMC_RSP_BUSY (1ul << 3) /* Card may send busy */ +#define MMC_RSP_OPCODE (1ul << 4) /* Response include opcode */ +#define MMC_CMD_AC (0ul << 5) /* AC? */ +#define MMC_CMD_ADTC (1ul << 5) /* ADTC? */ +#define MMC_CMD_BC (2ul << 5) /* BC? */ +#define MMC_CMD_BCR (3ul << 5) /* BCR? */ +#define MMC_RSP_MASK 0x1ful +#define MMC_CMD_MASK (3ul << 5) /* Possible response types defined in the standard: */ -#define MMC_RSP_R1 (MMC_RSP_SHORT | MMC_RSP_CRC) -#define MMC_RSP_R1B (MMC_RSP_SHORT | MMC_RSP_CRC | MMC_RSP_BUSY) -#define MMC_RSP_R2 (MMC_RSP_LONG | MMC_RSP_CRC) -#define MMC_RSP_R3 (MMC_RSP_SHORT) -#define MMC_RSP_R6 (MMC_RSP_SHORT | MMC_RSP_CRC) - uint32_t retires; +#define MMC_RSP_NONE (0) +#define MMC_RSP_R1 (MMC_RPS_PRESENT | MMC_RSP_CRC | MMC_RSP_OPCODE) +#define MMC_RSP_R1B (MMC_RSP_PRESENT | MMC_RSP_CRC | MMC_RSP_OPCODE | MMC_RSP_BUSY) +#define MMC_RSP_R2 (MMC_RSP_PRESENT | MMC_RSP_136 | MMC_RSP_CRC) +#define MMC_RSP_R3 (MMC_RSP_PRESENT) +#define MMC_RSP_R6 (MMC_RSP_PRESENT | MMC_RSP_CRC) +/* R7 -- new in sd 2.0 */ +#define MMC_RSP(x) ((x) & MMC_RSP_MASK) + uint32_t retries; uint32_t error; -#define MMC_ERR_NONE 0 -#define MMC_ERR_TIMEOUT 1 -#define MMC_ERR_BADCRC 2 -#define MMC_ERR_FIFO 3 -#define MMC_ERR_FAILED 4 -#define MMC_ERR_INVALID 5 +#define MMC_ERR_NONE 0 +#define MMC_ERR_TIMEOUT 1 +#define MMC_ERR_BADCRC 2 +#define MMC_ERR_FIFO 3 +#define MMC_ERR_FAILED 4 +#define MMC_ERR_INVALID 5 struct mmc_data *data; /* Data segment with cmd */ struct mmc_request *mrq; /* backpointer to request */ }; struct mmc_data { uint32_t flags; -#define MMC_DATA_WRITE (1UL << 8) -#define MMC_DATA_READ (1UL << 9) -#define MMC_DATA_STREAM (1UL << 10) +#define MMC_DATA_WRITE (1UL << 8) +#define MMC_DATA_READ (1UL << 9) +#define MMC_DATA_STREAM (1UL << 10) struct mmc_request *mrq; }; @@ -79,17 +87,122 @@ struct mmc_command *stop; void (*done)(struct mmc_request *); /* Completion function */ void *done_data; /* requestor set data */ + uint32_t flags; +#define MMC_REQ_DONE 1 }; +/* Command definitions */ + +/* Class 0 and 1: Basic commands & read stream commands */ +#define MMC_GO_IDLE_STATE 0 +#define MMC_SEND_OP_COND 1 +#define MMC_ALL_SEND_CID 2 +#define MMC_SET_RELATIVE_ADDR 3 +#define MMC_SET_DSR 4 + /* reserved: 5 */ +#define MMC_SELECT_CARD 7 +#define MMC_DESELECT_CARD 7 +#define MMC_SEND_IF_COND 8 +#define MMC_SEND_CSD 9 +#define MMC_SEND_CID 10 +#define MMC_READ_DAT_UNTIL_STOP 11 +#define MMC_STOP_TRANSMISSION 12 +#define MMC_SEND_STATUS 13 + /* reserved: 14 */ +#define MMC_GO_INACTIVE_STATE 15 + +/* Class 2: Block oriented read commands */ +#define MMC_SET_BLOCKLEN 16 +#define MMC_READ_SINGLE_BLOCK 17 +#define MMC_READ_MULTIPLE_BLOCK 18 + /* reserved: 19 */ + +/* Class 3: Stream write commands */ +#define MMC_WRITE_DAT_UNTIL_STOP 20 + /* reserved: 21 */ + /* reserved: 22 */ + +/* Class 4: Block oriented write commands */ +#define MMC_SET_BLOCK_COUNT 23 +#define MMC_WRITE_BLOCK 24 +#define MMC_WRITE_MULTIPLE_BLOCK 25 +#define MMC_PROGARM_CID 26 +#define MMC_PROGRAM_CSD 27 + +/* Class 6: Block oriented write protection commands */ +#define MMC_SET_WRITE_PROT 28 +#define MMC_CLR_WRITE_PROT 29 +#define MMC_SEND_WRITE_PROT 30 + /* reserved: 31 */ + +/* Class 5: Erase commands */ +#define SD_ERASE_WR_BLK_START 32 +#define SD_ERASE_WR_BLK_END 33 + /* 34 -- reserved old command */ +#define MMC_ERASE_GROUP_START 35 +#define MMC_ERASE_GROUP_END 36 + /* 37 -- reserved old command */ +#define MMC_ERASE 38 + +/* Class 9: I/O mode commands */ +#define MMC_FAST_IO 39 +#define MMC_GO_IRQ_STATE 40 + /* reserved: 41 */ + +/* Class 7: Lock card */ +#define MMC_LOCK_UNLOCK 42 + /* reserved: 43 */ + /* reserved: 44 */ + /* reserved: 45 */ + /* reserved: 46 */ + /* reserved: 47 */ + /* reserved: 48 */ + /* reserved: 49 */ + /* reserved: 50 */ + /* reserved: 51 */ + /* reserved: 54 */ + +/* Class 8: Application specific commands */ +#define MMC_APP_CMD 55 +#define MMC_GEN_CMD 56 + /* reserved: 57 */ + /* reserved: 58 */ + /* reserved: 59 */ + /* reserved for mfg: 60 */ + /* reserved for mfg: 61 */ + /* reserved for mfg: 62 */ + /* reserved for mfg: 63 */ + +/* Class 9: I/O cards (sd) */ +#define SD_IO_RW_DIRECT 52 +#define SD_IO_RW_EXTENDED 53 + +/* Class 10: Switch function commands */ +#define SD_SWITCH_FUNC 6 + /* reserved: 34 */ + /* reserved: 35 */ + /* reserved: 36 */ + /* reserved: 37 */ + /* reserved: 50 */ + /* reserved: 57 */ + + +/* Application specific commands for SD */ +#define ACMD_SET_BUS_WIDTH 6 +#define ACMD_SD_STATUS 13 +#define ACMD_SEND_NUM_WR_BLOCKS 22 +#define ACMD_SET_WR_BLK_ERASE_COUNT 23 +#define ACMD_SD_SEND_OP_COND 41 +#define ACMD_SET_CLR_CARD_DETECT 42 +#define ACMD_SEND_SCR 51 + /* OCR bits */ -#define MMC_OCR_145_150 (1U << 0) /* Vdd voltage 1.45 ~ 1.50 */ -#define MMC_OCR_150_155 (1U << 1) /* Vdd voltage 1.50 ~ 1.50 */ -#define MMC_OCR_155_160 (1U << 2) /* Vdd voltage 1.55 ~ 1.60 */ -#define MMC_OCR_160_165 (1U << 3) /* Vdd voltage 1.60 ~ 1.65 */ -#define MMC_OCR_165_170 (1U << 4) /* Vdd voltage 1.65 ~ 1.70 */ -#define MMC_OCR_170_180 (1U << 5) /* Vdd voltage 1.70 ~ 1.80 */ -#define MMC_OCR_180_190 (1U << 6) /* Vdd voltage 1.80 ~ 1.90 */ -#define MMC_OCR_190_200 (1U << 7) /* Vdd voltage 1.90 ~ 2.00 */ + +/* in SD 2.0 spec, bits 8-14 are now marked reserved */ +/* Low voltage in SD2.0 spec is bit 7, TBD voltage */ +/* Low voltage in MC 3.31 spec is bit 7, 1.65-1.95V */ +/* Linux has defines for lower bits down to 0, for reasons unknown */ +#define MMC_OCR_LOW_VOLTAGE (1u << 7) /* Low Voltage Range -- tbd */ #define MMC_OCR_200_210 (1U << 8) /* Vdd voltage 2.00 ~ 2.10 */ #define MMC_OCR_210_220 (1U << 9) /* Vdd voltage 2.10 ~ 2.20 */ #define MMC_OCR_220_230 (1U << 10) /* Vdd voltage 2.20 ~ 2.30 */ @@ -106,6 +219,7 @@ #define MMC_OCR_330_340 (1U << 21) /* Vdd voltage 3.30 ~ 3.40 */ #define MMC_OCR_340_350 (1U << 22) /* Vdd voltage 3.40 ~ 3.50 */ #define MMC_OCR_350_360 (1U << 23) /* Vdd voltage 3.50 ~ 3.60 */ -#define MMC_OCR_CARD_BUSY (1U << 31) /* Card Power up status */ +#define MMC_OCR_CCS (1u << 30) /* Card Capacity status (SD vs SDHC) */ +#define MMC_OCR_CARD_BUSY (1U << 31) /* Card Power up status */ #endif /* DEV_MMCREG_H */ From owner-p4-projects@FreeBSD.ORG Wed Sep 27 03:41:26 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D6CB516A412; Wed, 27 Sep 2006 03:41:25 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 AE61116A403 for ; Wed, 27 Sep 2006 03:41:25 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 59B5243D46 for ; Wed, 27 Sep 2006 03:41:25 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8R3fPsQ023391 for ; Wed, 27 Sep 2006 03:41:25 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8R3fO9Q023388 for perforce@freebsd.org; Wed, 27 Sep 2006 03:41:24 GMT (envelope-from mjacob@freebsd.org) Date: Wed, 27 Sep 2006 03:41:24 GMT Message-Id: <200609270341.k8R3fO9Q023388@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106755 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 03:41:26 -0000 http://perforce.freebsd.org/chv.cgi?CH=106755 Change 106755 by mjacob@newisp on 2006/09/27 03:40:43 IFC again. Affected files ... .. //depot/projects/newisp/conf/files#4 integrate .. //depot/projects/newisp/i386/i386/busdma_machdep.c#5 integrate .. //depot/projects/newisp/modules/libalias/Makefile#2 integrate .. //depot/projects/newisp/modules/libalias/libalias/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/Makefile.inc#1 branch .. //depot/projects/newisp/modules/libalias/modules/cuseeme/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/dummy/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/ftp/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/irc/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/modules.inc#1 branch .. //depot/projects/newisp/modules/libalias/modules/nbt/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/pptp/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/skinny/Makefile#1 branch .. //depot/projects/newisp/modules/libalias/modules/smedia/Makefile#1 branch .. //depot/projects/newisp/netinet/libalias/alias.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias.h#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_cuseeme.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_db.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_dummy.c#1 branch .. //depot/projects/newisp/netinet/libalias/alias_ftp.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_irc.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_local.h#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_mod.c#1 branch .. //depot/projects/newisp/netinet/libalias/alias_mod.h#1 branch .. //depot/projects/newisp/netinet/libalias/alias_nbt.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_old.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_pptp.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_proxy.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_skinny.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_smedia.c#2 integrate .. //depot/projects/newisp/netinet/libalias/alias_util.c#2 integrate .. //depot/projects/newisp/netinet/libalias/libalias.3#2 integrate Differences ... ==== //depot/projects/newisp/conf/files#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/files,v 1.1143 2006/09/25 11:40:14 scottl Exp $ +# $FreeBSD: src/sys/conf/files,v 1.1144 2006/09/26 23:26:51 piso Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -1744,16 +1744,11 @@ netinet/tcp_usrreq.c optional inet netinet/udp_usrreq.c optional inet netinet/libalias/alias.c optional libalias -netinet/libalias/alias_cuseeme.c optional libalias netinet/libalias/alias_db.c optional libalias -netinet/libalias/alias_ftp.c optional libalias -netinet/libalias/alias_irc.c optional libalias -netinet/libalias/alias_nbt.c optional libalias -netinet/libalias/alias_pptp.c optional libalias netinet/libalias/alias_proxy.c optional libalias -netinet/libalias/alias_skinny.c optional libalias -netinet/libalias/alias_smedia.c optional libalias netinet/libalias/alias_util.c optional libalias +netinet/libalias/alias_old.c optional libalias +netinet/libalias/alias_mod.c optional libalias netinet6/ah_aesxcbcmac.c optional ipsec netinet6/ah_core.c optional ipsec netinet6/ah_input.c optional ipsec ==== //depot/projects/newisp/i386/i386/busdma_machdep.c#5 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/i386/i386/busdma_machdep.c,v 1.83 2006/09/24 19:24:26 imp Exp $"); +__FBSDID("$FreeBSD: src/sys/i386/i386/busdma_machdep.c,v 1.84 2006/09/26 23:14:42 scottl Exp $"); #include #include @@ -53,7 +53,6 @@ #include #define MAX_BPAGES 512 -#define BUS_DMA_USE_FILTER BUS_DMA_BUS2 #define BUS_DMA_COULD_BOUNCE BUS_DMA_BUS3 #define BUS_DMA_MIN_ALLOC_COMP BUS_DMA_BUS4 @@ -269,8 +268,8 @@ newtag->boundary = MIN(parent->boundary, newtag->boundary); if ((newtag->filter != NULL) || - ((parent->flags & BUS_DMA_USE_FILTER) != 0)) - newtag->flags |= BUS_DMA_USE_FILTER; + ((parent->flags & BUS_DMA_COULD_BOUNCE) != 0)) + newtag->flags |= BUS_DMA_COULD_BOUNCE; if (newtag->filter == NULL) { /* * Short circuit looking at our parent directly @@ -583,7 +582,7 @@ while (vaddr < vendaddr) { paddr = pmap_kextract(vaddr); - if (((dmat->flags & BUS_DMA_USE_FILTER) != 0) && + if (((dmat->flags & BUS_DMA_COULD_BOUNCE) != 0) && run_filter(dmat, paddr) != 0) { needbounce = 1; map->pagesneeded++; @@ -682,7 +681,7 @@ sgsize = (baddr - curaddr); } - if (((dmat->flags & BUS_DMA_USE_FILTER) != 0) && + if (((dmat->flags & BUS_DMA_COULD_BOUNCE) != 0) && map->pagesneeded != 0 && run_filter(dmat, curaddr)) curaddr = add_bounce_page(dmat, map, vaddr, sgsize); ==== //depot/projects/newisp/modules/libalias/Makefile#2 (text+ko) ==== @@ -1,33 +1,5 @@ -# $FreeBSD: src/sys/modules/libalias/Makefile,v 1.2 2005/06/20 08:33:29 glebius Exp $ +# $FreeBSD: src/sys/modules/libalias/Makefile,v 1.3 2006/09/26 23:26:51 piso Exp $ -.PATH: ${.CURDIR}/../../netinet/libalias +SUBDIR= libalias modules -KMOD= libalias -SRCS= alias.c alias_cuseeme.c alias_db.c alias_ftp.c alias_irc.c \ - alias_nbt.c alias_pptp.c alias_proxy.c alias_skinny.c alias_smedia.c \ - alias_util.c -INCS= alias.h - -EXPORT_SYMS= LibAliasInit \ - LibAliasUninit \ - LibAliasSetAddress \ - LibAliasSetMode \ - LibAliasSkinnyPort \ - LibAliasIn \ - LibAliasOut \ - LibAliasRedirectPort \ - LibAliasRedirectAddr \ - LibAliasAddServer \ - LibAliasRedirectDynamic \ - LibAliasRedirectDelete \ - LibAliasProxyRule \ - LibAliasRedirectProto \ - LibAliasSaveFragment \ - LibAliasGetFragment \ - LibAliasFragmentIn \ - LibAliasSetTarget \ - LibAliasCheckNewLink \ - LibAliasInternetChecksum \ - LibAliasUnaliasOut - -.include +.include ==== //depot/projects/newisp/netinet/libalias/alias.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias.c,v 1.53 2005/06/27 22:21:42 phk Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias.c,v 1.54 2006/09/26 23:26:53 piso Exp $"); /* Alias.c provides supervisory control for the functions of the @@ -115,7 +115,11 @@ #include #else #include +#include #include +#include +#include +#include #endif #include @@ -128,22 +132,14 @@ #ifdef _KERNEL #include #include +#include #else +#include #include "alias.h" #include "alias_local.h" +#include "alias_mod.h" #endif -#define NETBIOS_NS_PORT_NUMBER 137 -#define NETBIOS_DGM_PORT_NUMBER 138 -#define FTP_CONTROL_PORT_NUMBER 21 -#define IRC_CONTROL_PORT_NUMBER_1 6667 -#define IRC_CONTROL_PORT_NUMBER_2 6668 -#define CUSEEME_PORT_NUMBER 7648 -#define RTSP_CONTROL_PORT_NUMBER_1 554 -#define RTSP_CONTROL_PORT_NUMBER_2 7070 -#define TFTP_PORT_NUMBER 69 -#define PPTP_CONTROL_PORT_NUMBER 1723 - static __inline int twowords(void *p) { @@ -725,24 +721,24 @@ struct in_addr original_address; u_short alias_port; int accumulate; - int r = 0; + int r = 0, error; + struct alias_data ad = { + .lnk = lnk, + .oaddr = &original_address, + .aaddr = &alias_address, + .aport = &alias_port, + .sport = &ud->uh_sport, + .dport = &ud->uh_dport, + .maxpktsize = 0 + }; alias_address = GetAliasAddress(lnk); original_address = GetOriginalAddress(lnk); alias_port = ud->uh_dport; ud->uh_dport = GetOriginalPort(lnk); -/* Special processing for IP encoding protocols */ - if (ntohs(ud->uh_dport) == CUSEEME_PORT_NUMBER) - AliasHandleCUSeeMeIn(la, pip, original_address); -/* If NETBIOS Datagram, It should be alias address in UDP Data, too */ - else if (ntohs(ud->uh_dport) == NETBIOS_DGM_PORT_NUMBER - || ntohs(ud->uh_sport) == NETBIOS_DGM_PORT_NUMBER) - r = AliasHandleUdpNbt(la, pip, lnk, &original_address, ud->uh_dport); - else if (ntohs(ud->uh_dport) == NETBIOS_NS_PORT_NUMBER - || ntohs(ud->uh_sport) == NETBIOS_NS_PORT_NUMBER) - r = AliasHandleUdpNbtNS(la, pip, lnk, &alias_address, &alias_port, - &original_address, &ud->uh_dport); + /* Walk out chain. */ + error = find_handler(IN, UDP, la, pip, &ad); /* If UDP checksum is not zero, then adjust since destination port */ /* is being unaliased and destination address is being altered. */ @@ -774,6 +770,7 @@ { struct udphdr *ud; struct alias_link *lnk; + int error; /* Return if proxy-only mode is enabled */ if (la->packetAliasMode & PKT_ALIAS_PROXY_ONLY) @@ -787,29 +784,21 @@ if (lnk != NULL) { u_short alias_port; struct in_addr alias_address; + struct alias_data ad = { + .lnk = lnk, + .oaddr = NULL, + .aaddr = &alias_address, + .aport = &alias_port, + .sport = &ud->uh_sport, + .dport = &ud->uh_dport, + .maxpktsize = 0 + }; alias_address = GetAliasAddress(lnk); alias_port = GetAliasPort(lnk); -/* Special processing for IP encoding protocols */ - if (ntohs(ud->uh_dport) == CUSEEME_PORT_NUMBER) - AliasHandleCUSeeMeOut(la, pip, lnk); -/* If NETBIOS Datagram, It should be alias address in UDP Data, too */ - else if (ntohs(ud->uh_dport) == NETBIOS_DGM_PORT_NUMBER - || ntohs(ud->uh_sport) == NETBIOS_DGM_PORT_NUMBER) - AliasHandleUdpNbt(la, pip, lnk, &alias_address, alias_port); - else if (ntohs(ud->uh_dport) == NETBIOS_NS_PORT_NUMBER - || ntohs(ud->uh_sport) == NETBIOS_NS_PORT_NUMBER) - AliasHandleUdpNbtNS(la, pip, lnk, &pip->ip_src, &ud->uh_sport, - &alias_address, &alias_port); -/* - * We don't know in advance what TID the TFTP server will choose, - * so we create a wilcard link (destination port is unspecified) - * that will match any TID from a given destination. - */ - else if (ntohs(ud->uh_dport) == TFTP_PORT_NUMBER) - FindRtspOut(la, pip->ip_src, pip->ip_dst, - ud->uh_sport, alias_port, IPPROTO_UDP); + /* Walk out chain. */ + error = find_handler(OUT, UDP, la, pip, &ad); /* If UDP checksum is not zero, adjust since source port is */ /* being aliased and source address is being altered */ @@ -855,15 +844,26 @@ struct in_addr proxy_address; u_short alias_port; u_short proxy_port; - int accumulate; + int accumulate, error; + + /* + * The init of MANY vars is a bit below, but aliashandlepptpin + * seems to need the destination port that came within the + * packet and not the original one looks below [*]. + */ + + struct alias_data ad = { + .lnk = lnk, + .oaddr = NULL, + .aaddr = NULL, + .aport = NULL, + .sport = &tc->th_sport, + .dport = &tc->th_dport, + .maxpktsize = 0 + }; -/* Special processing for IP encoding protocols */ - if (ntohs(tc->th_dport) == PPTP_CONTROL_PORT_NUMBER - || ntohs(tc->th_sport) == PPTP_CONTROL_PORT_NUMBER) - AliasHandlePptpIn(la, pip, lnk); - else if (la->skinnyPort != 0 && (ntohs(tc->th_dport) == la->skinnyPort - || ntohs(tc->th_sport) == la->skinnyPort)) - AliasHandleSkinny(la, pip, lnk); + /* Walk out chain. */ + error = find_handler(IN, TCP, la, pip, &ad); alias_address = GetAliasAddress(lnk); original_address = GetOriginalAddress(lnk); @@ -872,6 +872,28 @@ tc->th_dport = GetOriginalPort(lnk); proxy_port = GetProxyPort(lnk); + /* + * Look above, if anyone is going to add find_handler AFTER + * this aliashandlepptpin/point, please redo alias_data too. + * Uncommenting the piece here below should be enough. + */ +#if 0 + struct alias_data ad = { + .lnk = lnk, + .oaddr = &original_address, + .aaddr = &alias_address, + .aport = &alias_port, + .sport = &ud->uh_sport, + .dport = &ud->uh_dport, + .maxpktsize = 0 + }; + + /* Walk out chain. */ + error = find_handler(la, pip, &ad); + if (error == EHDNOF) + printf("Protocol handler not found\n"); +#endif + /* Adjust TCP checksum since destination port is being unaliased */ /* and destination port is being altered. */ accumulate = alias_port; @@ -926,7 +948,7 @@ static int TcpAliasOut(struct libalias *la, struct ip *pip, int maxpacketsize, int create) { - int proxy_type; + int proxy_type, error; u_short dest_port; u_short proxy_server_port; struct in_addr dest_address; @@ -973,6 +995,15 @@ u_short alias_port; struct in_addr alias_address; int accumulate; + struct alias_data ad = { + .lnk = lnk, + .oaddr = NULL, + .aaddr = &alias_address, + .aport = &alias_port, + .sport = &tc->th_sport, + .dport = &tc->th_dport, + .maxpktsize = maxpacketsize + }; /* Save original destination address, if this is a proxy packet. Also modify packet to include destination encoding. This may @@ -989,26 +1020,10 @@ /* Monitor TCP connection state */ TcpMonitorOut(pip, lnk); + + /* Walk out chain. */ + error = find_handler(OUT, TCP, la, pip, &ad); -/* Special processing for IP encoding protocols */ - if (ntohs(tc->th_dport) == FTP_CONTROL_PORT_NUMBER - || ntohs(tc->th_sport) == FTP_CONTROL_PORT_NUMBER) - AliasHandleFtpOut(la, pip, lnk, maxpacketsize); - else if (ntohs(tc->th_dport) == IRC_CONTROL_PORT_NUMBER_1 - || ntohs(tc->th_dport) == IRC_CONTROL_PORT_NUMBER_2) - AliasHandleIrcOut(la, pip, lnk, maxpacketsize); - else if (ntohs(tc->th_dport) == RTSP_CONTROL_PORT_NUMBER_1 - || ntohs(tc->th_sport) == RTSP_CONTROL_PORT_NUMBER_1 - || ntohs(tc->th_dport) == RTSP_CONTROL_PORT_NUMBER_2 - || ntohs(tc->th_sport) == RTSP_CONTROL_PORT_NUMBER_2) - AliasHandleRtspOut(la, pip, lnk, maxpacketsize); - else if (ntohs(tc->th_dport) == PPTP_CONTROL_PORT_NUMBER - || ntohs(tc->th_sport) == PPTP_CONTROL_PORT_NUMBER) - AliasHandlePptpOut(la, pip, lnk); - else if (la->skinnyPort != 0 && (ntohs(tc->th_sport) == la->skinnyPort - || ntohs(tc->th_dport) == la->skinnyPort)) - AliasHandleSkinny(la, pip, lnk); - /* Adjust TCP checksum since source port is being aliased */ /* and source address is being altered */ accumulate = tc->th_sport; @@ -1208,13 +1223,26 @@ case IPPROTO_TCP: iresult = TcpAliasIn(la, pip); break; - case IPPROTO_GRE: - if (la->packetAliasMode & PKT_ALIAS_PROXY_ONLY || - AliasHandlePptpGreIn(la, pip) == 0) + case IPPROTO_GRE: { + int error; + struct alias_data ad = { + .lnk = NULL, + .oaddr = NULL, + .aaddr = NULL, + .aport = NULL, + .sport = NULL, + .dport = NULL, + .maxpktsize = 0 + }; + + /* Walk out chain. */ + error = find_handler(IN, IP, la, pip, &ad); + if (error == 0) iresult = PKT_ALIAS_OK; else iresult = ProtoAliasIn(la, pip); - break; + } + break; default: iresult = ProtoAliasIn(la, pip); break; @@ -1321,12 +1349,25 @@ case IPPROTO_TCP: iresult = TcpAliasOut(la, pip, maxpacketsize, create); break; - case IPPROTO_GRE: - if (AliasHandlePptpGreOut(la, pip) == 0) - iresult = PKT_ALIAS_OK; - else - iresult = ProtoAliasOut(la, pip, create); - break; + case IPPROTO_GRE: { + int error; + struct alias_data ad = { + .lnk = NULL, + .oaddr = NULL, + .aaddr = NULL, + .aport = NULL, + .sport = NULL, + .dport = NULL, + .maxpktsize = 0 + }; + /* Walk out chain. */ + error = find_handler(OUT, IP, la, pip, &ad); + if (error == 0) + iresult = PKT_ALIAS_OK; + else + iresult = ProtoAliasOut(la, pip, create); + } + break; default: iresult = ProtoAliasOut(la, pip, create); break; @@ -1443,3 +1484,93 @@ return (iresult); } + +#ifndef _KERNEL + +int +LibAliasRefreshModules(void) +{ + char buf[256], conf[] = "/etc/libalias.conf"; + FILE *fd; + int len; + + fd = fopen(conf, "r"); + if (fd == NULL) + err(1, "fopen(%s)", conf); + + LibAliasUnLoadAllModule(); + + for (;;) { + fgets(buf, 256, fd); + if feof(fd) + break; + len = strlen(buf); + if (len > 1) { + buf[len - 1] = '\0'; + printf("Loading %s\n", buf); + LibAliasLoadModule(buf); + } + } + return (0); +} + +int +LibAliasLoadModule(char *path) +{ + struct dll *t; + void *handle; + struct proto_handler *m; + const char *error; + moduledata_t *p; + + handle = dlopen (path, RTLD_LAZY); + if (!handle) { + fputs (dlerror(), stderr); + return (EINVAL); + } + + p = dlsym(handle, "alias_mod"); + if ((error = dlerror()) != NULL) { + fputs(error, stderr); + return (EINVAL); + } + + t = malloc(sizeof(struct dll)); + if (t == NULL) + return (ENOMEM); + strncpy(t->name, p->name, DLL_LEN); + t->handle = handle; + if (attach_dll(t) == EEXIST) { + free(t); + fputs("dll conflict", stderr); + return (EEXIST); + } + + m = dlsym(t->handle, "handlers"); + if ((error = dlerror()) != NULL) { + fputs(error, stderr); + return (EINVAL); + } + + LibAliasAttachHandlers(m); + return (0); +} + +int +LibAliasUnLoadAllModule(void) +{ + struct dll *t; + struct proto_handler *p; + + /* Unload all modules then reload everything. */ + while ((p = first_handler()) != NULL) { + detach_handler(p); + } + while ((t = walk_dll_chain()) != NULL) { + dlclose(t->handle); + free(t); + } + return (1); +} + +#endif ==== //depot/projects/newisp/netinet/libalias/alias.h#2 (text+ko) ==== @@ -25,10 +25,10 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/netinet/libalias/alias.h,v 1.32 2005/05/05 21:53:17 glebius Exp $ + * $FreeBSD: src/sys/netinet/libalias/alias.h,v 1.33 2006/09/26 23:26:53 piso Exp $ */ -/*- +/* * Alias.h defines the outside world interfaces for the packet aliasing * software. * @@ -39,12 +39,16 @@ #ifndef _ALIAS_H_ #define _ALIAS_H_ +#include +#include +#include + +#define LIBALIAS_BUF_SIZE 128 #ifdef _KERNEL /* * The kernel version of libalias does not support these features. */ #define NO_FW_PUNCH -#define NO_LOGGING #define NO_USE_SOCKETS #endif @@ -180,6 +184,10 @@ /* Transparent proxying routines. */ int LibAliasProxyRule(struct libalias *, const char *_cmd); +/* Module handling API */ +int LibAliasLoadModule(char *); +int LibAliasUnLoadAllModule(void); +int LibAliasRefreshModules(void); /* * Mode flags and other constants. @@ -192,9 +200,7 @@ * If PKT_ALIAS_LOG is set, a message will be printed to /var/log/alias.log * every time a link is created or deleted. This is useful for debugging. */ -#ifndef NO_LOGGING #define PKT_ALIAS_LOG 0x01 -#endif /* * If PKT_ALIAS_DENY_INCOMING is set, then incoming connections (e.g. to ftp, ==== //depot/projects/newisp/netinet/libalias/alias_cuseeme.c#2 (text+ko) ==== @@ -27,11 +27,14 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_cuseeme.c,v 1.12 2005/05/05 21:55:17 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_cuseeme.c,v 1.13 2006/09/26 23:26:53 piso Exp $"); #ifdef _KERNEL #include +#include +#include #else +#include #include #include #endif @@ -44,10 +47,102 @@ #ifdef _KERNEL #include #include +#include #else #include "alias_local.h" +#include "alias_mod.h" #endif +#define CUSEEME_PORT_NUMBER 7648 + +static void +AliasHandleCUSeeMeOut(struct libalias *la, struct ip *pip, + struct alias_link *lnk); + +static void +AliasHandleCUSeeMeIn(struct libalias *la, struct ip *pip, + struct in_addr original_addr); + +static int +fingerprint(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + if (ah->dport == NULL || ah->oaddr == NULL) + return (-1); + if (ntohs(*ah->dport) == CUSEEME_PORT_NUMBER) + return (0); + return (-1); +} + +static int +protohandlerin(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + AliasHandleCUSeeMeIn(la, pip, *ah->oaddr); + return (0); +} + +static int +protohandlerout(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + AliasHandleCUSeeMeOut(la, pip, ah->lnk); + return (0); +} + +/* Kernel module definition. */ +struct proto_handler handlers[] = { + { + .pri = 120, + .dir = OUT, + .proto = UDP, + .fingerprint = &fingerprint, + .protohandler = &protohandlerout + }, + { + .pri = 120, + .dir = IN, + .proto = UDP, + .fingerprint = &fingerprint, + .protohandler = &protohandlerin + }, + { EOH } +}; + +static int +mod_handler(module_t mod, int type, void *data) +{ + int error; + + switch (type) { + case MOD_LOAD: + error = 0; + LibAliasAttachHandlers(handlers); + break; + case MOD_UNLOAD: + error = 0; + LibAliasDetachHandlers(handlers); + break; + default: + error = EINVAL; + } + return (error); +} + +#ifdef _KERNEL +static +#endif +moduledata_t +alias_mod = { + "alias_cuseeme", mod_handler, NULL +}; + +#ifdef _KERNEL +DECLARE_MODULE(alias_cuseeme, alias_mod, SI_SUB_DRIVERS, SI_ORDER_SECOND); +MODULE_VERSION(alias_cuseeme, 1); +MODULE_DEPEND(alias_cuseeme, libalias, 1, 1, 1); +#endif + /* CU-SeeMe Data Header */ struct cu_header { u_int16_t dest_family; @@ -77,7 +172,7 @@ * counts etc */ }; -void +static void AliasHandleCUSeeMeOut(struct libalias *la, struct ip *pip, struct alias_link *lnk) { struct udphdr *ud = ip_next(pip); @@ -100,7 +195,7 @@ } } -void +static void AliasHandleCUSeeMeIn(struct libalias *la, struct ip *pip, struct in_addr original_addr) { struct in_addr alias_addr; ==== //depot/projects/newisp/netinet/libalias/alias_db.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_db.c,v 1.68 2005/09/19 22:31:45 andre Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_db.c,v 1.69 2006/09/26 23:26:53 piso Exp $"); /* Alias_db.c encapsulates all data structures used for storing @@ -143,40 +143,32 @@ */ #ifdef _KERNEL +#include #include -#else -#include -#endif - -#include -#include -#include -#include - -#ifdef _KERNEL -#include #include -#include #include -#else +#include +#else +#include #include #include +#include +#include #include -#include #endif -/* BSD network include files */ -#include -#include -#include +#include #include #ifdef _KERNEL #include #include +#include +#include #else #include "alias.h" #include "alias_local.h" +#include "alias_mod.h" #endif static LIST_HEAD(, libalias) instancehead = LIST_HEAD_INITIALIZER(instancehead); @@ -358,10 +350,12 @@ switch (type) { case MOD_LOAD: error = 0; + handler_chain_init(); break; case MOD_QUIESCE: case MOD_UNLOAD: - finishoff(); + handler_chain_destroy(); + finishoff(); error = 0; break; default: @@ -409,12 +403,10 @@ #endif -#ifndef NO_LOGGING /* Log file control */ static void ShowAliasStats(struct libalias *); -static void InitPacketAliasLog(struct libalias *); +static int InitPacketAliasLog(struct libalias *); static void UninitPacketAliasLog(struct libalias *); -#endif static u_int StartPointIn(struct in_addr alias_addr, @@ -462,37 +454,55 @@ return (ntohl(y) - ntohl(x)); } +#ifdef _KERNEL + +static void +AliasLog(char *str, const char *format, ...) +{ + va_list ap; + + va_start(ap, format); + vsnprintf(str, LIBALIAS_BUF_SIZE, format, ap); + log(LOG_SECURITY | LOG_INFO, "%s\n", str); + va_end(ap); +} +#else +static void +AliasLog(FILE *stream, const char *format, ...) +{ + va_list ap; + + va_start(ap, format); + vfprintf(stream, format, ap); + va_end(ap); + fflush(stream); +} +#endif -#ifndef NO_LOGGING static void ShowAliasStats(struct libalias *la) { /* Used for debugging */ - - if (la->monitorFile) { - fprintf(la->monitorFile, - "icmp=%d, udp=%d, tcp=%d, pptp=%d, proto=%d, frag_id=%d frag_ptr=%d", - la->icmpLinkCount, - la->udpLinkCount, - la->tcpLinkCount, - la->pptpLinkCount, - la->protoLinkCount, - la->fragmentIdLinkCount, - la->fragmentPtrLinkCount); - - fprintf(la->monitorFile, " / tot=%d (sock=%d)\n", - la->icmpLinkCount + la->udpLinkCount - + la->tcpLinkCount - + la->pptpLinkCount - + la->protoLinkCount - + la->fragmentIdLinkCount - + la->fragmentPtrLinkCount, - la->sockCount); - - fflush(la->monitorFile); + if (la->logDesc) { + int tot = la->icmpLinkCount + la->udpLinkCount + + la->tcpLinkCount + la->pptpLinkCount + + la->protoLinkCount + la->fragmentIdLinkCount + + la->fragmentPtrLinkCount; + + AliasLog(la->logDesc, + "icmp=%u, udp=%u, tcp=%u, pptp=%u, proto=%u, frag_id=%u frag_ptr=%u / tot=%u", + la->icmpLinkCount, + la->udpLinkCount, + la->tcpLinkCount, + la->pptpLinkCount, + la->protoLinkCount, + la->fragmentIdLinkCount, + la->fragmentPtrLinkCount, tot); +#ifndef _KERNEL + AliasLog(la->logDesc, " (sock=%u)\n", la->sockCount); +#endif } } -#endif /* Internal routines for finding, deleting and adding links @@ -929,12 +939,10 @@ /* Free memory */ free(lnk); -#ifndef NO_LOGGING /* Write statistics, if logging enabled */ if (la->packetAliasMode & PKT_ALIAS_LOG) { ShowAliasStats(la); } -#endif } @@ -1072,11 +1080,9 @@ fprintf(stderr, "malloc() call failed.\n"); #endif } -#ifndef NO_LOGGING if (la->packetAliasMode & PKT_ALIAS_LOG) { ShowAliasStats(la); } -#endif return (lnk); } @@ -2203,30 +2209,40 @@ } } -#ifndef NO_LOGGING /* Init the log file and enable logging */ -static void +static int InitPacketAliasLog(struct libalias *la) { - if ((~la->packetAliasMode & PKT_ALIAS_LOG) - && (la->monitorFile = fopen("/var/log/alias.log", "w"))) { + if (~la->packetAliasMode & PKT_ALIAS_LOG) { +#ifdef _KERNEL + if ((la->logDesc = malloc(LIBALIAS_BUF_SIZE))) + ; +#else + if ((la->logDesc = fopen("/var/log/alias.log", "w"))) + fprintf(la->logDesc, "PacketAlias/InitPacketAliasLog: Packet alias logging enabled.\n"); +#endif + else + return (ENOMEM); /* log initialization failed */ la->packetAliasMode |= PKT_ALIAS_LOG; - fprintf(la->monitorFile, - "PacketAlias/InitPacketAliasLog: Packet alias logging enabled.\n"); } + + return (1); } /* Close the log-file and disable logging. */ static void UninitPacketAliasLog(struct libalias *la) { - if (la->monitorFile) { - fclose(la->monitorFile); - la->monitorFile = NULL; - } + if (la->logDesc) { >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Wed Sep 27 04:12:06 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 4D23216A415; Wed, 27 Sep 2006 04:12:06 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 0E35D16A407 for ; Wed, 27 Sep 2006 04:12:06 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 975C543D4C for ; Wed, 27 Sep 2006 04:12:05 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8R4C54k026052 for ; Wed, 27 Sep 2006 04:12:05 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8R4C5Y2026049 for perforce@freebsd.org; Wed, 27 Sep 2006 04:12:05 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 04:12:05 GMT Message-Id: <200609270412.k8R4C5Y2026049@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106756 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 04:12:06 -0000 http://perforce.freebsd.org/chv.cgi?CH=106756 Change 106756 by imp@imp_lighthouse on 2006/09/27 04:11:39 stub-out mmcbr methods.a Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#5 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#5 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#5 (text+ko) ==== @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2006 Berndt Walter. All rights reserved. + * Copyright (c) 2006 Bernd Walter. All rights reserved. * Copyright (c) 2006 M. Warner Losh. All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -56,6 +56,8 @@ #include #include +#include "mmcbr_if.h" + struct at91_mci_softc { void *intrhand; /* Interrupt handle */ device_t dev; @@ -242,10 +244,49 @@ } #endif +static int +at91_update_ios(device_t brdev, device_t reqdev) +{ + return (EIO); // XXX +} + +static int +at91_request(device_t brdev, device_t reqdev, struct mmc_request *req) +{ + return (EIO); // XXX +} + +static int +at91_get_ro(device_t brdev, device_t reqdev) +{ + return (-1); +} + +static int +at91_acquire_host(device_t brdev, device_t reqdev) +{ + return (EIO); // XXX +} + +static int +at91_release_host(device_t brdev, device_t reqdev) +{ + return (EIO); // XXX +} + static device_method_t at91_mci_methods[] = { + /* device_if */ DEVMETHOD(device_probe, at91_mci_probe), DEVMETHOD(device_attach, at91_mci_attach), DEVMETHOD(device_detach, at91_mci_detach), + + /* mmcbr_if */ + DEVMETHOD(mmcbr_update_ios, at91_update_ios), + DEVMETHOD(mmcbr_request, at91_request), + DEVMETHOD(mmcbr_get_ro, at91_get_ro), + DEVMETHOD(mmcbr_acquire_host, at91_acquire_host), + DEVMETHOD(mmcbr_release_host, at91_release_host), + {0, 0}, }; ==== //depot/projects/arm/src/sys/dev/mmc/mmcbr_if.m#5 (text+ko) ==== @@ -70,7 +70,7 @@ # Claim the current bridge, blocking the current thread until the host # is no longer busy. # -METHOD int aquire_host { +METHOD int acquire_host { device_t brdev; device_t reqdev; } From owner-p4-projects@FreeBSD.ORG Wed Sep 27 04:46:49 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9BA9116A416; Wed, 27 Sep 2006 04:46:49 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 5AF4716A407 for ; Wed, 27 Sep 2006 04:46:49 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 289DD43D53 for ; Wed, 27 Sep 2006 04:46:49 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8R4knsS027689 for ; Wed, 27 Sep 2006 04:46:49 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8R4km6D027686 for perforce@freebsd.org; Wed, 27 Sep 2006 04:46:48 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 04:46:48 GMT Message-Id: <200609270446.k8R4km6D027686@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106757 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 04:46:49 -0000 http://perforce.freebsd.org/chv.cgi?CH=106757 Change 106757 by imp@imp_lighthouse on 2006/09/27 04:45:59 fix spelling and values of a few registers. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mcireg.h#3 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mcireg.h#3 (text+ko) ==== @@ -51,8 +51,8 @@ #define MCI_CR_PWSDIS (0x1u << 3) /* (MCI) Power Save Mode Disable */ #define MCI_CR_SWRST (0x1u << 7) /* (MCI) Software Reset */ /* -------- MCI_MR : (MCI Offset: 0x4) MCI Mode Register -------- */ -#define MCI_MR_CLKDIV (0x1u << 0) /* (MCI) Clock Divider */ -#define MCI_MR_PWSDIV (0x1u << 8) /* (MCI) Power Saving Divider */ +#define MCI_MR_CLKDIV (0xffu << 0) /* (MCI) Clock Divider */ +#define MCI_MR_PWSDIV (0x3fu << 8) /* (MCI) Power Saving Divider */ #define MCI_MR_PDCPADV (0x1u << 14) /* (MCI) PDC Padding Value */ #define MCI_MR_PDCMODE (0x1u << 15) /* (MCI) PDC Oriented Mode */ #define MCI_MR_BLKLEN (0x1u << 18) /* (MCI) Data Block Length */ @@ -68,8 +68,8 @@ #define MCI_DTOR_DTOMUL_65536 (0x6u << 4) /* (MCI) DTOCYC x 65536 */ #define MCI_DTOR_DTOMUL_1M (0x7u << 4) /* (MCI) DTOCYC x 1048576 */ /* -------- MCI_SDCR : (MCI Offset: 0xc) MCI SD Card Register -------- */ -#define MCI_SDCR_SCDSEL (0x1u << 0) /* (MCI) SD Card Selector */ -#define MCI_SDCR_SCDBUS (0x1u << 7) /* (MCI) SD Card Bus Width */ +#define MCI_SDCR_SDCSEL (0x1u << 0) /* (MCI) SD Card Selector */ +#define MCI_SDCR_SDCBUS (0x1u << 7) /* (MCI) SD Card Bus Width */ /* -------- MCI_CMDR : (MCI Offset: 0x14) MCI Command Register -------- */ #define MCI_CMDR_CMDNB (0x1Fu << 0) /* (MCI) Command Number */ #define MCI_CMDR_RSPTYP (0x3u << 6) /* (MCI) Response Type */ From owner-p4-projects@FreeBSD.ORG Wed Sep 27 04:46:50 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D255616A558; Wed, 27 Sep 2006 04:46:49 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 AECAD16A4EC for ; Wed, 27 Sep 2006 04:46:49 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7C6FC43D53 for ; Wed, 27 Sep 2006 04:46:49 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8R4knpC027695 for ; Wed, 27 Sep 2006 04:46:49 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8R4kn97027692 for perforce@freebsd.org; Wed, 27 Sep 2006 04:46:49 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 04:46:49 GMT Message-Id: <200609270446.k8R4kn97027692@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106758 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 04:46:50 -0000 http://perforce.freebsd.org/chv.cgi?CH=106758 Change 106758 by imp@imp_lighthouse on 2006/09/27 04:46:40 Implement update_ios. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#6 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#6 (text+ko) ==== @@ -67,6 +67,7 @@ bus_dma_tag_t dmatag; bus_dmamap_t map; struct mmc_host host; + int wire4; }; static inline uint32_t @@ -247,7 +248,40 @@ static int at91_update_ios(device_t brdev, device_t reqdev) { - return (EIO); // XXX + uint32_t at91_master_clock = AT91C_MASTER_CLOCK; + struct at91_mci_softc *sc; + struct mmc_host *host; + struct mmc_ios *ios; + uint32_t clkdiv; + + sc = device_get_softc(brdev); + host = &sc->host; + ios = &host->ios; + // bus mode? + if (ios->clock == 0) { + WR4(sc, MCI_CR, MCI_CR_MCIDIS); + clkdiv = 0; + } else { + WR4(sc, MCI_CR, MCI_CR_MCIDIS); + if ((at91_master_clock % (ios->clock * 2)) == 0) + clkdiv = ((at91_master_clock / ios->clock) / 2) - 1; + else + clkdiv = (at91_master_clock / ios->clock) / 2; + } + if (ios->bus_width == bus_width_4 && sc->wire4) + WR4(sc, MCI_SDCR, RD4(sc, MCI_SDCR) | MCI_SDCR_SDCBUS); + else + WR4(sc, MCI_SDCR, RD4(sc, MCI_SDCR) & ~MCI_SDCR_SDCBUS); + WR4(sc, MCI_MR, (RD4(sc, MCI_MR) & ~MCI_MR_CLKDIV) | clkdiv); +#if 0 + if (sc->vcc_pin) { + if (sc->power_mode == MMC_POWER_OFF) + gpio_set(sc->vcc_pin, 0); + else + gpio_set(sc->vcc_pin, 1); + } +#endif + return (0); } static int From owner-p4-projects@FreeBSD.ORG Wed Sep 27 06:23:51 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B1D9616A417; Wed, 27 Sep 2006 06:23:51 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 7473116A403 for ; Wed, 27 Sep 2006 06:23:51 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3797B43D46 for ; Wed, 27 Sep 2006 06:23:51 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8R6NprY044315 for ; Wed, 27 Sep 2006 06:23:51 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8R6No11044312 for perforce@freebsd.org; Wed, 27 Sep 2006 06:23:50 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 06:23:50 GMT Message-Id: <200609270623.k8R6No11044312@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106761 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 06:23:52 -0000 http://perforce.freebsd.org/chv.cgi?CH=106761 Change 106761 by imp@imp_lighthouse on 2006/09/27 06:23:35 Make DTOCYC be a mask Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mcireg.h#4 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mcireg.h#4 (text+ko) ==== @@ -57,15 +57,15 @@ #define MCI_MR_PDCMODE (0x1u << 15) /* (MCI) PDC Oriented Mode */ #define MCI_MR_BLKLEN (0x1u << 18) /* (MCI) Data Block Length */ /* -------- MCI_DTOR : (MCI Offset: 0x8) MCI Data Timeout Register -------- */ -#define MCI_DTOR_DTOCYC (0x1u << 0) /* (MCI) Data Timeout Cycle Number */ +#define MCI_DTOR_DTOCYC (0xfu << 0) /* (MCI) Data Timeout Cycle Number */ #define MCI_DTOR_DTOMUL (0x7u << 4) /* (MCI) Data Timeout Multiplier */ #define MCI_DTOR_DTOMUL_1 (0x0u << 4) /* (MCI) DTOCYC x 1 */ #define MCI_DTOR_DTOMUL_16 (0x1u << 4) /* (MCI) DTOCYC x 16 */ #define MCI_DTOR_DTOMUL_128 (0x2u << 4) /* (MCI) DTOCYC x 128 */ #define MCI_DTOR_DTOMUL_256 (0x3u << 4) /* (MCI) DTOCYC x 256 */ -#define MCI_DTOR_DTOMUL_1024 (0x4u << 4) /* (MCI) DTOCYC x 1024 */ -#define MCI_DTOR_DTOMUL_4096 (0x5u << 4) /* (MCI) DTOCYC x 4096 */ -#define MCI_DTOR_DTOMUL_65536 (0x6u << 4) /* (MCI) DTOCYC x 65536 */ +#define MCI_DTOR_DTOMUL_1k (0x4u << 4) /* (MCI) DTOCYC x 1024 */ +#define MCI_DTOR_DTOMUL_4k (0x5u << 4) /* (MCI) DTOCYC x 4096 */ +#define MCI_DTOR_DTOMUL_64k (0x6u << 4) /* (MCI) DTOCYC x 65536 */ #define MCI_DTOR_DTOMUL_1M (0x7u << 4) /* (MCI) DTOCYC x 1048576 */ /* -------- MCI_SDCR : (MCI Offset: 0xc) MCI SD Card Register -------- */ #define MCI_SDCR_SDCSEL (0x1u << 0) /* (MCI) SD Card Selector */ From owner-p4-projects@FreeBSD.ORG Wed Sep 27 06:24:53 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3997116A47B; Wed, 27 Sep 2006 06:24:53 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 1882216A416 for ; Wed, 27 Sep 2006 06:24:53 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D8A6843D5C for ; Wed, 27 Sep 2006 06:24:52 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8R6OquP044346 for ; Wed, 27 Sep 2006 06:24:52 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8R6OqrE044343 for perforce@freebsd.org; Wed, 27 Sep 2006 06:24:52 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 06:24:52 GMT Message-Id: <200609270624.k8R6OqrE044343@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106762 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 06:24:53 -0000 http://perforce.freebsd.org/chv.cgi?CH=106762 Change 106762 by imp@imp_lighthouse on 2006/09/27 06:24:46 implement bus acquisision and release as kind of a poor-man's semaphore. Might be a good idea to add a device owner to the mix for sanity checking... Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#7 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#7 (text+ko) ==== @@ -68,6 +68,7 @@ bus_dmamap_t map; struct mmc_host host; int wire4; + int bus_busy; }; static inline uint32_t @@ -108,7 +109,7 @@ WR4(sc, MCI_CR, MCI_CR_MCIEN); /* Enable controller */ WR4(sc, MCI_IDR, 0xffffffff); /* Turn off interrupts */ - WR4(sc, MCI_DTOR, MCI_DTOR_DTOMUL_1M | MCI_DTOR_DTOCYC); + WR4(sc, MCI_DTOR, MCI_DTOR_DTOMUL_1M | 1); WR4(sc, MCI_MR, 0x834a); // XXX GROSS HACK FROM LINUX WR4(sc, MCI_SDCR, 0); /* SLOT A, 1 bit bus */ } @@ -133,7 +134,6 @@ static int at91_mci_attach(device_t dev) { - /* XXX: asumes MCK = 60MHz */ struct at91_mci_softc *sc = device_get_softc(dev); int err; device_t child; @@ -299,13 +299,27 @@ static int at91_acquire_host(device_t brdev, device_t reqdev) { - return (EIO); // XXX + struct at91_mci_softc *sc = device_get_softc(brdev); + int err = 0; + + AT91_MCI_LOCK(sc); + while (sc->bus_busy) + msleep(sc, &sc->sc_mtx, PZERO, "mciah", hz / 5); + sc->bus_busy++; + AT91_MCI_UNLOCK(sc); + return (err); } static int at91_release_host(device_t brdev, device_t reqdev) { - return (EIO); // XXX + struct at91_mci_softc *sc = device_get_softc(brdev); + + AT91_MCI_LOCK(sc); + sc->bus_busy--; + wakeup(sc); + AT91_MCI_UNLOCK(sc); + return (0); } static device_method_t at91_mci_methods[] = { From owner-p4-projects@FreeBSD.ORG Wed Sep 27 11:08:52 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 45C9916A51F; Wed, 27 Sep 2006 11:08:52 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 1A43616A51A for ; Wed, 27 Sep 2006 11:08:52 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id AF72A43D45 for ; Wed, 27 Sep 2006 11:08:51 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8RB8phw073088 for ; Wed, 27 Sep 2006 11:08:51 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8RB8me6073085 for perforce@freebsd.org; Wed, 27 Sep 2006 11:08:48 GMT (envelope-from piso@freebsd.org) Date: Wed, 27 Sep 2006 11:08:48 GMT Message-Id: <200609271108.k8RB8me6073085@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 106771 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 11:08:52 -0000 http://perforce.freebsd.org/chv.cgi?CH=106771 Change 106771 by piso@piso_newluxor on 2006/09/27 11:08:27 IFC@106770 Affected files ... .. //depot/projects/soc2005/libalias/contrib/telnet/telnetd/telnetd.c#2 integrate .. //depot/projects/soc2005/libalias/etc/Makefile#4 integrate .. //depot/projects/soc2005/libalias/lib/libalias/Makefile#7 integrate .. //depot/projects/soc2005/libalias/sbin/natd/natd.c#6 integrate .. //depot/projects/soc2005/libalias/share/examples/mdoc/example.4#3 integrate .. //depot/projects/soc2005/libalias/sys/conf/files#9 integrate .. //depot/projects/soc2005/libalias/sys/dev/mfi/mfi.c#5 integrate .. //depot/projects/soc2005/libalias/sys/dev/mfi/mfi_debug.c#2 integrate .. //depot/projects/soc2005/libalias/sys/i386/i386/busdma_machdep.c#4 integrate .. //depot/projects/soc2005/libalias/sys/modules/libalias/Makefile#8 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias.c#15 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias.h#5 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_cuseeme.c#14 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_db.c#12 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_ftp.c#13 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_irc.c#14 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_local.h#7 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_nbt.c#13 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_old.c#3 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_pptp.c#12 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_proxy.c#8 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_skinny.c#11 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_smedia.c#13 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_util.c#3 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/libalias.3#7 integrate .. //depot/projects/soc2005/libalias/sys/pci/agp_i810.c#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/id/id.1#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/id/id.c#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/vidcontrol/vidcontrol.c#2 integrate Differences ... ==== //depot/projects/soc2005/libalias/contrib/telnet/telnetd/telnetd.c#2 (text+ko) ==== @@ -37,7 +37,7 @@ #endif #endif #include -__FBSDID("$FreeBSD: src/contrib/telnet/telnetd/telnetd.c,v 1.28 2005/05/21 15:28:42 ume Exp $"); +__FBSDID("$FreeBSD: src/contrib/telnet/telnetd/telnetd.c,v 1.29 2006/09/26 21:46:11 ru Exp $"); #include "telnetd.h" #include "pathnames.h" @@ -1168,7 +1168,7 @@ ptyflush(); /* half-hearted */ #ifdef TCSIG - (void) ioctl(pty, TCSIG, (char *)SIGINT); + (void) ioctl(pty, TCSIG, SIGINT); #else /* TCSIG */ init_termbuf(); *pfrontp++ = slctab[SLC_IP].sptr ? @@ -1186,7 +1186,7 @@ { ptyflush(); /* half-hearted */ #ifdef TCSIG - (void) ioctl(pty, TCSIG, (char *)SIGQUIT); + (void) ioctl(pty, TCSIG, SIGQUIT); #else /* TCSIG */ init_termbuf(); *pfrontp++ = slctab[SLC_ABORT].sptr ? @@ -1200,7 +1200,7 @@ #ifdef SIGTSTP ptyflush(); /* half-hearted */ # ifdef TCSIG - (void) ioctl(pty, TCSIG, (char *)SIGTSTP); + (void) ioctl(pty, TCSIG, SIGTSTP); # else /* TCSIG */ *pfrontp++ = slctab[SLC_SUSP].sptr ? (unsigned char)*slctab[SLC_SUSP].sptr : '\032'; @@ -1217,7 +1217,7 @@ { #if defined(SIGINFO) && defined(TCSIG) if (slctab[SLC_AYT].sptr && *slctab[SLC_AYT].sptr != _POSIX_VDISABLE) { - (void) ioctl(pty, TCSIG, (char *)SIGINFO); + (void) ioctl(pty, TCSIG, SIGINFO); return; } #endif ==== //depot/projects/soc2005/libalias/etc/Makefile#4 (text+ko) ==== @@ -1,5 +1,5 @@ # from: @(#)Makefile 5.11 (Berkeley) 5/21/91 -# $FreeBSD: src/etc/Makefile,v 1.357 2006/08/31 09:51:33 cperciva Exp $ +# $FreeBSD: src/etc/Makefile,v 1.358 2006/09/26 23:26:48 piso Exp $ .include ==== //depot/projects/soc2005/libalias/lib/libalias/Makefile#7 (text+ko) ==== @@ -22,7 +22,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/Makefile,v 1.32 2006/09/26 23:26:49 piso Exp $ SUBDIR= libalias modules ==== //depot/projects/soc2005/libalias/sbin/natd/natd.c#6 (text+ko) ==== @@ -11,7 +11,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/natd/natd.c,v 1.49 2005/05/02 10:13:38 delphij Exp $"); +__FBSDID("$FreeBSD: src/sbin/natd/natd.c,v 1.50 2006/09/26 23:26:51 piso Exp $"); #define SYSLOG_NAMES ==== //depot/projects/soc2005/libalias/share/examples/mdoc/example.4#3 (text+ko) ==== @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/examples/mdoc/example.4,v 1.25 2006/09/18 15:18:54 ru Exp $ +.\" $FreeBSD: src/share/examples/mdoc/example.4,v 1.26 2006/09/26 19:59:52 danger Exp $ .\" .\" Note: The date here should be updated whenever a non-trivial .\" change is made to the manual page. @@ -33,11 +33,9 @@ .Nm example .Nd "example device driver manual page" .Sh SYNOPSIS -To compile the -.Ns Nm -driver into the kernel, -place the following lines in the -kernel configuration file: +To enable support for +.Ns Nm , +place the following lines in the kernel configuration file: .Bd -ragged -offset indent .Cd "device example" .Cd "options EXAMPLE_DEBUG" @@ -45,9 +43,9 @@ .Pp Alternatively, to load the .Ns Nm -driver as a -module at boot time, place the following line in -.Xr loader.conf 5 : +as a module at boot time, add the following line into the +.Xr loader.conf 5 +file: .Bd -literal -offset indent example_load="YES" .Ed ==== //depot/projects/soc2005/libalias/sys/conf/files#9 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/files,v 1.1143 2006/09/25 11:40:14 scottl Exp $ +# $FreeBSD: src/sys/conf/files,v 1.1144 2006/09/26 23:26:51 piso 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/soc2005/libalias/sys/dev/mfi/mfi.c#5 (text) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/mfi/mfi.c,v 1.18 2006/09/25 11:35:34 scottl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/mfi/mfi.c,v 1.19 2006/09/27 05:00:10 scottl Exp $"); #include "opt_mfi.h" @@ -2046,6 +2046,8 @@ deadline = time_uptime - MFI_CMD_TIMEOUT; mtx_lock(&sc->mfi_io_lock); TAILQ_FOREACH(cm, &sc->mfi_busy, cm_link) { + if (sc->mfi_aen_cm == cm) + continue; if (cm->cm_timestamp < deadline) { device_printf(sc->mfi_dev, "COMMAND %p TIMEOUT AFTER %d SECONDS\n", cm, ==== //depot/projects/soc2005/libalias/sys/dev/mfi/mfi_debug.c#2 (text+ko) ==== @@ -25,9 +25,9 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/mfi/mfi_debug.c,v 1.1 2006/09/25 11:35:34 scottl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/mfi/mfi_debug.c,v 1.2 2006/09/27 04:54:23 scottl Exp $"); -#include +#include "opt_mfi.h" #ifdef MFI_DEBUG ==== //depot/projects/soc2005/libalias/sys/i386/i386/busdma_machdep.c#4 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/i386/i386/busdma_machdep.c,v 1.83 2006/09/24 19:24:26 imp Exp $"); +__FBSDID("$FreeBSD: src/sys/i386/i386/busdma_machdep.c,v 1.84 2006/09/26 23:14:42 scottl Exp $"); #include #include @@ -53,7 +53,6 @@ #include #define MAX_BPAGES 512 -#define BUS_DMA_USE_FILTER BUS_DMA_BUS2 #define BUS_DMA_COULD_BOUNCE BUS_DMA_BUS3 #define BUS_DMA_MIN_ALLOC_COMP BUS_DMA_BUS4 @@ -269,8 +268,8 @@ newtag->boundary = MIN(parent->boundary, newtag->boundary); if ((newtag->filter != NULL) || - ((parent->flags & BUS_DMA_USE_FILTER) != 0)) - newtag->flags |= BUS_DMA_USE_FILTER; + ((parent->flags & BUS_DMA_COULD_BOUNCE) != 0)) + newtag->flags |= BUS_DMA_COULD_BOUNCE; if (newtag->filter == NULL) { /* * Short circuit looking at our parent directly @@ -583,7 +582,7 @@ while (vaddr < vendaddr) { paddr = pmap_kextract(vaddr); - if (((dmat->flags & BUS_DMA_USE_FILTER) != 0) && + if (((dmat->flags & BUS_DMA_COULD_BOUNCE) != 0) && run_filter(dmat, paddr) != 0) { needbounce = 1; map->pagesneeded++; @@ -682,7 +681,7 @@ sgsize = (baddr - curaddr); } - if (((dmat->flags & BUS_DMA_USE_FILTER) != 0) && + if (((dmat->flags & BUS_DMA_COULD_BOUNCE) != 0) && map->pagesneeded != 0 && run_filter(dmat, curaddr)) curaddr = add_bounce_page(dmat, map, vaddr, sgsize); ==== //depot/projects/soc2005/libalias/sys/modules/libalias/Makefile#8 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/Makefile,v 1.3 2006/09/26 23:26:51 piso Exp $ SUBDIR= libalias modules ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias.c#15 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias.c,v 1.53 2005/06/27 22:21:42 phk Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias.c,v 1.54 2006/09/26 23:26:53 piso Exp $"); /* Alias.c provides supervisory control for the functions of the ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias.h#5 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/netinet/libalias/alias.h,v 1.32 2005/05/05 21:53:17 glebius Exp $ + * $FreeBSD: src/sys/netinet/libalias/alias.h,v 1.33 2006/09/26 23:26:53 piso Exp $ */ /* ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_cuseeme.c#14 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_cuseeme.c,v 1.12 2005/05/05 21:55:17 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_cuseeme.c,v 1.13 2006/09/26 23:26:53 piso Exp $"); #ifdef _KERNEL #include ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_db.c#12 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_db.c,v 1.68 2005/09/19 22:31:45 andre Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_db.c,v 1.69 2006/09/26 23:26:53 piso Exp $"); /* Alias_db.c encapsulates all data structures used for storing ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_ftp.c#13 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_ftp.c,v 1.27 2005/06/27 07:36:02 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_ftp.c,v 1.28 2006/09/26 23:26:53 piso Exp $"); /* Alias_ftp.c performs special processing for FTP sessions under ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_irc.c#14 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_irc.c,v 1.21 2005/06/27 07:36:02 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_irc.c,v 1.22 2006/09/26 23:26:53 piso Exp $"); /* Alias_irc.c intercepts packages contain IRC CTCP commands, and changes DCC commands to export a port on the aliasing host instead ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_local.h#7 (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/netinet/libalias/alias_local.h,v 1.32 2005/06/27 07:36:02 glebius Exp $ + * $FreeBSD: src/sys/netinet/libalias/alias_local.h,v 1.33 2006/09/26 23:26:53 piso Exp $ */ /* ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_nbt.c#13 (text+ko) ==== @@ -29,7 +29,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_nbt.c,v 1.19 2005/05/06 11:07:49 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_nbt.c,v 1.20 2006/09/26 23:26:53 piso Exp $"); /* alias_nbt.c performs special processing for NetBios over TCP/IP ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_old.c#3 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_old.c,v 1.7 2005/05/05 19:27:32 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_old.c,v 1.8 2006/09/26 23:26:53 piso Exp $"); #ifdef _KERNEL #include ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_pptp.c#12 (text+ko) ==== @@ -37,7 +37,170 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_pptp.c,v 1.14 2005/05/05 21:55:17 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_pptp.c,v 1.15 2006/09/26 23:26:53 piso Exp $"); + +/* Includes */ +#ifdef _KERNEL +#include +#include +#include +#include +#else +#include +#include +#include +#include +#endif + +#include + +#ifdef _KERNEL +#include +#include +#include +#else +#include "alias.h" +#include "alias_local.h" +#include "alias_mod.h" +#endif + +#define PPTP_CONTROL_PORT_NUMBER 1723 + +static void +AliasHandlePptpOut(struct libalias *, struct ip *, struct alias_link *); + +static void +AliasHandlePptpIn(struct libalias *, struct ip *, struct alias_link *); + +static int +AliasHandlePptpGreOut(struct libalias *, struct ip *); + +static int +AliasHandlePptpGreIn(struct libalias *, struct ip *); + +static int +fingerprint(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + if (ah->dport == NULL || ah->sport == NULL || ah->lnk == NULL) + return (-1); + if (ntohs(*ah->dport) == PPTP_CONTROL_PORT_NUMBER + || ntohs(*ah->sport) == PPTP_CONTROL_PORT_NUMBER) + return (0); + return (-1); +} + +static int +fingerprintgre(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + return (0); +} + +static int +protohandlerin(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + AliasHandlePptpIn(la, pip, ah->lnk); + return (0); +} + +static int +protohandlerout(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + AliasHandlePptpOut(la, pip, ah->lnk); + return (0); +} + +static int +protohandlergrein(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + if (la->packetAliasMode & PKT_ALIAS_PROXY_ONLY || + AliasHandlePptpGreIn(la, pip) == 0) + return (0); + return (-1); +} + +static int +protohandlergreout(struct libalias *la, struct ip *pip, struct alias_data *ah) +{ + + if (AliasHandlePptpGreOut(la, pip) == 0) + return (0); + return (-1); +} + +/* Kernel module definition. */ +struct proto_handler handlers[] = { + { + .pri = 200, + .dir = IN, + .proto = TCP, + .fingerprint = &fingerprint, + .protohandler = &protohandlerin + }, + { + .pri = 210, + .dir = OUT, + .proto = TCP, + .fingerprint = &fingerprint, + .protohandler = &protohandlerout + }, +/* + * WATCH OUT!!! these 2 handlers NEED a priority of INT_MAX (highest possible) + * cause they will ALWAYS process packets, so they must be the last one + * in chain: look fingerprintgre() above. + */ + { + .pri = INT_MAX, + .dir = IN, + .proto = IP, + .fingerprint = &fingerprintgre, + .protohandler = &protohandlergrein + }, + { + .pri = INT_MAX, + .dir = OUT, + .proto = IP, + .fingerprint = &fingerprintgre, + .protohandler = &protohandlergreout + }, + { EOH } +}; +static int +mod_handler(module_t mod, int type, void *data) +{ + int error; + + switch (type) { + case MOD_LOAD: + error = 0; + LibAliasAttachHandlers(handlers); + break; + case MOD_UNLOAD: + error = 0; + LibAliasDetachHandlers(handlers); + break; + default: + error = EINVAL; + } + return (error); +} + +#ifdef _KERNEL +static +#endif +moduledata_t alias_mod = { + "alias_pptp", mod_handler, NULL +}; + +#ifdef _KERNEL +DECLARE_MODULE(alias_pptp, alias_mod, SI_SUB_DRIVERS, SI_ORDER_SECOND); +MODULE_VERSION(alias_pptp, 1); +MODULE_DEPEND(alias_pptp, libalias, 1, 1, 1); +#endif /* Includes */ #ifdef _KERNEL ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_proxy.c#8 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_proxy.c,v 1.26 2005/06/27 07:36:02 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_proxy.c,v 1.27 2006/09/26 23:26:53 piso Exp $"); /* file: alias_proxy.c ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_skinny.c#11 (text+ko) ==== @@ -27,7 +27,7 @@ * * Author: Joe Marcus Clarke * - * $FreeBSD: src/sys/netinet/libalias/alias_skinny.c,v 1.12 2005/06/27 07:36:02 glebius Exp $ + * $FreeBSD: src/sys/netinet/libalias/alias_skinny.c,v 1.13 2006/09/26 23:26:53 piso Exp $ */ #ifdef _KERNEL ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_smedia.c#13 (text+ko) ==== @@ -64,7 +64,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_smedia.c,v 1.15 2005/06/27 07:36:02 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_smedia.c,v 1.16 2006/09/26 23:26:53 piso Exp $"); /* Alias_smedia.c is meant to contain the aliasing code for streaming media ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_util.c#3 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_util.c,v 1.18 2005/06/27 07:36:02 glebius Exp $"); +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_util.c,v 1.19 2006/09/26 23:26:53 piso Exp $"); /* ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/libalias.3#7 (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/netinet/libalias/libalias.3,v 1.55 2006/07/04 20:39:38 maxim Exp $ +.\" $FreeBSD: src/sys/netinet/libalias/libalias.3,v 1.56 2006/09/26 23:26:53 piso Exp $ .\" .Dd July 04, 2006 .Dt LIBALIAS 3 ==== //depot/projects/soc2005/libalias/sys/pci/agp_i810.c#3 (text+ko) ==== @@ -31,7 +31,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/pci/agp_i810.c,v 1.38 2006/06/27 14:05:11 anholt Exp $"); +__FBSDID("$FreeBSD: src/sys/pci/agp_i810.c,v 1.39 2006/09/27 06:38:54 anholt Exp $"); #include "opt_bus.h" @@ -89,6 +89,8 @@ bus_space_tag_t gtt_bst; /* bus_space tag */ bus_space_handle_t gtt_bsh; /* bus_space handle */ + struct resource *gm; /* unmapped (but allocated) aperture */ + void *argb_cursor; /* contigmalloc area for ARGB cursor */ }; @@ -121,15 +123,10 @@ "Intel 82915G (915G GMCH) SVGA controller"}, {0x25928086, CHIP_I915, 0x00020000, "Intel 82915GM (915GM GMCH) SVGA controller"}, - /* XXX: I believe these chipsets should work, but they haven't been - * tested yet. - */ - /* {0x27728086, CHIP_I915, 0x00020000, "Intel 82945G (945G GMCH) SVGA controller"}, {0x27A28086, CHIP_I915, 0x00020000, "Intel 82945GM (945GM GMCH) SVGA controller"}, - */ {0, 0, 0, NULL} }; @@ -317,12 +314,30 @@ RF_ACTIVE); if (!sc->gtt) { bus_release_resource(dev, SYS_RES_MEMORY, - AGP_I810_MMADR, sc->regs); + AGP_I915_MMADR, sc->regs); agp_generic_detach(dev); return ENODEV; } sc->gtt_bst = rman_get_bustag(sc->gtt); sc->gtt_bsh = rman_get_bushandle(sc->gtt); + + /* While agp_generic_attach allocates the AGP_APBASE resource + * to try to reserve the aperture, on the 915 the aperture + * isn't in PCIR_BAR(0), it's in PCIR_BAR(2), so it allocated + * the registers that we just mapped anyway. So, allocate the + * aperture here, which also gives us easy access to it for the + * agp_i810_get_aperture(). + */ + rid = AGP_I915_GMADR; + sc->gm = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid, 0); + if (sc->gm == NULL) { + bus_release_resource(dev, SYS_RES_MEMORY, + AGP_I915_MMADR, sc->regs); + bus_release_resource(dev, SYS_RES_MEMORY, + AGP_I915_GTTADR, sc->regs); + agp_generic_detach(dev); + return ENODEV; + } } sc->initial_aperture = AGP_GET_APERTURE(dev); @@ -475,6 +490,8 @@ free(sc->gatt, M_AGP); if (sc->chiptype == CHIP_I915) { + bus_release_resource(dev, SYS_RES_MEMORY, AGP_I915_GMADR, + sc->gm); bus_release_resource(dev, SYS_RES_MEMORY, AGP_I915_GTTADR, sc->gtt); bus_release_resource(dev, SYS_RES_MEMORY, AGP_I915_MMADR, @@ -510,13 +527,12 @@ case CHIP_I855: return 128 * 1024 * 1024; case CHIP_I915: - temp = pci_read_config(dev, AGP_I915_MSAC, 1); - if ((temp & AGP_I915_MSAC_GMASIZE) == - AGP_I915_MSAC_GMASIZE_128) { - return 128 * 1024 * 1024; - } else { - return 256 * 1024 * 1024; - } + /* The documentation states that AGP_I915_MSAC should have bit + * 1 set if the aperture is 128MB instead of 256. However, + * that bit appears to not get set, so we instead use the + * aperture resource size, which should always be correct. + */ + return rman_get_size(sc->gm); } return 0; ==== //depot/projects/soc2005/libalias/usr.bin/id/id.1#3 (text+ko) ==== @@ -33,9 +33,9 @@ .\" SUCH DAMAGE. .\" .\" @(#)id.1 8.1 (Berkeley) 6/6/93 -.\" $FreeBSD: src/usr.bin/id/id.1,v 1.17 2006/09/23 15:43:29 rwatson Exp $ +.\" $FreeBSD: src/usr.bin/id/id.1,v 1.18 2006/09/26 22:28:12 ceri Exp $ .\" -.Dd May 3, 2004 +.Dd September 26, 2006 .Dt ID 1 .Os .Sh NAME @@ -89,6 +89,10 @@ Display the MAC label of the current process. .It Fl P Display the id as a password file entry. +.It Fl a +Ignored for compatibility with other +.Nm +implementations. .It Fl g Display the effective group ID as a number. .It Fl n ==== //depot/projects/soc2005/libalias/usr.bin/id/id.c#3 (text+ko) ==== @@ -43,7 +43,7 @@ #endif #endif /* not lint */ #include -__FBSDID("$FreeBSD: src/usr.bin/id/id.c,v 1.30 2006/09/26 05:46:55 ru Exp $"); +__FBSDID("$FreeBSD: src/usr.bin/id/id.c,v 1.31 2006/09/26 22:28:12 ceri Exp $"); #include #include @@ -96,7 +96,7 @@ } while ((ch = getopt(argc, argv, - (isgroups || iswhoami) ? "" : "APGMgnpru")) != -1) + (isgroups || iswhoami) ? "" : "APGMagnpru")) != -1) switch(ch) { #ifdef USE_BSM_AUDIT case 'A': @@ -112,6 +112,8 @@ case 'P': Pflag = 1; break; + case 'a': + break; case 'g': gflag = 1; break; ==== //depot/projects/soc2005/libalias/usr.sbin/vidcontrol/vidcontrol.c#2 (text+ko) ==== @@ -33,7 +33,7 @@ #ifndef lint static const char rcsid[] = - "$FreeBSD: src/usr.sbin/vidcontrol/vidcontrol.c,v 1.53 2005/09/17 12:52:04 rodrigc Exp $"; + "$FreeBSD: src/usr.sbin/vidcontrol/vidcontrol.c,v 1.54 2006/09/26 21:46:12 ru Exp $"; #endif /* not lint */ #include @@ -147,7 +147,7 @@ { int size[3]; - ioctl(0, VT_ACTIVATE, (caddr_t) (long) cur_info.active_vty); + ioctl(0, VT_ACTIVATE, cur_info.active_vty); fprintf(stderr, "\033[=%dA", cur_info.console_info.mv_ovscan); fprintf(stderr, "\033[=%dF", cur_info.console_info.mv_norm.fore); @@ -785,7 +785,7 @@ if (n < 1 || n > 16) { revert(); errx(1, "console number out of range"); - } else if (ioctl(0, VT_ACTIVATE, (caddr_t) (long) n) == -1) { + } else if (ioctl(0, VT_ACTIVATE, n) == -1) { revert(); errc(1, errno, "switching vty"); } From owner-p4-projects@FreeBSD.ORG Wed Sep 27 12:27:22 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1BBC416A415; Wed, 27 Sep 2006 12:27:22 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 E730316A407; Wed, 27 Sep 2006 12:27:21 +0000 (UTC) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3CED143D46; Wed, 27 Sep 2006 12:27:21 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from laptop.freebsd.czest.pl (gw98.internetdsl.tpnet.pl [80.53.74.98]) by freebsd.czest.pl (8.13.4/8.12.9) with ESMTP id k8RCllTd097091; Wed, 27 Sep 2006 12:47:49 GMT (envelope-from dunstan@freebsd.czest.pl) Received: from laptop.freebsd.czest.pl (localhost [127.0.0.1]) by laptop.freebsd.czest.pl (8.13.7/8.13.7) with ESMTP id k8S8aRnq003296; Thu, 28 Sep 2006 08:36:27 GMT (envelope-from dunstan@laptop.freebsd.czest.pl) Received: (from dunstan@localhost) by laptop.freebsd.czest.pl (8.13.7/8.13.4/Submit) id k8S8aQ9F003295; Thu, 28 Sep 2006 08:36:26 GMT (envelope-from dunstan) Date: Thu, 28 Sep 2006 08:36:24 +0000 From: "Wojciech A. Koszek" To: Alexander Leidinger Message-ID: <20060928083623.GA1297@FreeBSD.czest.pl> Mail-Followup-To: Alexander Leidinger , Perforce Change Reviews , saper@SYSTEM.PL References: <200609091856.k89Iu9lN090213@repoman.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline In-Reply-To: <200609091856.k89Iu9lN090213@repoman.freebsd.org> User-Agent: Mutt/1.5.11 X-Greylist: Sender DNS name whitelisted, not delayed by milter-greylist-2.0.2 (freebsd.czest.pl [80.48.250.4]); Wed, 27 Sep 2006 12:47:49 +0000 (UTC) Cc: saper@SYSTEM.PL, Perforce Change Reviews Subject: Re: PERFORCE change 105906 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 12:27:22 -0000 On sob, wrz 09, 2006 at 06:56:09 +0000, Alexander Leidinger wrote: > http://perforce.freebsd.org/chv.cgi?CH=105906 > > Change 105906 by netchild@netchild_magellan on 2006/09/09 18:56:01 > > Current Linux getsockopt() does not support SO_PEERCRED option used to > fetch UNIX domain socket peer PID, UID and GID. > > Without this option ORACLE 10i Express Edition lsnrctl is unable to > issue commands to a running listener (including "status" and "stop"). > All invocations result in the message: > TNS-01189: The listener could not authenticate the user > > Linux lsnrctl using so called "OS Authentication" mode probes if UNIX > socket connection peer is the process run under to privileged "dba" > group (or another group listed in the DBA_GROUP parameter of the > $ORACLE_HOME/network/admin/listener.ora file). > > Security of this patch is not tested. > > Known problem: Peer PID recognition is not done, we always return zero. > > PR: 102956 > Submitted by: Marcin Cieslak > > Affected files ... > > .. //depot/projects/linuxolator/src/sys/amd64/linux32/linux.h#2 edit > .. //depot/projects/linuxolator/src/sys/compat/linux/linux_socket.c#2 edit > .. //depot/projects/linuxolator/src/sys/i386/linux/linux.h#2 edit > > Differences ... > > ==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux.h#2 (text+ko) ==== > > @@ -659,6 +659,7 @@ > #define LINUX_SO_NO_CHECK 11 > #define LINUX_SO_PRIORITY 12 > #define LINUX_SO_LINGER 13 > +#define LINUX_SO_PEERCRED 17 > > #define LINUX_IP_TOS 1 > #define LINUX_IP_TTL 2 > > ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_socket.c#2 (text+ko) ==== > > @@ -35,6 +35,7 @@ > > #include > #include > +#include > #include > #include > #include > @@ -49,6 +50,7 @@ > #include > #include > #include > +#include > > #include > #include > @@ -292,6 +294,8 @@ > return (SO_OOBINLINE); > case LINUX_SO_LINGER: > return (SO_LINGER); > + case LINUX_SO_PEERCRED: > + return (LOCAL_PEERCRED); > } > return (-1); > } > @@ -1171,7 +1175,13 @@ > caddr_t val; > int *avalsize; > } */ bsd_args; > - int error, name; > + struct linux_ucred { > + uint32_t pid; > + uint32_t uid; > + uint32_t gid; > + } linux_ucred; > + struct xucred xuc; > + int error, name, optlen, rc, xuclen; > > if ((error = copyin(args, &linux_args, sizeof(linux_args)))) > return (error); > @@ -1193,12 +1203,43 @@ > name = -1; > break; > } > - if (name == -1) > + if (name == -1) { > + log(LOG_WARNING, "LINUX: 'getsockopt' level=0x%04x" > + "optname=0x%04x not implemented\n", > + linux_args.level, linux_args.optname); > return (EINVAL); > + }; > > bsd_args.name = name; > - bsd_args.val = PTRIN(linux_args.optval); > - bsd_args.avalsize = PTRIN(linux_args.optlen); > + if (bsd_args.level == SOL_SOCKET && name == LOCAL_PEERCRED) { > + if ((error = copyin(PTRIN(linux_args.optval), > + &linux_ucred, sizeof(linux_ucred)))) > + return (error); > + if ((error = copyin(PTRIN(linux_args.optlen), > + &optlen, sizeof(optlen)))) > + return (error); > + if (optlen < sizeof(linux_ucred)) > + return (EFAULT); > + xuclen = sizeof(xuc); > + if ((rc = error = kern_getsockopt(td, bsd_args.s, > + 0, bsd_args.name, > + (caddr_t) &xuc, UIO_SYSSPACE, &xuclen))) > + return (error); > + if (xuc.cr_version != XUCRED_VERSION) > + return (EINVAL); > + /* XXX get PID */ > + linux_ucred.pid = 0; > + linux_ucred.uid = xuc.cr_uid; > + linux_ucred.gid = xuc.cr_gid; > + if ((error = copyout(&linux_ucred, > + PTRIN(linux_args.optval), sizeof(linux_ucred)))) > + return (error); > + return (rc); > + } else { > + bsd_args.val = PTRIN(linux_args.optval); > + bsd_args.avalsize = PTRIN(linux_args.optlen); > + return (getsockopt(td, &bsd_args)); > + } > > if (name == IPV6_NEXTHOP) { > error = getsockopt(td, &bsd_args); > > ==== //depot/projects/linuxolator/src/sys/i386/linux/linux.h#2 (text+ko) ==== > > @@ -633,6 +633,7 @@ > #define LINUX_SO_NO_CHECK 11 > #define LINUX_SO_PRIORITY 12 > #define LINUX_SO_LINGER 13 > +#define LINUX_SO_PEERCRED 17 > > #define LINUX_IP_TOS 1 > #define LINUX_IP_TTL 2 I'm not sure if this patch is correct. I looked briefly over Marcin's report, and the code path responsible for handling translation between what Linux relies on and what FreeBSD requires. We tend to push the whole job in sogetopt() function, which in turn deploys uipc_ctloutput() function. With this mechanism, I belive it is possible to handle LOCAL_PEERCRED without a problem. The only exception is that the SOL_SOCKET has to be mapped to other value, like 0. This is what we actually do in getpeereid() case: int getpeereid(int s, uid_t *euid, gid_t *egid) { struct xucred xuc; socklen_t xuclen; int error; xuclen = sizeof(xuc); error = getsockopt(s, 0, LOCAL_PEERCRED, &xuc, &xuclen); if (error != 0) return (error); if (xuc.cr_version != XUCRED_VERSION) return (EINVAL); *euid = xuc.cr_uid; *egid = xuc.cr_gid; return (0); } -- Wojciech A. Koszek wkoszek@FreeBSD.org http://FreeBSD.czest.pl/dunstan/ From owner-p4-projects@FreeBSD.ORG Wed Sep 27 13:27:38 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1A05D16A47B; Wed, 27 Sep 2006 13:27:38 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 B847F16A40F; Wed, 27 Sep 2006 13:27:37 +0000 (UTC) (envelope-from saper@SYSTEM.PL) Received: from mail01.ish.de (pip249.ish.de [80.69.98.249]) by mx1.FreeBSD.org (Postfix) with ESMTP id E683A43D46; Wed, 27 Sep 2006 13:27:36 +0000 (GMT) (envelope-from saper@SYSTEM.PL) Received: from [80.69.97.9] (HELO saperski.saper.info) by mail-fe-02.mail01.ish.de (CommuniGate Pro SMTP 5.0.6) with ESMTPS id 67985462; Wed, 27 Sep 2006 15:27:34 +0200 Received: from [127.0.0.1] (saperski.saper.info [127.0.0.1]) by saperski.saper.info (8.13.8/8.13.8) with ESMTP id k8RDRHdt013274 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Wed, 27 Sep 2006 15:27:32 +0200 (CEST) (envelope-from saper@SYSTEM.PL) Message-ID: <451A7C35.8050209@SYSTEM.PL> Date: Wed, 27 Sep 2006 15:27:17 +0200 From: Marcin Cieslak User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.0.7) Gecko/20060926 SeaMonkey/1.0.5 MIME-Version: 1.0 To: Alexander Leidinger , Perforce Change Reviews , saper@SYSTEM.PL References: <200609091856.k89Iu9lN090213@repoman.freebsd.org> <20060928083623.GA1297@FreeBSD.czest.pl> In-Reply-To: <20060928083623.GA1297@FreeBSD.czest.pl> X-Enigmail-Version: 0.94.1.0 Content-Type: text/plain; charset=ISO-8859-2 Content-Transfer-Encoding: 7bit Cc: Subject: Re: PERFORCE change 105906 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 13:27:38 -0000 Wojciech A. Koszek wrote: What I basically do is: Try to copy safely whatever caller provided us with: >> + if (bsd_args.level == SOL_SOCKET && name == LOCAL_PEERCRED) { >> + if ((error = copyin(PTRIN(linux_args.optval), >> + &linux_ucred, sizeof(linux_ucred)))) >> + return (error); >> + if ((error = copyin(PTRIN(linux_args.optlen), >> + &optlen, sizeof(optlen)))) >> + return (error); >> + if (optlen < sizeof(linux_ucred)) >> + return (EFAULT); >> + xuclen = sizeof(xuc); I just really need to copy the result into different structure (unfortunately I think I can't use Linux structure provided by the caller). >> + /* XXX get PID */ >> + linux_ucred.pid = 0; >> + linux_ucred.uid = xuc.cr_uid; >> + linux_ucred.gid = xuc.cr_gid; >> + if ((error = copyout(&linux_ucred, >> + PTRIN(linux_args.optval), sizeof(linux_ucred)))) >> + return (error); >> + return (rc); > I'm not sure if this patch is correct. I looked briefly over Marcin's > report, and the code path responsible for handling translation between what > Linux relies on and what FreeBSD requires. We tend to push the whole job in > sogetopt() function, which in turn deploys uipc_ctloutput() function. With > this mechanism, I belive it is possible to handle LOCAL_PEERCRED without a > problem. The only exception is that the SOL_SOCKET has to be mapped to other > value, like 0. This is what we actually do in getpeereid() case: I don't I know if I understand this correctly; I will try to explain why I did it this way - the most important reason being my limited knowledge of BSD kernel inner workings (I only studied Steven's TCP/IP vol. 2 for that purpose long time ago). I faced following design choice: 1) Just wrap FreeBSD call with minimal effort (I only duplicate functionality of sooptcopyin(), sooptcopyout() in my code). Not a nice way, however such approach work for most of the cases in the linuxolator. 2) Provide copy of kern_getsockopt(), sogetopt() etc. just to provide own version of uipc_ctloutput() fragment to write the result down to the Linux structure. This requires some care about lock and freeing memory structures. Also if somebody for some reason restructures FreeBSD networking code there, Linux emulation will be probably left aside - I've seen already one case where Linux emulation mmap() was not up to date with FreeBSD mmap() advances. 3) Provide some other way to plug another return structure for uipc_ctloutput(). Probably the right way will be something between 1) and 2) - decide how deep Linux sockopt functions replace sogetopt() and go immediately to the level below in the respective networking code. But I think I have not enough experience to decide on that. It may happen that implementing delivery of the process ID of the other side of the socket - feature not available AFAIK in the FreeBSD right now - will impose on us much deeper dive into internal socket structures. -- << Marcin Cieslak // saper@system.pl >> From owner-p4-projects@FreeBSD.ORG Wed Sep 27 15:06:57 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 38D4316A407; Wed, 27 Sep 2006 15:06:57 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 EFCFA16A417 for ; Wed, 27 Sep 2006 15:06:56 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9A69F43D46 for ; Wed, 27 Sep 2006 15:06:56 +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.6/8.13.6) with ESMTP id k8RF6urO001903 for ; Wed, 27 Sep 2006 15:06:56 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8RF6uEx001900 for perforce@freebsd.org; Wed, 27 Sep 2006 15:06:56 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 27 Sep 2006 15:06:56 GMT Message-Id: <200609271506.k8RF6uEx001900@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 Cc: Subject: PERFORCE change 106780 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 15:06:57 -0000 http://perforce.freebsd.org/chv.cgi?CH=106780 Change 106780 by rwatson@rwatson_zoo on 2006/09/27 15:06:09 Add privilege and privilege checks for Bluetooth. Reported by: wkoszek Affected files ... .. //depot/projects/trustedbsd/priv/sys/netgraph/bluetooth/drivers/h4/ng_h4.c#2 edit .. //depot/projects/trustedbsd/priv/sys/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c#2 edit .. //depot/projects/trustedbsd/priv/sys/netgraph/bluetooth/socket/ng_btsocket_l2cap_raw.c#2 edit .. //depot/projects/trustedbsd/priv/sys/sys/priv.h#3 edit Differences ... ==== //depot/projects/trustedbsd/priv/sys/netgraph/bluetooth/drivers/h4/ng_h4.c#2 (text+ko) ==== @@ -48,6 +48,7 @@ #include #include #include +#include #include #include #include @@ -156,7 +157,7 @@ int s, error; /* Super-user only */ - error = suser(curthread); /* XXX */ + error = priv_check(curthread, PRIV_NETGRAPH_TTY); /* XXX */ if (error != 0) return (error); ==== //depot/projects/trustedbsd/priv/sys/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c#2 (text+ko) ==== @@ -44,6 +44,7 @@ #include #include #include +#include #include #include #include @@ -916,7 +917,7 @@ so->so_pcb = (caddr_t) pcb; pcb->so = so; - if (suser(td) == 0) + if (priv_check(td, PRIV_NETBLUETOOTH_RAW) == 0) pcb->flags |= NG_BTSOCKET_HCI_RAW_PRIVILEGED; /* ==== //depot/projects/trustedbsd/priv/sys/netgraph/bluetooth/socket/ng_btsocket_l2cap_raw.c#2 (text+ko) ==== @@ -43,6 +43,7 @@ #include #include #include +#include #include #include #include @@ -620,7 +621,7 @@ so->so_pcb = (caddr_t) pcb; pcb->so = so; - if (suser(td) == 0) + if (priv_check(td, PRIV_NETBLUETOOTH_RAW) == 0) pcb->flags |= NG_BTSOCKET_L2CAP_RAW_PRIVILEGED; mtx_init(&pcb->pcb_mtx, "btsocks_l2cap_raw_pcb_mtx", NULL, MTX_DEF); ==== //depot/projects/trustedbsd/priv/sys/sys/priv.h#3 (text+ko) ==== @@ -213,6 +213,7 @@ PRIV_NETATM_ADD, PRIV_NETATM_DEL, PRIV_NETATM_SET, + PRIV_NETBLUETOOTH_RAW, /* Open raw bluetooth socket. */ PRIV_NETGRAPH_CONTROL, /* Open netgraph control socket. */ PRIV_NETGRAPH_TTY, /* Configure tty for netgraph. */ PRIV_NETINET_RESERVEDPORT, /* Bind low port number. */ From owner-p4-projects@FreeBSD.ORG Wed Sep 27 19:29:02 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id DE30A16A416; Wed, 27 Sep 2006 19:29:01 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 B6D9716A415 for ; Wed, 27 Sep 2006 19:29:01 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B4C8443D5C for ; Wed, 27 Sep 2006 19:28:55 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8RJStDH027178 for ; Wed, 27 Sep 2006 19:28:55 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8RJStr0027175 for perforce@freebsd.org; Wed, 27 Sep 2006 19:28:55 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 19:28:55 GMT Message-Id: <200609271928.k8RJStr0027175@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106792 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 19:29:02 -0000 http://perforce.freebsd.org/chv.cgi?CH=106792 Change 106792 by imp@imp_lighthouse on 2006/09/27 19:28:45 more Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#6 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#7 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#6 (text+ko) ==== @@ -46,6 +46,8 @@ struct intr_config_hook config_intrhook; }; +#define CMD_RETRIES 3 + /* bus entry points */ static int mmc_probe(device_t dev); static int mmc_attach(device_t dev); @@ -184,10 +186,12 @@ mmcbr_update_ios(dev); mmc_ms_delay(1); + memset(&cmd, 0, sizeof(cmd)); cmd.opcode = MMC_GO_IDLE_STATE; cmd.arg = 0; cmd.flags = MMC_RSP_NONE | MMC_CMD_BC; mmc_wait_for_cmd(sc, &cmd, 0); + printf("GO_IDLE returns %d\n", cmd.error); mmc_ms_delay(1); mmcbr_set_chip_select(dev, cs_dontcare); @@ -196,17 +200,53 @@ } static int -mmc_send_app_op_cond(struct mmc_softc *sc, uint32_t rca, uint32_t *ocr) +mmc_send_app_op_cond(struct mmc_softc *sc, uint32_t ocr, uint32_t *rocr) { - // XXX write me - return EIO; + struct mmc_command cmd; + int err = MMC_ERR_NONE, i; + + memset(&cmd, 0, sizeof(cmd)); + cmd.opcode = ACMD_SD_SEND_OP_COND; + cmd.arg = ocr; + cmd.flags = MMC_RSP_R3 | MMC_CMD_BCR; + + for (i = 0; i < 100; i++) { + err = mmc_wait_for_cmd(sc, &cmd, CMD_RETRIES); + if (err != MMC_ERR_NONE) + break; + if ((cmd.resp[0] & MMC_OCR_CARD_BUSY) || ocr == 0) + break; + err = MMC_ERR_TIMEOUT; + mmc_ms_delay(10); + } + if (rocr && err == MMC_ERR_NONE) + *rocr = cmd.resp[0]; + return err; } static int -mmc_send_op_cond(struct mmc_softc *sc, uint32_t rca, uint32_t *ocr) +mmc_send_op_cond(struct mmc_softc *sc, uint32_t ocr, uint32_t *rocr) { - // XXX write me - return EIO; + struct mmc_command cmd; + int err = MMC_ERR_NONE, i; + + memset(&cmd, 0, sizeof(cmd)); + cmd.opcode = MMC_SEND_OP_COND; + cmd.arg = ocr; + cmd.flags = MMC_RSP_R3 | MMC_CMD_BCR; + + for (i = 0; i < 100; i++) { + err = mmc_wait_for_cmd(sc, &cmd, CMD_RETRIES); + if (err != MMC_ERR_NONE) + break; + if ((cmd.resp[0] & MMC_OCR_CARD_BUSY) || ocr == 0) + break; + err = MMC_ERR_TIMEOUT; + mmc_ms_delay(10); + } + if (rocr && err == MMC_ERR_NONE) + *rocr = cmd.resp[0]; + return err; } static void ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#7 (text+ko) ==== @@ -201,7 +201,9 @@ /* in SD 2.0 spec, bits 8-14 are now marked reserved */ /* Low voltage in SD2.0 spec is bit 7, TBD voltage */ /* Low voltage in MC 3.31 spec is bit 7, 1.65-1.95V */ -/* Linux has defines for lower bits down to 0, for reasons unknown */ +/* Linux has defines for lower bits down to 0, which were defined in prior */ +/* specs to MMC 3.31. 3.31 redefined them to be reserved and also said that */ +/* cards had to support the 2.7-3.6V. */ #define MMC_OCR_LOW_VOLTAGE (1u << 7) /* Low Voltage Range -- tbd */ #define MMC_OCR_200_210 (1U << 8) /* Vdd voltage 2.00 ~ 2.10 */ #define MMC_OCR_210_220 (1U << 9) /* Vdd voltage 2.10 ~ 2.20 */ From owner-p4-projects@FreeBSD.ORG Wed Sep 27 20:00:36 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9871A16A40F; Wed, 27 Sep 2006 20:00:36 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 4E9EA16A403 for ; Wed, 27 Sep 2006 20:00:36 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id EA1A743D45 for ; Wed, 27 Sep 2006 20:00:35 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8RK0ZSw029137 for ; Wed, 27 Sep 2006 20:00:35 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8RK0ZKQ029127 for perforce@freebsd.org; Wed, 27 Sep 2006 20:00:35 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 20:00:35 GMT Message-Id: <200609272000.k8RK0ZKQ029127@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106794 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 20:00:36 -0000 http://perforce.freebsd.org/chv.cgi?CH=106794 Change 106794 by imp@imp_lighthouse on 2006/09/27 20:00:21 Lots of new defines from SD 2.0 standard (lite) Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#8 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#8 (text+ko) ==== @@ -45,22 +45,22 @@ #define MMC_RSP_CRC (1ul << 2) /* Expect valid crc */ #define MMC_RSP_BUSY (1ul << 3) /* Card may send busy */ #define MMC_RSP_OPCODE (1ul << 4) /* Response include opcode */ -#define MMC_CMD_AC (0ul << 5) /* AC? */ -#define MMC_CMD_ADTC (1ul << 5) /* ADTC? */ -#define MMC_CMD_BC (2ul << 5) /* BC? */ -#define MMC_CMD_BCR (3ul << 5) /* BCR? */ -#define MMC_RSP_MASK 0x1ful -#define MMC_CMD_MASK (3ul << 5) +#define MMC_CMD_AC (0ul << 5) /* AC? */ +#define MMC_CMD_ADTC (1ul << 5) /* ADTC? */ +#define MMC_CMD_BC (2ul << 5) /* BC? */ +#define MMC_CMD_BCR (3ul << 5) /* BCR? */ +#define MMC_RSP_MASK 0x1ful +#define MMC_CMD_MASK (3ul << 5) /* Possible response types defined in the standard: */ -#define MMC_RSP_NONE (0) -#define MMC_RSP_R1 (MMC_RPS_PRESENT | MMC_RSP_CRC | MMC_RSP_OPCODE) +#define MMC_RSP_NONE (0) +#define MMC_RSP_R1 (MMC_RSP_PRESENT | MMC_RSP_CRC | MMC_RSP_OPCODE) #define MMC_RSP_R1B (MMC_RSP_PRESENT | MMC_RSP_CRC | MMC_RSP_OPCODE | MMC_RSP_BUSY) #define MMC_RSP_R2 (MMC_RSP_PRESENT | MMC_RSP_136 | MMC_RSP_CRC) #define MMC_RSP_R3 (MMC_RSP_PRESENT) #define MMC_RSP_R6 (MMC_RSP_PRESENT | MMC_RSP_CRC) /* R7 -- new in sd 2.0 */ -#define MMC_RSP(x) ((x) & MMC_RSP_MASK) +#define MMC_RSP(x) ((x) & MMC_RSP_MASK) uint32_t retries; uint32_t error; #define MMC_ERR_NONE 0 @@ -73,6 +73,55 @@ struct mmc_request *mrq; /* backpointer to request */ }; +/* + * R1 responses + * + * Types (per SD 2.0 standard) + * e : error bit + * s : status bit + * r : detected and set for the actual command response + * x : Detected and set during command execution. The host can get + * the status by issuing a command with R1 response. + * + * Clear Condition (per SD 2.0 standard) + * a : according to the card current state. + * b : always related to the previous command. reception of a valid + * command will clear it (with a delay of one command). + * c : clear by read + */ +#define R1_OUT_OF_RANGE (1u << 31) /* erx, c */ +#define R1_ADDRESS_ERROR (1u << 30) /* erx, c */ +#define R1_BLOCK_LEN_ERROR (1u << 29) /* erx, c */ +#define R1_ERASE_SEQ_ERROR (1u << 28) /* er, c */ +#define R1_ERASE_PARAM (1u << 27) /* erx, c */ +#define R1_WP_VIOLATION (1u << 26) /* erx, c */ +#define R1_CARD_IS_LOCKED (1u << 25) /* sx, a */ +#define R1_LOCK_UNLOCK_FAILED (1u << 24) /* erx, c */ +#define R1_COM_CRC_ERROR (1u << 23) /* er, b */ +#define R1_ILLEGAL_COMMAND (1u << 22) /* er, b */ +#define R1_CARD_ECC_FAILED (1u << 21) /* erx, c */ +#define R1_CC_ERROR (1u << 20) /* erx, c */ +#define R1_ERROR (1u << 19) /* erx, c */ +#define R1_CSD_OVERWRITE (1u << 16) /* erx, c */ +#define R1_WP_ERASE_SKIP (1u << 15) /* erx, c */ +#define R1_CARD_ECC_DISABLED (1u << 14) /* sx, a */ +#define R1_ERASE_RESET (1u << 13) /* sr, c */ +#define R1_CURRENT_STATE_MASK (0xfu << 9) /* sx, b */ +#define R1_READY_FOR_DATA (1u << 8) /* sx, a */ +#define R1_APP_CMD (1u << 5) /* sr, c */ +#define R1_AKE_SEQ_ERROR (1u << 3) /* er, c */ +#define R1_STATUS(x) (x & 0xFFFFE000 +#define R1_CURRENT_STATE(x) ((x) & R1_CURRENT_STATE_MASK) >> 9 +#define R1_STATE_IDLE 0 +#define R1_STATE_READY 1 +#define R1_STATE_IDENT 2 +#define R1_STATE_STBY 3 +#define R1_STATE_TRAN 4 +#define R1_STATE_DATA 5 +#define R1_STATE_RCV 6 +#define R1_STATE_PRG 7 +#define R1_STATE_DIS 8 + struct mmc_data { uint32_t flags; #define MMC_DATA_WRITE (1UL << 8) @@ -88,7 +137,7 @@ void (*done)(struct mmc_request *); /* Completion function */ void *done_data; /* requestor set data */ uint32_t flags; -#define MMC_REQ_DONE 1 +#define MMC_REQ_DONE 1 }; /* Command definitions */ @@ -102,7 +151,7 @@ /* reserved: 5 */ #define MMC_SELECT_CARD 7 #define MMC_DESELECT_CARD 7 -#define MMC_SEND_IF_COND 8 +#define MMC_SEND_IF_COND 8 #define MMC_SEND_CSD 9 #define MMC_SEND_CID 10 #define MMC_READ_DAT_UNTIL_STOP 11 @@ -204,7 +253,7 @@ /* Linux has defines for lower bits down to 0, which were defined in prior */ /* specs to MMC 3.31. 3.31 redefined them to be reserved and also said that */ /* cards had to support the 2.7-3.6V. */ -#define MMC_OCR_LOW_VOLTAGE (1u << 7) /* Low Voltage Range -- tbd */ +#define MMC_OCR_LOW_VOLTAGE (1u << 7) /* Low Voltage Range -- tbd */ #define MMC_OCR_200_210 (1U << 8) /* Vdd voltage 2.00 ~ 2.10 */ #define MMC_OCR_210_220 (1U << 9) /* Vdd voltage 2.10 ~ 2.20 */ #define MMC_OCR_220_230 (1U << 10) /* Vdd voltage 2.20 ~ 2.30 */ @@ -221,7 +270,7 @@ #define MMC_OCR_330_340 (1U << 21) /* Vdd voltage 3.30 ~ 3.40 */ #define MMC_OCR_340_350 (1U << 22) /* Vdd voltage 3.40 ~ 3.50 */ #define MMC_OCR_350_360 (1U << 23) /* Vdd voltage 3.50 ~ 3.60 */ -#define MMC_OCR_CCS (1u << 30) /* Card Capacity status (SD vs SDHC) */ +#define MMC_OCR_CCS (1u << 30) /* Card Capacity status (SD vs SDHC) */ #define MMC_OCR_CARD_BUSY (1U << 31) /* Card Power up status */ #endif /* DEV_MMCREG_H */ From owner-p4-projects@FreeBSD.ORG Wed Sep 27 20:01:38 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 86F2416A416; Wed, 27 Sep 2006 20:01:38 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 4D75116A412 for ; Wed, 27 Sep 2006 20:01:38 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0EFEE43D46 for ; Wed, 27 Sep 2006 20:01:38 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8RK1bN5029333 for ; Wed, 27 Sep 2006 20:01:37 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8RK1bKJ029330 for perforce@freebsd.org; Wed, 27 Sep 2006 20:01:37 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 20:01:37 GMT Message-Id: <200609272001.k8RK1bKJ029330@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106795 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 20:01:38 -0000 http://perforce.freebsd.org/chv.cgi?CH=106795 Change 106795 by imp@imp_lighthouse on 2006/09/27 20:00:39 wait_for_app_cmd Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#7 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#7 (text+ko) ==== @@ -175,6 +175,31 @@ return (cmd->error); } +static int +mmc_wait_for_app_cmd(struct mmc_softc *sc, uint32_t rca, + struct mmc_command *cmd, int retries) +{ + struct mmc_command appcmd; + int err = MMC_ERR_NONE, i; + + for (i = 0; i <= retries; i++) { + appcmd.opcode = MMC_APP_CMD; + appcmd.arg = rca << 16; + appcmd.flags = MMC_RSP_R1 | MMC_CMD_AC; + mmc_wait_for_cmd(sc, &appcmd, 0); + err = appcmd.error; + if (err != MMC_ERR_NONE) + continue; + if (appcmd.resp[0] & R1_APP_CMD) + return MMC_ERR_FAILED; + mmc_wait_for_cmd(sc, cmd, 0); + err = cmd->error; + if (err == MMC_ERR_NONE) + break; + } + return (err); +} + static void mmc_idle_cards(struct mmc_softc *sc) { @@ -211,7 +236,7 @@ cmd.flags = MMC_RSP_R3 | MMC_CMD_BCR; for (i = 0; i < 100; i++) { - err = mmc_wait_for_cmd(sc, &cmd, CMD_RETRIES); + err = mmc_wait_for_app_cmd(sc, 0, &cmd, CMD_RETRIES); if (err != MMC_ERR_NONE) break; if ((cmd.resp[0] & MMC_OCR_CARD_BUSY) || ocr == 0) From owner-p4-projects@FreeBSD.ORG Wed Sep 27 22:00:06 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 28B0116A415; Wed, 27 Sep 2006 22:00:06 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 04E8616A403 for ; Wed, 27 Sep 2006 22:00:05 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6DA1043D80 for ; Wed, 27 Sep 2006 22:00:05 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8RM05mZ068496 for ; Wed, 27 Sep 2006 22:00:05 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8RM05KF068493 for perforce@freebsd.org; Wed, 27 Sep 2006 22:00:05 GMT (envelope-from imp@freebsd.org) Date: Wed, 27 Sep 2006 22:00:05 GMT Message-Id: <200609272200.k8RM05KF068493@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106800 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2006 22:00:06 -0000 http://perforce.freebsd.org/chv.cgi?CH=106800 Change 106800 by imp@imp_lighthouse on 2006/09/27 21:59:43 Handle the queueing of commands... Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#8 edit .. //depot/projects/arm/src/sys/dev/mmc/bridge.h#4 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#9 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#8 (text+ko) ==== @@ -29,19 +29,20 @@ #include #include #include +#include +#include #include +#include +#include #include -#include #include #include -#include -#include +#include #include #include +#include #include #include -#include -#include #include #include @@ -61,6 +62,9 @@ struct at91_mci_softc { void *intrhand; /* Interrupt handle */ device_t dev; + int flags; +#define CMD_STARTED 1 +#define STOP_STARTED 2 struct resource *irq_res; /* IRQ resource */ struct resource *mem_res; /* Memory resource */ struct mtx sc_mtx; @@ -69,6 +73,7 @@ struct mmc_host host; int wire4; int bus_busy; + struct mmc_request *req; }; static inline uint32_t @@ -237,7 +242,7 @@ #if 0 static void -at91_getaddr(void *arg, bus_dma_segment_t *segs, int nsegs, int error) +at91_mci_getaddr(void *arg, bus_dma_segment_t *segs, int nsegs, int error) { if (error != 0) return; @@ -246,7 +251,7 @@ #endif static int -at91_update_ios(device_t brdev, device_t reqdev) +at91_mci_update_ios(device_t brdev, device_t reqdev) { uint32_t at91_master_clock = AT91C_MASTER_CLOCK; struct at91_mci_softc *sc; @@ -284,20 +289,62 @@ return (0); } +static void +at91_mci_start_cmd(struct at91_mci_softc *sc, struct mmc_command *cmd) +{ + // XXX +} + +static void +at91_mci_start(struct at91_mci_softc *sc) +{ + struct mmc_request *req; + + // assert locked + if (!(sc->flags & CMD_STARTED)) { + sc->flags |= CMD_STARTED; + at91_mci_start_cmd(sc, req->cmd); + return; + } + if (!(sc->flags & STOP_STARTED) && req->stop) { + sc->flags |= STOP_STARTED; + at91_mci_start_cmd(sc, req->stop); + return; + } + /* We must be done -- bad idea to do this while locked? */ + req = sc->req; + sc->req = NULL; + req->done(req->done_data); +} + static int -at91_request(device_t brdev, device_t reqdev, struct mmc_request *req) +at91_mci_request(device_t brdev, device_t reqdev, struct mmc_request *req) { - return (EIO); // XXX + struct at91_mci_softc *sc = device_get_softc(brdev); + + AT91_MCI_LOCK(sc); + // XXX do we want to be able to queue up multiple commands? + // XXX sounds like a good idea, but all protocols are sync, so + // XXX maybe the idea is naive... + if (sc->req != NULL) { + AT91_MCI_UNLOCK(sc); + return EBUSY; + } + sc->req = req; + sc->flags = 0; + at91_mci_start(sc); + AT91_MCI_UNLOCK(sc); + return (0); } static int -at91_get_ro(device_t brdev, device_t reqdev) +at91_mci_get_ro(device_t brdev, device_t reqdev) { return (-1); } static int -at91_acquire_host(device_t brdev, device_t reqdev) +at91_mci_acquire_host(device_t brdev, device_t reqdev) { struct at91_mci_softc *sc = device_get_softc(brdev); int err = 0; @@ -311,7 +358,7 @@ } static int -at91_release_host(device_t brdev, device_t reqdev) +at91_mci_release_host(device_t brdev, device_t reqdev) { struct at91_mci_softc *sc = device_get_softc(brdev); @@ -329,11 +376,11 @@ DEVMETHOD(device_detach, at91_mci_detach), /* mmcbr_if */ - DEVMETHOD(mmcbr_update_ios, at91_update_ios), - DEVMETHOD(mmcbr_request, at91_request), - DEVMETHOD(mmcbr_get_ro, at91_get_ro), - DEVMETHOD(mmcbr_acquire_host, at91_acquire_host), - DEVMETHOD(mmcbr_release_host, at91_release_host), + DEVMETHOD(mmcbr_update_ios, at91_mci_update_ios), + DEVMETHOD(mmcbr_request, at91_mci_request), + DEVMETHOD(mmcbr_get_ro, at91_mci_get_ro), + DEVMETHOD(mmcbr_acquire_host, at91_mci_acquire_host), + DEVMETHOD(mmcbr_release_host, at91_mci_release_host), {0, 0}, }; ==== //depot/projects/arm/src/sys/dev/mmc/bridge.h#4 (text+ko) ==== ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#9 (text+ko) ==== @@ -123,6 +123,8 @@ #define R1_STATE_DIS 8 struct mmc_data { + size_t len; /* size of the data */ + void *data; /* data buffer */ uint32_t flags; #define MMC_DATA_WRITE (1UL << 8) #define MMC_DATA_READ (1UL << 9) @@ -132,7 +134,6 @@ struct mmc_request { struct mmc_command *cmd; - struct mmc_data *data; struct mmc_command *stop; void (*done)(struct mmc_request *); /* Completion function */ void *done_data; /* requestor set data */ From owner-p4-projects@FreeBSD.ORG Thu Sep 28 06:42:26 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B66E116A416; Thu, 28 Sep 2006 06:42:26 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 91CB616A403 for ; Thu, 28 Sep 2006 06:42:26 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 545D743D58 for ; Thu, 28 Sep 2006 06:42:26 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8S6gQsC042187 for ; Thu, 28 Sep 2006 06:42:26 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8S6gPoi042184 for perforce@freebsd.org; Thu, 28 Sep 2006 06:42:25 GMT (envelope-from imp@freebsd.org) Date: Thu, 28 Sep 2006 06:42:25 GMT Message-Id: <200609280642.k8S6gPoi042184@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106807 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 06:42:27 -0000 http://perforce.freebsd.org/chv.cgi?CH=106807 Change 106807 by imp@imp_lighthouse on 2006/09/28 06:42:06 Initialize, per spec for this board XXX should work on making this generic. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_ssc.c#8 edit .. //depot/projects/arm/src/sys/arm/at91/at91_sscreg.h#5 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_ssc.c#8 (text+ko) ==== @@ -88,14 +88,16 @@ /* cdev routines */ static d_open_t at91_ssc_open; static d_close_t at91_ssc_close; -static d_ioctl_t at91_ssc_ioctl; +static d_read_t at91_ssc_read; +static d_write_t at91_ssc_write; static struct cdevsw at91_ssc_cdevsw = { .d_version = D_VERSION, .d_open = at91_ssc_open, .d_close = at91_ssc_close, - .d_ioctl = at91_ssc_ioctl + .d_read = at91_ssc_read, + .d_write = at91_ssc_write, }; static int @@ -134,6 +136,19 @@ goto out; } sc->cdev->si_drv1 = sc; + + // Init for TSC needs + WR4(sc, SSC_CR, SSC_CR_SWRST); + WR4(sc, SSC_CMR, 0); // clock divider unused + WR4(sc, SSC_RCMR, + SSC_RCMR_CKS_RK | SSC_RCMR_CKO_NONE | SSC_RCMR_START_FALL_EDGE_RF); + WR4(sc, SSC_RFMR, + 0x1f | SSC_RFMR_MSFBF | SSC_RFMR_FSOS_NONE); + WR4(sc, SSC_TCMR, + SSC_TCMR_CKS_TK | SSC_TCMR_CKO_NONE | SSC_RCMR_START_CONT); + WR4(sc, SSC_TFMR, + 0x1f | SSC_TFMR_DATDEF | SSC_TFMR_MSFBF | SSC_TFMR_FSOS_NEG_PULSE); + out:; if (err) at91_ssc_deactivate(dev); @@ -241,10 +256,15 @@ } static int -at91_ssc_ioctl(struct cdev *dev, u_long cmd, caddr_t data, int fflag, - struct thread *td) +at91_ssc_read(struct cdev *dev, struct uio *uio, int flag) +{ + return EIO; +} + +static int +at91_ssc_write(struct cdev *dev, struct uio *uio, int flag) { - return (ENXIO); + return EIO; } static device_method_t at91_ssc_methods[] = { ==== //depot/projects/arm/src/sys/arm/at91/at91_sscreg.h#5 (text+ko) ==== @@ -27,4 +27,109 @@ #ifndef ARM_AT91_AT91_SSCREG_H #define ARM_AT91_AT91_SSCREG_H +/* Registers */ +#define SSC_CR 0x00 /* Control Register */ +#define SSC_CMR 0x04 /* Clock Mode Register */ + /* 0x08 Reserved */ + /* 0x0c Reserved */ +#define SSC_RCMR 0x10 /* Receive Clock Mode Register */ +#define SSC_RFMR 0x14 /* Receive Frame Mode Register */ +#define SSC_TCMR 0x18 /* Transmit Clock Mode Register */ +#define SSC_TFMR 0x1c /* Transmit Frame Mode register */ +#define SSC_RHR 0x20 /* Receive Holding Register */ +#define SSC_THR 0x24 /* Transmit Holding Register */ + /* 0x28 Reserved */ + /* 0x2c Reserved */ +#define SSC_RSHR 0x30 /* Receive Sync Holding Register */ +#define SSC_TSHR 0x34 /* Transmit Sync Holding Register */ + /* 0x38 Reserved */ + /* 0x3c Reserved */ +#define SSC_SR 0x40 /* Status Register */ +#define SSC_IER 0x44 /* Interrupt Enable Register */ +#define SSC_IDR 0x48 /* Interrupt Disable Register */ +#define SSC_IMR 0x4c /* Interrupt Mask Register */ +/* And PDC registers */ + +/* SSC_CR */ +#define SSC_CR_RXEN (1u << 0) /* RXEN: Receive Enable */ +#define SSC_CR_RXDIS (1u << 1) /* RXDIS: Receive Disable */ +#define SSC_CR_TXEN (1u << 8) /* TXEN: Transmit Enable */ +#define SSC_CR_TXDIS (1u << 9) /* TXDIS: Transmit Disable */ +#define SSC_CR_SWRST (1u << 15) /* SWRST: Software Reset */ + +/* SSC_CMR */ +#define SSC_CMR_DIV 0xfffu /* DIV: Clock Divider mask */ + +/* SSC_RCMR */ +#define SSC_RCMR_PERIOD (0xffu << 24) /* PERIOD: Receive Period Divider sel*/ +#define SSC_RCMR_STTDLY (0xffu << 16) /* STTDLY: Receive Start Delay */ +#define SSC_RCMR_START (0xfu << 8) /* START: Receive Start Sel */ +#define SSC_RCMR_START_CONT (0u << 8) +#define SSC_RCMR_START_TX_START (1u << 8) +#define SSC_RCMR_START_LOW_RF (2u << 8) +#define SSC_RCMR_START_HIGH_RF (3u << 8) +#define SSC_RCMR_START_FALL_EDGE_RF (4u << 8) +#define SSC_RCMR_START_RISE_EDGE_RF (5u << 8) +#define SSC_RCMR_START_LEVEL_CHANGE_RF (6u << 8) +#define SSC_RCMR_START_ANY_EDGE_RF (7u << 8) +#define SSC_RCMR_CKI (1u << 5) /* CKI: Receive Clock Inversion */ +#define SSC_RCMR_CKO (7u << 2) /* CKO: Receive Clock Output Mode Sel*/ +#define SSC_RCMR_CKO_NONE (0u << 2) +#define SSC_RCMR_CKO_CONTINUOUS (1u << 2) +#define SSC_RCMR_CKS (3u) /* CKS: Receive Clock Selection */ +#define SSC_RCMR_CKS_DIVIDED (0) +#define SSC_RCMR_CKS_TK_CLOCK (1) +#define SSC_RCMR_CKS_RK (2) + +/* SSC_RFMR */ +#define SSC_RFMR_FSEDGE (1u << 24) /* FSEDGE: Frame Sync Edge Detection */ +#define SSC_RFMR_FSOS (7u << 20) /* FSOS: Receive frame Sync Out sel */ +#define SSC_RFMR_FSOS_NONE (0u << 20) +#define SSC_RFMR_FSOS_NEG_PULSE (1u << 20) +#define SSC_RFMR_FSOS_POS_PULSE (2u << 20) +#define SSC_RFMR_FSOS_LOW (3u << 20) +#define SSC_RFMR_FSOS_HIGH (4u << 20) +#define SSC_RFMR_FSOS_TOGGLE (5u << 20) +#define SSC_RFMR_FSLEN (0xfu << 16) /* FSLEN: Receive Frame Sync Length */ +#define SSC_RFMR_DATNB (0xfu << 8) /* DATNB: Data Number per Frame */ +#define SSC_RFMR_MSFBF (1u << 7) /* MSBF: Most Significant Bit First */ +#define SSC_RFMR_LOOP (1u << 5) /* LOOP: Loop Mode */ +#define SSC_RFMR_DATLEN (0x1fu << 0) /* DATLEN: Data Length */ + +/* SSC_TCMR */ +#define SSC_TCMR_PERIOD (0xffu << 24) /* PERIOD: Receive Period Divider sel*/ +#define SSC_TCMR_STTDLY (0xffu << 16) /* STTDLY: Receive Start Delay */ +#define SSC_TCMR_START (0xfu << 8) /* START: Receive Start Sel */ +#define SSC_TCMR_START_CONT (0u << 8) +#define SSC_TCMR_START_RX_START (1u << 8) +#define SSC_TCMR_START_LOW_RF (2u << 8) +#define SSC_TCMR_START_HIGH_RF (3u << 8) +#define SSC_TCMR_START_FALL_EDGE_RF (4u << 8) +#define SSC_TCMR_START_RISE_EDGE_RF (5u << 8) +#define SSC_TCMR_START_LEVEL_CHANGE_RF (6u << 8) +#define SSC_TCMR_START_ANY_EDGE_RF (7u << 8) +#define SSC_TCMR_CKI (1u << 5) /* CKI: Receive Clock Inversion */ +#define SSC_TCMR_CKO (7u << 2) /* CKO: Receive Clock Output Mode Sel*/ +#define SSC_TCMR_CKO_NONE (0u << 2) +#define SSC_TCMR_CKO_CONTINUOUS (1u << 2) +#define SSC_TCMR_CKS (3u) /* CKS: Receive Clock Selection */ +#define SSC_TCMR_CKS_DIVIDED (0) +#define SSC_TCMR_CKS_RK_CLOCK (1) +#define SSC_TCMR_CKS_TK (2) + +/* SSC_TFMR */ +#define SSC_TFMR_FSEDGE (1u << 24) /* FSEDGE: Frame Sync Edge Detection */ +#define SSC_TFMR_FSOS (7u << 20) /* FSOS: Receive frame Sync Out sel */ +#define SSC_TFMR_FSOS_NONE (0u << 20) +#define SSC_TFMR_FSOS_NEG_PULSE (1u << 20) +#define SSC_TFMR_FSOS_POS_PULSE (2u << 20) +#define SSC_TFMR_FSOS_LOW (3u << 20) +#define SSC_TFMR_FSOS_HIGH (4u << 20) +#define SSC_TFMR_FSOS_TOGGLE (5u << 20) +#define SSC_TFMR_FSLEN (0xfu << 16) /* FSLEN: Receive Frame Sync Length */ +#define SSC_TFMR_DATNB (0xfu << 8) /* DATNB: Data Number per Frame */ +#define SSC_TFMR_MSFBF (1u << 7) /* MSBF: Most Significant Bit First */ +#define SSC_TFMR_DATDEF (1u << 5) /* DATDEF: Data Default Value */ +#define SSC_TFMR_DATLEN (0x1fu << 0) /* DATLEN: Data Length */ + #endif /* ARM_AT91_AT91_SSCREG_H */ From owner-p4-projects@FreeBSD.ORG Thu Sep 28 06:48:34 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B2F7216A416; Thu, 28 Sep 2006 06:48:34 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 8A93816A40F for ; Thu, 28 Sep 2006 06:48:34 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5B46443D45 for ; Thu, 28 Sep 2006 06:48:34 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8S6mYNZ042555 for ; Thu, 28 Sep 2006 06:48:34 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8S6mYpk042552 for perforce@freebsd.org; Thu, 28 Sep 2006 06:48:34 GMT (envelope-from mjacob@freebsd.org) Date: Thu, 28 Sep 2006 06:48:34 GMT Message-Id: <200609280648.k8S6mYpk042552@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106808 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 06:48:35 -0000 http://perforce.freebsd.org/chv.cgi?CH=106808 Change 106808 by mjacob@newisp on 2006/09/28 06:47:53 Print N-port handles as hex values. Repeat after me 10**10**10 times: an NP handle is *not* a target id. Affected files ... .. //depot/projects/newisp/dev/isp/isp_freebsd.c#11 edit Differences ... ==== //depot/projects/newisp/dev/isp/isp_freebsd.c#11 (text+ko) ==== @@ -2923,10 +2923,10 @@ "(none)", "Target", "Initiator", "Target/Initiator" }; static const char prom[] = - "PortID 0x%06x N-port Handle %u role %s %s\n" + "PortID 0x%06x handle 0x%x role %s %s\n" " WWNN 0x%08x%08x WWPN 0x%08x%08x"; static const char prom2[] = - "PortID 0x%06x N-port Handle %u role %s %s tgt %u\n" + "PortID 0x%06x handle 0x%x role %s %s tgt %u\n" " WWNN 0x%08x%08x WWPN 0x%08x%08x"; target_id_t tgt; fcportdb_t *lp; From owner-p4-projects@FreeBSD.ORG Thu Sep 28 06:56:51 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0BEF116A40F; Thu, 28 Sep 2006 06:56:51 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 7660D16A403 for ; Thu, 28 Sep 2006 06:56:50 +0000 (UTC) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 27D1E43D68 for ; Thu, 28 Sep 2006 06:56:45 +0000 (GMT) (envelope-from mjacob@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8S6uj1m043139 for ; Thu, 28 Sep 2006 06:56:45 GMT (envelope-from mjacob@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8S6uihx043136 for perforce@freebsd.org; Thu, 28 Sep 2006 06:56:44 GMT (envelope-from mjacob@freebsd.org) Date: Thu, 28 Sep 2006 06:56:44 GMT Message-Id: <200609280656.k8S6uihx043136@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to mjacob@freebsd.org using -f From: Matt Jacob To: Perforce Change Reviews Cc: Subject: PERFORCE change 106809 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 06:56:51 -0000 http://perforce.freebsd.org/chv.cgi?CH=106809 Change 106809 by mjacob@newisp on 2006/09/28 06:56:23 Handle fabric case of cycling through old portdb members and finding that the handle for that member now returns info for some other device. Let's say we have a disk at handle 0x82, PortID 0x10300. We get a PDB event and go ask the fabric name server for a list of portids. When we get to 0x10300 in that list, we say "AhHa!"- because we already know about it. But we call isp_get_pdb to check out the info for handle 0x82 and we get info for PortID 0x105e0! Whups! So w/o telling us, the disk did a LOGO and somebody else then did a PLOGI to us which the QLogic f/w then reassigned handle 0x82 to that new member. The fix here is that when we get to this situation, we know that portid 0x10300 is still out there (we got that from the fabric name server)- it's just that the handle we'd been using to talk to it is no longer valid. This is *almost* like the arrival of a brand new device- except that we don't have to allocate a portdb entry (we already have one)- but we *do* have to go find an unused handle and try and log back into the old device, preserving our original virtual target id assignment. Finally, we have to mark this device as "CHANGED" so that later, in isp_pdb_sync, we could apply a policy of disbelieving that CHANGED devices are the same. Affected files ... .. //depot/projects/newisp/dev/isp/isp.c#14 edit Differences ... ==== //depot/projects/newisp/dev/isp/isp.c#14 (text+ko) ==== @@ -65,8 +65,8 @@ * Local static data */ static const char fconf[] = - "portdb[%d] confusion: 0x%x,0x%x 0x%x,0x%x, 0x%08x%08x/0x%08x%08x, " - "0x%08x%08x/0x%08x%08x"; + "PortDB[%d] changed:\n current =(0x%x@0x%06x 0x%08x%08x 0x%08x%08x)\n" + " database=(0x%x@0x%06x 0x%08x%08x 0x%08x%08x)"; static const char notresp[] = "Not RESPONSE in RESPONSE Queue (type 0x%x) @ idx %d (next %d) nlooked %d"; static const char xact1[] = @@ -122,6 +122,7 @@ static int isp_gid_ft_sns(ispsoftc_t *); static int isp_gid_ft_ct_passthru(ispsoftc_t *); static int isp_scan_fabric(ispsoftc_t *); +static int isp_login_device(ispsoftc_t *, uint32_t, isp_pdb_t *, uint16_t *); static int isp_register_fc4_type(ispsoftc_t *); static int isp_register_fc4_type_24xx(ispsoftc_t *); static uint16_t isp_nxt_handle(ispsoftc_t *, uint16_t); @@ -1999,15 +2000,36 @@ int i; for (i = 0; i < MAX_FC_TARG; i++) { + char mb[4]; + const char *dbs[8] = { + "NIL ", + "PROB", + "DEAD", + "CHGD", + "NEW ", + "PVLD", + "????", + "VLD " + }; + const char *roles[4] = { + " UNK", " TGT", " INI", "TINI" + }; fcportdb_t *lp = &fcp->portdb[i]; + if (lp->state == FC_PORTDB_STATE_NIL) { continue; } - isp_prt(isp, ISP_LOGALL, "%d: state %d al %d tgt %d role 0x%x" - " PortID 0x%06x nr %x np 0x%06x WWNN 0x%08x%08x WWPN " - "0x%08x%08x", i, lp->state, lp->autologin, - ((int) lp->ini_map_idx) - 1, lp->roles, lp->portid, - lp->new_roles, lp->new_portid, + if (lp->ini_map_idx) { + SNPRINTF(mb, sizeof (mb), "%3d", + ((int) lp->ini_map_idx) - 1); + } else { + SNPRINTF(mb, sizeof (mb), "---"); + } + isp_prt(isp, ISP_LOGALL, "%d: %s al%d tgt %s %s 0x%06x =>%s" + " 0x%06x; WWNN 0x%08x%08x WWPN 0x%08x%08x", i, + dbs[lp->state], lp->autologin, mb, + roles[lp->roles], lp->portid, + roles[lp->new_roles], lp->new_portid, (uint32_t) (lp->node_wwn >> 32), (uint32_t) (lp->node_wwn), (uint32_t) (lp->port_wwn >> 32), @@ -3306,12 +3328,11 @@ * WWNN/WWPN duple, we enter the device into our database. */ - for (portidx = 0; portidx < portlim; portidx++) { fcportdb_t *lp; isp_pdb_t pdb; uint64_t wwnn, wwpn; - int base, dbidx, r, nr, lim; + int dbidx, r, nr; portid = ((rs1->snscb_ports[portidx].portid[0]) << 16) | @@ -3351,9 +3372,10 @@ /* * We found a probational entry with this Port ID. - * */ if (dbidx < MAX_FC_TARG) { + int handle_changed = 0; + lp = &fcp->portdb[dbidx]; /* @@ -3388,11 +3410,9 @@ /* * Check to make sure that handle, portid, WWPN and - * WWNN agree. If they don't, things have gotten - * messed up because we can only have gotten here if - * we're logged into this device at this portid with - * this handle at this WWNN && WPPN, so treat the - * device as dead. + * WWNN agree. If they don't, then the association + * between this PortID and the stated handle has been + * broken by the firmware. */ MAKE_WWN_FROM_NODE_NAME(wwnn, pdb.nodename); MAKE_WWN_FROM_NODE_NAME(wwpn, pdb.portname); @@ -3400,18 +3420,48 @@ pdb.portid != portid || wwpn != lp->port_wwn || wwnn != lp->node_wwn) { - isp_prt(isp, ISP_LOGERR, fconf, dbidx, - pdb.handle, lp->handle, pdb.portid, - portid, (uint32_t) (wwpn >> 32), - (uint32_t) wwpn, (uint32_t) (wwnn >> 32), - (uint32_t) wwnn, + isp_prt(isp, ISP_LOGDEBUG0, fconf, dbidx, + pdb.handle, pdb.portid, + (uint32_t) (wwnn >> 32), (uint32_t) wwnn, + (uint32_t) (wwpn >> 32), (uint32_t) wwpn, + lp->handle, portid, + (uint32_t) (lp->node_wwn >> 32), + (uint32_t) lp->node_wwn, (uint32_t) (lp->port_wwn >> 32), - (uint32_t) lp->port_wwn, - (uint32_t) (lp->node_wwn >> 32), - (uint32_t) lp->node_wwn); - lp->new_portid = portid; - lp->state = FC_PORTDB_STATE_DEAD; - continue; + (uint32_t) lp->port_wwn); + /* + * Try to re-login to this device using a + * new handle. If that fails, mark it dead. + * + * isp_login_device will check for handle and + * portid consistency after re-login. + * + */ + if (isp_login_device(isp, portid, &pdb, + &oldhandle)) { + lp->new_portid = portid; + lp->state = FC_PORTDB_STATE_DEAD; + if (fcp->isp_loopstate != + LOOP_SCANNING_FABRIC) { + FC_SCRATCH_RELEASE(isp); + isp_mark_portdb(isp, 1); + return (-1); + } + continue; + } + MAKE_WWN_FROM_NODE_NAME(wwnn, pdb.nodename); + MAKE_WWN_FROM_NODE_NAME(wwpn, pdb.portname); + if (wwpn != lp->port_wwn || + wwnn != lp->node_wwn) { + isp_prt(isp, ISP_LOGWARN, "changed WWN" + " after relogin"); + lp->new_portid = portid; + lp->state = FC_PORTDB_STATE_DEAD; + continue; + } + + lp->handle = pdb.handle; + handle_changed++; } nr = (pdb.s3_role & SVC3_ROLE_MASK) >> SVC3_ROLE_SHIFT; @@ -3430,7 +3480,8 @@ lp->new_portid = portid; lp->new_roles = nr; - if (pdb.portid != lp->portid || nr != lp->roles) { + if (pdb.portid != lp->portid || nr != lp->roles || + handle_changed) { lp->state = FC_PORTDB_STATE_CHANGED; } else { lp->state = FC_PORTDB_STATE_PENDING_VALID; @@ -3466,13 +3517,7 @@ /* * Find an empty database entry for it. */ - if (fcp->isp_topo == TOPO_FL_PORT) { - base = SNS_ID+1; - } else { - base = 0; - } - - for (dbidx = base; dbidx < MAX_FC_TARG; dbidx++) { + for (dbidx = 0; dbidx < MAX_FC_TARG; dbidx++) { if (dbidx >= FL_ID && dbidx <= SNS_ID) { continue; } @@ -3488,97 +3533,13 @@ continue; } - if (IS_24XX(isp)) { - lim = 0xffff; - } else { - lim = MAX_FC_TARG; - } - handle = isp_nxt_handle(isp, oldhandle); - for (r = 0; r < lim; r++) { - int logval; - - /* - * See if we're still logged into something with - * this handle and that something agrees with this - * port id. - */ - r = isp_getpdb(isp, handle, &pdb, 0); - if (r == 0 && pdb.portid != portid) { - if (IS_24XX(isp)) { - logval = - PLOGX_FLG_CMD_LOGO | - PLOGX_FLG_IMPLICIT; - isp_plogx_24xx(isp, handle, portid, - &logval); - } else { - isp_port_logout(isp, handle, portid); - } - } else if (r == 0) { - break; - } - if (fcp->isp_loopstate != LOOP_SCANNING_FABRIC) { - FC_SCRATCH_RELEASE(isp); - isp_mark_portdb(isp, 1); - return (-1); - } - - /* - * Now try and log into the device - */ - if (IS_24XX(isp)) { - logval = PLOGX_FLG_CMD_PLOGI; - isp_plogx_24xx(isp, handle, portid, &logval); - } else { - logval = isp_port_login(isp, handle, portid); - } - if (fcp->isp_loopstate != LOOP_SCANNING_FABRIC) { - FC_SCRATCH_RELEASE(isp); - isp_mark_portdb(isp, 1); - return (-1); - } - if (logval == 0) { - oldhandle = handle; - break; - } else if ((logval & 0xffff) == MBOX_PORT_ID_USED) { - handle = logval >> 16; - break; - } else if (logval != MBOX_LOOP_ID_USED) { - r = lim; - break; - } else { - oldhandle = handle; - handle = isp_nxt_handle(isp, oldhandle); - } - } - - if (r == lim) { - isp_prt(isp, ISP_LOGERR, - "could not log PortID 0x%06x in", portid); - continue; - } - /* - * If we successfully logged into it, get the PDB for it - * so we can crosscheck that it is still what we think it - * is and that we also have the role it plays + * Try to log into this device. + * + * isp_login_device will check for handle and + * portid consistency after login. */ - r = isp_getpdb(isp, handle, &pdb, 0); - if (fcp->isp_loopstate != LOOP_SCANNING_FABRIC) { - FC_SCRATCH_RELEASE(isp); - isp_mark_portdb(isp, 1); - return (-1); - } - if (r != 0) { - isp_prt(isp, ISP_LOGERR, - "new device 0x%06x@0x%x disappeared", - portid, handle); - continue; - } - - if (pdb.handle != handle || pdb.portid != portid) { - isp_prt(isp, ISP_LOGERR, - "new device 0x%06x@0x%x changed (0x%06x@0x%0x", - portid, handle, pdb.portid, pdb.handle); + if (isp_login_device(isp, portid, &pdb, &oldhandle)) { if (fcp->isp_loopstate != LOOP_SCANNING_FABRIC) { FC_SCRATCH_RELEASE(isp); isp_mark_portdb(isp, 1); @@ -3587,6 +3548,7 @@ continue; } + handle = pdb.handle; MAKE_WWN_FROM_NODE_NAME(wwnn, pdb.nodename); MAKE_WWN_FROM_NODE_NAME(wwpn, pdb.portname); nr = (pdb.s3_role & SVC3_ROLE_MASK) >> SVC3_ROLE_SHIFT; @@ -3641,6 +3603,100 @@ return (0); } +/* + * Find an unused handle and try and use to login to a port. + */ +static int +isp_login_device(ispsoftc_t *isp, uint32_t portid, isp_pdb_t *p, uint16_t *ohp) +{ + int lim, r, logval; + uint16_t handle; + + if (IS_24XX(isp)) { + lim = 0xffff; + } else { + lim = MAX_FC_TARG; + } + + handle = isp_nxt_handle(isp, *ohp); + for (r = 0; r < lim; r++) { + /* + * See if we're still logged into something with + * this handle and that something agrees with this + * port id. + */ + r = isp_getpdb(isp, handle, p, 0); + if (r == 0 && p->portid != portid) { + if (IS_24XX(isp)) { + logval = + PLOGX_FLG_CMD_LOGO | + PLOGX_FLG_IMPLICIT; + isp_plogx_24xx(isp, handle, portid, &logval); + } else { + isp_port_logout(isp, handle, portid); + } + } else if (r == 0) { + break; + } + if (FCPARAM(isp)->isp_loopstate != LOOP_SCANNING_FABRIC) { + return (-1); + } + /* + * Now try and log into the device + */ + if (IS_24XX(isp)) { + logval = PLOGX_FLG_CMD_PLOGI; + isp_plogx_24xx(isp, handle, portid, &logval); + } else { + logval = isp_port_login(isp, handle, portid); + } + if (FCPARAM(isp)->isp_loopstate != LOOP_SCANNING_FABRIC) { + return (-1); + } + if (logval == 0) { + *ohp = handle; + break; + } else if ((logval & 0xffff) == MBOX_PORT_ID_USED) { + handle = logval >> 16; + break; + } else if (logval != MBOX_LOOP_ID_USED) { + r = lim; + break; + } else { + *ohp = handle; + handle = isp_nxt_handle(isp, *ohp); + } + } + + if (r == lim) { + isp_prt(isp, ISP_LOGERR, "PLOGI 0x%06x failed", portid); + return (-1); + } + + /* + * If we successfully logged into it, get the PDB for it + * so we can crosscheck that it is still what we think it + * is and that we also have the role it plays + */ + r = isp_getpdb(isp, handle, p, 0); + if (FCPARAM(isp)->isp_loopstate != LOOP_SCANNING_FABRIC) { + return (-1); + } + if (r != 0) { + isp_prt(isp, ISP_LOGERR, "new device 0x%06x@0x%x disappeared", + portid, handle); + return (-1); + } + + if (p->handle != handle || p->portid != portid) { + isp_prt(isp, ISP_LOGERR, + "new device 0x%06x@0x%x changed (0x%06x@0x%0x", + portid, handle, p->portid, p->handle); + return (-1); + } + return (0); +} + static int isp_register_fc4_type(ispsoftc_t *isp) { From owner-p4-projects@FreeBSD.ORG Thu Sep 28 11:42:49 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id DFA3F16A47B; Thu, 28 Sep 2006 11:42:48 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 9D4FB16A415 for ; Thu, 28 Sep 2006 11:42:48 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9B4E943D68 for ; Thu, 28 Sep 2006 11:42:42 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8SBggFG079648 for ; Thu, 28 Sep 2006 11:42:42 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8SBggPZ079645 for perforce@freebsd.org; Thu, 28 Sep 2006 11:42:42 GMT (envelope-from soc-andrew@freebsd.org) Date: Thu, 28 Sep 2006 11:42:42 GMT Message-Id: <200609281142.k8SBggPZ079645@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106813 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 11:42:49 -0000 http://perforce.freebsd.org/chv.cgi?CH=106813 Change 106813 by soc-andrew@soc-andrew_serv on 2006/09/28 11:41:51 Update the pre-install tasks to the newer snapshot Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/050_welcome.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/100_select_language.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/150_configure_console.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/400_load_kernel_modules.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/800_configure_network.lua#3 edit .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/main.lua#3 edit Differences ... ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/050_welcome.lua#3 (text+ko) ==== @@ -1,74 +1,73 @@ --- $Id: 050_welcome.lua,v 1.10 2005/08/26 04:25:25 cpressey Exp $ +-- $Id: 050_welcome.lua,v 1.12 2006/09/13 23:43:26 cpressey Exp $ -- -- "Welcome screen" for the BSD Installer. -- -return { - id = "welcome", - name = _("Welcome Screen"), - effect = function(step) - local result = App.ui:present({ - id = "welcome", - name = _("Welcome to the BSD Installer!"), - short_desc = _( - "Welcome to the BSD Installer!\n\n" .. - "Before we begin, you will be asked a few questions " .. - "so that this installation environment can be set up " .. - "to suit your needs.\n\n" .. - "You will then be presented a menu of items from which " .. - "you may select to install a new system, or configure " .. - "or upgrade an existing system." - ), - actions = { - { - id = "ok", - name = _("Proceed"), - short_desc = _("Set up the installation environment and continue") - }, - { - id = "skip", - accelerator = "ESC", - -- - -- XXX This should really be something more like this: - -- name = _("Skip to %s", step:get_upper_name()) - -- ...but current technical limitations prevent this. - -- (The pre-install tasks are invoked explicitly from - -- the main script, and not from the Select Task menu.) - -- - name = _("Skip to Select Task Menu"), - short_desc = _("Don't configure the environment; accept the default settings and continue") - }, - { - id = "reboot", - name = _("Reboot"), - short_desc = _("Reboot this computer") - }, - { - id = "exit", - name = _("Exit to %s", App.conf.media_name), - short_desc = _("Cancel this process and return to a command prompt") - } - } - }).action_id +id = "welcome" +name = _("Welcome Screen") + +effect = function(step) + local result = App.ui:present({ + id = "welcome", + name = _("Welcome to the BSD Installer!"), + short_desc = _( + "Welcome to the BSD Installer!\n\n" .. + "Before we begin, you will be asked a few questions " .. + "so that this installation environment can be set up " .. + "to suit your needs.\n\n" .. + "You will then be presented a menu of items from which " .. + "you may select to install a new system, or configure " .. + "or upgrade an existing system." + ), + actions = { + { + id = "ok", + name = _("Proceed"), + short_desc = _("Set up the installation environment and continue") + }, + { + id = "skip", + accelerator = "ESC", + -- + -- XXX This should really be something more like this: + -- name = _("Skip to %s", step:get_upper_name()) + -- ...but current technical limitations prevent this. + -- (The pre-install tasks are invoked explicitly from + -- the main script, and not from the Select Task menu.) + -- + name = _("Skip to Select Task Menu"), + short_desc = _("Don't configure the environment; accept the default settings and continue") + }, + { + id = "reboot", + name = _("Reboot"), + short_desc = _("Reboot this computer") + }, + { + id = "exit", + name = _("Exit to %s", App.conf.media_name), + short_desc = _("Cancel this process and return to a command prompt") + } + } + }).action_id - if result == "ok" then - return step:next() - elseif result == "skip" then - return nil - elseif result == "reboot" then - if TargetSystemUI.ask_reboot{ - cancel_desc = _("Return to %s", step:get_name()) - } then - App.state.do_reboot = true - return nil - else - return step - end - return nil - elseif result == "exit" then - App.state.do_exit = true - return nil + if result == "ok" then + return step:next() + elseif result == "skip" then + return nil + elseif result == "reboot" then + if App.state.source:ask_reboot{ + cancel_desc = _("Return to %s", step:get_name()) + } then + App.state.do_reboot = true + return nil + else + return step end + return nil + elseif result == "exit" then + App.state.do_exit = true + return nil end -} +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/100_select_language.lua#3 (text+ko) ==== @@ -1,120 +1,121 @@ --- $Id: 100_select_language.lua,v 1.18 2005/08/28 23:36:49 cpressey Exp $ +-- $Id: 100_select_language.lua,v 1.19 2006/09/13 23:43:26 cpressey Exp $ + +id = "select_language" +name = _("Select Language") -- -- If gettext isn't enabled, skip this Step - just don't return anything -- from this scriptlet, and the Flow object will not generate a Step. -- -if not GetText then - return nil +condition = function() + if not GetText then + return false, "GetText module is not available" + end + return true end -return { - id = "select_language", - name = _("Select Language"), - effect = function(step) - local actions = { - { - id = "default", - name = _("Default (English)"), - short_desc = _("Do not apply any language translation"), - accelerator = "ESC" - } - } +effect = function(step) + local actions = { + { + id = "default", + name = _("Default (English)"), + short_desc = _("Do not apply any language translation"), + accelerator = "ESC" + } + } + + -- + -- Load list of available languages from configuration file. + -- + local languages = App.conf.languages + + -- + -- If no languages are available, just skip this step. + -- + if not languages or table.getn(languages) == 0 then + return step:next() + end + + -- + -- Create actions for this dialog box, corresponding to available + -- languages. + -- XXX sort languages table by id, first + -- XXX also create table indexed by id, for lookup in messages? + -- + local i, lang_tab + for i, lang_tab in languages do + table.insert(actions, { + id = lang_tab.id, + name = lang_tab.name, + short_desc = lang_tab.short_desc + }) + end - -- - -- Load list of available languages from configuration file. - -- - local languages = App.conf.languages + local sel_lang_id = App.ui:present({ + id = "select_language", + name = _("Select Language"), + short_desc = _("Please select the language you wish you use."), + role = "menu", + actions = actions + }).action_id + if sel_lang_id == "default" then + App.state.lang_id = nil + else -- - -- If no languages are available, just skip this step. + -- Set up appropriate keymap, screenmap, and console fonts. -- - if not languages or table.getn(languages) == 0 then - return step:next() + if not App.ui:set("lang_syscons", sel_lang_id) then + App.ui:inform(_( + "Unable to apply console settings " .. + "for language '%s'.", sel_lang_id + )) + return step end -- - -- Create actions for this dialog box, corresponding to available - -- languages. - -- XXX sort languages table by id, first - -- XXX also create table indexed by id, for lookup in messages? + -- Set up appropriate environment variables. -- - local i, lang_tab - for i, lang_tab in languages do - table.insert(actions, { - id = lang_tab.id, - name = lang_tab.name, - short_desc = lang_tab.short_desc - }) + if not App.ui:set("lang_envars", sel_lang_id) then + App.ui:inform(_( + "Unable to set environment variables " .. + "for language '%s'.", sel_lang_id + )) + return step end - local sel_lang_id = App.ui:present({ - id = "select_language", - name = _("Select Language"), - short_desc = _("Please select the language you wish you use."), - role = "menu", - actions = actions - }).action_id + if not App.ui:set("lang", sel_lang_id) then + App.ui:inform(_( + "Unable to inform the user interface that " .. + "it should now use language '%s'.", sel_lang_id + )) + return step + end - if sel_lang_id == "default" then - App.state.lang_id = nil - else - -- - -- Set up appropriate keymap, screenmap, and console fonts. - -- - if not App.ui:set("lang_syscons", sel_lang_id) then - App.ui:inform(_( - "Unable to apply console settings " .. - "for language '%s'.", sel_lang_id - )) - return step - end + -- + -- Finally, let gettext know about the change of + -- the selected language: + -- + GetText.notify_change() - -- - -- Set up appropriate environment variables. - -- - if not App.ui:set("lang_envars", sel_lang_id) then - App.ui:inform(_( - "Unable to set environment variables " .. - "for language '%s'.", sel_lang_id - )) - return step - end + -- + -- And record it in App.state so that future decisions + -- can be made based on it: + -- + App.state.lang_id = sel_lang_id - if not App.ui:set("lang", sel_lang_id) then - App.ui:inform(_( - "Unable to inform the user interface that " .. - "it should now use language '%s'.", sel_lang_id - )) - return step - end - - -- - -- Finally, let gettext know about the change of - -- the selected language: - -- - GetText.notify_change() - - -- - -- And record it in App.state so that future decisions - -- can be made based on it: - -- - App.state.lang_id = sel_lang_id - - -- - -- Record the associated console settings, too. - -- - for i, lang_tab in languages do - if lang_tab.id == App.state.lang_id then - App.state.vidfont = lang_tab.vidfont - App.state.scrnmap = lang_tab.scrnmap - App.state.keymap = lang_tab.keymap - break - end - end - + -- + -- Record the associated console settings, too. + -- + for i, lang_tab in languages do + if lang_tab.id == App.state.lang_id then + App.state.vidfont = lang_tab.vidfont + App.state.scrnmap = lang_tab.scrnmap + App.state.keymap = lang_tab.keymap + break + end end + end - return step:next() - end -} + return step:next() +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/150_configure_console.lua#2 (text+ko) ==== @@ -1,13 +1,11 @@ --- $Id: 150_configure_console.lua,v 1.4 2005/08/04 22:00:40 cpressey Exp $ +-- $Id: 150_configure_console.lua,v 1.6 2006/09/13 23:43:26 cpressey Exp $ + +id = "configure_console" +name = _("Configure Console") -return { - id = "configure_console", - name = _("Configure Console"), - effect = function(step) - TargetSystemUI.configure_console{ - ts = App.state.source, - allow_cancel = false - } - return step:next() - end -} +effect = function(step) + App.state.source:configure_console{ + allow_cancel = false + } + return step:next() +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/400_load_kernel_modules.lua#3 (text+ko) ==== @@ -1,52 +1,51 @@ --- $Id: 400_load_kernel_modules.lua,v 1.5 2005/07/20 04:26:39 cpressey Exp $ +-- $Id: 400_load_kernel_modules.lua,v 1.6 2006/09/13 23:43:26 cpressey Exp $ -return { - id = "load_kernel_modules", - name = _("Load Kernel Modules"), - effect = function(step) - -- - -- Select a file. - -- - local dir = App.expand("${root}${MODULES_DIR}") +id = "load_kernel_modules" +name = _("Load Kernel Modules") - local filename = App.ui:select_file{ - title = _("Select Kernel Module to Load"), - short_desc = _( - "You may wish to load some kernel modules before " .. - "using the system (for example, to enable network " .. - "interfaces which require drivers which are not " .. - "included in the kernel by default.) You may " .. - "select a kernel module to load here." - ), - cancel_desc = _("Do not Load any Further Kernel Modules"), - cancel_pos = "top", - dir = dir, - predicate = function(filename) - return string.find(filename, "%.ko$") - end - } +effect = function(step) + -- + -- Select a file. + -- + local dir = App.expand("${root}${MODULES_DIR}") - if filename == "cancel" then - return step:next() - else - local cmds = CmdChain.new() + local filename = App.ui:select_file{ + title = _("Select Kernel Module to Load"), + short_desc = _( + "You may wish to load some kernel modules before " .. + "using the system (for example, to enable network " .. + "interfaces which require drivers which are not " .. + "included in the kernel by default.) You may " .. + "select a kernel module to load here." + ), + cancel_desc = _("Do not Load any Further Kernel Modules"), + cancel_pos = "top", + dir = dir, + predicate = function(filename) + return string.find(filename, "%.ko$") + end + } - cmds:add("${root}${KLDLOAD} ${root}modules/" .. filename) + if filename == "cancel" then + return step:next() + else + local cmds = CmdChain.new() - if cmds:execute() then - App.ui:inform(_( - "Kernel module '%s' was successfully loaded.", - filename - )) - else - App.ui:inform(_( - "Warning: kernel module '%s' could not " .. - "successfully be loaded.", - filename - )) - end + cmds:add("${root}${KLDLOAD} ${root}modules/" .. filename) - return step + if cmds:execute() then + App.ui:inform(_( + "Kernel module '%s' was successfully loaded.", + filename + )) + else + App.ui:inform(_( + "Warning: kernel module '%s' could not " .. + "successfully be loaded.", + filename + )) end + + return step end -} +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/800_configure_network.lua#3 (text+ko) ==== @@ -1,37 +1,36 @@ --- $Id: 800_configure_network.lua,v 1.17 2005/08/28 23:36:49 cpressey Exp $ +-- $Id: 800_configure_network.lua,v 1.18 2006/09/13 23:43:26 cpressey Exp $ -return { - id = "configure_network", - name = _("Configure your Network"), - req_state = { "net_if" }, - effect = function(step) - local actions, ifname, ni, result +id = "configure_network" +name = _("Configure your Network") +req_state = { "net_if" } - if App.state.net_if:ip_addr_count() > 0 then - -- - -- Looks like at least one interface is 'up'; - -- we assume that means it's already been - -- configured. - -- - return step:next() - end +effect = function(step) + local actions, ifname, ni, result - if not App.ui:confirm(_( - "You have not yet configured your network settings. " .. - "Would you like to do so now? (Having an operational " .. - "network connection will enhance the ability of " .. - "subsequent tasks, such as installing.)" - )) then - return step:next() - end + if App.state.net_if:ip_addr_count() > 0 then + -- + -- Looks like at least one interface is 'up'; + -- we assume that means it's already been + -- configured. + -- + return step:next() + end - ni = NetworkUI.select_interface(App.state.net_if) - if not ni then - return step:next() - end + if not App.ui:confirm(_( + "You have not yet configured your network settings. " .. + "Would you like to do so now? (Having an operational " .. + "network connection will enhance the ability of " .. + "subsequent tasks, such as installing.)" + )) then + return step:next() + end - NetworkUI.configure_interface(ni) - + ni = NetworkUI.select_interface(App.state.net_if) + if not ni then return step:next() end -} + + NetworkUI.configure_interface(ni) + + return step:next() +end ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/pit/main.lua#3 (text+ko) ==== @@ -1,8 +1,8 @@ -- pit/main.lua --- $Id: main.lua,v 1.10 2005/04/22 04:57:07 cpressey Exp $ +-- $Id: main.lua,v 1.11 2006/09/02 16:36:55 cpressey Exp $ -- Flow for "pre-install tasks" Flow.new{ id = "pre_install_tasks", name = _("Pre-Install Tasks") -}:populate("."):run() +}:populate("."):present() From owner-p4-projects@FreeBSD.ORG Thu Sep 28 18:15:58 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E6D5216A4A7; Thu, 28 Sep 2006 18:15:57 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 9D6C116A415; Thu, 28 Sep 2006 18:15:57 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from cyrus.watson.org (cyrus.watson.org [209.31.154.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8264243D53; Thu, 28 Sep 2006 18:15:55 +0000 (GMT) (envelope-from rwatson@FreeBSD.org) Received: from fledge.watson.org (fledge.watson.org [209.31.154.41]) by cyrus.watson.org (Postfix) with ESMTP id B033D46BF9; Thu, 28 Sep 2006 14:15:54 -0400 (EDT) Date: Thu, 28 Sep 2006 19:15:54 +0100 (BST) From: Robert Watson X-X-Sender: robert@fledge.watson.org To: Marcin Cieslak In-Reply-To: <451A7C35.8050209@SYSTEM.PL> Message-ID: <20060928191350.L76119@fledge.watson.org> References: <200609091856.k89Iu9lN090213@repoman.freebsd.org> <20060928083623.GA1297@FreeBSD.czest.pl> <451A7C35.8050209@SYSTEM.PL> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Perforce Change Reviews , Alexander Leidinger Subject: Re: PERFORCE change 105906 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 18:15:58 -0000 On Wed, 27 Sep 2006, Marcin Cieslak wrote: > It may happen that implementing delivery of the process ID of the other side > of the socket - feature not available AFAIK in the FreeBSD right now - will > impose on us much deeper dive into internal socket structures. The notion of "The process ID on the other side of a socket" is nonsensical. There may be zero, one, or many processes hooked up to a socket. The situations in which you can point clearly at a process or credential are the process/credential that called connect (if any), and the process/credential that sent a message. This is the distinction between LOCAL_CREDS and SCM_CREDS, FYI. Robert N M Watson Computer Laboratory University of Cambridge From owner-p4-projects@FreeBSD.ORG Thu Sep 28 19:38:19 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8CA9216A60A; Thu, 28 Sep 2006 19:38:19 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 4225C16A604 for ; Thu, 28 Sep 2006 19:38:19 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id D054043D4C for ; Thu, 28 Sep 2006 19:38:18 +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.6/8.13.6) with ESMTP id k8SJcIKs038394 for ; Thu, 28 Sep 2006 19:38:18 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8SJcI2G038387 for perforce@freebsd.org; Thu, 28 Sep 2006 19:38:18 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Thu, 28 Sep 2006 19:38:18 GMT Message-Id: <200609281938.k8SJcI2G038387@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 Cc: Subject: PERFORCE change 106842 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 19:38:19 -0000 http://perforce.freebsd.org/chv.cgi?CH=106842 Change 106842 by rwatson@rwatson_zoo on 2006/09/28 19:38:05 First cut at revised ipcperm(). Untested. Affected files ... .. //depot/projects/trustedbsd/priv/sys/kern/sysv_ipc.c#2 edit Differences ... ==== //depot/projects/trustedbsd/priv/sys/kern/sysv_ipc.c#2 (text+ko) ==== @@ -1,6 +1,7 @@ /* $NetBSD: sysv_ipc.c,v 1.7 1994/06/29 06:33:11 cgd Exp $ */ /*- * Copyright (c) 1994 Herb Peyerl + * Copyright (c) 2006 Robert N. M. Watson * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -39,6 +40,7 @@ #include #include #include +#include #include #include @@ -72,50 +74,73 @@ * Note: The MAC Framework does not require any modifications to the * ipcperm() function, as access control checks are performed throughout the * implementation of each primitive. Those entry point calls complement the - * ipcperm() discertionary checks. + * ipcperm() discertionary checks. Unlike file system discretionary access + * control, the original create of an object is given the same rights as the + * current owner. */ int -ipcperm(td, perm, mode) - struct thread *td; - struct ipc_perm *perm; - int mode; +ipcperm(struct thread *td, struct ipc_perm *perm, int acc_mode) { struct ucred *cred = td->td_ucred; - int error; + int error, obj_mode, dac_granted, priv_granted; - if (cred->cr_uid != perm->cuid && cred->cr_uid != perm->uid) { - /* - * For a non-create/owner, we require privilege to - * modify the object protections. Note: some other - * implementations permit IPC_M to be delegated to - * unprivileged non-creator/owner uids/gids. - */ - if (mode & IPC_M) { - error = suser(td); - if (error) - return (error); - } - /* - * Try to match against creator/owner group; if not, fall - * back on other. - */ - mode >>= 3; - if (!groupmember(perm->gid, cred) && - !groupmember(perm->cgid, cred)) - mode >>= 3; + dac_granted = 0; + if (cred->cr_uid == perm->cuid || cred->cr_uid == perm->uid) { + obj_mode = perm->mode; + dac_granted |= IPC_M; + } else if (groupmember(perm->gid, cred) || + groupmember(perm->cgid, cred)) { + obj_mode = perm->mode; + obj_mode <<= 3; } else { - /* - * Always permit the creator/owner to update the object - * protections regardless of whether the object mode - * permits it. - */ - if (mode & IPC_M) - return (0); + obj_mode = perm->mode; + obj_mode <<= 6; + } + + /* + * While the System V IPC permission model allows IPC_M to be + * granted, as part of the mode, our implementation requires + * privilege to adminster the object if not the owner or creator. + */ +#if 0 + if (obj_mode & IPC_M) + dac_granted |= IPC_M; +#endif + if (obj_mode & IPC_R) + dac_granted |= IPC_R; + if (obj_mode & IPC_W) + dac_granted |= IPC_W; + + /* + * Simple case: all required rights are granted by DAC. + */ + if ((dac_granted & acc_mode) == acc_mode) + return (0); + + /* + * Privilege is required to satisfy the request. + */ + priv_granted = 0; + if ((acc_mode & IPC_M) && !(dac_granted & IPC_M)) { + error = priv_check(td, PRIV_IPC_ADMIN); + if (error == 0) + priv_granted |= IPC_M; + } + + if ((acc_mode & IPC_R) && !(dac_granted & IPC_R)) { + error = priv_check(td, PRIV_IPC_READ); + if (error == 0) + priv_granted |= IPC_R; } - if ((mode & perm->mode) != mode) { - if (suser(td) != 0) - return (EACCES); + if ((acc_mode & IPC_W) && !(dac_granted & IPC_W)) { + error = priv_check(td, PRIV_IPC_WRITE); + if (error == 0) + priv_granted |= IPC_W; } - return (0); + + if (((dac_granted | priv_granted) & acc_mode) == acc_mode) + return (0); + else + return (EACCES); } From owner-p4-projects@FreeBSD.ORG Thu Sep 28 19:56:48 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 64D7016A417; Thu, 28 Sep 2006 19:56:48 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 4331816A415 for ; Thu, 28 Sep 2006 19:56:48 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id E05C243D66 for ; Thu, 28 Sep 2006 19:56:44 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8SJuiEh042100 for ; Thu, 28 Sep 2006 19:56:44 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8SJuiZX042086 for perforce@freebsd.org; Thu, 28 Sep 2006 19:56:44 GMT (envelope-from imp@freebsd.org) Date: Thu, 28 Sep 2006 19:56:44 GMT Message-Id: <200609281956.k8SJuiZX042086@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106847 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 19:56:48 -0000 http://perforce.freebsd.org/chv.cgi?CH=106847 Change 106847 by imp@imp_lighthouse on 2006/09/28 19:56:17 Make non-data command transfers actually work in interrupt mode. Oops. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#9 edit .. //depot/projects/arm/src/sys/arm/at91/at91_mcireg.h#5 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#9 (text+ko) ==== @@ -74,6 +74,7 @@ int wire4; int bus_busy; struct mmc_request *req; + struct mmc_command *curcmd; }; static inline uint32_t @@ -108,6 +109,20 @@ #define AT91_MCI_ASSERT_UNLOCKED(_sc) mtx_assert(&_sc->sc_mtx, MA_NOTOWNED); static void +at91_mci_pdc_disable(struct at91_mci_softc *sc) +{ + WR4(sc, PDC_PTCR, PDC_PTCR_TXTDIS | PDC_PTCR_RXTDIS); + WR4(sc, PDC_RPR, 0); + WR4(sc, PDC_RCR, 0); + WR4(sc, PDC_RNPR, 0); + WR4(sc, PDC_RNCR, 0); + WR4(sc, PDC_TPR, 0); + WR4(sc, PDC_TCR, 0); + WR4(sc, PDC_TNPR, 0); + WR4(sc, PDC_TNCR, 0); +} + +static void at91_mci_init(device_t dev) { struct at91_mci_softc *sc = device_get_softc(dev); @@ -125,6 +140,7 @@ struct at91_mci_softc *sc = device_get_softc(dev); WR4(sc, MCI_IDR, 0xffffffff); /* Turn off interrupts */ + at91_mci_pdc_disable(sc); WR4(sc, MCI_CR, MCI_CR_MCIDIS | MCI_CR_SWRST); /* Put the device into reset */ } @@ -292,7 +308,47 @@ static void at91_mci_start_cmd(struct at91_mci_softc *sc, struct mmc_command *cmd) { - // XXX + uint32_t cmdr; + + sc->curcmd = cmd; + cmdr = cmd->opcode; + if (MMC_RSP(cmd->flags) == MMC_RSP_NONE) + cmdr |= MCI_CMDR_RSPTYP_NO; + else { + /* Allow big timeout for responses */ + cmdr |= MCI_CMDR_MAXLAT; + if (cmd->flags & MMC_RSP_136) + cmdr |= MCI_CMDR_RSPTYP_136; + else + cmdr |= MCI_CMDR_RSPTYP_48; + } +#if 0 + if (cmd->data) { + if (cmd->data->flags & MMC_DATA_READ) + cmdr |= MCI_CMDR_TRDIR; + if (cmd->data->flags & (MMC_DATA_READ | MMC_DATA_WRITE)) + cmdr |= MCI_CMDR_TRCMD_START; + if (cmd->data->flags & MMC_DATA_STREAM) + cmdr |= MCI_CMDR_TRTYP_STREAM; + if (cmd->data->flags & MMC_DATA_MULTI) + cmdr |= MCI_CMDR_TRTYP_MULTIPLE; + // XXX bad + } +#endif + if (cmd->opcode == MMC_STOP_TRANSMISSION) + cmdr |= MCI_CMDR_TRCMD_STOP; +#if 0 + if (??? == opendrain) + cmdr |= MCI_CMDR_OPDCMD; +#endif + if (!cmd->data) { + at91_mci_pdc_disable(sc); + WR4(sc, MCI_ARGR, cmd->arg); + WR4(sc, MCI_CMDR, cmdr); + WR4(sc, MCI_IER, MCI_SR_ERROR | MCI_SR_CMDRDY); + return; + } +// panic(); } static void @@ -300,20 +356,26 @@ { struct mmc_request *req; + req = sc->req; // assert locked if (!(sc->flags & CMD_STARTED)) { + printf("Starting command %d of request %p\n", req->cmd->opcode, + req); sc->flags |= CMD_STARTED; at91_mci_start_cmd(sc, req->cmd); return; } if (!(sc->flags & STOP_STARTED) && req->stop) { + printf("Starting command %d of request %p\n", req->stop->opcode, + req); sc->flags |= STOP_STARTED; at91_mci_start_cmd(sc, req->stop); return; } /* We must be done -- bad idea to do this while locked? */ - req = sc->req; + printf("Finished request %p\n", req); sc->req = NULL; + sc->curcmd = NULL; req->done(req->done_data); } @@ -322,6 +384,7 @@ { struct at91_mci_softc *sc = device_get_softc(brdev); + printf("queuing request %p\n", req); AT91_MCI_LOCK(sc); // XXX do we want to be able to queue up multiple commands? // XXX sounds like a good idea, but all protocols are sync, so @@ -399,10 +462,33 @@ at91_mci_intr(void *arg) { struct at91_mci_softc *sc = (struct at91_mci_softc*)arg; + uint32_t sr; + int i; + struct mmc_command *cmd; AT91_MCI_LOCK(sc); - printf("i 0x%x\n", RD4(sc, MCI_SR)); - wakeup(sc); + sr = RD4(sc, MCI_SR); + printf("i 0x%x\n", sr); WR4(sc, MCI_IDR, 0xffffffff); + cmd = sc->curcmd; + if (sr & MCI_SR_CMDRDY && cmd != NULL) + for (i = 0; i < 4; i++) + cmd->resp[i] = RD4(sc, MCI_RSPR + (i << 2)); + if (sr & MCI_SR_ERROR) { + if ((sr & MCI_SR_RCRCE) && (cmd->opcode == MMC_SEND_OP_COND || + cmd->opcode == ACMD_SD_SEND_OP_COND)) + cmd->error = MMC_ERR_NONE; + else if (sr & (MCI_SR_RTOE | MCI_SR_DTOE)) + cmd->error = MMC_ERR_TIMEOUT; + else if (sr & (MCI_SR_RCRCE | MCI_SR_DCRCE)) + cmd->error = MMC_ERR_BADCRC; + else if (sr & (MCI_SR_OVRE | MCI_SR_UNRE)) + cmd->error = MMC_ERR_FIFO; + else + cmd->error = MMC_ERR_FAILED; + } else + cmd->error = MMC_ERR_NONE; + + at91_mci_start(sc); AT91_MCI_UNLOCK(sc); } ==== //depot/projects/arm/src/sys/arm/at91/at91_mcireg.h#5 (text+ko) ==== @@ -94,40 +94,33 @@ #define MCI_CMDR_TRTYP_MULTIPLE (0x1u << 19) /* (MCI) Multiple Block transfer type */ #define MCI_CMDR_TRTYP_STREAM (0x2u << 19) /* (MCI) Stream transfer type */ /* -------- MCI_SR : (MCI Offset: 0x40) MCI Status Register -------- */ -#define MCI_SR_CMDRDY (0x1u << 0) /* (MCI) Command Ready flag */ -#define MCI_SR_RXRDY (0x1u << 1) /* (MCI) RX Ready flag */ -#define MCI_SR_TXRDY (0x1u << 2) /* (MCI) TX Ready flag */ -#define MCI_SR_BLKE (0x1u << 3) /* (MCI) Data Block Transfer Ended flag */ -#define MCI_SR_DTIP (0x1u << 4) /* (MCI) Data Transfer in Progress flag */ -#define MCI_SR_NOTBUSY (0x1u << 5) /* (MCI) Data Line Not Busy flag */ -#define MCI_SR_ENDRX (0x1u << 6) /* (MCI) End of RX Buffer flag */ -#define MCI_SR_ENDTX (0x1u << 7) /* (MCI) End of TX Buffer flag */ -#define MCI_SR_RXBUFF (0x1u << 14) /* (MCI) RX Buffer Full flag */ -#define MCI_SR_TXBUFE (0x1u << 15) /* (MCI) TX Buffer Empty flag */ -#define MCI_SR_RINDE (0x1u << 16) /* (MCI) Response Index Error flag */ -#define MCI_SR_RDIRE (0x1u << 17) /* (MCI) Response Direction Error flag */ -#define MCI_SR_RCRCE (0x1u << 18) /* (MCI) Response CRC Error flag */ -#define MCI_SR_RENDE (0x1u << 19) /* (MCI) Response End Bit Error flag */ -#define MCI_SR_RTOE (0x1u << 20) /* (MCI) Response Time-out Error flag */ -#define MCI_SR_DCRCE (0x1u << 21) /* (MCI) data CRC Error flag */ -#define MCI_SR_DTOE (0x1u << 22) /* (MCI) Data timeout Error flag */ -#define MCI_SR_OVRE (0x1u << 30) /* (MCI) Overrun flag */ -#define MCI_SR_UNRE (0x1u << 31) /* (MCI) Underrun flag */ +#define MCI_SR_CMDRDY (0x1u << 0) /* (MCI) Command Ready flag */ +#define MCI_SR_RXRDY (0x1u << 1) /* (MCI) RX Ready flag */ +#define MCI_SR_TXRDY (0x1u << 2) /* (MCI) TX Ready flag */ +#define MCI_SR_BLKE (0x1u << 3) /* (MCI) Data Block Transfer Ended flag */ +#define MCI_SR_DTIP (0x1u << 4) /* (MCI) Data Transfer in Progress flag */ +#define MCI_SR_NOTBUSY (0x1u << 5) /* (MCI) Data Line Not Busy flag */ +#define MCI_SR_ENDRX (0x1u << 6) /* (MCI) End of RX Buffer flag */ +#define MCI_SR_ENDTX (0x1u << 7) /* (MCI) End of TX Buffer flag */ +#define MCI_SR_RXBUFF (0x1u << 14) /* (MCI) RX Buffer Full flag */ +#define MCI_SR_TXBUFE (0x1u << 15) /* (MCI) TX Buffer Empty flag */ +#define MCI_SR_RINDE (0x1u << 16) /* (MCI) Response Index Error flag */ +#define MCI_SR_RDIRE (0x1u << 17) /* (MCI) Response Direction Error flag */ +#define MCI_SR_RCRCE (0x1u << 18) /* (MCI) Response CRC Error flag */ +#define MCI_SR_RENDE (0x1u << 19) /* (MCI) Response End Bit Error flag */ +#define MCI_SR_RTOE (0x1u << 20) /* (MCI) Response Time-out Error flag */ +#define MCI_SR_DCRCE (0x1u << 21) /* (MCI) data CRC Error flag */ +#define MCI_SR_DTOE (0x1u << 22) /* (MCI) Data timeout Error flag */ +#define MCI_SR_OVRE (0x1u << 30) /* (MCI) Overrun flag */ +#define MCI_SR_UNRE (0x1u << 31) /* (MCI) Underrun flag */ + /* -------- MCI_IER : (MCI Offset: 0x44) MCI Interrupt Enable Register -------- */ /* -------- MCI_IDR : (MCI Offset: 0x48) MCI Interrupt Disable Register -------- */ /* -------- MCI_IMR : (MCI Offset: 0x4c) MCI Interrupt Mask Register -------- */ -#define MCI_SR_ERROR (MCI_SR_UNRE |\ - MCI_SR_OVRE |\ - MCI_SR_DTOE |\ - MCI_SR_DCRCE |\ - MCI_SR_RTOE |\ - MCI_SR_RENDE |\ - MCI_SR_RCRCE |\ - MCI_SR_RDIRE |\ - MCI_SR_RINDE) - -#define AT91C_NO_ARGUMENT 0x0 +#define MCI_SR_ERROR (MCI_SR_UNRE | MCI_SR_OVRE | MCI_SR_DTOE | \ + MCI_SR_DCRCE | MCI_SR_RTOE | MCI_SR_RENDE | \ + MCI_SR_RCRCE | MCI_SR_RDIRE | MCI_SR_RINDE) #define AT91C_BUS_WIDTH_1BIT 0x00 #define AT91C_BUS_WIDTH_4BITS 0x02 From owner-p4-projects@FreeBSD.ORG Thu Sep 28 21:36:54 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id C9E7816A4A0; Thu, 28 Sep 2006 21:36:54 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 9AB8716A494 for ; Thu, 28 Sep 2006 21:36:54 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 618DB43D49 for ; Thu, 28 Sep 2006 21:36:54 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8SLast6058153 for ; Thu, 28 Sep 2006 21:36:54 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8SLasoo058150 for perforce@freebsd.org; Thu, 28 Sep 2006 21:36:54 GMT (envelope-from imp@freebsd.org) Date: Thu, 28 Sep 2006 21:36:54 GMT Message-Id: <200609282136.k8SLasoo058150@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106850 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 21:36:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=106850 Change 106850 by imp@imp_lighthouse on 2006/09/28 21:36:31 Expand the ISR to be nearly complete. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#10 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#10 (text+ko) ==== @@ -463,17 +463,14 @@ { struct at91_mci_softc *sc = (struct at91_mci_softc*)arg; uint32_t sr; - int i; + int i, done = 0; struct mmc_command *cmd; AT91_MCI_LOCK(sc); - sr = RD4(sc, MCI_SR); + sr = RD4(sc, MCI_SR) & RD4(sc, MCI_IMR); printf("i 0x%x\n", sr); WR4(sc, MCI_IDR, 0xffffffff); cmd = sc->curcmd; - if (sr & MCI_SR_CMDRDY && cmd != NULL) - for (i = 0; i < 4; i++) - cmd->resp[i] = RD4(sc, MCI_RSPR + (i << 2)); if (sr & MCI_SR_ERROR) { if ((sr & MCI_SR_RCRCE) && (cmd->opcode == MMC_SEND_OP_COND || cmd->opcode == ACMD_SD_SEND_OP_COND)) @@ -486,9 +483,50 @@ cmd->error = MMC_ERR_FIFO; else cmd->error = MMC_ERR_FAILED; - } else - cmd->error = MMC_ERR_NONE; - - at91_mci_start(sc); + done = 1; + } else { + if (sr & MCI_SR_TXBUFE) { + printf("TXBUFE\n"); +// at91_mci_xmit_done(sc); + } + if (sr & MCI_SR_RXBUFF) { + printf("RXBUFF\n"); + WR4(sc, MCI_IER, MCI_SR_CMDRDY); + } + if (sr & MCI_SR_ENDTX) { + printf("ENDTX\n"); + } + if (sr & MCI_SR_ENDRX) { + printf("ENDRX\n"); +// at91_mci_read_done(sc); + } + if (sr & MCI_SR_NOTBUSY) { + printf("NOTBUSY\n"); + WR4(sc, MCI_IER, MCI_SR_CMDRDY); + } + if (sr & MCI_SR_DTIP) { + printf("Data transfer in progress\n"); + } + if (sr & MCI_SR_BLKE) { + printf("Block transfer end\n"); + } + if (sr & MCI_SR_TXRDY) { + printf("Ready to transmit\n"); + } + if (sr & MCI_SR_RXRDY) { + printf("Ready to receive\n"); + } + if (sr & MCI_SR_CMDRDY) { + printf("Command ready\n"); + done = 1; + cmd->error = MMC_ERR_NONE; + } + } + if (done) { + if (cmd != NULL) + for (i = 0; i < 4; i++) + cmd->resp[i] = RD4(sc, MCI_RSPR + (i << 2)); + at91_mci_start(sc); + } AT91_MCI_UNLOCK(sc); } From owner-p4-projects@FreeBSD.ORG Thu Sep 28 21:38:57 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id C6B5E16A417; Thu, 28 Sep 2006 21:38:57 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 A29AA16A415 for ; Thu, 28 Sep 2006 21:38:57 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6FA8843D46 for ; Thu, 28 Sep 2006 21:38:57 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8SLcv1a058245 for ; Thu, 28 Sep 2006 21:38:57 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8SLcv3b058242 for perforce@freebsd.org; Thu, 28 Sep 2006 21:38:57 GMT (envelope-from imp@freebsd.org) Date: Thu, 28 Sep 2006 21:38:57 GMT Message-Id: <200609282138.k8SLcv3b058242@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106851 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Sep 2006 21:38:58 -0000 http://perforce.freebsd.org/chv.cgi?CH=106851 Change 106851 by imp@imp_lighthouse on 2006/09/28 21:38:47 pr0n! Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#11 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#11 (text+ko) ==== @@ -487,7 +487,7 @@ } else { if (sr & MCI_SR_TXBUFE) { printf("TXBUFE\n"); -// at91_mci_xmit_done(sc); +//XXX at91_mci_xmit_done(sc); } if (sr & MCI_SR_RXBUFF) { printf("RXBUFF\n"); @@ -498,7 +498,7 @@ } if (sr & MCI_SR_ENDRX) { printf("ENDRX\n"); -// at91_mci_read_done(sc); +//XXX at91_mci_read_done(sc); } if (sr & MCI_SR_NOTBUSY) { printf("NOTBUSY\n"); From owner-p4-projects@FreeBSD.ORG Fri Sep 29 03:46:43 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7FD7816A417; Fri, 29 Sep 2006 03:46:43 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 45B0F16A40F for ; Fri, 29 Sep 2006 03:46:43 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id E579943D55 for ; Fri, 29 Sep 2006 03:46:42 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8T3kga4003695 for ; Fri, 29 Sep 2006 03:46:42 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8T3kgw5003692 for perforce@freebsd.org; Fri, 29 Sep 2006 03:46:42 GMT (envelope-from imp@freebsd.org) Date: Fri, 29 Sep 2006 03:46:42 GMT Message-Id: <200609290346.k8T3kgw5003692@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106862 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 03:46:43 -0000 http://perforce.freebsd.org/chv.cgi?CH=106862 Change 106862 by imp@imp_lighthouse on 2006/09/29 03:46:00 continue writing the code to probe for cards. Getting close to needing to write the flash driver itself... Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#12 edit .. //depot/projects/arm/src/sys/dev/mmc/bridge.h#5 edit .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#8 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#12 (text+ko) ==== @@ -56,6 +56,7 @@ #include #include #include +#include #include "mmcbr_if.h" @@ -337,10 +338,8 @@ #endif if (cmd->opcode == MMC_STOP_TRANSMISSION) cmdr |= MCI_CMDR_TRCMD_STOP; -#if 0 - if (??? == opendrain) + if (sc->host.ios.bus_mode == opendrain) cmdr |= MCI_CMDR_OPDCMD; -#endif if (!cmd->data) { at91_mci_pdc_disable(sc); WR4(sc, MCI_ARGR, cmd->arg); @@ -432,32 +431,7 @@ return (0); } -static device_method_t at91_mci_methods[] = { - /* device_if */ - DEVMETHOD(device_probe, at91_mci_probe), - DEVMETHOD(device_attach, at91_mci_attach), - DEVMETHOD(device_detach, at91_mci_detach), - - /* mmcbr_if */ - DEVMETHOD(mmcbr_update_ios, at91_mci_update_ios), - DEVMETHOD(mmcbr_request, at91_mci_request), - DEVMETHOD(mmcbr_get_ro, at91_mci_get_ro), - DEVMETHOD(mmcbr_acquire_host, at91_mci_acquire_host), - DEVMETHOD(mmcbr_release_host, at91_mci_release_host), - - {0, 0}, -}; -static driver_t at91_mci_driver = { - "at91_mci", - at91_mci_methods, - sizeof(struct at91_mci_softc), -}; -static devclass_t at91_mci_devclass; - - -DRIVER_MODULE(at91_mci, atmelarm, at91_mci_driver, at91_mci_devclass, 0, 0); - static void at91_mci_intr(void *arg) { @@ -523,10 +497,129 @@ } } if (done) { - if (cmd != NULL) - for (i = 0; i < 4; i++) - cmd->resp[i] = RD4(sc, MCI_RSPR + (i << 2)); + if (cmd != NULL) { + for (i = 0; i < ((cmd->flags & MMC_RSP_136) ? 4 : 1); + i++) { + cmd->resp[i] = RD4(sc, MCI_RSPR + i * 4); + printf("RSPR[%d] = %x\n", i, cmd->resp[i]); + } + } at91_mci_start(sc); } AT91_MCI_UNLOCK(sc); } + +static int +at91_mci_read_ivar(device_t bus, device_t child, int which, u_char *result) +{ + struct at91_mci_softc *sc = device_get_softc(bus); + + switch (which) { + default: + return (EINVAL); + case MMCBR_IVAR_BUS_MODE: + *(int *)result = sc->host.ios.bus_mode; + break; + case MMCBR_IVAR_BUS_WIDTH: + *(int *)result = sc->host.ios.bus_width; + break; + case MMCBR_IVAR_CHIP_SELECT: + *(int *)result = sc->host.ios.chip_select; + break; + case MMCBR_IVAR_CLOCK: + *(int *)result = sc->host.ios.clock; + break; + case MMCBR_IVAR_F_MIN: + *(int *)result = sc->host.f_min; + break; + case MMCBR_IVAR_F_MAX: + *(int *)result = sc->host.f_max; + break; + case MMCBR_IVAR_HOST_OCR: + *(int *)result = sc->host.host_ocr; + break; + case MMCBR_IVAR_MODE: + *(int *)result = sc->host.mode; + break; + case MMCBR_IVAR_OCR: + *(int *)result = sc->host.ocr; + break; + case MMCBR_IVAR_POWER_MODE: + *(int *)result = sc->host.ios.power_mode; + break; + case MMCBR_IVAR_VDD: + *(int *)result = sc->host.ios.vdd; + break; + } + return (0); +} + +static int +at91_mci_write_ivar(device_t bus, device_t child, int which, uintptr_t value) +{ + struct at91_mci_softc *sc = device_get_softc(bus); + + switch (which) { + default: + return (EINVAL); + case MMCBR_IVAR_BUS_MODE: + sc->host.ios.bus_mode = value; + break; + case MMCBR_IVAR_BUS_WIDTH: + sc->host.ios.bus_width = value; + break; + case MMCBR_IVAR_CHIP_SELECT: + sc->host.ios.chip_select = value; + break; + case MMCBR_IVAR_CLOCK: + sc->host.ios.clock = value; + break; + case MMCBR_IVAR_MODE: + sc->host.mode = value; + break; + case MMCBR_IVAR_OCR: + sc->host.ocr = value; + break; + case MMCBR_IVAR_POWER_MODE: + sc->host.ios.power_mode = value; + break; + case MMCBR_IVAR_VDD: + sc->host.ios.vdd = value; + break; + case MMCBR_IVAR_HOST_OCR: + case MMCBR_IVAR_F_MIN: + case MMCBR_IVAR_F_MAX: + return (EINVAL); + } + return (0); +} + +static device_method_t at91_mci_methods[] = { + /* device_if */ + DEVMETHOD(device_probe, at91_mci_probe), + DEVMETHOD(device_attach, at91_mci_attach), + DEVMETHOD(device_detach, at91_mci_detach), + + /* Bus interface */ + DEVMETHOD(bus_read_ivar, at91_mci_read_ivar), + DEVMETHOD(bus_write_ivar, at91_mci_write_ivar), + + /* mmcbr_if */ + DEVMETHOD(mmcbr_update_ios, at91_mci_update_ios), + DEVMETHOD(mmcbr_request, at91_mci_request), + DEVMETHOD(mmcbr_get_ro, at91_mci_get_ro), + DEVMETHOD(mmcbr_acquire_host, at91_mci_acquire_host), + DEVMETHOD(mmcbr_release_host, at91_mci_release_host), + + {0, 0}, +}; + +static driver_t at91_mci_driver = { + "at91_mci", + at91_mci_methods, + sizeof(struct at91_mci_softc), +}; +static devclass_t at91_mci_devclass; + + +DRIVER_MODULE(at91_mci, atmelarm, at91_mci_driver, at91_mci_devclass, 0, 0); ==== //depot/projects/arm/src/sys/dev/mmc/bridge.h#5 (text+ko) ==== @@ -59,7 +59,7 @@ vdd_330, vdd_340, vdd_350, vdd_360 }; -enum mmc_poewr_mode { +enum mmc_power_mode { power_off = 0, power_up, power_on }; @@ -81,6 +81,7 @@ enum mmc_bus_mode bus_mode; enum mmc_chip_select chip_select; enum mmc_bus_width bus_width; + enum mmc_power_mode power_mode; }; enum mmc_card_mode { @@ -91,6 +92,7 @@ int f_min; int f_max; uint32_t host_ocr; + uint32_t ocr; uint32_t caps; #define MMC_CAP_4_BIT_DATA (1 << 0) /* Can do 4-bit data transfers */ #define MMC_CAP_8_BIT_DATA (1 << 1) /* Can do 8-bit data transfers */ ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#8 (text+ko) ==== @@ -126,6 +126,8 @@ static uint32_t mmc_select_vdd(struct mmc_softc *sc, uint32_t ocr) { + // XXX + return ocr; } static int @@ -237,6 +239,7 @@ for (i = 0; i < 100; i++) { err = mmc_wait_for_app_cmd(sc, 0, &cmd, CMD_RETRIES); + printf("err is %x busy is %x\n", err, cmd.resp[0]); if (err != MMC_ERR_NONE) break; if ((cmd.resp[0] & MMC_OCR_CARD_BUSY) || ocr == 0) @@ -246,6 +249,7 @@ } if (rocr && err == MMC_ERR_NONE) *rocr = cmd.resp[0]; + printf("app op sayz %x\n", cmd.resp[0]); return err; } @@ -298,6 +302,29 @@ static void mmc_discover_cards(struct mmc_softc *sc) { +#if 0 // XXX XXX XXX + while (1) { + err = mmc_all_send_cid(sc, &rca); + if (err == MMC_ERR_TIMEOUT) { + err = MMC_ERR_NONE; + break; + } + if (err != MMC_ERR_NONE) { + printf("Error reading CID %d\n", err); + break; + } + card = find_card(sc, rca); + if (host->mode == MMC_MODE_SD) { + mmc_card_set_sd(card); + mmc_send_relative_addr(sc, 0); + card->rca = cmd.resp[0] >> 16; + // RO check + break; + } + // MMC XXX card detection + // set relative addr + } +#endif } static void @@ -322,12 +349,13 @@ mmcbr_set_mode(dev, mode_sd); mmc_power_up(sc); mmc_idle_cards(sc); - if (mmc_send_app_op_cond(sc, 0, &ocr)) { + if (mmc_send_app_op_cond(sc, 0, &ocr) != MMC_ERR_NONE) { // Failed, try MMC mmcbr_set_mode(dev, mode_mmc); - if (mmc_send_op_cond(sc, 0, &ocr)) + if (mmc_send_op_cond(sc, 0, &ocr) != MMC_ERR_NONE) return; // Failed both, punt! XXX power down? } + printf("OCR IS %x\n", ocr); mmcbr_set_ocr(dev, mmc_select_vdd(sc, ocr)); if (mmcbr_get_ocr(dev) != 0) mmc_idle_cards(sc); @@ -341,8 +369,9 @@ * Make sure that we have a mutually agreeable voltage to at least * one card on the bus. */ - if (mmcbr_get_ocr(dev) == 0) - return; + printf("Oink %x!\n", mmcbr_get_ocr(dev)); +// if (mmcbr_get_ocr(dev) == 0) +// return; /* XXX Linux re-sends op_cond command here */ mmc_discover_cards(sc); From owner-p4-projects@FreeBSD.ORG Fri Sep 29 12:37:07 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id CCCEA16A4E2; Fri, 29 Sep 2006 12:37:06 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 7758D16A417 for ; Fri, 29 Sep 2006 12:37:06 +0000 (UTC) (envelope-from bushman@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9CBC843D46 for ; Fri, 29 Sep 2006 12:37:05 +0000 (GMT) (envelope-from bushman@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TCb5C3066372 for ; Fri, 29 Sep 2006 12:37:05 GMT (envelope-from bushman@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TCb3cq066369 for perforce@freebsd.org; Fri, 29 Sep 2006 12:37:03 GMT (envelope-from bushman@freebsd.org) Date: Fri, 29 Sep 2006 12:37:03 GMT Message-Id: <200609291237.k8TCb3cq066369@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bushman@freebsd.org using -f From: Michael Bushkov To: Perforce Change Reviews Cc: Subject: PERFORCE change 106876 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 12:37:07 -0000 http://perforce.freebsd.org/chv.cgi?CH=106876 Change 106876 by bushman@bushman_nss_ldap_cached on 2006/09/29 12:36:20 IFC Affected files ... .. //depot/projects/soc2006/nss_ldap_cached/src/Makefile.inc1#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/defaults/periodic.conf#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/defaults/rc.conf#7 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/etc.alpha/ttys#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/etc/freebsd-update.conf#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/etc/hosts.allow#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/inetd.conf#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/libalias.conf#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/etc/mtree/BSD.include.dist#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/mtree/BSD.usr.dist#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/mtree/BSD.var.dist#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/network.subr#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/pccard_ether#4 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/periodic/security/410.logincheck#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/etc/periodic/security/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/periodic/weekly/120.clean-kvmdb#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/etc/periodic/weekly/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/phones#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/Makefile#4 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/auditd#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/bthidd#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/devd#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/powerd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/ramdisk#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/ramdisk-own#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/sshd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/ypxfrd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.initdiskless#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.subr#6 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/include/Makefile#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/Makefile#8 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/Makefile#7 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/SYS.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/Symbol.map#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/_fpmath.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/arith.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/_ctx_start.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/_set_tp.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/_setjmp.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/divrem.m4#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/fabs.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/flt_rounds.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/fpgetmask.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/fpgetround.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/fpgetsticky.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/fpsetmask.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/fpsetround.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/infinity.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/makecontext.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/modf.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/rfork_thread.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/setjmp.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/signalcontext.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/gen/sigsetjmp.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/net/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/net/byte_swap_2.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/net/byte_swap_4.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/net/htonl.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/net/htons.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/net/ntohl.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/net/ntohs.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/stdlib/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/string/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/string/bcopy.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/string/bzero.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/string/ffs.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/string/memcpy.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/string/memmove.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/Ovfork.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/brk.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/cerror.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/exect.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/fork.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/pipe.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/ptrace.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/sbrk.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/setlogin.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/alpha/sys/sigreturn.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/arm/net/htonl.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/arm/net/htons.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/arm/net/ntohl.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/arm/net/ntohs.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/gen/getgrent.c#5 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/gen/pwcache.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/gen/tls.c#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/gen/vis.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/i386/gen/Makefile.inc#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/i386/gen/alloca.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/i386/sys/i386_set_watch.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/ia64/gen/_set_tp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/isc/eventlib_p.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/net/gai_strerror.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/net/gethostbyname.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/powerpc/gen/_set_tp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/clnt_bcast.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/clnt_vc.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/getnetconfig.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/getnetpath.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/rpc_clnt_create.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/rpcb_clnt.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/rpcb_prot.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/svc_simple.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/rpc/svc_vc.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdio/fclose.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdio/findfp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdio/vfprintf.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdio/vfwprintf.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdlib/alloca.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdlib/getopt_long.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdlib/malloc.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/stdlib/malloc.c#6 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/Symbol.map#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/aio_error.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/chflags.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/clock_gettime.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/connect.2#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/getsockopt.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/gettimeofday.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/kldnext.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/kqueue.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/listen.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/mmap.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/open.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/recv.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/send.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/sigqueue.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/timer_create.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/timer_delete.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/timer_settime.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/libc/sys/utimes.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/lib/nss_compat/compat_group.c#5 edit .. //depot/projects/soc2006/nss_ldap_cached/src/lib/nss_compat/nss_compat.c#5 edit .. //depot/projects/soc2006/nss_ldap_cached/src/lib/nss_files/files_group.c#6 edit .. //depot/projects/soc2006/nss_ldap_cached/src/share/mk/bsd.cpu.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/share/mk/bsd.endian.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/share/mk/bsd.lib.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/share/mk/bsd.own.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/share/mk/bsd.port.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/share/mk/bsd.prog.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/IPXrouted/main.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/Makefile#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/auditreduce/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/authpf/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/bthid_config.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/bthidd.8#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/bthidd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/bthidd.conf.sample#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/bthidd.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/client.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/hid.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/kbd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/kbd.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/lexer.l#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/parser.y#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/server.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/bthidd/session.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/hccontrol/hccontrol.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/hccontrol/link_control.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/hccontrol/util.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/hcsecd/hcsecd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/rfcomm_pppd/rfcomm_pppd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/bluetooth/sdpd/server.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/cron/crontab/crontab.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/cron/lib/entry.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/crunch/crunchide/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/edquota/edquota.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/eeprom/eeprom.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/eeprom/ofw_options.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/freebsd-update/Makefile#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/freebsd-update/freebsd-update.8#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/freebsd-update/freebsd-update.sh#1 branch .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/inetd/inetd.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/inetd/inetd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/inetd/inetd.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/ipfwpcap/ipfwpcap.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/kbdcontrol/kbdcontrol.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/lmcconfig/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/ndiscvt/ndiscvt.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/ngctl/msg.c#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/pkg_install/add/main.c#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/pnpinfo/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/portsnap/portsnap/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/ppp/command.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/ppp/lcp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/ppp/ppp.8.m4#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/ppp/server.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/pw/pw.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/rip6query/rip6query.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/rpc.lockd/lockd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/rpc.statd/procs.c#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/rpc.statd/statd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/sendmail/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/sysinstall/config.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/sysinstall/devices.c#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/sysinstall/install.c#3 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpdump/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpslice/Makefile#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpslice/gwtm2secs.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpslice/search.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpslice/tcpslice.1#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpslice/tcpslice.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpslice/tcpslice.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/tcpdump/tcpslice/util.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/traceroute/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/vidcontrol/vidcontrol.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/watchdogd/watchdog.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/watchdogd/watchdogd.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached/src/usr.sbin/wpa/hostapd/hostapd.conf.5#2 integrate Differences ... ==== //depot/projects/soc2006/nss_ldap_cached/src/Makefile.inc1#2 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.552 2006/08/09 11:03:06 netchild Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.559 2006/09/08 10:09:02 ru Exp $ # # Make command line options: # -DNO_CLEANDIR run ${MAKE} clean, instead of ${MAKE} cleandir @@ -11,7 +11,7 @@ # -DNO_PORTSUPDATE do not update ports in ${MAKE} update # -DNO_DOCUPDATE do not update doc in ${MAKE} update # LOCAL_DIRS="list of dirs" to add additional dirs to the SUBDIR list -# TARGET_ARCH="arch" to crossbuild world to a different arch +# TARGET="machine" to crossbuild world for a different machine type # # The intended user-driven targets are: @@ -95,14 +95,36 @@ OSRELDATE= 0 .endif .endif + +# Guess machine architecture from machine type, and vice versa. +.if !defined(TARGET_ARCH) && defined(TARGET) +TARGET_ARCH= ${TARGET:S/pc98/i386/} +.elif !defined(TARGET) && defined(TARGET_ARCH) && \ + ${TARGET_ARCH} != ${MACHINE_ARCH} +TARGET= ${TARGET_ARCH} +.endif +# Otherwise, default to current machine type and architecture. +TARGET?= ${MACHINE} TARGET_ARCH?= ${MACHINE_ARCH} -.if ${TARGET_ARCH} == ${MACHINE_ARCH} -TARGET?= ${MACHINE} + +KNOWN_ARCHES?= amd64 arm i386 i386/pc98 ia64 powerpc sparc64 +.if ${TARGET} == ${TARGET_ARCH} +_t= ${TARGET} +.else +_t= ${TARGET_ARCH}/${TARGET} +.endif +.for _t in ${_t} +.if empty(KNOWN_ARCHES:M${_t}) +.error Unknown target ${TARGET_ARCH}:${TARGET}. +.endif +.endfor + +.if ${TARGET} == ${MACHINE} TARGET_CPUTYPE?=${CPUTYPE} .else -TARGET?= ${TARGET_ARCH} TARGET_CPUTYPE?= .endif + .if !empty(TARGET_CPUTYPE) _TARGET_CPUTYPE=${TARGET_CPUTYPE} .else @@ -185,11 +207,13 @@ # build-tools stage TMAKE= MAKEOBJDIRPREFIX=${OBJTREE} \ ${BMAKEENV} ${MAKE} -f Makefile.inc1 \ + TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ DESTDIR= \ BOOTSTRAPPING=${OSRELDATE} -DNO_LINT -DNO_CPU_CFLAGS -DNO_WARNS # cross-tools stage XMAKE= TOOLS_PREFIX=${WORLDTMP} ${BMAKE} \ + TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ -DWITHOUT_FORTRAN -DWITHOUT_GDB # world stage @@ -465,10 +489,20 @@ WMAKE_TGTS+= build32 .endif -buildworld: ${WMAKE_TGTS} -.ORDER: ${WMAKE_TGTS} +buildworld: buildworld_prologue ${WMAKE_TGTS} buildworld_epilogue +.ORDER: buildworld_prologue ${WMAKE_TGTS} buildworld_epilogue +buildworld_prologue: + @echo "--------------------------------------------------------------" + @echo ">>> World build started on `LC_ALL=C date`" + @echo "--------------------------------------------------------------" +buildworld_epilogue: + @echo + @echo "--------------------------------------------------------------" + @echo ">>> World build completed on `LC_ALL=C date`" + @echo "--------------------------------------------------------------" + # # We need to have this as a target because the indirection between Makefile # and Makefile.inc1 causes the correct PATH to be used, rather than a @@ -926,9 +960,6 @@ .if ${MK_RESCUE} != "no" || defined(RELEASEDIR) _crunchide= usr.sbin/crunch/crunchide .endif -.if ${TARGET_ARCH} == "alpha" -_elf2exe= usr.sbin/elf2exe -.endif .if ${TARGET_ARCH} == "i386" && defined(RELEASEDIR) _kgzip= usr.sbin/kgzip .endif @@ -941,7 +972,6 @@ usr.bin/xlint/lint1 usr.bin/xlint/lint2 usr.bin/xlint/xlint \ ${_btxld} \ ${_crunchide} \ - ${_elf2exe} \ ${_kgzip} ${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all,install)"; \ cd ${.CURDIR}/${_tool}; \ @@ -1036,8 +1066,9 @@ .for _lib in ${_startup_libs} ${_prebuild_libs:Nlib/libpam} ${_generic_libs} ${_lib}__L: .PHONY .if exists(${.CURDIR}/${_lib}) - ${_+_}@${ECHODIR} "===> ${_lib} (depend,all,install)"; \ + ${_+_}@${ECHODIR} "===> ${_lib} (obj,depend,all,install)"; \ cd ${.CURDIR}/${_lib}; \ + ${MAKE} DIRPRFX=${_lib}/ obj; \ ${MAKE} DIRPRFX=${_lib}/ depend; \ ${MAKE} DIRPRFX=${_lib}/ all; \ ${MAKE} DIRPRFX=${_lib}/ install @@ -1048,8 +1079,9 @@ # static PAM library, and dynamic PAM library before dynamic PAM # modules. lib/libpam__L: .PHONY - ${_+_}@${ECHODIR} "===> lib/libpam (depend,all,install)"; \ + ${_+_}@${ECHODIR} "===> lib/libpam (obj,depend,all,install)"; \ cd ${.CURDIR}/lib/libpam; \ + ${MAKE} DIRPRFX=lib/libpam/ obj; \ ${MAKE} DIRPRFX=lib/libpam/ depend; \ ${MAKE} DIRPRFX=lib/libpam/ -D_NO_LIBPAM_SO_YET all; \ ${MAKE} DIRPRFX=lib/libpam/ -D_NO_LIBPAM_SO_YET install ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/Makefile#2 (text+ko) ==== @@ -1,5 +1,5 @@ # from: @(#)Makefile 5.11 (Berkeley) 5/21/91 -# $FreeBSD: src/etc/Makefile,v 1.356 2006/05/03 15:14:46 ume Exp $ +# $FreeBSD: src/etc/Makefile,v 1.358 2006/09/26 23:26:48 piso Exp $ .include @@ -9,9 +9,10 @@ BIN1= amd.map apmd.conf auth.conf \ crontab csh.cshrc csh.login csh.logout devd.conf devfs.conf \ - dhclient.conf disktab fbtab ftpusers gettytab group \ + dhclient.conf disktab fbtab freebsd-update.conf \ + ftpusers gettytab group \ hosts hosts.allow hosts.equiv hosts.lpd \ - inetd.conf login.access login.conf mac.conf motd \ + inetd.conf libalias.conf login.access login.conf mac.conf motd \ netconfig network.subr networks newsyslog.conf nsswitch.conf \ portsnap.conf pf.conf pf.os phones profile protocols \ rc rc.bsdextended rc.firewall rc.firewall6 rc.initdiskless \ ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/defaults/periodic.conf#2 (text+ko) ==== @@ -13,7 +13,7 @@ # For a more detailed explanation of all the periodic.conf variables, please # refer to the periodic.conf(5) manual page. # -# $FreeBSD: src/etc/defaults/periodic.conf,v 1.38 2006/05/12 19:17:33 mlaier Exp $ +# $FreeBSD: src/etc/defaults/periodic.conf,v 1.41 2006/08/29 08:49:57 ru Exp $ # # What files override these defaults ? @@ -159,6 +159,9 @@ # 400.passwdless daily_status_security_passwdless_enable="YES" +# 410.logincheck +daily_status_security_logincheck_enable="YES" + # 500.ipfwdenied daily_status_security_ipfwdenied_enable="YES" @@ -196,11 +199,6 @@ weekly_show_info="YES" # scripts returning 1 weekly_show_badconfig="NO" # scripts returning 2 -# 120.clean-kvmdb -weekly_clean_kvmdb_enable="YES" # Clean kvmdb weekly -weekly_clean_kvmdb_days=7 # If not accessed for -weekly_clean_kvmdb_verbose="YES" # Mention files deleted - # 310.locate weekly_locate_enable="YES" # Update locate weekly @@ -217,7 +215,7 @@ # 400.status-pkg weekly_status_pkg_enable="NO" # Find out-of-date pkgs pkg_version=pkg_version # Use this program -pkg_version_index=/usr/ports/INDEX-6 # Use this index file +pkg_version_index=/usr/ports/INDEX-7 # Use this index file # 999.local weekly_local="/etc/weekly.local" # Local scripts ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/defaults/rc.conf#7 (text+ko) ==== @@ -15,7 +15,7 @@ # For a more detailed explanation of all the rc.conf variables, please # refer to the rc.conf(5) manual page. # -# $FreeBSD: src/etc/defaults/rc.conf,v 1.294 2006/08/17 20:13:24 brian Exp $ +# $FreeBSD: src/etc/defaults/rc.conf,v 1.296 2006/09/20 19:48:31 brooks Exp $ ############################################################## ### Important initial Boot-time options #################### @@ -40,7 +40,6 @@ kldxref_module_path="" # Override kern.module_path. A ';'-delimited list. powerd_enable="NO" # Run powerd to lower our power usage. powerd_flags="" # Flags to powerd (if enabled). -removable_route_flush="NO" # Flush routes when removing an interface tmpmfs="AUTO" # Set to YES to always create an mfs /tmp, NO to never tmpsize="20m" # Size of mfs /tmp if created tmpmfs_flags="-S -M" # Extra mdmfs options for the mfs /tmp @@ -336,6 +335,10 @@ sdpd_groupname="nobody" # set spdp(8) user/group to run as after sdpd_username="nobody" # it initializes +bthidd_enable="NO" # Enable bthidd(8) (or NO) +bthidd_config="/etc/bluetooth/bthidd.conf" # bthidd(8) configuration file +bthidd_hids="/var/db/bthidd.hids" # bthidd(8) known HID devices file + ### Miscellaneous network options: ### icmp_bmcastecho="NO" # respond to broadcast ping packets ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/hosts.allow#3 (text+ko) ==== @@ -1,6 +1,6 @@ # # hosts.allow access control file for "tcp wrapped" applications. -# $FreeBSD: src/etc/hosts.allow,v 1.22 2006/06/01 14:14:58 csjp Exp $ +# $FreeBSD: src/etc/hosts.allow,v 1.23 2006/08/29 09:20:48 ru Exp $ # # NOTE: The hosts.deny file is deprecated. # Place both 'allow' and 'deny' rules in the hosts.allow file. @@ -39,43 +39,43 @@ ALL : localhost 127.0.0.1 : allow # Comment out next line if you build libwrap without IPv6 support. ALL : [::1] : allow -ALL : my.machine.example.com 192.0.2.35 : allow +#ALL : my.machine.example.com 192.0.2.35 : allow # To use IPv6 addresses you must enclose them in []'s -ALL : [fe80::%fxp0]/10 : allow -ALL : [fe80::]/10 : deny -ALL : [2001:db8:2:1:2:3:4:3fe1] : deny -ALL : [2001:db8:2:1::]/64 : allow +#ALL : [fe80::%fxp0]/10 : allow +#ALL : [fe80::]/10 : deny +#ALL : [2001:db8:2:1:2:3:4:3fe1] : deny +#ALL : [2001:db8:2:1::]/64 : allow # Sendmail can help protect you against spammers and relay-rapers sendmail : localhost : allow -sendmail : .nice.guy.example.com : allow -sendmail : .evil.cracker.example.com : deny +#sendmail : .nice.guy.example.com : allow +#sendmail : .evil.cracker.example.com : deny sendmail : ALL : allow # Exim is an alternative to sendmail, available in the ports tree exim : localhost : allow -exim : .nice.guy.example.com : allow -exim : .evil.cracker.example.com : deny +#exim : .nice.guy.example.com : allow +#exim : .evil.cracker.example.com : deny exim : ALL : allow # Rpcbind is used for all RPC services; protect your NFS! # (IP addresses rather than hostnames *MUST* be used here) -rpcbind : 192.0.2.32/255.255.255.224 : allow -rpcbind : 192.0.2.96/255.255.255.224 : allow +#rpcbind : 192.0.2.32/255.255.255.224 : allow +#rpcbind : 192.0.2.96/255.255.255.224 : allow rpcbind : ALL : deny # NIS master server. Only local nets should have access # (Since this is an RPC service, rpcbind needs to be considered) ypserv : localhost : allow -ypserv : .unsafe.my.net.example.com : deny -ypserv : .my.net.example.com : allow +#ypserv : .unsafe.my.net.example.com : deny +#ypserv : .my.net.example.com : allow ypserv : ALL : deny # Provide a small amount of protection for ftpd ftpd : localhost : allow -ftpd : .nice.guy.example.com : allow -ftpd : .evil.cracker.example.com : deny +#ftpd : .nice.guy.example.com : allow +#ftpd : .evil.cracker.example.com : deny ftpd : ALL : allow # You need to be clever with finger; do _not_ backfinger!! You can easily ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/inetd.conf#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/inetd.conf,v 1.71 2006/02/05 19:23:05 ceri Exp $ +# $FreeBSD: src/etc/inetd.conf,v 1.72 2006/08/31 17:15:10 obrien Exp $ # # Internet server configuration database # @@ -8,6 +8,8 @@ # #ftp stream tcp nowait root /usr/libexec/ftpd ftpd -l #ftp stream tcp6 nowait root /usr/libexec/ftpd ftpd -l +#ftp stream tcp nowait root /usr/libexec/lukemftpd ftpd -l -r +#ftp stream tcp6 nowait root /usr/libexec/lukemftpd ftpd -l -r #ssh stream tcp nowait root /usr/sbin/sshd sshd -i -4 #ssh stream tcp6 nowait root /usr/sbin/sshd sshd -i -6 #telnet stream tcp nowait root /usr/libexec/telnetd telnetd ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/mtree/BSD.include.dist#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/mtree/BSD.include.dist,v 1.107 2006/08/01 22:19:00 sobomax Exp $ +# $FreeBSD: src/etc/mtree/BSD.include.dist,v 1.108 2006/09/07 18:24:24 emax Exp $ # # Please see the file src/etc/mtree/README before making changes to this file. # @@ -66,6 +66,8 @@ .. utopia .. + vkbd + .. wi .. .. ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/mtree/BSD.usr.dist#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/mtree/BSD.usr.dist,v 1.319 2006/08/03 05:44:51 jb Exp $ +# $FreeBSD: src/etc/mtree/BSD.usr.dist,v 1.320 2006/09/02 20:58:37 marcel Exp $ # # Please see the file src/etc/mtree/README before making changes to this file. # @@ -661,6 +661,8 @@ .. i386 .. + powerpc + .. sparc64 .. .. @@ -694,6 +696,8 @@ .. i386 .. + powerpc + .. sparc64 .. .. @@ -766,6 +770,8 @@ .. i386 .. + powerpc + .. sparc64 .. .. ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/mtree/BSD.var.dist#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/mtree/BSD.var.dist,v 1.74 2006/02/05 18:22:56 rwatson Exp $ +# $FreeBSD: src/etc/mtree/BSD.var.dist,v 1.75 2006/08/31 09:51:33 cperciva Exp $ # # Please see the file src/etc/mtree/README before making changes to this file. # @@ -32,6 +32,8 @@ db entropy uname=operator gname=operator mode=0700 .. + freebsd-update + .. ipf mode=0700 .. pkg ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/network.subr#3 (text+ko) ==== @@ -22,7 +22,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/network.subr,v 1.172 2006/08/17 03:03:38 brooks Exp $ +# $FreeBSD: src/etc/network.subr,v 1.173 2006/09/21 01:44:52 brooks Exp $ # # @@ -237,6 +237,30 @@ return 1 } +# ipv6if if +# Returns 0 if the interface should be configured for IPv6 and +# 1 otherwise. +ipv6if() +{ + if ! checkyesno ipv6_enable; then + return 1 + fi + case "${ipv6_network_interfaces}" in + [Aa][Uu][Tt][Oo]) + return 0 + ;; + ''|[Nn][Oo][Nn][Ee]) + return 1 + ;; + esac + for v6if in ${ipv6_network_interfaces}; do + if [ "${v6if}" = "${1}" ]; then + return 0 + fi + done + return 1 +} + # ifexists if # Returns 0 if the interface exists and 1 otherwise. ifexists() ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/pccard_ether#4 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh - # -# $FreeBSD: src/etc/pccard_ether,v 1.50 2006/08/18 13:19:45 brooks Exp $ +# $FreeBSD: src/etc/pccard_ether,v 1.53 2006/09/21 01:44:52 brooks Exp $ # # pccard_ether interfacename [start|stop|restart] # @@ -69,11 +69,13 @@ { ifexists $ifn || exit 1 - if [ -z "$rc_force" -a -x /usr/bin/grep ]; then - if ifconfig $ifn | grep -s '[<,]UP[,>]' > /dev/null 2>&1; then - # Interface is already up, so ignore it. - exit 0 - fi + if [ -z "$rc_force" ]; then + for uif in `ifconfig -ul`; do + if [ "${uif}" = "${ifn}" ]; then + # Interface is already up, so ignore it. + exit 0 + fi + done fi /etc/rc.d/netif start $ifn @@ -87,7 +89,11 @@ fi # IPv6 setup - if checkyesno ipv6_enable; then + if ipv6if $ifn; then + # XXX: network6_interface_setup assumes you're calling + # it with ALL the IPv6 interfaces at once and thus isn't + # really appropraite for this job, but it's the best we've + # got for now. network6_interface_setup $ifn fi } @@ -104,11 +110,6 @@ # clean ARP table ifexists $ifn && arp -d -i $ifn -a - - # Clean the routing table - if checkyesno removable_route_flush; then - route -n flush -inet > /dev/null - fi } pccard_ether_restart() ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/periodic/security/Makefile#2 (text+ko) ==== @@ -1,9 +1,10 @@ -# $FreeBSD: src/etc/periodic/security/Makefile,v 1.5 2006/05/12 19:17:34 mlaier Exp $ +# $FreeBSD: src/etc/periodic/security/Makefile,v 1.6 2006/08/25 07:34:36 trhodes Exp $ FILES= 100.chksetuid \ 200.chkmounts \ 300.chkuid0 \ 400.passwdless \ + 410.logincheck \ 500.ipfwdenied \ 510.ipfdenied \ 520.pfdenied \ ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/periodic/weekly/Makefile#2 (text+ko) ==== @@ -1,7 +1,6 @@ -# $FreeBSD: src/etc/periodic/weekly/Makefile,v 1.8 2002/07/18 12:33:01 ru Exp $ +# $FreeBSD: src/etc/periodic/weekly/Makefile,v 1.9 2006/08/29 08:49:57 ru Exp $ -FILES= 120.clean-kvmdb \ - 310.locate \ +FILES= 310.locate \ 320.whatis \ 330.catman \ 340.noid \ ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/phones#2 (text+ko) ==== @@ -1,11 +1,8 @@ -# $FreeBSD: src/etc/phones,v 1.8 1999/08/27 23:23:43 peter Exp $ +# $FreeBSD: src/etc/phones,v 1.9 2006/08/31 21:13:12 ru Exp $ # From: @(#)phones 5.2 (Berkeley) 6/30/90 # # phones -- remote host phone number data base # see tip(1), phones(5) -# -system1 9=3155557750 -system2 9145551241 -netcom 1(408)555-9760 -netcom 1(415)555-9940 -omen 1(503)555-3746 +# examples: +#system1 9=2225551212 +#system2 9995551212 ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/Makefile#4 (text+ko) ==== @@ -1,12 +1,12 @@ # $NetBSD: Makefile,v 1.16 2001/01/14 15:37:22 minoura Exp $ -# $FreeBSD: src/etc/rc.d/Makefile,v 1.74 2006/08/04 18:37:03 des Exp $ +# $FreeBSD: src/etc/rc.d/Makefile,v 1.76 2006/09/07 22:25:08 emax Exp $ .include FILES= DAEMON LOGIN NETWORKING SERVERS \ abi accounting addswap adjkerntz amd \ apm apmd archdep atm1 atm2 atm3 auditd \ - bgfsck bluetooth bootparams bridge bsnmpd \ + bgfsck bluetooth bootparams bridge bsnmpd bthidd \ ccd cleanvar cleartmp cron \ devd devfs dhclient \ dmesg dumpon \ @@ -30,7 +30,7 @@ pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ quota \ - ramdisk ramdisk-own random rarpd resolv root \ + random rarpd resolv root \ route6d routed routing rpcbind rtadvd rwho \ savecore sdpd securelevel sendmail \ serial sppp swap1 \ ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/auditd#3 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/auditd,v 1.2 2006/06/06 17:22:55 trhodes Exp $ +# $FreeBSD: src/etc/rc.d/auditd,v 1.3 2006/09/24 17:31:04 rwatson Exp $ # # Start up for the Audit daemon. # @@ -25,6 +25,7 @@ { /usr/sbin/audit -t + sleep 1 } load_rc_config $name ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/devd#3 (text+ko) ==== @@ -1,10 +1,10 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/devd,v 1.9 2006/06/01 00:41:07 thompsa Exp $ +# $FreeBSD: src/etc/rc.d/devd,v 1.10 2006/09/21 14:29:32 brooks Exp $ # # PROVIDE: devd -# REQUIRE: netif +# REQUIRE: netif network_ipv6 # BEFORE: NETWORKING mountcritremote # KEYWORD: nojail ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/powerd#2 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/powerd,v 1.3 2005/10/28 16:55:38 yar Exp $ +# $FreeBSD: src/etc/rc.d/powerd,v 1.4 2006/08/27 11:04:39 cperciva Exp $ # # PROVIDE: powerd @@ -13,6 +13,13 @@ name="powerd" rcvar=`set_rcvar` command="/usr/sbin/${name}" +stop_postcmd=powerd_poststop + +powerd_poststop() +{ + sysctl dev.cpu.0.freq=`sysctl -n dev.cpu.0.freq_levels | + sed -e 's:/.*::'` > /dev/null +} load_rc_config $name run_rc_command "$1" ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/sshd#2 (text+ko) ==== @@ -1,7 +1,7 @@ #!/bin/sh # # $NetBSD: sshd,v 1.18 2002/04/29 08:23:34 lukem Exp $ -# $FreeBSD: src/etc/rc.d/sshd,v 1.11 2006/04/11 09:08:15 flz Exp $ +# $FreeBSD: src/etc/rc.d/sshd,v 1.12 2006/08/22 11:17:28 flz Exp $ # # PROVIDE: sshd @@ -19,8 +19,6 @@ timeout=300 -load_rc_config $name - user_reseed() { ( @@ -49,46 +47,47 @@ umask 022 # Can't do anything if ssh is not installed - [ -x ${prefix}/bin/ssh-keygen ] || { - warn "${prefix}/bin/ssh-keygen does not exist." + [ -x /usr/bin/ssh-keygen ] || { + warn "/usr/bin/ssh-keygen does not exist." return 1 } - if [ -f ${etcdir}/ssh/ssh_host_key ]; then + if [ -f /etc/ssh/ssh_host_key ]; then echo "You already have an RSA host key" \ - "in ${etcdir}/ssh/ssh_host_key" + "in /etc/ssh/ssh_host_key" echo "Skipping protocol version 1 RSA Key Generation" else - ${prefix}/bin/ssh-keygen -t rsa1 -b 1024 \ - -f ${etcdir}/ssh/ssh_host_key -N '' + /usr/bin/ssh-keygen -t rsa1 -b 1024 \ + -f /etc/ssh/ssh_host_key -N '' fi - if [ -f ${etcdir}/ssh/ssh_host_dsa_key ]; then + if [ -f /etc/ssh/ssh_host_dsa_key ]; then echo "You already have a DSA host key" \ - "in ${etcdir}/ssh/ssh_host_dsa_key" + "in /etc/ssh/ssh_host_dsa_key" echo "Skipping protocol version 2 DSA Key Generation" else - ${prefix}/bin/ssh-keygen -t dsa -f ${etcdir}/ssh/ssh_host_dsa_key -N '' + /usr/bin/ssh-keygen -t dsa -f /etc/ssh/ssh_host_dsa_key -N '' fi - if [ -f ${etcdir}/ssh/ssh_host_rsa_key ]; then + if [ -f /etc/ssh/ssh_host_rsa_key ]; then echo "You already have a RSA host key" \ - "in ${etcdir}/ssh/ssh_host_rsa_key" + "in /etc/ssh/ssh_host_rsa_key" echo "Skipping protocol version 2 RSA Key Generation" else - ${prefix}/bin/ssh-keygen -t rsa -f ${etcdir}/ssh/ssh_host_rsa_key -N '' + /usr/bin/ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key -N '' fi ) } sshd_precmd() { - if [ ! -f ${etcdir}/ssh/ssh_host_key -o \ - ! -f ${etcdir}/ssh/ssh_host_dsa_key -o \ - ! -f ${etcdir}/ssh/ssh_host_rsa_key ]; then + if [ ! -f /etc/ssh/ssh_host_key -o \ + ! -f /etc/ssh/ssh_host_dsa_key -o \ + ! -f /etc/ssh/ssh_host_rsa_key ]; then user_reseed run_rc_command keygen fi } +load_rc_config $name run_rc_command "$1" ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.d/ypxfrd#2 (text+ko) ==== @@ -1,10 +1,10 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ypxfrd,v 1.6 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/ypxfrd,v 1.7 2006/08/22 14:58:23 flz Exp $ # # PROVIDE: ypxfrd -# REQUIRE: rpcbind +# REQUIRE: rpcbind ypserv . /etc/rc.subr ==== //depot/projects/soc2006/nss_ldap_cached/src/etc/rc.initdiskless#2 (text+ko) ==== @@ -24,7 +24,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.initdiskless,v 1.49 2006/01/11 21:59:30 brooks Exp $ +# $FreeBSD: src/etc/rc.initdiskless,v 1.51 2006/09/01 16:33:15 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 @@ -76,6 +76,9 @@ # If the file contains a pathname starting with "/", then # the root path is prepended to it; this allows relocation of # the root filesystem without changing configuration files. +# Because mount_nfs understands ".." in paths, it is +# possible to mount from locations above the NFS root with +# paths such as "/../../etc". # # /conf/T/M/md_size # The contents of the file specifies the size of the memory @@ -97,21 +100,27 @@ # The list of paths contained in the file are rm -rf'd # relative to /SUBDIR. # +# /conf/diskless_remount +# Similar to /conf/T/M/diskless_remount above, but allows +# all of /conf to be remounted. This can be used to allow +# multiple roots to share the same /conf. +# +# # You will almost universally want to create the following files under /conf # -# File Content -# ---------------------------- ------------------------------------------ -# /conf/base/etc/md_size size of /etc filesystem -# /conf/base/diskless_remount "/etc" -# /conf/default/etc/rc.conf generic diskless config parameters -# /conf/default/etc/fstab generic diskless fstab e.g. like this +# File Content +# ---------------------------- ---------------------------------- +# /conf/base/etc/md_size size of /etc filesystem +# /conf/base/etc/diskless_remount "/etc" +# /conf/default/etc/rc.conf generic diskless config parameters +# /conf/default/etc/fstab generic diskless fstab e.g. like this # -# foo:/root_part / nfs ro 0 0 -# foo:/usr_part /usr nfs ro 0 0 -# foo:/home_part /home nfs rw 0 0 -# md /tmp mfs -s=30m,rw 0 0 -# md /var mfs -s=30m,rw 0 0 >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Fri Sep 29 12:52:31 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7BA9F16A417; Fri, 29 Sep 2006 12:52:31 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 3250116A403 for ; Fri, 29 Sep 2006 12:52:31 +0000 (UTC) (envelope-from bushman@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id BEF4843D45 for ; Fri, 29 Sep 2006 12:52:30 +0000 (GMT) (envelope-from bushman@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TCqUOo075024 for ; Fri, 29 Sep 2006 12:52:30 GMT (envelope-from bushman@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TCqPrP075020 for perforce@freebsd.org; Fri, 29 Sep 2006 12:52:25 GMT (envelope-from bushman@freebsd.org) Date: Fri, 29 Sep 2006 12:52:25 GMT Message-Id: <200609291252.k8TCqPrP075020@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to bushman@freebsd.org using -f From: Michael Bushkov To: Perforce Change Reviews Cc: Subject: PERFORCE change 106878 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 12:52:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=106878 Change 106878 by bushman@bushman_nss_ldap_cached on 2006/09/29 12:51:37 IFC Affected files ... .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/Makefile.inc1#3 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/defaults/periodic.conf#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/defaults/rc.conf#5 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/etc.alpha/ttys#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/freebsd-update.conf#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/hosts.allow#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/inetd.conf#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/libalias.conf#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/mtree/BSD.include.dist#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/mtree/BSD.usr.dist#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/mtree/BSD.var.dist#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/network.subr#3 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/pccard_ether#4 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/periodic/security/410.logincheck#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/periodic/security/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/periodic/weekly/120.clean-kvmdb#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/periodic/weekly/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/phones#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/auditd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/bthidd#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/devd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/powerd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/ramdisk#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/ramdisk-own#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/sshd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/ypxfrd#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.initdiskless#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.subr#4 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/include/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/Makefile#4 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/SYS.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/Symbol.map#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/_fpmath.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/arith.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/_ctx_start.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/_set_tp.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/_setjmp.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/divrem.m4#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/fabs.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/flt_rounds.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/fpgetmask.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/fpgetround.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/fpgetsticky.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/fpsetmask.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/fpsetround.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/infinity.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/makecontext.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/modf.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/rfork_thread.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/setjmp.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/signalcontext.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/gen/sigsetjmp.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/net/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/net/byte_swap_2.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/net/byte_swap_4.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/net/htonl.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/net/htons.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/net/ntohl.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/net/ntohs.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/stdlib/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/string/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/string/bcopy.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/string/bzero.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/string/ffs.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/string/memcpy.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/string/memmove.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/Makefile.inc#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/Ovfork.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/brk.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/cerror.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/exect.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/fork.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/pipe.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/ptrace.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/sbrk.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/setlogin.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/alpha/sys/sigreturn.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/arm/net/htonl.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/arm/net/htons.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/arm/net/ntohl.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/arm/net/ntohs.S#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/gen/getgrent.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/gen/pwcache.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/gen/tls.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/gen/vis.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/i386/gen/Makefile.inc#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/i386/gen/alloca.S#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/i386/sys/i386_set_watch.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/ia64/gen/_set_tp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/isc/eventlib_p.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/net/gai_strerror.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/net/gethostbyname.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/powerpc/gen/_set_tp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/clnt_bcast.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/clnt_vc.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/getnetconfig.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/getnetpath.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/rpc_clnt_create.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/rpcb_clnt.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/rpcb_prot.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/svc_simple.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/rpc/svc_vc.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdio/fclose.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdio/findfp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdio/vfprintf.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdio/vfwprintf.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdlib/alloca.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdlib/getopt_long.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdlib/malloc.3#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/stdlib/malloc.c#3 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/Symbol.map#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/aio_error.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/chflags.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/clock_gettime.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/connect.2#3 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/getsockopt.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/gettimeofday.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/kldnext.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/kqueue.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/listen.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/mmap.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/open.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/recv.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/send.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/sigqueue.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/timer_create.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/timer_delete.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/timer_settime.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/libc/sys/utimes.2#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/nss_compat/compat_group.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/nss_compat/nss_compat.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/lib/nss_files/files_group.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/share/mk/bsd.cpu.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/share/mk/bsd.endian.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/share/mk/bsd.lib.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/share/mk/bsd.own.mk#3 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/share/mk/bsd.port.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/share/mk/bsd.prog.mk#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/IPXrouted/main.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/auditreduce/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/authpf/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/bthid_config.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/bthidd.8#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/bthidd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/bthidd.conf.sample#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/bthidd.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/client.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/hid.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/kbd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/kbd.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/lexer.l#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/parser.y#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/server.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/bthidd/session.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/hccontrol/hccontrol.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/hccontrol/link_control.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/hccontrol/util.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/hcsecd/hcsecd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/rfcomm_pppd/rfcomm_pppd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/bluetooth/sdpd/server.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/cron/crontab/crontab.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/cron/lib/entry.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/crunch/crunchide/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/edquota/edquota.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/eeprom/eeprom.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/eeprom/ofw_options.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/freebsd-update/Makefile#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/freebsd-update/freebsd-update.8#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/freebsd-update/freebsd-update.sh#1 branch .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/inetd/inetd.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/inetd/inetd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/inetd/inetd.h#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/ipfwpcap/ipfwpcap.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/kbdcontrol/kbdcontrol.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/lmcconfig/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/ndiscvt/ndiscvt.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/ngctl/msg.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/pkg_install/add/main.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/pnpinfo/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/portsnap/portsnap/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/ppp/command.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/ppp/lcp.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/ppp/ppp.8.m4#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/ppp/server.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/pw/pw.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/rip6query/rip6query.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/rpc.lockd/lockd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/rpc.statd/procs.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/rpc.statd/statd.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/sendmail/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/sysinstall/config.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/sysinstall/devices.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/sysinstall/install.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpdump/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpslice/Makefile#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpslice/gwtm2secs.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpslice/search.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpslice/tcpslice.1#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpslice/tcpslice.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpslice/tcpslice.h#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/tcpdump/tcpslice/util.c#2 delete .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/traceroute/Makefile#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/vidcontrol/vidcontrol.c#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/watchdogd/watchdog.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/watchdogd/watchdogd.8#2 integrate .. //depot/projects/soc2006/nss_ldap_cached_openldap/src/usr.sbin/wpa/hostapd/hostapd.conf.5#2 integrate Differences ... ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/Makefile.inc1#3 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.552 2006/08/09 11:03:06 netchild Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.559 2006/09/08 10:09:02 ru Exp $ # # Make command line options: # -DNO_CLEANDIR run ${MAKE} clean, instead of ${MAKE} cleandir @@ -11,7 +11,7 @@ # -DNO_PORTSUPDATE do not update ports in ${MAKE} update # -DNO_DOCUPDATE do not update doc in ${MAKE} update # LOCAL_DIRS="list of dirs" to add additional dirs to the SUBDIR list -# TARGET_ARCH="arch" to crossbuild world to a different arch +# TARGET="machine" to crossbuild world for a different machine type # # The intended user-driven targets are: @@ -95,14 +95,36 @@ OSRELDATE= 0 .endif .endif + +# Guess machine architecture from machine type, and vice versa. +.if !defined(TARGET_ARCH) && defined(TARGET) +TARGET_ARCH= ${TARGET:S/pc98/i386/} +.elif !defined(TARGET) && defined(TARGET_ARCH) && \ + ${TARGET_ARCH} != ${MACHINE_ARCH} +TARGET= ${TARGET_ARCH} +.endif +# Otherwise, default to current machine type and architecture. +TARGET?= ${MACHINE} TARGET_ARCH?= ${MACHINE_ARCH} -.if ${TARGET_ARCH} == ${MACHINE_ARCH} -TARGET?= ${MACHINE} + +KNOWN_ARCHES?= amd64 arm i386 i386/pc98 ia64 powerpc sparc64 +.if ${TARGET} == ${TARGET_ARCH} +_t= ${TARGET} +.else +_t= ${TARGET_ARCH}/${TARGET} +.endif +.for _t in ${_t} +.if empty(KNOWN_ARCHES:M${_t}) +.error Unknown target ${TARGET_ARCH}:${TARGET}. +.endif +.endfor + +.if ${TARGET} == ${MACHINE} TARGET_CPUTYPE?=${CPUTYPE} .else -TARGET?= ${TARGET_ARCH} TARGET_CPUTYPE?= .endif + .if !empty(TARGET_CPUTYPE) _TARGET_CPUTYPE=${TARGET_CPUTYPE} .else @@ -185,11 +207,13 @@ # build-tools stage TMAKE= MAKEOBJDIRPREFIX=${OBJTREE} \ ${BMAKEENV} ${MAKE} -f Makefile.inc1 \ + TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ DESTDIR= \ BOOTSTRAPPING=${OSRELDATE} -DNO_LINT -DNO_CPU_CFLAGS -DNO_WARNS # cross-tools stage XMAKE= TOOLS_PREFIX=${WORLDTMP} ${BMAKE} \ + TARGET=${TARGET} TARGET_ARCH=${TARGET_ARCH} \ -DWITHOUT_FORTRAN -DWITHOUT_GDB # world stage @@ -465,10 +489,20 @@ WMAKE_TGTS+= build32 .endif -buildworld: ${WMAKE_TGTS} -.ORDER: ${WMAKE_TGTS} +buildworld: buildworld_prologue ${WMAKE_TGTS} buildworld_epilogue +.ORDER: buildworld_prologue ${WMAKE_TGTS} buildworld_epilogue +buildworld_prologue: + @echo "--------------------------------------------------------------" + @echo ">>> World build started on `LC_ALL=C date`" + @echo "--------------------------------------------------------------" +buildworld_epilogue: + @echo + @echo "--------------------------------------------------------------" + @echo ">>> World build completed on `LC_ALL=C date`" + @echo "--------------------------------------------------------------" + # # We need to have this as a target because the indirection between Makefile # and Makefile.inc1 causes the correct PATH to be used, rather than a @@ -926,9 +960,6 @@ .if ${MK_RESCUE} != "no" || defined(RELEASEDIR) _crunchide= usr.sbin/crunch/crunchide .endif -.if ${TARGET_ARCH} == "alpha" -_elf2exe= usr.sbin/elf2exe -.endif .if ${TARGET_ARCH} == "i386" && defined(RELEASEDIR) _kgzip= usr.sbin/kgzip .endif @@ -941,7 +972,6 @@ usr.bin/xlint/lint1 usr.bin/xlint/lint2 usr.bin/xlint/xlint \ ${_btxld} \ ${_crunchide} \ - ${_elf2exe} \ ${_kgzip} ${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all,install)"; \ cd ${.CURDIR}/${_tool}; \ @@ -1040,8 +1070,9 @@ .for _lib in ${_startup_libs} ${_prebuild_libs:Nlib/libpam} ${_generic_libs} ${_lib}__L: .PHONY .if exists(${.CURDIR}/${_lib}) - ${_+_}@${ECHODIR} "===> ${_lib} (depend,all,install)"; \ + ${_+_}@${ECHODIR} "===> ${_lib} (obj,depend,all,install)"; \ cd ${.CURDIR}/${_lib}; \ + ${MAKE} DIRPRFX=${_lib}/ obj; \ ${MAKE} DIRPRFX=${_lib}/ depend; \ ${MAKE} DIRPRFX=${_lib}/ all; \ ${MAKE} DIRPRFX=${_lib}/ install @@ -1052,8 +1083,9 @@ # static PAM library, and dynamic PAM library before dynamic PAM # modules. lib/libpam__L: .PHONY - ${_+_}@${ECHODIR} "===> lib/libpam (depend,all,install)"; \ + ${_+_}@${ECHODIR} "===> lib/libpam (obj,depend,all,install)"; \ cd ${.CURDIR}/lib/libpam; \ + ${MAKE} DIRPRFX=lib/libpam/ obj; \ ${MAKE} DIRPRFX=lib/libpam/ depend; \ ${MAKE} DIRPRFX=lib/libpam/ -D_NO_LIBPAM_SO_YET all; \ ${MAKE} DIRPRFX=lib/libpam/ -D_NO_LIBPAM_SO_YET install ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/Makefile#2 (text+ko) ==== @@ -1,5 +1,5 @@ # from: @(#)Makefile 5.11 (Berkeley) 5/21/91 -# $FreeBSD: src/etc/Makefile,v 1.356 2006/05/03 15:14:46 ume Exp $ +# $FreeBSD: src/etc/Makefile,v 1.358 2006/09/26 23:26:48 piso Exp $ .include @@ -9,9 +9,10 @@ BIN1= amd.map apmd.conf auth.conf \ crontab csh.cshrc csh.login csh.logout devd.conf devfs.conf \ - dhclient.conf disktab fbtab ftpusers gettytab group \ + dhclient.conf disktab fbtab freebsd-update.conf \ + ftpusers gettytab group \ hosts hosts.allow hosts.equiv hosts.lpd \ - inetd.conf login.access login.conf mac.conf motd \ + inetd.conf libalias.conf login.access login.conf mac.conf motd \ netconfig network.subr networks newsyslog.conf nsswitch.conf \ portsnap.conf pf.conf pf.os phones profile protocols \ rc rc.bsdextended rc.firewall rc.firewall6 rc.initdiskless \ ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/defaults/periodic.conf#2 (text+ko) ==== @@ -13,7 +13,7 @@ # For a more detailed explanation of all the periodic.conf variables, please # refer to the periodic.conf(5) manual page. # -# $FreeBSD: src/etc/defaults/periodic.conf,v 1.38 2006/05/12 19:17:33 mlaier Exp $ +# $FreeBSD: src/etc/defaults/periodic.conf,v 1.41 2006/08/29 08:49:57 ru Exp $ # # What files override these defaults ? @@ -159,6 +159,9 @@ # 400.passwdless daily_status_security_passwdless_enable="YES" +# 410.logincheck +daily_status_security_logincheck_enable="YES" + # 500.ipfwdenied daily_status_security_ipfwdenied_enable="YES" @@ -196,11 +199,6 @@ weekly_show_info="YES" # scripts returning 1 weekly_show_badconfig="NO" # scripts returning 2 -# 120.clean-kvmdb -weekly_clean_kvmdb_enable="YES" # Clean kvmdb weekly -weekly_clean_kvmdb_days=7 # If not accessed for -weekly_clean_kvmdb_verbose="YES" # Mention files deleted - # 310.locate weekly_locate_enable="YES" # Update locate weekly @@ -217,7 +215,7 @@ # 400.status-pkg weekly_status_pkg_enable="NO" # Find out-of-date pkgs pkg_version=pkg_version # Use this program -pkg_version_index=/usr/ports/INDEX-6 # Use this index file +pkg_version_index=/usr/ports/INDEX-7 # Use this index file # 999.local weekly_local="/etc/weekly.local" # Local scripts ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/defaults/rc.conf#5 (text+ko) ==== @@ -15,7 +15,7 @@ # For a more detailed explanation of all the rc.conf variables, please # refer to the rc.conf(5) manual page. # -# $FreeBSD: src/etc/defaults/rc.conf,v 1.294 2006/08/17 20:13:24 brian Exp $ +# $FreeBSD: src/etc/defaults/rc.conf,v 1.296 2006/09/20 19:48:31 brooks Exp $ ############################################################## ### Important initial Boot-time options #################### @@ -40,7 +40,6 @@ kldxref_module_path="" # Override kern.module_path. A ';'-delimited list. powerd_enable="NO" # Run powerd to lower our power usage. powerd_flags="" # Flags to powerd (if enabled). -removable_route_flush="NO" # Flush routes when removing an interface tmpmfs="AUTO" # Set to YES to always create an mfs /tmp, NO to never tmpsize="20m" # Size of mfs /tmp if created tmpmfs_flags="-S -M" # Extra mdmfs options for the mfs /tmp @@ -336,6 +335,10 @@ sdpd_groupname="nobody" # set spdp(8) user/group to run as after sdpd_username="nobody" # it initializes +bthidd_enable="NO" # Enable bthidd(8) (or NO) +bthidd_config="/etc/bluetooth/bthidd.conf" # bthidd(8) configuration file +bthidd_hids="/var/db/bthidd.hids" # bthidd(8) known HID devices file + ### Miscellaneous network options: ### icmp_bmcastecho="NO" # respond to broadcast ping packets ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/hosts.allow#2 (text+ko) ==== @@ -1,6 +1,6 @@ # # hosts.allow access control file for "tcp wrapped" applications. -# $FreeBSD: src/etc/hosts.allow,v 1.22 2006/06/01 14:14:58 csjp Exp $ +# $FreeBSD: src/etc/hosts.allow,v 1.23 2006/08/29 09:20:48 ru Exp $ # # NOTE: The hosts.deny file is deprecated. # Place both 'allow' and 'deny' rules in the hosts.allow file. @@ -39,43 +39,43 @@ ALL : localhost 127.0.0.1 : allow # Comment out next line if you build libwrap without IPv6 support. ALL : [::1] : allow -ALL : my.machine.example.com 192.0.2.35 : allow +#ALL : my.machine.example.com 192.0.2.35 : allow # To use IPv6 addresses you must enclose them in []'s -ALL : [fe80::%fxp0]/10 : allow -ALL : [fe80::]/10 : deny -ALL : [2001:db8:2:1:2:3:4:3fe1] : deny -ALL : [2001:db8:2:1::]/64 : allow +#ALL : [fe80::%fxp0]/10 : allow +#ALL : [fe80::]/10 : deny +#ALL : [2001:db8:2:1:2:3:4:3fe1] : deny +#ALL : [2001:db8:2:1::]/64 : allow # Sendmail can help protect you against spammers and relay-rapers sendmail : localhost : allow -sendmail : .nice.guy.example.com : allow -sendmail : .evil.cracker.example.com : deny +#sendmail : .nice.guy.example.com : allow +#sendmail : .evil.cracker.example.com : deny sendmail : ALL : allow # Exim is an alternative to sendmail, available in the ports tree exim : localhost : allow -exim : .nice.guy.example.com : allow -exim : .evil.cracker.example.com : deny +#exim : .nice.guy.example.com : allow +#exim : .evil.cracker.example.com : deny exim : ALL : allow # Rpcbind is used for all RPC services; protect your NFS! # (IP addresses rather than hostnames *MUST* be used here) -rpcbind : 192.0.2.32/255.255.255.224 : allow -rpcbind : 192.0.2.96/255.255.255.224 : allow +#rpcbind : 192.0.2.32/255.255.255.224 : allow +#rpcbind : 192.0.2.96/255.255.255.224 : allow rpcbind : ALL : deny # NIS master server. Only local nets should have access # (Since this is an RPC service, rpcbind needs to be considered) ypserv : localhost : allow -ypserv : .unsafe.my.net.example.com : deny -ypserv : .my.net.example.com : allow +#ypserv : .unsafe.my.net.example.com : deny +#ypserv : .my.net.example.com : allow ypserv : ALL : deny # Provide a small amount of protection for ftpd ftpd : localhost : allow -ftpd : .nice.guy.example.com : allow -ftpd : .evil.cracker.example.com : deny +#ftpd : .nice.guy.example.com : allow +#ftpd : .evil.cracker.example.com : deny ftpd : ALL : allow # You need to be clever with finger; do _not_ backfinger!! You can easily ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/inetd.conf#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/inetd.conf,v 1.71 2006/02/05 19:23:05 ceri Exp $ +# $FreeBSD: src/etc/inetd.conf,v 1.72 2006/08/31 17:15:10 obrien Exp $ # # Internet server configuration database # @@ -8,6 +8,8 @@ # #ftp stream tcp nowait root /usr/libexec/ftpd ftpd -l #ftp stream tcp6 nowait root /usr/libexec/ftpd ftpd -l +#ftp stream tcp nowait root /usr/libexec/lukemftpd ftpd -l -r +#ftp stream tcp6 nowait root /usr/libexec/lukemftpd ftpd -l -r #ssh stream tcp nowait root /usr/sbin/sshd sshd -i -4 #ssh stream tcp6 nowait root /usr/sbin/sshd sshd -i -6 #telnet stream tcp nowait root /usr/libexec/telnetd telnetd ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/mtree/BSD.include.dist#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/mtree/BSD.include.dist,v 1.107 2006/08/01 22:19:00 sobomax Exp $ +# $FreeBSD: src/etc/mtree/BSD.include.dist,v 1.108 2006/09/07 18:24:24 emax Exp $ # # Please see the file src/etc/mtree/README before making changes to this file. # @@ -66,6 +66,8 @@ .. utopia .. + vkbd + .. wi .. .. ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/mtree/BSD.usr.dist#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/mtree/BSD.usr.dist,v 1.319 2006/08/03 05:44:51 jb Exp $ +# $FreeBSD: src/etc/mtree/BSD.usr.dist,v 1.320 2006/09/02 20:58:37 marcel Exp $ # # Please see the file src/etc/mtree/README before making changes to this file. # @@ -661,6 +661,8 @@ .. i386 .. + powerpc + .. sparc64 .. .. @@ -694,6 +696,8 @@ .. i386 .. + powerpc + .. sparc64 .. .. @@ -766,6 +770,8 @@ .. i386 .. + powerpc + .. sparc64 .. .. ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/mtree/BSD.var.dist#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/etc/mtree/BSD.var.dist,v 1.74 2006/02/05 18:22:56 rwatson Exp $ +# $FreeBSD: src/etc/mtree/BSD.var.dist,v 1.75 2006/08/31 09:51:33 cperciva Exp $ # # Please see the file src/etc/mtree/README before making changes to this file. # @@ -32,6 +32,8 @@ db entropy uname=operator gname=operator mode=0700 .. + freebsd-update + .. ipf mode=0700 .. pkg ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/network.subr#3 (text+ko) ==== @@ -22,7 +22,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/network.subr,v 1.172 2006/08/17 03:03:38 brooks Exp $ +# $FreeBSD: src/etc/network.subr,v 1.173 2006/09/21 01:44:52 brooks Exp $ # # @@ -237,6 +237,30 @@ return 1 } +# ipv6if if +# Returns 0 if the interface should be configured for IPv6 and +# 1 otherwise. +ipv6if() +{ + if ! checkyesno ipv6_enable; then + return 1 + fi + case "${ipv6_network_interfaces}" in + [Aa][Uu][Tt][Oo]) + return 0 + ;; + ''|[Nn][Oo][Nn][Ee]) + return 1 + ;; + esac + for v6if in ${ipv6_network_interfaces}; do + if [ "${v6if}" = "${1}" ]; then + return 0 + fi + done + return 1 +} + # ifexists if # Returns 0 if the interface exists and 1 otherwise. ifexists() ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/pccard_ether#4 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh - # -# $FreeBSD: src/etc/pccard_ether,v 1.50 2006/08/18 13:19:45 brooks Exp $ +# $FreeBSD: src/etc/pccard_ether,v 1.53 2006/09/21 01:44:52 brooks Exp $ # # pccard_ether interfacename [start|stop|restart] # @@ -69,11 +69,13 @@ { ifexists $ifn || exit 1 - if [ -z "$rc_force" -a -x /usr/bin/grep ]; then - if ifconfig $ifn | grep -s '[<,]UP[,>]' > /dev/null 2>&1; then - # Interface is already up, so ignore it. - exit 0 - fi + if [ -z "$rc_force" ]; then + for uif in `ifconfig -ul`; do + if [ "${uif}" = "${ifn}" ]; then + # Interface is already up, so ignore it. + exit 0 + fi + done fi /etc/rc.d/netif start $ifn @@ -87,7 +89,11 @@ fi # IPv6 setup - if checkyesno ipv6_enable; then + if ipv6if $ifn; then + # XXX: network6_interface_setup assumes you're calling + # it with ALL the IPv6 interfaces at once and thus isn't + # really appropraite for this job, but it's the best we've + # got for now. network6_interface_setup $ifn fi } @@ -104,11 +110,6 @@ # clean ARP table ifexists $ifn && arp -d -i $ifn -a - - # Clean the routing table - if checkyesno removable_route_flush; then - route -n flush -inet > /dev/null - fi } pccard_ether_restart() ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/periodic/security/Makefile#2 (text+ko) ==== @@ -1,9 +1,10 @@ -# $FreeBSD: src/etc/periodic/security/Makefile,v 1.5 2006/05/12 19:17:34 mlaier Exp $ +# $FreeBSD: src/etc/periodic/security/Makefile,v 1.6 2006/08/25 07:34:36 trhodes Exp $ FILES= 100.chksetuid \ 200.chkmounts \ 300.chkuid0 \ 400.passwdless \ + 410.logincheck \ 500.ipfwdenied \ 510.ipfdenied \ 520.pfdenied \ ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/periodic/weekly/Makefile#2 (text+ko) ==== @@ -1,7 +1,6 @@ -# $FreeBSD: src/etc/periodic/weekly/Makefile,v 1.8 2002/07/18 12:33:01 ru Exp $ +# $FreeBSD: src/etc/periodic/weekly/Makefile,v 1.9 2006/08/29 08:49:57 ru Exp $ -FILES= 120.clean-kvmdb \ - 310.locate \ +FILES= 310.locate \ 320.whatis \ 330.catman \ 340.noid \ ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/phones#2 (text+ko) ==== @@ -1,11 +1,8 @@ -# $FreeBSD: src/etc/phones,v 1.8 1999/08/27 23:23:43 peter Exp $ +# $FreeBSD: src/etc/phones,v 1.9 2006/08/31 21:13:12 ru Exp $ # From: @(#)phones 5.2 (Berkeley) 6/30/90 # # phones -- remote host phone number data base # see tip(1), phones(5) -# -system1 9=3155557750 -system2 9145551241 -netcom 1(408)555-9760 -netcom 1(415)555-9940 -omen 1(503)555-3746 +# examples: +#system1 9=2225551212 +#system2 9995551212 ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/Makefile#2 (text+ko) ==== @@ -1,12 +1,12 @@ # $NetBSD: Makefile,v 1.16 2001/01/14 15:37:22 minoura Exp $ -# $FreeBSD: src/etc/rc.d/Makefile,v 1.74 2006/08/04 18:37:03 des Exp $ +# $FreeBSD: src/etc/rc.d/Makefile,v 1.76 2006/09/07 22:25:08 emax Exp $ .include FILES= DAEMON LOGIN NETWORKING SERVERS \ abi accounting addswap adjkerntz amd \ apm apmd archdep atm1 atm2 atm3 auditd \ - bgfsck bluetooth bootparams bridge bsnmpd \ + bgfsck bluetooth bootparams bridge bsnmpd bthidd \ ccd cleanvar cleartmp cron \ devd devfs dhclient \ dmesg dumpon \ @@ -30,7 +30,7 @@ pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ quota \ - ramdisk ramdisk-own random rarpd resolv root \ + random rarpd resolv root \ route6d routed routing rpcbind rtadvd rwho \ savecore sdpd securelevel sendmail \ serial sppp swap1 \ ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/auditd#2 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/auditd,v 1.2 2006/06/06 17:22:55 trhodes Exp $ +# $FreeBSD: src/etc/rc.d/auditd,v 1.3 2006/09/24 17:31:04 rwatson Exp $ # # Start up for the Audit daemon. # @@ -25,6 +25,7 @@ { /usr/sbin/audit -t + sleep 1 } load_rc_config $name ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/devd#2 (text+ko) ==== @@ -1,10 +1,10 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/devd,v 1.9 2006/06/01 00:41:07 thompsa Exp $ +# $FreeBSD: src/etc/rc.d/devd,v 1.10 2006/09/21 14:29:32 brooks Exp $ # # PROVIDE: devd -# REQUIRE: netif +# REQUIRE: netif network_ipv6 # BEFORE: NETWORKING mountcritremote # KEYWORD: nojail ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/powerd#2 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/powerd,v 1.3 2005/10/28 16:55:38 yar Exp $ +# $FreeBSD: src/etc/rc.d/powerd,v 1.4 2006/08/27 11:04:39 cperciva Exp $ # # PROVIDE: powerd @@ -13,6 +13,13 @@ name="powerd" rcvar=`set_rcvar` command="/usr/sbin/${name}" +stop_postcmd=powerd_poststop + +powerd_poststop() +{ + sysctl dev.cpu.0.freq=`sysctl -n dev.cpu.0.freq_levels | + sed -e 's:/.*::'` > /dev/null +} load_rc_config $name run_rc_command "$1" ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/sshd#2 (text+ko) ==== @@ -1,7 +1,7 @@ #!/bin/sh # # $NetBSD: sshd,v 1.18 2002/04/29 08:23:34 lukem Exp $ -# $FreeBSD: src/etc/rc.d/sshd,v 1.11 2006/04/11 09:08:15 flz Exp $ +# $FreeBSD: src/etc/rc.d/sshd,v 1.12 2006/08/22 11:17:28 flz Exp $ # # PROVIDE: sshd @@ -19,8 +19,6 @@ timeout=300 -load_rc_config $name - user_reseed() { ( @@ -49,46 +47,47 @@ umask 022 # Can't do anything if ssh is not installed - [ -x ${prefix}/bin/ssh-keygen ] || { - warn "${prefix}/bin/ssh-keygen does not exist." + [ -x /usr/bin/ssh-keygen ] || { + warn "/usr/bin/ssh-keygen does not exist." return 1 } - if [ -f ${etcdir}/ssh/ssh_host_key ]; then + if [ -f /etc/ssh/ssh_host_key ]; then echo "You already have an RSA host key" \ - "in ${etcdir}/ssh/ssh_host_key" + "in /etc/ssh/ssh_host_key" echo "Skipping protocol version 1 RSA Key Generation" else - ${prefix}/bin/ssh-keygen -t rsa1 -b 1024 \ - -f ${etcdir}/ssh/ssh_host_key -N '' + /usr/bin/ssh-keygen -t rsa1 -b 1024 \ + -f /etc/ssh/ssh_host_key -N '' fi - if [ -f ${etcdir}/ssh/ssh_host_dsa_key ]; then + if [ -f /etc/ssh/ssh_host_dsa_key ]; then echo "You already have a DSA host key" \ - "in ${etcdir}/ssh/ssh_host_dsa_key" + "in /etc/ssh/ssh_host_dsa_key" echo "Skipping protocol version 2 DSA Key Generation" else - ${prefix}/bin/ssh-keygen -t dsa -f ${etcdir}/ssh/ssh_host_dsa_key -N '' + /usr/bin/ssh-keygen -t dsa -f /etc/ssh/ssh_host_dsa_key -N '' fi - if [ -f ${etcdir}/ssh/ssh_host_rsa_key ]; then + if [ -f /etc/ssh/ssh_host_rsa_key ]; then echo "You already have a RSA host key" \ - "in ${etcdir}/ssh/ssh_host_rsa_key" + "in /etc/ssh/ssh_host_rsa_key" echo "Skipping protocol version 2 RSA Key Generation" else - ${prefix}/bin/ssh-keygen -t rsa -f ${etcdir}/ssh/ssh_host_rsa_key -N '' + /usr/bin/ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key -N '' fi ) } sshd_precmd() { - if [ ! -f ${etcdir}/ssh/ssh_host_key -o \ - ! -f ${etcdir}/ssh/ssh_host_dsa_key -o \ - ! -f ${etcdir}/ssh/ssh_host_rsa_key ]; then + if [ ! -f /etc/ssh/ssh_host_key -o \ + ! -f /etc/ssh/ssh_host_dsa_key -o \ + ! -f /etc/ssh/ssh_host_rsa_key ]; then user_reseed run_rc_command keygen fi } +load_rc_config $name run_rc_command "$1" ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.d/ypxfrd#2 (text+ko) ==== @@ -1,10 +1,10 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ypxfrd,v 1.6 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/ypxfrd,v 1.7 2006/08/22 14:58:23 flz Exp $ # # PROVIDE: ypxfrd -# REQUIRE: rpcbind +# REQUIRE: rpcbind ypserv . /etc/rc.subr ==== //depot/projects/soc2006/nss_ldap_cached_openldap/src/etc/rc.initdiskless#2 (text+ko) ==== @@ -24,7 +24,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.initdiskless,v 1.49 2006/01/11 21:59:30 brooks Exp $ +# $FreeBSD: src/etc/rc.initdiskless,v 1.51 2006/09/01 16:33:15 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 @@ -76,6 +76,9 @@ # If the file contains a pathname starting with "/", then # the root path is prepended to it; this allows relocation of # the root filesystem without changing configuration files. +# Because mount_nfs understands ".." in paths, it is +# possible to mount from locations above the NFS root with +# paths such as "/../../etc". # # /conf/T/M/md_size # The contents of the file specifies the size of the memory @@ -97,21 +100,27 @@ # The list of paths contained in the file are rm -rf'd # relative to /SUBDIR. # +# /conf/diskless_remount +# Similar to /conf/T/M/diskless_remount above, but allows +# all of /conf to be remounted. This can be used to allow +# multiple roots to share the same /conf. +# +# # You will almost universally want to create the following files under /conf # -# File Content -# ---------------------------- ------------------------------------------ -# /conf/base/etc/md_size size of /etc filesystem -# /conf/base/diskless_remount "/etc" -# /conf/default/etc/rc.conf generic diskless config parameters -# /conf/default/etc/fstab generic diskless fstab e.g. like this +# File Content +# ---------------------------- ---------------------------------- +# /conf/base/etc/md_size size of /etc filesystem +# /conf/base/etc/diskless_remount "/etc" +# /conf/default/etc/rc.conf generic diskless config parameters +# /conf/default/etc/fstab generic diskless fstab e.g. like this # -# foo:/root_part / nfs ro 0 0 -# foo:/usr_part /usr nfs ro 0 0 -# foo:/home_part /home nfs rw 0 0 -# md /tmp mfs -s=30m,rw 0 0 -# md /var mfs -s=30m,rw 0 0 >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Fri Sep 29 13:22:11 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0F89016A416; Fri, 29 Sep 2006 13:22:11 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 DEC4016A40F for ; Fri, 29 Sep 2006 13:22:10 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id A774B43D45 for ; Fri, 29 Sep 2006 13:22:10 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TDMAGs078019 for ; Fri, 29 Sep 2006 13:22:10 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TDMARu078016 for perforce@freebsd.org; Fri, 29 Sep 2006 13:22:10 GMT (envelope-from rdivacky@FreeBSD.org) Date: Fri, 29 Sep 2006 13:22:10 GMT Message-Id: <200609291322.k8TDMARu078016@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106881 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 13:22:11 -0000 http://perforce.freebsd.org/chv.cgi?CH=106881 Change 106881 by rdivacky@rdivacky_witten on 2006/09/29 13:21:44 Be sane and set %gs instead of %fs. Still not there but getting closer. Affected files ... .. //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#5 edit Differences ... ==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#5 (text+ko) ==== @@ -57,6 +57,7 @@ #include #include +#include #include #include #include @@ -679,9 +680,11 @@ /* this is taken from amd64 version of cpu_set_user_tls() */ critical_enter(); - /* set %fs */ - td->td_pcb->pcb_fsbase = (register_t)((register_t)sd.sd_hibase << 24 | sd.sd_lobase); - wrmsr(MSR_FSBASE, td->td_pcb->pcb_fsbase); + /* set %gs */ + td->td_pcb->pcb_gsbase = (register_t)((register_t)sd.sd_hibase << 24 | sd.sd_lobase); +#if 0 + wrmsr(MSR_KGSBASE, td->td_pcb->pcb_fsbase); +#endif critical_exit(); } @@ -1281,9 +1284,9 @@ /* this is taken from amd64 version of cpu_set_user_tls() */ critical_enter(); - /* set %fs */ - td->td_pcb->pcb_fsbase = (register_t)((register_t)sd.sd_hibase << 24 | sd.sd_lobase); - wrmsr(MSR_FSBASE, td->td_pcb->pcb_fsbase); + /* set %gs */ + td->td_pcb->pcb_gsbase = (register_t)((register_t)sd.sd_hibase << 24 | sd.sd_lobase); + wrmsr(MSR_KGSBASE, td->td_pcb->pcb_gsbase); critical_exit(); From owner-p4-projects@FreeBSD.ORG Fri Sep 29 13:57:45 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E3C7D16A4F1; Fri, 29 Sep 2006 13:57:44 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 6807016A4A0 for ; Fri, 29 Sep 2006 13:57:44 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4919243E5B for ; Fri, 29 Sep 2006 13:55:56 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TDtu7N080539 for ; Fri, 29 Sep 2006 13:55:56 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TDtudD080536 for perforce@freebsd.org; Fri, 29 Sep 2006 13:55:56 GMT (envelope-from rdivacky@FreeBSD.org) Date: Fri, 29 Sep 2006 13:55:56 GMT Message-Id: <200609291355.k8TDtudD080536@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106886 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 13:57:45 -0000 http://perforce.freebsd.org/chv.cgi?CH=106886 Change 106886 by rdivacky@rdivacky_witten on 2006/09/29 13:55:30 Use the "base_addr" from the given descriptor instead of translating it to fbsd one and then back. Affected files ... .. //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#6 edit Differences ... ==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#6 (text+ko) ==== @@ -635,7 +635,6 @@ if (args->flags & CLONE_SETTLS) { struct l_user_desc info; int idx; - int a[2]; struct segment_descriptor sd; error = copyin((void *)td->td_frame->tf_rsi, &info, sizeof(struct l_user_desc)); @@ -660,28 +659,10 @@ return (error); } - a[0] = LDT_entry_a(&info); - a[1] = LDT_entry_b(&info); - - memcpy(&sd, &a, sizeof(a)); -#ifdef DEBUG - if (ldebug(clone)) - printf("Segment created in clone with CLONE_SETTLS: lobase: %x, hibase: %x, lolimit: %x, hilimit: %x, type: %i, dpl: %i, p: %i, xx: %i, def32: %i, gran: %i\n", sd.sd_lobase, - sd.sd_hibase, - sd.sd_lolimit, - sd.sd_hilimit, - sd.sd_type, - sd.sd_dpl, - sd.sd_p, - sd.sd_xx, - sd.sd_def32, - sd.sd_gran); -#endif - /* this is taken from amd64 version of cpu_set_user_tls() */ critical_enter(); /* set %gs */ - td->td_pcb->pcb_gsbase = (register_t)((register_t)sd.sd_hibase << 24 | sd.sd_lobase); + td->td_pcb->pcb_gsbase = (register_t)info.base_addr; #if 0 wrmsr(MSR_KGSBASE, td->td_pcb->pcb_fsbase); #endif @@ -1203,7 +1184,6 @@ struct l_user_desc info; int error; int idx; - int a[2]; struct segment_descriptor sd; error = copyin(args->desc, &info, sizeof(struct l_user_desc)); @@ -1259,33 +1239,9 @@ if (error) return (error); - if (LDT_empty(&info)) { - a[0] = 0; - a[1] = 0; - } else { - a[0] = LDT_entry_a(&info); - a[1] = LDT_entry_b(&info); - } - - memcpy(&sd, &a, sizeof(a)); -#ifdef DEBUG - if (ldebug(set_thread_area)) - printf("Segment created in set_thread_area: lobase: %x, hibase: %x, lolimit: %x, hilimit: %x, type: %i, dpl: %i, p: %i, xx: %i, def32: %i, gran: %i\n", sd.sd_lobase, - sd.sd_hibase, - sd.sd_lolimit, - sd.sd_hilimit, - sd.sd_type, - sd.sd_dpl, - sd.sd_p, - sd.sd_xx, - sd.sd_def32, - sd.sd_gran); -#endif - - /* this is taken from amd64 version of cpu_set_user_tls() */ critical_enter(); /* set %gs */ - td->td_pcb->pcb_gsbase = (register_t)((register_t)sd.sd_hibase << 24 | sd.sd_lobase); + td->td_pcb->pcb_gsbase = (register_t)info.base_addr; wrmsr(MSR_KGSBASE, td->td_pcb->pcb_gsbase); critical_exit(); From owner-p4-projects@FreeBSD.ORG Fri Sep 29 14:06:22 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6933E16A47C; Fri, 29 Sep 2006 14:06:22 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 37CB616A417 for ; Fri, 29 Sep 2006 14:06:22 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0BF1743D72 for ; Fri, 29 Sep 2006 14:06:19 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TE6IRW082512 for ; Fri, 29 Sep 2006 14:06:19 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TE6BHt082504 for perforce@freebsd.org; Fri, 29 Sep 2006 14:06:11 GMT (envelope-from rdivacky@FreeBSD.org) Date: Fri, 29 Sep 2006 14:06:11 GMT Message-Id: <200609291406.k8TE6BHt082504@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106890 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 14:06:22 -0000 http://perforce.freebsd.org/chv.cgi?CH=106890 Change 106890 by rdivacky@rdivacky_witten on 2006/09/29 14:05:26 IFC Note: p4 told me that I have a conflict in linux_aio.c I didnt find anything and just accepted that. diff shows no difference between what I have and what was in repo before this commit. Affected files ... .. //depot/projects/linuxolator/src/sys/amd64/amd64/local_apic.c#3 integrate .. //depot/projects/linuxolator/src/sys/amd64/conf/GENERIC#2 integrate .. //depot/projects/linuxolator/src/sys/boot/common/merge_help.awk#2 integrate .. //depot/projects/linuxolator/src/sys/boot/ficl/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/boot/i386/Makefile.inc#2 integrate .. //depot/projects/linuxolator/src/sys/boot/i386/btx/btx/btx.S#2 integrate .. //depot/projects/linuxolator/src/sys/boot/i386/libi386/biossmap.c#2 integrate .. //depot/projects/linuxolator/src/sys/boot/i386/loader/help.i386#2 integrate .. //depot/projects/linuxolator/src/sys/boot/pc98/boot2/inode.h#2 integrate .. //depot/projects/linuxolator/src/sys/bsm/audit_kevents.h#3 integrate .. //depot/projects/linuxolator/src/sys/conf/NOTES#3 integrate .. //depot/projects/linuxolator/src/sys/conf/files#3 integrate .. //depot/projects/linuxolator/src/sys/conf/options#3 integrate .. //depot/projects/linuxolator/src/sys/dev/acpica/Osd/OsdHardware.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/ata/ata-chipset.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/atkbdc/atkbd.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/digi/digi.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/em/if_em.c#4 integrate .. //depot/projects/linuxolator/src/sys/dev/exca/exca.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/ipmi/ipmi.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/isp/isp_freebsd.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/isp/isp_freebsd.h#2 integrate .. //depot/projects/linuxolator/src/sys/dev/kbdmux/kbdmux.c#4 integrate .. //depot/projects/linuxolator/src/sys/dev/mfi/mfi.c#4 integrate .. //depot/projects/linuxolator/src/sys/dev/mfi/mfi_debug.c#1 branch .. //depot/projects/linuxolator/src/sys/dev/mfi/mfivar.h#3 integrate .. //depot/projects/linuxolator/src/sys/dev/smbus/smb.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/midi/sequencer.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/ac97.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/ac97_patch.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/ac97_patch.h#2 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/channel.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/dsp.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/mixer.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/mixer.h#3 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/pcm/sound.h#3 integrate .. //depot/projects/linuxolator/src/sys/dev/sound/usb/uaudio_pcm.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/syscons/scvidctl.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/syscons/syscons.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/uart/uart_kbd_sun.c#3 integrate .. //depot/projects/linuxolator/src/sys/dev/usb/ukbd.c#2 integrate .. //depot/projects/linuxolator/src/sys/dev/vkbd/vkbd.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/devfs/devfs_vfsops.c#3 integrate .. //depot/projects/linuxolator/src/sys/fs/hpfs/hpfs_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/msdosfs/msdosfs_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/ntfs/ntfs_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/nullfs/null_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/nwfs/nwfs_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/portalfs/portal_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/procfs/procfs_ioctl.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/smbfs/smbfs_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/udf/udf_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/umapfs/umap_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/fs/unionfs/union_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/gnu/fs/ext2fs/ext2_inode.c#2 integrate .. //depot/projects/linuxolator/src/sys/gnu/fs/ext2fs/ext2_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/gnu/fs/reiserfs/reiserfs_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/i386/conf/GENERIC#2 integrate .. //depot/projects/linuxolator/src/sys/i386/i386/busdma_machdep.c#3 integrate .. //depot/projects/linuxolator/src/sys/i386/i386/local_apic.c#3 integrate .. //depot/projects/linuxolator/src/sys/ia64/conf/GENERIC#2 integrate .. //depot/projects/linuxolator/src/sys/isofs/cd9660/cd9660_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/init_main.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/kern_descrip.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/kern_event.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/kern_proc.c#4 integrate .. //depot/projects/linuxolator/src/sys/kern/sys_generic.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/tty_pts.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/tty_pty.c#3 integrate .. //depot/projects/linuxolator/src/sys/kern/tty_tty.c#3 integrate .. //depot/projects/linuxolator/src/sys/kern/uipc_mqueue.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/vfs_aio.c#4 integrate .. //depot/projects/linuxolator/src/sys/kern/vfs_cluster.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/vfs_export.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/vfs_mount.c#3 integrate .. //depot/projects/linuxolator/src/sys/kern/vfs_subr.c#2 integrate .. //depot/projects/linuxolator/src/sys/kern/vfs_syscalls.c#3 integrate .. //depot/projects/linuxolator/src/sys/modules/digi/digi/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/if_tap/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/kbdmux/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/libalias/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/libalias/libalias/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/Makefile.inc#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/cuseeme/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/dummy/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/ftp/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/irc/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/modules.inc#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/nbt/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/pptp/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/skinny/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/libalias/modules/smedia/Makefile#1 branch .. //depot/projects/linuxolator/src/sys/modules/mfi/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/procfs/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/ukbd/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/vkbd/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/modules/wlan/Makefile#2 integrate .. //depot/projects/linuxolator/src/sys/net/if_tap.c#2 integrate .. //depot/projects/linuxolator/src/sys/net/if_tap.h#2 integrate .. //depot/projects/linuxolator/src/sys/net80211/ieee80211_ioctl.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/in.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/in_var.h#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/ip_carp.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/ip_mroute.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/ip_output.c#3 integrate .. //depot/projects/linuxolator/src/sys/netinet/ip_var.h#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias.h#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_cuseeme.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_db.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_dummy.c#1 branch .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_ftp.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_irc.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_local.h#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_mod.c#1 branch .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_mod.h#1 branch .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_nbt.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_old.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_pptp.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_proxy.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_skinny.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_smedia.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/alias_util.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/libalias/libalias.3#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/tcp_input.c#4 integrate .. //depot/projects/linuxolator/src/sys/netinet/tcp_output.c#3 integrate .. //depot/projects/linuxolator/src/sys/netinet/tcp_subr.c#2 integrate .. //depot/projects/linuxolator/src/sys/netinet/tcp_timer.h#2 integrate .. //depot/projects/linuxolator/src/sys/nfsclient/nfs_vfsops.c#3 integrate .. //depot/projects/linuxolator/src/sys/nfsclient/nfs_vnops.c#3 integrate .. //depot/projects/linuxolator/src/sys/pc98/cbus/pckbd.c#2 integrate .. //depot/projects/linuxolator/src/sys/pc98/conf/GENERIC#2 integrate .. //depot/projects/linuxolator/src/sys/pci/agp_i810.c#2 integrate .. //depot/projects/linuxolator/src/sys/powerpc/conf/GENERIC#2 integrate .. //depot/projects/linuxolator/src/sys/security/audit/audit_worker.c#4 integrate .. //depot/projects/linuxolator/src/sys/sparc64/conf/GENERIC#2 integrate .. //depot/projects/linuxolator/src/sys/sys/consio.h#2 integrate .. //depot/projects/linuxolator/src/sys/sys/copyright.h#2 integrate .. //depot/projects/linuxolator/src/sys/sys/digiio.h#2 integrate .. //depot/projects/linuxolator/src/sys/sys/event.h#2 integrate .. //depot/projects/linuxolator/src/sys/sys/ioccom.h#2 integrate .. //depot/projects/linuxolator/src/sys/sys/kbio.h#2 integrate .. //depot/projects/linuxolator/src/sys/sys/mount.h#3 integrate .. //depot/projects/linuxolator/src/sys/sys/param.h#3 integrate .. //depot/projects/linuxolator/src/sys/sys/pioctl.h#2 integrate .. //depot/projects/linuxolator/src/sys/sys/ttycom.h#2 integrate .. //depot/projects/linuxolator/src/sys/ufs/ffs/ffs_snapshot.c#2 integrate .. //depot/projects/linuxolator/src/sys/ufs/ffs/ffs_softdep.c#3 integrate .. //depot/projects/linuxolator/src/sys/ufs/ffs/ffs_vfsops.c#2 integrate .. //depot/projects/linuxolator/src/sys/ufs/ufs/inode.h#2 integrate .. //depot/projects/linuxolator/src/sys/ufs/ufs/ufs_quota.c#3 integrate .. //depot/projects/linuxolator/src/sys/vm/vm_page.c#2 integrate Differences ... ==== //depot/projects/linuxolator/src/sys/amd64/amd64/local_apic.c#3 (text+ko) ==== @@ -32,7 +32,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/amd64/amd64/local_apic.c,v 1.29 2006/09/11 20:12:42 jhb Exp $"); +__FBSDID("$FreeBSD: src/sys/amd64/amd64/local_apic.c,v 1.31 2006/09/27 22:09:35 sobomax Exp $"); #include "opt_hwpmc_hooks.h" @@ -613,13 +613,17 @@ /* Send EOI first thing. */ lapic_eoi(); -#ifdef SMP +#if defined(SMP) && !defined(SCHED_ULE) /* * Don't do any accounting for the disabled HTT cores, since it * will provide misleading numbers for the userland. * * No locking is necessary here, since even if we loose the race * when hlt_cpus_mask changes it is not a big deal, really. + * + * Don't do that for ULE, since ULE doesn't consider hlt_cpus_mask + * and unlike other schedulers it actually schedules threads to + * those CPUs. */ if ((hlt_cpus_mask & (1 << PCPU_GET(cpuid))) != 0) return; ==== //depot/projects/linuxolator/src/sys/amd64/conf/GENERIC#2 (text+ko) ==== @@ -16,7 +16,7 @@ # If you are in doubt as to the purpose or necessity of a line, check first # in NOTES. # -# $FreeBSD: src/sys/amd64/conf/GENERIC,v 1.464 2006/07/09 16:39:21 mjacob Exp $ +# $FreeBSD: src/sys/amd64/conf/GENERIC,v 1.465 2006/09/26 12:36:33 ru Exp $ cpu HAMMER ident GENERIC @@ -49,6 +49,7 @@ options COMPAT_IA32 # Compatible with i386 binaries options COMPAT_FREEBSD4 # Compatible with FreeBSD4 options COMPAT_FREEBSD5 # Compatible with FreeBSD5 +options COMPAT_FREEBSD6 # Compatible with FreeBSD6 options SCSI_DELAY=5000 # Delay (in ms) before probing SCSI options KTRACE # ktrace(1) support options SYSVSHM # SYSV-style shared memory ==== //depot/projects/linuxolator/src/sys/boot/common/merge_help.awk#2 (text+ko) ==== @@ -1,6 +1,6 @@ #!/usr/bin/awk -f # -# $FreeBSD: src/sys/boot/common/merge_help.awk,v 1.5 2001/11/07 17:53:25 fenner Exp $ +# $FreeBSD: src/sys/boot/common/merge_help.awk,v 1.6 2006/09/28 19:06:20 jhb Exp $ # # Merge two boot loader help files for FreeBSD 3.0 # Joe Abley @@ -25,9 +25,12 @@ match($0, " T[[:graph:]]+"); T = substr($0, RSTART + 2, RLENGTH - 2); match($0, " S[[:graph:]]+"); + SSTART = RSTART S = (RLENGTH == -1) ? "" : substr($0, RSTART + 2, RLENGTH - 2); match($0, " D[[:graph:]][[:print:]]*$"); D = substr($0, RSTART + 2); + if (SSTART > RSTART) + S = ""; # find a suitable place to store this one... ind++; ==== //depot/projects/linuxolator/src/sys/boot/ficl/Makefile#2 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/boot/ficl/Makefile,v 1.43 2006/05/12 04:07:42 jhb Exp $ +# $FreeBSD: src/sys/boot/ficl/Makefile,v 1.44 2006/09/28 10:02:03 ru Exp $ # .PATH: ${.CURDIR}/${MACHINE_ARCH:S/amd64/i386/} BASE_SRCS= dict.c ficl.c fileaccess.c float.c loader.c math64.c \ @@ -42,7 +42,7 @@ #SOFTWORDS+= oo.fr classes.fr .if ${MACHINE_ARCH} == "amd64" -CFLAGS+= -m32 -I. +CFLAGS+= -m32 -march=i386 -I. .endif CFLAGS+= -I${.CURDIR} -I${.CURDIR}/${MACHINE_ARCH:S/amd64/i386/} \ ==== //depot/projects/linuxolator/src/sys/boot/i386/Makefile.inc#2 (text+ko) ==== @@ -1,6 +1,6 @@ # Common defines for all of /sys/boot/i386/ # -# $FreeBSD: src/sys/boot/i386/Makefile.inc,v 1.11 2005/07/15 12:22:14 ache Exp $ +# $FreeBSD: src/sys/boot/i386/Makefile.inc,v 1.12 2006/09/28 10:02:04 ru Exp $ BINDIR?= /boot @@ -10,7 +10,7 @@ LDFLAGS+= -nostdlib .if ${MACHINE_ARCH} == "amd64" -CFLAGS+= -m32 +CFLAGS+= -m32 -march=i386 LDFLAGS+= -m elf_i386_fbsd AFLAGS+= --32 .endif ==== //depot/projects/linuxolator/src/sys/boot/i386/btx/btx/btx.S#2 (text+ko) ==== @@ -12,7 +12,7 @@ * warranties of merchantability and fitness for a particular * purpose. * - * $FreeBSD: src/sys/boot/i386/btx/btx/btx.S,v 1.38 2004/11/24 14:54:33 jhb Exp $ + * $FreeBSD: src/sys/boot/i386/btx/btx/btx.S,v 1.42 2006/09/28 19:42:10 jhb Exp $ */ /* @@ -208,7 +208,7 @@ #ifdef PAGING or $0x80000001,%eax # mode and enable paging #else - or $0x01,%eax # mode + inc %ax # mode #endif mov %eax,%cr0 # ljmp $SEL_SCODE,$init.8 # To 32-bit code @@ -493,9 +493,7 @@ je v86wrmsr # Yes cmpb $0x32,(%esi) # Is it a RDMSR? je v86rdmsr # Yes - cmpb $0x20,(%esi) # Is this a - jne v86mon.4 # MOV EAX,CR0 - cmpb $0xc0,0x1(%esi) # instruction? + cmpb $0x20,(%esi) # Is this a MOV reg,CRx? je v86mov # Yes v86mon.4: cmpb $0xfa,%al # CLI? je v86cli # Yes @@ -527,10 +525,24 @@ leal 0x8(%esp,1),%esp # Discard int no, error iret # To V86 mode /* - * Emulate MOV EAX,CR0. + * Emulate MOV reg,CRx. */ -v86mov: movl %cr0,%eax # CR0 to - movl %eax,0x1c(%ebp) # saved EAX +v86mov: movb 0x1(%esi),%bl # Fetch Mod R/M byte + testb $0x10,%bl # Read CR2 or CR3? + jnz v86mov.1 # Yes + movl %cr0,%eax # Read CR0 + testb $0x20,%bl # Read CR4 instead? + jz v86mov.2 # No + movl %cr4,%eax # Read CR4 + jmp v86mov.2 +v86mov.1: movl %cr2,%eax # Read CR2 + testb $0x08,%bl # Read CR3 instead? + jz v86mov.2 # No + movl %cr3,%eax # Read CR3 +v86mov.2: andl $0x7,%ebx # Compute offset in + shl $2,%ebx # frame of destination + neg %ebx # register + movl %eax,0x1c(%ebp,%ebx,1) # Store CR to reg incl %esi # Adjust IP /* * Return from emulating a 0x0f prefixed instruction @@ -606,41 +618,27 @@ * reads count of words from saved %cx * returns success by setting %ah to 0 */ -int15_87: pushl %eax # Save - pushl %ebx # some information - pushl %esi # onto the stack. - pushl %edi - xorl %eax,%eax # clean EAX - xorl %ebx,%ebx # clean EBX - movl 0x4(%ebp),%esi # Get user's ESI - movl 0x3C(%ebp),%ebx # store ES - movw %si,%ax # store SI - shll $0x4,%ebx # Make it a seg. - addl %eax,%ebx # ebx=(es<<4)+si - movb 0x14(%ebx),%al # Grab the - movb 0x17(%ebx),%ah # necessary - shll $0x10,%eax # information - movw 0x12(%ebx),%ax # from - movl %eax,%esi # the - movb 0x1c(%ebx),%al # GDT in order to - movb 0x1f(%ebx),%ah # have %esi offset - shll $0x10,%eax # of source and %edi - movw 0x1a(%ebx),%ax # of destination. - movl %eax,%edi +int15_87: pushl %esi # Save + pushl %edi # registers + movzwl 0x4(%ebp),%eax # Load user's SI + movl 0x3C(%ebp),%edi # Load ES + leal (%eax,%edi,4),%edi # EDI = (ES << 4) + SI + movl 0x11(%edi),%eax # Read base of + movb 0x17(%edi),%al # GDT entry + ror $8,%eax # for source + xchgl %eax,%esi # into %esi + movl 0x19(%edi),%eax # Read base of + movb 0x1f(%edi),%al # GDT entry for + ror $8,%eax # destination + xchgl %eax,%edi # into %edi pushl %ds # Make: popl %es # es = ds - pushl %ecx # stash ECX - xorl %ecx,%ecx # highw of ECX is clear - movw 0x18(%ebp),%cx # Get user's ECX - shll $0x1,%ecx # Convert from num words to num - # bytes + movzwl 0x18(%ebp),%ecx # Get user's CX + shll $0x1,%ecx # Convert count from words rep # repeat... movsb # perform copy. - popl %ecx # Restore - popl %edi - popl %esi # previous - popl %ebx # register - popl %eax # values. + popl %edi # Restore + popl %esi # registers movb $0x0,0x1d(%ebp) # set ah = 0 to indicate # success andb $0xfe,%dl # clear CF @@ -659,23 +657,16 @@ cmpb $0x19,%al # is it int 19? je reboot # yes, reboot the machine cmpb $0x15,%al # is it int 15? - jne v86intn.3 # no, skip parse - pushl %eax # stash EAX - movl 0x1c(%ebp),%eax # user's saved EAX - cmpb $0x87,%ah # is it the memcpy subfunction? - jne v86intn.1 # no, keep checking - popl %eax # get the stack straight - jmp int15_87 # it's our cue -v86intn.1: cmpw $0x4f53,%ax # is it the delete key callout? - jne v86intn.2 # no, handle the int normally - movb BDA_KEYFLAGS,%al # get the shift key state - andb $0xc,%al # mask off just Ctrl and Alt - cmpb $0xc,%al # are both Ctrl and Alt down? - jne v86intn.2 # no, handle the int normally - popl %eax # restore EAX - jmp reboot # reboot the machine -v86intn.2: popl %eax # restore EAX -v86intn.3: subl %edi,%esi # From + jne v86intn.1 # no, skip parse + cmpb $0x87,0x1d(%ebp) # is it the memcpy subfunction? + je int15_87 # yes + cmpw $0x4f53,0x1c(%ebp) # is it the delete key callout? + jne v86intn.1 # no, handle the int normally + movb BDA_KEYFLAGS,%ch # get the shift key state + andb $0xc,%ch # mask off just Ctrl and Alt + cmpb $0xc,%ch # are both Ctrl and Alt down? + je reboot # yes, reboot the machine +v86intn.1: subl %edi,%esi # From shrl $0x4,%edi # linear movw %dx,-0x2(%ebx) # Save flags movw %di,-0x4(%ebx) # Save CS @@ -907,8 +898,7 @@ dump.3: lodsl # Set offset xchgl %eax,%edx # Save lodsl # Get segment - shll $0x4,%eax # * 0x10 - addl %edx,%eax # + offset + leal (%edx,%eax,4),%eax # * 0x10 + offset xchgl %eax,%esi # Set pointer dump.4: movb $2,%dl # Num lines dump.4a: movb $0x10,%cl # Bytes to dump ==== //depot/projects/linuxolator/src/sys/boot/i386/libi386/biossmap.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/boot/i386/libi386/biossmap.c,v 1.4 2005/12/19 09:00:11 sobomax Exp $"); +__FBSDID("$FreeBSD: src/sys/boot/i386/libi386/biossmap.c,v 1.5 2006/09/28 19:07:13 jhb Exp $"); /* * Obtain memory configuration information from the BIOS @@ -95,6 +95,7 @@ break; } while (v86.ebx != 0 && smaplen < n); } + void bios_addsmapdata(struct preloaded_file *kfp) { @@ -105,3 +106,17 @@ len = smaplen * sizeof(*smapbase); file_addmetadata(kfp, MODINFOMD_SMAP, len, smapbase); } + +COMMAND_SET(smap, "smap", "show BIOS SMAP", command_smap); + +static int +command_smap(int argc, char *argv[]) +{ + int i; + + if (smapbase == 0 || smaplen == 0) + return; + for (i = 0; i < smaplen; i++) + printf("SMAP type=%02x base=%016llx len=%016llx\n", + smapbase[i].type, smapbase[i].base, smapbase[i].length); +} ==== //depot/projects/linuxolator/src/sys/boot/i386/loader/help.i386#2 (text+ko) ==== @@ -54,3 +54,10 @@ forced by setting this variable. ################################################################################ +# Tsmap DDisplay BIOS SMAP table + + smap + + Displays the BIOS SMAP (system memory map) table. + +################################################################################ ==== //depot/projects/linuxolator/src/sys/boot/pc98/boot2/inode.h#2 (text+ko) ==== @@ -33,7 +33,7 @@ * * @(#)inode.h 8.9 (Berkeley) 5/14/95 * %FreeBSD: src/sys/ufs/ufs/inode.h,v 1.28.2.2 2001/09/29 12:52:52 iedowse Exp % - * $FreeBSD: src/sys/boot/pc98/boot2/inode.h,v 1.4 2004/06/16 18:21:22 phk Exp $ + * $FreeBSD: src/sys/boot/pc98/boot2/inode.h,v 1.5 2006/09/26 04:15:57 tegge Exp $ */ #ifndef _UFS_UFS_INODE_H_ @@ -147,7 +147,7 @@ /* Determine if soft dependencies are being done */ #define DOINGSOFTDEP(vp) ((vp)->v_mount->mnt_flag & MNT_SOFTDEP) -#define DOINGASYNC(vp) ((vp)->v_mount->mnt_flag & MNT_ASYNC) +#define DOINGASYNC(vp) ((vp)->v_mount->mnt_kern_flag & MNTK_ASYNC) /* This overlays the fid structure (see mount.h). */ struct ufid { ==== //depot/projects/linuxolator/src/sys/bsm/audit_kevents.h#3 (text) ==== @@ -30,8 +30,8 @@ * * @APPLE_BSD_LICENSE_HEADER_END@ * - * $P4: //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#28 $ - * $FreeBSD: src/sys/bsm/audit_kevents.h,v 1.8 2006/09/21 07:27:02 rwatson Exp $ + * $P4: //depot/projects/trustedbsd/audit3/sys/bsm/audit_kevents.h#29 $ + * $FreeBSD: src/sys/bsm/audit_kevents.h,v 1.9 2006/09/25 12:22:07 rwatson Exp $ */ #ifndef _BSM_AUDIT_KEVENTS_H_ @@ -471,6 +471,10 @@ #define AUE_KENV 43114 /* FreeBSD. */ #define AUE_JAIL_ATTACH 43115 /* FreeBSD. */ #define AUE_SYSCTL_WRITE 43116 /* FreeBSD. */ +#define AUE_IOPERM 43117 /* Linux. */ +#define AUE_READDIR 43118 /* Linux. */ +#define AUE_IOPL 43119 /* Linux. */ +#define AUE_VM86 43120 /* Linux. */ /* * Darwin BSM uses a number of AUE_O_* definitions, which are aliased to the ==== //depot/projects/linuxolator/src/sys/conf/NOTES#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/NOTES,v 1.1381 2006/09/20 13:33:40 rwatson Exp $ +# $FreeBSD: src/sys/conf/NOTES,v 1.1383 2006/09/26 12:36:33 ru Exp $ # # NOTES -- Lines that can be cut/pasted into kernel and hints configs. # @@ -273,6 +273,9 @@ # Enable FreeBSD5 compatibility syscalls options COMPAT_FREEBSD5 +# Enable FreeBSD6 compatibility syscalls +options COMPAT_FREEBSD6 + # # These three options provide support for System V Interface # Definition-style interprocess communication, in the form of shared @@ -1544,6 +1547,7 @@ device mlx # Mylex DAC960 device amr # AMI MegaRAID device mfi # LSI MegaRAID SAS +options MFI_DEBUG # # 3ware ATA RAID ==== //depot/projects/linuxolator/src/sys/conf/files#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/files,v 1.1142 2006/09/18 17:23:35 sam Exp $ +# $FreeBSD: src/sys/conf/files,v 1.1144 2006/09/26 23:26:51 piso Exp $ # # The long compile-with and dependency lines are required because of # limitations in config: backslash-newline doesn't work in strings, and @@ -713,6 +713,7 @@ dev/md/md.c optional md dev/mem/memdev.c optional mem dev/mfi/mfi.c optional mfi +dev/mfi/mfi_debug.c optional mfi dev/mfi/mfi_pci.c optional mfi pci dev/mfi/mfi_disk.c optional mfi dev/mfi/mfi_linux.c optional mfi compat_linux @@ -1743,16 +1744,11 @@ netinet/tcp_usrreq.c optional inet netinet/udp_usrreq.c optional inet netinet/libalias/alias.c optional libalias -netinet/libalias/alias_cuseeme.c optional libalias netinet/libalias/alias_db.c optional libalias -netinet/libalias/alias_ftp.c optional libalias -netinet/libalias/alias_irc.c optional libalias -netinet/libalias/alias_nbt.c optional libalias -netinet/libalias/alias_pptp.c optional libalias netinet/libalias/alias_proxy.c optional libalias -netinet/libalias/alias_skinny.c optional libalias -netinet/libalias/alias_smedia.c optional libalias netinet/libalias/alias_util.c optional libalias +netinet/libalias/alias_old.c optional libalias +netinet/libalias/alias_mod.c optional libalias netinet6/ah_aesxcbcmac.c optional ipsec netinet6/ah_core.c optional ipsec netinet6/ah_input.c optional ipsec ==== //depot/projects/linuxolator/src/sys/conf/options#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD: src/sys/conf/options,v 1.558 2006/09/20 13:33:40 rwatson Exp $ +# $FreeBSD: src/sys/conf/options,v 1.559 2006/09/26 12:36:33 ru Exp $ # # On the handling of kernel options # @@ -67,6 +67,7 @@ COMPAT_43TTY opt_compat.h COMPAT_FREEBSD4 opt_compat.h COMPAT_FREEBSD5 opt_compat.h +COMPAT_FREEBSD6 opt_compat.h COMPILING_LINT opt_global.h CY_PCI_FASTINTR DIRECTIO ==== //depot/projects/linuxolator/src/sys/dev/acpica/Osd/OsdHardware.c#2 (text+ko) ==== @@ -30,7 +30,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/acpica/Osd/OsdHardware.c,v 1.20 2006/04/04 02:22:38 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/Osd/OsdHardware.c,v 1.21 2006/09/24 09:39:17 hrs Exp $"); #include @@ -126,7 +126,9 @@ error = acpi_os_check_port(InPort, Width); if (error != 0) { - printf("acpi: bad read from port 0x%03x (%d)\n", (int)InPort, Width); + if (bootverbose) + printf("acpi: bad read from port 0x%03x (%d)\n", + (int)InPort, Width); if (error == -1) return (AE_BAD_PARAMETER); } @@ -159,8 +161,9 @@ error = acpi_os_check_port(OutPort, Width); if (error != 0) { - printf("acpi: bad write to port 0x%03x (%d), val %#x\n", (int)OutPort, - Width, Value); + if (bootverbose) + printf("acpi: bad write to port 0x%03x (%d), val %#x\n", + (int)OutPort, Width, Value); if (error == -1) return (AE_BAD_PARAMETER); } ==== //depot/projects/linuxolator/src/sys/dev/ata/ata-chipset.c#3 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/ata/ata-chipset.c,v 1.175 2006/09/12 22:06:39 sos Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/ata/ata-chipset.c,v 1.176 2006/09/25 11:26:29 sos Exp $"); #include "opt_ata.h" #include @@ -985,6 +985,13 @@ ctlr->allocate = ata_ali_sata_allocate; ctlr->setmode = ata_sata_setmode; + /* if we have a memory resource we can likely do AHCI */ + ctlr->r_type2 = SYS_RES_MEMORY; + ctlr->r_rid2 = PCIR_BAR(5); + if ((ctlr->r_res2 = bus_alloc_resource_any(dev, ctlr->r_type2, + &ctlr->r_rid2, RF_ACTIVE))) + return ata_ahci_chipinit(dev); + /* enable PCI interrupt */ pci_write_config(dev, PCIR_COMMAND, pci_read_config(dev, PCIR_COMMAND, 2) & ~0x0400, 2); ==== //depot/projects/linuxolator/src/sys/dev/atkbdc/atkbd.c#2 (text+ko) ==== @@ -26,8 +26,9 @@ */ #include -__FBSDID("$FreeBSD: src/sys/dev/atkbdc/atkbd.c,v 1.50 2006/05/17 09:33:07 phk Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/atkbdc/atkbd.c,v 1.51 2006/09/27 19:56:58 ru Exp $"); +#include "opt_compat.h" #include "opt_kbd.h" #include "opt_atkbd.h" @@ -851,6 +852,10 @@ int error; int s; int i; +#if defined(COMPAT_FREEBSD6) || defined(COMPAT_FREEBSD5) || \ + defined(COMPAT_FREEBSD4) || defined(COMPAT_43) + int ival; +#endif s = spltty(); switch (cmd) { @@ -858,6 +863,13 @@ case KDGKBMODE: /* get keyboard mode */ *(int *)arg = state->ks_mode; break; +#if defined(COMPAT_FREEBSD6) || defined(COMPAT_FREEBSD5) || \ + defined(COMPAT_FREEBSD4) || defined(COMPAT_43) + case _IO('K', 7): + ival = IOCPARM_IVAL(arg); + arg = (caddr_t)&ival; + /* FALLTHROUGH */ +#endif case KDSKBMODE: /* set keyboard mode */ switch (*(int *)arg) { case K_XLATE: @@ -883,6 +895,13 @@ case KDGETLED: /* get keyboard LED */ *(int *)arg = KBD_LED_VAL(kbd); break; +#if defined(COMPAT_FREEBSD6) || defined(COMPAT_FREEBSD5) || \ + defined(COMPAT_FREEBSD4) || defined(COMPAT_43) + case _IO('K', 66): + ival = IOCPARM_IVAL(arg); + arg = (caddr_t)&ival; + /* FALLTHROUGH */ +#endif case KDSETLED: /* set keyboard LED */ /* NOTE: lock key state in ks_state won't be changed */ if (*(int *)arg & ~LOCK_MASK) { @@ -912,6 +931,13 @@ case KDGKBSTATE: /* get lock key state */ *(int *)arg = state->ks_state & LOCK_MASK; break; +#if defined(COMPAT_FREEBSD6) || defined(COMPAT_FREEBSD5) || \ + defined(COMPAT_FREEBSD4) || defined(COMPAT_43) + case _IO('K', 20): + ival = IOCPARM_IVAL(arg); + arg = (caddr_t)&ival; + /* FALLTHROUGH */ +#endif case KDSKBSTATE: /* set lock key state */ if (*(int *)arg & ~LOCK_MASK) { splx(s); @@ -935,6 +961,13 @@ } return error; +#if defined(COMPAT_FREEBSD6) || defined(COMPAT_FREEBSD5) || \ + defined(COMPAT_FREEBSD4) || defined(COMPAT_43) + case _IO('K', 67): + ival = IOCPARM_IVAL(arg); + arg = (caddr_t)&ival; + /* FALLTHROUGH */ +#endif case KDSETRAD: /* set keyboard repeat rate (old interface) */ splx(s); if (!KBD_HAS_DEVICE(kbd)) ==== //depot/projects/linuxolator/src/sys/dev/digi/digi.c#2 (text+ko) ==== @@ -26,7 +26,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/digi/digi.c,v 1.62 2006/06/20 20:54:13 jhb Exp $ + * $FreeBSD: src/sys/dev/digi/digi.c,v 1.63 2006/09/27 19:56:58 ru Exp $ */ /*- @@ -913,6 +913,10 @@ { struct digi_softc *sc; struct digi_p *port; +#if defined(COMPAT_FREEBSD6) || defined(COMPAT_FREEBSD5) || \ + defined(COMPAT_FREEBSD4) || defined(COMPAT_43) + int ival; +#endif port = tp->t_sc; sc = port->sc; @@ -942,8 +946,15 @@ } } return (0); +#if defined(COMPAT_FREEBSD6) || defined(COMPAT_FREEBSD5) || \ + defined(COMPAT_FREEBSD4) || defined(COMPAT_43) + case _IO('e', 'C'): + ival = IOCPARM_IVAL(data); + data = &ival; + /* FALLTHROUGH */ +#endif case DIGIIO_RING: - port->send_ring = *(u_char *)data; + port->send_ring = (u_char)*(int *)data; break; default: return (ENOTTY); ==== //depot/projects/linuxolator/src/sys/dev/em/if_em.c#4 (text+ko) ==== @@ -31,7 +31,7 @@ ***************************************************************************/ -/*$FreeBSD: src/sys/dev/em/if_em.c,v 1.147 2006/09/21 19:14:51 andre Exp $*/ +/*$FreeBSD: src/sys/dev/em/if_em.c,v 1.152 2006/09/29 13:47:38 andre Exp $*/ #ifdef HAVE_KERNEL_OPTION_HEADERS #include "opt_device_polling.h" @@ -69,6 +69,7 @@ #include #include #include +#include #include #include @@ -911,8 +912,8 @@ ifp->if_capenable ^= IFCAP_HWCSUM; reinit = 1; } - if (mask & IFCAP_TSO) { - ifp->if_capenable ^= IFCAP_TSO; + if (mask & IFCAP_TSO4) { + ifp->if_capenable ^= IFCAP_TSO4; reinit = 1; } if (mask & IFCAP_VLAN_HWTAGGING) { @@ -1474,40 +1475,6 @@ } /* - * When operating in promiscuous mode, hardware encapsulation for - * packets is disabled. This means we have to add the vlan - * encapsulation in the driver, since it will have come down from the - * VLAN layer with a tag instead of a VLAN header. - */ - if ((m_head->m_flags & M_VLANTAG) && adapter->em_insert_vlan_header) { - struct ether_vlan_header *evl; - struct ether_header eh; - - m_head = m_pullup(m_head, sizeof(eh)); - if (m_head == NULL) { - *m_headp = NULL; - return (ENOBUFS); - } - eh = *mtod(m_head, struct ether_header *); - M_PREPEND(m_head, sizeof(*evl), M_DONTWAIT); - if (m_head == NULL) { - *m_headp = NULL; - return (ENOBUFS); - } - m_head = m_pullup(m_head, sizeof(*evl)); - if (m_head == NULL) { - *m_headp = NULL; - return (ENOBUFS); - } - evl = mtod(m_head, struct ether_vlan_header *); - bcopy(&eh, evl, sizeof(*evl)); - evl->evl_proto = evl->evl_encap_proto; - evl->evl_encap_proto = htons(ETHERTYPE_VLAN); - evl->evl_tag = htons(m_head->m_pkthdr.ether_vtag); - *m_headp = m_head; - } - - /* * TSO workaround: * If an mbuf is only header we need * to pull 4 bytes of data into it. @@ -1526,8 +1493,19 @@ tx_buffer = &adapter->tx_buffer_area[adapter->next_avail_tx_desc]; tx_buffer_last = tx_buffer; map = tx_buffer->map; + error = bus_dmamap_load_mbuf_sg(adapter->txtag, map, *m_headp, segs, &nsegs, BUS_DMA_NOWAIT); + + /* + * There are two types of errors we can (try) to handle: + * - EFBIG means the mbuf chain was too long and bus_dma ran + * out of segments. Defragment the mbuf chain and try again. + * - ENOMEM means bus_dma could not obtain enough bounce buffers + * at this point in time. Defer sending and try again later. + * All other errors, in particular EINVAL, are fatal and prevent the + * mbuf chain from ever going through. Drop it and report error. + */ if (error == EFBIG) { struct mbuf *m; @@ -1540,22 +1518,27 @@ return (ENOBUFS); } *m_headp = m; + error = bus_dmamap_load_mbuf_sg(adapter->txtag, map, *m_headp, segs, &nsegs, BUS_DMA_NOWAIT); - if (error != 0) { + + if (error == ENOMEM) { + adapter->no_tx_dma_setup++; + return (error); + } else if (error != 0) { adapter->no_tx_dma_setup++; m_freem(*m_headp); *m_headp = NULL; return (error); } + } else if (error == ENOMEM) { + adapter->no_tx_dma_setup++; + return (error); } else if (error != 0) { adapter->no_tx_dma_setup++; - return (error); - } - if (nsegs == 0) { m_freem(*m_headp); *m_headp = NULL; - return (EIO); + return (error); } /* @@ -1575,11 +1558,12 @@ bus_dmamap_unload(adapter->txtag, map); return (ENOBUFS); } + m_head = *m_headp; /* Do hardware assists */ - m_head = *m_headp; - if (ifp->if_hwassist > 0) { - if (em_tso_setup(adapter, m_head, &txd_upper, &txd_lower)) { + if (ifp->if_hwassist) { + if (do_tso && + em_tso_setup(adapter, m_head, &txd_upper, &txd_lower)) { /* we need to make a final sentinel transmit desc */ tso_desc = TRUE; } else @@ -1847,9 +1831,12 @@ if (ifp->if_flags & IFF_PROMISC) { reg_rctl |= (E1000_RCTL_UPE | E1000_RCTL_MPE); E1000_WRITE_REG(&adapter->hw, RCTL, reg_rctl); - /* Disable VLAN stripping in promiscous mode + /* + * Disable VLAN stripping in promiscous mode. * This enables bridging of vlan tagged frames to occur - * and also allows vlan tags to be seen in tcpdump + * and also allows vlan tags to be seen in tcpdump. + * XXX: This is a bit bogus as tcpdump may be used + * w/o promisc mode as well. */ if (ifp->if_capenable & IFCAP_VLAN_HWTAGGING) em_disable_vlans(adapter); @@ -2340,8 +2327,8 @@ /* Enable TSO if available */ if ((adapter->hw.mac_type > em_82544) && (adapter->hw.mac_type != em_82547)) { - ifp->if_capabilities |= IFCAP_TSO; - ifp->if_capenable |= IFCAP_TSO; + ifp->if_capabilities |= IFCAP_TSO4; + ifp->if_capenable |= IFCAP_TSO4; } /* @@ -2777,66 +2764,126 @@ { struct em_context_desc *TXD; struct em_buffer *tx_buffer; - int curr_txd; + struct ether_vlan_header *eh; + struct ip *ip; + struct ip6_hdr *ip6; + struct tcp_hdr *th; + int curr_txd, ehdrlen, hdr_len, ip_hlen; + uint32_t cmd = 0; + uint16_t etype; + uint8_t ipproto; - if (mp->m_pkthdr.csum_flags) { + /* Setup checksum offload context. */ + curr_txd = adapter->next_avail_tx_desc; + tx_buffer = &adapter->tx_buffer_area[curr_txd]; + TXD = (struct em_context_desc *) &adapter->tx_desc_base[curr_txd]; - if (mp->m_pkthdr.csum_flags & CSUM_TCP) { - *txd_upper = E1000_TXD_POPTS_TXSM << 8; - *txd_lower = E1000_TXD_CMD_DEXT | E1000_TXD_DTYP_D; - if (adapter->active_checksum_context == OFFLOAD_TCP_IP) - return; - else - adapter->active_checksum_context = OFFLOAD_TCP_IP; + *txd_lower = E1000_TXD_CMD_DEXT | /* Extended descr type */ + E1000_TXD_DTYP_D; /* Data descr */ - } else if (mp->m_pkthdr.csum_flags & CSUM_UDP) { - *txd_upper = E1000_TXD_POPTS_TXSM << 8; >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Fri Sep 29 14:15:43 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D538E16A4C8; Fri, 29 Sep 2006 14:15:42 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 A4F1A16A492 for ; Fri, 29 Sep 2006 14:15:42 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 232F343D6B for ; Fri, 29 Sep 2006 14:15:32 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TEFWKW083058 for ; Fri, 29 Sep 2006 14:15:32 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TEFVXR083052 for perforce@freebsd.org; Fri, 29 Sep 2006 14:15:31 GMT (envelope-from imp@freebsd.org) Date: Fri, 29 Sep 2006 14:15:31 GMT Message-Id: <200609291415.k8TEFVXR083052@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106892 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 14:15:43 -0000 http://perforce.freebsd.org/chv.cgi?CH=106892 Change 106892 by imp@imp_lighthouse on 2006/09/29 14:15:25 checkpoint cid/csd parsing. Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#9 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#10 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#9 (text+ko) ==== @@ -46,6 +46,16 @@ struct intr_config_hook config_intrhook; }; +/* + * Per-card data + */ +struct mmc_ivars { + uint32_t raw_cid[4]; /* Raw bits of the CID */ + uint32_t raw_csd[4]; /* Raw bits of the CSD */ + struct mmc_cid cid; + struct mmc_csd csd; +}; + #define CMD_RETRIES 3 /* bus entry points */ @@ -300,6 +310,52 @@ } static void +mmc_decode_cid(int is_sd, uint32_t *raw_cid, struct mmc_cid *cid) +{ + memset(cid, 0, sizeof(*cid)); + if (is_sd) { + /* There's no version info, so we take it on faith */ + cid->mid = mmc_get_bits(raw_cid, 120, 8); + cid->oid = mmc_get_bits(raw_cid, 104, 16); + for (i = 0; i < 5; i++) + cid->pnm[i] = mmc_get_bits(raw_cid, 96 - i * 8, 8); + cid->prv = mmc_get_bits(raw_cid, 56, 8); + cid->psn = mmc_get_bits(raw_cid, 24, 32); + cid->mdt_year = mmc_get_bits(raw_cid, 12, 8) + 2001; + cid->mdt_month = mmc_get_bits(raw_cid, 8, 4); + } else { + // XXX write me + panic("write mmc cid decoder"); + } +} + +static void +mmc_decode_csd(int is_sd, uint32_t *raw_csd, struct mmc_csd *csd) +{ + int v; + + memset(csd, 0, sizeof(*csd)); + if (is_sd) { + csd->csd_structure = v = mmc_get_bits(raw_csd, 126, 2); + if (v == 0) { + m = mmc_get_bits(raw_csd, 115, 4); + e = mmc_get_bits(raw_csd, 112, 3); + csd->tacc = tacc_exp[e] * tacc_mant[m] + 9 / 10; + csd->nsac = mmc_get_bits(raw_csd, 104, 8) * 100; + m = mmc_get_bits(raw_csd, 99, 4); + e = mmc_get_bits(raw_csd, 96, 3); + csd->tran_speed = tran_exp[e] * tran_mant[m]; + + } else if (v == 1) { + panic("Write SDHC CSD parser"); + } else + pacic("unknown SD CSD version"); + } else { + panic("Write a MMC CSD parser"); + } +} + +static void mmc_discover_cards(struct mmc_softc *sc) { #if 0 // XXX XXX XXX ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#10 (text+ko) ==== @@ -274,4 +274,33 @@ #define MMC_OCR_CCS (1u << 30) /* Card Capacity status (SD vs SDHC) */ #define MMC_OCR_CARD_BUSY (1U << 31) /* Card Power up status */ +/* CSD -- decoded structure */ +struct mmc_cid { + uint32_t mid; + char pnm[8]; + uint32_t psn; + uint16_t oid; + uint16_t mdt_year; + uint8_t mdt_month; + uint8_t prv; + uint8_t fwrev; +}; + +struct mmc_csd +{ + uint8_t csd_structure; + uint16_t cmdclass; + uint16_t tacc; + uint32_t nsac_clks; + uint32_t r2w_factor; + uint32_t tran_speed; + uint32_t read_blkbits; + uint32_t write_blkbits; + uint32_t capacity; + unsigned int read_partial:1, + read_misalign:1, + write_partial:1, + write_misalign:1; +}; + #endif /* DEV_MMCREG_H */ From owner-p4-projects@FreeBSD.ORG Fri Sep 29 14:31:54 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0300216A417; Fri, 29 Sep 2006 14:31:54 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 D329216A403 for ; Fri, 29 Sep 2006 14:31:53 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id A106043D4C for ; Fri, 29 Sep 2006 14:31:53 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TEVrCo084030 for ; Fri, 29 Sep 2006 14:31:53 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TEVrqM084027 for perforce@freebsd.org; Fri, 29 Sep 2006 14:31:53 GMT (envelope-from rdivacky@FreeBSD.org) Date: Fri, 29 Sep 2006 14:31:53 GMT Message-Id: <200609291431.k8TEVrqM084027@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106894 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 14:31:54 -0000 http://perforce.freebsd.org/chv.cgi?CH=106894 Change 106894 by rdivacky@rdivacky_witten on 2006/09/29 14:30:54 Remove unused variables. Affected files ... .. //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#7 edit Differences ... ==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#7 (text+ko) ==== @@ -635,7 +635,6 @@ if (args->flags & CLONE_SETTLS) { struct l_user_desc info; int idx; - struct segment_descriptor sd; error = copyin((void *)td->td_frame->tf_rsi, &info, sizeof(struct l_user_desc)); if (error) @@ -1184,7 +1183,6 @@ struct l_user_desc info; int error; int idx; - struct segment_descriptor sd; error = copyin(args->desc, &info, sizeof(struct l_user_desc)); if (error) From owner-p4-projects@FreeBSD.ORG Fri Sep 29 14:48:23 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6E34416A492; Fri, 29 Sep 2006 14:48:23 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 34E1A16A40F for ; Fri, 29 Sep 2006 14:48:23 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C986B43D70 for ; Fri, 29 Sep 2006 14:48:14 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TEmEFa084760 for ; Fri, 29 Sep 2006 14:48:14 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TEmEqn084757 for perforce@freebsd.org; Fri, 29 Sep 2006 14:48:14 GMT (envelope-from rdivacky@FreeBSD.org) Date: Fri, 29 Sep 2006 14:48:14 GMT Message-Id: <200609291448.k8TEmEqn084757@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106896 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 14:48:23 -0000 http://perforce.freebsd.org/chv.cgi?CH=106896 Change 106896 by rdivacky@rdivacky_witten on 2006/09/29 14:47:56 Size_t instead of int to let this compile on amd64. Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linux/linux_aio.c#7 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_aio.c#7 (text+ko) ==== @@ -475,7 +475,7 @@ static int mirror_native_aio_sysctl(struct thread *td) { int nerr = 0; - int l; + size_t l; l = sizeof(native_aio_capacity_proc); nerr = kernel_sysctlbyname(td, NATIVE_AIO_SYSCTL_CAPACITY_PROC, From owner-p4-projects@FreeBSD.ORG Fri Sep 29 18:54:31 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 7DA4B16A416; Fri, 29 Sep 2006 18:54:31 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 5934516A412 for ; Fri, 29 Sep 2006 18:54:31 +0000 (UTC) (envelope-from jmg@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2881943D45 for ; Fri, 29 Sep 2006 18:54:31 +0000 (GMT) (envelope-from jmg@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TIsV63035119 for ; Fri, 29 Sep 2006 18:54:31 GMT (envelope-from jmg@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TIsU2o035116 for perforce@freebsd.org; Fri, 29 Sep 2006 18:54:30 GMT (envelope-from jmg@freebsd.org) Date: Fri, 29 Sep 2006 18:54:30 GMT Message-Id: <200609291854.k8TIsU2o035116@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to jmg@freebsd.org using -f From: John-Mark Gurney To: Perforce Change Reviews Cc: Subject: PERFORCE change 106907 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 18:54:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=106907 Change 106907 by jmg@jmg_carbon-60 on 2006/09/29 18:54:04 fix spelling in comment.... Sponsered by: nCircle Network Security, Inc. Affected files ... .. //depot/projects/trustedbsd/priv/sys/sys/priv.h#4 edit Differences ... ==== //depot/projects/trustedbsd/priv/sys/sys/priv.h#4 (text+ko) ==== @@ -160,7 +160,7 @@ PRIV_VFS_CHROOT, /* chroot(). */ PRIV_VFS_CLEARSUGID, /* Don't clear sugid on change. */ PRIV_VFS_EXTATTR_SYSTEM, /* Operate on system EA namespace. */ - PRIV_VFS_FCHROOT, /* fchrot(). */ + PRIV_VFS_FCHROOT, /* fchroot(). */ PRIV_VFS_FHOPEN, /* Can fhopen(). */ PRIV_VFS_FHSTAT, /* Can fhstat(). */ PRIV_VFS_FHSTATFS, /* Can fhstatfs(). */ From owner-p4-projects@FreeBSD.ORG Fri Sep 29 22:02:32 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id E0D1616A416; Fri, 29 Sep 2006 22:02:31 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 BDC6716A403 for ; Fri, 29 Sep 2006 22:02:31 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id AF86943D6A for ; Fri, 29 Sep 2006 22:02:29 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TM2Tou058084 for ; Fri, 29 Sep 2006 22:02:29 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TM2Tib058081 for perforce@freebsd.org; Fri, 29 Sep 2006 22:02:29 GMT (envelope-from imp@freebsd.org) Date: Fri, 29 Sep 2006 22:02:29 GMT Message-Id: <200609292202.k8TM2Tib058081@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106917 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 22:02:32 -0000 http://perforce.freebsd.org/chv.cgi?CH=106917 Change 106917 by imp@imp_lighthouse on 2006/09/29 22:02:17 new config Affected files ... .. //depot/projects/arm/src/sys/arm/conf/TSC4370#10 edit Differences ... ==== //depot/projects/arm/src/sys/arm/conf/TSC4370#10 (text+ko) ==== @@ -43,11 +43,11 @@ #options MD_ROOT #MD is a potential root device #options MD_ROOT_SIZE=4096 # 4MB ram disk #options ROOTDEVNAME=\"ufs:md0\" -options NFSCLIENT #Network Filesystem Client +#options NFSCLIENT #Network Filesystem Client #options NFSSERVER #Network Filesystem Server -options NFS_ROOT #NFS usable as /, requires NFSCLIENT -options BOOTP_NFSROOT -options BOOTP +#options NFS_ROOT #NFS usable as /, requires NFSCLIENT +#options BOOTP_NFSROOT +#options BOOTP #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) From owner-p4-projects@FreeBSD.ORG Fri Sep 29 22:31:07 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id DA2F716A47B; Fri, 29 Sep 2006 22:31:06 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 9AEC516A403 for ; Fri, 29 Sep 2006 22:31:06 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0143343D73 for ; Fri, 29 Sep 2006 22:31:05 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TMV5Ix060462 for ; Fri, 29 Sep 2006 22:31:05 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TMV5Uv060459 for perforce@freebsd.org; Fri, 29 Sep 2006 22:31:05 GMT (envelope-from imp@freebsd.org) Date: Fri, 29 Sep 2006 22:31:05 GMT Message-Id: <200609292231.k8TMV5Uv060459@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106918 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 22:31:07 -0000 http://perforce.freebsd.org/chv.cgi?CH=106918 Change 106918 by imp@imp_lighthouse on 2006/09/29 22:30:13 After sending CMD55, make sure we get a R1_APP_CMD bit set in the reply (not cleared). set bus mode push-pull for sd detection (linux doesn't do this, but the boot blocks do and work) Re-add ocr check Debugging changes Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#10 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#10 (text+ko) ==== @@ -183,6 +183,7 @@ cmd->retries = retries; cmd->data = NULL; mreq.cmd = cmd; + printf("CMD: %x ARG %x\n", cmd->opcode, cmd->arg); mmc_wait_for_req(sc, &mreq); return (cmd->error); } @@ -202,7 +203,7 @@ err = appcmd.error; if (err != MMC_ERR_NONE) continue; - if (appcmd.resp[0] & R1_APP_CMD) + if (!(appcmd.resp[0] & R1_APP_CMD)) return MMC_ERR_FAILED; mmc_wait_for_cmd(sc, cmd, 0); err = cmd->error; @@ -247,9 +248,8 @@ cmd.arg = ocr; cmd.flags = MMC_RSP_R3 | MMC_CMD_BCR; - for (i = 0; i < 100; i++) { + for (i = 0; i < 10; i++) { err = mmc_wait_for_app_cmd(sc, 0, &cmd, CMD_RETRIES); - printf("err is %x busy is %x\n", err, cmd.resp[0]); if (err != MMC_ERR_NONE) break; if ((cmd.resp[0] & MMC_OCR_CARD_BUSY) || ocr == 0) @@ -259,7 +259,6 @@ } if (rocr && err == MMC_ERR_NONE) *rocr = cmd.resp[0]; - printf("app op sayz %x\n", cmd.resp[0]); return err; } @@ -309,6 +308,7 @@ mmc_ms_delay(2); } +#if 0 static void mmc_decode_cid(int is_sd, uint32_t *raw_cid, struct mmc_cid *cid) { @@ -354,6 +354,7 @@ panic("Write a MMC CSD parser"); } } +#endif static void mmc_discover_cards(struct mmc_softc *sc) @@ -404,6 +405,7 @@ // First, try SD modes mmcbr_set_mode(dev, mode_sd); mmc_power_up(sc); + mmcbr_set_bus_mode(dev, pushpull); mmc_idle_cards(sc); if (mmc_send_app_op_cond(sc, 0, &ocr) != MMC_ERR_NONE) { // Failed, try MMC @@ -426,8 +428,8 @@ * one card on the bus. */ printf("Oink %x!\n", mmcbr_get_ocr(dev)); -// if (mmcbr_get_ocr(dev) == 0) -// return; + if (mmcbr_get_ocr(dev) == 0) + return; /* XXX Linux re-sends op_cond command here */ mmc_discover_cards(sc); From owner-p4-projects@FreeBSD.ORG Fri Sep 29 22:34:13 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 0405C16A47B; Fri, 29 Sep 2006 22:34:13 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 D2DA016A407 for ; Fri, 29 Sep 2006 22:34:12 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3A91F43D58 for ; Fri, 29 Sep 2006 22:34:10 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TMYATu060587 for ; Fri, 29 Sep 2006 22:34:10 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TMY9bo060584 for perforce@freebsd.org; Fri, 29 Sep 2006 22:34:09 GMT (envelope-from imp@freebsd.org) Date: Fri, 29 Sep 2006 22:34:09 GMT Message-Id: <200609292234.k8TMY9bo060584@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106919 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 22:34:13 -0000 http://perforce.freebsd.org/chv.cgi?CH=106919 Change 106919 by imp@imp_lighthouse on 2006/09/29 22:34:05 Kill lots of debug When there's a clock, set the ENable bit, not the DISable bit (the hardware continues to kinda work when you do this!) tweak interrupt disabling # we now get OCR! Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#13 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#13 (text+ko) ==== @@ -284,7 +284,7 @@ WR4(sc, MCI_CR, MCI_CR_MCIDIS); clkdiv = 0; } else { - WR4(sc, MCI_CR, MCI_CR_MCIDIS); + WR4(sc, MCI_CR, MCI_CR_MCIEN); if ((at91_master_clock % (ios->clock * 2)) == 0) clkdiv = ((at91_master_clock / ios->clock) / 2) - 1; else @@ -342,6 +342,7 @@ cmdr |= MCI_CMDR_OPDCMD; if (!cmd->data) { at91_mci_pdc_disable(sc); + printf("CMDR %x ARGR %x\n", cmdr, cmd->arg); WR4(sc, MCI_ARGR, cmd->arg); WR4(sc, MCI_CMDR, cmdr); WR4(sc, MCI_IER, MCI_SR_ERROR | MCI_SR_CMDRDY); @@ -358,21 +359,16 @@ req = sc->req; // assert locked if (!(sc->flags & CMD_STARTED)) { - printf("Starting command %d of request %p\n", req->cmd->opcode, - req); sc->flags |= CMD_STARTED; at91_mci_start_cmd(sc, req->cmd); return; } if (!(sc->flags & STOP_STARTED) && req->stop) { - printf("Starting command %d of request %p\n", req->stop->opcode, - req); sc->flags |= STOP_STARTED; at91_mci_start_cmd(sc, req->stop); return; } /* We must be done -- bad idea to do this while locked? */ - printf("Finished request %p\n", req); sc->req = NULL; sc->curcmd = NULL; req->done(req->done_data); @@ -383,7 +379,6 @@ { struct at91_mci_softc *sc = device_get_softc(brdev); - printf("queuing request %p\n", req); AT91_MCI_LOCK(sc); // XXX do we want to be able to queue up multiple commands? // XXX sounds like a good idea, but all protocols are sync, so @@ -443,7 +438,6 @@ AT91_MCI_LOCK(sc); sr = RD4(sc, MCI_SR) & RD4(sc, MCI_IMR); printf("i 0x%x\n", sr); - WR4(sc, MCI_IDR, 0xffffffff); cmd = sc->curcmd; if (sr & MCI_SR_ERROR) { if ((sr & MCI_SR_RCRCE) && (cmd->opcode == MMC_SEND_OP_COND || @@ -497,7 +491,8 @@ } } if (done) { - if (cmd != NULL) { + WR4(sc, MCI_IDR, 0xffffffff); + if (cmd != NULL && (cmd->flags & MMC_RSP_PRESENT)) { for (i = 0; i < ((cmd->flags & MMC_RSP_136) ? 4 : 1); i++) { cmd->resp[i] = RD4(sc, MCI_RSPR + i * 4); From owner-p4-projects@FreeBSD.ORG Fri Sep 29 22:36:13 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id BBDF016A417; Fri, 29 Sep 2006 22:36:13 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 8D33916A403 for ; Fri, 29 Sep 2006 22:36:13 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4FC8E43D5A for ; Fri, 29 Sep 2006 22:36:13 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8TMaDbn060695 for ; Fri, 29 Sep 2006 22:36:13 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8TMaDh4060692 for perforce@freebsd.org; Fri, 29 Sep 2006 22:36:13 GMT (envelope-from imp@freebsd.org) Date: Fri, 29 Sep 2006 22:36:13 GMT Message-Id: <200609292236.k8TMaDh4060692@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106920 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Sep 2006 22:36:14 -0000 http://perforce.freebsd.org/chv.cgi?CH=106920 Change 106920 by imp@imp_lighthouse on 2006/09/29 22:36:10 Comments and whitespace nit Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_mci.c#14 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_mci.c#14 (text+ko) ==== @@ -440,7 +440,8 @@ printf("i 0x%x\n", sr); cmd = sc->curcmd; if (sr & MCI_SR_ERROR) { - if ((sr & MCI_SR_RCRCE) && (cmd->opcode == MMC_SEND_OP_COND || + // Ignore CRC errors on CMD2 and ACMD47, per relevant standards + if ((sr & MCI_SR_RCRCE) && (cmd->opcode == MMC_SEND_OP_COND || cmd->opcode == ACMD_SD_SEND_OP_COND)) cmd->error = MMC_ERR_NONE; else if (sr & (MCI_SR_RTOE | MCI_SR_DTOE)) From owner-p4-projects@FreeBSD.ORG Sat Sep 30 00:36:55 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id EA95B16A4EF; Sat, 30 Sep 2006 00:36:54 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 C2A5016A412 for ; Sat, 30 Sep 2006 00:36:54 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 663EC43D58 for ; Sat, 30 Sep 2006 00:36:52 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U0aqbp070979 for ; Sat, 30 Sep 2006 00:36:52 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U0apha070976 for perforce@freebsd.org; Sat, 30 Sep 2006 00:36:51 GMT (envelope-from imp@freebsd.org) Date: Sat, 30 Sep 2006 00:36:51 GMT Message-Id: <200609300036.k8U0apha070976@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 106924 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 00:36:55 -0000 http://perforce.freebsd.org/chv.cgi?CH=106924 Change 106924 by imp@imp_lighthouse on 2006/09/30 00:36:29 SD 1.x cards now properly detected (1.x means standard capacity and not the newer SDHC or SD 2.0 high capacity cards). Affected files ... .. //depot/projects/arm/src/sys/dev/mmc/mmc.c#11 edit .. //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#11 edit Differences ... ==== //depot/projects/arm/src/sys/dev/mmc/mmc.c#11 (text+ko) ==== @@ -52,8 +52,10 @@ struct mmc_ivars { uint32_t raw_cid[4]; /* Raw bits of the CID */ uint32_t raw_csd[4]; /* Raw bits of the CSD */ - struct mmc_cid cid; - struct mmc_csd csd; + uint16_t rca; + enum mmc_card_mode mode; + struct mmc_cid cid; /* cid decoded */ + struct mmc_csd csd; /* csd decoded */ }; #define CMD_RETRIES 3 @@ -308,10 +310,23 @@ mmc_ms_delay(2); } -#if 0 +// I wonder if the following is endian safe. +static uint32_t +mmc_get_bits(uint32_t *bits, int start, int size) +{ + const int i = 3 - (start / 32); + const int shift = start & 31; + uint32_t retval = bits[i] >> shift; + if (size + shift > 32) + retval |= bits[i - 1] << (32 - shift); + return retval & ((1 << size) - 1); +} + static void mmc_decode_cid(int is_sd, uint32_t *raw_cid, struct mmc_cid *cid) { + int i; + memset(cid, 0, sizeof(*cid)); if (is_sd) { /* There's no version info, so we take it on faith */ @@ -329,10 +344,25 @@ } } +static const int exp[8] = { + 1, 10, 100, 1000, 10000, 100000, 1000000, 10000000 +}; +static const int mant[16] = { + 10, 12, 13, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 70, 80 +}; +static const int cur_min[8] = { + 500, 1000, 5000, 10000, 25000, 35000, 60000, 100000 +}; +static const int cur_max[8] = { + 1000, 5000, 10000, 25000, 35000, 45000, 800000, 200000 +}; + static void mmc_decode_csd(int is_sd, uint32_t *raw_csd, struct mmc_csd *csd) { int v; + int m; + int e; memset(csd, 0, sizeof(*csd)); if (is_sd) { @@ -340,61 +370,114 @@ if (v == 0) { m = mmc_get_bits(raw_csd, 115, 4); e = mmc_get_bits(raw_csd, 112, 3); - csd->tacc = tacc_exp[e] * tacc_mant[m] + 9 / 10; + csd->tacc = exp[e] * mant[m] + 9 / 10; csd->nsac = mmc_get_bits(raw_csd, 104, 8) * 100; m = mmc_get_bits(raw_csd, 99, 4); e = mmc_get_bits(raw_csd, 96, 3); - csd->tran_speed = tran_exp[e] * tran_mant[m]; - + csd->tran_speed = exp[e] * 10000 * mant[m]; + csd->ccc = mmc_get_bits(raw_csd, 84, 12); + csd->read_bl_len = 1 << mmc_get_bits(raw_csd, 80, 4); + csd->read_bl_partial = mmc_get_bits(raw_csd, 79, 1); + csd->write_blk_misalign = mmc_get_bits(raw_csd, 78, 1); + csd->read_blk_misalign = mmc_get_bits(raw_csd, 77, 1); + csd->dsr_imp = mmc_get_bits(raw_csd, 76, 1); + csd->vdd_r_curr_min = cur_min[mmc_get_bits(raw_csd, 59, 3)]; + csd->vdd_r_curr_max = cur_max[mmc_get_bits(raw_csd, 56, 3)]; + csd->vdd_w_curr_min = cur_min[mmc_get_bits(raw_csd, 53, 3)]; + csd->vdd_w_curr_max = cur_max[mmc_get_bits(raw_csd, 50, 3)]; + m = mmc_get_bits(raw_csd, 62, 12); + e = mmc_get_bits(raw_csd, 47, 3); + csd->capacity = ((1 + m) << (e + 2)) * csd->read_bl_len; + csd->erase_blk_en = mmc_get_bits(raw_csd, 46, 1); + csd->sector_size = mmc_get_bits(raw_csd, 39, 7); + csd->wp_grp_size = mmc_get_bits(raw_csd, 32, 7); + csd->wp_grp_enable = mmc_get_bits(raw_csd, 31, 1); + csd->r2w_factor = 1 << mmc_get_bits(raw_csd, 26, 3); + csd->write_bl_len = 1 << mmc_get_bits(raw_csd, 22, 4); + csd->write_bl_partial = mmc_get_bits(raw_csd, 21, 1); } else if (v == 1) { panic("Write SDHC CSD parser"); } else - pacic("unknown SD CSD version"); + panic("unknown SD CSD version"); } else { panic("Write a MMC CSD parser"); } } -#endif + +static int +mmc_all_send_cid(struct mmc_softc *sc, uint32_t *rawcid) +{ + struct mmc_command cmd; + int err; + + cmd.opcode = MMC_ALL_SEND_CID; + cmd.arg = 0; + cmd.flags = MMC_RSP_R2 | MMC_CMD_BCR; + err = mmc_wait_for_cmd(sc, &cmd, 0); + memcpy(rawcid, cmd.resp, 4 * sizeof(uint32_t)); + return (err); +} + +static int +mmc_send_csd(struct mmc_softc *sc, uint16_t rca, uint32_t *rawcid) +{ + struct mmc_command cmd; + int err; + + cmd.opcode = MMC_SEND_CSD; + cmd.arg = rca << 16; + cmd.flags = MMC_RSP_R2 | MMC_CMD_BCR; + err = mmc_wait_for_cmd(sc, &cmd, 0); + memcpy(rawcid, cmd.resp, 4 * sizeof(uint32_t)); + return (err); +} + +static int +mmc_send_relative_addr(struct mmc_softc *sc, uint32_t *resp) +{ + struct mmc_command cmd; + int err; + + cmd.opcode = SD_SEND_RELATIVE_ADDR; + cmd.arg = 0; + cmd.flags = MMC_RSP_R6 | MMC_CMD_BCR; + err = mmc_wait_for_cmd(sc, &cmd, 0); + *resp = cmd.resp[0]; + return (err); +} static void mmc_discover_cards(struct mmc_softc *sc) { -#if 0 // XXX XXX XXX + struct mmc_ivars *ivar; + int err; + uint32_t resp; + while (1) { - err = mmc_all_send_cid(sc, &rca); - if (err == MMC_ERR_TIMEOUT) { - err = MMC_ERR_NONE; + ivar = malloc(sizeof(struct mmc_ivars), M_DEVBUF, M_WAITOK); + err = mmc_all_send_cid(sc, ivar->raw_cid); + if (err == MMC_ERR_TIMEOUT) break; - } if (err != MMC_ERR_NONE) { printf("Error reading CID %d\n", err); break; } - card = find_card(sc, rca); - if (host->mode == MMC_MODE_SD) { - mmc_card_set_sd(card); - mmc_send_relative_addr(sc, 0); - card->rca = cmd.resp[0] >> 16; + if (mmcbr_get_mode(sc->dev) == mode_sd) { + ivar->mode = mode_sd; + mmc_decode_cid(1, ivar->raw_cid, &ivar->cid); + mmc_send_relative_addr(sc, &resp); + ivar->rca = resp >> 16; // RO check + mmc_send_csd(sc, ivar->rca, ivar->raw_csd); + mmc_decode_csd(1, ivar->raw_csd, &ivar->csd); + printf("SD CARD: %lld bytes\n", ivar->csd.capacity); break; } - // MMC XXX card detection - // set relative addr + panic("Write MMC card code here"); } -#endif } static void -mmc_read_csds(struct mmc_softc *sc) -{ -} - -static void -mmc_read_scrs(struct mmc_softc *sc) -{ -} - -static void mmc_go_discovery(struct mmc_softc *sc) { uint32_t ocr; @@ -427,17 +510,19 @@ * Make sure that we have a mutually agreeable voltage to at least * one card on the bus. */ - printf("Oink %x!\n", mmcbr_get_ocr(dev)); if (mmcbr_get_ocr(dev) == 0) return; - /* XXX Linux re-sends op_cond command here */ + /* + * Reselect the cards after we've idled them above. + */ + if (mmcbr_get_mode(dev) == mode_sd) + mmc_send_app_op_cond(sc, mmcbr_get_ocr(dev), NULL); + else + mmc_send_op_cond(sc, mmcbr_get_ocr(dev), NULL); mmc_discover_cards(sc); mmcbr_set_bus_mode(dev, pushpull); mmcbr_update_ios(dev); - mmc_read_csds(sc); - if (mmcbr_get_mode(dev) == mode_sd) - mmc_read_scrs(sc); } static int ==== //depot/projects/arm/src/sys/dev/mmc/mmcreg.h#11 (text+ko) ==== @@ -148,6 +148,7 @@ #define MMC_SEND_OP_COND 1 #define MMC_ALL_SEND_CID 2 #define MMC_SET_RELATIVE_ADDR 3 +#define SD_SEND_RELATIVE_ADDR 3 #define MMC_SET_DSR 4 /* reserved: 5 */ #define MMC_SELECT_CARD 7 @@ -248,12 +249,19 @@ /* OCR bits */ -/* in SD 2.0 spec, bits 8-14 are now marked reserved */ -/* Low voltage in SD2.0 spec is bit 7, TBD voltage */ -/* Low voltage in MC 3.31 spec is bit 7, 1.65-1.95V */ -/* Linux has defines for lower bits down to 0, which were defined in prior */ -/* specs to MMC 3.31. 3.31 redefined them to be reserved and also said that */ -/* cards had to support the 2.7-3.6V. */ +/* + * in SD 2.0 spec, bits 8-14 are now marked reserved + * Low voltage in SD2.0 spec is bit 7, TBD voltage + * Low voltage in MC 3.31 spec is bit 7, 1.65-1.95V + * Specs prior to MMC 3.31 defined bits 0-7 as voltages down to 1.5V. + * 3.31 redefined them to be reserved and also said that cards had to + * support the 2.7-3.6V and fixed the OCR to be 0xfff8000 for high voltage + * cards. MMC 4.0 says that a dual voltage card responds with 0xfff8080. + * Looks like the fine-grained control of the voltage tolerance ranges + * was abandoned. + * + * The MMC_OCR_CCS appears to be valid for only SD cards. + */ #define MMC_OCR_LOW_VOLTAGE (1u << 7) /* Low Voltage Range -- tbd */ #define MMC_OCR_200_210 (1U << 8) /* Vdd voltage 2.00 ~ 2.10 */ #define MMC_OCR_210_220 (1U << 9) /* Vdd voltage 2.10 ~ 2.20 */ @@ -289,18 +297,27 @@ struct mmc_csd { uint8_t csd_structure; - uint16_t cmdclass; + uint16_t ccc; uint16_t tacc; - uint32_t nsac_clks; + uint32_t nsac; uint32_t r2w_factor; uint32_t tran_speed; - uint32_t read_blkbits; - uint32_t write_blkbits; - uint32_t capacity; - unsigned int read_partial:1, - read_misalign:1, - write_partial:1, - write_misalign:1; + uint32_t read_bl_len; + uint32_t write_bl_len; + uint32_t vdd_r_curr_min; + uint32_t vdd_r_curr_max; + uint32_t vdd_w_curr_min; + uint32_t vdd_w_curr_max; + uint32_t wp_grp_size; + uint32_t sector_size; /* Erase sector size! */ + uint64_t capacity; + unsigned int read_bl_partial:1, + read_blk_misalign:1, + write_bl_partial:1, + write_blk_misalign:1, + dsr_imp:1, + erase_blk_en:1, + wp_grp_enable:1; }; #endif /* DEV_MMCREG_H */ From owner-p4-projects@FreeBSD.ORG Sat Sep 30 08:07:33 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3D73E16A47B; Sat, 30 Sep 2006 08:07:33 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 18E9416A412 for ; Sat, 30 Sep 2006 08:07:33 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 348F443D6E for ; Sat, 30 Sep 2006 08:07:31 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U87VQ8024628 for ; Sat, 30 Sep 2006 08:07:31 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U87Uuc024625 for perforce@freebsd.org; Sat, 30 Sep 2006 08:07:30 GMT (envelope-from rdivacky@FreeBSD.org) Date: Sat, 30 Sep 2006 08:07:30 GMT Message-Id: <200609300807.k8U87Uuc024625@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106945 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 08:07:33 -0000 http://perforce.freebsd.org/chv.cgi?CH=106945 Change 106945 by rdivacky@rdivacky_witten on 2006/09/30 08:06:39 Setting TLS in the calling thread doesnt make sense. Set TLS in the newly created one. Affected files ... .. //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#8 edit Differences ... ==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_machdep.c#8 (text+ko) ==== @@ -661,7 +661,7 @@ /* this is taken from amd64 version of cpu_set_user_tls() */ critical_enter(); /* set %gs */ - td->td_pcb->pcb_gsbase = (register_t)info.base_addr; + td2->td_pcb->pcb_gsbase = (register_t)info.base_addr; #if 0 wrmsr(MSR_KGSBASE, td->td_pcb->pcb_fsbase); #endif From owner-p4-projects@FreeBSD.ORG Sat Sep 30 08:13:43 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6B3A516A4E2; Sat, 30 Sep 2006 08:13:43 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 313EA16A415 for ; Sat, 30 Sep 2006 08:13:43 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1DC9643D46 for ; Sat, 30 Sep 2006 08:13:42 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U8Df79025214 for ; Sat, 30 Sep 2006 08:13:41 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U8DfFV025211 for perforce@freebsd.org; Sat, 30 Sep 2006 08:13:41 GMT (envelope-from soc-andrew@freebsd.org) Date: Sat, 30 Sep 2006 08:13:41 GMT Message-Id: <200609300813.k8U8DfFV025211@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106949 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 08:13:43 -0000 http://perforce.freebsd.org/chv.cgi?CH=106949 Change 106949 by soc-andrew@soc-andrew_serv on 2006/09/30 08:12:59 Update the customised parts of the BSDInstaller to work with the new snapshot Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/conf/FreeBSD.lua#7 edit .. //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/inst/430_select_dists.lua#4 edit .. //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/inst/432_kernel.lua#2 edit .. //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/inst/435_ports.lua#3 edit Differences ... ==== //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/conf/FreeBSD.lua#7 (text+ko) ==== @@ -1,13 +1,13 @@ -- -- conf/FreeBSD.lua --- $Id: FreeBSD.lua,v 1.8 2006/05/16 01:59:54 sullrich Exp $ +-- $Id: FreeBSD.lua,v 1.11 2006/09/04 18:01:33 cpressey Exp $ -- -- This file contains FreeBSD-specific overrides to BSDInstaller.lua. -- os = { name = "FreeBSD", - version = "6.0" + version = "7.0" } install_items = {} @@ -74,5 +74,7 @@ disklabel_on_disk = false has_softupdates = true window_subpartitions = { "c" } +needs_makedev = false +disklabel_offset = 16 use_cpdup = false use_tar = true ==== //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/inst/430_select_dists.lua#4 (text+ko) ==== @@ -2,11 +2,11 @@ -- -- Allows the user to select what dists they want to install on their machine -return { - id = "select_dists", - name = _("Select Distribution"), - req_state = { "source", "sel_pkgs" }, - effect = function(step) +id = "select_dists" +name = _("Select Distribution") +req_state = { "source", "sel_pkgs" } + +effect = function(step) local datasets = {} for item in App.conf.install_items_orig do table.insert(datasets, { @@ -99,5 +99,4 @@ else return step:prev() end - end -} +end ==== //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/inst/432_kernel.lua#2 (text+ko) ==== @@ -1,14 +1,11 @@ -- $FreeBSD$ -local Pty = require("pty") -local POSIX = require("posix") - -- -- Allows the user to select what kernels they want to install on their machine -return { - id = "select_kernels", - name = _("Select Kernel"), - effect = function(step) +id = "select_kernels" +name = _("Select Kernel") + +effect = function(step) local datasets = {} local output @@ -82,4 +79,3 @@ return step:prev() end end -} ==== //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/inst/435_ports.lua#3 (text+ko) ==== @@ -31,11 +31,11 @@ -- $FreeBSD$ -return { - id = "ports", - name = _("Install the Ports collection?"), - req_state = { "source", "sel_pkgs" }, - effect = function(step) +id = "ports" +name = _("Install the Ports collection?") +req_state = { "source", "sel_pkgs" } + +effect = function(step) local response = App.ui:present({ id = "install_ports", name = _("Install Ports collection"), @@ -65,5 +65,4 @@ else return step:prev() end - end -} +end From owner-p4-projects@FreeBSD.ORG Sat Sep 30 08:14:45 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D662216A415; Sat, 30 Sep 2006 08:14:44 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 6CF9716A407 for ; Sat, 30 Sep 2006 08:14:44 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0165743D4C for ; Sat, 30 Sep 2006 08:14:44 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U8EhUZ025279 for ; Sat, 30 Sep 2006 08:14:43 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U8Eh1f025276 for perforce@freebsd.org; Sat, 30 Sep 2006 08:14:43 GMT (envelope-from soc-andrew@freebsd.org) Date: Sat, 30 Sep 2006 08:14:43 GMT Message-Id: <200609300814.k8U8Eh1f025276@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106950 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 08:14:45 -0000 http://perforce.freebsd.org/chv.cgi?CH=106950 Change 106950 by soc-andrew@soc-andrew_serv on 2006/09/30 08:14:31 Update the Makefiles to the new file names. Export require for some of the custom steps Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/main.lua#5 edit .. //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/base/Makefile#4 edit .. //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/lib/Makefile#3 edit Differences ... ==== //depot/projects/soc2005/bsdinstaller/src/contrib/bsdinstaller/backend/lua/main.lua#5 (text+ko) ==== @@ -201,6 +201,7 @@ print = print, pairs = pairs, ipairs = ipairs, + require = require, table = table, string = string } ==== //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/base/Makefile#4 (text+ko) ==== @@ -1,6 +1,7 @@ NOOBJ= -FILES= 200_install.lua 400_configure.lua 950_reboot.lua main.lua +FILES= 200_install.lua 400_configure.lua 500_create_geom_mirror.lua \ + 950_reboot.lua main.lua FILESDIR= ${INST_DIR} ==== //depot/projects/soc2005/bsdinstaller/src/libexec/bsdinstaller/lib/Makefile#3 (text+ko) ==== @@ -1,9 +1,13 @@ NOOBJ= -FILES= bitwise.lua cmdchain.lua configvars.lua flow.lua menu.lua \ - network.lua network_ui.lua package.lua package_ui.lua \ - storage.lua storage_ui.lua target_system.lua \ - target_system_ui.lua uinav.lua +FILES= Bitwise.lua Capacity.lua CmdChain.lua ConfigFile.lua Disk.lua \ + DiskUI.lua Flow.lua FlowStep.lua Installation.lua \ + InstallationUI.lua Menu.lua MenuItem.lua NavContainer.lua \ + NavLeaf.lua Network.lua NetworkUI.lua Package.lua \ + PackageGraph.lua PackageList.lua PackageSet.lua PackageUI.lua \ + Partition.lua PartitionUI.lua StorageSystem.lua \ + StorageSystemUI.lua Subpartition.lua + FILESDIR= ${INST_DIR}/lib From owner-p4-projects@FreeBSD.ORG Sat Sep 30 08:56:42 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2C8DE16A412; Sat, 30 Sep 2006 08:56:42 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 01DC916A40F for ; Sat, 30 Sep 2006 08:56:42 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B0C6543D4C for ; Sat, 30 Sep 2006 08:56:41 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U8ufCK035661 for ; Sat, 30 Sep 2006 08:56:41 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U8uf0Q035658 for perforce@freebsd.org; Sat, 30 Sep 2006 08:56:41 GMT (envelope-from rdivacky@FreeBSD.org) Date: Sat, 30 Sep 2006 08:56:41 GMT Message-Id: <200609300856.k8U8uf0Q035658@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106959 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 08:56:42 -0000 http://perforce.freebsd.org/chv.cgi?CH=106959 Change 106959 by rdivacky@rdivacky_witten on 2006/09/30 08:56:19 change if (cond) panic() to KASSERT. Suggested by: ssouhlal Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linux/linux_emul.c#2 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_emul.c#2 (text+ko) ==== @@ -97,8 +97,7 @@ LIST_INIT(&s->threads); } p = pfind(child); - if (p == NULL) - panic("process not found in proc_init\n"); + KASSERT(p != NULL, ("process not found in proc_init\n")); p->p_emuldata = em; PROC_UNLOCK(p); EMUL_LOCK(&emul_lock); From owner-p4-projects@FreeBSD.ORG Sat Sep 30 08:57:48 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 31C8A16A40F; Sat, 30 Sep 2006 08:57:48 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 0E32F16A403 for ; Sat, 30 Sep 2006 08:57:48 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 06BDC43D76 for ; Sat, 30 Sep 2006 08:57:43 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U8vhSi035752 for ; Sat, 30 Sep 2006 08:57:43 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U8vhUN035749 for perforce@freebsd.org; Sat, 30 Sep 2006 08:57:43 GMT (envelope-from rdivacky@FreeBSD.org) Date: Sat, 30 Sep 2006 08:57:43 GMT Message-Id: <200609300857.k8U8vhUN035749@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106961 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 08:57:48 -0000 http://perforce.freebsd.org/chv.cgi?CH=106961 Change 106961 by rdivacky@rdivacky_witten on 2006/09/30 08:57:41 Dont forget to free em in a case of error. Suggested by: ssouhlal Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linux/linux_emul.c#3 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_emul.c#3 (text+ko) ==== @@ -181,8 +181,10 @@ int null = 0; error = copyout(&null, child_clear_tid, sizeof(null)); - if (error) + if (error) { + free(em, M_LINUX); return; + } /* futexes stuff */ cup.uaddr = child_clear_tid; From owner-p4-projects@FreeBSD.ORG Sat Sep 30 09:09:00 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2269916A415; Sat, 30 Sep 2006 09:09:00 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 C224316A407 for ; Sat, 30 Sep 2006 09:08:59 +0000 (UTC) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8CC6243D46 for ; Sat, 30 Sep 2006 09:08:59 +0000 (GMT) (envelope-from soc-andrew@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U98xIW037957 for ; Sat, 30 Sep 2006 09:08:59 GMT (envelope-from soc-andrew@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U98xlL037954 for perforce@freebsd.org; Sat, 30 Sep 2006 09:08:59 GMT (envelope-from soc-andrew@freebsd.org) Date: Sat, 30 Sep 2006 09:08:59 GMT Message-Id: <200609300908.k8U98xlL037954@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to soc-andrew@freebsd.org using -f From: soc-andrew To: Perforce Change Reviews Cc: Subject: PERFORCE change 106964 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 09:09:00 -0000 http://perforce.freebsd.org/chv.cgi?CH=106964 Change 106964 by soc-andrew@soc-andrew_serv on 2006/09/30 09:08:44 Update the start script for the new file names in the lua port Affected files ... .. //depot/projects/soc2005/bsdinstaller/src/release/bsdinstaller/bsdinstaller_shell.sh#12 edit Differences ... ==== //depot/projects/soc2005/bsdinstaller/src/release/bsdinstaller/bsdinstaller_shell.sh#12 (text+ko) ==== @@ -1,5 +1,7 @@ #!/bin/sh +LUA_VER="5.0" +LUA_LIBS="-lcompat-5.1" TTY=`tty` if [ -f /.do_reboot ] @@ -10,21 +12,22 @@ if [ ${TTY} = "/dev/ttyv0" ] then -# /usr/sbin/bsd_installer_ncurses + # Run the frontend on ttyv0 /usr/local/bin/dfuife_curses elif [ ${TTY} = "/dev/ttyv1" ] then - export LD_PRELOAD="/usr/local/lib/liblua.so;/usr/local/lib/liblualib.so;/usr/lib/libm.so" - export LUA_PATH="/usr/local/share/lua/5.0/?.lua;/usr/lib/lua/?.lua;/usr/libexec/bsdinstaller/lib/?.lua" - export LUA_CPATH="/usr/local/lib/lua/5.0/?.so;/usr/lib/lua/?.so" - export LUA_SOPATH=/usr/local/lib/lua/5.0/ - lua -lcompat-5.1 /usr/libexec/bsdinstaller/main.lua \ + # Run the backend on ttyv1 + export LD_PRELOAD="/usr/local/lib/liblua-${LUA_VER}.so;/usr/local/lib/liblualib-${LUA_VER}.so;/usr/lib/libm.so" + export LUA_PATH="/usr/local/share/lua/${LUA_VER}/?.lua;/usr/lib/lua/?.lua;/usr/libexec/bsdinstaller/lib/?.lua" + export LUA_CPATH="/usr/local/lib/lua/${LUA_VER}/?.so;/usr/lib/lua/?.so" + export LUA_SOPATH=/usr/local/lib/lua/${LUA_VER}/ + lua-${LUA_VER} ${LUA_LIBS} /usr/libexec/bsdinstaller/main.lua \ /usr/libexec/bsdinstaller/conf/BSDInstaller.lua \ /usr/libexec/bsdinstaller/conf/FreeBSD.lua dir.root=/ \ booted_from_install_media=true if [ $? -eq 5 ] then -# The backend returned the reboot value + # The backend returned the reboot value shutdown -r now touch /.do_reboot fi From owner-p4-projects@FreeBSD.ORG Sat Sep 30 09:36:38 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id B92AE16A416; Sat, 30 Sep 2006 09:36:38 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 924DF16A403 for ; Sat, 30 Sep 2006 09:36:38 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 60E3F43D49 for ; Sat, 30 Sep 2006 09:36:38 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U9acmg039361 for ; Sat, 30 Sep 2006 09:36:38 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U9abJb039358 for perforce@freebsd.org; Sat, 30 Sep 2006 09:36:37 GMT (envelope-from rdivacky@FreeBSD.org) Date: Sat, 30 Sep 2006 09:36:37 GMT Message-Id: <200609300936.k8U9abJb039358@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106967 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 09:36:39 -0000 http://perforce.freebsd.org/chv.cgi?CH=106967 Change 106967 by rdivacky@rdivacky_witten on 2006/09/30 09:36:25 Check the status of the options before messing with it. Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linux/linux_misc.c#4 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_misc.c#4 (text+ko) ==== @@ -795,6 +795,12 @@ printf(ARGS(waitpid, "%d, %p, %d"), args->pid, (void *)args->status, args->options); #endif + /* + * this is necessary because the test in kern_wait doesnt + * work because we mess with the options here + */ + if (args->options &~ (WUNTRACED|WNOHANG|WCONTINUED)) + return (EINVAL); options = (args->options & (WNOHANG | WUNTRACED)); /* WLINUXCLONE should be equal to __WCLONE, but we make sure */ From owner-p4-projects@FreeBSD.ORG Sat Sep 30 09:49:58 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 79F9616A417; Sat, 30 Sep 2006 09:49:58 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 5461F16A403 for ; Sat, 30 Sep 2006 09:49:58 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0E43843D49 for ; Sat, 30 Sep 2006 09:49:58 +0000 (GMT) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8U9nvUl040150 for ; Sat, 30 Sep 2006 09:49:57 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8U9nvcv040147 for perforce@freebsd.org; Sat, 30 Sep 2006 09:49:57 GMT (envelope-from rdivacky@FreeBSD.org) Date: Sat, 30 Sep 2006 09:49:57 GMT Message-Id: <200609300949.k8U9nvcv040147@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 106970 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 09:49:58 -0000 http://perforce.freebsd.org/chv.cgi?CH=106970 Change 106970 by rdivacky@rdivacky_witten on 2006/09/30 09:49:27 Implement /proc/sys/kernel/pid_max. Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linprocfs/linprocfs.c#2 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linprocfs/linprocfs.c#2 (text+ko) ==== @@ -925,6 +925,17 @@ } /* + * Filler function for proc/pid_max + */ +static int +linprocfs_dopid_max(PFS_FILL_ARGS) +{ + sbuf_printf(sb, "%i\n", PID_MAX); + + return (0); +} + +/* * Filler function for proc/scsi/device_info */ static int @@ -1063,6 +1074,14 @@ NULL, NULL, PFS_RD); pfs_create_file(dir, "scsi", &linprocfs_doscsiscsi, NULL, NULL, PFS_RD); + + /* /proc/sys/... */ + dir = pfs_create_dir(root, "sys", NULL, NULL, 0); + /* /proc/sys/kernel/... */ + dir = pfs_create_dir(dir, "kernel", NULL, NULL, 0); + pfs_create_file(dir, "pid_max", &linprocfs_dopid_max, + NULL, NULL, PFS_RD); + return (0); } From owner-p4-projects@FreeBSD.ORG Sat Sep 30 13:29:15 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 1346116A416; Sat, 30 Sep 2006 13:29:15 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 CBAA716A412 for ; Sat, 30 Sep 2006 13:29:14 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9257943D8B for ; Sat, 30 Sep 2006 13:28:46 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UDSjLZ065285 for ; Sat, 30 Sep 2006 13:28:45 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UDSZJu065269 for perforce@freebsd.org; Sat, 30 Sep 2006 13:28:35 GMT (envelope-from piso@freebsd.org) Date: Sat, 30 Sep 2006 13:28:35 GMT Message-Id: <200609301328.k8UDSZJu065269@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 106980 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 13:29:15 -0000 http://perforce.freebsd.org/chv.cgi?CH=106980 Change 106980 by piso@piso_newluxor on 2006/09/30 13:27:40 IFC@106979 Affected files ... .. //depot/projects/soc2005/libalias/ObsoleteFiles.inc#7 integrate .. //depot/projects/soc2005/libalias/UPDATING#8 integrate .. //depot/projects/soc2005/libalias/bin/cp/cp.c#4 integrate .. //depot/projects/soc2005/libalias/contrib/ntp/include/ntp_stdlib.h#2 integrate .. //depot/projects/soc2005/libalias/contrib/ntp/include/ntpd.h#2 integrate .. //depot/projects/soc2005/libalias/contrib/telnet/telnet/telnet.1#3 integrate .. //depot/projects/soc2005/libalias/etc/defaults/rc.conf#7 integrate .. //depot/projects/soc2005/libalias/etc/rc.d/mrouted#2 integrate .. //depot/projects/soc2005/libalias/games/fortune/datfiles/limerick#2 integrate .. //depot/projects/soc2005/libalias/games/fortune/datfiles/startrek#2 integrate .. //depot/projects/soc2005/libalias/lib/libalias/Makefile#8 integrate .. //depot/projects/soc2005/libalias/lib/libc/gen/err.3#2 integrate .. //depot/projects/soc2005/libalias/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#10 integrate .. //depot/projects/soc2005/libalias/sbin/ipfw/ipfw2.c#10 integrate .. //depot/projects/soc2005/libalias/sbin/newfs/mkfs.c#2 integrate .. //depot/projects/soc2005/libalias/share/examples/mdoc/example.4#4 integrate .. //depot/projects/soc2005/libalias/share/examples/mdoc/example.9#2 integrate .. //depot/projects/soc2005/libalias/share/examples/scsi_target/scsi_cmds.c#2 integrate .. //depot/projects/soc2005/libalias/share/examples/scsi_target/scsi_target.c#2 integrate .. //depot/projects/soc2005/libalias/share/examples/scsi_target/scsi_target.h#2 integrate .. //depot/projects/soc2005/libalias/share/man/man4/bge.4#3 integrate .. //depot/projects/soc2005/libalias/share/man/man4/ip6.4#2 integrate .. //depot/projects/soc2005/libalias/share/man/man4/man4.i386/wl.4#2 integrate .. //depot/projects/soc2005/libalias/share/man/man5/rc.conf.5#5 integrate .. //depot/projects/soc2005/libalias/share/mk/bsd.info.mk#2 integrate .. //depot/projects/soc2005/libalias/sys/amd64/amd64/local_apic.c#4 integrate .. //depot/projects/soc2005/libalias/sys/boot/common/merge_help.awk#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/common/panic.c#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/ficl/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/Makefile.inc#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/btx/btx/btx.S#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/libi386/biospci.c#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/libi386/biossmap.c#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/libi386/bootinfo64.c#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/libi386/elf64_freebsd.c#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/libi386/libi386.h#2 integrate .. //depot/projects/soc2005/libalias/sys/boot/i386/loader/help.i386#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/atkbdc/atkbd.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/digi/digi.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/em/if_em.c#11 integrate .. //depot/projects/soc2005/libalias/sys/dev/kbdmux/kbdmux.c#5 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/midi/sequencer.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pci/ak452x.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pci/ak452x.h#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pci/envy24ht.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/sound/pci/envy24ht.h#1 branch .. //depot/projects/soc2005/libalias/sys/dev/sound/pci/spicds.c#1 branch .. //depot/projects/soc2005/libalias/sys/dev/sound/pci/spicds.h#1 branch .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/ac97.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/ac97_patch.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/ac97_patch.h#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/channel.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/dsp.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/mixer.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/mixer.h#4 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/pcm/sound.h#4 integrate .. //depot/projects/soc2005/libalias/sys/dev/sound/usb/uaudio_pcm.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/syscons/scvidctl.c#2 integrate .. //depot/projects/soc2005/libalias/sys/dev/syscons/syscons.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/uart/uart_kbd_sun.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/usb/ukbd.c#3 integrate .. //depot/projects/soc2005/libalias/sys/dev/vkbd/vkbd.c#2 integrate .. //depot/projects/soc2005/libalias/sys/fs/procfs/procfs_ioctl.c#2 integrate .. //depot/projects/soc2005/libalias/sys/geom/eli/g_eli.c#4 integrate .. //depot/projects/soc2005/libalias/sys/geom/eli/g_eli_ctl.c#4 integrate .. //depot/projects/soc2005/libalias/sys/geom/label/g_label_msdosfs.c#3 integrate .. //depot/projects/soc2005/libalias/sys/geom/label/g_label_msdosfs.h#2 integrate .. //depot/projects/soc2005/libalias/sys/geom/nop/g_nop.h#3 integrate .. //depot/projects/soc2005/libalias/sys/geom/raid3/g_raid3.c#5 integrate .. //depot/projects/soc2005/libalias/sys/i386/i386/local_apic.c#4 integrate .. //depot/projects/soc2005/libalias/sys/i386/i386/machdep.c#6 integrate .. //depot/projects/soc2005/libalias/sys/kern/kern_proc.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/sys_generic.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/tty.c#4 integrate .. //depot/projects/soc2005/libalias/sys/kern/tty_pts.c#2 integrate .. //depot/projects/soc2005/libalias/sys/kern/tty_pty.c#3 integrate .. //depot/projects/soc2005/libalias/sys/kern/tty_tty.c#3 integrate .. //depot/projects/soc2005/libalias/sys/modules/digi/digi/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/modules/if_tap/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/modules/kbdmux/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/modules/libalias/Makefile#9 integrate .. //depot/projects/soc2005/libalias/sys/modules/procfs/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/modules/ukbd/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/modules/vkbd/Makefile#2 integrate .. //depot/projects/soc2005/libalias/sys/net/if_tap.c#3 integrate .. //depot/projects/soc2005/libalias/sys/net/if_tap.h#2 integrate .. //depot/projects/soc2005/libalias/sys/netgraph/atm/ccatm/ng_ccatm.c#2 integrate .. //depot/projects/soc2005/libalias/sys/netinet/in.c#2 integrate .. //depot/projects/soc2005/libalias/sys/netinet/in_var.h#3 integrate .. //depot/projects/soc2005/libalias/sys/netinet/ip_mroute.c#2 integrate .. //depot/projects/soc2005/libalias/sys/netinet/ip_mroute.h#2 integrate .. //depot/projects/soc2005/libalias/sys/netinet/ip_output.c#6 integrate .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_pptp.c#13 edit .. //depot/projects/soc2005/libalias/sys/netinet/tcp_output.c#3 integrate .. //depot/projects/soc2005/libalias/sys/netinet/tcp_subr.c#6 integrate .. //depot/projects/soc2005/libalias/sys/netinet6/ip6_mroute.h#2 integrate .. //depot/projects/soc2005/libalias/sys/pc98/cbus/pckbd.c#2 integrate .. //depot/projects/soc2005/libalias/sys/pc98/pc98/machdep.c#3 integrate .. //depot/projects/soc2005/libalias/sys/sys/consio.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/digiio.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/ioccom.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/kbio.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/param.h#8 integrate .. //depot/projects/soc2005/libalias/sys/sys/pioctl.h#2 integrate .. //depot/projects/soc2005/libalias/sys/sys/ttycom.h#2 integrate .. //depot/projects/soc2005/libalias/sys/vm/vm_page.c#6 integrate .. //depot/projects/soc2005/libalias/tools/tools/find-sb/Makefile#2 integrate .. //depot/projects/soc2005/libalias/tools/tools/find-sb/find-sb.c#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/calendar/calendars/calendar.freebsd#5 integrate .. //depot/projects/soc2005/libalias/usr.bin/du/du.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/file/magic.5#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/find/find.1#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/locate/locate/locate.1#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/logger/logger.1#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/login/login.1#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/lorder/lorder.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/make/make.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/mktemp/mktemp.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/mkuzip/mkuzip.8#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/netstat/mroute.c#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/netstat/mroute6.c#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/netstat/netstat.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/split/split.1#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/su/su.1#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/su/su.c#3 integrate .. //depot/projects/soc2005/libalias/usr.bin/tftp/tftp.c#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/time/time.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/truncate/truncate.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/truss/truss.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/vmstat/vmstat.8#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/whois/whois.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/xargs/xargs.1#2 integrate .. //depot/projects/soc2005/libalias/usr.bin/xinstall/install.1#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/Makefile#6 integrate .. //depot/projects/soc2005/libalias/usr.sbin/adduser/adduser.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/arp/arp.4#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/arp/arp.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/asf/asf.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/asf/asf.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/crunch/crunchgen/crunchgen.1#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/crunch/examples/really-big.conf#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/devinfo/devinfo.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/devinfo/devinfo.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/gstat/gstat.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/iostat/iostat.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/jail/jail.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/jexec/jexec.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/jexec/jexec.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/kbdcontrol/kbdcontrol.1#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/mailwrapper/mailwrapper.8#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/moused/moused.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/LICENSE#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/Makefile.inc#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/RELEASE#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/VERSION#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/callout.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/cfparse.y#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/common/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/config.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/defs.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/dvmrp.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/icmp.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/igmp.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/igmpv2.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/inet.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/ipip.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/kern.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/main.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/map-mbone.8#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/map-mbone/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mapper.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mrinfo.8#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mrinfo.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mrinfo/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mrouted.8#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mrouted.conf#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mrouted/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mtrace.8#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mtrace.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mtrace.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/mtrace/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/pathnames.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/prune.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/prune.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/route.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/route.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/rsrr.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/rsrr.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/rsrr_var.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/testrsrr/Makefile#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/testrsrr/testrsrr.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/vif.c#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mrouted/vif.h#2 delete .. //depot/projects/soc2005/libalias/usr.sbin/mtree/mtree.8#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/newsyslog/newsyslog.conf.5#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/ntp/doc/ntp.conf.5#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/ntp/doc/ntpd.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/ntp/doc/ntpdc.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/ntp/doc/ntpq.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/pkg_install/add/main.c#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/pkg_install/create/main.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/pkg_install/info/pkg_info.1#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/pmcstat/pmcstat.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/pmcstat/pmcstat.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/portsnap/portsnap/portsnap.8#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/syslogd/syslog.conf.5#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/syslogd/syslogd.c#2 integrate .. //depot/projects/soc2005/libalias/usr.sbin/watchdogd/watchdog.8#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/watchdogd/watchdogd.8#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/wpa/hostapd/hostapd.conf.5#3 integrate .. //depot/projects/soc2005/libalias/usr.sbin/wpa/ndis_events/ndis_events.8#2 integrate Differences ... ==== //depot/projects/soc2005/libalias/ObsoleteFiles.inc#7 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/ObsoleteFiles.inc,v 1.51 2006/09/24 10:57:34 simon Exp $ +# $FreeBSD: src/ObsoleteFiles.inc,v 1.53 2006/09/29 10:39:23 bms Exp $ # # This file lists old files (OLD_FILES), libraries (OLD_LIBS) and # directories (OLD_DIRS) which should get removed at an update. Recently @@ -14,9 +14,20 @@ # The file is partitioned: OLD_FILES first, then OLD_LIBS and OLD_DIRS last. # +# 20060929: mrouted removed +OLD_FILES+=usr/sbin/map-mbone +OLD_FILES+=usr/sbin/mrinfo +OLD_FILES+=usr/sbin/mrouted +OLD_FILES+=usr/sbin/mtrace +OLD_FILES+=usr/share/man/man8/map-mbone.8.gz +OLD_FILES+=usr/share/man/man8/mrinfo.8.gz +OLD_FILES+=usr/share/man/man8/mrouted.8.gz +OLD_FILES+=usr/share/man/man8/mtrace.8.gz # 20060924: tcpslice removed OLD_FILES+=usr/sbin/tcpslice OLD_FILES+=usr/share/man/man1/tcpslice.1.gz +# 20060829: kvmdb cleanup script removed +OLD_FILES+=etc/periodic/weekly/120.clean-kvmdb # 20060822: ramdisk{,-own} have been replaced by mdconfig{,2} OLD_FILES+=etc/rc.d/ramdisk OLD_FILES+=etc/rc.d/ramdisk-own ==== //depot/projects/soc2005/libalias/UPDATING#8 (text+ko) ==== @@ -21,6 +21,17 @@ developers choose to disable these features on build machines to maximize performance. +20060929: + mrouted and its utilities have been removed from the base system. + +20060924: + tcpslice has been removed from the base system. + +20060913: + The sizes of struct tcpcb (and struct xtcpcb) have changed due to + the rewrite of TCP syncookies. Tools like netstat, sockstat, and + systat needs to be rebuilt. + 20060903: libpcap updated to v0.9.4 and tcpdump to v3.9.4 @@ -613,4 +624,4 @@ Contact Warner Losh if you have any questions about your use of this document. -$FreeBSD: src/UPDATING,v 1.456 2006/09/18 11:24:25 maxim Exp $ +$FreeBSD: src/UPDATING,v 1.459 2006/09/29 10:39:23 bms Exp $ ==== //depot/projects/soc2005/libalias/bin/cp/cp.c#4 (text+ko) ==== @@ -42,7 +42,7 @@ #endif /* not lint */ #endif #include -__FBSDID("$FreeBSD: src/bin/cp/cp.c,v 1.54 2006/08/24 20:45:38 julian Exp $"); +__FBSDID("$FreeBSD: src/bin/cp/cp.c,v 1.55 2006/09/29 06:06:39 ru Exp $"); /* * Cp copies source files to target files. @@ -102,7 +102,7 @@ char *target; Hflag = Lflag = Pflag = 0; - while ((ch = getopt(argc, argv, "HLPRfinprvl")) != -1) + while ((ch = getopt(argc, argv, "HLPRfilnprv")) != -1) switch (ch) { case 'H': Hflag = 1; @@ -127,6 +127,9 @@ iflag = 1; fflag = nflag = 0; break; + case 'l': + lflag = 1; + break; case 'n': nflag = 1; fflag = iflag = 0; @@ -140,9 +143,6 @@ case 'v': vflag = 1; break; - case 'l': - lflag = 1; - break; default: usage(); break; ==== //depot/projects/soc2005/libalias/contrib/ntp/include/ntp_stdlib.h#2 (text+ko) ==== @@ -134,8 +134,10 @@ extern u_int cache_keylen; /* key length */ /* clocktypes.c */ +#ifdef NTP_REFCLOCK_H struct clktype; extern struct clktype clktypes[]; +#endif /* getopt.c */ extern char * ntp_optarg; /* global argument pointer */ ==== //depot/projects/soc2005/libalias/contrib/ntp/include/ntpd.h#2 (text+ko) ==== @@ -226,8 +226,10 @@ #endif /* ntp_control.c */ +#if 0 struct ctl_trap; extern struct ctl_trap ctl_trap[]; +#endif extern int num_ctl_traps; extern keyid_t ctl_auth_keyid; /* keyid used for authenticating write requests */ ==== //depot/projects/soc2005/libalias/contrib/telnet/telnet/telnet.1#3 (text+ko) ==== @@ -30,7 +30,7 @@ .\" SUCH DAMAGE. .\" .\" @(#)telnet.1 8.6 (Berkeley) 6/1/94 -.\" $FreeBSD: src/contrib/telnet/telnet/telnet.1,v 1.19 2006/09/18 15:03:18 maxim Exp $ +.\" $FreeBSD: src/contrib/telnet/telnet/telnet.1,v 1.20 2006/09/29 22:51:29 ru Exp $ .\" .Dd September 18, 2006 .Dt TELNET 1 @@ -233,7 +233,7 @@ port is used. .El .Pp -When in rlogin mode, a line of the form ~. disconnects from the +When in rlogin mode, a line of the form ~.\& disconnects from the remote host; ~ is the .Nm escape character. @@ -645,7 +645,7 @@ the canonical name of that string as determined by .Xr getaddrinfo 3 , or the string -.Dq DEFAULT +.Dq Li DEFAULT indicating all hosts. The rest of the line, and successive lines that begin with white space are assumed to be ==== //depot/projects/soc2005/libalias/etc/defaults/rc.conf#7 (text+ko) ==== @@ -15,7 +15,7 @@ # For a more detailed explanation of all the rc.conf variables, please # refer to the rc.conf(5) manual page. # -# $FreeBSD: src/etc/defaults/rc.conf,v 1.296 2006/09/20 19:48:31 brooks Exp $ +# $FreeBSD: src/etc/defaults/rc.conf,v 1.297 2006/09/29 15:45:09 bms Exp $ ############################################################## ### Important initial Boot-time options #################### @@ -297,7 +297,11 @@ router_enable="NO" # Set to YES to enable a routing daemon. router="/sbin/routed" # Name of routing daemon to use if enabled. router_flags="-q" # Flags for routing daemon. -mrouted_enable="NO" # Do multicast routing (see /etc/mrouted.conf). +mrouted_enable="NO" # Do IPv4 multicast routing. +mrouted_program="/usr/local/sbin/mrouted" # Name of IPv4 multicast + # routing daemon. You need to + # install it from package or + # port. mrouted_flags="" # Flags for multicast routing daemon. ipxgateway_enable="NO" # Set to YES to enable IPX routing. ipxrouted_enable="NO" # Set to YES to run the IPX routing daemon. ==== //depot/projects/soc2005/libalias/etc/rc.d/mrouted#2 (text+ko) ==== @@ -1,7 +1,7 @@ #!/bin/sh # # $NetBSD: mrouted,v 1.6 2002/03/22 04:33:59 thorpej Exp $ -# $FreeBSD: src/etc/rc.d/mrouted,v 1.9 2005/01/16 03:12:03 obrien Exp $ +# $FreeBSD: src/etc/rc.d/mrouted,v 1.10 2006/09/29 15:45:10 bms Exp $ # # PROVIDE: mrouted @@ -12,7 +12,7 @@ name="mrouted" rcvar=`set_rcvar` -command="/usr/sbin/${name}" +command="/usr/local/sbin/${name}" pidfile="/var/run/${name}.pid" required_files="/etc/${name}.conf" extra_commands="reload" ==== //depot/projects/soc2005/libalias/games/fortune/datfiles/limerick#2 (text+ko) ==== @@ -1,4 +1,4 @@ -%% $FreeBSD: src/games/fortune/datfiles/limerick,v 1.10 2005/12/26 16:09:58 schweikh Exp $ +%% $FreeBSD: src/games/fortune/datfiles/limerick,v 1.11 2006/09/27 19:20:43 schweikh Exp $ A bad little girl in Madrid, A most reprehensible kid, Told her Tante Louise @@ -1457,7 +1457,7 @@ Asked the man who started to bore 'er: "Do you mean birds and bees Go through antics like these, -To suppy us our fauna and flora?" +To supply us our fauna and flora?" % An irate young lady named Booker Told her husband, "You beast, I'm no hooker! ==== //depot/projects/soc2005/libalias/games/fortune/datfiles/startrek#2 (text+ko) ==== @@ -1,4 +1,4 @@ -%% $FreeBSD: src/games/fortune/datfiles/startrek,v 1.8 2005/08/30 16:33:39 schweikh Exp $ +%% $FreeBSD: src/games/fortune/datfiles/startrek,v 1.9 2006/09/27 19:20:43 schweikh Exp $ A father doesn't destroy his children. -- Lt. Carolyn Palamas, "Who Mourns for Adonais?", stardate 3468.1. @@ -77,7 +77,7 @@ Change is the essential process of all existence. -- Spock, "Let That Be Your Last Battlefield", stardate 5730.2 % -Compassion -- that's the one things no machine ever had. Maybe it's +Compassion -- that's the one thing no machine ever had. Maybe it's the one thing that keeps men ahead of them. -- McCoy, "The Ultimate Computer", stardate 4731.3 % ==== //depot/projects/soc2005/libalias/lib/libalias/Makefile#8 (text+ko) ==== @@ -1,29 +1,5 @@ -# Copyright 2006 Paolo Pisati -# All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -# SUCH DAMAGE. -# -# $FreeBSD: src/lib/libalias/Makefile,v 1.32 2006/09/26 23:26:49 piso Exp $ +# $FreeBSD: src/lib/libalias/Makefile,v 1.33 2006/09/27 12:30:27 ru Exp $ -SUBDIR= libalias modules +SUBDIR= libalias modules .include ==== //depot/projects/soc2005/libalias/lib/libc/gen/err.3#2 (text+ko) ==== @@ -30,7 +30,7 @@ .\" SUCH DAMAGE. .\" .\" From: @(#)err.3 8.1 (Berkeley) 6/9/93 -.\" $FreeBSD: src/lib/libc/gen/err.3,v 1.20 2004/10/04 14:04:37 jkoshy Exp $ +.\" $FreeBSD: src/lib/libc/gen/err.3,v 1.21 2006/09/29 22:57:22 ru Exp $ .\" .Dd March 6, 1999 .Dt ERR 3 @@ -98,7 +98,7 @@ If the .Fa fmt argument is not NULL, the -.Xr printf 3 +.Xr printf 3 Ns -like formatted error message is output. The output is terminated by a newline character. .Pp ==== //depot/projects/soc2005/libalias/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#10 (text+ko) ==== @@ -3,7 +3,7 @@ The &os; Project - $FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.975 2006/09/16 03:58:07 bmah Exp $ + $FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.977 2006/09/28 15:36:59 bmah Exp $ 2000 @@ -212,6 +212,17 @@ has been fixed. For more details, see security advisory FreeBSD-SA-06:20.bind. &merged; + Several programming errors have been fixed in &man.gzip.1;. + They could have the effect of causing a crash or an infinite + loop when decompressing files. More information can be found in + security advisory + FreeBSD-SA-06:21.gzip. &merged; + + Multiple errors in the OpenSSL &man.crypto.3; library have + been fixed. Potential effects are varied, and are documented in + more detail in security advisory + FreeBSD-SA-06:23.openssl. &merged; + @@ -1180,6 +1191,10 @@ The &man.id.1; utility now prints the effective user ID after the group ID. + The &man.id.1; utility now supports a + flag to print process audit properties, including the audit user + id. &merged; + The &man.ifconfig.8; utility now supports a flag to allow printing potentially sensitive keying material to standard output. @@ -1444,6 +1459,11 @@ flag to suppress header lines when multiple files are specified. &merged; + The version of tcpslice in the &os; base system has been + removed due to obsolescence. A more up-to-date version can be + found in the Ports Collection + as net/tcpslice. + The &man.time.1; utility now prints the time that a given command has been running if sent a SIGINFO signal. @@ -1485,6 +1505,9 @@ implemented. This function is popular in Microsoft and GNU systems. + The compiler toolchain is now capable of generating + executables for systems using the ARM processor. + <filename>/etc/rc.d</filename> Scripts @@ -1825,7 +1848,7 @@ The supported version of the KDE desktop environment (x11/kde3) has been - updated from 3.4.2 to 3.5.3. &merged; + updated from 3.4.2 to 3.5.4. &merged; The supported Linux emulation now uses the libraries in the ==== //depot/projects/soc2005/libalias/sbin/ipfw/ipfw2.c#10 (text+ko) ==== @@ -17,7 +17,7 @@ * * NEW command line interface for IP firewall facility * - * $FreeBSD: src/sbin/ipfw/ipfw2.c,v 1.98 2006/09/16 19:27:40 jhay Exp $ + * $FreeBSD: src/sbin/ipfw/ipfw2.c,v 1.99 2006/09/29 08:00:40 maxim Exp $ */ #include @@ -6189,6 +6189,8 @@ */ av += optind - 1; ac -= optind - 1; + if (ac < 2) + errx(EX_USAGE, "no filename argument"); av[ac-1] = NULL; fprintf(stderr, "command is %s\n", av[0]); break; ==== //depot/projects/soc2005/libalias/sbin/newfs/mkfs.c#2 (text+ko) ==== @@ -42,7 +42,7 @@ #endif /* not lint */ #endif #include -__FBSDID("$FreeBSD: src/sbin/newfs/mkfs.c,v 1.90 2005/08/14 17:07:04 iedowse Exp $"); +__FBSDID("$FreeBSD: src/sbin/newfs/mkfs.c,v 1.91 2006/09/27 05:49:21 delphij Exp $"); #include #include @@ -755,7 +755,7 @@ if ((grp = getgrnam("operator")) != NULL) { gid = grp->gr_gid; } else { - warnx("Cannot retrieve operator gid."); + warnx("Cannot retrieve operator gid, using gid 0."); gid = 0; } entries = (nflag) ? ROOTLINKCNT - 1: ROOTLINKCNT; ==== //depot/projects/soc2005/libalias/share/examples/mdoc/example.4#4 (text+ko) ==== @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/examples/mdoc/example.4,v 1.26 2006/09/26 19:59:52 danger Exp $ +.\" $FreeBSD: src/share/examples/mdoc/example.4,v 1.27 2006/09/27 21:28:44 danger Exp $ .\" .\" Note: The date here should be updated whenever a non-trivial .\" change is made to the manual page. @@ -33,9 +33,11 @@ .Nm example .Nd "example device driver manual page" .Sh SYNOPSIS -To enable support for -.Ns Nm , -place the following lines in the kernel configuration file: +To compile the +.Ns Nm +driver into the kernel, +place the following lines in the +kernel configuration file: .Bd -ragged -offset indent .Cd "device example" .Cd "options EXAMPLE_DEBUG" @@ -43,9 +45,9 @@ .Pp Alternatively, to load the .Ns Nm -as a module at boot time, add the following line into the -.Xr loader.conf 5 -file: +driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : .Bd -literal -offset indent example_load="YES" .Ed ==== //depot/projects/soc2005/libalias/share/examples/mdoc/example.9#2 (text+ko) ==== @@ -22,11 +22,11 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/examples/mdoc/example.9,v 1.3 2005/01/15 16:01:19 jkoshy Exp $ +.\" $FreeBSD: src/share/examples/mdoc/example.9,v 1.4 2006/09/27 08:39:00 pjd Exp $ .\" .\" Note: The date here should be updated whenever a non-trivial .\" change is made to the manual page. -.Dd January 12, 2005 +.Dd September 27, 2006 .Dt EXAMPLE 9 .Os .Sh NAME @@ -96,14 +96,14 @@ section is returned, to indicate the error. .Sh EXAMPLES .Bd -literal - int val; + int error; - mutex_lock(&example_lock); - if ((val = example(NULL, EXAMPLE_ONE)) != 0) { - mutex_unlock(&example_lock); - return (val); + mtx_lock(&example_lock); + if ((error = example(NULL, EXAMPLE_ONE)) != 0) { + mtx_unlock(&example_lock); + return (error); } - mutex_unlock(&example_lock); + mtx_unlock(&example_lock); .Ed .Sh COMPATIBILITY The @@ -298,7 +298,8 @@ .Xr example 1 , .Xr example 3 , .Xr example 4 , -.Xr mdoc 7 +.Xr mdoc 7 , +.Xr mutex 9 .Rs .%A "A. B. Author" .%T "Example RFC Title" ==== //depot/projects/soc2005/libalias/share/examples/scsi_target/scsi_cmds.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/share/examples/scsi_target/scsi_cmds.c,v 1.9 2006/04/11 21:36:43 mjacob Exp $ + * $FreeBSD: src/share/examples/scsi_target/scsi_cmds.c,v 1.10 2006/09/27 15:38:13 mjacob Exp $ */ #include @@ -35,6 +35,7 @@ #include #include #include +#include #include #include #include @@ -360,7 +361,7 @@ /* Advertise only what the SIM can actually support */ req_flags &= sim_flags; - scsi_ulto2b(req_flags, &inq->reserved[1]); + scsi_ulto2b(req_flags, &inq->spc2_flags); inq->response_format = 2; /* SCSI2 Inquiry Format */ inq->additional_length = SHORT_INQUIRY_LENGTH - @@ -496,21 +497,13 @@ if ((a_descr->flags & CAM_DIR_IN) != 0) { ret = start_io(atio, ctio, CAM_DIR_IN); if (debug) -#if __FreeBSD_version >= 500000 - warnx("Starting DIR_IN @%jd:%u", -#else - warnx("Starting DIR_IN @%lld:%u", -#endif - c_descr->offset, a_descr->targ_req); + warnx("Starting %p DIR_IN @" OFF_FMT ":%u", + a_descr, c_descr->offset, a_descr->targ_req); } else { ret = start_io(atio, ctio, CAM_DIR_OUT); if (debug) -#if __FreeBSD_version >= 500000 - warnx("Starting DIR_OUT @%jd:%u", -#else - warnx("Starting DIR_OUT @%lld:%u", -#endif - c_descr->offset, a_descr->init_req); + warnx("Starting %p DIR_OUT @" OFF_FMT ":%u", + a_descr, c_descr->offset, a_descr->init_req); } return (ret); @@ -572,29 +565,17 @@ a_descr->total_len = count * sector_size; if (a_descr->total_len == 0) { if (debug) -#if __FreeBSD_version >= 500000 - warnx("r/w 0 blocks @ blkno %ju", blkno); -#else - warnx("r/w 0 blocks @ blkno %llu", blkno); -#endif + warnx("r/w 0 blocks @ blkno " OFF_FMT, blkno); tcmd_null_ok(atio, ctio); return (0); } else if (cdb[0] == WRITE_6 || cdb[0] == WRITE_10) { a_descr->flags |= CAM_DIR_OUT; if (debug) -#if __FreeBSD_version >= 500000 - warnx("write %u blocks @ blkno %ju", count, blkno); -#else - warnx("write %u blocks @ blkno %llu", count, blkno); -#endif + warnx("write %u blocks @ blkno " OFF_FMT, count, blkno); } else { a_descr->flags |= CAM_DIR_IN; if (debug) -#if __FreeBSD_version >= 500000 - warnx("read %u blocks @ blkno %ju", count, blkno); -#else - warnx("read %u blocks @ blkno %llu", count, blkno); -#endif + warnx("read %u blocks @ blkno " OFF_FMT, count, blkno); } return (1); } @@ -626,14 +607,41 @@ /* If DIR_IN, start read from target, otherwise begin CTIO xfer. */ ret = 1; if (dir == CAM_DIR_IN) { - if (aio_read(&c_descr->aiocb) < 0) - err(1, "aio_read"); /* XXX */ + if (notaio) { + if (debug) + warnx("read sync %lud @ block " OFF_FMT, + (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (lseek(c_descr->aiocb.aio_fildes, + c_descr->aiocb.aio_offset, SEEK_SET) < 0) { + perror("lseek"); + err(1, "lseek"); + } + if (read(c_descr->aiocb.aio_fildes, + (void *)c_descr->aiocb.aio_buf, + ctio->dxfer_len) != ctio->dxfer_len) { + err(1, "read"); + } + } else { + if (debug) + warnx("read async %lud @ block " OFF_FMT, + (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (aio_read(&c_descr->aiocb) < 0) { + err(1, "aio_read"); /* XXX */ + } + } a_descr->targ_req += ctio->dxfer_len; + /* if we're done, we can mark the CCB as to send status */ if (a_descr->targ_req == a_descr->total_len) { ctio->ccb_h.flags |= CAM_SEND_STATUS; ctio->scsi_status = SCSI_STATUS_OK; ret = 0; } + if (notaio) + tcmd_rdwr_done(atio, ctio, AIO_DONE); } else { if (a_descr->targ_ack == a_descr->total_len) tcmd_null_ok(atio, ctio); @@ -665,7 +673,7 @@ switch (event) { case AIO_DONE: - if (aio_return(&c_descr->aiocb) < 0) { + if (!notaio && aio_return(&c_descr->aiocb) < 0) { warn("aio_return error"); /* XXX */ tcmd_sense(ctio->init_id, ctio, @@ -675,8 +683,12 @@ } a_descr->targ_ack += ctio->dxfer_len; if ((a_descr->flags & CAM_DIR_IN) != 0) { - if (debug) - warnx("sending CTIO for AIO read"); + if (debug) { + if (notaio) + warnx("sending CTIO for AIO read"); + else + warnx("sending CTIO for sync read"); + } a_descr->init_req += ctio->dxfer_len; send_ccb((union ccb *)ctio, /*priority*/1); } else { @@ -710,11 +722,34 @@ a_descr->init_ack += ctio->dxfer_len; if ((a_descr->flags & CAM_DIR_MASK) == CAM_DIR_OUT && ctio->dxfer_len > 0) { - if (debug) - warnx("sending AIO for CTIO write"); a_descr->targ_req += ctio->dxfer_len; - if (aio_write(&c_descr->aiocb) < 0) - err(1, "aio_write"); /* XXX */ + if (notaio) { + if (debug) + warnx("write sync %lud @ block " + OFF_FMT, (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (lseek(c_descr->aiocb.aio_fildes, + c_descr->aiocb.aio_offset, SEEK_SET) < 0) { + perror("lseek"); + err(1, "lseek"); + } + if (write(c_descr->aiocb.aio_fildes, + (void *) c_descr->aiocb.aio_buf, + ctio->dxfer_len) != ctio->dxfer_len) { + err(1, "write"); + } + tcmd_rdwr_done(atio, ctio, AIO_DONE); + } else { + if (debug) + warnx("write async %lud @ block " + OFF_FMT, (unsigned long) + (ctio->dxfer_len / sector_size), + c_descr->offset / sector_size); + if (aio_write(&c_descr->aiocb) < 0) { + err(1, "aio_write"); /* XXX */ + } + } } else { if (debug) warnx("CTIO done freeing CTIO"); ==== //depot/projects/soc2005/libalias/share/examples/scsi_target/scsi_target.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/share/examples/scsi_target/scsi_target.c,v 1.17 2006/03/22 17:00:14 mjacob Exp $ + * $FreeBSD: src/share/examples/scsi_target/scsi_target.c,v 1.18 2006/09/27 15:38:13 mjacob Exp $ */ #include @@ -56,12 +56,13 @@ /* Maximum amount to transfer per CTIO */ #define MAX_XFER MAXPHYS /* Maximum number of allocated CTIOs */ -#define MAX_CTIOS 32 +#define MAX_CTIOS 64 /* Maximum sector size for emulated volume */ #define MAX_SECTOR 32768 /* Global variables */ int debug; +int notaio = 0; off_t volume_size; u_int sector_size; size_t buf_size; @@ -86,7 +87,7 @@ static void handle_read(void); /* static int work_atio(struct ccb_accept_tio *); */ static void queue_io(struct ccb_scsiio *); -static void run_queue(struct ccb_accept_tio *); +static int run_queue(struct ccb_accept_tio *); static int work_inot(struct ccb_immed_notify *); static struct ccb_scsiio * get_ctio(void); @@ -117,7 +118,7 @@ TAILQ_INIT(&pending_queue); TAILQ_INIT(&work_queue); - while ((ch = getopt(argc, argv, "AdSTb:c:s:W:")) != -1) { + while ((ch = getopt(argc, argv, "AdSTYb:c:s:W:")) != -1) { switch(ch) { case 'A': req_flags |= SID_Addr16; @@ -193,6 +194,9 @@ /* NOTREACHED */ } break; + case 'Y': + notaio = 1; + break; default: usage(); /* NOTREACHED */ @@ -246,20 +250,16 @@ volume_size = user_size / sector_size; } if (debug) -#if __FreeBSD_version >= 500000 - warnx("volume_size: %d bytes x %jd sectors", -#else - warnx("volume_size: %d bytes x %lld sectors", -#endif + warnx("volume_size: %d bytes x " OFF_FMT " sectors", sector_size, volume_size); if (volume_size <= 0) errx(1, "volume must be larger than %d", sector_size); - { + if (notaio == 0) { struct aiocb aio, *aiop; - /* Make sure we have working AIO support */ + /* See if we have we have working AIO support */ memset(&aio, 0, sizeof(aio)); aio.aio_buf = malloc(sector_size); if (aio.aio_buf == NULL) @@ -269,16 +269,17 @@ aio.aio_nbytes = sector_size; signal(SIGSYS, SIG_IGN); if (aio_read(&aio) != 0) { - printf("You must enable VFS_AIO in your kernel " - "or load the aio(4) module.\n"); - err(1, "aio_read"); + printf("AIO support is not available- switchin to" + " single-threaded mode.\n"); >>> TRUNCATED FOR MAIL (1000 lines) <<< From owner-p4-projects@FreeBSD.ORG Sat Sep 30 13:52:17 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 13BDA16A415; Sat, 30 Sep 2006 13:52:17 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 E2F1616A403 for ; Sat, 30 Sep 2006 13:52:16 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id E616A43D53 for ; Sat, 30 Sep 2006 13:52:15 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UDqFCb066942 for ; Sat, 30 Sep 2006 13:52:15 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UDqFCc066939 for perforce@freebsd.org; Sat, 30 Sep 2006 13:52:15 GMT (envelope-from piso@freebsd.org) Date: Sat, 30 Sep 2006 13:52:15 GMT Message-Id: <200609301352.k8UDqFCc066939@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 106981 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 13:52:17 -0000 http://perforce.freebsd.org/chv.cgi?CH=106981 Change 106981 by piso@piso_newluxor on 2006/09/30 13:51:51 Reduce diff against HEAD Affected files ... .. //depot/projects/soc2005/libalias/etc/libalias.conf#2 edit .. //depot/projects/soc2005/libalias/lib/libalias/libalias/Makefile#3 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/Makefile#6 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/Makefile.inc#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/cuseeme/Makefile#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/dummy/Makefile#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/ftp/Makefile#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/irc/Makefile#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/nbt/Makefile#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/pptp/Makefile#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/skinny/Makefile#4 edit .. //depot/projects/soc2005/libalias/lib/libalias/modules/smedia/Makefile#4 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/libalias/Makefile#9 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/Makefile#5 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/Makefile.inc#4 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/cuseeme/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/dummy/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/ftp/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/irc/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/nbt/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/pptp/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/skinny/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/smedia/Makefile#3 edit .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_dummy.c#13 edit .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_mod.c#23 edit .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_mod.h#22 edit Differences ... ==== //depot/projects/soc2005/libalias/etc/libalias.conf#2 (text+ko) ==== @@ -1,3 +1,4 @@ +# $FreeBSD: src/etc/libalias.conf,v 1.1 2006/09/26 23:26:48 piso Exp $ /usr/lib/libalias_cuseeme.so /usr/lib/libalias_ftp.so /usr/lib/libalias_irc.so ==== //depot/projects/soc2005/libalias/lib/libalias/libalias/Makefile#3 (text+ko) ==== @@ -1,13 +1,14 @@ -# $FreeBSD: src/lib/libalias/Makefile,v 1.30.2.1 2005/07/22 17:29:02 kensmith Exp $ +# $FreeBSD: src/lib/libalias/libalias/Makefile,v 1.3 2006/09/27 12:30:27 ru Exp $ .PATH: ${.CURDIR}/../../../sys/netinet/libalias LIB= alias SHLIBDIR?= /lib -SHLIB_MAJOR= 5 +SHLIB_MAJOR= 5 MAN= libalias.3 SRCS= alias.c alias_db.c alias_proxy.c alias_util.c alias_old.c alias_mod.c -INCS= alias.h +INCS= alias.h WARNS?= 6 +NO_WERROR= .include ==== //depot/projects/soc2005/libalias/lib/libalias/modules/Makefile#6 (text+ko) ==== @@ -1,7 +1,7 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/Makefile,v 1.2 2006/09/27 12:30:27 ru Exp $ -.include "../../../sys/modules/libalias/modules/modules.inc" +.include "${.CURDIR}/../../../sys/modules/libalias/modules/modules.inc" -SUBDIR= ${MODULES} +SUBDIR= ${MODULES} .include ==== //depot/projects/soc2005/libalias/lib/libalias/modules/Makefile.inc#4 (text+ko) ==== @@ -1,7 +1,7 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/Makefile.inc,v 1.2 2006/09/27 12:30:27 ru Exp $ .PATH: ${.CURDIR}/../../../../sys/netinet/libalias SHLIBDIR?= /lib -SHLIB_MAJOR= 4 -WARNS?= 1 +SHLIB_MAJOR= 4 +WARNS?= 1 ==== //depot/projects/soc2005/libalias/lib/libalias/modules/cuseeme/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/cuseeme/Makefile,v 1.1 2006/09/26 23:26:50 piso Exp $ LIB= alias_cuseeme SRCS= alias_cuseeme.c ==== //depot/projects/soc2005/libalias/lib/libalias/modules/dummy/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/dummy/Makefile,v 1.1 2006/09/26 23:26:50 piso Exp $ LIB= alias_dummy SRCS= alias_dummy.c ==== //depot/projects/soc2005/libalias/lib/libalias/modules/ftp/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/ftp/Makefile,v 1.1 2006/09/26 23:26:50 piso Exp $ LIB= alias_ftp SRCS= alias_ftp.c ==== //depot/projects/soc2005/libalias/lib/libalias/modules/irc/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/irc/Makefile,v 1.1 2006/09/26 23:26:50 piso Exp $ LIB= alias_irc SRCS= alias_irc.c ==== //depot/projects/soc2005/libalias/lib/libalias/modules/nbt/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/nbt/Makefile,v 1.1 2006/09/26 23:26:50 piso Exp $ LIB= alias_nbt SRCS= alias_nbt.c ==== //depot/projects/soc2005/libalias/lib/libalias/modules/pptp/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/pptp/Makefile,v 1.1 2006/09/26 23:26:50 piso Exp $ LIB= alias_pptp SRCS= alias_pptp.c ==== //depot/projects/soc2005/libalias/lib/libalias/modules/skinny/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/skinny/Makefile,v 1.1 2006/09/26 23:26:51 piso Exp $ LIB= alias_skinny SRCS= alias_skinny.c ==== //depot/projects/soc2005/libalias/lib/libalias/modules/smedia/Makefile#4 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/lib/libalias/modules/smedia/Makefile,v 1.1 2006/09/26 23:26:51 piso Exp $ LIB= alias_smedia SRCS= alias_smedia.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/libalias/Makefile#9 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/libalias/Makefile,v 1.1 2006/09/26 23:26:51 piso Exp $ .PATH: ${.CURDIR}/../../../netinet/libalias ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/Makefile#5 (text+ko) ==== @@ -1,7 +1,7 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/Makefile,v 1.2 2006/09/27 12:30:27 ru Exp $ -.include "modules.inc" +.include "${.CURDIR}/modules.inc" -SUBDIR= ${MODULES} +SUBDIR= ${MODULES} .include ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/Makefile.inc#4 (text+ko) ==== @@ -1,3 +1,3 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/Makefile.inc,v 1.1 2006/09/26 23:26:51 piso Exp $ .PATH: ${.CURDIR}/../../../../netinet/libalias ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/cuseeme/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/cuseeme/Makefile,v 1.1 2006/09/26 23:26:52 piso Exp $ KMOD= alias_cuseeme SRCS= alias_cuseeme.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/dummy/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/dummy/Makefile,v 1.1 2006/09/26 23:26:52 piso Exp $ KMOD= alias_dummy SRCS= alias_dummy.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/ftp/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/ftp/Makefile,v 1.1 2006/09/26 23:26:52 piso Exp $ KMOD= alias_ftp SRCS= alias_ftp.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/irc/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/irc/Makefile,v 1.1 2006/09/26 23:26:52 piso Exp $ KMOD= alias_irc SRCS= alias_irc.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/nbt/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/nbt/Makefile,v 1.1 2006/09/26 23:26:52 piso Exp $ KMOD= alias_nbt SRCS= alias_nbt.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/pptp/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/pptp/Makefile,v 1.1 2006/09/26 23:26:52 piso Exp $ KMOD= alias_pptp SRCS= alias_pptp.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/skinny/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/skinny/Makefile,v 1.1 2006/09/26 23:26:52 piso Exp $ KMOD= alias_skinny SRCS= alias_skinny.c ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/smedia/Makefile#3 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/smedia/Makefile,v 1.1 2006/09/26 23:26:53 piso Exp $ KMOD= alias_smedia SRCS= alias_smedia.c ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_dummy.c#13 (text+ko) ==== @@ -25,6 +25,7 @@ */ #include +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_dummy.c,v 1.1 2006/09/26 23:26:53 piso Exp $"); /* * Alias_dummy is just an empty skeleton used to demostrate how to write ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_mod.c#23 (text+ko) ==== @@ -24,6 +24,8 @@ * SUCH DAMAGE. * */ +#include +__FBSDID("$FreeBSD: src/sys/netinet/libalias/alias_mod.c,v 1.2 2006/09/27 02:08:44 piso Exp $"); #ifdef _KERNEL #include ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias_mod.h#22 (text+ko) ==== @@ -22,6 +22,8 @@ * 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/netinet/libalias/alias_mod.h,v 1.1 2006/09/26 23:26:53 piso Exp $ */ /* From owner-p4-projects@FreeBSD.ORG Sat Sep 30 13:54:21 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id DAEFD16A415; Sat, 30 Sep 2006 13:54:20 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 B5EDA16A403 for ; Sat, 30 Sep 2006 13:54:20 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 560D143D4C for ; Sat, 30 Sep 2006 13:54:20 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UDsKR3066996 for ; Sat, 30 Sep 2006 13:54:20 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UDsJkv066993 for perforce@freebsd.org; Sat, 30 Sep 2006 13:54:19 GMT (envelope-from piso@freebsd.org) Date: Sat, 30 Sep 2006 13:54:19 GMT Message-Id: <200609301354.k8UDsJkv066993@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 106982 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 13:54:21 -0000 http://perforce.freebsd.org/chv.cgi?CH=106982 Change 106982 by piso@piso_newluxor on 2006/09/30 13:54:07 Ooopss... forgot this in the previous commit... Affected files ... .. //depot/projects/soc2005/libalias/sys/modules/libalias/modules/modules.inc#6 edit Differences ... ==== //depot/projects/soc2005/libalias/sys/modules/libalias/modules/modules.inc#6 (text+ko) ==== @@ -1,4 +1,4 @@ -# $FreeBSD$ +# $FreeBSD: src/sys/modules/libalias/modules/modules.inc,v 1.1 2006/09/26 23:26:51 piso Exp $ MODULES = MODULES += cuseeme From owner-p4-projects@FreeBSD.ORG Sat Sep 30 17:02:31 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 8D80216A49E; Sat, 30 Sep 2006 17:02:31 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 4932F16A417 for ; Sat, 30 Sep 2006 17:02:31 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6529A43D58 for ; Sat, 30 Sep 2006 17:02:30 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UH2UQb089599 for ; Sat, 30 Sep 2006 17:02:30 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UH2TJE089596 for perforce@freebsd.org; Sat, 30 Sep 2006 17:02:29 GMT (envelope-from attilio@FreeBSD.org) Date: Sat, 30 Sep 2006 17:02:29 GMT Message-Id: <200609301702.k8UH2TJE089596@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 106998 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 17:02:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=106998 Change 106998 by attilio@attilio_laptop on 2006/09/30 17:02:08 restyle ohci.h. I'm unsure if it is the right thing to do at the moment, BTW if somebody has something to say can contact me. Affected files ... .. //depot/projects/usb/src/sys/dev/usb/ohci.h#5 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/ohci.h#5 (text+ko) ==== @@ -38,244 +38,230 @@ #ifndef _OHCI_H_ #define _OHCI_H_ -/*** PCI config registers ***/ +/* PCI config registers */ +#define PCI_CBMEM 0x10 /* configuration base memory */ +#define PCI_INTERFACE_OHCI 0x10 -#define PCI_CBMEM 0x10 /* configuration base memory */ +/* OHCI registers */ +#define OHCI_REVISION 0x00 /* OHCI revision */ +#define OHCI_REV_LO(rev) ((rev) & 0xf) +#define OHCI_REV_HI(rev) (((rev)>>4) & 0xf) +#define OHCI_REV_LEGACY(rev) ((rev) & 0x100) +#define OHCI_CONTROL 0x04 +#define OHCI_CBSR_MASK 0x00000003 /* Control/Bulk Service Ratio */ +#define OHCI_RATIO_1_1 0x00000000 +#define OHCI_RATIO_1_2 0x00000001 +#define OHCI_RATIO_1_3 0x00000002 +#define OHCI_RATIO_1_4 0x00000003 +#define OHCI_PLE 0x00000004 /* Periodic List Enable */ +#define OHCI_IE 0x00000008 /* Isochronous Enable */ +#define OHCI_CLE 0x00000010 /* Control List Enable */ +#define OHCI_BLE 0x00000020 /* Bulk List Enable */ +#define OHCI_HCFS_MASK 0x000000c0 /* HostControllerFunctionalState */ +#define OHCI_HCFS_RESET 0x00000000 +#define OHCI_HCFS_RESUME 0x00000040 +#define OHCI_HCFS_OPERATIONAL 0x00000080 +#define OHCI_HCFS_SUSPEND 0x000000c0 +#define OHCI_IR 0x00000100 /* Interrupt Routing */ +#define OHCI_RWC 0x00000200 /* Remote Wakeup Connected */ +#define OHCI_RWE 0x00000400 /* Remote Wakeup Enabled */ +#define OHCI_COMMAND_STATUS 0x08 +#define OHCI_HCR 0x00000001 /* Host Controller Reset */ +#define OHCI_CLF 0x00000002 /* Control List Filled */ +#define OHCI_BLF 0x00000004 /* Bulk List Filled */ +#define OHCI_OCR 0x00000008 /* Ownership Change Request */ +#define OHCI_SOC_MASK 0x00030000 /* Scheduling Overrun Count */ +#define OHCI_INTERRUPT_STATUS 0x0c +#define OHCI_SO 0x00000001 /* Scheduling Overrun */ +#define OHCI_WDH 0x00000002 /* Writeback Done Head */ +#define OHCI_SF 0x00000004 /* Start of Frame */ +#define OHCI_RD 0x00000008 /* Resume Detected */ +#define OHCI_UE 0x00000010 /* Unrecoverable Error */ +#define OHCI_FNO 0x00000020 /* Frame Number Overflow */ +#define OHCI_RHSC 0x00000040 /* Root Hub Status Change */ +#define OHCI_OC 0x40000000 /* Ownership Change */ +#define OHCI_MIE 0x80000000 /* Master Interrupt Enable */ +#define OHCI_INTERRUPT_ENABLE 0x10 +#define OHCI_INTERRUPT_DISABLE 0x14 +#define OHCI_HCCA 0x18 +#define OHCI_PERIOD_CURRENT_ED 0x1c +#define OHCI_CONTROL_HEAD_ED 0x20 +#define OHCI_CONTROL_CURRENT_ED 0x24 +#define OHCI_BULK_HEAD_ED 0x28 +#define OHCI_BULK_CURRENT_ED 0x2c +#define OHCI_DONE_HEAD 0x30 +#define OHCI_FM_INTERVAL 0x34 +#define OHCI_GET_IVAL(s) ((s) & 0x3fff) +#define OHCI_GET_FSMPS(s) (((s) >> 16) & 0x7fff) +#define OHCI_FIT 0x80000000 +#define OHCI_FM_REMAINING 0x38 +#define OHCI_FM_NUMBER 0x3c +#define OHCI_PERIODIC_START 0x40 +#define OHCI_LS_THRESHOLD 0x44 +#define OHCI_RH_DESCRIPTOR_A 0x48 +#define OHCI_GET_NDP(s) ((s) & 0xff) +#define OHCI_PSM 0x0100 /* Power Switching Mode */ +#define OHCI_NPS 0x0200 /* No Power Switching */ +#define OHCI_DT 0x0400 /* Device Type */ +#define OHCI_OCPM 0x0800 /* Overcurrent Protection Mode */ +#define OHCI_NOCP 0x1000 /* No Overcurrent Protection */ +#define OHCI_GET_POTPGT(s) ((s) >> 24) +#define OHCI_RH_DESCRIPTOR_B 0x4c +#define OHCI_RH_STATUS 0x50 +#define OHCI_LPS 0x00000001 /* Local Power Status */ +#define OHCI_OCI 0x00000002 /* OverCurrent Indicator */ +#define OHCI_DRWE 0x00008000 /* Device Remote Wakeup Enable */ +#define OHCI_LPSC 0x00010000 /* Local Power Status Change */ +#define OHCI_CCIC 0x00020000 /* OverCurrent Indicator Change */ +#define OHCI_CRWE 0x80000000 /* Clear Remote Wakeup Enable */ +#define OHCI_RH_PORT_STATUS(n) (0x50 + ((n)*4)) /* 1 based indexing */ -#define PCI_INTERFACE_OHCI 0x10 +#define OHCI_LES (OHCI_PLE | OHCI_IE | OHCI_CLE | OHCI_BLE) +#define OHCI_ALL_INTRS (OHCI_SO | OHCI_WDH | OHCI_SF | \ + OHCI_RD | OHCI_UE | OHCI_FNO | \ + OHCI_RHSC | OHCI_OC) +#define OHCI_NORMAL_INTRS (OHCI_WDH | OHCI_RD | OHCI_UE | OHCI_RHSC) -/*** OHCI registers */ +#define OHCI_FSMPS(i) (((i-210)*6/7) << 16) +#define OHCI_PERIODIC(i) ((i)*9/10) -#define OHCI_REVISION 0x00 /* OHCI revision # */ -#define OHCI_REV_LO(rev) ((rev) & 0xf) -#define OHCI_REV_HI(rev) (((rev)>>4) & 0xf) -#define OHCI_REV_LEGACY(rev) ((rev) & 0x100) +#define OHCI_NO_INTRS 32 +#define OHCI_HCCA_SIZE 256 -#define OHCI_CONTROL 0x04 -#define OHCI_CBSR_MASK 0x00000003 /* Control/Bulk Service Ratio */ -#define OHCI_RATIO_1_1 0x00000000 -#define OHCI_RATIO_1_2 0x00000001 -#define OHCI_RATIO_1_3 0x00000002 -#define OHCI_RATIO_1_4 0x00000003 -#define OHCI_PLE 0x00000004 /* Periodic List Enable */ -#define OHCI_IE 0x00000008 /* Isochronous Enable */ -#define OHCI_CLE 0x00000010 /* Control List Enable */ -#define OHCI_BLE 0x00000020 /* Bulk List Enable */ -#define OHCI_HCFS_MASK 0x000000c0 /* HostControllerFunctionalState */ -#define OHCI_HCFS_RESET 0x00000000 -#define OHCI_HCFS_RESUME 0x00000040 -#define OHCI_HCFS_OPERATIONAL 0x00000080 -#define OHCI_HCFS_SUSPEND 0x000000c0 -#define OHCI_IR 0x00000100 /* Interrupt Routing */ -#define OHCI_RWC 0x00000200 /* Remote Wakeup Connected */ -#define OHCI_RWE 0x00000400 /* Remote Wakeup Enabled */ -#define OHCI_COMMAND_STATUS 0x08 -#define OHCI_HCR 0x00000001 /* Host Controller Reset */ -#define OHCI_CLF 0x00000002 /* Control List Filled */ -#define OHCI_BLF 0x00000004 /* Bulk List Filled */ -#define OHCI_OCR 0x00000008 /* Ownership Change Request */ -#define OHCI_SOC_MASK 0x00030000 /* Scheduling Overrun Count */ -#define OHCI_INTERRUPT_STATUS 0x0c -#define OHCI_SO 0x00000001 /* Scheduling Overrun */ -#define OHCI_WDH 0x00000002 /* Writeback Done Head */ -#define OHCI_SF 0x00000004 /* Start of Frame */ -#define OHCI_RD 0x00000008 /* Resume Detected */ -#define OHCI_UE 0x00000010 /* Unrecoverable Error */ -#define OHCI_FNO 0x00000020 /* Frame Number Overflow */ -#define OHCI_RHSC 0x00000040 /* Root Hub Status Change */ -#define OHCI_OC 0x40000000 /* Ownership Change */ -#define OHCI_MIE 0x80000000 /* Master Interrupt Enable */ -#define OHCI_INTERRUPT_ENABLE 0x10 -#define OHCI_INTERRUPT_DISABLE 0x14 -#define OHCI_HCCA 0x18 -#define OHCI_PERIOD_CURRENT_ED 0x1c -#define OHCI_CONTROL_HEAD_ED 0x20 -#define OHCI_CONTROL_CURRENT_ED 0x24 -#define OHCI_BULK_HEAD_ED 0x28 -#define OHCI_BULK_CURRENT_ED 0x2c -#define OHCI_DONE_HEAD 0x30 -#define OHCI_FM_INTERVAL 0x34 -#define OHCI_GET_IVAL(s) ((s) & 0x3fff) -#define OHCI_GET_FSMPS(s) (((s) >> 16) & 0x7fff) -#define OHCI_FIT 0x80000000 -#define OHCI_FM_REMAINING 0x38 -#define OHCI_FM_NUMBER 0x3c -#define OHCI_PERIODIC_START 0x40 -#define OHCI_LS_THRESHOLD 0x44 -#define OHCI_RH_DESCRIPTOR_A 0x48 -#define OHCI_GET_NDP(s) ((s) & 0xff) -#define OHCI_PSM 0x0100 /* Power Switching Mode */ -#define OHCI_NPS 0x0200 /* No Power Switching */ -#define OHCI_DT 0x0400 /* Device Type */ -#define OHCI_OCPM 0x0800 /* Overcurrent Protection Mode */ -#define OHCI_NOCP 0x1000 /* No Overcurrent Protection */ -#define OHCI_GET_POTPGT(s) ((s) >> 24) -#define OHCI_RH_DESCRIPTOR_B 0x4c -#define OHCI_RH_STATUS 0x50 -#define OHCI_LPS 0x00000001 /* Local Power Status */ -#define OHCI_OCI 0x00000002 /* OverCurrent Indicator */ -#define OHCI_DRWE 0x00008000 /* Device Remote Wakeup Enable */ -#define OHCI_LPSC 0x00010000 /* Local Power Status Change */ -#define OHCI_CCIC 0x00020000 /* OverCurrent Indicator Change */ -#define OHCI_CRWE 0x80000000 /* Clear Remote Wakeup Enable */ -#define OHCI_RH_PORT_STATUS(n) (0x50 + ((n)*4)) /* 1 based indexing */ +/* Structures alignment (bytes) */ +#define OHCI_HCCA_ALIGN 256 +#define OHCI_ED_ALIGN 16 +#define OHCI_TD_ALIGN 16 +#define OHCI_ITD_ALIGN 32 -#define OHCI_LES (OHCI_PLE | OHCI_IE | OHCI_CLE | OHCI_BLE) -#define OHCI_ALL_INTRS (OHCI_SO | OHCI_WDH | OHCI_SF | OHCI_RD | OHCI_UE | \ - OHCI_FNO | OHCI_RHSC | OHCI_OC) -#define OHCI_NORMAL_INTRS (OHCI_WDH | OHCI_RD | OHCI_UE | OHCI_RHSC) +#define OHCI_PAGE_SIZE 0x1000 +#define OHCI_PAGE(x) ((x) &~ 0xfff) +#define OHCI_PAGE_OFFSET(x) ((x) & 0xfff) +#define OHCI_PAGE_MASK(x) ((x) & 0xfff) -#define OHCI_FSMPS(i) (((i-210)*6/7) << 16) -#define OHCI_PERIODIC(i) ((i)*9/10) +#if ((USB_PAGE_SIZE < OHCI_ED_ALIGN) || (OHCI_ED_ALIGN == 0) || \ + (USB_PAGE_SIZE < OHCI_TD_ALIGN) || (OHCI_TD_ALIGN == 0) || \ + (USB_PAGE_SIZE < OHCI_ITD_ALIGN) || (OHCI_ITD_ALIGN == 0) || \ + (USB_PAGE_SIZE < OHCI_PAGE_SIZE) || (OHCI_PAGE_SIZE == 0)) +#error "Invalid USB page size!" +#endif -#define OHCI_NO_INTRS 32 -#define OHCI_HCCA_SIZE 256 -#define OHCI_HCCA_ALIGN 256 /* bytes */ struct ohci_hcca { - __volatile__ u_int32_t hcca_interrupt_table[OHCI_NO_INTRS]; - __volatile__ u_int32_t hcca_frame_number; - __volatile__ u_int32_t hcca_done_head; -#define OHCI_DONE_INTRS 1 -} __attribute__((__aligned__(OHCI_HCCA_ALIGN))); - -#define OHCI_PAGE_SIZE 0x1000 -#define OHCI_PAGE(x) ((x) &~ 0xfff) -#define OHCI_PAGE_OFFSET(x) ((x) & 0xfff) -#define OHCI_PAGE_MASK(x) ((x) & 0xfff) - -#define OHCI_ED_ALIGN 16 /* bytes */ + volatile uint32_t hcca_interrupt_table[OHCI_NO_INTRS]; + volatile uint32_t hcca_frame_number; + volatile uint32_t hcca_done_head; +#define OHCI_DONE_INTRS 1 +} __aligned(OHCI_HCCA_ALIGN); typedef struct ohci_ed { - __volatile__ u_int32_t ed_flags; -#define OHCI_ED_GET_FA(s) ((s) & 0x7f) -#define OHCI_ED_ADDRMASK 0x0000007f -#define OHCI_ED_SET_FA(s) (s) -#define OHCI_ED_GET_EN(s) (((s) >> 7) & 0xf) -#define OHCI_ED_SET_EN(s) ((s) << 7) -#define OHCI_ED_DIR_MASK 0x00001800 -#define OHCI_ED_DIR_TD 0x00000000 -#define OHCI_ED_DIR_OUT 0x00000800 -#define OHCI_ED_DIR_IN 0x00001000 -#define OHCI_ED_SPEED 0x00002000 -#define OHCI_ED_SKIP 0x00004000 -#define OHCI_ED_FORMAT_GEN 0x00000000 -#define OHCI_ED_FORMAT_ISO 0x00008000 -#define OHCI_ED_GET_MAXP(s) (((s) >> 16) & 0x07ff) -#define OHCI_ED_SET_MAXP(s) ((s) << 16) -#define OHCI_ED_MAXPMASK (0x7ff << 16) - __volatile__ u_int32_t ed_tailp; - __volatile__ u_int32_t ed_headp; -#define OHCI_HALTED 0x00000001 -#define OHCI_TOGGLECARRY 0x00000002 -#define OHCI_HEADMASK 0xfffffffc - __volatile__ u_int32_t ed_next; - - /* - * extra information needed: - */ - struct ohci_ed *next; - struct ohci_ed *prev; - struct ohci_ed *obj_next; - - u_int32_t ed_self; - -} __attribute__((__aligned__(OHCI_ED_ALIGN))) ohci_ed_t; + volatile uint32_t ed_flags; +#define OHCI_ED_GET_FA(s) ((s) & 0x7f) +#define OHCI_ED_ADDRMASK 0x0000007f +#define OHCI_ED_SET_FA(s) (s) +#define OHCI_ED_GET_EN(s) (((s) >> 7) & 0xf) +#define OHCI_ED_SET_EN(s) ((s) << 7) +#define OHCI_ED_DIR_MASK 0x00001800 +#define OHCI_ED_DIR_TD 0x00000000 +#define OHCI_ED_DIR_OUT 0x00000800 +#define OHCI_ED_DIR_IN 0x00001000 +#define OHCI_ED_SPEED 0x00002000 +#define OHCI_ED_SKIP 0x00004000 +#define OHCI_ED_FORMAT_GEN 0x00000000 +#define OHCI_ED_FORMAT_ISO 0x00008000 +#define OHCI_ED_GET_MAXP(s) (((s) >> 16) & 0x07ff) +#define OHCI_ED_SET_MAXP(s) ((s) << 16) +#define OHCI_ED_MAXPMASK (0x7ff << 16) + volatile uint32_t ed_tailp; + volatile uint32_t ed_headp; +#define OHCI_HALTED 0x00000001 +#define OHCI_TOGGLECARRY 0x00000002 +#define OHCI_HEADMASK 0xfffffffc + volatile uint32_t ed_next; +/* + * Extra information needed: + */ + struct ohci_ed *next; + struct ohci_ed *prev; + struct ohci_ed *obj_next; + uint32_t ed_self; +} __aligned(OHCI_ED_ALIGN) ohci_ed_t; -#define OHCI_TD_ALIGN 16 /* bytes */ - typedef struct ohci_td { - __volatile__ u_int32_t td_flags; -#define OHCI_TD_R 0x00040000 /* Buffer Rounding */ -#define OHCI_TD_DP_MASK 0x00180000 /* Direction / PID */ -#define OHCI_TD_SETUP 0x00000000 -#define OHCI_TD_OUT 0x00080000 -#define OHCI_TD_IN 0x00100000 -#define OHCI_TD_GET_DI(x) (((x) >> 21) & 7) /* Delay Interrupt */ -#define OHCI_TD_SET_DI(x) ((x) << 21) -#define OHCI_TD_NOINTR 0x00e00000 -#define OHCI_TD_INTR_MASK 0x00e00000 -#define OHCI_TD_TOGGLE_CARRY 0x00000000 -#define OHCI_TD_TOGGLE_0 0x02000000 -#define OHCI_TD_TOGGLE_1 0x03000000 -#define OHCI_TD_TOGGLE_MASK 0x03000000 -#define OHCI_TD_GET_EC(x) (((x) >> 26) & 3) /* Error Count */ -#define OHCI_TD_GET_CC(x) ((x) >> 28) /* Condition Code */ -#define OHCI_TD_NOCC 0xf0000000 - __volatile__ u_int32_t td_cbp; /* Current Buffer Pointer */ - __volatile__ u_int32_t td_next; /* Next TD */ - __volatile__ u_int32_t td_be; /* Buffer End */ - - /* - * extra information needed: - */ - struct ohci_td * obj_next; - - u_int32_t td_self; - - u_int16_t len; - -} __attribute__((__aligned__(OHCI_TD_ALIGN))) ohci_td_t; - + volatile uint32_t td_flags; +#define OHCI_TD_R 0x00040000 /* Buffer Rounding */ +#define OHCI_TD_DP_MASK 0x00180000 /* Direction / PID */ +#define OHCI_TD_SETUP 0x00000000 +#define OHCI_TD_OUT 0x00080000 +#define OHCI_TD_IN 0x00100000 +#define OHCI_TD_GET_DI(x) (((x) >> 21) & 7) /* Delay Interrupt */ +#define OHCI_TD_SET_DI(x) ((x) << 21) +#define OHCI_TD_NOINTR 0x00e00000 +#define OHCI_TD_INTR_MASK 0x00e00000 +#define OHCI_TD_TOGGLE_CARRY 0x00000000 +#define OHCI_TD_TOGGLE_0 0x02000000 +#define OHCI_TD_TOGGLE_1 0x03000000 +#define OHCI_TD_TOGGLE_MASK 0x03000000 +#define OHCI_TD_GET_EC(x) (((x) >> 26) & 3) /* Error Count */ +#define OHCI_TD_GET_CC(x) ((x) >> 28) /* Condition Code */ +#define OHCI_TD_NOCC 0xf0000000 + volatile uint32_t td_cbp; /* Current Buffer Pointer */ + volatile uint32_t td_next; /* Next TD */ + volatile uint32_t td_be; /* Buffer End */ +/* + * Extra information needed: + */ + struct ohci_td *obj_next; + uint32_t td_self; + uint16_t len; +} __aligned(OHCI_TD_ALIGN) ohci_td_t; -#define OHCI_ITD_NOFFSET 8 -#define OHCI_ITD_ALIGN 32 /* bytes */ typedef struct ohci_itd { - __volatile__ u_int32_t itd_flags; -#define OHCI_ITD_GET_SF(x) ((x) & 0x0000ffff) -#define OHCI_ITD_SET_SF(x) ((x) & 0xffff) -#define OHCI_ITD_GET_DI(x) (((x) >> 21) & 7) /* Delay Interrupt */ -#define OHCI_ITD_SET_DI(x) ((x) << 21) -#define OHCI_ITD_NOINTR 0x00e00000 -#define OHCI_ITD_GET_FC(x) ((((x) >> 24) & 7)+1) /* Frame Count */ -#define OHCI_ITD_SET_FC(x) (((x)-1) << 24) -#define OHCI_ITD_GET_CC(x) ((x) >> 28) /* Condition Code */ -#define OHCI_ITD_NOCC 0xf0000000 - __volatile__ u_int32_t itd_bp0; /* Buffer Page 0 */ - __volatile__ u_int32_t itd_next; /* Next ITD */ - __volatile__ u_int32_t itd_be; /* Buffer End */ - __volatile__ u_int16_t itd_offset[OHCI_ITD_NOFFSET]; /* Buffer offsets and Status */ -#define OHCI_ITD_PAGE_SELECT 0x00001000 -#define OHCI_ITD_MK_OFFS(len) (0xe000 | ((len) & 0x1fff)) -#define OHCI_ITD_PSW_LENGTH(x) ((x) & 0xfff) /* Transfer length */ -#define OHCI_ITD_PSW_GET_CC(x) ((x) >> 12) /* Condition Code */ + volatile uint32_t itd_flags; +#define OHCI_ITD_GET_SF(x) ((x) & 0x0000ffff) +#define OHCI_ITD_SET_SF(x) ((x) & 0xffff) +#define OHCI_ITD_GET_DI(x) (((x) >> 21) & 7) /* Delay Interrupt */ +#define OHCI_ITD_SET_DI(x) ((x) << 21) +#define OHCI_ITD_NOINTR 0x00e00000 +#define OHCI_ITD_GET_FC(x) ((((x) >> 24) & 7)+1) /* Frame Count */ +#define OHCI_ITD_SET_FC(x) (((x)-1) << 24) +#define OHCI_ITD_GET_CC(x) ((x) >> 28) /* Condition Code */ +#define OHCI_ITD_NOCC 0xf0000000 +#define OHCI_ITD_NOFFSET 8 + volatile uint32_t itd_bp0; /* Buffer Page 0 */ + volatile uint32_t itd_next; /* Next ITD */ + volatile uint32_t itd_be; /* Buffer End */ + volatile uint16_t itd_offset[OHCI_ITD_NOFFSET]; /* Buffer offsets and Status */ +#define OHCI_ITD_PAGE_SELECT 0x00001000 +#define OHCI_ITD_MK_OFFS(len) (0xe000 | ((len) & 0x1fff)) +#define OHCI_ITD_PSW_LENGTH(x) ((x) & 0xfff) /* Transfer length */ +#define OHCI_ITD_PSW_GET_CC(x) ((x) >> 12) /* Condition Code */ +/* + * Extra information needed: + */ + struct ohci_itd *obj_next; + uint32_t itd_self; + uint8_t frames; +} __aligned(OHCI_ITD_ALIGN) ohci_itd_t; - /* - * extra information needed - */ - struct ohci_itd *obj_next; - - u_int32_t itd_self; - - u_int8_t frames; - -} __attribute__((__aligned__(OHCI_ITD_ALIGN))) ohci_itd_t; +#define OHCI_CC_NO_ERROR 0 +#define OHCI_CC_CRC 1 +#define OHCI_CC_BIT_STUFFING 2 +#define OHCI_CC_DATA_TOGGLE_MISMATCH 3 +#define OHCI_CC_STALL 4 +#define OHCI_CC_DEVICE_NOT_RESPONDING 5 +#define OHCI_CC_PID_CHECK_FAILURE 6 +#define OHCI_CC_UNEXPECTED_PID 7 +#define OHCI_CC_DATA_OVERRUN 8 +#define OHCI_CC_DATA_UNDERRUN 9 +#define OHCI_CC_BUFFER_OVERRUN 12 +#define OHCI_CC_BUFFER_UNDERRUN 13 +#define OHCI_CC_NOT_ACCESSED 15 -#define OHCI_CC_NO_ERROR 0 -#define OHCI_CC_CRC 1 -#define OHCI_CC_BIT_STUFFING 2 -#define OHCI_CC_DATA_TOGGLE_MISMATCH 3 -#define OHCI_CC_STALL 4 -#define OHCI_CC_DEVICE_NOT_RESPONDING 5 -#define OHCI_CC_PID_CHECK_FAILURE 6 -#define OHCI_CC_UNEXPECTED_PID 7 -#define OHCI_CC_DATA_OVERRUN 8 -#define OHCI_CC_DATA_UNDERRUN 9 -#define OHCI_CC_BUFFER_OVERRUN 12 -#define OHCI_CC_BUFFER_UNDERRUN 13 -#define OHCI_CC_NOT_ACCESSED 15 - /* Some delay needed when changing certain registers. */ -#define OHCI_ENABLE_POWER_DELAY 5 -#define OHCI_READ_DESC_DELAY 5 +#define OHCI_ENABLE_POWER_DELAY 5 +#define OHCI_READ_DESC_DELAY 5 -#define OHCI_NO_EDS (2*OHCI_NO_INTRS) - -#if ((USB_PAGE_SIZE < OHCI_ED_ALIGN) || (OHCI_ED_ALIGN == 0) || \ - (USB_PAGE_SIZE < OHCI_TD_ALIGN) || (OHCI_TD_ALIGN == 0) || \ - (USB_PAGE_SIZE < OHCI_ITD_ALIGN) || (OHCI_ITD_ALIGN == 0) || \ - (USB_PAGE_SIZE < OHCI_PAGE_SIZE) || (OHCI_PAGE_SIZE == 0)) -#error "Invalid USB page size!" -#endif +#define OHCI_NO_EDS (2*OHCI_NO_INTRS) struct ohci_hw_softc { struct ohci_hcca hcca; @@ -286,65 +272,54 @@ }; typedef struct ohci_softc { - struct ohci_hw_softc sc_hw; /* hardware structures first */ + struct ohci_hw_softc sc_hw; /* hardware structures first */ - ohci_ed_t * sc_ctrl_p_last; - ohci_ed_t * sc_bulk_p_last; - ohci_ed_t * sc_isoc_p_last; - ohci_ed_t * sc_intr_p_last[OHCI_NO_EDS]; - u_int16_t sc_intr_stat[OHCI_NO_EDS]; + ohci_ed_t *sc_ctrl_p_last; + ohci_ed_t *sc_bulk_p_last; + ohci_ed_t *sc_isoc_p_last; + ohci_ed_t *sc_intr_p_last[OHCI_NO_EDS]; + uint16_t sc_intr_stat[OHCI_NO_EDS]; struct usbd_bus sc_bus; /* base device */ - u_int32_t sc_physaddr; + uint32_t sc_physaddr; - bus_space_tag_t iot; - bus_space_handle_t ioh; - bus_size_t sc_size; + bus_space_tag_t iot; + bus_space_handle_t ioh; + bus_size_t sc_size; - void *ih; + void *ih; - struct resource *io_res; - struct resource *irq_res; + struct resource *io_res; + struct resource *irq_res; - u_int32_t sc_eintrs; /* enabled interrupts */ + uint32_t sc_eintrs; /* enabled interrupts */ - u_int8_t sc_noport; - u_int8_t sc_addr; /* device address */ - u_int8_t sc_conf; /* device configuration */ + uint8_t sc_noport; + uint8_t sc_addr; /* device address */ + uint8_t sc_conf; /* device configuration */ - device_t sc_dev; + device_t sc_dev; - struct usbd_xfer *sc_intrxfer; + struct usbd_xfer *sc_intrxfer; - u_int8_t sc_vendor[16]; - int sc_id_vendor; - -#if defined(__NetBSD__) || defined(__OpenBSD__) - void *sc_powerhook; /* cookie from power hook */ - void *sc_shutdownhook; /* cookie from shutdown hook */ + uint8_t sc_vendor[16]; + int sc_id_vendor; +#if defined(__NetBSD__) + void *sc_powerhook; /* cookie from power hook */ + void *sc_shutdownhook; /* cookie from shutdown hook */ #endif - u_int32_t sc_control; /* Preserved during suspend/standby */ - u_int32_t sc_intre; + uint32_t sc_control; /* Preserved during suspend/standby */ + uint32_t sc_intre; - LIST_HEAD(, usbd_xfer) sc_interrupt_list_head; + LIST_HEAD(, usbd_xfer) sc_interrupt_list_head; - struct __callout sc_tmo_rhsc; + struct __callout sc_tmo_rhsc; } ohci_softc_t; -usbd_status -ohci_init(ohci_softc_t *sc); - -void -ohci_detach(struct ohci_softc *sc); - -void -ohci_suspend(ohci_softc_t *sc); +usbd_status ohci_init(ohci_softc_t *sc); +void ohci_detach(struct ohci_softc *sc); +void ohci_suspend(ohci_softc_t *sc); +void ohci_resume(ohci_softc_t *sc); +void ohci_interrupt(ohci_softc_t *sc); -void -ohci_resume(ohci_softc_t *sc); - -void -ohci_interrupt(ohci_softc_t *sc); - #endif /* _OHCI_H_ */ - From owner-p4-projects@FreeBSD.ORG Sat Sep 30 17:39:20 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id EB9B216A415; Sat, 30 Sep 2006 17:39:19 +0000 (UTC) X-Original-To: perforce@FreeBSD.org 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 C5A2416A407 for ; Sat, 30 Sep 2006 17:39:19 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8843C43D46 for ; Sat, 30 Sep 2006 17:39:19 +0000 (GMT) (envelope-from attilio@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UHdJo0092765 for ; Sat, 30 Sep 2006 17:39:19 GMT (envelope-from attilio@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UHdJAZ092762 for perforce@freebsd.org; Sat, 30 Sep 2006 17:39:19 GMT (envelope-from attilio@FreeBSD.org) Date: Sat, 30 Sep 2006 17:39:19 GMT Message-Id: <200609301739.k8UHdJAZ092762@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to attilio@FreeBSD.org using -f From: Attilio Rao To: Perforce Change Reviews Cc: Subject: PERFORCE change 107002 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 17:39:20 -0000 http://perforce.freebsd.org/chv.cgi?CH=107002 Change 107002 by attilio@attilio_laptop on 2006/09/30 17:39:11 Adjust erroneous padding. Affected files ... .. //depot/projects/usb/src/sys/dev/usb/ehci.h#6 edit Differences ... ==== //depot/projects/usb/src/sys/dev/usb/ehci.h#6 (text+ko) ==== @@ -113,8 +113,7 @@ #define EHCI_STS_INTRS(x) ((x) & 0x3f) #define EHCI_NORMAL_INTRS (/* EHCI_STS_IAA | */ EHCI_STS_HSE | \ - EHCI_STS_PCD | EHCI_STS_ERRINT | \ - EHCI_STS_INT) + EHCI_STS_PCD | EHCI_STS_ERRINT | EHCI_STS_INT) #define EHCI_USBINTR 0x08 /* RW Interrupt register */ #define EHCI_INTR_IAAE 0x00000020 /* interrupt on async advance ena */ From owner-p4-projects@FreeBSD.ORG Sat Sep 30 18:04:08 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 901BB16A417; Sat, 30 Sep 2006 18:04:08 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 69C3E16A407 for ; Sat, 30 Sep 2006 18:04:08 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5C11C43D7E for ; Sat, 30 Sep 2006 18:03:55 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UI3tNV095560 for ; Sat, 30 Sep 2006 18:03:55 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UI3t9H095557 for perforce@freebsd.org; Sat, 30 Sep 2006 18:03:55 GMT (envelope-from piso@freebsd.org) Date: Sat, 30 Sep 2006 18:03:55 GMT Message-Id: <200609301803.k8UI3t9H095557@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 107007 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 18:04:08 -0000 http://perforce.freebsd.org/chv.cgi?CH=107007 Change 107007 by piso@piso_newluxor on 2006/09/30 18:02:56 Affected files ... .. //depot/projects/soc2005/libalias/sys/conf/files#10 edit .. //depot/projects/soc2005/libalias/sys/netinet/libalias/libalias.3#8 edit Differences ... ==== //depot/projects/soc2005/libalias/sys/conf/files#10 (text+ko) ==== @@ -1745,10 +1745,10 @@ netinet/udp_usrreq.c optional inet netinet/libalias/alias.c optional libalias netinet/libalias/alias_db.c optional libalias +netinet/libalias/alias_mod.c optional libalias +netinet/libalias/alias_old.c optional libalias netinet/libalias/alias_proxy.c optional libalias netinet/libalias/alias_util.c optional libalias -netinet/libalias/alias_old.c optional libalias -netinet/libalias/alias_mod.c optional libalias netinet6/ah_aesxcbcmac.c optional ipsec netinet6/ah_core.c optional ipsec netinet6/ah_input.c optional ipsec ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/libalias.3#8 (text+ko) ==== @@ -1016,259 +1016,217 @@ random and unrelated to the local port number. .Sh MODULAR ARCHITECTURE (AND Xr ipfw 4 Sh SUPPORT) One of the latest improvements to -.Nm libalias was to make its support +.Nm +was to make its support for new protocols independent from the rest of the library, giving it -the ability to load/unload at run-time support for new protocols. +the ability to load/unload support for new protocols at run-time. To achieve this feature, all the code for protocol handling was moved to a series of modules outside of the main library. -These modules are compiled from the same sources but works in a +These modules are compiled from the same sources but work in different ways, depending on whether they are compiled to work inside a kernel or as part of the userland library. .Ss LIBALIAS MODULES IN KERNEL LAND -When compiled to be parts of a kernel, -.Nm libalias -modules are plain simple KLDs: +When compiled for the kernel, +.Nm +modules are plain KLDs recognizable with the "alias_" prefix. .Pp -.Bl -item -compact -.It -.Pa /boot/kernel/alias_cuseeme.ko -.It -.Pa /boot/kernel/alias_dummy.ko -.It -.Pa /boot/kernel/alias_ftp.ko -.It -.Pa /boot/kernel/alias_irc.ko -.It -.Pa /boot/kernel/alias_nbt.ko -.It -.Pa /boot/kernel/alias_pptp.ko -.It -.Pa /boot/kernel/alias_skinny.ko -.It -.Pa /boot/kernel/alias_smedia.ko -.El +To add support for a new protocol, load the corresponding module. +For example: .Pp -To add support for new protocol just kldload its module, for example: +.Dl "kldload alias_ftp" .Pp -.Dl "kldload alias_ftp +When support for a protocol is no longer needed, its module can be unloaded: .Pp -and when you don't need it anymore, you can unload it: -.Pp -.Dl "kldunload alias_ftp +.Dl "kldunload alias_ftp" .Ss LIBALIAS MODULES IN USERLAND -Due to the differences between kernel and userland (no kld mechanism, -many different address spaces, etc etc), we had to change a bit how to -handle modules loading/tracking/unloading in userland. +Due to the differences between kernel and userland (no KLD mechanism, +many different address spaces, etc.), we had to change a bit how to +handle module loading/tracking/unloading in userland. .Pp While compiled for a userland -.Nm libalias -all the modules are plain libraries: +.Nm , +all the modules are plain libraries, residing in /usr/lib, and recognizable with the "libalias_" prefix. .Pp -.Bl -item -compact -.It -.Pa /usr/lib/libalias_cuseeme.a -.It -.Pa /usr/lib/libalias_cuseeme.so -> /lib/libalias_cuseeme.so.4 -.It -.Pa /usr/lib/libalias_cuseeme_p.a -.It -.Pa /usr/lib/libalias_dummy.a -.It -.Pa /usr/lib/libalias_dummy.so -> /lib/libalias_dummy.so.4 -.It -.Pa /usr/lib/libalias_dummy_p.a -.It -.Pa /usr/lib/libalias_ftp.a -.It -.Pa /usr/lib/libalias_ftp.so -> /lib/libalias_ftp.so.4 -.It -.Pa /usr/lib/libalias_ftp_p.a -.It -.Pa /usr/lib/libalias_irc.a -.It -.Pa /usr/lib/libalias_irc.so -> /lib/libalias_irc.so.4 -.It -.Pa /usr/lib/libalias_irc_p.a -.It -.Pa /usr/lib/libalias_nbt.a -.It -.Pa /usr/lib/libalias_nbt.so -> /lib/libalias_nbt.so.4 -.It -.Pa /usr/lib/libalias_nbt_p.a -.It -.Pa /usr/lib/libalias_pptp.a -.It -.Pa /usr/lib/libalias_pptp.so -> /lib/libalias_pptp.so.4 -.It -.Pa /usr/lib/libalias_pptp_p.a -.It -.Pa /usr/lib/libalias_skinny.a -.It -.Pa /usr/lib/libalias_skinny.so -> /lib/libalias_skinny.so.4 -.It -.Pa /usr/lib/libalias_skinny_p.a -.It -.Pa /usr/lib/libalias_smedia.a -.It -.Pa /usr/lib/libalias_smedia.so -> /lib/libalias_smedia.so.4 -.It -.Pa /usr/lib/libalias_smedia_p.a -.El +There is a configuration file, +.Pa /etc/libalias.conf , +with the following contents (by default): +.Bd -literal -offset indent +/usr/lib/libalias_cuseeme.so +/usr/lib/libalias_ftp.so +/usr/lib/libalias_irc.so +/usr/lib/libalias_nbt.so +/usr/lib/libalias_pptp.so +/usr/lib/libalias_skinny.so +/usr/lib/libalias_smedia.so +.Ed .Pp -To take advantage of modules, an application must be -patched to handle SIGHUP signal and call LibAliasRefreshModules() -whenever it receives that signal (see below for details). -.Pp -If you have correctly installed -.Nm libalias -in /etc you should -find a file called libalias.conf with the following contents (or -similar): -.Pp -.Bl -item -compact -.It -.Pa /usr/lib/libalias_cuseeme.so -.It -.Pa /usr/lib/libalias_ftp.so -.It -.Pa /usr/lib/libalias_irc.so -.It -.Pa /usr/lib/libalias_nbt.so -.It -.Pa /usr/lib/libalias_pptp.so -.It -.Pa /usr/lib/libalias_skinny.so -.It -.Pa /usr/lib/libalias_smedia.so -.El -.Pp -this file contains the paths to the modules that -.Nm libalias +This file contains the paths to the modules that +.Nm will load. -To load/unload a new module just add its path to libalias.conf and -send a SIGHUP signal to the application that needs the new module: +To load/unload a new module, just add its path to +.Pa libalias.conf +and call LibAliasRefreshModules from the program. +In case the application provides an HUP signal handler, add a call to LibAliasRefreshModules inside the handler, and everytime you want to refresh the loaded modules, send it the +.Dv SIGHUP +signal: .Pp -.Dl "kill -HUP +.Dl "kill -HUP " .Ss MODULAR ARCHITECURE: HOW IT WORKS The modular architecture of -.Nm libalias -work (almost) the same when it's -running inside kernel or in userland. From alias_mod.c: +.Nm +works similar whether it is running inside the +kernel or in userland. +From +.Pa alias_mod.c : +.Bd -literal +/* Protocol and userland module handlers chains. */ +LIST_HEAD(handler_chain, proto_handler) handler_chain \&... +\&... +SLIST_HEAD(dll_chain, dll) dll_chain \&... +.Ed +.Pp +.Va handler_chain +keep tracks of all the protocol handlers loaded, while +.Va ddl_chain +takes care of userland modules loaded. +.Pp +.Va handler_chain +is composed of +.Vt "struct proto_handler" +entries: .Bd -literal -/* protocol and userland module handlers chains */ -struct chain handler_chain, dll_chain; - -handler_chain keep tracks of all the protocol handlers loaded, while -ddl_chain takes care of userland modules loaded. - -handler_chain is composed of struct proto_handler entries: - struct proto_handler { - - /* handler priority */ - int pri; - /* flow direction */ - int16_t dir; - /* working protocol */ - int16_t proto; - /* fingerprint * function */ - int (*fingerprint)(struct libalias *la, + u_int pri; + int16_t dir; + uint8_t proto; + int (*fingerprint)(struct libalias *la, struct ip *pip, struct alias_data *ah); - /* aliasing * function */ - int (*protohandler)(struct libalias *la, - struct ip *pip, struct alias_data *ah); - struct proto_handler *next; + int (*protohandler)(struct libalias *la, + struct ip *pip, struct alias_data *ah); + LIST_ENTRY(proto_handler) entries; }; .Ed .Pp where: -.Pp -pri is the priority assigned to a protocol handler, lower +.Bl -inset +.It Va pri +is the priority assigned to a protocol handler, lower is better. -.Pp -dir is the direction of packets: ingoing or outgoing. -.Pp -proto says at which protocol this packet belongs: IP, TCP or UDP -.Pp -fingerprint points to the fingerprint function while protohandler points +.It Va dir +is the direction of packets: ingoing or outgoing. +.It Va proto +says at which protocol this packet belongs: IP, TCP or UDP. +.It Va fingerprint +points to the fingerprint function while protohandler points to the protocol handler function. +.El .Pp -The fingerprint function has the double of scope of checking if the -incoming packet is sound and if it belongs to any categories that this +The +.Va fingerprint +function has the double of scope of checking if the +incoming packet is found and if it belongs to any categories that this module can handle. .Pp -The protocol handler function is the function that actually manipulates +The +.Va protohandler +function actually manipulates the packet to make -.Nm libalias -correctly nat it. +.Nm +correctly NAT it. .Pp When a packet enters -.Nm libalias -, if it meets a module hook, -handler_chain is searched to see if there's an handler that match -this type of packet (it checks protocol and direction of packet), then if -more then one handler is found, it starts with the module with -a lower priority number: it calls fingerprints and read the result. +.Nm , +if it meets a module hook, +.Va handler_chain +is searched to see if there is an handler that matches +this type of a packet (it checks protocol and direction of packet), then if +more than one handler is found, it starts with the module with +the lowest priority number: it calls the +.Va fingerprint +function and interprets the result. .Pp -If the result value is equal to OK, then it calls the protocol handler -of this handler and return, else it skip to the fingerprint function -of the next eligible module, till the end of handler_chain +If the result value is equal to 0 then it calls the protocol handler +of this handler and returns. +Otherwise, it proceeds to the next eligible module until the +.Va handler_chain +is exhausted. .Pp Inside -.Nm libalias +.Nm , the module hook looks like this: -.Bd -literal - struct alias_data ad = { - lnk, - &original_address, - &alias_address, - &alias_port, - &ud->uh_sport, /* original source port */ - &ud->uh_dport, /* original dest port */ - 256 /* maxpacketsize */ - }; +.Bd -literal -offset indent +struct alias_data ad = { + lnk, + &original_address, + &alias_address, + &alias_port, + &ud->uh_sport, /* original source port */ + &ud->uh_dport, /* original dest port */ + 256 /* maxpacketsize */ +}; - ... +\&... - /* walk out chain */ - err = find_handler(IN, UDP, la, pip, &ad); +/* walk out chain */ +err = find_handler(IN, UDP, la, pip, &ad); .Ed -all data useful to a module are gathered together in a alias_data -structure, then find_handler is called. -find_handler is the function responsible of walking out the handler +.Pp +All data useful to a module are gathered together in an +.Vt alias_data +structure, then +.Fn find_handler +is called. +The +.Fn find_handler +function is responsible for walking out the handler chain, it receives as input parameters: +.Bl -tag -width indent +.It Fa IN +direction +.It Fa UDP +working protocol +.It Fa la +pointer to this instance of libalias +.It Fa pip +pointer to a +.Vt "struct ip" +.It Fa ad +pointer to +.Vt "struct alias_data" +(see above) +.El .Pp -IN: direction -.Pp -UDP: working protocol -.Pp -la: pointer to this instance of libalias -.Pp -pip: pointer to a struct ip -.Pp -ad: pointer to struct alias_data (see above) -.Pp -in this case, find_handler will search only for modules registered for +In this case, +.Fn find_handler +will search only for modules registered for supporting INcoming UDP packets. .Pp -As i said earlier, -.Nm libalias -in userland is a bit different, cause we -have to take care of module handling too (avoiding duplicate load of -module, avoiding module with same name, etc etc) so dll_chain was -introduced. +As was mentioned earlier, +.Nm +in userland is a bit different, cause +care has to be taken of module handling too (avoiding duplicate load of +module, avoiding module with same name, etc.) so +.Va dll_chain +was introduced. .Pp -dll_chain contains a list of all userland -.Nm libalias +.Va dll_chain +contains a list of all userland +.Nm modules loaded. .Pp -When an application calls LibAliasRefreshModules(), -.Nm libalias -first unload all the loaded modules, then reload all the modules listed in -/etc/libalias.conf: for every module loaded, a new entry to dll_chain +When an application calls +.Fn LibAliasRefreshModules , +.Nm +first unloads all the loaded modules, then reloads all the modules listed in +.Pa /etc/libalias.conf : +for every module loaded, a new entry to +.Va dll_chain is added. .Pp -dll_chain is composed of struct dll entries: +.Va dll_chain +is composed of +.Vt "struct dll" +entries: .Bd -literal struct dll { /* name of module */ @@ -1276,44 +1234,64 @@ /* * ptr to shared obj obtained through * dlopen() - use this ptr to get access - * to any symbols from a loaded module + * to any symbols from a loaded module * via dlsym() */ void *handle; struct dll *next; -}; -.Ed -name is the name of the module -.Pp -handle is a pointer to the module obtained through dlopen() -.Pp +}; +.Ed +.Bl -inset +.It Va name +is the name of the module +.It Va handle +is a pointer to the module obtained through +.Xr dlopen 3 +.El Whenever a module is loaded in userland, an entry is added to -dll_chain, than every protocol handler present in that module -is resolved and registered in handler_chain. +.Va dll_chain , +then every protocol handler present in that module +is resolved and registered in +.Va handler_chain . .Ss HOW TO WRITE A MODULE FOR LIBALIAS -There's a module (called alias_dummy.[ch]) in -.Nm libalias +There is a module (called +.Pa alias_dummy.[ch] ) +in +.Nm that can be used as a skeleton for future work, here we analyse some parts of that module. -From alias_dummy.c: +From +.Pa alias_dummy.c : .Bd -literal struct proto_handler handlers [] = {{666, IN|OUT, UDP|TCP, &fingerprint, &protohandler}}; .Ed .Pp -The variable 'handlers' is the 'most important thing' in your module, -cause it describes the handlers present and let the outside world use +The variable +.Va handlers +is the +.Dq "most important thing" +in a module +cause it describes the handlers present and lets the outside world use it in an opaque way. .Pp It must ALWAYS be present in every module, and it MUST retain -the name 'handlers', else if you'll try to load -this module in userland, it will complain about missing symbols: for -more info about module load/unload, please refer to -LibAliasRefreshModules, LibAliasLoadModule and LibAliasUnloadModule in -alias.c +the name +.Va handlers , +otherwise attempting to load a module in userland will fail and +complain about missing symbols: for more information about module +load/unload, please refer to +.Fn LibAliasRefreshModules , +.Fn LibAliasLoadModule +and +.Fn LibAliasUnloadModule +in +.Pa alias.c . .Pp -handlers[] contains all the proto_handler structures present in a -module. +.Va handlers +contains all the +.Vt proto_handler +structures present in a module. .Bd -literal static int mod_handler(module_t mod, int type, void *data) @@ -1335,8 +1313,13 @@ return (error); } .Ed -When running as kld, mod_handler register/deregister the module using -attach_handlers/detach_handlers respectively. +When running as KLD, +.Fn mod_handler +register/deregister the module using +.Fn attach_handlers +and +.Fn detach_handlers , +respectively. .Pp Every module must contain at least 2 functions: one fingerprint function and a protocol handler function. @@ -1348,7 +1331,7 @@ fingerprint(struct libalias *la, struct ip *pip, struct alias_data *ah) { -... +\&... } #ifdef _KERNEL @@ -1359,59 +1342,73 @@ struct alias_data *ah) { -... +\&... } .Ed and they must accept exactly these input parameters. .Ss PATCHING AN APPLICATION FOR USERLAND LIBALIAS MODULES -If you have any application that uses -.Nm libalias -and you want to add it -support for modules, then follow this simple 5 steps -procedure. -.Bd -ragged -offset indent -.An -split -.An 1) first, figure out which file is the main file of your program -.An (let's call it main.c) -.An 2) add this to the header section of main,c, if not already -.An present: +To add module support into an application that uses +.Nm , +the following simple steps can be followed. +.Bl -enum +.It +Find the main file of an application +(let us call it +.Pa main.c ) . +.It +Add this to the header section of +.Pa main.c , +if not already present: .Pp -.An #include +.Dl "#include " .Pp -.An 3) and this just after the header section: +and this just after the header section: .Pp -.An static void signal_handler(int); +.Dl "static void signal_handler(int);" +.It +Add the following line to the init function of an application or, +if it does not have any init function, put it in +.Fn main : .Pp -.An 4) add this line in the init function of you program or, if it -.An doesn't have any init function, put it in main(): +.Dl "signal(SIGHUP, signal_handler);" .Pp -.An signal(SIGHUP, signal_handler); +and place the +.Fn signal_handler +function somewhere in +.Pa main.c : +.Bd -literal -offset indent +static void +signal_handler(int sig) +{ + + LibAliasRefreshModules(); +} +.Ed .Pp -.An 5) and place this function somewhere in main.c: +Otherwise, if an application already traps the +.Dv SIGHUP +signal, just add a call to +.Fn LibAliasRefreshModules +in the signal handler function. +.El +For example, to patch +.Xr natd 8 +to use +.Nm +modules, just add the following line to +.Fn RefreshAddr "int sig __unused" : .Pp -.An static void -.An signal_handler(int sig) -.An { -.Pp -.An LibAliasRefreshModules(); -.An } +.Dl "LibAliasRefreshModules()" .Pp -.An else, if your program already trap SIGHUP signal, just add a call -.An to LibAliasRefreshModules() in the function serving that signal. -.Pp -.An For example, to patch natd to use libalias modules, just add -.An the following line to RefreshAddr (int sig __unused): -.Pp -.An LibAliasRefreshModules() -.Pp -.An recompile and you are done. -.Ed +recompile and you are done. .Ss LOGGING SUPPORT IN KERNEL LAND -.Pp -While working as kld, -.Nm libalias -now have log support that -happens on a buffer allocated inside struct libalias(from alias_local.h): +When working as KLD, +.Nm +now has log support that +happens on a buffer allocated inside +.Vt "struct libalias" +(from +.Pa alias_local.h ) : .Bd -literal struct libalias { ... @@ -1431,12 +1428,18 @@ */ #endif -... + ... } .Ed -so all the applications using -.Nm libalias -, will be able to handle their -own logs, if they want, accessing logDesc. -Moreover, every change to log buffer is automatically added to syslog -with facilities security and info. +so all applications using +.Nm +will be able to handle their +own logs, if they want, accessing +.Va logDesc . +Moreover, every change to a log buffer is automatically added to +.Xr syslog 3 +with the +.Dv LOG_SECURITY +facility and the +.Dv LOG_INFO +level. From owner-p4-projects@FreeBSD.ORG Sat Sep 30 18:07:00 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 40AEA16A4E9; Sat, 30 Sep 2006 18:07:00 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 1C3E916A47C for ; Sat, 30 Sep 2006 18:07:00 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9713D43D5A for ; Sat, 30 Sep 2006 18:06:59 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UI6xGl095846 for ; Sat, 30 Sep 2006 18:06:59 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UI6x6O095838 for perforce@freebsd.org; Sat, 30 Sep 2006 18:06:59 GMT (envelope-from piso@freebsd.org) Date: Sat, 30 Sep 2006 18:06:59 GMT Message-Id: <200609301806.k8UI6x6O095838@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 107008 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 18:07:00 -0000 http://perforce.freebsd.org/chv.cgi?CH=107008 Change 107008 by piso@piso_newluxor on 2006/09/30 18:06:28 Forced commit: sorted alias* files. Affected files ... .. //depot/projects/soc2005/libalias/sys/conf/files#11 edit Differences ... ==== //depot/projects/soc2005/libalias/sys/conf/files#11 (text+ko) ==== From owner-p4-projects@FreeBSD.ORG Sat Sep 30 18:10:04 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 5251516A47E; Sat, 30 Sep 2006 18:10:04 +0000 (UTC) X-Original-To: perforce@freebsd.org 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 2DBAC16A40F for ; Sat, 30 Sep 2006 18:10:04 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id CBC0A43D45 for ; Sat, 30 Sep 2006 18:10:03 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k8UIA3jU095965 for ; Sat, 30 Sep 2006 18:10:03 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k8UIA3AO095962 for perforce@freebsd.org; Sat, 30 Sep 2006 18:10:03 GMT (envelope-from piso@freebsd.org) Date: Sat, 30 Sep 2006 18:10:03 GMT Message-Id: <200609301810.k8UIA3AO095962@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 107009 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 18:10:04 -0000 http://perforce.freebsd.org/chv.cgi?CH=107009 Change 107009 by piso@piso_newluxor on 2006/09/30 18:09:25 Forced commit: -mdoc and grammar fixes -deleted stuff not pertinent to a .3 man page section -reduced usage of verb 'must' -synced some examples with source code Obtained from: ru with minor tweaks by me Affected files ... .. //depot/projects/soc2005/libalias/sys/netinet/libalias/libalias.3#9 edit Differences ... ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/libalias.3#9 (text+ko) ====