From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 00:04:02 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id CAF591065670; Sun, 2 Jan 2011 00:04:02 +0000 (UTC) Date: Sun, 2 Jan 2011 00:04:02 +0000 From: Alexander Best To: Sean Farley Message-ID: <20110102000402.GA65041@freebsd.org> References: <201012300218.oBU2I4BF020068@svn.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201012300218.oBU2I4BF020068@svn.freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216813 - head/sys/compat/linux X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 00:04:02 -0000 On Thu Dec 30 10, Sean Farley wrote: > Author: scf > Date: Thu Dec 30 02:18:04 2010 > New Revision: 216813 > URL: http://svn.freebsd.org/changeset/base/216813 > > Log: > Fix the LINUX_SOUND_MIXER_INFO ioctl to return success after the > information is set to FreeBSD. It had been falling through to the end > of linux_ioctl_sound() and returning ENOIOCTL. Noticed when running the > Linux ALSA amixer tool. > > Add a LINUX_SOUND_MIXER_READ_CAPS ioctl which is used by the Skype > v2.1.0.81 binary. i'm running r216877 and still skype won't detect my audio devices (i.e. it reports "Problem With Audio Playback"). this is with the static skype binary package. cheers. alex > > Reviewed by: gavin > MFC after: 2 weeks > > Modified: > head/sys/compat/linux/linux_ioctl.c > head/sys/compat/linux/linux_ioctl.h > > Modified: head/sys/compat/linux/linux_ioctl.c > ============================================================================== > --- head/sys/compat/linux/linux_ioctl.c Thu Dec 30 01:28:56 2010 (r216812) > +++ head/sys/compat/linux/linux_ioctl.c Thu Dec 30 02:18:04 2010 (r216813) > @@ -1749,7 +1749,7 @@ linux_ioctl_sound(struct thread *td, str > strncpy(info.id, "OSS", sizeof(info.id) - 1); > strncpy(info.name, "FreeBSD OSS Mixer", sizeof(info.name) - 1); > copyout(&info, (void *)args->arg, sizeof(info)); > - break; > + return (0); > } > case 0x0030: { /* SOUND_OLD_MIXER_INFO */ > struct linux_old_mixer_info info; > @@ -1757,7 +1757,7 @@ linux_ioctl_sound(struct thread *td, str > strncpy(info.id, "OSS", sizeof(info.id) - 1); > strncpy(info.name, "FreeBSD OSS Mixer", sizeof(info.name) - 1); > copyout(&info, (void *)args->arg, sizeof(info)); > - break; > + return (0); > } > default: > return (ENOIOCTL); > @@ -1774,6 +1774,10 @@ linux_ioctl_sound(struct thread *td, str > args->cmd = SOUND_MIXER_READ_STEREODEVS; > return (ioctl(td, (struct ioctl_args *)args)); > > + case LINUX_SOUND_MIXER_READ_CAPS: > + args->cmd = SOUND_MIXER_READ_CAPS; > + return (ioctl(td, (struct ioctl_args *)args)); > + > case LINUX_SOUND_MIXER_READ_RECMASK: > args->cmd = SOUND_MIXER_READ_RECMASK; > return (ioctl(td, (struct ioctl_args *)args)); > > Modified: head/sys/compat/linux/linux_ioctl.h > ============================================================================== > --- head/sys/compat/linux/linux_ioctl.h Thu Dec 30 01:28:56 2010 (r216812) > +++ head/sys/compat/linux/linux_ioctl.h Thu Dec 30 02:18:04 2010 (r216813) > @@ -267,6 +267,7 @@ > #define LINUX_SOUND_MIXER_INFO 0x4d65 > #define LINUX_OSS_GETVERSION 0x4d76 > #define LINUX_SOUND_MIXER_READ_STEREODEVS 0x4dfb > +#define LINUX_SOUND_MIXER_READ_CAPS 0x4dfc > #define LINUX_SOUND_MIXER_READ_RECMASK 0x4dfd > #define LINUX_SOUND_MIXER_READ_DEVMASK 0x4dfe > #define LINUX_SOUND_MIXER_WRITE_RECSRC 0x4dff -- a13x From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 10:27:27 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 78B8A106566C; Sun, 2 Jan 2011 10:27:27 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4E25B8FC0C; Sun, 2 Jan 2011 10:27:27 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02ARRxj041455; Sun, 2 Jan 2011 10:27:27 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02ARRUN041453; Sun, 2 Jan 2011 10:27:27 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201101021027.p02ARRUN041453@svn.freebsd.org> From: Michael Tuexen Date: Sun, 2 Jan 2011 10:27:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216887 - head/sys/netinet X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 10:27:27 -0000 Author: tuexen Date: Sun Jan 2 10:27:27 2011 New Revision: 216887 URL: http://svn.freebsd.org/changeset/base/216887 Log: Bugfix: Make sure that the COMM_UP notificatin is delivered first also on the passive side. MFC after: 3 days. Modified: head/sys/netinet/sctp_input.c Modified: head/sys/netinet/sctp_input.c ============================================================================== --- head/sys/netinet/sctp_input.c Sun Jan 2 10:01:29 2011 (r216886) +++ head/sys/netinet/sctp_input.c Sun Jan 2 10:27:27 2011 (r216887) @@ -2311,6 +2311,7 @@ sctp_handle_cookie_echo(struct mbuf *m, int notification = 0; struct sctp_nets *netl; int had_a_existing_tcb = 0; + int send_int_conf = 0; SCTPDBG(SCTP_DEBUG_INPUT2, "sctp_handle_cookie: handling COOKIE-ECHO\n"); @@ -2630,8 +2631,7 @@ sctp_handle_cookie_echo(struct mbuf *m, netl->dest_state &= ~SCTP_ADDR_UNCONFIRMED; (void)sctp_set_primary_addr((*stcb), (struct sockaddr *)NULL, netl); - sctp_ulp_notify(SCTP_NOTIFY_INTERFACE_CONFIRMED, - (*stcb), 0, (void *)netl, SCTP_SO_NOT_LOCKED); + send_int_conf = 1; } } if (*stcb) { @@ -2655,6 +2655,10 @@ sctp_handle_cookie_echo(struct mbuf *m, * socket, no need to do anything. I THINK!! */ sctp_ulp_notify(notification, *stcb, 0, (void *)&sac_restart_id, SCTP_SO_NOT_LOCKED); + if (send_int_conf) { + sctp_ulp_notify(SCTP_NOTIFY_INTERFACE_CONFIRMED, + (*stcb), 0, (void *)netl, SCTP_SO_NOT_LOCKED); + } return (m); } oso = (*inp_p)->sctp_socket; @@ -2766,7 +2770,10 @@ sctp_handle_cookie_echo(struct mbuf *m, /* Switch over to the new guy */ *inp_p = inp; sctp_ulp_notify(notification, *stcb, 0, NULL, SCTP_SO_NOT_LOCKED); - + if (send_int_conf) { + sctp_ulp_notify(SCTP_NOTIFY_INTERFACE_CONFIRMED, + (*stcb), 0, (void *)netl, SCTP_SO_NOT_LOCKED); + } /* * Pull it from the incomplete queue and wake the * guy @@ -2785,8 +2792,14 @@ sctp_handle_cookie_echo(struct mbuf *m, return (m); } } - if ((notification) && ((*inp_p)->sctp_flags & SCTP_PCB_FLAGS_UDPTYPE)) { - sctp_ulp_notify(notification, *stcb, 0, NULL, SCTP_SO_NOT_LOCKED); + if ((*inp_p)->sctp_flags & SCTP_PCB_FLAGS_UDPTYPE) { + if (notification) { + sctp_ulp_notify(notification, *stcb, 0, NULL, SCTP_SO_NOT_LOCKED); + } + if (send_int_conf) { + sctp_ulp_notify(SCTP_NOTIFY_INTERFACE_CONFIRMED, + (*stcb), 0, (void *)netl, SCTP_SO_NOT_LOCKED); + } } return (m); } From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 12:16:58 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2942E106564A; Sun, 2 Jan 2011 12:16:58 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 188148FC13; Sun, 2 Jan 2011 12:16:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02CGv5H045215; Sun, 2 Jan 2011 12:16:57 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02CGvMC045213; Sun, 2 Jan 2011 12:16:57 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201101021216.p02CGvMC045213@svn.freebsd.org> From: Edward Tomasz Napierala Date: Sun, 2 Jan 2011 12:16:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216888 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 12:16:58 -0000 Author: trasz Date: Sun Jan 2 12:16:57 2011 New Revision: 216888 URL: http://svn.freebsd.org/changeset/base/216888 Log: Finishing touches to fork1() - ANSIfy missed function definition, style(9) fixes, removal of few comments that didn't really make sense and addition of fork_findpid() locking requirements. Modified: head/sys/kern/kern_fork.c Modified: head/sys/kern/kern_fork.c ============================================================================== --- head/sys/kern/kern_fork.c Sun Jan 2 10:27:27 2011 (r216887) +++ head/sys/kern/kern_fork.c Sun Jan 2 12:16:57 2011 (r216888) @@ -112,9 +112,7 @@ fork(struct thread *td, struct fork_args /* ARGSUSED */ int -vfork(td, uap) - struct thread *td; - struct vfork_args *uap; +vfork(struct thread *td, struct vfork_args *uap) { int error, flags; struct proc *p2; @@ -200,7 +198,12 @@ fork_findpid(int flags) int trypid; static int pidchecked = 0; - sx_assert(&allproc_lock, SX_XLOCKED); + /* + * Requires allproc_lock in order to iterate over the list + * of processes, and proctree_lock to access p_pgrp. + */ + sx_assert(&allproc_lock, SX_LOCKED); + sx_assert(&proctree_lock, SX_LOCKED); /* * Find an unused process ID. We remember a range of unused IDs @@ -281,7 +284,7 @@ again: } static int -fork_norfproc(struct thread *td, int flags, struct proc **procp) +fork_norfproc(struct thread *td, int flags) { int error; struct proc *p1; @@ -289,7 +292,6 @@ fork_norfproc(struct thread *td, int fla KASSERT((flags & RFPROC) == 0, ("fork_norfproc called with RFPROC set")); p1 = td->td_proc; - *procp = NULL; if (((p1->p_flag & (P_HADTHREADS|P_SYSTEM)) == P_HADTHREADS) && (flags & (RFCFDG | RFFDG))) { @@ -408,14 +410,12 @@ do_fork(struct thread *td, int flags, st } else { fd = fdshare(p1->p_fd); if (p1->p_fdtol == NULL) - p1->p_fdtol = - filedesc_to_leader_alloc(NULL, - NULL, - p1->p_leader); + p1->p_fdtol = filedesc_to_leader_alloc(NULL, NULL, + p1->p_leader); if ((flags & RFTHREAD) != 0) { /* - * Shared file descriptor table and - * shared process leaders. + * Shared file descriptor table, and shared + * process leaders. */ fdtol = p1->p_fdtol; FILEDESC_XLOCK(p1->p_fd); @@ -423,12 +423,11 @@ do_fork(struct thread *td, int flags, st FILEDESC_XUNLOCK(p1->p_fd); } else { /* - * Shared file descriptor table, and - * different process leaders + * Shared file descriptor table, and different + * process leaders. */ fdtol = filedesc_to_leader_alloc(p1->p_fdtol, - p1->p_fd, - p2); + p1->p_fd, p2); } } /* @@ -492,7 +491,7 @@ do_fork(struct thread *td, int flags, st PROC_UNLOCK(p1); PROC_UNLOCK(p2); - /* Bump references to the text vnode (for procfs) */ + /* Bump references to the text vnode (for procfs). */ if (p2->p_textvp) vref(p2->p_textvp); @@ -622,7 +621,6 @@ do_fork(struct thread *td, int flags, st /* * Both processes are set up, now check if any loadable modules want * to adjust anything. - * What if they have an error? XXX */ EVENTHANDLER_INVOKE(process_fork, p1, p2, flags); @@ -682,7 +680,6 @@ do_fork(struct thread *td, int flags, st while (p2->p_flag & P_PPWAIT) cv_wait(&p2->p_pwait, &p2->p_mtx); PROC_UNLOCK(p2); - } int @@ -708,14 +705,10 @@ fork1(struct thread *td, int flags, int * Here we don't create a new process, but we divorce * certain parts of a process from itself. */ - if ((flags & RFPROC) == 0) - return (fork_norfproc(td, flags, procp)); - - /* - * XXX - * We did have single-threading code here - * however it proved un-needed and caused problems - */ + if ((flags & RFPROC) == 0) { + *procp = NULL; + return (fork_norfproc(td, flags)); + } mem_charged = 0; vm2 = NULL; From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 15:01:04 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 65B371065672; Sun, 2 Jan 2011 15:01:04 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 31E838FC08; Sun, 2 Jan 2011 15:01:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02F14im049346; Sun, 2 Jan 2011 15:01:04 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02F14xV049344; Sun, 2 Jan 2011 15:01:04 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101021501.p02F14xV049344@svn.freebsd.org> From: Marius Strobl Date: Sun, 2 Jan 2011 15:01:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216891 - head/sys/sparc64/sparc64 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 15:01:04 -0000 Author: marius Date: Sun Jan 2 15:01:03 2011 New Revision: 216891 URL: http://svn.freebsd.org/changeset/base/216891 Log: Extend the section in which interrupts are disabled in the TLB demap functions, otherwise if we get preempted after checking whether a certain pmap is active on the current CPU but before disabling interrupts we might operate on an outdated state as the pmap might have been deactivated in the meantime. As the same issue may arises when the TLB demap function is interrupted by a TLB demap IPI, just entering a critical section before the check isn't sufficient so we have to fully disable interrupts instead. MFC after: 3 days Modified: head/sys/sparc64/sparc64/tlb.c Modified: head/sys/sparc64/sparc64/tlb.c ============================================================================== --- head/sys/sparc64/sparc64/tlb.c Sun Jan 2 13:31:10 2011 (r216890) +++ head/sys/sparc64/sparc64/tlb.c Sun Jan 2 15:01:03 2011 (r216891) @@ -80,15 +80,15 @@ tlb_context_demap(struct pmap *pm) */ PMAP_STATS_INC(tlb_ncontext_demap); cookie = ipi_tlb_context_demap(pm); + s = intr_disable(); if (pm->pm_active & PCPU_GET(cpumask)) { KASSERT(pm->pm_context[curcpu] != -1, ("tlb_context_demap: inactive pmap?")); - s = intr_disable(); stxa(TLB_DEMAP_PRIMARY | TLB_DEMAP_CONTEXT, ASI_DMMU_DEMAP, 0); stxa(TLB_DEMAP_PRIMARY | TLB_DEMAP_CONTEXT, ASI_IMMU_DEMAP, 0); flush(KERNBASE); - intr_restore(s); } + intr_restore(s); ipi_wait(cookie); } @@ -101,6 +101,7 @@ tlb_page_demap(struct pmap *pm, vm_offse PMAP_STATS_INC(tlb_npage_demap); cookie = ipi_tlb_page_demap(pm, va); + s = intr_disable(); if (pm->pm_active & PCPU_GET(cpumask)) { KASSERT(pm->pm_context[curcpu] != -1, ("tlb_page_demap: inactive pmap?")); @@ -109,12 +110,11 @@ tlb_page_demap(struct pmap *pm, vm_offse else flags = TLB_DEMAP_PRIMARY | TLB_DEMAP_PAGE; - s = intr_disable(); stxa(TLB_DEMAP_VA(va) | flags, ASI_DMMU_DEMAP, 0); stxa(TLB_DEMAP_VA(va) | flags, ASI_IMMU_DEMAP, 0); flush(KERNBASE); - intr_restore(s); } + intr_restore(s); ipi_wait(cookie); } @@ -128,6 +128,7 @@ tlb_range_demap(struct pmap *pm, vm_offs PMAP_STATS_INC(tlb_nrange_demap); cookie = ipi_tlb_range_demap(pm, start, end); + s = intr_disable(); if (pm->pm_active & PCPU_GET(cpumask)) { KASSERT(pm->pm_context[curcpu] != -1, ("tlb_range_demap: inactive pmap?")); @@ -136,13 +137,12 @@ tlb_range_demap(struct pmap *pm, vm_offs else flags = TLB_DEMAP_PRIMARY | TLB_DEMAP_PAGE; - s = intr_disable(); for (va = start; va < end; va += PAGE_SIZE) { stxa(TLB_DEMAP_VA(va) | flags, ASI_DMMU_DEMAP, 0); stxa(TLB_DEMAP_VA(va) | flags, ASI_IMMU_DEMAP, 0); flush(KERNBASE); } - intr_restore(s); } + intr_restore(s); ipi_wait(cookie); } From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 15:06:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 24A331065733; Sun, 2 Jan 2011 15:06:08 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 144948FC08; Sun, 2 Jan 2011 15:06:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02F67ek049494; Sun, 2 Jan 2011 15:06:07 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02F67q2049492; Sun, 2 Jan 2011 15:06:07 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201101021506.p02F67q2049492@svn.freebsd.org> From: Gavin Atkinson Date: Sun, 2 Jan 2011 15:06:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216892 - head/sys/pc98/pc98 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 15:06:08 -0000 Author: gavin Date: Sun Jan 2 15:06:07 2011 New Revision: 216892 URL: http://svn.freebsd.org/changeset/base/216892 Log: MFi386 r216012 by kib: Calling fill_fpregs() for curthread is legitimate, and ELF coredump does this. Discussed with: kib MFC after: 3 days Modified: head/sys/pc98/pc98/machdep.c Modified: head/sys/pc98/pc98/machdep.c ============================================================================== --- head/sys/pc98/pc98/machdep.c Sun Jan 2 15:01:03 2011 (r216891) +++ head/sys/pc98/pc98/machdep.c Sun Jan 2 15:06:07 2011 (r216892) @@ -2551,7 +2551,8 @@ int fill_fpregs(struct thread *td, struct fpreg *fpregs) { - KASSERT(TD_IS_SUSPENDED(td), ("not suspended thread %p", td)); + KASSERT(td == curthread || TD_IS_SUSPENDED(td), + ("not suspended thread %p", td)); npxgetregs(td); #ifdef CPU_ENABLE_SSE if (cpu_fxsr) From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 19:58:39 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 989CE1065670; Sun, 2 Jan 2011 19:58:39 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 86E5B8FC08; Sun, 2 Jan 2011 19:58:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02JwdwM056662; Sun, 2 Jan 2011 19:58:39 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02JwdtC056657; Sun, 2 Jan 2011 19:58:39 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101021958.p02JwdtC056657@svn.freebsd.org> From: Rick Macklem Date: Sun, 2 Jan 2011 19:58:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216893 - head/sys/fs/nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 19:58:39 -0000 Author: rmacklem Date: Sun Jan 2 19:58:39 2011 New Revision: 216893 URL: http://svn.freebsd.org/changeset/base/216893 Log: Add checks for VI_DOOMED and vn_lock() failures to the experimental NFS server, to handle the case where an exported file system is forced dismounted while an RPC is in progress. Further commits will fix the cases where a mount point is used when the associated vnode isn't locked. Reviewed by: kib MFC after: 2 weeks Modified: head/sys/fs/nfsserver/nfs_nfsdport.c head/sys/fs/nfsserver/nfs_nfsdserv.c head/sys/fs/nfsserver/nfs_nfsdsocket.c head/sys/fs/nfsserver/nfs_nfsdstate.c Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Sun Jan 2 15:06:07 2011 (r216892) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Sun Jan 2 19:58:39 2011 (r216893) @@ -153,6 +153,10 @@ nfsvno_accchk(struct vnode *vp, accmode_ struct vattr vattr; int error = 0, getret = 0; + if (vpislocked == 0) { + if (vn_lock(vp, LK_SHARED) != 0) + return (EPERM); + } if (accmode & VWRITE) { /* Just vn_writechk() changed to check rdonly */ /* @@ -166,7 +170,7 @@ nfsvno_accchk(struct vnode *vp, accmode_ case VREG: case VDIR: case VLNK: - return (EROFS); + error = EROFS; default: break; } @@ -176,11 +180,14 @@ nfsvno_accchk(struct vnode *vp, accmode_ * the inode, try to free it up once. If * we fail, we can't allow writing. */ - if (vp->v_vflag & VV_TEXT) - return (ETXTBSY); + if ((vp->v_vflag & VV_TEXT) != 0 && error == 0) + error = ETXTBSY; + } + if (error != 0) { + if (vpislocked == 0) + VOP_UNLOCK(vp, 0); + return (error); } - if (vpislocked == 0) - vn_lock(vp, LK_SHARED | LK_RETRY); /* * Should the override still be applied when ACLs are enabled? @@ -1097,9 +1104,11 @@ nfsvno_rename(struct nameidata *fromndp, goto out; } if (ndflag & ND_NFSV4) { - NFSVOPLOCK(fvp, LK_EXCLUSIVE | LK_RETRY, p); - error = nfsrv_checkremove(fvp, 0, p); - NFSVOPUNLOCK(fvp, 0, p); + if (vn_lock(fvp, LK_EXCLUSIVE) == 0) { + error = nfsrv_checkremove(fvp, 0, p); + VOP_UNLOCK(fvp, 0); + } else + error = EPERM; if (tvp && !error) error = nfsrv_checkremove(tvp, 1, p); } else { @@ -1156,13 +1165,16 @@ nfsvno_link(struct nameidata *ndp, struc error = EXDEV; } if (!error) { - NFSVOPLOCK(vp, LK_EXCLUSIVE | LK_RETRY, p); - error = VOP_LINK(ndp->ni_dvp, vp, &ndp->ni_cnd); + vn_lock(vp, LK_EXCLUSIVE | LK_RETRY); + if ((vp->v_iflag & VI_DOOMED) == 0) + error = VOP_LINK(ndp->ni_dvp, vp, &ndp->ni_cnd); + else + error = EPERM; if (ndp->ni_dvp == vp) vrele(ndp->ni_dvp); else vput(ndp->ni_dvp); - NFSVOPUNLOCK(vp, 0, p); + VOP_UNLOCK(vp, 0); } else { if (ndp->ni_dvp == ndp->ni_vp) vrele(ndp->ni_dvp); @@ -2793,6 +2805,11 @@ nfsvno_advlock(struct vnode *vp, int fty if (nfsrv_dolocallocks == 0) return (0); + + /* Check for VI_DOOMED here, so that VOP_ADVLOCK() isn't performed. */ + if ((vp->v_iflag & VI_DOOMED) != 0) + return (EPERM); + fl.l_whence = SEEK_SET; fl.l_type = ftype; fl.l_start = (off_t)first; Modified: head/sys/fs/nfsserver/nfs_nfsdserv.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdserv.c Sun Jan 2 15:06:07 2011 (r216892) +++ head/sys/fs/nfsserver/nfs_nfsdserv.c Sun Jan 2 19:58:39 2011 (r216893) @@ -2676,9 +2676,12 @@ nfsrvd_open(struct nfsrv_descript *nd, _ }; stp->ls_flags |= NFSLCK_RECLAIM; vp = dp; - NFSVOPLOCK(vp, LK_EXCLUSIVE | LK_RETRY, p); - nd->nd_repstat = nfsrv_opencheck(clientid, &stateid, stp, vp, - nd, p, nd->nd_repstat); + vn_lock(vp, LK_EXCLUSIVE | LK_RETRY); + if ((vp->v_iflag & VI_DOOMED) == 0) + nd->nd_repstat = nfsrv_opencheck(clientid, &stateid, + stp, vp, nd, p, nd->nd_repstat); + else + nd->nd_repstat = NFSERR_PERM; } else { nd->nd_repstat = NFSERR_BADXDR; vrele(dp); Modified: head/sys/fs/nfsserver/nfs_nfsdsocket.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdsocket.c Sun Jan 2 15:06:07 2011 (r216892) +++ head/sys/fs/nfsserver/nfs_nfsdsocket.c Sun Jan 2 19:58:39 2011 (r216893) @@ -902,13 +902,15 @@ nfsrvd_compound(struct nfsrv_descript *n nd->nd_repstat = NFSERR_XDEV; break; } - VREF(vp); - VREF(savevp); if (nfsv4_opflag[op].modifyfs) NFS_STARTWRITE(NULL, &mp); - NFSVOPLOCK(savevp, LK_EXCLUSIVE | LK_RETRY, p); - error = (*(nfsrv4_ops2[op]))(nd, isdgram, savevp, - vp, p, &savevpnes, &vpnes); + if (vn_lock(savevp, LK_EXCLUSIVE) == 0) { + VREF(vp); + VREF(savevp); + error = (*(nfsrv4_ops2[op]))(nd, isdgram, + savevp, vp, p, &savevpnes, &vpnes); + } else + nd->nd_repstat = NFSERR_PERM; if (nfsv4_opflag[op].modifyfs) NFS_ENDWRITE(mp); } else { @@ -916,12 +918,15 @@ nfsrvd_compound(struct nfsrv_descript *n panic("nfsrvd_compound"); if (nfsv4_opflag[op].needscfh) { if (vp != NULL) { + if (nfsv4_opflag[op].modifyfs) + NFS_STARTWRITE(NULL, &mp); if (vn_lock(vp, nfsv4_opflag[op].lktype) - != 0) + == 0) + VREF(vp); + else nd->nd_repstat = NFSERR_PERM; - } else + } else { nd->nd_repstat = NFSERR_NOFILEHANDLE; - if (nd->nd_repstat != 0) { if (op == NFSV4OP_SETATTR) { /* * Setattr reply requires a @@ -934,11 +939,9 @@ nfsrvd_compound(struct nfsrv_descript *n } break; } - VREF(vp); - if (nfsv4_opflag[op].modifyfs) - NFS_STARTWRITE(NULL, &mp); - error = (*(nfsrv4_ops0[op]))(nd, isdgram, vp, - p, &vpnes); + if (nd->nd_repstat == 0) + error = (*(nfsrv4_ops0[op]))(nd, + isdgram, vp, p, &vpnes); if (nfsv4_opflag[op].modifyfs) NFS_ENDWRITE(mp); } else { Modified: head/sys/fs/nfsserver/nfs_nfsdstate.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdstate.c Sun Jan 2 15:06:07 2011 (r216892) +++ head/sys/fs/nfsserver/nfs_nfsdstate.c Sun Jan 2 19:58:39 2011 (r216893) @@ -1659,7 +1659,7 @@ tryagain: if (new_stp->ls_flags & bits & NFSLCK_ACCESSBITS) { ret = nfsrv_clientconflict(tstp->ls_clp, &haslock, vp, p); - if (ret) { + if (ret == 1) { /* * nfsrv_clientconflict unlocks state * when it returns non-zero. @@ -1667,13 +1667,17 @@ tryagain: lckstp = NULL; goto tryagain; } - NFSUNLOCKSTATE(); + if (ret == 0) + NFSUNLOCKSTATE(); if (haslock) { NFSLOCKV4ROOTMUTEX(); nfsv4_unlock(&nfsv4rootfs_lock, 1); NFSUNLOCKV4ROOTMUTEX(); } - return (NFSERR_OPENMODE); + if (ret == 2) + return (NFSERR_PERM); + else + return (NFSERR_OPENMODE); } } } @@ -1826,7 +1830,7 @@ tryagain: other_lop = NULL; } ret = nfsrv_clientconflict(lop->lo_stp->ls_clp,&haslock,vp,p); - if (ret) { + if (ret == 1) { if (filestruct_locked != 0) { /* Roll back local locks. */ nfsrv_locallock_rollback(vp, lfp, p); @@ -1845,7 +1849,7 @@ tryagain: * Found a conflicting lock, so record the conflict and * return the error. */ - if (cfp) { + if (cfp != NULL && ret == 0) { cfp->cl_clientid.lval[0]=lop->lo_stp->ls_stateid.other[0]; cfp->cl_clientid.lval[1]=lop->lo_stp->ls_stateid.other[1]; cfp->cl_first = lop->lo_first; @@ -1855,20 +1859,23 @@ tryagain: NFSBCOPY(lop->lo_stp->ls_owner, cfp->cl_owner, cfp->cl_ownerlen); } - if (new_stp->ls_flags & NFSLCK_RECLAIM) + if (ret == 2) + error = NFSERR_PERM; + else if (new_stp->ls_flags & NFSLCK_RECLAIM) error = NFSERR_RECLAIMCONFLICT; else if (new_stp->ls_flags & NFSLCK_CHECK) error = NFSERR_LOCKED; else error = NFSERR_DENIED; - if (filestruct_locked != 0) { + if (filestruct_locked != 0 && ret == 0) { /* Roll back local locks. */ NFSUNLOCKSTATE(); nfsrv_locallock_rollback(vp, lfp, p); NFSLOCKSTATE(); nfsrv_unlocklf(lfp); } - NFSUNLOCKSTATE(); + if (ret == 0) + NFSUNLOCKSTATE(); if (haslock) { NFSLOCKV4ROOTMUTEX(); nfsv4_unlock(&nfsv4rootfs_lock, 1); @@ -2120,18 +2127,21 @@ tryagain: ((stp->ls_flags & NFSLCK_ACCESSBITS) & ((new_stp->ls_flags>>NFSLCK_SHIFT)&NFSLCK_ACCESSBITS)))){ ret = nfsrv_clientconflict(stp->ls_clp,&haslock,vp,p); - if (ret) { + if (ret == 1) { /* * nfsrv_clientconflict() unlocks * state when it returns non-zero. */ goto tryagain; } - if (new_stp->ls_flags & NFSLCK_RECLAIM) + if (ret == 2) + error = NFSERR_PERM; + else if (new_stp->ls_flags & NFSLCK_RECLAIM) error = NFSERR_RECLAIMCONFLICT; else error = NFSERR_SHAREDENIED; - NFSUNLOCKSTATE(); + if (ret == 0) + NFSUNLOCKSTATE(); if (haslock) { NFSLOCKV4ROOTMUTEX(); nfsv4_unlock(&nfsv4rootfs_lock, 1); @@ -2394,7 +2404,7 @@ tryagain: ((stp->ls_flags & NFSLCK_ACCESSBITS) & ((new_stp->ls_flags>>NFSLCK_SHIFT)&NFSLCK_ACCESSBITS))){ ret = nfsrv_clientconflict(stp->ls_clp,&haslock,vp,p); - if (ret) { + if (ret == 1) { /* * nfsrv_clientconflict() unlocks state * when it returns non-zero. @@ -2404,11 +2414,14 @@ tryagain: openstp = NULL; goto tryagain; } - if (new_stp->ls_flags & NFSLCK_RECLAIM) + if (ret == 2) + error = NFSERR_PERM; + else if (new_stp->ls_flags & NFSLCK_RECLAIM) error = NFSERR_RECLAIMCONFLICT; else error = NFSERR_SHAREDENIED; - NFSUNLOCKSTATE(); + if (ret == 0) + NFSUNLOCKSTATE(); if (haslock) { NFSLOCKV4ROOTMUTEX(); nfsv4_unlock(&nfsv4rootfs_lock, 1); @@ -4080,10 +4093,13 @@ nfsrv_updatestable(NFSPROC_T *p) NFSVNO_SETATTRVAL(&nva, size, 0); vp = NFSFPVNODE(sf->nsf_fp); NFS_STARTWRITE(vp, &mp); - NFSVOPLOCK(vp, LK_EXCLUSIVE | LK_RETRY, p); - error = nfsvno_setattr(vp, &nva, NFSFPCRED(sf->nsf_fp), p, NULL); + if (vn_lock(vp, LK_EXCLUSIVE) == 0) { + error = nfsvno_setattr(vp, &nva, NFSFPCRED(sf->nsf_fp), p, + NULL); + VOP_UNLOCK(vp, 0); + } else + error = EPERM; NFS_ENDWRITE(mp); - NFSVOPUNLOCK(vp, 0, p); if (!error) error = NFSD_RDWR(UIO_WRITE, vp, (caddr_t)&sf->nsf_rec, sizeof (struct nfsf_rec), (off_t)0, @@ -4211,10 +4227,11 @@ nfsrv_checkstable(struct nfsclient *clp) * Return 0 to indicate the conflict can't be revoked and 1 to indicate * the revocation worked and the conflicting client is "bye, bye", so it * can be tried again. + * Return 2 to indicate that the vnode is VI_DOOMED after vn_lock(). * Unlocks State before a non-zero value is returned. */ static int -nfsrv_clientconflict(struct nfsclient *clp, int *haslockp, __unused vnode_t vp, +nfsrv_clientconflict(struct nfsclient *clp, int *haslockp, vnode_t vp, NFSPROC_T *p) { int gotlock, lktype; @@ -4238,7 +4255,10 @@ nfsrv_clientconflict(struct nfsclient *c NFSUNLOCKV4ROOTMUTEX(); *haslockp = 1; vn_lock(vp, lktype | LK_RETRY); - return (1); + if ((vp->v_iflag & VI_DOOMED) != 0) + return (2); + else + return (1); } NFSUNLOCKSTATE(); @@ -4254,7 +4274,6 @@ nfsrv_clientconflict(struct nfsclient *c return (1); } - /* * Resolve a delegation conflict. * Returns 0 to indicate the conflict was resolved without sleeping. @@ -4403,6 +4422,13 @@ nfsrv_delegconflict(struct nfsstate *stp NFSUNLOCKV4ROOTMUTEX(); *haslockp = 1; vn_lock(vp, lktype | LK_RETRY); + if ((vp->v_iflag & VI_DOOMED) != 0) { + *haslockp = 0; + NFSLOCKV4ROOTMUTEX(); + nfsv4_unlock(&nfsv4rootfs_lock, 1); + NFSUNLOCKV4ROOTMUTEX(); + return (NFSERR_PERM); + } return (-1); } @@ -4594,12 +4620,11 @@ nfsd_recalldelegation(vnode_t vp, NFSPRO NFSGETNANOTIME(&mytime); starttime = (u_int32_t)mytime.tv_sec; do { - vn_lock(vp, LK_EXCLUSIVE | LK_RETRY); - if ((vp->v_iflag & VI_DOOMED) == 0) + if (vn_lock(vp, LK_EXCLUSIVE) == 0) { error = nfsrv_checkremove(vp, 0, p); - else + VOP_UNLOCK(vp, 0); + } else error = EPERM; - VOP_UNLOCK(vp, 0); if (error == NFSERR_DELAY) { NFSGETNANOTIME(&mytime); if (((u_int32_t)mytime.tv_sec - starttime) > From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 21:34:01 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C754F10656A4; Sun, 2 Jan 2011 21:34:01 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B65498FC16; Sun, 2 Jan 2011 21:34:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02LY16X059090; Sun, 2 Jan 2011 21:34:01 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02LY1Sm059086; Sun, 2 Jan 2011 21:34:01 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101022134.p02LY1Sm059086@svn.freebsd.org> From: Rick Macklem Date: Sun, 2 Jan 2011 21:34:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216894 - head/sys/fs/nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 21:34:01 -0000 Author: rmacklem Date: Sun Jan 2 21:34:01 2011 New Revision: 216894 URL: http://svn.freebsd.org/changeset/base/216894 Log: Delete some cruft from the experimental NFS server that was only used by the OpenBSD port for its pseudo-fs. MFC after: 2 weeks Modified: head/sys/fs/nfsserver/nfs_nfsdport.c head/sys/fs/nfsserver/nfs_nfsdserv.c head/sys/fs/nfsserver/nfs_nfsdsocket.c Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Sun Jan 2 19:58:39 2011 (r216893) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Sun Jan 2 21:34:01 2011 (r216894) @@ -47,7 +47,6 @@ __FBSDID("$FreeBSD$"); #include extern u_int32_t newnfs_true, newnfs_false, newnfs_xdrneg1; -extern int nfsv4root_set; extern int nfsrv_useacl; extern int newnfs_numnfsd; extern struct mount nfsv4root_mnt; @@ -2677,10 +2676,9 @@ nfsrv_v4rootexport(void *argp, struct uc fhandle_t fh; error = vfs_export(&nfsv4root_mnt, &nfsexargp->export); - if ((nfsexargp->export.ex_flags & MNT_DELEXPORT)) { + if ((nfsexargp->export.ex_flags & MNT_DELEXPORT) != 0) nfs_rootfhset = 0; - nfsv4root_set = 0; - } else if (error == 0) { + else if (error == 0) { if (nfsexargp->fspec == NULL) return (EPERM); /* Modified: head/sys/fs/nfsserver/nfs_nfsdserv.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdserv.c Sun Jan 2 19:58:39 2011 (r216893) +++ head/sys/fs/nfsserver/nfs_nfsdserv.c Sun Jan 2 21:34:01 2011 (r216894) @@ -51,7 +51,7 @@ __FBSDID("$FreeBSD$"); extern u_int32_t newnfs_false, newnfs_true; extern enum vtype nv34tov_type[8]; extern struct timeval nfsboottime; -extern int nfs_rootfhset, nfsv4root_set; +extern int nfs_rootfhset; #endif /* !APPLEKEXT */ /* @@ -2874,8 +2874,7 @@ nfsrvd_delegpurge(struct nfsrv_descript int error = 0; nfsquad_t clientid; - if ((!nfs_rootfhset && !nfsv4root_set) || - nfsd_checkrootexp(nd)) { + if (nfs_rootfhset == 0 || nfsd_checkrootexp(nd) != 0) { nd->nd_repstat = NFSERR_WRONGSEC; return (0); } @@ -3073,8 +3072,7 @@ nfsrvd_renew(struct nfsrv_descript *nd, int error = 0; nfsquad_t clientid; - if ((!nfs_rootfhset && !nfsv4root_set) || - nfsd_checkrootexp(nd)) { + if (nfs_rootfhset == 0 || nfsd_checkrootexp(nd) != 0) { nd->nd_repstat = NFSERR_WRONGSEC; return (0); } @@ -3212,8 +3210,7 @@ nfsrvd_setclientid(struct nfsrv_descript u_char *verf, *ucp, *ucp2, addrbuf[24]; nfsquad_t clientid, confirm; - if ((!nfs_rootfhset && !nfsv4root_set) || - nfsd_checkrootexp(nd)) { + if (nfs_rootfhset == 0 || nfsd_checkrootexp(nd) != 0) { nd->nd_repstat = NFSERR_WRONGSEC; return (0); } @@ -3321,8 +3318,7 @@ nfsrvd_setclientidcfrm(struct nfsrv_desc int error = 0; nfsquad_t clientid, confirm; - if ((!nfs_rootfhset && !nfsv4root_set) || - nfsd_checkrootexp(nd)) { + if (nfs_rootfhset == 0 || nfsd_checkrootexp(nd) != 0) { nd->nd_repstat = NFSERR_WRONGSEC; return (0); } @@ -3409,8 +3405,7 @@ nfsrvd_releaselckown(struct nfsrv_descri int error = 0, len; nfsquad_t clientid; - if ((!nfs_rootfhset && !nfsv4root_set) || - nfsd_checkrootexp(nd)) { + if (nfs_rootfhset == 0 || nfsd_checkrootexp(nd) != 0) { nd->nd_repstat = NFSERR_WRONGSEC; return (0); } Modified: head/sys/fs/nfsserver/nfs_nfsdsocket.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdsocket.c Sun Jan 2 19:58:39 2011 (r216893) +++ head/sys/fs/nfsserver/nfs_nfsdsocket.c Sun Jan 2 21:34:01 2011 (r216894) @@ -50,8 +50,6 @@ extern struct nfsclienthashhead nfsclien extern int nfsrc_floodlevel, nfsrc_tcpsavedreplies; NFSV4ROOTLOCKMUTEX; NFSSTATESPINLOCK; -vnode_t nfsv4root_vp = NULL; -int nfsv4root_set = 0; int (*nfsrv3_procs0[NFS_V3NPROCS])(struct nfsrv_descript *, int, vnode_t , NFSPROC_T *, struct nfsexstuff *) = { @@ -748,20 +746,8 @@ nfsrvd_compound(struct nfsrv_descript *n NFSVOPUNLOCK(vp, 0, p); vpnes = nes; } - } else if (nfsv4root_vp && nfsv4root_set) { - if (vp) { - if (vpnes.nes_vfslocked) - nfsvno_unlockvfs(mp); - vrele(vp); - } - vp = nfsv4root_vp; - VREF(vp); - NFSVNO_SETEXRDONLY(&vpnes); - vpnes.nes_vfslocked = 0; - mp = vnode_mount(vp); - } else { + } else nd->nd_repstat = NFSERR_NOFILEHANDLE; - } break; case NFSV4OP_SAVEFH: if (vp && NFSVNO_EXPORTED(&vpnes)) { @@ -859,17 +845,6 @@ nfsrvd_compound(struct nfsrv_descript *n vfs_statfs(vnode_mount(nvp))->f_fsid.val[0] || vfs_statfs(mp)->f_fsid.val[1] != vfs_statfs(vnode_mount(nvp))->f_fsid.val[1]) { - if (vfs_statfs(vnode_mount(nvp))->f_fsid.val[0] == - NFSV4ROOT_FSID0 && - vfs_statfs(vnode_mount(nvp))->f_fsid.val[1] == - NFSV4ROOT_FSID1) { - if (vpnes.nes_vfslocked) { - nfsvno_unlockvfs(mp); - vpnes.nes_vfslocked = 0; - } - NFSVNO_SETEXRDONLY(&vpnes); - mp = vnode_mount(nvp); - } else { nd->nd_repstat = nfsvno_checkexp(vnode_mount(nvp), nd->nd_nam, &nes, &credanon); if (!nd->nd_repstat) @@ -885,7 +860,6 @@ nfsrvd_compound(struct nfsrv_descript *n vpnes.nes_vfslocked = nfsvno_lockvfs(mp); } - } } if (!nd->nd_repstat) { vrele(vp); From owner-svn-src-head@FreeBSD.ORG Sun Jan 2 23:38:06 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 48A491065698; Sun, 2 Jan 2011 23:38:06 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 37BA78FC14; Sun, 2 Jan 2011 23:38:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02Nc6iY062072; Sun, 2 Jan 2011 23:38:06 GMT (envelope-from jpaetzel@svn.freebsd.org) Received: (from jpaetzel@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02Nc6j4062070; Sun, 2 Jan 2011 23:38:06 GMT (envelope-from jpaetzel@svn.freebsd.org) Message-Id: <201101022338.p02Nc6j4062070@svn.freebsd.org> From: Josh Paetzel Date: Sun, 2 Jan 2011 23:38:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216895 - head/usr.bin/calendar/calendars X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 23:38:06 -0000 Author: jpaetzel (ports committer) Date: Sun Jan 2 23:38:05 2011 New Revision: 216895 URL: http://svn.freebsd.org/changeset/base/216895 Log: Add myself. Modified: head/usr.bin/calendar/calendars/calendar.freebsd Modified: head/usr.bin/calendar/calendars/calendar.freebsd ============================================================================== --- head/usr.bin/calendar/calendars/calendar.freebsd Sun Jan 2 21:34:01 2011 (r216894) +++ head/usr.bin/calendar/calendars/calendar.freebsd Sun Jan 2 23:38:05 2011 (r216895) @@ -178,6 +178,7 @@ 06/06 Alan Eldridge died in Denver, Colorado, 2003 06/07 Jimmy Olgeni born in Milano, Italy, 1976 06/07 Benjamin Close born in Adelaide, Australia, 1978 +06/14 Josh Paetzel born in Minneapolis, Minnesota, United States, 1973 06/17 Tilman Linneweh born in Weinheim, Baden-Wuertemberg, Germany, 1978 06/18 Li-Wen Hsu born in Taipei, Taiwan, Republic of China, 1984 06/18 Roman Bogorodskiy born in Saratov, Russian Federation, 1986 From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 00:33:33 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 23CC4106564A; Mon, 3 Jan 2011 00:33:33 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id EC7038FC13; Mon, 3 Jan 2011 00:33:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p030XWif063412; Mon, 3 Jan 2011 00:33:32 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p030XWG9063409; Mon, 3 Jan 2011 00:33:32 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101030033.p030XWG9063409@svn.freebsd.org> From: Rick Macklem Date: Mon, 3 Jan 2011 00:33:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216897 - head/sys/fs/nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 00:33:33 -0000 Author: rmacklem Date: Mon Jan 3 00:33:32 2011 New Revision: 216897 URL: http://svn.freebsd.org/changeset/base/216897 Log: Modify the experimental NFSv4 server so that the lookup ops return a locked vnode. This ensures that the associated mount point will always be valid for the code that follows the operation. Also add a couple of additional checks for non-error to the other functions that create file objects. MFC after: 2 weeks Modified: head/sys/fs/nfsserver/nfs_nfsdserv.c head/sys/fs/nfsserver/nfs_nfsdsocket.c Modified: head/sys/fs/nfsserver/nfs_nfsdserv.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdserv.c Mon Jan 3 00:11:10 2011 (r216896) +++ head/sys/fs/nfsserver/nfs_nfsdserv.c Mon Jan 3 00:33:32 2011 (r216897) @@ -470,12 +470,10 @@ nfsrvd_lookup(struct nfsrv_descript *nd, nd->nd_repstat = nfsvno_getfh(vp, fhp, p); if (!(nd->nd_flag & ND_NFSV4) && !nd->nd_repstat) nd->nd_repstat = nfsvno_getattr(vp, &nva, nd->nd_cred, p, 1); - if (vpp) { - NFSVOPUNLOCK(vp, 0, p); + if (vpp != NULL && nd->nd_repstat == 0) *vpp = vp; - } else { + else vput(vp); - } if (dirp) { if (nd->nd_flag & ND_NFSV3) dattr_ret = nfsvno_getattr(dirp, &dattr, nd->nd_cred, @@ -1218,12 +1216,11 @@ nfsrvd_mknod(struct nfsrv_descript *nd, if ((nd->nd_flag & ND_NFSV3) && !nd->nd_repstat) nd->nd_repstat = nfsvno_getattr(vp, &nva, nd->nd_cred, p, 1); - if (vpp) { - NFSVOPUNLOCK(vp, 0, p); + if (vpp != NULL && nd->nd_repstat == 0) { + VOP_UNLOCK(vp, 0); *vpp = vp; - } else { + } else vput(vp); - } } diraft_ret = nfsvno_getattr(dirp, &diraft, nd->nd_cred, p, 0); @@ -1706,12 +1703,11 @@ nfsrvd_symlinksub(struct nfsrv_descript nd->nd_repstat = nfsvno_getattr(ndp->ni_vp, nvap, nd->nd_cred, p, 1); } - if (vpp) { - NFSVOPUNLOCK(ndp->ni_vp, 0, p); + if (vpp != NULL && nd->nd_repstat == 0) { + VOP_UNLOCK(ndp->ni_vp, 0); *vpp = ndp->ni_vp; - } else { + } else vput(ndp->ni_vp); - } } if (dirp) { *diraft_retp = nfsvno_getattr(dirp, diraftp, nd->nd_cred, p, 0); Modified: head/sys/fs/nfsserver/nfs_nfsdsocket.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdsocket.c Mon Jan 3 00:11:10 2011 (r216896) +++ head/sys/fs/nfsserver/nfs_nfsdsocket.c Mon Jan 3 00:33:32 2011 (r216897) @@ -861,10 +861,14 @@ nfsrvd_compound(struct nfsrv_descript *n nfsvno_lockvfs(mp); } } + if (op == NFSV4OP_LOOKUP || op == NFSV4OP_LOOKUPP) + /* Lookup ops return a locked vnode */ + VOP_UNLOCK(nvp, 0); if (!nd->nd_repstat) { vrele(vp); vp = nvp; - } + } else + vrele(nvp); } if (nfsv4_opflag[op].modifyfs) NFS_ENDWRITE(mp); From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 00:40:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7BB80106564A; Mon, 3 Jan 2011 00:40:13 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6B2378FC15; Mon, 3 Jan 2011 00:40:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p030eDSu063570; Mon, 3 Jan 2011 00:40:13 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p030eDLO063568; Mon, 3 Jan 2011 00:40:13 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101030040.p030eDLO063568@svn.freebsd.org> From: Rick Macklem Date: Mon, 3 Jan 2011 00:40:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216898 - head/sys/fs/nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 00:40:13 -0000 Author: rmacklem Date: Mon Jan 3 00:40:13 2011 New Revision: 216898 URL: http://svn.freebsd.org/changeset/base/216898 Log: Fix the experimental NFS server so that it doesn't leak a reference count on the directory when creating device special files. MFC after: 2 weeks Modified: head/sys/fs/nfsserver/nfs_nfsdport.c Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Mon Jan 3 00:33:32 2011 (r216897) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Mon Jan 3 00:40:13 2011 (r216898) @@ -857,8 +857,7 @@ nfsvno_mknod(struct nameidata *ndp, stru &ndp->ni_cnd, &nvap->na_vattr); vput(ndp->ni_dvp); nfsvno_relpathbuf(ndp); - if (error) - vrele(ndp->ni_startdir); + vrele(ndp->ni_startdir); /* * Since VOP_MKNOD returns the ni_vp, I can't * see any reason to do the lookup. From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 00:41:57 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 57A741065672; Mon, 3 Jan 2011 00:41:57 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2F09A8FC1C; Mon, 3 Jan 2011 00:41:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p030fvYn063635; Mon, 3 Jan 2011 00:41:57 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p030fvJn063632; Mon, 3 Jan 2011 00:41:57 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201101030041.p030fvJn063632@svn.freebsd.org> From: Alan Cox Date: Mon, 3 Jan 2011 00:41:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216899 - head/sys/vm X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 00:41:57 -0000 Author: alc Date: Mon Jan 3 00:41:56 2011 New Revision: 216899 URL: http://svn.freebsd.org/changeset/base/216899 Log: Release the page lock early in vm_pageout_clean(). There is no reason to hold this lock until the end of the function. With the aforementioned change to vm_pageout_clean(), page locks don't need to support recursive (MTX_RECURSE) or duplicate (MTX_DUPOK) acquisitions. Reviewed by: kib Modified: head/sys/vm/vm_page.c head/sys/vm/vm_pageout.c Modified: head/sys/vm/vm_page.c ============================================================================== --- head/sys/vm/vm_page.c Mon Jan 3 00:40:13 2011 (r216898) +++ head/sys/vm/vm_page.c Mon Jan 3 00:41:56 2011 (r216899) @@ -332,8 +332,7 @@ vm_page_startup(vm_offset_t vaddr) /* Setup page locks. */ for (i = 0; i < PA_LOCK_COUNT; i++) - mtx_init(&pa_lock[i].data, "page lock", NULL, - MTX_DEF | MTX_RECURSE | MTX_DUPOK); + mtx_init(&pa_lock[i].data, "page lock", NULL, MTX_DEF); /* * Initialize the queue headers for the hold queue, the active queue, Modified: head/sys/vm/vm_pageout.c ============================================================================== --- head/sys/vm/vm_pageout.c Mon Jan 3 00:40:13 2011 (r216898) +++ head/sys/vm/vm_pageout.c Mon Jan 3 00:41:56 2011 (r216899) @@ -326,7 +326,8 @@ vm_pageout_clean(vm_page_t m) vm_pindex_t pindex = m->pindex; vm_page_lock_assert(m, MA_OWNED); - VM_OBJECT_LOCK_ASSERT(m->object, MA_OWNED); + object = m->object; + VM_OBJECT_LOCK_ASSERT(object, MA_OWNED); /* * It doesn't cost us anything to pageout OBJT_DEFAULT or OBJT_SWAP @@ -343,6 +344,7 @@ vm_pageout_clean(vm_page_t m) KASSERT(m->busy == 0 && (m->oflags & VPO_BUSY) == 0, ("vm_pageout_clean: page %p is busy", m)); KASSERT(m->hold_count == 0, ("vm_pageout_clean: page %p is held", m)); + vm_page_unlock(m); mc[vm_pageout_page_count] = pb = ps = m; pageout_count = 1; @@ -369,7 +371,6 @@ vm_pageout_clean(vm_page_t m) * first and attempt to align our cluster, then do a * forward scan if room remains. */ - object = m->object; more: while (ib && pageout_count < vm_pageout_page_count) { vm_page_t p; @@ -434,7 +435,6 @@ more: if (ib && pageout_count < vm_pageout_page_count) goto more; - vm_page_unlock(m); /* * we allow reads during pageouts... */ From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 12:57:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2FF091065693; Mon, 3 Jan 2011 12:57:08 +0000 (UTC) (envelope-from mm@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 046CB8FC08; Mon, 3 Jan 2011 12:57:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03Cv7Fq091599; Mon, 3 Jan 2011 12:57:07 GMT (envelope-from mm@svn.freebsd.org) Received: (from mm@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03Cv7C4091596; Mon, 3 Jan 2011 12:57:07 GMT (envelope-from mm@svn.freebsd.org) Message-Id: <201101031257.p03Cv7C4091596@svn.freebsd.org> From: Martin Matuska Date: Mon, 3 Jan 2011 12:57:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216919 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 12:57:08 -0000 Author: mm Date: Mon Jan 3 12:57:07 2011 New Revision: 216919 URL: http://svn.freebsd.org/changeset/base/216919 Log: MFp4 r186485, r186859: Fix a race by defining two tasks in the zio structure as we can still be returning from issue task when interrupt task is used. Tested by: pjd Approved by: pjd, delphij (mentor) MFC after: 3 days Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h Mon Jan 3 09:18:12 2011 (r216918) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h Mon Jan 3 12:57:07 2011 (r216919) @@ -340,7 +340,8 @@ struct zio { #ifdef _KERNEL /* FreeBSD only. */ - struct ostask io_task; + struct ostask io_task_issue; + struct ostask io_task_interrupt; #endif }; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c Mon Jan 3 09:18:12 2011 (r216918) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c Mon Jan 3 12:57:07 2011 (r216919) @@ -947,6 +947,18 @@ zio_taskq_dispatch(zio_t *zio, enum zio_ { spa_t *spa = zio->io_spa; zio_type_t t = zio->io_type; +#ifdef _KERNEL + struct ostask *task; +#endif + + ASSERT(q == ZIO_TASKQ_ISSUE || q == ZIO_TASKQ_INTERRUPT); + +#ifdef _KERNEL + if (q == ZIO_TASKQ_ISSUE) + task = &zio->io_task_issue; + else /* if (q == ZIO_TASKQ_INTERRUPT) */ + task = &zio->io_task_interrupt; +#endif /* * If we're a config writer or a probe, the normal issue and @@ -970,8 +982,13 @@ zio_taskq_dispatch(zio_t *zio, enum zio_ q++; ASSERT3U(q, <, ZIO_TASKQ_TYPES); +#ifdef _KERNEL (void) taskq_dispatch_safe(spa->spa_zio_taskq[t][q], - (task_func_t *)zio_execute, zio, &zio->io_task); + (task_func_t *)zio_execute, zio, task); +#else + (void) taskq_dispatch(spa->spa_zio_taskq[t][q], + (task_func_t *)zio_execute, zio, TQ_SLEEP); +#endif } static boolean_t @@ -2300,9 +2317,16 @@ zio_done(zio_t *zio) * Reexecution is potentially a huge amount of work. * Hand it off to the otherwise-unused claim taskq. */ +#ifdef _KERNEL (void) taskq_dispatch_safe( spa->spa_zio_taskq[ZIO_TYPE_CLAIM][ZIO_TASKQ_ISSUE], - (task_func_t *)zio_reexecute, zio, &zio->io_task); + (task_func_t *)zio_reexecute, zio, + &zio->io_task_issue); +#else + (void) taskq_dispatch( + spa->spa_zio_taskq[ZIO_TYPE_CLAIM][ZIO_TASKQ_ISSUE], + (task_func_t *)zio_reexecute, zio, TQ_SLEEP); +#endif } return (ZIO_PIPELINE_STOP); } From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 16:29:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BECCA106564A; Mon, 3 Jan 2011 16:29:00 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AE1908FC18; Mon, 3 Jan 2011 16:29:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03GT0dP098282; Mon, 3 Jan 2011 16:29:00 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03GT0Ar098280; Mon, 3 Jan 2011 16:29:00 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101031629.p03GT0Ar098280@svn.freebsd.org> From: John Baldwin Date: Mon, 3 Jan 2011 16:29:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216921 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 16:29:00 -0000 Author: jhb Date: Mon Jan 3 16:29:00 2011 New Revision: 216921 URL: http://svn.freebsd.org/changeset/base/216921 Log: Small whitespace nits and add a comment explaining why kthread_exit() can call kproc_exit() that was lost earlier. Modified: head/sys/kern/kern_kthread.c Modified: head/sys/kern/kern_kthread.c ============================================================================== --- head/sys/kern/kern_kthread.c Mon Jan 3 15:31:02 2011 (r216920) +++ head/sys/kern/kern_kthread.c Mon Jan 3 16:29:00 2011 (r216921) @@ -316,17 +316,20 @@ kthread_exit(void) p = curthread->td_proc; - /* A module may be waiting for us to exit. */ wakeup(curthread); + + /* + * The last exiting thread in a kernel process must tear down + * the whole process. + */ rw_wlock(&tidhash_lock); PROC_LOCK(p); if (p->p_numthreads == 1) { PROC_UNLOCK(p); rw_wunlock(&tidhash_lock); kproc_exit(0); - - /* NOTREACHED. */ + /* NOTREACHED */ } LIST_REMOVE(curthread, td_hash); rw_wunlock(&tidhash_lock); From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 17:17:32 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 02BD8106566B; Mon, 3 Jan 2011 17:17:32 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E63C38FC08; Mon, 3 Jan 2011 17:17:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03HHVMP099588; Mon, 3 Jan 2011 17:17:31 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03HHVUC099586; Mon, 3 Jan 2011 17:17:31 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201101031717.p03HHVUC099586@svn.freebsd.org> From: Jaakko Heinonen Date: Mon, 3 Jan 2011 17:17:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216922 - head/bin/setfacl X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 17:17:32 -0000 Author: jh Date: Mon Jan 3 17:17:31 2011 New Revision: 216922 URL: http://svn.freebsd.org/changeset/base/216922 Log: Increase carried_error if we skip a file due to an error. This ensures that setfacl(1) exits with proper exit status on failure. PR: bin/149780 Submitted by: Ævar Arnfjörð Bjarmason (original version) Reviewed by: trasz MFC after: 3 weeks Modified: head/bin/setfacl/setfacl.c Modified: head/bin/setfacl/setfacl.c ============================================================================== --- head/bin/setfacl/setfacl.c Mon Jan 3 16:29:00 2011 (r216921) +++ head/bin/setfacl/setfacl.c Mon Jan 3 17:17:31 2011 (r216922) @@ -201,12 +201,14 @@ main(int argc, char *argv[]) if (stat(file->filename, &sb) == -1) { warn("%s: stat() failed", file->filename); + carried_error++; continue; } if (acl_type == ACL_TYPE_DEFAULT && S_ISDIR(sb.st_mode) == 0) { warnx("%s: default ACL may only be set on a directory", file->filename); + carried_error++; continue; } @@ -218,6 +220,7 @@ main(int argc, char *argv[]) if (acl_type == ACL_TYPE_DEFAULT) { warnx("%s: there are no default entries " "in NFSv4 ACLs", file->filename); + carried_error++; continue; } acl_type = ACL_TYPE_NFS4; @@ -240,6 +243,7 @@ main(int argc, char *argv[]) else warn("%s: acl_get_file() failed", file->filename); + carried_error++; continue; } From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 18:28:30 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E4CE11065673; Mon, 3 Jan 2011 18:28:30 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D30318FC0A; Mon, 3 Jan 2011 18:28:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03ISUqw001425; Mon, 3 Jan 2011 18:28:30 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03ISU1S001414; Mon, 3 Jan 2011 18:28:30 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101031828.p03ISU1S001414@svn.freebsd.org> From: John Baldwin Date: Mon, 3 Jan 2011 18:28:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216925 - in head/sys/dev: ae age alc ale nfe X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 18:28:31 -0000 Author: jhb Date: Mon Jan 3 18:28:30 2011 New Revision: 216925 URL: http://svn.freebsd.org/changeset/base/216925 Log: Add a 'locked' variant of the foo_start() routine and call it directly from interrupt handlers and watchdog routines instead of queueing a task to call foo_start(). Reviewed by: yongari MFC after: 1 month Modified: head/sys/dev/ae/if_ae.c head/sys/dev/ae/if_aevar.h head/sys/dev/age/if_age.c head/sys/dev/age/if_agevar.h head/sys/dev/alc/if_alc.c head/sys/dev/alc/if_alcvar.h head/sys/dev/ale/if_ale.c head/sys/dev/ale/if_alevar.h head/sys/dev/nfe/if_nfe.c head/sys/dev/nfe/if_nfevar.h Modified: head/sys/dev/ae/if_ae.c ============================================================================== --- head/sys/dev/ae/if_ae.c Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/ae/if_ae.c Mon Jan 3 18:28:30 2011 (r216925) @@ -124,10 +124,10 @@ static int ae_resume(device_t dev); static unsigned int ae_tx_avail_size(ae_softc_t *sc); static int ae_encap(ae_softc_t *sc, struct mbuf **m_head); static void ae_start(struct ifnet *ifp); +static void ae_start_locked(struct ifnet *ifp); static void ae_link_task(void *arg, int pending); static void ae_stop_rxmac(ae_softc_t *sc); static void ae_stop_txmac(ae_softc_t *sc); -static void ae_tx_task(void *arg, int pending); static void ae_mac_config(ae_softc_t *sc); static int ae_intr(void *arg); static void ae_int_task(void *arg, int pending); @@ -402,7 +402,6 @@ ae_attach(device_t dev) /* * Create and run all helper tasks. */ - TASK_INIT(&sc->tx_task, 1, ae_tx_task, ifp); sc->tq = taskqueue_create_fast("ae_taskq", M_WAITOK, taskqueue_thread_enqueue, &sc->tq); if (sc->tq == NULL) { @@ -763,7 +762,6 @@ ae_detach(device_t dev) AE_UNLOCK(sc); callout_drain(&sc->tick_ch); taskqueue_drain(sc->tq, &sc->int_task); - taskqueue_drain(sc->tq, &sc->tx_task); taskqueue_drain(taskqueue_swi, &sc->link_task); ether_ifdetach(ifp); } @@ -1518,23 +1516,32 @@ static void ae_start(struct ifnet *ifp) { ae_softc_t *sc; + + sc = ifp->if_softc; + AE_LOCK(sc); + ae_start_locked(ifp); + AE_UNLOCK(sc); +} + +static void +ae_start_locked(struct ifnet *ifp) +{ + ae_softc_t *sc; unsigned int count; struct mbuf *m0; int error; sc = ifp->if_softc; KASSERT(sc != NULL, ("[ae, %d]: sc is NULL", __LINE__)); - AE_LOCK(sc); + AE_LOCK_ASSERT(sc); #ifdef AE_DEBUG if_printf(ifp, "Start called.\n"); #endif if ((ifp->if_drv_flags & (IFF_DRV_RUNNING | IFF_DRV_OACTIVE)) != - IFF_DRV_RUNNING || (sc->flags & AE_FLAG_LINK) == 0) { - AE_UNLOCK(sc); + IFF_DRV_RUNNING || (sc->flags & AE_FLAG_LINK) == 0) return; - } count = 0; while (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) { @@ -1570,7 +1577,6 @@ ae_start(struct ifnet *ifp) if_printf(ifp, "Tx pos now is %d.\n", sc->txd_cur); #endif } - AE_UNLOCK(sc); } static void @@ -1704,15 +1710,6 @@ ae_stop_txmac(ae_softc_t *sc) } static void -ae_tx_task(void *arg, int pending) -{ - struct ifnet *ifp; - - ifp = (struct ifnet *)arg; - ae_start(ifp); -} - -static void ae_mac_config(ae_softc_t *sc) { struct mii_data *mii; @@ -1869,7 +1866,7 @@ ae_tx_intr(ae_softc_t *sc) if ((sc->flags & AE_FLAG_TXAVAIL) != 0) { if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->tq, &sc->tx_task); + ae_start_locked(ifp); } /* @@ -1997,7 +1994,7 @@ ae_watchdog(ae_softc_t *sc) ifp->if_drv_flags &= ~IFF_DRV_RUNNING; ae_init_locked(sc); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->tq, &sc->tx_task); + ae_start_locked(ifp); } static void Modified: head/sys/dev/ae/if_aevar.h ============================================================================== --- head/sys/dev/ae/if_aevar.h Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/ae/if_aevar.h Mon Jan 3 18:28:30 2011 (r216925) @@ -119,7 +119,6 @@ typedef struct ae_softc { /* Tasks. */ struct task int_task; - struct task tx_task; struct task link_task; struct taskqueue *tq; Modified: head/sys/dev/age/if_age.c ============================================================================== --- head/sys/dev/age/if_age.c Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/age/if_age.c Mon Jan 3 18:28:30 2011 (r216925) @@ -118,8 +118,8 @@ static void age_setwol(struct age_softc static int age_suspend(device_t); static int age_resume(device_t); static int age_encap(struct age_softc *, struct mbuf **); -static void age_tx_task(void *, int); static void age_start(struct ifnet *); +static void age_start_locked(struct ifnet *); static void age_watchdog(struct age_softc *); static int age_ioctl(struct ifnet *, u_long, caddr_t); static void age_mac_config(struct age_softc *); @@ -636,7 +636,6 @@ age_attach(device_t dev) ifp->if_data.ifi_hdrlen = sizeof(struct ether_vlan_header); /* Create local taskq. */ - TASK_INIT(&sc->age_tx_task, 1, age_tx_task, ifp); sc->age_tq = taskqueue_create_fast("age_taskq", M_WAITOK, taskqueue_thread_enqueue, &sc->age_tq); if (sc->age_tq == NULL) { @@ -693,7 +692,6 @@ age_detach(device_t dev) AGE_UNLOCK(sc); callout_drain(&sc->age_tick_ch); taskqueue_drain(sc->age_tq, &sc->age_int_task); - taskqueue_drain(sc->age_tq, &sc->age_tx_task); taskqueue_drain(taskqueue_swi, &sc->age_link_task); ether_ifdetach(ifp); } @@ -1706,16 +1704,18 @@ age_encap(struct age_softc *sc, struct m } static void -age_tx_task(void *arg, int pending) +age_start(struct ifnet *ifp) { - struct ifnet *ifp; + struct age_softc *sc; - ifp = (struct ifnet *)arg; - age_start(ifp); + sc = ifp->if_softc; + AGE_LOCK(sc); + age_start_locked(ifp); + AGE_UNLOCK(sc); } static void -age_start(struct ifnet *ifp) +age_start_locked(struct ifnet *ifp) { struct age_softc *sc; struct mbuf *m_head; @@ -1723,13 +1723,11 @@ age_start(struct ifnet *ifp) sc = ifp->if_softc; - AGE_LOCK(sc); + AGE_LOCK_ASSERT(sc); if ((ifp->if_drv_flags & (IFF_DRV_RUNNING | IFF_DRV_OACTIVE)) != - IFF_DRV_RUNNING || (sc->age_flags & AGE_FLAG_LINK) == 0) { - AGE_UNLOCK(sc); + IFF_DRV_RUNNING || (sc->age_flags & AGE_FLAG_LINK) == 0) return; - } for (enq = 0; !IFQ_DRV_IS_EMPTY(&ifp->if_snd); ) { IFQ_DRV_DEQUEUE(&ifp->if_snd, m_head); @@ -1788,7 +1786,7 @@ age_watchdog(struct age_softc *sc) if_printf(sc->age_ifp, "watchdog timeout (missed Tx interrupts) -- recovering\n"); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->age_tq, &sc->age_tx_task); + age_start_locked(ifp); return; } if_printf(sc->age_ifp, "watchdog timeout\n"); @@ -1796,7 +1794,7 @@ age_watchdog(struct age_softc *sc) ifp->if_drv_flags &= ~IFF_DRV_RUNNING; age_init_locked(sc); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->age_tq, &sc->age_tx_task); + age_start_locked(ifp); } static int @@ -2172,7 +2170,7 @@ age_int_task(void *arg, int pending) age_init_locked(sc); } if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->age_tq, &sc->age_tx_task); + age_start_locked(ifp); if ((status & INTR_SMB) != 0) age_stats_update(sc); } Modified: head/sys/dev/age/if_agevar.h ============================================================================== --- head/sys/dev/age/if_agevar.h Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/age/if_agevar.h Mon Jan 3 18:28:30 2011 (r216925) @@ -222,7 +222,6 @@ struct age_softc { int age_tpd_cons; struct task age_int_task; - struct task age_tx_task; struct task age_link_task; struct taskqueue *age_tq; struct mtx age_mtx; Modified: head/sys/dev/alc/if_alc.c ============================================================================== --- head/sys/dev/alc/if_alc.c Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/alc/if_alc.c Mon Jan 3 18:28:30 2011 (r216925) @@ -159,6 +159,7 @@ static void alc_setlinkspeed(struct alc_ static void alc_setwol(struct alc_softc *); static int alc_shutdown(device_t); static void alc_start(struct ifnet *); +static void alc_start_locked(struct ifnet *); static void alc_start_queue(struct alc_softc *); static void alc_stats_clear(struct alc_softc *); static void alc_stats_update(struct alc_softc *); @@ -168,7 +169,6 @@ static void alc_stop_queue(struct alc_so static int alc_suspend(device_t); static void alc_sysctl_node(struct alc_softc *); static void alc_tick(void *); -static void alc_tx_task(void *, int); static void alc_txeof(struct alc_softc *); static void alc_watchdog(struct alc_softc *); static int sysctl_int_range(SYSCTL_HANDLER_ARGS, int, int); @@ -1002,7 +1002,6 @@ alc_attach(device_t dev) ifp->if_data.ifi_hdrlen = sizeof(struct ether_vlan_header); /* Create local taskq. */ - TASK_INIT(&sc->alc_tx_task, 1, alc_tx_task, ifp); sc->alc_tq = taskqueue_create_fast("alc_taskq", M_WAITOK, taskqueue_thread_enqueue, &sc->alc_tq); if (sc->alc_tq == NULL) { @@ -1059,7 +1058,6 @@ alc_detach(device_t dev) ALC_UNLOCK(sc); callout_drain(&sc->alc_tick_ch); taskqueue_drain(sc->alc_tq, &sc->alc_int_task); - taskqueue_drain(sc->alc_tq, &sc->alc_tx_task); ether_ifdetach(ifp); } @@ -2237,16 +2235,18 @@ alc_encap(struct alc_softc *sc, struct m } static void -alc_tx_task(void *arg, int pending) +alc_start(struct ifnet *ifp) { - struct ifnet *ifp; + struct alc_softc *sc; - ifp = (struct ifnet *)arg; - alc_start(ifp); + sc = ifp->if_softc; + ALC_LOCK(sc); + alc_start_locked(ifp); + ALC_UNLOCK(sc); } static void -alc_start(struct ifnet *ifp) +alc_start_locked(struct ifnet *ifp) { struct alc_softc *sc; struct mbuf *m_head; @@ -2254,17 +2254,15 @@ alc_start(struct ifnet *ifp) sc = ifp->if_softc; - ALC_LOCK(sc); + ALC_LOCK_ASSERT(sc); /* Reclaim transmitted frames. */ if (sc->alc_cdata.alc_tx_cnt >= ALC_TX_DESC_HIWAT) alc_txeof(sc); if ((ifp->if_drv_flags & (IFF_DRV_RUNNING | IFF_DRV_OACTIVE)) != - IFF_DRV_RUNNING || (sc->alc_flags & ALC_FLAG_LINK) == 0) { - ALC_UNLOCK(sc); + IFF_DRV_RUNNING || (sc->alc_flags & ALC_FLAG_LINK) == 0) return; - } for (enq = 0; !IFQ_DRV_IS_EMPTY(&ifp->if_snd); ) { IFQ_DRV_DEQUEUE(&ifp->if_snd, m_head); @@ -2303,8 +2301,6 @@ alc_start(struct ifnet *ifp) /* Set a timeout in case the chip goes out to lunch. */ sc->alc_watchdog_timer = ALC_TX_TIMEOUT; } - - ALC_UNLOCK(sc); } static void @@ -2330,7 +2326,7 @@ alc_watchdog(struct alc_softc *sc) ifp->if_drv_flags &= ~IFF_DRV_RUNNING; alc_init_locked(sc); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->alc_tq, &sc->alc_tx_task); + alc_start_locked(ifp); } static int @@ -2710,7 +2706,7 @@ alc_int_task(void *arg, int pending) } if ((ifp->if_drv_flags & IFF_DRV_RUNNING) != 0 && !IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->alc_tq, &sc->alc_tx_task); + alc_start_locked(ifp); } if (more == EAGAIN || Modified: head/sys/dev/alc/if_alcvar.h ============================================================================== --- head/sys/dev/alc/if_alcvar.h Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/alc/if_alcvar.h Mon Jan 3 18:28:30 2011 (r216925) @@ -246,7 +246,6 @@ struct alc_softc { int alc_buf_size; struct task alc_int_task; - struct task alc_tx_task; struct taskqueue *alc_tq; struct mtx alc_mtx; }; Modified: head/sys/dev/ale/if_ale.c ============================================================================== --- head/sys/dev/ale/if_ale.c Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/ale/if_ale.c Mon Jan 3 18:28:30 2011 (r216925) @@ -136,6 +136,7 @@ static void ale_setlinkspeed(struct ale_ static void ale_setwol(struct ale_softc *); static int ale_shutdown(device_t); static void ale_start(struct ifnet *); +static void ale_start_locked(struct ifnet *); static void ale_stats_clear(struct ale_softc *); static void ale_stats_update(struct ale_softc *); static void ale_stop(struct ale_softc *); @@ -143,7 +144,6 @@ static void ale_stop_mac(struct ale_soft static int ale_suspend(device_t); static void ale_sysctl_node(struct ale_softc *); static void ale_tick(void *); -static void ale_tx_task(void *, int); static void ale_txeof(struct ale_softc *); static void ale_watchdog(struct ale_softc *); static int sysctl_int_range(SYSCTL_HANDLER_ARGS, int, int); @@ -625,7 +625,6 @@ ale_attach(device_t dev) ifp->if_data.ifi_hdrlen = sizeof(struct ether_vlan_header); /* Create local taskq. */ - TASK_INIT(&sc->ale_tx_task, 1, ale_tx_task, ifp); sc->ale_tq = taskqueue_create_fast("ale_taskq", M_WAITOK, taskqueue_thread_enqueue, &sc->ale_tq); if (sc->ale_tq == NULL) { @@ -682,7 +681,6 @@ ale_detach(device_t dev) ALE_UNLOCK(sc); callout_drain(&sc->ale_tick_ch); taskqueue_drain(sc->ale_tq, &sc->ale_int_task); - taskqueue_drain(sc->ale_tq, &sc->ale_tx_task); taskqueue_drain(taskqueue_swi, &sc->ale_link_task); ether_ifdetach(ifp); } @@ -1845,16 +1843,18 @@ ale_encap(struct ale_softc *sc, struct m } static void -ale_tx_task(void *arg, int pending) +ale_start(struct ifnet *ifp) { - struct ifnet *ifp; + struct ale_softc *sc; - ifp = (struct ifnet *)arg; - ale_start(ifp); + sc = ifp->if_softc; + ALE_LOCK(sc); + ale_start_locked(ifp); + ALE_UNLOCK(sc); } static void -ale_start(struct ifnet *ifp) +ale_start_locked(struct ifnet *ifp) { struct ale_softc *sc; struct mbuf *m_head; @@ -1862,17 +1862,15 @@ ale_start(struct ifnet *ifp) sc = ifp->if_softc; - ALE_LOCK(sc); + ALE_LOCK_ASSERT(sc); /* Reclaim transmitted frames. */ if (sc->ale_cdata.ale_tx_cnt >= ALE_TX_DESC_HIWAT) ale_txeof(sc); if ((ifp->if_drv_flags & (IFF_DRV_RUNNING | IFF_DRV_OACTIVE)) != - IFF_DRV_RUNNING || (sc->ale_flags & ALE_FLAG_LINK) == 0) { - ALE_UNLOCK(sc); + IFF_DRV_RUNNING || (sc->ale_flags & ALE_FLAG_LINK) == 0) return; - } for (enq = 0; !IFQ_DRV_IS_EMPTY(&ifp->if_snd); ) { IFQ_DRV_DEQUEUE(&ifp->if_snd, m_head); @@ -1933,7 +1931,7 @@ ale_watchdog(struct ale_softc *sc) ifp->if_drv_flags &= ~IFF_DRV_RUNNING; ale_init_locked(sc); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->ale_tq, &sc->ale_tx_task); + ale_start_locked(ifp); } static int @@ -2320,7 +2318,7 @@ ale_int_task(void *arg, int pending) return; } if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->ale_tq, &sc->ale_tx_task); + ale_start_locked(ifp); } if (more == EAGAIN || Modified: head/sys/dev/ale/if_alevar.h ============================================================================== --- head/sys/dev/ale/if_alevar.h Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/ale/if_alevar.h Mon Jan 3 18:28:30 2011 (r216925) @@ -222,7 +222,6 @@ struct ale_softc { int ale_pagesize; struct task ale_int_task; - struct task ale_tx_task; struct task ale_link_task; struct taskqueue *ale_tq; struct mtx ale_mtx; Modified: head/sys/dev/nfe/if_nfe.c ============================================================================== --- head/sys/dev/nfe/if_nfe.c Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/nfe/if_nfe.c Mon Jan 3 18:28:30 2011 (r216925) @@ -99,8 +99,8 @@ static int nfe_jrxeof(struct nfe_softc static void nfe_txeof(struct nfe_softc *); static int nfe_encap(struct nfe_softc *, struct mbuf **); static void nfe_setmulti(struct nfe_softc *); -static void nfe_tx_task(void *, int); static void nfe_start(struct ifnet *); +static void nfe_start_locked(struct ifnet *); static void nfe_watchdog(struct ifnet *); static void nfe_init(void *); static void nfe_init_locked(void *); @@ -553,7 +553,6 @@ nfe_attach(device_t dev) error = ENOSPC; goto fail; } - TASK_INIT(&sc->nfe_tx_task, 1, nfe_tx_task, ifp); /* * Allocate Tx and Rx rings. @@ -679,7 +678,6 @@ nfe_detach(device_t dev) ifp->if_flags &= ~IFF_UP; NFE_UNLOCK(sc); callout_drain(&sc->nfe_stat_ch); - taskqueue_drain(taskqueue_fast, &sc->nfe_tx_task); ether_ifdetach(ifp); } @@ -1631,7 +1629,7 @@ nfe_poll(struct ifnet *ifp, enum poll_cm rx_npkts = nfe_rxeof(sc, count, &rx_npkts); nfe_txeof(sc); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue_fast(sc->nfe_tq, &sc->nfe_tx_task); + nfe_start_locked(ifp); if (cmd == POLL_AND_CHECK_STATUS) { if ((r = NFE_READ(sc, sc->nfe_irq_status)) == 0) { @@ -1903,7 +1901,7 @@ nfe_int_task(void *arg, int pending) nfe_txeof(sc); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue_fast(sc->nfe_tq, &sc->nfe_tx_task); + nfe_start_locked(ifp); NFE_UNLOCK(sc); @@ -2599,29 +2597,27 @@ done: static void -nfe_tx_task(void *arg, int pending) +nfe_start(struct ifnet *ifp) { - struct ifnet *ifp; + struct nfe_softc *sc = ifp->if_softc; - ifp = (struct ifnet *)arg; - nfe_start(ifp); + NFE_LOCK(sc); + nfe_start_locked(ifp); + NFE_UNLOCK(sc); } - static void -nfe_start(struct ifnet *ifp) +nfe_start_locked(struct ifnet *ifp) { struct nfe_softc *sc = ifp->if_softc; struct mbuf *m0; int enq; - NFE_LOCK(sc); + NFE_LOCK_ASSERT(sc); if ((ifp->if_drv_flags & (IFF_DRV_RUNNING | IFF_DRV_OACTIVE)) != - IFF_DRV_RUNNING || sc->nfe_link == 0) { - NFE_UNLOCK(sc); + IFF_DRV_RUNNING || sc->nfe_link == 0) return; - } for (enq = 0; !IFQ_DRV_IS_EMPTY(&ifp->if_snd);) { IFQ_DRV_DEQUEUE(&ifp->if_snd, m0); @@ -2651,8 +2647,6 @@ nfe_start(struct ifnet *ifp) */ sc->nfe_watchdog_timer = 5; } - - NFE_UNLOCK(sc); } @@ -2670,7 +2664,7 @@ nfe_watchdog(struct ifnet *ifp) if_printf(ifp, "watchdog timeout (missed Tx interrupts) " "-- recovering\n"); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue_fast(sc->nfe_tq, &sc->nfe_tx_task); + nfe_start_locked(ifp); return; } /* Check if we've lost start Tx command. */ Modified: head/sys/dev/nfe/if_nfevar.h ============================================================================== --- head/sys/dev/nfe/if_nfevar.h Mon Jan 3 18:22:22 2011 (r216924) +++ head/sys/dev/nfe/if_nfevar.h Mon Jan 3 18:28:30 2011 (r216925) @@ -139,7 +139,6 @@ struct nfe_softc { struct nfe_hw_stats nfe_stats; struct taskqueue *nfe_tq; struct task nfe_int_task; - struct task nfe_tx_task; int nfe_link; int nfe_suspended; int nfe_framesize; From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 19:30:48 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2B3FA106564A; Mon, 3 Jan 2011 19:30:48 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1ACD78FC0C; Mon, 3 Jan 2011 19:30:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03JUlRB003044; Mon, 3 Jan 2011 19:30:48 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03JUlQT003042; Mon, 3 Jan 2011 19:30:47 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101031930.p03JUlQT003042@svn.freebsd.org> From: Warner Losh Date: Mon, 3 Jan 2011 19:30:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216928 - head/tools/tools/nanobsd X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 19:30:48 -0000 Author: imp Date: Mon Jan 3 19:30:47 2011 New Revision: 216928 URL: http://svn.freebsd.org/changeset/base/216928 Log: Put in the other half of the SRCCONF patch. Submitted by: phk Modified: head/tools/tools/nanobsd/nanobsd.sh Modified: head/tools/tools/nanobsd/nanobsd.sh ============================================================================== --- head/tools/tools/nanobsd/nanobsd.sh Mon Jan 3 19:23:43 2011 (r216927) +++ head/tools/tools/nanobsd/nanobsd.sh Mon Jan 3 19:30:47 2011 (r216928) @@ -245,7 +245,7 @@ make_conf_install ( ) ( echo "${CONF_WORLD}" > ${NANO_MAKE_CONF_INSTALL} echo "${CONF_INSTALL}" >> ${NANO_MAKE_CONF_INSTALL} - echo "_WITHOUT_SRCCONF=t" >> ${NANO_MAKE_CONF_INSTALL} + echo "SRCCONF=/dev/null" >> ${NANO_MAKE_CONF_INSTALL} ) install_world ( ) ( From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 19:32:54 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DA630106566B; Mon, 3 Jan 2011 19:32:54 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CA17F8FC0A; Mon, 3 Jan 2011 19:32:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03JWsR1003120; Mon, 3 Jan 2011 19:32:54 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03JWsYG003118; Mon, 3 Jan 2011 19:32:54 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101031932.p03JWsYG003118@svn.freebsd.org> From: Warner Losh Date: Mon, 3 Jan 2011 19:32:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216929 - head/tools/tools/nanobsd X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 19:32:54 -0000 Author: imp Date: Mon Jan 3 19:32:54 2011 New Revision: 216929 URL: http://svn.freebsd.org/changeset/base/216929 Log: Bump the media size from approx 600MB to approx 750MB. The great hob-nailed tennis shoe of progress demands it! Submitted by: phk Modified: head/tools/tools/nanobsd/nanobsd.sh Modified: head/tools/tools/nanobsd/nanobsd.sh ============================================================================== --- head/tools/tools/nanobsd/nanobsd.sh Mon Jan 3 19:30:47 2011 (r216928) +++ head/tools/tools/nanobsd/nanobsd.sh Mon Jan 3 19:32:54 2011 (r216929) @@ -91,7 +91,7 @@ NANO_NEWFS="-b 4096 -f 512 -i 8192 -O1 - NANO_DRIVE=ad0 # Target media size in 512 bytes sectors -NANO_MEDIASIZE=1200000 +NANO_MEDIASIZE=1500000 # Number of code images on media (1 or 2) NANO_IMAGES=2 From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 20:32:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B8A081065670; Mon, 3 Jan 2011 20:32:08 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A805A8FC13; Mon, 3 Jan 2011 20:32:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03KW8ui004444; Mon, 3 Jan 2011 20:32:08 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03KW8jp004442; Mon, 3 Jan 2011 20:32:08 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101032032.p03KW8jp004442@svn.freebsd.org> From: Warner Losh Date: Mon, 3 Jan 2011 20:32:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216930 - head/tools/tools/nanobsd/gateworks X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 20:32:08 -0000 Author: imp Date: Mon Jan 3 20:32:08 2011 New Revision: 216930 URL: http://svn.freebsd.org/changeset/base/216930 Log: Update gateworks exclusion list to match latest tree. Modified: head/tools/tools/nanobsd/gateworks/common Modified: head/tools/tools/nanobsd/gateworks/common ============================================================================== --- head/tools/tools/nanobsd/gateworks/common Mon Jan 3 19:32:54 2011 (r216929) +++ head/tools/tools/nanobsd/gateworks/common Mon Jan 3 20:32:08 2011 (r216930) @@ -101,39 +101,48 @@ export NANO_MAKEFS # NB: leave c++ enabled so devd can be built CONF_BUILD=" +WITHOUT_ACCT=true WITHOUT_ACPI=true +WITHOUT_APM=true WITHOUT_ATM=true WITHOUT_AUDIT=true WITHOUT_BIND_DNSSEC=true WITHOUT_BIND_ETC=true WITHOUT_BIND_LIBS_LWRES=true WITHOUT_BLUETOOTH=true +WITHOUT_BSNMP=true WITHOUT_CALENDAR=true WITHOUT_CDDL=true +WITHOUT_CTM=true WITHOUT_CVS=true WITHOUT_DICT=true WITHOUT_EXAMPLES=true +WITHOUT_FLOPPY=true WITHOUT_FORTRAN=true WITHOUT_GAMES=true WITHOUT_GCOV=true WITHOUT_GPIB=true +WITHOUT_GROFF=true WITHOUT_HTML=true -WITHOUT_I4B=true WITHOUT_INET6=true WITHOUT_INFO=true WITHOUT_IPFILTER=true WITHOUT_IPX=true WITHOUT_KERBEROS=true -WITHOUT_LIBKSE=true WITHOUT_LOCALES=true WITHOUT_LPR=true WITHOUT_MAN=true +WITHOUT_MAIL=true +WITHOUT_MAILWRAPPER=true WITHOUT_NETCAT=true WITHOUT_NIS=true WITHOUT_NLS=true WITHOUT_NS_CACHING=true WITHOUT_OBJC=true +WITHOUT_PMC=true +WITHOUT_PORTSNAP=true WITHOUT_PROFILE=true +WITHOUT_QUOTAS=true WITHOUT_RCMDS=true WITHOUT_RCS=true WITHOUT_RESCUE=true @@ -141,7 +150,10 @@ WITHOUT_SENDMAIL=true WITHOUT_SHAREDOCS=true WITHOUT_SSP=true WITHOUT_SYSCONS=true +WITHOUT_SYSINSTALL=true WITHOUT_TCSH=true +WITHOUT_TFTPD=true +WITHOUT_ZFS=true " CONF_INSTALL="$CONF_BUILD WITHOUT_TOOLCHAIN=true From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 20:37:32 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2B4B7106564A; Mon, 3 Jan 2011 20:37:32 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1888C8FC0A; Mon, 3 Jan 2011 20:37:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03KbVvj004602; Mon, 3 Jan 2011 20:37:31 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03KbVYm004591; Mon, 3 Jan 2011 20:37:31 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101032037.p03KbVYm004591@svn.freebsd.org> From: Rick Macklem Date: Mon, 3 Jan 2011 20:37:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216931 - in head/sys: conf fs/nfsclient fs/nfsserver nfs nfsclient nlm X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 20:37:32 -0000 Author: rmacklem Date: Mon Jan 3 20:37:31 2011 New Revision: 216931 URL: http://svn.freebsd.org/changeset/base/216931 Log: Fix the nlm so that it no longer depends on the regular nfs client and, as such, can be loaded for the experimental nfs client without the regular client. Reviewed by: jhb MFC after: 2 weeks Modified: head/sys/conf/files head/sys/fs/nfsclient/nfs_clvfsops.c head/sys/fs/nfsclient/nfsmount.h head/sys/fs/nfsserver/nfs_nfsdport.c head/sys/nfs/nfs_lock.c head/sys/nfs/nfs_mountcommon.h head/sys/nfsclient/nfs_vfsops.c head/sys/nfsclient/nfsmount.h head/sys/nlm/nlm_advlock.c head/sys/nlm/nlm_prot_impl.c Modified: head/sys/conf/files ============================================================================== --- head/sys/conf/files Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/conf/files Mon Jan 3 20:37:31 2011 (r216931) @@ -2719,7 +2719,7 @@ netsmb/smb_subr.c optional netsmb netsmb/smb_trantcp.c optional netsmb netsmb/smb_usr.c optional netsmb nfs/nfs_common.c optional nfsclient | nfsserver -nfs/nfs_lock.c optional nfsclient | nfscl +nfs/nfs_lock.c optional nfsclient | nfscl | nfslockd | nfsd nfsclient/bootp_subr.c optional bootp nfsclient nfsclient/krpc_subr.c optional bootp nfsclient nfsclient/nfs_bio.c optional nfsclient @@ -2735,7 +2735,7 @@ nfsserver/nfs_serv.c optional nfsserver nfsserver/nfs_srvkrpc.c optional nfsserver nfsserver/nfs_srvsubs.c optional nfsserver nfs/nfs_nfssvc.c optional nfsserver | nfscl | nfsd -nlm/nlm_advlock.c optional nfslockd nfsclient | nfsd nfsclient +nlm/nlm_advlock.c optional nfslockd | nfsd nlm/nlm_prot_clnt.c optional nfslockd | nfsd nlm/nlm_prot_impl.c optional nfslockd | nfsd nlm/nlm_prot_server.c optional nfslockd | nfsd Modified: head/sys/fs/nfsclient/nfs_clvfsops.c ============================================================================== --- head/sys/fs/nfsclient/nfs_clvfsops.c Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/fs/nfsclient/nfs_clvfsops.c Mon Jan 3 20:37:31 2011 (r216931) @@ -102,7 +102,8 @@ static int mountnfs(struct nfs_args *, s struct sockaddr *, char *, u_char *, u_char *, u_char *, struct vnode **, struct ucred *, struct thread *, int); static void nfs_getnlminfo(struct vnode *, uint8_t *, size_t *, - struct sockaddr_storage *, int *, off_t *); + struct sockaddr_storage *, int *, off_t *, + struct timeval *); static vfs_mount_t nfs_mount; static vfs_cmount_t nfs_cmount; static vfs_unmount_t nfs_unmount; @@ -1123,6 +1124,7 @@ mountnfs(struct nfs_args *argp, struct m mtx_init(&nmp->nm_sockreq.nr_mtx, "nfssock", NULL, MTX_DEF); mp->mnt_data = nmp; nmp->nm_getinfo = nfs_getnlminfo; + nmp->nm_vinvalbuf = ncl_vinvalbuf; } vfs_getnewfsid(mp); nmp->nm_mountp = mp; @@ -1465,7 +1467,8 @@ nfs_sysctl(struct mount *mp, fsctlop_t o */ static void nfs_getnlminfo(struct vnode *vp, uint8_t *fhp, size_t *fhlenp, - struct sockaddr_storage *sp, int *is_v3p, off_t *sizep) + struct sockaddr_storage *sp, int *is_v3p, off_t *sizep, + struct timeval *timeop) { struct nfsmount *nmp; struct nfsnode *np = VTONFS(vp); @@ -1481,5 +1484,9 @@ nfs_getnlminfo(struct vnode *vp, uint8_t *is_v3p = NFS_ISV3(vp); if (sizep != NULL) *sizep = np->n_size; + if (timeop != NULL) { + timeop->tv_sec = nmp->nm_timeo / NFS_HZ; + timeop->tv_usec = (nmp->nm_timeo % NFS_HZ) * (1000000 / NFS_HZ); + } } Modified: head/sys/fs/nfsclient/nfsmount.h ============================================================================== --- head/sys/fs/nfsclient/nfsmount.h Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/fs/nfsclient/nfsmount.h Mon Jan 3 20:37:31 2011 (r216931) @@ -94,6 +94,7 @@ struct nfsmount { #define nm_retry nm_com.nmcom_retry #define nm_hostname nm_com.nmcom_hostname #define nm_getinfo nm_com.nmcom_getinfo +#define nm_vinvalbuf nm_com.nmcom_vinvalbuf #define NFSMNT_DIRPATH(m) (&((m)->nm_name[(m)->nm_krbnamelen + 1])) #define NFSMNT_SRVKRBNAME(m) \ Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Mon Jan 3 20:37:31 2011 (r216931) @@ -3142,6 +3142,7 @@ DECLARE_MODULE(nfsd, nfsd_mod, SI_SUB_VF /* So that loader and kldload(2) can find us, wherever we are.. */ MODULE_VERSION(nfsd, 1); MODULE_DEPEND(nfsd, nfscommon, 1, 1, 1); +MODULE_DEPEND(nfsd, nfslock, 1, 1, 1); MODULE_DEPEND(nfsd, nfslockd, 1, 1, 1); MODULE_DEPEND(nfsd, krpc, 1, 1, 1); MODULE_DEPEND(nfsd, nfssvc, 1, 1, 1); Modified: head/sys/nfs/nfs_lock.c ============================================================================== --- head/sys/nfs/nfs_lock.c Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/nfs/nfs_lock.c Mon Jan 3 20:37:31 2011 (r216931) @@ -251,7 +251,7 @@ nfs_dolock(struct vop_advlock_args *ap) ASSERT_VOP_LOCKED(vp, "nfs_dolock"); nmp->nm_getinfo(vp, msg.lm_fh, &msg.lm_fh_len, &msg.lm_addr, - &msg.lm_nfsv3, NULL); + &msg.lm_nfsv3, NULL, NULL); VOP_UNLOCK(vp, 0); /* Modified: head/sys/nfs/nfs_mountcommon.h ============================================================================== --- head/sys/nfs/nfs_mountcommon.h Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/nfs/nfs_mountcommon.h Mon Jan 3 20:37:31 2011 (r216931) @@ -35,7 +35,9 @@ * a mechanism for getting the client specific info for an nfs vnode. */ typedef void nfs_getinfofromvp_ftype(struct vnode *, uint8_t *, size_t *, - struct sockaddr_storage *, int *, off_t *); + struct sockaddr_storage *, int *, off_t *, + struct timeval *); +typedef int nfs_vinvalbuf_ftype(struct vnode *, int, struct thread *, int); struct nfsmount_common { struct mtx nmcom_mtx; @@ -46,6 +48,7 @@ struct nfsmount_common { int nmcom_retry; /* Max retries */ char nmcom_hostname[MNAMELEN]; /* server's name */ nfs_getinfofromvp_ftype *nmcom_getinfo; /* Get info from nfsnode */ + nfs_vinvalbuf_ftype *nmcom_vinvalbuf; /* Invalidate buffers */ }; #endif /* _NFS_MOUNTCOMMON_H_ */ Modified: head/sys/nfsclient/nfs_vfsops.c ============================================================================== --- head/sys/nfsclient/nfs_vfsops.c Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/nfsclient/nfs_vfsops.c Mon Jan 3 20:37:31 2011 (r216931) @@ -116,7 +116,8 @@ static int mountnfs(struct nfs_args *, s struct sockaddr *, char *, struct vnode **, struct ucred *cred, int); static void nfs_getnlminfo(struct vnode *, uint8_t *, size_t *, - struct sockaddr_storage *, int *, off_t *); + struct sockaddr_storage *, int *, off_t *, + struct timeval *); static vfs_mount_t nfs_mount; static vfs_cmount_t nfs_cmount; static vfs_unmount_t nfs_unmount; @@ -1205,6 +1206,7 @@ mountnfs(struct nfs_args *argp, struct m TAILQ_INIT(&nmp->nm_bufq); mp->mnt_data = nmp; nmp->nm_getinfo = nfs_getnlminfo; + nmp->nm_vinvalbuf = nfs_vinvalbuf; } vfs_getnewfsid(mp); nmp->nm_mountp = mp; @@ -1499,7 +1501,8 @@ nfs_sysctl(struct mount *mp, fsctlop_t o */ static void nfs_getnlminfo(struct vnode *vp, uint8_t *fhp, size_t *fhlenp, - struct sockaddr_storage *sp, int *is_v3p, off_t *sizep) + struct sockaddr_storage *sp, int *is_v3p, off_t *sizep, + struct timeval *timeop) { struct nfsmount *nmp; struct nfsnode *np = VTONFS(vp); @@ -1515,5 +1518,9 @@ nfs_getnlminfo(struct vnode *vp, uint8_t *is_v3p = NFS_ISV3(vp); if (sizep != NULL) *sizep = np->n_size; + if (timeop != NULL) { + timeop->tv_sec = nmp->nm_timeo / NFS_HZ; + timeop->tv_usec = (nmp->nm_timeo % NFS_HZ) * (1000000 / NFS_HZ); + } } Modified: head/sys/nfsclient/nfsmount.h ============================================================================== --- head/sys/nfsclient/nfsmount.h Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/nfsclient/nfsmount.h Mon Jan 3 20:37:31 2011 (r216931) @@ -100,6 +100,7 @@ struct nfsmount { #define nm_retry nm_com.nmcom_retry #define nm_hostname nm_com.nmcom_hostname #define nm_getinfo nm_com.nmcom_getinfo +#define nm_vinvalbuf nm_com.nmcom_vinvalbuf #if defined(_KERNEL) /* Modified: head/sys/nlm/nlm_advlock.c ============================================================================== --- head/sys/nlm/nlm_advlock.c Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/nlm/nlm_advlock.c Mon Jan 3 20:37:31 2011 (r216931) @@ -217,20 +217,18 @@ nlm_advlock_internal(struct vnode *vp, v ASSERT_VOP_LOCKED(vp, "nlm_advlock_1"); + nmp = VFSTONFS(vp->v_mount); /* * Push any pending writes to the server and flush our cache * so that if we are contending with another machine for a * file, we get whatever they wrote and vice-versa. */ if (op == F_SETLK || op == F_UNLCK) - nfs_vinvalbuf(vp, V_SAVE, td, 1); + nmp->nm_vinvalbuf(vp, V_SAVE, td, 1); - nmp = VFSTONFS(vp->v_mount); strcpy(servername, nmp->nm_hostname); - nmp->nm_getinfo(vp, fh.fh_bytes, &fhlen, &ss, &is_v3, &size); + nmp->nm_getinfo(vp, fh.fh_bytes, &fhlen, &ss, &is_v3, &size, &timo); sa = (struct sockaddr *) &ss; - timo.tv_sec = nmp->nm_timeo / NFS_HZ; - timo.tv_usec = (nmp->nm_timeo % NFS_HZ) * (1000000 / NFS_HZ); if (is_v3 != 0) vers = NLM_VERS4; else Modified: head/sys/nlm/nlm_prot_impl.c ============================================================================== --- head/sys/nlm/nlm_prot_impl.c Mon Jan 3 20:32:08 2011 (r216930) +++ head/sys/nlm/nlm_prot_impl.c Mon Jan 3 20:37:31 2011 (r216931) @@ -2430,6 +2430,5 @@ DECLARE_MODULE(nfslockd, nfslockd_mod, S /* So that loader and kldload(2) can find us, wherever we are.. */ MODULE_DEPEND(nfslockd, krpc, 1, 1, 1); -MODULE_DEPEND(nfslockd, nfs, 1, 1, 1); MODULE_DEPEND(nfslockd, nfslock, 1, 1, 1); MODULE_VERSION(nfslockd, 1); From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 21:28:12 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B6A43106566B; Mon, 3 Jan 2011 21:28:12 +0000 (UTC) (envelope-from csjp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A57058FC12; Mon, 3 Jan 2011 21:28:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03LSCa4005863; Mon, 3 Jan 2011 21:28:12 GMT (envelope-from csjp@svn.freebsd.org) Received: (from csjp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03LSCSa005861; Mon, 3 Jan 2011 21:28:12 GMT (envelope-from csjp@svn.freebsd.org) Message-Id: <201101032128.p03LSCSa005861@svn.freebsd.org> From: "Christian S.J. Peron" Date: Mon, 3 Jan 2011 21:28:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216932 - head/libexec/ftpd X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 21:28:12 -0000 Author: csjp Date: Mon Jan 3 21:28:12 2011 New Revision: 216932 URL: http://svn.freebsd.org/changeset/base/216932 Log: expand checkuser() to support the propagation of error codes back to the caller. Currently, checkuser() does not differentiate between the failure to open the file and the absence of a user in the file. Check to see if there was an error opening the file. If there are any errors, terminate the connection. Currently, the only exception to this rule is ENOENT, since there is nothing that says the /etc/ftpuser and /etc/ftpchroot has to exist. MFC after: 3 weeks Modified: head/libexec/ftpd/ftpd.c Modified: head/libexec/ftpd/ftpd.c ============================================================================== --- head/libexec/ftpd/ftpd.c Mon Jan 3 20:37:31 2011 (r216931) +++ head/libexec/ftpd/ftpd.c Mon Jan 3 21:28:12 2011 (r216932) @@ -244,7 +244,7 @@ static void sigurg(int); static void maskurg(int); static void flagxfer(int); static int myoob(void); -static int checkuser(char *, char *, int, char **); +static int checkuser(char *, char *, int, char **, int *); static FILE *dataconn(char *, off_t, char *); static void dolog(struct sockaddr *); static void end_login(void); @@ -996,6 +996,7 @@ static char curname[MAXLOGNAME]; /* curr void user(char *name) { + int ecode; char *cp, *shell; if (logged_in) { @@ -1016,8 +1017,11 @@ user(char *name) pw = sgetpwnam("ftp"); #endif if (strcmp(name, "ftp") == 0 || strcmp(name, "anonymous") == 0) { - if (checkuser(_PATH_FTPUSERS, "ftp", 0, NULL) || - checkuser(_PATH_FTPUSERS, "anonymous", 0, NULL)) + if (checkuser(_PATH_FTPUSERS, "ftp", 0, NULL, &ecode) || + (ecode != 0 && ecode != ENOENT)) + reply(530, "User %s access denied.", name); + else if (checkuser(_PATH_FTPUSERS, "anonymous", 0, NULL, &ecode) || + (ecode != 0 && ecode != ENOENT)) reply(530, "User %s access denied.", name); else if (pw != NULL) { guest = 1; @@ -1045,7 +1049,9 @@ user(char *name) break; endusershell(); - if (cp == NULL || checkuser(_PATH_FTPUSERS, name, 1, NULL)) { + if (cp == NULL || + (checkuser(_PATH_FTPUSERS, name, 1, NULL, &ecode) || + (ecode != 0 && ecode != ENOENT))) { reply(530, "User %s access denied.", name); if (logging) syslog(LOG_NOTICE, @@ -1087,13 +1093,15 @@ user(char *name) * of the matching line in "residue" if not NULL. */ static int -checkuser(char *fname, char *name, int pwset, char **residue) +checkuser(char *fname, char *name, int pwset, char **residue, int *ecode) { FILE *fd; int found = 0; size_t len; char *line, *mp, *p; + if (ecode != NULL) + *ecode = 0; if ((fd = fopen(fname, "r")) != NULL) { while (!found && (line = fgetln(fd, &len)) != NULL) { /* skip comments */ @@ -1162,7 +1170,8 @@ nextline: free(mp); } (void) fclose(fd); - } + } else if (ecode != NULL) + *ecode = errno; return (found); } @@ -1359,7 +1368,7 @@ auth_pam(struct passwd **ppw, const char void pass(char *passwd) { - int rval; + int rval, ecode; FILE *fd; #ifdef LOGIN_CAP login_cap_t *lc = NULL; @@ -1475,11 +1484,21 @@ skip: #endif dochroot = - checkuser(_PATH_FTPCHROOT, pw->pw_name, 1, &residue) + checkuser(_PATH_FTPCHROOT, pw->pw_name, 1, &residue, &ecode) #ifdef LOGIN_CAP /* Allow login.conf configuration as well */ || login_getcapbool(lc, "ftp-chroot", 0) #endif ; + /* + * It is possible that checkuser() failed to open the chroot file. + * If this is the case, report that logins are un-available, since we + * have no way of checking whether or not the user should be chrooted. + * We ignore ENOENT since it is not required that this file be present. + */ + if (ecode != 0 && ecode != ENOENT) { + reply(530, "Login not available right now."); + return; + } chrootdir = NULL; /* Disable wtmp logging when chrooting. */ From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 22:48:01 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 66A83106564A; Mon, 3 Jan 2011 22:48:01 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 565668FC18; Mon, 3 Jan 2011 22:48:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03Mm1e3007685; Mon, 3 Jan 2011 22:48:01 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03Mm14W007683; Mon, 3 Jan 2011 22:48:01 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101032248.p03Mm14W007683@svn.freebsd.org> From: Warner Losh Date: Mon, 3 Jan 2011 22:48:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216934 - head X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 22:48:01 -0000 Author: imp Date: Mon Jan 3 22:48:01 2011 New Revision: 216934 URL: http://svn.freebsd.org/changeset/base/216934 Log: When TARGET_ARCH_${kernel} gets set, it is using the host's config, not the one we build as part of make world. This means that make universe will fail if building on a too-old current or any stable system prior to a few days ago in weird ways (parse errors from shell). This copes with these old systems in two ways: (1) Works around the WARNING: issue by filtering all warnings that sneak onto stdout. (2) if TARGET_ARCH_${kernel} winds up being empty, then we error out immediately with a semi-useful error message. This usually comes from config not groking -m. Ideally, we'd use a buildworld's config here, but that's tricky, so I'll leave that detail to others to fix (it has to be done post make world for the arch rather than at the top level makefile). This should make 'make universe' usable from recent 8-stable systems (recent == last few months or so) for building -current. They have -m, but spewed warnings out stdout. Older systems will now at least get a firm error early rather than a confusing error late. Modified: head/Makefile Modified: head/Makefile ============================================================================== --- head/Makefile Mon Jan 3 22:25:34 2011 (r216933) +++ head/Makefile Mon Jan 3 22:48:01 2011 (r216934) @@ -351,7 +351,10 @@ universe_kernconfs: .for kernel in ${KERNCONFS} TARGET_ARCH_${kernel}!= cd ${.CURDIR}/sys/${TARGET}/conf && \ config -m ${.CURDIR}/sys/${TARGET}/conf/${kernel} 2> /dev/null | \ - cut -f 2 + grep -v WARNING: | cut -f 2 +.if empty(TARGET_ARCH_${kernel}) +.error "Target architecture for ${TARGET}/conf/${kernel} unknown. config(8) likely too old." +.endif universe_kernconfs: universe_kernconf_${TARGET}_${kernel} universe_kernconf_${TARGET}_${kernel}: @(cd ${.CURDIR} && env __MAKE_CONF=/dev/null \ From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 23:05:20 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7544B106564A; Mon, 3 Jan 2011 23:05:20 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 64C458FC0C; Mon, 3 Jan 2011 23:05:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03N5KOu008367; Mon, 3 Jan 2011 23:05:20 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03N5Kp5008365; Mon, 3 Jan 2011 23:05:20 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101032305.p03N5Kp5008365@svn.freebsd.org> From: Warner Losh Date: Mon, 3 Jan 2011 23:05:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216938 - head X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 23:05:20 -0000 Author: imp Date: Mon Jan 3 23:05:20 2011 New Revision: 216938 URL: http://svn.freebsd.org/changeset/base/216938 Log: Note compatibility issues with make universe and stable systems. Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Mon Jan 3 23:00:52 2011 (r216937) +++ head/UPDATING Mon Jan 3 23:05:20 2011 (r216938) @@ -22,6 +22,20 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 9. machines to maximize performance. (To disable malloc debugging, run ln -s aj /etc/malloc.conf.) +20110103: + If you are trying to run make universe on a -stable system, and you get + the following warning: +"Makefile", line 356: "Target architecture for i386/conf/GENERIC unknown. config(8) likely too old." + or something similar to it, then you must upgrade your -stable system + to 8.2-Release or newer (really, any time after r210146 7/15/2010 in + stable/8) or build the config from the latest stable/8 branch and + install it on your system. + + Prior to this date, building a current universe on 8-stable system from + between 7/15/2010 and 1/2/2011 would result in a weird shell parsing + error in the first kernel build phase. A new config on those old systems + will fix that problem for older versions of -current. + 20101228: The TCP stack has been modified to allow Khelp modules to interact with it via helper hook points and store per-connection data in the TCP From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 23:11:52 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BB5EC106566B; Mon, 3 Jan 2011 23:11:52 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AA8908FC08; Mon, 3 Jan 2011 23:11:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03NBqiN008551; Mon, 3 Jan 2011 23:11:52 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03NBqDE008549; Mon, 3 Jan 2011 23:11:52 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201101032311.p03NBqDE008549@svn.freebsd.org> From: Nathan Whitehorn Date: Mon, 3 Jan 2011 23:11:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216939 - head/libexec/rtld-elf/powerpc64 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 23:11:52 -0000 Author: nwhitehorn Date: Mon Jan 3 23:11:52 2011 New Revision: 216939 URL: http://svn.freebsd.org/changeset/base/216939 Log: Add support for R_PPC64_UADDR64 relocations. Modified: head/libexec/rtld-elf/powerpc64/reloc.c Modified: head/libexec/rtld-elf/powerpc64/reloc.c ============================================================================== --- head/libexec/rtld-elf/powerpc64/reloc.c Mon Jan 3 23:05:20 2011 (r216938) +++ head/libexec/rtld-elf/powerpc64/reloc.c Mon Jan 3 23:11:52 2011 (r216939) @@ -165,7 +165,8 @@ reloc_nonplt_object(Obj_Entry *obj_rtld, case R_PPC_NONE: break; - case R_PPC64_ADDR64: /* doubleword64 S + A */ + case R_PPC64_UADDR64: /* doubleword64 S + A */ + case R_PPC64_ADDR64: case R_PPC_GLOB_DAT: def = find_symdef(ELF_R_SYM(rela->r_info), obj, &defobj, false, cache, lockstate); From owner-svn-src-head@FreeBSD.ORG Mon Jan 3 23:37:42 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E05EB10656D0; Mon, 3 Jan 2011 23:37:42 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D01368FC1C; Mon, 3 Jan 2011 23:37:42 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p03NbgL6009095; Mon, 3 Jan 2011 23:37:42 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p03Nbgrr009093; Mon, 3 Jan 2011 23:37:42 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201101032337.p03Nbgrr009093@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 3 Jan 2011 23:37:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216940 - head/sys/dev/acpica X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jan 2011 23:37:43 -0000 Author: jkim Date: Mon Jan 3 23:37:42 2011 New Revision: 216940 URL: http://svn.freebsd.org/changeset/base/216940 Log: Fix parameters for wakeup(9) and tsleep(9). MFC after: 3 days Modified: head/sys/dev/acpica/acpi_ec.c Modified: head/sys/dev/acpica/acpi_ec.c ============================================================================== --- head/sys/dev/acpica/acpi_ec.c Mon Jan 3 23:11:52 2011 (r216939) +++ head/sys/dev/acpica/acpi_ec.c Mon Jan 3 23:37:42 2011 (r216940) @@ -707,7 +707,7 @@ EcGpeHandler(ACPI_HANDLE GpeDevice, UINT * address and then data values.) */ atomic_add_int(&sc->ec_gencount, 1); - wakeup(&sc); + wakeup(sc); /* * If the EC_SCI bit of the status register is set, queue a query handler. @@ -863,7 +863,7 @@ EcWaitEvent(struct acpi_ec_softc *sc, EC */ for (i = 0; i < count; i++) { if (gen_count == sc->ec_gencount) - tsleep(&sc, 0, "ecgpe", slp_ival); + tsleep(sc, 0, "ecgpe", slp_ival); /* * Record new generation count. It's possible the GPE was * just to notify us that a query is needed and we need to From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 00:08:39 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E9C7A1065673; Tue, 4 Jan 2011 00:08:39 +0000 (UTC) (envelope-from pjd@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D95C08FC0A; Tue, 4 Jan 2011 00:08:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p0408dQv010380; Tue, 4 Jan 2011 00:08:39 GMT (envelope-from pjd@svn.freebsd.org) Received: (from pjd@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p0408dak010378; Tue, 4 Jan 2011 00:08:39 GMT (envelope-from pjd@svn.freebsd.org) Message-Id: <201101040008.p0408dak010378@svn.freebsd.org> From: Pawel Jakub Dawidek Date: Tue, 4 Jan 2011 00:08:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216941 - head/sys/dev/mmc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 00:08:40 -0000 Author: pjd Date: Tue Jan 4 00:08:39 2011 New Revision: 216941 URL: http://svn.freebsd.org/changeset/base/216941 Log: Wait for commands to complete 10 times longer. This makes my A-DATA 32GB SDHC card being detected. Reviewed by: imp MFC after: 2 weeks Modified: head/sys/dev/mmc/mmc.c Modified: head/sys/dev/mmc/mmc.c ============================================================================== --- head/sys/dev/mmc/mmc.c Mon Jan 3 23:37:42 2011 (r216940) +++ head/sys/dev/mmc/mmc.c Tue Jan 4 00:08:39 2011 (r216941) @@ -448,7 +448,7 @@ mmc_send_app_op_cond(struct mmc_softc *s cmd.flags = MMC_RSP_R3 | MMC_CMD_BCR; cmd.data = NULL; - for (i = 0; i < 100; i++) { + for (i = 0; i < 1000; i++) { err = mmc_wait_for_app_cmd(sc, 0, &cmd, CMD_RETRIES); if (err != MMC_ERR_NONE) break; @@ -475,7 +475,7 @@ mmc_send_op_cond(struct mmc_softc *sc, u cmd.flags = MMC_RSP_R3 | MMC_CMD_BCR; cmd.data = NULL; - for (i = 0; i < 100; i++) { + for (i = 0; i < 1000; i++) { err = mmc_wait_for_cmd(sc, &cmd, CMD_RETRIES); if (err != MMC_ERR_NONE) break; From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 00:10:29 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CBEB010656A8; Tue, 4 Jan 2011 00:10:29 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A0E018FC0A; Tue, 4 Jan 2011 00:10:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p040ATv1010533; Tue, 4 Jan 2011 00:10:29 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p040ATX1010531; Tue, 4 Jan 2011 00:10:29 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201101040010.p040ATX1010531@svn.freebsd.org> From: Jung-uk Kim Date: Tue, 4 Jan 2011 00:10:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216942 - head/sys/dev/acpica X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 00:10:29 -0000 Author: jkim Date: Tue Jan 4 00:10:29 2011 New Revision: 216942 URL: http://svn.freebsd.org/changeset/base/216942 Log: Clear GPE from a query handler if the task was deferred. Modified: head/sys/dev/acpica/acpi_ec.c Modified: head/sys/dev/acpica/acpi_ec.c ============================================================================== --- head/sys/dev/acpica/acpi_ec.c Tue Jan 4 00:08:39 2011 (r216941) +++ head/sys/dev/acpica/acpi_ec.c Tue Jan 4 00:10:29 2011 (r216942) @@ -624,7 +624,7 @@ EcGpeQueryHandler(void *Context) struct acpi_ec_softc *sc = (struct acpi_ec_softc *)Context; UINT8 Data; ACPI_STATUS Status; - int retry; + int retry, sci_enqueued; char qxx[5]; ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); @@ -645,6 +645,7 @@ EcGpeQueryHandler(void *Context) * that may arise from running the query from causing another query * to be queued, we clear the pending flag only after running it. */ + sci_enqueued = sc->ec_sci_pend; for (retry = 0; retry < 2; retry++) { Status = EcCommand(sc, EC_COMMAND_QUERY); if (ACPI_SUCCESS(Status)) @@ -684,6 +685,12 @@ EcGpeQueryHandler(void *Context) device_printf(sc->ec_dev, "evaluation of query method %s failed: %s\n", qxx, AcpiFormatException(Status)); } + if (sci_enqueued) { + Status = AcpiFinishGpe(sc->ec_gpehandle, sc->ec_gpebit); + if (ACPI_FAILURE(Status)) + device_printf(sc->ec_dev, "clearing GPE failed: %s\n", + AcpiFormatException(Status)); + } } /* @@ -717,16 +724,12 @@ EcGpeHandler(ACPI_HANDLE GpeDevice, UINT if ((EcStatus & EC_EVENT_SCI) && !sc->ec_sci_pend) { CTR0(KTR_ACPI, "ec gpe queueing query handler"); Status = AcpiOsExecute(OSL_GPE_HANDLER, EcGpeQueryHandler, Context); - if (ACPI_SUCCESS(Status)) + if (ACPI_SUCCESS(Status)) { sc->ec_sci_pend = TRUE; - else + return (0); + } else printf("EcGpeHandler: queuing GPE query handler failed\n"); } - - /* - * XXX jkim - * AcpiFinishGpe() should be used at the necessary places. - */ return (ACPI_REENABLE_GPE); } From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 00:11:09 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E62D9106566C; Tue, 4 Jan 2011 00:11:09 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D5A298FC17; Tue, 4 Jan 2011 00:11:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p040B9YO010635; Tue, 4 Jan 2011 00:11:09 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p040B9Er010633; Tue, 4 Jan 2011 00:11:09 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201101040011.p040B9Er010633@svn.freebsd.org> From: Ed Maste Date: Tue, 4 Jan 2011 00:11:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216943 - head/libexec/ftpd X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 00:11:10 -0000 Author: emaste Date: Tue Jan 4 00:11:09 2011 New Revision: 216943 URL: http://svn.freebsd.org/changeset/base/216943 Log: Handle failure from ftpd_popen in statfilecmd(). Reviewed by: attilio MFC after: 1 week Modified: head/libexec/ftpd/ftpd.c Modified: head/libexec/ftpd/ftpd.c ============================================================================== --- head/libexec/ftpd/ftpd.c Tue Jan 4 00:10:29 2011 (r216942) +++ head/libexec/ftpd/ftpd.c Tue Jan 4 00:11:09 2011 (r216943) @@ -2350,6 +2350,10 @@ statfilecmd(char *filename) code = lstat(filename, &st) == 0 && S_ISDIR(st.st_mode) ? 212 : 213; (void)snprintf(line, sizeof(line), _PATH_LS " -lgA %s", filename); fin = ftpd_popen(line, "r"); + if (fin == NULL) { + perror_reply(551, filename); + return; + } lreply(code, "Status of %s:", filename); atstart = 1; while ((c = getc(fin)) != EOF) { From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 00:16:39 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 345DC1065672; Tue, 4 Jan 2011 00:16:39 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 096E88FC14; Tue, 4 Jan 2011 00:16:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p040Gcqi011000; Tue, 4 Jan 2011 00:16:38 GMT (envelope-from cperciva@svn.freebsd.org) Received: (from cperciva@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p040GcNf010998; Tue, 4 Jan 2011 00:16:38 GMT (envelope-from cperciva@svn.freebsd.org) Message-Id: <201101040016.p040GcNf010998@svn.freebsd.org> From: Colin Percival Date: Tue, 4 Jan 2011 00:16:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216944 - head/sys/i386/xen X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 00:16:39 -0000 Author: cperciva Date: Tue Jan 4 00:16:38 2011 New Revision: 216944 URL: http://svn.freebsd.org/changeset/base/216944 Log: Adjust the critical section protecting _xen_flush_queue to cover the entire range where the page mapping request queue needs to be atomically examined and modified. Oddly, while this doesn't seem to affect the overall rate of panics (running 'make index' on EC2 t1.micro instances, there are 0.6 +/- 0.1 panics per hour, both before and after this change), it eliminates vm_fault from panic backtraces, leaving only backtraces going through vmspace_fork. Modified: head/sys/i386/xen/xen_machdep.c Modified: head/sys/i386/xen/xen_machdep.c ============================================================================== --- head/sys/i386/xen/xen_machdep.c Tue Jan 4 00:11:09 2011 (r216943) +++ head/sys/i386/xen/xen_machdep.c Tue Jan 4 00:16:38 2011 (r216944) @@ -42,6 +42,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include @@ -249,10 +250,13 @@ _xen_flush_queue(void) SET_VCPU(); int _xpq_idx = XPQ_IDX; int error, i; - /* window of vulnerability here? */ +#ifdef INVARIANTS if (__predict_true(gdtset)) - critical_enter(); + KASSERT(curthread->td_critnest > 0, + ("xen queue flush should be in a critical section")); +#endif + XPQ_IDX = 0; /* Make sure index is cleared first to avoid double updates. */ error = HYPERVISOR_mmu_update((mmu_update_t *)&XPQ_QUEUE, @@ -286,8 +290,6 @@ _xen_flush_queue(void) } } #endif - if (__predict_true(gdtset)) - critical_exit(); if (__predict_false(error < 0)) { for (i = 0; i < _xpq_idx; i++) printf("val: %llx ptr: %llx\n", @@ -301,7 +303,12 @@ void xen_flush_queue(void) { SET_VCPU(); + + if (__predict_true(gdtset)) + critical_enter(); if (XPQ_IDX != 0) _xen_flush_queue(); + if (__predict_true(gdtset)) + critical_exit(); } static __inline void From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 00:39:57 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 01A94106566B; Tue, 4 Jan 2011 00:39:57 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E549E8FC14; Tue, 4 Jan 2011 00:39:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p040duNW012485; Tue, 4 Jan 2011 00:39:56 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p040dugD012482; Tue, 4 Jan 2011 00:39:56 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201101040039.p040dugD012482@svn.freebsd.org> From: Ed Maste Date: Tue, 4 Jan 2011 00:39:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216945 - head/libexec/ftpd X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 00:39:57 -0000 Author: emaste Date: Tue Jan 4 00:39:56 2011 New Revision: 216945 URL: http://svn.freebsd.org/changeset/base/216945 Log: Make format string a string literal. (Discovered by clang.) MFC After: 1 week Modified: head/libexec/ftpd/ftpd.c Modified: head/libexec/ftpd/ftpd.c ============================================================================== --- head/libexec/ftpd/ftpd.c Tue Jan 4 00:16:38 2011 (r216944) +++ head/libexec/ftpd/ftpd.c Tue Jan 4 00:39:56 2011 (r216945) @@ -2153,7 +2153,7 @@ send_data(FILE *instr, FILE *outstr, siz } } ENDXFER; - reply(226, msg); + reply(226, "%s", msg); return (0); } From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 02:11:04 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 043C1106566B; Tue, 4 Jan 2011 02:11:04 +0000 (UTC) (envelope-from jmallett@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E77358FC12; Tue, 4 Jan 2011 02:11:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p042B3Jn018079; Tue, 4 Jan 2011 02:11:03 GMT (envelope-from jmallett@svn.freebsd.org) Received: (from jmallett@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p042B3XK018077; Tue, 4 Jan 2011 02:11:03 GMT (envelope-from jmallett@svn.freebsd.org) Message-Id: <201101040211.p042B3XK018077@svn.freebsd.org> From: Juli Mallett Date: Tue, 4 Jan 2011 02:11:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216946 - head/sys/mips/cavium X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 02:11:04 -0000 Author: jmallett Date: Tue Jan 4 02:11:03 2011 New Revision: 216946 URL: http://svn.freebsd.org/changeset/base/216946 Log: o) Unmask Central Interrupt Unit interrupts on APs, too. o) There's no good reason to make the low bits of the ebase the core number. While per-CPU exception bases would be nice, for now we just need to make ebase the same on all cores. Modified: head/sys/mips/cavium/octeon_mp.c Modified: head/sys/mips/cavium/octeon_mp.c ============================================================================== --- head/sys/mips/cavium/octeon_mp.c Tue Jan 4 00:39:56 2011 (r216945) +++ head/sys/mips/cavium/octeon_mp.c Tue Jan 4 02:11:03 2011 (r216946) @@ -74,12 +74,12 @@ platform_ipi_intrnum(void) void platform_init_ap(int cpuid) { - unsigned ipi_int_mask, clock_int_mask; + unsigned ciu_int_mask, clock_int_mask, ipi_int_mask; /* * Set the exception base. */ - mips_wr_ebase(0x80000000 | cpuid); + mips_wr_ebase(0x80000000); /* * Clear any pending IPIs. @@ -92,11 +92,12 @@ platform_init_ap(int cpuid) octeon_ciu_reset(); /* - * Unmask the clock and ipi interrupts. + * Unmask the clock, ipi and ciu interrupts. */ + ciu_int_mask = hard_int_mask(0); clock_int_mask = hard_int_mask(5); ipi_int_mask = hard_int_mask(platform_ipi_intrnum()); - set_intr_mask(ipi_int_mask | clock_int_mask); + set_intr_mask(ciu_int_mask | clock_int_mask | ipi_int_mask); mips_wbflush(); } From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 02:33:49 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 35600106566C; Tue, 4 Jan 2011 02:33:49 +0000 (UTC) (envelope-from jmallett@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2353D8FC13; Tue, 4 Jan 2011 02:33:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p042XnNm019465; Tue, 4 Jan 2011 02:33:49 GMT (envelope-from jmallett@svn.freebsd.org) Received: (from jmallett@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p042XnRH019462; Tue, 4 Jan 2011 02:33:49 GMT (envelope-from jmallett@svn.freebsd.org) Message-Id: <201101040233.p042XnRH019462@svn.freebsd.org> From: Juli Mallett Date: Tue, 4 Jan 2011 02:33:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216947 - in head/sys/mips: cavium include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 02:33:49 -0000 Author: jmallett Date: Tue Jan 4 02:33:48 2011 New Revision: 216947 URL: http://svn.freebsd.org/changeset/base/216947 Log: o) Add MIPS_COP_0_EXC_PC accessors to . o) Make the octeon_wdog driver work on multi-CPU systems and to also print more information on NMI that may aid debugging. Simplify and clean up internal API and structure. Modified: head/sys/mips/cavium/octeon_wdog.c head/sys/mips/include/cpufunc.h Modified: head/sys/mips/cavium/octeon_wdog.c ============================================================================== --- head/sys/mips/cavium/octeon_wdog.c Tue Jan 4 02:11:03 2011 (r216946) +++ head/sys/mips/cavium/octeon_wdog.c Tue Jan 4 02:33:48 2011 (r216947) @@ -1,5 +1,6 @@ /*- * Copyright (c) 2009, Oleksandr Tymoshenko + * Copyright (c) 2010-2011, Juli Mallett * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -48,93 +49,98 @@ __FBSDID("$FreeBSD$"); #define DEFAULT_TIMER_VAL 65535 struct octeon_wdog_softc { - device_t dev; - /* XXX: replace with repscive CVMX_ constant */ - struct resource *irq_res[16]; - void *intr_hdl[16]; - int armed; - int debug; + device_t sc_dev; + struct octeon_wdog_core_softc { + int csc_core; + struct resource *csc_intr; + void *csc_intr_cookie; + } sc_cores[MAXCPU]; + int sc_armed; + int sc_debug; }; extern void octeon_wdog_nmi_handler(void); void octeon_wdog_nmi(void); -static void octeon_watchdog_arm_core(int core, unsigned long timer_val); -static void octeon_watchdog_disarm_core(int core); -static int octeon_wdog_attach(device_t dev); -static void octeon_wdog_identify(driver_t *drv, device_t parent); -static int octeon_wdog_intr(void *);; -static int octeon_wdog_probe(device_t dev); -static void octeon_wdog_setup(struct octeon_wdog_softc *sc, int cpu); -static void octeon_wdog_sysctl(device_t dev); -static void octeon_wdog_watchdog_fn(void *private, u_int cmd, int *error); +static void octeon_watchdog_arm_core(int); +static void octeon_watchdog_disarm_core(int); +static int octeon_wdog_attach(device_t); +static void octeon_wdog_identify(driver_t *, device_t); +static int octeon_wdog_intr(void *); +static int octeon_wdog_probe(device_t); +static void octeon_wdog_setup(struct octeon_wdog_softc *, int); +static void octeon_wdog_sysctl(device_t); +static void octeon_wdog_watchdog_fn(void *, u_int, int *); void -octeon_wdog_nmi() +octeon_wdog_nmi(void) { + int core; - /* XXX: Add something useful here */ - printf("NMI detected\n"); + core = cvmx_get_core_num(); - /* - * This is the end - * Beautiful friend + printf("cpu%u: NMI detected\n", core); + printf("cpu%u: Exception PC: %p\n", core, (void *)mips_rd_excpc()); + printf("cpu%u: status %#x cause %#x\n", core, mips_rd_status(), mips_rd_cause()); + + /* + * This is the end + * Beautiful friend * * Just wait for Soft Reset to come and take us */ for (;;) - ; + continue; } -static void -octeon_watchdog_arm_core(int core, unsigned long timer_val) +static void +octeon_watchdog_arm_core(int core) { cvmx_ciu_wdogx_t ciu_wdog; /* Poke it! */ cvmx_write_csr(CVMX_CIU_PP_POKEX(core), 1); + /* + * XXX + * Perhaps if KDB is enabled, we should use mode=2 and drop into the + * debugger on NMI? + * + * XXX + * Timer should be calculated based on CPU frquency + */ ciu_wdog.u64 = 0; - ciu_wdog.s.len = timer_val; + ciu_wdog.s.len = DEFAULT_TIMER_VAL; ciu_wdog.s.mode = 3; cvmx_write_csr(CVMX_CIU_WDOGX(core), ciu_wdog.u64); } -static void +static void octeon_watchdog_disarm_core(int core) { cvmx_write_csr(CVMX_CIU_WDOGX(core), 0); } - - static void octeon_wdog_watchdog_fn(void *private, u_int cmd, int *error) { struct octeon_wdog_softc *sc = private; - uint64_t timer_val = 0; + int core; cmd &= WD_INTERVAL; - if (sc->debug) - device_printf(sc->dev, "octeon_wdog_watchdog_fn: cmd: %x\n", cmd); + if (sc->sc_debug) + device_printf(sc->sc_dev, "%s: cmd: %x\n", __func__, cmd); if (cmd > 0) { - if (sc->debug) - device_printf(sc->dev, "octeon_wdog_watchdog_fn: programming timer: %jx\n", (uintmax_t) timer_val); - /* - * XXX: This should be done for every core and with value - * calculated based on CPU frquency - */ - octeon_watchdog_arm_core(cvmx_get_core_num(), DEFAULT_TIMER_VAL); - sc->armed = 1; + CPU_FOREACH(core) + octeon_watchdog_arm_core(core); + sc->sc_armed = 1; *error = 0; } else { - if (sc->debug) - device_printf(sc->dev, "octeon_wdog_watchdog_fn: disarming\n"); - if (sc->armed) { - sc->armed = 0; - /* XXX: This should be done for every core */ - octeon_watchdog_disarm_core(cvmx_get_core_num()); + if (sc->sc_armed) { + CPU_FOREACH(core) + octeon_watchdog_disarm_core(core); + sc->sc_armed = 0; } } } @@ -144,54 +150,64 @@ octeon_wdog_sysctl(device_t dev) { struct octeon_wdog_softc *sc = device_get_softc(dev); - struct sysctl_ctx_list *ctx = device_get_sysctl_ctx(sc->dev); - struct sysctl_oid *tree = device_get_sysctl_tree(sc->dev); + struct sysctl_ctx_list *ctx = device_get_sysctl_ctx(sc->sc_dev); + struct sysctl_oid *tree = device_get_sysctl_tree(sc->sc_dev); SYSCTL_ADD_INT(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, - "debug", CTLFLAG_RW, &sc->debug, 0, + "debug", CTLFLAG_RW, &sc->sc_debug, 0, "enable watchdog debugging"); SYSCTL_ADD_INT(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, - "armed", CTLFLAG_RD, &sc->armed, 0, + "armed", CTLFLAG_RD, &sc->sc_armed, 0, "whether the watchdog is armed"); } static void -octeon_wdog_setup(struct octeon_wdog_softc *sc, int cpu) +octeon_wdog_setup(struct octeon_wdog_softc *sc, int core) { - int core, rid, err; + struct octeon_wdog_core_softc *csc; + int rid, error; - /* XXX: map cpu id to core here ? */ - core = cvmx_get_core_num(); + csc = &sc->sc_cores[core]; + + csc->csc_core = core; /* Interrupt part */ rid = 0; - sc->irq_res[core] = - bus_alloc_resource(sc->dev, SYS_RES_IRQ, &rid, - CVMX_IRQ_WDOG0+core, - CVMX_IRQ_WDOG0+core, 1, RF_ACTIVE); - if (!(sc->irq_res[core])) - goto error; - - err = bus_setup_intr(sc->dev, sc->irq_res[core], INTR_TYPE_MISC, - octeon_wdog_intr, NULL, sc, &sc->intr_hdl[core]); - if (err) - goto error; - - /* XXX: pin interrupt handler to the respective core */ - - /* Disarm by default */ - octeon_watchdog_disarm_core(core); - - return; - -error: - panic("failed to setup watchdog interrupt for core %d", core); + csc->csc_intr = bus_alloc_resource(sc->sc_dev, SYS_RES_IRQ, &rid, + CVMX_IRQ_WDOG0 + core, CVMX_IRQ_WDOG0 + core, 1, RF_ACTIVE); + if (csc->csc_intr == NULL) + panic("%s: bus_alloc_resource for core %u failed", + __func__, core); + + error = bus_setup_intr(sc->sc_dev, csc->csc_intr, INTR_TYPE_MISC, + octeon_wdog_intr, NULL, csc, &csc->csc_intr_cookie); + if (error != 0) + panic("%s: bus_setup_intr for core %u: %d", __func__, core, + error); + + bus_bind_intr(sc->sc_dev, csc->csc_intr, core); + bus_describe_intr(sc->sc_dev, csc->csc_intr, csc->csc_intr_cookie, + "cpu%u", core); + + if (sc->sc_armed) { + /* Armed by default. */ + octeon_watchdog_arm_core(core); + } else { + /* Disarmed by default. */ + octeon_watchdog_disarm_core(core); + } } - static int -octeon_wdog_intr(void *sc) +octeon_wdog_intr(void *arg) { + struct octeon_wdog_core_softc *csc = arg; + + KASSERT(csc->csc_core == cvmx_get_core_num(), + ("got watchdog interrupt for core %u on core %u.", + csc->csc_core, cvmx_get_core_num())); + + (void)csc; /* Poke it! */ cvmx_write_csr(CVMX_CIU_PP_POKEX(cvmx_get_core_num()), 1); @@ -211,14 +227,14 @@ static int octeon_wdog_attach(device_t dev) { struct octeon_wdog_softc *sc = device_get_softc(dev); - int i; uint64_t *nmi_handler = (uint64_t*)octeon_wdog_nmi_handler; - + int core, i; + /* Initialise */ - sc->armed = 0; - sc->debug = 0; + sc->sc_armed = 0; /* XXX Ought to be a tunable / config option. */ + sc->sc_debug = 0; - sc->dev = dev; + sc->sc_dev = dev; EVENTHANDLER_REGISTER(watchdog_list, octeon_wdog_watchdog_fn, sc, 0); octeon_wdog_sysctl(dev); @@ -229,8 +245,8 @@ octeon_wdog_attach(device_t dev) cvmx_write_csr(CVMX_MIO_BOOT_LOC_CFGX(0), 0x81fc0000); - /* XXX: This should be done for every core */ - octeon_wdog_setup(sc, cvmx_get_core_num()); + CPU_FOREACH(core) + octeon_wdog_setup(sc, core); return (0); } Modified: head/sys/mips/include/cpufunc.h ============================================================================== --- head/sys/mips/include/cpufunc.h Tue Jan 4 02:11:03 2011 (r216946) +++ head/sys/mips/include/cpufunc.h Tue Jan 4 02:33:48 2011 (r216947) @@ -108,6 +108,11 @@ mips_write_membar(void) } #ifdef _KERNEL +/* + * XXX + * It would be nice to add variants that read/write register_t, to avoid some + * ABI checks. + */ #if defined(__mips_n32) || defined(__mips_n64) #define MIPS_RDRW64_COP0(n,r) \ static __inline uint64_t \ @@ -132,6 +137,7 @@ mips_wr_ ## n (uint64_t a0) \ } struct __hack #if defined(__mips_n64) +MIPS_RDRW64_COP0(excpc, MIPS_COP_0_EXC_PC); MIPS_RDRW64_COP0(entrylo0, MIPS_COP_0_TLB_LO0); MIPS_RDRW64_COP0(entrylo1, MIPS_COP_0_TLB_LO1); MIPS_RDRW64_COP0(entryhi, MIPS_COP_0_TLB_HI); @@ -208,6 +214,9 @@ MIPS_RDRW32_COP0(count, MIPS_COP_0_COUNT MIPS_RDRW32_COP0(index, MIPS_COP_0_TLB_INDEX); MIPS_RDRW32_COP0(wired, MIPS_COP_0_TLB_WIRED); MIPS_RDRW32_COP0(cause, MIPS_COP_0_CAUSE); +#if !defined(__mips_n64) +MIPS_RDWR32_COP0(excpc, MIPS_COP_0_EXC_PC); +#endif MIPS_RDRW32_COP0(status, MIPS_COP_0_STATUS); /* XXX: Some of these registers are specific to MIPS32. */ From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 02:52:22 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C1FDD1065670; Tue, 4 Jan 2011 02:52:22 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B10A38FC12; Tue, 4 Jan 2011 02:52:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p042qMaH020116; Tue, 4 Jan 2011 02:52:22 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p042qMo3020113; Tue, 4 Jan 2011 02:52:22 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201101040252.p042qMo3020113@svn.freebsd.org> From: Ed Maste Date: Tue, 4 Jan 2011 02:52:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216948 - head/usr.sbin/fwcontrol X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 02:52:22 -0000 Author: emaste Date: Tue Jan 4 02:52:22 2011 New Revision: 216948 URL: http://svn.freebsd.org/changeset/base/216948 Log: Quiet clang warnings by using literal format strings for printf-like functions. Modified: head/usr.sbin/fwcontrol/fwdv.c head/usr.sbin/fwcontrol/fwmpegts.c Modified: head/usr.sbin/fwcontrol/fwdv.c ============================================================================== --- head/usr.sbin/fwcontrol/fwdv.c Tue Jan 4 02:33:48 2011 (r216947) +++ head/usr.sbin/fwcontrol/fwdv.c Tue Jan 4 02:52:22 2011 (r216948) @@ -110,7 +110,7 @@ dvrecv(int d, const char *filename, char } else { fd = open(filename, O_CREAT | O_WRONLY | O_TRUNC, 0660); if (fd == -1) - err(EX_NOINPUT, filename); + err(EX_NOINPUT, "%s", filename); } buf = malloc(RBUFSIZE); pad = malloc(DSIZE*MAXBLOCKS); @@ -270,7 +270,7 @@ dvsend(int d, const char *filename, char fd = open(filename, O_RDONLY); if (fd == -1) - err(EX_NOINPUT, filename); + err(EX_NOINPUT, "%s", filename); pbuf = malloc(DSIZE * TNBUF); bzero(wbuf, sizeof(wbuf)); Modified: head/usr.sbin/fwcontrol/fwmpegts.c ============================================================================== --- head/usr.sbin/fwcontrol/fwmpegts.c Tue Jan 4 02:33:48 2011 (r216947) +++ head/usr.sbin/fwcontrol/fwmpegts.c Tue Jan 4 02:52:22 2011 (r216948) @@ -167,7 +167,7 @@ mpegtsrecv(int d, const char *filename, else { fd = open(filename, O_CREAT | O_WRONLY | O_TRUNC, 0660); if (fd == -1) - err(EX_NOINPUT, filename); + err(EX_NOINPUT, "%s", filename); } buf = malloc(RBUFSIZE); From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 05:35:20 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F12AE106564A; Tue, 4 Jan 2011 05:35:19 +0000 (UTC) (envelope-from davidxu@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E0B018FC12; Tue, 4 Jan 2011 05:35:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p045ZJFe023793; Tue, 4 Jan 2011 05:35:19 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p045ZJEu023791; Tue, 4 Jan 2011 05:35:19 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201101040535.p045ZJEu023791@svn.freebsd.org> From: David Xu Date: Tue, 4 Jan 2011 05:35:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216949 - head/lib/libthr/thread X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 05:35:20 -0000 Author: davidxu Date: Tue Jan 4 05:35:19 2011 New Revision: 216949 URL: http://svn.freebsd.org/changeset/base/216949 Log: Because sleepqueue may still being used, we should always check wchan with queue locked. Modified: head/lib/libthr/thread/thr_cond.c Modified: head/lib/libthr/thread/thr_cond.c ============================================================================== --- head/lib/libthr/thread/thr_cond.c Tue Jan 4 02:52:22 2011 (r216948) +++ head/lib/libthr/thread/thr_cond.c Tue Jan 4 05:35:19 2011 (r216949) @@ -246,11 +246,6 @@ cond_wait_user(struct pthread_cond *cvp, error = _thr_sleep(curthread, cvp->__clock_id, abstime); } - if (curthread->wchan == NULL) { - error = 0; - goto out; - } - _sleepq_lock(cvp); if (curthread->wchan == NULL) { error = 0; @@ -274,7 +269,6 @@ cond_wait_user(struct pthread_cond *cvp, } } _sleepq_unlock(cvp); -out: curthread->mutex_obj = NULL; _mutex_cv_lock(mp, recurse); return (error); From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 10:25:55 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 90BF4106566B; Tue, 4 Jan 2011 10:25:55 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7FE708FC1C; Tue, 4 Jan 2011 10:25:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04APtrj033074; Tue, 4 Jan 2011 10:25:55 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04APtbu033072; Tue, 4 Jan 2011 10:25:55 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101041025.p04APtbu033072@svn.freebsd.org> From: Konstantin Belousov Date: Tue, 4 Jan 2011 10:25:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216951 - head/sys/ufs/ffs X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 10:25:55 -0000 Author: kib Date: Tue Jan 4 10:25:55 2011 New Revision: 216951 URL: http://svn.freebsd.org/changeset/base/216951 Log: Instead of incrementing freework reference counter in indir_trunc(), do it at the allocation time for journaled fs and indirect blocks, when the allocated object is not accessible outside. Requested and reviewed by: jeff Tested by: pho Modified: head/sys/ufs/ffs/ffs_softdep.c Modified: head/sys/ufs/ffs/ffs_softdep.c ============================================================================== --- head/sys/ufs/ffs/ffs_softdep.c Tue Jan 4 05:35:44 2011 (r216950) +++ head/sys/ufs/ffs/ffs_softdep.c Tue Jan 4 10:25:55 2011 (r216951) @@ -876,8 +876,8 @@ static struct jfreeblk *newjfreeblk(stru ufs2_daddr_t, int); static struct jfreefrag *newjfreefrag(struct freefrag *, struct inode *, ufs2_daddr_t, long, ufs_lbn_t); -static struct freework *newfreework(struct freeblks *, struct freework *, - ufs_lbn_t, ufs2_daddr_t, int, int); +static struct freework *newfreework(struct ufsmount *, struct freeblks *, + struct freework *, ufs_lbn_t, ufs2_daddr_t, int, int); static void jwait(struct worklist *wk); static struct inodedep *inodedep_lookup_ip(struct inode *); static int bmsafemap_rollbacks(struct bmsafemap *); @@ -3367,7 +3367,8 @@ free_freedep(freedep) * is visible outside of softdep_setup_freeblocks(). */ static struct freework * -newfreework(freeblks, parent, lbn, nb, frags, journal) +newfreework(ump, freeblks, parent, lbn, nb, frags, journal) + struct ufsmount *ump; struct freeblks *freeblks; struct freework *parent; ufs_lbn_t lbn; @@ -3384,7 +3385,8 @@ newfreework(freeblks, parent, lbn, nb, f freework->fw_lbn = lbn; freework->fw_blkno = nb; freework->fw_frags = frags; - freework->fw_ref = 0; + freework->fw_ref = ((UFSTOVFS(ump)->mnt_kern_flag & MNTK_SUJ) == 0 || + lbn >= -NXADDR) ? 0 : NINDIR(ump->um_fs) + 1; freework->fw_off = 0; LIST_INIT(&freework->fw_jwork); @@ -5199,15 +5201,16 @@ softdep_setup_freeblocks(ip, length, fla continue; frags = sblksize(fs, oldsize, i); frags = numfrags(fs, frags); - newfreework(freeblks, NULL, i, blkno, frags, needj); + newfreework(ip->i_ump, freeblks, NULL, i, blkno, frags, + needj); } for (i = 0, tmpval = NINDIR(fs), lbn = NDADDR; i < NIADDR; i++, tmpval *= NINDIR(fs)) { blkno = DIP(ip, i_ib[i]); DIP_SET(ip, i_ib[i], 0); - if (blkno) - newfreework(freeblks, NULL, -lbn - i, blkno, - fs->fs_frag, needj); + if (blkno) + newfreework(ip->i_ump, freeblks, NULL, -lbn - i, + blkno, fs->fs_frag, needj); lbn += tmpval; } UFS_LOCK(ip->i_ump); @@ -5225,8 +5228,8 @@ softdep_setup_freeblocks(ip, length, fla continue; frags = sblksize(fs, oldextsize, i); frags = numfrags(fs, frags); - newfreework(freeblks, NULL, -1 - i, blkno, frags, - needj); + newfreework(ip->i_ump, freeblks, NULL, -1 - i, blkno, + frags, needj); } } if (LIST_EMPTY(&freeblks->fb_jfreeblkhd)) @@ -6141,9 +6144,6 @@ indir_trunc(freework, dbn, lbn) bap2 = (ufs2_daddr_t *)bp->b_data; } - if (needj) - freework->fw_ref += NINDIR(fs) + 1; - /* * Reclaim indirect blocks which never made it to disk. */ @@ -6178,7 +6178,7 @@ indir_trunc(freework, dbn, lbn) ufs_lbn_t nlbn; nlbn = (lbn + 1) - (i * lbnadd); - nfreework = newfreework(freeblks, freework, + nfreework = newfreework(ump, freeblks, freework, nlbn, nb, fs->fs_frag, 0); WORKLIST_INSERT_UNLOCKED(&nfreework->fw_jwork, wk); freedeps++; @@ -6225,7 +6225,7 @@ indir_trunc(freework, dbn, lbn) nlbn = (lbn + 1) - (i * lbnadd); if (needj != 0) { - nfreework = newfreework(freeblks, freework, + nfreework = newfreework(ump, freeblks, freework, nlbn, nb, fs->fs_frag, 0); freedeps++; } From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 10:59:38 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8AFA11065672; Tue, 4 Jan 2011 10:59:38 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 794A88FC1C; Tue, 4 Jan 2011 10:59:38 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04AxcfZ033833; Tue, 4 Jan 2011 10:59:38 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04AxcpX033823; Tue, 4 Jan 2011 10:59:38 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101041059.p04AxcpX033823@svn.freebsd.org> From: Konstantin Belousov Date: Tue, 4 Jan 2011 10:59:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216952 - in head/sys: dev/pty dev/random geom kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 10:59:38 -0000 Author: kib Date: Tue Jan 4 10:59:38 2011 New Revision: 216952 URL: http://svn.freebsd.org/changeset/base/216952 Log: Finish r210923, 210926. Mark some devices as eternal. MFC after: 2 weeks Modified: head/sys/dev/pty/pty.c head/sys/dev/random/randomdev.c head/sys/geom/geom_ctl.c head/sys/kern/kern_descrip.c head/sys/kern/subr_bus.c head/sys/kern/subr_devstat.c head/sys/kern/subr_log.c head/sys/kern/tty.c head/sys/kern/tty_tty.c Modified: head/sys/dev/pty/pty.c ============================================================================== --- head/sys/dev/pty/pty.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/dev/pty/pty.c Tue Jan 4 10:59:38 2011 (r216952) @@ -142,7 +142,8 @@ pty_modevent(module_t mod, int type, voi switch(type) { case MOD_LOAD: EVENTHANDLER_REGISTER(dev_clone, pty_clone, 0, 1000); - make_dev(&ptmx_cdevsw, 0, UID_ROOT, GID_WHEEL, 0666, "ptmx"); + make_dev_credf(MAKEDEV_ETERNAL_KLD, &ptmx_cdevsw, 0, NULL, + UID_ROOT, GID_WHEEL, 0666, "ptmx"); break; case MOD_SHUTDOWN: break; Modified: head/sys/dev/random/randomdev.c ============================================================================== --- head/sys/dev/random/randomdev.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/dev/random/randomdev.c Tue Jan 4 10:59:38 2011 (r216952) @@ -195,8 +195,8 @@ random_modevent(module_t mod __unused, i printf("random: \n", random_systat.ident); - random_dev = make_dev(&random_cdevsw, RANDOM_MINOR, - UID_ROOT, GID_WHEEL, 0666, "random"); + random_dev = make_dev_credf(MAKEDEV_ETERNAL_KLD, &random_cdevsw, + RANDOM_MINOR, NULL, UID_ROOT, GID_WHEEL, 0666, "random"); make_dev_alias(random_dev, "urandom"); /* XXX Deprecated */ break; Modified: head/sys/geom/geom_ctl.c ============================================================================== --- head/sys/geom/geom_ctl.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/geom/geom_ctl.c Tue Jan 4 10:59:38 2011 (r216952) @@ -75,7 +75,7 @@ void g_ctl_init(void) { - make_dev(&g_ctl_cdevsw, 0, + make_dev_credf(MAKEDEV_ETERNAL, &g_ctl_cdevsw, 0, NULL, UID_ROOT, GID_OPERATOR, 0640, PATH_GEOM_CTL); KASSERT(GCTL_PARAM_RD == VM_PROT_READ, ("GCTL_PARAM_RD != VM_PROT_READ")); Modified: head/sys/kern/kern_descrip.c ============================================================================== --- head/sys/kern/kern_descrip.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/kern/kern_descrip.c Tue Jan 4 10:59:38 2011 (r216952) @@ -3430,11 +3430,14 @@ fildesc_drvinit(void *unused) { struct cdev *dev; - dev = make_dev(&fildesc_cdevsw, 0, UID_ROOT, GID_WHEEL, 0666, "fd/0"); + dev = make_dev_credf(MAKEDEV_ETERNAL, &fildesc_cdevsw, 0, NULL, + UID_ROOT, GID_WHEEL, 0666, "fd/0"); make_dev_alias(dev, "stdin"); - dev = make_dev(&fildesc_cdevsw, 1, UID_ROOT, GID_WHEEL, 0666, "fd/1"); + dev = make_dev_credf(MAKEDEV_ETERNAL, &fildesc_cdevsw, 1, NULL, + UID_ROOT, GID_WHEEL, 0666, "fd/1"); make_dev_alias(dev, "stdout"); - dev = make_dev(&fildesc_cdevsw, 2, UID_ROOT, GID_WHEEL, 0666, "fd/2"); + dev = make_dev_credf(MAKEDEV_ETERNAL, &fildesc_cdevsw, 2, NULL, + UID_ROOT, GID_WHEEL, 0666, "fd/2"); make_dev_alias(dev, "stderr"); } Modified: head/sys/kern/subr_bus.c ============================================================================== --- head/sys/kern/subr_bus.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/kern/subr_bus.c Tue Jan 4 10:59:38 2011 (r216952) @@ -405,8 +405,8 @@ static struct cdev *devctl_dev; static void devinit(void) { - devctl_dev = make_dev(&dev_cdevsw, 0, UID_ROOT, GID_WHEEL, 0600, - "devctl"); + devctl_dev = make_dev_credf(MAKEDEV_ETERNAL, &dev_cdevsw, 0, NULL, + UID_ROOT, GID_WHEEL, 0600, "devctl"); mtx_init(&devsoftc.mtx, "dev mtx", "devd", MTX_DEF); cv_init(&devsoftc.cv, "dev cv"); TAILQ_INIT(&devsoftc.devq); Modified: head/sys/kern/subr_devstat.c ============================================================================== --- head/sys/kern/subr_devstat.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/kern/subr_devstat.c Tue Jan 4 10:59:38 2011 (r216952) @@ -476,7 +476,7 @@ devstat_alloc(void) mtx_assert(&devstat_mutex, MA_NOTOWNED); if (!once) { - make_dev(&devstat_cdevsw, 0, + make_dev_credf(MAKEDEV_ETERNAL, &devstat_cdevsw, 0, NULL, UID_ROOT, GID_WHEEL, 0400, DEVSTAT_DEVICE_NAME); once = 1; } Modified: head/sys/kern/subr_log.c ============================================================================== --- head/sys/kern/subr_log.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/kern/subr_log.c Tue Jan 4 10:59:38 2011 (r216952) @@ -256,7 +256,8 @@ log_drvinit(void *unused) cv_init(&log_wakeup, "klog"); callout_init_mtx(&logsoftc.sc_callout, &msgbuf_lock, 0); - make_dev(&log_cdevsw, 0, UID_ROOT, GID_WHEEL, 0600, "klog"); + make_dev_credf(MAKEDEV_ETERNAL, &log_cdevsw, 0, NULL, UID_ROOT, + GID_WHEEL, 0600, "klog"); } SYSINIT(logdev,SI_SUB_DRIVERS,SI_ORDER_MIDDLE,log_drvinit,NULL); Modified: head/sys/kern/tty.c ============================================================================== --- head/sys/kern/tty.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/kern/tty.c Tue Jan 4 10:59:38 2011 (r216952) @@ -1946,8 +1946,8 @@ static void ttyconsdev_init(void *unused) { - dev_console = make_dev(&ttyconsdev_cdevsw, 0, UID_ROOT, GID_WHEEL, - 0600, "console"); + dev_console = make_dev_credf(MAKEDEV_ETERNAL, &ttyconsdev_cdevsw, 0, + NULL, UID_ROOT, GID_WHEEL, 0600, "console"); } SYSINIT(tty, SI_SUB_DRIVERS, SI_ORDER_FIRST, ttyconsdev_init, NULL); Modified: head/sys/kern/tty_tty.c ============================================================================== --- head/sys/kern/tty_tty.c Tue Jan 4 10:25:55 2011 (r216951) +++ head/sys/kern/tty_tty.c Tue Jan 4 10:59:38 2011 (r216952) @@ -87,7 +87,8 @@ ctty_drvinit(void *unused) { EVENTHANDLER_REGISTER(dev_clone, ctty_clone, 0, 1000); - ctty = make_dev(&ctty_cdevsw, 0, 0, 0, 0666, "ctty"); + ctty = make_dev_credf(MAKEDEV_ETERNAL, &ctty_cdevsw, 0, NULL, UID_ROOT, + GID_WHEEL, 0666, "ctty"); } SYSINIT(cttydev,SI_SUB_DRIVERS,SI_ORDER_MIDDLE,ctty_drvinit,NULL); From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 13:02:53 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 081B7106566B; Tue, 4 Jan 2011 13:02:53 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id EB9318FC14; Tue, 4 Jan 2011 13:02:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04D2qeu036720; Tue, 4 Jan 2011 13:02:52 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04D2qkE036718; Tue, 4 Jan 2011 13:02:52 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201101041302.p04D2qkE036718@svn.freebsd.org> From: Ed Maste Date: Tue, 4 Jan 2011 13:02:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216953 - head/lib/libugidfw X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 13:02:53 -0000 Author: emaste Date: Tue Jan 4 13:02:52 2011 New Revision: 216953 URL: http://svn.freebsd.org/changeset/base/216953 Log: Quiet clang warnings by using string literal format strings. Modified: head/lib/libugidfw/ugidfw.c Modified: head/lib/libugidfw/ugidfw.c ============================================================================== --- head/lib/libugidfw/ugidfw.c Tue Jan 4 10:59:38 2011 (r216952) +++ head/lib/libugidfw/ugidfw.c Tue Jan 4 13:02:52 2011 (r216953) @@ -1134,7 +1134,7 @@ bsde_get_rule_count(size_t buflen, char len = sizeof(rule_count); error = sysctlbyname(MIB ".rule_count", &rule_count, &len, NULL, 0); if (error) { - len = snprintf(errstr, buflen, strerror(errno)); + len = snprintf(errstr, buflen, "%s", strerror(errno)); return (-1); } if (len != sizeof(rule_count)) { @@ -1156,7 +1156,7 @@ bsde_get_rule_slots(size_t buflen, char len = sizeof(rule_slots); error = sysctlbyname(MIB ".rule_slots", &rule_slots, &len, NULL, 0); if (error) { - len = snprintf(errstr, buflen, strerror(errno)); + len = snprintf(errstr, buflen, "%s", strerror(errno)); return (-1); } if (len != sizeof(rule_slots)) { From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 13:16:28 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E0628106564A; Tue, 4 Jan 2011 13:16:28 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D01308FC0C; Tue, 4 Jan 2011 13:16:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04DGSWV037044; Tue, 4 Jan 2011 13:16:28 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04DGSo6037042; Tue, 4 Jan 2011 13:16:28 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101041316.p04DGSo6037042@svn.freebsd.org> From: John Baldwin Date: Tue, 4 Jan 2011 13:16:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 13:16:29 -0000 Author: jhb Date: Tue Jan 4 13:16:28 2011 New Revision: 216954 URL: http://svn.freebsd.org/changeset/base/216954 Log: kproc_exit() is already marked __dead2 so a NOTREACHED comment here isn't needed for lint. Submitted by: bde Modified: head/sys/kern/kern_kthread.c Modified: head/sys/kern/kern_kthread.c ============================================================================== --- head/sys/kern/kern_kthread.c Tue Jan 4 13:02:52 2011 (r216953) +++ head/sys/kern/kern_kthread.c Tue Jan 4 13:16:28 2011 (r216954) @@ -329,7 +329,6 @@ kthread_exit(void) PROC_UNLOCK(p); rw_wunlock(&tidhash_lock); kproc_exit(0); - /* NOTREACHED */ } LIST_REMOVE(curthread, td_hash); rw_wunlock(&tidhash_lock); From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 13:27:28 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7A372106566B; Tue, 4 Jan 2011 13:27:28 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 49FC88FC0C; Tue, 4 Jan 2011 13:27:28 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id D141F46B03; Tue, 4 Jan 2011 08:27:27 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id C41D98A009; Tue, 4 Jan 2011 08:27:26 -0500 (EST) From: John Baldwin To: Colin Percival Date: Tue, 4 Jan 2011 08:00:44 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101040016.p040GcNf010998@svn.freebsd.org> In-Reply-To: <201101040016.p040GcNf010998@svn.freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101040800.45155.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Tue, 04 Jan 2011 08:27:26 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216944 - head/sys/i386/xen X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 13:27:28 -0000 On Monday, January 03, 2011 7:16:38 pm Colin Percival wrote: > Author: cperciva > Date: Tue Jan 4 00:16:38 2011 > New Revision: 216944 > URL: http://svn.freebsd.org/changeset/base/216944 > > Log: > Adjust the critical section protecting _xen_flush_queue to cover the > entire range where the page mapping request queue needs to be atomically > examined and modified. > > Oddly, while this doesn't seem to affect the overall rate of panics > (running 'make index' on EC2 t1.micro instances, there are 0.6 +/- 0.1 > panics per hour, both before and after this change), it eliminates > vm_fault from panic backtraces, leaving only backtraces going through > vmspace_fork. > > Modified: > head/sys/i386/xen/xen_machdep.c > > Modified: head/sys/i386/xen/xen_machdep.c > ============================================================================== > --- head/sys/i386/xen/xen_machdep.c Tue Jan 4 00:11:09 2011 (r216943) > +++ head/sys/i386/xen/xen_machdep.c Tue Jan 4 00:16:38 2011 (r216944) > @@ -42,6 +42,7 @@ __FBSDID("$FreeBSD$"); > #include > #include > #include > +#include > #include > #include > > @@ -249,10 +250,13 @@ _xen_flush_queue(void) > SET_VCPU(); > int _xpq_idx = XPQ_IDX; > int error, i; > - /* window of vulnerability here? */ > > +#ifdef INVARIANTS > if (__predict_true(gdtset)) > - critical_enter(); > + KASSERT(curthread->td_critnest > 0, > + ("xen queue flush should be in a critical section")); > +#endif > + You can use CRITICAL_ASSERT(curthread) instead perhaps. > XPQ_IDX = 0; > /* Make sure index is cleared first to avoid double updates. */ > error = HYPERVISOR_mmu_update((mmu_update_t *)&XPQ_QUEUE, > @@ -286,8 +290,6 @@ _xen_flush_queue(void) > } > } > #endif > - if (__predict_true(gdtset)) > - critical_exit(); > if (__predict_false(error < 0)) { > for (i = 0; i < _xpq_idx; i++) > printf("val: %llx ptr: %llx\n", > @@ -301,7 +303,12 @@ void > xen_flush_queue(void) > { > SET_VCPU(); > + > + if (__predict_true(gdtset)) > + critical_enter(); > if (XPQ_IDX != 0) _xen_flush_queue(); > + if (__predict_true(gdtset)) > + critical_exit(); > } > > static __inline void > -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 14:13:10 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 52807106566C; Tue, 4 Jan 2011 14:13:10 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 278838FC08; Tue, 4 Jan 2011 14:13:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04EDAHf038362; Tue, 4 Jan 2011 14:13:10 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04EDA4f038360; Tue, 4 Jan 2011 14:13:10 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101041413.p04EDA4f038360@svn.freebsd.org> From: Konstantin Belousov Date: Tue, 4 Jan 2011 14:13:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 14:13:10 -0000 Author: kib Date: Tue Jan 4 14:13:09 2011 New Revision: 216955 URL: http://svn.freebsd.org/changeset/base/216955 Log: Make the parsing of the integer arguments for rtprio(1)/idprio(1) stricter. Style. Based on submission by: Eitan Adler , keramida Reviewed by: jhb, keramida MFC after: 1 week Modified: head/usr.sbin/rtprio/rtprio.c Modified: head/usr.sbin/rtprio/rtprio.c ============================================================================== --- head/usr.sbin/rtprio/rtprio.c Tue Jan 4 13:16:28 2011 (r216954) +++ head/usr.sbin/rtprio/rtprio.c Tue Jan 4 14:13:09 2011 (r216955) @@ -37,31 +37,31 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include +#include #include #include #include #include -static void usage(); +static int parseint(const char *, const char *); +static void usage(void); int -main(argc, argv) - int argc; - char **argv; +main(int argc, char *argv[]) { - char *p; - int proc = 0; struct rtprio rtp; + char *p; + pid_t proc; /* find basename */ if ((p = rindex(argv[0], '/')) == NULL) p = argv[0]; else ++p; + proc = 0; if (!strcmp(p, "rtprio")) rtp.type = RTP_PRIO_REALTIME; @@ -70,12 +70,12 @@ main(argc, argv) switch (argc) { case 2: - proc = abs(atoi(argv[1])); /* Should check if numeric - * arg! */ + proc = parseint(argv[1], "pid"); + proc = abs(proc); /* FALLTHROUGH */ case 1: if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) - err(1, "%s", argv[0]); + err(1, "RTP_LOOKUP"); printf("%s: ", p); switch (rtp.type) { case RTP_PRIO_REALTIME: @@ -103,19 +103,17 @@ main(argc, argv) usage(); break; } - } else { - rtp.prio = atoi(argv[1]); - } + } else + rtp.prio = parseint(argv[1], "priority"); } else { usage(); break; } if (argv[2][0] == '-') - proc = -atoi(argv[2]); - + proc = parseint(argv[2] + 1, "pid"); if (rtprio(RTP_SET, proc, &rtp) != 0) - err(1, "%s", argv[0]); + err(1, "RTP_SET"); if (proc == 0) { execvp(argv[2], &argv[2]); @@ -123,12 +121,28 @@ main(argc, argv) } exit(0); } - exit (1); + exit(1); +} + +static int +parseint(const char *str, const char *errname) +{ + char *endp; + long res; + + errno = 0; + res = strtol(str, &endp, 10); + if (errno != 0 || endp == str || *endp != '\0') + err(1, "%s must be a number", errname); + if (res >= INT_MAX) + err(1, "Integer overflow parsing %s", errname); + return (res); } static void -usage() +usage(void) { + (void) fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n%s\n", "usage: [id|rt]prio", " [id|rt]prio [-]pid", From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 14:49:54 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EC58D106564A; Tue, 4 Jan 2011 14:49:54 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D957B8FC13; Tue, 4 Jan 2011 14:49:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04Ensrx039324; Tue, 4 Jan 2011 14:49:54 GMT (envelope-from rwatson@svn.freebsd.org) Received: (from rwatson@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04EnsLS039312; Tue, 4 Jan 2011 14:49:54 GMT (envelope-from rwatson@svn.freebsd.org) Message-Id: <201101041449.p04EnsLS039312@svn.freebsd.org> From: Robert Watson Date: Tue, 4 Jan 2011 14:49:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216956 - in head/sys: conf dev/xen/balloon dev/xen/blkfront dev/xen/netfront dev/xen/xenpci i386/include i386/include/xen X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 14:49:55 -0000 Author: rwatson Date: Tue Jan 4 14:49:54 2011 New Revision: 216956 URL: http://svn.freebsd.org/changeset/base/216956 Log: Make "options XENHVM" compile for i386, not just amd64 -- a largely mechanical change. This opens the door for using PV device drivers under Xen HVM on i386, as well as more general harmonisation of i386 and amd64 Xen support in FreeBSD. Reviewed by: cperciva MFC after: 3 weeks Modified: head/sys/conf/options.i386 head/sys/dev/xen/balloon/balloon.c head/sys/dev/xen/blkfront/blkfront.c head/sys/dev/xen/netfront/netfront.c head/sys/dev/xen/xenpci/evtchn.c head/sys/i386/include/pcpu.h head/sys/i386/include/pmap.h head/sys/i386/include/xen/hypercall.h head/sys/i386/include/xen/xen-os.h head/sys/i386/include/xen/xenpmap.h head/sys/i386/include/xen/xenvar.h Modified: head/sys/conf/options.i386 ============================================================================== --- head/sys/conf/options.i386 Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/conf/options.i386 Tue Jan 4 14:49:54 2011 (r216956) @@ -118,3 +118,4 @@ BPF_JITTER opt_bpf.h NATIVE opt_global.h XEN opt_global.h +XENHVM opt_global.h Modified: head/sys/dev/xen/balloon/balloon.c ============================================================================== --- head/sys/dev/xen/balloon/balloon.c Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/dev/xen/balloon/balloon.c Tue Jan 4 14:49:54 2011 (r216956) @@ -41,8 +41,8 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include +#include #include #include Modified: head/sys/dev/xen/blkfront/blkfront.c ============================================================================== --- head/sys/dev/xen/blkfront/blkfront.c Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/dev/xen/blkfront/blkfront.c Tue Jan 4 14:49:54 2011 (r216956) @@ -51,6 +51,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include Modified: head/sys/dev/xen/netfront/netfront.c ============================================================================== --- head/sys/dev/xen/netfront/netfront.c Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/dev/xen/netfront/netfront.c Tue Jan 4 14:49:54 2011 (r216956) @@ -77,6 +77,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: head/sys/dev/xen/xenpci/evtchn.c ============================================================================== --- head/sys/dev/xen/xenpci/evtchn.c Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/dev/xen/xenpci/evtchn.c Tue Jan 4 14:49:54 2011 (r216956) @@ -51,13 +51,19 @@ __FBSDID("$FreeBSD$"); #include +#if defined(__i386__) +#define __ffs(word) ffs(word) +#elif defined(__amd64__) static inline unsigned long __ffs(unsigned long word) { __asm__("bsfq %1,%0" :"=r" (word) - :"rm" (word)); + :"rm" (word)); /* XXXRW: why no "cc"? */ return word; } +#else +#error "evtchn: unsupported architecture" +#endif #define is_valid_evtchn(x) ((x) != 0) #define evtchn_from_irq(x) (irq_evtchn[irq].evtchn) Modified: head/sys/i386/include/pcpu.h ============================================================================== --- head/sys/i386/include/pcpu.h Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/i386/include/pcpu.h Tue Jan 4 14:49:54 2011 (r216956) @@ -44,13 +44,16 @@ * other processors" */ -#ifdef XEN +#if defined(XEN) || defined(XENHVM) #ifndef NR_VIRQS #define NR_VIRQS 24 #endif #ifndef NR_IPIS #define NR_IPIS 2 #endif +#endif + +#if defined(XEN) /* These are peridically updated in shared_info, and then copied here. */ struct shadow_time_info { @@ -72,8 +75,18 @@ struct shadow_time_info { int pc_callfunc_irq; \ int pc_virq_to_irq[NR_VIRQS]; \ int pc_ipi_to_irq[NR_IPIS] -#else + +#elif defined(XENHVM) + +#define PCPU_XEN_FIELDS \ + ; \ + unsigned int pc_last_processed_l1i; \ + unsigned int pc_last_processed_l2i + +#else /* !XEN && !XENHVM */ + #define PCPU_XEN_FIELDS + #endif #define PCPU_MD_FIELDS \ Modified: head/sys/i386/include/pmap.h ============================================================================== --- head/sys/i386/include/pmap.h Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/i386/include/pmap.h Tue Jan 4 14:49:54 2011 (r216956) @@ -208,7 +208,7 @@ extern pd_entry_t *IdlePTD; /* physical */ #define vtophys(va) pmap_kextract((vm_offset_t)(va)) -#ifdef XEN +#if defined(XEN) #include #include #include @@ -315,7 +315,9 @@ pmap_kextract(vm_offset_t va) } return (pa); } +#endif +#if !defined(XEN) #define PT_UPDATES_FLUSH() #endif Modified: head/sys/i386/include/xen/hypercall.h ============================================================================== --- head/sys/i386/include/xen/hypercall.h Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/i386/include/xen/hypercall.h Tue Jan 4 14:49:54 2011 (r216956) @@ -234,9 +234,14 @@ HYPERVISOR_memory_op( return _hypercall2(int, memory_op, cmd, arg); } +#if defined(XEN) int HYPERVISOR_multicall(multicall_entry_t *, int); static inline int _HYPERVISOR_multicall( +#else /* XENHVM */ +static inline int +HYPERVISOR_multicall( +#endif void *call_list, int nr_calls) { return _hypercall2(int, multicall, call_list, nr_calls); Modified: head/sys/i386/include/xen/xen-os.h ============================================================================== --- head/sys/i386/include/xen/xen-os.h Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/i386/include/xen/xen-os.h Tue Jan 4 14:49:54 2011 (r216956) @@ -12,7 +12,7 @@ #define CONFIG_X86_PAE #endif -#if defined(XEN) && !defined(__XEN_INTERFACE_VERSION__) +#if !defined(__XEN_INTERFACE_VERSION__) /* * Can update to a more recent version when we implement * the hypercall page @@ -95,6 +95,8 @@ void printk(const char *fmt, ...); /* some function prototypes */ void trap_init(void); +#ifndef XENHVM + /* * STI/CLI equivalents. These basically set and clear the virtual * event_enable flag in teh shared_info structure. Note that when @@ -164,6 +166,7 @@ do { #define spin_lock_irqsave mtx_lock_irqsave #define spin_unlock_irqrestore mtx_unlock_irqrestore +#endif #ifdef SMP #define smp_mb() mb() Modified: head/sys/i386/include/xen/xenpmap.h ============================================================================== --- head/sys/i386/include/xen/xenpmap.h Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/i386/include/xen/xenpmap.h Tue Jan 4 14:49:54 2011 (r216956) @@ -35,6 +35,8 @@ #ifndef _XEN_XENPMAP_H_ #define _XEN_XENPMAP_H_ + +#if defined(XEN) void _xen_queue_pt_update(vm_paddr_t, vm_paddr_t, char *, int); void xen_pt_switch(vm_paddr_t); void xen_set_ldt(vm_paddr_t, unsigned long); @@ -230,5 +232,15 @@ phys_to_machine_mapping_valid(unsigned l return xen_phys_machine[pfn] != INVALID_P2M_ENTRY; } +#elif defined(XENHVM) + +#define set_phys_to_machine(pfn, mfn) ((void)0) +#define phys_to_machine_mapping_valid(pfn) (TRUE) + +#if !defined(PAE) +#define vtomach(va) pmap_kextract((vm_offset_t) (va)) +#endif + +#endif /* !XEN && !XENHVM */ #endif /* _XEN_XENPMAP_H_ */ Modified: head/sys/i386/include/xen/xenvar.h ============================================================================== --- head/sys/i386/include/xen/xenvar.h Tue Jan 4 14:13:09 2011 (r216955) +++ head/sys/i386/include/xen/xenvar.h Tue Jan 4 14:49:54 2011 (r216956) @@ -28,6 +28,11 @@ #ifndef XENVAR_H_ #define XENVAR_H_ + +#include + +#if defined(XEN) + #define XBOOTUP 0x1 #define XPMAP 0x2 extern int xendebug_flags; @@ -36,7 +41,6 @@ extern int xendebug_flags; #else #define XENPRINTF printf #endif -#include extern xen_pfn_t *xen_phys_machine; extern xen_pfn_t *xen_pfn_to_mfn_frame_list[16]; @@ -101,4 +105,11 @@ int xen_create_contiguous_region(vm_pag void xen_destroy_contiguous_region(void * addr, int npages); +#elif defined(XENHVM) + +#define PFNTOMFN(pa) (pa) +#define MFNTOPFN(ma) (ma) + +#endif /* !XEN && !XENHVM */ + #endif From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 15:55:16 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0E01F106566C; Tue, 4 Jan 2011 15:55:16 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E7A528FC24; Tue, 4 Jan 2011 15:55:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04FtFLS041038; Tue, 4 Jan 2011 15:55:15 GMT (envelope-from cperciva@svn.freebsd.org) Received: (from cperciva@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04FtFo1041036; Tue, 4 Jan 2011 15:55:15 GMT (envelope-from cperciva@svn.freebsd.org) Message-Id: <201101041555.p04FtFo1041036@svn.freebsd.org> From: Colin Percival Date: Tue, 4 Jan 2011 15:55:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216960 - head/sys/i386/xen X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 15:55:16 -0000 Author: cperciva Date: Tue Jan 4 15:55:15 2011 New Revision: 216960 URL: http://svn.freebsd.org/changeset/base/216960 Log: Add hamfisted locking to the Xen/PV pmap code: Only allow one thread to be in {pmap_pinit, pmap_copy, pmap_release} at a time. This reduces the rate of panics when running 'make index' from ~0.6/hour to ~0.02/hour (p < 10^-30). At a later date this locking will be removed, and for this reason, it is wrapped in #ifdef HAMFISTED_LOCKING; this temporary hack is being put in place with the intention of shipping somewhat-stable Xen bits in FreeBSD 8.2-RELEASE. PR: kern/153672 MFC after: 3 days Modified: head/sys/i386/xen/pmap.c Modified: head/sys/i386/xen/pmap.c ============================================================================== --- head/sys/i386/xen/pmap.c Tue Jan 4 15:53:38 2011 (r216959) +++ head/sys/i386/xen/pmap.c Tue Jan 4 15:55:15 2011 (r216960) @@ -202,6 +202,11 @@ __FBSDID("$FreeBSD$"); #define pmap_pte_set_prot(pte, v) ((*(int *)pte &= ~PG_PROT), (*(int *)pte |= (v))) +#define HAMFISTED_LOCKING +#ifdef HAMFISTED_LOCKING +static struct mtx createdelete_lock; +#endif + struct pmap kernel_pmap_store; LIST_HEAD(pmaplist, pmap); static struct pmaplist allpmaps; @@ -502,6 +507,10 @@ pmap_bootstrap(vm_paddr_t firstaddr) /* Turn on PG_G on kernel page(s) */ pmap_set_pg(); #endif + +#ifdef HAMFISTED_LOCKING + mtx_init(&createdelete_lock, "pmap create/delete", NULL, MTX_DEF); +#endif } /* @@ -1462,6 +1471,10 @@ pmap_pinit(pmap_t pmap) static int color; int i; +#ifdef HAMFISTED_LOCKING + mtx_lock(&createdelete_lock); +#endif + PMAP_LOCK_INIT(pmap); /* @@ -1473,6 +1486,9 @@ pmap_pinit(pmap_t pmap) NBPTD); if (pmap->pm_pdir == NULL) { PMAP_LOCK_DESTROY(pmap); +#ifdef HAMFISTED_LOCKING + mtx_unlock(&createdelete_lock); +#endif return (0); } #ifdef PAE @@ -1545,6 +1561,9 @@ pmap_pinit(pmap_t pmap) TAILQ_INIT(&pmap->pm_pvchunk); bzero(&pmap->pm_stats, sizeof pmap->pm_stats); +#ifdef HAMFISTED_LOCKING + mtx_unlock(&createdelete_lock); +#endif return (1); } @@ -1776,6 +1795,10 @@ pmap_release(pmap_t pmap) pmap->pm_stats.resident_count)); PT_UPDATES_FLUSH(); +#ifdef HAMFISTED_LOCKING + mtx_lock(&createdelete_lock); +#endif + pmap_lazyfix(pmap); mtx_lock_spin(&allpmaps_lock); LIST_REMOVE(pmap, pm_list); @@ -1811,6 +1834,10 @@ pmap_release(pmap_t pmap) pmap_qremove((vm_offset_t)pmap->pm_pdpt, 1); #endif PMAP_LOCK_DESTROY(pmap); + +#ifdef HAMFISTED_LOCKING + mtx_unlock(&createdelete_lock); +#endif } static int @@ -3136,6 +3163,10 @@ pmap_copy(pmap_t dst_pmap, pmap_t src_pm CTR5(KTR_PMAP, "pmap_copy: dst_pmap=%p src_pmap=%p dst_addr=0x%x len=%d src_addr=0x%x", dst_pmap, src_pmap, dst_addr, len, src_addr); +#ifdef HAMFISTED_LOCKING + mtx_lock(&createdelete_lock); +#endif + vm_page_lock_queues(); if (dst_pmap < src_pmap) { PMAP_LOCK(dst_pmap); @@ -3225,6 +3256,10 @@ pmap_copy(pmap_t dst_pmap, pmap_t src_pm vm_page_unlock_queues(); PMAP_UNLOCK(src_pmap); PMAP_UNLOCK(dst_pmap); + +#ifdef HAMFISTED_LOCKING + mtx_unlock(&createdelete_lock); +#endif } static __inline void From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 15:59:55 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx2.freebsd.org (mx2.freebsd.org [IPv6:2001:4f8:fff6::35]) by hub.freebsd.org (Postfix) with ESMTP id B629C1065670 for ; Tue, 4 Jan 2011 15:59:55 +0000 (UTC) (envelope-from cperciva@freebsd.org) Received: from xps.daemonology.net (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx2.freebsd.org (Postfix) with SMTP id 3E16D14E6EC for ; Tue, 4 Jan 2011 15:59:55 +0000 (UTC) Received: (qmail 46819 invoked from network); 4 Jan 2011 15:59:55 -0000 Received: from unknown (HELO xps.daemonology.net) (127.0.0.1) by localhost with SMTP; 4 Jan 2011 15:59:55 -0000 Message-ID: <4D2343FB.4030402@freebsd.org> Date: Tue, 04 Jan 2011 07:59:55 -0800 From: Colin Percival User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.1.16) Gecko/20101220 Thunderbird/3.0.11 MIME-Version: 1.0 To: John Baldwin References: <201101040016.p040GcNf010998@svn.freebsd.org> <201101040800.45155.jhb@freebsd.org> In-Reply-To: <201101040800.45155.jhb@freebsd.org> X-Enigmail-Version: 1.0.1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216944 - head/sys/i386/xen X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 15:59:55 -0000 On 01/04/11 05:00, John Baldwin wrote: > On Monday, January 03, 2011 7:16:38 pm Colin Percival wrote: >> +#ifdef INVARIANTS >> if (__predict_true(gdtset)) >> - critical_enter(); >> + KASSERT(curthread->td_critnest > 0, >> + ("xen queue flush should be in a critical section")); >> +#endif >> + > > You can use CRITICAL_ASSERT(curthread) instead perhaps. Duh. I was looking for that but somehow didn't feed the right keywords to grep. Thanks! -- Colin Percival Security Officer, FreeBSD | freebsd.org | The power to serve Founder / author, Tarsnap | tarsnap.com | Online backups for the truly paranoid From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 16:08:49 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 51C981065670; Tue, 4 Jan 2011 16:08:49 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 2AAC28FC18; Tue, 4 Jan 2011 16:08:49 +0000 (UTC) Received: from fledge.watson.org (fledge.watson.org [65.122.17.41]) by cyrus.watson.org (Postfix) with ESMTPS id CB1E046B58; Tue, 4 Jan 2011 11:08:48 -0500 (EST) Date: Tue, 4 Jan 2011 16:08:48 +0000 (GMT) From: Robert Watson X-X-Sender: robert@fledge.watson.org To: Ed Maste In-Reply-To: <201101041302.p04D2qkE036718@svn.freebsd.org> Message-ID: References: <201101041302.p04D2qkE036718@svn.freebsd.org> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216953 - head/lib/libugidfw X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 16:08:49 -0000 On Tue, 4 Jan 2011, Ed Maste wrote: > Author: emaste > Date: Tue Jan 4 13:02:52 2011 > New Revision: 216953 > URL: http://svn.freebsd.org/changeset/base/216953 > > Log: > Quiet clang warnings by using string literal format strings. Thanks! Robert > > Modified: > head/lib/libugidfw/ugidfw.c > > Modified: head/lib/libugidfw/ugidfw.c > ============================================================================== > --- head/lib/libugidfw/ugidfw.c Tue Jan 4 10:59:38 2011 (r216952) > +++ head/lib/libugidfw/ugidfw.c Tue Jan 4 13:02:52 2011 (r216953) > @@ -1134,7 +1134,7 @@ bsde_get_rule_count(size_t buflen, char > len = sizeof(rule_count); > error = sysctlbyname(MIB ".rule_count", &rule_count, &len, NULL, 0); > if (error) { > - len = snprintf(errstr, buflen, strerror(errno)); > + len = snprintf(errstr, buflen, "%s", strerror(errno)); > return (-1); > } > if (len != sizeof(rule_count)) { > @@ -1156,7 +1156,7 @@ bsde_get_rule_slots(size_t buflen, char > len = sizeof(rule_slots); > error = sysctlbyname(MIB ".rule_slots", &rule_slots, &len, NULL, 0); > if (error) { > - len = snprintf(errstr, buflen, strerror(errno)); > + len = snprintf(errstr, buflen, "%s", strerror(errno)); > return (-1); > } > if (len != sizeof(rule_slots)) { > From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 16:11:33 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 15F50106567A; Tue, 4 Jan 2011 16:11:33 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 042C18FC24; Tue, 4 Jan 2011 16:11:33 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04GBWGa042480; Tue, 4 Jan 2011 16:11:32 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04GBW7F042472; Tue, 4 Jan 2011 16:11:32 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101041611.p04GBW7F042472@svn.freebsd.org> From: Marius Strobl Date: Tue, 4 Jan 2011 16:11:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216961 - in head/sys: sparc64/include sparc64/pci sparc64/sbus sparc64/sparc64 sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 16:11:33 -0000 Author: marius Date: Tue Jan 4 16:11:32 2011 New Revision: 216961 URL: http://svn.freebsd.org/changeset/base/216961 Log: Reserve INTR_MD[1-4] similarly to what BUS_DMA_BUS[1-4] are intended for and switch sparc64 to use the first one for bus error filter handlers of bridge drivers instead of (ab)using INTR_FAST for that so we eventually can get rid of the latter. Reviewed by: jhb MFC after: 1 month Modified: head/sys/sparc64/include/intr_machdep.h head/sys/sparc64/pci/fire.c head/sys/sparc64/pci/psycho.c head/sys/sparc64/pci/schizo.c head/sys/sparc64/sbus/sbus.c head/sys/sparc64/sparc64/intr_machdep.c head/sys/sys/bus.h Modified: head/sys/sparc64/include/intr_machdep.h ============================================================================== --- head/sys/sparc64/include/intr_machdep.h Tue Jan 4 15:55:15 2011 (r216960) +++ head/sys/sparc64/include/intr_machdep.h Tue Jan 4 16:11:32 2011 (r216961) @@ -48,11 +48,13 @@ #define PIL_PREEMPT 6 /* preempt idle thread cpu ipi */ #define PIL_HARDCLOCK 7 /* hardclock broadcast */ #define PIL_FILTER 12 /* filter interrupts */ -#define PIL_FAST 13 /* fast interrupts */ +#define PIL_BRIDGE 13 /* bridge interrupts */ #define PIL_TICK 14 /* tick interrupts */ #ifndef LOCORE +#define INTR_BRIDGE INTR_MD1 + struct trapframe; typedef void ih_func_t(struct trapframe *); Modified: head/sys/sparc64/pci/fire.c ============================================================================== --- head/sys/sparc64/pci/fire.c Tue Jan 4 15:55:15 2011 (r216960) +++ head/sys/sparc64/pci/fire.c Tue Jan 4 16:11:32 2011 (r216961) @@ -836,7 +836,7 @@ fire_set_intr(struct fire_softc *sc, u_i INTIGN(vec) != sc->sc_ign || intr_vectors[vec].iv_ic != &fire_ic || bus_setup_intr(sc->sc_dev, sc->sc_irq_res[index], - INTR_TYPE_MISC | INTR_FAST, handler, NULL, arg, + INTR_TYPE_MISC | INTR_BRIDGE, handler, NULL, arg, &sc->sc_ihand[index]) != 0) panic("%s: failed to set up interrupt %d", __func__, index); } Modified: head/sys/sparc64/pci/psycho.c ============================================================================== --- head/sys/sparc64/pci/psycho.c Tue Jan 4 15:55:15 2011 (r216960) +++ head/sys/sparc64/pci/psycho.c Tue Jan 4 16:11:32 2011 (r216961) @@ -716,7 +716,7 @@ psycho_set_intr(struct psycho_softc *sc, INTVEC(PSYCHO_READ8(sc, intrmap)) != vec || intr_vectors[vec].iv_ic != &psycho_ic || bus_setup_intr(sc->sc_dev, sc->sc_irq_res[index], - INTR_TYPE_MISC | INTR_FAST, filt, intr, sc, + INTR_TYPE_MISC | INTR_BRIDGE, filt, intr, sc, &sc->sc_ihand[index]) != 0) panic("%s: failed to set up interrupt %d", __func__, index); } Modified: head/sys/sparc64/pci/schizo.c ============================================================================== --- head/sys/sparc64/pci/schizo.c Tue Jan 4 15:55:15 2011 (r216960) +++ head/sys/sparc64/pci/schizo.c Tue Jan 4 16:11:32 2011 (r216961) @@ -745,7 +745,7 @@ schizo_set_intr(struct schizo_softc *sc, INTIGN(vec) != sc->sc_ign || intr_vectors[vec].iv_ic != &schizo_ic || bus_setup_intr(sc->sc_dev, sc->sc_irq_res[index], - INTR_TYPE_MISC | INTR_FAST, handler, NULL, sc, + INTR_TYPE_MISC | INTR_BRIDGE, handler, NULL, sc, &sc->sc_ihand[index]) != 0) panic("%s: failed to set up interrupt %d", __func__, index); } Modified: head/sys/sparc64/sbus/sbus.c ============================================================================== --- head/sys/sparc64/sbus/sbus.c Tue Jan 4 15:55:15 2011 (r216960) +++ head/sys/sparc64/sbus/sbus.c Tue Jan 4 16:11:32 2011 (r216961) @@ -459,7 +459,7 @@ sbus_attach(device_t dev) INTIGN(vec = rman_get_start(sc->sc_ot_ires)) != sc->sc_ign || INTVEC(SYSIO_READ8(sc, SBR_THERM_INT_MAP)) != vec || intr_vectors[vec].iv_ic != &sbus_ic || - bus_setup_intr(dev, sc->sc_ot_ires, INTR_TYPE_MISC | INTR_FAST, + bus_setup_intr(dev, sc->sc_ot_ires, INTR_TYPE_MISC | INTR_BRIDGE, NULL, sbus_overtemp, sc, &sc->sc_ot_ihand) != 0) panic("%s: failed to set up temperature interrupt", __func__); i = 3; @@ -469,7 +469,7 @@ sbus_attach(device_t dev) INTIGN(vec = rman_get_start(sc->sc_pf_ires)) != sc->sc_ign || INTVEC(SYSIO_READ8(sc, SBR_POWER_INT_MAP)) != vec || intr_vectors[vec].iv_ic != &sbus_ic || - bus_setup_intr(dev, sc->sc_pf_ires, INTR_TYPE_MISC | INTR_FAST, + bus_setup_intr(dev, sc->sc_pf_ires, INTR_TYPE_MISC | INTR_BRIDGE, NULL, sbus_pwrfail, sc, &sc->sc_pf_ihand) != 0) panic("%s: failed to set up power fail interrupt", __func__); Modified: head/sys/sparc64/sparc64/intr_machdep.c ============================================================================== --- head/sys/sparc64/sparc64/intr_machdep.c Tue Jan 4 15:55:15 2011 (r216960) +++ head/sys/sparc64/sparc64/intr_machdep.c Tue Jan 4 16:11:32 2011 (r216961) @@ -99,7 +99,7 @@ static const char *const pil_names[] = { "hardclock", /* PIL_HARDCLOCK */ "stray", "stray", "stray", "stray", "filter", /* PIL_FILTER */ - "fast", /* PIL_FAST */ + "bridge", /* PIL_BRIDGE */ "tick", /* PIL_TICK */ }; @@ -328,10 +328,10 @@ inthand_add(const char *name, int vec, d if (vec < 0 || vec >= IV_MAX) return (EINVAL); /* - * INTR_FAST filters/handlers are special purpose only, allowing + * INTR_BRIDGE filters/handlers are special purpose only, allowing * them to be shared just would complicate things unnecessarily. */ - if ((flags & INTR_FAST) != 0 && (flags & INTR_EXCL) == 0) + if ((flags & INTR_BRIDGE) != 0 && (flags & INTR_EXCL) == 0) return (EINVAL); sx_xlock(&intr_table_lock); iv = &intr_vectors[vec]; @@ -349,7 +349,7 @@ inthand_add(const char *name, int vec, d ic->ic_disable(iv); iv->iv_refcnt++; if (iv->iv_refcnt == 1) - intr_setup((flags & INTR_FAST) != 0 ? PIL_FAST : + intr_setup((flags & INTR_BRIDGE) != 0 ? PIL_BRIDGE : filt != NULL ? PIL_FILTER : PIL_ITHREAD, intr_fast, vec, intr_execute_handlers, iv); else if (filt != NULL) { Modified: head/sys/sys/bus.h ============================================================================== --- head/sys/sys/bus.h Tue Jan 4 15:55:15 2011 (r216960) +++ head/sys/sys/bus.h Tue Jan 4 16:11:32 2011 (r216961) @@ -194,7 +194,11 @@ enum intr_type { INTR_FAST = 128, INTR_EXCL = 256, /* exclusive interrupt */ INTR_MPSAFE = 512, /* this interrupt is SMP safe */ - INTR_ENTROPY = 1024 /* this interrupt provides entropy */ + INTR_ENTROPY = 1024, /* this interrupt provides entropy */ + INTR_MD1 = 4096, /* flag reserved for MD use */ + INTR_MD2 = 8192, /* flag reserved for MD use */ + INTR_MD3 = 16384, /* flag reserved for MD use */ + INTR_MD4 = 32768 /* flag reserved for MD use */ }; enum intr_trigger { From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 16:21:15 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2E6281065696; Tue, 4 Jan 2011 16:21:15 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1AFEA8FC18; Tue, 4 Jan 2011 16:21:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04GLFVl043340; Tue, 4 Jan 2011 16:21:15 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04GLEet043337; Tue, 4 Jan 2011 16:21:14 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101041621.p04GLEet043337@svn.freebsd.org> From: Marius Strobl Date: Tue, 4 Jan 2011 16:21:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216962 - head/sys/sparc64/pci X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 16:21:15 -0000 Author: marius Date: Tue Jan 4 16:21:14 2011 New Revision: 216962 URL: http://svn.freebsd.org/changeset/base/216962 Log: Inherit the APB and the generic OFW PCI-PCI bridge driver from the generic PCI-PCI bridge driver in order to safe some code. Modified: head/sys/sparc64/pci/apb.c head/sys/sparc64/pci/ofw_pcib.c Modified: head/sys/sparc64/pci/apb.c ============================================================================== --- head/sys/sparc64/pci/apb.c Tue Jan 4 16:11:32 2011 (r216961) +++ head/sys/sparc64/pci/apb.c Tue Jan 4 16:21:14 2011 (r216962) @@ -81,25 +81,11 @@ static device_method_t apb_methods[] = { /* Device interface */ DEVMETHOD(device_probe, apb_probe), DEVMETHOD(device_attach, apb_attach), - DEVMETHOD(device_shutdown, bus_generic_shutdown), - DEVMETHOD(device_suspend, bus_generic_suspend), - DEVMETHOD(device_resume, bus_generic_resume), /* Bus interface */ - DEVMETHOD(bus_print_child, bus_generic_print_child), - DEVMETHOD(bus_read_ivar, pcib_read_ivar), - DEVMETHOD(bus_write_ivar, pcib_write_ivar), DEVMETHOD(bus_alloc_resource, apb_alloc_resource), - DEVMETHOD(bus_activate_resource, bus_generic_activate_resource), - DEVMETHOD(bus_deactivate_resource, bus_generic_deactivate_resource), - DEVMETHOD(bus_release_resource, bus_generic_release_resource), - DEVMETHOD(bus_setup_intr, bus_generic_setup_intr), - DEVMETHOD(bus_teardown_intr, bus_generic_teardown_intr), /* pcib interface */ - DEVMETHOD(pcib_maxslots, pcib_maxslots), - DEVMETHOD(pcib_read_config, pcib_read_config), - DEVMETHOD(pcib_write_config, pcib_write_config), DEVMETHOD(pcib_route_interrupt, ofw_pcib_gen_route_interrupt), /* ofw_bus interface */ @@ -110,7 +96,8 @@ static device_method_t apb_methods[] = { static devclass_t pcib_devclass; -DEFINE_CLASS_0(pcib, apb_driver, apb_methods, sizeof(struct apb_softc)); +DEFINE_CLASS_1(pcib, apb_driver, apb_methods, sizeof(struct apb_softc), + pcib_driver); EARLY_DRIVER_MODULE(apb, pci, apb_driver, pcib_devclass, 0, 0, BUS_PASS_BUS); MODULE_DEPEND(apb, pci, 1, 1, 1); Modified: head/sys/sparc64/pci/ofw_pcib.c ============================================================================== --- head/sys/sparc64/pci/ofw_pcib.c Tue Jan 4 16:11:32 2011 (r216961) +++ head/sys/sparc64/pci/ofw_pcib.c Tue Jan 4 16:21:14 2011 (r216962) @@ -64,31 +64,11 @@ static device_method_t ofw_pcib_methods[ /* Device interface */ DEVMETHOD(device_probe, ofw_pcib_probe), DEVMETHOD(device_attach, ofw_pcib_attach), - DEVMETHOD(device_shutdown, bus_generic_shutdown), - DEVMETHOD(device_suspend, bus_generic_suspend), - DEVMETHOD(device_resume, bus_generic_resume), /* Bus interface */ - DEVMETHOD(bus_print_child, bus_generic_print_child), - DEVMETHOD(bus_read_ivar, pcib_read_ivar), - DEVMETHOD(bus_write_ivar, pcib_write_ivar), - DEVMETHOD(bus_alloc_resource, pcib_alloc_resource), - DEVMETHOD(bus_activate_resource, bus_generic_activate_resource), - DEVMETHOD(bus_deactivate_resource, bus_generic_deactivate_resource), - DEVMETHOD(bus_release_resource, bus_generic_release_resource), - DEVMETHOD(bus_setup_intr, bus_generic_setup_intr), - DEVMETHOD(bus_teardown_intr, bus_generic_teardown_intr), /* pcib interface */ - DEVMETHOD(pcib_maxslots, pcib_maxslots), - DEVMETHOD(pcib_read_config, pcib_read_config), - DEVMETHOD(pcib_write_config, pcib_write_config), - DEVMETHOD(pcib_route_interrupt, ofw_pcib_gen_route_interrupt), - DEVMETHOD(pcib_alloc_msi, pcib_alloc_msi), - DEVMETHOD(pcib_release_msi, pcib_release_msi), - DEVMETHOD(pcib_alloc_msix, pcib_alloc_msix), - DEVMETHOD(pcib_release_msix, pcib_release_msix), - DEVMETHOD(pcib_map_msi, pcib_map_msi), + DEVMETHOD(pcib_route_interrupt, ofw_pcib_gen_route_interrupt), /* ofw_bus interface */ DEVMETHOD(ofw_bus_get_node, ofw_pcib_gen_get_node), @@ -98,8 +78,8 @@ static device_method_t ofw_pcib_methods[ static devclass_t pcib_devclass; -DEFINE_CLASS_0(pcib, ofw_pcib_driver, ofw_pcib_methods, - sizeof(struct ofw_pcib_gen_softc)); +DEFINE_CLASS_1(pcib, ofw_pcib_driver, ofw_pcib_methods, + sizeof(struct ofw_pcib_gen_softc), pcib_driver); EARLY_DRIVER_MODULE(ofw_pcib, pci, ofw_pcib_driver, pcib_devclass, 0, 0, BUS_PASS_BUS); MODULE_DEPEND(ofw_pcib, pci, 1, 1, 1); From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 16:29:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2C805106566C; Tue, 4 Jan 2011 16:29:08 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1C3FE8FC26; Tue, 4 Jan 2011 16:29:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04GT8sY044029; Tue, 4 Jan 2011 16:29:08 GMT (envelope-from cperciva@svn.freebsd.org) Received: (from cperciva@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04GT71A044027; Tue, 4 Jan 2011 16:29:07 GMT (envelope-from cperciva@svn.freebsd.org) Message-Id: <201101041629.p04GT71A044027@svn.freebsd.org> From: Colin Percival Date: Tue, 4 Jan 2011 16:29:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216963 - head/sys/i386/xen X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 16:29:08 -0000 Author: cperciva Date: Tue Jan 4 16:29:07 2011 New Revision: 216963 URL: http://svn.freebsd.org/changeset/base/216963 Log: Spell CRITICAL_ASSERT correctly. Submitted by: jhb MFC with: r216944 Modified: head/sys/i386/xen/xen_machdep.c Modified: head/sys/i386/xen/xen_machdep.c ============================================================================== --- head/sys/i386/xen/xen_machdep.c Tue Jan 4 16:21:14 2011 (r216962) +++ head/sys/i386/xen/xen_machdep.c Tue Jan 4 16:29:07 2011 (r216963) @@ -253,8 +253,7 @@ _xen_flush_queue(void) #ifdef INVARIANTS if (__predict_true(gdtset)) - KASSERT(curthread->td_critnest > 0, - ("xen queue flush should be in a critical section")); + CRITICAL_ASSERT(curthread); #endif XPQ_IDX = 0; From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 17:06:03 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 734D41065670; Tue, 4 Jan 2011 17:06:03 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 62CA58FC1C; Tue, 4 Jan 2011 17:06:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04H630u047424; Tue, 4 Jan 2011 17:06:03 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04H63Xx047422; Tue, 4 Jan 2011 17:06:03 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201101041706.p04H63Xx047422@svn.freebsd.org> From: Jung-uk Kim Date: Tue, 4 Jan 2011 17:06:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216965 - head/sys/dev/acpica X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 17:06:03 -0000 Author: jkim Date: Tue Jan 4 17:06:03 2011 New Revision: 216965 URL: http://svn.freebsd.org/changeset/base/216965 Log: Clarify the previous commit. AcpiFinishGpe() will not clear GPE for us because we set it to edge-trigger. Modified: head/sys/dev/acpica/acpi_ec.c Modified: head/sys/dev/acpica/acpi_ec.c ============================================================================== --- head/sys/dev/acpica/acpi_ec.c Tue Jan 4 16:51:24 2011 (r216964) +++ head/sys/dev/acpica/acpi_ec.c Tue Jan 4 17:06:03 2011 (r216965) @@ -685,10 +685,12 @@ EcGpeQueryHandler(void *Context) device_printf(sc->ec_dev, "evaluation of query method %s failed: %s\n", qxx, AcpiFormatException(Status)); } + + /* Reenable runtime GPE if its execution was deferred. */ if (sci_enqueued) { Status = AcpiFinishGpe(sc->ec_gpehandle, sc->ec_gpebit); if (ACPI_FAILURE(Status)) - device_printf(sc->ec_dev, "clearing GPE failed: %s\n", + device_printf(sc->ec_dev, "reenabling runtime GPE failed: %s\n", AcpiFormatException(Status)); } } From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 17:15:04 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C006C106566B for ; Tue, 4 Jan 2011 17:15:04 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from out-0.mx.aerioconnect.net (out-0-24.mx.aerioconnect.net [216.240.47.84]) by mx1.freebsd.org (Postfix) with ESMTP id 974868FC0C for ; Tue, 4 Jan 2011 17:15:04 +0000 (UTC) Received: from idiom.com (postfix@mx0.idiom.com [216.240.32.160]) by out-0.mx.aerioconnect.net (8.13.8/8.13.8) with ESMTP id p04Gxm1J018256; Tue, 4 Jan 2011 08:59:48 -0800 X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e Received: from julian-mac.elischer.org (h-67-100-89-137.snfccasy.static.covad.net [67.100.89.137]) by idiom.com (Postfix) with ESMTP id D7C5B2D6012; Tue, 4 Jan 2011 08:59:46 -0800 (PST) Message-ID: <4D23521C.8020506@freebsd.org> Date: Tue, 04 Jan 2011 09:00:12 -0800 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.4; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: John Baldwin References: <201101041316.p04DGSo6037042@svn.freebsd.org> In-Reply-To: <201101041316.p04DGSo6037042@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.67 on 216.240.47.51 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 17:15:04 -0000 On 1/4/11 5:16 AM, John Baldwin wrote: > Author: jhb > Date: Tue Jan 4 13:16:28 2011 > New Revision: 216954 > URL: http://svn.freebsd.org/changeset/base/216954 > > Log: > kproc_exit() is already marked __dead2 so a NOTREACHED comment here isn't > needed for lint. yes but it IS good documentation when reading the code. > > Submitted by: bde > > Modified: > head/sys/kern/kern_kthread.c > > Modified: head/sys/kern/kern_kthread.c > ============================================================================== > --- head/sys/kern/kern_kthread.c Tue Jan 4 13:02:52 2011 (r216953) > +++ head/sys/kern/kern_kthread.c Tue Jan 4 13:16:28 2011 (r216954) > @@ -329,7 +329,6 @@ kthread_exit(void) > PROC_UNLOCK(p); > rw_wunlock(&tidhash_lock); > kproc_exit(0); > - /* NOTREACHED */ > } > LIST_REMOVE(curthread, td_hash); > rw_wunlock(&tidhash_lock); > From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 17:27:17 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F0C05106566B; Tue, 4 Jan 2011 17:27:17 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E07088FC08; Tue, 4 Jan 2011 17:27:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04HRHnv048896; Tue, 4 Jan 2011 17:27:17 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04HRHZC048894; Tue, 4 Jan 2011 17:27:17 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101041727.p04HRHZC048894@svn.freebsd.org> From: Konstantin Belousov Date: Tue, 4 Jan 2011 17:27:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216967 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 17:27:18 -0000 Author: kib Date: Tue Jan 4 17:27:17 2011 New Revision: 216967 URL: http://svn.freebsd.org/changeset/base/216967 Log: Use errx() instead of err() in parseint. There is usually no interesting information in errno. Noted by: Garrett Cooper MFC after: 1 week Modified: head/usr.sbin/rtprio/rtprio.c Modified: head/usr.sbin/rtprio/rtprio.c ============================================================================== --- head/usr.sbin/rtprio/rtprio.c Tue Jan 4 17:18:53 2011 (r216966) +++ head/usr.sbin/rtprio/rtprio.c Tue Jan 4 17:27:17 2011 (r216967) @@ -133,9 +133,9 @@ parseint(const char *str, const char *er errno = 0; res = strtol(str, &endp, 10); if (errno != 0 || endp == str || *endp != '\0') - err(1, "%s must be a number", errname); + errx(1, "%s must be a number", errname); if (res >= INT_MAX) - err(1, "Integer overflow parsing %s", errname); + errx(1, "Integer overflow parsing %s", errname); return (res); } From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 17:37:43 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 17C371065673; Tue, 4 Jan 2011 17:37:43 +0000 (UTC) (envelope-from bruce@cran.org.uk) Received: from muon.cran.org.uk (muon.cran.org.uk [IPv6:2a01:348:0:15:5d59:5c40:0:1]) by mx1.freebsd.org (Postfix) with ESMTP id 9A7B38FC1C; Tue, 4 Jan 2011 17:37:42 +0000 (UTC) Received: from muon.cran.org.uk (localhost [127.0.0.1]) by muon.cran.org.uk (Postfix) with ESMTP id 7868CE8218; Tue, 4 Jan 2011 17:37:41 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=cran.org.uk; h=date:from :to:cc:subject:message-id:in-reply-to:references:mime-version :content-type:content-transfer-encoding; s=mail; bh=Q98jiZtdisw7 kRsVyWAjFKYZo8k=; b=TPYxNIWBXKdf3XLB+73zoE2EUFPFXkD5QsOE0Cdbe2fn Dxd3rWJOUXsxyTLrkMWsKuTFyJ35mglG5OxkU9MA3JFnV28MuSDrak9P7E1s8p1l uPPUM2IcSzfGsBcN/s15Rs8doCVFyXn14eTFqC0mau3Yz5LfnHQ6TrPWtlFPTEA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=cran.org.uk; h=date:from:to :cc:subject:message-id:in-reply-to:references:mime-version :content-type:content-transfer-encoding; q=dns; s=mail; b=dKbNmV V7AZ5sU2eMCDH5QVNi/7z3usYSyqgZlNqfe9cd4baSiEdKLY4Vp1C7lK5rh9d8Sv Mpre3RrLVgVupju5lfzxmexhS5WKjtwy4Es7jVQ/4qOLU7udu7SemYi2w7iW6imj qxN5xyvseQPK1Gz++uozgULgHSGet9itKgvMk= Received: from unknown (client-86-27-23-77.glfd.adsl.virginmedia.com [86.27.23.77]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by muon.cran.org.uk (Postfix) with ESMTPSA id C7DB9E72B1; Tue, 4 Jan 2011 17:37:40 +0000 (GMT) Date: Tue, 4 Jan 2011 17:37:36 +0000 From: Bruce Cran To: Julian Elischer Message-ID: <20110104173736.00006b5b@unknown> In-Reply-To: <4D23521C.8020506@freebsd.org> References: <201101041316.p04DGSo6037042@svn.freebsd.org> <4D23521C.8020506@freebsd.org> X-Mailer: Claws Mail 3.7.6 (GTK+ 2.16.0; i586-pc-mingw32msvc) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, John Baldwin Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 17:37:43 -0000 On Tue, 04 Jan 2011 09:00:12 -0800 Julian Elischer wrote: > On 1/4/11 5:16 AM, John Baldwin wrote: > > kproc_exit() is already marked __dead2 so a NOTREACHED comment > > here isn't needed for lint. > > yes but it IS good documentation when reading the code. Shouldn't people know that kproc_exit doesn't return? -- Bruce Cran From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 17:41:53 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 80D81106564A; Tue, 4 Jan 2011 17:41:53 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-ew0-f54.google.com (mail-ew0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 90DF68FC12; Tue, 4 Jan 2011 17:41:52 +0000 (UTC) Received: by ewy24 with SMTP id 24so6788449ewy.13 for ; Tue, 04 Jan 2011 09:41:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=nCcdZ29bCeFEGOXdYccQSRdPflux9/OUx55FiUrnL1Q=; b=BHy3VvozQ1xeRBMcralSMjxAJfdPjRwKbe1wzBglY1yXs0kYbOAux+Xjr6TWWHEqvs kIZ8p+wbLoYEhuNXWG+wD3m56yn69GoowUQk/iFSQgOj1wGaVM6kL8IhtEjFVAMy6IUQ cB9P11cnOF2FKvhkK/1POuXvNjobJJgNnwaG8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=RRsRXzlDbX1wnBCrDhmAn/N2aByK1RpZSHzDUQMp7A1UOLNQDsGEv/dIGopZjgendy 2/aY2uarfp4ooGbMPpX1/k6R7kICMq7v2xmQtwsE+j1Cb1gIw43w2A0bDk2S9jcH8jZF MkCyTgXqNox6sAcLFpGOLHtrdx5CnpPPZZ/iY= MIME-Version: 1.0 Received: by 10.216.141.75 with SMTP id f53mr9288268wej.16.1294162911202; Tue, 04 Jan 2011 09:41:51 -0800 (PST) Sender: yanegomi@gmail.com Received: by 10.216.254.226 with HTTP; Tue, 4 Jan 2011 09:41:51 -0800 (PST) In-Reply-To: <201101041727.p04HRHZC048894@svn.freebsd.org> References: <201101041727.p04HRHZC048894@svn.freebsd.org> Date: Tue, 4 Jan 2011 09:41:51 -0800 X-Google-Sender-Auth: uP4vVMrYlZTmg4iGklkPa1nQ58c Message-ID: From: Garrett Cooper To: Konstantin Belousov Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216967 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 17:41:53 -0000 On Tue, Jan 4, 2011 at 9:27 AM, Konstantin Belousov wrote= : > Author: kib > Date: Tue Jan =A04 17:27:17 2011 > New Revision: 216967 > URL: http://svn.freebsd.org/changeset/base/216967 > > Log: > =A0Use errx() instead of err() in parseint. There is usually no interesti= ng > =A0information in errno. > > =A0Noted by: =A0 =A0 Garrett Cooper > =A0MFC after: =A0 =A01 week Someday it would be nice if we could have one standard / libraritized set of functions that properly handle overflow and all that good stuff (as bde has suggested to me elsewhere), but this is good enough for today. Thanks! -Garrett From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 18:18:28 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 17BBA1065675; Tue, 4 Jan 2011 18:18:28 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id DEF3B8FC13; Tue, 4 Jan 2011 18:18:27 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 84BFF46B09; Tue, 4 Jan 2011 13:18:27 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id B6E278A009; Tue, 4 Jan 2011 13:18:26 -0500 (EST) From: John Baldwin To: Julian Elischer Date: Tue, 4 Jan 2011 13:14:08 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101041316.p04DGSo6037042@svn.freebsd.org> <4D23521C.8020506@freebsd.org> In-Reply-To: <4D23521C.8020506@freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101041314.08949.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Tue, 04 Jan 2011 13:18:26 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 18:18:28 -0000 On Tuesday, January 04, 2011 12:00:12 pm Julian Elischer wrote: > On 1/4/11 5:16 AM, John Baldwin wrote: > > Author: jhb > > Date: Tue Jan 4 13:16:28 2011 > > New Revision: 216954 > > URL: http://svn.freebsd.org/changeset/base/216954 > > > > Log: > > kproc_exit() is already marked __dead2 so a NOTREACHED comment here isn't > > needed for lint. > > yes but it IS good documentation when reading the code. Err, no, the point of NOTREACHED is to serve as documentation for lint(1), but that has subsequently been obsoleted by __dead2. Do you put a NOTREACHED comment after every call to exit() in userland? :) -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 18:25:40 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 293051065674; Tue, 4 Jan 2011 18:25:40 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id EEF8A8FC17; Tue, 4 Jan 2011 18:25:39 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id A50C346B3B; Tue, 4 Jan 2011 13:25:39 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 8247B8A009; Tue, 4 Jan 2011 13:25:38 -0500 (EST) From: John Baldwin To: Garrett Cooper Date: Tue, 4 Jan 2011 13:22:32 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101041727.p04HRHZC048894@svn.freebsd.org> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201101041322.33071.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Tue, 04 Jan 2011 13:25:38 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov Subject: Re: svn commit: r216967 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 18:25:40 -0000 On Tuesday, January 04, 2011 12:41:51 pm Garrett Cooper wrote: > On Tue, Jan 4, 2011 at 9:27 AM, Konstantin Belousov wrote: > > Author: kib > > Date: Tue Jan 4 17:27:17 2011 > > New Revision: 216967 > > URL: http://svn.freebsd.org/changeset/base/216967 > > > > Log: > > Use errx() instead of err() in parseint. There is usually no interesting > > information in errno. > > > > Noted by: Garrett Cooper > > MFC after: 1 week > > Someday it would be nice if we could have one standard / libraritized > set of functions that properly handle overflow and all that good stuff > (as bde has suggested to me elsewhere), but this is good enough for > today. strtonum(3)? -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 18:30:46 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A6FBE106566C; Tue, 4 Jan 2011 18:30:46 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-iw0-f182.google.com (mail-iw0-f182.google.com [209.85.214.182]) by mx1.freebsd.org (Postfix) with ESMTP id 24FA28FC1A; Tue, 4 Jan 2011 18:30:45 +0000 (UTC) Received: by iwn39 with SMTP id 39so14824681iwn.13 for ; Tue, 04 Jan 2011 10:30:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to:x-mailer; bh=1yt4FTAcfKgByfm6DBIAYgLcpO9vWJ37FMGkFebhQKc=; b=Moh0vfdxOoPXvVGRlVsmoNve2aAte7/Ntka7mHgAgIGy3YaKXgdhs1ZWNK4FTnOd5r QoE+6rcvXri5iGWFAJADSOGnwigFEelk/3jKBN4a1bHuceX6Xq4C01N1DnUtksbBlpPj nwxpZanBmWhM+KpYqL33ggm5K5AEgab8SJk/E= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=XGP3qP8s4s40fMlx5H4UyEk4LTS/nSb4DIMw+bUgvpsCViq3TfY4M9AH9PY+XbVmYW o/43/A9PTMHTinldG/eK6UCFohELVS4krRU2A7/17oZoac7ViC5eZ/+WRhBONIqfvSte 1NSyTlMCm9kFlOYrDoNXuiiOFA8Wm/Yi/Lxbo= Received: by 10.231.11.68 with SMTP id s4mr22504287ibs.14.1294165845415; Tue, 04 Jan 2011 10:30:45 -0800 (PST) Received: from [192.168.20.5] (c-24-130-151-210.hsd1.ca.comcast.net [24.130.151.210]) by mx.google.com with ESMTPS id gy41sm20057146ibb.5.2011.01.04.10.30.42 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 04 Jan 2011 10:30:44 -0800 (PST) Mime-Version: 1.0 (Apple Message framework v1082) Content-Type: text/plain; charset=us-ascii From: Garrett Cooper In-Reply-To: <201101041322.33071.jhb@freebsd.org> Date: Tue, 4 Jan 2011 10:30:40 -0800 Content-Transfer-Encoding: quoted-printable Message-Id: <004687DF-47EF-4468-97DB-8443A249BE00@gmail.com> References: <201101041727.p04HRHZC048894@svn.freebsd.org> <201101041322.33071.jhb@freebsd.org> To: John Baldwin X-Mailer: Apple Mail (2.1082) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov , Garrett Cooper Subject: Re: svn commit: r216967 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 18:30:46 -0000 On Jan 4, 2011, at 10:22 AM, John Baldwin wrote: > On Tuesday, January 04, 2011 12:41:51 pm Garrett Cooper wrote: >> On Tue, Jan 4, 2011 at 9:27 AM, Konstantin Belousov = wrote: >>> Author: kib >>> Date: Tue Jan 4 17:27:17 2011 >>> New Revision: 216967 >>> URL: http://svn.freebsd.org/changeset/base/216967 >>>=20 >>> Log: >>> Use errx() instead of err() in parseint. There is usually no = interesting >>> information in errno. >>>=20 >>> Noted by: Garrett Cooper >>> MFC after: 1 week >>=20 >> Someday it would be nice if we could have one standard / libraritized >> set of functions that properly handle overflow and all that good = stuff >> (as bde has suggested to me elsewhere), but this is good enough for >> today. >=20 > strtonum(3)? bde said (back in 11/15): "It is good to fix the blind truncation, but overflow is never graceful. I will review the patch for errors like the ones in corresponding user code (dd get_num(), strtonum(), expand_number()... get_num() is almost OK, but the newer more public APIs are broken as designed)." So there's some concern that he has with those APIs still.. the = fact that I was trying to use a similar API to parse numbers in strings = in the kernel (strtoq in tunable work) didn't make things any better = unfortunately. Thanks, -Garrett= From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 19:09:05 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D45EC106564A; Tue, 4 Jan 2011 19:09:05 +0000 (UTC) (envelope-from jmallett@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C3CC38FC12; Tue, 4 Jan 2011 19:09:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04J95WJ051539; Tue, 4 Jan 2011 19:09:05 GMT (envelope-from jmallett@svn.freebsd.org) Received: (from jmallett@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04J95i8051538; Tue, 4 Jan 2011 19:09:05 GMT (envelope-from jmallett@svn.freebsd.org) Message-Id: <201101041909.p04J95i8051538@svn.freebsd.org> From: Juli Mallett Date: Tue, 4 Jan 2011 19:09:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216969 - head/sys/mips/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 19:09:05 -0000 Author: jmallett Date: Tue Jan 4 19:09:05 2011 New Revision: 216969 URL: http://svn.freebsd.org/changeset/base/216969 Log: Remove OCTEON1-32. Since moving to the Cavium SDK, we've lost our support for running an o32 kernel safely, and would have to add interrupt disabling and reenabling to a bunch of macros in the Simple Executive sources to support it. The only reason one would run an o32 kernel on Octeon would be to run o32 world, which is better worked towards by adding o32 binary compatibility to n64 kernels along with, eventually, supporting multilib systems so o32 binaries can run alongside n32 and n64 ones. Discussed with: imp Deleted: head/sys/mips/conf/OCTEON1-32 From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 19:10:55 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 23B1F106564A; Tue, 4 Jan 2011 19:10:55 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 133A68FC1B; Tue, 4 Jan 2011 19:10:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04JAskw051612; Tue, 4 Jan 2011 19:10:54 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04JAsfk051610; Tue, 4 Jan 2011 19:10:54 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201101041910.p04JAsfk051610@svn.freebsd.org> From: Pyun YongHyeon Date: Tue, 4 Jan 2011 19:10:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216970 - head/sys/dev/bge X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 19:10:55 -0000 Author: yongari Date: Tue Jan 4 19:10:54 2011 New Revision: 216970 URL: http://svn.freebsd.org/changeset/base/216970 Log: Partially revert change made in r212061. r212061 relied on bus_dma(9)'s capability which honors boundary restrictions of DMA tag for dynamic buffers. However it seems this does not work well and it triggered watchodg timeouts on controller that has the hardware bug. It's not clear whether there is still another hardware bug not mentioned in errata. This should be revisited since this change shall make use of bounce buffers which in turn reduces performance a lot on systems that have more than 4GB memory. Reported by: Michael L. Squires (mikes <> siralan dot org) Tested by: Michael L. Squires (mikes <> siralan dot org) MFC after: 3 days Modified: head/sys/dev/bge/if_bge.c Modified: head/sys/dev/bge/if_bge.c ============================================================================== --- head/sys/dev/bge/if_bge.c Tue Jan 4 19:09:05 2011 (r216969) +++ head/sys/dev/bge/if_bge.c Tue Jan 4 19:10:54 2011 (r216970) @@ -2475,8 +2475,15 @@ bge_dma_alloc(struct bge_softc *sc) boundary = 0; if ((sc->bge_flags & BGE_FLAG_4G_BNDRY_BUG) != 0) boundary = BGE_DMA_BNDRY; + /* + * XXX + * It seems bus_dma(9) still has issue on dealing with boundary + * restriction for dynamic buffers so disable the boundary + * restriction and limit DMA address space to 32bit. It's not + * clear whether there is another hardware issue here. + */ error = bus_dma_tag_create(bus_get_dma_tag(sc->bge_dev), - 1, boundary, lowaddr, BUS_SPACE_MAXADDR, NULL, + 1, 0, BUS_SPACE_MAXADDR_32BIT, BUS_SPACE_MAXADDR, NULL, NULL, BUS_SPACE_MAXSIZE_32BIT, 0, BUS_SPACE_MAXSIZE_32BIT, 0, NULL, NULL, &sc->bge_cdata.bge_buffer_tag); if (error != 0) { From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 19:26:11 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 66DE9106564A; Tue, 4 Jan 2011 19:26:11 +0000 (UTC) (envelope-from bschmidt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 5629C8FC14; Tue, 4 Jan 2011 19:26:11 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04JQBgJ052020; Tue, 4 Jan 2011 19:26:11 GMT (envelope-from bschmidt@svn.freebsd.org) Received: (from bschmidt@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04JQB6Q052018; Tue, 4 Jan 2011 19:26:11 GMT (envelope-from bschmidt@svn.freebsd.org) Message-Id: <201101041926.p04JQB6Q052018@svn.freebsd.org> From: Bernhard Schmidt Date: Tue, 4 Jan 2011 19:26:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216971 - head/share/man/man4 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 19:26:11 -0000 Author: bschmidt Date: Tue Jan 4 19:26:11 2011 New Revision: 216971 URL: http://svn.freebsd.org/changeset/base/216971 Log: OLDCARD is long gone. Discussed with: imp Modified: head/share/man/man4/wi.4 Modified: head/share/man/man4/wi.4 ============================================================================== --- head/share/man/man4/wi.4 Tue Jan 4 19:10:54 2011 (r216970) +++ head/share/man/man4/wi.4 Tue Jan 4 19:26:11 2011 (r216971) @@ -31,7 +31,7 @@ .\" $FreeBSD$ .\" $OpenBSD: wi.4tbl,v 1.14 2002/04/29 19:53:50 jsyn Exp $ .\" -.Dd August 2, 2008 +.Dd January 4, 2010 .Dt WI 4 .Os .Sh NAME @@ -375,21 +375,3 @@ Symbol none none none none Not all the new messages are documented here, and many of them are indications of transient errors that are not indications of serious problems. -.Pp -WL200 PCI wireless cards are based on a Cirrus Logic CL-PD6729 bridge -chips glued to an Intersil Prism-II PCMCIA chipset w/o the PC Card -form factor being present. -These chips are special and require special care to use properly. -One must set -.Va hw.pcic.pd6729_intr_path Ns = Ns Qq Li 2 -in -.Pa /boot/loader.conf . -This tells the PC Card system to use PCI interrupts for this odd beast. -It is not possible to know automatically which kind of interrupts to use. -OLDCARD devices -support this device. -NEWCARD devices -.Xr ( pccbb 4 -and -.Xr pccard 4 ) -do not support it at this time. From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 19:32:04 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 72801106564A; Tue, 4 Jan 2011 19:32:04 +0000 (UTC) (envelope-from jmallett@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 29A428FC08; Tue, 4 Jan 2011 19:32:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04JW4P4052195; Tue, 4 Jan 2011 19:32:04 GMT (envelope-from jmallett@svn.freebsd.org) Received: (from jmallett@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04JW4TC052193; Tue, 4 Jan 2011 19:32:04 GMT (envelope-from jmallett@svn.freebsd.org) Message-Id: <201101041932.p04JW4TC052193@svn.freebsd.org> From: Juli Mallett Date: Tue, 4 Jan 2011 19:32:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216972 - head/sys/mips/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 19:32:04 -0000 Author: jmallett Date: Tue Jan 4 19:32:03 2011 New Revision: 216972 URL: http://svn.freebsd.org/changeset/base/216972 Log: Correct an 8-year-old typo which reliably leads to typo after typo today: The macros here for generating coprocessor 0 accessors are named like: MIPS_RDRW32_COP0 That macro would produce mips_rd_() and mips_wr_() inlines to access the specified register by name from C. The problem is that the R and the W were swapped in the macros originally; it was meant to be named RDWR because it generated mips_rd_* and mips_wr_* functions, but was instead spelled RDRW, which nobody should be expected to get right by anything other than copy and paste. It's too many consonants in a row to keep straight anyway, so just prefer e.g.: MIPS_RW32_COP0 While here, add a missing #undef. Modified: head/sys/mips/include/cpufunc.h Modified: head/sys/mips/include/cpufunc.h ============================================================================== --- head/sys/mips/include/cpufunc.h Tue Jan 4 19:26:11 2011 (r216971) +++ head/sys/mips/include/cpufunc.h Tue Jan 4 19:32:03 2011 (r216972) @@ -114,7 +114,7 @@ mips_write_membar(void) * ABI checks. */ #if defined(__mips_n32) || defined(__mips_n64) -#define MIPS_RDRW64_COP0(n,r) \ +#define MIPS_RW64_COP0(n,r) \ static __inline uint64_t \ mips_rd_ ## n (void) \ { \ @@ -137,18 +137,18 @@ mips_wr_ ## n (uint64_t a0) \ } struct __hack #if defined(__mips_n64) -MIPS_RDRW64_COP0(excpc, MIPS_COP_0_EXC_PC); -MIPS_RDRW64_COP0(entrylo0, MIPS_COP_0_TLB_LO0); -MIPS_RDRW64_COP0(entrylo1, MIPS_COP_0_TLB_LO1); -MIPS_RDRW64_COP0(entryhi, MIPS_COP_0_TLB_HI); -MIPS_RDRW64_COP0(pagemask, MIPS_COP_0_TLB_PG_MASK); +MIPS_RW64_COP0(excpc, MIPS_COP_0_EXC_PC); +MIPS_RW64_COP0(entrylo0, MIPS_COP_0_TLB_LO0); +MIPS_RW64_COP0(entrylo1, MIPS_COP_0_TLB_LO1); +MIPS_RW64_COP0(entryhi, MIPS_COP_0_TLB_HI); +MIPS_RW64_COP0(pagemask, MIPS_COP_0_TLB_PG_MASK); #endif -MIPS_RDRW64_COP0(xcontext, MIPS_COP_0_TLB_XCONTEXT); +MIPS_RW64_COP0(xcontext, MIPS_COP_0_TLB_XCONTEXT); -#undef MIPS_RDRW64_COP0 +#undef MIPS_RW64_COP0 #endif -#define MIPS_RDRW32_COP0(n,r) \ +#define MIPS_RW32_COP0(n,r) \ static __inline uint32_t \ mips_rd_ ## n (void) \ { \ @@ -170,7 +170,7 @@ mips_wr_ ## n (uint32_t a0) \ mips_barrier(); \ } struct __hack -#define MIPS_RDRW32_COP0_SEL(n,r,s) \ +#define MIPS_RW32_COP0_SEL(n,r,s) \ static __inline uint32_t \ mips_rd_ ## n(void) \ { \ @@ -205,45 +205,46 @@ static __inline void mips_sync_icache (v } #endif -MIPS_RDRW32_COP0(compare, MIPS_COP_0_COMPARE); -MIPS_RDRW32_COP0(config, MIPS_COP_0_CONFIG); -MIPS_RDRW32_COP0_SEL(config1, MIPS_COP_0_CONFIG, 1); -MIPS_RDRW32_COP0_SEL(config2, MIPS_COP_0_CONFIG, 2); -MIPS_RDRW32_COP0_SEL(config3, MIPS_COP_0_CONFIG, 3); -MIPS_RDRW32_COP0(count, MIPS_COP_0_COUNT); -MIPS_RDRW32_COP0(index, MIPS_COP_0_TLB_INDEX); -MIPS_RDRW32_COP0(wired, MIPS_COP_0_TLB_WIRED); -MIPS_RDRW32_COP0(cause, MIPS_COP_0_CAUSE); +MIPS_RW32_COP0(compare, MIPS_COP_0_COMPARE); +MIPS_RW32_COP0(config, MIPS_COP_0_CONFIG); +MIPS_RW32_COP0_SEL(config1, MIPS_COP_0_CONFIG, 1); +MIPS_RW32_COP0_SEL(config2, MIPS_COP_0_CONFIG, 2); +MIPS_RW32_COP0_SEL(config3, MIPS_COP_0_CONFIG, 3); +MIPS_RW32_COP0(count, MIPS_COP_0_COUNT); +MIPS_RW32_COP0(index, MIPS_COP_0_TLB_INDEX); +MIPS_RW32_COP0(wired, MIPS_COP_0_TLB_WIRED); +MIPS_RW32_COP0(cause, MIPS_COP_0_CAUSE); #if !defined(__mips_n64) -MIPS_RDWR32_COP0(excpc, MIPS_COP_0_EXC_PC); +MIPS_RW32_COP0(excpc, MIPS_COP_0_EXC_PC); #endif -MIPS_RDRW32_COP0(status, MIPS_COP_0_STATUS); +MIPS_RW32_COP0(status, MIPS_COP_0_STATUS); /* XXX: Some of these registers are specific to MIPS32. */ #if !defined(__mips_n64) -MIPS_RDRW32_COP0(entrylo0, MIPS_COP_0_TLB_LO0); -MIPS_RDRW32_COP0(entrylo1, MIPS_COP_0_TLB_LO1); -MIPS_RDRW32_COP0(entryhi, MIPS_COP_0_TLB_HI); -MIPS_RDRW32_COP0(pagemask, MIPS_COP_0_TLB_PG_MASK); +MIPS_RW32_COP0(entrylo0, MIPS_COP_0_TLB_LO0); +MIPS_RW32_COP0(entrylo1, MIPS_COP_0_TLB_LO1); +MIPS_RW32_COP0(entryhi, MIPS_COP_0_TLB_HI); +MIPS_RW32_COP0(pagemask, MIPS_COP_0_TLB_PG_MASK); #endif -MIPS_RDRW32_COP0(prid, MIPS_COP_0_PRID); +MIPS_RW32_COP0(prid, MIPS_COP_0_PRID); /* XXX 64-bit? */ -MIPS_RDRW32_COP0_SEL(ebase, MIPS_COP_0_PRID, 1); -MIPS_RDRW32_COP0(watchlo, MIPS_COP_0_WATCH_LO); -MIPS_RDRW32_COP0_SEL(watchlo1, MIPS_COP_0_WATCH_LO, 1); -MIPS_RDRW32_COP0_SEL(watchlo2, MIPS_COP_0_WATCH_LO, 2); -MIPS_RDRW32_COP0_SEL(watchlo3, MIPS_COP_0_WATCH_LO, 3); -MIPS_RDRW32_COP0(watchhi, MIPS_COP_0_WATCH_HI); -MIPS_RDRW32_COP0_SEL(watchhi1, MIPS_COP_0_WATCH_HI, 1); -MIPS_RDRW32_COP0_SEL(watchhi2, MIPS_COP_0_WATCH_HI, 2); -MIPS_RDRW32_COP0_SEL(watchhi3, MIPS_COP_0_WATCH_HI, 3); - -MIPS_RDRW32_COP0_SEL(perfcnt0, MIPS_COP_0_PERFCNT, 0); -MIPS_RDRW32_COP0_SEL(perfcnt1, MIPS_COP_0_PERFCNT, 1); -MIPS_RDRW32_COP0_SEL(perfcnt2, MIPS_COP_0_PERFCNT, 2); -MIPS_RDRW32_COP0_SEL(perfcnt3, MIPS_COP_0_PERFCNT, 3); +MIPS_RW32_COP0_SEL(ebase, MIPS_COP_0_PRID, 1); +MIPS_RW32_COP0(watchlo, MIPS_COP_0_WATCH_LO); +MIPS_RW32_COP0_SEL(watchlo1, MIPS_COP_0_WATCH_LO, 1); +MIPS_RW32_COP0_SEL(watchlo2, MIPS_COP_0_WATCH_LO, 2); +MIPS_RW32_COP0_SEL(watchlo3, MIPS_COP_0_WATCH_LO, 3); +MIPS_RW32_COP0(watchhi, MIPS_COP_0_WATCH_HI); +MIPS_RW32_COP0_SEL(watchhi1, MIPS_COP_0_WATCH_HI, 1); +MIPS_RW32_COP0_SEL(watchhi2, MIPS_COP_0_WATCH_HI, 2); +MIPS_RW32_COP0_SEL(watchhi3, MIPS_COP_0_WATCH_HI, 3); + +MIPS_RW32_COP0_SEL(perfcnt0, MIPS_COP_0_PERFCNT, 0); +MIPS_RW32_COP0_SEL(perfcnt1, MIPS_COP_0_PERFCNT, 1); +MIPS_RW32_COP0_SEL(perfcnt2, MIPS_COP_0_PERFCNT, 2); +MIPS_RW32_COP0_SEL(perfcnt3, MIPS_COP_0_PERFCNT, 3); -#undef MIPS_RDRW32_COP0 +#undef MIPS_RW32_COP0 +#undef MIPS_RW32_COP0_SEL static __inline register_t intr_disable(void) From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 20:06:26 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6557E106564A; Tue, 4 Jan 2011 20:06:26 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 549F18FC14; Tue, 4 Jan 2011 20:06:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04K6QAU053346; Tue, 4 Jan 2011 20:06:26 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04K6Qwl053344; Tue, 4 Jan 2011 20:06:26 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201101042006.p04K6Qwl053344@svn.freebsd.org> From: Pyun YongHyeon Date: Tue, 4 Jan 2011 20:06:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216973 - head/sys/dev/bge X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 20:06:26 -0000 Author: yongari Date: Tue Jan 4 20:06:26 2011 New Revision: 216973 URL: http://svn.freebsd.org/changeset/base/216973 Log: Limit hardware bug workaround to controllers that have 4GB boundary bug instead of blindly applying it to all controllers. Pointed out by: marius MFC after: 3 days Modified: head/sys/dev/bge/if_bge.c Modified: head/sys/dev/bge/if_bge.c ============================================================================== --- head/sys/dev/bge/if_bge.c Tue Jan 4 19:32:03 2011 (r216972) +++ head/sys/dev/bge/if_bge.c Tue Jan 4 20:06:26 2011 (r216973) @@ -2482,8 +2482,11 @@ bge_dma_alloc(struct bge_softc *sc) * restriction and limit DMA address space to 32bit. It's not * clear whether there is another hardware issue here. */ + lowaddr = BUS_SPACE_MAXADDR; + if ((sc->bge_flags & BGE_FLAG_40BIT_BUG) != 0) + lowaddr = BUS_SPACE_MAXADDR_32BIT; error = bus_dma_tag_create(bus_get_dma_tag(sc->bge_dev), - 1, 0, BUS_SPACE_MAXADDR_32BIT, BUS_SPACE_MAXADDR, NULL, + 1, 0, lowaddr, BUS_SPACE_MAXADDR, NULL, NULL, BUS_SPACE_MAXSIZE_32BIT, 0, BUS_SPACE_MAXSIZE_32BIT, 0, NULL, NULL, &sc->bge_cdata.bge_buffer_tag); if (error != 0) { From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 20:26:41 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BC9851065670; Tue, 4 Jan 2011 20:26:41 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AC0C48FC0A; Tue, 4 Jan 2011 20:26:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04KQfYi053957; Tue, 4 Jan 2011 20:26:41 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04KQfV2053954; Tue, 4 Jan 2011 20:26:41 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201101042026.p04KQfV2053954@svn.freebsd.org> From: Dimitry Andric Date: Tue, 4 Jan 2011 20:26:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216975 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 20:26:41 -0000 Author: dim Date: Tue Jan 4 20:26:41 2011 New Revision: 216975 URL: http://svn.freebsd.org/changeset/base/216975 Log: Remove '-elf' from build flags for libexec/rtld-elf for amd64 and i386. ELF has been the default format for almost 12 years now. Modified: head/libexec/rtld-elf/amd64/Makefile.inc head/libexec/rtld-elf/i386/Makefile.inc Modified: head/libexec/rtld-elf/amd64/Makefile.inc ============================================================================== --- head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:15:16 2011 (r216974) +++ head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:26:41 2011 (r216975) @@ -1,7 +1,5 @@ # $FreeBSD$ -CFLAGS+= -elf -LDFLAGS+= -elf # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x Modified: head/libexec/rtld-elf/i386/Makefile.inc ============================================================================== --- head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:15:16 2011 (r216974) +++ head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:26:41 2011 (r216975) @@ -1,7 +1,5 @@ # $FreeBSD$ -CFLAGS+= -elf -LDFLAGS+= -elf # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 20:51:28 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E470D1065673; Tue, 4 Jan 2011 20:51:28 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D3AF18FC12; Tue, 4 Jan 2011 20:51:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04KpSYi054567; Tue, 4 Jan 2011 20:51:28 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04KpSGk054564; Tue, 4 Jan 2011 20:51:28 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201101042051.p04KpSGk054564@svn.freebsd.org> From: Dimitry Andric Date: Tue, 4 Jan 2011 20:51:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 20:51:29 -0000 Author: dim Date: Tue Jan 4 20:51:28 2011 New Revision: 216977 URL: http://svn.freebsd.org/changeset/base/216977 Log: On amd64 and i386, tell the compiler to refrain from generating SSE, 3DNow, MMX and floating point instructions in rtld-elf. Otherwise, _rtld_bind() (and whatever it calls) could possibly clobber function arguments that are passed in SSE/3DNow/MMX/FP registers, usually floating point values. This can happen, for example, when clang generates SSE code for memset() or memcpy() calls. One symptom of this is sshd dying early on amd64 with "PRNG not seeded", which is ultimately caused by libcrypto.so.6 calling RAND_add() with a double parameter. That parameter is passed via %xmm0, which gets wiped out by an SSE memset() in _rtld_bind(). Reviewed by: kib, kan Modified: head/libexec/rtld-elf/amd64/Makefile.inc head/libexec/rtld-elf/i386/Makefile.inc Modified: head/libexec/rtld-elf/amd64/Makefile.inc ============================================================================== --- head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:38:52 2011 (r216976) +++ head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:51:28 2011 (r216977) @@ -1,5 +1,6 @@ # $FreeBSD$ +CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x Modified: head/libexec/rtld-elf/i386/Makefile.inc ============================================================================== --- head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:38:52 2011 (r216976) +++ head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:51:28 2011 (r216977) @@ -1,5 +1,6 @@ # $FreeBSD$ +CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 20:56:23 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 912751065670; Tue, 4 Jan 2011 20:56:23 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail06.syd.optusnet.com.au (mail06.syd.optusnet.com.au [211.29.132.187]) by mx1.freebsd.org (Postfix) with ESMTP id 156308FC0A; Tue, 4 Jan 2011 20:56:22 +0000 (UTC) Received: from c122-106-165-206.carlnfd1.nsw.optusnet.com.au (c122-106-165-206.carlnfd1.nsw.optusnet.com.au [122.106.165.206]) by mail06.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p04KuJ8g015388 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 5 Jan 2011 07:56:20 +1100 Date: Wed, 5 Jan 2011 07:56:19 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Garrett Cooper In-Reply-To: <004687DF-47EF-4468-97DB-8443A249BE00@gmail.com> Message-ID: <20110105064831.B1008@besplex.bde.org> References: <201101041727.p04HRHZC048894@svn.freebsd.org> <201101041322.33071.jhb@freebsd.org> <004687DF-47EF-4468-97DB-8443A249BE00@gmail.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: src-committers@freebsd.org, John Baldwin , svn-src-all@freebsd.org, Garrett Cooper , Konstantin Belousov , svn-src-head@freebsd.org Subject: Re: svn commit: r216967 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 20:56:23 -0000 On Tue, 4 Jan 2011, Garrett Cooper wrote: > On Jan 4, 2011, at 10:22 AM, John Baldwin wrote: > >> On Tuesday, January 04, 2011 12:41:51 pm Garrett Cooper wrote: >>> On Tue, Jan 4, 2011 at 9:27 AM, Konstantin Belousov wrote: >>>> Author: kib >>>> Date: Tue Jan 4 17:27:17 2011 >>>> New Revision: 216967 >>>> URL: http://svn.freebsd.org/changeset/base/216967 >>>> >>>> Log: >>>> Use errx() instead of err() in parseint. There is usually no interesting >>>> information in errno. >>>> >>>> Noted by: Garrett Cooper >>>> MFC after: 1 week >>> >>> Someday it would be nice if we could have one standard / libraritized >>> set of functions that properly handle overflow and all that good stuff >>> (as bde has suggested to me elsewhere), but this is good enough for >>> today. >> >> strtonum(3)? > > bde said (back in 11/15): > > "It is good to fix the blind truncation, but overflow is never graceful. > > I will review the patch for errors like the ones in corresponding user > code (dd get_num(), strtonum(), expand_number()... get_num() is almost > OK, but the newer more public APIs are broken as designed)." > > So there's some concern that he has with those APIs still.. the > fact that I was trying to use a similar API to parse numbers in strings > in the kernel (strtoq in tunable work) didn't make things any better > unfortunately. Part of the brokenness is that strtonum() uses the long long abomination nstead of [u]intmax_t. humanize_number() and expand_number() also haven't caught up with C99 -- they use uint64_t. % Modified: head/usr.sbin/rtprio/rtprio.c % ============================================================================== % --- head/usr.sbin/rtprio/rtprio.c Tue Jan 4 17:18:53 2011 (r216966) % +++ head/usr.sbin/rtprio/rtprio.c Tue Jan 4 17:27:17 2011 (r216967) % @@ -133,9 +133,9 @@ parseint(const char *str, const char *er % errno = 0; % res = strtol(str, &endp, 10); % if (errno != 0 || endp == str || *endp != '\0') % - err(1, "%s must be a number", errname); % + errx(1, "%s must be a number", errname); % if (res >= INT_MAX) % - err(1, "Integer overflow parsing %s", errname); % + errx(1, "Integer overflow parsing %s", errname); % return (res); % } Unfortunately this has many of the common bugs for using the strto*() family: - although it carefully sets errno, it uses errno in a bad way. When strtol() sets ERANGE, this is misinterpreted as a generic error so the misleading message "%s must be a number" is printed for numbers that are out of range. The previous version was better since it also printed the strerror(ERANGE). OTOH, the other error (EINVAL) reported in errno is detected better by the checks on endp. errno being set to EINVAL is a POSIX mistake^Wextextension. Portable code still needs to use the endp checks. rtprio isn't portable but it shouldn't set a bad example. - the other part of the overflow checking is mostly wrong too: strtol() returns LONG_MAX for range errors, but also returns LONG_MIN for range errors; LONG_MAX may or may not exceed INT_MAX; on 32-bit arches it happens to equal INT_MAX. So: (a) overflow of negative values is not detected. Except, all cases of overflow are detected by the generic check on errno and misreported. (b) when LONG_MAX exceeds INT_MAX, there is no problem (yet) when res exceed INT_MAX since although there is no overflow yet, there would be when parseint() returns int. When res equals INT_MAX, there is an off-by-1 error -- a non-overflow case is misreported as overflow. This is almost harmless since a value of INT_MAX is out of range for a pid. The error message is just slightly misleading -- the value is too large, although not overflow. (c) when LONG_MAX equals INT_MAX, res cannot INT_MAX. No problem when the infinite-precision value exceeds INT_MAX (this is overflow). When res equals INT_MAX, there may or may not be overflow. Both cases are reported as overflow. This is mostly harmless, as in (b). (d) Overflow may occur immediately when parseint() returns, since its value is stored in a pid_t with no further checks. pid_t happens to have type int on all supported arches, so there is no problem in practice. (e) Negative values for the pid are not errors, but have a special meaning. The code for handling negative values is laborious and has at least the following bugs: (i) proc = abs(proc) overflows on all supported arches when proc = INT_MIN (ii) only leading '-' signs are detected by the ad hoc parsing. strtol() will find '-' signs after leading whitespace. Thus negative pids may reach the kernel. (iii) isdigit() is applied to a value that may be negative. As a result of these bugs, the rtprio passed to the kernel can be way out of the valid range [0..31]. Hopefully the kernel knows how to check ranges so the result is just late detection of the invalid option with an error message less specific than it could be. I get "rtprio: rtprio: No such process" for "rtprio 22 -33333333" with an old version of rtprio(1) using atoi(). Similarly with enough more 3's to overflow to LONG_MIN. Bit with 21 3's, the error changes to the weird "No such file or directory". Summary: all the strto*() interfaces are too hard to use. When fixing use of atoi(), you want to be able to use the same API (maybe s/atoi/xatoi/, where xatoi exits on error) and not have to write a buggy parse for each case or even change to a more complicated API like strtonum(). Here the change from atoi() seems to only gain detection of garbage input like "1garbage". Even using atoi(), most programs need range checking that has nothing to do with INT_MAX. Bruce From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 21:00:07 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8A51F1065695; Tue, 4 Jan 2011 21:00:07 +0000 (UTC) (envelope-from swell.k@gmail.com) Received: from mail-fx0-f54.google.com (mail-fx0-f54.google.com [209.85.161.54]) by mx1.freebsd.org (Postfix) with ESMTP id AC1D38FC0A; Tue, 4 Jan 2011 21:00:06 +0000 (UTC) Received: by fxm16 with SMTP id 16so14330604fxm.13 for ; Tue, 04 Jan 2011 13:00:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:references :date:in-reply-to:message-id:user-agent:mime-version:content-type; bh=0vAN++MJwrpmiNOgL/003GLFKWWfnshKHlZJ63vB+D4=; b=ArKESq4kDX3yEyWxMKIFk5id0rk5hRyUqI8+fym4vrZjwcsbzLf9ylyswquvWwtdhw I0bp0lSd6gEY7/3uB8L0sYiRvBT39wSRl5GgJrS3HGwx7sYvcn99CxVmbVC0fPWixWPc gMnjEouS7AJMoIY3LLU8HEw984fNjvZN81aqA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; b=urEjE8iWzs7NRc4BrARKDC8PjujK9O8mproail26j8ZKjV5I8NiS/yQ9KDhDEbZsf1 KTQGeeAzyaqffa49kpdCDG2l17/WpZS3WrnFknAPYgifvDuIyjXZYbn5x/UFA1eBrYU9 ONhCBZufKUCJTEuTufQNJmfLSJddkVGtyzzfg= Received: by 10.223.78.138 with SMTP id l10mr1576640fak.17.1294174803721; Tue, 04 Jan 2011 13:00:03 -0800 (PST) Received: from localhost ([95.143.193.145]) by mx.google.com with ESMTPS id n1sm5268198fam.40.2011.01.04.12.59.57 (version=SSLv3 cipher=RC4-MD5); Tue, 04 Jan 2011 13:00:01 -0800 (PST) From: Anonymous To: Dimitry Andric References: <201101042026.p04KQfV2053954__34106.6334084191$1294172817$gmane$org@svn.freebsd.org> Date: Tue, 04 Jan 2011 23:59:30 +0300 In-Reply-To: <201101042026.p04KQfV2053954__34106.6334084191$1294172817$gmane$org@svn.freebsd.org> (Dimitry Andric's message of "Tue, 4 Jan 2011 20:26:41 +0000 (UTC)") Message-ID: <8639p8tmfh.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216975 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 21:00:07 -0000 Dimitry Andric writes: > Author: dim > Date: Tue Jan 4 20:26:41 2011 > New Revision: 216975 > URL: http://svn.freebsd.org/changeset/base/216975 > > Log: > Remove '-elf' from build flags for libexec/rtld-elf for amd64 and i386. > ELF has been the default format for almost 12 years now. '-elf' is not documented in either gcc(1) or ld(1). Did it work? From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 21:42:28 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 084451065674; Tue, 4 Jan 2011 21:42:28 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id BC77D8FC19; Tue, 4 Jan 2011 21:42:27 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:6585:4c82:cc96:98f0] (unknown [IPv6:2001:7b8:3a7:0:6585:4c82:cc96:98f0]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id F40855C5A; Tue, 4 Jan 2011 22:42:26 +0100 (CET) Message-ID: <4D23943D.2080808@FreeBSD.org> Date: Tue, 04 Jan 2011 22:42:21 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.14pre) Gecko/20110104 Lanikai/3.1.8pre MIME-Version: 1.0 To: Anonymous References: <201101042026.p04KQfV2053954__34106.6334084191$1294172817$gmane$org@svn.freebsd.org> <8639p8tmfh.fsf@gmail.com> In-Reply-To: <8639p8tmfh.fsf@gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216975 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 21:42:28 -0000 On 2011-01-04 21:59, Anonymous wrote: > '-elf' is not documented in either gcc(1) or ld(1). Did it work? It was a custom gcc option, but it was removed about 8 years ago: http://svn.freebsd.org/changeset/base/107286 From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 22:56:18 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C8792106566C; Tue, 4 Jan 2011 22:56:18 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B6FC78FC0A; Tue, 4 Jan 2011 22:56:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04MuIRv057619; Tue, 4 Jan 2011 22:56:18 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04MuISM057617; Tue, 4 Jan 2011 22:56:18 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201101042256.p04MuISM057617@svn.freebsd.org> From: Gavin Atkinson Date: Tue, 4 Jan 2011 22:56:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216982 - head/share/misc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 22:56:19 -0000 Author: gavin Date: Tue Jan 4 22:56:18 2011 New Revision: 216982 URL: http://svn.freebsd.org/changeset/base/216982 Log: Update committers-doc.dot, noving doc committer alumni into the alumni section and recording the date these commit bits were returned. Also, sort the remaining entries, and add a node for mheinen, who is already referenced within the mentor relationships. Other doc committers are encouraged to add themselves, and any mentor/mentee relationships. The current rendered output is available at http://people.freebsd.org/~gavin/comm-doc.png Modified: head/share/misc/committers-doc.dot Modified: head/share/misc/committers-doc.dot ============================================================================== --- head/share/misc/committers-doc.dot Tue Jan 4 22:50:28 2011 (r216981) +++ head/share/misc/committers-doc.dot Tue Jan 4 22:56:18 2011 (r216982) @@ -29,44 +29,46 @@ node [color=grey62, style=filled, bgcolo # Alumni go here. Try to keep things sorted. +ache [label="Andrey Chernov\nache@FreeBSD.org\n1997/06/13\n2010/12/11"] +bmah [label="Bruce A. Mah\nbmah@FreeBSD.org\n2000/08/22\n2009/09/13"] +bvs [label="Vitaly Bogdanov\nbvs@FreeBSD.org\n2005/10/03\n2010/12/11"] +den [label="Denis Peplin\nden@FreeBSD.org\n2003/09/13\n2009/07/09"] +garys [label="Gary W. Swearingen\ngarys@FreeBSD.org\n2005/08/21\n2008/03/02"] +jcamou [label="Jesus R. Camou\njcamou@FreeBSD.org\n2005/03/02\n2008/12/20"] +jesusr [label="Jesus Rodriguez Cuesta\njesusr@FreeBSD.org\n1998/12/10\n2010/12/11"] +jim [label="Jim Mock\njim@FreeBSD.org\n1999/08/11\n2003/12/15"] +josef [label="Josef El-Rayes\njosef@FreeBSD.org\n2004/01/15\n2008/03/29"] +mheinen [label="Martin Heinen\nmheinen@FreeBSD.org\n2002/10/04\n2006/04/26"] +nik [label="Nik Clayton\nnik@FreeBSD.org\n1998/02/26\n2008/12/20"] +pgj [label="Gabor Pali\npgj@FreeBSD.org\n2008/04/21\n2010/12/01"] + node [color=lightblue2, style=filled, bgcolor=black]; # Current doc committers go here. Try to keep things sorted. -ache [label="Andrey Chernov\nache@FreeBSD.org\n1997/06/13"] ale [label="Alex Dupre\nale@FreeBSD.org\n2003/12/22"] bcr [label="Benedict Reuschling\nbcr@FreeBSD.org\n2009/12/24"] blackend [label="Marc Fonvieille\nblackend@FreeBSD.org\n2002/06/16"] -bmah [label="Bruce A. Mah\nbmah@FreeBSD.org\n2000/08/22"] brd [label="Brad Davis\nbrd@FreeBSD.org\n2005/06/01"] brueffer [label="Christian Brueffer\nbrueffer@FreeBSD.org\n2003/01/13"] -bvs [label="Vitaly Bogdanov\nbvs@FreeBSD.org\n2005/10/03"] ceri [label="Ceri Davies\nceri@FreeBSD.org\n2002/03/17"] chinsan [label="Chinsan Huang\nchinsan@FreeBSD.org\n2006/09/20"] danger [label="Daniel Gerzo\ndanger@FreeBSD.org\n2006/08/20"] -den [label="Denis Peplin\nden@FreeBSD.org\n2003/09/13"] delphij [label="Xin Li\ndelphij@FreeBSD.org\n2004/09/14"] gabor [label="Gabor Kovesdan\ngabor@FreeBSD.org\n2007/02/02"] ganbold [label="Ganbold Tsagaankhuu\nganbold@FreeBSD.org\n2008/02/26"] -garys [label="Gary W. Swearingen\ngarys@FreeBSD.org\n2005/08/21"] -jcamou [label="Jesus R. Camou\njcamou@FreeBSD.org\n2005/03/02"] -jesusr [label="Jesus Rodriguez Cuesta\njesusr@FreeBSD.org\n1998/12/10"] -jim [label="Jim Mock\njim@FreeBSD.org\n1999/08/11\n2003/12/15"] jkois [label="Johann Kois\njkois@FreeBSD.org\n2004/11/11"] joel [label="Joel Dahl\njoel@FreeBSD.org\n2005/04/05"] -josef [label="Josef El-Rayes\njosef@FreeBSD.org\n2004/01/15"] keramida [label="Giorgos Keramidas\nkeramida@FreeBSD.org\n2001/10/12"] -loader [label="Fukang Chen\nloader@FreeBSD.org\n2007/07/30"] linimon [label="Mark Linimon\nlinimon@FreeBSD.org\n2004/03/31"] +loader [label="Fukang Chen\nloader@FreeBSD.org\n2007/07/30"] manolis [label="Manolis Kiagias\nmanolis@FreeBSD.org\n2008/05/24"] marcel [label="Marcel Moolenaar\nmarcel@FreeBSD.org\n1999/07/03"] marck [label="Dmitry Morozovsky\nmarck@FreeBSD.org\n2004/08/10"] maxim [label="Maxim Konovalov\nmaxim@FreeBSD.org\n2002/02/07"] miwi [label="Martin Wilke\nmiwi@FreeBSD.org\n2007/10/26"] murray [label="Murray Stokely\nmurray@FreeBSD.org\n2000/04/05"] -nik [label="Nik Clayton\nnik@FreeBSD.org\n1998/02/26"] pav [label="Pav Lucistnik\npav@FreeBSD.org\n2005/08/12"] -pgj [label="Gabor Pali\npgj@FreeBSD.org\n2008/04/21"] remko [label="Remko Lodder\nremko@FreeBSD.org\n2004/10/16"] rene [label="Rene Ladan\nrene@FreeBSD.org\n2008/11/03"] roam [label="Peter Pentchev\nroam@FreeBSD.org\n2003/02/14"] From owner-svn-src-head@FreeBSD.ORG Tue Jan 4 23:00:54 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D448C1065672; Tue, 4 Jan 2011 23:00:54 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C3C178FC12; Tue, 4 Jan 2011 23:00:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04N0sSL057768; Tue, 4 Jan 2011 23:00:54 GMT (envelope-from jpaetzel@svn.freebsd.org) Received: (from jpaetzel@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04N0s7e057766; Tue, 4 Jan 2011 23:00:54 GMT (envelope-from jpaetzel@svn.freebsd.org) Message-Id: <201101042300.p04N0s7e057766@svn.freebsd.org> From: Josh Paetzel Date: Tue, 4 Jan 2011 23:00:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216983 - head/etc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 23:00:54 -0000 Author: jpaetzel (ports committer) Date: Tue Jan 4 23:00:54 2011 New Revision: 216983 URL: http://svn.freebsd.org/changeset/base/216983 Log: Fix typo in default config file. Approved by: Warner Losh MFC after: 3 days Modified: head/etc/devd.conf Modified: head/etc/devd.conf ============================================================================== --- head/etc/devd.conf Tue Jan 4 22:56:18 2011 (r216982) +++ head/etc/devd.conf Tue Jan 4 23:00:54 2011 (r216983) @@ -45,7 +45,7 @@ notify 0 { # # Try to start dhclient on Ethernet like interfaces when the link comes # up. Only devices that are configured to support DHCP will actually -# run it. No link down rule exists because dhclient automaticly exits +# run it. No link down rule exists because dhclient automatically exits # when the link goes down. # notify 0 { From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 01:16:35 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id A48331065672; Wed, 5 Jan 2011 01:16:35 +0000 (UTC) Date: Wed, 5 Jan 2011 01:16:35 +0000 From: Alexander Best To: Dimitry Andric Message-ID: <20110105011635.GA4952@freebsd.org> References: <201101042051.p04KpSGk054564@svn.freebsd.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="YiEDa0DAkWCtVeE4" Content-Disposition: inline In-Reply-To: <201101042051.p04KpSGk054564@svn.freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 01:16:35 -0000 --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue Jan 4 11, Dimitry Andric wrote: > Author: dim > Date: Tue Jan 4 20:51:28 2011 > New Revision: 216977 > URL: http://svn.freebsd.org/changeset/base/216977 > > Log: > On amd64 and i386, tell the compiler to refrain from generating SSE, > 3DNow, MMX and floating point instructions in rtld-elf. > > Otherwise, _rtld_bind() (and whatever it calls) could possibly clobber > function arguments that are passed in SSE/3DNow/MMX/FP registers, > usually floating point values. This can happen, for example, when clang > generates SSE code for memset() or memcpy() calls. the sorting order for these flags seems to be: -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay consistent? also what's the status of clang? will these flags make sure that newer cpu extension won't be activated? i checked contrib/llvm/tools/clang/include/clang/Driver/Options.td and clang has support for: -m3dnowa -mssse3 -msse4a -msse4 -msse4_1 -msse4_2 -maes -mavx since these extensions only get set in a hand full of files maybe special cases for CC == clang can be added. also maybe you could have a look at the attached patch. i sent this to hackers@ and nobody objected, but nobody wanted to commit the patch unfortunately. cheers. alex > > One symptom of this is sshd dying early on amd64 with "PRNG not seeded", > which is ultimately caused by libcrypto.so.6 calling RAND_add() with a > double parameter. That parameter is passed via %xmm0, which gets wiped > out by an SSE memset() in _rtld_bind(). > > Reviewed by: kib, kan > > Modified: > head/libexec/rtld-elf/amd64/Makefile.inc > head/libexec/rtld-elf/i386/Makefile.inc > > Modified: head/libexec/rtld-elf/amd64/Makefile.inc > ============================================================================== > --- head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:38:52 2011 (r216976) > +++ head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:51:28 2011 (r216977) > @@ -1,5 +1,6 @@ > # $FreeBSD$ > > +CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float > # Uncomment this to build the dynamic linker as an executable instead > # of a shared library: > #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x > > Modified: head/libexec/rtld-elf/i386/Makefile.inc > ============================================================================== > --- head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:38:52 2011 (r216976) > +++ head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:51:28 2011 (r216977) > @@ -1,5 +1,6 @@ > # $FreeBSD$ > > +CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float > # Uncomment this to build the dynamic linker as an executable instead > # of a shared library: > #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x -- a13x --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="sse2.diff" diff --git a/sys/boot/i386/boot2/Makefile b/sys/boot/i386/boot2/Makefile index b91a43b..39ef619 100644 --- a/sys/boot/i386/boot2/Makefile +++ b/sys/boot/i386/boot2/Makefile @@ -3,7 +3,7 @@ .include # XXX: clang can compile the boot code just fine, but boot2 gets too big -CC:=${CC:C/^(.*\/)?clang$/gcc/1} +#CC:=${CC:C/^(.*\/)?clang$/gcc/1} FILES= boot boot1 boot2 @@ -31,7 +31,6 @@ CFLAGS= -Os \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -D${BOOT2_UFS} \ -DFLAGS=${BOOT_BOOT1_FLAGS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ diff --git a/sys/boot/i386/gptboot/Makefile b/sys/boot/i386/gptboot/Makefile index a0fad61..452b100 100644 --- a/sys/boot/i386/gptboot/Makefile +++ b/sys/boot/i386/gptboot/Makefile @@ -26,7 +26,6 @@ CFLAGS= -DBOOTPROG=\"gptboot\" \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DGPT \ -D${GPTBOOT_UFS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ diff --git a/sys/boot/i386/gptzfsboot/Makefile b/sys/boot/i386/gptzfsboot/Makefile index 30a5fc7..7f5f287 100644 --- a/sys/boot/i386/gptzfsboot/Makefile +++ b/sys/boot/i386/gptzfsboot/Makefile @@ -23,7 +23,6 @@ CFLAGS= -DBOOTPROG=\"gptzfsboot\" \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DGPT -DBOOT2 \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ -DSIOFMT=${B2SIOFMT} \ diff --git a/sys/boot/i386/zfsboot/Makefile b/sys/boot/i386/zfsboot/Makefile index 10616e4..38e8a9f 100644 --- a/sys/boot/i386/zfsboot/Makefile +++ b/sys/boot/i386/zfsboot/Makefile @@ -24,7 +24,6 @@ CFLAGS= -DBOOTPROG=\"zfsboot\" \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DBOOT2 \ -DFLAGS=${BOOT_BOOT1_FLAGS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ diff --git a/sys/boot/pc98/boot2/Makefile b/sys/boot/pc98/boot2/Makefile index dfd8607..035b5dd 100644 --- a/sys/boot/pc98/boot2/Makefile +++ b/sys/boot/pc98/boot2/Makefile @@ -28,7 +28,6 @@ CFLAGS= -Os \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -D${BOOT2_UFS} \ -DFLAGS=${BOOT_BOOT1_FLAGS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ --YiEDa0DAkWCtVeE4-- From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 03:52:43 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 1235A106566C; Wed, 5 Jan 2011 03:52:43 +0000 (UTC) Date: Wed, 5 Jan 2011 03:52:43 +0000 From: Alexander Best To: Dimitry Andric Message-ID: <20110105035243.GA24903@freebsd.org> References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110105011635.GA4952@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 03:52:43 -0000 On Wed Jan 5 11, Alexander Best wrote: > On Tue Jan 4 11, Dimitry Andric wrote: > > Author: dim > > Date: Tue Jan 4 20:51:28 2011 > > New Revision: 216977 > > URL: http://svn.freebsd.org/changeset/base/216977 > > > > Log: > > On amd64 and i386, tell the compiler to refrain from generating SSE, > > 3DNow, MMX and floating point instructions in rtld-elf. > > > > Otherwise, _rtld_bind() (and whatever it calls) could possibly clobber > > function arguments that are passed in SSE/3DNow/MMX/FP registers, > > usually floating point values. This can happen, for example, when clang > > generates SSE code for memset() or memcpy() calls. > > the sorting order for these flags seems to be: > > -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > > see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay > consistent? > > also what's the status of clang? will these flags make sure that newer > cpu extension won't be activated? i checked > contrib/llvm/tools/clang/include/clang/Driver/Options.td > and clang has support for: > > -m3dnowa > -mssse3 > -msse4a > -msse4 > -msse4_1 > -msse4_2 > -maes > -mavx > > since these extensions only get set in a hand full of files maybe special > cases for CC == clang can be added. > > also maybe you could have a look at the attached patch. i sent this to hackers@ > and nobody objected, but nobody wanted to commit the patch unfortunately. > > cheers. > alex > > > > > One symptom of this is sshd dying early on amd64 with "PRNG not seeded", > > which is ultimately caused by libcrypto.so.6 calling RAND_add() with a > > double parameter. That parameter is passed via %xmm0, which gets wiped > > out by an SSE memset() in _rtld_bind(). > > > > Reviewed by: kib, kan > > > > Modified: > > head/libexec/rtld-elf/amd64/Makefile.inc > > head/libexec/rtld-elf/i386/Makefile.inc > > > > Modified: head/libexec/rtld-elf/amd64/Makefile.inc > > ============================================================================== > > --- head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:38:52 2011 (r216976) > > +++ head/libexec/rtld-elf/amd64/Makefile.inc Tue Jan 4 20:51:28 2011 (r216977) > > @@ -1,5 +1,6 @@ > > # $FreeBSD$ > > > > +CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float > > # Uncomment this to build the dynamic linker as an executable instead > > # of a shared library: > > #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x > > > > Modified: head/libexec/rtld-elf/i386/Makefile.inc > > ============================================================================== > > --- head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:38:52 2011 (r216976) > > +++ head/libexec/rtld-elf/i386/Makefile.inc Tue Jan 4 20:51:28 2011 (r216977) > > @@ -1,5 +1,6 @@ > > # $FreeBSD$ > > > > +CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float > > # Uncomment this to build the dynamic linker as an executable instead > > # of a shared library: > > #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x > > -- > a13x > diff --git a/sys/boot/i386/boot2/Makefile b/sys/boot/i386/boot2/Makefile > index b91a43b..39ef619 100644 > --- a/sys/boot/i386/boot2/Makefile > +++ b/sys/boot/i386/boot2/Makefile > @@ -3,7 +3,7 @@ > .include > > # XXX: clang can compile the boot code just fine, but boot2 gets too big > -CC:=${CC:C/^(.*\/)?clang$/gcc/1} > +#CC:=${CC:C/^(.*\/)?clang$/gcc/1} ^^ sorry. that was a leftover from some hacking i did. > > FILES= boot boot1 boot2 > > @@ -31,7 +31,6 @@ CFLAGS= -Os \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -D${BOOT2_UFS} \ > -DFLAGS=${BOOT_BOOT1_FLAGS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > diff --git a/sys/boot/i386/gptboot/Makefile b/sys/boot/i386/gptboot/Makefile > index a0fad61..452b100 100644 > --- a/sys/boot/i386/gptboot/Makefile > +++ b/sys/boot/i386/gptboot/Makefile > @@ -26,7 +26,6 @@ CFLAGS= -DBOOTPROG=\"gptboot\" \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -DGPT \ > -D${GPTBOOT_UFS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > diff --git a/sys/boot/i386/gptzfsboot/Makefile b/sys/boot/i386/gptzfsboot/Makefile > index 30a5fc7..7f5f287 100644 > --- a/sys/boot/i386/gptzfsboot/Makefile > +++ b/sys/boot/i386/gptzfsboot/Makefile > @@ -23,7 +23,6 @@ CFLAGS= -DBOOTPROG=\"gptzfsboot\" \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -DGPT -DBOOT2 \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > -DSIOFMT=${B2SIOFMT} \ > diff --git a/sys/boot/i386/zfsboot/Makefile b/sys/boot/i386/zfsboot/Makefile > index 10616e4..38e8a9f 100644 > --- a/sys/boot/i386/zfsboot/Makefile > +++ b/sys/boot/i386/zfsboot/Makefile > @@ -24,7 +24,6 @@ CFLAGS= -DBOOTPROG=\"zfsboot\" \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -DBOOT2 \ > -DFLAGS=${BOOT_BOOT1_FLAGS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > diff --git a/sys/boot/pc98/boot2/Makefile b/sys/boot/pc98/boot2/Makefile > index dfd8607..035b5dd 100644 > --- a/sys/boot/pc98/boot2/Makefile > +++ b/sys/boot/pc98/boot2/Makefile > @@ -28,7 +28,6 @@ CFLAGS= -Os \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -D${BOOT2_UFS} \ > -DFLAGS=${BOOT_BOOT1_FLAGS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ -- a13x From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 09:43:04 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 717AB106564A; Wed, 5 Jan 2011 09:43:04 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 608538FC12; Wed, 5 Jan 2011 09:43:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p059h4Vi071758; Wed, 5 Jan 2011 09:43:04 GMT (envelope-from keramida@svn.freebsd.org) Received: (from keramida@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p059h4k8071756; Wed, 5 Jan 2011 09:43:04 GMT (envelope-from keramida@svn.freebsd.org) Message-Id: <201101050943.p059h4k8071756@svn.freebsd.org> From: Giorgos Keramidas Date: Wed, 5 Jan 2011 09:43:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216986 - head/share/misc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 09:43:04 -0000 Author: keramida (doc committer) Date: Wed Jan 5 09:43:04 2011 New Revision: 216986 URL: http://svn.freebsd.org/changeset/base/216986 Log: Add gjb to the doc committer graph, as my current mentee. Modified: head/share/misc/committers-doc.dot Modified: head/share/misc/committers-doc.dot ============================================================================== --- head/share/misc/committers-doc.dot Wed Jan 5 01:07:32 2011 (r216985) +++ head/share/misc/committers-doc.dot Wed Jan 5 09:43:04 2011 (r216986) @@ -57,6 +57,8 @@ danger [label="Daniel Gerzo\ndanger@Free delphij [label="Xin Li\ndelphij@FreeBSD.org\n2004/09/14"] gabor [label="Gabor Kovesdan\ngabor@FreeBSD.org\n2007/02/02"] ganbold [label="Ganbold Tsagaankhuu\nganbold@FreeBSD.org\n2008/02/26"] +gjb [label="Glen Barber\ngjb@FreeBSD.org\n2010/09/01"] + jkois [label="Johann Kois\njkois@FreeBSD.org\n2004/11/11"] joel [label="Joel Dahl\njoel@FreeBSD.org\n2005/04/05"] keramida [label="Giorgos Keramidas\nkeramida@FreeBSD.org\n2001/10/12"] @@ -111,6 +113,7 @@ keramida -> danger keramida -> gabor keramida -> ganbold keramida -> garys +keramida -> gjb keramida -> pav marck -> bvs From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 09:45:20 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6284F10656C4; Wed, 5 Jan 2011 09:45:20 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 51D398FC16; Wed, 5 Jan 2011 09:45:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p059jK0T071866; Wed, 5 Jan 2011 09:45:20 GMT (envelope-from keramida@svn.freebsd.org) Received: (from keramida@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p059jKQw071864; Wed, 5 Jan 2011 09:45:20 GMT (envelope-from keramida@svn.freebsd.org) Message-Id: <201101050945.p059jKQw071864@svn.freebsd.org> From: Giorgos Keramidas Date: Wed, 5 Jan 2011 09:45:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216987 - head/share/misc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 09:45:20 -0000 Author: keramida (doc committer) Date: Wed Jan 5 09:45:20 2011 New Revision: 216987 URL: http://svn.freebsd.org/changeset/base/216987 Log: Glen Barber is co-mentored by me and jkois, so add another relationship edge to the committer graph to show this. Modified: head/share/misc/committers-doc.dot Modified: head/share/misc/committers-doc.dot ============================================================================== --- head/share/misc/committers-doc.dot Wed Jan 5 09:43:04 2011 (r216986) +++ head/share/misc/committers-doc.dot Wed Jan 5 09:45:20 2011 (r216987) @@ -107,6 +107,7 @@ jim -> trhodes jkois -> miwi jkois -> bcr +jkois -> gjb keramida -> blackend keramida -> danger From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 09:58:41 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 802C8106564A; Wed, 5 Jan 2011 09:58:41 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 54D568FC12; Wed, 5 Jan 2011 09:58:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p059wf0l072210; Wed, 5 Jan 2011 09:58:41 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p059wfTN072208; Wed, 5 Jan 2011 09:58:41 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201101050958.p059wfTN072208@svn.freebsd.org> From: Edward Tomasz Napierala Date: Wed, 5 Jan 2011 09:58:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216988 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 09:58:41 -0000 Author: trasz Date: Wed Jan 5 09:58:41 2011 New Revision: 216988 URL: http://svn.freebsd.org/changeset/base/216988 Log: Fix page fault that occurred when trying to initialize preloaded kernel module, the dependency of which was preloaded, but failed to initialize. Previously, kernel dereferenced NULL pointer returned by modlist_lookup2(); now, when this happens, we unload the dependent module. Since the depended_files list is sorted in dependency order, this properly propagates, unloading modules that depend on failed ones. From the user point of view, this prevents the kernel from panicing when trying to boot kernel compiled without KDTRACE_HOOKS with dtraceall_load="YES" in /boot/loader.conf. Reviewed by: kib Modified: head/sys/kern/kern_linker.c Modified: head/sys/kern/kern_linker.c ============================================================================== --- head/sys/kern/kern_linker.c Wed Jan 5 09:45:20 2011 (r216987) +++ head/sys/kern/kern_linker.c Wed Jan 5 09:58:41 2011 (r216988) @@ -1584,6 +1584,12 @@ restart: modname = mp->md_cval; verinfo = mp->md_data; mod = modlist_lookup2(modname, verinfo); + if (mod == NULL) { + printf("KLD file %s - cannot find " + "dependency \"%s\"\n", + lf->filename, modname); + goto fail; + } /* Don't count self-dependencies */ if (lf == mod->container) continue; @@ -1600,11 +1606,9 @@ restart: */ error = LINKER_LINK_PRELOAD_FINISH(lf); if (error) { - TAILQ_REMOVE(&depended_files, lf, loaded); printf("KLD file %s - could not finalize loading\n", lf->filename); - linker_file_unload(lf, LINKER_UNLOAD_FORCE); - continue; + goto fail; } linker_file_register_modules(lf); if (linker_file_lookup_set(lf, "sysinit_set", &si_start, @@ -1612,6 +1616,10 @@ restart: sysinit_add(si_start, si_stop); linker_file_register_sysctls(lf); lf->flags |= LINKER_FILE_LINKED; + continue; +fail: + TAILQ_REMOVE(&depended_files, lf, loaded); + linker_file_unload(lf, LINKER_UNLOAD_FORCE); } /* woohoo! we made it! */ } From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 11:49:23 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7799F106566B; Wed, 5 Jan 2011 11:49:23 +0000 (UTC) (envelope-from lstewart@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 653D88FC0A; Wed, 5 Jan 2011 11:49:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05BnNwS076838; Wed, 5 Jan 2011 11:49:23 GMT (envelope-from lstewart@svn.freebsd.org) Received: (from lstewart@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05BnNic076835; Wed, 5 Jan 2011 11:49:23 GMT (envelope-from lstewart@svn.freebsd.org) Message-Id: <201101051149.p05BnNic076835@svn.freebsd.org> From: Lawrence Stewart Date: Wed, 5 Jan 2011 11:49:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216995 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 11:49:23 -0000 Author: lstewart Date: Wed Jan 5 11:49:23 2011 New Revision: 216995 URL: http://svn.freebsd.org/changeset/base/216995 Log: Add a man page for the Object Specific Data (OSD) KPI. Although not directly related the FreeBSD Foundation funded "Five New TCP Congestion Control Algorithms for FreeBSD" project, the understanding and inspiration required to write this documentation was significantly bolstered by the Foundation's support. Reviewed by: pjd MFC after: 1 week Added: head/share/man/man9/osd.9 (contents, props changed) Modified: head/share/man/man9/Makefile Modified: head/share/man/man9/Makefile ============================================================================== --- head/share/man/man9/Makefile Wed Jan 5 11:46:18 2011 (r216994) +++ head/share/man/man9/Makefile Wed Jan 5 11:49:23 2011 (r216995) @@ -173,6 +173,7 @@ MAN= accept_filter.9 \ mutex.9 \ namei.9 \ netisr.9 \ + osd.9 \ panic.9 \ pbuf.9 \ p_candebug.9 \ Added: head/share/man/man9/osd.9 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/share/man/man9/osd.9 Wed Jan 5 11:49:23 2011 (r216995) @@ -0,0 +1,390 @@ +.\" +.\" Copyright (c) 2010 Lawrence Stewart +.\" 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, +.\" without modification, immediately at the beginning of the file. +.\" 2. The name of the author may not be used to endorse or promote products +.\" derived from this software without specific prior written permission. +.\" +.\" 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$ +.\" +.Dd January 5, 2011 +.Dt OSD 9 +.Os +.Sh NAME +.Nm osd , +.Nm osd_register , +.Nm osd_deregister , +.Nm osd_set , +.Nm osd_get , +.Nm osd_del, +.Nm osd_call , +.Nm osd_exit +.Nd Object Specific Data +.Sh SYNOPSIS +.In sys/osd.h +.Ft typedef void +.Fn "\*(lp*osd_destructor_t\*(rp" "void *value" +.Ft typedef int +.Fn "\*(lp*osd_method_t\*(rp" "void *obj" "void *data" +.Ft int +.Fo osd_register +.Fa "u_int type" +.Fa "osd_destructor_t destructor" +.Fa "osd_method_t *methods" +.Fc +.Ft void +.Fo osd_deregister +.Fa "u_int type" +.Fa "u_int slot" +.Fc +.Ft int +.Fo osd_set +.Fa "u_int type" +.Fa "struct osd *osd" +.Fa "u_int slot" +.Fa "void *value" +.Fc +.Ft void * +.Fo osd_get +.Fa "u_int type" +.Fa "struct osd *osd" +.Fa "u_int slot" +.Fc +.Ft void +.Fo osd_del +.Fa "u_int type" +.Fa "struct osd *osd" +.Fa "u_int slot" +.Fc +.Ft int +.Fo osd_call +.Fa "u_int type" +.Fa "u_int method" +.Fa "void *obj" +.Fa "void *data" +.Fc +.Ft void +.Fo osd_exit +.Fa "u_int type" +.Fa "struct osd *osd" +.Fc +.Sh DESCRIPTION +The +.Nm +framework provides a mechanism to dynamically associate arbitrary data at +run-time with any kernel data structure which has been suitably modified for use +with +.Nm . +The one-off modification required involves embedding a +.Vt "struct osd" +inside the kernel data structure. +.Pp +An additional benefit is that after the initial change to a structure is made, +all subsequent use of +.Nm +with the structure involves no changes to the structure's layout. +By extension, if the data structure is part of the ABI, +.Nm +provides a way of extending the structure in an ABI preserving manner. +.Pp +The details of the embedded +.Vt "struct osd" +are not relevant to consumers of the +.Nm +framework and should not be manipulated directly. +.Pp +Data associated with a structure is referenced by the +.Nm +framework using a type/slot identifier pair. +Types are statically defined in +.In sys/osd.h +and provide a high-level grouping for slots to be registered under. +Slot identifiers are dynamically assigned by the framework when a data type is +registered using +.Fn osd_register +and remains valid until a corresponding call to +.Fn osd_deregister . +.Ss Functions +The +.Fn osd_register +function registers a type/slot identifier pair with the +.Nm +framework for use with a new data type. +The function may sleep and therefore cannot be called from a non-sleepable +context. +The +.Fa type +argument specifies which high-level type grouping from +.In sys/osd.h +the slot identifier should be allocated under. +The +.Fa destructor +argument specifies an optional osd_destructor_t function pointer that will be +called for objects of the type being registered which are later destroyed by the +.Fn osd_del +function. +NULL may be passed if no destructor is required. +The +.Fa methods +argument specifies an optional array of osd_method_t function pointers which +can be later invoked by the +.Fn osd_call +function. +NULL may be passed if no methods are required. +The +.Fa methods +argument is currently only useful with the OSD_JAIL type identifier. +.Pp +The +.Fn osd_deregister +function deregisters a previously registered type/slot identifier pair. +The function may sleep and therefore cannot be called from a non-sleepable +context. +The +.Fa type +argument specifies which high-level type grouping from +.In sys/osd.h +the slot identifier is allocated under. +The +.Fa slot +argument specifies the slot identifier which is being deregistered and should be +the value that was returned by +.Fn osd_register +when the data type was registered. +.Pp +The +.Fn osd_set +function associates a data object pointer with a kernel data structure's +.Vt struct osd +member. +The +.Fa type +argument specifies which high-level type grouping from +.In sys/osd.h +the slot identifier is allocated under. +The +.Fa osd +argument is a pointer to the kernel data structure's +.Vt struct osd +which will have the +.Fa value +pointer associated with it. +The +.Fa slot +argument specifies the slot identifier to assign the +.Fa value +pointer to. +The +.Fa value +argument points to a data object to associate with +.Fa osd . +.Pp +The +.Fn osd_get +function returns the data pointer associated with a kernel data structure's +.Vt struct osd +member from the specified type/slot identifier pair. +The +.Fa type +argument specifies which high-level type grouping from +.In sys/osd.h +the slot identifier is allocated under. +The +.Fa osd +argument is a pointer to the kernel data structure's +.Vt struct osd +to retrieve the data pointer from. +The +.Fa slot +argument specifies the slot identifier to retrieve the data pointer from. +.Pp +The +.Fn osd_del +function removes the data pointer associated with a kernel data structure's +.Vt struct osd +member from the specified type/slot identifier pair. +The +.Fa type +argument specifies which high-level type grouping from +.In sys/osd.h +the slot identifier is allocated under. +The +.Fa osd +argument is a pointer to the kernel data structure's +.Vt struct osd +to remove the data pointer from. +The +.Fa slot +argument specifies the slot identifier to remove the data pointer from. +If an osd_destructor_t function pointer was specified at registration time, the +destructor function will be called and passed the data pointer for the type/slot +identifier pair which is being deleted. +.Pp +The +.Fn osd_call +function calls the specified osd_method_t function pointer for all +currently registered slots of a given type on the specified +.Fa obj +and +.Fa data +pointers. +The function may sleep and therefore cannot be called from a non-sleepable +context. +The +.Fa type +argument specifies which high-level type grouping from +.In sys/osd.h +to call the method for. +The +.Fa method +argument specifies the index into the osd_method_t array that was passed to +.Fn osd_register . +The +.Fa obj +and +.Fa data +arguments are passed to the method function pointer of each slot. +.Pp +The +.Fn osd_exit +function removes all data object pointers from all currently registered slots +for a given type for the specified kernel data structure's +.Vt struct osd +member. +The +.Fa type +argument specifies which high-level type grouping from +.In sys/osd.h +to remove data pointers from. +The +.Fa osd +argument is a pointer to the kernel data structure's +.Vt struct osd +to remove all data object pointers for all currently registered slots from. +.Sh IMPLEMENTATION NOTES +.Nm +uses a two dimensional matrix (array of arrays) as the data structure to manage +the external data associated with a kernel data structure's +.Vt struct osd +member. +The type identifier is used as the index into the outer array, and the slot +identifier is used as the index into the inner array. To set or retrieve a data +pointer for a given type/slot identifier pair, +.Fn osd_set +and +.Fn osd_get +perform the equivalent of array[type][slot], which is both constant time and +fast. +.Pp +If +.Fn osd_set +is called on a +.Vt struct osd +for the first time, the array for storing data pointers is dynamically allocated +using +.Xr malloc 9 +with M_NOWAIT to a size appropriate for the slot identifier being set. +If a subsequent call to +.Fn osd_set +attempts to set a slot identifier which is numerically larger than the slot used +in the previous +.Fn osd_set +call, +.Xr realloc 9 +is used to grow the array to the appropriate size such that the slot identifier +can be used. +To maximise the efficiency of any code which calls +.Fn osd_set +sequentially on a number of different slot identifiers (e.g. during an +initialisation phase) one should loop through the slot identifiers in descending +order from highest to lowest. +This will result in only a single +.Xr malloc 9 +call to create an array of the largest slot size and all subsequent calls to +.Fn osd_set +will proceed without any +.Xr realloc 9 +calls. +.Pp +The +.Nm +API is geared towards slot identifiers storing pointers to the same underlying +data structure type for a given +.Nm +type identifier. +This is not a requirement, and +.Xr khelp 9 +for example stores completely different data types in slots under the OSD_KHELP +type identifier. +.Ss Locking +.Nm +internally uses a mix of +.Xr mutex 9 , +.Xr rmlock 9 +and +.Xr sx 9 +locks to protect its internal data structures and state. +.Pp +Responsibility for synchronising access to a kernel data structure's +.Vt struct osd +member is left to the subsystem that uses the data structure and calls the +.Nm +API. +.Pp +.Fn osd_get +only acquires an +.Xr rmlock +in read mode, therefore making it safe to use in the majority of contexts within +the kernel including most fast paths. +.Sh RETURN VALUES +.Fn osd_register +returns the slot identifier for the newly registered data type. +.Pp +.Fn osd_set +returns zero on success or ENOMEM if the specified type/slot identifier pair +triggered an internal +.Xr realloc 9 +which failed. +.Pp +.Fn osd_get +returns the data pointer for the specified type/slot identifier pair, or NULL if +the slot has not been initialised yet. +.Pp +.Fn osd_call +returns zero if no method is run or the method for each slot runs successfully. +If a method for a slot returns non-zero, +.Fn osd_call +terminates prematurely and returns the method's error to the caller. +.Sh SEE ALSO +.Xr khelp 9 +.Sh HISTORY +The +Object Specific Data (OSD) facility first appeared in +.Fx 8.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm +facility was written by +.An Pawel Jakub Dawidek Aq pjd@FreeBSD.org . +.Pp +This manual page was written by +.An Lawrence Stewart Aq lstewart@FreeBSD.org . From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 12:29:57 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C7DBD106566C; Wed, 5 Jan 2011 12:29:57 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id 86CBA8FC0A; Wed, 5 Jan 2011 12:29:57 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:b1c7:6e17:2223:c629] (unknown [IPv6:2001:7b8:3a7:0:b1c7:6e17:2223:c629]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 6ECB95C5A; Wed, 5 Jan 2011 13:29:56 +0100 (CET) Message-ID: <4D246444.1060904@FreeBSD.org> Date: Wed, 05 Jan 2011 13:29:56 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.14pre) Gecko/20110104 Lanikai/3.1.8pre MIME-Version: 1.0 To: Alexander Best References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> In-Reply-To: <20110105011635.GA4952@freebsd.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 12:29:57 -0000 On 2011-01-05 02:16, Alexander Best wrote: > the sorting order for these flags seems to be: > > -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > > see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay > consistent? I copied the order from sys/conf/kern.mk, lines 69 and 70: -mfpmath=387 -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow \ -msoft-float -fno-asynchronous-unwind-tables I don't particularly care about the order, though. The order you found seems to be the historical order. If people prefer to have the same order everywhere, I'll fix it. > also what's the status of clang? will these flags make sure that newer > cpu extension won't be activated? i checked > contrib/llvm/tools/clang/include/clang/Driver/Options.td > and clang has support for: > > -m3dnowa > -mssse3 > -msse4a > -msse4 > -msse4_1 > -msse4_2 > -maes > -mavx The in-tree clang has support for these "-mno-xxx" options: -mno_3dnow -mno_3dnowa -mno_aes -mno_avx -mno_constant_cfstrings -mno_mmx -mno_omit_leaf_frame_pointer -mno_pascal_strings -mno_red_zone -mno_relax_all -mno_soft_float -mno_sse -mno_sse2 -mno_sse3 -mno_sse4 -mno_sse4_1 -mno_sse4_2 -mno_sse4a -mno_ssse3 -mno_thumb -mno_warn_nonportable_cfstrings so I think you just looked incorrectly. :) > since these extensions only get set in a hand full of files maybe special > cases for CC == clang can be added. I don't think it's necessary. Maybe there could be one central definition (say, in share/sys.mk) for the flags that disable all 'special' features, e.g. for amd64 and i386: CFLAGS_CONSERVATIVE=-mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float Similar flags could be defined for other arches too. > also maybe you could have a look at the attached patch. i sent this to hackers@ > and nobody objected, but nobody wanted to commit the patch unfortunately. @@ -26,7 +26,6 @@ CFLAGS= -DBOOTPROG=\"gptboot\" \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DGPT \ -D${GPTBOOT_UFS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ Ehm, this looks wrong, those options should not be removed for anything in sys/boot. Boot programs should normally refrain from using any advanced CPU instructions. What did you want to achieve with this patch? From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 12:43:31 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C6E62106566B; Wed, 5 Jan 2011 12:43:31 +0000 (UTC) (envelope-from gleb.kurtsou@gmail.com) Received: from mail-fx0-f54.google.com (mail-fx0-f54.google.com [209.85.161.54]) by mx1.freebsd.org (Postfix) with ESMTP id A50D68FC0A; Wed, 5 Jan 2011 12:43:30 +0000 (UTC) Received: by fxm16 with SMTP id 16so14848777fxm.13 for ; Wed, 05 Jan 2011 04:43:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:cc:subject :message-id:references:mime-version:content-type:content-disposition :in-reply-to:user-agent; bh=R+rPherEVpJK4fT6iyO6RdqnfkwGLCnK8MUYcWhJ7Cs=; b=E5NxN78Y6zy35nnB4ZrM2eFKJw+VXw/V1uvJ9LBDDg1r7VgivAjtcU17R/SiO/7X1c oXvV4hHHhU0gl9L0x2oAemXYqWsjNKLKFef1L/IM0T3MrvyheBdsJjED9M6Yl04VI9KL ZN21u4lwrww4PR2f9I2M++GkTy9lknANJPvTk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; b=l0U7Fb/ur/rTtGsApydjcYA6myZHTIETxsrXaStM4oQIU9K8G+RwScJjkmQnu+mkjw fpLDbIQCzrbhn03N9qVr4G7cyHyFN3WTNcQZIfFqqSh46gBw7Xa5sl987tDacxfONk5h wTIn20jlM+ssltJmc6slzIaA2Q/mLZnMTVnzU= Received: by 10.223.86.3 with SMTP id q3mr127899fal.139.1294230004990; Wed, 05 Jan 2011 04:20:04 -0800 (PST) Received: from localhost (lan-78-157-92-5.vln.skynet.lt [78.157.92.5]) by mx.google.com with ESMTPS id y3sm5446506fai.14.2011.01.05.04.20.03 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 05 Jan 2011 04:20:03 -0800 (PST) Date: Wed, 5 Jan 2011 14:19:10 +0200 From: Gleb Kurtsou To: Alexander Best Message-ID: <20110105121910.GA1841@tops.skynet.lt> References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20110105011635.GA4952@freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Dimitry Andric Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 12:43:31 -0000 On (05/01/2011 01:16), Alexander Best wrote: > On Tue Jan 4 11, Dimitry Andric wrote: > > Author: dim > > Date: Tue Jan 4 20:51:28 2011 > > New Revision: 216977 > > URL: http://svn.freebsd.org/changeset/base/216977 > > > > Log: > > On amd64 and i386, tell the compiler to refrain from generating SSE, > > 3DNow, MMX and floating point instructions in rtld-elf. > > > > Otherwise, _rtld_bind() (and whatever it calls) could possibly clobber > > function arguments that are passed in SSE/3DNow/MMX/FP registers, > > usually floating point values. This can happen, for example, when clang > > generates SSE code for memset() or memcpy() calls. > > the sorting order for these flags seems to be: > > -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > > see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay > consistent? > > also what's the status of clang? will these flags make sure that newer > cpu extension won't be activated? i checked > contrib/llvm/tools/clang/include/clang/Driver/Options.td > and clang has support for: > > -m3dnowa > -mssse3 > -msse4a > -msse4 > -msse4_1 > -msse4_2 > -maes > -mavx > > since these extensions only get set in a hand full of files maybe special > cases for CC == clang can be added. Why not to add NO_HWFLOAT knob (or similar) into makefile infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. These flags are getting rather common in tree. > also maybe you could have a look at the attached patch. i sent this to hackers@ > and nobody objected, but nobody wanted to commit the patch unfortunately. > > cheers. > alex From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 13:00:27 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 331D41065749; Wed, 5 Jan 2011 13:00:27 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 026648FC08; Wed, 5 Jan 2011 13:00:27 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id A8A4C46B39; Wed, 5 Jan 2011 08:00:26 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 55DAC8A009; Wed, 5 Jan 2011 08:00:25 -0500 (EST) From: John Baldwin To: Gleb Kurtsou Date: Wed, 5 Jan 2011 07:59:50 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> <20110105121910.GA1841@tops.skynet.lt> In-Reply-To: <20110105121910.GA1841@tops.skynet.lt> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101050759.50877.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 08:00:25 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, Alexander Best , svn-src-all@freebsd.org, src-committers@freebsd.org, Dimitry Andric Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 13:00:27 -0000 On Wednesday, January 05, 2011 7:19:10 am Gleb Kurtsou wrote: > On (05/01/2011 01:16), Alexander Best wrote: > > On Tue Jan 4 11, Dimitry Andric wrote: > > > Author: dim > > > Date: Tue Jan 4 20:51:28 2011 > > > New Revision: 216977 > > > URL: http://svn.freebsd.org/changeset/base/216977 > > > > > > Log: > > > On amd64 and i386, tell the compiler to refrain from generating SSE, > > > 3DNow, MMX and floating point instructions in rtld-elf. > > > > > > Otherwise, _rtld_bind() (and whatever it calls) could possibly clobber > > > function arguments that are passed in SSE/3DNow/MMX/FP registers, > > > usually floating point values. This can happen, for example, when clang > > > generates SSE code for memset() or memcpy() calls. > > > > the sorting order for these flags seems to be: > > > > -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > > > > see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay > > consistent? > > > > also what's the status of clang? will these flags make sure that newer > > cpu extension won't be activated? i checked > > contrib/llvm/tools/clang/include/clang/Driver/Options.td > > and clang has support for: > > > > -m3dnowa > > -mssse3 > > -msse4a > > -msse4 > > -msse4_1 > > -msse4_2 > > -maes > > -mavx > > > > since these extensions only get set in a hand full of files maybe special > > cases for CC == clang can be added. > Why not to add NO_HWFLOAT knob (or similar) into makefile > infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. > These flags are getting rather common in tree. It strikes me that we really want clang/gcc to have some sort of '-mno-hwfloat' so we don't keep having to add new flags in the future. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 13:36:07 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9CF2A1065674; Wed, 5 Jan 2011 13:36:07 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id 59E588FC20; Wed, 5 Jan 2011 13:36:07 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:b1c7:6e17:2223:c629] (unknown [IPv6:2001:7b8:3a7:0:b1c7:6e17:2223:c629]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 92CF85C5A; Wed, 5 Jan 2011 14:36:06 +0100 (CET) Message-ID: <4D2473C6.40102@FreeBSD.org> Date: Wed, 05 Jan 2011 14:36:06 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.14pre) Gecko/20110104 Lanikai/3.1.8pre MIME-Version: 1.0 To: John Baldwin References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> <20110105121910.GA1841@tops.skynet.lt> <201101050759.50877.jhb@freebsd.org> In-Reply-To: <201101050759.50877.jhb@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, Alexander Best , Gleb Kurtsou , src-committers@freebsd.org, svn-src-all@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 13:36:07 -0000 On 2011-01-05 13:59, John Baldwin wrote: >> Why not to add NO_HWFLOAT knob (or similar) into makefile >> infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. >> These flags are getting rather common in tree. > > It strikes me that we really want clang/gcc to have some sort of > '-mno-hwfloat' so we don't keep having to add new flags in the future. This is not just about floats, clang can also use SSE/AVX instructions for e.g. memset(), memcpy() and the like, or even for structure assignments. As I replied to Alexander, it's probably better to just put such "lowest common denominator for an arch" flags into sys.mk or bsd.cpu.mk. From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 14:33:48 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 89197106564A; Wed, 5 Jan 2011 14:33:48 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 789EC8FC14; Wed, 5 Jan 2011 14:33:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05EXmxf081215; Wed, 5 Jan 2011 14:33:48 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05EXmXr081213; Wed, 5 Jan 2011 14:33:48 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051433.p05EXmXr081213@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 14:33:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217009 - head/sys/dev/mpt X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 14:33:48 -0000 Author: marius Date: Wed Jan 5 14:33:48 2011 New Revision: 217009 URL: http://svn.freebsd.org/changeset/base/217009 Log: Remove a redundant variable assignment found with the clang static analyzer. MFC after: 1 week Modified: head/sys/dev/mpt/mpt_cam.c Modified: head/sys/dev/mpt/mpt_cam.c ============================================================================== --- head/sys/dev/mpt/mpt_cam.c Wed Jan 5 13:50:37 2011 (r217008) +++ head/sys/dev/mpt/mpt_cam.c Wed Jan 5 14:33:48 2011 (r217009) @@ -2971,7 +2971,7 @@ mpt_fc_els_reply_handler(struct mpt_soft } if (tgt_req) { mpt_tgt_state_t *tgt = MPT_TGT_STATE(mpt, tgt_req); - union ccb *ccb = tgt->ccb; + union ccb *ccb; uint32_t ct_id; /* From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 14:37:23 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D11B1106566C; Wed, 5 Jan 2011 14:37:23 +0000 (UTC) (envelope-from das@FreeBSD.ORG) Received: from zim.MIT.EDU (ZIM.MIT.EDU [18.95.3.101]) by mx1.freebsd.org (Postfix) with ESMTP id 75DD38FC14; Wed, 5 Jan 2011 14:37:23 +0000 (UTC) Received: from zim.MIT.EDU (localhost [127.0.0.1]) by zim.MIT.EDU (8.14.4/8.14.2) with ESMTP id p05EbMSw040693; Wed, 5 Jan 2011 09:37:22 -0500 (EST) (envelope-from das@FreeBSD.ORG) Received: (from das@localhost) by zim.MIT.EDU (8.14.4/8.14.2/Submit) id p05EbMVl040692; Wed, 5 Jan 2011 09:37:22 -0500 (EST) (envelope-from das@FreeBSD.ORG) Date: Wed, 5 Jan 2011 09:37:22 -0500 From: David Schultz To: John Baldwin Message-ID: <20110105143722.GA40648@zim.MIT.EDU> Mail-Followup-To: John Baldwin , Gleb Kurtsou , Alexander Best , Dimitry Andric , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> <20110105121910.GA1841@tops.skynet.lt> <201101050759.50877.jhb@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101050759.50877.jhb@freebsd.org> Cc: Gleb Kurtsou , src-committers@FreeBSD.ORG, svn-src-all@FreeBSD.ORG, Dimitry Andric , svn-src-head@FreeBSD.ORG, Alexander Best Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 14:37:23 -0000 On Wed, Jan 05, 2011, John Baldwin wrote: > On Wednesday, January 05, 2011 7:19:10 am Gleb Kurtsou wrote: > > On (05/01/2011 01:16), Alexander Best wrote: > > > On Tue Jan 4 11, Dimitry Andric wrote: > > > > Author: dim > > > > Date: Tue Jan 4 20:51:28 2011 > > > > New Revision: 216977 > > > > URL: http://svn.freebsd.org/changeset/base/216977 > > > > > > > > Log: > > > > On amd64 and i386, tell the compiler to refrain from generating SSE, > > > > 3DNow, MMX and floating point instructions in rtld-elf. > > > > > > > > Otherwise, _rtld_bind() (and whatever it calls) could possibly clobber > > > > function arguments that are passed in SSE/3DNow/MMX/FP registers, > > > > usually floating point values. This can happen, for example, when clang > > > > generates SSE code for memset() or memcpy() calls. > > > > > > the sorting order for these flags seems to be: > > > > > > -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > > > > > > see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay > > > consistent? > > > > > > also what's the status of clang? will these flags make sure that newer > > > cpu extension won't be activated? i checked > > > contrib/llvm/tools/clang/include/clang/Driver/Options.td > > > and clang has support for: > > > > > > -m3dnowa > > > -mssse3 > > > -msse4a > > > -msse4 > > > -msse4_1 > > > -msse4_2 > > > -maes > > > -mavx > > > > > > since these extensions only get set in a hand full of files maybe special > > > cases for CC == clang can be added. > > Why not to add NO_HWFLOAT knob (or similar) into makefile > > infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. > > These flags are getting rather common in tree. > > It strikes me that we really want clang/gcc to have some sort of > '-mno-hwfloat' so we don't keep having to add new flags in the future. It would have to be called something like -mno-xmmregs. Many SSE instructions are for vector operations on integers, not floating point. Furthermore, I don't think the i387 floating point instructions would cause the problem being addressed here (although they're a bad idea for _rtld_bind() for other reasons). From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 14:38:41 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C0A971065679; Wed, 5 Jan 2011 14:38:41 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 90EE48FC0C; Wed, 5 Jan 2011 14:38:41 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 3083846B09; Wed, 5 Jan 2011 09:38:41 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 19EDC8A009; Wed, 5 Jan 2011 09:38:40 -0500 (EST) From: John Baldwin To: Dimitry Andric Date: Wed, 5 Jan 2011 09:28:30 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101042051.p04KpSGk054564@svn.freebsd.org> <201101050759.50877.jhb@freebsd.org> <4D2473C6.40102@FreeBSD.org> In-Reply-To: <4D2473C6.40102@FreeBSD.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101050928.30748.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 09:38:40 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, Alexander Best , Gleb Kurtsou , src-committers@freebsd.org, svn-src-all@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 14:38:41 -0000 On Wednesday, January 05, 2011 8:36:06 am Dimitry Andric wrote: > On 2011-01-05 13:59, John Baldwin wrote: > >> Why not to add NO_HWFLOAT knob (or similar) into makefile > >> infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. > >> These flags are getting rather common in tree. > > > > It strikes me that we really want clang/gcc to have some sort of > > '-mno-hwfloat' so we don't keep having to add new flags in the future. > > This is not just about floats, clang can also use SSE/AVX instructions > for e.g. memset(), memcpy() and the like, or even for structure > assignments. Yes, but the thing that all these extensions have in common is that they use FPU state (i.e. subject to DNA traps, managed via *SAVE and *RSTOR, etc.) and that is the problem with using them in boot code or rtld. What I would want a -mno-hwfloat flag to do is to disable use of anything that would require working FPU state handling. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 14:50:43 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B587A106564A; Wed, 5 Jan 2011 14:50:43 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from mail.icecube.wisc.edu (trout.icecube.wisc.edu [128.104.255.119]) by mx1.freebsd.org (Postfix) with ESMTP id 5398E8FC1D; Wed, 5 Jan 2011 14:50:43 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 4992B58140; Wed, 5 Jan 2011 08:50:42 -0600 (CST) X-Virus-Scanned: amavisd-new at icecube.wisc.edu Received: from mail.icecube.wisc.edu ([127.0.0.1]) by localhost (trout.icecube.wisc.edu [127.0.0.1]) (amavisd-new, port 10030) with ESMTP id SyApKtUjSIYq; Wed, 5 Jan 2011 08:50:42 -0600 (CST) Received: from comporellon.tachypleus.net (unknown [76.210.75.5]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 5EEF758137; Wed, 5 Jan 2011 08:50:41 -0600 (CST) Message-ID: <4D248540.3030602@freebsd.org> Date: Wed, 05 Jan 2011 08:50:40 -0600 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101214 Thunderbird/3.1.7 MIME-Version: 1.0 To: John Baldwin References: <201101042051.p04KpSGk054564@svn.freebsd.org> <201101050759.50877.jhb@freebsd.org> <4D2473C6.40102@FreeBSD.org> <201101050928.30748.jhb@freebsd.org> In-Reply-To: <201101050928.30748.jhb@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Gleb Kurtsou , src-committers@freebsd.org, svn-src-all@freebsd.org, Dimitry Andric , svn-src-head@freebsd.org, Alexander Best Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 14:50:43 -0000 On 01/05/11 08:28, John Baldwin wrote: > On Wednesday, January 05, 2011 8:36:06 am Dimitry Andric wrote: >> On 2011-01-05 13:59, John Baldwin wrote: >>>> Why not to add NO_HWFLOAT knob (or similar) into makefile >>>> infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. >>>> These flags are getting rather common in tree. >>> It strikes me that we really want clang/gcc to have some sort of >>> '-mno-hwfloat' so we don't keep having to add new flags in the future. >> This is not just about floats, clang can also use SSE/AVX instructions >> for e.g. memset(), memcpy() and the like, or even for structure >> assignments. > Yes, but the thing that all these extensions have in common is that they use > FPU state (i.e. subject to DNA traps, managed via *SAVE and *RSTOR, etc.) > and that is the problem with using them in boot code or rtld. What I would > want a -mno-hwfloat flag to do is to disable use of anything that would > require working FPU state handling. You would also want this to be cross-platform, in which case it's more than floating point. E.g. on powerpc, you also want to disable both FP and vector extensions, which use separate sets of instructions and registers. I guess overriding CPU type to be something very old (386?) potentially deoptimizes the code? -Nathan From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 14:51:04 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BC9F91065697; Wed, 5 Jan 2011 14:51:04 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AC1F38FC1A; Wed, 5 Jan 2011 14:51:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05Ep4Ga081652; Wed, 5 Jan 2011 14:51:04 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05Ep4dM081650; Wed, 5 Jan 2011 14:51:04 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051451.p05Ep4dM081650@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 14:51:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217010 - head/sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 14:51:04 -0000 Author: marius Date: Wed Jan 5 14:51:04 2011 New Revision: 217010 URL: http://svn.freebsd.org/changeset/base/217010 Log: Fix whitespace. MFC after: 1 week Modified: head/sys/net/if_media.h Modified: head/sys/net/if_media.h ============================================================================== --- head/sys/net/if_media.h Wed Jan 5 14:33:48 2011 (r217009) +++ head/sys/net/if_media.h Wed Jan 5 14:51:04 2011 (r217010) @@ -36,7 +36,7 @@ */ #ifndef _NET_IF_MEDIA_H_ -#define _NET_IF_MEDIA_H_ +#define _NET_IF_MEDIA_H_ /* * Prototypes and definitions for BSD/OS-compatible network interface @@ -144,13 +144,12 @@ uint64_t ifmedia_baudrate(int); #define IFM_10G_LR 18 /* 10GBase-LR 1310nm Single-mode */ #define IFM_10G_SR 19 /* 10GBase-SR 850nm Multi-mode */ #define IFM_10G_CX4 20 /* 10GBase CX4 copper */ -#define IFM_2500_SX 21 /* 2500BaseSX - multi-mode fiber */ -#define IFM_10G_TWINAX 22 /* 10GBase Twinax copper */ -#define IFM_10G_TWINAX_LONG 23 /* 10GBase Twinax Long copper */ -#define IFM_10G_LRM 24 /* 10GBase-LRM 850nm Multi-mode */ -#define IFM_UNKNOWN 25 /* media types not defined yet */ -#define IFM_10G_T 26 /* 10GBase-T - RJ45 */ - +#define IFM_2500_SX 21 /* 2500BaseSX - multi-mode fiber */ +#define IFM_10G_TWINAX 22 /* 10GBase Twinax copper */ +#define IFM_10G_TWINAX_LONG 23 /* 10GBase Twinax Long copper */ +#define IFM_10G_LRM 24 /* 10GBase-LRM 850nm Multi-mode */ +#define IFM_UNKNOWN 25 /* media types not defined yet */ +#define IFM_10G_T 26 /* 10GBase-T - RJ45 */ /* note 31 is the max! */ @@ -232,20 +231,20 @@ uint64_t ifmedia_baudrate(int); /* * ATM */ -#define IFM_ATM 0x000000a0 -#define IFM_ATM_UNKNOWN 3 -#define IFM_ATM_UTP_25 4 -#define IFM_ATM_TAXI_100 5 -#define IFM_ATM_TAXI_140 6 -#define IFM_ATM_MM_155 7 -#define IFM_ATM_SM_155 8 -#define IFM_ATM_UTP_155 9 -#define IFM_ATM_MM_622 10 -#define IFM_ATM_SM_622 11 +#define IFM_ATM 0x000000a0 +#define IFM_ATM_UNKNOWN 3 +#define IFM_ATM_UTP_25 4 +#define IFM_ATM_TAXI_100 5 +#define IFM_ATM_TAXI_140 6 +#define IFM_ATM_MM_155 7 +#define IFM_ATM_SM_155 8 +#define IFM_ATM_UTP_155 9 +#define IFM_ATM_MM_622 10 +#define IFM_ATM_SM_622 11 #define IFM_ATM_VIRTUAL 12 -#define IFM_ATM_SDH 0x00000100 /* SDH instead of SONET */ -#define IFM_ATM_NOSCRAMB 0x00000200 /* no scrambling */ -#define IFM_ATM_UNASSIGNED 0x00000400 /* unassigned cells */ +#define IFM_ATM_SDH 0x00000100 /* SDH instead of SONET */ +#define IFM_ATM_NOSCRAMB 0x00000200 /* no scrambling */ +#define IFM_ATM_UNASSIGNED 0x00000400 /* unassigned cells */ /* * CARP Common Address Redundancy Protocol @@ -295,22 +294,22 @@ uint64_t ifmedia_baudrate(int); #define IFM_STATUS_VALID IFM_AVALID /* List of "status valid" bits, for ifconfig(8). */ -#define IFM_STATUS_VALID_LIST { \ - IFM_AVALID, \ - 0 \ +#define IFM_STATUS_VALID_LIST { \ + IFM_AVALID, \ + 0 \ } /* * Macros to extract various bits of information from the media word. */ -#define IFM_TYPE(x) ((x) & IFM_NMASK) -#define IFM_SUBTYPE(x) ((x) & IFM_TMASK) -#define IFM_TYPE_OPTIONS(x) ((x) & IFM_OMASK) -#define IFM_INST(x) (((x) & IFM_IMASK) >> IFM_ISHIFT) -#define IFM_OPTIONS(x) ((x) & (IFM_OMASK|IFM_GMASK)) -#define IFM_MODE(x) ((x) & IFM_MMASK) +#define IFM_TYPE(x) ((x) & IFM_NMASK) +#define IFM_SUBTYPE(x) ((x) & IFM_TMASK) +#define IFM_TYPE_OPTIONS(x) ((x) & IFM_OMASK) +#define IFM_INST(x) (((x) & IFM_IMASK) >> IFM_ISHIFT) +#define IFM_OPTIONS(x) ((x) & (IFM_OMASK | IFM_GMASK)) +#define IFM_MODE(x) ((x) & IFM_MMASK) -#define IFM_INST_MAX IFM_INST(IFM_IMASK) +#define IFM_INST_MAX IFM_INST(IFM_IMASK) /* * Macro to create a media word. @@ -541,7 +540,7 @@ struct ifmedia_description { { 0, NULL }, \ } -# define IFM_SUBTYPE_ATM_DESCRIPTIONS { \ +#define IFM_SUBTYPE_ATM_DESCRIPTIONS { \ { IFM_ATM_UNKNOWN, "Unknown" }, \ { IFM_ATM_UTP_25, "UTP/25.6MBit" }, \ { IFM_ATM_TAXI_100, "Taxi/100MBit" }, \ @@ -555,7 +554,7 @@ struct ifmedia_description { { 0, NULL }, \ } -# define IFM_SUBTYPE_ATM_ALIASES { \ +#define IFM_SUBTYPE_ATM_ALIASES { \ { IFM_ATM_UNKNOWN, "UNKNOWN" }, \ { IFM_ATM_UTP_25, "UTP-25" }, \ { IFM_ATM_TAXI_100, "TAXI-100" }, \ @@ -576,7 +575,6 @@ struct ifmedia_description { { 0, NULL }, \ } - #define IFM_SUBTYPE_SHARED_DESCRIPTIONS { \ { IFM_AUTO, "autoselect" }, \ { IFM_MANUAL, "manual" }, \ @@ -608,7 +606,7 @@ struct ifmedia_baudrate { uint64_t ifmb_baudrate; /* corresponding baudrate */ }; -#define IFM_BAUDRATE_DESCRIPTIONS { \ +#define IFM_BAUDRATE_DESCRIPTIONS { \ { IFM_ETHER | IFM_10_T, IF_Mbps(10) }, \ { IFM_ETHER | IFM_10_2, IF_Mbps(10) }, \ { IFM_ETHER | IFM_10_5, IF_Mbps(10) }, \ @@ -672,10 +670,10 @@ struct ifmedia_status_description { const char *ifms_string[2]; }; -#define IFM_STATUS_DESC(ifms, bit) \ +#define IFM_STATUS_DESC(ifms, bit) \ (ifms)->ifms_string[((ifms)->ifms_bit & (bit)) ? 1 : 0] -#define IFM_STATUS_DESCRIPTIONS { \ +#define IFM_STATUS_DESCRIPTIONS { \ { IFM_ETHER, IFM_AVALID, IFM_ACTIVE, \ { "no carrier", "active" } }, \ { IFM_FDDI, IFM_AVALID, IFM_ACTIVE, \ From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 15:02:53 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7FC5E1065673; Wed, 5 Jan 2011 15:02:53 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 4C9768FC13; Wed, 5 Jan 2011 15:02:53 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id E882046B09; Wed, 5 Jan 2011 10:02:52 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 19F6B8A009; Wed, 5 Jan 2011 10:02:52 -0500 (EST) From: John Baldwin To: Nathan Whitehorn Date: Wed, 5 Jan 2011 10:02:51 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101042051.p04KpSGk054564@svn.freebsd.org> <201101050928.30748.jhb@freebsd.org> <4D248540.3030602@freebsd.org> In-Reply-To: <4D248540.3030602@freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101051002.51598.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 10:02:52 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: Gleb Kurtsou , src-committers@freebsd.org, svn-src-all@freebsd.org, Dimitry Andric , svn-src-head@freebsd.org, Alexander Best Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 15:02:53 -0000 On Wednesday, January 05, 2011 9:50:40 am Nathan Whitehorn wrote: > On 01/05/11 08:28, John Baldwin wrote: > > On Wednesday, January 05, 2011 8:36:06 am Dimitry Andric wrote: > >> On 2011-01-05 13:59, John Baldwin wrote: > >>>> Why not to add NO_HWFLOAT knob (or similar) into makefile > >>>> infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. > >>>> These flags are getting rather common in tree. > >>> It strikes me that we really want clang/gcc to have some sort of > >>> '-mno-hwfloat' so we don't keep having to add new flags in the future. > >> This is not just about floats, clang can also use SSE/AVX instructions > >> for e.g. memset(), memcpy() and the like, or even for structure > >> assignments. > > Yes, but the thing that all these extensions have in common is that they use > > FPU state (i.e. subject to DNA traps, managed via *SAVE and *RSTOR, etc.) > > and that is the problem with using them in boot code or rtld. What I would > > want a -mno-hwfloat flag to do is to disable use of anything that would > > require working FPU state handling. > > You would also want this to be cross-platform, in which case it's more > than floating point. E.g. on powerpc, you also want to disable both FP > and vector extensions, which use separate sets of instructions and > registers. I guess overriding CPU type to be something very old (386?) > potentially deoptimizes the code? Hmm, I don't know if this is generically MI, but at least for x86 having a single -mno-sse-xmm-mmx-anything-registers-please would be useful I think. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 15:04:44 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 777F0106566B; Wed, 5 Jan 2011 15:04:44 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id 337F78FC16; Wed, 5 Jan 2011 15:04:44 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:b1c7:6e17:2223:c629] (unknown [IPv6:2001:7b8:3a7:0:b1c7:6e17:2223:c629]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 7189B5C5A; Wed, 5 Jan 2011 16:04:43 +0100 (CET) Message-ID: <4D24888B.50305@FreeBSD.org> Date: Wed, 05 Jan 2011 16:04:43 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.14pre) Gecko/20110104 Lanikai/3.1.8pre MIME-Version: 1.0 To: Nathan Whitehorn References: <201101042051.p04KpSGk054564@svn.freebsd.org> <201101050759.50877.jhb@freebsd.org> <4D2473C6.40102@FreeBSD.org> <201101050928.30748.jhb@freebsd.org> <4D248540.3030602@freebsd.org> In-Reply-To: <4D248540.3030602@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Gleb Kurtsou , src-committers@freebsd.org, John Baldwin , svn-src-all@freebsd.org, svn-src-head@freebsd.org, Alexander Best Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 15:04:44 -0000 On 2011-01-05 15:50, Nathan Whitehorn wrote: > You would also want this to be cross-platform, in which case it's more > than floating point. E.g. on powerpc, you also want to disable both FP > and vector extensions, which use separate sets of instructions and > registers. Yeah, but in any case, hacking the compiler itself is not the proper way to achieve this goal, IMHO. It should go into sys.mk, or more appropriately bsd.cpu.mk. I'll make a crude diff for this tonight. > I guess overriding CPU type to be something very old (386?) > potentially deoptimizes the code? That won't work for amd64. :) From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 15:28:31 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 36C8B1065670; Wed, 5 Jan 2011 15:28:31 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 240DD8FC1C; Wed, 5 Jan 2011 15:28:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05FSV2u082699; Wed, 5 Jan 2011 15:28:31 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05FSVPL082696; Wed, 5 Jan 2011 15:28:31 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051528.p05FSVPL082696@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 15:28:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217013 - in head: sbin/ifconfig sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 15:28:31 -0000 Author: marius Date: Wed Jan 5 15:28:30 2011 New Revision: 217013 URL: http://svn.freebsd.org/changeset/base/217013 Log: Teach ifconfig(8) the handy shared option shortcut aliases the NetBSD counterpart also takes, i.e. "fdx" for "full-duplex", "flow" for "flowcontrol", "hdx" for "half-duplex" as well as "loop" and "loopback" for "hw-loopback". MFC after: 1 week Modified: head/sbin/ifconfig/ifmedia.c head/sys/net/if_media.h Modified: head/sbin/ifconfig/ifmedia.c ============================================================================== --- head/sbin/ifconfig/ifmedia.c Wed Jan 5 15:10:58 2011 (r217012) +++ head/sbin/ifconfig/ifmedia.c Wed Jan 5 15:28:30 2011 (r217013) @@ -421,6 +421,9 @@ static struct ifmedia_description ifm_su static struct ifmedia_description ifm_shared_option_descriptions[] = IFM_SHARED_OPTION_DESCRIPTIONS; +static struct ifmedia_description ifm_shared_option_aliases[] = + IFM_SHARED_OPTION_ALIASES; + struct ifmedia_type_to_subtype { struct { struct ifmedia_description *desc; @@ -429,7 +432,7 @@ struct ifmedia_type_to_subtype { struct { struct ifmedia_description *desc; int alias; - } options[3]; + } options[4]; struct { struct ifmedia_description *desc; int alias; @@ -448,6 +451,7 @@ static struct ifmedia_type_to_subtype if }, { { &ifm_shared_option_descriptions[0], 0 }, + { &ifm_shared_option_aliases[0], 1 }, { &ifm_subtype_ethernet_option_descriptions[0], 0 }, { NULL, 0 }, }, @@ -465,6 +469,7 @@ static struct ifmedia_type_to_subtype if }, { { &ifm_shared_option_descriptions[0], 0 }, + { &ifm_shared_option_aliases[0], 1 }, { &ifm_subtype_tokenring_option_descriptions[0], 0 }, { NULL, 0 }, }, @@ -482,6 +487,7 @@ static struct ifmedia_type_to_subtype if }, { { &ifm_shared_option_descriptions[0], 0 }, + { &ifm_shared_option_aliases[0], 1 }, { &ifm_subtype_fddi_option_descriptions[0], 0 }, { NULL, 0 }, }, @@ -499,6 +505,7 @@ static struct ifmedia_type_to_subtype if }, { { &ifm_shared_option_descriptions[0], 0 }, + { &ifm_shared_option_aliases[0], 1 }, { &ifm_subtype_ieee80211_option_descriptions[0], 0 }, { NULL, 0 }, }, @@ -518,6 +525,7 @@ static struct ifmedia_type_to_subtype if }, { { &ifm_shared_option_descriptions[0], 0 }, + { &ifm_shared_option_aliases[0], 1 }, { &ifm_subtype_atm_option_descriptions[0], 0 }, { NULL, 0 }, }, Modified: head/sys/net/if_media.h ============================================================================== --- head/sys/net/if_media.h Wed Jan 5 15:10:58 2011 (r217012) +++ head/sys/net/if_media.h Wed Jan 5 15:28:30 2011 (r217013) @@ -598,6 +598,15 @@ struct ifmedia_description { { 0, NULL }, \ } +#define IFM_SHARED_OPTION_ALIASES { \ + { IFM_FDX, "fdx" }, \ + { IFM_HDX, "hdx" }, \ + { IFM_FLOW, "flow" }, \ + { IFM_LOOP, "loop" }, \ + { IFM_LOOP, "loopback" }, \ + { 0, NULL }, \ +} + /* * Baudrate descriptions for the various media types. */ From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 15:35:07 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 55DF6106564A; Wed, 5 Jan 2011 15:35:07 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mail.cksoft.de (mail.cksoft.de [IPv6:2001:4068:10::3]) by mx1.freebsd.org (Postfix) with ESMTP id F2F3E8FC1D; Wed, 5 Jan 2011 15:35:06 +0000 (UTC) Received: from localhost (amavis.fra.cksoft.de [192.168.74.71]) by mail.cksoft.de (Postfix) with ESMTP id 5850F41C7A7; Wed, 5 Jan 2011 16:35:06 +0100 (CET) X-Virus-Scanned: amavisd-new at cksoft.de Received: from mail.cksoft.de ([192.168.74.103]) by localhost (amavis.fra.cksoft.de [192.168.74.71]) (amavisd-new, port 10024) with ESMTP id sX3GD27XdI2H; Wed, 5 Jan 2011 16:35:05 +0100 (CET) Received: by mail.cksoft.de (Postfix, from userid 66) id A603B41C7A6; Wed, 5 Jan 2011 16:35:05 +0100 (CET) Received: from maildrop.int.zabbadoz.net (maildrop.int.zabbadoz.net [10.111.66.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.int.zabbadoz.net (Postfix) with ESMTP id 608B34448F3; Wed, 5 Jan 2011 15:34:30 +0000 (UTC) Date: Wed, 5 Jan 2011 15:34:30 +0000 (UTC) From: "Bjoern A. Zeeb" X-X-Sender: bz@maildrop.int.zabbadoz.net To: Marius Strobl In-Reply-To: <201101051528.p05FSVPL082696@svn.freebsd.org> Message-ID: <20110105153107.X14966@maildrop.int.zabbadoz.net> References: <201101051528.p05FSVPL082696@svn.freebsd.org> X-OpenPGP-Key: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217013 - in head: sbin/ifconfig sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 15:35:07 -0000 On Wed, 5 Jan 2011, Marius Strobl wrote: > Author: marius > Date: Wed Jan 5 15:28:30 2011 > New Revision: 217013 > URL: http://svn.freebsd.org/changeset/base/217013 > > Log: > Teach ifconfig(8) the handy shared option shortcut aliases the NetBSD > counterpart also takes, i.e. "fdx" for "full-duplex", "flow" for > "flowcontrol", "hdx" for "half-duplex" as well as "loop" and "loopback" > for "hw-loopback". I am not sure this is a good idea. Unless this is really really useful for compatibility with scripts (which I doubt) it'll sooner or later cause headaches, especially given some of the (new) names could be very well used for different things as well. > MFC after: 1 week > > Modified: > head/sbin/ifconfig/ifmedia.c > head/sys/net/if_media.h > > Modified: head/sbin/ifconfig/ifmedia.c > ============================================================================== > --- head/sbin/ifconfig/ifmedia.c Wed Jan 5 15:10:58 2011 (r217012) > +++ head/sbin/ifconfig/ifmedia.c Wed Jan 5 15:28:30 2011 (r217013) > @@ -421,6 +421,9 @@ static struct ifmedia_description ifm_su > static struct ifmedia_description ifm_shared_option_descriptions[] = > IFM_SHARED_OPTION_DESCRIPTIONS; > > +static struct ifmedia_description ifm_shared_option_aliases[] = > + IFM_SHARED_OPTION_ALIASES; > + > struct ifmedia_type_to_subtype { > struct { > struct ifmedia_description *desc; > @@ -429,7 +432,7 @@ struct ifmedia_type_to_subtype { > struct { > struct ifmedia_description *desc; > int alias; > - } options[3]; > + } options[4]; > struct { > struct ifmedia_description *desc; > int alias; > @@ -448,6 +451,7 @@ static struct ifmedia_type_to_subtype if > }, > { > { &ifm_shared_option_descriptions[0], 0 }, > + { &ifm_shared_option_aliases[0], 1 }, > { &ifm_subtype_ethernet_option_descriptions[0], 0 }, > { NULL, 0 }, > }, > @@ -465,6 +469,7 @@ static struct ifmedia_type_to_subtype if > }, > { > { &ifm_shared_option_descriptions[0], 0 }, > + { &ifm_shared_option_aliases[0], 1 }, > { &ifm_subtype_tokenring_option_descriptions[0], 0 }, > { NULL, 0 }, > }, > @@ -482,6 +487,7 @@ static struct ifmedia_type_to_subtype if > }, > { > { &ifm_shared_option_descriptions[0], 0 }, > + { &ifm_shared_option_aliases[0], 1 }, > { &ifm_subtype_fddi_option_descriptions[0], 0 }, > { NULL, 0 }, > }, > @@ -499,6 +505,7 @@ static struct ifmedia_type_to_subtype if > }, > { > { &ifm_shared_option_descriptions[0], 0 }, > + { &ifm_shared_option_aliases[0], 1 }, > { &ifm_subtype_ieee80211_option_descriptions[0], 0 }, > { NULL, 0 }, > }, > @@ -518,6 +525,7 @@ static struct ifmedia_type_to_subtype if > }, > { > { &ifm_shared_option_descriptions[0], 0 }, > + { &ifm_shared_option_aliases[0], 1 }, > { &ifm_subtype_atm_option_descriptions[0], 0 }, > { NULL, 0 }, > }, > > Modified: head/sys/net/if_media.h > ============================================================================== > --- head/sys/net/if_media.h Wed Jan 5 15:10:58 2011 (r217012) > +++ head/sys/net/if_media.h Wed Jan 5 15:28:30 2011 (r217013) > @@ -598,6 +598,15 @@ struct ifmedia_description { > { 0, NULL }, \ > } > > +#define IFM_SHARED_OPTION_ALIASES { \ > + { IFM_FDX, "fdx" }, \ > + { IFM_HDX, "hdx" }, \ > + { IFM_FLOW, "flow" }, \ > + { IFM_LOOP, "loop" }, \ > + { IFM_LOOP, "loopback" }, \ > + { 0, NULL }, \ > +} > + > /* > * Baudrate descriptions for the various media types. > */ > -- Bjoern A. Zeeb You have to have visions! Going to jail sucks -- All my daemons like it! http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/jails.html From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 15:55:15 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7EE92106566B; Wed, 5 Jan 2011 15:55:15 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id 05D808FC13; Wed, 5 Jan 2011 15:55:14 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id p05FtDGG097208; Wed, 5 Jan 2011 16:55:13 +0100 (CET) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id p05FtDE9097207; Wed, 5 Jan 2011 16:55:13 +0100 (CET) (envelope-from marius) Date: Wed, 5 Jan 2011 16:55:13 +0100 From: Marius Strobl To: "Bjoern A. Zeeb" Message-ID: <20110105155513.GA97101@alchemy.franken.de> References: <201101051528.p05FSVPL082696@svn.freebsd.org> <20110105153107.X14966@maildrop.int.zabbadoz.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110105153107.X14966@maildrop.int.zabbadoz.net> User-Agent: Mutt/1.4.2.3i Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r217013 - in head: sbin/ifconfig sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 15:55:15 -0000 On Wed, Jan 05, 2011 at 03:34:30PM +0000, Bjoern A. Zeeb wrote: > On Wed, 5 Jan 2011, Marius Strobl wrote: > > >Author: marius > >Date: Wed Jan 5 15:28:30 2011 > >New Revision: 217013 > >URL: http://svn.freebsd.org/changeset/base/217013 > > > >Log: > > Teach ifconfig(8) the handy shared option shortcut aliases the NetBSD > > counterpart also takes, i.e. "fdx" for "full-duplex", "flow" for > > "flowcontrol", "hdx" for "half-duplex" as well as "loop" and "loopback" > > for "hw-loopback". > > I am not sure this is a good idea. Unless this is really really > useful for compatibility with scripts (which I doubt) it'll sooner or > later cause headaches, especially given some of the (new) names could > be very well used for different things as well. Could you please elaborate on what different use you have in mind? Generally it seems a bad idea to me if the existing options and the new names as implemented would trigger different things as you suggest given the latter are rather common abbreviations as well as diverging from the user interface of the other BSDs seems like a bad idea (i.e. not only not supporting the same names they do but also controlling different things with a given one). Also the concept of aliases taken by ifconfig(8) isn't new, we support several including f.e. "auto" for "autoselect" for quite some time. Marius > > > > MFC after: 1 week > > > >Modified: > > head/sbin/ifconfig/ifmedia.c > > head/sys/net/if_media.h > > > >Modified: head/sbin/ifconfig/ifmedia.c > >============================================================================== > >--- head/sbin/ifconfig/ifmedia.c Wed Jan 5 15:10:58 2011 (r217012) > >+++ head/sbin/ifconfig/ifmedia.c Wed Jan 5 15:28:30 2011 (r217013) > >@@ -421,6 +421,9 @@ static struct ifmedia_description ifm_su > >static struct ifmedia_description ifm_shared_option_descriptions[] = > > IFM_SHARED_OPTION_DESCRIPTIONS; > > > >+static struct ifmedia_description ifm_shared_option_aliases[] = > >+ IFM_SHARED_OPTION_ALIASES; > >+ > >struct ifmedia_type_to_subtype { > > struct { > > struct ifmedia_description *desc; > >@@ -429,7 +432,7 @@ struct ifmedia_type_to_subtype { > > struct { > > struct ifmedia_description *desc; > > int alias; > >- } options[3]; > >+ } options[4]; > > struct { > > struct ifmedia_description *desc; > > int alias; > >@@ -448,6 +451,7 @@ static struct ifmedia_type_to_subtype if > > }, > > { > > { &ifm_shared_option_descriptions[0], 0 }, > >+ { &ifm_shared_option_aliases[0], 1 }, > > { &ifm_subtype_ethernet_option_descriptions[0], 0 }, > > { NULL, 0 }, > > }, > >@@ -465,6 +469,7 @@ static struct ifmedia_type_to_subtype if > > }, > > { > > { &ifm_shared_option_descriptions[0], 0 }, > >+ { &ifm_shared_option_aliases[0], 1 }, > > { &ifm_subtype_tokenring_option_descriptions[0], 0 }, > > { NULL, 0 }, > > }, > >@@ -482,6 +487,7 @@ static struct ifmedia_type_to_subtype if > > }, > > { > > { &ifm_shared_option_descriptions[0], 0 }, > >+ { &ifm_shared_option_aliases[0], 1 }, > > { &ifm_subtype_fddi_option_descriptions[0], 0 }, > > { NULL, 0 }, > > }, > >@@ -499,6 +505,7 @@ static struct ifmedia_type_to_subtype if > > }, > > { > > { &ifm_shared_option_descriptions[0], 0 }, > >+ { &ifm_shared_option_aliases[0], 1 }, > > { &ifm_subtype_ieee80211_option_descriptions[0], 0 }, > > { NULL, 0 }, > > }, > >@@ -518,6 +525,7 @@ static struct ifmedia_type_to_subtype if > > }, > > { > > { &ifm_shared_option_descriptions[0], 0 }, > >+ { &ifm_shared_option_aliases[0], 1 }, > > { &ifm_subtype_atm_option_descriptions[0], 0 }, > > { NULL, 0 }, > > }, > > > >Modified: head/sys/net/if_media.h > >============================================================================== > >--- head/sys/net/if_media.h Wed Jan 5 15:10:58 2011 (r217012) > >+++ head/sys/net/if_media.h Wed Jan 5 15:28:30 2011 (r217013) > >@@ -598,6 +598,15 @@ struct ifmedia_description { > > { 0, NULL }, \ > >} > > > >+#define IFM_SHARED_OPTION_ALIASES { \ > >+ { IFM_FDX, "fdx" }, \ > >+ { IFM_HDX, "hdx" }, \ > >+ { IFM_FLOW, "flow" }, \ > >+ { IFM_LOOP, "loop" }, \ > >+ { IFM_LOOP, "loopback" }, \ > >+ { 0, NULL }, \ > >+} > >+ > >/* > > * Baudrate descriptions for the various media types. > > */ > > > > -- > Bjoern A. Zeeb You have to have visions! > Going to jail sucks -- All my daemons like it! > http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/jails.html From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 16:17:28 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2D77C106566C; Wed, 5 Jan 2011 16:17:28 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from gw01.mail.saunalahti.fi (gw01.mail.saunalahti.fi [195.197.172.115]) by mx1.freebsd.org (Postfix) with ESMTP id D47798FC15; Wed, 5 Jan 2011 16:17:27 +0000 (UTC) Received: from a91-153-123-205.elisa-laajakaista.fi (a91-153-123-205.elisa-laajakaista.fi [91.153.123.205]) by gw01.mail.saunalahti.fi (Postfix) with SMTP id 1A35F151478; Wed, 5 Jan 2011 18:17:21 +0200 (EET) Date: Wed, 5 Jan 2011 18:17:20 +0200 From: Jaakko Heinonen To: John Baldwin Message-ID: <20110105161720.GA1388@a91-153-123-205.elisa-laajakaista.fi> References: <201101041316.p04DGSo6037042@svn.freebsd.org> <4D23521C.8020506@freebsd.org> <201101041314.08949.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101041314.08949.jhb@freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Julian Elischer Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 16:17:28 -0000 On 2011-01-04, John Baldwin wrote: > Err, no, the point of NOTREACHED is to serve as documentation for lint(1), but > that has subsequently been obsoleted by __dead2. style(9) is out of date then? -- Jaakko From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 16:47:58 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9249D106566C; Wed, 5 Jan 2011 16:47:58 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 626F88FC0A; Wed, 5 Jan 2011 16:47:58 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 02DC446B29; Wed, 5 Jan 2011 11:47:58 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id CF7A18A01D; Wed, 5 Jan 2011 11:47:56 -0500 (EST) From: John Baldwin To: Jaakko Heinonen Date: Wed, 5 Jan 2011 11:44:56 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101041316.p04DGSo6037042@svn.freebsd.org> <201101041314.08949.jhb@freebsd.org> <20110105161720.GA1388@a91-153-123-205.elisa-laajakaista.fi> In-Reply-To: <20110105161720.GA1388@a91-153-123-205.elisa-laajakaista.fi> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201101051144.56940.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 11:47:56 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Julian Elischer Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 16:47:58 -0000 On Wednesday, January 05, 2011 11:17:20 am Jaakko Heinonen wrote: > On 2011-01-04, John Baldwin wrote: > > Err, no, the point of NOTREACHED is to serve as documentation for lint(1), but > > that has subsequently been obsoleted by __dead2. > > style(9) is out of date then? According to bde@'s most recent e-mails, yes. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 16:48:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 30E89106564A; Wed, 5 Jan 2011 16:48:00 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id F40AB8FC0C; Wed, 5 Jan 2011 16:47:59 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id A739846B38; Wed, 5 Jan 2011 11:47:59 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id B0E938A027; Wed, 5 Jan 2011 11:47:58 -0500 (EST) From: John Baldwin To: Dimitry Andric Date: Wed, 5 Jan 2011 11:46:26 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101042051.p04KpSGk054564@svn.freebsd.org> <4D248540.3030602@freebsd.org> <4D24888B.50305@FreeBSD.org> In-Reply-To: <4D24888B.50305@FreeBSD.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101051146.26723.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 11:47:58 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: Gleb Kurtsou , src-committers@freebsd.org, svn-src-all@freebsd.org, Nathan Whitehorn , svn-src-head@freebsd.org, Alexander Best Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 16:48:00 -0000 On Wednesday, January 05, 2011 10:04:43 am Dimitry Andric wrote: > On 2011-01-05 15:50, Nathan Whitehorn wrote: > > You would also want this to be cross-platform, in which case it's more > > than floating point. E.g. on powerpc, you also want to disable both FP > > and vector extensions, which use separate sets of instructions and > > registers. > > Yeah, but in any case, hacking the compiler itself is not the proper way > to achieve this goal, IMHO. It should go into sys.mk, or more > appropriately bsd.cpu.mk. I'll make a crude diff for this tonight. I think this is a workaround for a deficiency in the compiler, and one we are probably stuck with. But it sure would be nice to have in the compiler. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 16:59:11 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BBC4B106566C; Wed, 5 Jan 2011 16:59:11 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 5B4A98FC17; Wed, 5 Jan 2011 16:59:11 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p05GokrI016818; Wed, 5 Jan 2011 09:50:46 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D24A165.4080506@bsdimp.com> Date: Wed, 05 Jan 2011 09:50:45 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: John Baldwin References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> <20110105121910.GA1841@tops.skynet.lt> <201101050759.50877.jhb@freebsd.org> In-Reply-To: <201101050759.50877.jhb@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Gleb Kurtsou , src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, Dimitry Andric , svn-src-head@FreeBSD.org, Alexander Best Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 16:59:11 -0000 On 01/05/2011 05:59, John Baldwin wrote: > On Wednesday, January 05, 2011 7:19:10 am Gleb Kurtsou wrote: >> On (05/01/2011 01:16), Alexander Best wrote: >>> On Tue Jan 4 11, Dimitry Andric wrote: >>>> Author: dim >>>> Date: Tue Jan 4 20:51:28 2011 >>>> New Revision: 216977 >>>> URL: http://svn.freebsd.org/changeset/base/216977 >>>> >>>> Log: >>>> On amd64 and i386, tell the compiler to refrain from generating SSE, >>>> 3DNow, MMX and floating point instructions in rtld-elf. >>>> >>>> Otherwise, _rtld_bind() (and whatever it calls) could possibly clobber >>>> function arguments that are passed in SSE/3DNow/MMX/FP registers, >>>> usually floating point values. This can happen, for example, when clang >>>> generates SSE code for memset() or memcpy() calls. >>> the sorting order for these flags seems to be: >>> >>> -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 >>> >>> see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay >>> consistent? >>> >>> also what's the status of clang? will these flags make sure that newer >>> cpu extension won't be activated? i checked >>> contrib/llvm/tools/clang/include/clang/Driver/Options.td >>> and clang has support for: >>> >>> -m3dnowa >>> -mssse3 >>> -msse4a >>> -msse4 >>> -msse4_1 >>> -msse4_2 >>> -maes >>> -mavx >>> >>> since these extensions only get set in a hand full of files maybe special >>> cases for CC == clang can be added. >> Why not to add NO_HWFLOAT knob (or similar) into makefile >> infrastructure. And set CFLAGS accordingly, depending on CC, arch, etc. >> These flags are getting rather common in tree. > It strikes me that we really want clang/gcc to have some sort of > '-mno-hwfloat' so we don't keep having to add new flags in the future. gcc already has -msoftfloat, but I guess that's a little different than what you are proposing... Warner From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 18:27:39 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 20E86106566B; Wed, 5 Jan 2011 18:27:39 +0000 (UTC) (envelope-from ken@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 101228FC19; Wed, 5 Jan 2011 18:27:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05IRcYf087138; Wed, 5 Jan 2011 18:27:38 GMT (envelope-from ken@svn.freebsd.org) Received: (from ken@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05IRcOm087136; Wed, 5 Jan 2011 18:27:38 GMT (envelope-from ken@svn.freebsd.org) Message-Id: <201101051827.p05IRcOm087136@svn.freebsd.org> From: "Kenneth D. Merry" Date: Wed, 5 Jan 2011 18:27:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217016 - head/sbin/camcontrol X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 18:27:39 -0000 Author: ken Date: Wed Jan 5 18:27:38 2011 New Revision: 217016 URL: http://svn.freebsd.org/changeset/base/217016 Log: The camcontrol smppc option to clear a PHY error log is 'clearerrlog', not 'clearerrorlog'. Modified: head/sbin/camcontrol/camcontrol.8 Modified: head/sbin/camcontrol/camcontrol.8 ============================================================================== --- head/sbin/camcontrol/camcontrol.8 Wed Jan 5 17:10:10 2011 (r217015) +++ head/sbin/camcontrol/camcontrol.8 Wed Jan 5 18:27:38 2011 (r217016) @@ -677,7 +677,7 @@ Send the HARD RESET command to the phy. .It disable Send the DISABLE command to the phy. Note that the LINK RESET or HARD RESET commands should re-enable the phy. -.It clearerrorlog +.It clearerrlog Send the CLEAR ERROR LOG command. This clears the error log counters for the specified phy. .It clearaffiliation From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 18:46:05 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 75F751065696; Wed, 5 Jan 2011 18:46:05 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 64FDD8FC18; Wed, 5 Jan 2011 18:46:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05Ik5pb087570; Wed, 5 Jan 2011 18:46:05 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05Ik5a1087568; Wed, 5 Jan 2011 18:46:05 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101051846.p05Ik5a1087568@svn.freebsd.org> From: Rick Macklem Date: Wed, 5 Jan 2011 18:46:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217017 - head/sys/fs/nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 18:46:05 -0000 Author: rmacklem Date: Wed Jan 5 18:46:05 2011 New Revision: 217017 URL: http://svn.freebsd.org/changeset/base/217017 Log: Fix the experimental NFS server to use vfs_busyfs() instead of vfs_getvfs() so that the mount point is busied for the VFS_FHTOVP() call. This is analagous to r185432 for the regular NFS server. Reviewed by: kib MFC after: 12 days Modified: head/sys/fs/nfsserver/nfs_nfsdport.c Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Wed Jan 5 18:27:38 2011 (r217016) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Wed Jan 5 18:46:05 2011 (r217017) @@ -2548,8 +2548,8 @@ nfsd_fhtovp(struct nfsrv_descript *nd, s /* * Check for the special case of the nfsv4root_fh. */ - mp = vfs_getvfs(&fhp->fh_fsid); - if (!mp) { + mp = vfs_busyfs(&fhp->fh_fsid); + if (mp == NULL) { *vpp = NULL; nd->nd_repstat = ESTALE; if (*mpp && exp->nes_vfslocked) @@ -2575,6 +2575,7 @@ nfsd_fhtovp(struct nfsrv_descript *nd, s nd->nd_repstat = nfsvno_fhtovp(mp, fhp, nd->nd_nam, lktype, vpp, exp, &credanon); + vfs_unbusy(mp); /* * For NFSv4 without a pseudo root fs, unexported file handles @@ -2636,11 +2637,8 @@ nfsd_fhtovp(struct nfsrv_descript *nd, s VFS_UNLOCK_GIANT(mp); exp->nes_vfslocked = 0; } - vfs_rel(mp); *vpp = NULL; *mpp = NULL; - } else { - vfs_rel(mp); } } @@ -2780,10 +2778,11 @@ nfsvno_getvp(fhandle_t *fhp) struct vnode *vp; int error; - mp = vfs_getvfs(&fhp->fh_fsid); + mp = vfs_busyfs(&fhp->fh_fsid); if (mp == NULL) return (NULL); error = VFS_FHTOVP(mp, &fhp->fh_fid, &vp); + vfs_unbusy(mp); if (error) return (NULL); return (vp); From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 18:55:07 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4552C106564A; Wed, 5 Jan 2011 18:55:07 +0000 (UTC) (envelope-from bzeeb-lists@lists.zabbadoz.net) Received: from mail.cksoft.de (mail.cksoft.de [IPv6:2001:4068:10::3]) by mx1.freebsd.org (Postfix) with ESMTP id F21DE8FC19; Wed, 5 Jan 2011 18:55:06 +0000 (UTC) Received: from localhost (amavis.fra.cksoft.de [192.168.74.71]) by mail.cksoft.de (Postfix) with ESMTP id 546BB41C757; Wed, 5 Jan 2011 19:55:06 +0100 (CET) X-Virus-Scanned: amavisd-new at cksoft.de Received: from mail.cksoft.de ([192.168.74.103]) by localhost (amavis.fra.cksoft.de [192.168.74.71]) (amavisd-new, port 10024) with ESMTP id TyRkjdvNv+X4; Wed, 5 Jan 2011 19:55:05 +0100 (CET) Received: by mail.cksoft.de (Postfix, from userid 66) id AC19241C74D; Wed, 5 Jan 2011 19:55:05 +0100 (CET) Received: from maildrop.int.zabbadoz.net (maildrop.int.zabbadoz.net [10.111.66.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.int.zabbadoz.net (Postfix) with ESMTP id 2143A4448F3; Wed, 5 Jan 2011 18:54:45 +0000 (UTC) Date: Wed, 5 Jan 2011 18:54:44 +0000 (UTC) From: "Bjoern A. Zeeb" X-X-Sender: bz@maildrop.int.zabbadoz.net To: Juli Mallett In-Reply-To: <201101041909.p04J95i8051538@svn.freebsd.org> Message-ID: <20110105185309.N14966@maildrop.int.zabbadoz.net> References: <201101041909.p04J95i8051538@svn.freebsd.org> X-OpenPGP-Key: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216969 - head/sys/mips/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 18:55:07 -0000 On Tue, 4 Jan 2011, Juli Mallett wrote: > Author: jmallett > Date: Tue Jan 4 19:09:05 2011 > New Revision: 216969 > URL: http://svn.freebsd.org/changeset/base/216969 > > Log: > Remove OCTEON1-32. Since moving to the Cavium SDK, we've lost our support for > running an o32 kernel safely, and would have to add interrupt disabling and > reenabling to a bunch of macros in the Simple Executive sources to support it. > > The only reason one would run an o32 kernel on Octeon would be to run o32 world, > which is better worked towards by adding o32 binary compatibility to n64 kernels > along with, eventually, supporting multilib systems so o32 binaries can run > alongside n32 and n64 ones. > > Discussed with: imp Thanks for fixing. Can anyone look at MALTA64 OCTEON1 SWARM64 SWARM64_SMP and XLR64 as well? Those seem to be the last kernels failing on universe now. > Deleted: > head/sys/mips/conf/OCTEON1-32 > -- Bjoern A. Zeeb You have to have visions! Going to jail sucks -- All my daemons like it! http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/jails.html From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 18:59:44 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 91BC41065670; Wed, 5 Jan 2011 18:59:44 +0000 (UTC) Date: Wed, 5 Jan 2011 18:59:44 +0000 From: Alexander Best To: Dimitry Andric Message-ID: <20110105185944.GA30449@freebsd.org> References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> <4D246444.1060904@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D246444.1060904@FreeBSD.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 18:59:44 -0000 On Wed Jan 5 11, Dimitry Andric wrote: > On 2011-01-05 02:16, Alexander Best wrote: > >the sorting order for these flags seems to be: > > > >-mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > > > >see 'grep -R "\-no-sse" /usr/src'. maybe the sorting order should stay > >consistent? > > I copied the order from sys/conf/kern.mk, lines 69 and 70: > > -mfpmath=387 -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow \ > -msoft-float -fno-asynchronous-unwind-tables > > I don't particularly care about the order, though. The order you found > seems to be the historical order. If people prefer to have the same > order everywhere, I'll fix it. judging from the discussion going on right now it seems those flags will be grouped together to form a new variable. so things will probably change shortly and fixing the order is probably not necessary. however if in fact new switches are being added to CFLAGS for clang it might be a good idea to have them sorted consistently or the chances of missing flags might increase. if you e.g. define all the -mno-xxx flags clang supports, you want to stick to one order. otherwise it will be very had to spot a missing flags between ~ 20 unsorted flags. > > > >also what's the status of clang? will these flags make sure that newer > >cpu extension won't be activated? i checked > >contrib/llvm/tools/clang/include/clang/Driver/Options.td > >and clang has support for: > > > >-m3dnowa > >-mssse3 > >-msse4a > >-msse4 > >-msse4_1 > >-msse4_2 > >-maes > >-mavx > > The in-tree clang has support for these "-mno-xxx" options: > > -mno_3dnow > -mno_3dnowa > -mno_aes > -mno_avx > -mno_constant_cfstrings > -mno_mmx > -mno_omit_leaf_frame_pointer > -mno_pascal_strings > -mno_red_zone > -mno_relax_all > -mno_soft_float > -mno_sse > -mno_sse2 > -mno_sse3 > -mno_sse4 > -mno_sse4_1 > -mno_sse4_2 > -mno_sse4a > -mno_ssse3 > -mno_thumb > -mno_warn_nonportable_cfstrings > > so I think you just looked incorrectly. :) *lol* you're right. i'm not that much of a cpu guru so i wasn't sure about the meaning of most of the flags and whether they are cpu related or not. > > > >since these extensions only get set in a hand full of files maybe special > >cases for CC == clang can be added. > > I don't think it's necessary. Maybe there could be one central > definition (say, in share/sys.mk) for the flags that disable all > 'special' features, e.g. for amd64 and i386: > > CFLAGS_CONSERVATIVE=-mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > -msoft-float judging from the discussion going on right now this seems to be the best solution...even if more cases need to be considered for different architectures. some people have proposed hacking into clang which i personally think is a very bad idea. why not contact the clang developers? they might like the idea of a switch disabling all advanced extensions for every architecture? > > Similar flags could be defined for other arches too. > > > >also maybe you could have a look at the attached patch. i sent this to > >hackers@ > >and nobody objected, but nobody wanted to commit the patch unfortunately. > > @@ -26,7 +26,6 @@ CFLAGS= -DBOOTPROG=\"gptboot\" \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -DGPT \ > -D${GPTBOOT_UFS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > > Ehm, this looks wrong, those options should not be removed for anything > in sys/boot. Boot programs should normally refrain from using any > advanced CPU instructions. What did you want to achieve with this > patch? these flags are already being defined in sys/boot/{i386,pc98}/Makefile.inc so it doesn't seem necessary to also have them in the other makefiles. you should be able to verify this quite easily: before applying the patch cd to /usr/src/sys/boot and do: for i in amd64 arm i386 ia64 mips pc98 powerpc sparc64 sun4v; do make TARGET=$i ; make TARGET=$i clean; done > ~/no-patch 2>&1 then apply the patch and rerun the command: for i in amd64 arm i386 ia64 mips pc98 powerpc sparc64 sun4v; do make TARGET=$i ; make TARGET=$i clean; done > ~/with-patch 2>&1 then do diff -ru0N with-patch no-patch > differ if you have a look at differ you can see that without the patch -mno-mmx, -mno-3dnow, -mno-sse, -mno-sse2, -mno-sse3 get added twice to some commands. with the patch they only get added once to the corresponding commands. cheers. alex -- a13x From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 18:59:59 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D514B1065673; Wed, 5 Jan 2011 18:59:59 +0000 (UTC) (envelope-from pawel@dawidek.net) Received: from mail.garage.freebsd.pl (60.wheelsystems.com [83.12.187.60]) by mx1.freebsd.org (Postfix) with ESMTP id 7EEFA8FC0A; Wed, 5 Jan 2011 18:59:59 +0000 (UTC) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id CFBBE45E49; Wed, 5 Jan 2011 19:59:57 +0100 (CET) Received: from localhost (89-73-192-49.dynamic.chello.pl [89.73.192.49]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id 0A8BF45CAC; Wed, 5 Jan 2011 19:59:51 +0100 (CET) Date: Wed, 5 Jan 2011 19:59:46 +0100 From: Pawel Jakub Dawidek To: Lawrence Stewart Message-ID: <20110105185946.GB1843@garage.freebsd.pl> References: <201101051149.p05BnNic076835@svn.freebsd.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="O5XBE6gyVG5Rl6Rj" Content-Disposition: inline In-Reply-To: <201101051149.p05BnNic076835@svn.freebsd.org> User-Agent: Mutt/1.4.2.3i X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 9.0-CURRENT amd64 X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-0.6 required=4.5 tests=BAYES_00,RCVD_IN_SORBS_DUL autolearn=no version=3.0.4 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216995 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 18:59:59 -0000 --O5XBE6gyVG5Rl6Rj Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jan 05, 2011 at 11:49:23AM +0000, Lawrence Stewart wrote: > Author: lstewart > Date: Wed Jan 5 11:49:23 2011 > New Revision: 216995 > URL: http://svn.freebsd.org/changeset/base/216995 >=20 > Log: > Add a man page for the Object Specific Data (OSD) KPI. Thank you! --=20 Pawel Jakub Dawidek http://www.wheelsystems.com pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --O5XBE6gyVG5Rl6Rj Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAk0kv6IACgkQForvXbEpPzScEwCdG5iPi+1342EsPPHOuf09rXZb AzUAnRfbpMs50D1FI20Q9rVAQh2Xmms2 =InMx -----END PGP SIGNATURE----- --O5XBE6gyVG5Rl6Rj-- From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 19:10:07 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 59D461065672; Wed, 5 Jan 2011 19:10:07 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mail.cksoft.de (mail.cksoft.de [IPv6:2001:4068:10::3]) by mx1.freebsd.org (Postfix) with ESMTP id 02F328FC0C; Wed, 5 Jan 2011 19:10:07 +0000 (UTC) Received: from localhost (amavis.fra.cksoft.de [192.168.74.71]) by mail.cksoft.de (Postfix) with ESMTP id 5849D41C64A; Wed, 5 Jan 2011 20:10:06 +0100 (CET) X-Virus-Scanned: amavisd-new at cksoft.de Received: from mail.cksoft.de ([192.168.74.103]) by localhost (amavis.fra.cksoft.de [192.168.74.71]) (amavisd-new, port 10024) with ESMTP id bXToCCiXBkhZ; Wed, 5 Jan 2011 20:10:05 +0100 (CET) Received: by mail.cksoft.de (Postfix, from userid 66) id D97CA41C62D; Wed, 5 Jan 2011 20:10:05 +0100 (CET) Received: from maildrop.int.zabbadoz.net (maildrop.int.zabbadoz.net [10.111.66.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.int.zabbadoz.net (Postfix) with ESMTP id 5F05F4448F3; Wed, 5 Jan 2011 19:09:10 +0000 (UTC) Date: Wed, 5 Jan 2011 19:09:10 +0000 (UTC) From: "Bjoern A. Zeeb" X-X-Sender: bz@maildrop.int.zabbadoz.net To: Marius Strobl In-Reply-To: <20110105155513.GA97101@alchemy.franken.de> Message-ID: <20110105185451.W14966@maildrop.int.zabbadoz.net> References: <201101051528.p05FSVPL082696@svn.freebsd.org> <20110105153107.X14966@maildrop.int.zabbadoz.net> <20110105155513.GA97101@alchemy.franken.de> X-OpenPGP-Key: 0x14003F198FEFA3E77207EE8D2B58B8F83CCF1842 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r217013 - in head: sbin/ifconfig sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 19:10:07 -0000 On Wed, 5 Jan 2011, Marius Strobl wrote: > On Wed, Jan 05, 2011 at 03:34:30PM +0000, Bjoern A. Zeeb wrote: >> On Wed, 5 Jan 2011, Marius Strobl wrote: >> >>> Author: marius >>> Date: Wed Jan 5 15:28:30 2011 >>> New Revision: 217013 >>> URL: http://svn.freebsd.org/changeset/base/217013 >>> >>> Log: >>> Teach ifconfig(8) the handy shared option shortcut aliases the NetBSD >>> counterpart also takes, i.e. "fdx" for "full-duplex", "flow" for >>> "flowcontrol", "hdx" for "half-duplex" as well as "loop" and "loopback" >>> for "hw-loopback". >> >> I am not sure this is a good idea. Unless this is really really >> useful for compatibility with scripts (which I doubt) it'll sooner or >> later cause headaches, especially given some of the (new) names could >> be very well used for different things as well. > > Could you please elaborate on what different use you have in mind? > Generally it seems a bad idea to me if the existing options and the > new names as implemented would trigger different things as you suggest > given the latter are rather common abbreviations as well as diverging > from the user interface of the other BSDs seems like a bad idea (i.e. > not only not supporting the same names they do but also controlling > different things with a given one). Also the concept of aliases taken > by ifconfig(8) isn't new, we support several including f.e. "auto" for > "autoselect" for quite some time. "flow" is a term used at other layers as well and really different to flow control. We are not only seeing discussions about flowid usage in IPv6 but also people trying to control "ULP flows" on NICs (RSS). loop and loopback sound bad as well, especially as I could only see one man page in man4 (tl.4) that actually references it. My worries are just that people will confuse those things with other options outside of media-opts. I guess I have no problem with fdx and hdx but you will see a mix other either showing up then in scripts and man pages and that'll give an incosistent view to users and confuse them as well (especially since those options are all descriped with the driver's man pages rather than having a global list [if needed with aliases] in ifconfig then refering to the driver man pages to see which of those a driver actually supports). To give you an example -- "add" is an alias for "alias" with inet, and people are writing alias where add should be (different places on the command line) which leads to confusion as it shouldn't work there and doesn't for IPv6. Much confusion for years. /bz -- Bjoern A. Zeeb You have to have visions! Going to jail sucks -- All my daemons like it! http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/jails.html From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 19:11:12 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id DA3B310656A4; Wed, 5 Jan 2011 19:11:12 +0000 (UTC) Date: Wed, 5 Jan 2011 19:11:12 +0000 From: Alexander Best To: John Baldwin Message-ID: <20110105191112.GB30449@freebsd.org> References: <201101042051.p04KpSGk054564@svn.freebsd.org> <4D248540.3030602@freebsd.org> <4D24888B.50305@FreeBSD.org> <201101051146.26723.jhb@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101051146.26723.jhb@freebsd.org> Cc: Gleb Kurtsou , src-committers@freebsd.org, svn-src-all@freebsd.org, Dimitry Andric , Nathan Whitehorn , svn-src-head@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 19:11:12 -0000 On Wed Jan 5 11, John Baldwin wrote: > On Wednesday, January 05, 2011 10:04:43 am Dimitry Andric wrote: > > On 2011-01-05 15:50, Nathan Whitehorn wrote: > > > You would also want this to be cross-platform, in which case it's more > > > than floating point. E.g. on powerpc, you also want to disable both FP > > > and vector extensions, which use separate sets of instructions and > > > registers. > > > > Yeah, but in any case, hacking the compiler itself is not the proper way > > to achieve this goal, IMHO. It should go into sys.mk, or more > > appropriately bsd.cpu.mk. I'll make a crude diff for this tonight. > > I think this is a workaround for a deficiency in the compiler, and one we are > probably stuck with. But it sure would be nice to have in the compiler. ehm...i'm not an expert on clang, but why not ask the clang developers to add a switch to disable all floating point extensions and for archs that use it another switch to disable vector extensions? it seems the clang developers are very open minded and open to new ideas. cheers. alex > > -- > John Baldwin -- a13x From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 19:35:35 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9F0F51065696; Wed, 5 Jan 2011 19:35:35 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7378A8FC0C; Wed, 5 Jan 2011 19:35:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05JZZ35088900; Wed, 5 Jan 2011 19:35:35 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05JZZMa088898; Wed, 5 Jan 2011 19:35:35 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101051935.p05JZZMa088898@svn.freebsd.org> From: Rick Macklem Date: Wed, 5 Jan 2011 19:35:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217023 - head/sys/fs/nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 19:35:35 -0000 Author: rmacklem Date: Wed Jan 5 19:35:35 2011 New Revision: 217023 URL: http://svn.freebsd.org/changeset/base/217023 Log: Modify the experimental NFS server so that it calls vn_start_write() with a non-NULL vp. That way it will find the correct mount point mp and use that mp for the subsequent vn_finished_write() call. Also, it should fail without crashing if the mount point is being forced dismounted because vn_start_write() will set the mp NULL via VOP_GETWRITEMOUNT(). Reviewed by: kib MFC after: 12 days Modified: head/sys/fs/nfsserver/nfs_nfsdsocket.c Modified: head/sys/fs/nfsserver/nfs_nfsdsocket.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdsocket.c Wed Jan 5 19:33:16 2011 (r217022) +++ head/sys/fs/nfsserver/nfs_nfsdsocket.c Wed Jan 5 19:35:35 2011 (r217023) @@ -498,7 +498,7 @@ nfsrvd_compound(struct nfsrv_descript *n u_char tag[NFSV4_SMALLSTR + 1], *tagstr; vnode_t vp, nvp, savevp; struct nfsrvfh fh; - mount_t mp, savemp; + mount_t mp, savemp, temp_mp = NULL; struct ucred *credanon; struct nfsexstuff nes, vpnes, savevpnes; static u_int64_t compref = 0; @@ -837,7 +837,7 @@ nfsrvd_compound(struct nfsrv_descript *n } VREF(vp); if (nfsv4_opflag[op].modifyfs) - NFS_STARTWRITE(NULL, &mp); + vn_start_write(vp, &temp_mp, V_WAIT); error = (*(nfsrv4_ops1[op]))(nd, isdgram, vp, &nvp, (fhandle_t *)fh.nfsrvfh_data, p, &vpnes); if (!error && !nd->nd_repstat) { @@ -871,7 +871,7 @@ nfsrvd_compound(struct nfsrv_descript *n vrele(nvp); } if (nfsv4_opflag[op].modifyfs) - NFS_ENDWRITE(mp); + vn_finished_write(temp_mp); } else if (nfsv4_opflag[op].retfh == 2) { if (vp == NULL || savevp == NULL) { nd->nd_repstat = NFSERR_NOFILEHANDLE; @@ -881,7 +881,7 @@ nfsrvd_compound(struct nfsrv_descript *n break; } if (nfsv4_opflag[op].modifyfs) - NFS_STARTWRITE(NULL, &mp); + vn_start_write(savevp, &temp_mp, V_WAIT); if (vn_lock(savevp, LK_EXCLUSIVE) == 0) { VREF(vp); VREF(savevp); @@ -890,14 +890,15 @@ nfsrvd_compound(struct nfsrv_descript *n } else nd->nd_repstat = NFSERR_PERM; if (nfsv4_opflag[op].modifyfs) - NFS_ENDWRITE(mp); + vn_finished_write(temp_mp); } else { if (nfsv4_opflag[op].retfh != 0) panic("nfsrvd_compound"); if (nfsv4_opflag[op].needscfh) { if (vp != NULL) { if (nfsv4_opflag[op].modifyfs) - NFS_STARTWRITE(NULL, &mp); + vn_start_write(vp, &temp_mp, + V_WAIT); if (vn_lock(vp, nfsv4_opflag[op].lktype) == 0) VREF(vp); @@ -921,7 +922,7 @@ nfsrvd_compound(struct nfsrv_descript *n error = (*(nfsrv4_ops0[op]))(nd, isdgram, vp, p, &vpnes); if (nfsv4_opflag[op].modifyfs) - NFS_ENDWRITE(mp); + vn_finished_write(temp_mp); } else { error = (*(nfsrv4_ops0[op]))(nd, isdgram, NULL, p, &vpnes); From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 19:40:02 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E78671065695; Wed, 5 Jan 2011 19:40:02 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail04.syd.optusnet.com.au (mail04.syd.optusnet.com.au [211.29.132.185]) by mx1.freebsd.org (Postfix) with ESMTP id 651B48FC1A; Wed, 5 Jan 2011 19:40:01 +0000 (UTC) Received: from c122-106-165-206.carlnfd1.nsw.optusnet.com.au (c122-106-165-206.carlnfd1.nsw.optusnet.com.au [122.106.165.206]) by mail04.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p05Jdw3n004391 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 6 Jan 2011 06:39:59 +1100 Date: Thu, 6 Jan 2011 06:39:58 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: John Baldwin In-Reply-To: <201101051144.56940.jhb@freebsd.org> Message-ID: <20110106062530.Y1027@besplex.bde.org> References: <201101041316.p04DGSo6037042@svn.freebsd.org> <201101041314.08949.jhb@freebsd.org> <20110105161720.GA1388@a91-153-123-205.elisa-laajakaista.fi> <201101051144.56940.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@FreeBSD.org, Jaakko Heinonen , svn-src-all@FreeBSD.org, src-committers@FreeBSD.org, Julian Elischer Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 19:40:03 -0000 On Wed, 5 Jan 2011, John Baldwin wrote: > On Wednesday, January 05, 2011 11:17:20 am Jaakko Heinonen wrote: >> On 2011-01-04, John Baldwin wrote: >>> Err, no, the point of NOTREACHED is to serve as documentation for lint(1), but >>> that has subsequently been obsoleted by __dead2. >> >> style(9) is out of date then? > > According to bde@'s most recent e-mails, yes. It's obviously out of date, since its only example of using NOTREACHED is after a usage() call, and this usage is missing a __dead2. Of course it doesn't use NOTREACHED after its 3 exit() calls or its 2 err() calls or its 1 errx() call, so its "should" requirement for using NOTREACHED is mostly not satisfied by itself. Bruce From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 19:59:24 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B14441065679 for ; Wed, 5 Jan 2011 19:59:24 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx22.fluidhosting.com [204.14.89.5]) by mx1.freebsd.org (Postfix) with ESMTP id 3FB348FC2A for ; Wed, 5 Jan 2011 19:59:23 +0000 (UTC) Received: (qmail 2844 invoked by uid 399); 5 Jan 2011 19:59:21 -0000 Received: from localhost (HELO doug-optiplex.ka9q.net) (dougb@dougbarton.us@127.0.0.1) by localhost with ESMTPAM; 5 Jan 2011 19:59:21 -0000 X-Originating-IP: 127.0.0.1 X-Sender: dougb@dougbarton.us Message-ID: <4D24CD98.9080906@FreeBSD.org> Date: Wed, 05 Jan 2011 11:59:20 -0800 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101210 Thunderbird/3.1.7 MIME-Version: 1.0 To: Alexander Best References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> <4D246444.1060904@FreeBSD.org> <20110105185944.GA30449@freebsd.org> In-Reply-To: <20110105185944.GA30449@freebsd.org> X-Enigmail-Version: 1.1.2 OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Dimitry Andric Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 19:59:24 -0000 On 01/05/2011 10:59, Alexander Best wrote: > judging from the discussion going on right now it seems those flags will be > grouped together to form a new variable. so things will probably change shortly > and fixing the order is probably not necessary. Much better to fix the problem properly now than to rely on future work that may or may not happen. I realize that you alluded to this later in your message, but I think as a general principle this is worth reinforcing. > some people have proposed hacking into clang which i personally think is a very > bad idea. why not contact the clang developers? they might like the idea of a > switch disabling all advanced extensions for every architecture? I agree with this. We have a very awkward situation right now with lots of local hacks in our version of gcc that in an ideal world we would not replicate with clang; particularly considering the much lower barrier to entry when it comes to contributing things back. Doug -- Nothin' ever doesn't change, but nothin' changes much. -- OK Go Breadth of IT experience, and depth of knowledge in the DNS. Yours for the right price. :) http://SupersetSolutions.com/ From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 20:16:46 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A8A89106566B; Wed, 5 Jan 2011 20:16:46 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 75A968FC12; Wed, 5 Jan 2011 20:16:46 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 10C6146B4C; Wed, 5 Jan 2011 15:16:46 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 199CB8A009; Wed, 5 Jan 2011 15:16:45 -0500 (EST) From: John Baldwin To: Doug Barton Date: Wed, 5 Jan 2011 15:08:40 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105185944.GA30449@freebsd.org> <4D24CD98.9080906@FreeBSD.org> In-Reply-To: <4D24CD98.9080906@FreeBSD.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201101051508.40337.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 15:16:45 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, Alexander Best , svn-src-all@freebsd.org, src-committers@freebsd.org, Dimitry Andric Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 20:16:46 -0000 On Wednesday, January 05, 2011 2:59:20 pm Doug Barton wrote: > On 01/05/2011 10:59, Alexander Best wrote: > > > judging from the discussion going on right now it seems those flags will be > > grouped together to form a new variable. so things will probably change shortly > > and fixing the order is probably not necessary. > > Much better to fix the problem properly now than to rely on future work > that may or may not happen. I realize that you alluded to this later in > your message, but I think as a general principle this is worth reinforcing. > > > some people have proposed hacking into clang which i personally think is a very > > bad idea. why not contact the clang developers? they might like the idea of a > > switch disabling all advanced extensions for every architecture? > > I agree with this. We have a very awkward situation right now with lots > of local hacks in our version of gcc that in an ideal world we would not > replicate with clang; particularly considering the much lower barrier to > entry when it comes to contributing things back. My suggestion was that we ask clang to add a '-mno-whatever' and hopefully we could convince gcc to follow suit. clang developers seem to be fairly receptive, so I was hoping one of our clang liaisons could suggest it. :) -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 20:26:29 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A779C106577D; Wed, 5 Jan 2011 20:26:29 +0000 (UTC) (envelope-from juli@clockworksquid.com) Received: from mail-yw0-f54.google.com (mail-yw0-f54.google.com [209.85.213.54]) by mx1.freebsd.org (Postfix) with ESMTP id 45C8E8FC14; Wed, 5 Jan 2011 20:26:29 +0000 (UTC) Received: by ywp6 with SMTP id 6so6670577ywp.13 for ; Wed, 05 Jan 2011 12:26:28 -0800 (PST) Received: by 10.236.108.41 with SMTP id p29mr5521193yhg.21.1294257347249; Wed, 05 Jan 2011 11:55:47 -0800 (PST) MIME-Version: 1.0 Sender: juli@clockworksquid.com Received: by 10.236.108.51 with HTTP; Wed, 5 Jan 2011 11:55:26 -0800 (PST) In-Reply-To: <20110105185309.N14966@maildrop.int.zabbadoz.net> References: <201101041909.p04J95i8051538@svn.freebsd.org> <20110105185309.N14966@maildrop.int.zabbadoz.net> From: Juli Mallett Date: Wed, 5 Jan 2011 11:55:26 -0800 X-Google-Sender-Auth: F4AI0EU2zDsOwwwL8dgtAVYVWUE Message-ID: To: "Bjoern A. Zeeb" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216969 - head/sys/mips/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 20:26:29 -0000 On Wed, Jan 5, 2011 at 10:54, Bjoern A. Zeeb wrote: > Thanks for fixing. > > Can anyone look at MALTA64 OCTEON1 SWARM64 SWARM64_SMP and XLR64 as > well? =A0Those seem to be the last kernels failing on universe now. 64-bit kernels are broken in make universe because we don't simply ignore kernels with unknown TARGET_ARCH values; that's probably the right thing to do until someone checks in changes to eliminate TARGET_ABI and support TARGET_ARCH for non-o32 ABIs instead. Thanks, Juli. From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 20:29:58 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 50263106566B; Wed, 5 Jan 2011 20:29:58 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id 071428FC13; Wed, 5 Jan 2011 20:29:58 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:55f7:2f68:9ecc:13f4] (unknown [IPv6:2001:7b8:3a7:0:55f7:2f68:9ecc:13f4]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id CA0D65C5A; Wed, 5 Jan 2011 21:29:56 +0100 (CET) Message-ID: <4D24D4C5.2020903@FreeBSD.org> Date: Wed, 05 Jan 2011 21:29:57 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.14pre) Gecko/20110104 Lanikai/3.1.8pre MIME-Version: 1.0 To: John Baldwin References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105185944.GA30449@freebsd.org> <4D24CD98.9080906@FreeBSD.org> <201101051508.40337.jhb@freebsd.org> In-Reply-To: <201101051508.40337.jhb@freebsd.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, Alexander Best , svn-src-all@freebsd.org, Doug Barton , src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 20:29:58 -0000 On 2011-01-05 21:08, John Baldwin wrote: > My suggestion was that we ask clang to add a '-mno-whatever' and hopefully we > could convince gcc to follow suit. clang developers seem to be fairly > receptive, so I was hoping one of our clang liaisons could suggest it. :) These options already exist, e.g -mno-sse -mno-sse2 and so on. The semantics of -mno-everything would be a bit hard to predict, especially with new instruction sets coming out all the time. :) From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 20:38:16 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 3DF481065672; Wed, 5 Jan 2011 20:38:16 +0000 (UTC) Date: Wed, 5 Jan 2011 20:38:16 +0000 From: Alexander Best To: John Baldwin Message-ID: <20110105203816.GA54929@freebsd.org> References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105185944.GA30449@freebsd.org> <4D24CD98.9080906@FreeBSD.org> <201101051508.40337.jhb@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101051508.40337.jhb@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, Doug Barton , Dimitry Andric , src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 20:38:16 -0000 On Wed Jan 5 11, John Baldwin wrote: > On Wednesday, January 05, 2011 2:59:20 pm Doug Barton wrote: > > On 01/05/2011 10:59, Alexander Best wrote: > > > > > judging from the discussion going on right now it seems those flags will be > > > grouped together to form a new variable. so things will probably change shortly > > > and fixing the order is probably not necessary. > > > > Much better to fix the problem properly now than to rely on future work > > that may or may not happen. I realize that you alluded to this later in > > your message, but I think as a general principle this is worth reinforcing. > > > > > some people have proposed hacking into clang which i personally think is a very > > > bad idea. why not contact the clang developers? they might like the idea of a > > > switch disabling all advanced extensions for every architecture? > > > > I agree with this. We have a very awkward situation right now with lots > > of local hacks in our version of gcc that in an ideal world we would not > > replicate with clang; particularly considering the much lower barrier to > > entry when it comes to contributing things back. > > My suggestion was that we ask clang to add a '-mno-whatever' and hopefully we > could convince gcc to follow suit. clang developers seem to be fairly > receptive, so I was hoping one of our clang liaisons could suggest it. :) why gcc? even if they decide to add such a switch it will be gpl3'ed. shouldn't gcc with clang at hand be considered legacy software? cheers. alex ps: btw there is a patch in GNATS which bumps base gcc to the very last revision which didn't include gplv3. i think the patch fixes quite a few issues: 153298. also it seems apple is maintaining a gcc branch which has a lot of improvements, yet it is based on gcc 4.2.1 and thus licensed under gplv2. i'm not sure if it is avalable somewhere, but having a peek at the changes they made would in fact be nice. still i don't think tackling base gcc is worth the hassle, since that time could be spent much better improving clang. > > -- > John Baldwin -- a13x From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 20:50:36 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id C928D1065674; Wed, 5 Jan 2011 20:50:36 +0000 (UTC) Date: Wed, 5 Jan 2011 20:50:36 +0000 From: Alexander Best To: Doug Barton Message-ID: <20110105205036.GA58175@freebsd.org> References: <201101042051.p04KpSGk054564@svn.freebsd.org> <20110105011635.GA4952@freebsd.org> <4D246444.1060904@FreeBSD.org> <20110105185944.GA30449@freebsd.org> <4D24CD98.9080906@FreeBSD.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="Qxx1br4bt0+wmkIi" Content-Disposition: inline In-Reply-To: <4D24CD98.9080906@FreeBSD.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Dimitry Andric Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 20:50:36 -0000 --Qxx1br4bt0+wmkIi Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed Jan 5 11, Doug Barton wrote: > On 01/05/2011 10:59, Alexander Best wrote: > > >judging from the discussion going on right now it seems those flags will be > >grouped together to form a new variable. so things will probably change > >shortly > >and fixing the order is probably not necessary. > > Much better to fix the problem properly now than to rely on future work > that may or may not happen. I realize that you alluded to this later in > your message, but I think as a general principle this is worth reinforcing. this patch should make all the -mno-* flags be sorted conistently. cheers. alex > > >some people have proposed hacking into clang which i personally think is a > >very > >bad idea. why not contact the clang developers? they might like the idea > >of a > >switch disabling all advanced extensions for every architecture? > > I agree with this. We have a very awkward situation right now with lots > of local hacks in our version of gcc that in an ideal world we would not > replicate with clang; particularly considering the much lower barrier to > entry when it comes to contributing things back. > > > Doug > > -- > > Nothin' ever doesn't change, but nothin' changes much. > -- OK Go > > Breadth of IT experience, and depth of knowledge in the DNS. > Yours for the right price. :) http://SupersetSolutions.com/ -- a13x --Qxx1br4bt0+wmkIi Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="sse3.diff" diff --git a/libexec/rtld-elf/amd64/Makefile.inc b/libexec/rtld-elf/amd64/Makefile.inc index 7d68611..7528dbe 100644 --- a/libexec/rtld-elf/amd64/Makefile.inc +++ b/libexec/rtld-elf/amd64/Makefile.inc @@ -1,6 +1,6 @@ # $FreeBSD$ -CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x diff --git a/libexec/rtld-elf/i386/Makefile.inc b/libexec/rtld-elf/i386/Makefile.inc index 7d68611..7528dbe 100644 --- a/libexec/rtld-elf/i386/Makefile.inc +++ b/libexec/rtld-elf/i386/Makefile.inc @@ -1,6 +1,6 @@ # $FreeBSD$ -CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk index 4d8636c..61f814d 100644 --- a/sys/conf/kern.mk +++ b/sys/conf/kern.mk @@ -66,7 +66,7 @@ INLINE_LIMIT?= 15000 # .if ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mcmodel=kernel -mno-red-zone \ - -mfpmath=387 -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow \ + -mfpmath=387 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -msoft-float -fno-asynchronous-unwind-tables INLINE_LIMIT?= 8000 .endif --Qxx1br4bt0+wmkIi-- From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 20:58:31 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4E3F3106566C; Wed, 5 Jan 2011 20:58:31 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 201B38FC14; Wed, 5 Jan 2011 20:58:31 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id D806346B2C; Wed, 5 Jan 2011 15:58:30 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 5FAB68A009; Wed, 5 Jan 2011 15:58:29 -0500 (EST) From: John Baldwin To: Dimitry Andric Date: Wed, 5 Jan 2011 15:54:29 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101042051.p04KpSGk054564@svn.freebsd.org> <201101051508.40337.jhb@freebsd.org> <4D24D4C5.2020903@FreeBSD.org> In-Reply-To: <4D24D4C5.2020903@FreeBSD.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201101051554.29814.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 15:58:29 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, Alexander Best , svn-src-all@freebsd.org, Doug Barton , src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 20:58:31 -0000 On Wednesday, January 05, 2011 3:29:57 pm Dimitry Andric wrote: > On 2011-01-05 21:08, John Baldwin wrote: > > My suggestion was that we ask clang to add a '-mno-whatever' and hopefully we > > could convince gcc to follow suit. clang developers seem to be fairly > > receptive, so I was hoping one of our clang liaisons could suggest it. :) > > These options already exist, e.g -mno-sse -mno-sse2 and so on. The > semantics of -mno-everything would be a bit hard to predict, especially > with new instruction sets coming out all the time. :) That's actually the point. I would want the compiler to automatically add new register set options to -mno-everything when it grew support for them so we don't have to frob the Makefiles every time. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 20:58:32 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 74657106564A; Wed, 5 Jan 2011 20:58:32 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 435978FC15; Wed, 5 Jan 2011 20:58:32 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id F0C5146B38; Wed, 5 Jan 2011 15:58:31 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id E81228A01D; Wed, 5 Jan 2011 15:58:30 -0500 (EST) From: John Baldwin To: Alexander Best Date: Wed, 5 Jan 2011 15:55:45 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101042051.p04KpSGk054564@svn.freebsd.org> <201101051508.40337.jhb@freebsd.org> <20110105203816.GA54929@freebsd.org> In-Reply-To: <20110105203816.GA54929@freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201101051555.45419.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Wed, 05 Jan 2011 15:58:31 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, Doug Barton , Dimitry Andric , src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 20:58:32 -0000 On Wednesday, January 05, 2011 3:38:16 pm Alexander Best wrote: > On Wed Jan 5 11, John Baldwin wrote: > > On Wednesday, January 05, 2011 2:59:20 pm Doug Barton wrote: > > > On 01/05/2011 10:59, Alexander Best wrote: > > > > > > > judging from the discussion going on right now it seems those flags will be > > > > grouped together to form a new variable. so things will probably change shortly > > > > and fixing the order is probably not necessary. > > > > > > Much better to fix the problem properly now than to rely on future work > > > that may or may not happen. I realize that you alluded to this later in > > > your message, but I think as a general principle this is worth reinforcing. > > > > > > > some people have proposed hacking into clang which i personally think is a very > > > > bad idea. why not contact the clang developers? they might like the idea of a > > > > switch disabling all advanced extensions for every architecture? > > > > > > I agree with this. We have a very awkward situation right now with lots > > > of local hacks in our version of gcc that in an ideal world we would not > > > replicate with clang; particularly considering the much lower barrier to > > > entry when it comes to contributing things back. > > > > My suggestion was that we ask clang to add a '-mno-whatever' and hopefully we > > could convince gcc to follow suit. clang developers seem to be fairly > > receptive, so I was hoping one of our clang liaisons could suggest it. :) > > why gcc? even if they decide to add such a switch it will be gpl3'ed. shouldn't > gcc with clang at hand be considered legacy software? I think a more realistic view is that some folks will want to use a gpl3 toolchain (e.g. platforms clang doesn't support (or support well) which need newer binutils, etc.). The gpl3 bits don't have to live in the tree, but I think our build infrastructure should support using them as an external toolchain. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 21:03:37 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 6F3A91065674; Wed, 5 Jan 2011 21:03:37 +0000 (UTC) Date: Wed, 5 Jan 2011 21:03:37 +0000 From: Alexander Best To: John Baldwin Message-ID: <20110105210337.GA60416@freebsd.org> References: <201101042051.p04KpSGk054564@svn.freebsd.org> <201101051508.40337.jhb@freebsd.org> <20110105203816.GA54929@freebsd.org> <201101051555.45419.jhb@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101051555.45419.jhb@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, Doug Barton , Dimitry Andric , src-committers@freebsd.org Subject: Re: svn commit: r216977 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 21:03:37 -0000 On Wed Jan 5 11, John Baldwin wrote: > On Wednesday, January 05, 2011 3:38:16 pm Alexander Best wrote: > > On Wed Jan 5 11, John Baldwin wrote: > > > On Wednesday, January 05, 2011 2:59:20 pm Doug Barton wrote: > > > > On 01/05/2011 10:59, Alexander Best wrote: > > > > > > > > > judging from the discussion going on right now it seems those flags will be > > > > > grouped together to form a new variable. so things will probably change shortly > > > > > and fixing the order is probably not necessary. > > > > > > > > Much better to fix the problem properly now than to rely on future work > > > > that may or may not happen. I realize that you alluded to this later in > > > > your message, but I think as a general principle this is worth reinforcing. > > > > > > > > > some people have proposed hacking into clang which i personally think is a very > > > > > bad idea. why not contact the clang developers? they might like the idea of a > > > > > switch disabling all advanced extensions for every architecture? > > > > > > > > I agree with this. We have a very awkward situation right now with lots > > > > of local hacks in our version of gcc that in an ideal world we would not > > > > replicate with clang; particularly considering the much lower barrier to > > > > entry when it comes to contributing things back. > > > > > > My suggestion was that we ask clang to add a '-mno-whatever' and hopefully we > > > could convince gcc to follow suit. clang developers seem to be fairly > > > receptive, so I was hoping one of our clang liaisons could suggest it. :) > > > > why gcc? even if they decide to add such a switch it will be gpl3'ed. shouldn't > > gcc with clang at hand be considered legacy software? > > I think a more realistic view is that some folks will want to use a gpl3 > toolchain (e.g. platforms clang doesn't support (or support well) which > need newer binutils, etc.). The gpl3 bits don't have to live in the tree, > but I think our build infrastructure should support using them as an > external toolchain. good point. would be nice to be able to do echo "CC = gcc46" >> /etc/src.conf ... expecially for benchmarking clang vs. a recent gcc for world/kernel. cheers. alex > > -- > John Baldwin -- a13x From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 21:17:14 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AB558106564A; Wed, 5 Jan 2011 21:17:14 +0000 (UTC) (envelope-from osa@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9A6478FC17; Wed, 5 Jan 2011 21:17:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05LHEQQ091277; Wed, 5 Jan 2011 21:17:14 GMT (envelope-from osa@svn.freebsd.org) Received: (from osa@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05LHEi3091275; Wed, 5 Jan 2011 21:17:14 GMT (envelope-from osa@svn.freebsd.org) Message-Id: <201101052117.p05LHEi3091275@svn.freebsd.org> From: "Sergey A. Osokin" Date: Wed, 5 Jan 2011 21:17:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217025 - head/usr.bin/calendar X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 21:17:14 -0000 Author: osa (ports committer) Date: Wed Jan 5 21:17:14 2011 New Revision: 217025 URL: http://svn.freebsd.org/changeset/base/217025 Log: Fix typo: March -> September. Modified: head/usr.bin/calendar/calendar.1 Modified: head/usr.bin/calendar/calendar.1 ============================================================================== --- head/usr.bin/calendar/calendar.1 Wed Jan 5 19:53:48 2011 (r217024) +++ head/usr.bin/calendar/calendar.1 Wed Jan 5 21:17:14 2011 (r217025) @@ -128,7 +128,7 @@ The solar equinox in March. .It JunSolstice The solar solstice in June. .It SepEquinox -The solar equinox in March. +The solar equinox in September. .It DecSolstice The solar solstice in December. .It ChineseNewYear From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 21:23:27 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 338711065673; Wed, 5 Jan 2011 21:23:27 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 079D98FC0C; Wed, 5 Jan 2011 21:23:27 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05LNQlP091451; Wed, 5 Jan 2011 21:23:26 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05LNQr4091447; Wed, 5 Jan 2011 21:23:26 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201101052123.p05LNQr4091447@svn.freebsd.org> From: Dimitry Andric Date: Wed, 5 Jan 2011 21:23:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217026 - in head: libexec/rtld-elf/amd64 libexec/rtld-elf/i386 sys/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 21:23:27 -0000 Author: dim Date: Wed Jan 5 21:23:26 2011 New Revision: 217026 URL: http://svn.freebsd.org/changeset/base/217026 Log: Sort -mno-(mmx|3dnow|sse|sse2|sse3) options consistently throughout the tree. Submitted by: arundel Modified: head/libexec/rtld-elf/amd64/Makefile.inc head/libexec/rtld-elf/i386/Makefile.inc head/sys/conf/kern.mk Modified: head/libexec/rtld-elf/amd64/Makefile.inc ============================================================================== --- head/libexec/rtld-elf/amd64/Makefile.inc Wed Jan 5 21:17:14 2011 (r217025) +++ head/libexec/rtld-elf/amd64/Makefile.inc Wed Jan 5 21:23:26 2011 (r217026) @@ -1,6 +1,6 @@ # $FreeBSD$ -CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x Modified: head/libexec/rtld-elf/i386/Makefile.inc ============================================================================== --- head/libexec/rtld-elf/i386/Makefile.inc Wed Jan 5 21:17:14 2011 (r217025) +++ head/libexec/rtld-elf/i386/Makefile.inc Wed Jan 5 21:23:26 2011 (r217026) @@ -1,6 +1,6 @@ # $FreeBSD$ -CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float # Uncomment this to build the dynamic linker as an executable instead # of a shared library: #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x Modified: head/sys/conf/kern.mk ============================================================================== --- head/sys/conf/kern.mk Wed Jan 5 21:17:14 2011 (r217025) +++ head/sys/conf/kern.mk Wed Jan 5 21:23:26 2011 (r217026) @@ -66,7 +66,7 @@ INLINE_LIMIT?= 15000 # .if ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mcmodel=kernel -mno-red-zone \ - -mfpmath=387 -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow \ + -mfpmath=387 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -msoft-float -fno-asynchronous-unwind-tables INLINE_LIMIT?= 8000 .endif From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 21:29:10 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C7045106564A; Wed, 5 Jan 2011 21:29:10 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 853148FC17; Wed, 5 Jan 2011 21:29:10 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p05LND20020462; Wed, 5 Jan 2011 14:23:13 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D24E13F.3040807@bsdimp.com> Date: Wed, 05 Jan 2011 14:23:11 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: "Bjoern A. Zeeb" References: <201101041909.p04J95i8051538@svn.freebsd.org> <20110105185309.N14966@maildrop.int.zabbadoz.net> In-Reply-To: <20110105185309.N14966@maildrop.int.zabbadoz.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Juli Mallett , svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r216969 - head/sys/mips/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 21:29:10 -0000 On 01/05/2011 11:54, Bjoern A. Zeeb wrote: > On Tue, 4 Jan 2011, Juli Mallett wrote: > >> Author: jmallett >> Date: Tue Jan 4 19:09:05 2011 >> New Revision: 216969 >> URL: http://svn.freebsd.org/changeset/base/216969 >> >> Log: >> Remove OCTEON1-32. Since moving to the Cavium SDK, we've lost our >> support for >> running an o32 kernel safely, and would have to add interrupt >> disabling and >> reenabling to a bunch of macros in the Simple Executive sources to >> support it. >> >> The only reason one would run an o32 kernel on Octeon would be to >> run o32 world, >> which is better worked towards by adding o32 binary compatibility to >> n64 kernels >> along with, eventually, supporting multilib systems so o32 binaries >> can run >> alongside n32 and n64 ones. >> >> Discussed with: imp > > Thanks for fixing. > > Can anyone look at MALTA64 OCTEON1 SWARM64 SWARM64_SMP and XLR64 as > well? Those seem to be the last kernels failing on universe now. Yes. They are. In a n64 world they build fine. I'll look at the loops to see why they are even built, because they shouldn't be since we haven't integrated the n64 stuff into the MACHINE_ARCH name yet. Warner > > >> Deleted: >> head/sys/mips/conf/OCTEON1-32 >> > From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 21:34:05 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AB734106564A; Wed, 5 Jan 2011 21:34:05 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-ww0-f50.google.com (mail-ww0-f50.google.com [74.125.82.50]) by mx1.freebsd.org (Postfix) with ESMTP id D7F048FC08; Wed, 5 Jan 2011 21:34:04 +0000 (UTC) Received: by wwf26 with SMTP id 26so15573296wwf.31 for ; Wed, 05 Jan 2011 13:34:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=XzsYtVm926EUVKds9Kjy8MDR4QAPAauWBmIatZ0aDRw=; b=XVAFGgvQavY4SGPoW1BF8n4m4gvLDrrcKtG+pk1PVOqzCmbNRHFGnE8SVf3SWRlVzH Gm6zPOX8LdnZbvgQcJR+eZe9fSUOkFdF8hrJeTE/eiItOnsiKLD/6wW5+LNulA/nKkBs +/Wjd+E9QmH6uBAn0lBX6apF28vukn75DNLxU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=MdH3AHclD6kAfQGM74QBqLV9Z6MyJogwTcpuyHH82lhv3sxUzWpUZQxnGZAW0h1VzH 8zZfxzSy39eXvD2zrWgWZe35b80Gpj+C2hXgXutSnNFRJHN4uqEcDPh9IWjB7ifYH95I nVqUZLlB+BE/3HoHMF3Y3lAl/v/7ynlucbe8U= MIME-Version: 1.0 Received: by 10.216.78.146 with SMTP id g18mr3933843wee.1.1294263240245; Wed, 05 Jan 2011 13:34:00 -0800 (PST) Sender: yanegomi@gmail.com Received: by 10.216.254.226 with HTTP; Wed, 5 Jan 2011 13:34:00 -0800 (PST) In-Reply-To: <20110105185451.W14966@maildrop.int.zabbadoz.net> References: <201101051528.p05FSVPL082696@svn.freebsd.org> <20110105153107.X14966@maildrop.int.zabbadoz.net> <20110105155513.GA97101@alchemy.franken.de> <20110105185451.W14966@maildrop.int.zabbadoz.net> Date: Wed, 5 Jan 2011 13:34:00 -0800 X-Google-Sender-Auth: Vuj0nzW5SSa0GZDbztE9IEXtXWw Message-ID: From: Garrett Cooper To: "Bjoern A. Zeeb" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Marius Strobl Subject: Re: svn commit: r217013 - in head: sbin/ifconfig sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 21:34:05 -0000 On Wed, Jan 5, 2011 at 11:09 AM, Bjoern A. Zeeb wrote: > On Wed, 5 Jan 2011, Marius Strobl wrote: > >> On Wed, Jan 05, 2011 at 03:34:30PM +0000, Bjoern A. Zeeb wrote: >>> >>> On Wed, 5 Jan 2011, Marius Strobl wrote: >>> >>>> Author: marius >>>> Date: Wed Jan =A05 15:28:30 2011 >>>> New Revision: 217013 >>>> URL: http://svn.freebsd.org/changeset/base/217013 >>>> >>>> Log: >>>> Teach ifconfig(8) the handy shared option shortcut aliases the NetBSD >>>> counterpart also takes, i.e. "fdx" for "full-duplex", "flow" for >>>> "flowcontrol", "hdx" for "half-duplex" as well as "loop" and "loopback= " >>>> for "hw-loopback". >>> >>> I am not sure this is a good idea. =A0Unless this is really really >>> useful for compatibility with scripts (which I doubt) it'll sooner or >>> later cause headaches, especially given some of the (new) names could >>> be very well used for different things as well. >> >> Could you please elaborate on what different use you have in mind? >> Generally it seems a bad idea to me if the existing options and the >> new names as implemented would trigger different things as you suggest >> given the latter are rather common abbreviations as well as diverging >> from the user interface of the other BSDs seems like a bad idea (i.e. >> not only not supporting the same names they do but also controlling >> different things with a given one). Also the concept of aliases taken >> by ifconfig(8) isn't new, we support several including f.e. "auto" for >> "autoselect" for quite some time. > > "flow" is a term used at other layers as well and really different to > flow control. =A0We are not only seeing discussions about flowid usage > in IPv6 but also people trying to control "ULP flows" on NICs (RSS). > > loop and loopback sound bad as well, especially as I could only see > one man page in man4 (tl.4) that actually references it. > > My worries are just that people will confuse those things with other > options outside of media-opts. > > I guess I have no problem with fdx and hdx but you will see a mix > other either showing up then in scripts and man pages and that'll give > an incosistent view to users and confuse them as well (especially > since those options are all descriped with the driver's man pages > rather than having a global list [if needed with aliases] in ifconfig > then refering to the driver man pages to see which of those a driver > actually supports). > > > To give you an example -- "add" is an alias for "alias" with inet, and > people are writing alias where add should be (different places on the > command line) which leads to confusion as it shouldn't work there and > doesn't for IPv6. =A0Much confusion for years. I agree with Bjoern. I realize people love abbreviations, but if you have to spend more time disambiguating terms and defining what overloaded terms are so that everyone can understand what they are, then you aren't really saving that much time for a few characters (and in fact you're making things more complicated by adding additional available abbreviations to the supported CLI in ifconfig in this case). I have enough trouble explaining non-Cisco industry terms to Cisco people. Cisco loves abbreviations and TLAs (:)...) and other ways of shortening terms for the sake of saving a few seconds of typing in an email or a few breaths in a meeting, etc. I find it incredibly annoying when I have to search Google for these terms (and maybe find the answers, maybe not), because it's not saving me that much time. I've run into this issue in other American companies with custom work jargon on a day-to-day basis, and it varies from group to group, and often conflicts intra-group. It would be nice if we avoided this dumbing down for the sake of saving a few characters :(... Thanks, -Garrett From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 21:38:03 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4FA0F1065781; Wed, 5 Jan 2011 21:38:03 +0000 (UTC) (envelope-from andreast@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3EA278FC1B; Wed, 5 Jan 2011 21:38:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05Lc31Q091824; Wed, 5 Jan 2011 21:38:03 GMT (envelope-from andreast@svn.freebsd.org) Received: (from andreast@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05Lc3e2091822; Wed, 5 Jan 2011 21:38:03 GMT (envelope-from andreast@svn.freebsd.org) Message-Id: <201101052138.p05Lc3e2091822@svn.freebsd.org> From: Andreas Tobler Date: Wed, 5 Jan 2011 21:38:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217027 - head/sys/powerpc/ofw X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 21:38:03 -0000 Author: andreast Date: Wed Jan 5 21:38:02 2011 New Revision: 217027 URL: http://svn.freebsd.org/changeset/base/217027 Log: Fix null string handling in ofw_real_nextprop function. Pass the right length to ofw_real_map in case of a null string. This makes ofwdump(8) work correctly when trying to print all properties with ofwdump -p. Approved by: nwhitehorn (mentor) Modified: head/sys/powerpc/ofw/ofw_real.c Modified: head/sys/powerpc/ofw/ofw_real.c ============================================================================== --- head/sys/powerpc/ofw/ofw_real.c Wed Jan 5 21:23:26 2011 (r217026) +++ head/sys/powerpc/ofw/ofw_real.c Wed Jan 5 21:38:02 2011 (r217027) @@ -266,7 +266,11 @@ ofw_real_map(const void *buf, size_t len return 0; } - memcpy(of_bounce_virt + of_bounce_offset, buf, len); + if (buf != NULL) + memcpy(of_bounce_virt + of_bounce_offset, buf, len); + else + return (0); + phys = of_bounce_phys + of_bounce_offset; of_bounce_offset += len; @@ -282,6 +286,9 @@ ofw_real_unmap(cell_t physaddr, void *bu if (of_bounce_virt == NULL) return; + if (physaddr == 0) + return; + memcpy(buf,of_bounce_virt + (physaddr - of_bounce_phys),len); } @@ -546,11 +553,10 @@ ofw_real_nextprop(ofw_t ofw, phandle_t p ofw_real_start(); args.package = package; - args.previous = ofw_real_map(previous, strlen(previous) + 1); + args.previous = ofw_real_map(previous, (previous != NULL) ? (strlen(previous) + 1) : 0); args.buf = ofw_real_map(buf, size); argsptr = ofw_real_map(&args, sizeof(args)); - if (args.previous == 0 || args.buf == 0 || - openfirmware((void *)argsptr) == -1) { + if (args.buf == 0 || openfirmware((void *)argsptr) == -1) { ofw_real_stop(); return (-1); } From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 21:46:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E83E5106564A; Wed, 5 Jan 2011 21:46:08 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CBBF98FC16; Wed, 5 Jan 2011 21:46:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05Lk8bk092058; Wed, 5 Jan 2011 21:46:08 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05Lk8OC092052; Wed, 5 Jan 2011 21:46:08 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201101052146.p05Lk8OC092052@svn.freebsd.org> From: Dimitry Andric Date: Wed, 5 Jan 2011 21:46:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217028 - in head/sys/boot: i386/boot2 i386/gptboot i386/gptzfsboot i386/zfsboot pc98/boot2 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 21:46:09 -0000 Author: dim Date: Wed Jan 5 21:46:08 2011 New Revision: 217028 URL: http://svn.freebsd.org/changeset/base/217028 Log: Remove superfluous -mno-(mmx|3dnow|sse|sse2|sse3) flags in Makefiles under sys/boot/{i386,pc98}, since these are already added via sys/boot/{i386,pc98}/Makefile.inc. Submitted by: arundel Modified: head/sys/boot/i386/boot2/Makefile head/sys/boot/i386/gptboot/Makefile head/sys/boot/i386/gptzfsboot/Makefile head/sys/boot/i386/zfsboot/Makefile head/sys/boot/pc98/boot2/Makefile Modified: head/sys/boot/i386/boot2/Makefile ============================================================================== --- head/sys/boot/i386/boot2/Makefile Wed Jan 5 21:38:02 2011 (r217027) +++ head/sys/boot/i386/boot2/Makefile Wed Jan 5 21:46:08 2011 (r217028) @@ -31,7 +31,6 @@ CFLAGS= -Os \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -D${BOOT2_UFS} \ -DFLAGS=${BOOT_BOOT1_FLAGS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ Modified: head/sys/boot/i386/gptboot/Makefile ============================================================================== --- head/sys/boot/i386/gptboot/Makefile Wed Jan 5 21:38:02 2011 (r217027) +++ head/sys/boot/i386/gptboot/Makefile Wed Jan 5 21:46:08 2011 (r217028) @@ -26,7 +26,6 @@ CFLAGS= -DBOOTPROG=\"gptboot\" \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DGPT \ -D${GPTBOOT_UFS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ Modified: head/sys/boot/i386/gptzfsboot/Makefile ============================================================================== --- head/sys/boot/i386/gptzfsboot/Makefile Wed Jan 5 21:38:02 2011 (r217027) +++ head/sys/boot/i386/gptzfsboot/Makefile Wed Jan 5 21:46:08 2011 (r217028) @@ -23,7 +23,6 @@ CFLAGS= -DBOOTPROG=\"gptzfsboot\" \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DGPT -DBOOT2 \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ -DSIOFMT=${B2SIOFMT} \ Modified: head/sys/boot/i386/zfsboot/Makefile ============================================================================== --- head/sys/boot/i386/zfsboot/Makefile Wed Jan 5 21:38:02 2011 (r217027) +++ head/sys/boot/i386/zfsboot/Makefile Wed Jan 5 21:46:08 2011 (r217028) @@ -24,7 +24,6 @@ CFLAGS= -DBOOTPROG=\"zfsboot\" \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DBOOT2 \ -DFLAGS=${BOOT_BOOT1_FLAGS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ Modified: head/sys/boot/pc98/boot2/Makefile ============================================================================== --- head/sys/boot/pc98/boot2/Makefile Wed Jan 5 21:38:02 2011 (r217027) +++ head/sys/boot/pc98/boot2/Makefile Wed Jan 5 21:46:08 2011 (r217028) @@ -28,7 +28,6 @@ CFLAGS= -Os \ -fno-unit-at-a-time \ -mno-align-long-strings \ -mrtd \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -D${BOOT2_UFS} \ -DFLAGS=${BOOT_BOOT1_FLAGS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 22:00:37 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C3E261065675; Wed, 5 Jan 2011 22:00:37 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 887F18FC18; Wed, 5 Jan 2011 22:00:37 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05M0bWp092437; Wed, 5 Jan 2011 22:00:37 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05M0bWJ092433; Wed, 5 Jan 2011 22:00:37 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201101052200.p05M0bWJ092433@svn.freebsd.org> From: Dimitry Andric Date: Wed, 5 Jan 2011 22:00:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217029 - in head: lib/libstand sys/boot/ficl sys/boot/zfs X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 22:00:37 -0000 Author: dim Date: Wed Jan 5 22:00:37 2011 New Revision: 217029 URL: http://svn.freebsd.org/changeset/base/217029 Log: In lib/libstand, sys/boot/ficl and sys/boot/zfs, -mno-sse3 should also be used for amd64, not just for i386. Modified: head/lib/libstand/Makefile head/sys/boot/ficl/Makefile head/sys/boot/zfs/Makefile Modified: head/lib/libstand/Makefile ============================================================================== --- head/lib/libstand/Makefile Wed Jan 5 21:46:08 2011 (r217028) +++ head/lib/libstand/Makefile Wed Jan 5 22:00:37 2011 (r217029) @@ -22,10 +22,7 @@ CFLAGS+= -I${.CURDIR} .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mpreferred-stack-boundary=2 -CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -.endif -.if ${MACHINE_CPUARCH} == "i386" -CFLAGS+= -mno-sse3 +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 .endif .if ${MACHINE} == "pc98" CFLAGS+= -Os Modified: head/sys/boot/ficl/Makefile ============================================================================== --- head/sys/boot/ficl/Makefile Wed Jan 5 21:46:08 2011 (r217028) +++ head/sys/boot/ficl/Makefile Wed Jan 5 22:00:37 2011 (r217029) @@ -9,10 +9,9 @@ CLEANFILES= softcore.c testmain testmain CFLAGS+= -ffreestanding .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mpreferred-stack-boundary=2 -CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 .endif .if ${MACHINE_CPUARCH} == "i386" -CFLAGS+= -mno-sse3 .endif .if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "arm" CFLAGS+= -msoft-float Modified: head/sys/boot/zfs/Makefile ============================================================================== --- head/sys/boot/zfs/Makefile Wed Jan 5 21:46:08 2011 (r217028) +++ head/sys/boot/zfs/Makefile Wed Jan 5 22:00:37 2011 (r217029) @@ -13,10 +13,7 @@ CFLAGS+= -I${.CURDIR}/../../cddl/boot/zf CFLAGS+= -ffreestanding .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mpreferred-stack-boundary=2 -CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -.endif -.if ${MACHINE_CPUARCH} == "i386" -CFLAGS+= -mno-sse3 +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 .endif .if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "arm" CFLAGS+= -msoft-float From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 22:09:02 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id D20D71065672; Wed, 5 Jan 2011 22:09:02 +0000 (UTC) Date: Wed, 5 Jan 2011 22:09:02 +0000 From: Alexander Best To: Dimitry Andric Message-ID: <20110105220902.GA70759@freebsd.org> References: <201101052146.p05Lk8OC092052@svn.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101052146.p05Lk8OC092052@svn.freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217028 - in head/sys/boot: i386/boot2 i386/gptboot i386/gptzfsboot i386/zfsboot pc98/boot2 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 22:09:02 -0000 On Wed Jan 5 11, Dimitry Andric wrote: > Author: dim > Date: Wed Jan 5 21:46:08 2011 > New Revision: 217028 > URL: http://svn.freebsd.org/changeset/base/217028 > > Log: > Remove superfluous -mno-(mmx|3dnow|sse|sse2|sse3) flags in Makefiles > under sys/boot/{i386,pc98}, since these are already added via > sys/boot/{i386,pc98}/Makefile.inc. thanks a bunch. :) > > Submitted by: arundel > > Modified: > head/sys/boot/i386/boot2/Makefile > head/sys/boot/i386/gptboot/Makefile > head/sys/boot/i386/gptzfsboot/Makefile > head/sys/boot/i386/zfsboot/Makefile > head/sys/boot/pc98/boot2/Makefile > > Modified: head/sys/boot/i386/boot2/Makefile > ============================================================================== > --- head/sys/boot/i386/boot2/Makefile Wed Jan 5 21:38:02 2011 (r217027) > +++ head/sys/boot/i386/boot2/Makefile Wed Jan 5 21:46:08 2011 (r217028) > @@ -31,7 +31,6 @@ CFLAGS= -Os \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -D${BOOT2_UFS} \ > -DFLAGS=${BOOT_BOOT1_FLAGS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > > Modified: head/sys/boot/i386/gptboot/Makefile > ============================================================================== > --- head/sys/boot/i386/gptboot/Makefile Wed Jan 5 21:38:02 2011 (r217027) > +++ head/sys/boot/i386/gptboot/Makefile Wed Jan 5 21:46:08 2011 (r217028) > @@ -26,7 +26,6 @@ CFLAGS= -DBOOTPROG=\"gptboot\" \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -DGPT \ > -D${GPTBOOT_UFS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > > Modified: head/sys/boot/i386/gptzfsboot/Makefile > ============================================================================== > --- head/sys/boot/i386/gptzfsboot/Makefile Wed Jan 5 21:38:02 2011 (r217027) > +++ head/sys/boot/i386/gptzfsboot/Makefile Wed Jan 5 21:46:08 2011 (r217028) > @@ -23,7 +23,6 @@ CFLAGS= -DBOOTPROG=\"gptzfsboot\" \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -DGPT -DBOOT2 \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > -DSIOFMT=${B2SIOFMT} \ > > Modified: head/sys/boot/i386/zfsboot/Makefile > ============================================================================== > --- head/sys/boot/i386/zfsboot/Makefile Wed Jan 5 21:38:02 2011 (r217027) > +++ head/sys/boot/i386/zfsboot/Makefile Wed Jan 5 21:46:08 2011 (r217028) > @@ -24,7 +24,6 @@ CFLAGS= -DBOOTPROG=\"zfsboot\" \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -DBOOT2 \ > -DFLAGS=${BOOT_BOOT1_FLAGS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ > > Modified: head/sys/boot/pc98/boot2/Makefile > ============================================================================== > --- head/sys/boot/pc98/boot2/Makefile Wed Jan 5 21:38:02 2011 (r217027) > +++ head/sys/boot/pc98/boot2/Makefile Wed Jan 5 21:46:08 2011 (r217028) > @@ -28,7 +28,6 @@ CFLAGS= -Os \ > -fno-unit-at-a-time \ > -mno-align-long-strings \ > -mrtd \ > - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ > -D${BOOT2_UFS} \ > -DFLAGS=${BOOT_BOOT1_FLAGS} \ > -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ -- a13x From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 22:12:06 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 86522106564A; Wed, 5 Jan 2011 22:12:06 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 75B218FC0A; Wed, 5 Jan 2011 22:12:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05MC6gl092793; Wed, 5 Jan 2011 22:12:06 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05MC6J4092791; Wed, 5 Jan 2011 22:12:06 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201101052212.p05MC6J4092791@svn.freebsd.org> From: Dimitry Andric Date: Wed, 5 Jan 2011 22:12:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217030 - head/sys/boot/ficl X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 22:12:06 -0000 Author: dim Date: Wed Jan 5 22:12:06 2011 New Revision: 217030 URL: http://svn.freebsd.org/changeset/base/217030 Log: Remove an empty .if/.endif pair from sys/boot/ficl/Makefile that I forgot to cleanup in the last commit. Modified: head/sys/boot/ficl/Makefile Modified: head/sys/boot/ficl/Makefile ============================================================================== --- head/sys/boot/ficl/Makefile Wed Jan 5 22:00:37 2011 (r217029) +++ head/sys/boot/ficl/Makefile Wed Jan 5 22:12:06 2011 (r217030) @@ -11,8 +11,6 @@ CFLAGS+= -ffreestanding CFLAGS+= -mpreferred-stack-boundary=2 CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 .endif -.if ${MACHINE_CPUARCH} == "i386" -.endif .if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "arm" CFLAGS+= -msoft-float .endif From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 22:15:57 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E152B1065694; Wed, 5 Jan 2011 22:15:57 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D0C678FC16; Wed, 5 Jan 2011 22:15:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05MFvEd092956; Wed, 5 Jan 2011 22:15:57 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05MFvGC092954; Wed, 5 Jan 2011 22:15:57 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101052215.p05MFvGC092954@svn.freebsd.org> From: Warner Losh Date: Wed, 5 Jan 2011 22:15:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217032 - in head/sys/arm: conf include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 22:15:58 -0000 Author: imp Date: Wed Jan 5 22:15:57 2011 New Revision: 217032 URL: http://svn.freebsd.org/changeset/base/217032 Log: Remove ancient simulation code. Skyeye simulation never really worked quite right and hasn't been used in ages and is likely broken. QEMU with GUMSTIX is a more promising road to FreeBSD/arm in emulation anyway. Reviewed by: cognet@ Deleted: head/sys/arm/conf/SKYEYE Modified: head/sys/arm/include/pmap.h Modified: head/sys/arm/include/pmap.h ============================================================================== --- head/sys/arm/include/pmap.h Wed Jan 5 22:14:18 2011 (r217031) +++ head/sys/arm/include/pmap.h Wed Jan 5 22:15:57 2011 (r217032) @@ -336,10 +336,6 @@ extern int pmap_needs_pte_sync; #endif /* ARM_NMMUS > 1 */ -#ifdef SKYEYE_WORKAROUNDS -#define PMAP_NEEDS_PTE_SYNC 1 -#define PMAP_INCLUDE_PTE_SYNC -#else #if (ARM_MMU_SA1 == 1) && (ARM_NMMUS == 1) #define PMAP_NEEDS_PTE_SYNC 1 #define PMAP_INCLUDE_PTE_SYNC @@ -349,7 +345,6 @@ extern int pmap_needs_pte_sync; #elif (ARM_MMU_SA1 == 0) #define PMAP_NEEDS_PTE_SYNC 0 #endif -#endif /* * These macros return various bits based on kernel/user and protection. From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 22:16:41 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id B937D1065693; Wed, 5 Jan 2011 22:16:41 +0000 (UTC) Date: Wed, 5 Jan 2011 22:16:41 +0000 From: Alexander Best To: Dimitry Andric Message-ID: <20110105221641.GB70759@freebsd.org> References: <201101052123.p05LNQr4091447@svn.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101052123.p05LNQr4091447@svn.freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217026 - in head: libexec/rtld-elf/amd64 libexec/rtld-elf/i386 sys/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 22:16:41 -0000 On Wed Jan 5 11, Dimitry Andric wrote: > Author: dim > Date: Wed Jan 5 21:23:26 2011 > New Revision: 217026 > URL: http://svn.freebsd.org/changeset/base/217026 > > Log: > Sort -mno-(mmx|3dnow|sse|sse2|sse3) options consistently throughout the > tree. thanks a lot. > > Submitted by: arundel > > Modified: > head/libexec/rtld-elf/amd64/Makefile.inc > head/libexec/rtld-elf/i386/Makefile.inc > head/sys/conf/kern.mk > > Modified: head/libexec/rtld-elf/amd64/Makefile.inc > ============================================================================== > --- head/libexec/rtld-elf/amd64/Makefile.inc Wed Jan 5 21:17:14 2011 (r217025) > +++ head/libexec/rtld-elf/amd64/Makefile.inc Wed Jan 5 21:23:26 2011 (r217026) > @@ -1,6 +1,6 @@ > # $FreeBSD$ > > -CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float > +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float > # Uncomment this to build the dynamic linker as an executable instead > # of a shared library: > #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x > > Modified: head/libexec/rtld-elf/i386/Makefile.inc > ============================================================================== > --- head/libexec/rtld-elf/i386/Makefile.inc Wed Jan 5 21:17:14 2011 (r217025) > +++ head/libexec/rtld-elf/i386/Makefile.inc Wed Jan 5 21:23:26 2011 (r217026) > @@ -1,6 +1,6 @@ > # $FreeBSD$ > > -CFLAGS+= -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow -msoft-float > +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float > # Uncomment this to build the dynamic linker as an executable instead > # of a shared library: > #LDSCRIPT= ${.CURDIR}/${MACHINE_CPUARCH}/elf_rtld.x > > Modified: head/sys/conf/kern.mk > ============================================================================== > --- head/sys/conf/kern.mk Wed Jan 5 21:17:14 2011 (r217025) > +++ head/sys/conf/kern.mk Wed Jan 5 21:23:26 2011 (r217026) > @@ -66,7 +66,7 @@ INLINE_LIMIT?= 15000 > # > .if ${MACHINE_CPUARCH} == "amd64" > CFLAGS+= -mcmodel=kernel -mno-red-zone \ > - -mfpmath=387 -mno-sse -mno-sse2 -mno-sse3 -mno-mmx -mno-3dnow \ > + -mfpmath=387 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ any news regarding the "-mfpmath=387"-issue we discussed on freebsd-toolchain? iirc correctly there was one objection from somebody. > -msoft-float -fno-asynchronous-unwind-tables > INLINE_LIMIT?= 8000 > .endif -- a13x From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 22:24:34 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 557AF1065695; Wed, 5 Jan 2011 22:24:34 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 19D608FC08; Wed, 5 Jan 2011 22:24:34 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05MOXC7093182; Wed, 5 Jan 2011 22:24:33 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05MOXQs093175; Wed, 5 Jan 2011 22:24:33 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201101052224.p05MOXQs093175@svn.freebsd.org> From: Dimitry Andric Date: Wed, 5 Jan 2011 22:24:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217033 - in head: lib/libstand sys/boot/ficl sys/boot/i386 sys/boot/pc98 sys/boot/zfs sys/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 22:24:34 -0000 Author: dim Date: Wed Jan 5 22:24:33 2011 New Revision: 217033 URL: http://svn.freebsd.org/changeset/base/217033 Log: On i386 and amd64, consistently use the following options whenever we want to avoid using any "advanced" CPU features: -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float Modified: head/lib/libstand/Makefile head/sys/boot/ficl/Makefile head/sys/boot/i386/Makefile.inc head/sys/boot/pc98/Makefile.inc head/sys/boot/zfs/Makefile head/sys/conf/kern.mk Modified: head/lib/libstand/Makefile ============================================================================== --- head/lib/libstand/Makefile Wed Jan 5 22:15:57 2011 (r217032) +++ head/lib/libstand/Makefile Wed Jan 5 22:24:33 2011 (r217033) @@ -22,7 +22,7 @@ CFLAGS+= -I${.CURDIR} .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mpreferred-stack-boundary=2 -CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float .endif .if ${MACHINE} == "pc98" CFLAGS+= -Os Modified: head/sys/boot/ficl/Makefile ============================================================================== --- head/sys/boot/ficl/Makefile Wed Jan 5 22:15:57 2011 (r217032) +++ head/sys/boot/ficl/Makefile Wed Jan 5 22:24:33 2011 (r217033) @@ -9,7 +9,7 @@ CLEANFILES= softcore.c testmain testmain CFLAGS+= -ffreestanding .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mpreferred-stack-boundary=2 -CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float .endif .if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "arm" CFLAGS+= -msoft-float Modified: head/sys/boot/i386/Makefile.inc ============================================================================== --- head/sys/boot/i386/Makefile.inc Wed Jan 5 22:15:57 2011 (r217032) +++ head/sys/boot/i386/Makefile.inc Wed Jan 5 22:24:33 2011 (r217033) @@ -6,7 +6,7 @@ BINDIR?= /boot LOADER_ADDRESS?=0x200000 CFLAGS+= -ffreestanding -mpreferred-stack-boundary=2 \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 + -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float LDFLAGS+= -nostdlib .if ${MACHINE_CPUARCH} == "amd64" Modified: head/sys/boot/pc98/Makefile.inc ============================================================================== --- head/sys/boot/pc98/Makefile.inc Wed Jan 5 22:15:57 2011 (r217032) +++ head/sys/boot/pc98/Makefile.inc Wed Jan 5 22:24:33 2011 (r217033) @@ -6,7 +6,7 @@ BINDIR?= /boot LOADER_ADDRESS?=0x200000 CFLAGS+= -ffreestanding -mpreferred-stack-boundary=2 \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ + -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float \ -Os -DPC98 LDFLAGS+= -nostdlib Modified: head/sys/boot/zfs/Makefile ============================================================================== --- head/sys/boot/zfs/Makefile Wed Jan 5 22:15:57 2011 (r217032) +++ head/sys/boot/zfs/Makefile Wed Jan 5 22:24:33 2011 (r217033) @@ -13,7 +13,7 @@ CFLAGS+= -I${.CURDIR}/../../cddl/boot/zf CFLAGS+= -ffreestanding .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" CFLAGS+= -mpreferred-stack-boundary=2 -CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float .endif .if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "arm" CFLAGS+= -msoft-float Modified: head/sys/conf/kern.mk ============================================================================== --- head/sys/conf/kern.mk Wed Jan 5 22:15:57 2011 (r217032) +++ head/sys/conf/kern.mk Wed Jan 5 22:24:33 2011 (r217033) @@ -33,7 +33,7 @@ CWARNFLAGS?= -Wall -Wredundant-decls -Wn .if ${CC:T:Mclang} != "clang" CFLAGS+= -mno-align-long-strings -mpreferred-stack-boundary=2 .endif -CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 +CFLAGS+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float INLINE_LIMIT?= 8000 .endif From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 23:15:06 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5D91D106566B; Wed, 5 Jan 2011 23:15:06 +0000 (UTC) (envelope-from ivoras@gmail.com) Received: from mail-qy0-f175.google.com (mail-qy0-f175.google.com [209.85.216.175]) by mx1.freebsd.org (Postfix) with ESMTP id BA5298FC1A; Wed, 5 Jan 2011 23:15:05 +0000 (UTC) Received: by qyk8 with SMTP id 8so16087315qyk.13 for ; Wed, 05 Jan 2011 15:15:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:sender:received :in-reply-to:references:from:date:x-google-sender-auth:message-id :subject:to:cc:content-type:content-transfer-encoding; bh=gpO/KSDqNaICd3sIruzVlXy/fFGv1HeGUP8tAsJURxU=; b=FsTRP7zpBfc66RqeMA/qy5rBASX3Hn/OYI13rEqdS22Mx38IMkzEcoxsh/83rz76RV VGXBNLpQU/Msvsa0+4QdKLWWyeLqfa+XrPhcisvg1C6z94C6GH0kXinSKBkd2ZeNHY4g 5e8fpAEhH00vvD+KOtGprOsbbwsV1JCSVxC3Q= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :content-transfer-encoding; b=ohDtofKFsJIPXO5B0F6+WQA1XyytVQBFA1HxXMrk74yC+kAe4wec3NsRk7Y2gKnkbb Tew68M7XEmR7axqFSRoqE5Agy8hc3Db1/oXYioYMYR9txNzRBbtY+PjWxochVDKYdRqS uv7UMhLzMfI0JbEAprYobn5cGmylU/73f0PDY= Received: by 10.229.98.71 with SMTP id p7mr20754924qcn.139.1294269305056; Wed, 05 Jan 2011 15:15:05 -0800 (PST) MIME-Version: 1.0 Sender: ivoras@gmail.com Received: by 10.229.44.70 with HTTP; Wed, 5 Jan 2011 15:14:24 -0800 (PST) In-Reply-To: <201101052224.p05MOXQs093175@svn.freebsd.org> References: <201101052224.p05MOXQs093175@svn.freebsd.org> From: Ivan Voras Date: Thu, 6 Jan 2011 00:14:24 +0100 X-Google-Sender-Auth: HZ247e9jmaIIhJW4eu_zGHA5sz4 Message-ID: To: Dimitry Andric Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217033 - in head: lib/libstand sys/boot/ficl sys/boot/i386 sys/boot/pc98 sys/boot/zfs sys/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 23:15:06 -0000 On 5 January 2011 23:24, Dimitry Andric wrote: > Author: dim > Date: Wed Jan =C2=A05 22:24:33 2011 > New Revision: 217033 > URL: http://svn.freebsd.org/changeset/base/217033 > > Log: > =C2=A0On i386 and amd64, consistently use the following options whenever = we > =C2=A0want to avoid using any "advanced" CPU features: > > =C2=A0 =C2=A0-mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-floa= t I'm late to the party - but is there any hope of centralizing these and then doing something like "CFLAGS +=3D ${CC_NO_FP}" ? As soon as we get a newer compiler someone will have to add -mno-sse4 to the list (if not already with clang...). From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 23:15:22 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AF95210656A9; Wed, 5 Jan 2011 23:15:22 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9C3468FC23; Wed, 5 Jan 2011 23:15:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05NFMgu094252; Wed, 5 Jan 2011 23:15:22 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05NFMiP094249; Wed, 5 Jan 2011 23:15:22 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201101052315.p05NFMiP094249@svn.freebsd.org> From: Matt Jacob Date: Wed, 5 Jan 2011 23:15:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217034 - head/sys/dev/ispfw X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 23:15:22 -0000 Author: mjacob Date: Wed Jan 5 23:15:22 2011 New Revision: 217034 URL: http://svn.freebsd.org/changeset/base/217034 Log: Update firmware to more recent versions. MFC after: 3 months Modified: head/sys/dev/ispfw/asm_2322.h head/sys/dev/ispfw/asm_2400.h head/sys/dev/ispfw/asm_2500.h Modified: head/sys/dev/ispfw/asm_2322.h ============================================================================== --- head/sys/dev/ispfw/asm_2322.h Wed Jan 5 22:24:33 2011 (r217033) +++ head/sys/dev/ispfw/asm_2322.h Wed Jan 5 23:15:22 2011 (r217034) @@ -33,15 +33,15 @@ * * ************************************************************************/ /* - * Firmware Version 3.03.19 (09:43 Nov 30, 2005) + * Firmware Version 3.03.26 (17:00 Aug 14, 2007) */ static const uint16_t isp_2322_risc_code[] = { - 0x0470, 0x0000, 0x0000, 0xd49c, 0x0000, 0x0003, 0x0003, 0x0013, - 0x0117, 0x2043, 0x4f50, 0x5952, 0x4947, 0x4854, 0x2032, 0x3030, + 0x0470, 0x0000, 0x0000, 0xeb49, 0x0000, 0x0003, 0x0003, 0x001a, + 0x0137, 0x2043, 0x4f50, 0x5952, 0x4947, 0x4854, 0x2032, 0x3030, 0x3120, 0x514c, 0x4f47, 0x4943, 0x2043, 0x4f52, 0x504f, 0x5241, 0x5449, 0x4f4e, 0x2049, 0x5350, 0x3233, 0x3030, 0x2046, 0x6972, 0x6d77, 0x6172, 0x6520, 0x2056, 0x6572, 0x7369, 0x6f6e, 0x2030, - 0x332e, 0x3033, 0x2e31, 0x3920, 0x2020, 0x2020, 0x2400, 0x20a9, + 0x332e, 0x3033, 0x2e32, 0x3620, 0x2020, 0x2020, 0x2400, 0x20a9, 0x000f, 0x2001, 0x0000, 0x400f, 0x2091, 0x2200, 0x20a9, 0x000f, 0x2001, 0x0000, 0x400f, 0x2091, 0x2400, 0x20a9, 0x000f, 0x2001, 0x0000, 0x400f, 0x2091, 0x2600, 0x20a9, 0x000f, 0x2001, 0x0000, @@ -50,7605 +50,8472 @@ static const uint16_t isp_2322_risc_code 0x2c00, 0x20a9, 0x000f, 0x2001, 0x0000, 0x400f, 0x2091, 0x2e00, 0x20a9, 0x000f, 0x2001, 0x0000, 0x400f, 0x2091, 0x2000, 0x2001, 0x0000, 0x20c1, 0x0004, 0x20c9, 0x1cff, 0x2059, 0x0000, 0x2b78, - 0x7883, 0x0004, 0x2089, 0x2a22, 0x2051, 0x1800, 0x2a70, 0x20e1, - 0x0001, 0x20e9, 0x0001, 0x2009, 0x0000, 0x080c, 0x0e70, 0x00f6, - 0x7888, 0x9005, 0x11f8, 0x2061, 0xc000, 0x080c, 0x1f9e, 0x1170, - 0x2079, 0x0300, 0x080c, 0x1fb4, 0x2061, 0xe000, 0x080c, 0x1f9e, - 0x1128, 0x2079, 0x0380, 0x080c, 0x1fb4, 0x0060, 0x00fe, 0x7883, + 0x7883, 0x0004, 0x2089, 0x2caa, 0x2051, 0x1800, 0x2a70, 0x20e1, + 0x0001, 0x20e9, 0x0001, 0x2009, 0x0000, 0x080c, 0x0e77, 0x00f6, + 0x7888, 0x9005, 0x11f8, 0x2061, 0xc000, 0x080c, 0x2141, 0x1170, + 0x2079, 0x0300, 0x080c, 0x2157, 0x2061, 0xe000, 0x080c, 0x2141, + 0x1128, 0x2079, 0x0380, 0x080c, 0x2157, 0x0060, 0x00fe, 0x7883, 0x4010, 0x7837, 0x4010, 0x7833, 0x0011, 0x2091, 0x5000, 0x2091, 0x4080, 0x0cf8, 0x00fe, 0x2029, 0x5600, 0x2031, 0xffff, 0x2039, 0x55dc, 0x2021, 0x0200, 0x20e9, 0x0001, 0x20a1, 0x0000, 0x20a9, 0x0800, 0x900e, 0x4104, 0x20e9, 0x0001, 0x20a1, 0x1000, 0x900e, 0x2001, 0x0dc1, 0x9084, 0x0fff, 0x20a8, 0x4104, 0x2001, 0x0000, - 0x9086, 0x0000, 0x0120, 0x21a8, 0x4104, 0x8001, 0x1de0, 0x756a, - 0x766e, 0x7766, 0x7472, 0x7476, 0x00e6, 0x2071, 0x1b4b, 0x2472, - 0x00ee, 0x20a1, 0x1ddc, 0x716c, 0x810d, 0x810d, 0x810d, 0x810d, + 0x9086, 0x0000, 0x0120, 0x21a8, 0x4104, 0x8001, 0x1de0, 0x756e, + 0x7672, 0x776a, 0x7476, 0x747a, 0x00e6, 0x2071, 0x1b86, 0x2472, + 0x00ee, 0x20a1, 0x1ddc, 0x7170, 0x810d, 0x810d, 0x810d, 0x810d, 0x918c, 0x000f, 0x2001, 0x0001, 0x9112, 0x900e, 0x21a8, 0x4104, - 0x8211, 0x1de0, 0x716c, 0x3400, 0x8001, 0x9102, 0x0120, 0x0218, + 0x8211, 0x1de0, 0x7170, 0x3400, 0x8001, 0x9102, 0x0120, 0x0218, 0x20a8, 0x900e, 0x4104, 0x2009, 0x1800, 0x810d, 0x810d, 0x810d, 0x810d, 0x810d, 0x918c, 0x001f, 0x2001, 0x0001, 0x9112, 0x20e9, 0x0001, 0x20a1, 0x0800, 0x900e, 0x20a9, 0x0800, 0x4104, 0x8211, - 0x1dd8, 0x080c, 0x0f6d, 0x080c, 0x5ef2, 0x080c, 0xa010, 0x080c, - 0x1124, 0x080c, 0x1314, 0x080c, 0x1afc, 0x080c, 0x8731, 0x080c, - 0x0d13, 0x080c, 0x10a9, 0x080c, 0x33ca, 0x080c, 0x7673, 0x080c, - 0x6959, 0x080c, 0x8378, 0x080c, 0x2193, 0x080c, 0x7d17, 0x080c, - 0x1fcd, 0x080c, 0x210b, 0x080c, 0x2188, 0x2091, 0x3009, 0x7883, - 0x0000, 0x1004, 0x0941, 0x7880, 0x9086, 0x0002, 0x1190, 0x7883, - 0x4000, 0x7837, 0x4000, 0x7833, 0x0010, 0x0e04, 0x0935, 0x2091, - 0x5000, 0x2091, 0x4080, 0x2001, 0x0089, 0x2004, 0xd084, 0x190c, - 0x11fc, 0x2071, 0x1800, 0x7003, 0x0000, 0x780c, 0x9084, 0x0030, - 0x9086, 0x0020, 0x1168, 0x7034, 0xc08d, 0x7036, 0x2001, 0x0050, - 0x7072, 0x7076, 0x7052, 0x6067, 0x269c, 0x2071, 0x1b4b, 0x2072, - 0x2071, 0x1800, 0x7000, 0x908e, 0x0003, 0x1158, 0x080c, 0x4b5b, - 0x080c, 0x33f1, 0x080c, 0x76db, 0x080c, 0x6e43, 0x080c, 0x83a1, - 0x0c78, 0x000b, 0x0c98, 0x0975, 0x0976, 0x0b11, 0x0973, 0x0bcb, - 0x0d12, 0x0d12, 0x0d12, 0x080c, 0x0d81, 0x0005, 0x0126, 0x00f6, - 0x2091, 0x8000, 0x7000, 0x9086, 0x0001, 0x1904, 0x0ae4, 0x080c, - 0x0ec0, 0x080c, 0x7347, 0x0150, 0x080c, 0x736a, 0x15b0, 0x2079, - 0x0100, 0x7828, 0x9085, 0x1800, 0x782a, 0x0478, 0x080c, 0x7276, - 0x7000, 0x9086, 0x0001, 0x1904, 0x0ae4, 0x7094, 0x9086, 0x0029, - 0x1904, 0x0ae4, 0x080c, 0x8361, 0x080c, 0x8353, 0x2001, 0x0161, - 0x2003, 0x0001, 0x2079, 0x0100, 0x2011, 0xffff, 0x080c, 0x2933, - 0x7a28, 0x9295, 0x5e2c, 0x7a2a, 0x2011, 0x71bb, 0x080c, 0x8447, - 0x2011, 0x71ae, 0x080c, 0x854d, 0x2011, 0x5d49, 0x080c, 0x8447, - 0x2011, 0x8030, 0x901e, 0x7392, 0x04d0, 0x080c, 0x55f6, 0x2079, - 0x0100, 0x7844, 0x9005, 0x1904, 0x0ae4, 0x2011, 0x5d49, 0x080c, - 0x8447, 0x2011, 0x71bb, 0x080c, 0x8447, 0x2011, 0x71ae, 0x080c, - 0x854d, 0x2001, 0x0265, 0x2001, 0x0205, 0x2003, 0x0000, 0x7840, - 0x9084, 0xfffb, 0x7842, 0x2001, 0x1980, 0x2004, 0x9005, 0x1140, - 0x00c6, 0x2061, 0x0100, 0x080c, 0x5e9a, 0x00ce, 0x0804, 0x0ae4, - 0x780f, 0x006b, 0x7a28, 0x080c, 0x734f, 0x0118, 0x9295, 0x5e2c, - 0x0010, 0x9295, 0x402c, 0x7a2a, 0x2011, 0x8010, 0x73d4, 0x2001, - 0x1981, 0x2003, 0x0001, 0x080c, 0x27fb, 0x080c, 0x4a96, 0x7244, - 0xc284, 0x7246, 0x2001, 0x180c, 0x200c, 0xc1ac, 0xc1cc, 0x2102, - 0x2001, 0x0390, 0x2003, 0x0400, 0x080c, 0x9c32, 0x080c, 0x9563, - 0x2011, 0x0004, 0x080c, 0xbdc7, 0x080c, 0x9c4e, 0x080c, 0x676d, - 0x080c, 0x7347, 0x1120, 0x080c, 0x285c, 0x0600, 0x0420, 0x080c, - 0x5ea1, 0x0140, 0x7093, 0x0001, 0x70cf, 0x0000, 0x080c, 0x57c3, - 0x0804, 0x0ae4, 0x2001, 0x0390, 0x2003, 0x0404, 0x080c, 0x558c, - 0xd094, 0x0188, 0x2011, 0x180c, 0x2204, 0xc0cd, 0x2012, 0x080c, - 0x5590, 0xd0d4, 0x1118, 0x080c, 0x285c, 0x1270, 0x2011, 0x180c, - 0x2204, 0xc0bc, 0x00a8, 0x080c, 0x5590, 0xd0d4, 0x1db8, 0x2011, - 0x180c, 0x2204, 0xc0bd, 0x0060, 0x2011, 0x180c, 0x2204, 0xc0bd, - 0x2012, 0x080c, 0x6878, 0x1128, 0xd0a4, 0x0118, 0x2204, 0xc0fd, - 0x2012, 0x080c, 0x683e, 0x0120, 0x7a0c, 0xc2b4, 0x7a0e, 0x00a8, - 0x707b, 0x0000, 0x080c, 0x7347, 0x1130, 0x70ac, 0x9005, 0x1168, - 0x080c, 0xc225, 0x0050, 0x080c, 0xc225, 0x70d8, 0xd09c, 0x1128, - 0x70ac, 0x9005, 0x0110, 0x080c, 0x5e77, 0x70e3, 0x0000, 0x70df, - 0x0000, 0x70a3, 0x0000, 0x080c, 0x2864, 0x0228, 0x2011, 0x0101, - 0x2204, 0xc0c4, 0x2012, 0x72d8, 0x080c, 0x7347, 0x1178, 0x9016, - 0x0016, 0x080c, 0x2604, 0x2019, 0x1946, 0x211a, 0x001e, 0x705b, - 0xffff, 0x705f, 0x00ef, 0x707f, 0x0000, 0x0020, 0x2019, 0x1946, - 0x201b, 0x0000, 0x2079, 0x185b, 0x7804, 0xd0ac, 0x0108, 0xc295, - 0x72da, 0x080c, 0x7347, 0x0118, 0x9296, 0x0004, 0x0518, 0x2011, - 0x0001, 0x080c, 0xbdc7, 0x70a7, 0x0000, 0x70ab, 0xffff, 0x7003, - 0x0002, 0x00fe, 0x080c, 0x2f1f, 0x080c, 0x9c32, 0x2011, 0x0005, - 0x080c, 0x9699, 0x080c, 0x9c4e, 0x080c, 0x7347, 0x0148, 0x00c6, - 0x2061, 0x0100, 0x0016, 0x080c, 0x2604, 0x61e2, 0x001e, 0x00ce, - 0x012e, 0x00e0, 0x70a7, 0x0000, 0x70ab, 0xffff, 0x7003, 0x0002, - 0x080c, 0x9c32, 0x2011, 0x0005, 0x080c, 0x9699, 0x080c, 0x9c4e, - 0x080c, 0x7347, 0x0148, 0x00c6, 0x2061, 0x0100, 0x0016, 0x080c, - 0x2604, 0x61e2, 0x001e, 0x00ce, 0x00fe, 0x012e, 0x0005, 0x00c6, - 0x00b6, 0x080c, 0x7347, 0x1118, 0x20a9, 0x0800, 0x0010, 0x20a9, - 0x0782, 0x080c, 0x7347, 0x1110, 0x900e, 0x0010, 0x2009, 0x007e, - 0x86ff, 0x0138, 0x9180, 0x1000, 0x2004, 0x905d, 0x0110, 0xb800, - 0xd0bc, 0x090c, 0x325a, 0x8108, 0x1f04, 0x0af8, 0x707b, 0x0000, - 0x707c, 0x9084, 0x00ff, 0x707e, 0x70af, 0x0000, 0x00be, 0x00ce, - 0x0005, 0x00b6, 0x0126, 0x2091, 0x8000, 0x7000, 0x9086, 0x0002, - 0x1904, 0x0bc8, 0x70a8, 0x9086, 0xffff, 0x0120, 0x080c, 0x2f1f, - 0x0804, 0x0bc8, 0x70d8, 0xd0ac, 0x1110, 0xd09c, 0x0538, 0xd084, - 0x0528, 0x0006, 0x2001, 0x0103, 0x2003, 0x002b, 0x000e, 0xd08c, - 0x01e8, 0x080c, 0x32c3, 0x11b0, 0x70dc, 0x9086, 0xffff, 0x0190, - 0x080c, 0x30b7, 0x70d8, 0xd094, 0x1904, 0x0bc8, 0x2011, 0x0001, - 0x080c, 0xc4e1, 0x0110, 0x2011, 0x0003, 0x901e, 0x080c, 0x30f1, - 0x0804, 0x0bc8, 0x70e0, 0x9005, 0x1904, 0x0bc8, 0x70a4, 0x9005, - 0x1904, 0x0bc8, 0x70d8, 0xd0a4, 0x0118, 0xd0b4, 0x0904, 0x0bc8, - 0x080c, 0x683e, 0x1904, 0x0bc8, 0x080c, 0x6891, 0x1904, 0x0bc8, - 0x080c, 0x6878, 0x01c0, 0x0156, 0x00c6, 0x20a9, 0x007f, 0x900e, - 0x0016, 0x080c, 0x6479, 0x1118, 0xb800, 0xd0ec, 0x1138, 0x001e, - 0x8108, 0x1f04, 0x0b68, 0x00ce, 0x015e, 0x0028, 0x001e, 0x00ce, - 0x015e, 0x0804, 0x0bc8, 0x0006, 0x2001, 0x0103, 0x2003, 0x006b, - 0x000e, 0x2011, 0x198d, 0x080c, 0x0fdd, 0x2011, 0x19a7, 0x080c, - 0x0fdd, 0x7030, 0xc08c, 0x7032, 0x7003, 0x0003, 0x70ab, 0xffff, - 0x080c, 0x0e94, 0x9006, 0x080c, 0x2491, 0x080c, 0x32c3, 0x0118, - 0x080c, 0x4c33, 0x0050, 0x0036, 0x0046, 0x2019, 0xffff, 0x2021, - 0x0006, 0x080c, 0x4c4d, 0x004e, 0x003e, 0x00f6, 0x2079, 0x0100, - 0x080c, 0x736a, 0x0150, 0x080c, 0x7347, 0x7828, 0x0118, 0x9084, - 0xe1ff, 0x0010, 0x9084, 0xffdf, 0x782a, 0x00fe, 0x080c, 0x9c32, - 0x2001, 0x19c2, 0x2004, 0x9086, 0x0005, 0x1120, 0x2011, 0x0000, - 0x080c, 0x9699, 0x2011, 0x0000, 0x080c, 0x96a3, 0x080c, 0x9c4e, - 0x012e, 0x00be, 0x0005, 0x0016, 0x0026, 0x0046, 0x00f6, 0x0126, - 0x2091, 0x8000, 0x2079, 0x0100, 0x7904, 0x918c, 0xfffd, 0x7906, - 0x2009, 0x00f7, 0x080c, 0x5e60, 0x7940, 0x918c, 0x0010, 0x7942, - 0x7924, 0xd1b4, 0x0120, 0x2011, 0x0040, 0x080c, 0x2933, 0xd19c, - 0x0120, 0x2011, 0x0008, 0x080c, 0x2933, 0x0006, 0x0036, 0x0156, - 0x0000, 0x2001, 0x1981, 0x2004, 0x9005, 0x1518, 0x080c, 0x28c7, - 0x1148, 0x2001, 0x0001, 0x080c, 0x282a, 0x2001, 0x0001, 0x080c, - 0x280d, 0x00b8, 0x080c, 0x28cf, 0x1138, 0x9006, 0x080c, 0x282a, - 0x9006, 0x080c, 0x280d, 0x0068, 0x080c, 0x28d7, 0x1d50, 0x2001, - 0x1971, 0x2004, 0xd0fc, 0x0108, 0x0020, 0x080c, 0x2638, 0x0804, - 0x0cc5, 0x20a9, 0x003a, 0x1d04, 0x0c1b, 0x080c, 0x852d, 0x1f04, - 0x0c1b, 0x080c, 0x7358, 0x0148, 0x080c, 0x736a, 0x1118, 0x080c, - 0x766e, 0x0050, 0x080c, 0x734f, 0x0dd0, 0x080c, 0x7669, 0x080c, - 0x765f, 0x080c, 0x7276, 0x0020, 0x2009, 0x00f8, 0x080c, 0x5e60, - 0x7850, 0xc0e5, 0x7852, 0x080c, 0x7347, 0x0120, 0x7843, 0x0090, - 0x7843, 0x0010, 0x2021, 0xe678, 0x2019, 0xea60, 0x0d0c, 0x852d, - 0x7820, 0xd09c, 0x15a0, 0x080c, 0x7347, 0x0904, 0x0ca7, 0x7824, - 0xd0ac, 0x1904, 0x0cca, 0x080c, 0x736a, 0x1548, 0x0046, 0x2021, - 0x0320, 0x8421, 0x1df0, 0x004e, 0x2011, 0x1800, 0x080c, 0x2933, - 0x080c, 0x28df, 0x7824, 0x9084, 0x1800, 0x1168, 0x9484, 0x0fff, - 0x1140, 0x2001, 0x1810, 0x2004, 0x9084, 0x9000, 0x0110, 0x080c, - 0x0ced, 0x8421, 0x1160, 0x1d04, 0x0c77, 0x080c, 0x852d, 0x080c, - 0x7669, 0x080c, 0x765f, 0x7003, 0x0001, 0x0804, 0x0cca, 0x8319, - 0x1928, 0x2001, 0x1810, 0x2004, 0x9084, 0x9000, 0x0110, 0x080c, - 0x0ced, 0x1d04, 0x0c8d, 0x080c, 0x852d, 0x2009, 0x1974, 0x2104, - 0x9005, 0x0118, 0x8001, 0x200a, 0x1188, 0x200b, 0x000a, 0x2011, - 0x0048, 0x080c, 0x2933, 0x20a9, 0x0002, 0x080c, 0x28c0, 0x7924, - 0x080c, 0x28df, 0xd19c, 0x0110, 0x080c, 0x27fb, 0x00f0, 0x080c, - 0x7358, 0x1140, 0x94a2, 0x03e8, 0x1128, 0x080c, 0x731b, 0x7003, - 0x0001, 0x00c0, 0x2011, 0x1800, 0x080c, 0x2933, 0x080c, 0x28df, - 0x7824, 0x080c, 0x7361, 0x0110, 0xd0ac, 0x1160, 0x9084, 0x1800, - 0x0904, 0x0c7f, 0x7003, 0x0001, 0x0028, 0x2001, 0x0001, 0x080c, - 0x2491, 0x00a0, 0x7850, 0xc0e4, 0x7852, 0x2009, 0x180c, 0x210c, - 0xd19c, 0x1120, 0x7904, 0x918d, 0x0002, 0x7906, 0x2011, 0x0048, - 0x080c, 0x2933, 0x7828, 0x9085, 0x0028, 0x782a, 0x2001, 0x1981, - 0x2003, 0x0000, 0x9006, 0x78f2, 0x015e, 0x003e, 0x000e, 0x012e, - 0x00fe, 0x004e, 0x002e, 0x001e, 0x0005, 0x0006, 0x0016, 0x0026, - 0x0036, 0x0046, 0x00b6, 0x00c6, 0x00d6, 0x00e6, 0x00f6, 0x0156, - 0x0071, 0x0d0c, 0x852d, 0x015e, 0x00fe, 0x00ee, 0x00de, 0x00ce, - 0x00be, 0x004e, 0x003e, 0x002e, 0x001e, 0x000e, 0x0005, 0x00e6, - 0x2071, 0x189c, 0x7004, 0x9086, 0x0001, 0x1110, 0x080c, 0x33f1, - 0x00ee, 0x0005, 0x0005, 0x2a70, 0x2061, 0x1985, 0x2063, 0x0003, - 0x6007, 0x0003, 0x600b, 0x0013, 0x600f, 0x0117, 0x2001, 0x1955, - 0x900e, 0x2102, 0x7192, 0x2001, 0x0100, 0x2004, 0x9082, 0x0002, - 0x0218, 0x705b, 0xffff, 0x0008, 0x715a, 0x7063, 0xffff, 0x717a, - 0x717e, 0x080c, 0xc225, 0x70eb, 0x00c0, 0x2061, 0x1945, 0x6003, - 0x0909, 0x6106, 0x600b, 0x8800, 0x600f, 0x0200, 0x6013, 0x00ff, - 0x6017, 0x000f, 0x611a, 0x601f, 0x07d0, 0x2061, 0x194d, 0x6003, - 0x8000, 0x6106, 0x610a, 0x600f, 0x0200, 0x6013, 0x00ff, 0x6116, - 0x601b, 0x0001, 0x611e, 0x2061, 0x1962, 0x6003, 0x514c, 0x6007, - 0x4f47, 0x600b, 0x4943, 0x600f, 0x2020, 0x2001, 0x182b, 0x2102, - 0x0005, 0x9016, 0x080c, 0x6479, 0x1178, 0xb804, 0x90c4, 0x00ff, - 0x98c6, 0x0006, 0x0128, 0x90c4, 0xff00, 0x98c6, 0x0600, 0x1120, - 0x9186, 0x0080, 0x0108, 0x8210, 0x8108, 0x9186, 0x0800, 0x1d50, - 0x2208, 0x0005, 0x2091, 0x8000, 0x2079, 0x0000, 0x000e, 0x00f6, - 0x0010, 0x2091, 0x8000, 0x0e04, 0x0d83, 0x0006, 0x0016, 0x2001, - 0x8002, 0x0006, 0x2079, 0x0000, 0x000e, 0x7882, 0x7836, 0x001e, - 0x798e, 0x000e, 0x788a, 0x000e, 0x7886, 0x3900, 0x789a, 0x00d6, - 0x2069, 0x0300, 0x6818, 0x78ae, 0x681c, 0x78b2, 0x6808, 0x78be, - 0x00de, 0x7833, 0x0012, 0x2091, 0x5000, 0x0156, 0x00d6, 0x0036, - 0x0026, 0x2079, 0x0300, 0x2069, 0x1b03, 0x7a08, 0x226a, 0x2069, - 0x1b04, 0x7a18, 0x226a, 0x8d68, 0x7a1c, 0x226a, 0x782c, 0x2019, - 0x1b11, 0x201a, 0x2019, 0x1b14, 0x9016, 0x7808, 0xd09c, 0x0168, - 0x7820, 0x201a, 0x8210, 0x8318, 0x9386, 0x1b2d, 0x0108, 0x0ca8, - 0x7808, 0xd09c, 0x0110, 0x2011, 0xdead, 0x2019, 0x1b12, 0x782c, - 0x201a, 0x8318, 0x221a, 0x7803, 0x0000, 0x2069, 0x1a59, 0x901e, - 0x20a9, 0x0020, 0x7b26, 0x7a28, 0x226a, 0x8d68, 0x8318, 0x1f04, - 0x0dda, 0x2069, 0x1a79, 0x2019, 0x0050, 0x20a9, 0x0020, 0x7b26, - 0x7a28, 0x226a, 0x8d68, 0x8318, 0x1f04, 0x0de7, 0x0491, 0x002e, - 0x003e, 0x00de, 0x015e, 0x2079, 0x1800, 0x7803, 0x0005, 0x2091, - 0x4080, 0x2001, 0x0089, 0x2004, 0xd084, 0x0180, 0x2001, 0x19fe, - 0x2004, 0x9005, 0x0128, 0x2001, 0x008b, 0x2004, 0xd0fc, 0x0dd8, - 0x2001, 0x008a, 0x2003, 0x0002, 0x2003, 0x1001, 0x080c, 0x559b, - 0x1170, 0x080c, 0x0f2e, 0x0110, 0x080c, 0x0e81, 0x080c, 0x559b, - 0x1130, 0x2071, 0x1800, 0x2011, 0x8000, 0x080c, 0x0f42, 0x0c70, - 0x0005, 0x2001, 0x0382, 0x2004, 0x9084, 0x0007, 0x9086, 0x0001, - 0x1120, 0x2001, 0x0015, 0x080c, 0x9c23, 0x2079, 0x0380, 0x2069, - 0x1ae3, 0x7818, 0x6802, 0x781c, 0x6806, 0x7840, 0x680a, 0x7844, - 0x680e, 0x782c, 0x6812, 0x2019, 0x1aee, 0x9016, 0x7808, 0xd09c, - 0x0150, 0x7820, 0x201a, 0x8210, 0x8318, 0x8210, 0x9282, 0x0011, - 0x0ea8, 0x2011, 0xdead, 0x6a2a, 0x7830, 0x681a, 0x7834, 0x681e, - 0x7838, 0x6822, 0x783c, 0x6826, 0x7803, 0x0000, 0x2069, 0x1aa3, - 0x901e, 0x20a9, 0x0020, 0x7b26, 0x7828, 0x206a, 0x8d68, 0x8318, - 0x1f04, 0x0e5b, 0x2069, 0x1ac3, 0x2019, 0x00b0, 0x20a9, 0x0020, - 0x7b26, 0x7828, 0x206a, 0x8d68, 0x8318, 0x1f04, 0x0e68, 0x0005, - 0x918c, 0x03ff, 0x2001, 0x0003, 0x2004, 0x9084, 0x0600, 0x1118, - 0x918d, 0x6c00, 0x0010, 0x918d, 0x6400, 0x2001, 0x017f, 0x2102, - 0x0005, 0x0026, 0x0126, 0x2011, 0x0080, 0x080c, 0x0f20, 0x20a9, - 0x0900, 0x080c, 0x0f56, 0x2011, 0x0040, 0x080c, 0x0f20, 0x20a9, - 0x0900, 0x080c, 0x0f56, 0x0c78, 0x0026, 0x080c, 0x0f2e, 0x1188, + 0x1dd8, 0x080c, 0x0f74, 0x080c, 0x6331, 0x080c, 0xb3c9, 0x080c, + 0x112b, 0x080c, 0x1358, 0x080c, 0x1c97, 0x080c, 0x97ef, 0x080c, + 0x0d19, 0x080c, 0x10b0, 0x080c, 0x3676, 0x080c, 0x7cb7, 0x080c, + 0x6ed7, 0x080c, 0x8ef1, 0x080c, 0x8b06, 0x080c, 0x233e, 0x080c, + 0x83e2, 0x080c, 0x2170, 0x080c, 0x22b2, 0x080c, 0x2333, 0x2091, + 0x3009, 0x7883, 0x0000, 0x1004, 0x0943, 0x7880, 0x9086, 0x0002, + 0x1190, 0x7883, 0x4000, 0x7837, 0x4000, 0x7833, 0x0010, 0x0e04, + 0x0937, 0x2091, 0x5000, 0x2091, 0x4080, 0x2001, 0x0089, 0x2004, + 0xd084, 0x190c, 0x1203, 0x2071, 0x1800, 0x7003, 0x0000, 0x780c, + 0x9084, 0x0030, 0x9086, 0x0020, 0x1168, 0x7034, 0xc08d, 0x7036, + 0x2001, 0x0050, 0x7076, 0x707a, 0x7056, 0x606b, 0x269c, 0x2071, + 0x1b86, 0x2072, 0x2071, 0x1800, 0x7000, 0x908e, 0x0003, 0x1168, + 0x080c, 0x4ee7, 0x080c, 0x369d, 0x080c, 0x7d1f, 0x080c, 0x7462, + 0x080c, 0x8fd8, 0x080c, 0x8b2f, 0x0c68, 0x000b, 0x0c88, 0x0979, + 0x097a, 0x0b17, 0x0977, 0x0bd1, 0x0d18, 0x0d18, 0x0d18, 0x080c, + 0x0d87, 0x0005, 0x0126, 0x00f6, 0x2091, 0x8000, 0x7000, 0x9086, + 0x0001, 0x1904, 0x0aea, 0x080c, 0x0ec7, 0x080c, 0x798b, 0x0150, + 0x080c, 0x79ae, 0x15c0, 0x2079, 0x0100, 0x7828, 0x9085, 0x1800, + 0x782a, 0x0488, 0x080c, 0x78ba, 0x7000, 0x9086, 0x0001, 0x1904, + 0x0aea, 0x7098, 0x9086, 0x0029, 0x1904, 0x0aea, 0x080c, 0x8ae6, + 0x080c, 0x8ad8, 0x2079, 0x0100, 0x782f, 0x0008, 0x2001, 0x0161, + 0x2003, 0x0001, 0x2011, 0xffff, 0x080c, 0x2b72, 0x7a28, 0x9295, + 0x5e2c, 0x7a2a, 0x2011, 0x77ff, 0x080c, 0x8bdb, 0x2011, 0x77f2, + 0x080c, 0x8d33, 0x2011, 0x6188, 0x080c, 0x8bdb, 0x2011, 0x8030, + 0x901e, 0x7396, 0x04d0, 0x080c, 0x5a30, 0x2079, 0x0100, 0x7844, + 0x9005, 0x1904, 0x0aea, 0x2011, 0x6188, 0x080c, 0x8bdb, 0x2011, + 0x77ff, 0x080c, 0x8bdb, 0x2011, 0x77f2, 0x080c, 0x8d33, 0x2001, + 0x0265, 0x2001, 0x0205, 0x2003, 0x0000, 0x7840, 0x9084, 0xfffb, + 0x7842, 0x2001, 0x19aa, 0x2004, 0x9005, 0x1140, 0x00c6, 0x2061, + 0x0100, 0x080c, 0x62d9, 0x00ce, 0x0804, 0x0aea, 0x780f, 0x006b, + 0x7a28, 0x080c, 0x7993, 0x0118, 0x9295, 0x5e2c, 0x0010, 0x9295, + 0x402c, 0x7a2a, 0x2011, 0x8010, 0x73d8, 0x2001, 0x19ab, 0x2003, + 0x0001, 0x080c, 0x2a31, 0x080c, 0x4e22, 0x7248, 0xc284, 0x724a, + 0x2001, 0x180c, 0x200c, 0xc1ac, 0xc1cc, 0x2102, 0x2001, 0x0390, + 0x2003, 0x0400, 0x080c, 0xafa2, 0x080c, 0xa77d, 0x2011, 0x0004, + 0x080c, 0xd2d5, 0x080c, 0xafbe, 0x080c, 0x6c81, 0x080c, 0x798b, + 0x1120, 0x080c, 0x2a92, 0x0600, 0x0420, 0x080c, 0x62e0, 0x0140, + 0x7097, 0x0001, 0x70d3, 0x0000, 0x080c, 0x5c02, 0x0804, 0x0aea, + 0x2001, 0x0390, 0x2003, 0x0404, 0x080c, 0x59d0, 0xd094, 0x0188, + 0x2011, 0x180c, 0x2204, 0xc0cd, 0x2012, 0x080c, 0x59d4, 0xd0d4, + 0x1118, 0x080c, 0x2a92, 0x1270, 0x2011, 0x180c, 0x2204, 0xc0bc, + 0x00a8, 0x080c, 0x59d4, 0xd0d4, 0x1db8, 0x2011, 0x180c, 0x2204, + 0xc0bd, 0x0060, 0x2011, 0x180c, 0x2204, 0xc0bd, 0x2012, 0x080c, + 0x6ddf, 0x1128, 0xd0a4, 0x0118, 0x2204, 0xc0fd, 0x2012, 0x080c, + 0x6da5, 0x0120, 0x7a0c, 0xc2b4, 0x7a0e, 0x00a8, 0x707f, 0x0000, + 0x080c, 0x798b, 0x1130, 0x70b0, 0x9005, 0x1168, 0x080c, 0xd72a, + 0x0050, 0x080c, 0xd72a, 0x70dc, 0xd09c, 0x1128, 0x70b0, 0x9005, + 0x0110, 0x080c, 0x62b6, 0x70e7, 0x0000, 0x70e3, 0x0000, 0x70a7, + 0x0000, 0x080c, 0x2a9a, 0x0228, 0x2011, 0x0101, 0x2204, 0xc0c4, + 0x2012, 0x72dc, 0x080c, 0x798b, 0x1178, 0x9016, 0x0016, 0x080c, + 0x283a, 0x2019, 0x1970, 0x211a, 0x001e, 0x705f, 0xffff, 0x7063, + 0x00ef, 0x7083, 0x0000, 0x0020, 0x2019, 0x1970, 0x201b, 0x0000, + 0x2079, 0x184a, 0x7804, 0xd0ac, 0x0108, 0xc295, 0x72de, 0x080c, + 0x798b, 0x0118, 0x9296, 0x0004, 0x0518, 0x2011, 0x0001, 0x080c, + 0xd2d5, 0x70ab, 0x0000, 0x70af, 0xffff, 0x7003, 0x0002, 0x00fe, + 0x080c, 0x31a7, 0x080c, 0xafa2, 0x2011, 0x0005, 0x080c, 0xa8b7, + 0x080c, 0xafbe, 0x080c, 0x798b, 0x0148, 0x00c6, 0x2061, 0x0100, + 0x0016, 0x080c, 0x283a, 0x61e2, 0x001e, 0x00ce, 0x012e, 0x00e0, + 0x70ab, 0x0000, 0x70af, 0xffff, 0x7003, 0x0002, 0x080c, 0xafa2, + 0x2011, 0x0005, 0x080c, 0xa8b7, 0x080c, 0xafbe, 0x080c, 0x798b, + 0x0148, 0x00c6, 0x2061, 0x0100, 0x0016, 0x080c, 0x283a, 0x61e2, + 0x001e, 0x00ce, 0x00fe, 0x012e, 0x0005, 0x00c6, 0x00b6, 0x080c, + 0x798b, 0x1118, 0x20a9, 0x0800, 0x0010, 0x20a9, 0x0782, 0x080c, + 0x798b, 0x1110, 0x900e, 0x0010, 0x2009, 0x007e, 0x86ff, 0x0138, + 0x9180, 0x1000, 0x2004, 0x905d, 0x0110, 0xb800, 0xd0bc, 0x090c, + 0x3506, 0x8108, 0x1f04, 0x0afe, 0x707f, 0x0000, 0x7080, 0x9084, + 0x00ff, 0x7082, 0x70b3, 0x0000, 0x00be, 0x00ce, 0x0005, 0x00b6, + 0x0126, 0x2091, 0x8000, 0x7000, 0x9086, 0x0002, 0x1904, 0x0bce, + 0x70ac, 0x9086, 0xffff, 0x0120, 0x080c, 0x31a7, 0x0804, 0x0bce, + 0x70dc, 0xd0ac, 0x1110, 0xd09c, 0x0538, 0xd084, 0x0528, 0x0006, + 0x2001, 0x0103, 0x2003, 0x002b, 0x000e, 0xd08c, 0x01e8, 0x080c, + 0x356f, 0x11b0, 0x70e0, 0x9086, 0xffff, 0x0190, 0x080c, 0x3363, + 0x70dc, 0xd094, 0x1904, 0x0bce, 0x2011, 0x0001, 0x080c, 0xd9e5, + 0x0110, 0x2011, 0x0003, 0x901e, 0x080c, 0x339d, 0x0804, 0x0bce, + 0x70e4, 0x9005, 0x1904, 0x0bce, 0x70a8, 0x9005, 0x1904, 0x0bce, + 0x70dc, 0xd0a4, 0x0118, 0xd0b4, 0x0904, 0x0bce, 0x080c, 0x6da5, + 0x1904, 0x0bce, 0x080c, 0x6df8, 0x1904, 0x0bce, 0x080c, 0x6ddf, + 0x01c0, 0x0156, 0x00c6, 0x20a9, 0x007f, 0x900e, 0x0016, 0x080c, + 0x6945, 0x1118, 0xb800, 0xd0ec, 0x1138, 0x001e, 0x8108, 0x1f04, + 0x0b6e, 0x00ce, 0x015e, 0x0028, 0x001e, 0x00ce, 0x015e, 0x0804, + 0x0bce, 0x0006, 0x2001, 0x0103, 0x2003, 0x002b, 0x000e, 0x2011, + 0x19b7, 0x080c, 0x0fe4, 0x2011, 0x19d1, 0x080c, 0x0fe4, 0x7030, + 0xc08c, 0x7032, 0x7003, 0x0003, 0x70af, 0xffff, 0x080c, 0x0e9b, + 0x9006, 0x080c, 0x26c7, 0x080c, 0x356f, 0x0118, 0x080c, 0x4fbf, + 0x0050, 0x0036, 0x0046, 0x2019, 0xffff, 0x2021, 0x0006, 0x080c, + 0x4fd9, 0x004e, 0x003e, 0x00f6, 0x2079, 0x0100, 0x080c, 0x79ae, + 0x0150, 0x080c, 0x798b, 0x7828, 0x0118, 0x9084, 0xe1ff, 0x0010, + 0x9084, 0xffdf, 0x782a, 0x00fe, 0x080c, 0xafa2, 0x2001, 0x19ec, + 0x2004, 0x9086, 0x0005, 0x1120, 0x2011, 0x0000, 0x080c, 0xa8b7, + 0x2011, 0x0000, 0x080c, 0xa8c1, 0x080c, 0xafbe, 0x012e, 0x00be, + 0x0005, 0x0016, 0x0026, 0x0046, 0x00f6, 0x0126, 0x2091, 0x8000, + 0x2079, 0x0100, 0x7904, 0x918c, 0xfffd, 0x7906, 0x2009, 0x00f7, + 0x080c, 0x629f, 0x7940, 0x918c, 0x0010, 0x7942, 0x7924, 0xd1b4, + 0x0120, 0x2011, 0x0040, 0x080c, 0x2b72, 0xd19c, 0x0120, 0x2011, + 0x0008, 0x080c, 0x2b72, 0x0006, 0x0036, 0x0156, 0x0000, 0x2001, + 0x19ab, 0x2004, 0x9005, 0x1518, 0x080c, 0x2b06, 0x1148, 0x2001, + 0x0001, 0x080c, 0x2a60, 0x2001, 0x0001, 0x080c, 0x2a43, 0x00b8, + 0x080c, 0x2b0e, 0x1138, 0x9006, 0x080c, 0x2a60, 0x9006, 0x080c, + 0x2a43, 0x0068, 0x080c, 0x2b16, 0x1d50, 0x2001, 0x199b, 0x2004, + 0xd0fc, 0x0108, 0x0020, 0x080c, 0x286e, 0x0804, 0x0ccb, 0x20a9, + 0x003a, 0x1d04, 0x0c21, 0x080c, 0x8d13, 0x1f04, 0x0c21, 0x080c, + 0x799c, 0x0148, 0x080c, 0x79ae, 0x1118, 0x080c, 0x7cb2, 0x0050, + 0x080c, 0x7993, 0x0dd0, 0x080c, 0x7cad, 0x080c, 0x7ca3, 0x080c, + 0x78ba, 0x0020, 0x2009, 0x00f8, 0x080c, 0x629f, 0x7850, 0xc0e5, + 0x7852, 0x080c, 0x798b, 0x0120, 0x7843, 0x0090, 0x7843, 0x0010, + 0x2021, 0xe678, 0x2019, 0xea60, 0x0d0c, 0x8d13, 0x7820, 0xd09c, + 0x15a0, 0x080c, 0x798b, 0x0904, 0x0cad, 0x7824, 0xd0ac, 0x1904, + 0x0cd0, 0x080c, 0x79ae, 0x1548, 0x0046, 0x2021, 0x0320, 0x8421, + 0x1df0, 0x004e, 0x2011, 0x1800, 0x080c, 0x2b72, 0x080c, 0x2b1e, + 0x7824, 0x9084, 0x1800, 0x1168, 0x9484, 0x0fff, 0x1140, 0x2001, + 0x1810, 0x2004, 0x9084, 0x9000, 0x0110, 0x080c, 0x0cf3, 0x8421, + 0x1160, 0x1d04, 0x0c7d, 0x080c, 0x8d13, 0x080c, 0x7cad, 0x080c, + 0x7ca3, 0x7003, 0x0001, 0x0804, 0x0cd0, 0x8319, 0x1928, 0x2001, + 0x1810, 0x2004, 0x9084, 0x9000, 0x0110, 0x080c, 0x0cf3, 0x1d04, + 0x0c93, 0x080c, 0x8d13, 0x2009, 0x199e, 0x2104, 0x9005, 0x0118, + 0x8001, 0x200a, 0x1188, 0x200b, 0x000a, 0x2011, 0x0048, 0x080c, + 0x2b72, 0x20a9, 0x0002, 0x080c, 0x2aff, 0x7924, 0x080c, 0x2b1e, + 0xd19c, 0x0110, 0x080c, 0x2a31, 0x00f0, 0x080c, 0x799c, 0x1140, + 0x94a2, 0x03e8, 0x1128, 0x080c, 0x795f, 0x7003, 0x0001, 0x00c0, + 0x2011, 0x1800, 0x080c, 0x2b72, 0x080c, 0x2b1e, 0x7824, 0x080c, + 0x79a5, 0x0110, 0xd0ac, 0x1160, 0x9084, 0x1800, 0x0904, 0x0c85, + 0x7003, 0x0001, 0x0028, 0x2001, 0x0001, 0x080c, 0x26c7, 0x00a0, + 0x7850, 0xc0e4, 0x7852, 0x2009, 0x180c, 0x210c, 0xd19c, 0x1120, + 0x7904, 0x918d, 0x0002, 0x7906, 0x2011, 0x0048, 0x080c, 0x2b72, + 0x7828, 0x9085, 0x0028, 0x782a, 0x2001, 0x19ab, 0x2003, 0x0000, + 0x9006, 0x78f2, 0x015e, 0x003e, 0x000e, 0x012e, 0x00fe, 0x004e, + 0x002e, 0x001e, 0x0005, 0x0006, 0x0016, 0x0026, 0x0036, 0x0046, + 0x00b6, 0x00c6, 0x00d6, 0x00e6, 0x00f6, 0x0156, 0x0071, 0x0d0c, + 0x8d13, 0x015e, 0x00fe, 0x00ee, 0x00de, 0x00ce, 0x00be, 0x004e, + 0x003e, 0x002e, 0x001e, 0x000e, 0x0005, 0x00e6, 0x2071, 0x18a1, + 0x7004, 0x9086, 0x0001, 0x1110, 0x080c, 0x369d, 0x00ee, 0x0005, + 0x0005, 0x2a70, 0x2061, 0x19af, 0x2063, 0x0003, 0x6007, 0x0003, + 0x600b, 0x001a, 0x600f, 0x0137, 0x2001, 0x197f, 0x900e, 0x2102, + 0x7196, 0x2001, 0x0100, 0x2004, 0x9082, 0x0002, 0x0218, 0x705f, + 0xffff, 0x0008, 0x715e, 0x7067, 0xffff, 0x717e, 0x7182, 0x080c, + 0xd72a, 0x70ef, 0x00c0, 0x2061, 0x196f, 0x6003, 0x0909, 0x6106, + 0x600b, 0x8800, 0x600f, 0x0200, 0x6013, 0x00ff, 0x6017, 0x001f, + 0x611a, 0x601f, 0x07d0, 0x2061, 0x1977, 0x6003, 0x8000, 0x6106, + 0x610a, 0x600f, 0x0200, 0x6013, 0x00ff, 0x6116, 0x601b, 0x0001, + 0x611e, 0x2061, 0x198c, 0x6003, 0x514c, 0x6007, 0x4f47, 0x600b, + 0x4943, 0x600f, 0x2020, 0x2001, 0x182c, 0x2102, 0x0005, 0x9016, + 0x080c, 0x6945, 0x1178, 0xb804, 0x90c4, 0x00ff, 0x98c6, 0x0006, + 0x0128, 0x90c4, 0xff00, 0x98c6, 0x0600, 0x1120, 0x9186, 0x0080, + 0x0108, 0x8210, 0x8108, 0x9186, 0x0800, 0x1d50, 0x2208, 0x0005, + 0x2091, 0x8000, 0x2079, 0x0000, 0x000e, 0x00f6, 0x0010, 0x2091, + 0x8000, 0x0e04, 0x0d89, 0x0006, 0x0016, 0x2001, 0x8002, 0x0006, + 0x2079, 0x0000, 0x000e, 0x7882, 0x7836, 0x001e, 0x798e, 0x000e, + 0x788a, 0x000e, 0x7886, 0x3900, 0x789a, 0x00d6, 0x2069, 0x0300, + 0x6818, 0x78ae, 0x681c, 0x78b2, 0x6808, 0x78be, 0x00de, 0x7833, + 0x0012, 0x2091, 0x5000, 0x0156, 0x00d6, 0x0036, 0x0026, 0x2079, + 0x0300, 0x2069, 0x1b3e, 0x7a08, 0x226a, 0x2069, 0x1b3f, 0x7a18, + 0x226a, 0x8d68, 0x7a1c, 0x226a, 0x782c, 0x2019, 0x1b4c, 0x201a, + 0x2019, 0x1b4f, 0x9016, 0x7808, 0xd09c, 0x0168, 0x7820, 0x201a, + 0x8210, 0x8318, 0x9386, 0x1b68, 0x0108, 0x0ca8, 0x7808, 0xd09c, + 0x0110, 0x2011, 0xdead, 0x2019, 0x1b4d, 0x782c, 0x201a, 0x8318, + 0x221a, 0x7803, 0x0000, 0x2069, 0x1a94, 0x901e, 0x20a9, 0x0020, + 0x7b26, 0x7a28, 0x226a, 0x8d68, 0x8318, 0x1f04, 0x0de0, 0x2069, + 0x1ab4, 0x2019, 0x0050, 0x20a9, 0x0020, 0x7b26, 0x7a28, 0x226a, + 0x8d68, 0x8318, 0x1f04, 0x0ded, 0x0499, 0x002e, 0x003e, 0x00de, + 0x015e, 0x2079, 0x1800, 0x7803, 0x0005, 0x2091, 0x4080, 0x2001, + 0x0089, 0x2004, 0xd084, 0x0188, 0x2001, 0x1a38, 0x2004, 0x9005, + 0x0130, 0x2001, 0x008b, 0x2004, 0x9084, 0x8004, 0x0dd0, 0x2001, + 0x008a, 0x2003, 0x0002, 0x2003, 0x1001, 0x080c, 0x59df, 0x1170, + 0x080c, 0x0f35, 0x0110, 0x080c, 0x0e88, 0x080c, 0x59df, 0x1130, + 0x2071, 0x1800, 0x2011, 0x8000, 0x080c, 0x0f49, 0x0c70, 0x0005, + 0x2001, 0x0382, 0x2004, 0x9084, 0x0007, 0x9086, 0x0001, 0x1120, + 0x2001, 0x0015, 0x080c, 0xaf93, 0x2079, 0x0380, 0x2069, 0x1b1e, + 0x7818, 0x6802, 0x781c, 0x6806, 0x7840, 0x680a, 0x7844, 0x680e, + 0x782c, 0x6812, 0x2019, 0x1b29, 0x9016, 0x7808, 0xd09c, 0x0150, + 0x7820, 0x201a, 0x8210, 0x8318, 0x8210, 0x9282, 0x0011, 0x0ea8, + 0x2011, 0xdead, 0x6a2a, 0x7830, 0x681a, 0x7834, 0x681e, 0x7838, + 0x6822, 0x783c, 0x6826, 0x7803, 0x0000, 0x2069, 0x1ade, 0x901e, + 0x20a9, 0x0020, 0x7b26, 0x7828, 0x206a, 0x8d68, 0x8318, 0x1f04, + 0x0e62, 0x2069, 0x1afe, 0x2019, 0x00b0, 0x20a9, 0x0020, 0x7b26, + 0x7828, 0x206a, 0x8d68, 0x8318, 0x1f04, 0x0e6f, 0x0005, 0x918c, + 0x03ff, 0x2001, 0x0003, 0x2004, 0x9084, 0x0600, 0x1118, 0x918d, + 0x6c00, 0x0010, 0x918d, 0x6400, 0x2001, 0x017f, 0x2102, 0x0005, + 0x0026, 0x0126, 0x2011, 0x0080, 0x080c, 0x0f27, 0x20a9, 0x0900, + 0x080c, 0x0f5d, 0x2011, 0x0040, 0x080c, 0x0f27, 0x20a9, 0x0900, + 0x080c, 0x0f5d, 0x0c78, 0x0026, 0x080c, 0x0f35, 0x1188, 0x2011, + 0x010e, 0x2214, 0x9294, 0x0007, 0x9296, 0x0007, 0x0118, 0x2011, + 0x0947, 0x0010, 0x2011, 0x1b47, 0x080c, 0x0f49, 0x002e, 0x0005, 0x2011, 0x010e, 0x2214, 0x9294, 0x0007, 0x9296, 0x0007, 0x0118, - 0x2011, 0x0947, 0x0010, 0x2011, 0x1b47, 0x080c, 0x0f42, 0x002e, - 0x0005, 0x2011, 0x010e, 0x2214, 0x9294, 0x0007, 0x9296, 0x0007, - 0x0118, 0x2011, 0xa880, 0x0010, 0x2011, 0x6840, 0xd0e4, 0x70ef, - 0x0000, 0x1120, 0x70ef, 0x0fa0, 0x080c, 0x0f33, 0x002e, 0x0005, - 0x0026, 0x080c, 0x0f2e, 0x0148, 0xd0a4, 0x1138, 0x2011, 0xcdd5, - 0x0010, 0x2011, 0x0080, 0x080c, 0x0f33, 0x002e, 0x0005, 0x0026, - 0x70ef, 0x0000, 0x080c, 0x0f2e, 0x1130, 0x2011, 0x8040, 0x080c, - 0x0f42, 0x002e, 0x0005, 0x080c, 0x28d7, 0x1118, 0x2011, 0xcdc5, - 0x0010, 0x2011, 0xcac2, 0x080c, 0x0f33, 0x002e, 0x0005, 0x00e6, - 0x0016, 0x0006, 0x2071, 0x1800, 0xd0b4, 0x70e8, 0x71e4, 0x1118, - 0xc0e4, 0xc1f4, 0x0050, 0x0006, 0x3b00, 0x9084, 0xff3e, 0x20d8, - 0x000e, 0x70ef, 0x0000, 0xc0e5, 0xc1f5, 0x0099, 0x000e, 0x001e, - 0x00ee, 0x0005, 0x00e6, 0x2071, 0x1800, 0xd0e4, 0x70e8, 0x1110, - 0xc0dc, 0x0008, 0xc0dd, 0x0016, 0x71e4, 0x0019, 0x001e, 0x00ee, - 0x0005, 0x70ea, 0x71e6, 0x7000, 0x9084, 0x0007, 0x000b, 0x0005, - 0x0ee6, 0x0ec0, 0x0ec0, 0x0e94, 0x0ecf, 0x0ec0, 0x0ec0, 0x0ecf, - 0xc284, 0x0016, 0x3b08, 0x3a00, 0x9104, 0x918d, 0x00c1, 0x21d8, - 0x9084, 0xff3e, 0x9205, 0x20d0, 0x001e, 0x0005, 0x2001, 0x183a, - 0x2004, 0xd0dc, 0x0005, 0x9e86, 0x1800, 0x190c, 0x0d81, 0x70e8, - 0xd0e4, 0x0108, 0xc2e5, 0x72ea, 0xd0e4, 0x1118, 0x9294, 0x00c1, - 0x08f9, 0x0005, 0x9e86, 0x1800, 0x190c, 0x0d81, 0x70e4, 0xd0f4, - 0x0108, 0xc2f5, 0x72e6, 0xd0f4, 0x1140, 0x9284, 0x8000, 0x8005, - 0xc284, 0x9215, 0x9294, 0x00c1, 0x0861, 0x0005, 0x1d04, 0x0f56, - 0x2091, 0x6000, 0x1f04, 0x0f56, 0x0005, 0x890e, 0x810e, 0x810f, - 0x9194, 0x003f, 0x918c, 0xffc0, 0x0005, 0x0006, 0x2200, 0x914d, - 0x894f, 0x894d, 0x894d, 0x000e, 0x0005, 0x01d6, 0x0146, 0x0036, - 0x0096, 0x2061, 0x188b, 0x600b, 0x0000, 0x600f, 0x0000, 0x6003, - 0x0000, 0x6007, 0x0000, 0x2009, 0xffc0, 0x2105, 0x0006, 0x2001, - 0xaaaa, 0x200f, 0x2019, 0x5555, 0x9016, 0x2049, 0x0bff, 0xab02, - 0xa001, 0xa001, 0xa800, 0x9306, 0x1138, 0x2105, 0x9306, 0x0120, - 0x8210, 0x99c8, 0x0400, 0x0c98, 0x000e, 0x200f, 0x2001, 0x189b, - 0x928a, 0x000e, 0x1638, 0x928a, 0x0006, 0x2011, 0x0006, 0x1210, - 0x2011, 0x0000, 0x2202, 0x9006, 0x2008, 0x82ff, 0x01b0, 0x8200, - 0x600a, 0x600f, 0xffff, 0x6003, 0x0002, 0x6007, 0x0000, 0x0026, - 0x2019, 0x0010, 0x9280, 0x0001, 0x20e8, 0x21a0, 0x21a8, 0x4104, - 0x8319, 0x1de0, 0x8211, 0x1da0, 0x002e, 0x009e, 0x003e, 0x014e, - 0x01de, 0x0005, 0x2011, 0x000e, 0x08e8, 0x0016, 0x0026, 0x0096, - 0x3348, 0x080c, 0x0f5d, 0x2100, 0x9300, 0x2098, 0x22e0, 0x009e, - 0x002e, 0x001e, 0x0036, 0x3518, 0x20a9, 0x0001, 0x4002, 0x8007, - 0x4004, 0x8319, 0x1dd8, 0x003e, 0x0005, 0x20e9, 0x0001, 0x71b4, - 0x81ff, 0x11c0, 0x9006, 0x2009, 0x0200, 0x20a9, 0x0002, 0x9298, - 0x0018, 0x23a0, 0x4001, 0x2009, 0x0700, 0x20a9, 0x0002, 0x9298, - 0x0008, 0x23a0, 0x4001, 0x7078, 0x8007, 0x717c, 0x810f, 0x20a9, - 0x0002, 0x4001, 0x9298, 0x000c, 0x23a0, 0x900e, 0x080c, 0x0d61, - 0x2001, 0x0000, 0x810f, 0x20a9, 0x0002, 0x4001, 0x0005, 0x89ff, - 0x0140, 0xa804, 0xa807, 0x0000, 0x0006, 0x080c, 0x1087, 0x009e, - 0x0cb0, 0x0005, 0x00e6, 0x2071, 0x1800, 0x080c, 0x1100, 0x090c, - 0x0d81, 0x00ee, 0x0005, 0x0086, 0x00e6, 0x0006, 0x0026, 0x0036, - 0x0126, 0x2091, 0x8000, 0x00c9, 0x2071, 0x1800, 0x73bc, 0x702c, - 0x9016, 0x9045, 0x0158, 0x8210, 0x9906, 0x090c, 0x0d81, 0x2300, - 0x9202, 0x0120, 0x1a0c, 0x0d81, 0xa000, 0x0c98, 0x012e, 0x003e, - 0x002e, 0x000e, 0x00ee, 0x008e, 0x0005, 0x0086, 0x00e6, 0x0006, - 0x0126, 0x2091, 0x8000, 0x2071, 0x190e, 0x7010, 0x9005, 0x0140, - 0x7018, 0x9045, 0x0128, 0x9906, 0x090c, 0x0d81, 0xa000, 0x0cc8, - 0x012e, 0x000e, 0x00ee, 0x008e, 0x0005, 0x00e6, 0x2071, 0x1800, - 0x0126, 0x2091, 0x8000, 0x70bc, 0x8001, 0x0270, 0x70be, 0x702c, - 0x2048, 0x9085, 0x0001, 0xa800, 0x702e, 0xa803, 0x0000, 0xa807, + 0x2011, 0xa880, 0x0010, 0x2011, 0x6840, 0xd0e4, 0x70f3, 0x0000, + 0x1120, 0x70f3, 0x0fa0, 0x080c, 0x0f3a, 0x002e, 0x0005, 0x0026, + 0x080c, 0x0f35, 0x0148, 0xd0a4, 0x1138, 0x2011, 0xcdd5, 0x0010, + 0x2011, 0x0080, 0x080c, 0x0f3a, 0x002e, 0x0005, 0x0026, 0x70f3, + 0x0000, 0x080c, 0x0f35, 0x1130, 0x2011, 0x8040, 0x080c, 0x0f49, + 0x002e, 0x0005, 0x080c, 0x2b16, 0x1118, 0x2011, 0xcdc5, 0x0010, + 0x2011, 0xcac2, 0x080c, 0x0f3a, 0x002e, 0x0005, 0x00e6, 0x0016, + 0x0006, 0x2071, 0x1800, 0xd0b4, 0x70ec, 0x71e8, 0x1118, 0xc0e4, + 0xc1f4, 0x0050, 0x0006, 0x3b00, 0x9084, 0xff3e, 0x20d8, 0x000e, + 0x70f3, 0x0000, 0xc0e5, 0xc1f5, 0x0099, 0x000e, 0x001e, 0x00ee, + 0x0005, 0x00e6, 0x2071, 0x1800, 0xd0e4, 0x70ec, 0x1110, 0xc0dc, + 0x0008, 0xc0dd, 0x0016, 0x71e8, 0x0019, 0x001e, 0x00ee, 0x0005, + 0x70ee, 0x71ea, 0x7000, 0x9084, 0x0007, 0x000b, 0x0005, 0x0eed, + 0x0ec7, 0x0ec7, 0x0e9b, 0x0ed6, 0x0ec7, 0x0ec7, 0x0ed6, 0xc284, + 0x0016, 0x3b08, 0x3a00, 0x9104, 0x918d, 0x00c1, 0x21d8, 0x9084, + 0xff3e, 0x9205, 0x20d0, 0x001e, 0x0005, 0x2001, 0x183b, 0x2004, + 0xd0dc, 0x0005, 0x9e86, 0x1800, 0x190c, 0x0d87, 0x70ec, 0xd0e4, + 0x0108, 0xc2e5, 0x72ee, 0xd0e4, 0x1118, 0x9294, 0x00c1, 0x08f9, + 0x0005, 0x9e86, 0x1800, 0x190c, 0x0d87, 0x70e8, 0xd0f4, 0x0108, + 0xc2f5, 0x72ea, 0xd0f4, 0x1140, 0x9284, 0x8000, 0x8005, 0xc284, + 0x9215, 0x9294, 0x00c1, 0x0861, 0x0005, 0x1d04, 0x0f5d, 0x2091, + 0x6000, 0x1f04, 0x0f5d, 0x0005, 0x890e, 0x810e, 0x810f, 0x9194, + 0x003f, 0x918c, 0xffc0, 0x0005, 0x0006, 0x2200, 0x914d, 0x894f, + 0x894d, 0x894d, 0x000e, 0x0005, 0x01d6, 0x0146, 0x0036, 0x0096, + 0x2061, 0x1890, 0x600b, 0x0000, 0x600f, 0x0000, 0x6003, 0x0000, + 0x6007, 0x0000, 0x2009, 0xffc0, 0x2105, 0x0006, 0x2001, 0xaaaa, + 0x200f, 0x2019, 0x5555, 0x9016, 0x2049, 0x0bff, 0xab02, 0xa001, + 0xa001, 0xa800, 0x9306, 0x1138, 0x2105, 0x9306, 0x0120, 0x8210, + 0x99c8, 0x0400, 0x0c98, 0x000e, 0x200f, 0x2001, 0x18a0, 0x928a, + 0x000e, 0x1638, 0x928a, 0x0006, 0x2011, 0x0006, 0x1210, 0x2011, + 0x0000, 0x2202, 0x9006, 0x2008, 0x82ff, 0x01b0, 0x8200, 0x600a, + 0x600f, 0xffff, 0x6003, 0x0002, 0x6007, 0x0000, 0x0026, 0x2019, + 0x0010, 0x9280, 0x0001, 0x20e8, 0x21a0, 0x21a8, 0x4104, 0x8319, + 0x1de0, 0x8211, 0x1da0, 0x002e, 0x009e, 0x003e, 0x014e, 0x01de, + 0x0005, 0x2011, 0x000e, 0x08e8, 0x0016, 0x0026, 0x0096, 0x3348, + 0x080c, 0x0f64, 0x2100, 0x9300, 0x2098, 0x22e0, 0x009e, 0x002e, + 0x001e, 0x0036, 0x3518, 0x20a9, 0x0001, 0x4002, 0x8007, 0x4004, + 0x8319, 0x1dd8, 0x003e, 0x0005, 0x20e9, 0x0001, 0x71b8, 0x81ff, + 0x11c0, 0x9006, 0x2009, 0x0200, 0x20a9, 0x0002, 0x9298, 0x0018, + 0x23a0, 0x4001, 0x2009, 0x0700, 0x20a9, 0x0002, 0x9298, 0x0008, + 0x23a0, 0x4001, 0x707c, 0x8007, 0x7180, 0x810f, 0x20a9, 0x0002, + 0x4001, 0x9298, 0x000c, 0x23a0, 0x900e, 0x080c, 0x0d67, 0x2001, + 0x0000, 0x810f, 0x20a9, 0x0002, 0x4001, 0x0005, 0x89ff, 0x0140, + 0xa804, 0xa807, 0x0000, 0x0006, 0x080c, 0x108e, 0x009e, 0x0cb0, + 0x0005, 0x00e6, 0x2071, 0x1800, 0x080c, 0x1107, 0x090c, 0x0d87, + 0x00ee, 0x0005, 0x0086, 0x00e6, 0x0006, 0x0026, 0x0036, 0x0126, + 0x2091, 0x8000, 0x00c9, 0x2071, 0x1800, 0x73c0, 0x702c, 0x9016, + 0x9045, 0x0158, 0x8210, 0x9906, 0x090c, 0x0d87, 0x2300, 0x9202, + 0x0120, 0x1a0c, 0x0d87, 0xa000, 0x0c98, 0x012e, 0x003e, 0x002e, + 0x000e, 0x00ee, 0x008e, 0x0005, 0x0086, 0x00e6, 0x0006, 0x0126, + 0x2091, 0x8000, 0x2071, 0x1913, 0x7010, 0x9005, 0x0140, 0x7018, + 0x9045, 0x0128, 0x9906, 0x090c, 0x0d87, 0xa000, 0x0cc8, 0x012e, + 0x000e, 0x00ee, 0x008e, 0x0005, 0x00e6, 0x2071, 0x1800, 0x0126, + 0x2091, 0x8000, 0x70c0, 0x8001, 0x0270, 0x70c2, 0x702c, 0x2048, + 0x9085, 0x0001, 0xa800, 0x702e, 0xa803, 0x0000, 0xa807, 0x0000, + 0x012e, 0x00ee, 0x0005, 0x904e, 0x0cd8, 0x00e6, 0x0126, 0x2091, + 0x8000, 0x2071, 0x1800, 0x70c0, 0x90ca, 0x0020, 0x0268, 0x8001, + 0x70c2, 0x702c, 0x2048, 0xa800, 0x702e, 0xa803, 0x0000, 0xa807, 0x0000, 0x012e, 0x00ee, 0x0005, 0x904e, 0x0cd8, 0x00e6, 0x0126, - 0x2091, 0x8000, 0x2071, 0x1800, 0x70bc, 0x90ca, 0x0040, 0x0268, - 0x8001, 0x70be, 0x702c, 0x2048, 0xa800, 0x702e, 0xa803, 0x0000, - 0xa807, 0x0000, 0x012e, 0x00ee, 0x0005, 0x904e, 0x0cd8, 0x00e6, - 0x0126, 0x2091, 0x8000, 0x0016, 0x890e, 0x810e, 0x810f, 0x9184, - 0x003f, 0xa862, 0x9184, 0xffc0, 0xa85e, 0x001e, 0x0020, 0x00e6, - 0x0126, 0x2091, 0x8000, 0x2071, 0x1800, 0x702c, 0xa802, 0x2900, - 0x702e, 0x70bc, 0x8000, 0x70be, 0x080c, 0x8353, 0x012e, 0x00ee, - 0x0005, 0x2071, 0x1800, 0x9026, 0x2009, 0x0000, 0x2049, 0x0400, - 0x2900, 0x702e, 0x8940, 0x2800, 0xa802, 0xa95e, 0xa863, 0x0001, - 0x8420, 0x9886, 0x0440, 0x0120, 0x2848, 0x9188, 0x0040, 0x0c90, - 0x2071, 0x188b, 0x7000, 0x9005, 0x11a0, 0x2001, 0x0558, 0xa802, - 0x2048, 0x2009, 0x5600, 0x8940, 0x2800, 0xa802, 0xa95e, 0xa863, - 0x0001, 0x8420, 0x9886, 0x0800, 0x0120, 0x2848, 0x9188, 0x0040, - 0x0c90, 0x2071, 0x188b, 0x7104, 0x7200, 0x82ff, 0x01d0, 0x7308, - 0x8318, 0x831f, 0x831b, 0x831b, 0x7312, 0x8319, 0x2001, 0x0800, - 0xa802, 0x2048, 0x8900, 0xa802, 0x2040, 0xa95e, 0xaa62, 0x8420, - 0x2300, 0x9906, 0x0130, 0x2848, 0x9188, 0x0040, 0x9291, 0x0000, - 0x0c88, 0xa803, 0x0000, 0x2071, 0x1800, 0x74ba, 0x74be, 0x0005, - 0x00e6, 0x0016, 0x9984, 0xfc00, 0x01e8, 0x908c, 0xf800, 0x1168, - 0x9982, 0x0400, 0x02b8, 0x9982, 0x0440, 0x0278, 0x9982, 0x0558, - 0x0288, 0x9982, 0x0800, 0x1270, 0x0040, 0x9982, 0x0800, 0x0250, - 0x2071, 0x188b, 0x7010, 0x9902, 0x1228, 0x9085, 0x0001, 0x001e, - 0x00ee, 0x0005, 0x9006, 0x0cd8, 0x00e6, 0x2071, 0x19fd, 0x7007, - 0x0000, 0x9006, 0x701e, 0x7022, 0x7002, 0x2071, 0x0000, 0x7010, - 0x9085, 0x8044, 0x7012, 0x2071, 0x0080, 0x9006, 0x702b, 0x0060, - 0x20a9, 0x0040, 0x7022, 0x1f04, 0x113a, 0x702b, 0x0060, 0x702b, - 0x0020, 0x20a9, 0x0040, 0x7022, 0x1f04, 0x1143, 0x702b, 0x0020, - 0x00ee, 0x0005, 0x0126, 0x2091, 0x8000, 0x00e6, 0xa06f, 0x0000, - 0x2071, 0x19fd, 0x701c, 0x9088, 0x1a07, 0x280a, 0x8000, 0x9084, - 0x003f, 0x701e, 0x7120, 0x9106, 0x090c, 0x0d81, 0x7004, 0x9005, - 0x1128, 0x00f6, 0x2079, 0x0080, 0x00a9, 0x00fe, 0x00ee, 0x012e, - 0x0005, 0x0126, 0x2091, 0x8000, 0x00e6, 0x2071, 0x19fd, 0x7004, - 0x9005, 0x1128, 0x00f6, 0x2079, 0x0080, 0x0021, 0x00fe, 0x00ee, - 0x012e, 0x0005, 0x7004, 0x9086, 0x0000, 0x1110, 0x7007, 0x0006, - 0x7000, 0x0002, 0x118c, 0x118a, 0x118a, 0x118a, 0x1303, 0x1303, - 0x1303, 0x1303, 0x080c, 0x0d81, 0x701c, 0x7120, 0x9106, 0x1148, - 0x792c, 0x9184, 0x0001, 0x1120, 0xd1fc, 0x1110, 0x7007, 0x0000, - 0x0005, 0x0096, 0x9180, 0x1a07, 0x2004, 0x700a, 0x2048, 0x8108, - 0x918c, 0x003f, 0x7122, 0x782b, 0x0026, 0xa88c, 0x7802, 0xa890, - 0x7806, 0xa894, 0x780a, 0xa898, 0x780e, 0xa878, 0x700e, 0xa870, - 0x7016, 0xa874, 0x701a, 0xa868, 0x009e, 0xd084, 0x0120, 0x7007, - 0x0001, 0x0029, 0x0005, 0x7007, 0x0002, 0x00b1, 0x0005, 0x0016, - 0x0026, 0x710c, 0x2011, 0x0040, 0x9182, 0x0040, 0x1210, 0x2110, - 0x9006, 0x700e, 0x7212, 0x8203, 0x7812, 0x782b, 0x0020, 0x782b, - 0x0041, 0x002e, 0x001e, 0x0005, 0x0016, 0x0026, 0x0136, 0x0146, - 0x0156, 0x7014, 0x20e0, 0x7018, 0x2098, 0x20e9, 0x0000, 0x20a1, - 0x0088, 0x782b, 0x0026, 0x710c, 0x2011, 0x0040, 0x9182, 0x0040, - 0x1210, 0x2110, 0x9006, 0x700e, 0x22a8, 0x4006, 0x8203, 0x7812, - 0x782b, 0x0020, 0x3300, 0x701a, 0x782b, 0x0001, 0x015e, 0x014e, - 0x013e, 0x002e, 0x001e, 0x0005, 0x2009, 0x19fd, 0x2104, 0xc095, - 0x200a, 0x080c, 0x1169, 0x0005, 0x0016, 0x00e6, 0x2071, 0x19fd, - 0x00f6, 0x2079, 0x0080, 0x792c, 0xd1bc, 0x190c, 0x0d7a, 0x782b, - 0x0002, 0xd1fc, 0x0120, 0x918c, 0x0700, 0x7004, 0x0023, 0x00fe, - 0x00ee, 0x001e, 0x0005, 0x117a, 0x1222, 0x1256, 0x0d81, 0x0d81, - 0x130f, 0x0d81, 0x918c, 0x0700, 0x1550, 0x0136, 0x0146, 0x0156, - 0x7014, 0x20e8, 0x7018, 0x20a0, 0x20e1, 0x0000, 0x2099, 0x0088, - 0x782b, 0x0040, 0x7010, 0x20a8, 0x4005, 0x3400, 0x701a, 0x015e, - 0x014e, 0x013e, 0x700c, 0x9005, 0x0578, 0x7800, 0x7802, 0x7804, - 0x7806, 0x080c, 0x11bf, 0x0005, 0x7008, 0x0096, 0x2048, 0xa86f, - 0x0100, 0x009e, 0x7007, 0x0000, 0x080c, 0x117a, 0x0005, 0x7008, - 0x0096, 0x2048, 0xa86f, 0x0200, 0x009e, 0x0ca0, 0x918c, 0x0700, - 0x1150, 0x700c, 0x9005, 0x0180, 0x7800, 0x7802, 0x7804, 0x7806, - 0x080c, 0x11d4, 0x0005, 0x7008, 0x0096, 0x2048, 0xa86f, 0x0200, - 0x009e, 0x7007, 0x0000, 0x0080, 0x0096, 0x7008, 0x2048, 0x7800, - 0xa88e, 0x7804, 0xa892, 0x7808, 0xa896, 0x780c, 0xa89a, 0xa86f, - 0x0100, 0x009e, 0x7007, 0x0000, 0x0096, 0x00d6, 0x7008, 0x2048, - 0x2001, 0x18b7, 0x2004, 0x9906, 0x1128, 0xa89c, 0x080f, 0x00de, - 0x009e, 0x00a0, 0x00de, 0x009e, 0x0096, 0x00d6, 0x7008, 0x2048, - 0x0081, 0x0150, 0xa89c, 0x0086, 0x2940, 0x080f, 0x008e, 0x00de, - 0x009e, 0x080c, 0x1169, 0x0005, 0x00de, 0x009e, 0x080c, 0x1169, - 0x0005, 0xa8a8, 0xd08c, 0x0005, 0x0096, 0xa0a0, 0x904d, 0x090c, - 0x0d81, 0xa06c, 0x908e, 0x0100, 0x0130, 0xa87b, 0x0030, 0xa883, - 0x0000, 0xa897, 0x4002, 0x080c, 0x6bf7, 0xa09f, 0x0000, 0xa0a3, - 0x0000, 0x2848, 0x080c, 0x1087, 0x009e, 0x0005, 0x00a6, 0xa0a0, - 0x904d, 0x090c, 0x0d81, 0xa06c, 0x908e, 0x0100, 0x0128, 0xa87b, - 0x0001, 0xa883, 0x0000, 0x00c0, 0xa80c, 0x2050, 0xb004, 0x9005, - 0x0198, 0xa80e, 0x2050, 0x8006, 0x8006, 0x8007, 0x908c, 0x003f, - 0x9084, 0xffc0, 0x9080, 0x0002, 0xa076, 0xa172, 0xb000, 0xa07a, - 0x2810, 0x080c, 0x114a, 0x00e8, 0xa97c, 0xa894, 0x0016, 0x0006, - 0x080c, 0x6bf7, 0x000e, 0x001e, 0xd1fc, 0x1138, 0xd1f4, 0x0128, - 0x00c6, 0x2060, 0x080c, 0xa07a, 0x00ce, 0x7008, 0x2048, 0xa89f, - 0x0000, 0xa8a3, 0x0000, 0x080c, 0x1087, 0x7007, 0x0000, 0x080c, - 0x1169, 0x00ae, 0x0005, 0x0126, 0x2091, 0x8000, 0x782b, 0x1001, - 0x7007, 0x0005, 0x7000, 0xc094, 0x7002, 0x012e, 0x0005, 0x7007, - 0x0000, 0x080c, 0x117a, 0x0005, 0x0126, 0x2091, 0x2200, 0x2079, - 0x0300, 0x2071, 0x1a47, 0x7003, 0x0000, 0x78bf, 0x00f6, 0x0041, - 0x7807, 0x0007, 0x7803, 0x0000, 0x7803, 0x0001, 0x012e, 0x0005, - 0x00c6, 0x7803, 0x0000, 0x2001, 0x0165, 0x2003, 0x4198, 0x7808, - 0xd09c, 0x0110, 0x7820, 0x0cd8, 0x2001, 0x1a48, 0x2003, 0x0000, + 0x2091, 0x8000, 0x0016, 0x890e, 0x810e, 0x810f, 0x9184, 0x003f, + 0xa862, 0x9184, 0xffc0, 0xa85e, 0x001e, 0x0020, 0x00e6, 0x0126, + 0x2091, 0x8000, 0x2071, 0x1800, 0x702c, 0xa802, 0x2900, 0x702e, + 0x70c0, 0x8000, 0x70c2, 0x080c, 0x8ad8, 0x012e, 0x00ee, 0x0005, + 0x2071, 0x1800, 0x9026, 0x2009, 0x0000, 0x2049, 0x0400, 0x2900, + 0x702e, 0x8940, 0x2800, 0xa802, 0xa95e, 0xa863, 0x0001, 0x8420, + 0x9886, 0x0440, 0x0120, 0x2848, 0x9188, 0x0040, 0x0c90, 0x2071, + 0x1890, 0x7000, 0x9005, 0x11a0, 0x2001, 0x0558, 0xa802, 0x2048, + 0x2009, 0x5600, 0x8940, 0x2800, 0xa802, 0xa95e, 0xa863, 0x0001, + 0x8420, 0x9886, 0x0800, 0x0120, 0x2848, 0x9188, 0x0040, 0x0c90, + 0x2071, 0x1890, 0x7104, 0x7200, 0x82ff, 0x01d0, 0x7308, 0x8318, + 0x831f, 0x831b, 0x831b, 0x7312, 0x8319, 0x2001, 0x0800, 0xa802, + 0x2048, 0x8900, 0xa802, 0x2040, 0xa95e, 0xaa62, 0x8420, 0x2300, + 0x9906, 0x0130, 0x2848, 0x9188, 0x0040, 0x9291, 0x0000, 0x0c88, + 0xa803, 0x0000, 0x2071, 0x1800, 0x74be, 0x74c2, 0x0005, 0x00e6, + 0x0016, 0x9984, 0xfc00, 0x01e8, 0x908c, 0xf800, 0x1168, 0x9982, + 0x0400, 0x02b8, 0x9982, 0x0440, 0x0278, 0x9982, 0x0558, 0x0288, + 0x9982, 0x0800, 0x1270, 0x0040, 0x9982, 0x0800, 0x0250, 0x2071, + 0x1890, 0x7010, 0x9902, 0x1228, 0x9085, 0x0001, 0x001e, 0x00ee, + 0x0005, 0x9006, 0x0cd8, 0x00e6, 0x2071, 0x1a37, 0x7007, 0x0000, + 0x9006, 0x701e, 0x7022, 0x7002, 0x2071, 0x0000, 0x7010, 0x9085, + 0x8044, 0x7012, 0x2071, 0x0080, 0x9006, 0x702b, 0x0060, 0x20a9, + 0x0040, 0x7022, 0x1f04, 0x1141, 0x702b, 0x0060, 0x702b, 0x0020, + 0x20a9, 0x0040, 0x7022, 0x1f04, 0x114a, 0x702b, 0x0020, 0x00ee, + 0x0005, 0x0126, 0x2091, 0x8000, 0x00e6, 0xa073, 0x0000, 0x2071, + 0x1a37, 0x701c, 0x9088, 0x1a41, 0x280a, 0x8000, 0x9084, 0x003f, + 0x701e, 0x7120, 0x9106, 0x090c, 0x0d87, 0x7004, 0x9005, 0x1128, + 0x00f6, 0x2079, 0x0080, 0x00a9, 0x00fe, 0x00ee, 0x012e, 0x0005, + 0x0126, 0x2091, 0x8000, 0x00e6, 0x2071, 0x1a37, 0x7004, 0x9005, + 0x1128, 0x00f6, 0x2079, 0x0080, 0x0021, 0x00fe, 0x00ee, 0x012e, + 0x0005, 0x7004, 0x9086, 0x0000, 0x1110, 0x7007, 0x0006, 0x7000, + 0x0002, 0x1193, 0x1319, 0x1191, 0x1191, 0x130d, 0x130d, 0x130d, + 0x130d, 0x080c, 0x0d87, 0x701c, 0x7120, 0x9106, 0x1148, 0x792c, + 0x9184, 0x0001, 0x1120, 0xd1fc, 0x1110, 0x7007, 0x0000, 0x0005, + 0x0096, 0x9180, 0x1a41, 0x2004, 0x700a, 0x2048, 0x8108, 0x918c, + 0x003f, 0x7122, 0x782b, 0x0026, 0xa890, 0x7802, 0xa894, 0x7806, + 0xa898, 0x780a, 0xa89c, 0x780e, 0xa87c, 0x700e, 0xa874, 0x7016, + 0xa878, 0x701a, 0xa86c, 0x009e, 0xd084, 0x0120, 0x7007, 0x0001, + 0x0029, 0x0005, 0x7007, 0x0002, 0x00b1, 0x0005, 0x0016, 0x0026, + 0x710c, 0x2011, 0x0040, 0x9182, 0x0040, 0x1210, 0x2110, 0x9006, + 0x700e, 0x7212, 0x8203, 0x7812, 0x782b, 0x0020, 0x782b, 0x0041, + 0x002e, 0x001e, 0x0005, 0x0016, 0x0026, 0x0136, 0x0146, 0x0156, + 0x7014, 0x20e0, 0x7018, 0x2098, 0x20e9, 0x0000, 0x20a1, 0x0088, + 0x782b, 0x0026, 0x710c, 0x2011, 0x0040, 0x9182, 0x0040, 0x1210, + 0x2110, 0x9006, 0x700e, 0x22a8, 0x4006, 0x8203, 0x7812, 0x782b, + 0x0020, 0x3300, 0x701a, 0x782b, 0x0001, 0x015e, 0x014e, 0x013e, + 0x002e, 0x001e, 0x0005, 0x0016, 0x2009, 0x1a37, 0x2104, 0xc095, + 0x200a, 0x080c, 0x1170, 0x001e, 0x0005, 0x0016, 0x00e6, 0x2071, + 0x1a37, 0x00f6, 0x2079, 0x0080, 0x792c, 0xd1bc, 0x190c, 0x0d80, + 0x782b, 0x0002, 0xd1fc, 0x0120, 0x918c, 0x0700, 0x7004, 0x0023, + 0x00fe, 0x00ee, 0x001e, 0x0005, 0x1181, 0x122b, 0x125f, 0x1338, + 0x0d87, 0x1353, 0x0d87, 0x918c, 0x0700, 0x1550, 0x0136, 0x0146, + 0x0156, 0x7014, 0x20e8, 0x7018, 0x20a0, 0x20e1, 0x0000, 0x2099, + 0x0088, 0x782b, 0x0040, 0x7010, 0x20a8, 0x4005, 0x3400, 0x701a, + 0x015e, 0x014e, 0x013e, 0x700c, 0x9005, 0x0578, 0x7800, 0x7802, + 0x7804, 0x7806, 0x080c, 0x11c6, 0x0005, 0x7008, 0x0096, 0x2048, + 0xa873, 0x0100, 0x009e, 0x7007, 0x0000, 0x080c, 0x1181, 0x0005, + 0x7008, 0x0096, 0x2048, 0xa873, 0x0200, 0x009e, 0x0ca0, 0x918c, + 0x0700, 0x1150, 0x700c, 0x9005, 0x0180, 0x7800, 0x7802, 0x7804, + 0x7806, 0x080c, 0x11db, 0x0005, 0x7008, 0x0096, 0x2048, 0xa873, + 0x0200, 0x009e, 0x7007, 0x0000, 0x0080, 0x0096, 0x7008, 0x2048, + 0x7800, 0xa892, 0x7804, 0xa896, 0x7808, 0xa89a, 0x780c, 0xa89e, + 0xa873, 0x0100, 0x009e, 0x7007, 0x0000, 0x0096, 0x00d6, 0x7008, + 0x2048, 0x2001, 0x18bc, 0x2004, 0x9906, 0x1128, 0xa8a0, 0x080f, + 0x00de, 0x009e, 0x00a0, 0x00de, 0x009e, 0x0096, 0x00d6, 0x7008, + 0x2048, 0x0081, 0x0150, 0xa8a0, 0x0086, 0x2940, 0x080f, 0x008e, + 0x00de, 0x009e, 0x080c, 0x1170, 0x0005, 0x00de, 0x009e, 0x080c, + 0x1170, 0x0005, 0xa8ac, 0xd08c, 0x0005, 0x0096, 0xa0a4, 0x904d, + 0x090c, 0x0d87, 0xa070, 0x908e, 0x0100, 0x0130, 0xa87f, 0x0030, + 0xa887, 0x0000, 0xa89b, 0x4002, 0xa898, 0x908e, 0x006b, 0x090c, + 0x49da, 0x080c, 0x71f3, 0xa0a3, 0x0000, 0xa0a7, 0x0000, 0x2848, + 0x080c, 0x108e, 0x009e, 0x0005, 0x00a6, 0xa0a4, 0x904d, 0x090c, + 0x0d87, 0xa070, 0x908e, 0x0100, 0x0128, 0xa87f, 0x0001, 0xa887, + 0x0000, 0x00c0, 0xa80c, 0x2050, 0xb004, 0x9005, 0x0198, 0xa80e, + 0x2050, 0x8006, 0x8006, 0x8007, 0x908c, 0x003f, 0x9084, 0xffc0, + 0x9080, 0x0002, 0xa07a, 0xa176, 0xb000, 0xa07e, 0x2810, 0x080c, + 0x1151, 0x00c8, 0xa980, 0xa898, 0x0016, 0x0006, 0x080c, 0x71f3, + 0x000e, 0x001e, 0xd1a4, 0x0128, 0x00c6, 0x2060, 0x080c, 0xb433, + 0x00ce, 0x7008, 0x2048, 0xa8a3, 0x0000, 0xa8a7, 0x0000, 0x080c, + 0x108e, 0x080c, 0x1170, 0x00ae, 0x0005, 0x0126, 0x2091, 0x8000, + 0x782b, 0x1001, 0x7007, 0x0005, 0x7000, 0xc094, 0x7002, 0x012e, + 0x0005, 0x0096, 0x2001, 0x1932, 0x204c, 0xa880, 0x7812, 0xa890, + 0x7802, 0xa894, 0x7806, 0xa898, 0x780a, 0xa89c, 0x780e, 0x782b, + 0x0020, 0x0126, 0x2091, 0x8000, 0x782b, 0x0041, 0x7007, 0x0003, + 0x7000, 0xc084, 0x7002, 0x2900, 0x700a, 0x012e, 0x009e, 0x0005, + 0x20e1, 0x0000, 0x2099, 0x0088, 0x782b, 0x0040, 0x0096, 0x2001, + 0x1932, 0x204c, 0xaa80, 0x009e, 0x080c, 0x920c, 0x2009, 0x188f, + 0x2104, 0x9084, 0xfffc, 0x200a, 0x080c, 0x907b, 0x7007, 0x0000, + 0x080c, 0x1181, 0x0005, 0x7007, 0x0000, 0x080c, 0x1181, 0x0005, + 0x0126, 0x2091, 0x2200, 0x2079, 0x0300, 0x2071, 0x1a81, 0x7003, + 0x0000, 0x78bf, 0x00f6, 0x0041, 0x7807, 0x0007, 0x7803, 0x0000, + 0x7803, 0x0001, 0x012e, 0x0005, 0x00c6, 0x7803, 0x0000, 0x2001, + 0x0165, 0x2003, 0x4198, 0x781b, 0x0400, 0x7808, 0xd09c, 0x0120, + 0x7820, 0x080c, 0x13be, 0x0cc8, 0x2001, 0x1a82, 0x2003, 0x0000, 0x78ab, 0x0004, 0x78ac, 0xd0ac, 0x1de8, 0x78ab, 0x0002, 0x7807, 0x0007, 0x7827, 0x0030, 0x782b, 0x0400, 0x7827, 0x0031, 0x782b, - 0x1a59, 0x78e3, 0xff00, 0x781f, 0xff00, 0x781b, 0xff00, 0x2001, - 0x1a49, 0x2003, 0x0000, 0x2001, 0x0200, 0x2004, 0xd0dc, 0x0110, - 0x781f, 0x0303, 0x2061, 0x1a59, 0x602f, 0x1ddc, 0x2001, 0x1819, - 0x2004, 0x9082, 0x1ddc, 0x6032, 0x603b, 0x1d99, 0x602b, 0x1a99, - 0x6007, 0x1a79, 0x2061, 0x1a79, 0x00ce, 0x0005, 0x0126, 0x2091, - 0x2200, 0x7908, 0x9184, 0x0070, 0x190c, 0x0d7a, 0xd19c, 0x05a0, - 0x7820, 0x908c, 0xf000, 0x0540, 0x2060, 0x6020, 0x9086, 0x0003, - 0x1550, 0x6000, 0x9086, 0x0004, 0x1530, 0x6114, 0x2148, 0xa876, - 0xa87a, 0xa867, 0x0103, 0x080c, 0x6a18, 0x00b6, 0x6010, 0x2058, - 0xba3c, 0x8211, 0x0208, 0xba3e, 0xb8c0, 0x9005, 0x190c, 0x65a4, - 0x00be, 0x6044, 0xd0fc, 0x190c, 0x9c5b, 0x080c, 0xa0a2, 0x7808, - 0xd09c, 0x19b0, 0x012e, 0x0005, 0x908a, 0x0024, 0x1a0c, 0x0d81, - 0x002b, 0x012e, 0x0005, 0x04b0, 0x012e, 0x0005, 0x13d2, 0x13f8, - 0x1428, 0x142d, 0x1431, 0x1436, 0x145e, 0x1462, 0x1470, 0x1474, - 0x13d2, 0x1500, 0x1504, 0x1574, 0x13d2, 0x13d2, 0x13d2, 0x13d2, - 0x13d2, 0x13d2, 0x13d2, 0x13d2, 0x13d2, 0x13d2, 0x13d2, 0x13d2, - 0x13d2, 0x1438, 0x13d2, 0x1400, 0x1425, 0x13ec, 0x13d2, 0x140c, - 0x13d6, 0x13d4, 0x080c, 0x0d81, 0x080c, 0x0d7a, 0x080c, 0x157b, - 0x2009, 0x1a55, 0x2104, 0x8000, 0x200a, 0x080c, 0x7dda, 0x080c, - 0x19fe, 0x0005, 0x6044, 0xd0fc, 0x190c, 0x9c5b, 0x2009, 0x0055, - 0x080c, 0xa117, 0x012e, 0x0005, 0x080c, 0x157b, 0x2060, 0x6044, - 0xd0fc, 0x190c, 0x9c5b, 0x2009, 0x0055, 0x080c, 0xa117, 0x0005, - 0x2009, 0x0048, 0x080c, 0x157b, 0x2060, 0x080c, 0xa117, 0x0005, - 0x2009, 0x0054, 0x080c, 0x157b, 0x2060, 0x6044, 0xd0fc, 0x190c, - 0x9c5b, 0x080c, 0xa117, 0x0005, 0x080c, 0x157b, 0x2060, 0x0056, - 0x0066, 0x080c, 0x157b, 0x2028, 0x080c, 0x157b, 0x2030, 0x0036, - 0x0046, 0x2021, 0x0000, 0x2418, 0x2009, 0x0056, 0x080c, 0xa117, - 0x004e, 0x003e, 0x006e, 0x005e, 0x0005, 0x080c, 0x157b, 0x0005, - 0x7004, 0xc085, 0xc0b5, 0x7006, 0x0005, 0x7004, 0xc085, 0x7006, - 0x0005, 0x080c, 0x157b, 0x080c, 0x1671, 0x0005, 0x080c, 0x0d81, - 0x080c, 0x157b, 0x2060, 0x6014, 0x0096, 0x2048, 0xa83b, 0xffff, - 0x009e, 0x2009, 0x0048, 0x080c, 0xa117, 0x2001, 0x015d, 0x2003, - 0x0000, 0x2009, 0x03e8, 0x8109, 0x0160, 0x2001, 0x0201, 0x2004, - 0x9005, 0x0dc8, 0x2001, 0x0218, 0x2004, 0xd0ec, 0x1110, 0x080c, - 0x1580, 0x2001, 0x0307, 0x2003, 0x8000, 0x0005, 0x7004, 0xc095, - 0x7006, 0x0005, 0x080c, 0x157b, 0x2060, 0x6014, 0x0096, 0x2048, - 0xa83b, 0xffff, 0x009e, 0x2009, 0x0048, 0x080c, 0xa117, 0x0005, - 0x080c, 0x157b, 0x080c, 0x0d81, 0x080c, 0x157b, 0x080c, 0x14eb, - 0x7827, 0x0018, 0x79ac, 0xd1dc, 0x0540, 0x7827, 0x0015, 0x7828, - 0x782b, 0x0000, 0x9065, 0x0138, 0x2001, 0x020d, 0x2003, 0x0050, - 0x2003, 0x0020, 0x0400, 0x7004, 0x9005, 0x1180, 0x78ab, 0x0004, - 0x7827, 0x0018, 0x782b, 0x0000, 0xd1bc, 0x090c, 0x0d81, 0x2001, - 0x020d, 0x2003, 0x0050, 0x2003, 0x0020, 0x0490, 0x78ab, 0x0004, - 0x7803, 0x0001, 0x080c, 0x1504, 0x0005, 0x7828, 0x782b, 0x0000, - 0x9065, 0x090c, 0x0d81, 0x6014, 0x2048, 0x78ab, 0x0004, 0x918c, - 0x0700, 0x01a8, 0x080c, 0x7dda, 0x080c, 0x19fe, 0x080c, 0xbdb7, - 0x0158, 0xa9ac, 0xa936, 0xa9b0, 0xa93a, 0xa83f, 0xffff, 0xa843, - 0xffff, 0xa880, 0xc0bd, 0xa882, 0x080c, 0xb983, 0x0005, 0x6010, - 0x00b6, 0x2058, 0xb800, 0x00be, 0xd0bc, 0x6024, 0x190c, 0xc1ba, - 0x2029, 0x00c8, 0x8529, 0x0128, 0x2001, 0x0201, 0x2004, 0x9005, - 0x0dc8, 0x7dbc, 0x080c, 0xdc34, 0xd5a4, 0x1118, 0x080c, 0x1580, - 0x0005, 0x080c, 0x7dda, 0x080c, 0x19fe, 0x0005, 0x781f, 0x0300, - 0x7803, 0x0001, 0x0005, 0x0016, 0x0066, 0x0076, 0x00f6, 0x2079, - 0x0300, 0x7908, 0x918c, 0x0007, 0x9186, 0x0003, 0x0120, 0x2001, - 0x0016, 0x080c, 0x15f1, 0x00fe, 0x007e, 0x006e, 0x001e, 0x0005, - 0x7004, 0xc09d, 0x7006, 0x0005, 0x7104, 0x9184, 0x0004, 0x190c, - 0x0d81, 0xd184, 0x11b1, 0xd19c, 0x0180, 0xc19c, 0x7106, 0x0016, - 0x080c, 0x1654, 0x001e, 0x0148, 0x2001, 0x020d, 0x2003, 0x0050, - 0x2003, 0x0020, 0x080c, 0x1580, 0x0005, 0x81ff, 0x190c, 0x0d81, - 0x0005, 0x2100, 0xc184, 0xc1b4, 0x7106, 0xd0b4, 0x0016, 0x00e6, - 0x1904, 0x1569, 0x2071, 0x0200, 0x080c, 0x1648, 0x080c, 0x1654, - 0x05a8, 0x6014, 0x9005, 0x05a8, 0x0096, 0x2048, 0xa864, 0x009e, - 0x9084, 0x00ff, 0x908e, 0x0029, 0x0160, 0x908e, 0x0048, 0x1548, - 0x601c, 0xd084, 0x11d8, 0x00f6, 0x2c78, 0x080c, 0x16de, 0x00fe, - 0x00a8, 0x00f6, 0x2c78, 0x080c, 0x1822, 0x00fe, 0x2009, 0x01f4, + 0x1a94, 0x78e3, 0xff00, 0x781f, 0xff00, 0x781b, 0xff00, 0x2001, + 0x1a83, 0x2003, 0x0000, 0x2001, 0x0200, 0x2004, 0xd0dc, 0x0110, + 0x781f, 0x0303, 0x2061, 0x1a94, 0x602f, 0x1ddc, 0x2001, 0x181a, + 0x2004, 0x9082, 0x1ddc, 0x6032, 0x603b, 0x1f3c, 0x602b, 0x1ad4, + 0x6007, 0x1ab4, 0x2061, 0x1ab4, 0x606f, 0x1940, 0x2001, 0x192b, + 0x2004, 0x607a, 0x783f, 0x3576, 0x00ce, 0x0005, 0x9086, 0x000d, + 0x11d0, 0x7808, 0xd09c, 0x01b8, 0x7820, 0x0026, 0x2010, 0x080c, + 0xd2b3, 0x0180, 0x2260, 0x6000, 0x9086, 0x0004, 0x1158, 0x0016, + 0x6120, 0x9186, 0x0009, 0x0108, 0x0020, 0x2009, 0x004c, 0x080c, + 0xb4d0, 0x001e, 0x002e, 0x0005, 0x0126, 0x2091, 0x2200, 0x7908, + 0x9184, 0x0030, 0x190c, 0x0d80, 0xd19c, 0x05b8, 0x7820, 0x908c, + 0xf000, 0x0550, 0x2060, 0x6020, 0x9086, 0x0003, 0x1560, 0x6000, + 0x9086, 0x0004, 0x1540, 0x6114, 0x2148, 0xa87a, 0xa87e, 0xa86b, + 0x0103, 0x080c, 0x7014, 0x00b6, 0x6010, 0x2058, 0xba3c, 0x82ff, + 0x0110, 0x8211, 0xba3e, 0xb8d0, 0x9005, 0x190c, 0x6a92, 0x00be, + 0x6044, 0xd0fc, 0x190c, 0xafcb, 0x1110, 0x080c, 0xb45c, 0x7808, + 0xd09c, 0x19a0, 0x012e, 0x0005, 0x908a, 0x0025, 0x1a0c, 0x0d87, + 0x0033, 0x012e, 0x0005, 0x0804, 0x1464, 0x012e, 0x0005, 0x1444, + 0x1484, 0x14b9, 0x14be, 0x14c6, 0x14cb, 0x14f3, 0x14f7, 0x1505, + 0x1509, 0x1444, 0x15dc, 0x15e0, 0x167d, 0x1684, 0x1444, 0x1685, + 0x1686, 0x1691, 0x1698, 0x1444, 0x1444, 0x1444, 0x1444, 0x1444, + 0x1444, 0x1444, 0x14cd, 0x1444, 0x148c, 0x14b6, 0x1473, 0x1444, + 0x149d, 0x1458, 0x1448, 0x14c2, 0x080c, 0x0d87, 0x080c, 0x0d80, + 0x080c, 0x16a3, 0x080c, 0x15c7, 0x7827, 0x0018, 0x7828, 0x782b, + 0x0000, 0x080c, 0x84a5, 0x080c, 0xf307, 0x080c, 0x1b99, 0x0005, + 0x080c, 0x16a3, 0x2009, 0x1a90, 0x2104, 0x8000, 0x200a, 0x080c, + 0x84a5, 0x080c, 0x1b99, 0x0005, 0x6020, 0x9086, 0x0003, 0x1148, + 0x6044, 0xd0fc, 0x190c, 0xafcb, 0x1120, 0x2009, 0x0055, 0x080c, + 0xb4d0, 0x012e, 0x0005, 0x080c, 0x16a3, 0x2060, 0x6020, 0x9086, + 0x0003, 0x1148, 0x6044, 0xd0fc, 0x190c, 0xafcb, 0x1120, 0x2009, + 0x0055, 0x080c, 0xb4d0, 0x0005, 0x2009, 0x0048, 0x080c, 0x16a3, + 0x2060, 0x080c, 0xb4d0, 0x0005, 0x2009, 0x0054, 0x080c, 0x16a3, + 0x2060, 0x6020, 0x9086, 0x0003, 0x1138, 0x6044, 0xd0fc, 0x190c, + 0xafcb, 0x1110, 0x080c, 0xb4d0, 0x0005, 0x080c, 0x16a3, 0x2060, + 0x0056, 0x0066, 0x080c, 0x16a3, 0x2028, 0x080c, 0x16a3, 0x2030, + 0x0036, 0x0046, 0x2021, 0x0000, 0x2418, 0x2009, 0x0056, 0x080c, + 0xb4d0, 0x004e, 0x003e, 0x006e, 0x005e, 0x0005, 0x080c, 0x16a3, + 0x0005, 0x7004, 0xc085, 0xc0b5, 0x7006, 0x0005, 0x7004, 0xc085, + 0x7006, 0x0005, 0x7004, 0xc0bd, 0x7006, 0x0005, 0x080c, 0x16a3, + 0x080c, 0x17b0, 0x0005, 0x080c, 0x0d87, 0x080c, 0x16a3, 0x2060, + 0x6014, 0x0096, 0x2048, 0xa83b, 0xffff, 0x009e, 0x2009, 0x0048, + 0x080c, 0xb4d0, 0x2001, 0x015d, 0x2003, 0x0000, 0x2009, 0x03e8, 0x8109, 0x0160, 0x2001, 0x0201, 0x2004, 0x9005, 0x0dc8, 0x2001, - 0x0218, 0x2004, 0xd0ec, 0x1110, 0x0419, 0x0040, 0x2001, 0x020d, - 0x2003, 0x0020, 0x080c, 0x1328, 0x7803, 0x0001, 0x00ee, 0x001e, - 0x0005, 0x080c, 0x1654, 0x0dd0, 0x2001, 0x020d, 0x2003, 0x0050, - 0x2003, 0x0020, 0x0069, 0x0c90, 0x0031, 0x2060, 0x2009, 0x0053, - 0x080c, 0xa117, 0x0005, 0x7808, 0xd09c, 0x0de8, 0x7820, 0x0005, - 0x080c, 0x14eb, 0x00d6, 0x2069, 0x0200, 0x2009, 0x01f4, 0x8109, - 0x0510, 0x6804, 0x9005, 0x0dd8, 0x2001, 0x015d, 0x2003, 0x0000, - 0x79bc, 0xd1a4, 0x1528, 0x79b8, 0x918c, 0x0fff, 0x0180, 0x9182, + 0x0218, 0x2004, 0xd0ec, 0x1110, 0x080c, 0x16a8, 0x2001, 0x0307, + 0x2003, 0x8000, 0x0005, 0x7004, 0xc095, 0x7006, 0x0005, 0x080c, + 0x16a3, 0x2060, 0x6014, 0x0096, 0x2048, 0xa83b, 0xffff, 0x009e, + 0x2009, 0x0048, 0x080c, 0xb4d0, 0x0005, 0x080c, 0x16a3, 0x080c, + 0x0d87, 0x080c, 0x16a3, 0x080c, 0x15c7, 0x7827, 0x0018, 0x79ac, + 0xd1dc, 0x0904, 0x1572, 0x7827, 0x0015, 0x7828, 0x782b, 0x0000, + 0x9065, 0x0140, 0x2001, 0x020d, 0x2003, 0x0050, 0x2003, 0x0020, + 0x0804, 0x1578, 0x7004, 0x9005, 0x01c8, 0x1188, 0x78ab, 0x0004, + 0x7827, 0x0018, 0x782b, 0x0000, 0xd1bc, 0x090c, 0x0d87, 0x2001, + 0x020d, 0x2003, 0x0050, 0x2003, 0x0020, 0x0804, 0x15ac, 0x78ab, + 0x0004, 0x7803, 0x0001, 0x080c, 0x15e0, 0x0005, 0x7827, 0x0018, + 0xa001, 0x7828, 0x7827, 0x0011, 0xa001, 0x7928, 0x9106, 0x0110, + 0x79ac, 0x08e0, 0x00e6, 0x2071, 0x0200, 0x702c, 0xd0c4, 0x0140, + 0x00ee, 0x080c, 0x1b99, 0x080c, 0x136c, 0x7803, 0x0001, 0x0005, + 0x7037, 0x0001, 0xa001, 0x7150, 0x00ee, 0x918c, 0xff00, 0x9186, + 0x0500, 0x0110, 0x79ac, 0x0810, 0x7004, 0xc09d, 0x7006, 0x78ab, + 0x0004, 0x7803, 0x0001, 0x080c, 0x15e0, 0x2001, 0x020d, 0x2003, + 0x0020, 0x0005, 0x7828, 0x782b, 0x0000, 0x9065, 0x090c, 0x0d87, + 0x6014, 0x2048, 0x78ab, 0x0004, 0x918c, 0x0700, 0x01d8, 0x080c, + 0x84a5, 0x080c, 0x1b99, 0x080c, 0xd2c5, 0x0158, 0xa9b0, 0xa936, + 0xa9b4, 0xa93a, 0xa83f, 0xffff, 0xa843, 0xffff, 0xa884, 0xc0bd, + 0xa886, 0xa984, 0x9184, 0x0020, 0x1120, 0xc1ad, 0xa986, 0x080c, + 0xce7e, 0x0005, 0x6020, 0x9086, 0x0009, 0x1128, 0x2009, 0x004c, + 0x080c, 0xb4d0, 0x0048, 0x6010, 0x00b6, 0x2058, 0xb800, 0x00be, + 0xd0bc, 0x6024, 0x190c, 0xd6bf, 0x2029, 0x00c8, 0x8529, 0x0128, + 0x2001, 0x0201, 0x2004, 0x9005, 0x0dc8, 0x7dbc, 0x080c, 0xf2c5, + 0xd5a4, 0x1118, 0x080c, 0x16a8, 0x0005, 0x080c, 0x84a5, 0x080c, + 0x1b99, 0x0005, 0x781f, 0x0300, 0x7803, 0x0001, 0x0005, 0x0016, + 0x0066, 0x0076, 0x00f6, 0x2079, 0x0300, 0x7908, 0x918c, 0x0007, + 0x9186, 0x0003, 0x0120, 0x2001, 0x0016, 0x080c, 0x1729, 0x00fe, + 0x007e, 0x006e, 0x001e, 0x0005, 0x7004, 0xc09d, 0x7006, 0x0005, + 0x7104, 0x9184, 0x0004, 0x190c, 0x0d87, 0xd184, 0x190c, 0x1642, + 0xd1bc, 0x11b1, 0xd19c, 0x0180, 0xc19c, 0x7106, 0x0016, 0x080c, + 0x1793, 0x001e, 0x0148, 0x2001, 0x020d, 0x2003, 0x0050, 0x2003, + 0x0020, 0x080c, 0x16a8, 0x0005, 0x81ff, 0x190c, 0x0d87, 0x0005, + 0xc1bc, 0x7106, 0x0016, 0x00e6, 0x2071, 0x0200, 0x080c, 0x1780, + 0x6014, 0x9005, 0x0558, 0x0096, 0x2048, 0xa868, 0x009e, 0x9084, + 0x00ff, 0x908e, 0x0029, 0x190c, 0x0d87, 0x00f6, 0x2c78, 0x080c, + 0x19bb, 0x00fe, 0x2009, 0x01f4, 0x8109, 0x0168, 0x2001, 0x0201, + 0x2004, 0x9005, 0x0dc8, 0x2001, 0x0218, 0x2004, 0xd0ec, 0x1118, + 0x080c, 0x16a8, 0x0040, 0x2001, 0x020d, 0x2003, 0x0020, 0x2001, + 0x0307, 0x2003, 0x0300, 0x00ee, 0x001e, 0x0005, 0x080c, 0x1793, + 0x0dd0, 0x2001, 0x020d, 0x2003, 0x0050, 0x2003, 0x0020, 0x080c, + 0x16a8, 0x0c88, 0x2100, 0xc184, 0xc1b4, 0x7106, 0xd0b4, 0x0016, + 0x00e6, 0x1540, 0x2071, 0x0200, 0x080c, 0x1780, 0x0518, 0x080c, + 0x1793, 0x01e8, 0x6014, 0x9005, 0x01e8, 0x0096, 0x2048, 0xa868, + 0x009e, 0x9084, 0x00ff, 0x908e, 0x0048, 0x11a0, 0x601c, 0xd084, + 0x1130, 0x00f6, 0x2c78, 0x080c, 0x1826, 0x00fe, 0x0000, 0x2001, + 0x020d, 0x2003, 0x0020, 0x080c, 0x136c, 0x7803, 0x0001, 0x00ee, + 0x001e, 0x0005, 0x080c, 0x1793, 0x0dd0, 0x2001, 0x020d, 0x2003, + 0x0050, 0x2003, 0x0020, 0x0461, 0x0c90, 0x0429, 0x2060, 0x2009, + 0x0053, 0x080c, 0xb4d0, 0x0005, 0x0005, 0x0005, 0x00e1, 0x2008, + 0x00d1, 0x0006, 0x7004, 0xc09d, 0x7006, 0x000e, 0x080c, 0x9555, + 0x0005, 0x0089, 0x9005, 0x0118, 0x080c, 0x9171, 0x0cd0, 0x0005, + 0x2001, 0x0036, 0x2009, 0x1820, 0x210c, 0x2011, 0x181f, 0x2214, + 0x080c, 0x1729, 0x0005, 0x7808, 0xd09c, 0x0de8, 0x7820, 0x0005, + 0x080c, 0x15c7, 0x00d6, 0x2069, 0x0200, 0x2009, 0x01f4, 0x8109, + 0x0520, 0x6804, 0x9005, 0x0dd8, 0x2001, 0x015d, 0x2003, 0x0000, + 0x79bc, 0xd1a4, 0x1578, 0x79b8, 0x918c, 0x0fff, 0x0180, 0x9182, 0x0841, 0x1268, 0x9188, 0x0007, 0x918c, 0x0ff8, 0x810c, 0x810c, - 0x810c, 0x080c, 0x15e3, 0x6827, 0x0001, 0x8109, 0x1dd0, 0x04d9, - 0x6827, 0x0002, 0x04c1, 0x6804, 0x9005, 0x1130, 0x682c, 0xd0e4, - 0x1500, 0x6804, 0x9005, 0x0de8, 0x79b8, 0xd1ec, 0x1130, 0x08c0, - 0x080c, 0x7dda, 0x080c, 0x19fe, 0x0090, 0x7827, 0x0015, 0x782b, - 0x0000, 0x7827, 0x0018, 0x782b, 0x0000, 0x2001, 0x020d, 0x2003, - 0x0020, 0x2001, 0x0307, 0x2003, 0x0300, 0x7803, 0x0001, 0x00de, - 0x0005, 0x682c, 0x9084, 0x5400, 0x9086, 0x5400, 0x0d30, 0x7827, - 0x0015, 0x782b, 0x0000, 0x7803, 0x0001, 0x6800, 0x9085, 0x1800, - 0x6802, 0x00de, 0x0005, 0x6824, 0x9084, 0x0003, 0x1de0, 0x0005, + 0x810c, 0x080c, 0x1715, 0x6827, 0x0001, 0x8109, 0x1dd0, 0x080c, + 0x1715, 0x6827, 0x0002, 0x080c, 0x1715, 0x6804, 0x9005, 0x1170, + 0x682c, 0xd0e4, 0x1540, 0x691c, 0x9184, 0x0014, 0x0120, 0x6830, + 0x9084, 0x9554, 0x15b9, 0x6804, 0x9005, 0x0da8, 0x79b8, 0xd1ec, + 0x1130, 0x0870, 0x080c, 0x84a5, 0x080c, 0x1b99, 0x0090, 0x7827, + 0x0015, 0x782b, 0x0000, 0x7827, 0x0018, 0x782b, 0x0000, 0x2001, + 0x020d, 0x2003, 0x0020, 0x2001, 0x0307, 0x2003, 0x0300, 0x7803, + 0x0001, 0x00de, 0x0005, 0x682c, 0x9084, 0x5400, 0x9086, 0x5400, + 0x0d30, 0x7827, 0x0015, 0x782b, 0x0000, 0x7803, 0x0001, 0x6800, + 0x9085, 0x1800, 0x6802, 0x00de, 0x0005, 0x6824, 0x9084, 0x0003, + 0x1de0, 0x0005, 0x2079, 0x0001, 0x000e, 0x00f6, 0x0804, 0x0d89, 0x2001, 0x0030, 0x2c08, 0x621c, 0x0021, 0x7830, 0x9086, 0x0041, - 0x0005, 0x00f6, 0x00e6, 0x2079, 0x0300, 0x0006, 0x2071, 0x1a47, + 0x0005, 0x00f6, 0x00e6, 0x2079, 0x0300, 0x0006, 0x2071, 0x1a81, 0x7008, 0x9005, 0x1110, 0x78e3, 0x0c0c, 0x8000, 0x700a, 0x0026, 0x2011, 0x0006, 0x7808, 0xd09c, 0x0150, 0x0016, 0x0026, 0x00c6, - 0x080c, 0x136e, 0x00ce, 0x002e, 0x001e, 0x8211, 0x1d98, 0x002e, + 0x080c, 0x13dc, 0x00ce, 0x002e, 0x001e, 0x8211, 0x1d98, 0x002e, 0x000e, 0x0006, 0x7832, 0x7936, 0x7a3a, 0x781b, 0x8080, 0x00b9, - 0x1178, 0x2071, 0x1a47, 0x7008, 0x9005, 0x0130, 0x8001, 0x0a0c, - 0x0d81, 0x700a, 0x78e3, 0x0c00, 0x000e, 0x00ee, 0x00fe, 0x0005, - 0x000e, 0x792c, 0x3900, 0x8000, 0x2004, 0x080c, 0x0d81, 0x2009, + 0x1178, 0x2071, 0x1a81, 0x7008, 0x9005, 0x0130, 0x8001, 0x0a0c, + 0x0d87, 0x700a, 0x78e3, 0x0c00, 0x000e, 0x00ee, 0x00fe, 0x0005, + 0x000e, 0x792c, 0x3900, 0x8000, 0x2004, 0x080c, 0x0d87, 0x2009, 0xff00, 0x8109, 0x0120, 0x7818, 0xd0bc, 0x1dd8, 0x0005, 0x9085, 0x0001, 0x0005, 0x7832, 0x7936, 0x7a3a, 0x781b, 0x8080, 0x0c79, - 0x1108, 0x0005, 0x792c, 0x3900, 0x8000, 0x2004, 0x080c, 0x0d81, + 0x1108, 0x0005, 0x792c, 0x3900, 0x8000, 0x2004, 0x080c, 0x0d87, 0x7037, 0x0001, 0x7150, 0x7037, 0x0002, 0x7050, 0x2060, 0xd1bc, - 0x1110, 0x7054, 0x2060, 0x0005, 0x0006, 0x0046, 0x00e6, 0x2071, - 0x0200, 0x7037, 0x0002, 0x7058, 0x9084, 0xff00, 0x8007, 0x9086, - 0x00bc, 0x1158, 0x2021, 0x1a56, 0x2404, 0x8000, 0x0208, 0x2022, - 0x080c, 0x7dda, 0x080c, 0x19fe, 0x9006, 0x00ee, 0x004e, 0x000e, - 0x0005, 0x0c11, 0x1108, 0x0005, 0x00e6, 0x0016, 0x2071, 0x0200, - 0x0879, 0x6124, 0xd1dc, 0x01f8, 0x701c, 0xd08c, 0x0904, 0x16d3, - 0x7017, 0x0000, 0x2001, 0x0264, 0x2004, 0xd0bc, 0x0904, 0x16d3, + 0x1110, 0x7054, 0x2060, 0x918c, 0xff00, 0x9186, 0x0500, 0x0110, + 0x9085, 0x0001, 0x0005, 0x0006, 0x0046, 0x00e6, 0x2071, 0x0200, + 0x7037, 0x0002, 0x7058, 0x9084, 0xff00, 0x8007, 0x9086, 0x00bc, + 0x1158, 0x2021, 0x1a91, 0x2404, 0x8000, 0x0208, 0x2022, 0x080c, + 0x84a5, 0x080c, 0x1b99, 0x9006, 0x00ee, 0x004e, 0x000e, 0x0005, + 0x0c11, 0x1108, 0x0005, 0x00e6, 0x0016, 0x2071, 0x0200, 0x0841, + 0x6120, 0x9186, 0x0000, 0x0904, 0x181b, 0x9186, 0x0002, 0x0904, + 0x181b, 0x6124, 0xd1dc, 0x01f8, 0x701c, 0xd08c, 0x0904, 0x181b, + 0x7017, 0x0000, 0x2001, 0x0264, 0x2004, 0xd0bc, 0x0904, 0x181b, 0x2001, 0x0268, 0x00c6, 0x2064, 0x6104, 0x6038, 0x00ce, 0x918e, - 0x0039, 0x1904, 0x16d3, 0x9c06, 0x15f0, 0x0126, 0x2091, 0x2600, - 0x080c, 0x7d32, 0x012e, 0x7358, 0x745c, 0x6014, 0x905d, 0x0598, + 0x0039, 0x1904, 0x181b, 0x9c06, 0x15f0, 0x0126, 0x2091, 0x2600, + 0x080c, 0x83fd, 0x012e, 0x7358, 0x745c, 0x6014, 0x905d, 0x0598, 0x2b48, 0x6010, 0x00b6, 0x2058, 0xb800, 0x00be, 0xd0bc, 0x190c, - 0xc195, 0xab42, 0xac3e, 0x2001, 0x187d, 0x2004, 0xd0b4, 0x1170, + 0xd69a, 0xab42, 0xac3e, 0x2001, 0x186c, 0x2004, 0xd0b4, 0x1170, 0x601c, 0xd0e4, 0x1158, 0x6010, 0x00b6, 0x2058, 0xb800, 0x00be, - 0xd0bc, 0x1120, 0xa83b, 0x7fff, 0xa837, 0xffff, 0x080c, 0x1db9, - 0x1190, 0x080c, 0x187f, 0x2a00, 0xa816, 0x0130, 0x2800, 0xa80e, + 0xd0bc, 0x1120, 0xa83b, 0x7fff, 0xa837, 0xffff, 0x080c, 0x1f5c, + 0x1190, 0x080c, 0x1a18, 0x2a00, 0xa816, 0x0130, 0x2800, 0xa80e, 0x2c05, 0xa80a, 0x2c00, 0xa812, 0x7037, 0x0020, 0x781f, 0x0300, 0x001e, 0x00ee, 0x0005, 0x7037, 0x0050, 0x7037, 0x0020, 0x001e, - 0x00ee, 0x080c, 0x1580, 0x0005, 0x080c, 0x0d81, 0x2001, 0x180d, - 0x2004, 0xd08c, 0x190c, 0x693b, 0x2cf0, 0x0126, 0x2091, 0x2200, + 0x00ee, 0x080c, 0x16a8, 0x0005, 0x080c, 0x0d87, 0x2001, 0x180d, + 0x2004, 0xd08c, 0x190c, 0x6eb9, 0x2cf0, 0x0126, 0x2091, 0x2200, 0x0016, 0x00c6, 0x3e60, 0x6014, 0x2048, 0x2940, 0x903e, 0x2730, - 0xa864, 0x2068, 0xa81a, 0x9d84, 0x000f, 0x9088, 0x1d99, 0x2165, - 0x0002, 0x1710, 0x175d, 0x1710, 0x1710, 0x1710, 0x173f, 0x1710, - 0x1714, 0x1709, 0x1754, 0x1710, 0x1710, 0x1710, 0x181a, 0x1728, - 0x171e, 0xa964, 0x918c, 0x00ff, 0x918e, 0x0048, 0x0904, 0x1754, - 0x9085, 0x0001, 0x0804, 0x1810, 0xa87c, 0xd0bc, 0x0dc8, 0xa890, - 0xa842, 0xa88c, 0xa83e, 0xa888, 0x0804, 0x1764, 0xa87c, 0xd0bc, - 0x0d78, 0xa890, 0xa842, 0xa88c, 0xa83e, 0xa888, 0x0804, 0x17b3, - 0xa87c, 0xd0bc, 0x0d28, 0xa890, 0xa842, 0xa88c, 0xa83e, 0xa804, - 0x9045, 0x090c, 0x0d81, 0xa164, 0xa91a, 0x91ec, 0x000f, 0x9d80, - 0x1d99, 0x2065, 0xa888, 0xd19c, 0x1904, 0x17b3, 0x0428, 0xa87c, - 0xd0ac, 0x0970, 0xa804, 0x9045, 0x090c, 0x0d81, 0xa164, 0xa91a, - 0x91ec, 0x000f, 0x9d80, 0x1d99, 0x2065, 0x9006, 0xa842, 0xa83e, - 0xd19c, 0x1904, 0x17b3, 0x0080, 0xa87c, 0xd0ac, 0x0904, 0x1710, - 0x9006, 0xa842, 0xa83e, 0x0804, 0x17b3, 0xa87c, 0xd0ac, 0x0904, - 0x1710, 0x9006, 0xa842, 0xa83e, 0x2c05, 0x908a, 0x0036, 0x1a0c, - 0x0d81, 0x9082, 0x001b, 0x0002, 0x1787, 0x1787, 0x1789, 0x1787, - 0x1787, 0x1787, 0x178f, 0x1787, 0x1787, 0x1787, 0x1795, 0x1787, - 0x1787, 0x1787, 0x179b, 0x1787, 0x1787, 0x1787, 0x17a1, 0x1787, - 0x1787, 0x1787, 0x17a7, 0x1787, 0x1787, 0x1787, 0x17ad, 0x080c, - 0x0d81, 0xa574, 0xa478, 0xa37c, 0xa280, 0x0804, 0x17f8, 0xa584, - 0xa488, 0xa38c, 0xa290, 0x0804, 0x17f8, 0xa594, 0xa498, 0xa39c, - 0xa2a0, 0x0804, 0x17f8, 0xa5a4, 0xa4a8, 0xa3ac, 0xa2b0, 0x0804, - 0x17f8, 0xa5b4, 0xa4b8, 0xa3bc, 0xa2c0, 0x0804, 0x17f8, 0xa5c4, - 0xa4c8, 0xa3cc, 0xa2d0, 0x0804, 0x17f8, 0xa5d4, 0xa4d8, 0xa3dc, - 0xa2e0, 0x0804, 0x17f8, 0x2c05, 0x908a, 0x0034, 0x1a0c, 0x0d81, - 0x9082, 0x001b, 0x0002, 0x17d6, 0x17d4, 0x17d4, 0x17d4, 0x17d4, - 0x17d4, 0x17dd, 0x17d4, 0x17d4, 0x17d4, 0x17d4, 0x17d4, 0x17e4, - 0x17d4, 0x17d4, 0x17d4, 0x17d4, 0x17d4, 0x17eb, 0x17d4, 0x17d4, - 0x17d4, 0x17d4, 0x17d4, 0x17f2, 0x080c, 0x0d81, 0xa56c, 0xa470, - 0xa774, 0xa678, 0xa37c, 0xa280, 0x00d8, 0xa584, 0xa488, 0xa78c, - 0xa690, 0xa394, 0xa298, 0x00a0, 0xa59c, 0xa4a0, 0xa7a4, 0xa6a8, - 0xa3ac, 0xa2b0, 0x0068, 0xa5b4, 0xa4b8, 0xa7bc, 0xa6c0, 0xa3c4, - 0xa2c8, 0x0030, 0xa5cc, 0xa4d0, 0xa7d4, 0xa6d8, 0xa3dc, 0xa2e0, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 23:17:29 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7B0161065674; Wed, 5 Jan 2011 23:17:29 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4F64C8FC15; Wed, 5 Jan 2011 23:17:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05NHTT7094330; Wed, 5 Jan 2011 23:17:29 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05NHTL1094327; Wed, 5 Jan 2011 23:17:29 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201101052317.p05NHTL1094327@svn.freebsd.org> From: Jilles Tjoelker Date: Wed, 5 Jan 2011 23:17:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217035 - in head: bin/sh tools/regression/bin/sh/builtins X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 23:17:29 -0000 Author: jilles Date: Wed Jan 5 23:17:29 2011 New Revision: 217035 URL: http://svn.freebsd.org/changeset/base/217035 Log: sh: Do not call exitshell() from evalcommand() unless evalcommand() forked itself. This ensures that certain traps caused by builtins are executed. Added: head/tools/regression/bin/sh/builtins/trap4.0 (contents, props changed) Modified: head/bin/sh/eval.c Modified: head/bin/sh/eval.c ============================================================================== --- head/bin/sh/eval.c Wed Jan 5 23:15:22 2011 (r217034) +++ head/bin/sh/eval.c Wed Jan 5 23:17:29 2011 (r217035) @@ -671,6 +671,7 @@ safe_builtin(int idx, int argc, char **a /* * Execute a simple command. + * Note: This may or may not return if (flags & EV_EXIT). */ static void @@ -707,6 +708,7 @@ evalcommand(union node *cmd, int flags, arglist.lastp = &arglist.list; varlist.lastp = &varlist.list; varflag = 1; + jp = NULL; do_clearcmdentry = 0; oexitstatus = exitstatus; exitstatus = 0; @@ -965,7 +967,7 @@ evalcommand(union node *cmd, int flags, evalskip = 0; skipcount = 0; } - if (flags & EV_EXIT) + if (jp) exitshell(exitstatus); } else if (cmdentry.cmdtype == CMDBUILTIN) { #ifdef DEBUG @@ -1013,13 +1015,12 @@ cmddone: out1 = &output; out2 = &errout; freestdout(); + handler = savehandler; if (e != EXSHELLPROC) { commandname = savecmdname; - if (flags & EV_EXIT) { + if (jp) exitshell(exitstatus); - } } - handler = savehandler; if (flags == EV_BACKCMD) { backcmd->buf = memout.buf; backcmd->nleft = memout.nextc - memout.buf; Added: head/tools/regression/bin/sh/builtins/trap4.0 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/regression/bin/sh/builtins/trap4.0 Wed Jan 5 23:17:29 2011 (r217035) @@ -0,0 +1,17 @@ +# $FreeBSD$ + +T=$(mktemp -d ${TMPDIR:-/tmp}/sh-test.XXXXXX) +trap 'rm -rf $T' 0 +cd $T || exit 3 +mkfifo fifo1 + +v=$( + exec 3>&1 + : &3 2>/dev/null' PIPE + echo x 2>/dev/null + } >fifo1 +) +test "$v" = trapped From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 23:27:21 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 22FF51065670; Wed, 5 Jan 2011 23:27:21 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id 6F2D68FC0C; Wed, 5 Jan 2011 23:27:20 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id p05NRJAG098966; Thu, 6 Jan 2011 00:27:19 +0100 (CET) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id p05NRJ5Z098965; Thu, 6 Jan 2011 00:27:19 +0100 (CET) (envelope-from marius) Date: Thu, 6 Jan 2011 00:27:18 +0100 From: Marius Strobl To: "Bjoern A. Zeeb" Message-ID: <20110105232718.GB97101@alchemy.franken.de> References: <201101051528.p05FSVPL082696@svn.freebsd.org> <20110105153107.X14966@maildrop.int.zabbadoz.net> <20110105155513.GA97101@alchemy.franken.de> <20110105185451.W14966@maildrop.int.zabbadoz.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110105185451.W14966@maildrop.int.zabbadoz.net> User-Agent: Mutt/1.4.2.3i Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r217013 - in head: sbin/ifconfig sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 23:27:21 -0000 On Wed, Jan 05, 2011 at 07:09:10PM +0000, Bjoern A. Zeeb wrote: > On Wed, 5 Jan 2011, Marius Strobl wrote: > > >On Wed, Jan 05, 2011 at 03:34:30PM +0000, Bjoern A. Zeeb wrote: > >>On Wed, 5 Jan 2011, Marius Strobl wrote: > >> > >>>Author: marius > >>>Date: Wed Jan 5 15:28:30 2011 > >>>New Revision: 217013 > >>>URL: http://svn.freebsd.org/changeset/base/217013 > >>> > >>>Log: > >>>Teach ifconfig(8) the handy shared option shortcut aliases the NetBSD > >>>counterpart also takes, i.e. "fdx" for "full-duplex", "flow" for > >>>"flowcontrol", "hdx" for "half-duplex" as well as "loop" and "loopback" > >>>for "hw-loopback". > >> > >>I am not sure this is a good idea. Unless this is really really > >>useful for compatibility with scripts (which I doubt) it'll sooner or > >>later cause headaches, especially given some of the (new) names could > >>be very well used for different things as well. > > > >Could you please elaborate on what different use you have in mind? > >Generally it seems a bad idea to me if the existing options and the > >new names as implemented would trigger different things as you suggest > >given the latter are rather common abbreviations as well as diverging > >from the user interface of the other BSDs seems like a bad idea (i.e. > >not only not supporting the same names they do but also controlling > >different things with a given one). Also the concept of aliases taken > >by ifconfig(8) isn't new, we support several including f.e. "auto" for > >"autoselect" for quite some time. > > "flow" is a term used at other layers as well and really different to > flow control. We are not only seeing discussions about flowid usage > in IPv6 but also people trying to control "ULP flows" on NICs (RSS). > > loop and loopback sound bad as well, especially as I could only see > one man page in man4 (tl.4) that actually references it. If you grep for IFM_LOOP in sys/dev you'll see that several MAC and PHY drivers support it an that the man pages of MAC drivers that use mii(4) like f.e. tl(4) does are actually the wrong place to document this given that the media is primarily handled by the PHY drivers in that case (hence no match in sys/dev/tl). > > My worries are just that people will confuse those things with other > options outside of media-opts. IMO that risk is rather low as long as the verb is tied to an option like f.e. "mode" or in this case "mediaopt". > > I guess I have no problem with fdx and hdx but you will see a mix > other either showing up then in scripts and man pages and that'll give > an incosistent view to users and confuse them as well (especially > since those options are all descriped with the driver's man pages > rather than having a global list [if needed with aliases] in ifconfig > then refering to the driver man pages to see which of those a driver > actually supports). Yes, actually we are very bad at documenting the media and media options; several of the man pages of MAC drivers using mii(4) are outdated and as outlined above technically it makes no sense to document these there. Even if we had man pages for the PHY drivers it would be next to impossible to document the media and media options there correctly as PHY drivers generally determine these dynamically an there are f.e. low-cost variants of MACs supported by bge(4) but limited to Fast Ethernet equipped with Gigabit PHYs. So what I would prefer instead would be one central place similar to the NetBSD and OpenBSD ifmedia.4 describing the media and media options and how to set them with ifconfig(8) and in the man pages of the MAC drivers then just reference ifmedia.4 and tell them to check the output of `ifconfig -m foo0` to check what a given interface actually supports. > > To give you an example -- "add" is an alias for "alias" with inet, and > people are writing alias where add should be (different places on the > command line) which leads to confusion as it shouldn't work there and > doesn't for IPv6. Much confusion for years. > Well, without a command line example this is a bit hard to follow but it sounds like the real problem here is the inconsistency between the IPv6 and non-IPv6 cases and maybe that in one place ifconfig(8) shouldn't accept "alias" even in the non-IPv6 case. Generally one can take the argument about inconsistency leading to user confusion into different directions. F.e. users also have complained loudly about the fact the FreeBSD requires (or required?) a netmask of 0xffffffff for IPv4-aliases while the other BSDs and Linux as well as apparently every other system one can configure an alias address on uses the same netmask for the alias as for the primary address (which also is sheer intuitive). Yet, another inconsistency is that in dmesg mii(4) announces the autoselect media as "auto" and the media options {full,half}-duplex as {F,H}DX (and recently also flow-control as "flow") which don't translate to (non-alias) verbs understood by ifconfig(8). IMO r217013 thus actually reduces existing inconsistencies and thus potentially user confusions between OSes and within FreeBSD itself while you arguing with possible future inconsistency if we make the mistake to name new ifconfig(8) options for different things the same as others have already chosen for existing functionality before. Marius From owner-svn-src-head@FreeBSD.ORG Wed Jan 5 23:45:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6E792106564A; Wed, 5 Jan 2011 23:45:08 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 5D0178FC15; Wed, 5 Jan 2011 23:45:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05Nj824094944; Wed, 5 Jan 2011 23:45:08 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05Nj855094938; Wed, 5 Jan 2011 23:45:08 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101052345.p05Nj855094938@svn.freebsd.org> From: Warner Losh Date: Wed, 5 Jan 2011 23:45:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217036 - head/sys/arm/at91 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 23:45:08 -0000 Author: imp Date: Wed Jan 5 23:45:07 2011 New Revision: 217036 URL: http://svn.freebsd.org/changeset/base/217036 Log: Remove support for SKYEYE simulator Modified: head/sys/arm/at91/at91_st.c head/sys/arm/at91/at91rm9200.c head/sys/arm/at91/uart_bus_at91usart.c head/sys/arm/at91/uart_cpu_at91rm9200usart.c head/sys/arm/at91/uart_dev_at91usart.c Modified: head/sys/arm/at91/at91_st.c ============================================================================== --- head/sys/arm/at91/at91_st.c Wed Jan 5 23:17:29 2011 (r217035) +++ head/sys/arm/at91/at91_st.c Wed Jan 5 23:45:07 2011 (r217036) @@ -77,11 +77,7 @@ static unsigned at91st_get_timecount(str static struct timecounter at91st_timecounter = { at91st_get_timecount, /* get_timecount */ NULL, /* no poll_pps */ -#ifdef SKYEYE_WORKAROUNDS - 0xffffffffu, /* counter_mask */ -#else 0xfffffu, /* counter_mask */ -#endif 32768, /* frequency */ "AT91RM9200 timer", /* name */ 1000 /* quality */ @@ -138,18 +134,10 @@ static devclass_t at91st_devclass; DRIVER_MODULE(at91_st, atmelarm, at91st_driver, at91st_devclass, 0, 0); -#ifdef SKYEYE_WORKAROUNDS -static unsigned long tot_count = 0; -#endif - static unsigned at91st_get_timecount(struct timecounter *tc) { -#ifdef SKYEYE_WORKAROUNDS - return (tot_count); -#else return (st_crtr()); -#endif } /* @@ -189,9 +177,6 @@ clock_intr(void *arg) /* The interrupt is shared, so we have to make sure it's for us. */ if (RD4(ST_SR) & ST_SR_PITS) { -#ifdef SKYEYE_WORKAROUNDS - tot_count += 32768 / hz; -#endif hardclock(TRAPF_USERMODE(fp), TRAPF_PC(fp)); return (FILTER_HANDLED); } Modified: head/sys/arm/at91/at91rm9200.c ============================================================================== --- head/sys/arm/at91/at91rm9200.c Wed Jan 5 23:17:29 2011 (r217035) +++ head/sys/arm/at91/at91rm9200.c Wed Jan 5 23:45:07 2011 (r217036) @@ -121,15 +121,11 @@ static const struct cpu_devs at91_devs[] DEVICE("at91_ssc", SSC2, 2), DEVICE("spi", SPI, 0), -#ifndef SKYEYE_WORKAROUNDS DEVICE("uart", DBGU, 0), DEVICE("uart", USART0, 1), DEVICE("uart", USART1, 2), DEVICE("uart", USART2, 3), DEVICE("uart", USART3, 4), -#else - DEVICE("uart", USART0, 0), -#endif DEVICE("at91_aic", AIC, 0), DEVICE("at91_mc", MC, 0), DEVICE("at91_tc", TC0, 0), Modified: head/sys/arm/at91/uart_bus_at91usart.c ============================================================================== --- head/sys/arm/at91/uart_bus_at91usart.c Wed Jan 5 23:17:29 2011 (r217035) +++ head/sys/arm/at91/uart_bus_at91usart.c Wed Jan 5 23:45:07 2011 (r217036) @@ -76,11 +76,7 @@ usart_at91rm92_probe(device_t dev) switch (device_get_unit(dev)) { case 0: -#ifdef SKYEYE_WORKAROUNDS - device_set_desc(dev, "USART0"); -#else device_set_desc(dev, "DBGU"); -#endif /* * Setting sc_sysdev makes this device a 'system device' and * indirectly makes it the system console. Modified: head/sys/arm/at91/uart_cpu_at91rm9200usart.c ============================================================================== --- head/sys/arm/at91/uart_cpu_at91rm9200usart.c Wed Jan 5 23:17:29 2011 (r217035) +++ head/sys/arm/at91/uart_cpu_at91rm9200usart.c Wed Jan 5 23:45:07 2011 (r217036) @@ -73,13 +73,8 @@ uart_cpu_getdev(int devtype, struct uart * XXX: Not pretty, but will work because we map the needed addresses * early. */ -#ifdef SKYEYE_WORKAROUNDS - di->bas.bsh = AT91RM92_BASE + AT91RM92_USART0_BASE; - di->baudrate = 38400; -#else di->bas.bsh = AT91RM92_BASE + AT91RM92_DBGU_BASE; di->baudrate = 115200; -#endif di->bas.regshft = 0; di->bas.rclk = 0; di->databits = 8; Modified: head/sys/arm/at91/uart_dev_at91usart.c ============================================================================== --- head/sys/arm/at91/uart_dev_at91usart.c Wed Jan 5 23:17:29 2011 (r217035) +++ head/sys/arm/at91/uart_dev_at91usart.c Wed Jan 5 23:45:07 2011 (r217036) @@ -315,7 +315,6 @@ at91_usart_bus_probe(struct uart_softc * return (0); } -#ifndef SKYEYE_WORKAROUNDS static void at91_getaddr(void *arg, bus_dma_segment_t *segs, int nsegs, int error) { @@ -323,15 +322,12 @@ at91_getaddr(void *arg, bus_dma_segment_ return; *(bus_addr_t *)arg = segs[0].ds_addr; } -#endif static int at91_usart_bus_attach(struct uart_softc *sc) { -#ifndef SKYEYE_WORKAROUNDS int err; int i; -#endif uint32_t cr; struct at91_usart_softc *atsc; @@ -349,7 +345,6 @@ at91_usart_bus_attach(struct uart_softc atsc->flags |= HAS_TIMEOUT; WR4(&sc->sc_bas, USART_IDR, 0xffffffff); -#ifndef SKYEYE_WORKAROUNDS /* * Allocate DMA tags and maps */ @@ -380,7 +375,6 @@ at91_usart_bus_attach(struct uart_softc atsc->ping = &atsc->ping_pong[0]; atsc->pong = &atsc->ping_pong[1]; } -#endif /* * Prime the pump with the RX buffer. We use two 64 byte bounce @@ -414,34 +408,25 @@ at91_usart_bus_attach(struct uart_softc WR4(&sc->sc_bas, USART_IER, USART_CSR_RXRDY); } WR4(&sc->sc_bas, USART_IER, USART_CSR_RXBRK); -#ifndef SKYEYE_WORKAROUNDS errout:; // XXX bad return (err); -#else - return (0); -#endif } static int at91_usart_bus_transmit(struct uart_softc *sc) { -#ifndef SKYEYE_WORKAROUNDS bus_addr_t addr; -#endif struct at91_usart_softc *atsc; atsc = (struct at91_usart_softc *)sc; -#ifndef SKYEYE_WORKAROUNDS if (bus_dmamap_load(atsc->dmatag, atsc->tx_map, sc->sc_txbuf, sc->sc_txdatasz, at91_getaddr, &addr, 0) != 0) return (EAGAIN); bus_dmamap_sync(atsc->dmatag, atsc->tx_map, BUS_DMASYNC_PREWRITE); -#endif uart_lock(sc->sc_hwmtx); sc->sc_txbusy = 1; -#ifndef SKYEYE_WORKAROUNDS /* * Setup the PDC to transfer the data and interrupt us when it * is done. We've already requested the interrupt. @@ -451,15 +436,6 @@ at91_usart_bus_transmit(struct uart_soft WR4(&sc->sc_bas, PDC_PTCR, PDC_PTCR_TXTEN); WR4(&sc->sc_bas, USART_IER, USART_CSR_ENDTX); uart_unlock(sc->sc_hwmtx); -#else - for (int i = 0; i < sc->sc_txdatasz; i++) - at91_usart_putc(&sc->sc_bas, sc->sc_txbuf[i]); - /* - * XXX: Gross hack : Skyeye doesn't raise an interrupt once the - * transfer is done, so simulate it. - */ - WR4(&sc->sc_bas, USART_IER, USART_CSR_TXRDY); -#endif return (0); } static int From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 03:30:16 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 677AB106566B; Thu, 6 Jan 2011 03:30:16 +0000 (UTC) (envelope-from davidxu@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 58ECB8FC0C; Thu, 6 Jan 2011 03:30:16 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p063UGKF000415; Thu, 6 Jan 2011 03:30:16 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p063UGNa000413; Thu, 6 Jan 2011 03:30:16 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201101060330.p063UGNa000413@svn.freebsd.org> From: David Xu Date: Thu, 6 Jan 2011 03:30:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217039 - head/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 03:30:16 -0000 Author: davidxu Date: Thu Jan 6 03:30:16 2011 New Revision: 217039 URL: http://svn.freebsd.org/changeset/base/217039 Log: Remove leftover for r214093. Modified: head/include/pthread.h Modified: head/include/pthread.h ============================================================================== --- head/include/pthread.h Thu Jan 6 02:36:29 2011 (r217038) +++ head/include/pthread.h Thu Jan 6 03:30:16 2011 (r217039) @@ -135,15 +135,6 @@ enum pthread_mutextype { #define PTHREAD_MUTEX_DEFAULT PTHREAD_MUTEX_ERRORCHECK -enum pthread_rwlocktype_np -{ - PTHREAD_RWLOCK_PREFER_READER_NP, - PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP, - PTHREAD_RWLOCK_PREFER_WRITER_NP, - PTHREAD_RWLOCK_DEFAULT_NP = - PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP -}; - struct _pthread_cleanup_info { __uintptr_t pthread_cleanup_pad[8]; }; From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 03:33:44 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3B2BC1065670; Thu, 6 Jan 2011 03:33:44 +0000 (UTC) (envelope-from scf@FreeBSD.org) Received: from mail.farley.org (mail.farley.org [IPv6:2001:470:1f0f:20:2::11]) by mx1.freebsd.org (Postfix) with ESMTP id EEBF98FC14; Thu, 6 Jan 2011 03:33:43 +0000 (UTC) Received: from [192.168.1.201] ([192.168.1.201]) by mail.farley.org (8.14.4/8.14.4) with ESMTP id p063Xgo4076544; Wed, 5 Jan 2011 21:33:42 -0600 (CST) (envelope-from scf@FreeBSD.org) Date: Wed, 5 Jan 2011 22:33:41 -0500 (EST) From: "Sean C. Farley" To: Alexander Best In-Reply-To: <20110102000402.GA65041@freebsd.org> Message-ID: References: <201012300218.oBU2I4BF020068@svn.freebsd.org> <20110102000402.GA65041@freebsd.org> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII X-Spam-Status: No, score=-2.9 required=4.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.farley.org Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r216813 - head/sys/compat/linux X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 03:33:44 -0000 On Sun, 2 Jan 2011, Alexander Best wrote: > On Thu Dec 30 10, Sean Farley wrote: >> Author: scf >> Date: Thu Dec 30 02:18:04 2010 >> New Revision: 216813 >> URL: http://svn.freebsd.org/changeset/base/216813 >> >> Log: >> Fix the LINUX_SOUND_MIXER_INFO ioctl to return success after the >> information is set to FreeBSD. It had been falling through to the end >> of linux_ioctl_sound() and returning ENOIOCTL. Noticed when running the >> Linux ALSA amixer tool. >> >> Add a LINUX_SOUND_MIXER_READ_CAPS ioctl which is used by the Skype >> v2.1.0.81 binary. > > i'm running r216877 and still skype won't detect my audio devices > (i.e. it reports "Problem With Audio Playback"). > > this is with the static skype binary package. I forgot to mention that the change is only effective using the secret decoder ring. :) Here[1] is the E-mail I sent previously to emulation@ which details what is necessary to get sound output working in Skype and input in arecord. I have not figured out how to get Skype to work with the microphone, at least on my system. I wish Skype would bring back the OSS capability. Sean 1. http://lists.freebsd.org/pipermail/freebsd-emulation/2010-September/008085.html -- scf@FreeBSD.org From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 03:36:04 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ED949106564A; Thu, 6 Jan 2011 03:36:04 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DEF028FC0A; Thu, 6 Jan 2011 03:36:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p063a4w1000591; Thu, 6 Jan 2011 03:36:04 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p063a4aE000589; Thu, 6 Jan 2011 03:36:04 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201101060336.p063a4aE000589@svn.freebsd.org> From: Nathan Whitehorn Date: Thu, 6 Jan 2011 03:36:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217040 - head/sys/geom/part X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 03:36:05 -0000 Author: nwhitehorn Date: Thu Jan 6 03:36:04 2011 New Revision: 217040 URL: http://svn.freebsd.org/changeset/base/217040 Log: Add an entry to the gpart XML to determine if the geom has pending changes that need to be committed (or undone). MFC after: 2 weeks Modified: head/sys/geom/part/g_part.c Modified: head/sys/geom/part/g_part.c ============================================================================== --- head/sys/geom/part/g_part.c Thu Jan 6 03:30:16 2011 (r217039) +++ head/sys/geom/part/g_part.c Thu Jan 6 03:36:04 2011 (r217040) @@ -1868,6 +1868,8 @@ g_part_dumpconf(struct sbuf *sb, const c table->gpt_heads); sbuf_printf(sb, "%s%s\n", indent, table->gpt_corrupt ? "CORRUPT": "OK"); + sbuf_printf(sb, "%s%s\n", indent, + table->gpt_opened ? "true": "false"); G_PART_DUMPCONF(table, NULL, sb, indent); } } From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 04:05:25 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ABB3A1065673; Thu, 6 Jan 2011 04:05:25 +0000 (UTC) (envelope-from lstewart@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9CCB38FC17; Thu, 6 Jan 2011 04:05:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p0645P3H001451; Thu, 6 Jan 2011 04:05:25 GMT (envelope-from lstewart@svn.freebsd.org) Received: (from lstewart@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p0645Pav001449; Thu, 6 Jan 2011 04:05:25 GMT (envelope-from lstewart@svn.freebsd.org) Message-Id: <201101060405.p0645Pav001449@svn.freebsd.org> From: Lawrence Stewart Date: Thu, 6 Jan 2011 04:05:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217043 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 04:05:25 -0000 Author: lstewart Date: Thu Jan 6 04:05:25 2011 New Revision: 217043 URL: http://svn.freebsd.org/changeset/base/217043 Log: Fix a whitespace nit. MFC after: 1 week X-MFC with: r216995 Modified: head/share/man/man9/osd.9 Modified: head/share/man/man9/osd.9 ============================================================================== --- head/share/man/man9/osd.9 Thu Jan 6 03:57:25 2011 (r217042) +++ head/share/man/man9/osd.9 Thu Jan 6 04:05:25 2011 (r217043) @@ -34,7 +34,7 @@ .Nm osd_deregister , .Nm osd_set , .Nm osd_get , -.Nm osd_del, +.Nm osd_del , .Nm osd_call , .Nm osd_exit .Nd Object Specific Data From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 04:12:30 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4E03B106564A; Thu, 6 Jan 2011 04:12:30 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3C3F88FC0C; Thu, 6 Jan 2011 04:12:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p064CUoB001682; Thu, 6 Jan 2011 04:12:30 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p064CUrA001671; Thu, 6 Jan 2011 04:12:30 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201101060412.p064CUrA001671@svn.freebsd.org> From: Nathan Whitehorn Date: Thu, 6 Jan 2011 04:12:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217044 - in head/sys: boot/powerpc boot/powerpc/ps3 conf powerpc/conf powerpc/include powerpc/ps3 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 04:12:30 -0000 Author: nwhitehorn Date: Thu Jan 6 04:12:29 2011 New Revision: 217044 URL: http://svn.freebsd.org/changeset/base/217044 Log: Import support for the Sony Playstation 3 using the OtherOS feature available on firmwares 3.15 and earlier. Caveats: Support for the internal SATA controller is currently missing, as is support for framebuffer resolutions other than 720x480. These deficiencies will be remedied soon. Special thanks to Peter Grehan for providing the hardware that made this port possible, and thanks to Geoff Levand of Sony Computer Entertainment for advice on the LV1 hypervisor. Added: head/sys/boot/powerpc/ps3/ head/sys/boot/powerpc/ps3/Makefile (contents, props changed) head/sys/boot/powerpc/ps3/conf.c (contents, props changed) head/sys/boot/powerpc/ps3/devicename.c (contents, props changed) head/sys/boot/powerpc/ps3/help.ps3 (contents, props changed) head/sys/boot/powerpc/ps3/ldscript.powerpc (contents, props changed) head/sys/boot/powerpc/ps3/lv1call.S (contents, props changed) head/sys/boot/powerpc/ps3/lv1call.h (contents, props changed) head/sys/boot/powerpc/ps3/main.c (contents, props changed) head/sys/boot/powerpc/ps3/metadata.c (contents, props changed) head/sys/boot/powerpc/ps3/ppc64_elf_freebsd.c (contents, props changed) head/sys/boot/powerpc/ps3/ps3.h (contents, props changed) head/sys/boot/powerpc/ps3/ps3cons.c (contents, props changed) head/sys/boot/powerpc/ps3/ps3mmu.c (contents, props changed) head/sys/boot/powerpc/ps3/ps3net.c (contents, props changed) head/sys/boot/powerpc/ps3/start.S (contents, props changed) head/sys/boot/powerpc/ps3/version (contents, props changed) head/sys/powerpc/ps3/ head/sys/powerpc/ps3/ehci_ps3.c (contents, props changed) head/sys/powerpc/ps3/if_glc.c (contents, props changed) head/sys/powerpc/ps3/if_glcreg.h (contents, props changed) head/sys/powerpc/ps3/mmu_ps3.c (contents, props changed) head/sys/powerpc/ps3/platform_ps3.c (contents, props changed) head/sys/powerpc/ps3/ps3-hv-asm.awk (contents, props changed) head/sys/powerpc/ps3/ps3-hv-header.awk (contents, props changed) head/sys/powerpc/ps3/ps3-hvcall.S (contents, props changed) head/sys/powerpc/ps3/ps3-hvcall.h (contents, props changed) head/sys/powerpc/ps3/ps3-hvcall.master (contents, props changed) head/sys/powerpc/ps3/ps3_syscons.c (contents, props changed) head/sys/powerpc/ps3/ps3bus.c (contents, props changed) head/sys/powerpc/ps3/ps3bus.h (contents, props changed) head/sys/powerpc/ps3/ps3pic.c (contents, props changed) Modified: head/sys/boot/powerpc/Makefile head/sys/conf/files.powerpc head/sys/conf/options.powerpc head/sys/powerpc/conf/GENERIC64 head/sys/powerpc/conf/NOTES head/sys/powerpc/include/pte.h Modified: head/sys/boot/powerpc/Makefile ============================================================================== --- head/sys/boot/powerpc/Makefile Thu Jan 6 04:05:25 2011 (r217043) +++ head/sys/boot/powerpc/Makefile Thu Jan 6 04:12:29 2011 (r217044) @@ -1,5 +1,5 @@ # $FreeBSD$ -SUBDIR= boot1.chrp ofw uboot +SUBDIR= boot1.chrp ofw ps3 uboot .include Added: head/sys/boot/powerpc/ps3/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/Makefile Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1,122 @@ +# $FreeBSD$ + +.include +MK_SSP= no + +PROG= loader.ps3 +NEWVERSWHAT= "Playstation 3 loader" ${MACHINE_ARCH} +BINDIR?= /boot +INSTALLFLAGS= -b + +# Architecture-specific loader code +SRCS= start.S conf.c metadata.c vers.c main.c devicename.c ppc64_elf_freebsd.c +SRCS+= lv1call.S ps3cons.c font.h ps3mmu.c ps3net.c +SRCS+= ucmpdi2.c + +LOADER_DISK_SUPPORT?= yes +LOADER_UFS_SUPPORT?= yes +LOADER_CD9660_SUPPORT?= yes +LOADER_EXT2FS_SUPPORT?= no +LOADER_NET_SUPPORT?= yes +LOADER_NFS_SUPPORT?= yes +LOADER_TFTP_SUPPORT?= no +LOADER_GZIP_SUPPORT?= yes +LOADER_FDT_SUPPORT?= no +LOADER_BZIP2_SUPPORT?= no + +.if ${LOADER_DISK_SUPPORT} == "yes" +CFLAGS+= -DLOADER_DISK_SUPPORT +.endif +.if ${LOADER_UFS_SUPPORT} == "yes" +CFLAGS+= -DLOADER_UFS_SUPPORT +.endif +.if ${LOADER_CD9660_SUPPORT} == "yes" +CFLAGS+= -DLOADER_CD9660_SUPPORT +.endif +.if ${LOADER_EXT2FS_SUPPORT} == "yes" +CFLAGS+= -DLOADER_EXT2FS_SUPPORT +.endif +.if ${LOADER_GZIP_SUPPORT} == "yes" +CFLAGS+= -DLOADER_GZIP_SUPPORT +.endif +.if ${LOADER_BZIP2_SUPPORT} == "yes" +CFLAGS+= -DLOADER_BZIP2_SUPPORT +.endif +.if ${LOADER_NET_SUPPORT} == "yes" +CFLAGS+= -DLOADER_NET_SUPPORT +.endif +.if ${LOADER_NFS_SUPPORT} == "yes" +CFLAGS+= -DLOADER_NFS_SUPPORT +.endif +.if ${LOADER_TFTP_SUPPORT} == "yes" +CFLAGS+= -DLOADER_TFTP_SUPPORT +.endif +.if ${LOADER_FDT_SUPPORT} == "yes" +CFLAGS+= -I${.CURDIR}/../../fdt +CFLAGS+= -I${.OBJDIR}/../../fdt +CFLAGS+= -DLOADER_FDT_SUPPORT +LIBFDT= ${.OBJDIR}/../../fdt/libfdt.a +.endif + + +.if ${MK_FORTH} != "no" +# Enable BootForth +BOOT_FORTH= yes +CFLAGS+= -DBOOT_FORTH -I${.CURDIR}/../../ficl -I${.CURDIR}/../../ficl/powerpc +LIBFICL= ${.OBJDIR}/../../ficl/libficl.a +.endif + +# Avoid the open-close-dance for every file access as some firmwares perform +# an auto-negotiation on every open of the network interface and thus causes +# netbooting to take horribly long. +CFLAGS+= -DNETIF_OPEN_CLOSE_ONCE -mcpu=powerpc64 + +# Always add MI sources +.PATH: ${.CURDIR}/../../common ${.CURDIR}/../../../libkern +.include "${.CURDIR}/../../common/Makefile.inc" +CFLAGS+= -I${.CURDIR}/../../common -I${.CURDIR}/../../.. +CFLAGS+= -I. + +CLEANFILES+= vers.c loader.help + +CFLAGS+= -Wall -ffreestanding -msoft-float -DAIM +# load address. set in linker script +RELOC?= 0x0 +CFLAGS+= -DRELOC=${RELOC} + +LDFLAGS= -nostdlib -static -T ${.CURDIR}/ldscript.powerpc + +# 64-bit bridge extensions +CFLAGS+= -Wa,-mppc64bridge + +# Pull in common loader code +#.PATH: ${.CURDIR}/../../ofw/common +#.include "${.CURDIR}/../../ofw/common/Makefile.inc" + +# where to get libstand from +CFLAGS+= -I${.CURDIR}/../../../../lib/libstand/ + +DPADD= ${LIBFICL} ${LIBOFW} ${LIBSTAND} +LDADD= ${LIBFICL} ${LIBOFW} -lstand + +SC_DFLT_FONT=cp437 + +font.h: + uudecode < /usr/share/syscons/fonts/${SC_DFLT_FONT}-8x16.fnt && file2c 'u_char dflt_font_16[16*256] = {' '};' < ${SC_DFLT_FONT}-8x16 > font.h && uudecode < /usr/share/syscons/fonts/${SC_DFLT_FONT}-8x14.fnt && file2c 'u_char dflt_font_14[14*256] = {' '};' < ${SC_DFLT_FONT}-8x14 >> font.h && uudecode < /usr/share/syscons/fonts/${SC_DFLT_FONT}-8x8.fnt && file2c 'u_char dflt_font_8[8*256] = {' '};' < ${SC_DFLT_FONT}-8x8 >> font.h + +vers.c: ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version + sh ${.CURDIR}/../../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT} + +loader.help: help.common help.ps3 + cat ${.ALLSRC} | \ + awk -f ${.CURDIR}/../../common/merge_help.awk > ${.TARGET} + +.PATH: ${.CURDIR}/../../forth +FILES= loader.help loader.4th support.4th loader.conf +FILESDIR_loader.conf= /boot/defaults + +.if !exists(${DESTDIR}/boot/loader.rc) +FILES+= loader.rc +.endif + +.include Added: head/sys/boot/powerpc/ps3/conf.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/conf.c Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1,119 @@ +/*- + * Copyright (c) 1999 Michael Smith + * 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. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include "bootstrap.h" + +#if defined(LOADER_NET_SUPPORT) +#include "dev_net.h" +#endif + +/* + * We could use linker sets for some or all of these, but + * then we would have to control what ended up linked into + * the bootstrap. So it's easier to conditionalise things + * here. + * + * XXX rename these arrays to be consistent and less namespace-hostile + */ + +/* Exported for libstand */ +struct devsw *devsw[] = { +#if defined(LOADER_DISK_SUPPORT) || defined(LOADER_CD9660_SUPPORT) +#ifdef NOTYET + &ps3disk, +#endif +#endif +#if defined(LOADER_NET_SUPPORT) + &netdev, +#endif + NULL +}; + +struct fs_ops *file_system[] = { +#if defined(LOADER_UFS_SUPPORT) + &ufs_fsops, +#endif +#if defined(LOADER_CD9660_SUPPORT) + &cd9660_fsops, +#endif +#if defined(LOADER_EXT2FS_SUPPORT) + &ext2fs_fsops, +#endif +#if defined(LOADER_NFS_SUPPORT) + &nfs_fsops, +#endif +#if defined(LOADER_TFTP_SUPPORT) + &tftp_fsops, +#endif +#if defined(LOADER_GZIP_SUPPORT) + &gzipfs_fsops, +#endif +#if defined(LOADER_BZIP2_SUPPORT) + &bzipfs_fsops, +#endif + NULL +}; + +extern struct netif_driver ps3net; + +struct netif_driver *netif_drivers[] = { +#if defined(LOADER_NET_SUPPORT) + &ps3net, +#endif + NULL, +}; + +/* Exported for PowerPC only */ +/* + * Sort formats so that those that can detect based on arguments + * rather than reading the file go first. + */ + +extern struct file_format ppc_elf64; + +struct file_format *file_formats[] = { + &ppc_elf64, + NULL +}; + +/* + * Consoles + */ +extern struct console ps3console; + +struct console *consoles[] = { + &ps3console, + NULL +}; + +/* + * reloc - our load address + */ +vm_offset_t reloc = RELOC; Added: head/sys/boot/powerpc/ps3/devicename.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/devicename.c Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1,238 @@ +/*- + * Copyright (c) 1998 Michael Smith + * 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. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include + +#include +#include + +#include "bootstrap.h" + +static int ps3_parsedev(struct devdesc **dev, const char *devspec, + const char **path); + +/* + * Point (dev) at an allocated device specifier for the device matching the + * path in (devspec). If it contains an explicit device specification, + * use that. If not, use the default device. + */ +int +ps3_getdev(void **vdev, const char *devspec, const char **path) +{ + struct devdesc **dev = (struct devdesc **)vdev; + int rv = 0; + + /* + * If it looks like this is just a path and no + * device, go with the current device. + */ + if ((devspec == NULL) || (devspec[0] == '/') || + (strchr(devspec, ':') == NULL)) { + rv = ps3_parsedev(dev, getenv("currdev"), NULL); + + if (rv == 0 && path != NULL) + *path = devspec; + return(rv); + } + + /* + * Try to parse the device name off the beginning of the devspec. + */ + return (ps3_parsedev(dev, devspec, path)); +} + +/* + * Point (dev) at an allocated device specifier matching the string version + * at the beginning of (devspec). Return a pointer to the remaining + * text in (path). + * + * In all cases, the beginning of (devspec) is compared to the names + * of known devices in the device switch, and then any following text + * is parsed according to the rules applied to the device type. + * + * For disk-type devices, the syntax is: + * + * disk[]: + * + */ +static int +ps3_parsedev(struct devdesc **dev, const char *devspec, const char **path) +{ + struct devdesc *idev; + struct devsw *dv; + char *cp; + const char *np; + int i, unit, pnum, ptype, err; + + /* minimum length check */ + if (strlen(devspec) < 2) + return(EINVAL); + + /* look for a device that matches */ + for (i = 0, dv = NULL; devsw[i] != NULL; i++) { + if (!strncmp(devspec, devsw[i]->dv_name, + strlen(devsw[i]->dv_name))) { + dv = devsw[i]; + break; + } + } + if (dv == NULL) + return(ENOENT); + idev = malloc(sizeof(struct devdesc)); + err = 0; + np = (devspec + strlen(dv->dv_name)); + + switch(dv->dv_type) { + case DEVT_NONE: + break; + +#ifdef NOTYET + case DEVT_DISK: + unit = -1; + pnum = -1; + ptype = -1; + if (*np && (*np != ':')) { + /* next comes the unit number */ + unit = strtol(np, &cp, 10); + if (cp == np) { + err = EUNIT; + goto fail; + } + if (*cp && (*cp != ':')) { + /* get partition */ + if (*cp == 'p' && *(cp + 1) && + *(cp + 1) != ':') { + pnum = strtol(cp + 1, &cp, 10); + ptype = PTYPE_GPT; + } else { + pnum = *cp - 'a'; + ptype = PTYPE_BSDLABEL; + if ((pnum < 0) || + (pnum >= MAXPARTITIONS)) { + err = EPART; + goto fail; + } + cp++; + } + } + } + if (*cp && (*cp != ':')) { + err = EINVAL; + goto fail; + } + + idev->d_unit = unit; + idev->d_disk.pnum = pnum; + idev->d_disk.ptype = ptype; + idev->d_disk.data = NULL; + if (path != NULL) + *path = (*cp == 0) ? cp : cp + 1; + break; +#endif + + case DEVT_NET: + /* + * PS3 only has one network interface (well, two, but + * netbooting over wireless is not something I'm going + * to worry about. + */ + + idev->d_unit = 0; + break; + + default: + err = EINVAL; + goto fail; + } + idev->d_dev = dv; + idev->d_type = dv->dv_type; + if (dev == NULL) { + free(idev); + } else { + *dev = idev; + } + return (0); + +fail: + free(idev); + return (err); +} + + +char * +ps3_fmtdev(void *vdev) +{ + struct devdesc *dev = (struct devdesc *)vdev; + char *cp; + static char buf[128]; + + switch(dev->d_type) { + case DEVT_NONE: + strcpy(buf, "(no device)"); + break; + +#ifdef NOTYET + case DEVT_DISK: + cp = buf; + cp += sprintf(cp, "%s%d", dev->d_dev->dv_name, dev->d_unit); + if (dev->d_kind.disk.pnum >= 0) { + if (dev->d_kind.disk.ptype == PTYPE_BSDLABEL) + cp += sprintf(cp, "%c", + dev->d_kind.disk.pnum + 'a'); + else if (dev->d_kind.disk.ptype == PTYPE_GPT) + cp += sprintf(cp, "p%i", + dev->d_kind.disk.pnum); + } + + strcat(cp, ":"); + break; +#endif + + case DEVT_NET: + sprintf(buf, "%s%d:", dev->d_dev->dv_name, dev->d_unit); + break; + } + return(buf); +} + +/* + * Set currdev to suit the value being supplied in (value). + */ +int +ps3_setcurrdev(struct env_var *ev, int flags, const void *value) +{ + struct devdesc *ncurr; + int rv; + + if ((rv = ps3_parsedev(&ncurr, value, NULL)) != 0) + return (rv); + free(ncurr); + env_setenv(ev->ev_name, flags | EV_NOHOOK, value, NULL, NULL); + return (0); +} Added: head/sys/boot/powerpc/ps3/help.ps3 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/help.ps3 Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1 @@ +$FreeBSD$ Added: head/sys/boot/powerpc/ps3/ldscript.powerpc ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/ldscript.powerpc Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1,112 @@ +/* $FreeBSD$ */ + +OUTPUT_FORMAT("elf32-powerpc", "elf32-powerpc", "elf32-powerpc") +OUTPUT_ARCH(powerpc:common) +ENTRY(_start) +SEARCH_DIR(/usr/lib); +/* Do we need any of these for elf? + __DYNAMIC = 0; */ +PROVIDE (__stack = 0); +SECTIONS +{ + /* Read-only sections, merged into text segment: */ + . = 0x0; + .text : + { + *(.text) + /* .gnu.warning sections are handled specially by elf32.em. */ + *(.gnu.warning) + *(.gnu.linkonce.t*) + } =0 + _etext = .; + .interp : { *(.interp) } + .hash : { *(.hash) } + .dynsym : { *(.dynsym) } + .dynstr : { *(.dynstr) } + .gnu.version : { *(.gnu.version) } + .gnu.version_d : { *(.gnu.version_d) } + .gnu.version_r : { *(.gnu.version_r) } + .rela.text : + { *(.rela.text) *(.rela.gnu.linkonce.t*) } + .rela.data : + { *(.rela.data) *(.rela.gnu.linkonce.d*) } + .rela.rodata : + { *(.rela.rodata) *(.rela.gnu.linkonce.r*) } + .rela.got : { *(.rela.got) } + .rela.got1 : { *(.rela.got1) } + .rela.got2 : { *(.rela.got2) } + .rela.ctors : { *(.rela.ctors) } + .rela.dtors : { *(.rela.dtors) } + .rela.init : { *(.rela.init) } + .rela.fini : { *(.rela.fini) } + .rela.bss : { *(.rela.bss) } + .rela.plt : { *(.rela.plt) } + .rela.sbss : { *(.rela.sbss) } + .rela.sbss2 : { *(.rela.sbss2) } + .text : + { + *(.text) + /* .gnu.warning sections are handled specially by elf32.em. */ + *(.gnu.warning) + *(.gnu.linkonce.t*) + } =0 + _etext = .; + PROVIDE (etext = .); + .init : { *(.init) } =0 + .fini : { *(.fini) } =0 + .rodata : { *(.rodata) *(.gnu.linkonce.r*) } + .rodata1 : { *(.rodata1) } + .sbss2 : { *(.sbss2) } + /* Adjust the address for the data segment to the next page up. */ + . = ((. + 0x1000) & ~(0x1000 - 1)); + .data : + { + *(.data) + *(.gnu.linkonce.d*) + CONSTRUCTORS + } + .data1 : { *(.data1) } + .got1 : { *(.got1) } + .dynamic : { *(.dynamic) } + /* Put .ctors and .dtors next to the .got2 section, so that the pointers + get relocated with -mrelocatable. Also put in the .fixup pointers. + The current compiler no longer needs this, but keep it around for 2.7.2 */ + PROVIDE (_GOT2_START_ = .); + .got2 : { *(.got2) } + PROVIDE (__CTOR_LIST__ = .); + .ctors : { *(.ctors) } + PROVIDE (__CTOR_END__ = .); + PROVIDE (__DTOR_LIST__ = .); + .dtors : { *(.dtors) } + PROVIDE (__DTOR_END__ = .); + PROVIDE (_FIXUP_START_ = .); + .fixup : { *(.fixup) } + PROVIDE (_FIXUP_END_ = .); + PROVIDE (_GOT2_END_ = .); + PROVIDE (_GOT_START_ = .); + .got : { *(.got) } + .got.plt : { *(.got.plt) } + PROVIDE (_GOT_END_ = .); + _edata = .; + PROVIDE (edata = .); + .sbss : + { + PROVIDE (__sbss_start = .); + *(.sbss) + *(.scommon) + *(.dynsbss) + PROVIDE (__sbss_end = .); + } + .plt : { *(.plt) } + .bss : + { + PROVIDE (__bss_start = .); + *(.dynbss) + *(.bss) + *(COMMON) + } + . = ALIGN(4096); + _end = . ; + PROVIDE (end = .); +} + Added: head/sys/boot/powerpc/ps3/lv1call.S ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/lv1call.S Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1,256 @@ +/*- + * Copyright (C) 2010 Nathan Whitehorn + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL TOOLS GMBH 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$ + */ + +/* Hypercall stubs. Note: this is all a hack and should die. */ + +#define hc .long 0x44000022 + +#define LD64_IM(r, highest, higher, high, low) \ + lis r,highest; \ + addi r,r,higher; \ + sldi r,r,32; \ + addis r,r,high; \ + addi r,r,low; + +#define SIMPLE_HVCALL(x, c) \ +.global x; \ +x: \ + mflr %r0; \ + stw %r0,4(%r1); \ + clrldi %r3,%r3,32; \ + clrldi %r4,%r4,32; \ + clrldi %r5,%r5,32; \ + clrldi %r6,%r6,32; \ + clrldi %r7,%r7,32; \ + clrldi %r8,%r8,32; \ + clrldi %r9,%r9,32; \ + clrldi %r10,%r10,32; \ + li %r11,c; \ + hc; \ + extsw %r3,%r3; \ + lwz %r0,4(%r1); \ + mtlr %r0; \ + blr + +SIMPLE_HVCALL(lv1_open_device, 170) +SIMPLE_HVCALL(lv1_close_device, 171) +SIMPLE_HVCALL(lv1_gpu_open, 210) +SIMPLE_HVCALL(lv1_gpu_context_attribute, 225) +SIMPLE_HVCALL(lv1_panic, 255) +SIMPLE_HVCALL(lv1_net_start_tx_dma, 187) +SIMPLE_HVCALL(lv1_net_stop_tx_dma, 188) +SIMPLE_HVCALL(lv1_net_start_rx_dma, 189) +SIMPLE_HVCALL(lv1_net_stop_rx_dma, 190) + +.global lv1_get_physmem +lv1_get_physmem: + mflr %r0 + stw %r0,4(%r1) + stw %r3,-8(%r1) /* Address for maxmem */ + + li %r11,69 /* Get PU ID */ + hc + std %r4,-16(%r1) + + li %r11,74 /* Get LPAR ID */ + hc + std %r4,-24(%r1) + + ld %r3,-24(%r1) + LD64_IM(%r4,0x0000,0x0000,0x6269,0x0000 /* "bi" */) + LD64_IM(%r5,0x7075,0x0000,0x0000,0x0000 /* "pu" */) + ld %r6,-16(%r1) + LD64_IM(%r7,0x726d,0x5f73,0x697a,0x6500 /* "rm_size" */) + li %r11,91 + hc + extsw %r3,%r3 + + lwz %r5,-8(%r1) + std %r4,0(%r5) + + lwz %r0,4(%r1) + mtlr %r0 + blr + +.global lv1_setup_address_space +lv1_setup_address_space: + mflr %r0 + stw %r0,4(%r1) + + stw %r3,-4(%r1) + stw %r4,-8(%r1) + + li %r3,18 /* PT size: log2(256 KB) */ + li %r4,2 /* Two page sizes */ + li %r5,24 /* Page sizes: (24 << 56) | (16 << 48) */ + sldi %r5,%r5,24 + li %r6,16 + sldi %r6,%r6,16 + or %r5,%r5,%r6 + sldi %r5,%r5,32 + + li %r11,2 /* lv1_construct_virtual_address_space */ + hc + + lwz %r6,-4(%r1) + lwz %r7,-8(%r1) + std %r4,0(%r6) + std %r5,0(%r7) + + /* AS_ID in r4 */ + mr %r3,%r4 + li %r11,7 /* lv1_select_virtual_address_space */ + hc + extsw %r3,%r3 + + lwz %r0,4(%r1) + mtlr %r0 + blr + +.global lv1_insert_pte +lv1_insert_pte: + mflr %r0 + stw %r0,4(%r1) + + mr %r11,%r4 /* Save R4 */ + + clrldi %r3,%r3,32 + clrldi %r7,%r5,32 + + sldi %r4,%r3,3 /* Convert ptegidx into base PTE slot */ + li %r3,0 /* Current address space */ + ld %r5,0(%r11) + ld %r6,8(%r11) + li %r8,0 /* No other flags */ + + li %r11,158 + hc + extsw %r3,%r3 + + lwz %r0,4(%r1) + mtlr %r0 + blr + +.global lv1_gpu_context_allocate +lv1_gpu_context_allocate: + mflr %r0 + stw %r0,4(%r1) + stw %r7,-4(%r1) + + sldi %r3,%r3,32 + clrldi %r4,%r4,32 + ori %r3,%r3,%r4 + clrldi %r4,%r5,32 + clrldi %r5,%r6,32 + + li %r11,217 + hc + extsw %r3,%r3 + + lwz %r7,-4(%r1) + std %r4,0(%r7) + + lwz %r0,4(%r1) + mtlr %r0 + blr + +.global lv1_gpu_memory_allocate +lv1_gpu_memory_allocate: + mflr %r0 + stw %r0,4(%r1) + stw %r8,-4(%r1) + stw %r9,-8(%r1) + + li %r11,214 + hc + extsw %r3,%r3 + + lwz %r8,-4(%r1) + lwz %r9,-8(%r1) + std %r4,0(%r8) + std %r5,0(%r9) + + lwz %r0,4(%r1) + mtlr %r0 + blr + +.global lv1_net_control +lv1_net_control: + mflr %r0 + stw %r0,4(%r1) + stw %r9,-4(%r1) + + li %r11,194 + hc + extsw %r3,%r3 + + lwz %r8,-4(%r1) + std %r4,0(%r8) + + lwz %r0,4(%r1) + mtlr %r0 + blr + +.global lv1_setup_dma +lv1_setup_dma: + mflr %r0 + stw %r0,4(%r1) + stw %r3,-4(%r1) + stw %r4,-8(%r1) + stw %r5,-12(%r1) + + lwz %r3,-4(%r1) + lwz %r4,-8(%r1) + lis %r5,0x0800 /* 128 MB */ + li %r6,24 /* log2(IO_PAGESIZE) */ + li %r7,0 /* flags */ + li %r11,174 /* lv1_allocate_device_dma_region */ + hc + extsw %r3,%r3 + cmpdi %r3,0 + bne 1f + std %r4,-24(%r1) + + lwz %r3,-4(%r1) + lwz %r4,-8(%r1) + li %r5,0 + ld %r6,-24(%r1) + lis %r7,0x0800 /* 128 MB */ + lis %r8,0xf800 /* flags */ + sldi %r8,%r8,32 + li %r11,176 /* lv1_map_device_dma_region */ + hc + extsw %r3,%r3 + + lwz %r9,-12(%r1) + ld %r6,-24(%r1) + std %r6,0(%r9) + +1: lwz %r0,4(%r1) + mtlr %r0 + blr + Added: head/sys/boot/powerpc/ps3/lv1call.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/lv1call.h Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1,72 @@ +/*- + * Copyright (C) 2010 Nathan Whitehorn + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL TOOLS GMBH 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$ + */ + +#ifndef _PS3_LV1CALL_H +#define _PS3_LV1CALL_H + +#include + +int lv1_get_physmem(uint64_t *maxmem); +int lv1_setup_address_space(uint64_t *as_id, uint64_t *ptsize); +int lv1_insert_pte(u_int ptegidx, struct lpte *pte, int lockflags); +int lv1_panic(int reboot); + +#define L1GPU_CONTEXT_ATTRIBUTE_DISPLAY_MODE_SET 0x0100 +#define L1GPU_CONTEXT_ATTRIBUTE_DISPLAY_SYNC 0x0101 +#define L1GPU_DISPLAY_SYNC_HSYNC 1 +#define L1GPU_DISPLAY_SYNC_VSYNC 2 +#define L1GPU_CONTEXT_ATTRIBUTE_DISPLAY_FLIP 0x0102 + +int lv1_gpu_open(int); +int lv1_gpu_context_attribute(int context, int op, int, int, int, int); +int lv1_gpu_memory_allocate(int size, int, int, int, int, uint64_t *handle, + uint64_t *paddr); +int lv1_gpu_context_allocate(uint64_t handle, int, uint64_t *context); + +int lv1_open_device(int, int, int /* 0 */); +int lv1_close_device(int, int); +int lv1_setup_dma(int, int, uint64_t *dmabase); + +#define GELIC_GET_MAC_ADDRESS 0x0001 +#define GELIC_GET_LINK_STATUS 0x0002 +#define GELIC_LINK_UP 0x0001 +#define GELIC_FULL_DUPLEX 0x0002 +#define GELIC_AUTO_NEG 0x0004 +#define GELIC_SPEED_10 0x0010 +#define GELIC_SPEED_100 0x0020 +#define GELIC_SPEED_1000 0x0040 +#define GELIC_GET_VLAN_ID 0x0004 + +int lv1_net_init(int bus, int dev); +int lv1_net_control(int bus, int dev, int, int, int, int, uint64_t *); +int lv1_net_start_tx_dma(int bus, int dev, uint32_t addr, int); +int lv1_net_start_rx_dma(int bus, int dev, uint32_t addr, int); +int lv1_net_stop_tx_dma(int bus, int dev, int); +int lv1_net_stop_rx_dma(int bus, int dev, int); + +#endif + Added: head/sys/boot/powerpc/ps3/main.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/powerpc/ps3/main.c Thu Jan 6 04:12:29 2011 (r217044) @@ -0,0 +1,211 @@ +/*- + * Copyright (C) 2010 Nathan Whitehorn + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL TOOLS GMBH BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include + +#define _KERNEL +#include + +#include "bootstrap.h" +#include "lv1call.h" +#include "ps3.h" + +struct arch_switch archsw; +extern void *_end; + +extern char bootprog_name[]; +extern char bootprog_rev[]; +extern char bootprog_date[]; +extern char bootprog_maker[]; + +int ps3_getdev(void **vdev, const char *devspec, const char **path); *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 07:13:23 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B95E91065670; Thu, 6 Jan 2011 07:13:23 +0000 (UTC) (envelope-from stas@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A98688FC0A; Thu, 6 Jan 2011 07:13:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p067DNss006350; Thu, 6 Jan 2011 07:13:23 GMT (envelope-from stas@svn.freebsd.org) Received: (from stas@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p067DNfw006348; Thu, 6 Jan 2011 07:13:23 GMT (envelope-from stas@svn.freebsd.org) Message-Id: <201101060713.p067DNfw006348@svn.freebsd.org> From: Stanislav Sedov Date: Thu, 6 Jan 2011 07:13:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217046 - head/usr.sbin/cpucontrol X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 07:13:23 -0000 Author: stas Date: Thu Jan 6 07:13:23 2011 New Revision: 217046 URL: http://svn.freebsd.org/changeset/base/217046 Log: - Show textual representation of ioctl command in warning message if ioctl(4) is failed besides the command number. Suggested by: delphij MFC after: 2 weeks Modified: head/usr.sbin/cpucontrol/cpucontrol.c Modified: head/usr.sbin/cpucontrol/cpucontrol.c ============================================================================== --- head/usr.sbin/cpucontrol/cpucontrol.c Thu Jan 6 04:38:10 2011 (r217045) +++ head/usr.sbin/cpucontrol/cpucontrol.c Thu Jan 6 07:13:23 2011 (r217046) @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2008 Stanislav Sedov . + * Copyright (c) 2008-2011 Stanislav Sedov . * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -177,6 +177,7 @@ do_msr(const char *cmdarg, const char *d unsigned long command; int do_invert = 0, op; int fd, error; + const char *command_name; char *endptr; char *p; @@ -245,15 +246,19 @@ do_msr(const char *cmdarg, const char *d switch (op) { case OP_READ: command = CPUCTL_RDMSR; + command_name = "CPUCTL_RDMSR"; break; case OP_WRITE: command = CPUCTL_WRMSR; + command_name = "CPUCTL_WRMSR"; break; case OP_OR: command = CPUCTL_MSRSBIT; + command_name = "CPUCTL_MSRSBIT"; break; case OP_AND: command = CPUCTL_MSRCBIT; + command_name = "CPUCTL_MSRCBIT"; break; default: abort(); @@ -266,7 +271,7 @@ do_msr(const char *cmdarg, const char *d } error = ioctl(fd, command, &args); if (error < 0) { - WARN(0, "ioctl(%s, %lu)", dev, command); + WARN(0, "ioctl(%s, %s (%lu))", dev, command_name, command); close(fd); return (1); } From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 08:13:31 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C308C1065696; Thu, 6 Jan 2011 08:13:31 +0000 (UTC) (envelope-from davidxu@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 077158FC0C; Thu, 6 Jan 2011 08:13:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p068DUEk007753; Thu, 6 Jan 2011 08:13:30 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p068DUUK007751; Thu, 6 Jan 2011 08:13:30 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201101060813.p068DUUK007751@svn.freebsd.org> From: David Xu Date: Thu, 6 Jan 2011 08:13:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217047 - head/lib/libthr/thread X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 08:13:31 -0000 Author: davidxu Date: Thu Jan 6 08:13:30 2011 New Revision: 217047 URL: http://svn.freebsd.org/changeset/base/217047 Log: Return 0 instead of garbage value. Found by: clang static analyzer Modified: head/lib/libthr/thread/thr_mutex.c Modified: head/lib/libthr/thread/thr_mutex.c ============================================================================== --- head/lib/libthr/thread/thr_mutex.c Thu Jan 6 07:13:23 2011 (r217046) +++ head/lib/libthr/thread/thr_mutex.c Thu Jan 6 08:13:30 2011 (r217047) @@ -492,11 +492,10 @@ int _mutex_cv_attach(struct pthread_mutex *m, int count) { struct pthread *curthread = _get_curthread(); - int error; ENQUEUE_MUTEX(curthread, m); m->m_count = count; - return (error); + return (0); } int From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 08:33:48 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A920A106566B; Thu, 6 Jan 2011 08:33:48 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 996E68FC18; Thu, 6 Jan 2011 08:33:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p068XmhN008301; Thu, 6 Jan 2011 08:33:48 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p068Xmrj008299; Thu, 6 Jan 2011 08:33:48 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201101060833.p068Xmrj008299@svn.freebsd.org> From: Edward Tomasz Napierala Date: Thu, 6 Jan 2011 08:33:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217048 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 08:33:48 -0000 Author: trasz Date: Thu Jan 6 08:33:48 2011 New Revision: 217048 URL: http://svn.freebsd.org/changeset/base/217048 Log: Get rid of bad advice regarding /* NOTREACHED */. Compilers don't really need it (one can use __dead2 instead), and style(9) was not even consistent with itself in this regard. Modified: head/share/man/man9/style.9 Modified: head/share/man/man9/style.9 ============================================================================== --- head/share/man/man9/style.9 Thu Jan 6 08:13:30 2011 (r217047) +++ head/share/man/man9/style.9 Thu Jan 6 08:33:48 2011 (r217048) @@ -470,9 +470,6 @@ statement that cascade should have a .Li FALLTHROUGH comment. Numerical arguments should be checked for accuracy. -Code that cannot be reached should have a -.Li NOTREACHED -comment. .Bd -literal while ((ch = getopt(argc, argv, "abNn:")) != -1) switch (ch) { /* Indent the switch. */ @@ -496,7 +493,6 @@ comment. case '?': default: usage(); - /* NOTREACHED */ } argc -= optind; argv += optind; From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 09:00:02 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7E80C106564A; Thu, 6 Jan 2011 09:00:02 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from out-0.mx.aerioconnect.net (outy.internet-mail-service.net [216.240.47.248]) by mx1.freebsd.org (Postfix) with ESMTP id 58F058FC14; Thu, 6 Jan 2011 09:00:02 +0000 (UTC) Received: from idiom.com (postfix@mx0.idiom.com [216.240.32.160]) by out-0.mx.aerioconnect.net (8.13.8/8.13.8) with ESMTP id p068npXu001491; Thu, 6 Jan 2011 00:49:51 -0800 X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e Received: from julian-mac.elischer.org (h-67-100-89-137.snfccasy.static.covad.net [67.100.89.137]) by idiom.com (Postfix) with ESMTP id 40F4A2D6012; Thu, 6 Jan 2011 00:49:49 -0800 (PST) Message-ID: <4D258247.5030707@freebsd.org> Date: Thu, 06 Jan 2011 00:50:15 -0800 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.4; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: Bruce Evans References: <201101041316.p04DGSo6037042@svn.freebsd.org> <201101041314.08949.jhb@freebsd.org> <20110105161720.GA1388@a91-153-123-205.elisa-laajakaista.fi> <201101051144.56940.jhb@freebsd.org> <20110106062530.Y1027@besplex.bde.org> In-Reply-To: <20110106062530.Y1027@besplex.bde.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.67 on 216.240.47.51 Cc: svn-src-head@freebsd.org, Jaakko Heinonen , svn-src-all@freebsd.org, src-committers@freebsd.org, John Baldwin Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 09:00:02 -0000 On 1/5/11 11:39 AM, Bruce Evans wrote: > On Wed, 5 Jan 2011, John Baldwin wrote: > >> On Wednesday, January 05, 2011 11:17:20 am Jaakko Heinonen wrote: >>> On 2011-01-04, John Baldwin wrote: >>>> Err, no, the point of NOTREACHED is to serve as documentation for >>>> lint(1), but >>>> that has subsequently been obsoleted by __dead2. >>> >>> style(9) is out of date then? >> >> According to bde@'s most recent e-mails, yes. > > It's obviously out of date, since its only example of using > NOTREACHED is after a usage() call, and this usage is missing a > __dead2. Of course it > doesn't use NOTREACHED after its 3 exit() calls or its 2 err() calls or > its 1 errx() call, so its "should" requirement for using NOTREACHED is > mostly not satisfied by itself. However I feel that teh notreached comment is as much for the reader as the compiler/lint. Removing it makes the code harder to understand for the feeble minded such as myself. > > Bruce > From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 09:02:19 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6422E1065672; Thu, 6 Jan 2011 09:02:19 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from out-0.mx.aerioconnect.net (outy.internet-mail-service.net [216.240.47.248]) by mx1.freebsd.org (Postfix) with ESMTP id 420E28FC08; Thu, 6 Jan 2011 09:02:19 +0000 (UTC) Received: from idiom.com (postfix@mx0.idiom.com [216.240.32.160]) by out-0.mx.aerioconnect.net (8.13.8/8.13.8) with ESMTP id p0692IAk001958; Thu, 6 Jan 2011 01:02:18 -0800 X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e X-Client-Authorized: MaGic Cook1e Received: from julian-mac.elischer.org (h-67-100-89-137.snfccasy.static.covad.net [67.100.89.137]) by idiom.com (Postfix) with ESMTP id A710C2D6010; Thu, 6 Jan 2011 01:02:17 -0800 (PST) Message-ID: <4D258533.3@freebsd.org> Date: Thu, 06 Jan 2011 01:02:43 -0800 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.4; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: Edward Tomasz Napierala References: <201101060833.p068Xmrj008299@svn.freebsd.org> In-Reply-To: <201101060833.p068Xmrj008299@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.67 on 216.240.47.51 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217048 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 09:02:19 -0000 On 1/6/11 12:33 AM, Edward Tomasz Napierala wrote: > Author: trasz > Date: Thu Jan 6 08:33:48 2011 > New Revision: 217048 > URL: http://svn.freebsd.org/changeset/base/217048 > > Log: > Get rid of bad advice regarding /* NOTREACHED */. Compilers don't > really need it (one can use __dead2 instead), and style(9) was not > even consistent with itself in this regard. > > Modified: > head/share/man/man9/style.9 > > Modified: head/share/man/man9/style.9 > ============================================================================== > --- head/share/man/man9/style.9 Thu Jan 6 08:13:30 2011 (r217047) > +++ head/share/man/man9/style.9 Thu Jan 6 08:33:48 2011 (r217048) > @@ -470,9 +470,6 @@ statement that cascade should have a > .Li FALLTHROUGH > comment. > Numerical arguments should be checked for accuracy. > -Code that cannot be reached should have a > -.Li NOTREACHED > -comment. I object STRONGLY to this change. The NOTREACHED is also to help the reader understand what has happened and as an afterthought was also useful in LINT. I know know of no technological change to the average reader that makes it less useful. > .Bd -literal > while ((ch = getopt(argc, argv, "abNn:")) != -1) > switch (ch) { /* Indent the switch. */ > @@ -496,7 +493,6 @@ comment. > case '?': > default: > usage(); > - /* NOTREACHED */ > } > argc -= optind; > argv += optind; > From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 09:32:36 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 237C4106564A; Thu, 6 Jan 2011 09:32:36 +0000 (UTC) (envelope-from etnapierala@googlemail.com) Received: from mail-wy0-f182.google.com (mail-wy0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id 5A6EF8FC0C; Thu, 6 Jan 2011 09:32:35 +0000 (UTC) Received: by wyf19 with SMTP id 19so16358870wyf.13 for ; Thu, 06 Jan 2011 01:32:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:sender:subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to:x-mailer; bh=Ci7bRZkWXLNYabVuRJBCtaI5JhttGe8GZdRcO2GHM4c=; b=W91tWitMXolrMwi6AqX7PTH75yFITraxB5DqWacn5nF5VwCkSr23tgv9sAvJqN3gKl e3gz4JzGhRz1uYwsEaXf2m0LXH6Bdd4+/wuSYB3ITQtf9P2bNJG35gSxgBehcSZyNZNT 95BKxiMrO9kr1q21WLINHULphqC7XGAMMCd5s= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=sender:subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=rlI2lwOhVs11ePwBnstxhFZL3W/4f5JQ0hUq7vvt8aFNHst7P+rFR3ALK+e1ntY5+y tQQsFRaJPzCnTSiawwN7nwzj+luzUF7JgIQ3HWLSQerE8LZFO/MBG9acHV7wlKSiTQ/Z besF4DxR9tPuf4Si98fGTod1OnOsm0r+g33Rg= Received: by 10.216.187.10 with SMTP id x10mr23001047wem.97.1294305004394; Thu, 06 Jan 2011 01:10:04 -0800 (PST) Received: from [192.168.2.4] (gate19.robnet.pl [194.105.132.219]) by mx.google.com with ESMTPS id t11sm11072035wes.41.2011.01.06.01.10.01 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 06 Jan 2011 01:10:03 -0800 (PST) Sender: =?UTF-8?Q?Edward_Tomasz_Napiera=C5=82a?= Mime-Version: 1.0 (Apple Message framework v1082) Content-Type: text/plain; charset=iso-8859-2 From: =?iso-8859-2?Q?Edward_Tomasz_Napiera=B3a?= In-Reply-To: <4D258533.3@freebsd.org> Date: Thu, 6 Jan 2011 10:09:59 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: <8C6A03B3-8A1E-4316-8A7C-1EF4CE10E12B@freebsd.org> References: <201101060833.p068Xmrj008299@svn.freebsd.org> <4D258533.3@freebsd.org> To: Julian Elischer X-Mailer: Apple Mail (2.1082) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217048 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 09:32:36 -0000 Wiadomo=B6=E6 napisana przez Julian Elischer w dniu 2011-01-06, o godz. = 10:02: > On 1/6/11 12:33 AM, Edward Tomasz Napierala wrote: >> Author: trasz >> Date: Thu Jan 6 08:33:48 2011 >> New Revision: 217048 >> URL: http://svn.freebsd.org/changeset/base/217048 >>=20 >> Log: >> Get rid of bad advice regarding /* NOTREACHED */. Compilers don't >> really need it (one can use __dead2 instead), and style(9) was not >> even consistent with itself in this regard. >>=20 >> Modified: >> head/share/man/man9/style.9 >>=20 >> Modified: head/share/man/man9/style.9 >> = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D >> --- head/share/man/man9/style.9 Thu Jan 6 08:13:30 2011 = (r217047) >> +++ head/share/man/man9/style.9 Thu Jan 6 08:33:48 2011 = (r217048) >> @@ -470,9 +470,6 @@ statement that cascade should have a >> .Li FALLTHROUGH >> comment. >> Numerical arguments should be checked for accuracy. >> -Code that cannot be reached should have a >> -.Li NOTREACHED >> -comment. >=20 > I object STRONGLY to this change. >=20 > The NOTREACHED is also to help the reader understand what has happened = and as an afterthought > was also useful in LINT. I know know of no technological change to = the average reader that makes > it less useful. What about adding something like this? Code that cannot be reached for non-obvious reasons may have .Li NOTREACHED comment. -- If you cut off my head, what would I say? Me and my head, or me and my = body? From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 09:42:41 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0C444106566C; Thu, 6 Jan 2011 09:42:41 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (cl-327.ede-01.nl.sixxs.net [IPv6:2001:7b8:2ff:146::2]) by mx1.freebsd.org (Postfix) with ESMTP id BFFDD8FC08; Thu, 6 Jan 2011 09:42:40 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:386f:212a:67be:86c8] (unknown [IPv6:2001:7b8:3a7:0:386f:212a:67be:86c8]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id A57F45C5A; Thu, 6 Jan 2011 10:42:39 +0100 (CET) Message-ID: <4D258E91.2040403@FreeBSD.org> Date: Thu, 06 Jan 2011 10:42:41 +0100 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2.14pre) Gecko/20110104 Lanikai/3.1.8pre MIME-Version: 1.0 To: Ivan Voras References: <201101052224.p05MOXQs093175@svn.freebsd.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217033 - in head: lib/libstand sys/boot/ficl sys/boot/i386 sys/boot/pc98 sys/boot/zfs sys/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 09:42:41 -0000 On 2011-01-06 00:14, Ivan Voras wrote: >> -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float > I'm late to the party - but is there any hope of centralizing these > and then doing something like "CFLAGS += ${CC_NO_FP}" ? Yeah, that is the next step. First I wanted to get all the flags the same. Btw, this is not only about "no floating point", as SSE instructions can be used for other things (memset, memcpy, etc) too. So "NO_FP" is misleading in my opinion, but it seems to be what most people want. > As soon as we > get a newer compiler someone will have to add -mno-sse4 to the list > (if not already with clang...). For clang, we should add the following, if we want to be very cautious: -mno_aes -mno_avx -mno_sse4 -mno_sse4_1 -mno_sse4_2 -mno_sse4a -mno_ssse3 From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 12:47:53 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3513D106566C; Thu, 6 Jan 2011 12:47:53 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 08E9F8FC16; Thu, 6 Jan 2011 12:47:53 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id A6D5746B06; Thu, 6 Jan 2011 07:47:52 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id C96CC8A01D; Thu, 6 Jan 2011 07:47:51 -0500 (EST) From: John Baldwin To: Julian Elischer Date: Thu, 6 Jan 2011 07:47:48 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101060833.p068Xmrj008299@svn.freebsd.org> <4D258533.3@freebsd.org> In-Reply-To: <4D258533.3@freebsd.org> MIME-Version: 1.0 Message-Id: <201101060747.48443.jhb@freebsd.org> Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Thu, 06 Jan 2011 07:47:51 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Edward Tomasz Napierala Subject: Re: svn commit: r217048 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 12:47:53 -0000 On Thursday, January 06, 2011 4:02:43 am Julian Elischer wrote: > On 1/6/11 12:33 AM, Edward Tomasz Napierala wrote: > > Author: trasz > > Date: Thu Jan 6 08:33:48 2011 > > New Revision: 217048 > > URL: http://svn.freebsd.org/changeset/base/217048 > > > > Log: > > Get rid of bad advice regarding /* NOTREACHED */. Compilers don't > > really need it (one can use __dead2 instead), and style(9) was not > > even consistent with itself in this regard. > > > > Modified: > > head/share/man/man9/style.9 > > > > Modified: head/share/man/man9/style.9 > > ============================================================================== > > --- head/share/man/man9/style.9 Thu Jan 6 08:13:30 2011 (r217047) > > +++ head/share/man/man9/style.9 Thu Jan 6 08:33:48 2011 (r217048) > > @@ -470,9 +470,6 @@ statement that cascade should have a > > .Li FALLTHROUGH > > comment. > > Numerical arguments should be checked for accuracy. > > -Code that cannot be reached should have a > > -.Li NOTREACHED > > -comment. > > I object STRONGLY to this change. > > The NOTREACHED is also to help the reader understand what has happened > and as an afterthought > was also useful in LINT. I know know of no technological change to > the average reader that makes > it less useful. Clutter. It should be very obvious that exit(), err*(), pthread_exit(), kthread_exit(), kproc_exit() and even usage() all terminate without returning (the last not required, just a very common convention). If you look at most code, NOTREACHED is actually used sparingly if at all. Needless clutter makes code harder to parse (less of it fits into a single editor window) and should be avoided. Most cases of 'ARGSUSED' are probably worse than 'NOTREACHED' abuses. Also, our code in general has not followed this rule. Some older code (back when lint was used before compilers (and lint) supported things like __dead2) still uses it, but new code tends to not use it. __dead2 is actually far more useful than NOTREACHED since the compiler groks it (whereas compilers ignore NOTREACHED comments). -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 12:56:11 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx2.freebsd.org (mx2.freebsd.org [IPv6:2001:4f8:fff6::35]) by hub.freebsd.org (Postfix) with ESMTP id 2BE0410656A9 for ; Thu, 6 Jan 2011 12:56:11 +0000 (UTC) (envelope-from cperciva@freebsd.org) Received: from xps.daemonology.net (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx2.freebsd.org (Postfix) with SMTP id B98A315337A for ; Thu, 6 Jan 2011 12:56:09 +0000 (UTC) Received: (qmail 71394 invoked from network); 6 Jan 2011 12:56:09 -0000 Received: from unknown (HELO xps.daemonology.net) (127.0.0.1) by localhost with SMTP; 6 Jan 2011 12:56:09 -0000 Message-ID: <4D25BBE9.4090905@freebsd.org> Date: Thu, 06 Jan 2011 04:56:09 -0800 From: Colin Percival User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.1.16) Gecko/20101220 Thunderbird/3.0.11 MIME-Version: 1.0 To: John Baldwin References: <201101060833.p068Xmrj008299@svn.freebsd.org> <4D258533.3@freebsd.org> <201101060747.48443.jhb@freebsd.org> In-Reply-To: <201101060747.48443.jhb@freebsd.org> X-Enigmail-Version: 1.0.1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, Edward Tomasz Napierala , svn-src-all@freebsd.org, src-committers@freebsd.org, Julian Elischer Subject: Re: svn commit: r217048 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 12:56:11 -0000 On 01/06/11 04:47, John Baldwin wrote: > On Thursday, January 06, 2011 4:02:43 am Julian Elischer wrote: >> On 1/6/11 12:33 AM, Edward Tomasz Napierala wrote: >>> -Code that cannot be reached should have a >>> -.Li NOTREACHED >>> -comment. > > Clutter. It should be very obvious that exit(), err*(), pthread_exit(), > kthread_exit(), kproc_exit() and even usage() all terminate without returning > (the last not required, just a very common convention). [...] However, it might not be so obvious following long 'for (;;)' loops which return rather than breaking. I'd prefer to see the remark stay in style(9) with an added "in cases where this isn't immediately obvious from the surrounding code" clause. -- Colin Percival Security Officer, FreeBSD | freebsd.org | The power to serve Founder / author, Tarsnap | tarsnap.com | Online backups for the truly paranoid From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 14:12:24 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B266A106566B; Thu, 6 Jan 2011 14:12:24 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A19EB8FC1A; Thu, 6 Jan 2011 14:12:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06ECOJF017181; Thu, 6 Jan 2011 14:12:24 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06ECOwZ017179; Thu, 6 Jan 2011 14:12:24 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201101061412.p06ECOwZ017179@svn.freebsd.org> From: Nathan Whitehorn Date: Thu, 6 Jan 2011 14:12:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217054 - head/sys/powerpc/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 14:12:24 -0000 Author: nwhitehorn Date: Thu Jan 6 14:12:24 2011 New Revision: 217054 URL: http://svn.freebsd.org/changeset/base/217054 Log: Unbreak the LINT build. PS3 kernels can only be built 64-bit, and LINT is built for both architectures. We need a better solution here. Modified: head/sys/powerpc/conf/NOTES Modified: head/sys/powerpc/conf/NOTES ============================================================================== --- head/sys/powerpc/conf/NOTES Thu Jan 6 13:21:38 2011 (r217053) +++ head/sys/powerpc/conf/NOTES Thu Jan 6 14:12:24 2011 (r217054) @@ -20,7 +20,7 @@ options FPU_EMU #options MPC85XX options POWERMAC #NewWorld Apple PowerMacs -options PS3 #Sony Playstation 3 +#options PS3 #Sony Playstation 3 options PSIM #GDB PSIM ppc simulator options MAMBO #IBM Mambo Full System Simulator From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 15:09:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ADF0A106583B; Thu, 6 Jan 2011 15:09:13 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 804FC8FC16; Thu, 6 Jan 2011 15:09:13 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 3743246B49; Thu, 6 Jan 2011 10:09:13 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 5FB408A01D; Thu, 6 Jan 2011 10:09:12 -0500 (EST) From: John Baldwin To: Nathan Whitehorn Date: Thu, 6 Jan 2011 10:07:02 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101061412.p06ECOwZ017179@svn.freebsd.org> In-Reply-To: <201101061412.p06ECOwZ017179@svn.freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101061007.02920.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Thu, 06 Jan 2011 10:09:12 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217054 - head/sys/powerpc/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 15:09:13 -0000 On Thursday, January 06, 2011 9:12:24 am Nathan Whitehorn wrote: > Author: nwhitehorn > Date: Thu Jan 6 14:12:24 2011 > New Revision: 217054 > URL: http://svn.freebsd.org/changeset/base/217054 > > Log: > Unbreak the LINT build. PS3 kernels can only be built 64-bit, and LINT is > built for both architectures. We need a better solution here. NOTES64? (At some point it almost seems that a sys/powerpc64/conf/ with GENERIC and NOTES would be simpler even if that is all the sys/powerpc64 directory contained). > Modified: > head/sys/powerpc/conf/NOTES > > Modified: head/sys/powerpc/conf/NOTES > ============================================================================== > --- head/sys/powerpc/conf/NOTES Thu Jan 6 13:21:38 2011 (r217053) > +++ head/sys/powerpc/conf/NOTES Thu Jan 6 14:12:24 2011 (r217054) > @@ -20,7 +20,7 @@ options FPU_EMU > > #options MPC85XX > options POWERMAC #NewWorld Apple PowerMacs > -options PS3 #Sony Playstation 3 > +#options PS3 #Sony Playstation 3 > options PSIM #GDB PSIM ppc simulator > options MAMBO #IBM Mambo Full System Simulator > > -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 15:24:17 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 596A0106566B; Thu, 6 Jan 2011 15:24:17 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from mail.icecube.wisc.edu (trout.icecube.wisc.edu [128.104.255.119]) by mx1.freebsd.org (Postfix) with ESMTP id 2C78F8FC13; Thu, 6 Jan 2011 15:24:16 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 856445811B; Thu, 6 Jan 2011 09:24:16 -0600 (CST) X-Virus-Scanned: amavisd-new at icecube.wisc.edu Received: from mail.icecube.wisc.edu ([127.0.0.1]) by localhost (trout.icecube.wisc.edu [127.0.0.1]) (amavisd-new, port 10030) with ESMTP id TYZ9JMK75CS0; Thu, 6 Jan 2011 09:24:16 -0600 (CST) Received: from comporellon.tachypleus.net (unknown [76.210.75.5]) by mail.icecube.wisc.edu (Postfix) with ESMTP id DE8835811D; Thu, 6 Jan 2011 09:24:15 -0600 (CST) Message-ID: <4D25DE9E.80603@freebsd.org> Date: Thu, 06 Jan 2011 09:24:14 -0600 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101214 Thunderbird/3.1.7 MIME-Version: 1.0 To: John Baldwin References: <201101061412.p06ECOwZ017179@svn.freebsd.org> <201101061007.02920.jhb@freebsd.org> In-Reply-To: <201101061007.02920.jhb@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217054 - head/sys/powerpc/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 15:24:18 -0000 On 01/06/11 09:07, John Baldwin wrote: > On Thursday, January 06, 2011 9:12:24 am Nathan Whitehorn wrote: >> Author: nwhitehorn >> Date: Thu Jan 6 14:12:24 2011 >> New Revision: 217054 >> URL: http://svn.freebsd.org/changeset/base/217054 >> >> Log: >> Unbreak the LINT build. PS3 kernels can only be built 64-bit, and LINT is >> built for both architectures. We need a better solution here. > NOTES64? (At some point it almost seems that a sys/powerpc64/conf/ with > GENERIC and NOTES would be simpler even if that is all the sys/powerpc64 > directory contained). > Adding a /sys/powerpc64/conf makes all kinds of things harder, since it implies MACHINE=powerpc64. You then have to duplicate all the stuff in /sys/conf, special-case things in /sys/boot, add tons of stub headers, etc., etc. I had this while developing, and it was much worse to deal with than the current setup -- and while developing, I could use symlinks in the tree. A NOTES64, or conditional logic in config(8), are better solutions, I think. -Nathan From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 17:28:32 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1178D106566B; Thu, 6 Jan 2011 17:28:32 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 00BC58FC08; Thu, 6 Jan 2011 17:28:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06HSV6l023156; Thu, 6 Jan 2011 17:28:31 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06HSVCU023154; Thu, 6 Jan 2011 17:28:31 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101061728.p06HSVCU023154@svn.freebsd.org> From: Marius Strobl Date: Thu, 6 Jan 2011 17:28:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217058 - head/sys/sparc64/sparc64 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 17:28:32 -0000 Author: marius Date: Thu Jan 6 17:28:31 2011 New Revision: 217058 URL: http://svn.freebsd.org/changeset/base/217058 Log: Remove an unused variable accidentally added in r216803. Modified: head/sys/sparc64/sparc64/tsb.c Modified: head/sys/sparc64/sparc64/tsb.c ============================================================================== --- head/sys/sparc64/sparc64/tsb.c Thu Jan 6 16:25:08 2011 (r217057) +++ head/sys/sparc64/sparc64/tsb.c Thu Jan 6 17:28:31 2011 (r217058) @@ -80,7 +80,6 @@ struct tte *tsb_kernel; vm_size_t tsb_kernel_mask; vm_size_t tsb_kernel_size; vm_paddr_t tsb_kernel_phys; -vm_paddr_t tsb_kernel_phys_end; u_int tsb_kernel_ldd_phys; struct tte * From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 19:17:29 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C62BF106566B; Thu, 6 Jan 2011 19:17:29 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B56888FC17; Thu, 6 Jan 2011 19:17:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06JHTZZ025660; Thu, 6 Jan 2011 19:17:29 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06JHTYK025657; Thu, 6 Jan 2011 19:17:29 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201101061917.p06JHTYK025657@svn.freebsd.org> From: Gavin Atkinson Date: Thu, 6 Jan 2011 19:17:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217061 - in head/sys/dev/usb: . serial X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 19:17:29 -0000 Author: gavin Date: Thu Jan 6 19:17:29 2011 New Revision: 217061 URL: http://svn.freebsd.org/changeset/base/217061 Log: Support the Uniform Industrial Corp (UIC) MSR206 Magnetic Card Reader. MFC after: 1 week Modified: head/sys/dev/usb/serial/uplcom.c head/sys/dev/usb/usbdevs Modified: head/sys/dev/usb/serial/uplcom.c ============================================================================== --- head/sys/dev/usb/serial/uplcom.c Thu Jan 6 18:23:36 2011 (r217060) +++ head/sys/dev/usb/serial/uplcom.c Thu Jan 6 19:17:29 2011 (r217061) @@ -283,6 +283,7 @@ static const struct usb_device_id uplcom UPLCOM_DEV(PROLIFIC, PL2303), /* Generic adapter */ UPLCOM_DEV(PROLIFIC, RSAQ2), /* I/O DATA USB-RSAQ2 */ UPLCOM_DEV(PROLIFIC, RSAQ3), /* I/O DATA USB-RSAQ3 */ + UPLCOM_DEV(PROLIFIC, UIC_MSR206), /* UIC MSR206 Card Reader */ UPLCOM_DEV(PROLIFIC2, PL2303), /* Prolific adapter */ UPLCOM_DEV(RADIOSHACK, USBCABLE), UPLCOM_DEV(RATOC, REXUSB60), /* RATOC REX-USB60 */ Modified: head/sys/dev/usb/usbdevs ============================================================================== --- head/sys/dev/usb/usbdevs Thu Jan 6 18:23:36 2011 (r217060) +++ head/sys/dev/usb/usbdevs Thu Jan 6 19:17:29 2011 (r217061) @@ -2593,6 +2593,7 @@ product PROLIFIC ALLTRONIX_GPRS 0x0609 A product PROLIFIC ALDIGA_AL11U 0x0611 AlDiga AL-11U modem product PROLIFIC MICROMAX_610U 0x0612 Micromax 610U product PROLIFIC DCU11 0x1234 DCU-11 Phone Cable +product PROLIFIC UIC_MSR206 0x206a UIC MSR206 Card Reader product PROLIFIC PL2303 0x2303 PL2303 Serial (ATEN/IOGEAR UC232A) product PROLIFIC PL2305 0x2305 Parallel printer product PROLIFIC ATAPI4 0x2307 ATAPI-4 Controller From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 19:32:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C1F871065693; Thu, 6 Jan 2011 19:32:00 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 976638FC18; Thu, 6 Jan 2011 19:32:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06JW004026003; Thu, 6 Jan 2011 19:32:00 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06JW0qW026001; Thu, 6 Jan 2011 19:32:00 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101061932.p06JW0qW026001@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 19:32:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217062 - head/sys/arm/at91 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 19:32:00 -0000 Author: jhb Date: Thu Jan 6 19:32:00 2011 New Revision: 217062 URL: http://svn.freebsd.org/changeset/base/217062 Log: - Use macbstart_locked() directly instead of deferring it to a task. - Expand locking scope in interrupt handler. - Flesh out the detach routine. Reviewed by: cognet Modified: head/sys/arm/at91/if_macb.c Modified: head/sys/arm/at91/if_macb.c ============================================================================== --- head/sys/arm/at91/if_macb.c Thu Jan 6 19:17:29 2011 (r217061) +++ head/sys/arm/at91/if_macb.c Thu Jan 6 19:32:00 2011 (r217062) @@ -137,7 +137,6 @@ macb_watchdog(struct macb_softc *sc); static int macb_intr_rx_locked(struct macb_softc *sc, int count); static void macb_intr_task(void *arg, int pending __unused); -static void macb_tx_task(void *arg, int pending __unused); static void macb_intr(void *xsc); static void @@ -533,7 +532,7 @@ macb_watchdog(struct macb_softc *sc) ifp->if_drv_flags &= ~IFF_DRV_RUNNING; macbinit_locked(sc); if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->sc_tq, &sc->sc_tx_task); + macbstart_locked(ifp); } @@ -837,6 +836,7 @@ macb_intr(void *xsc) return; } + MACB_LOCK(sc); status = read_4(sc, EMAC_ISR); while (status) { @@ -846,16 +846,15 @@ macb_intr(void *xsc) } if (status & TCOMP_INTERRUPT) { - MACB_LOCK(sc); macb_tx_cleanup(sc); - MACB_UNLOCK(sc); } status = read_4(sc, EMAC_ISR); } if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - taskqueue_enqueue(sc->sc_tq, &sc->sc_tx_task); + macbstart_locked(ifp); + MACB_UNLOCK(sc); } static inline int @@ -1026,16 +1025,6 @@ macbstart(struct ifnet *ifp) static void -macb_tx_task(void *arg, int pending __unused) -{ - struct ifnet *ifp; - - ifp = (struct ifnet *)arg; - macbstart(ifp); -} - - -static void macbstop(struct macb_softc *sc) { struct ifnet *ifp = sc->ifp; @@ -1392,7 +1381,6 @@ macb_attach(device_t dev) sc->if_flags = ifp->if_flags; TASK_INIT(&sc->sc_intr_task, 0, macb_intr_task, sc); - TASK_INIT(&sc->sc_tx_task, 0, macb_tx_task, ifp); sc->sc_tq = taskqueue_create_fast("macb_taskq", M_WAITOK, taskqueue_thread_enqueue, &sc->sc_tq); @@ -1434,8 +1422,18 @@ macb_detach(device_t dev) struct macb_softc *sc; sc = device_get_softc(dev); + ether_ifdetach(sc->ifp); + MACB_LOCK(sc); macbstop(sc); + MACB_UNLOCK(sc); + callout_drain(&sc->tick_ch); + bus_teardown_intr(dev, sc->irq_res, sc->intrhand); + taskqueue_drain(sc->sc_tq, &sc->sc_intr_task); + taskqueue_free(sc->sc_tq); macb_deactivate(dev); + bus_release_resource(dev, SYS_RES_IRQ, 0, sc->irq_res); + bus_release_resource(dev, SYS_RES_MEMORY, 0, sc->mem_res); + MACB_LOCK_DESTROY(sc); return (0); } From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 19:50:11 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4C3E71065693; Thu, 6 Jan 2011 19:50:11 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3A93B8FC15; Thu, 6 Jan 2011 19:50:11 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06JoBlw026387; Thu, 6 Jan 2011 19:50:11 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06JoBNk026381; Thu, 6 Jan 2011 19:50:11 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101061950.p06JoBNk026381@svn.freebsd.org> From: Rick Macklem Date: Thu, 6 Jan 2011 19:50:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217063 - in head/sys/fs: nfs nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 19:50:11 -0000 Author: rmacklem Date: Thu Jan 6 19:50:11 2011 New Revision: 217063 URL: http://svn.freebsd.org/changeset/base/217063 Log: Since the VFS_LOCK_GIANT() code in the experimental NFS server is broken and the major file systems are now all mpsafe, modify the server so that it will only export mpsafe file systems. This was discussed on freebsd-fs@ and removes a fair bit of crufty code. MFC after: 12 days Modified: head/sys/fs/nfs/nfs_var.h head/sys/fs/nfs/nfsdport.h head/sys/fs/nfsserver/nfs_nfsdport.c head/sys/fs/nfsserver/nfs_nfsdserv.c head/sys/fs/nfsserver/nfs_nfsdsocket.c Modified: head/sys/fs/nfs/nfs_var.h ============================================================================== --- head/sys/fs/nfs/nfs_var.h Thu Jan 6 19:32:00 2011 (r217062) +++ head/sys/fs/nfs/nfs_var.h Thu Jan 6 19:50:11 2011 (r217063) @@ -570,8 +570,6 @@ int nfsvno_pathconf(vnode_t, int, regist NFSPROC_T *); vnode_t nfsvno_getvp(fhandle_t *); int nfsvno_advlock(vnode_t, int, u_int64_t, u_int64_t, NFSPROC_T *); -void nfsvno_unlockvfs(mount_t); -int nfsvno_lockvfs(mount_t); int nfsrv_v4rootexport(void *, struct ucred *, NFSPROC_T *); int nfsvno_testexp(struct nfsrv_descript *, struct nfsexstuff *); uint32_t nfsrv_hashfh(fhandle_t *); Modified: head/sys/fs/nfs/nfsdport.h ============================================================================== --- head/sys/fs/nfs/nfsdport.h Thu Jan 6 19:32:00 2011 (r217062) +++ head/sys/fs/nfs/nfsdport.h Thu Jan 6 19:50:11 2011 (r217063) @@ -52,7 +52,6 @@ * needs to be returned by nfsd_fhtovp(). */ struct nfsexstuff { - int nes_vfslocked; /* required for all ports */ int nes_exflag; /* export flags */ int nes_numsecflavor; /* # of security flavors */ int nes_secflavors[MAXSECFLAVORS]; /* and the flavors */ Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Thu Jan 6 19:32:00 2011 (r217062) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Thu Jan 6 19:50:11 2011 (r217063) @@ -332,18 +332,7 @@ nfsvno_namei(struct nfsrv_descript *nd, * In either case ni_startdir will be dereferenced and NULLed * out. */ - if (exp->nes_vfslocked) - ndp->ni_cnd.cn_flags |= GIANTHELD; error = lookup(ndp); - /* - * The Giant lock should only change when - * crossing mount points. - */ - if (crossmnt) { - exp->nes_vfslocked = - (ndp->ni_cnd.cn_flags & GIANTHELD) != 0; - ndp->ni_cnd.cn_flags &= ~GIANTHELD; - } if (error) break; @@ -2471,7 +2460,10 @@ nfsvno_fhtovp(struct mount *mp, fhandle_ *credp = NULL; exp->nes_numsecflavor = 0; - error = VFS_FHTOVP(mp, &fhp->fh_fid, vpp); + if (VFS_NEEDSGIANT(mp)) + error = ESTALE; + else + error = VFS_FHTOVP(mp, &fhp->fh_fid, vpp); if (error != 0) /* Make sure the server replies ESTALE to the client. */ error = ESTALE; @@ -2521,19 +2513,8 @@ nfsvno_pathconf(struct vnode *vp, int fl * - get vp and export rights by calling nfsvno_fhtovp() * - if cred->cr_uid == 0 or MNT_EXPORTANON set it to credanon * for AUTH_SYS - * Also handle getting the Giant lock for the file system, - * as required: - * - if same mount point as *mpp - * do nothing - * else if *mpp == NULL - * if already locked - * leave it locked - * else - * call VFS_LOCK_GIANT() - * else - * if already locked - * unlock Giant - * call VFS_LOCK_GIANT() + * - if mpp != NULL, return the mount point so that it can + * be used for vn_finished_write() by the caller */ void nfsd_fhtovp(struct nfsrv_descript *nd, struct nfsrvfh *nfp, int lktype, @@ -2549,27 +2530,14 @@ nfsd_fhtovp(struct nfsrv_descript *nd, s * Check for the special case of the nfsv4root_fh. */ mp = vfs_busyfs(&fhp->fh_fsid); + if (mpp != NULL) + *mpp = mp; if (mp == NULL) { *vpp = NULL; nd->nd_repstat = ESTALE; - if (*mpp && exp->nes_vfslocked) - VFS_UNLOCK_GIANT(*mpp); - *mpp = NULL; - exp->nes_vfslocked = 0; return; } - /* - * Now, handle Giant for the file system. - */ - if (*mpp != NULL && *mpp != mp && exp->nes_vfslocked) { - VFS_UNLOCK_GIANT(*mpp); - exp->nes_vfslocked = 0; - } - if (!exp->nes_vfslocked && *mpp != mp) - exp->nes_vfslocked = VFS_LOCK_GIANT(mp); - - *mpp = mp; if (startwrite) vn_start_write(NULL, mpp, V_WAIT); @@ -2633,12 +2601,9 @@ nfsd_fhtovp(struct nfsrv_descript *nd, s if (nd->nd_repstat) { if (startwrite) vn_finished_write(mp); - if (exp->nes_vfslocked) { - VFS_UNLOCK_GIANT(mp); - exp->nes_vfslocked = 0; - } *vpp = NULL; - *mpp = NULL; + if (mpp != NULL) + *mpp = NULL; } } @@ -2840,29 +2805,6 @@ nfsvno_advlock(struct vnode *vp, int fty } /* - * Unlock an underlying local file system. - */ -void -nfsvno_unlockvfs(struct mount *mp) -{ - - VFS_UNLOCK_GIANT(mp); -} - -/* - * Lock an underlying file system, as required, and return - * whether or not it is locked. - */ -int -nfsvno_lockvfs(struct mount *mp) -{ - int ret; - - ret = VFS_LOCK_GIANT(mp); - return (ret); -} - -/* * Check the nfsv4 root exports. */ int Modified: head/sys/fs/nfsserver/nfs_nfsdserv.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdserv.c Thu Jan 6 19:32:00 2011 (r217062) +++ head/sys/fs/nfsserver/nfs_nfsdserv.c Thu Jan 6 19:50:11 2011 (r217063) @@ -1351,7 +1351,6 @@ nfsrvd_rename(struct nfsrv_descript *nd, struct nfsvattr fdirfor, fdiraft, tdirfor, tdiraft; struct nfsexstuff tnes; struct nfsrvfh tfh; - mount_t mp = NULL; char *bufp, *tbufp = NULL; u_long *hashp; @@ -1387,9 +1386,7 @@ nfsrvd_rename(struct nfsrv_descript *nd, return (error); } nd->nd_cred->cr_uid = nd->nd_saveduid; - /* Won't lock vfs if already locked, mp == NULL */ - tnes.nes_vfslocked = exp->nes_vfslocked; - nfsd_fhtovp(nd, &tfh, LK_EXCLUSIVE, &tdp, &tnes, &mp, 0, p); + nfsd_fhtovp(nd, &tfh, LK_EXCLUSIVE, &tdp, &tnes, NULL, 0, p); if (tdp) { tdirfor_ret = nfsvno_getattr(tdp, &tdirfor, nd->nd_cred, p, 1); @@ -1401,12 +1398,8 @@ nfsrvd_rename(struct nfsrv_descript *nd, if (!nd->nd_repstat) { error = nfsrv_parsename(nd, tbufp, hashp, &tond.ni_pathlen); if (error) { - if (tdp) { - if (tnes.nes_vfslocked && !exp->nes_vfslocked && - !(nd->nd_flag & ND_NFSV4)) - nfsvno_unlockvfs(mp); + if (tdp) vrele(tdp); - } vput(dp); nfsvno_relpathbuf(&fromnd); nfsvno_relpathbuf(&tond); @@ -1420,12 +1413,8 @@ nfsrvd_rename(struct nfsrv_descript *nd, nfsrv_wcc(nd, tdirfor_ret, &tdirfor, tdiraft_ret, &tdiraft); } - if (tdp) { - if (tnes.nes_vfslocked && !exp->nes_vfslocked && - !(nd->nd_flag & ND_NFSV4)) - nfsvno_unlockvfs(mp); + if (tdp) vrele(tdp); - } vput(dp); nfsvno_relpathbuf(&fromnd); nfsvno_relpathbuf(&tond); @@ -1445,12 +1434,8 @@ nfsrvd_rename(struct nfsrv_descript *nd, } if (fdirp) vrele(fdirp); - if (tdp) { - if (tnes.nes_vfslocked && !exp->nes_vfslocked && - !(nd->nd_flag & ND_NFSV4)) - nfsvno_unlockvfs(mp); + if (tdp) vrele(tdp); - } nfsvno_relpathbuf(&tond); return (0); } @@ -1465,9 +1450,6 @@ nfsrvd_rename(struct nfsrv_descript *nd, if (tdirp) tdiraft_ret = nfsvno_getattr(tdirp, &tdiraft, nd->nd_cred, p, 0); - if (tnes.nes_vfslocked && !exp->nes_vfslocked && - !(nd->nd_flag & ND_NFSV4)) - nfsvno_unlockvfs(mp); if (fdirp) vrele(fdirp); if (tdirp) @@ -1505,7 +1487,6 @@ nfsrvd_link(struct nfsrv_descript *nd, i struct nfsvattr dirfor, diraft, at; struct nfsexstuff tnes; struct nfsrvfh dfh; - mount_t mp = NULL; char *bufp; u_long *hashp; @@ -1541,9 +1522,7 @@ nfsrvd_link(struct nfsrv_descript *nd, i /* tovp is always NULL unless NFSv4 */ return (error); } - /* Won't lock vfs if already locked, mp == NULL */ - tnes.nes_vfslocked = exp->nes_vfslocked; - nfsd_fhtovp(nd, &dfh, LK_EXCLUSIVE, &dp, &tnes, &mp, 0, + nfsd_fhtovp(nd, &dfh, LK_EXCLUSIVE, &dp, &tnes, NULL, 0, p); if (dp) NFSVOPUNLOCK(dp, 0, p); @@ -1556,12 +1535,8 @@ nfsrvd_link(struct nfsrv_descript *nd, i error = nfsrv_parsename(nd, bufp, hashp, &named.ni_pathlen); if (error) { vrele(vp); - if (dp) { - if (tnes.nes_vfslocked && !exp->nes_vfslocked && - !(nd->nd_flag & ND_NFSV4)) - nfsvno_unlockvfs(mp); + if (dp) vrele(dp); - } nfsvno_relpathbuf(&named); return (error); } @@ -1591,9 +1566,6 @@ nfsrvd_link(struct nfsrv_descript *nd, i diraft_ret = nfsvno_getattr(dirp, &diraft, nd->nd_cred, p, 0); vrele(dirp); } - if (tnes.nes_vfslocked && !exp->nes_vfslocked && - !(nd->nd_flag & ND_NFSV4)) - nfsvno_unlockvfs(mp); vrele(vp); if (nd->nd_flag & ND_NFSV3) { nfsrv_postopattr(nd, getret, &at); @@ -3101,7 +3073,6 @@ nfsrvd_secinfo(struct nfsrv_descript *nd vnode_t dirp = NULL, vp; struct nfsrvfh fh; struct nfsexstuff retnes; - mount_t mp; u_int32_t *sizp; int error, savflag, i; char *bufp; @@ -3134,12 +3105,10 @@ nfsrvd_secinfo(struct nfsrv_descript *nd fh.nfsrvfh_len = NFSX_MYFH; vp = named.ni_vp; nd->nd_repstat = nfsvno_getfh(vp, (fhandle_t *)fh.nfsrvfh_data, p); - mp = vnode_mount(vp); /* so it won't try to re-lock filesys */ - retnes.nes_vfslocked = exp->nes_vfslocked; vput(vp); savflag = nd->nd_flag; if (!nd->nd_repstat) { - nfsd_fhtovp(nd, &fh, LK_SHARED, &vp, &retnes, &mp, 0, p); + nfsd_fhtovp(nd, &fh, LK_SHARED, &vp, &retnes, NULL, 0, p); if (vp) vput(vp); } Modified: head/sys/fs/nfsserver/nfs_nfsdsocket.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdsocket.c Thu Jan 6 19:32:00 2011 (r217062) +++ head/sys/fs/nfsserver/nfs_nfsdsocket.c Thu Jan 6 19:50:11 2011 (r217063) @@ -386,7 +386,6 @@ nfsrvd_dorpc(struct nfsrv_descript *nd, lktype = LK_SHARED; else lktype = LK_EXCLUSIVE; - nes.nes_vfslocked = 0; if (nd->nd_flag & ND_PUBLOOKUP) nfsd_fhtovp(nd, &nfs_pubfh, lktype, &vp, &nes, &mp, nfs_writerpc[nd->nd_procnum], p); @@ -415,12 +414,8 @@ nfsrvd_dorpc(struct nfsrv_descript *nd, if (nd->nd_repstat && (nd->nd_flag & ND_NFSV2)) { *nd->nd_errp = nfsd_errmap(nd); NFSINCRGLOBAL(newnfsstats.srvrpccnt[nfsv3to4op[nd->nd_procnum]]); - if (mp != NULL) { - if (nfs_writerpc[nd->nd_procnum]) - NFS_ENDWRITE(mp); - if (nes.nes_vfslocked) - nfsvno_unlockvfs(mp); - } + if (mp != NULL && nfs_writerpc[nd->nd_procnum] != 0) + vn_finished_write(mp); return; } @@ -445,12 +440,8 @@ nfsrvd_dorpc(struct nfsrv_descript *nd, error = (*(nfsrv3_procs0[nd->nd_procnum]))(nd, isdgram, vp, p, &nes); } - if (mp) { - if (nfs_writerpc[nd->nd_procnum]) - NFS_ENDWRITE(mp); - if (nes.nes_vfslocked) - nfsvno_unlockvfs(mp); - } + if (mp != NULL && nfs_writerpc[nd->nd_procnum] != 0) + vn_finished_write(mp); NFSINCRGLOBAL(newnfsstats.srvrpccnt[nfsv3to4op[nd->nd_procnum]]); } if (error) { @@ -498,9 +489,10 @@ nfsrvd_compound(struct nfsrv_descript *n u_char tag[NFSV4_SMALLSTR + 1], *tagstr; vnode_t vp, nvp, savevp; struct nfsrvfh fh; - mount_t mp, savemp, temp_mp = NULL; + mount_t new_mp, temp_mp = NULL; struct ucred *credanon; struct nfsexstuff nes, vpnes, savevpnes; + fsid_t cur_fsid, save_fsid; static u_int64_t compref = 0; NFSVNO_EXINIT(&vpnes); @@ -597,8 +589,8 @@ nfsrvd_compound(struct nfsrv_descript *n } savevp = vp = NULL; - savevpnes.nes_vfslocked = vpnes.nes_vfslocked = 0; - savemp = mp = NULL; + save_fsid.val[0] = save_fsid.val[1] = 0; + cur_fsid.val[0] = cur_fsid.val[1] = 0; NFSM_DISSECT(tl, u_int32_t *, NFSX_UNSIGNED); taglen = fxdr_unsigned(int, *tl); if (taglen < 0) { @@ -704,46 +696,44 @@ nfsrvd_compound(struct nfsrv_descript *n error = nfsrv_mtofh(nd, &fh); if (error) goto nfsmout; - if (!nd->nd_repstat) { - nes.nes_vfslocked = vpnes.nes_vfslocked; - nfsd_fhtovp(nd, &fh, LK_SHARED, &nvp, &nes, &mp, - 0, p); - } + if (!nd->nd_repstat) + nfsd_fhtovp(nd, &fh, LK_SHARED, &nvp, &nes, + NULL, 0, p); /* For now, allow this for non-export FHs */ if (!nd->nd_repstat) { if (vp) vrele(vp); vp = nvp; - NFSVOPUNLOCK(vp, 0, p); + cur_fsid = vp->v_mount->mnt_stat.f_fsid; + VOP_UNLOCK(vp, 0); vpnes = nes; } break; case NFSV4OP_PUTPUBFH: - if (nfs_pubfhset) { - nes.nes_vfslocked = vpnes.nes_vfslocked; + if (nfs_pubfhset) nfsd_fhtovp(nd, &nfs_pubfh, LK_SHARED, &nvp, - &nes, &mp, 0, p); - } else { + &nes, NULL, 0, p); + else nd->nd_repstat = NFSERR_NOFILEHANDLE; - } if (!nd->nd_repstat) { if (vp) vrele(vp); vp = nvp; - NFSVOPUNLOCK(vp, 0, p); + cur_fsid = vp->v_mount->mnt_stat.f_fsid; + VOP_UNLOCK(vp, 0); vpnes = nes; } break; case NFSV4OP_PUTROOTFH: if (nfs_rootfhset) { - nes.nes_vfslocked = vpnes.nes_vfslocked; nfsd_fhtovp(nd, &nfs_rootfh, LK_SHARED, &nvp, - &nes, &mp, 0, p); + &nes, NULL, 0, p); if (!nd->nd_repstat) { if (vp) vrele(vp); vp = nvp; - NFSVOPUNLOCK(vp, 0, p); + cur_fsid = vp->v_mount->mnt_stat.f_fsid; + VOP_UNLOCK(vp, 0); vpnes = nes; } } else @@ -759,7 +749,7 @@ nfsrvd_compound(struct nfsrv_descript *n VREF(vp); savevp = vp; savevpnes = vpnes; - savemp = mp; + save_fsid = cur_fsid; } } else { nd->nd_repstat = NFSERR_NOFILEHANDLE; @@ -771,23 +761,10 @@ nfsrvd_compound(struct nfsrv_descript *n /* If vp == savevp, a no-op */ if (vp != savevp) { VREF(savevp); - if (mp == NULL || savemp == NULL) - panic("nfscmpmp"); - if (!savevpnes.nes_vfslocked && - vpnes.nes_vfslocked) { - if (mp == savemp) - panic("nfscmp2"); - nfsvno_unlockvfs(mp); - } else if (savevpnes.nes_vfslocked && - !vpnes.nes_vfslocked) { - if (mp == savemp) - panic("nfscmp3"); - savevpnes.nes_vfslocked = nfsvno_lockvfs(savemp); - } vrele(vp); vp = savevp; vpnes = savevpnes; - mp = savemp; + cur_fsid = save_fsid; } } else { nd->nd_repstat = NFSERR_RESTOREFH; @@ -841,11 +818,14 @@ nfsrvd_compound(struct nfsrv_descript *n error = (*(nfsrv4_ops1[op]))(nd, isdgram, vp, &nvp, (fhandle_t *)fh.nfsrvfh_data, p, &vpnes); if (!error && !nd->nd_repstat) { - if (vfs_statfs(mp)->f_fsid.val[0] != - vfs_statfs(vnode_mount(nvp))->f_fsid.val[0] || - vfs_statfs(mp)->f_fsid.val[1] != - vfs_statfs(vnode_mount(nvp))->f_fsid.val[1]) { - nd->nd_repstat = nfsvno_checkexp(vnode_mount(nvp), + if (op == NFSV4OP_LOOKUP || op == NFSV4OP_LOOKUPP) { + new_mp = nvp->v_mount; + if (cur_fsid.val[0] != + new_mp->mnt_stat.f_fsid.val[0] || + cur_fsid.val[1] != + new_mp->mnt_stat.f_fsid.val[1]) { + /* crossed a server mount point */ + nd->nd_repstat = nfsvno_checkexp(new_mp, nd->nd_nam, &nes, &credanon); if (!nd->nd_repstat) nd->nd_repstat = nfsd_excred(nd, @@ -853,17 +833,13 @@ nfsrvd_compound(struct nfsrv_descript *n if (credanon != NULL) crfree(credanon); if (!nd->nd_repstat) { - if (vpnes.nes_vfslocked) - nfsvno_unlockvfs(mp); - mp = vnode_mount(nvp); vpnes = nes; - vpnes.nes_vfslocked = - nfsvno_lockvfs(mp); + cur_fsid = new_mp->mnt_stat.f_fsid; } + } + /* Lookup ops return a locked vnode */ + VOP_UNLOCK(nvp, 0); } - if (op == NFSV4OP_LOOKUP || op == NFSV4OP_LOOKUPP) - /* Lookup ops return a locked vnode */ - VOP_UNLOCK(nvp, 0); if (!nd->nd_repstat) { vrele(vp); vp = nvp; @@ -876,7 +852,8 @@ nfsrvd_compound(struct nfsrv_descript *n if (vp == NULL || savevp == NULL) { nd->nd_repstat = NFSERR_NOFILEHANDLE; break; - } else if (mp != savemp) { + } else if (cur_fsid.val[0] != save_fsid.val[0] || + cur_fsid.val[1] != save_fsid.val[1]) { nd->nd_repstat = NFSERR_XDEV; break; } @@ -960,8 +937,6 @@ nfsmout: } else { *retopsp = txdr_unsigned(retops); } - if (mp && vpnes.nes_vfslocked) - nfsvno_unlockvfs(mp); if (vp) vrele(vp); if (savevp) From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 20:05:24 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9AB66106566C; Thu, 6 Jan 2011 20:05:24 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6F9C48FC12; Thu, 6 Jan 2011 20:05:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06K5O1f026818; Thu, 6 Jan 2011 20:05:24 GMT (envelope-from keramida@svn.freebsd.org) Received: (from keramida@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06K5ORU026814; Thu, 6 Jan 2011 20:05:24 GMT (envelope-from keramida@svn.freebsd.org) Message-Id: <201101062005.p06K5ORU026814@svn.freebsd.org> From: Giorgos Keramidas Date: Thu, 6 Jan 2011 20:05:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217064 - head/tools/regression/acct X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 20:05:24 -0000 Author: keramida (doc committer) Date: Thu Jan 6 20:05:24 2011 New Revision: 217064 URL: http://svn.freebsd.org/changeset/base/217064 Log: tests: sort & fix includes, remove -include from CFLAGS of acct tests - Sort the includes of pack.c, moving sys/*.h files near the top. - Add a couple of missing #include lines, and remove the need for custom -include options in the CFLAGS of the test Makefile. - Remove the ad-hoc 'all' target, but keep its 'regress' bits for testing. - Convert the ad-hoc 'clean' target to proper CLEANFILES stuff, so that the normal bsd.prog.mk machinery can clean up. - Use `make -V .OBJDIR' to detect the place where 'pack' lives, so that regress.t works both with and without 'make obj'. Reviewed by: uqs MFC after: 1 week Modified: head/tools/regression/acct/Makefile head/tools/regression/acct/pack.c head/tools/regression/acct/regress.t Modified: head/tools/regression/acct/Makefile ============================================================================== --- head/tools/regression/acct/Makefile Thu Jan 6 19:50:11 2011 (r217063) +++ head/tools/regression/acct/Makefile Thu Jan 6 20:05:24 2011 (r217064) @@ -1,26 +1,22 @@ # # $FreeBSD$ # -# "make" will compile what is needed and run the regression tests. +# "make" will compile the acct test programs # + PROG= pack +SRCS= pack.c NO_MAN= +CFLAGS+= -I${.OBJDIR} -CFLAGS= -include /usr/include/sys/limits.h \ - -include /usr/include/sys/syslog.h - -all: regress - -pack: pack.c convert.c +pack.o: convert.c +CLEANFILES+= convert.c convert.c: ../../../sys/kern/kern_acct.c sed -n -e 's/log(/syslog(/g' \ -e '/FLOAT_CONVERSION_START/,/FLOAT_CONVERSION_END/p' $? >$@ regress: pack regress.t - ./regress.t - -clean: - rm -f $(PROG) convert.c + ${.CURDIR}/regress.t .include Modified: head/tools/regression/acct/pack.c ============================================================================== --- head/tools/regression/acct/pack.c Thu Jan 6 19:50:11 2011 (r217063) +++ head/tools/regression/acct/pack.c Thu Jan 6 20:05:24 2011 (r217064) @@ -25,15 +25,18 @@ #include __FBSDID("$FreeBSD$"); +#include + #include #include +#include #include #include +#include #include #include - -#include -#include +#include +#include #define KASSERT(val, msg) assert(val) Modified: head/tools/regression/acct/regress.t ============================================================================== --- head/tools/regression/acct/regress.t Thu Jan 6 19:50:11 2011 (r217063) +++ head/tools/regression/acct/regress.t Thu Jan 6 20:05:24 2011 (r217064) @@ -3,7 +3,12 @@ # $FreeBSD$ # -DIR=`dirname $0` +if test -z "${DIR}" ; then + DIR=$( make -V .OBJDIR ) +fi +if test -z "${DIR}" ; then + DIR=$( dirname $0 ) +fi check() { From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 20:19:01 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D1A621065672; Thu, 6 Jan 2011 20:19:01 +0000 (UTC) (envelope-from andreast@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C08FF8FC16; Thu, 6 Jan 2011 20:19:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06KJ13h027199; Thu, 6 Jan 2011 20:19:01 GMT (envelope-from andreast@svn.freebsd.org) Received: (from andreast@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06KJ1Tn027192; Thu, 6 Jan 2011 20:19:01 GMT (envelope-from andreast@svn.freebsd.org) Message-Id: <201101062019.p06KJ1Tn027192@svn.freebsd.org> From: Andreas Tobler Date: Thu, 6 Jan 2011 20:19:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217065 - in head/sys/powerpc: aim cpufreq powermac X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 20:19:02 -0000 Author: andreast Date: Thu Jan 6 20:19:01 2011 New Revision: 217065 URL: http://svn.freebsd.org/changeset/base/217065 Log: Remove unused variables. Spotted by a cppcheck (devel/cppcheck, http://sourceforge.net/projects/cppcheck) run. Approved by: nwhitehorn (mentor) Modified: head/sys/powerpc/aim/nexus.c head/sys/powerpc/aim/vm_machdep.c head/sys/powerpc/cpufreq/dfs.c head/sys/powerpc/cpufreq/pcr.c head/sys/powerpc/powermac/macgpio.c head/sys/powerpc/powermac/uninorth.c Modified: head/sys/powerpc/aim/nexus.c ============================================================================== --- head/sys/powerpc/aim/nexus.c Thu Jan 6 20:05:24 2011 (r217064) +++ head/sys/powerpc/aim/nexus.c Thu Jan 6 20:19:01 2011 (r217065) @@ -340,7 +340,6 @@ static int nexus_setup_intr(device_t dev, device_t child, struct resource *res, int flags, driver_filter_t *filter, driver_intr_t *ihand, void *arg, void **cookiep) { - driver_t *driver; int error; /* somebody tried to setup an irq that failed to allocate! */ @@ -351,8 +350,6 @@ nexus_setup_intr(device_t dev, device_t if ((rman_get_flags(res) & RF_SHAREABLE) == 0) flags |= INTR_EXCL; - driver = device_get_driver(child); - /* * We depend here on rman_activate_resource() being idempotent. */ Modified: head/sys/powerpc/aim/vm_machdep.c ============================================================================== --- head/sys/powerpc/aim/vm_machdep.c Thu Jan 6 20:05:24 2011 (r217064) +++ head/sys/powerpc/aim/vm_machdep.c Thu Jan 6 20:19:01 2011 (r217065) @@ -143,7 +143,6 @@ extern uintptr_t tocbase; void cpu_fork(struct thread *td1, struct proc *p2, struct thread *td2, int flags) { - struct proc *p1; struct trapframe *tf; struct callframe *cf; struct pcb *pcb; @@ -156,8 +155,6 @@ cpu_fork(struct thread *td1, struct proc if ((flags & RFPROC) == 0) return; - p1 = td1->td_proc; - pcb = (struct pcb *)((td2->td_kstack + td2->td_kstack_pages * PAGE_SIZE - sizeof(struct pcb)) & ~0x2fUL); td2->td_pcb = pcb; Modified: head/sys/powerpc/cpufreq/dfs.c ============================================================================== --- head/sys/powerpc/cpufreq/dfs.c Thu Jan 6 20:05:24 2011 (r217064) +++ head/sys/powerpc/cpufreq/dfs.c Thu Jan 6 20:19:01 2011 (r217065) @@ -165,12 +165,10 @@ dfs_settings(device_t dev, struct cf_set static int dfs_set(device_t dev, const struct cf_setting *set) { - struct dfs_softc *sc; register_t hid1; if (set == NULL) return (EINVAL); - sc = device_get_softc(dev); hid1 = mfspr(SPR_HID1); hid1 &= ~(HID1_DFS2 | HID1_DFS4); Modified: head/sys/powerpc/cpufreq/pcr.c ============================================================================== --- head/sys/powerpc/cpufreq/pcr.c Thu Jan 6 20:05:24 2011 (r217064) +++ head/sys/powerpc/cpufreq/pcr.c Thu Jan 6 20:19:01 2011 (r217065) @@ -305,12 +305,10 @@ pcr_set(device_t dev, const struct cf_se static int pcr_get(device_t dev, struct cf_setting *set) { - struct pcr_softc *sc; uint64_t psr; if (set == NULL) return (EINVAL); - sc = device_get_softc(dev); memset(set, CPUFREQ_VAL_UNKNOWN, sizeof(*set)); Modified: head/sys/powerpc/powermac/macgpio.c ============================================================================== --- head/sys/powerpc/powermac/macgpio.c Thu Jan 6 20:05:24 2011 (r217064) +++ head/sys/powerpc/powermac/macgpio.c Thu Jan 6 20:19:01 2011 (r217065) @@ -264,10 +264,8 @@ static struct resource * macgpio_alloc_resource(device_t bus, device_t child, int type, int *rid, u_long start, u_long end, u_long count, u_int flags) { - struct macgpio_softc *sc; struct macgpio_devinfo *dinfo; - sc = device_get_softc(bus); dinfo = device_get_ivars(child); if (type != SYS_RES_IRQ) Modified: head/sys/powerpc/powermac/uninorth.c ============================================================================== --- head/sys/powerpc/powermac/uninorth.c Thu Jan 6 20:05:24 2011 (r217064) +++ head/sys/powerpc/powermac/uninorth.c Thu Jan 6 20:19:01 2011 (r217065) @@ -530,11 +530,8 @@ static int unin_chip_activate_resource(device_t bus, device_t child, int type, int rid, struct resource *res) { - struct unin_chip_softc *sc; void *p; - sc = device_get_softc(bus); - if (type == SYS_RES_IRQ) return (bus_activate_resource(bus, type, rid, res)); From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 20:31:33 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 85130106564A; Thu, 6 Jan 2011 20:31:33 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 743EE8FC12; Thu, 6 Jan 2011 20:31:33 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06KVXQk027509; Thu, 6 Jan 2011 20:31:33 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06KVXla027506; Thu, 6 Jan 2011 20:31:33 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <201101062031.p06KVXla027506@svn.freebsd.org> From: Rick Macklem Date: Thu, 6 Jan 2011 20:31:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217066 - in head/sys/fs: nfs nfsserver X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 20:31:33 -0000 Author: rmacklem Date: Thu Jan 6 20:31:33 2011 New Revision: 217066 URL: http://svn.freebsd.org/changeset/base/217066 Log: Delete the NFS_STARTWRITE() and NFS_ENDWRITE() macros that obscured vn_start_write() and vn_finished_write() for the old OpenBSD port, since most uses have been replaced by the correct calls. MFC after: 12 days Modified: head/sys/fs/nfs/nfsport.h head/sys/fs/nfsserver/nfs_nfsdstate.c Modified: head/sys/fs/nfs/nfsport.h ============================================================================== --- head/sys/fs/nfs/nfsport.h Thu Jan 6 20:19:01 2011 (r217065) +++ head/sys/fs/nfs/nfsport.h Thu Jan 6 20:31:33 2011 (r217066) @@ -596,13 +596,6 @@ int nfsmsleep(void *, void *, int, const #define MAX_COMMIT_COUNT (1024 * 1024) /* - * These macros are called at the start and end of operations that - * might modify the underlying file system. - */ -#define NFS_STARTWRITE(v, m) vn_start_write((v), (m), V_WAIT) -#define NFS_ENDWRITE(m) vn_finished_write(m) - -/* * Define these to handle the type of va_rdev. */ #define NFSMAKEDEV(m, n) makedev((m), (n)) Modified: head/sys/fs/nfsserver/nfs_nfsdstate.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdstate.c Thu Jan 6 20:19:01 2011 (r217065) +++ head/sys/fs/nfsserver/nfs_nfsdstate.c Thu Jan 6 20:31:33 2011 (r217066) @@ -4092,14 +4092,14 @@ nfsrv_updatestable(NFSPROC_T *p) NFSVNO_ATTRINIT(&nva); NFSVNO_SETATTRVAL(&nva, size, 0); vp = NFSFPVNODE(sf->nsf_fp); - NFS_STARTWRITE(vp, &mp); + vn_start_write(vp, &mp, V_WAIT); if (vn_lock(vp, LK_EXCLUSIVE) == 0) { error = nfsvno_setattr(vp, &nva, NFSFPCRED(sf->nsf_fp), p, NULL); VOP_UNLOCK(vp, 0); } else error = EPERM; - NFS_ENDWRITE(mp); + vn_finished_write(mp); if (!error) error = NFSD_RDWR(UIO_WRITE, vp, (caddr_t)&sf->nsf_rec, sizeof (struct nfsf_rec), (off_t)0, From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 20:41:57 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id C0AB51065673; Thu, 6 Jan 2011 20:41:57 +0000 (UTC) Date: Thu, 6 Jan 2011 20:41:57 +0000 From: Alexander Best To: Konstantin Belousov Message-ID: <20110106204157.GA41314@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101041413.p04EDA4f038360@svn.freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 20:41:57 -0000 On Tue Jan 4 11, Konstantin Belousov wrote: > Author: kib > Date: Tue Jan 4 14:13:09 2011 > New Revision: 216955 > URL: http://svn.freebsd.org/changeset/base/216955 > > Log: > Make the parsing of the integer arguments for rtprio(1)/idprio(1) stricter. > Style. > > Based on submission by: Eitan Adler , keramida > Reviewed by: jhb, keramida > MFC after: 1 week > > Modified: > head/usr.sbin/rtprio/rtprio.c > > Modified: head/usr.sbin/rtprio/rtprio.c > ============================================================================== > --- head/usr.sbin/rtprio/rtprio.c Tue Jan 4 13:16:28 2011 (r216954) > +++ head/usr.sbin/rtprio/rtprio.c Tue Jan 4 14:13:09 2011 (r216955) > @@ -37,31 +37,31 @@ __FBSDID("$FreeBSD$"); > > #include > #include > -#include > > #include > #include > +#include > #include > #include > #include > #include > > -static void usage(); > +static int parseint(const char *, const char *); > +static void usage(void); > > int > -main(argc, argv) > - int argc; > - char **argv; > +main(int argc, char *argv[]) > { > - char *p; > - int proc = 0; > struct rtprio rtp; > + char *p; > + pid_t proc; > > /* find basename */ > if ((p = rindex(argv[0], '/')) == NULL) > p = argv[0]; > else > ++p; > + proc = 0; > > if (!strcmp(p, "rtprio")) > rtp.type = RTP_PRIO_REALTIME; > @@ -70,12 +70,12 @@ main(argc, argv) > > switch (argc) { > case 2: > - proc = abs(atoi(argv[1])); /* Should check if numeric > - * arg! */ > + proc = parseint(argv[1], "pid"); > + proc = abs(proc); > /* FALLTHROUGH */ > case 1: > if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) > - err(1, "%s", argv[0]); > + err(1, "RTP_LOOKUP"); > printf("%s: ", p); > switch (rtp.type) { > case RTP_PRIO_REALTIME: > @@ -103,19 +103,17 @@ main(argc, argv) > usage(); > break; > } > - } else { > - rtp.prio = atoi(argv[1]); > - } > + } else > + rtp.prio = parseint(argv[1], "priority"); > } else { > usage(); > break; > } > > if (argv[2][0] == '-') > - proc = -atoi(argv[2]); > - > + proc = parseint(argv[2] + 1, "pid"); > if (rtprio(RTP_SET, proc, &rtp) != 0) > - err(1, "%s", argv[0]); > + err(1, "RTP_SET"); > > if (proc == 0) { this causes problems when pid is -0: [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via execvp(). beforehand however this will also trigger rtprio(). a better solution would be to do: if (argv[2][0] == '-') { proc = parseint(argv[2] + 1, "pid"); if (rtprio(RTP_SET, proc, &rtp) != 0) err(1, "RTP_SET"); } else { execvp(argv[2], &argv[2]); err(1, "%s", argv[2]); } cheers. alex > execvp(argv[2], &argv[2]); > @@ -123,12 +121,28 @@ main(argc, argv) > } > exit(0); > } > - exit (1); > + exit(1); > +} > + > +static int > +parseint(const char *str, const char *errname) > +{ > + char *endp; > + long res; > + > + errno = 0; > + res = strtol(str, &endp, 10); > + if (errno != 0 || endp == str || *endp != '\0') > + err(1, "%s must be a number", errname); > + if (res >= INT_MAX) > + err(1, "Integer overflow parsing %s", errname); > + return (res); > } > > static void > -usage() > +usage(void) > { > + > (void) fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n%s\n", > "usage: [id|rt]prio", > " [id|rt]prio [-]pid", -- a13x From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 20:50:17 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0923B106566C; Thu, 6 Jan 2011 20:50:17 +0000 (UTC) (envelope-from marcel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E951D8FC19; Thu, 6 Jan 2011 20:50:16 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06KoGDK027929; Thu, 6 Jan 2011 20:50:16 GMT (envelope-from marcel@svn.freebsd.org) Received: (from marcel@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06KoGcY027926; Thu, 6 Jan 2011 20:50:16 GMT (envelope-from marcel@svn.freebsd.org) Message-Id: <201101062050.p06KoGcY027926@svn.freebsd.org> From: Marcel Moolenaar Date: Thu, 6 Jan 2011 20:50:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217067 - head/sys/boot/efi/libefi X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 20:50:18 -0000 Author: marcel Date: Thu Jan 6 20:50:16 2011 New Revision: 217067 URL: http://svn.freebsd.org/changeset/base/217067 Log: Help static analysis by initializing variables that we know cannot be used uninitialized, but which cannot be inferred from the code itself. Modified: head/sys/boot/efi/libefi/efinet.c head/sys/boot/efi/libefi/efipart.c Modified: head/sys/boot/efi/libefi/efinet.c ============================================================================== --- head/sys/boot/efi/libefi/efinet.c Thu Jan 6 20:31:33 2011 (r217066) +++ head/sys/boot/efi/libefi/efinet.c Thu Jan 6 20:50:16 2011 (r217067) @@ -262,6 +262,7 @@ efinet_dev_init() int err, i, nifs; sz = 0; + handles = NULL; status = BS->LocateHandle(ByProtocol, &sn_guid, 0, &sz, 0); if (status == EFI_BUFFER_TOO_SMALL) { handles = (EFI_HANDLE *)malloc(sz); Modified: head/sys/boot/efi/libefi/efipart.c ============================================================================== --- head/sys/boot/efi/libefi/efipart.c Thu Jan 6 20:31:33 2011 (r217066) +++ head/sys/boot/efi/libefi/efipart.c Thu Jan 6 20:50:16 2011 (r217067) @@ -69,6 +69,7 @@ efipart_init(void) int err; sz = 0; + hin = NULL; status = BS->LocateHandle(ByProtocol, &blkio_guid, 0, &sz, 0); if (status == EFI_BUFFER_TOO_SMALL) { hin = (EFI_HANDLE *)malloc(sz * 2); From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:02:15 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1844F106566C; Thu, 6 Jan 2011 21:02:15 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0828D8FC18; Thu, 6 Jan 2011 21:02:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06L2E9o028215; Thu, 6 Jan 2011 21:02:14 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06L2Euw028213; Thu, 6 Jan 2011 21:02:14 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062102.p06L2Euw028213@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 21:02:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217068 - head/sys/dev/adlink X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:02:15 -0000 Author: jhb Date: Thu Jan 6 21:02:14 2011 New Revision: 217068 URL: http://svn.freebsd.org/changeset/base/217068 Log: Remove an unnecessary INTR_MPSAFE and a comment suggesting it was unnecessary. Modified: head/sys/dev/adlink/adlink.c Modified: head/sys/dev/adlink/adlink.c ============================================================================== --- head/sys/dev/adlink/adlink.c Thu Jan 6 20:50:16 2011 (r217067) +++ head/sys/dev/adlink/adlink.c Thu Jan 6 21:02:14 2011 (r217068) @@ -375,9 +375,7 @@ adlink_attach(device_t self) if (error) return (error); - /* XXX why do we need INTR_MPSAFE if INTR_FAST was declared too?!?!? */ - i = bus_setup_intr(self, sc->res[2], - INTR_MPSAFE | INTR_TYPE_MISC, + i = bus_setup_intr(self, sc->res[2], INTR_TYPE_MISC, adlink_intr, NULL, sc, &sc->intrhand); if (i) { printf("adlink: Couldn't get FAST intr\n"); From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:03:56 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BC0F9106564A; Thu, 6 Jan 2011 21:03:56 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 56AA18FC21; Thu, 6 Jan 2011 21:03:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06L3tOl028286; Thu, 6 Jan 2011 21:03:55 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06L3t8s028284; Thu, 6 Jan 2011 21:03:55 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062103.p06L3t8s028284@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 21:03:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217069 - head/sys/arm/mv X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:03:56 -0000 Author: jhb Date: Thu Jan 6 21:03:55 2011 New Revision: 217069 URL: http://svn.freebsd.org/changeset/base/217069 Log: - Add a proper return value to mv_gpio_intr(). - Remove an obsolete use of INTR_FAST. Modified: head/sys/arm/mv/gpio.c Modified: head/sys/arm/mv/gpio.c ============================================================================== --- head/sys/arm/mv/gpio.c Thu Jan 6 21:02:14 2011 (r217068) +++ head/sys/arm/mv/gpio.c Thu Jan 6 21:03:55 2011 (r217069) @@ -74,7 +74,7 @@ static uint32_t gpio_setup[MV_GPIO_MAX_N static int mv_gpio_probe(device_t); static int mv_gpio_attach(device_t); -static void mv_gpio_intr(void *); +static int mv_gpio_intr(void *); static void mv_gpio_intr_handler(int pin); static uint32_t mv_gpio_reg_read(uint32_t reg); @@ -193,8 +193,7 @@ mv_gpio_attach(device_t dev) for (i = 0; i < sc->irq_num; i++) { if (bus_setup_intr(dev, sc->res[1 + i], - INTR_TYPE_MISC | INTR_FAST, - (driver_filter_t *)mv_gpio_intr, NULL, + INTR_TYPE_MISC, mv_gpio_intr, NULL, sc, &sc->ih_cookie[i]) != 0) { bus_release_resources(dev, mv_gpio_res, sc->res); device_printf(dev, "could not set up intr %d\n", i); @@ -208,7 +207,7 @@ mv_gpio_attach(device_t dev) return (0); } -static void +static int mv_gpio_intr(void *arg) { uint32_t int_cause, gpio_val; @@ -241,6 +240,8 @@ mv_gpio_intr(void *arg) i++; } } + + return (FILTER_HANDLED); } /* From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:04:01 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1D9A21065780; Thu, 6 Jan 2011 21:04:01 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0D5068FC19; Thu, 6 Jan 2011 21:04:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06L40di028327; Thu, 6 Jan 2011 21:04:00 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06L40ft028324; Thu, 6 Jan 2011 21:04:00 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101062104.p06L40ft028324@svn.freebsd.org> From: Warner Losh Date: Thu, 6 Jan 2011 21:04:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217070 - in head/sys/modules: aha ahb X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:04:01 -0000 Author: imp Date: Thu Jan 6 21:04:00 2011 New Revision: 217070 URL: http://svn.freebsd.org/changeset/base/217070 Log: No need to genreate these here Modified: head/sys/modules/aha/Makefile head/sys/modules/ahb/Makefile Modified: head/sys/modules/aha/Makefile ============================================================================== --- head/sys/modules/aha/Makefile Thu Jan 6 21:03:55 2011 (r217069) +++ head/sys/modules/aha/Makefile Thu Jan 6 21:04:00 2011 (r217070) @@ -4,11 +4,6 @@ KMOD= aha SRCS= aha.c aha_isa.c ahareg.h opt_cam.h device_if.h bus_if.h \ - opt_scsi.h isa_if.h - -.if !defined(KERNBUILDDIR) -opt_scsi.h: - echo "#define SCSI_DELAY 15000" > ${.TARGET} -.endif + isa_if.h .include Modified: head/sys/modules/ahb/Makefile ============================================================================== --- head/sys/modules/ahb/Makefile Thu Jan 6 21:03:55 2011 (r217069) +++ head/sys/modules/ahb/Makefile Thu Jan 6 21:04:00 2011 (r217070) @@ -3,11 +3,6 @@ .PATH: ${.CURDIR}/../../dev/ahb KMOD= ahb -SRCS= ahb.c opt_cam.h device_if.h bus_if.h eisa_if.h opt_scsi.h - -.if !defined(KERNBUILDDIR) -opt_scsi.h: - echo "#define SCSI_DELAY 15000" > ${.TARGET} -.endif +SRCS= ahb.c opt_cam.h device_if.h bus_if.h eisa_if.h .include From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:07:51 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A50811065672; Thu, 6 Jan 2011 21:07:51 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 950418FC1E; Thu, 6 Jan 2011 21:07:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06L7p4k028442; Thu, 6 Jan 2011 21:07:51 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06L7p9o028440; Thu, 6 Jan 2011 21:07:51 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101062107.p06L7p9o028440@svn.freebsd.org> From: Warner Losh Date: Thu, 6 Jan 2011 21:07:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217071 - head/lib/bind X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:07:51 -0000 Author: imp Date: Thu Jan 6 21:07:51 2011 New Revision: 217071 URL: http://svn.freebsd.org/changeset/base/217071 Log: Make this work on big endian MIPS, while not breaking it for small endian mips. This will also make it work automatically on all future big endian platforms. Modified: head/lib/bind/config.mk Modified: head/lib/bind/config.mk ============================================================================== --- head/lib/bind/config.mk Thu Jan 6 21:04:00 2011 (r217070) +++ head/lib/bind/config.mk Thu Jan 6 21:07:51 2011 (r217071) @@ -1,6 +1,7 @@ # $FreeBSD$ .include +.include # BIND version number .if defined(BIND_DIR) && exists(${BIND_DIR}/version) @@ -45,7 +46,7 @@ CFLAGS+= -DOPENSSL CFLAGS+= -DUSE_MD5 # Endianness -.if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "sparc64" +.if ${TARGET_ENDIANNESS} == 4321 CFLAGS+= -DWORDS_BIGENDIAN .endif @@ -64,11 +65,7 @@ CFLAGS+= -I${LIB_BIND_DIR} .endif # Use the right version of the atomic.h file from lib/isc -.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" -ISC_ATOMIC_ARCH= x86_32 -.else -ISC_ATOMIC_ARCH= ${MACHINE_CPUARCH} -.endif +ISC_ATOMIC_ARCH=${MACHINE_CPUARCH:S/i386/x86_32/:S/amd64/x86_32/} # Optional features .if ${MK_BIND_LARGE_FILE} == "yes" @@ -121,4 +118,3 @@ CRYPTO_LDADD= -lcrypto PTHREAD_DPADD= ${LIBPTHREAD} PTHREAD_LDADD= -lpthread - From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:08:06 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B36981065670; Thu, 6 Jan 2011 21:08:06 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A0B3C8FC1B; Thu, 6 Jan 2011 21:08:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06L86Du028499; Thu, 6 Jan 2011 21:08:06 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06L86na028488; Thu, 6 Jan 2011 21:08:06 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062108.p06L86na028488@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 21:08:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217072 - in head/sys: arm/s3c2xx0 dev/usb/controller i386/xen mips/mips mips/rmi mips/rmi/dev/nlge mips/rmi/dev/xlr powerpc/powerpc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:08:06 -0000 Author: jhb Date: Thu Jan 6 21:08:06 2011 New Revision: 217072 URL: http://svn.freebsd.org/changeset/base/217072 Log: Remove bogus usage of INTR_FAST. "Fast" interrupts are now indicated by registering a filter handler rather than a threaded handler. Also remove a bogus use of INTR_MPSAFE for a filter. Modified: head/sys/arm/s3c2xx0/s3c24x0_clk.c head/sys/dev/usb/controller/ehci_mv.c head/sys/i386/xen/clock.c head/sys/i386/xen/mp_machdep.c head/sys/mips/mips/mp_machdep.c head/sys/mips/rmi/dev/nlge/if_nlge.c head/sys/mips/rmi/dev/xlr/rge.c head/sys/mips/rmi/fmn.c head/sys/powerpc/powerpc/intr_machdep.c Modified: head/sys/arm/s3c2xx0/s3c24x0_clk.c ============================================================================== --- head/sys/arm/s3c2xx0/s3c24x0_clk.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/arm/s3c2xx0/s3c24x0_clk.c Thu Jan 6 21:08:06 2011 (r217072) @@ -200,7 +200,7 @@ cpu_initclocks(void) if (!irq) panic("Unable to allocate the clock irq handler.\n"); - err = bus_setup_intr(dev, irq, INTR_TYPE_CLK | INTR_FAST, + err = bus_setup_intr(dev, irq, INTR_TYPE_CLK, clock_intr, NULL, NULL, &ihl); if (err != 0) panic("Unable to setup the clock irq handler.\n"); Modified: head/sys/dev/usb/controller/ehci_mv.c ============================================================================== --- head/sys/dev/usb/controller/ehci_mv.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/dev/usb/controller/ehci_mv.c Thu Jan 6 21:08:06 2011 (r217072) @@ -225,7 +225,7 @@ mv_ehci_attach(device_t self) sprintf(sc->sc_vendor, "Marvell"); - err = bus_setup_intr(self, irq_err, INTR_FAST | INTR_TYPE_BIO, + err = bus_setup_intr(self, irq_err, INTR_TYPE_BIO, err_intr, NULL, sc, &ih_err); if (err) { device_printf(self, "Could not setup error irq, %d\n", err); Modified: head/sys/i386/xen/clock.c ============================================================================== --- head/sys/i386/xen/clock.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/i386/xen/clock.c Thu Jan 6 21:08:06 2011 (r217072) @@ -777,7 +777,7 @@ cpu_initclocks(void) error = bind_virq_to_irqhandler(VIRQ_TIMER, 0, "clk", clkintr, NULL, NULL, - INTR_TYPE_CLK | INTR_FAST, &time_irq); + INTR_TYPE_CLK, &time_irq); if (error) panic("failed to register clock interrupt\n"); /* should fast clock be enabled ? */ @@ -796,7 +796,7 @@ ap_cpu_initclocks(int cpu) &xen_set_periodic_tick); error = bind_virq_to_irqhandler(VIRQ_TIMER, 0, "clk", clkintr, NULL, NULL, - INTR_TYPE_CLK | INTR_FAST, &time_irq); + INTR_TYPE_CLK, &time_irq); if (error) panic("failed to register clock interrupt\n"); Modified: head/sys/i386/xen/mp_machdep.c ============================================================================== --- head/sys/i386/xen/mp_machdep.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/i386/xen/mp_machdep.c Thu Jan 6 21:08:06 2011 (r217072) @@ -470,7 +470,7 @@ xen_smp_intr_init(unsigned int cpu) cpu, resched_name[cpu], smp_reschedule_interrupt, - INTR_FAST|INTR_TYPE_TTY|INTR_MPSAFE, &irq); + INTR_TYPE_TTY, &irq); printf("[XEN] IPI cpu=%d irq=%d vector=RESCHEDULE_VECTOR (%d)\n", cpu, irq, RESCHEDULE_VECTOR); @@ -482,7 +482,7 @@ xen_smp_intr_init(unsigned int cpu) cpu, callfunc_name[cpu], smp_call_function_interrupt, - INTR_FAST|INTR_TYPE_TTY|INTR_MPSAFE, &irq); + INTR_TYPE_TTY, &irq); if (rc < 0) goto fail; per_cpu(callfunc_irq, cpu) = irq; Modified: head/sys/mips/mips/mp_machdep.c ============================================================================== --- head/sys/mips/mips/mp_machdep.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/mips/mips/mp_machdep.c Thu Jan 6 21:08:06 2011 (r217072) @@ -333,7 +333,7 @@ release_aps(void *dummy __unused) */ ipi_irq = platform_ipi_intrnum(); cpu_establish_hardintr("ipi", mips_ipi_handler, NULL, NULL, ipi_irq, - INTR_TYPE_MISC | INTR_EXCL | INTR_FAST, NULL); + INTR_TYPE_MISC | INTR_EXCL, NULL); atomic_store_rel_int(&aps_ready, 1); Modified: head/sys/mips/rmi/dev/nlge/if_nlge.c ============================================================================== --- head/sys/mips/rmi/dev/nlge/if_nlge.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/mips/rmi/dev/nlge/if_nlge.c Thu Jan 6 21:08:06 2011 (r217072) @@ -1715,8 +1715,8 @@ nlge_irq_init(struct nlge_softc *sc) irq_num = block_info->baseirq + sc->instance; irq_res.__r_i = (struct resource_i *)(intptr_t) (irq_num); - ret = bus_setup_intr(sc->nlge_dev, &irq_res, (INTR_FAST | - INTR_TYPE_NET | INTR_MPSAFE), NULL, nlge_intr, sc, NULL); + ret = bus_setup_intr(sc->nlge_dev, &irq_res, + INTR_TYPE_NET | INTR_MPSAFE, NULL, nlge_intr, sc, NULL); if (ret) { nlge_detach(sc->nlge_dev); device_printf(sc->nlge_dev, "couldn't set up irq: error=%d\n", Modified: head/sys/mips/rmi/dev/xlr/rge.c ============================================================================== --- head/sys/mips/rmi/dev/xlr/rge.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/mips/rmi/dev/xlr/rge.c Thu Jan 6 21:08:06 2011 (r217072) @@ -1841,7 +1841,7 @@ rge_attach(device_t dev) */ sc->rge_irq.__r_i = (struct resource_i *)(intptr_t)sc->irq; - ret = bus_setup_intr(dev, &sc->rge_irq, INTR_FAST | INTR_TYPE_NET | INTR_MPSAFE, + ret = bus_setup_intr(dev, &sc->rge_irq, INTR_TYPE_NET | INTR_MPSAFE, NULL, rge_intr, sc, &sc->rge_intrhand); if (ret) { Modified: head/sys/mips/rmi/fmn.c ============================================================================== --- head/sys/mips/rmi/fmn.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/mips/rmi/fmn.c Thu Jan 6 21:08:06 2011 (r217072) @@ -437,7 +437,7 @@ register_msgring_handler(int startb, int msgring_maxthreads = xlr_threads_per_core; cpu_establish_hardintr("msgring", msgring_process_fast_intr, NULL, NULL, IRQ_MSGRING, - INTR_TYPE_NET | INTR_FAST, &cookie); + INTR_TYPE_NET, &cookie); } return (0); } Modified: head/sys/powerpc/powerpc/intr_machdep.c ============================================================================== --- head/sys/powerpc/powerpc/intr_machdep.c Thu Jan 6 21:07:51 2011 (r217071) +++ head/sys/powerpc/powerpc/intr_machdep.c Thu Jan 6 21:08:06 2011 (r217072) @@ -352,7 +352,7 @@ powerpc_enable_intr(void) error = powerpc_setup_intr("IPI", INTR_VEC(piclist[n].pic_id, piclist[n].ipi_irq), powerpc_ipi_handler, NULL, NULL, - INTR_TYPE_MISC | INTR_EXCL | INTR_FAST, &ipi_cookie); + INTR_TYPE_MISC | INTR_EXCL, &ipi_cookie); if (error) { printf("unable to setup IPI handler\n"); return (error); From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:08:40 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 716AB1065693; Thu, 6 Jan 2011 21:08:40 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-wy0-f182.google.com (mail-wy0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id ED0548FC17; Thu, 6 Jan 2011 21:08:38 +0000 (UTC) Received: by wyf19 with SMTP id 19so16952210wyf.13 for ; Thu, 06 Jan 2011 13:08:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=9LLJpGx5+6zDxkO9k+CP6wwQyotKtAQrk057zEkhc6c=; b=USZVr+xiI869nSrvYdM+qD4d4akuoBx4R525XA15mGm1Y32PA2FSgBPETDdX9yXlf/ Un/iPL9fUABhIYNQs27aL79k5dphzeoCJEMP+BHdO74MoQO6oFUzXWtbP2DNk/aX3YgP VU279VbiqpjPS16KtXIIGt7snjjwc/2uvMcEI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=GvC488wILUcwe3E6QqW1ml6hD+LXpCL/Im36TIiyjxeC0mvhG9tBLKJ2hRdof7+dL+ 69xxj7ge2kqC9kOMldtwMZjSmnsNmomYa4Qwi50uodMKdJ1uBzvnz+6WV39mYwIaVGgg 2QAp3hDohE/h7eXqUAa0MTySvdirX9iEIlSX0= MIME-Version: 1.0 Received: by 10.216.191.215 with SMTP id g65mr914071wen.16.1294348117726; Thu, 06 Jan 2011 13:08:37 -0800 (PST) Sender: yanegomi@gmail.com Received: by 10.216.254.226 with HTTP; Thu, 6 Jan 2011 13:08:37 -0800 (PST) In-Reply-To: <20110106204157.GA41314@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106204157.GA41314@freebsd.org> Date: Thu, 6 Jan 2011 13:08:37 -0800 X-Google-Sender-Auth: MtaY_-jVlvEYK9zCVFyIDPQYM0E Message-ID: From: Garrett Cooper To: Alexander Best Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:08:40 -0000 On Thu, Jan 6, 2011 at 12:41 PM, Alexander Best wrote= : ... > this causes problems when pid is -0: > > [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via execvp(). > beforehand however this will also trigger rtprio(). > > a better solution would be to do: > > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (argv[2][0] =3D=3D '-') { > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0proc =3D parseint(argv[2] = + 1, "pid"); > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (rtprio(RTP_SET, proc, = &rtp) !=3D 0) > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0err(1, "RT= P_SET"); > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} else { > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0execvp(argv[2], &argv[2]); > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0err(1, "%s= ", argv[2]); > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} How did you get a pid of -0? Thanks, -Garrett From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:09:22 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5897D106567A; Thu, 6 Jan 2011 21:09:22 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 48A948FC08; Thu, 6 Jan 2011 21:09:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06L9MTt028559; Thu, 6 Jan 2011 21:09:22 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06L9Mdg028557; Thu, 6 Jan 2011 21:09:22 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101062109.p06L9Mdg028557@svn.freebsd.org> From: Warner Losh Date: Thu, 6 Jan 2011 21:09:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217073 - head/etc/rc.d X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:09:22 -0000 Author: imp Date: Thu Jan 6 21:09:22 2011 New Revision: 217073 URL: http://svn.freebsd.org/changeset/base/217073 Log: Don't require /usr/lib/aout to be on the system. Test for its existance since we don't generally need it. MFC after: 1 week Modified: head/etc/rc.d/ldconfig Modified: head/etc/rc.d/ldconfig ============================================================================== --- head/etc/rc.d/ldconfig Thu Jan 6 21:08:06 2011 (r217072) +++ head/etc/rc.d/ldconfig Thu Jan 6 21:09:22 2011 (r217073) @@ -66,8 +66,8 @@ ldconfig_start() i386) # Default the a.out ldconfig path. : ${ldconfig_paths_aout=${ldconfig_paths}} - _LDC=/usr/lib/aout - for i in ${ldconfig_paths_aout} /etc/ld.so.conf; do + _LDC="" + for i in /usr/lib/aout ${ldconfig_paths_aout} /etc/ld.so.conf; do if [ -r "${i}" ]; then _LDC="${_LDC} ${i}" fi From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:10:17 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 3AFB6106566C; Thu, 6 Jan 2011 21:10:17 +0000 (UTC) Date: Thu, 6 Jan 2011 21:10:17 +0000 From: Alexander Best To: Garrett Cooper Message-ID: <20110106211017.GA46874@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106204157.GA41314@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:10:17 -0000 On Thu Jan 6 11, Garrett Cooper wrote: > On Thu, Jan 6, 2011 at 12:41 PM, Alexander Best wrote: > > ... > > > this causes problems when pid is -0: > > > > [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via execvp(). > > beforehand however this will also trigger rtprio(). > > > > a better solution would be to do: > > > >                if (argv[2][0] == '-') { > >                        proc = parseint(argv[2] + 1, "pid"); > >                        if (rtprio(RTP_SET, proc, &rtp) != 0) > >                                err(1, "RTP_SET"); > >                } else { > >                        execvp(argv[2], &argv[2]); > >                                err(1, "%s", argv[2]); > >                } > > How did you get a pid of -0? pid 0 stands for the current process. see rptio(2). cheers. alex > Thanks, > -Garrett -- a13x From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:13:34 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 348241065670; Thu, 6 Jan 2011 21:13:34 +0000 (UTC) Date: Thu, 6 Jan 2011 21:13:34 +0000 From: Alexander Best To: Konstantin Belousov Message-ID: <20110106211334.GA47424@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106204157.GA41314@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110106204157.GA41314@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:13:34 -0000 On Thu Jan 6 11, Alexander Best wrote: > On Tue Jan 4 11, Konstantin Belousov wrote: > > Author: kib > > Date: Tue Jan 4 14:13:09 2011 > > New Revision: 216955 > > URL: http://svn.freebsd.org/changeset/base/216955 > > > > Log: > > Make the parsing of the integer arguments for rtprio(1)/idprio(1) stricter. > > Style. > > > > Based on submission by: Eitan Adler , keramida > > Reviewed by: jhb, keramida > > MFC after: 1 week > > > > Modified: > > head/usr.sbin/rtprio/rtprio.c > > > > Modified: head/usr.sbin/rtprio/rtprio.c > > ============================================================================== > > --- head/usr.sbin/rtprio/rtprio.c Tue Jan 4 13:16:28 2011 (r216954) > > +++ head/usr.sbin/rtprio/rtprio.c Tue Jan 4 14:13:09 2011 (r216955) > > @@ -37,31 +37,31 @@ __FBSDID("$FreeBSD$"); > > > > #include > > #include > > -#include > > > > #include > > #include > > +#include > > #include > > #include > > #include > > #include > > > > -static void usage(); > > +static int parseint(const char *, const char *); > > +static void usage(void); > > > > int > > -main(argc, argv) > > - int argc; > > - char **argv; > > +main(int argc, char *argv[]) > > { > > - char *p; > > - int proc = 0; > > struct rtprio rtp; > > + char *p; > > + pid_t proc; > > > > /* find basename */ > > if ((p = rindex(argv[0], '/')) == NULL) > > p = argv[0]; > > else > > ++p; > > + proc = 0; > > > > if (!strcmp(p, "rtprio")) > > rtp.type = RTP_PRIO_REALTIME; > > @@ -70,12 +70,12 @@ main(argc, argv) > > > > switch (argc) { > > case 2: > > - proc = abs(atoi(argv[1])); /* Should check if numeric > > - * arg! */ > > + proc = parseint(argv[1], "pid"); > > + proc = abs(proc); > > /* FALLTHROUGH */ > > case 1: > > if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) > > - err(1, "%s", argv[0]); > > + err(1, "RTP_LOOKUP"); > > printf("%s: ", p); > > switch (rtp.type) { > > case RTP_PRIO_REALTIME: > > @@ -103,19 +103,17 @@ main(argc, argv) > > usage(); > > break; > > } > > - } else { > > - rtp.prio = atoi(argv[1]); > > - } > > + } else > > + rtp.prio = parseint(argv[1], "priority"); > > } else { > > usage(); > > break; > > } > > > > if (argv[2][0] == '-') > > - proc = -atoi(argv[2]); > > - > > + proc = parseint(argv[2] + 1, "pid"); > > if (rtprio(RTP_SET, proc, &rtp) != 0) > > - err(1, "%s", argv[0]); > > + err(1, "RTP_SET"); > > > > if (proc == 0) { > > this causes problems when pid is -0: > > [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via execvp(). > beforehand however this will also trigger rtprio(). > > a better solution would be to do: > > if (argv[2][0] == '-') { > proc = parseint(argv[2] + 1, "pid"); > if (rtprio(RTP_SET, proc, &rtp) != 0) > err(1, "RTP_SET"); > } else { > execvp(argv[2], &argv[2]); > err(1, "%s", argv[2]); > } ...better make that: if (argv[2][0] == '-') { proc = parseint(argv[2], "pid"); proc = abs(proc); if (rtprio(RTP_SET, proc, &rtp) != 0) err(1, "RTP_SET"); } else { execvp(argv[2], &argv[2]); err(1, "%s", argv[2]); } his prevents something like [id|rt]prio -t --1 to be actually passed over to rtprio(). cheers. alex > > cheers. > alex > > > execvp(argv[2], &argv[2]); > > @@ -123,12 +121,28 @@ main(argc, argv) > > } > > exit(0); > > } > > - exit (1); > > + exit(1); > > +} > > + > > +static int > > +parseint(const char *str, const char *errname) > > +{ > > + char *endp; > > + long res; > > + > > + errno = 0; > > + res = strtol(str, &endp, 10); > > + if (errno != 0 || endp == str || *endp != '\0') > > + err(1, "%s must be a number", errname); > > + if (res >= INT_MAX) > > + err(1, "Integer overflow parsing %s", errname); > > + return (res); > > } > > > > static void > > -usage() > > +usage(void) > > { > > + > > (void) fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n%s\n", > > "usage: [id|rt]prio", > > " [id|rt]prio [-]pid", > > -- > a13x -- a13x From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:14:16 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 528E4106566B; Thu, 6 Jan 2011 21:14:16 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-ww0-f50.google.com (mail-ww0-f50.google.com [74.125.82.50]) by mx1.freebsd.org (Postfix) with ESMTP id 3B2608FC18; Thu, 6 Jan 2011 21:14:14 +0000 (UTC) Received: by wwf26 with SMTP id 26so16576568wwf.31 for ; Thu, 06 Jan 2011 13:14:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=t3CI/ArDUGCv3dUZLxt9X/dwWDdvjQKeA/HwSXYQ3/E=; b=pihqUTXoj2WEDsAOcQqMBnb5d6pW16u0DaWdF5luqp2JhtymPLb2FIKMEI8rjS64x+ ZcQ3BfRfP4A26Gvt1Jvvu3XSdlc1SEYuVKAQBJ7ZJbCCSy6ceGNHRtRTO8RAPihkcJ7p vvTmDcyK3q7/Cl4vpRzQ2Bfd68fnl+g20/voc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=Zg0p5ZIUP8v5ken+SmHs967Ag+0bvgSfJhbSQmS9I0rDuDdZ9jUyy4FMTgyT8VGEmn xBGUAxJ+AmaRrRB/oQn80Ry68rYbBPChXgXTGRsnhLPAms0iGL3Y5GiQIPPg/1ggV/dA lpST7XHfsnmmOh/71tAKoEY6pfsqB6ANzgAJA= MIME-Version: 1.0 Received: by 10.216.185.142 with SMTP id u14mr902964wem.31.1294348454005; Thu, 06 Jan 2011 13:14:14 -0800 (PST) Sender: yanegomi@gmail.com Received: by 10.216.254.226 with HTTP; Thu, 6 Jan 2011 13:14:13 -0800 (PST) In-Reply-To: <20110106211017.GA46874@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106204157.GA41314@freebsd.org> <20110106211017.GA46874@freebsd.org> Date: Thu, 6 Jan 2011 13:14:13 -0800 X-Google-Sender-Auth: Kws_QjZw_DvJHpVTNX7tpOxMQQg Message-ID: From: Garrett Cooper To: Alexander Best Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:14:16 -0000 On Thu, Jan 6, 2011 at 1:10 PM, Alexander Best wrote: > On Thu Jan =A06 11, Garrett Cooper wrote: >> On Thu, Jan 6, 2011 at 12:41 PM, Alexander Best wr= ote: >> >> ... >> >> > this causes problems when pid is -0: >> > >> > [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via execvp= (). >> > beforehand however this will also trigger rtprio(). >> > >> > a better solution would be to do: >> > >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (argv[2][0] =3D=3D '-') { >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0proc =3D parseint(argv[= 2] + 1, "pid"); >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (rtprio(RTP_SET, pro= c, &rtp) !=3D 0) >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0err(1, = "RTP_SET"); >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} else { >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0execvp(argv[2], &argv[2= ]); >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0err(1, = "%s", argv[2]); >> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} >> >> How did you get a pid of -0? > > pid 0 stands for the current process. see rptio(2). Man, that's awesome syntax >.<. -Garrett From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:14:35 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 597441065695; Thu, 6 Jan 2011 21:14:35 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 488918FC19; Thu, 6 Jan 2011 21:14:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06LEZYN028724; Thu, 6 Jan 2011 21:14:35 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06LEZfs028718; Thu, 6 Jan 2011 21:14:35 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062114.p06LEZfs028718@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 21:14:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217074 - in head: share/man/man9 sys/sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:14:35 -0000 Author: jhb Date: Thu Jan 6 21:14:34 2011 New Revision: 217074 URL: http://svn.freebsd.org/changeset/base/217074 Log: Retire the INTR_FAST flag as it was obsoleted by the introduction of the filter argument to bus_setup_intr(). Modified: head/share/man/man9/BUS_SETUP_INTR.9 head/share/man/man9/ithread.9 head/share/man/man9/mutex.9 head/share/man/man9/swi.9 head/sys/sys/bus.h Modified: head/share/man/man9/BUS_SETUP_INTR.9 ============================================================================== --- head/share/man/man9/BUS_SETUP_INTR.9 Thu Jan 6 21:09:22 2011 (r217073) +++ head/share/man/man9/BUS_SETUP_INTR.9 Thu Jan 6 21:14:34 2011 (r217074) @@ -85,9 +85,8 @@ marks the interrupt as being a good sour this may be used by the entropy device .Pa /dev/random . .Pp -To define a time-critical handler (previously known as -.Dv INTR_FAST ) -that will not execute any potentially blocking operation, use the +To define a time-critical handler that will not execute any potentially +blocking operation, use the .Fa filter argument. See the @@ -128,10 +127,7 @@ will no longer be called. .Pp Mutexes are not allowed to be held across calls to these functions. .Ss "Filter Routines" -A filter runs in a context very similar to what was known as an -.Dv INTR_FAST -routine in previous versions of -.Fx . +A filter runs in primary interrupt context. In this context, normal mutexes cannot be used. Only the spin lock version of these can be used (specified by passing .Dv MTX_SPIN Modified: head/share/man/man9/ithread.9 ============================================================================== --- head/share/man/man9/ithread.9 Thu Jan 6 21:09:22 2011 (r217073) +++ head/share/man/man9/ithread.9 Thu Jan 6 21:14:34 2011 (r217074) @@ -180,15 +180,6 @@ The flag specifies that this handler cannot share an interrupt thread with another handler. The -.Dv INTR_FAST -flag specifies that when this handler is executed, it should be run immediately -rather than being run asynchronously when its interrupt thread is scheduled to -run. -The -.Dv INTR_FAST -flag implies -.Dv INTR_EXCL . -The .Dv INTR_MPSAFE flag specifies that this handler is MP safe in that it does not need the Giant mutex to be held while it is executed. @@ -198,10 +189,8 @@ flag specifies that the interrupt source source of entropy, and thus that entropy should be gathered when an interrupt from the handler's source triggers. Presently, the -.Dv INTR_FAST -and .Dv INTR_ENTROPY -flags are not valid for software interrupt handlers. +flag is not valid for software interrupt handlers. .Pp It is not permitted to sleep in an interrupt thread; hence, any memory or zone allocations in an interrupt thread should be specified with the @@ -237,7 +226,7 @@ swi_add(struct ithd **ithdp, const char struct ithd *ithd; int error; - if (flags & (INTR_FAST | INTR_ENTROPY)) + if (flags & INTR_ENTROPY) return (EINVAL); ithd = (ithdp != NULL) ? *ithdp : NULL; Modified: head/share/man/man9/mutex.9 ============================================================================== --- head/share/man/man9/mutex.9 Thu Jan 6 21:09:22 2011 (r217073) +++ head/share/man/man9/mutex.9 Thu Jan 6 21:14:34 2011 (r217074) @@ -128,9 +128,7 @@ Mutexes which do not context switch are mutexes. These should only be used to protect data shared with primary interrupt code. -This includes -.Dv INTR_FAST -interrupt handlers and low level scheduling code. +This includes interrupt filters and low level scheduling code. In all architectures both acquiring and releasing of a uncontested spin mutex is more expensive than the same operation on a non-spin mutex. Modified: head/share/man/man9/swi.9 ============================================================================== --- head/share/man/man9/swi.9 Thu Jan 6 21:09:22 2011 (r217073) +++ head/share/man/man9/swi.9 Thu Jan 6 21:14:34 2011 (r217074) @@ -179,10 +179,8 @@ MIB variable .It Bq Er EINVAL The .Fa flags -argument specifies either -.Dv INTR_ENTROPY -or -.Dv INTR_FAST . +argument specifies +.Dv INTR_ENTROPY . .It Bq Er EINVAL The .Fa ithdp Modified: head/sys/sys/bus.h ============================================================================== --- head/sys/sys/bus.h Thu Jan 6 21:09:22 2011 (r217073) +++ head/sys/sys/bus.h Thu Jan 6 21:14:34 2011 (r217074) @@ -191,7 +191,6 @@ enum intr_type { INTR_TYPE_MISC = 16, INTR_TYPE_CLK = 32, INTR_TYPE_AV = 64, - INTR_FAST = 128, INTR_EXCL = 256, /* exclusive interrupt */ INTR_MPSAFE = 512, /* this interrupt is SMP safe */ INTR_ENTROPY = 1024, /* this interrupt provides entropy */ From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:14:43 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id CAC8A106576E; Thu, 6 Jan 2011 21:14:43 +0000 (UTC) Date: Thu, 6 Jan 2011 21:14:43 +0000 From: Alexander Best To: Garrett Cooper Message-ID: <20110106211443.GA48244@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106204157.GA41314@freebsd.org> <20110106211017.GA46874@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20110106211017.GA46874@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:14:43 -0000 On Thu Jan 6 11, Alexander Best wrote: > On Thu Jan 6 11, Garrett Cooper wrote: > > On Thu, Jan 6, 2011 at 12:41 PM, Alexander Best wrote: > > > > ... > > > > > this causes problems when pid is -0: > > > > > > [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via execvp(). > > > beforehand however this will also trigger rtprio(). > > > > > > a better solution would be to do: > > > > > >                if (argv[2][0] == '-') { > > >                        proc = parseint(argv[2] + 1, "pid"); > > >                        if (rtprio(RTP_SET, proc, &rtp) != 0) > > >                                err(1, "RTP_SET"); > > >                } else { > > >                        execvp(argv[2], &argv[2]); > > >                                err(1, "%s", argv[2]); > > >                } > > > > How did you get a pid of -0? > > pid 0 stands for the current process. see rptio(2). rtprio(2) that is. ;) > > cheers. > alex > > > Thanks, > > -Garrett > > -- > a13x -- a13x From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:27:07 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1D507106566C; Thu, 6 Jan 2011 21:27:07 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id E2FCF8FC12; Thu, 6 Jan 2011 21:27:06 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id A63CF46B3B; Thu, 6 Jan 2011 16:27:06 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id AE96F8A009; Thu, 6 Jan 2011 16:27:05 -0500 (EST) From: John Baldwin To: Alexander Best Date: Thu, 6 Jan 2011 16:18:39 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106211017.GA46874@freebsd.org> In-Reply-To: <20110106211017.GA46874@freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <201101061618.39695.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Thu, 06 Jan 2011 16:27:05 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov , Garrett Cooper Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:27:07 -0000 On Thursday, January 06, 2011 4:10:17 pm Alexander Best wrote: > On Thu Jan 6 11, Garrett Cooper wrote: > > On Thu, Jan 6, 2011 at 12:41 PM, Alexander Best wrote: > > > > ... > > > > > this causes problems when pid is -0: > > > > > > [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via execvp(). > > > beforehand however this will also trigger rtprio(). > > > > > > a better solution would be to do: > > > > > > if (argv[2][0] == '-') { > > > proc = parseint(argv[2] + 1, "pid"); > > > if (rtprio(RTP_SET, proc, &rtp) != 0) > > > err(1, "RTP_SET"); > > > } else { > > > execvp(argv[2], &argv[2]); > > > err(1, "%s", argv[2]); > > > } > > > > How did you get a pid of -0? > > pid 0 stands for the current process. see rptio(2). Note that that usage is rather pointless since it means you apply rtprio to the 'rtprio' process that is about to exit. :) -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:27:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6E388106564A; Thu, 6 Jan 2011 21:27:08 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 419B18FC13; Thu, 6 Jan 2011 21:27:08 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 027B146B4C; Thu, 6 Jan 2011 16:27:08 -0500 (EST) Received: from jhbbsd.localnet (smtp.hudson-trading.com [209.249.190.9]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 28CCC8A01D; Thu, 6 Jan 2011 16:27:07 -0500 (EST) From: John Baldwin To: Warner Losh Date: Thu, 6 Jan 2011 16:20:31 -0500 User-Agent: KMail/1.13.5 (FreeBSD/7.3-CBSD-20101102; KDE/4.4.5; amd64; ; ) References: <201101062104.p06L40ft028324@svn.freebsd.org> In-Reply-To: <201101062104.p06L40ft028324@svn.freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201101061620.31477.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Thu, 06 Jan 2011 16:27:07 -0500 (EST) X-Virus-Scanned: clamav-milter 0.96.3 at bigwig.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-1.9 required=4.2 tests=BAYES_00 autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bigwig.baldwin.cx Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217070 - in head/sys/modules: aha ahb X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:27:08 -0000 On Thursday, January 06, 2011 4:04:00 pm Warner Losh wrote: > Author: imp > Date: Thu Jan 6 21:04:00 2011 > New Revision: 217070 > URL: http://svn.freebsd.org/changeset/base/217070 > > Log: > No need to genreate these here I think this changes the SCSI_DELAY these modules are effectively built with when built standalone since the default value in the header is 2000. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:42:43 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 2F4431065672; Thu, 6 Jan 2011 21:42:43 +0000 (UTC) Date: Thu, 6 Jan 2011 21:42:43 +0000 From: Alexander Best To: John Baldwin Message-ID: <20110106214243.GA51802@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106211017.GA46874@freebsd.org> <201101061618.39695.jhb@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101061618.39695.jhb@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Konstantin Belousov , Garrett Cooper Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:42:43 -0000 On Thu Jan 6 11, John Baldwin wrote: > On Thursday, January 06, 2011 4:10:17 pm Alexander Best wrote: > > On Thu Jan 6 11, Garrett Cooper wrote: > > > On Thu, Jan 6, 2011 at 12:41 PM, Alexander Best > wrote: > > > > > > ... > > > > > > > this causes problems when pid is -0: > > > > > > > > [id|rt]prio -t -0 and [id|rt]prio 10 -0 will try to run "0" via > execvp(). > > > > beforehand however this will also trigger rtprio(). > > > > > > > > a better solution would be to do: > > > > > > > > if (argv[2][0] == '-') { > > > > proc = parseint(argv[2] + 1, "pid"); > > > > if (rtprio(RTP_SET, proc, &rtp) != 0) > > > > err(1, "RTP_SET"); > > > > } else { > > > > execvp(argv[2], &argv[2]); > > > > err(1, "%s", argv[2]); > > > > } > > > > > > How did you get a pid of -0? > > > > pid 0 stands for the current process. see rptio(2). > > Note that that usage is rather pointless since it means you apply rtprio to > the 'rtprio' process that is about to exit. :) yeah but at least it makes the usage of -X consistent. ;) also consider the following: the current shell has idle priority and you want to run rtprio in normal priority. then rtprio -t -0 would be a neat way of doing rtprio -t rtprio. ;) wel...not quite, because the priotity gets set to "NORMAL" when rtprio is almost finished running. ;) i admit using -0 for setting rtpio's own priority isn't very useful, but the rtprio(1) manual states: Pid of 0 means "the current process". ...so it better work. ;) cheers. alex > > -- > John Baldwin -- a13x From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:49:47 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 993F71065672; Thu, 6 Jan 2011 21:49:47 +0000 (UTC) Date: Thu, 6 Jan 2011 21:49:47 +0000 From: Alexander Best To: Konstantin Belousov Message-ID: <20110106214947.GA53760@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="3V7upXqbjpZ4EhLz" Content-Disposition: inline In-Reply-To: <201101041413.p04EDA4f038360@svn.freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:49:47 -0000 --3V7upXqbjpZ4EhLz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue Jan 4 11, Konstantin Belousov wrote: > Author: kib > Date: Tue Jan 4 14:13:09 2011 > New Revision: 216955 > URL: http://svn.freebsd.org/changeset/base/216955 > > Log: > Make the parsing of the integer arguments for rtprio(1)/idprio(1) stricter. > Style. here's a patch with some changes. you might want to cherry pick from it. ;) cheers. alex > > Based on submission by: Eitan Adler , keramida > Reviewed by: jhb, keramida > MFC after: 1 week > > Modified: > head/usr.sbin/rtprio/rtprio.c > > Modified: head/usr.sbin/rtprio/rtprio.c > ============================================================================== > --- head/usr.sbin/rtprio/rtprio.c Tue Jan 4 13:16:28 2011 (r216954) > +++ head/usr.sbin/rtprio/rtprio.c Tue Jan 4 14:13:09 2011 (r216955) > @@ -37,31 +37,31 @@ __FBSDID("$FreeBSD$"); > > #include > #include > -#include > > #include > #include > +#include > #include > #include > #include > #include > > -static void usage(); > +static int parseint(const char *, const char *); > +static void usage(void); > > int > -main(argc, argv) > - int argc; > - char **argv; > +main(int argc, char *argv[]) > { > - char *p; > - int proc = 0; > struct rtprio rtp; > + char *p; > + pid_t proc; > > /* find basename */ > if ((p = rindex(argv[0], '/')) == NULL) > p = argv[0]; > else > ++p; > + proc = 0; > > if (!strcmp(p, "rtprio")) > rtp.type = RTP_PRIO_REALTIME; > @@ -70,12 +70,12 @@ main(argc, argv) > > switch (argc) { > case 2: > - proc = abs(atoi(argv[1])); /* Should check if numeric > - * arg! */ > + proc = parseint(argv[1], "pid"); > + proc = abs(proc); > /* FALLTHROUGH */ > case 1: > if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) > - err(1, "%s", argv[0]); > + err(1, "RTP_LOOKUP"); > printf("%s: ", p); > switch (rtp.type) { > case RTP_PRIO_REALTIME: > @@ -103,19 +103,17 @@ main(argc, argv) > usage(); > break; > } > - } else { > - rtp.prio = atoi(argv[1]); > - } > + } else > + rtp.prio = parseint(argv[1], "priority"); > } else { > usage(); > break; > } > > if (argv[2][0] == '-') > - proc = -atoi(argv[2]); > - > + proc = parseint(argv[2] + 1, "pid"); > if (rtprio(RTP_SET, proc, &rtp) != 0) > - err(1, "%s", argv[0]); > + err(1, "RTP_SET"); > > if (proc == 0) { > execvp(argv[2], &argv[2]); > @@ -123,12 +121,28 @@ main(argc, argv) > } > exit(0); > } > - exit (1); > + exit(1); > +} > + > +static int > +parseint(const char *str, const char *errname) > +{ > + char *endp; > + long res; > + > + errno = 0; > + res = strtol(str, &endp, 10); > + if (errno != 0 || endp == str || *endp != '\0') > + err(1, "%s must be a number", errname); > + if (res >= INT_MAX) > + err(1, "Integer overflow parsing %s", errname); > + return (res); > } > > static void > -usage() > +usage(void) > { > + > (void) fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n%s\n", > "usage: [id|rt]prio", > " [id|rt]prio [-]pid", -- a13x --3V7upXqbjpZ4EhLz Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="rtprio.diff3" diff --git a/usr.sbin/rtprio/rtprio.c b/usr.sbin/rtprio/rtprio.c index 38dade8..e28eee8 100644 --- a/usr.sbin/rtprio/rtprio.c +++ b/usr.sbin/rtprio/rtprio.c @@ -67,6 +67,8 @@ main(int argc, char *argv[]) rtp.type = RTP_PRIO_REALTIME; else if (!strcmp(p, "idprio")) rtp.type = RTP_PRIO_IDLE; + else + errx(1, "invalid basename"); switch (argc) { case 2: @@ -76,20 +78,19 @@ main(int argc, char *argv[]) case 1: if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) err(1, "RTP_LOOKUP"); - printf("%s: ", p); switch (rtp.type) { case RTP_PRIO_REALTIME: case RTP_PRIO_FIFO: - printf("realtime priority %d\n", rtp.prio); + warnx("realtime priority %d", rtp.prio); break; case RTP_PRIO_NORMAL: - printf("normal priority\n"); + warnx("normal priority"); break; case RTP_PRIO_IDLE: - printf("idle priority %d\n", rtp.prio); + warnx("idle priority %d", rtp.prio); break; default: - printf("invalid priority type %d\n", rtp.type); + errx(1, "invalid priority type %d", rtp.type); break; } exit(0); @@ -110,18 +111,17 @@ main(int argc, char *argv[]) break; } - if (argv[2][0] == '-') - proc = parseint(argv[2] + 1, "pid"); - if (rtprio(RTP_SET, proc, &rtp) != 0) - err(1, "RTP_SET"); - - if (proc == 0) { + if (argv[2][0] == '-') { + proc = parseint(argv[2], "pid"); + proc = abs(proc); + if (rtprio(RTP_SET, proc, &rtp) != 0) + err(1, "RTP_SET"); + } else { execvp(argv[2], &argv[2]); - err(1, "%s", argv[2]); + err(1, "%s", argv[2]); } exit(0); } - exit(1); } static int --3V7upXqbjpZ4EhLz-- From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 21:52:27 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9490C106567A; Thu, 6 Jan 2011 21:52:27 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 555D78FC14; Thu, 6 Jan 2011 21:52:27 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p06LhNP8035222; Thu, 6 Jan 2011 14:43:23 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D263779.7040803@bsdimp.com> Date: Thu, 06 Jan 2011 14:43:21 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: John Baldwin References: <201101062104.p06L40ft028324@svn.freebsd.org> <201101061620.31477.jhb@freebsd.org> In-Reply-To: <201101061620.31477.jhb@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Warner Losh Subject: Re: svn commit: r217070 - in head/sys/modules: aha ahb X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 21:52:27 -0000 On 01/06/2011 14:20, John Baldwin wrote: > On Thursday, January 06, 2011 4:04:00 pm Warner Losh wrote: >> Author: imp >> Date: Thu Jan 6 21:04:00 2011 >> New Revision: 217070 >> URL: http://svn.freebsd.org/changeset/base/217070 >> >> Log: >> No need to genreate these here > I think this changes the SCSI_DELAY these modules are effectively built with > when built standalone since the default value in the header is 2000 % cd sys/dev/aha % grep SCSI_DELAY * % cd ../ahb % grep SCSI_DELAY * % They aren't referenced, so there's no need to generate them at all. Warner From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:02:22 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id CAE15106566B; Thu, 6 Jan 2011 22:02:22 +0000 (UTC) Date: Thu, 6 Jan 2011 22:02:22 +0000 From: Alexander Best To: Dimitry Andric Message-ID: <20110106220222.GA54092@freebsd.org> References: <201101052224.p05MOXQs093175@svn.freebsd.org> <4D258E91.2040403@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D258E91.2040403@FreeBSD.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Ivan Voras Subject: Re: svn commit: r217033 - in head: lib/libstand sys/boot/ficl sys/boot/i386 sys/boot/pc98 sys/boot/zfs sys/conf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:02:22 -0000 On Thu Jan 6 11, Dimitry Andric wrote: > On 2011-01-06 00:14, Ivan Voras wrote: > >> -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float > >I'm late to the party - but is there any hope of centralizing these > >and then doing something like "CFLAGS += ${CC_NO_FP}" ? > > Yeah, that is the next step. First I wanted to get all the flags the > same. > > Btw, this is not only about "no floating point", as SSE instructions can > be used for other things (memset, memcpy, etc) too. So "NO_FP" is > misleading in my opinion, but it seems to be what most people want. any suggestions? how about ${NO_CPU_EXT}? also i was think...if we add something like this to sys/conf/kern.mk: ${NO_CPU_EXT}+= -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -msoft-float .if ${CC:T:Mclang} == "clang" ${NO_CPU_EXT}+= -mno_sse4 -mno_sse4_1 -mno_sse4_2 -mno_sse4a -mno_ssse3 \ -mno_aes -mno_avx .endif ...will this be evaluated once or dynamically? because there are places in base where gcc gets always used no matter what's in src.conf (bootblocks e.g.). in those case we don't want to send all the new -mno-* flags to gcc, do we. cheers. alex > > > >As soon as we > >get a newer compiler someone will have to add -mno-sse4 to the list > >(if not already with clang...). > > For clang, we should add the following, if we want to be very cautious: > > -mno_aes -mno_avx -mno_sse4 -mno_sse4_1 -mno_sse4_2 -mno_sse4a -mno_ssse3 -- a13x From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:09:37 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C5040106566C; Thu, 6 Jan 2011 22:09:37 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B487A8FC15; Thu, 6 Jan 2011 22:09:37 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06M9bsg029920; Thu, 6 Jan 2011 22:09:37 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06M9bCV029917; Thu, 6 Jan 2011 22:09:37 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062209.p06M9bCV029917@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 22:09:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217075 - in head/sys: kern sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:09:37 -0000 Author: jhb Date: Thu Jan 6 22:09:37 2011 New Revision: 217075 URL: http://svn.freebsd.org/changeset/base/217075 Log: Retire PCONFIG and leave the priority of thread0 alone when waiting for interrupt config hooks to execute. Modified: head/sys/kern/subr_autoconf.c head/sys/sys/priority.h Modified: head/sys/kern/subr_autoconf.c ============================================================================== --- head/sys/kern/subr_autoconf.c Thu Jan 6 21:14:34 2011 (r217074) +++ head/sys/kern/subr_autoconf.c Thu Jan 6 22:09:37 2011 (r217075) @@ -135,7 +135,7 @@ boot_run_interrupt_driven_config_hooks(v warned = 0; while (!TAILQ_EMPTY(&intr_config_hook_list)) { if (msleep(&intr_config_hook_list, &intr_config_hook_lock, - PCONFIG, "conifhk", WARNING_INTERVAL_SECS * hz) == + 0, "conifhk", WARNING_INTERVAL_SECS * hz) == EWOULDBLOCK) { mtx_unlock(&intr_config_hook_lock); warned++; Modified: head/sys/sys/priority.h ============================================================================== --- head/sys/sys/priority.h Thu Jan 6 21:14:34 2011 (r217074) +++ head/sys/sys/priority.h Thu Jan 6 22:09:37 2011 (r217075) @@ -105,9 +105,8 @@ #define PZERO (PRI_MIN_KERN + 20) #define PSOCK (PRI_MIN_KERN + 24) #define PWAIT (PRI_MIN_KERN + 28) -#define PCONFIG (PRI_MIN_KERN + 32) -#define PLOCK (PRI_MIN_KERN + 36) -#define PPAUSE (PRI_MIN_KERN + 40) +#define PLOCK (PRI_MIN_KERN + 32) +#define PPAUSE (PRI_MIN_KERN + 36) #define PRI_MIN_REALTIME (128) #define PRI_MAX_REALTIME (PRI_MIN_TIMESHARE - 1) From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:11:09 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 542231065675; Thu, 6 Jan 2011 22:11:09 +0000 (UTC) Date: Thu, 6 Jan 2011 22:11:09 +0000 From: Alexander Best To: Konstantin Belousov Message-ID: <20110106221109.GA57588@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106214947.GA53760@freebsd.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="FL5UXtIhxfXey3p5" Content-Disposition: inline In-Reply-To: <20110106214947.GA53760@freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:11:09 -0000 --FL5UXtIhxfXey3p5 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu Jan 6 11, Alexander Best wrote: > On Tue Jan 4 11, Konstantin Belousov wrote: > > Author: kib > > Date: Tue Jan 4 14:13:09 2011 > > New Revision: 216955 > > URL: http://svn.freebsd.org/changeset/base/216955 > > > > Log: > > Make the parsing of the integer arguments for rtprio(1)/idprio(1) stricter. > > Style. > > here's a patch with some changes. you might want to cherry pick from it. ;) fixed a whitespace issue. thanks to gcooper@. > > cheers. > alex > > > > > Based on submission by: Eitan Adler , keramida > > Reviewed by: jhb, keramida > > MFC after: 1 week > > > > Modified: > > head/usr.sbin/rtprio/rtprio.c > > > > Modified: head/usr.sbin/rtprio/rtprio.c > > ============================================================================== > > --- head/usr.sbin/rtprio/rtprio.c Tue Jan 4 13:16:28 2011 (r216954) > > +++ head/usr.sbin/rtprio/rtprio.c Tue Jan 4 14:13:09 2011 (r216955) > > @@ -37,31 +37,31 @@ __FBSDID("$FreeBSD$"); > > > > #include > > #include > > -#include > > > > #include > > #include > > +#include > > #include > > #include > > #include > > #include > > > > -static void usage(); > > +static int parseint(const char *, const char *); > > +static void usage(void); > > > > int > > -main(argc, argv) > > - int argc; > > - char **argv; > > +main(int argc, char *argv[]) > > { > > - char *p; > > - int proc = 0; > > struct rtprio rtp; > > + char *p; > > + pid_t proc; > > > > /* find basename */ > > if ((p = rindex(argv[0], '/')) == NULL) > > p = argv[0]; > > else > > ++p; > > + proc = 0; > > > > if (!strcmp(p, "rtprio")) > > rtp.type = RTP_PRIO_REALTIME; > > @@ -70,12 +70,12 @@ main(argc, argv) > > > > switch (argc) { > > case 2: > > - proc = abs(atoi(argv[1])); /* Should check if numeric > > - * arg! */ > > + proc = parseint(argv[1], "pid"); > > + proc = abs(proc); > > /* FALLTHROUGH */ > > case 1: > > if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) > > - err(1, "%s", argv[0]); > > + err(1, "RTP_LOOKUP"); > > printf("%s: ", p); > > switch (rtp.type) { > > case RTP_PRIO_REALTIME: > > @@ -103,19 +103,17 @@ main(argc, argv) > > usage(); > > break; > > } > > - } else { > > - rtp.prio = atoi(argv[1]); > > - } > > + } else > > + rtp.prio = parseint(argv[1], "priority"); > > } else { > > usage(); > > break; > > } > > > > if (argv[2][0] == '-') > > - proc = -atoi(argv[2]); > > - > > + proc = parseint(argv[2] + 1, "pid"); > > if (rtprio(RTP_SET, proc, &rtp) != 0) > > - err(1, "%s", argv[0]); > > + err(1, "RTP_SET"); > > > > if (proc == 0) { > > execvp(argv[2], &argv[2]); > > @@ -123,12 +121,28 @@ main(argc, argv) > > } > > exit(0); > > } > > - exit (1); > > + exit(1); > > +} > > + > > +static int > > +parseint(const char *str, const char *errname) > > +{ > > + char *endp; > > + long res; > > + > > + errno = 0; > > + res = strtol(str, &endp, 10); > > + if (errno != 0 || endp == str || *endp != '\0') > > + err(1, "%s must be a number", errname); > > + if (res >= INT_MAX) > > + err(1, "Integer overflow parsing %s", errname); > > + return (res); > > } > > > > static void > > -usage() > > +usage(void) > > { > > + > > (void) fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n%s\n", > > "usage: [id|rt]prio", > > " [id|rt]prio [-]pid", > > -- > a13x > diff --git a/usr.sbin/rtprio/rtprio.c b/usr.sbin/rtprio/rtprio.c > index 38dade8..e28eee8 100644 > --- a/usr.sbin/rtprio/rtprio.c > +++ b/usr.sbin/rtprio/rtprio.c > @@ -67,6 +67,8 @@ main(int argc, char *argv[]) > rtp.type = RTP_PRIO_REALTIME; > else if (!strcmp(p, "idprio")) > rtp.type = RTP_PRIO_IDLE; > + else > + errx(1, "invalid basename"); > > switch (argc) { > case 2: > @@ -76,20 +78,19 @@ main(int argc, char *argv[]) > case 1: > if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) > err(1, "RTP_LOOKUP"); > - printf("%s: ", p); > switch (rtp.type) { > case RTP_PRIO_REALTIME: > case RTP_PRIO_FIFO: > - printf("realtime priority %d\n", rtp.prio); > + warnx("realtime priority %d", rtp.prio); > break; > case RTP_PRIO_NORMAL: > - printf("normal priority\n"); > + warnx("normal priority"); > break; > case RTP_PRIO_IDLE: > - printf("idle priority %d\n", rtp.prio); > + warnx("idle priority %d", rtp.prio); > break; > default: > - printf("invalid priority type %d\n", rtp.type); > + errx(1, "invalid priority type %d", rtp.type); > break; > } > exit(0); > @@ -110,18 +111,17 @@ main(int argc, char *argv[]) > break; > } > > - if (argv[2][0] == '-') > - proc = parseint(argv[2] + 1, "pid"); > - if (rtprio(RTP_SET, proc, &rtp) != 0) > - err(1, "RTP_SET"); > - > - if (proc == 0) { > + if (argv[2][0] == '-') { > + proc = parseint(argv[2], "pid"); > + proc = abs(proc); > + if (rtprio(RTP_SET, proc, &rtp) != 0) > + err(1, "RTP_SET"); > + } else { > execvp(argv[2], &argv[2]); > - err(1, "%s", argv[2]); > + err(1, "%s", argv[2]); > } > exit(0); > } > - exit(1); > } > > static int -- a13x --FL5UXtIhxfXey3p5 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="rtprio.diff3" diff --git a/usr.sbin/rtprio/rtprio.c b/usr.sbin/rtprio/rtprio.c index 38dade8..e15d346 100644 --- a/usr.sbin/rtprio/rtprio.c +++ b/usr.sbin/rtprio/rtprio.c @@ -67,6 +67,8 @@ main(int argc, char *argv[]) rtp.type = RTP_PRIO_REALTIME; else if (!strcmp(p, "idprio")) rtp.type = RTP_PRIO_IDLE; + else + errx(1, "invalid basename"); switch (argc) { case 2: @@ -76,20 +78,19 @@ main(int argc, char *argv[]) case 1: if (rtprio(RTP_LOOKUP, proc, &rtp) != 0) err(1, "RTP_LOOKUP"); - printf("%s: ", p); switch (rtp.type) { case RTP_PRIO_REALTIME: case RTP_PRIO_FIFO: - printf("realtime priority %d\n", rtp.prio); + warnx("realtime priority %d", rtp.prio); break; case RTP_PRIO_NORMAL: - printf("normal priority\n"); + warnx("normal priority"); break; case RTP_PRIO_IDLE: - printf("idle priority %d\n", rtp.prio); + warnx("idle priority %d", rtp.prio); break; default: - printf("invalid priority type %d\n", rtp.type); + errx(1, "invalid priority type %d", rtp.type); break; } exit(0); @@ -110,18 +111,17 @@ main(int argc, char *argv[]) break; } - if (argv[2][0] == '-') - proc = parseint(argv[2] + 1, "pid"); - if (rtprio(RTP_SET, proc, &rtp) != 0) - err(1, "RTP_SET"); - - if (proc == 0) { + if (argv[2][0] == '-') { + proc = parseint(argv[2], "pid"); + proc = abs(proc); + if (rtprio(RTP_SET, proc, &rtp) != 0) + err(1, "RTP_SET"); + } else { execvp(argv[2], &argv[2]); err(1, "%s", argv[2]); } exit(0); } - exit(1); } static int --FL5UXtIhxfXey3p5-- From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:14:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A40A7106566B; Thu, 6 Jan 2011 22:14:13 +0000 (UTC) (envelope-from swell.k@gmail.com) Received: from mail-ww0-f50.google.com (mail-ww0-f50.google.com [74.125.82.50]) by mx1.freebsd.org (Postfix) with ESMTP id 671248FC0A; Thu, 6 Jan 2011 22:14:12 +0000 (UTC) Received: by wwf26 with SMTP id 26so16631506wwf.31 for ; Thu, 06 Jan 2011 14:14:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:references :date:in-reply-to:message-id:user-agent:mime-version:content-type; bh=4MC6sDWfDIh5lID4n0YeCpdXV+2vMMCPLwZerUcYEMw=; b=N5dxpzQ7gv6DljN07JdFTv7nsrwV3Cm48oHswu+T5umOrzrmpPALLL8+u9Nss237pp hq1GCVsHHjzF+hYvjkGns3MlVzDGBWhXLv9FxyCjWLgE1TGXVoTf42FBPFh7YzzWg47Z EmCxFWgHasEx77s2s7eDP9EZCYACMZV0drY1Q= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; b=dUUjC637K5YGFTGj6vNY2FQ8jgXT55qvkQv+pBJ8j1573SU7BNUZFL2kteU05tbIJR kKCH5JWtJi5SHiE7IlB1XDXLGEut11WvtadkCsFBBdjCWJllU06PZZ0LsQJ6m7zLHin/ 4QVSCs5Lk3BBZz1yGBM9R9cXQlU70W6V92+vg= Received: by 10.216.169.1 with SMTP id m1mr23590769wel.112.1294352051175; Thu, 06 Jan 2011 14:14:11 -0800 (PST) Received: from localhost (tor-exit-readme.hands.com [83.142.228.14]) by mx.google.com with ESMTPS id p4sm12065203wer.29.2011.01.06.14.14.08 (version=SSLv3 cipher=RC4-MD5); Thu, 06 Jan 2011 14:14:09 -0800 (PST) From: Anonymous To: Alexander Best References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106211017.GA46874@freebsd.org> <201101061618.39695.jhb@freebsd.org> <20110106214243.GA51802__16340.9905079336$1294350178$gmane$org@freebsd.org> Date: Fri, 07 Jan 2011 01:13:58 +0300 In-Reply-To: <20110106214243.GA51802__16340.9905079336$1294350178$gmane$org@freebsd.org> (Alexander Best's message of "Thu, 6 Jan 2011 21:42:43 +0000") Message-ID: <86bp3the8p.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain Cc: src-committers@freebsd.org, John Baldwin , svn-src-all@freebsd.org, Garrett Cooper , Konstantin Belousov , svn-src-head@freebsd.org Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:14:13 -0000 Alexander Best writes: > On Thu Jan 6 11, John Baldwin wrote: >> Note that that usage is rather pointless since it means you apply rtprio to >> the 'rtprio' process that is about to exit. :) > > yeah but at least it makes the usage of -X consistent. ;) also consider the > following: the current shell has idle priority and you want to run rtprio in > normal priority. then rtprio -t -0 would be a neat way of doing > rtprio -t rtprio. ;) wel...not quite, because the priotity gets set to "NORMAL" > when rtprio is almost finished running. ;) I think it'd be useful if the syntax allowed smth like $ rtprio 1 -0 -111 -222 -333 -444 -555 ... > > i admit using -0 for setting rtpio's own priority isn't very useful, but the > rtprio(1) manual states: > > Pid of 0 means "the current process". From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:17:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 26BAE106564A; Thu, 6 Jan 2011 22:17:08 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id F02AF8FC15; Thu, 6 Jan 2011 22:17:07 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06MH7if030121; Thu, 6 Jan 2011 22:17:07 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06MH7ff030118; Thu, 6 Jan 2011 22:17:07 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062217.p06MH7ff030118@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 22:17:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217076 - in head/sys: kern net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:17:08 -0000 Author: jhb Date: Thu Jan 6 22:17:07 2011 New Revision: 217076 URL: http://svn.freebsd.org/changeset/base/217076 Log: - Restore dropping the priority of syncer down to PPAUSE when it is idle. This was lost when it was converted to using a condition variable instead of lbolt. - Drop the priority of flowtable down to PPAUSE when it is idle as well since it is a similar background task. MFC after: 2 weeks Modified: head/sys/kern/vfs_subr.c head/sys/net/flowtable.c Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Thu Jan 6 22:09:37 2011 (r217075) +++ head/sys/kern/vfs_subr.c Thu Jan 6 22:17:07 2011 (r217076) @@ -65,6 +65,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include @@ -1880,6 +1881,12 @@ sched_sync(void) * matter as we are just trying to generally pace the * filesystem activity. */ + if (syncer_state != SYNCER_RUNNING || + time_uptime == starttime) { + thread_lock(td); + sched_prio(td, PPAUSE); + thread_unlock(td); + } if (syncer_state != SYNCER_RUNNING) cv_timedwait(&sync_wakeup, &sync_mtx, hz / SYNCER_SHUTDOWN_SPEEDUP); Modified: head/sys/net/flowtable.c ============================================================================== --- head/sys/net/flowtable.c Thu Jan 6 22:09:37 2011 (r217075) +++ head/sys/net/flowtable.c Thu Jan 6 22:17:07 2011 (r217076) @@ -1549,9 +1549,11 @@ static void flowtable_cleaner(void) { VNET_ITERATOR_DECL(vnet_iter); + struct thread *td; if (bootverbose) log(LOG_INFO, "flowtable cleaner started\n"); + td = curthread; while (1) { VNET_LIST_RLOCK(); VNET_FOREACH(vnet_iter) { @@ -1566,6 +1568,9 @@ flowtable_cleaner(void) * is arbitrary */ mtx_lock(&flowclean_lock); + thread_lock(td); + sched_prio(td, PPAUSE); + thread_unlock(td); flowclean_cycles++; cv_broadcast(&flowclean_f_cv); cv_timedwait(&flowclean_c_cv, &flowclean_lock, flowclean_freq); From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:19:15 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BB9581065672; Thu, 6 Jan 2011 22:19:15 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AB3D68FC15; Thu, 6 Jan 2011 22:19:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06MJFHk030196; Thu, 6 Jan 2011 22:19:15 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06MJFUb030194; Thu, 6 Jan 2011 22:19:15 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062219.p06MJFUb030194@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 22:19:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217077 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:19:15 -0000 Author: jhb Date: Thu Jan 6 22:19:15 2011 New Revision: 217077 URL: http://svn.freebsd.org/changeset/base/217077 Log: Only change the priority of timeshare threads to PRI_MAX_TIMESHARE when yield() is called. Specifically, leave the priority of real time and idle threads unchanged. MFC after: 2 weeks Modified: head/sys/kern/kern_synch.c Modified: head/sys/kern/kern_synch.c ============================================================================== --- head/sys/kern/kern_synch.c Thu Jan 6 22:17:07 2011 (r217076) +++ head/sys/kern/kern_synch.c Thu Jan 6 22:19:15 2011 (r217077) @@ -546,7 +546,8 @@ yield(struct thread *td, struct yield_ar { thread_lock(td); - sched_prio(td, PRI_MAX_TIMESHARE); + if (PRI_BASE(td->td_pri_class) == PRI_TIMESHARE) + sched_prio(td, PRI_MAX_TIMESHARE); mi_switch(SW_VOL | SWT_RELINQUISH, NULL); thread_unlock(td); td->td_retval[0] = 0; From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:24:01 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F15D5106567A; Thu, 6 Jan 2011 22:24:00 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D66B58FC14; Thu, 6 Jan 2011 22:24:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06MO0U2030347; Thu, 6 Jan 2011 22:24:00 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06MO0xq030343; Thu, 6 Jan 2011 22:24:00 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062224.p06MO0xq030343@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 22:24:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217078 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:24:01 -0000 Author: jhb Date: Thu Jan 6 22:24:00 2011 New Revision: 217078 URL: http://svn.freebsd.org/changeset/base/217078 Log: - Move sched_fork() later in fork() after the various sections of the new thread and proc have been copied and zeroed from the old thread and proc. Otherwise attempts to modify thread or process data in sched_fork() could be undone. - Don't copy td_{base,}_user_pri from the old thread to the new thread in sched_fork_thread() in ULE. This is already done courtesy the bcopy() of the thread copy region. - Always initialize the real priority (td_priority) of new threads to the new thread's base priority (td_base_pri) to avoid bogusly inheriting a borrowed priority from the parent thread. MFC after: 2 weeks Modified: head/sys/kern/kern_fork.c head/sys/kern/sched_4bsd.c head/sys/kern/sched_ule.c Modified: head/sys/kern/kern_fork.c ============================================================================== --- head/sys/kern/kern_fork.c Thu Jan 6 22:19:15 2011 (r217077) +++ head/sys/kern/kern_fork.c Thu Jan 6 22:24:00 2011 (r217078) @@ -360,12 +360,6 @@ do_fork(struct thread *td, int flags, st p2->p_state = PRS_NEW; /* protect against others */ p2->p_pid = trypid; - /* - * Allow the scheduler to initialize the child. - */ - thread_lock(td); - sched_fork(td, td2); - thread_unlock(td); AUDIT_ARG_PID(p2->p_pid); LIST_INSERT_HEAD(&allproc, p2, p_list); LIST_INSERT_HEAD(PIDHASH(p2->p_pid), p2, p_hash); @@ -457,6 +451,13 @@ do_fork(struct thread *td, int flags, st #endif /* + * Allow the scheduler to initialize the child. + */ + thread_lock(td); + sched_fork(td, td2); + thread_unlock(td); + + /* * Duplicate sub-structures as needed. * Increase reference counts on shared objects. */ Modified: head/sys/kern/sched_4bsd.c ============================================================================== --- head/sys/kern/sched_4bsd.c Thu Jan 6 22:19:15 2011 (r217077) +++ head/sys/kern/sched_4bsd.c Thu Jan 6 22:24:00 2011 (r217078) @@ -759,6 +759,7 @@ sched_fork_thread(struct thread *td, str childtd->td_estcpu = td->td_estcpu; childtd->td_lock = &sched_lock; childtd->td_cpuset = cpuset_ref(td->td_cpuset); + childtd->td_priority = childtd->td_base_pri; ts = childtd->td_sched; bzero(ts, sizeof(*ts)); ts->ts_flags |= (td->td_sched->ts_flags & TSF_AFFINITY); Modified: head/sys/kern/sched_ule.c ============================================================================== --- head/sys/kern/sched_ule.c Thu Jan 6 22:19:15 2011 (r217077) +++ head/sys/kern/sched_ule.c Thu Jan 6 22:24:00 2011 (r217078) @@ -1961,14 +1961,16 @@ sched_fork_thread(struct thread *td, str ts2->ts_cpu = ts->ts_cpu; ts2->ts_flags = 0; /* - * Grab our parents cpu estimation information and priority. + * Grab our parents cpu estimation information. */ ts2->ts_ticks = ts->ts_ticks; ts2->ts_ltick = ts->ts_ltick; ts2->ts_incrtick = ts->ts_incrtick; ts2->ts_ftick = ts->ts_ftick; - child->td_user_pri = td->td_user_pri; - child->td_base_user_pri = td->td_base_user_pri; + /* + * Do not inherit any borrowed priority from the parent. + */ + child->td_priority = child->td_base_pri; /* * And update interactivity score. */ From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:26:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 842371065670; Thu, 6 Jan 2011 22:26:00 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 73E4F8FC1B; Thu, 6 Jan 2011 22:26:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p06MQ0SL030427; Thu, 6 Jan 2011 22:26:00 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06MQ0fn030424; Thu, 6 Jan 2011 22:26:00 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101062226.p06MQ0fn030424@svn.freebsd.org> From: John Baldwin Date: Thu, 6 Jan 2011 22:26:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217079 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:26:00 -0000 Author: jhb Date: Thu Jan 6 22:26:00 2011 New Revision: 217079 URL: http://svn.freebsd.org/changeset/base/217079 Log: - Properly initialize the base priority (td_base_pri) of thread0 to PVM to match the desired priority in td_priority. Otherwise the first time thread0 used a borrowed priority it would drop down to PUSER instead of PVM. - Explicitly initialize the starting priority of new kprocs to PVM to avoid inheriting some random priority from thread0. MFC after: 2 weeks Modified: head/sys/kern/init_main.c head/sys/kern/kern_kthread.c Modified: head/sys/kern/init_main.c ============================================================================== --- head/sys/kern/init_main.c Thu Jan 6 22:24:00 2011 (r217078) +++ head/sys/kern/init_main.c Thu Jan 6 22:26:00 2011 (r217079) @@ -462,7 +462,7 @@ proc0_init(void *dummy __unused) td->td_base_user_pri = PUSER; td->td_lend_user_pri = PRI_MAX; td->td_priority = PVM; - td->td_base_pri = PUSER; + td->td_base_pri = PVM; td->td_oncpu = 0; td->td_flags = TDF_INMEM|TDP_KTHREAD; td->td_cpuset = cpuset_thread0(); Modified: head/sys/kern/kern_kthread.c ============================================================================== --- head/sys/kern/kern_kthread.c Thu Jan 6 22:24:00 2011 (r217078) +++ head/sys/kern/kern_kthread.c Thu Jan 6 22:26:00 2011 (r217079) @@ -117,14 +117,15 @@ kproc_create(void (*func)(void *), void /* call the processes' main()... */ cpu_set_fork_handler(td, func, arg); + thread_lock(td); TD_SET_CAN_RUN(td); + sched_prio(td, PVM); + sched_user_prio(td, PUSER); /* Delay putting it on the run queue until now. */ - if (!(flags & RFSTOPPED)) { - thread_lock(td); + if (!(flags & RFSTOPPED)) sched_add(td, SRQ_BORING); - thread_unlock(td); - } + thread_unlock(td); return 0; } From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 22:41:39 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 58D5D106567A; Thu, 6 Jan 2011 22:41:39 +0000 (UTC) Date: Thu, 6 Jan 2011 22:41:39 +0000 From: Alexander Best To: Anonymous Message-ID: <20110106224139.GA62043@freebsd.org> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106211017.GA46874@freebsd.org> <201101061618.39695.jhb@freebsd.org> <20110106214243.GA51802__16340.9905079336$1294350178$gmane$org@freebsd.org> <86bp3the8p.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <86bp3the8p.fsf@gmail.com> Cc: src-committers@freebsd.org, John Baldwin , svn-src-all@freebsd.org, Garrett Cooper , Konstantin Belousov , svn-src-head@freebsd.org Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 22:41:39 -0000 On Fri Jan 7 11, Anonymous wrote: > Alexander Best writes: > > > On Thu Jan 6 11, John Baldwin wrote: > >> Note that that usage is rather pointless since it means you apply rtprio to > >> the 'rtprio' process that is about to exit. :) > > > > yeah but at least it makes the usage of -X consistent. ;) also consider the > > following: the current shell has idle priority and you want to run rtprio in > > normal priority. then rtprio -t -0 would be a neat way of doing > > rtprio -t rtprio. ;) wel...not quite, because the priotity gets set to "NORMAL" > > when rtprio is almost finished running. ;) > > I think it'd be useful if the syntax allowed smth like > > $ rtprio 1 -0 -111 -222 -333 -444 -555 ... defenately, but that would require quite some code. also please bear in mind: in its current form rtprio *DOES* process -0. my code doesn't change that. the only thing that it changes is that before hand -0 was processed *AND* then also executed. now the execution doesn't take place. cheers. alex > > > > > i admit using -0 for setting rtpio's own priority isn't very useful, but the > > rtprio(1) manual states: > > > > Pid of 0 means "the current process". -- a13x From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 23:37:21 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 98E7C106566B; Thu, 6 Jan 2011 23:37:21 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-yw0-f54.google.com (mail-yw0-f54.google.com [209.85.213.54]) by mx1.freebsd.org (Postfix) with ESMTP id C8BAF8FC12; Thu, 6 Jan 2011 23:37:20 +0000 (UTC) Received: by ywp6 with SMTP id 6so7154834ywp.13 for ; Thu, 06 Jan 2011 15:37:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to:x-mailer; bh=6IHD51zOrs+s99WbafwoMx4HvQBhnRy5GYcOiyxyshg=; b=N29JJYhsVeIlVRURTV3aSWPzKZ1n5bE5iTQxstNR31zDbaIMIFOcaEIkWFYXfZwfKN aT3650RtmnBqgNEIpJlL+imXeV+SNwwlscMnhx0sYR6maG1+ohikDPZQJqtYWo4sjWUH 8UqXCsAmNL9XuSuwJeo3qkJLjyVOYNRRjW7UE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=qVoRyh77hHgTRoKd423V+HyyOsWPB4/BgjMNEmWUpKkH3CiMRri0AXubO/lk6bQhFl x5+q2KnfzDjtnWHVMUiZGHQ4dA8aiEnKjB1WNYAHTMX/34WG1B4Na+uV05ZYiqBOmtbn dnk7O3gSnc3kfzxhDOE1eljcQNbTG3D7ctd8o= Received: by 10.147.40.1 with SMTP id s1mr35151202yaj.15.1294357040127; Thu, 06 Jan 2011 15:37:20 -0800 (PST) Received: from dhcp-173-37-0-197.cisco.com (nat.ironport.com [63.251.108.100]) by mx.google.com with ESMTPS id a52sm1191160yhd.15.2011.01.06.15.37.17 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 06 Jan 2011 15:37:18 -0800 (PST) Mime-Version: 1.0 (Apple Message framework v1082) Content-Type: text/plain; charset=us-ascii From: Garrett Cooper In-Reply-To: <20110106224139.GA62043@freebsd.org> Date: Thu, 6 Jan 2011 15:37:15 -0800 Content-Transfer-Encoding: quoted-printable Message-Id: <3AFB20EC-3BEF-4C52-B51F-94F0A9338CBB@gmail.com> References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106211017.GA46874@freebsd.org> <201101061618.39695.jhb@freebsd.org> <20110106214243.GA51802__16340.9905079336$1294350178$gmane$org@freebsd.org> <86bp3the8p.fsf@gmail.com> <20110106224139.GA62043@freebsd.org> To: Alexander Best X-Mailer: Apple Mail (2.1082) Cc: src-committers@freebsd.org, John Baldwin , svn-src-all@freebsd.org, Garrett Cooper , svn-src-head@freebsd.org, Konstantin Belousov , Anonymous Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 23:37:21 -0000 On Jan 6, 2011, at 2:41 PM, Alexander Best wrote: > On Fri Jan 7 11, Anonymous wrote: >> Alexander Best writes: >>=20 >>> On Thu Jan 6 11, John Baldwin wrote: >>>> Note that that usage is rather pointless since it means you apply = rtprio to=20 >>>> the 'rtprio' process that is about to exit. :) >>>=20 >>> yeah but at least it makes the usage of -X consistent. ;) also = consider the >>> following: the current shell has idle priority and you want to run = rtprio in >>> normal priority. then rtprio -t -0 would be a neat way of doing >>> rtprio -t rtprio. ;) wel...not quite, because the priotity gets set = to "NORMAL" >>> when rtprio is almost finished running. ;) >>=20 >> I think it'd be useful if the syntax allowed smth like >>=20 >> $ rtprio 1 -0 -111 -222 -333 -444 -555 ... >=20 > defenately, but that would require quite some code. also please bear = in mind: > in its current form rtprio *DOES* process -0. my code doesn't change = that. the > only thing that it changes is that before hand -0 was processed *AND* = then also > executed. now the execution doesn't take place. Same thing, no code change: sh -c 'for i in 1 -0 -111 -222 -333 -444 -555; do rtprio $i; done' Yes, there's more of a processing cost to doing it this way with = exec/fork jazz and shell logic -- but how often do you execute rtprio, = and is the required code change really necessary? Simple is better in my = book. Thanks, -Garrett= From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 23:56:52 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EAB54106564A; Thu, 6 Jan 2011 23:56:51 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail06.syd.optusnet.com.au (mail06.syd.optusnet.com.au [211.29.132.187]) by mx1.freebsd.org (Postfix) with ESMTP id 7E4148FC1A; Thu, 6 Jan 2011 23:56:51 +0000 (UTC) Received: from c122-106-165-206.carlnfd1.nsw.optusnet.com.au (c122-106-165-206.carlnfd1.nsw.optusnet.com.au [122.106.165.206]) by mail06.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p06Num87031920 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 7 Jan 2011 10:56:49 +1100 Date: Fri, 7 Jan 2011 10:56:48 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Julian Elischer In-Reply-To: <4D258247.5030707@freebsd.org> Message-ID: <20110107101659.M1473@besplex.bde.org> References: <201101041316.p04DGSo6037042@svn.freebsd.org> <201101041314.08949.jhb@freebsd.org> <20110105161720.GA1388@a91-153-123-205.elisa-laajakaista.fi> <201101051144.56940.jhb@freebsd.org> <20110106062530.Y1027@besplex.bde.org> <4D258247.5030707@freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Jaakko Heinonen , src-committers@FreeBSD.org, John Baldwin , svn-src-all@FreeBSD.org, Bruce Evans , svn-src-head@FreeBSD.org Subject: Re: svn commit: r216954 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 23:56:52 -0000 On Thu, 6 Jan 2011, Julian Elischer wrote: > On 1/5/11 11:39 AM, Bruce Evans wrote: >> On Wed, 5 Jan 2011, John Baldwin wrote: >> >>> On Wednesday, January 05, 2011 11:17:20 am Jaakko Heinonen wrote: >>>> On 2011-01-04, John Baldwin wrote: >>>>> Err, no, the point of NOTREACHED is to serve as documentation for >>>>> lint(1), but >>>>> that has subsequently been obsoleted by __dead2. >>>> >>>> style(9) is out of date then? >>> >>> According to bde@'s most recent e-mails, yes. >> >> It's obviously out of date, since its only example of using NOTREACHED is >> after a usage() call, and this usage is missing a __dead2. Of course it >> doesn't use NOTREACHED after its 3 exit() calls or its 2 err() calls or >> its 1 errx() call, so its "should" requirement for using NOTREACHED is >> mostly not satisfied by itself. > > However I feel that teh notreached comment is as much for the reader as the > compiler/lint. > > Removing it makes the code harder to understand for the feeble minded such > as myself. Not to be personal, but is this why sys/netgraph never uses NOTREACHED? It set an even better example than style(9) in this regard :-). Perhaps netgraph use have many non-returning functions, but it has thousands of return statements (which, according to style(9), "should" be followed by a NOTREACHED comment. That is obviously wrong, but it is very easy to have unreachable code due to early returns; then a /* Not reached due to mumble ... */ comment might be useful but a lint /* NOTREACHED */ one isn't. netgraph has 84 uses of panic() without NOTREACHED. The unreachability of code after panic() is especially interesting, since panic() shouldn't return, but it can be misconfigured to return using RESTARTABLE_PANICS. ng_parse.c is one of the few places that sort of supports RESTARTABLE_PANICS. Parts of it return (0) iff RESTARTABLE_PANICS && panic() returns. Other parts of it it are not so careful -- they blindly fall through if panic() returns. The parts with sloppy returns are also the parts with non-KNF style. These RESTARTABLE_PANICS ifdefs document the (non-) NOTREACHability of the !RESTARTABLE_PANICS case much better than NOTREACHED comments ever could, but are ugly clutter in a different way. There are only 6 of them (4 in ng_parse.c; 2 elsewhere), leaving 78 panic() calls with possibly-not- NOTREACHED code after them. Grepping for '/\* [A-Z]* \*/' showed only 10 lint comments in netgraph (all FALLTHROUGHs). These are outnumbered by about 3.5 to 1 by my favourite, XXX :-). Bruce From owner-svn-src-head@FreeBSD.ORG Thu Jan 6 23:58:29 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 758421065670; Thu, 6 Jan 2011 23:58:29 +0000 (UTC) (envelope-from swell.k@gmail.com) Received: from mail-ww0-f50.google.com (mail-ww0-f50.google.com [74.125.82.50]) by mx1.freebsd.org (Postfix) with ESMTP id 136DD8FC0C; Thu, 6 Jan 2011 23:58:27 +0000 (UTC) Received: by wwf26 with SMTP id 26so16706976wwf.31 for ; Thu, 06 Jan 2011 15:58:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:references :date:in-reply-to:message-id:user-agent:mime-version:content-type; bh=YmKh3rAM3GCy69iogmJjG9LP5Q38dkl+glRnE6iDVqA=; b=piWsqW4nNKnvdOuXTNmb5SZKnZdAVfDWDdGhiebZA06aqBalUhMwenD78F4f3WNAt8 BfcE/mWt/ZpF6G0kibuNxDCkhoYjojXJSgHtjOu4dPVI3g4w52d00gTCZOOvYDP3qik4 1l3UKU2V4BF0AOl6NIR3OYFsmte4nVIfhSK/c= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; b=NkHUZTGNO7OCFffhjkMG5vekPQ9fhR+CLEms52HEyHZuDau+8528Baf03WYIdvMOXI Sua4DRxZulWrYN4kbhaQGh0CdiVBekVSI6UsEMvtgmJTy/vbDie6yBKMziyhUWnZLheU YFOdVzmpUwkEQmXkY9rViQsEP2M8V5jdpp/dI= Received: by 10.216.51.67 with SMTP id a45mr1016738wec.19.1294358307168; Thu, 06 Jan 2011 15:58:27 -0800 (PST) Received: from localhost ([81.218.219.122]) by mx.google.com with ESMTPS id r38sm12118545weq.47.2011.01.06.15.58.23 (version=SSLv3 cipher=RC4-MD5); Thu, 06 Jan 2011 15:58:26 -0800 (PST) From: Anonymous To: Garrett Cooper References: <201101041413.p04EDA4f038360@svn.freebsd.org> <20110106211017.GA46874@freebsd.org> <201101061618.39695.jhb@freebsd.org> <20110106214243.GA51802__16340.9905079336$1294350178$gmane$org@freebsd.org> <86bp3the8p.fsf@gmail.com> <20110106224139.GA62043@freebsd.org> <3AFB20EC-3BEF-4C52-B51F-94F0A9338CBB@gmail.com> Date: Fri, 07 Jan 2011 02:58:13 +0300 In-Reply-To: <3AFB20EC-3BEF-4C52-B51F-94F0A9338CBB@gmail.com> (Garrett Cooper's message of "Thu, 6 Jan 2011 15:37:15 -0800") Message-ID: <86y66xd1pm.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain Cc: src-committers@freebsd.org, John Baldwin , svn-src-all@freebsd.org, Garrett Cooper , Konstantin Belousov , svn-src-head@freebsd.org, Alexander Best Subject: Re: svn commit: r216955 - head/usr.sbin/rtprio X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 23:58:29 -0000 Garrett Cooper writes: > On Jan 6, 2011, at 2:41 PM, Alexander Best wrote: > >> On Fri Jan 7 11, Anonymous wrote: >>> Alexander Best writes: >>> >>>> On Thu Jan 6 11, John Baldwin wrote: >>>>> Note that that usage is rather pointless since it means you apply rtprio to >>>>> the 'rtprio' process that is about to exit. :) >>>> >>>> yeah but at least it makes the usage of -X consistent. ;) also consider the >>>> following: the current shell has idle priority and you want to run rtprio in >>>> normal priority. then rtprio -t -0 would be a neat way of doing >>>> rtprio -t rtprio. ;) wel...not quite, because the priotity gets set to "NORMAL" >>>> when rtprio is almost finished running. ;) >>> >>> I think it'd be useful if the syntax allowed smth like >>> >>> $ rtprio 1 -0 -111 -222 -333 -444 -555 ... >> >> defenately, but that would require quite some code. also please bear in mind: >> in its current form rtprio *DOES* process -0. my code doesn't change that. the >> only thing that it changes is that before hand -0 was processed *AND* then also >> executed. now the execution doesn't take place. > > Same thing, no code change: > > sh -c 'for i in 1 -0 -111 -222 -333 -444 -555; do rtprio $i; done' > > Yes, there's more of a processing cost to doing it this way > with exec/fork jazz and shell logic I was thinking about rtprio(1) raising its own priority using syntax like $ rtprio num -0 ... or $ rtprio -t -0 ... so that subsequent calls to rtprio(2) are under new priority. Not sure if it makes difference on heavily loaded system. > -- but how often do you execute > rtprio, and is the required code change really necessary? Simple is > better in my book. From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 08:34:12 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A79EC106564A; Fri, 7 Jan 2011 08:34:12 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 96C398FC0C; Fri, 7 Jan 2011 08:34:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p078YCjC044397; Fri, 7 Jan 2011 08:34:12 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p078YCeg044395; Fri, 7 Jan 2011 08:34:12 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201101070834.p078YCeg044395@svn.freebsd.org> From: Edward Tomasz Napierala Date: Fri, 7 Jan 2011 08:34:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217087 - head/share/man/man9 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 08:34:12 -0000 Author: trasz Date: Fri Jan 7 08:34:12 2011 New Revision: 217087 URL: http://svn.freebsd.org/changeset/base/217087 Log: Restore comment describing /* NOTREACHED */, updated to match reality. Modified: head/share/man/man9/style.9 Modified: head/share/man/man9/style.9 ============================================================================== --- head/share/man/man9/style.9 Fri Jan 7 01:50:25 2011 (r217086) +++ head/share/man/man9/style.9 Fri Jan 7 08:34:12 2011 (r217087) @@ -26,7 +26,7 @@ .\" From: @(#)style 1.14 (Berkeley) 4/28/95 .\" $FreeBSD$ .\" -.Dd December 17, 2008 +.Dd January 7, 2010 .Dt STYLE 9 .Os .Sh NAME @@ -470,6 +470,9 @@ statement that cascade should have a .Li FALLTHROUGH comment. Numerical arguments should be checked for accuracy. +Code which is unreachable for non-obvious reasons may be marked /* +.Li NOTREACHED +*/. .Bd -literal while ((ch = getopt(argc, argv, "abNn:")) != -1) switch (ch) { /* Indent the switch. */ From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 10:59:23 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 510801065696; Fri, 7 Jan 2011 10:59:23 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 40E5D8FC15; Fri, 7 Jan 2011 10:59:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07AxNdB049136; Fri, 7 Jan 2011 10:59:23 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07AxN1F049134; Fri, 7 Jan 2011 10:59:23 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201101071059.p07AxN1F049134@svn.freebsd.org> From: Jaakko Heinonen Date: Fri, 7 Jan 2011 10:59:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217090 - head/etc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 10:59:23 -0000 Author: jh Date: Fri Jan 7 10:59:22 2011 New Revision: 217090 URL: http://svn.freebsd.org/changeset/base/217090 Log: Warn if rules could not be read from a ruleset file. Now at least something gets logged if the file has syntax errors. PR: conf/91342 Silence on: freebsd-rc Modified: head/etc/rc.subr Modified: head/etc/rc.subr ============================================================================== --- head/etc/rc.subr Fri Jan 7 08:45:56 2011 (r217089) +++ head/etc/rc.subr Fri Jan 7 10:59:22 2011 (r217090) @@ -1349,7 +1349,10 @@ devfs_init_rulesets() return fi for file in $devfs_rulesets; do - devfs_rulesets_from_file $file || return 1 + if ! devfs_rulesets_from_file $file; then + warn "$_me: could not read rules from $file" + return 1 + fi done devfs_rulesets_init=1 debug "$_me: devfs rulesets initialized" From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 14:22:34 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C77AD106564A; Fri, 7 Jan 2011 14:22:34 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A27608FC16; Fri, 7 Jan 2011 14:22:34 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07EMY4c055080; Fri, 7 Jan 2011 14:22:34 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07EMYlP055071; Fri, 7 Jan 2011 14:22:34 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071422.p07EMYlP055071@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 14:22:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217097 - in head/sys: amd64/include arm/include i386/include ia64/include mips/include powerpc/include sparc64/include sun4v/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 14:22:34 -0000 Author: kib Date: Fri Jan 7 14:22:34 2011 New Revision: 217097 URL: http://svn.freebsd.org/changeset/base/217097 Log: Add AT_STACKPROT elf aux vector. Will be used to inform rtld about the initial stack protection set by the kernel image activator. Modified: head/sys/amd64/include/elf.h head/sys/arm/include/elf.h head/sys/i386/include/elf.h head/sys/ia64/include/elf.h head/sys/mips/include/elf.h head/sys/powerpc/include/elf.h head/sys/sparc64/include/elf.h head/sys/sun4v/include/elf.h Modified: head/sys/amd64/include/elf.h ============================================================================== --- head/sys/amd64/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/amd64/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -94,8 +94,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 19 /* Number of CPUs. */ #define AT_PAGESIZES 20 /* Pagesizes. */ #define AT_PAGESIZESLEN 21 /* Number of pagesizes. */ +#define AT_STACKPROT 23 /* Initial stack protection. */ -#define AT_COUNT 22 /* Count of defined aux entry types. */ +#define AT_COUNT 24 /* Count of defined aux entry types. */ /* * Relocation types. Modified: head/sys/arm/include/elf.h ============================================================================== --- head/sys/arm/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/arm/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -82,8 +82,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 19 /* Number of CPUs. */ #define AT_PAGESIZES 20 /* Pagesizes. */ #define AT_PAGESIZESLEN 21 /* Number of pagesizes. */ +#define AT_STACKPROT 23 /* Initial stack protection. */ -#define AT_COUNT 22 /* Count of defined aux entry types. */ +#define AT_COUNT 24 /* Count of defined aux entry types. */ #define R_ARM_COUNT 33 /* Count of defined relocation types. */ Modified: head/sys/i386/include/elf.h ============================================================================== --- head/sys/i386/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/i386/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -96,8 +96,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 19 /* Number of CPUs. */ #define AT_PAGESIZES 20 /* Pagesizes. */ #define AT_PAGESIZESLEN 21 /* Number of pagesizes. */ +#define AT_STACKPROT 23 /* Initial stack protection. */ -#define AT_COUNT 22 /* Count of defined aux entry types. */ +#define AT_COUNT 24 /* Count of defined aux entry types. */ /* * Relocation types. Modified: head/sys/ia64/include/elf.h ============================================================================== --- head/sys/ia64/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/ia64/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -95,8 +95,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 19 /* Number of CPUs. */ #define AT_PAGESIZES 20 /* Pagesizes. */ #define AT_PAGESIZESLEN 21 /* Number of pagesizes. */ +#define AT_STACKPROT 23 /* Initial stack protection. */ -#define AT_COUNT 22 /* Count of defined aux entry types. */ +#define AT_COUNT 24 /* Count of defined aux entry types. */ /* * Values for e_flags. Modified: head/sys/mips/include/elf.h ============================================================================== --- head/sys/mips/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/mips/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -257,8 +257,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 19 /* Number of CPUs. */ #define AT_PAGESIZES 20 /* Pagesizes. */ #define AT_PAGESIZESLEN 21 /* Number of pagesizes. */ +#define AT_STACKPROT 23 /* Initial stack protection. */ -#define AT_COUNT 22 /* Count of defined aux entry types. */ +#define AT_COUNT 24 /* Count of defined aux entry types. */ #define ET_DYN_LOAD_ADDR 0x0120000 Modified: head/sys/powerpc/include/elf.h ============================================================================== --- head/sys/powerpc/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/powerpc/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -105,8 +105,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 17 /* Number of CPUs. */ #define AT_PAGESIZES 18 /* Pagesizes. */ #define AT_PAGESIZESLEN 19 /* Number of pagesizes. */ +#define AT_STACKPROT 21 /* Initial stack protection. */ -#define AT_COUNT 20 /* Count of defined aux entry types. */ +#define AT_COUNT 22 /* Count of defined aux entry types. */ /* * Relocation types. Modified: head/sys/sparc64/include/elf.h ============================================================================== --- head/sys/sparc64/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/sparc64/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -90,8 +90,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 19 /* Number of CPUs. */ #define AT_PAGESIZES 20 /* Pagesizes. */ #define AT_PAGESIZESLEN 21 /* Number of pagesizes. */ +#define AT_STACKPROT 23 /* Initial stack protection. */ -#define AT_COUNT 22 /* Count of defined aux entry types. */ +#define AT_COUNT 24 /* Count of defined aux entry types. */ /* Define "machine" characteristics */ #if __ELF_WORD_SIZE == 32 Modified: head/sys/sun4v/include/elf.h ============================================================================== --- head/sys/sun4v/include/elf.h Fri Jan 7 14:17:29 2011 (r217096) +++ head/sys/sun4v/include/elf.h Fri Jan 7 14:22:34 2011 (r217097) @@ -90,8 +90,9 @@ __ElfType(Auxinfo); #define AT_NCPUS 19 /* Number of CPUs. */ #define AT_PAGESIZES 20 /* Pagesizes. */ #define AT_PAGESIZESLEN 21 /* Number of pagesizes. */ +#define AT_STACKPROT 23 /* Initial stack protection. */ -#define AT_COUNT 22 /* Count of defined aux entry types. */ +#define AT_COUNT 24 /* Count of defined aux entry types. */ /* Define "machine" characteristics */ #if __ELF_WORD_SIZE == 32 From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 14:24:24 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8BD071065693; Fri, 7 Jan 2011 14:24:24 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7B3528FC15; Fri, 7 Jan 2011 14:24:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07EOOlI055167; Fri, 7 Jan 2011 14:24:24 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07EOOY7055165; Fri, 7 Jan 2011 14:24:24 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071424.p07EOOY7055165@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 14:24:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217098 - head/contrib/gcc/config/i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 14:24:24 -0000 Author: kib Date: Fri Jan 7 14:24:24 2011 New Revision: 217098 URL: http://svn.freebsd.org/changeset/base/217098 Log: Make gcc emit the .note.GNU-stack section into the assembler files. Reviewed by: kan Modified: head/contrib/gcc/config/i386/freebsd.h Modified: head/contrib/gcc/config/i386/freebsd.h ============================================================================== --- head/contrib/gcc/config/i386/freebsd.h Fri Jan 7 14:22:34 2011 (r217097) +++ head/contrib/gcc/config/i386/freebsd.h Fri Jan 7 14:24:24 2011 (r217098) @@ -239,3 +239,6 @@ Boston, MA 02110-1301, USA. */ XSTR (XEXP (DECL_RTL (current_function_decl), 0), 0)); \ fprintf (asm_out_file, "\n"); \ } while (0) + +#undef NEED_INDICATE_EXEC_STACK +#define NEED_INDICATE_EXEC_STACK 1 From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 14:28:54 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9F85C106566C; Fri, 7 Jan 2011 14:28:54 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8EFB48FC17; Fri, 7 Jan 2011 14:28:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07ESshN055314; Fri, 7 Jan 2011 14:28:54 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07ESsCr055312; Fri, 7 Jan 2011 14:28:54 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071428.p07ESsCr055312@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 14:28:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217099 - head/lib/libc/sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 14:28:54 -0000 Author: kib Date: Fri Jan 7 14:28:54 2011 New Revision: 217099 URL: http://svn.freebsd.org/changeset/base/217099 Log: Emit .note.GNU-stack for the syscall stubs generated by libc. Modified: head/lib/libc/sys/Makefile.inc Modified: head/lib/libc/sys/Makefile.inc ============================================================================== --- head/lib/libc/sys/Makefile.inc Fri Jan 7 14:24:24 2011 (r217098) +++ head/lib/libc/sys/Makefile.inc Fri Jan 7 14:28:54 2011 (r217099) @@ -56,11 +56,13 @@ CLEANFILES+= ${SASM} ${SPSEUDO} ${SASM}: printf '#include "compat.h"\n' > ${.TARGET} printf '#include "SYS.h"\nRSYSCALL(${.PREFIX})\n' >> ${.TARGET} + printf '\t.section .note.GNU-stack,"",%%progbits\n' >>${.TARGET} ${SPSEUDO}: printf '#include "compat.h"\n' > ${.TARGET} printf '#include "SYS.h"\nPSEUDO(${.PREFIX:S/_//})\n' \ >> ${.TARGET} + printf '\t.section .note.GNU-stack,"",%%progbits\n' >>${.TARGET} MAN+= abort2.2 accept.2 access.2 acct.2 adjtime.2 \ aio_cancel.2 aio_error.2 aio_read.2 aio_return.2 \ From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 14:32:29 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F2098106566C; Fri, 7 Jan 2011 14:32:29 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C720F8FC18; Fri, 7 Jan 2011 14:32:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07EWTIZ055442; Fri, 7 Jan 2011 14:32:29 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07EWToA055439; Fri, 7 Jan 2011 14:32:29 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071432.p07EWToA055439@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 14:32:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217100 - head/share/mk X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 14:32:30 -0000 Author: kib Date: Fri Jan 7 14:32:29 2011 New Revision: 217100 URL: http://svn.freebsd.org/changeset/base/217100 Log: Introduce make variable ACFLAGS used to supply additional flags to cc driver when compiling assembler source file that is preprocessed. Modified: head/share/mk/bsd.lib.mk head/share/mk/sys.mk Modified: head/share/mk/bsd.lib.mk ============================================================================== --- head/share/mk/bsd.lib.mk Fri Jan 7 14:28:54 2011 (r217099) +++ head/share/mk/bsd.lib.mk Fri Jan 7 14:32:29 2011 (r217100) @@ -120,26 +120,27 @@ PO_FLAG=-pg ${CTFCONVERT} ${CTFFLAGS} ${.TARGET}) .asm.po: - ${CC} -x assembler-with-cpp -DPROF ${PO_CFLAGS} -c ${.IMPSRC} -o ${.TARGET} + ${CC} -x assembler-with-cpp -DPROF ${PO_CFLAGS} ${ACFLAGS} \ + -c ${.IMPSRC} -o ${.TARGET} @[ -z "${CTFCONVERT}" -o -n "${NO_CTF}" ] || \ (${ECHO} ${CTFCONVERT} ${CTFFLAGS} ${.TARGET} && \ ${CTFCONVERT} ${CTFFLAGS} ${.TARGET}) .asm.So: - ${CC} -x assembler-with-cpp ${PICFLAG} -DPIC ${CFLAGS} \ + ${CC} -x assembler-with-cpp ${PICFLAG} -DPIC ${CFLAGS} ${ACFLAGS} \ -c ${.IMPSRC} -o ${.TARGET} @[ -z "${CTFCONVERT}" -o -n "${NO_CTF}" ] || \ (${ECHO} ${CTFCONVERT} ${CTFFLAGS} ${.TARGET} && \ ${CTFCONVERT} ${CTFFLAGS} ${.TARGET}) .S.po: - ${CC} -DPROF ${PO_CFLAGS} -c ${.IMPSRC} -o ${.TARGET} + ${CC} -DPROF ${PO_CFLAGS} ${ACFLAGS} -c ${.IMPSRC} -o ${.TARGET} @[ -z "${CTFCONVERT}" -o -n "${NO_CTF}" ] || \ (${ECHO} ${CTFCONVERT} ${CTFFLAGS} ${.TARGET} && \ ${CTFCONVERT} ${CTFFLAGS} ${.TARGET}) .S.So: - ${CC} ${PICFLAG} -DPIC ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET} + ${CC} ${PICFLAG} -DPIC ${CFLAGS} ${ACFLAGS} -c ${.IMPSRC} -o ${.TARGET} @[ -z "${CTFCONVERT}" -o -n "${NO_CTF}" ] || \ (${ECHO} ${CTFCONVERT} ${CTFFLAGS} ${.TARGET} && \ ${CTFCONVERT} ${CTFFLAGS} ${.TARGET}) Modified: head/share/mk/sys.mk ============================================================================== --- head/share/mk/sys.mk Fri Jan 7 14:28:54 2011 (r217099) +++ head/share/mk/sys.mk Fri Jan 7 14:32:29 2011 (r217100) @@ -41,6 +41,7 @@ RANLIB ?= ranlib AS ?= as AFLAGS ?= +ACFLAGS ?= .if defined(%POSIX) CC ?= c89 @@ -275,13 +276,13 @@ YFLAGS ?= -d ${FC} ${RFLAGS} ${EFLAGS} ${FFLAGS} -c ${.IMPSRC} .S.o: - ${CC} ${CFLAGS} -c ${.IMPSRC} + ${CC} ${CFLAGS} ${ACFLAGS} -c ${.IMPSRC} @[ -z "${CTFCONVERT}" -o -n "${NO_CTF}" ] || \ (${ECHO} ${CTFCONVERT} ${CTFFLAGS} ${.TARGET} && \ ${CTFCONVERT} ${CTFFLAGS} ${.TARGET}) .asm.o: - ${CC} -x assembler-with-cpp ${CFLAGS} -c ${.IMPSRC} + ${CC} -x assembler-with-cpp ${CFLAGS} ${ACFLAGS} -c ${.IMPSRC} @[ -z "${CTFCONVERT}" -o -n "${NO_CTF}" ] || \ (${ECHO} ${CTFCONVERT} ${CTFFLAGS} ${.TARGET} && \ ${CTFCONVERT} ${CTFFLAGS} ${.TARGET}) From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 14:35:46 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3BA11106564A; Fri, 7 Jan 2011 14:35:46 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2B1B38FC12; Fri, 7 Jan 2011 14:35:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07EZkHD055562; Fri, 7 Jan 2011 14:35:46 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07EZkNU055560; Fri, 7 Jan 2011 14:35:46 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071435.p07EZkNU055560@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 14:35:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217101 - head/lib/libcompiler_rt X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 14:35:46 -0000 Author: kib Date: Fri Jan 7 14:35:45 2011 New Revision: 217101 URL: http://svn.freebsd.org/changeset/base/217101 Log: On amd64 and i386, force assembler to mark objects compiled from the assembler source for libcompiler_rt as not needed executable stack. This is done with a hammer instead of properly marking each assembly file with section .note.GNU-stack to avoid modifying contributed source. Discussed with: ed Modified: head/lib/libcompiler_rt/Makefile Modified: head/lib/libcompiler_rt/Makefile ============================================================================== --- head/lib/libcompiler_rt/Makefile Fri Jan 7 14:32:29 2011 (r217100) +++ head/lib/libcompiler_rt/Makefile Fri Jan 7 14:35:45 2011 (r217101) @@ -156,4 +156,10 @@ SYMLINKS+=libcompiler_rt_p.a ${LIBDIR}/l . endif .endif +.if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386" +AFLAGS+=--noexecstack +ACFLAGS+=-Wl,a,--noexecstack +.endif + + .include From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 15:05:26 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 63094106564A; Fri, 7 Jan 2011 15:05:26 +0000 (UTC) (envelope-from swell.k@gmail.com) Received: from mail-ww0-f50.google.com (mail-ww0-f50.google.com [74.125.82.50]) by mx1.freebsd.org (Postfix) with ESMTP id 6B2AB8FC08; Fri, 7 Jan 2011 15:05:24 +0000 (UTC) Received: by wwf26 with SMTP id 26so17268074wwf.31 for ; Fri, 07 Jan 2011 07:05:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:references :date:in-reply-to:message-id:user-agent:mime-version:content-type; bh=iKKCPn0l71M/KrCBwZnjfK/tKevMbROvYuD0IgXkXco=; b=uYKEhLlPJqT3/4fjogDBCQNHuocOE+umpWjLGzv5f4d5W6QsyJVngLAFlxx6AL4ejL TC9GoWYsZs8iH4dYD7ricM6lLH/uSa1cqAMwPF8KEZ+mufWViwdbHdmAp+tXjfs2LE1i viXXbofOPy1XwUD5XdGq9hqLCAhWBkr/NpDRI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; b=gWMwYKvj7sgCcvkBtZ75f+jUHuUqLBP0fkdc7idbowBXqL/YFq2WPOrOvFXPlXGoWY 0G6zCLxV3oB4hstfw36otMojhd8FVEXKC9Um8HO3X6EreE5UNoaEO93k4oF3CNYRjVqc BhwC7km2wNONPXMuTx8fitBeprn0K0nVQAsZg= Received: by 10.216.160.129 with SMTP id u1mr1502255wek.88.1294412723622; Fri, 07 Jan 2011 07:05:23 -0800 (PST) Received: from localhost ([188.72.223.162]) by mx.google.com with ESMTPS id n18sm12467125wee.40.2011.01.07.07.05.20 (version=SSLv3 cipher=RC4-MD5); Fri, 07 Jan 2011 07:05:22 -0800 (PST) From: Anonymous To: Konstantin Belousov References: <201101071435.p07EZkNU055560__46495.048949919$1294410977$gmane$org@svn.freebsd.org> Date: Fri, 07 Jan 2011 18:05:16 +0300 In-Reply-To: <201101071435.p07EZkNU055560__46495.048949919$1294410977$gmane$org@svn.freebsd.org> (Konstantin Belousov's message of "Fri, 7 Jan 2011 14:35:46 +0000 (UTC)") Message-ID: <8662u0ycsz.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217101 - head/lib/libcompiler_rt X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 15:05:26 -0000 Konstantin Belousov writes: > Author: kib > Date: Fri Jan 7 14:35:45 2011 > New Revision: 217101 > URL: http://svn.freebsd.org/changeset/base/217101 > > Log: > On amd64 and i386, force assembler to mark objects compiled from the > assembler source for libcompiler_rt as not needed executable stack. This > is done with a hammer instead of properly marking each assembly file > with section .note.GNU-stack to avoid modifying contributed source. > > Discussed with: ed > > Modified: > head/lib/libcompiler_rt/Makefile > > Modified: head/lib/libcompiler_rt/Makefile > ============================================================================== > --- head/lib/libcompiler_rt/Makefile Fri Jan 7 14:32:29 2011 (r217100) > +++ head/lib/libcompiler_rt/Makefile Fri Jan 7 14:35:45 2011 (r217101) > @@ -156,4 +156,10 @@ SYMLINKS+=libcompiler_rt_p.a ${LIBDIR}/l > . endif > .endif > > +.if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386" > +AFLAGS+=--noexecstack > +ACFLAGS+=-Wl,a,--noexecstack > +.endif Typo? -Wl,a,--foo vs. -Wa,--foo. From gcc(1) manpage Assembler Option -Wa,option -Xassembler option Linker Options -Wl,option -Xlinker option From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 15:59:23 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B2F62106564A; Fri, 7 Jan 2011 15:59:23 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A210B8FC0A; Fri, 7 Jan 2011 15:59:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07FxN3c057427; Fri, 7 Jan 2011 15:59:23 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07FxNRV057425; Fri, 7 Jan 2011 15:59:23 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071559.p07FxNRV057425@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 15:59:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217102 - head/lib/libcompiler_rt X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 15:59:23 -0000 Author: kib Date: Fri Jan 7 15:59:23 2011 New Revision: 217102 URL: http://svn.freebsd.org/changeset/base/217102 Log: Fix braino in r217101. -Wa is used to supply assembler flag to cc driver. Noted by: Anonymous Modified: head/lib/libcompiler_rt/Makefile Modified: head/lib/libcompiler_rt/Makefile ============================================================================== --- head/lib/libcompiler_rt/Makefile Fri Jan 7 14:35:45 2011 (r217101) +++ head/lib/libcompiler_rt/Makefile Fri Jan 7 15:59:23 2011 (r217102) @@ -158,7 +158,7 @@ SYMLINKS+=libcompiler_rt_p.a ${LIBDIR}/l .if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386" AFLAGS+=--noexecstack -ACFLAGS+=-Wl,a,--noexecstack +ACFLAGS+=-Wa,--noexecstack .endif From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:06:56 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A88B11065740; Fri, 7 Jan 2011 16:06:56 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id 1E13D8FC16; Fri, 7 Jan 2011 16:06:55 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id p07G6qMd093695 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 7 Jan 2011 18:06:52 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id p07G6qAA033967; Fri, 7 Jan 2011 18:06:52 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id p07G6qXx033966; Fri, 7 Jan 2011 18:06:52 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 7 Jan 2011 18:06:52 +0200 From: Kostik Belousov To: Anonymous Message-ID: <20110107160652.GY12599@deviant.kiev.zoral.com.ua> References: <201101071435.p07EZkNU055560__46495.048949919$1294410977$gmane$org@svn.freebsd.org> <8662u0ycsz.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="wHYmV+hLPeNaasdK" Content-Disposition: inline In-Reply-To: <8662u0ycsz.fsf@gmail.com> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217101 - head/lib/libcompiler_rt X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:06:56 -0000 --wHYmV+hLPeNaasdK Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jan 07, 2011 at 06:05:16PM +0300, Anonymous wrote: > Konstantin Belousov writes: >=20 > > Author: kib > > Date: Fri Jan 7 14:35:45 2011 > > New Revision: 217101 > > URL: http://svn.freebsd.org/changeset/base/217101 > > > > Log: > > On amd64 and i386, force assembler to mark objects compiled from the > > assembler source for libcompiler_rt as not needed executable stack. T= his > > is done with a hammer instead of properly marking each assembly file > > with section .note.GNU-stack to avoid modifying contributed source. > > =20 > > Discussed with: ed > > > > Modified: > > head/lib/libcompiler_rt/Makefile > > > > Modified: head/lib/libcompiler_rt/Makefile > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D > > --- head/lib/libcompiler_rt/Makefile Fri Jan 7 14:32:29 2011 (r217100) > > +++ head/lib/libcompiler_rt/Makefile Fri Jan 7 14:35:45 2011 (r217101) > > @@ -156,4 +156,10 @@ SYMLINKS+=3Dlibcompiler_rt_p.a ${LIBDIR}/l > > . endif > > .endif > > =20 > > +.if ${MACHINE_CPUARCH} =3D=3D "amd64" || ${MACHINE_CPUARCH} =3D=3D "i3= 86" > > +AFLAGS+=3D--noexecstack > > +ACFLAGS+=3D-Wl,a,--noexecstack > > +.endif >=20 > Typo? -Wl,a,--foo vs. -Wa,--foo. From gcc(1) manpage >=20 > Assembler Option > -Wa,option -Xassembler option >=20 > Linker Options > -Wl,option -Xlinker option Thank you. Should be fixed in r217102. --wHYmV+hLPeNaasdK Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk0nOhsACgkQC3+MBN1Mb4jCTACdHTxRpNpkOknLPxTjKg8VzGqR XIoAn1O6dU1kMTuz2mCMyfKyUv9/5fn/ =ON1C -----END PGP SIGNATURE----- --wHYmV+hLPeNaasdK-- From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:07:06 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 44FA91065670; Fri, 7 Jan 2011 16:07:06 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 203A98FC15; Fri, 7 Jan 2011 16:07:06 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07G76DH057682; Fri, 7 Jan 2011 16:07:06 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07G7617057679; Fri, 7 Jan 2011 16:07:06 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071607.p07G7617057679@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 16:07:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217103 - in head/libexec/rtld-elf: amd64 i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:07:06 -0000 Author: kib Date: Fri Jan 7 16:07:05 2011 New Revision: 217103 URL: http://svn.freebsd.org/changeset/base/217103 Log: Add section .note.GNU-stack for assembly files used by 386 and amd64. Modified: head/libexec/rtld-elf/amd64/rtld_start.S head/libexec/rtld-elf/i386/rtld_start.S Modified: head/libexec/rtld-elf/amd64/rtld_start.S ============================================================================== --- head/libexec/rtld-elf/amd64/rtld_start.S Fri Jan 7 15:59:23 2011 (r217102) +++ head/libexec/rtld-elf/amd64/rtld_start.S Fri Jan 7 16:07:05 2011 (r217103) @@ -112,3 +112,5 @@ _rtld_bind_start: popfq # Restore rflags leaq 16(%rsp),%rsp # Discard spare, obj, do not change rflags ret # "Return" to target address + + .section .note.GNU-stack,"",%progbits Modified: head/libexec/rtld-elf/i386/rtld_start.S ============================================================================== --- head/libexec/rtld-elf/i386/rtld_start.S Fri Jan 7 15:59:23 2011 (r217102) +++ head/libexec/rtld-elf/i386/rtld_start.S Fri Jan 7 16:07:05 2011 (r217103) @@ -89,3 +89,5 @@ _rtld_bind_start: popf # Restore eflags leal 4(%esp),%esp # Discard reloff, do not change eflags ret # "Return" to target address + + .section .note.GNU-stack,"",%progbits From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:07:29 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 56A15106566C; Fri, 7 Jan 2011 16:07:29 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4600A8FC18; Fri, 7 Jan 2011 16:07:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07G7Tlk057723; Fri, 7 Jan 2011 16:07:29 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07G7TTP057721; Fri, 7 Jan 2011 16:07:29 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101071607.p07G7TTP057721@svn.freebsd.org> From: John Baldwin Date: Fri, 7 Jan 2011 16:07:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217104 - head/sys/dev/mxge X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:07:29 -0000 Author: jhb Date: Fri Jan 7 16:07:29 2011 New Revision: 217104 URL: http://svn.freebsd.org/changeset/base/217104 Log: Use a regular taskqueue rather than a fast taskqueue for mxge(4). Reviewed by: gallatin Modified: head/sys/dev/mxge/if_mxge.c Modified: head/sys/dev/mxge/if_mxge.c ============================================================================== --- head/sys/dev/mxge/if_mxge.c Fri Jan 7 16:07:05 2011 (r217103) +++ head/sys/dev/mxge/if_mxge.c Fri Jan 7 16:07:29 2011 (r217104) @@ -4647,9 +4647,8 @@ mxge_attach(device_t dev) mxge_fetch_tunables(sc); TASK_INIT(&sc->watchdog_task, 1, mxge_watchdog_task, sc); - sc->tq = taskqueue_create_fast("mxge_taskq", M_WAITOK, - taskqueue_thread_enqueue, - &sc->tq); + sc->tq = taskqueue_create("mxge_taskq", M_WAITOK, + taskqueue_thread_enqueue, &sc->tq); if (sc->tq == NULL) { err = ENOMEM; goto abort_with_nothing; From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:07:52 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 607421065695; Fri, 7 Jan 2011 16:07:52 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 34F648FC15; Fri, 7 Jan 2011 16:07:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07G7qLP057770; Fri, 7 Jan 2011 16:07:52 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07G7qsx057764; Fri, 7 Jan 2011 16:07:52 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071607.p07G7qsx057764@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 16:07:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217105 - in head/lib/csu: amd64 i386-elf X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:07:52 -0000 Author: kib Date: Fri Jan 7 16:07:51 2011 New Revision: 217105 URL: http://svn.freebsd.org/changeset/base/217105 Log: Add section .note.GNU-stack for assembly files used by 386 and amd64. Modified: head/lib/csu/amd64/crti.S head/lib/csu/amd64/crtn.S head/lib/csu/i386-elf/crt1_s.S head/lib/csu/i386-elf/crti.S head/lib/csu/i386-elf/crtn.S Modified: head/lib/csu/amd64/crti.S ============================================================================== --- head/lib/csu/amd64/crti.S Fri Jan 7 16:07:29 2011 (r217104) +++ head/lib/csu/amd64/crti.S Fri Jan 7 16:07:51 2011 (r217105) @@ -39,3 +39,5 @@ _init: .type _fini,@function _fini: subq $8,%rsp + + .section .note.GNU-stack,"",%progbits Modified: head/lib/csu/amd64/crtn.S ============================================================================== --- head/lib/csu/amd64/crtn.S Fri Jan 7 16:07:29 2011 (r217104) +++ head/lib/csu/amd64/crtn.S Fri Jan 7 16:07:51 2011 (r217105) @@ -33,3 +33,5 @@ __FBSDID("$FreeBSD$"); .section .fini,"ax",@progbits addq $8,%rsp ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/csu/i386-elf/crt1_s.S ============================================================================== --- head/lib/csu/i386-elf/crt1_s.S Fri Jan 7 16:07:29 2011 (r217104) +++ head/lib/csu/i386-elf/crt1_s.S Fri Jan 7 16:07:51 2011 (r217105) @@ -49,3 +49,5 @@ _start: int3 .cfi_endproc .size _start, . - _start + + .section .note.GNU-stack,"",%progbits Modified: head/lib/csu/i386-elf/crti.S ============================================================================== --- head/lib/csu/i386-elf/crti.S Fri Jan 7 16:07:29 2011 (r217104) +++ head/lib/csu/i386-elf/crti.S Fri Jan 7 16:07:51 2011 (r217105) @@ -39,3 +39,5 @@ _init: .type _fini,@function _fini: sub $12,%esp /* re-align stack pointer */ + + .section .note.GNU-stack,"",%progbits Modified: head/lib/csu/i386-elf/crtn.S ============================================================================== --- head/lib/csu/i386-elf/crtn.S Fri Jan 7 16:07:29 2011 (r217104) +++ head/lib/csu/i386-elf/crtn.S Fri Jan 7 16:07:51 2011 (r217105) @@ -33,3 +33,5 @@ __FBSDID("$FreeBSD$"); .section .fini,"ax",@progbits add $12,%esp ret + + .section .note.GNU-stack,"",%progbits From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:08:41 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AEBC6106566B; Fri, 7 Jan 2011 16:08:41 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9AEE28FC13; Fri, 7 Jan 2011 16:08:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07G8fTC057899; Fri, 7 Jan 2011 16:08:41 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07G8eDh057826; Fri, 7 Jan 2011 16:08:40 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071608.p07G8eDh057826@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 16:08:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217106 - in head/lib/libc: amd64/gen amd64/stdlib amd64/string amd64/sys i386/gen i386/stdlib i386/string i386/sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:08:41 -0000 Author: kib Date: Fri Jan 7 16:08:40 2011 New Revision: 217106 URL: http://svn.freebsd.org/changeset/base/217106 Log: Add section .note.GNU-stack for assembly files used by 386 and amd64. Modified: head/lib/libc/amd64/gen/_setjmp.S head/lib/libc/amd64/gen/fabs.S head/lib/libc/amd64/gen/modf.S head/lib/libc/amd64/gen/rfork_thread.S head/lib/libc/amd64/gen/setjmp.S head/lib/libc/amd64/gen/sigsetjmp.S head/lib/libc/amd64/stdlib/div.S head/lib/libc/amd64/stdlib/ldiv.S head/lib/libc/amd64/stdlib/lldiv.S head/lib/libc/amd64/string/bcmp.S head/lib/libc/amd64/string/bcopy.S head/lib/libc/amd64/string/bzero.S head/lib/libc/amd64/string/memcmp.S head/lib/libc/amd64/string/memmove.S head/lib/libc/amd64/string/memset.S head/lib/libc/amd64/string/strcat.S head/lib/libc/amd64/string/strcmp.S head/lib/libc/amd64/string/strcpy.S head/lib/libc/amd64/sys/brk.S head/lib/libc/amd64/sys/cerror.S head/lib/libc/amd64/sys/exect.S head/lib/libc/amd64/sys/getcontext.S head/lib/libc/amd64/sys/pipe.S head/lib/libc/amd64/sys/ptrace.S head/lib/libc/amd64/sys/reboot.S head/lib/libc/amd64/sys/sbrk.S head/lib/libc/amd64/sys/setlogin.S head/lib/libc/amd64/sys/sigreturn.S head/lib/libc/amd64/sys/vfork.S head/lib/libc/i386/gen/_ctx_start.S head/lib/libc/i386/gen/_setjmp.S head/lib/libc/i386/gen/fabs.S head/lib/libc/i386/gen/modf.S head/lib/libc/i386/gen/rfork_thread.S head/lib/libc/i386/gen/setjmp.S head/lib/libc/i386/gen/sigsetjmp.S head/lib/libc/i386/stdlib/div.S head/lib/libc/i386/stdlib/ldiv.S head/lib/libc/i386/string/bcmp.S head/lib/libc/i386/string/bcopy.S head/lib/libc/i386/string/bzero.S head/lib/libc/i386/string/ffs.S head/lib/libc/i386/string/index.S head/lib/libc/i386/string/memchr.S head/lib/libc/i386/string/memcmp.S head/lib/libc/i386/string/memcpy.S head/lib/libc/i386/string/memmove.S head/lib/libc/i386/string/memset.S head/lib/libc/i386/string/rindex.S head/lib/libc/i386/string/strcat.S head/lib/libc/i386/string/strchr.S head/lib/libc/i386/string/strcmp.S head/lib/libc/i386/string/strcpy.S head/lib/libc/i386/string/strncmp.S head/lib/libc/i386/string/strrchr.S head/lib/libc/i386/string/swab.S head/lib/libc/i386/string/wcschr.S head/lib/libc/i386/string/wcscmp.S head/lib/libc/i386/string/wcslen.S head/lib/libc/i386/string/wmemchr.S head/lib/libc/i386/sys/Ovfork.S head/lib/libc/i386/sys/brk.S head/lib/libc/i386/sys/cerror.S head/lib/libc/i386/sys/exect.S head/lib/libc/i386/sys/getcontext.S head/lib/libc/i386/sys/pipe.S head/lib/libc/i386/sys/ptrace.S head/lib/libc/i386/sys/reboot.S head/lib/libc/i386/sys/sbrk.S head/lib/libc/i386/sys/setlogin.S head/lib/libc/i386/sys/sigreturn.S head/lib/libc/i386/sys/syscall.S Modified: head/lib/libc/amd64/gen/_setjmp.S ============================================================================== --- head/lib/libc/amd64/gen/_setjmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/gen/_setjmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -92,3 +92,5 @@ ENTRY(___longjmp) 1: movq %rcx,0(%rsp) ret END(___longjmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/gen/fabs.S ============================================================================== --- head/lib/libc/amd64/gen/fabs.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/gen/fabs.S Fri Jan 7 16:08:40 2011 (r217106) @@ -42,3 +42,5 @@ END(fabs) .data signbit: .quad 0x8000000000000000 + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/gen/modf.S ============================================================================== --- head/lib/libc/amd64/gen/modf.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/gen/modf.S Fri Jan 7 16:08:40 2011 (r217106) @@ -87,3 +87,5 @@ ENTRY(modf) ret END(modf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/gen/rfork_thread.S ============================================================================== --- head/lib/libc/amd64/gen/rfork_thread.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/gen/rfork_thread.S Fri Jan 7 16:08:40 2011 (r217106) @@ -100,3 +100,5 @@ ENTRY(rfork_thread) jmp HIDENAME(cerror) #endif END(rfork_thread) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/gen/setjmp.S ============================================================================== --- head/lib/libc/amd64/gen/setjmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/gen/setjmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -110,3 +110,5 @@ ENTRY(__longjmp) 1: movq %rcx,0(%rsp) ret END(__longjmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/gen/sigsetjmp.S ============================================================================== --- head/lib/libc/amd64/gen/sigsetjmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/gen/sigsetjmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -111,3 +111,5 @@ ENTRY(__siglongjmp) 1: movq %rcx,0(%rsp) ret END(__siglongjmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/stdlib/div.S ============================================================================== --- head/lib/libc/amd64/stdlib/div.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/stdlib/div.S Fri Jan 7 16:08:40 2011 (r217106) @@ -16,3 +16,5 @@ ENTRY(div) orq %rdx,%rax ret END(div) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/stdlib/ldiv.S ============================================================================== --- head/lib/libc/amd64/stdlib/ldiv.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/stdlib/ldiv.S Fri Jan 7 16:08:40 2011 (r217106) @@ -14,3 +14,5 @@ ENTRY(ldiv) idivq %rsi ret END(ldiv) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/stdlib/lldiv.S ============================================================================== --- head/lib/libc/amd64/stdlib/lldiv.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/stdlib/lldiv.S Fri Jan 7 16:08:40 2011 (r217106) @@ -14,3 +14,5 @@ ENTRY(lldiv) idivq %rsi ret END(lldiv) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/bcmp.S ============================================================================== --- head/lib/libc/amd64/string/bcmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/bcmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -23,3 +23,5 @@ L1: movsbl %al,%eax ret END(bcmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/bcopy.S ============================================================================== --- head/lib/libc/amd64/string/bcopy.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/bcopy.S Fri Jan 7 16:08:40 2011 (r217106) @@ -95,3 +95,5 @@ END(memmove) END(bcopy) #endif #endif + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/bzero.S ============================================================================== --- head/lib/libc/amd64/string/bzero.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/bzero.S Fri Jan 7 16:08:40 2011 (r217106) @@ -42,3 +42,5 @@ L1: movq %rsi,%rcx /* zero remainder by ret END(bzero) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/memcmp.S ============================================================================== --- head/lib/libc/amd64/string/memcmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/memcmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -40,3 +40,5 @@ L6: xorl %eax,%eax /* Perform unsigned subl %edx,%eax ret END(memcmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/memmove.S ============================================================================== --- head/lib/libc/amd64/string/memmove.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/memmove.S Fri Jan 7 16:08:40 2011 (r217106) @@ -3,3 +3,5 @@ #define MEMMOVE #include "bcopy.S" + + .section .note.GNU-stack,"",%progbist Modified: head/lib/libc/amd64/string/memset.S ============================================================================== --- head/lib/libc/amd64/string/memset.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/memset.S Fri Jan 7 16:08:40 2011 (r217106) @@ -59,3 +59,5 @@ L1: rep ret END(memset) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/strcat.S ============================================================================== --- head/lib/libc/amd64/string/strcat.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/strcat.S Fri Jan 7 16:08:40 2011 (r217106) @@ -164,3 +164,5 @@ ENTRY(strcat) .Ldone: ret END(strcat) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/strcmp.S ============================================================================== --- head/lib/libc/amd64/string/strcmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/strcmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -72,3 +72,5 @@ ENTRY(strcmp) subq %rdx,%rax ret END(strcmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/string/strcpy.S ============================================================================== --- head/lib/libc/amd64/string/strcpy.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/string/strcpy.S Fri Jan 7 16:08:40 2011 (r217106) @@ -110,3 +110,5 @@ ENTRY(strcpy) .Ldone: ret END(strcpy) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/brk.S ============================================================================== --- head/lib/libc/amd64/sys/brk.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/brk.S Fri Jan 7 16:08:40 2011 (r217106) @@ -83,3 +83,5 @@ err: jmp HIDENAME(cerror) #endif END(brk) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/cerror.S ============================================================================== --- head/lib/libc/amd64/sys/cerror.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/cerror.S Fri Jan 7 16:08:40 2011 (r217106) @@ -56,3 +56,4 @@ HIDENAME(cerror): movq $-1,%rdx ret + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/exect.S ============================================================================== --- head/lib/libc/amd64/sys/exect.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/exect.S Fri Jan 7 16:08:40 2011 (r217106) @@ -54,3 +54,5 @@ ENTRY(exect) jmp HIDENAME(cerror) #endif END(exect) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/getcontext.S ============================================================================== --- head/lib/libc/amd64/sys/getcontext.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/getcontext.S Fri Jan 7 16:08:40 2011 (r217106) @@ -53,3 +53,5 @@ ENTRY(__sys_getcontext) jmp HIDENAME(cerror) #endif END(__sys_getcontext) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/pipe.S ============================================================================== --- head/lib/libc/amd64/sys/pipe.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/pipe.S Fri Jan 7 16:08:40 2011 (r217106) @@ -58,3 +58,5 @@ ENTRY(__sys_pipe) jmp HIDENAME(cerror) #endif END(__sys_pipe) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/ptrace.S ============================================================================== --- head/lib/libc/amd64/sys/ptrace.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/ptrace.S Fri Jan 7 16:08:40 2011 (r217106) @@ -58,3 +58,5 @@ err: jmp HIDENAME(cerror) #endif END(ptrace) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/reboot.S ============================================================================== --- head/lib/libc/amd64/sys/reboot.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/reboot.S Fri Jan 7 16:08:40 2011 (r217106) @@ -55,3 +55,5 @@ ENTRY(__sys_reboot) jmp HIDENAME(cerror) #endif END(__sys_reboot) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/sbrk.S ============================================================================== --- head/lib/libc/amd64/sys/sbrk.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/sbrk.S Fri Jan 7 16:08:40 2011 (r217106) @@ -86,3 +86,5 @@ err: jmp HIDENAME(cerror) #endif END(sbrk) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/setlogin.S ============================================================================== --- head/lib/libc/amd64/sys/setlogin.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/setlogin.S Fri Jan 7 16:08:40 2011 (r217106) @@ -63,3 +63,5 @@ ENTRY(__sys_setlogin) jmp HIDENAME(cerror) #endif END(__sys_setlogin) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/sigreturn.S ============================================================================== --- head/lib/libc/amd64/sys/sigreturn.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/sigreturn.S Fri Jan 7 16:08:40 2011 (r217106) @@ -44,3 +44,5 @@ __FBSDID("$FreeBSD$"); */ RSYSCALL(sigreturn) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/amd64/sys/vfork.S ============================================================================== --- head/lib/libc/amd64/sys/vfork.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/amd64/sys/vfork.S Fri Jan 7 16:08:40 2011 (r217106) @@ -57,3 +57,5 @@ ENTRY(__sys_vfork) jmp HIDENAME(cerror) #endif END(__sys_vfork) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/gen/_ctx_start.S ============================================================================== --- head/lib/libc/i386/gen/_ctx_start.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/gen/_ctx_start.S Fri Jan 7 16:08:40 2011 (r217106) @@ -50,3 +50,5 @@ ENTRY(_ctx_start) call PIC_PLT(abort) /* fubar */ ret END(_ctx_start) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/gen/_setjmp.S ============================================================================== --- head/lib/libc/i386/gen/_setjmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/gen/_setjmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -78,3 +78,5 @@ ENTRY(___longjmp) 1: movl %ecx,0(%esp) ret END(___longjmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/gen/fabs.S ============================================================================== --- head/lib/libc/i386/gen/fabs.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/gen/fabs.S Fri Jan 7 16:08:40 2011 (r217106) @@ -41,3 +41,5 @@ ENTRY(fabs) fabs ret END(fabs) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/gen/modf.S ============================================================================== --- head/lib/libc/i386/gen/modf.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/gen/modf.S Fri Jan 7 16:08:40 2011 (r217106) @@ -83,3 +83,5 @@ ENTRY(modf) leave ret END(modf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/gen/rfork_thread.S ============================================================================== --- head/lib/libc/i386/gen/rfork_thread.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/gen/rfork_thread.S Fri Jan 7 16:08:40 2011 (r217106) @@ -116,3 +116,5 @@ ENTRY(rfork_thread) PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) END(rfork_thread) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/gen/setjmp.S ============================================================================== --- head/lib/libc/i386/gen/setjmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/gen/setjmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -98,3 +98,5 @@ ENTRY(__longjmp) 1: movl %ecx,0(%esp) ret END(__longjmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/gen/sigsetjmp.S ============================================================================== --- head/lib/libc/i386/gen/sigsetjmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/gen/sigsetjmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -110,3 +110,5 @@ ENTRY(__siglongjmp) 1: movl %ecx,0(%esp) ret END(__siglongjmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/stdlib/div.S ============================================================================== --- head/lib/libc/i386/stdlib/div.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/stdlib/div.S Fri Jan 7 16:08:40 2011 (r217106) @@ -35,3 +35,5 @@ ENTRY(div) idiv %ecx ret END(div) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/stdlib/ldiv.S ============================================================================== --- head/lib/libc/i386/stdlib/ldiv.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/stdlib/ldiv.S Fri Jan 7 16:08:40 2011 (r217106) @@ -38,3 +38,5 @@ ENTRY(ldiv) idiv %ecx ret END(ldiv) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/bcmp.S ============================================================================== --- head/lib/libc/i386/string/bcmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/bcmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -62,3 +62,5 @@ L1: popl %edi ret END(bcmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/bcopy.S ============================================================================== --- head/lib/libc/i386/string/bcopy.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/bcopy.S Fri Jan 7 16:08:40 2011 (r217106) @@ -106,3 +106,5 @@ END(memmove) END(bcopy) #endif #endif + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/bzero.S ============================================================================== --- head/lib/libc/i386/string/bzero.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/bzero.S Fri Jan 7 16:08:40 2011 (r217106) @@ -80,3 +80,5 @@ L1: rep popl %edi ret END(bzero) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/ffs.S ============================================================================== --- head/lib/libc/i386/string/ffs.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/ffs.S Fri Jan 7 16:08:40 2011 (r217106) @@ -52,3 +52,5 @@ ENTRY(ffs) L1: xorl %eax,%eax /* clear result */ ret END(ffs) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/index.S ============================================================================== --- head/lib/libc/i386/string/index.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/index.S Fri Jan 7 16:08:40 2011 (r217106) @@ -62,3 +62,5 @@ L2: popl %ebx ret END(index) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/memchr.S ============================================================================== --- head/lib/libc/i386/string/memchr.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/memchr.S Fri Jan 7 16:08:40 2011 (r217106) @@ -57,3 +57,5 @@ L1: xorl %eax,%eax popl %edi ret END(memchr) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/memcmp.S ============================================================================== --- head/lib/libc/i386/string/memcmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/memcmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -74,3 +74,5 @@ L6: movzbl -1(%edi),%eax /* Perform un popl %edi ret END(memcmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/memcpy.S ============================================================================== --- head/lib/libc/i386/string/memcpy.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/memcpy.S Fri Jan 7 16:08:40 2011 (r217106) @@ -3,3 +3,5 @@ __FBSDID("$FreeBSD$"); #define MEMCOPY #include "bcopy.S" + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/memmove.S ============================================================================== --- head/lib/libc/i386/string/memmove.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/memmove.S Fri Jan 7 16:08:40 2011 (r217106) @@ -3,3 +3,5 @@ __FBSDID("$FreeBSD$"); #define MEMMOVE #include "bcopy.S" + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/memset.S ============================================================================== --- head/lib/libc/i386/string/memset.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/memset.S Fri Jan 7 16:08:40 2011 (r217106) @@ -88,3 +88,5 @@ L1: rep popl %edi ret END(memset) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/rindex.S ============================================================================== --- head/lib/libc/i386/string/rindex.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/rindex.S Fri Jan 7 16:08:40 2011 (r217106) @@ -63,3 +63,5 @@ L2: popl %ebx ret END(rindex) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/strcat.S ============================================================================== --- head/lib/libc/i386/string/strcat.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/strcat.S Fri Jan 7 16:08:40 2011 (r217106) @@ -99,3 +99,5 @@ L2: popl %eax /* pop destination addre popl %edi /* restore edi */ ret END(strcat) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/strchr.S ============================================================================== --- head/lib/libc/i386/string/strchr.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/strchr.S Fri Jan 7 16:08:40 2011 (r217106) @@ -62,3 +62,5 @@ L2: popl %ebx ret END(strchr) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/strcmp.S ============================================================================== --- head/lib/libc/i386/string/strcmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/strcmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -118,3 +118,5 @@ L3: movzbl (%eax),%eax subl %edx,%eax ret END(strcmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/strcpy.S ============================================================================== --- head/lib/libc/i386/string/strcpy.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/strcpy.S Fri Jan 7 16:08:40 2011 (r217106) @@ -88,3 +88,5 @@ L1: movb (%edx),%al /* unroll loop, but L2: popl %eax /* pop dst address */ ret END(strcpy) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/strncmp.S ============================================================================== --- head/lib/libc/i386/string/strncmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/strncmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -165,3 +165,5 @@ L4: xorl %eax,%eax popl %ebx ret END(strncmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/strrchr.S ============================================================================== --- head/lib/libc/i386/string/strrchr.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/strrchr.S Fri Jan 7 16:08:40 2011 (r217106) @@ -63,3 +63,5 @@ L2: popl %ebx ret END(strrchr) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/swab.S ============================================================================== --- head/lib/libc/i386/string/swab.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/swab.S Fri Jan 7 16:08:40 2011 (r217106) @@ -98,3 +98,5 @@ L4: popl %edi popl %esi ret END(swab) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/wcschr.S ============================================================================== --- head/lib/libc/i386/string/wcschr.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/wcschr.S Fri Jan 7 16:08:40 2011 (r217106) @@ -75,3 +75,5 @@ no: popl %ebx xorl %eax,%eax ret END(wcschr) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/wcscmp.S ============================================================================== --- head/lib/libc/i386/string/wcscmp.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/wcscmp.S Fri Jan 7 16:08:40 2011 (r217106) @@ -78,3 +78,5 @@ no0: subl (%esi),%eax popl %edi ret END(wcscmp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/wcslen.S ============================================================================== --- head/lib/libc/i386/string/wcslen.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/wcslen.S Fri Jan 7 16:08:40 2011 (r217106) @@ -67,3 +67,5 @@ found1: incl %eax found0: popl %ebx ret END(wcslen) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/string/wmemchr.S ============================================================================== --- head/lib/libc/i386/string/wmemchr.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/string/wmemchr.S Fri Jan 7 16:08:40 2011 (r217106) @@ -104,3 +104,5 @@ no: xorl %eax,%eax popl %edi ret END(wmemchr) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/Ovfork.S ============================================================================== --- head/lib/libc/i386/sys/Ovfork.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/Ovfork.S Fri Jan 7 16:08:40 2011 (r217106) @@ -53,3 +53,5 @@ ENTRY(__sys_vfork) PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) END(__sys_vfork) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/brk.S ============================================================================== --- head/lib/libc/i386/sys/brk.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/brk.S Fri Jan 7 16:08:40 2011 (r217106) @@ -86,3 +86,5 @@ err: jmp HIDENAME(cerror) #endif END(brk) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/cerror.S ============================================================================== --- head/lib/libc/i386/sys/cerror.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/cerror.S Fri Jan 7 16:08:40 2011 (r217106) @@ -63,3 +63,4 @@ HIDENAME(cerror): movl $-1,%edx ret + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/exect.S ============================================================================== --- head/lib/libc/i386/sys/exect.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/exect.S Fri Jan 7 16:08:40 2011 (r217106) @@ -50,3 +50,5 @@ ENTRY(exect) PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) /* exect(file, argv, env); */ END(exect) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/getcontext.S ============================================================================== --- head/lib/libc/i386/sys/getcontext.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/getcontext.S Fri Jan 7 16:08:40 2011 (r217106) @@ -49,3 +49,5 @@ ENTRY(__sys_getcontext) PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) END(__sys_getcontext) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/pipe.S ============================================================================== --- head/lib/libc/i386/sys/pipe.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/pipe.S Fri Jan 7 16:08:40 2011 (r217106) @@ -45,3 +45,5 @@ SYSCALL(pipe) movl $0,%eax ret END(__sys_pipe) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/ptrace.S ============================================================================== --- head/lib/libc/i386/sys/ptrace.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/ptrace.S Fri Jan 7 16:08:40 2011 (r217106) @@ -56,3 +56,5 @@ err: PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) END(ptrace) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/reboot.S ============================================================================== --- head/lib/libc/i386/sys/reboot.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/reboot.S Fri Jan 7 16:08:40 2011 (r217106) @@ -41,3 +41,5 @@ __FBSDID("$FreeBSD$"); SYSCALL(reboot) iret END(__sys_reboot) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/sbrk.S ============================================================================== --- head/lib/libc/i386/sys/sbrk.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/sbrk.S Fri Jan 7 16:08:40 2011 (r217106) @@ -89,3 +89,5 @@ err: jmp HIDENAME(cerror) #endif /* PIC */ END(sbrk) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/setlogin.S ============================================================================== --- head/lib/libc/i386/sys/setlogin.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/setlogin.S Fri Jan 7 16:08:40 2011 (r217106) @@ -53,3 +53,5 @@ SYSCALL(setlogin) #endif ret /* setlogin(name) */ END(__sys_setlogin) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/sigreturn.S ============================================================================== --- head/lib/libc/i386/sys/sigreturn.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/sigreturn.S Fri Jan 7 16:08:40 2011 (r217106) @@ -44,3 +44,5 @@ __FBSDID("$FreeBSD$"); */ RSYSCALL(sigreturn) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libc/i386/sys/syscall.S ============================================================================== --- head/lib/libc/i386/sys/syscall.S Fri Jan 7 16:07:51 2011 (r217105) +++ head/lib/libc/i386/sys/syscall.S Fri Jan 7 16:08:40 2011 (r217106) @@ -51,3 +51,5 @@ ENTRY(syscall) PIC_PROLOGUE jmp PIC_PLT(HIDENAME(cerror)) END(syscall) + + .section .note.GNU-stack,"",%progbits From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:09:34 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5321B106566C; Fri, 7 Jan 2011 16:09:34 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 420218FC12; Fri, 7 Jan 2011 16:09:34 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07G9Y1x057955; Fri, 7 Jan 2011 16:09:34 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07G9Y9P057952; Fri, 7 Jan 2011 16:09:34 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071609.p07G9Y9P057952@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 16:09:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217107 - in head/lib/libthr/arch: amd64/amd64 i386/i386 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:09:34 -0000 Author: kib Date: Fri Jan 7 16:09:33 2011 New Revision: 217107 URL: http://svn.freebsd.org/changeset/base/217107 Log: Add section .note.GNU-stack for assembly files used by 386 and amd64. Modified: head/lib/libthr/arch/amd64/amd64/_umtx_op_err.S head/lib/libthr/arch/i386/i386/_umtx_op_err.S Modified: head/lib/libthr/arch/amd64/amd64/_umtx_op_err.S ============================================================================== --- head/lib/libthr/arch/amd64/amd64/_umtx_op_err.S Fri Jan 7 16:08:40 2011 (r217106) +++ head/lib/libthr/arch/amd64/amd64/_umtx_op_err.S Fri Jan 7 16:09:33 2011 (r217107) @@ -35,3 +35,5 @@ #define KERNCALL movq %rcx, %r10; syscall RSYSCALL_ERR(_umtx_op) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/libthr/arch/i386/i386/_umtx_op_err.S ============================================================================== --- head/lib/libthr/arch/i386/i386/_umtx_op_err.S Fri Jan 7 16:08:40 2011 (r217106) +++ head/lib/libthr/arch/i386/i386/_umtx_op_err.S Fri Jan 7 16:09:33 2011 (r217107) @@ -34,3 +34,5 @@ mov __CONCAT($SYS_,x),%eax; int $0x80; ret SYSCALL_ERR(_umtx_op) + + .section .note.GNU-stack,"",%progbits From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:13:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 47D76106566B; Fri, 7 Jan 2011 16:13:13 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 356518FC0C; Fri, 7 Jan 2011 16:13:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07GDDfh058150; Fri, 7 Jan 2011 16:13:13 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07GDCkd058081; Fri, 7 Jan 2011 16:13:12 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101071613.p07GDCkd058081@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Jan 2011 16:13:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217108 - in head/lib/msun: amd64 i387 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:13:13 -0000 Author: kib Date: Fri Jan 7 16:13:12 2011 New Revision: 217108 URL: http://svn.freebsd.org/changeset/base/217108 Log: Add section .note.GNU-stack for assembly files used by 386 and amd64. Modified: head/lib/msun/amd64/e_remainder.S head/lib/msun/amd64/e_remainderf.S head/lib/msun/amd64/e_remainderl.S head/lib/msun/amd64/e_sqrt.S head/lib/msun/amd64/e_sqrtf.S head/lib/msun/amd64/e_sqrtl.S head/lib/msun/amd64/s_llrint.S head/lib/msun/amd64/s_llrintf.S head/lib/msun/amd64/s_llrintl.S head/lib/msun/amd64/s_logbl.S head/lib/msun/amd64/s_lrint.S head/lib/msun/amd64/s_lrintf.S head/lib/msun/amd64/s_lrintl.S head/lib/msun/amd64/s_remquo.S head/lib/msun/amd64/s_remquof.S head/lib/msun/amd64/s_remquol.S head/lib/msun/amd64/s_rintl.S head/lib/msun/amd64/s_scalbn.S head/lib/msun/amd64/s_scalbnf.S head/lib/msun/amd64/s_scalbnl.S head/lib/msun/i387/e_exp.S head/lib/msun/i387/e_fmod.S head/lib/msun/i387/e_log.S head/lib/msun/i387/e_log10.S head/lib/msun/i387/e_log10f.S head/lib/msun/i387/e_logf.S head/lib/msun/i387/e_remainder.S head/lib/msun/i387/e_remainderf.S head/lib/msun/i387/e_remainderl.S head/lib/msun/i387/e_sqrt.S head/lib/msun/i387/e_sqrtf.S head/lib/msun/i387/e_sqrtl.S head/lib/msun/i387/s_ceil.S head/lib/msun/i387/s_ceilf.S head/lib/msun/i387/s_ceill.S head/lib/msun/i387/s_copysign.S head/lib/msun/i387/s_copysignf.S head/lib/msun/i387/s_copysignl.S head/lib/msun/i387/s_cos.S head/lib/msun/i387/s_finite.S head/lib/msun/i387/s_floor.S head/lib/msun/i387/s_floorf.S head/lib/msun/i387/s_floorl.S head/lib/msun/i387/s_llrint.S head/lib/msun/i387/s_llrintf.S head/lib/msun/i387/s_llrintl.S head/lib/msun/i387/s_logb.S head/lib/msun/i387/s_logbf.S head/lib/msun/i387/s_logbl.S head/lib/msun/i387/s_lrint.S head/lib/msun/i387/s_lrintf.S head/lib/msun/i387/s_lrintl.S head/lib/msun/i387/s_remquo.S head/lib/msun/i387/s_remquof.S head/lib/msun/i387/s_remquol.S head/lib/msun/i387/s_rint.S head/lib/msun/i387/s_rintf.S head/lib/msun/i387/s_rintl.S head/lib/msun/i387/s_scalbn.S head/lib/msun/i387/s_scalbnf.S head/lib/msun/i387/s_scalbnl.S head/lib/msun/i387/s_significand.S head/lib/msun/i387/s_significandf.S head/lib/msun/i387/s_sin.S head/lib/msun/i387/s_tan.S head/lib/msun/i387/s_trunc.S head/lib/msun/i387/s_truncf.S head/lib/msun/i387/s_truncl.S Modified: head/lib/msun/amd64/e_remainder.S ============================================================================== --- head/lib/msun/amd64/e_remainder.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/e_remainder.S Fri Jan 7 16:13:12 2011 (r217108) @@ -51,3 +51,5 @@ ENTRY(remainder) movsd -8(%rsp),%xmm0 fstp %st ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/e_remainderf.S ============================================================================== --- head/lib/msun/amd64/e_remainderf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/e_remainderf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -21,3 +21,5 @@ ENTRY(remainderf) movss -4(%rsp),%xmm0 fstp %st ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/e_remainderl.S ============================================================================== --- head/lib/msun/amd64/e_remainderl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/e_remainderl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -46,3 +46,5 @@ ENTRY(remainderl) jne 1b fstp %st(1) ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/e_sqrt.S ============================================================================== --- head/lib/msun/amd64/e_sqrt.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/e_sqrt.S Fri Jan 7 16:13:12 2011 (r217108) @@ -32,3 +32,5 @@ ENTRY(sqrt) ret END(sqrt) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/e_sqrtf.S ============================================================================== --- head/lib/msun/amd64/e_sqrtf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/e_sqrtf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -31,3 +31,5 @@ ENTRY(sqrtf) sqrtss %xmm0, %xmm0 ret END(sqrtf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/e_sqrtl.S ============================================================================== --- head/lib/msun/amd64/e_sqrtl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/e_sqrtl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -31,3 +31,5 @@ ENTRY(sqrtl) fldt 8(%rsp) fsqrt ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_llrint.S ============================================================================== --- head/lib/msun/amd64/s_llrint.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_llrint.S Fri Jan 7 16:13:12 2011 (r217108) @@ -4,3 +4,5 @@ __FBSDID("$FreeBSD$") /* sizeof(long) == sizeof(long long) */ #define fn llrint #include "s_lrint.S" + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_llrintf.S ============================================================================== --- head/lib/msun/amd64/s_llrintf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_llrintf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -4,3 +4,5 @@ __FBSDID("$FreeBSD$") /* sizeof(long) == sizeof(long long) */ #define fn llrintf #include "s_lrintf.S" + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_llrintl.S ============================================================================== --- head/lib/msun/amd64/s_llrintl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_llrintl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -33,3 +33,5 @@ ENTRY(llrintl) fistpll (%rsp) popq %rax ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_logbl.S ============================================================================== --- head/lib/msun/amd64/s_logbl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_logbl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -41,3 +41,5 @@ ENTRY(logbl) fxtract fstp %st ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_lrint.S ============================================================================== --- head/lib/msun/amd64/s_lrint.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_lrint.S Fri Jan 7 16:13:12 2011 (r217108) @@ -35,3 +35,5 @@ ENTRY(fn) cvtsd2si %xmm0, %rax ret END(fn) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_lrintf.S ============================================================================== --- head/lib/msun/amd64/s_lrintf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_lrintf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -35,3 +35,5 @@ ENTRY(fn) cvtss2si %xmm0, %rax ret END(fn) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_lrintl.S ============================================================================== --- head/lib/msun/amd64/s_lrintl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_lrintl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -33,3 +33,5 @@ ENTRY(lrintl) fistpll (%rsp) popq %rax ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_remquo.S ============================================================================== --- head/lib/msun/amd64/s_remquo.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_remquo.S Fri Jan 7 16:13:12 2011 (r217108) @@ -64,3 +64,5 @@ ENTRY(remquo) movsd -8(%rsp),%xmm0 ret END(remquo) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_remquof.S ============================================================================== --- head/lib/msun/amd64/s_remquof.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_remquof.S Fri Jan 7 16:13:12 2011 (r217108) @@ -64,3 +64,5 @@ ENTRY(remquof) movss -4(%rsp),%xmm0 ret END(remquof) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_remquol.S ============================================================================== --- head/lib/msun/amd64/s_remquol.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_remquol.S Fri Jan 7 16:13:12 2011 (r217108) @@ -60,3 +60,5 @@ ENTRY(remquol) /* Store the quotient and return. */ movl %eax,(%rdi) ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_rintl.S ============================================================================== --- head/lib/msun/amd64/s_rintl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_rintl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -41,3 +41,5 @@ ENTRY(rintl) fldt 8(%rsp) frndint ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_scalbn.S ============================================================================== --- head/lib/msun/amd64/s_scalbn.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_scalbn.S Fri Jan 7 16:13:12 2011 (r217108) @@ -38,3 +38,5 @@ ENTRY(scalbn) movsd -8(%rsp),%xmm0 ret END(scalbn) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_scalbnf.S ============================================================================== --- head/lib/msun/amd64/s_scalbnf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_scalbnf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -41,3 +41,5 @@ END(scalbnf) .globl CNAME(ldexpf) .set CNAME(ldexpf),CNAME(scalbnf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/amd64/s_scalbnl.S ============================================================================== --- head/lib/msun/amd64/s_scalbnl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/amd64/s_scalbnl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -18,3 +18,5 @@ END(scalbnl) .globl CNAME(ldexpl) .set CNAME(ldexpl),CNAME(scalbnl) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_exp.S ============================================================================== --- head/lib/msun/i387/e_exp.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_exp.S Fri Jan 7 16:13:12 2011 (r217108) @@ -96,3 +96,5 @@ x_not_minus_Inf: fldl 4(%esp) ret END(exp) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_fmod.S ============================================================================== --- head/lib/msun/i387/e_fmod.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_fmod.S Fri Jan 7 16:13:12 2011 (r217108) @@ -46,3 +46,5 @@ ENTRY(fmod) fstp %st(1) ret END(fmod) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_log.S ============================================================================== --- head/lib/msun/i387/e_log.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_log.S Fri Jan 7 16:13:12 2011 (r217108) @@ -42,3 +42,5 @@ ENTRY(log) fyl2x ret END(log) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_log10.S ============================================================================== --- head/lib/msun/i387/e_log10.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_log10.S Fri Jan 7 16:13:12 2011 (r217108) @@ -42,3 +42,5 @@ ENTRY(log10) fyl2x ret END(log10) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_log10f.S ============================================================================== --- head/lib/msun/i387/e_log10f.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_log10f.S Fri Jan 7 16:13:12 2011 (r217108) @@ -14,3 +14,5 @@ ENTRY(log10f) fyl2x ret END(log10f) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_logf.S ============================================================================== --- head/lib/msun/i387/e_logf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_logf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -13,3 +13,5 @@ ENTRY(logf) flds 4(%esp) fyl2x ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_remainder.S ============================================================================== --- head/lib/msun/i387/e_remainder.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_remainder.S Fri Jan 7 16:13:12 2011 (r217108) @@ -46,3 +46,5 @@ ENTRY(remainder) fstp %st(1) ret END(remainder) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_remainderf.S ============================================================================== --- head/lib/msun/i387/e_remainderf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_remainderf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -18,3 +18,5 @@ ENTRY(remainderf) fstp %st(1) ret END(remainderf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_remainderl.S ============================================================================== --- head/lib/msun/i387/e_remainderl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_remainderl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -46,3 +46,5 @@ ENTRY(remainderl) jp 1b fstp %st(1) ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_sqrt.S ============================================================================== --- head/lib/msun/i387/e_sqrt.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_sqrt.S Fri Jan 7 16:13:12 2011 (r217108) @@ -41,3 +41,5 @@ ENTRY(sqrt) fsqrt ret END(sqrt) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_sqrtf.S ============================================================================== --- head/lib/msun/i387/e_sqrtf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_sqrtf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -13,3 +13,5 @@ ENTRY(sqrtf) fsqrt ret END(sqrtf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/e_sqrtl.S ============================================================================== --- head/lib/msun/i387/e_sqrtl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/e_sqrtl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -40,3 +40,5 @@ ENTRY(sqrtl) fldt 4(%esp) fsqrt ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_ceil.S ============================================================================== --- head/lib/msun/i387/s_ceil.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_ceil.S Fri Jan 7 16:13:12 2011 (r217108) @@ -56,3 +56,5 @@ ENTRY(ceil) leave ret END(ceil) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_ceilf.S ============================================================================== --- head/lib/msun/i387/s_ceilf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_ceilf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -28,3 +28,5 @@ ENTRY(ceilf) leave ret END(ceilf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_ceill.S ============================================================================== --- head/lib/msun/i387/s_ceill.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_ceill.S Fri Jan 7 16:13:12 2011 (r217108) @@ -26,3 +26,5 @@ ENTRY(ceill) leave ret END(ceill) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_copysign.S ============================================================================== --- head/lib/msun/i387/s_copysign.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_copysign.S Fri Jan 7 16:13:12 2011 (r217108) @@ -46,3 +46,5 @@ ENTRY(copysign) fldl 4(%esp) ret END(copysign) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_copysignf.S ============================================================================== --- head/lib/msun/i387/s_copysignf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_copysignf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -18,3 +18,5 @@ ENTRY(copysignf) flds 4(%esp) ret END(copysignf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_copysignl.S ============================================================================== --- head/lib/msun/i387/s_copysignl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_copysignl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -16,3 +16,5 @@ ENTRY(copysignl) fldt 4(%esp) ret END(copysignl) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_cos.S ============================================================================== --- head/lib/msun/i387/s_cos.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_cos.S Fri Jan 7 16:13:12 2011 (r217108) @@ -54,3 +54,5 @@ ENTRY(cos) fcos ret END(cos) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_finite.S ============================================================================== --- head/lib/msun/i387/s_finite.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_finite.S Fri Jan 7 16:13:12 2011 (r217108) @@ -44,3 +44,5 @@ ENTRY(finite) andl $0x000000ff, %eax ret END(finite) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_floor.S ============================================================================== --- head/lib/msun/i387/s_floor.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_floor.S Fri Jan 7 16:13:12 2011 (r217108) @@ -56,3 +56,5 @@ ENTRY(floor) leave ret END(floor) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_floorf.S ============================================================================== --- head/lib/msun/i387/s_floorf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_floorf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -28,3 +28,5 @@ ENTRY(floorf) leave ret END(floorf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_floorl.S ============================================================================== --- head/lib/msun/i387/s_floorl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_floorl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -26,3 +26,5 @@ ENTRY(floorl) leave ret END(floorl) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_llrint.S ============================================================================== --- head/lib/msun/i387/s_llrint.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_llrint.S Fri Jan 7 16:13:12 2011 (r217108) @@ -35,3 +35,5 @@ ENTRY(llrint) popl %edx ret END(llrint) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_llrintf.S ============================================================================== --- head/lib/msun/i387/s_llrintf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_llrintf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -35,3 +35,5 @@ ENTRY(llrintf) popl %edx ret END(llrintf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_llrintl.S ============================================================================== --- head/lib/msun/i387/s_llrintl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_llrintl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -34,3 +34,5 @@ ENTRY(llrintl) popl %eax popl %edx ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_logb.S ============================================================================== --- head/lib/msun/i387/s_logb.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_logb.S Fri Jan 7 16:13:12 2011 (r217108) @@ -42,3 +42,5 @@ ENTRY(logb) fstp %st ret END(logb) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_logbf.S ============================================================================== --- head/lib/msun/i387/s_logbf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_logbf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -14,3 +14,5 @@ ENTRY(logbf) fstp %st ret END(logbf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_logbl.S ============================================================================== --- head/lib/msun/i387/s_logbl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_logbl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -41,3 +41,5 @@ ENTRY(logbl) fxtract fstp %st ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_lrint.S ============================================================================== --- head/lib/msun/i387/s_lrint.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_lrint.S Fri Jan 7 16:13:12 2011 (r217108) @@ -34,3 +34,5 @@ ENTRY(lrint) popl %eax ret END(lrint) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_lrintf.S ============================================================================== --- head/lib/msun/i387/s_lrintf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_lrintf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -34,3 +34,5 @@ ENTRY(lrintf) popl %eax ret END(lrintf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_lrintl.S ============================================================================== --- head/lib/msun/i387/s_lrintl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_lrintl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -33,3 +33,5 @@ ENTRY(lrintl) fistpl (%esp) popl %eax ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_remquo.S ============================================================================== --- head/lib/msun/i387/s_remquo.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_remquo.S Fri Jan 7 16:13:12 2011 (r217108) @@ -61,3 +61,5 @@ ENTRY(remquo) movl %eax,(%ecx) ret END(remquo) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_remquof.S ============================================================================== --- head/lib/msun/i387/s_remquof.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_remquof.S Fri Jan 7 16:13:12 2011 (r217108) @@ -61,3 +61,5 @@ ENTRY(remquof) movl %eax,(%ecx) ret END(remquof) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_remquol.S ============================================================================== --- head/lib/msun/i387/s_remquol.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_remquol.S Fri Jan 7 16:13:12 2011 (r217108) @@ -61,3 +61,5 @@ ENTRY(remquol) movl 28(%esp),%ecx movl %eax,(%ecx) ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_rint.S ============================================================================== --- head/lib/msun/i387/s_rint.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_rint.S Fri Jan 7 16:13:12 2011 (r217108) @@ -41,3 +41,5 @@ ENTRY(rint) frndint ret END(rint) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_rintf.S ============================================================================== --- head/lib/msun/i387/s_rintf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_rintf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -13,3 +13,5 @@ ENTRY(rintf) frndint ret END(rintf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_rintl.S ============================================================================== --- head/lib/msun/i387/s_rintl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_rintl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -40,3 +40,5 @@ ENTRY(rintl) fldt 4(%esp) frndint ret + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_scalbn.S ============================================================================== --- head/lib/msun/i387/s_scalbn.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_scalbn.S Fri Jan 7 16:13:12 2011 (r217108) @@ -43,3 +43,5 @@ ENTRY(scalbn) fstp %st(1) ret END(scalbn) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_scalbnf.S ============================================================================== --- head/lib/msun/i387/s_scalbnf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_scalbnf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -18,3 +18,5 @@ END(scalbnf) .globl CNAME(ldexpf) .set CNAME(ldexpf),CNAME(scalbnf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_scalbnl.S ============================================================================== --- head/lib/msun/i387/s_scalbnl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_scalbnl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -18,3 +18,5 @@ END(scalbnl) .globl CNAME(ldexpl) .set CNAME(ldexpl),CNAME(scalbnl) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_significand.S ============================================================================== --- head/lib/msun/i387/s_significand.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_significand.S Fri Jan 7 16:13:12 2011 (r217108) @@ -42,3 +42,5 @@ ENTRY(significand) fstp %st(1) ret END(significand) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_significandf.S ============================================================================== --- head/lib/msun/i387/s_significandf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_significandf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -14,3 +14,5 @@ ENTRY(significandf) fstp %st(1) ret END(significandf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_sin.S ============================================================================== --- head/lib/msun/i387/s_sin.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_sin.S Fri Jan 7 16:13:12 2011 (r217108) @@ -54,3 +54,5 @@ ENTRY(sin) fsin ret END(sin) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_tan.S ============================================================================== --- head/lib/msun/i387/s_tan.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_tan.S Fri Jan 7 16:13:12 2011 (r217108) @@ -56,3 +56,5 @@ ENTRY(tan) fstp %st(0) ret END(tan) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_trunc.S ============================================================================== --- head/lib/msun/i387/s_trunc.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_trunc.S Fri Jan 7 16:13:12 2011 (r217108) @@ -25,3 +25,5 @@ ENTRY(trunc) leave ret END(trunc) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_truncf.S ============================================================================== --- head/lib/msun/i387/s_truncf.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_truncf.S Fri Jan 7 16:13:12 2011 (r217108) @@ -25,3 +25,5 @@ ENTRY(truncf) leave ret END(truncf) + + .section .note.GNU-stack,"",%progbits Modified: head/lib/msun/i387/s_truncl.S ============================================================================== --- head/lib/msun/i387/s_truncl.S Fri Jan 7 16:09:33 2011 (r217107) +++ head/lib/msun/i387/s_truncl.S Fri Jan 7 16:13:12 2011 (r217108) @@ -25,3 +25,5 @@ ENTRY(truncl) leave ret END(truncl) + + .section .note.GNU-stack,"",%progbits From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:46:20 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9604E1065675; Fri, 7 Jan 2011 16:46:20 +0000 (UTC) (envelope-from mdf@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 853588FC0A; Fri, 7 Jan 2011 16:46:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07GkK9N058964; Fri, 7 Jan 2011 16:46:20 GMT (envelope-from mdf@svn.freebsd.org) Received: (from mdf@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07GkKTV058962; Fri, 7 Jan 2011 16:46:20 GMT (envelope-from mdf@svn.freebsd.org) Message-Id: <201101071646.p07GkKTV058962@svn.freebsd.org> From: Matthew D Fleming Date: Fri, 7 Jan 2011 16:46:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217109 - head/sys/geom/part X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:46:20 -0000 Author: mdf Date: Fri Jan 7 16:46:20 2011 New Revision: 217109 URL: http://svn.freebsd.org/changeset/base/217109 Log: Fix a memory overflow where the input length to g_gpt_utf8_to_utf16() was specified incorrectly, causing the bzero to run past the end of a malloc(9)'d object. Submitted by: Eric Youngblut < eyoungblut AT isilon DOT com > MFC after: 3 days Modified: head/sys/geom/part/g_part_gpt.c Modified: head/sys/geom/part/g_part_gpt.c ============================================================================== --- head/sys/geom/part/g_part_gpt.c Fri Jan 7 16:13:12 2011 (r217108) +++ head/sys/geom/part/g_part_gpt.c Fri Jan 7 16:46:20 2011 (r217109) @@ -425,7 +425,8 @@ g_part_gpt_add(struct g_part_table *base } if (gpp->gpp_parms & G_PART_PARM_LABEL) g_gpt_utf8_to_utf16(gpp->gpp_label, entry->ent.ent_name, - sizeof(entry->ent.ent_name)); + sizeof(entry->ent.ent_name) / + sizeof(entry->ent.ent_name[0])); return (0); } @@ -588,7 +589,8 @@ g_part_gpt_modify(struct g_part_table *b } if (gpp->gpp_parms & G_PART_PARM_LABEL) g_gpt_utf8_to_utf16(gpp->gpp_label, entry->ent.ent_name, - sizeof(entry->ent.ent_name)); + sizeof(entry->ent.ent_name) / + sizeof(entry->ent.ent_name[0])); return (0); } From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 16:47:21 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 38AAE1065720; Fri, 7 Jan 2011 16:47:21 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 27F878FC18; Fri, 7 Jan 2011 16:47:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07GlLm9059025; Fri, 7 Jan 2011 16:47:21 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07GlLSn059023; Fri, 7 Jan 2011 16:47:21 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101071647.p07GlLSn059023@svn.freebsd.org> From: John Baldwin Date: Fri, 7 Jan 2011 16:47:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217110 - head/sys/netinet/ipfw X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 16:47:21 -0000 Author: jhb Date: Fri Jan 7 16:47:20 2011 New Revision: 217110 URL: http://svn.freebsd.org/changeset/base/217110 Log: Use a regular taskqueue for dummynet rather than a "fast" taskqueue. Reviewed by: luigi Modified: head/sys/netinet/ipfw/ip_dummynet.c Modified: head/sys/netinet/ipfw/ip_dummynet.c ============================================================================== --- head/sys/netinet/ipfw/ip_dummynet.c Fri Jan 7 16:46:20 2011 (r217109) +++ head/sys/netinet/ipfw/ip_dummynet.c Fri Jan 7 16:47:20 2011 (r217110) @@ -2157,7 +2157,7 @@ ip_dn_init(void) DN_LOCK_INIT(); TASK_INIT(&dn_task, 0, dummynet_task, curvnet); - dn_tq = taskqueue_create_fast("dummynet", M_NOWAIT, + dn_tq = taskqueue_create("dummynet", M_NOWAIT, taskqueue_thread_enqueue, &dn_tq); taskqueue_start_threads(&dn_tq, 1, PI_NET, "dummynet"); From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 17:02:57 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E2579106566C; Fri, 7 Jan 2011 17:02:57 +0000 (UTC) (envelope-from minimarmot@gmail.com) Received: from mail-bw0-f54.google.com (mail-bw0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id 1B2D18FC1C; Fri, 7 Jan 2011 17:02:56 +0000 (UTC) Received: by bwz12 with SMTP id 12so10158051bwz.13 for ; Fri, 07 Jan 2011 09:02:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=84dN4YdvYnjnDXIH6yaqS5XfUizN4kr5oYC4Vr52fAM=; b=AXKFq+tBXFAjY0bhcbeYt1I5PKLkVyDhCmj/fm1yItcbNk03rBqZcV3tpKxAJqoMDB JWhuhtPTv+5TKbelI3eM7ulE3L6mn++zJvtvqubuQUhvRDavucUjzdH/iphxlgYRgptB G4BzYE+5yYJnQpyitekSBQlZyfuLzNM28xt0o= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=AJmaGen9ySvMoB3TCzA/M2u6PKuUTo53GU/QipiBCVjRlhGV1j0QbcwzFGZrK1aHXH /qFiN8aAZO6wWMPLWYlotDIDpobu5rYbah/2waxEdpNqHdARwBnmP3j/SKOulVyrwha+ lWy3J3o7TBgoUuINzCG7epwo2LcbGnKDRKBss= MIME-Version: 1.0 Received: by 10.204.68.76 with SMTP id u12mr3690780bki.57.1294419775762; Fri, 07 Jan 2011 09:02:55 -0800 (PST) Received: by 10.204.118.141 with HTTP; Fri, 7 Jan 2011 09:02:55 -0800 (PST) In-Reply-To: <201101071422.p07EMYlP055071@svn.freebsd.org> References: <201101071422.p07EMYlP055071@svn.freebsd.org> Date: Fri, 7 Jan 2011 12:02:55 -0500 Message-ID: From: Ben Kaduk To: Konstantin Belousov Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217097 - in head/sys: amd64/include arm/include i386/include ia64/include mips/include powerpc/include sparc64/include sun4v/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 17:02:58 -0000 On Fri, Jan 7, 2011 at 9:22 AM, Konstantin Belousov wrote= : > Author: kib > Date: Fri Jan =A07 14:22:34 2011 > New Revision: 217097 > URL: http://svn.freebsd.org/changeset/base/217097 > > Log: > =A0Add AT_STACKPROT elf aux vector. Will be used to inform rtld about the > =A0initial stack protection set by the kernel image activator. > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > --- head/sys/amd64/include/elf.h =A0 =A0 =A0 =A0Fri Jan =A07 14:17:29 201= 1 =A0 =A0 =A0 =A0(r217096) > +++ head/sys/amd64/include/elf.h =A0 =A0 =A0 =A0Fri Jan =A07 14:22:34 201= 1 =A0 =A0 =A0 =A0(r217097) > @@ -94,8 +94,9 @@ __ElfType(Auxinfo); > =A0#define =A0 =A0 =A0 =A0AT_NCPUS =A0 =A0 =A0 =A019 =A0 =A0 =A0/* Number= of CPUs. */ > =A0#define =A0 =A0 =A0 =A0AT_PAGESIZES =A0 =A020 =A0 =A0 =A0/* Pagesizes.= */ > =A0#define =A0 =A0 =A0 =A0AT_PAGESIZESLEN 21 =A0 =A0 =A0/* Number of page= sizes. */ > +#define =A0 =A0 =A0 =A0AT_STACKPROT =A0 =A023 =A0 =A0 =A0/* Initial stac= k protection. */ > > -#define =A0 =A0 =A0 =A0AT_COUNT =A0 =A0 =A0 =A022 =A0 =A0 =A0/* Count of= defined aux entry types. */ > +#define =A0 =A0 =A0 =A0AT_COUNT =A0 =A0 =A0 =A024 =A0 =A0 =A0/* Count of= defined aux entry types. */ Is there a reason to skip 22? -Ben Kaduk From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 17:26:08 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BE416106566B; Fri, 7 Jan 2011 17:26:08 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id 4E2518FC08; Fri, 7 Jan 2011 17:26:07 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id p07HQ46E000696 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 7 Jan 2011 19:26:04 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id p07HQ4fL034862; Fri, 7 Jan 2011 19:26:04 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id p07HQ49i034861; Fri, 7 Jan 2011 19:26:04 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 7 Jan 2011 19:26:04 +0200 From: Kostik Belousov To: Ben Kaduk Message-ID: <20110107172604.GC12599@deviant.kiev.zoral.com.ua> References: <201101071422.p07EMYlP055071@svn.freebsd.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="nG7dHWd/DOCuxGWF" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217097 - in head/sys: amd64/include arm/include i386/include ia64/include mips/include powerpc/include sparc64/include sun4v/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 17:26:08 -0000 --nG7dHWd/DOCuxGWF Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jan 07, 2011 at 12:02:55PM -0500, Ben Kaduk wrote: > On Fri, Jan 7, 2011 at 9:22 AM, Konstantin Belousov wro= te: > > Author: kib > > Date: Fri Jan =9A7 14:22:34 2011 > > New Revision: 217097 > > URL: http://svn.freebsd.org/changeset/base/217097 > > > > Log: > > =9AAdd AT_STACKPROT elf aux vector. Will be used to inform rtld about t= he > > =9Ainitial stack protection set by the kernel image activator. > > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > > --- head/sys/amd64/include/elf.h =9A =9A =9A =9AFri Jan =9A7 14:17:29 2= 011 =9A =9A =9A =9A(r217096) > > +++ head/sys/amd64/include/elf.h =9A =9A =9A =9AFri Jan =9A7 14:22:34 2= 011 =9A =9A =9A =9A(r217097) > > @@ -94,8 +94,9 @@ __ElfType(Auxinfo); > > =9A#define =9A =9A =9A =9AAT_NCPUS =9A =9A =9A =9A19 =9A =9A =9A/* Numb= er of CPUs. */ > > =9A#define =9A =9A =9A =9AAT_PAGESIZES =9A =9A20 =9A =9A =9A/* Pagesize= s. */ > > =9A#define =9A =9A =9A =9AAT_PAGESIZESLEN 21 =9A =9A =9A/* Number of pa= gesizes. */ > > +#define =9A =9A =9A =9AAT_STACKPROT =9A =9A23 =9A =9A =9A/* Initial st= ack protection. */ > > > > -#define =9A =9A =9A =9AAT_COUNT =9A =9A =9A =9A22 =9A =9A =9A/* Count = of defined aux entry types. */ > > +#define =9A =9A =9A =9AAT_COUNT =9A =9A =9A =9A24 =9A =9A =9A/* Count = of defined aux entry types. */ >=20 >=20 > Is there a reason to skip 22? Yes, I can swear that I saw the reference that stated that even aux vector types are used for Elf_Auxinfo.a_un.a_ptr, and odd are for a_val. I already received a private inquiry about the same issue, probably had to note this in the commit message. --nG7dHWd/DOCuxGWF Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iEYEARECAAYFAk0nTKsACgkQC3+MBN1Mb4i1RgCg3dyYIrpd6/gjKcqNEAQOZoKD g/kAoKsfMgou+N9neVYekaMg8c9X/i/L =Aas4 -----END PGP SIGNATURE----- --nG7dHWd/DOCuxGWF-- From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 18:14:59 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 340471065670; Fri, 7 Jan 2011 18:14:59 +0000 (UTC) (envelope-from gnn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 235018FC1C; Fri, 7 Jan 2011 18:14:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07IExdQ060988; Fri, 7 Jan 2011 18:14:59 GMT (envelope-from gnn@svn.freebsd.org) Received: (from gnn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07IExJm060986; Fri, 7 Jan 2011 18:14:59 GMT (envelope-from gnn@svn.freebsd.org) Message-Id: <201101071814.p07IExJm060986@svn.freebsd.org> From: "George V. Neville-Neil" Date: Fri, 7 Jan 2011 18:14:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217113 - head/sys/netinet X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 18:14:59 -0000 Author: gnn Date: Fri Jan 7 18:14:58 2011 New Revision: 217113 URL: http://svn.freebsd.org/changeset/base/217113 Log: Adjust ARP hold queue locking. Submitted by: Rozhuk Ivan, jhb MFC after: 2 weeks Modified: head/sys/netinet/if_ether.c Modified: head/sys/netinet/if_ether.c ============================================================================== --- head/sys/netinet/if_ether.c Fri Jan 7 16:54:29 2011 (r217112) +++ head/sys/netinet/if_ether.c Fri Jan 7 18:14:58 2011 (r217113) @@ -731,6 +731,9 @@ match: if (la->la_hold != NULL) { struct mbuf *m_hold, *m_hold_next; + m_hold = la->la_hold; + la->la_hold = NULL; + la->la_numheld = 0; memcpy(&sa, L3_ADDR(la), sizeof(sa)); LLE_WUNLOCK(la); for (m_hold = la->la_hold, la->la_hold = NULL; @@ -741,8 +744,6 @@ match: } } else LLE_WUNLOCK(la); - la->la_hold = NULL; - la->la_numheld = 0; } /* end of FIB loop */ reply: if (op != ARPOP_REQUEST) From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 18:19:40 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EC000106564A for ; Fri, 7 Jan 2011 18:19:40 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx22.fluidhosting.com [204.14.89.5]) by mx1.freebsd.org (Postfix) with ESMTP id 7AC428FC0A for ; Fri, 7 Jan 2011 18:19:40 +0000 (UTC) Received: (qmail 27053 invoked by uid 399); 7 Jan 2011 18:19:39 -0000 Received: from localhost (HELO doug-optiplex.ka9q.net) (dougb@dougbarton.us@127.0.0.1) by localhost with ESMTPAM; 7 Jan 2011 18:19:39 -0000 X-Originating-IP: 127.0.0.1 X-Sender: dougb@dougbarton.us Message-ID: <4D27593A.8050103@FreeBSD.org> Date: Fri, 07 Jan 2011 10:19:38 -0800 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101210 Thunderbird/3.1.7 MIME-Version: 1.0 To: Jaakko Heinonen References: <201101071059.p07AxN1F049134@svn.freebsd.org> In-Reply-To: <201101071059.p07AxN1F049134@svn.freebsd.org> X-Enigmail-Version: 1.1.2 OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217090 - head/etc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 18:19:41 -0000 On 01/07/2011 02:59, Jaakko Heinonen wrote: > Author: jh > Date: Fri Jan 7 10:59:22 2011 > New Revision: 217090 > URL: http://svn.freebsd.org/changeset/base/217090 > > Log: > Warn if rules could not be read from a ruleset file. Now at least > something gets logged if the file has syntax errors. > > PR: conf/91342 > Silence on: freebsd-rc If by silence you mean that there was no comment on the PR in the future please don't take that as tacit approval. There are a non-trivial number of PRs assigned to -rc, and historically the practice has been not to comment on them until someone indicates that they actually plan to do something about it. In the future it would be great if you could send a note to the list indicating that you plan to make a change, and then wait say 2 or 3 non-{weekend|holiday} days for feedback. Doug -- Nothin' ever doesn't change, but nothin' changes much. -- OK Go Breadth of IT experience, and depth of knowledge in the DNS. Yours for the right price. :) http://SupersetSolutions.com/ From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 18:42:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 37663106564A; Fri, 7 Jan 2011 18:42:00 +0000 (UTC) (envelope-from bschmidt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 26EA08FC19; Fri, 7 Jan 2011 18:42:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07Ig0YQ061864; Fri, 7 Jan 2011 18:42:00 GMT (envelope-from bschmidt@svn.freebsd.org) Received: (from bschmidt@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07Ig0sl061862; Fri, 7 Jan 2011 18:42:00 GMT (envelope-from bschmidt@svn.freebsd.org) Message-Id: <201101071842.p07Ig0sl061862@svn.freebsd.org> From: Bernhard Schmidt Date: Fri, 7 Jan 2011 18:42:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217118 - head/sys/dev/if_ndis X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 18:42:00 -0000 Author: bschmidt Date: Fri Jan 7 18:41:59 2011 New Revision: 217118 URL: http://svn.freebsd.org/changeset/base/217118 Log: Don't try to free an unassigned pointer. Submitted by: Paul B Mahol MFC after: 1 week Modified: head/sys/dev/if_ndis/if_ndis.c Modified: head/sys/dev/if_ndis/if_ndis.c ============================================================================== --- head/sys/dev/if_ndis/if_ndis.c Fri Jan 7 18:41:32 2011 (r217117) +++ head/sys/dev/if_ndis/if_ndis.c Fri Jan 7 18:41:59 2011 (r217118) @@ -1176,11 +1176,8 @@ ndis_rxeof_eth(adapter, ctx, addr, hdr, block = adapter; m = m_getcl(M_DONTWAIT, MT_DATA, M_PKTHDR); - - if (m == NULL) { - NdisFreePacket(p); + if (m == NULL) return; - } /* Save the data provided to us so far. */ From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 18:52:09 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 527C41065673; Fri, 7 Jan 2011 18:52:09 +0000 (UTC) (envelope-from stas@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4221F8FC18; Fri, 7 Jan 2011 18:52:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07Iq9C0062151; Fri, 7 Jan 2011 18:52:09 GMT (envelope-from stas@svn.freebsd.org) Received: (from stas@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07Iq92H062149; Fri, 7 Jan 2011 18:52:09 GMT (envelope-from stas@svn.freebsd.org) Message-Id: <201101071852.p07Iq92H062149@svn.freebsd.org> From: Stanislav Sedov Date: Fri, 7 Jan 2011 18:52:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217119 - head/usr.sbin/cpucontrol X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 18:52:09 -0000 Author: stas Date: Fri Jan 7 18:52:08 2011 New Revision: 217119 URL: http://svn.freebsd.org/changeset/base/217119 Log: - Save some space relying on the fact that all ioctl commands prefixes are the same. Suggested by: "Carlos A. M. dos Santos" Modified: head/usr.sbin/cpucontrol/cpucontrol.c Modified: head/usr.sbin/cpucontrol/cpucontrol.c ============================================================================== --- head/usr.sbin/cpucontrol/cpucontrol.c Fri Jan 7 18:41:59 2011 (r217118) +++ head/usr.sbin/cpucontrol/cpucontrol.c Fri Jan 7 18:52:08 2011 (r217119) @@ -246,19 +246,19 @@ do_msr(const char *cmdarg, const char *d switch (op) { case OP_READ: command = CPUCTL_RDMSR; - command_name = "CPUCTL_RDMSR"; + command_name = "RDMSR"; break; case OP_WRITE: command = CPUCTL_WRMSR; - command_name = "CPUCTL_WRMSR"; + command_name = "WRMSR"; break; case OP_OR: command = CPUCTL_MSRSBIT; - command_name = "CPUCTL_MSRSBIT"; + command_name = "MSRSBIT"; break; case OP_AND: command = CPUCTL_MSRCBIT; - command_name = "CPUCTL_MSRCBIT"; + command_name = "MSRCBIT"; break; default: abort(); @@ -271,7 +271,7 @@ do_msr(const char *cmdarg, const char *d } error = ioctl(fd, command, &args); if (error < 0) { - WARN(0, "ioctl(%s, %s (%lu))", dev, command_name, command); + WARN(0, "ioctl(%s, CPUCTL_%s (%lu))", dev, command_name, command); close(fd); return (1); } From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 19:00:44 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4E02E106566B; Fri, 7 Jan 2011 19:00:44 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from gw03.mail.saunalahti.fi (gw03.mail.saunalahti.fi [195.197.172.111]) by mx1.freebsd.org (Postfix) with ESMTP id 077C08FC21; Fri, 7 Jan 2011 19:00:43 +0000 (UTC) Received: from a91-153-123-205.elisa-laajakaista.fi (a91-153-123-205.elisa-laajakaista.fi [91.153.123.205]) by gw03.mail.saunalahti.fi (Postfix) with SMTP id EF7B32166FD; Fri, 7 Jan 2011 21:00:37 +0200 (EET) Date: Fri, 7 Jan 2011 21:00:37 +0200 From: Jaakko Heinonen To: Doug Barton Message-ID: <20110107190037.GA1501@a91-153-123-205.elisa-laajakaista.fi> References: <201101071059.p07AxN1F049134@svn.freebsd.org> <4D27593A.8050103@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D27593A.8050103@FreeBSD.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217090 - head/etc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 19:00:44 -0000 Hi, On 2011-01-07, Doug Barton wrote: > If by silence you mean that there was no comment on the PR in the future > please don't take that as tacit approval. There are a non-trivial number > of PRs assigned to -rc, and historically the practice has been not to > comment on them until someone indicates that they actually plan to do > something about it. > > In the future it would be great if you could send a note to the list > indicating that you plan to make a change, and then wait say 2 or 3 > non-{weekend|holiday} days for feedback. I mean this message: http://lists.freebsd.org/pipermail/freebsd-rc/2010-December/002142.html I waited >2 weeks for comments and then committed the patch. Admittedly I posted the patch as a bug follow-up but I made sure that the message ended up to freebsd-rc list. -- Jaakko From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 19:18:54 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E73D41065673 for ; Fri, 7 Jan 2011 19:18:54 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx22.fluidhosting.com [204.14.89.5]) by mx1.freebsd.org (Postfix) with ESMTP id 76C038FC1F for ; Fri, 7 Jan 2011 19:18:54 +0000 (UTC) Received: (qmail 7504 invoked by uid 399); 7 Jan 2011 19:18:53 -0000 Received: from localhost (HELO doug-optiplex.ka9q.net) (dougb@dougbarton.us@127.0.0.1) by localhost with ESMTPAM; 7 Jan 2011 19:18:53 -0000 X-Originating-IP: 127.0.0.1 X-Sender: dougb@dougbarton.us Message-ID: <4D27671C.5070907@FreeBSD.org> Date: Fri, 07 Jan 2011 11:18:52 -0800 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101210 Thunderbird/3.1.7 MIME-Version: 1.0 To: Jaakko Heinonen References: <201101071059.p07AxN1F049134@svn.freebsd.org> <4D27593A.8050103@FreeBSD.org> <20110107190037.GA1501@a91-153-123-205.elisa-laajakaista.fi> In-Reply-To: <20110107190037.GA1501@a91-153-123-205.elisa-laajakaista.fi> X-Enigmail-Version: 1.1.2 OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217090 - head/etc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 19:18:55 -0000 On 01/07/2011 11:00, Jaakko Heinonen wrote: > > Hi, > > On 2011-01-07, Doug Barton wrote: >> If by silence you mean that there was no comment on the PR in the future >> please don't take that as tacit approval. There are a non-trivial number >> of PRs assigned to -rc, and historically the practice has been not to >> comment on them until someone indicates that they actually plan to do >> something about it. >> >> In the future it would be great if you could send a note to the list >> indicating that you plan to make a change, and then wait say 2 or 3 >> non-{weekend|holiday} days for feedback. > > I mean this message: > > http://lists.freebsd.org/pipermail/freebsd-rc/2010-December/002142.html > > I waited>2 weeks for comments and then committed the patch. Admittedly > I posted the patch as a bug follow-up but I made sure that the message > ended up to freebsd-rc list. Yeah, that's Ok, and I should have mentioned that this change is fine. My point more generally is that regular e-mail about proposed changes is more likely to get useful attention and feedback. Doug -- Nothin' ever doesn't change, but nothin' changes much. -- OK Go Breadth of IT experience, and depth of knowledge in the DNS. Yours for the right price. :) http://SupersetSolutions.com/ From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 20:02:05 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 83743106566B; Fri, 7 Jan 2011 20:02:05 +0000 (UTC) (envelope-from gnn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 733A28FC19; Fri, 7 Jan 2011 20:02:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07K25Db064157; Fri, 7 Jan 2011 20:02:05 GMT (envelope-from gnn@svn.freebsd.org) Received: (from gnn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07K25iu064155; Fri, 7 Jan 2011 20:02:05 GMT (envelope-from gnn@svn.freebsd.org) Message-Id: <201101072002.p07K25iu064155@svn.freebsd.org> From: "George V. Neville-Neil" Date: Fri, 7 Jan 2011 20:02:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217121 - head/sys/netinet X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 20:02:05 -0000 Author: gnn Date: Fri Jan 7 20:02:05 2011 New Revision: 217121 URL: http://svn.freebsd.org/changeset/base/217121 Log: Fix a memory leak in ARP queues. Pointed out by: jhb@ MFC after: 2 weeks Modified: head/sys/netinet/if_ether.c Modified: head/sys/netinet/if_ether.c ============================================================================== --- head/sys/netinet/if_ether.c Fri Jan 7 18:54:08 2011 (r217120) +++ head/sys/netinet/if_ether.c Fri Jan 7 20:02:05 2011 (r217121) @@ -736,8 +736,7 @@ match: la->la_numheld = 0; memcpy(&sa, L3_ADDR(la), sizeof(sa)); LLE_WUNLOCK(la); - for (m_hold = la->la_hold, la->la_hold = NULL; - m_hold != NULL; m_hold = m_hold_next) { + for (; m_hold != NULL; m_hold = m_hold_next) { m_hold_next = m_hold->m_nextpkt; m_hold->m_nextpkt = NULL; (*ifp->if_output)(ifp, m_hold, &sa, NULL); From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 20:26:33 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 753A11065672; Fri, 7 Jan 2011 20:26:33 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 616268FC14; Fri, 7 Jan 2011 20:26:33 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07KQX9d064792; Fri, 7 Jan 2011 20:26:33 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07KQXKe064774; Fri, 7 Jan 2011 20:26:33 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101072026.p07KQXKe064774@svn.freebsd.org> From: Warner Losh Date: Fri, 7 Jan 2011 20:26:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217123 - in head: . gnu/lib/libgcc gnu/lib/libgomp gnu/usr.bin/binutils gnu/usr.bin/binutils/ld gnu/usr.bin/binutils/libbfd gnu/usr.bin/cc gnu/usr.bin/gdb gnu/usr.bin/gdb/libgdb lib/li... X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 20:26:33 -0000 Author: imp Date: Fri Jan 7 20:26:33 2011 New Revision: 217123 URL: http://svn.freebsd.org/changeset/base/217123 Log: Retire TARGET_ABI. Implement MACHINE_ARCH=mips64e[lb] to build N64 images. This replaces MACHINE_ARCH=mipse[lb] TARGET_ABI=n64. MACHINE_ARCH=mipsn32e[lb] has been added, but currently requires WITHOUT_CDDL due to atomic issues in libzfs. I've not investigated this much, but implemented this to preserve as much of the TARGET_ABI functionality that I could. Since its presence doesn't affect the working cases, I've kept it in for now. Added mips64e[lb] to make universe, so more kernels build. And I think this (finally) closes the curtain on the tbemd tree. Modified: head/Makefile head/Makefile.inc1 head/Makefile.mips head/gnu/lib/libgcc/Makefile head/gnu/lib/libgomp/Makefile head/gnu/usr.bin/binutils/Makefile.inc0 head/gnu/usr.bin/binutils/ld/Makefile.mips head/gnu/usr.bin/binutils/libbfd/Makefile.mips head/gnu/usr.bin/cc/Makefile.inc head/gnu/usr.bin/cc/Makefile.tgt head/gnu/usr.bin/gdb/Makefile.inc head/gnu/usr.bin/gdb/libgdb/Makefile head/lib/libc/Makefile head/share/mk/bsd.endian.mk head/share/mk/sys.mk head/usr.bin/xlint/Makefile.inc head/usr.sbin/Makefile.mips Modified: head/Makefile ============================================================================== --- head/Makefile Fri Jan 7 20:07:30 2011 (r217122) +++ head/Makefile Fri Jan 7 20:26:33 2011 (r217123) @@ -283,7 +283,7 @@ tinderbox: .if make(universe) || make(universe_kernels) || make(tinderbox) TARGETS?=amd64 arm i386 ia64 mips pc98 powerpc sparc64 sun4v TARGET_ARCHES_arm?= arm armeb -TARGET_ARCHES_mips?= mipsel mipseb +TARGET_ARCHES_mips?= mipsel mipseb mips64el mips64eb TARGET_ARCHES_powerpc?= powerpc powerpc64 TARGET_ARCHES_pc98?= i386 TARGET_ARCHES_sun4v?= sparc64 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Fri Jan 7 20:07:30 2011 (r217122) +++ head/Makefile.inc1 Fri Jan 7 20:26:33 2011 (r217123) @@ -121,7 +121,7 @@ VERSION+= ${OSRELDATE} TARGET_ARCH= ${TARGET:S/pc98/i386/:S/sun4v/sparc64/:S/mips/mipsel/} .elif !defined(TARGET) && defined(TARGET_ARCH) && \ ${TARGET_ARCH} != ${MACHINE_ARCH} -TARGET= ${TARGET_ARCH:C/mipse[lb]/mips/:C/armeb/arm/} +TARGET= ${TARGET_ARCH:C/mips.*e[lb]/mips/:C/armeb/arm/} .endif # Legacy names, for a transition period mips:mips -> mipsel:mips .if defined(TARGET) && defined(TARGET_ARCH) && \ @@ -142,7 +142,7 @@ TARGET_ARCH=armeb TARGET?= ${MACHINE} TARGET_ARCH?= ${MACHINE_ARCH} -KNOWN_ARCHES?= amd64 arm armeb/arm i386 i386/pc98 ia64 mipsel/mips mipseb/mips powerpc powerpc64/powerpc sparc64 sparc64/sun4v +KNOWN_ARCHES?= amd64 arm armeb/arm i386 i386/pc98 ia64 mipsel/mips mipseb/mips mips64el/mips mips64eb/mips mipsn32el/mips mipsn32eb/mips powerpc powerpc64/powerpc sparc64 sparc64/sun4v .if ${TARGET} == ${TARGET_ARCH} _t= ${TARGET} .else Modified: head/Makefile.mips ============================================================================== --- head/Makefile.mips Fri Jan 7 20:07:30 2011 (r217122) +++ head/Makefile.mips Fri Jan 7 20:26:33 2011 (r217123) @@ -1,5 +1,5 @@ # $FreeBSD$ -.if defined(TARGET_ABI) && ${TARGET_ABI} == "n64" +.if ${MACHINE_ARCH} != "mipsel" && ${MACHINE_ARCH} != "mipseb" MK_RESCUE=no .endif Modified: head/gnu/lib/libgcc/Makefile ============================================================================== --- head/gnu/lib/libgcc/Makefile Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/lib/libgcc/Makefile Fri Jan 7 20:26:33 2011 (r217123) @@ -119,9 +119,10 @@ LIB2FUNCS_EXTRA = floatunsidf.c floatuns # _fixsfsi _fixunssfsi _floatdidf _floatdisf .endif -.if ${TARGET_CPUARCH} == "mips" +.if ${TARGET_CPUARCH} == mips LIB2FUNCS_EXTRA = floatunsidf.c floatunsisf.c -.if defined(TARGET_ABI) && ${TARGET_ABI} != "o32" +# XXX do we need n32 here? +.if ${TARGET_ARCH:Mmips64*} != "" LIB2FUNCS_EXTRA+= floatdidf.c fixunsdfsi.c LIB2FUNCS_EXTRA+= floatdisf.c floatundidf.c LIB2FUNCS_EXTRA+= fixsfdi.c floatundisf.c Modified: head/gnu/lib/libgomp/Makefile ============================================================================== --- head/gnu/lib/libgomp/Makefile Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/lib/libgomp/Makefile Fri Jan 7 20:26:33 2011 (r217123) @@ -25,8 +25,7 @@ VERSION_MAP= ${SRCDIR}/libgomp.map # Target-specific OpenMP configuration .if ${MACHINE_CPUARCH} == arm || ${MACHINE_CPUARCH} == i386 || \ ${MACHINE_ARCH} == powerpc || \ - (${MACHINE_CPUARCH} == mips && \ - (!defined(TARGET_ABI) || ${TARGET_ABI} != "n64")) + ${MACHINE_ARCH} == mipsel || ${MACHINE_ARCH} == mipseb OMP_LOCK_ALIGN = 4 OMP_LOCK_KIND= 4 OMP_LOCK_SIZE= 4 Modified: head/gnu/usr.bin/binutils/Makefile.inc0 ============================================================================== --- head/gnu/usr.bin/binutils/Makefile.inc0 Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/usr.bin/binutils/Makefile.inc0 Fri Jan 7 20:26:33 2011 (r217123) @@ -7,14 +7,14 @@ VERSION= "2.15 [FreeBSD] 2004-05-23" .if defined(TARGET_ARCH) -TARGET_CPUARCH=${TARGET_ARCH:C/mipse[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} +TARGET_CPUARCH=${TARGET_ARCH:C/mips.*e[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} .else TARGET_CPUARCH=${MACHINE_CPUARCH} .endif TARGET_ARCH?= ${MACHINE_ARCH} BINUTILS_ARCH=${TARGET_ARCH:C/amd64/x86_64/} TARGET_TUPLE?= ${BINUTILS_ARCH}-obrien-freebsd -.if ${TARGET_ARCH} == "armeb" || ${TARGET_ARCH} == "mipseb" +.if ${TARGET_ARCH} == "armeb" || ${TARGET_ARCH:Mmips*eb} != "" TARGET_BIG_ENDIAN=t .endif @@ -28,8 +28,7 @@ SRCDIR= ${.CURDIR}/${RELSRC} .if ${TARGET_CPUARCH} == "arm" || ${TARGET_CPUARCH} == "i386" || \ ${TARGET_ARCH} == "powerpc" || \ - (${TARGET_CPUARCH} == "mips" && \ - (!defined(TARGET_ABI) || ${TARGET_ABI} != "n64")) + ${TARGET_ARCH} == "mipsel" || ${TARGET_ARCH} == "mipseb" CFLAGS+= -DBFD_DEFAULT_TARGET_SIZE=32 .else CFLAGS+= -DBFD_DEFAULT_TARGET_SIZE=64 Modified: head/gnu/usr.bin/binutils/ld/Makefile.mips ============================================================================== --- head/gnu/usr.bin/binutils/ld/Makefile.mips Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/usr.bin/binutils/ld/Makefile.mips Fri Jan 7 20:26:33 2011 (r217123) @@ -1,19 +1,18 @@ # $FreeBSD$ -.if ${TARGET_ARCH} == "mipsel" +.if ${TARGET_ARCH:Mmips*el} != "" _EMULATION_ENDIAN=l .else _EMULATION_ENDIAN=b .endif -.if defined(TARGET_ABI) && ${TARGET_ABI} != "o32" -.if ${TARGET_ABI} == "n32" -NATIVE_EMULATION=elf32${_EMULATION_ENDIAN}tsmipn32_fbsd -.elif ${TARGET_ABI} == "n64" +.if ${TARGET_ARCH:Mmips64*} != "" NATIVE_EMULATION=elf64${_EMULATION_ENDIAN}tsmip_fbsd -.endif -.endif +.elif ${TARGET_ARCH:Mmipsn32*} != "" +NATIVE_EMULATION=elf32${_EMULATION_ENDIAN}tsmipn32_fbsd +.else NATIVE_EMULATION?=elf32${_EMULATION_ENDIAN}tsmip_fbsd +.endif MIPS_ABIS=elf32btsmip_fbsd elf32ltsmip_fbsd elf64btsmip_fbsd elf64ltsmip_fbsd \ elf32btsmipn32_fbsd elf32ltsmipn32_fbsd Modified: head/gnu/usr.bin/binutils/libbfd/Makefile.mips ============================================================================== --- head/gnu/usr.bin/binutils/libbfd/Makefile.mips Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/usr.bin/binutils/libbfd/Makefile.mips Fri Jan 7 20:26:33 2011 (r217123) @@ -1,19 +1,18 @@ # $FreeBSD$ -.if ${TARGET_ARCH} == "mipsel" +.if ${TARGET_ARCH:Mmips*el} != "" _EMULATION_ENDIAN=little .else _EMULATION_ENDIAN=big .endif -.if defined(TARGET_ABI) && ${TARGET_ABI} != "o32" -.if ${TARGET_ABI} == "n32" -DEFAULT_VECTOR= bfd_elf32_ntrad${_EMULATION_ENDIAN}mips_vec -.elif ${TARGET_ABI} == "n64" +.if ${TARGET_ARCH:Mmips64*} != "" DEFAULT_VECTOR= bfd_elf64_trad${_EMULATION_ENDIAN}mips_vec +.elif ${TARGET_ARCH:Mmipsn32*} != "" +DEFAULT_VECTOR= bfd_elf32_ntrad${_EMULATION_ENDIAN}mips_vec +.else +DEFAULT_VECTOR=bfd_elf32_trad${_EMULATION_ENDIAN}mips_vec .endif -.endif -DEFAULT_VECTOR?=bfd_elf32_trad${_EMULATION_ENDIAN}mips_vec SRCS+= coff-mips.c \ cpu-mips.c \ Modified: head/gnu/usr.bin/cc/Makefile.inc ============================================================================== --- head/gnu/usr.bin/cc/Makefile.inc Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/usr.bin/cc/Makefile.inc Fri Jan 7 20:26:33 2011 (r217123) @@ -36,21 +36,18 @@ CFLAGS+= -DCROSS_COMPILE CFLAGS += -DTARGET_ENDIAN_DEFAULT=MASK_BIG_END .endif - .if ${TARGET_CPUARCH} == "mips" -.if ${TARGET_ARCH} == "mipsel" +.if ${TARGET_ARCH:Mmips*el} != "" CFLAGS += -DTARGET_ENDIAN_DEFAULT=0 .endif -.if defined(TARGET_ABI) && ${TARGET_ABI} != "o32" -.if ${TARGET_ABI} == "n32" -MIPS_ABI_DEFAULT=ABI_N32 -.elif ${TARGET_ABI} == "n64" +.if ${TARGET_ARCH:Mmips64*} != "" MIPS_ABI_DEFAULT=ABI_64 +.elif ${TARGET_ARCH:Mmipsn32*} != "" +MIPS_ABI_DEFAULT=ABI_N32 +.else +MIPS_ABI_DEFAULT=ABI_32 .endif -.endif - -MIPS_ABI_DEFAULT?=ABI_32 CFLAGS += -DMIPS_ABI_DEFAULT=${MIPS_ABI_DEFAULT} # If we are compiling for the O32 ABI, we need to default to MIPS-III rather Modified: head/gnu/usr.bin/cc/Makefile.tgt ============================================================================== --- head/gnu/usr.bin/cc/Makefile.tgt Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/usr.bin/cc/Makefile.tgt Fri Jan 7 20:26:33 2011 (r217123) @@ -4,7 +4,7 @@ # MACHINE_CPUARCH, but there's no easy way to export make functions... .if defined(TARGET_ARCH) -TARGET_CPUARCH=${TARGET_ARCH:C/mipse[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} +TARGET_CPUARCH=${TARGET_ARCH:C/mips.*e[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} .else TARGET_CPUARCH=${MACHINE_CPUARCH} .endif @@ -17,7 +17,7 @@ TARGET_CPU_DEFAULT= MASK_GNU_AS|MASK_GNU .if ${TARGET_ARCH} == "sparc64" TARGET_CPU_DEFAULT= TARGET_CPU_ultrasparc .endif -.if ${TARGET_ARCH} == "armeb" || ${TARGET_ARCH} == "mipseb" || ${TARGET_ARCH} == "mips64eb" +.if ${TARGET_ARCH} == "armeb" || ${TARGET_ARCH:Mmips*eb} != "" TARGET_BIG_ENDIAN=t .endif .if ${TARGET_ARCH} == "powerpc64" Modified: head/gnu/usr.bin/gdb/Makefile.inc ============================================================================== --- head/gnu/usr.bin/gdb/Makefile.inc Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/usr.bin/gdb/Makefile.inc Fri Jan 7 20:26:33 2011 (r217123) @@ -20,7 +20,7 @@ OBJ_GDB= ${OBJ_ROOT}/gdb # MACHINE_CPUARCH, but there's no easy way to export make functions... .if defined(TARGET_ARCH) -TARGET_CPUARCH=${TARGET_ARCH:C/mipse[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} +TARGET_CPUARCH=${TARGET_ARCH:C/mips.*e[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} .else TARGET_CPUARCH=${MACHINE_CPUARCH} .endif Modified: head/gnu/usr.bin/gdb/libgdb/Makefile ============================================================================== --- head/gnu/usr.bin/gdb/libgdb/Makefile Fri Jan 7 20:07:30 2011 (r217122) +++ head/gnu/usr.bin/gdb/libgdb/Makefile Fri Jan 7 20:26:33 2011 (r217123) @@ -4,7 +4,7 @@ # MACHINE_CPUARCH, but there's no easy way to export make functions... .if defined(TARGET_ARCH) -TARGET_CPUARCH=${TARGET_ARCH:C/mipse[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} +TARGET_CPUARCH=${TARGET_ARCH:C/mips.*e[bl]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} .else TARGET_CPUARCH=${MACHINE_CPUARCH} .endif Modified: head/lib/libc/Makefile ============================================================================== --- head/lib/libc/Makefile Fri Jan 7 20:07:30 2011 (r217122) +++ head/lib/libc/Makefile Fri Jan 7 20:26:33 2011 (r217123) @@ -68,11 +68,7 @@ NOASM= ${LIBC_ARCH} != "ia64" && \ ${LIBC_ARCH} != "powerpc64" && \ ${LIBC_ARCH} != "sparc64" && \ - ${LIBC_ARCH} != "mips" -.include "${.CURDIR}/quad/Makefile.inc" -.endif -.if ${LIBC_ARCH} == "mips" && \ - (!defined(TARGET_ABI) || ${TARGET_ABI} == "o32") + ${MACHINE_ARCH:Mmips64*} == "" .include "${.CURDIR}/quad/Makefile.inc" .endif .include "${.CURDIR}/regex/Makefile.inc" Modified: head/share/mk/bsd.endian.mk ============================================================================== --- head/share/mk/bsd.endian.mk Fri Jan 7 20:07:30 2011 (r217122) +++ head/share/mk/bsd.endian.mk Fri Jan 7 20:26:33 2011 (r217123) @@ -4,12 +4,12 @@ ${MACHINE_ARCH} == "i386" || \ ${MACHINE_ARCH} == "ia64" || \ ${MACHINE_ARCH} == "arm" || \ - ${MACHINE_ARCH} == "mipsel" + ${MACHINE_ARCH:Mmips*el} != "" TARGET_ENDIANNESS= 1234 .elif ${MACHINE_ARCH} == "powerpc" || \ ${MACHINE_ARCH} == "powerpc64" || \ ${MACHINE_ARCH} == "sparc64" || \ ${MACHINE_ARCH} == "armeb" || \ - ${MACHINE_ARCH} == "mipseb" + ${MACHINE_ARCH:Mmips*eb} != "" TARGET_ENDIANNESS= 4321 .endif Modified: head/share/mk/sys.mk ============================================================================== --- head/share/mk/sys.mk Fri Jan 7 20:07:30 2011 (r217122) +++ head/share/mk/sys.mk Fri Jan 7 20:26:33 2011 (r217123) @@ -13,7 +13,7 @@ unix ?= We run FreeBSD, not UNIX. # and/or endian. This is called MACHINE_CPU in NetBSD, but that's used # for something different in FreeBSD. # -MACHINE_CPUARCH=${MACHINE_ARCH:C/mipse[lb]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} +MACHINE_CPUARCH=${MACHINE_ARCH:C/mips.*e[lb]/mips/:C/armeb/arm/:C/powerpc64/powerpc/} .endif # If the special target .POSIX appears (without prerequisites or Modified: head/usr.bin/xlint/Makefile.inc ============================================================================== --- head/usr.bin/xlint/Makefile.inc Fri Jan 7 20:07:30 2011 (r217122) +++ head/usr.bin/xlint/Makefile.inc Fri Jan 7 20:26:33 2011 (r217123) @@ -8,7 +8,7 @@ WARNS?= 0 # These assignments duplicate much of the functionality of # MACHINE_CPUARCH, but there's no easy way to export make functions... .if defined(TARGET_ARCH) -TARGET_CPUARCH= ${TARGET_ARCH:C/mipse[bl]/mips/:C/armeb/arm/} +TARGET_CPUARCH= ${TARGET_ARCH:C/mips.*e[bl]/mips/:C/armeb/arm/} .else TARGET_CPUARCH= ${MACHINE_CPUARCH} TARGET_ARCH= ${MACHINE_ARCH} Modified: head/usr.sbin/Makefile.mips ============================================================================== --- head/usr.sbin/Makefile.mips Fri Jan 7 20:07:30 2011 (r217122) +++ head/usr.sbin/Makefile.mips Fri Jan 7 20:26:33 2011 (r217123) @@ -1,6 +1,6 @@ # $FreeBSD$ SUBDIR:= ${SUBDIR:Nsysinstall} -.if defined(TARGET_ABI) && ${TARGET_ABI} == "n64" +.if ${MACHINE_ARCH:Mmips64*} != "" SUBDIR:= ${SUBDIR:Nuathload} .endif From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 20:32:28 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 820D8106566B; Fri, 7 Jan 2011 20:32:28 +0000 (UTC) (envelope-from juli@clockworksquid.com) Received: from mail-gw0-f54.google.com (mail-gw0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id 0D8D08FC1C; Fri, 7 Jan 2011 20:32:27 +0000 (UTC) Received: by gwj21 with SMTP id 21so8420826gwj.13 for ; Fri, 07 Jan 2011 12:32:27 -0800 (PST) Received: by 10.236.110.5 with SMTP id t5mr19622552yhg.8.1294432347419; Fri, 07 Jan 2011 12:32:27 -0800 (PST) MIME-Version: 1.0 Sender: juli@clockworksquid.com Received: by 10.236.108.51 with HTTP; Fri, 7 Jan 2011 12:32:07 -0800 (PST) In-Reply-To: <201101072026.p07KQXKe064774@svn.freebsd.org> References: <201101072026.p07KQXKe064774@svn.freebsd.org> From: Juli Mallett Date: Fri, 7 Jan 2011 12:32:07 -0800 X-Google-Sender-Auth: JyXRZMyRcyoUOaYVgphGYnaTa1c Message-ID: To: Warner Losh Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217123 - in head: . gnu/lib/libgcc gnu/lib/libgomp gnu/usr.bin/binutils gnu/usr.bin/binutils/ld gnu/usr.bin/binutils/libbfd gnu/usr.bin/cc gnu/usr.bin/gdb gnu/usr.bin/gdb/libgdb lib/li... X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 20:32:28 -0000 On Fri, Jan 7, 2011 at 12:26, Warner Losh wrote: > --- head/gnu/lib/libgcc/Makefile =A0 =A0 =A0 =A0Fri Jan =A07 20:07:30 201= 1 =A0 =A0 =A0 =A0(r217122) > +++ head/gnu/lib/libgcc/Makefile =A0 =A0 =A0 =A0Fri Jan =A07 20:26:33 201= 1 =A0 =A0 =A0 =A0(r217123) > @@ -119,9 +119,10 @@ LIB2FUNCS_EXTRA =3D floatunsidf.c floatuns > =A0# =A0 =A0 =A0_fixsfsi _fixunssfsi _floatdidf _floatdisf > =A0.endif > > -.if ${TARGET_CPUARCH} =3D=3D "mips" > +.if ${TARGET_CPUARCH} =3D=3D mips > =A0LIB2FUNCS_EXTRA =3D floatunsidf.c floatunsisf.c > -.if defined(TARGET_ABI) && ${TARGET_ABI} !=3D "o32" > +# XXX do we need n32 here? > +.if ${TARGET_ARCH:Mmips64*} !=3D "" Almost certainly. n32 fails the !=3D o32 check. I was careful when I made the TARGET_ABI changes. There's a possibility that this was wrong for some reason, but I'm skeptical. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > --- head/lib/libc/Makefile =A0 =A0 =A0Fri Jan =A07 20:07:30 2011 =A0 =A0 = =A0 =A0(r217122) > +++ head/lib/libc/Makefile =A0 =A0 =A0Fri Jan =A07 20:26:33 2011 =A0 =A0 = =A0 =A0(r217123) > @@ -68,11 +68,7 @@ NOASM=3D > =A0 =A0 ${LIBC_ARCH} !=3D "ia64" && \ > =A0 =A0 ${LIBC_ARCH} !=3D "powerpc64" && \ > =A0 =A0 ${LIBC_ARCH} !=3D "sparc64" && \ > - =A0 =A0${LIBC_ARCH} !=3D "mips" > -.include "${.CURDIR}/quad/Makefile.inc" > -.endif > -.if ${LIBC_ARCH} =3D=3D "mips" && \ > - =A0 =A0(!defined(TARGET_ABI) || ${TARGET_ABI} =3D=3D "o32") > + =A0 =A0${MACHINE_ARCH:Mmips64*} =3D=3D "" > =A0.include "${.CURDIR}/quad/Makefile.inc" Here it's definitely wrong to restate !=3Do32 as =3D=3Dn64; n32 doesn't nee= d soft quads, it has 64-bit registers. Thanks, Juli. From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 20:36:27 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8283A1065670; Fri, 7 Jan 2011 20:36:27 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 72BBE8FC20; Fri, 7 Jan 2011 20:36:27 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07KaR4u065107; Fri, 7 Jan 2011 20:36:27 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07KaRCe065105; Fri, 7 Jan 2011 20:36:27 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201101072036.p07KaRCe065105@svn.freebsd.org> From: Warner Losh Date: Fri, 7 Jan 2011 20:36:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217125 - head X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 20:36:27 -0000 Author: imp Date: Fri Jan 7 20:36:27 2011 New Revision: 217125 URL: http://svn.freebsd.org/changeset/base/217125 Log: make targets This produces a list of currently supported targets. Here "supported" means "built in make universe" on the theory that those targets are more supported than any that might work in 'make buildworld TARGET=x TARGET_ARCH=y' since the latter are less tested. Suggested by: rwatson Modified: head/Makefile Modified: head/Makefile ============================================================================== --- head/Makefile Fri Jan 7 20:31:47 2011 (r217124) +++ head/Makefile Fri Jan 7 20:36:27 2011 (r217125) @@ -26,6 +26,7 @@ # delete-old-dirs - Delete obsolete directories. # delete-old-files - Delete obsolete files. # delete-old-libs - Delete obsolete libraries. +# targets - Print a list of supported TARGET/TARGET_ARCH pairs. # # This makefile is simple by design. The FreeBSD make automatically reads # the /usr/share/mk/sys.mk unless the -m argument is specified on the @@ -280,7 +281,7 @@ tinderbox: # with a reasonable chance of success, regardless of how old your # existing system is. # -.if make(universe) || make(universe_kernels) || make(tinderbox) +.if make(universe) || make(universe_kernels) || make(tinderbox) || make(targets) TARGETS?=amd64 arm i386 ia64 mips pc98 powerpc sparc64 sun4v TARGET_ARCHES_arm?= arm armeb TARGET_ARCHES_mips?= mipsel mipseb mips64el mips64eb @@ -291,6 +292,14 @@ TARGET_ARCHES_sun4v?= sparc64 TARGET_ARCHES_${target}?= ${target} .endfor +targets: + @echo "Supported TARGET/TARGET_ARCH pairs" +.for target in ${TARGETS} +.for target_arch in ${TARGET_ARCHES_${target}} + @echo " ${target}/${target_arch}" +.endfor +.endfor + .if defined(DOING_TINDERBOX) FAILFILE=tinderbox.failed MAKEFAIL=tee -a ${FAILFILE} From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 20:53:00 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E58D3106564A; Fri, 7 Jan 2011 20:53:00 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id A00DF8FC18; Fri, 7 Jan 2011 20:53:00 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p07Kmmcs051191; Fri, 7 Jan 2011 13:48:48 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D277C2E.2070300@bsdimp.com> Date: Fri, 07 Jan 2011 13:48:46 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: Juli Mallett References: <201101072026.p07KQXKe064774@svn.freebsd.org> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org, Warner Losh Subject: Re: svn commit: r217123 - in head: . gnu/lib/libgcc gnu/lib/libgomp gnu/usr.bin/binutils gnu/usr.bin/binutils/ld gnu/usr.bin/binutils/libbfd gnu/usr.bin/cc gnu/usr.bin/gdb gnu/usr.bin/gdb/libgdb lib/li... X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 20:53:01 -0000 On 01/07/2011 13:32, Juli Mallett wrote: > On Fri, Jan 7, 2011 at 12:26, Warner Losh wrote: >> --- head/gnu/lib/libgcc/Makefile Fri Jan 7 20:07:30 2011 (r217122) >> +++ head/gnu/lib/libgcc/Makefile Fri Jan 7 20:26:33 2011 (r217123) >> @@ -119,9 +119,10 @@ LIB2FUNCS_EXTRA = floatunsidf.c floatuns >> # _fixsfsi _fixunssfsi _floatdidf _floatdisf >> .endif >> >> -.if ${TARGET_CPUARCH} == "mips" >> +.if ${TARGET_CPUARCH} == mips >> LIB2FUNCS_EXTRA = floatunsidf.c floatunsisf.c >> -.if defined(TARGET_ABI)&& ${TARGET_ABI} != "o32" >> +# XXX do we need n32 here? >> +.if ${TARGET_ARCH:Mmips64*} != "" > Almost certainly. n32 fails the != o32 check. I was careful when I > made the TARGET_ABI changes. There's a possibility that this was > wrong for some reason, but I'm skeptical. I'll update then. It appears to work without it. > > ============================================================================== >> --- head/lib/libc/Makefile Fri Jan 7 20:07:30 2011 (r217122) >> +++ head/lib/libc/Makefile Fri Jan 7 20:26:33 2011 (r217123) >> @@ -68,11 +68,7 @@ NOASM= >> ${LIBC_ARCH} != "ia64"&& \ >> ${LIBC_ARCH} != "powerpc64"&& \ >> ${LIBC_ARCH} != "sparc64"&& \ >> - ${LIBC_ARCH} != "mips" >> -.include "${.CURDIR}/quad/Makefile.inc" >> -.endif >> -.if ${LIBC_ARCH} == "mips"&& \ >> - (!defined(TARGET_ABI) || ${TARGET_ABI} == "o32") >> + ${MACHINE_ARCH:Mmips64*} == "" >> .include "${.CURDIR}/quad/Makefile.inc" > Here it's definitely wrong to restate !=o32 as ==n64; n32 doesn't need > soft quads, it has 64-bit registers. I thought sure that I'd fixed this one too. Warner From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 21:40:35 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4EB6F10656AB; Fri, 7 Jan 2011 21:40:35 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3E1528FC0A; Fri, 7 Jan 2011 21:40:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07LeZVL066584; Fri, 7 Jan 2011 21:40:35 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07LeZBZ066573; Fri, 7 Jan 2011 21:40:35 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101072140.p07LeZBZ066573@svn.freebsd.org> From: John Baldwin Date: Fri, 7 Jan 2011 21:40:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217126 - head/sys/netinet X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 21:40:35 -0000 Author: jhb Date: Fri Jan 7 21:40:34 2011 New Revision: 217126 URL: http://svn.freebsd.org/changeset/base/217126 Log: Trim extra spaces before tabs. Modified: head/sys/netinet/tcp_input.c head/sys/netinet/tcp_lro.c head/sys/netinet/tcp_lro.h head/sys/netinet/tcp_reass.c head/sys/netinet/tcp_syncache.h head/sys/netinet/tcp_timer.c head/sys/netinet/tcp_usrreq.c head/sys/netinet/tcp_var.h head/sys/netinet/udp.h head/sys/netinet/udp_var.h Modified: head/sys/netinet/tcp_input.c ============================================================================== --- head/sys/netinet/tcp_input.c Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_input.c Fri Jan 7 21:40:34 2011 (r217126) @@ -1086,7 +1086,7 @@ relocked: "SYN|FIN segment ignored (based on " "sysctl setting)\n", s, __func__); TCPSTAT_INC(tcps_badsyn); - goto dropunlock; + goto dropunlock; } /* * Segment's flags are (SYN) or (SYN|FIN). @@ -2271,7 +2271,7 @@ tcp_do_segment(struct mbuf *m, struct tc /* * Compute the amount of data in flight first. * We can inject new data into the pipe iff - * we have less than 1/2 the original window's + * we have less than 1/2 the original window's * worth of data in flight. */ awnd = (tp->snd_nxt - tp->snd_fack) + Modified: head/sys/netinet/tcp_lro.c ============================================================================== --- head/sys/netinet/tcp_lro.c Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_lro.c Fri Jan 7 21:40:34 2011 (r217126) @@ -108,7 +108,7 @@ tcp_lro_free(struct lro_ctrl *cntl) while (!SLIST_EMPTY(&cntl->lro_free)) { entry = SLIST_FIRST(&cntl->lro_free); - SLIST_REMOVE_HEAD(&cntl->lro_free, next); + SLIST_REMOVE_HEAD(&cntl->lro_free, next); free(entry, M_DEVBUF); } } Modified: head/sys/netinet/tcp_lro.h ============================================================================== --- head/sys/netinet/tcp_lro.h Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_lro.h Fri Jan 7 21:40:34 2011 (r217126) @@ -41,7 +41,7 @@ struct lro_entry; struct lro_entry { SLIST_ENTRY(lro_entry) next; - struct mbuf *m_head; + struct mbuf *m_head; struct mbuf *m_tail; int timestamp; struct ip *ip; Modified: head/sys/netinet/tcp_reass.c ============================================================================== --- head/sys/netinet/tcp_reass.c Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_reass.c Fri Jan 7 21:40:34 2011 (r217126) @@ -266,7 +266,7 @@ tcp_reass(struct tcpcb *tp, struct tcphd th->th_seq += i; } } - tp->t_rcvoopack++; + tp->t_rcvoopack++; TCPSTAT_INC(tcps_rcvoopack); TCPSTAT_ADD(tcps_rcvoobyte, *tlenp); Modified: head/sys/netinet/tcp_syncache.h ============================================================================== --- head/sys/netinet/tcp_syncache.h Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_syncache.h Fri Jan 7 21:40:34 2011 (r217126) @@ -77,7 +77,7 @@ struct syncache { u_int16_t sc_flags; #ifndef TCP_OFFLOAD_DISABLE struct toe_usrreqs *sc_tu; /* TOE operations */ - void *sc_toepcb; /* TOE protocol block */ + void *sc_toepcb; /* TOE protocol block */ #endif struct label *sc_label; /* MAC label reference */ struct ucred *sc_cred; /* cred cache for jail checks */ Modified: head/sys/netinet/tcp_timer.c ============================================================================== --- head/sys/netinet/tcp_timer.c Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_timer.c Fri Jan 7 21:40:34 2011 (r217126) @@ -486,15 +486,15 @@ tcp_timer_rexmt(void * xtp) tp->t_rxtshift = TCP_MAXRXTSHIFT; TCPSTAT_INC(tcps_timeoutdrop); in_pcbref(inp); - INP_INFO_RUNLOCK(&V_tcbinfo); - INP_WUNLOCK(inp); - INP_INFO_WLOCK(&V_tcbinfo); - INP_WLOCK(inp); - if (in_pcbrele(inp)) { - INP_INFO_WUNLOCK(&V_tcbinfo); - CURVNET_RESTORE(); - return; - } + INP_INFO_RUNLOCK(&V_tcbinfo); + INP_WUNLOCK(inp); + INP_INFO_WLOCK(&V_tcbinfo); + INP_WLOCK(inp); + if (in_pcbrele(inp)) { + INP_INFO_WUNLOCK(&V_tcbinfo); + CURVNET_RESTORE(); + return; + } tp = tcp_drop(tp, tp->t_softerror ? tp->t_softerror : ETIMEDOUT); headlocked = 1; Modified: head/sys/netinet/tcp_usrreq.c ============================================================================== --- head/sys/netinet/tcp_usrreq.c Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_usrreq.c Fri Jan 7 21:40:34 2011 (r217126) @@ -1042,7 +1042,7 @@ struct pr_usrreqs tcp6_usrreqs = { .pru_send = tcp_usr_send, .pru_shutdown = tcp_usr_shutdown, .pru_sockaddr = in6_mapped_sockaddr, - .pru_sosetlabel = in_pcbsosetlabel, + .pru_sosetlabel = in_pcbsosetlabel, .pru_close = tcp_usr_close, }; #endif /* INET6 */ Modified: head/sys/netinet/tcp_var.h ============================================================================== --- head/sys/netinet/tcp_var.h Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/tcp_var.h Fri Jan 7 21:40:34 2011 (r217126) @@ -476,7 +476,7 @@ struct tcpstat { u_long tcps_sack_rexmit_bytes; /* SACK rexmit bytes */ u_long tcps_sack_rcv_blocks; /* SACK blocks (options) received */ u_long tcps_sack_send_blocks; /* SACK blocks (options) sent */ - u_long tcps_sack_sboverflow; /* times scoreboard overflowed */ + u_long tcps_sack_sboverflow; /* times scoreboard overflowed */ /* ECN related stats */ u_long tcps_ecn_ce; /* ECN Congestion Experienced */ @@ -532,7 +532,7 @@ struct xtcp_timer { int tt_keep; /* keepalive */ int tt_2msl; /* 2*msl TIME_WAIT timer */ int tt_delack; /* delayed ACK timer */ - int t_rcvtime; /* Time since last packet received */ + int t_rcvtime; /* Time since last packet received */ }; struct xtcpcb { size_t xt_len; @@ -648,7 +648,7 @@ void tcp_init(void); void tcp_destroy(void); #endif void tcp_fini(void *); -char *tcp_log_addrs(struct in_conninfo *, struct tcphdr *, void *, +char *tcp_log_addrs(struct in_conninfo *, struct tcphdr *, void *, const void *); char *tcp_log_vain(struct in_conninfo *, struct tcphdr *, void *, const void *); Modified: head/sys/netinet/udp.h ============================================================================== --- head/sys/netinet/udp.h Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/udp.h Fri Jan 7 21:40:34 2011 (r217126) @@ -55,7 +55,7 @@ struct udphdr { * UDP Encapsulation of IPsec Packets options. */ /* Encapsulation types. */ -#define UDP_ENCAP_ESPINUDP_NON_IKE 1 /* draft-ietf-ipsec-nat-t-ike-00/01 */ +#define UDP_ENCAP_ESPINUDP_NON_IKE 1 /* draft-ietf-ipsec-nat-t-ike-00/01 */ #define UDP_ENCAP_ESPINUDP 2 /* draft-ietf-ipsec-udp-encaps-02+ */ /* Default ESP in UDP encapsulation port. */ Modified: head/sys/netinet/udp_var.h ============================================================================== --- head/sys/netinet/udp_var.h Fri Jan 7 20:36:27 2011 (r217125) +++ head/sys/netinet/udp_var.h Fri Jan 7 21:40:34 2011 (r217126) @@ -146,7 +146,7 @@ int udp_newudpcb(struct inpcb *); void udp_discardcb(struct udpcb *); void udp_ctlinput(int, struct sockaddr *, void *); -int udp_ctloutput(struct socket *, struct sockopt *); +int udp_ctloutput(struct socket *, struct sockopt *); void udp_init(void); #ifdef VIMAGE void udp_destroy(void); From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 22:34:56 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 61AEB1065672; Fri, 7 Jan 2011 22:34:56 +0000 (UTC) (envelope-from jfv@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 515178FC13; Fri, 7 Jan 2011 22:34:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07MYuL0067827; Fri, 7 Jan 2011 22:34:56 GMT (envelope-from jfv@svn.freebsd.org) Received: (from jfv@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07MYu9S067825; Fri, 7 Jan 2011 22:34:56 GMT (envelope-from jfv@svn.freebsd.org) Message-Id: <201101072234.p07MYu9S067825@svn.freebsd.org> From: Jack F Vogel Date: Fri, 7 Jan 2011 22:34:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217127 - head/sys/dev/ixgbe X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 22:34:56 -0000 Author: jfv Date: Fri Jan 7 22:34:56 2011 New Revision: 217127 URL: http://svn.freebsd.org/changeset/base/217127 Log: kern/153772 fix variable names. Thank you Andrew Boyer for catching these MFC in 3 days Modified: head/sys/dev/ixgbe/ixgbe.c Modified: head/sys/dev/ixgbe/ixgbe.c ============================================================================== --- head/sys/dev/ixgbe/ixgbe.c Fri Jan 7 21:40:34 2011 (r217126) +++ head/sys/dev/ixgbe/ixgbe.c Fri Jan 7 22:34:56 2011 (r217127) @@ -5129,13 +5129,13 @@ ixgbe_add_hw_stats(struct adapter *adapt CTLFLAG_RD, &stats->lxontxc, "Link XON Transmitted"); SYSCTL_ADD_QUAD(ctx, stat_list, OID_AUTO, "link_xon_rcvd", - CTLFLAG_RD, &stats->lxontxc, + CTLFLAG_RD, &stats->lxonrxc, "Link XON Received"); SYSCTL_ADD_QUAD(ctx, stat_list, OID_AUTO, "link_xoff_txd", CTLFLAG_RD, &stats->lxofftxc, "Link XOFF Transmitted"); SYSCTL_ADD_QUAD(ctx, stat_list, OID_AUTO, "link_xoff_rcvd", - CTLFLAG_RD, &stats->lxofftxc, + CTLFLAG_RD, &stats->lxoffrxc, "Link XOFF Received"); /* Packet Reception Stats */ From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 22:57:31 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B25CB106566C; Fri, 7 Jan 2011 22:57:31 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A02CE8FC0A; Fri, 7 Jan 2011 22:57:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07MvV9Y068457; Fri, 7 Jan 2011 22:57:31 GMT (envelope-from tijl@svn.freebsd.org) Received: (from tijl@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07MvVe5068451; Fri, 7 Jan 2011 22:57:31 GMT (envelope-from tijl@svn.freebsd.org) Message-Id: <201101072257.p07MvVe5068451@svn.freebsd.org> From: Tijl Coosemans Date: Fri, 7 Jan 2011 22:57:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217128 - in head: gnu/usr.bin/cc sys/arm/include sys/i386/include sys/mips/include sys/powerpc/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 22:57:31 -0000 Author: tijl Date: Fri Jan 7 22:57:31 2011 New Revision: 217128 URL: http://svn.freebsd.org/changeset/base/217128 Log: Remove unused support for 64 bit long on 32 bit architectures. It was used mainly to discover and fix some 64-bit portability problems before 64-bit arches were widely available. Discussed with: bde Approved by: kib (mentor) Modified: head/gnu/usr.bin/cc/Makefile.inc head/sys/arm/include/_limits.h head/sys/i386/include/_limits.h head/sys/mips/include/_limits.h head/sys/powerpc/include/_limits.h Modified: head/gnu/usr.bin/cc/Makefile.inc ============================================================================== --- head/gnu/usr.bin/cc/Makefile.inc Fri Jan 7 22:34:56 2011 (r217127) +++ head/gnu/usr.bin/cc/Makefile.inc Fri Jan 7 22:57:31 2011 (r217128) @@ -22,12 +22,6 @@ CFLAGS+= -DPREFIX=\"${TOOLS_PREFIX}/usr\ #CFLAGS+= -DWANT_COMPILER_INVARIANTS CSTD?= gnu89 -# If building 64-bit longs for the i386, "_LARGE_LONG" should also be defined -# to get the proper sizes in limits.h -.if defined(LONG_TYPE_SIZE) -CFLAGS+= -DLONG_TYPE_SIZE=${LONG_TYPE_SIZE} -.endif - .if ${TARGET_ARCH} != ${MACHINE_ARCH} CFLAGS+= -DCROSS_COMPILE .endif Modified: head/sys/arm/include/_limits.h ============================================================================== --- head/sys/arm/include/_limits.h Fri Jan 7 22:34:56 2011 (r217127) +++ head/sys/arm/include/_limits.h Fri Jan 7 22:57:31 2011 (r217128) @@ -59,16 +59,9 @@ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ -/* Bad hack for gcc configured to give 64-bit longs. */ -#ifdef _LARGE_LONG -#define __ULONG_MAX 0xffffffffffffffffUL -#define __LONG_MAX 0x7fffffffffffffffL -#define __LONG_MIN (-0x7fffffffffffffffL - 1) -#else #define __ULONG_MAX 0xffffffffUL /* max value for an unsigned long */ #define __LONG_MAX 0x7fffffffL /* max value for a long */ #define __LONG_MIN (-0x7fffffffL - 1) /* min value for a long */ -#endif /* max value for an unsigned long long */ #define __ULLONG_MAX 0xffffffffffffffffULL @@ -87,11 +80,7 @@ #define __QUAD_MAX __LLONG_MAX /* max value for a quad_t */ #define __QUAD_MIN __LLONG_MIN /* min value for a quad_t */ -#ifdef _LARGE_LONG -#define __LONG_BIT 64 -#else #define __LONG_BIT 32 -#endif #define __WORD_BIT 32 /* Minimum signal stack size. */ Modified: head/sys/i386/include/_limits.h ============================================================================== --- head/sys/i386/include/_limits.h Fri Jan 7 22:34:56 2011 (r217127) +++ head/sys/i386/include/_limits.h Fri Jan 7 22:57:31 2011 (r217128) @@ -59,16 +59,9 @@ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ -/* Bad hack for gcc configured to give 64-bit longs. */ -#ifdef _LARGE_LONG -#define __ULONG_MAX 0xffffffffffffffffUL -#define __LONG_MAX 0x7fffffffffffffffL -#define __LONG_MIN (-0x7fffffffffffffffL - 1) -#else #define __ULONG_MAX 0xffffffffUL /* max value for an unsigned long */ #define __LONG_MAX 0x7fffffffL /* max value for a long */ #define __LONG_MIN (-0x7fffffffL - 1) /* min value for a long */ -#endif /* max value for an unsigned long long */ #define __ULLONG_MAX 0xffffffffffffffffULL @@ -87,11 +80,7 @@ #define __QUAD_MAX __LLONG_MAX /* max value for a quad_t */ #define __QUAD_MIN __LLONG_MIN /* min value for a quad_t */ -#ifdef _LARGE_LONG -#define __LONG_BIT 64 -#else #define __LONG_BIT 32 -#endif #define __WORD_BIT 32 /* Modified: head/sys/mips/include/_limits.h ============================================================================== --- head/sys/mips/include/_limits.h Fri Jan 7 22:34:56 2011 (r217127) +++ head/sys/mips/include/_limits.h Fri Jan 7 22:57:31 2011 (r217128) @@ -34,10 +34,6 @@ #ifndef _MACHINE__LIMITS_H_ #define _MACHINE__LIMITS_H_ -#if _MIPS_SZLONG == 64 -#define _LARGE_LONG -#endif - /* * According to ANSI (section 2.2.4.2), the values below must be usable by * #if preprocessing directives. Additionally, the expression must have the @@ -64,15 +60,16 @@ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ -/* Bad hack for gcc configured to give 64-bit longs. */ -#ifdef _LARGE_LONG +#ifdef __LP64__ #define __ULONG_MAX 0xffffffffffffffffUL #define __LONG_MAX 0x7fffffffffffffffL #define __LONG_MIN (-0x7fffffffffffffffL - 1) +#define __LONG_BIT 64 #else #define __ULONG_MAX 0xffffffffUL /* max value for an unsigned long */ #define __LONG_MAX 0x7fffffffL /* max value for a long */ #define __LONG_MIN (-0x7fffffffL - 1) /* min value for a long */ +#define __LONG_BIT 32 #endif /* max value for an unsigned long long */ @@ -92,11 +89,6 @@ #define __QUAD_MAX __LLONG_MAX /* max value for a quad_t */ #define __QUAD_MIN __LLONG_MIN /* min value for a quad_t */ -#ifdef _LARGE_LONG -#define __LONG_BIT 64 -#else -#define __LONG_BIT 32 -#endif #define __WORD_BIT 32 #define __MINSIGSTKSZ (512 * 4) Modified: head/sys/powerpc/include/_limits.h ============================================================================== --- head/sys/powerpc/include/_limits.h Fri Jan 7 22:34:56 2011 (r217127) +++ head/sys/powerpc/include/_limits.h Fri Jan 7 22:57:31 2011 (r217128) @@ -59,14 +59,16 @@ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ -#if defined(_LARGE_LONG) || defined(__LP64__) +#ifdef __LP64__ #define __ULONG_MAX 0xffffffffffffffffUL #define __LONG_MAX 0x7fffffffffffffffL #define __LONG_MIN (-0x7fffffffffffffffL - 1) +#define __LONG_BIT 64 #else #define __ULONG_MAX 0xffffffffUL /* max value for an unsigned long */ #define __LONG_MAX 0x7fffffffL /* max value for a long */ #define __LONG_MIN (-0x7fffffffL - 1) /* min value for a long */ +#define __LONG_BIT 32 #endif #define __ULLONG_MAX 0xffffffffffffffffULL @@ -89,11 +91,6 @@ #define __QUAD_MAX __LLONG_MAX /* max value for a quad_t */ #define __QUAD_MIN __LLONG_MIN /* min value for a quad_t */ -#if defined(_LARGE_LONG) || defined(__LP64__) -#define __LONG_BIT 64 -#else -#define __LONG_BIT 32 -#endif #define __WORD_BIT 32 /* Minimum signal stack size. */ From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 22:58:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 367FA106566B; Fri, 7 Jan 2011 22:58:13 +0000 (UTC) (envelope-from jfv@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2613D8FC15; Fri, 7 Jan 2011 22:58:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07MwDId068511; Fri, 7 Jan 2011 22:58:13 GMT (envelope-from jfv@svn.freebsd.org) Received: (from jfv@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07MwDJK068509; Fri, 7 Jan 2011 22:58:13 GMT (envelope-from jfv@svn.freebsd.org) Message-Id: <201101072258.p07MwDJK068509@svn.freebsd.org> From: Jack F Vogel Date: Fri, 7 Jan 2011 22:58:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217129 - head/sys/dev/ixgbe X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 22:58:13 -0000 Author: jfv Date: Fri Jan 7 22:58:12 2011 New Revision: 217129 URL: http://svn.freebsd.org/changeset/base/217129 Log: Fix to kern/150247 - make ixgbe buildable for 7.x Modified: head/sys/dev/ixgbe/ixgbe.h Modified: head/sys/dev/ixgbe/ixgbe.h ============================================================================== --- head/sys/dev/ixgbe/ixgbe.h Fri Jan 7 22:57:31 2011 (r217128) +++ head/sys/dev/ixgbe/ixgbe.h Fri Jan 7 22:58:12 2011 (r217129) @@ -484,7 +484,7 @@ ixgbe_is_sfp(struct ixgbe_hw *hw) } /* Workaround to make 8.0 buildable */ -#if __FreeBSD_version < 800504 +#if __FreeBSD_version >= 800000 && __FreeBSD_version < 800504 static __inline int drbr_needs_enqueue(struct ifnet *ifp, struct buf_ring *br) { From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 23:19:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CA0F61065674; Fri, 7 Jan 2011 23:19:13 +0000 (UTC) (envelope-from jfv@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B99848FC18; Fri, 7 Jan 2011 23:19:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07NJDE1069036; Fri, 7 Jan 2011 23:19:13 GMT (envelope-from jfv@svn.freebsd.org) Received: (from jfv@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07NJD9S069034; Fri, 7 Jan 2011 23:19:13 GMT (envelope-from jfv@svn.freebsd.org) Message-Id: <201101072319.p07NJD9S069034@svn.freebsd.org> From: Jack F Vogel Date: Fri, 7 Jan 2011 23:19:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217131 - head/sys/dev/ixgbe X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 23:19:13 -0000 Author: jfv Date: Fri Jan 7 23:19:13 2011 New Revision: 217131 URL: http://svn.freebsd.org/changeset/base/217131 Log: kern/150247 - virtualization code also needs fix for 7.X to be buildable... MFC in 3 days Modified: head/sys/dev/ixgbe/ixv.h Modified: head/sys/dev/ixgbe/ixv.h ============================================================================== --- head/sys/dev/ixgbe/ixv.h Fri Jan 7 23:11:19 2011 (r217130) +++ head/sys/dev/ixgbe/ixv.h Fri Jan 7 23:19:13 2011 (r217131) @@ -400,7 +400,7 @@ struct adapter { #define IXV_TX_LOCK_ASSERT(_sc) mtx_assert(&(_sc)->tx_mtx, MA_OWNED) /* Workaround to make 8.0 buildable */ -#if __FreeBSD_version < 800504 +#if __FreeBSD_version >= 800000 && __FreeBSD_version < 800504 static __inline int drbr_needs_enqueue(struct ifnet *ifp, struct buf_ring *br) { From owner-svn-src-head@FreeBSD.ORG Fri Jan 7 23:39:41 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E4A7F106566B; Fri, 7 Jan 2011 23:39:41 +0000 (UTC) (envelope-from jfv@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D43398FC0A; Fri, 7 Jan 2011 23:39:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07NdfLi069491; Fri, 7 Jan 2011 23:39:41 GMT (envelope-from jfv@svn.freebsd.org) Received: (from jfv@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07NdfqF069489; Fri, 7 Jan 2011 23:39:41 GMT (envelope-from jfv@svn.freebsd.org) Message-Id: <201101072339.p07NdfqF069489@svn.freebsd.org> From: Jack F Vogel Date: Fri, 7 Jan 2011 23:39:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217132 - head/sys/dev/ixgbe X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 23:39:42 -0000 Author: jfv Date: Fri Jan 7 23:39:41 2011 New Revision: 217132 URL: http://svn.freebsd.org/changeset/base/217132 Log: CSUM flags need to be OS version sensitive in ixv code MFC in 3 days Modified: head/sys/dev/ixgbe/ixv.h Modified: head/sys/dev/ixgbe/ixv.h ============================================================================== --- head/sys/dev/ixgbe/ixv.h Fri Jan 7 23:19:13 2011 (r217131) +++ head/sys/dev/ixgbe/ixv.h Fri Jan 7 23:39:41 2011 (r217132) @@ -175,7 +175,11 @@ #define VFTA_SIZE 128 /* Offload bits in mbuf flag */ +#if __FreeBSD_version >= 800000 #define CSUM_OFFLOAD (CSUM_IP|CSUM_TCP|CSUM_UDP|CSUM_SCTP) +#else +#define CSUM_OFFLOAD (CSUM_IP|CSUM_TCP|CSUM_UDP) +#endif /* ***************************************************************************** From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 00:03:19 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5433A10656A5; Sat, 8 Jan 2011 00:03:19 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 28F8D8FC12; Sat, 8 Jan 2011 00:03:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p0803J81070171; Sat, 8 Jan 2011 00:03:19 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p0803J1S070169; Sat, 8 Jan 2011 00:03:19 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201101080003.p0803J1S070169@svn.freebsd.org> From: Jilles Tjoelker Date: Sat, 8 Jan 2011 00:03:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217133 - head/usr.bin/sed X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 00:03:19 -0000 Author: jilles Date: Sat Jan 8 00:03:18 2011 New Revision: 217133 URL: http://svn.freebsd.org/changeset/base/217133 Log: sed: Try hard links to make -i target available continually. When creating a backup file, sed renamed the original before renaming the changed copy into place, leading to a short time when no file with the original name was present (usually only visible on SMP systems). Try creating the backup file using a hard link instead, avoiding this problem. If creating the hard link fails for any reason, fall back to the old rename method. When not creating a backup file, sed already renamed the changed copy onto the original. This remains unchanged. I am not adding the suppression of redundant fchown/fchmod to this commit, because FreeBSD appears to check this in the kernel (for msdosfs at least). PR: bin/153261 Submitted by: Pedro F. Giffuni Reviewed by: dds (older version) Obtained from: Illumos MFC after: 2 weeks Modified: head/usr.bin/sed/main.c Modified: head/usr.bin/sed/main.c ============================================================================== --- head/usr.bin/sed/main.c Fri Jan 7 23:39:41 2011 (r217132) +++ head/usr.bin/sed/main.c Sat Jan 8 00:03:18 2011 (r217133) @@ -338,18 +338,35 @@ mf_fgets(SPACE *sp, enum e_spflag spflag if (infile != NULL) { fclose(infile); if (*oldfname != '\0') { - if (rename(fname, oldfname) != 0) { + /* if there was a backup file, remove it */ + unlink(oldfname); + /* + * Backup the original. Note that hard links + * are not supported on all filesystems. + */ + if ((link(fname, oldfname) != 0) && + (rename(fname, oldfname) != 0)) { warn("rename()"); - unlink(tmpfname); + if (*tmpfname) + unlink(tmpfname); exit(1); } *oldfname = '\0'; } if (*tmpfname != '\0') { if (outfile != NULL && outfile != stdout) - fclose(outfile); + if (fclose(outfile) != 0) { + warn("fclose()"); + unlink(tmpfname); + exit(1); + } outfile = NULL; - rename(tmpfname, fname); + if (rename(tmpfname, fname) != 0) { + /* this should not happen really! */ + warn("rename()"); + unlink(tmpfname); + exit(1); + } *tmpfname = '\0'; } outfname = NULL; From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 00:06:22 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 947CE1065675; Sat, 8 Jan 2011 00:06:22 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8301B8FC17; Sat, 8 Jan 2011 00:06:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p0806MRJ070344; Sat, 8 Jan 2011 00:06:22 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p0806M7L070340; Sat, 8 Jan 2011 00:06:22 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201101080006.p0806M7L070340@svn.freebsd.org> From: Jilles Tjoelker Date: Sat, 8 Jan 2011 00:06:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217134 - head/tools/regression/usr.bin/sed X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 00:06:22 -0000 Author: jilles Date: Sat Jan 8 00:06:22 2011 New Revision: 217134 URL: http://svn.freebsd.org/changeset/base/217134 Log: sed: Add test for r217133 (-i race). PR: bin/153261 MFC after: 2 weeks Added: head/tools/regression/usr.bin/sed/inplace_race.t (contents, props changed) Modified: head/tools/regression/usr.bin/sed/Makefile Modified: head/tools/regression/usr.bin/sed/Makefile ============================================================================== --- head/tools/regression/usr.bin/sed/Makefile Sat Jan 8 00:03:18 2011 (r217133) +++ head/tools/regression/usr.bin/sed/Makefile Sat Jan 8 00:06:22 2011 (r217134) @@ -3,3 +3,4 @@ all: @m4 ${.CURDIR}/../regress.m4 ${.CURDIR}/regress.sh | sh /dev/stdin ${.CURDIR} @sh multitest.t + @sh inplace_race.t Added: head/tools/regression/usr.bin/sed/inplace_race.t ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/regression/usr.bin/sed/inplace_race.t Sat Jan 8 00:06:22 2011 (r217134) @@ -0,0 +1,83 @@ +#!/bin/sh + +#- +# Copyright (c) 2011 Jilles Tjoelker +# 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$ + +: "${SED=sed}" + +# This test really needs an SMP system. On an UP system, it will +# usually pass even if the race condition exists. +if command -v cpuset >/dev/null; then + case `cpuset -g -p $$` in + *,*) ;; + *) + echo '1..0 # Skipped: not an SMP system' + exit 0 ;; + esac +fi + +echo "1..1" + +T=$(mktemp -d "${TMPDIR:-/tmp}/sed-test.XXXXXX") +trap 'cd /; rm -rf "$T"' 0 +cd "$T" + +data=abababab +data=$data$data$data$data +data=$data$data$data$data +data=$data$data$data$data +data=$data$data$data$data +data="BEGIN +$data +END" +for i in 0 1 2 3 4 5 6 7 8 9; do + echo "$data" >file$i +done +len=${#data} + +i=0 +while [ $i -lt 100 ]; do + ${SED} -i.prev "s/$i/ab/" file[0-9] + i=$((i+1)) +done & +sedproc=$! + +while :; do + set -- file[0-9] + if [ $# -ne 10 ]; then + echo "not ok 1 inplace_race" + exit 3 + fi +done & +checkproc=$! + +wait $sedproc +kill $checkproc 2>/dev/null +wait $checkproc >/dev/null 2>&1 +if [ $? -ne 3 ]; then + echo "ok 1 inplace_race" +fi From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 00:41:17 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 390E910656AA; Sat, 8 Jan 2011 00:41:17 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail05.syd.optusnet.com.au (mail05.syd.optusnet.com.au [211.29.132.186]) by mx1.freebsd.org (Postfix) with ESMTP id E69A48FC0C; Sat, 8 Jan 2011 00:41:16 +0000 (UTC) Received: from c122-106-165-206.carlnfd1.nsw.optusnet.com.au (c122-106-165-206.carlnfd1.nsw.optusnet.com.au [122.106.165.206]) by mail05.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p080fDGd021336 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 8 Jan 2011 11:41:14 +1100 Date: Sat, 8 Jan 2011 11:41:13 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Jilles Tjoelker In-Reply-To: <201101080003.p0803J1S070169@svn.freebsd.org> Message-ID: <20110108112559.U7585@besplex.bde.org> References: <201101080003.p0803J1S070169@svn.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r217133 - head/usr.bin/sed X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 00:41:17 -0000 On Sat, 8 Jan 2011, Jilles Tjoelker wrote: > Log: > sed: Try hard links to make -i target available continually. > ... > I am not adding the suppression of redundant fchown/fchmod to this commit, > because FreeBSD appears to check this in the kernel (for msdosfs at least). I vaguely remember fixing (?) ffs to allow null changes even in cases where permissions should deny changes (perhaps even null ones). msdosfs is still very inconsistent in ignoring (non-null) changes for attributes that it cannot support. Most annoying is utimes() with a non-null times pointer. This requires either the file's uid to match the process's uid, or superuser privileges. The file's uid is fake. It can be anything, but is rarely you. So you normally need superuser privilege to copy file times. msdosfs cannot really support copying file times from most file other file systems even for the superuser, since it only has mtimes and has deficient precision even for those, but it silently ignores errors from these problems. Ignoring errors is not good, but this is almost the best possible. Best would be to give the user and application more control, and have applications actually control things properly. The best possible behaviour is what happens for copying ids when the ids don't match -- cp sees the error and reports it and then proceeds; this is accidentally best since there is no possibility of setting the ids. However, for file times it is possible in theory to set the mtime, but impossible in practice unless you are the superuser or own the file. Bruce From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 00:44:17 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 75E381065693; Sat, 8 Jan 2011 00:44:17 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 64DAE8FC12; Sat, 8 Jan 2011 00:44:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p080iHtM071124; Sat, 8 Jan 2011 00:44:17 GMT (envelope-from bz@svn.freebsd.org) Received: (from bz@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p080iHR2071122; Sat, 8 Jan 2011 00:44:17 GMT (envelope-from bz@svn.freebsd.org) Message-Id: <201101080044.p080iHR2071122@svn.freebsd.org> From: "Bjoern A. Zeeb" Date: Sat, 8 Jan 2011 00:44:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217135 - head/share/man/man4 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 00:44:17 -0000 Author: bz Date: Sat Jan 8 00:44:17 2011 New Revision: 217135 URL: http://svn.freebsd.org/changeset/base/217135 Log: Clarify when we switch from keepidle to keepinvtl intervals if sending TCP keepalive probes is enabled. Reviewed by: gnn MFC After: 3 days Modified: head/share/man/man4/tcp.4 Modified: head/share/man/man4/tcp.4 ============================================================================== --- head/share/man/man4/tcp.4 Sat Jan 8 00:06:22 2011 (r217134) +++ head/share/man/man4/tcp.4 Sat Jan 8 00:44:17 2011 (r217135) @@ -32,7 +32,7 @@ .\" From: @(#)tcp.4 8.1 (Berkeley) 6/5/93 .\" $FreeBSD$ .\" -.Dd September 16, 2010 +.Dd January 8, 2011 .Dt TCP 4 .Os .Sh NAME @@ -289,7 +289,9 @@ Amount of time, in milliseconds, that th before keepalive probes (if enabled) are sent. .It Va keepintvl The interval, in milliseconds, between keepalive probes sent to remote -machines. +machines, when no response is received on a +.Va keepidle +probe. After .Dv TCPTV_KEEPCNT (default 8) probes are sent, with no response, the connection is dropped. From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 01:57:24 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 32FCB10656A4; Sat, 8 Jan 2011 01:57:24 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 21EB08FC0C; Sat, 8 Jan 2011 01:57:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p081vOpk072919; Sat, 8 Jan 2011 01:57:24 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p081vOwd072917; Sat, 8 Jan 2011 01:57:24 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201101080157.p081vOwd072917@svn.freebsd.org> From: Xin LI Date: Sat, 8 Jan 2011 01:57:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217140 - head/usr.sbin/ndp X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 01:57:24 -0000 Author: delphij Date: Sat Jan 8 01:57:23 2011 New Revision: 217140 URL: http://svn.freebsd.org/changeset/base/217140 Log: Use ether_ntoa instead of home-grown version. Noticed by: Boris Kochergin Modified: head/usr.sbin/ndp/ndp.c Modified: head/usr.sbin/ndp/ndp.c ============================================================================== --- head/usr.sbin/ndp/ndp.c Sat Jan 8 01:39:43 2011 (r217139) +++ head/usr.sbin/ndp/ndp.c Sat Jan 8 01:57:23 2011 (r217140) @@ -153,7 +153,6 @@ static void getdefif(void); static void setdefif(char *); #endif static char *sec2str(time_t); -static char *ether_str(struct sockaddr_dl *); static void ts_print(const struct timeval *); #ifdef ICMPV6CTL_ND6_DRLIST @@ -820,17 +819,14 @@ getnbrinfo(addr, ifindex, warning) } static char * -ether_str(sdl) - struct sockaddr_dl *sdl; +ether_str(struct sockaddr_dl *sdl) { static char hbuf[NI_MAXHOST]; - u_char *cp; - if (sdl->sdl_alen) { - cp = (u_char *)LLADDR(sdl); - snprintf(hbuf, sizeof(hbuf), "%x:%x:%x:%x:%x:%x", - cp[0], cp[1], cp[2], cp[3], cp[4], cp[5]); - } else + if (sdl->sdl_alen > 0) + strlcpy(hbuf, ether_ntoa((struct ether_addr *)LLADDR(sdl)), + sizeof(hbuf)); + else snprintf(hbuf, sizeof(hbuf), "(incomplete)"); return(hbuf); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 05:14:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5862A10656A5 for ; Sat, 8 Jan 2011 05:14:00 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx22.fluidhosting.com [204.14.89.5]) by mx1.freebsd.org (Postfix) with ESMTP id 035578FC08 for ; Sat, 8 Jan 2011 05:13:59 +0000 (UTC) Received: (qmail 31347 invoked by uid 399); 8 Jan 2011 05:13:59 -0000 Received: from localhost (HELO doug-optiplex.ka9q.net) (dougb@dougbarton.us@127.0.0.1) by localhost with ESMTPAM; 8 Jan 2011 05:13:59 -0000 X-Originating-IP: 127.0.0.1 X-Sender: dougb@dougbarton.us Message-ID: <4D27F295.1030609@FreeBSD.org> Date: Fri, 07 Jan 2011 21:13:57 -0800 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.13) Gecko/20101210 Thunderbird/3.1.7 MIME-Version: 1.0 To: Warner Losh References: <201101062107.p06L7p9o028440@svn.freebsd.org> In-Reply-To: <201101062107.p06L7p9o028440@svn.freebsd.org> X-Enigmail-Version: 1.1.2 OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217071 - head/lib/bind X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 05:14:00 -0000 I've said before that I like to have the opportunity to pre-commit review patches in this area because at minimum it helps me to be aware of them for potential MFC purposes. That said, I appreciate the help, especially with the more "exotic" arches that I don't have experience with. A few comments below. On 01/06/2011 13:07, Warner Losh wrote: > Author: imp > Date: Thu Jan 6 21:07:51 2011 > New Revision: 217071 > URL: http://svn.freebsd.org/changeset/base/217071 > > Log: > Make this work on big endian MIPS, while not breaking it for small > endian mips. This will also make it work automatically on all future > big endian platforms. > > Modified: > head/lib/bind/config.mk > > Modified: head/lib/bind/config.mk > ============================================================================== > --- head/lib/bind/config.mk Thu Jan 6 21:04:00 2011 (r217070) > +++ head/lib/bind/config.mk Thu Jan 6 21:07:51 2011 (r217071) > @@ -1,6 +1,7 @@ > # $FreeBSD$ > > .include > +.include > > # BIND version number > .if defined(BIND_DIR)&& exists(${BIND_DIR}/version) > @@ -45,7 +46,7 @@ CFLAGS+= -DOPENSSL > CFLAGS+= -DUSE_MD5 > > # Endianness > -.if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "sparc64" > +.if ${TARGET_ENDIANNESS} == 4321 > CFLAGS+= -DWORDS_BIGENDIAN > .endif This is just the kind of solution I was hoping would be available, and exactly the kind I prefer, the no-maintenance kind. :) Is this safe to MFC, or does it require bits that are only in HEAD atm? If the latter, can you please let me know when it's ready to go? Thanks. > @@ -64,11 +65,7 @@ CFLAGS+= -I${LIB_BIND_DIR} > .endif > > # Use the right version of the atomic.h file from lib/isc > -.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" > -ISC_ATOMIC_ARCH= x86_32 > -.else > -ISC_ATOMIC_ARCH= ${MACHINE_CPUARCH} > -.endif > +ISC_ATOMIC_ARCH=${MACHINE_CPUARCH:S/i386/x86_32/:S/amd64/x86_32/} This change I am less enthusiastic about. It seems to me that it does the exact same thing, but while admittedly quite a bit more clever than I am capable of I find it less readable. Unless this is doing something more or better than the previous code I will likely revert this. Doug -- Nothin' ever doesn't change, but nothin' changes much. -- OK Go Breadth of IT experience, and depth of knowledge in the DNS. Yours for the right price. :) http://SupersetSolutions.com/ From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 10:56:58 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 78AE7106566B; Sat, 8 Jan 2011 10:56:58 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 67ED08FC14; Sat, 8 Jan 2011 10:56:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08AuwTR088928; Sat, 8 Jan 2011 10:56:58 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08Auwqu088926; Sat, 8 Jan 2011 10:56:58 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081056.p08Auwqu088926@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 10:56:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217143 - head/lib/libc/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 10:56:58 -0000 Author: kib Date: Sat Jan 8 10:56:58 2011 New Revision: 217143 URL: http://svn.freebsd.org/changeset/base/217143 Log: Fix struct FILE * leak on error (in disabled by default hesiod support code). Submitted by: henning petersen PR: 153756 MFC after: 1 week Modified: head/lib/libc/net/hesiod.c Modified: head/lib/libc/net/hesiod.c ============================================================================== --- head/lib/libc/net/hesiod.c Sat Jan 8 08:58:46 2011 (r217142) +++ head/lib/libc/net/hesiod.c Sat Jan 8 10:56:58 2011 (r217143) @@ -324,6 +324,7 @@ read_config_file(ctx, filename) ? &ctx->lhs : &ctx->rhs; *which = strdup(data); if (!*which) { + fclose(fp); errno = ENOMEM; return -1; } From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 11:04:31 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 22B911065673; Sat, 8 Jan 2011 11:04:31 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 11EB48FC13; Sat, 8 Jan 2011 11:04:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08B4UES089192; Sat, 8 Jan 2011 11:04:30 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08B4UlD089190; Sat, 8 Jan 2011 11:04:30 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081104.p08B4UlD089190@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 11:04:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217144 - head/lib/libc/stdlib X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 11:04:31 -0000 Author: kib Date: Sat Jan 8 11:04:30 2011 New Revision: 217144 URL: http://svn.freebsd.org/changeset/base/217144 Log: Fix some style(9) issues. Do not use strlcpy() where simple assignment is enough. Noted by: bde (long time ago) MFC after: 1 week Modified: head/lib/libc/stdlib/realpath.c Modified: head/lib/libc/stdlib/realpath.c ============================================================================== --- head/lib/libc/stdlib/realpath.c Sat Jan 8 10:56:58 2011 (r217143) +++ head/lib/libc/stdlib/realpath.c Sat Jan 8 11:04:30 2011 (r217144) @@ -54,7 +54,7 @@ realpath(const char * __restrict path, c char *p, *q, *s; size_t left_len, resolved_len; unsigned symlinks; - int serrno, slen, m; + int m, serrno, slen; char left[PATH_MAX], next_token[PATH_MAX], symlink[PATH_MAX]; if (path == NULL) { @@ -73,7 +73,6 @@ realpath(const char * __restrict path, c m = 1; } else m = 0; - symlinks = 0; if (path[0] == '/') { resolved[0] = '/'; @@ -86,8 +85,10 @@ realpath(const char * __restrict path, c if (getcwd(resolved, PATH_MAX) == NULL) { if (m) free(resolved); - else - strlcpy(resolved, ".", PATH_MAX); + else { + resolved[0] = '.'; + resolved[1] = '\0'; + } return (NULL); } resolved_len = strlen(resolved); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 11:13:34 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8CD981065698; Sat, 8 Jan 2011 11:13:34 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 78F2C8FC15; Sat, 8 Jan 2011 11:13:34 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08BDYeP089419; Sat, 8 Jan 2011 11:13:34 GMT (envelope-from tijl@svn.freebsd.org) Received: (from tijl@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08BDYhP089410; Sat, 8 Jan 2011 11:13:34 GMT (envelope-from tijl@svn.freebsd.org) Message-Id: <201101081113.p08BDYhP089410@svn.freebsd.org> From: Tijl Coosemans Date: Sat, 8 Jan 2011 11:13:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217145 - in head/sys: amd64/include arm/include i386/include ia64/include mips/include powerpc/include sparc64/include sun4v/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 11:13:34 -0000 Author: tijl Date: Sat Jan 8 11:13:34 2011 New Revision: 217145 URL: http://svn.freebsd.org/changeset/base/217145 Log: Fix types of some values in machine/_limits.h. On some architectures UCHAR_MAX and USHRT_MAX had type unsigned int. However, lacking integer suffixes for types smaller than int, their type should correspond to that of an object of type unsigned char (or short) when used in an expression with objects of type int. In that case unsigned char (short) are promoted to int (i.e. signed) so the type of UCHAR_MAX and USHRT_MAX should also be int. Where MIN/MAX constants implicitly have the correct type the suffix has been removed. While here, correct some comments. Reviewed by: bde Approved by: kib (mentor) Modified: head/sys/amd64/include/_limits.h head/sys/arm/include/_limits.h head/sys/i386/include/_limits.h head/sys/ia64/include/_limits.h head/sys/mips/include/_limits.h head/sys/powerpc/include/_limits.h head/sys/sparc64/include/_limits.h head/sys/sun4v/include/_limits.h Modified: head/sys/amd64/include/_limits.h ============================================================================== --- head/sys/amd64/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/amd64/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -40,8 +40,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -49,19 +47,19 @@ #define __SCHAR_MAX 0x7f /* max value for a signed char */ #define __SCHAR_MIN (-0x7f - 1) /* min value for a signed char */ -#define __UCHAR_MAX 0xffU /* max value for an unsigned char */ +#define __UCHAR_MAX 0xff /* max value for an unsigned char */ -#define __USHRT_MAX 0xffffU /* max value for an unsigned short */ +#define __USHRT_MAX 0xffff /* max value for an unsigned short */ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff - 1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ -#define __ULONG_MAX 0xffffffffffffffffUL /* max for an unsigned long */ -#define __LONG_MAX 0x7fffffffffffffffL /* max for a long */ -#define __LONG_MIN (-0x7fffffffffffffffL - 1) /* min for a long */ +#define __ULONG_MAX 0xffffffffffffffff /* max for an unsigned long */ +#define __LONG_MAX 0x7fffffffffffffff /* max for a long */ +#define __LONG_MIN (-0x7fffffffffffffff - 1) /* min for a long */ /* max value for an unsigned long long */ #define __ULLONG_MAX 0xffffffffffffffffULL @@ -83,10 +81,7 @@ #define __LONG_BIT 64 #define __WORD_BIT 32 -/* - * Minimum signal stack size. The current signal frame - * for i386 is 408 bytes large. - */ +/* Minimum signal stack size. */ #define __MINSIGSTKSZ (512 * 4) #endif /* !_MACHINE__LIMITS_H_ */ Modified: head/sys/arm/include/_limits.h ============================================================================== --- head/sys/arm/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/arm/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -40,8 +40,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -55,7 +53,7 @@ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff - 1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ Modified: head/sys/i386/include/_limits.h ============================================================================== --- head/sys/i386/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/i386/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -40,8 +40,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -55,7 +53,7 @@ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff - 1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ @@ -83,10 +81,7 @@ #define __LONG_BIT 32 #define __WORD_BIT 32 -/* - * Minimum signal stack size. The current signal frame - * for i386 is 408 bytes large. - */ +/* Minimum signal stack size. */ #define __MINSIGSTKSZ (512 * 4) #endif /* !_MACHINE__LIMITS_H_ */ Modified: head/sys/ia64/include/_limits.h ============================================================================== --- head/sys/ia64/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/ia64/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -42,8 +42,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -51,21 +49,21 @@ #define __SCHAR_MAX 0x7f /* max value for a signed char */ #define __SCHAR_MIN (-0x7f-1) /* min value for a signed char */ -#define __UCHAR_MAX 0xffU /* max value for an unsigned char */ +#define __UCHAR_MAX 0xff /* max value for an unsigned char */ -#define __USHRT_MAX 0xffffU /* max value for an unsigned short */ +#define __USHRT_MAX 0xffff /* max value for an unsigned short */ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff-1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff-1) /* min value for an int */ -#define __ULONG_MAX 0xffffffffffffffffUL /* max for an unsigned long */ -#define __LONG_MAX 0x7fffffffffffffffL /* max for a long */ -#define __LONG_MIN (-0x7fffffffffffffffL-1) /* min for a long */ +#define __ULONG_MAX 0xffffffffffffffff /* max for an unsigned long */ +#define __LONG_MAX 0x7fffffffffffffff /* max for a long */ +#define __LONG_MIN (-0x7fffffffffffffff-1) /* min for a long */ -/* Long longs and longs are the same size on the IA-64. */ +/* Long longs have the same size but not the same type as longs. */ /* max for an unsigned long long */ #define __ULLONG_MAX 0xffffffffffffffffULL #define __LLONG_MAX 0x7fffffffffffffffLL /* max for a long long */ Modified: head/sys/mips/include/_limits.h ============================================================================== --- head/sys/mips/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/mips/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -41,8 +41,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -56,14 +54,14 @@ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff - 1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ #ifdef __LP64__ -#define __ULONG_MAX 0xffffffffffffffffUL -#define __LONG_MAX 0x7fffffffffffffffL -#define __LONG_MIN (-0x7fffffffffffffffL - 1) +#define __ULONG_MAX 0xffffffffffffffff +#define __LONG_MAX 0x7fffffffffffffff +#define __LONG_MIN (-0x7fffffffffffffff - 1) #define __LONG_BIT 64 #else #define __ULONG_MAX 0xffffffffUL /* max value for an unsigned long */ Modified: head/sys/powerpc/include/_limits.h ============================================================================== --- head/sys/powerpc/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/powerpc/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -40,8 +40,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -55,14 +53,14 @@ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff - 1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff - 1) /* min value for an int */ #ifdef __LP64__ -#define __ULONG_MAX 0xffffffffffffffffUL -#define __LONG_MAX 0x7fffffffffffffffL -#define __LONG_MIN (-0x7fffffffffffffffL - 1) +#define __ULONG_MAX 0xffffffffffffffff +#define __LONG_MAX 0x7fffffffffffffff +#define __LONG_MIN (-0x7fffffffffffffff - 1) #define __LONG_BIT 64 #else #define __ULONG_MAX 0xffffffffUL /* max value for an unsigned long */ Modified: head/sys/sparc64/include/_limits.h ============================================================================== --- head/sys/sparc64/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/sparc64/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -37,8 +37,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -46,21 +44,21 @@ #define __SCHAR_MAX 0x7f /* max value for a signed char */ #define __SCHAR_MIN (-0x7f-1) /* min value for a signed char */ -#define __UCHAR_MAX 0xffU /* max value for an unsigned char */ +#define __UCHAR_MAX 0xff /* max value for an unsigned char */ -#define __USHRT_MAX 0xffffU /* max value for an unsigned short */ +#define __USHRT_MAX 0xffff /* max value for an unsigned short */ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff-1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff-1) /* min value for an int */ -#define __ULONG_MAX 0xffffffffffffffffUL /* max for an unsigned long */ -#define __LONG_MAX 0x7fffffffffffffffL /* max for a long */ -#define __LONG_MIN (-0x7fffffffffffffffL-1) /* min for a long */ +#define __ULONG_MAX 0xffffffffffffffff /* max for an unsigned long */ +#define __LONG_MAX 0x7fffffffffffffff /* max for a long */ +#define __LONG_MIN (-0x7fffffffffffffff-1) /* min for a long */ -/* Long longs and longs are the same size on sparc64. */ +/* Long longs have the same size but not the same type as longs. */ /* max for an unsigned long long */ #define __ULLONG_MAX 0xffffffffffffffffULL #define __LLONG_MAX 0x7fffffffffffffffLL /* max for a long long */ Modified: head/sys/sun4v/include/_limits.h ============================================================================== --- head/sys/sun4v/include/_limits.h Sat Jan 8 11:04:30 2011 (r217144) +++ head/sys/sun4v/include/_limits.h Sat Jan 8 11:13:34 2011 (r217145) @@ -37,8 +37,6 @@ * type converted according to the integral promotions. The subtraction for * INT_MIN, etc., is so the value is not unsigned; e.g., 0x80000000 is an * unsigned int for 32-bit two's complement ANSI compilers (section 3.1.3.2). - * These numbers are for the default configuration of gcc. They work for - * some other compilers as well, but this should not be depended on. */ #define __CHAR_BIT 8 /* number of bits in a char */ @@ -46,21 +44,21 @@ #define __SCHAR_MAX 0x7f /* max value for a signed char */ #define __SCHAR_MIN (-0x7f-1) /* min value for a signed char */ -#define __UCHAR_MAX 0xffU /* max value for an unsigned char */ +#define __UCHAR_MAX 0xff /* max value for an unsigned char */ -#define __USHRT_MAX 0xffffU /* max value for an unsigned short */ +#define __USHRT_MAX 0xffff /* max value for an unsigned short */ #define __SHRT_MAX 0x7fff /* max value for a short */ #define __SHRT_MIN (-0x7fff-1) /* min value for a short */ -#define __UINT_MAX 0xffffffffU /* max value for an unsigned int */ +#define __UINT_MAX 0xffffffff /* max value for an unsigned int */ #define __INT_MAX 0x7fffffff /* max value for an int */ #define __INT_MIN (-0x7fffffff-1) /* min value for an int */ -#define __ULONG_MAX 0xffffffffffffffffUL /* max for an unsigned long */ -#define __LONG_MAX 0x7fffffffffffffffL /* max for a long */ -#define __LONG_MIN (-0x7fffffffffffffffL-1) /* min for a long */ +#define __ULONG_MAX 0xffffffffffffffff /* max for an unsigned long */ +#define __LONG_MAX 0x7fffffffffffffff /* max for a long */ +#define __LONG_MIN (-0x7fffffffffffffff-1) /* min for a long */ -/* Long longs and longs are the same size on sparc64. */ +/* Long longs have the same size but not the same type as longs. */ /* max for an unsigned long long */ #define __ULLONG_MAX 0xffffffffffffffffULL #define __LLONG_MAX 0x7fffffffffffffffLL /* max for a long long */ From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 11:47:55 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B7BEC10656C7; Sat, 8 Jan 2011 11:47:55 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A59778FC1B; Sat, 8 Jan 2011 11:47:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08BltfR090991; Sat, 8 Jan 2011 11:47:55 GMT (envelope-from tijl@svn.freebsd.org) Received: (from tijl@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08BltfD090985; Sat, 8 Jan 2011 11:47:55 GMT (envelope-from tijl@svn.freebsd.org) Message-Id: <201101081147.p08BltfD090985@svn.freebsd.org> From: Tijl Coosemans Date: Sat, 8 Jan 2011 11:47:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217146 - in head/sys: arm/include i386/include mips/include powerpc/include sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 11:47:55 -0000 Author: tijl Date: Sat Jan 8 11:47:55 2011 New Revision: 217146 URL: http://svn.freebsd.org/changeset/base/217146 Log: On 32 bit architectures define (u)int64_t as (unsigned) long long instead of (unsigned) int __attribute__((__mode__(__DI__))). This aligns better with macros such as (U)INT64_C, (U)INT64_MAX, etc. which assume (u)int64_t has type (unsigned) long long. The mode attribute was used because long long wasn't standardised until C99. Nowadays compilers should support long long and use of the mode attribute is discouraged according to GCC Internals documentation. The type definition has to be marked with __extension__ to support compilation with "-std=c89 -pedantic". Discussed with: bde Approved by: kib (mentor) Modified: head/sys/arm/include/_types.h head/sys/i386/include/_types.h head/sys/mips/include/_types.h head/sys/powerpc/include/_types.h head/sys/sys/cdefs.h Modified: head/sys/arm/include/_types.h ============================================================================== --- head/sys/arm/include/_types.h Sat Jan 8 11:13:34 2011 (r217145) +++ head/sys/arm/include/_types.h Sat Jan 8 11:47:55 2011 (r217146) @@ -52,16 +52,16 @@ typedef short __int16_t; typedef unsigned short __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; - -#ifdef __GNUCLIKE_ATTRIBUTE_MODE_DI -typedef int __attribute__((__mode__(__DI__))) __int64_t; -typedef unsigned int __attribute__((__mode__(__DI__))) __uint64_t; -#else +#ifndef lint +__extension__ +#endif /* LONGLONG */ typedef long long __int64_t; +#ifndef lint +__extension__ +#endif /* LONGLONG */ typedef unsigned long long __uint64_t; -#endif /* * Standard type definitions. Modified: head/sys/i386/include/_types.h ============================================================================== --- head/sys/i386/include/_types.h Sat Jan 8 11:13:34 2011 (r217145) +++ head/sys/i386/include/_types.h Sat Jan 8 11:47:55 2011 (r217146) @@ -54,21 +54,16 @@ typedef short __int16_t; typedef unsigned short __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; - -#if defined(lint) -/* LONGLONG */ -typedef long long __int64_t; -/* LONGLONG */ -typedef unsigned long long __uint64_t; -#elif defined(__GNUCLIKE_ATTRIBUTE_MODE_DI) -typedef int __attribute__((__mode__(__DI__))) __int64_t; -typedef unsigned int __attribute__((__mode__(__DI__))) __uint64_t; -#else +#ifndef lint +__extension__ +#endif /* LONGLONG */ typedef long long __int64_t; +#ifndef lint +__extension__ +#endif /* LONGLONG */ typedef unsigned long long __uint64_t; -#endif /* * Standard type definitions. Modified: head/sys/mips/include/_types.h ============================================================================== --- head/sys/mips/include/_types.h Sat Jan 8 11:13:34 2011 (r217145) +++ head/sys/mips/include/_types.h Sat Jan 8 11:47:55 2011 (r217146) @@ -53,26 +53,21 @@ typedef short __int16_t; typedef unsigned short __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; - #ifdef __mips_n64 typedef long __int64_t; typedef unsigned long __uint64_t; #else -#if defined(lint) -/* LONGLONG */ -typedef long long __int64_t; -/* LONGLONG */ -typedef unsigned long long __uint64_t; -#elif defined(__GNUCLIKE_ATTRIBUTE_MODE_DI) -typedef int __attribute__((__mode__(__DI__))) __int64_t; -typedef unsigned int __attribute__((__mode__(__DI__))) __uint64_t; -#else +#ifndef lint +__extension__ +#endif /* LONGLONG */ typedef long long __int64_t; +#ifndef lint +__extension__ +#endif /* LONGLONG */ typedef unsigned long long __uint64_t; #endif -#endif /* * Standard type definitions. Modified: head/sys/powerpc/include/_types.h ============================================================================== --- head/sys/powerpc/include/_types.h Sat Jan 8 11:13:34 2011 (r217145) +++ head/sys/powerpc/include/_types.h Sat Jan 8 11:47:55 2011 (r217146) @@ -52,29 +52,20 @@ typedef short __int16_t; typedef unsigned short __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; - #ifdef __powerpc64__ - typedef long __int64_t; typedef unsigned long __uint64_t; - #else - -#if defined(lint) -/* LONGLONG */ -typedef long long __int64_t; -/* LONGLONG */ -typedef unsigned long long __uint64_t; -#elif defined(__GNUCLIKE_ATTRIBUTE_MODE_DI) -typedef int __attribute__((__mode__(__DI__))) __int64_t; -typedef unsigned int __attribute__((__mode__(__DI__))) __uint64_t; -#else -/* LONGLONG */ -typedef long long __int64_t; +#ifndef lint +__extension__ +#endif /* LONGLONG */ -typedef unsigned long long __uint64_t; +typedef long long __int64_t; +#ifndef lint +__extension__ #endif - +/* LONGLONG */ +typedef unsigned long long __uint64_t; #endif /* Modified: head/sys/sys/cdefs.h ============================================================================== --- head/sys/sys/cdefs.h Sat Jan 8 11:13:34 2011 (r217145) +++ head/sys/sys/cdefs.h Sat Jan 8 11:47:55 2011 (r217146) @@ -62,8 +62,6 @@ #define __GNUCLIKE___OFFSETOF 1 #define __GNUCLIKE___SECTION 1 -#define __GNUCLIKE_ATTRIBUTE_MODE_DI 1 - #ifndef __INTEL_COMPILER # define __GNUCLIKE_CTOR_SECTION_HANDLING 1 #endif From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 12:43:05 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8BBC010656A7; Sat, 8 Jan 2011 12:43:05 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 784DD8FC0A; Sat, 8 Jan 2011 12:43:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08Ch5Ts092309; Sat, 8 Jan 2011 12:43:05 GMT (envelope-from tijl@svn.freebsd.org) Received: (from tijl@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08Ch5vR092295; Sat, 8 Jan 2011 12:43:05 GMT (envelope-from tijl@svn.freebsd.org) Message-Id: <201101081243.p08Ch5vR092295@svn.freebsd.org> From: Tijl Coosemans Date: Sat, 8 Jan 2011 12:43:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217147 - in head/sys: amd64/include arm/include i386/include ia64/include mips/include powerpc/include sparc64/include sun4v/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 12:43:05 -0000 Author: tijl Date: Sat Jan 8 12:43:05 2011 New Revision: 217147 URL: http://svn.freebsd.org/changeset/base/217147 Log: On mixed 32/64 bit architectures (mips, powerpc) use __LP64__ rather than architecture macros (__mips_n64, __powerpc64__) when 64 bit types (and corresponding macros) are different from 32 bit. [1] Correct the type of INT64_MIN, INT64_MAX and UINT64_MAX. Define (U)INTMAX_C as an alias for (U)INT64_C matching the type definition for (u)intmax_t. Do this on all architectures for consistency. Suggested by: bde [1] Approved by: kib (mentor) Modified: head/sys/amd64/include/_stdint.h head/sys/arm/include/_stdint.h head/sys/i386/include/_stdint.h head/sys/ia64/include/_stdint.h head/sys/mips/include/_inttypes.h head/sys/mips/include/_stdint.h head/sys/mips/include/_types.h head/sys/powerpc/include/_inttypes.h head/sys/powerpc/include/_limits.h head/sys/powerpc/include/_stdint.h head/sys/powerpc/include/_types.h head/sys/sparc64/include/_stdint.h head/sys/sun4v/include/_stdint.h Modified: head/sys/amd64/include/_stdint.h ============================================================================== --- head/sys/amd64/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/amd64/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -52,8 +52,8 @@ #define UINT32_C(c) (c ## U) #define UINT64_C(c) (c ## UL) -#define INTMAX_C(c) (c ## L) -#define UINTMAX_C(c) (c ## UL) +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ Modified: head/sys/arm/include/_stdint.h ============================================================================== --- head/sys/arm/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/arm/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -45,8 +45,8 @@ #define UINT32_C(c) (c ## U) #define UINT64_C(c) (c ## ULL) -#define INTMAX_C(c) (c ## LL) -#define UINTMAX_C(c) (c ## ULL) +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ Modified: head/sys/i386/include/_stdint.h ============================================================================== --- head/sys/i386/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/i386/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -52,8 +52,8 @@ #define UINT32_C(c) (c ## U) #define UINT64_C(c) (c ## ULL) -#define INTMAX_C(c) (c ## LL) -#define UINTMAX_C(c) (c ## ULL) +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ Modified: head/sys/ia64/include/_stdint.h ============================================================================== --- head/sys/ia64/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/ia64/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -45,8 +45,8 @@ #define UINT32_C(c) (c ## U) #define UINT64_C(c) (c ## UL) -#define INTMAX_C(c) (c ## L) -#define UINTMAX_C(c) (c ## UL) +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ Modified: head/sys/mips/include/_inttypes.h ============================================================================== --- head/sys/mips/include/_inttypes.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/mips/include/_inttypes.h Sat Jan 8 12:43:05 2011 (r217147) @@ -38,7 +38,7 @@ * Macros for format specifiers. */ -#if defined(__mips_n64) +#ifdef __LP64__ #define PRI64 "l" #else #define PRI64 "ll" Modified: head/sys/mips/include/_stdint.h ============================================================================== --- head/sys/mips/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/mips/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -46,28 +46,21 @@ #define INT8_C(c) (c) #define INT16_C(c) (c) #define INT32_C(c) (c) -#ifdef __mips_n64 -#define INT64_C(c) (c ## L) -#else -#define INT64_C(c) (c ## LL) -#endif #define UINT8_C(c) (c) #define UINT16_C(c) (c) #define UINT32_C(c) (c ## U) -#ifdef __mips_n64 + +#ifdef __LP64__ +#define INT64_C(c) (c ## L) #define UINT64_C(c) (c ## UL) #else +#define INT64_C(c) (c ## LL) #define UINT64_C(c) (c ## ULL) #endif -#ifdef __mips_n64 -#define INTMAX_C(c) (c ## L) -#define UINTMAX_C(c) (c ## UL) -#else -#define INTMAX_C(c) (c ## LL) -#define UINTMAX_C(c) (c ## ULL) -#endif +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ @@ -81,19 +74,19 @@ #define INT8_MIN (-0x7f-1) #define INT16_MIN (-0x7fff-1) #define INT32_MIN (-0x7fffffff-1) -#define INT64_MIN (-INTMAX_C(0x7fffffffffffffff)-1) +#define INT64_MIN (-INT64_C(0x7fffffffffffffff)-1) /* Maximum values of exact-width signed integer types. */ #define INT8_MAX 0x7f #define INT16_MAX 0x7fff #define INT32_MAX 0x7fffffff -#define INT64_MAX INTMAX_C(0x7fffffffffffffff) +#define INT64_MAX INT64_C(0x7fffffffffffffff) /* Maximum values of exact-width unsigned integer types. */ #define UINT8_MAX 0xff #define UINT16_MAX 0xffff -#define UINT32_MAX 0xffffffffU -#define UINT64_MAX UINTMAX_C(0xffffffffffffffff) +#define UINT32_MAX 0xffffffff +#define UINT64_MAX UINT64_C(0xffffffffffffffff) /* * ISO/IEC 9899:1999 @@ -143,7 +136,7 @@ * ISO/IEC 9899:1999 * 7.18.2.4 Limits of integer types capable of holding object pointers */ -#ifdef __mips_n64 +#ifdef __LP64__ #define INTPTR_MIN INT64_MIN #define INTPTR_MAX INT64_MAX #define UINTPTR_MAX UINT64_MAX @@ -165,26 +158,26 @@ * ISO/IEC 9899:1999 * 7.18.3 Limits of other integer types */ +#ifdef __LP64__ /* Limits of ptrdiff_t. */ -#ifdef __mips_n64 #define PTRDIFF_MIN INT64_MIN #define PTRDIFF_MAX INT64_MAX + +/* Limit of size_t. */ +#define SIZE_MAX UINT64_MAX #else +/* Limits of ptrdiff_t. */ #define PTRDIFF_MIN INT32_MIN #define PTRDIFF_MAX INT32_MAX + +/* Limit of size_t. */ +#define SIZE_MAX UINT32_MAX #endif /* Limits of sig_atomic_t. */ #define SIG_ATOMIC_MIN INT32_MIN #define SIG_ATOMIC_MAX INT32_MAX -/* Limit of size_t. */ -#ifdef __mips_n64 -#define SIZE_MAX UINT64_MAX -#else -#define SIZE_MAX UINT32_MAX -#endif - #ifndef WCHAR_MIN /* Also possibly defined in */ /* Limits of wchar_t. */ #define WCHAR_MIN INT32_MIN Modified: head/sys/mips/include/_types.h ============================================================================== --- head/sys/mips/include/_types.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/mips/include/_types.h Sat Jan 8 12:43:05 2011 (r217147) @@ -53,7 +53,7 @@ typedef short __int16_t; typedef unsigned short __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; -#ifdef __mips_n64 +#ifdef __LP64__ typedef long __int64_t; typedef unsigned long __uint64_t; #else @@ -74,17 +74,14 @@ typedef unsigned long long __uint64_t; */ typedef __int32_t __clock_t; /* clock()... */ typedef unsigned int __cpumask_t; -#ifdef __mips_n64 -typedef __int64_t __critical_t; -#else -typedef __int32_t __critical_t; -#endif typedef double __double_t; typedef double __float_t; -#ifdef __mips_n64 +#ifdef __LP64__ +typedef __int64_t __critical_t; typedef __int64_t __intfptr_t; typedef __int64_t __intptr_t; #else +typedef __int32_t __critical_t; typedef __int32_t __intfptr_t; typedef __int32_t __intptr_t; #endif @@ -97,14 +94,14 @@ typedef __int8_t __int_least8_t; typedef __int16_t __int_least16_t; typedef __int32_t __int_least32_t; typedef __int64_t __int_least64_t; -#if defined(__mips_n64) || defined(__mips_n32) +#if defined(__LP64__) || defined(__mips_n32) typedef __int64_t __register_t; typedef __int64_t f_register_t; #else typedef __int32_t __register_t; typedef __int32_t f_register_t; #endif -#ifdef __mips_n64 +#ifdef __LP64__ typedef __int64_t __ptrdiff_t; typedef __int64_t __segsz_t; typedef __uint64_t __size_t; @@ -129,12 +126,12 @@ typedef __uint8_t __uint_least8_t; typedef __uint16_t __uint_least16_t; typedef __uint32_t __uint_least32_t; typedef __uint64_t __uint_least64_t; -#if defined(__mips_n64) || defined(__mips_n32) +#if defined(__LP64__) || defined(__mips_n32) typedef __uint64_t __u_register_t; #else typedef __uint32_t __u_register_t; #endif -#if defined(__mips_n64) +#ifdef __LP64__ typedef __uint64_t __vm_offset_t; typedef __uint64_t __vm_paddr_t; typedef __uint64_t __vm_size_t; Modified: head/sys/powerpc/include/_inttypes.h ============================================================================== --- head/sys/powerpc/include/_inttypes.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/powerpc/include/_inttypes.h Sat Jan 8 12:43:05 2011 (r217147) @@ -37,7 +37,7 @@ * Macros for format specifiers. */ -#ifdef __powerpc64__ +#ifdef __LP64__ #define PRI64 "l" #define PRIreg "l" #else Modified: head/sys/powerpc/include/_limits.h ============================================================================== --- head/sys/powerpc/include/_limits.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/powerpc/include/_limits.h Sat Jan 8 12:43:05 2011 (r217147) @@ -73,7 +73,7 @@ #define __LLONG_MAX 0x7fffffffffffffffLL /* max value for a long long */ #define __LLONG_MIN (-0x7fffffffffffffffLL - 1) /* min for a long long */ -#ifdef __powerpc64__ +#ifdef __LP64__ #define __SSIZE_MAX __LONG_MAX /* max value for a ssize_t */ #define __SIZE_T_MAX __ULONG_MAX /* max value for a size_t */ #else Modified: head/sys/powerpc/include/_stdint.h ============================================================================== --- head/sys/powerpc/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/powerpc/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -50,18 +50,17 @@ #define UINT16_C(c) (c) #define UINT32_C(c) (c ## U) -#ifdef __powerpc64__ +#ifdef __LP64__ #define INT64_C(c) (c ## L) #define UINT64_C(c) (c ## UL) -#define INTMAX_C(c) (c ## L) -#define UINTMAX_C(c) (c ## UL) #else #define INT64_C(c) (c ## LL) #define UINT64_C(c) (c ## ULL) -#define INTMAX_C(c) (c ## LL) -#define UINTMAX_C(c) (c ## ULL) #endif +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) + #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ #if !defined(__cplusplus) || defined(__STDC_LIMIT_MACROS) @@ -74,27 +73,19 @@ #define INT8_MIN (-0x7f-1) #define INT16_MIN (-0x7fff-1) #define INT32_MIN (-0x7fffffff-1) -#define INT64_MIN (-0x7fffffffffffffffLL-1) +#define INT64_MIN (-INT64_C(0x7fffffffffffffff)-1) /* Maximum values of exact-width signed integer types. */ #define INT8_MAX 0x7f #define INT16_MAX 0x7fff #define INT32_MAX 0x7fffffff -#ifdef __powerpc64__ -#define INT64_MAX 0x7fffffffffffffffL -#else -#define INT64_MAX 0x7fffffffffffffffLL -#endif +#define INT64_MAX INT64_C(0x7fffffffffffffff) /* Maximum values of exact-width unsigned integer types. */ #define UINT8_MAX 0xff #define UINT16_MAX 0xffff -#define UINT32_MAX 0xffffffffU -#ifdef __powerpc64__ -#define UINT64_MAX 0xffffffffffffffffUL -#else -#define UINT64_MAX 0xffffffffffffffffULL -#endif +#define UINT32_MAX 0xffffffff +#define UINT64_MAX UINT64_C(0xffffffffffffffff) /* * ISO/IEC 9899:1999 @@ -144,7 +135,7 @@ * ISO/IEC 9899:1999 * 7.18.2.4 Limits of integer types capable of holding object pointers */ -#ifdef __powerpc64__ +#ifdef __LP64__ #define INTPTR_MIN INT64_MIN #define INTPTR_MAX INT64_MAX #define UINTPTR_MAX UINT64_MAX @@ -166,7 +157,7 @@ * ISO/IEC 9899:1999 * 7.18.3 Limits of other integer types */ -#ifdef __powerpc64__ +#ifdef __LP64__ /* Limits of ptrdiff_t. */ #define PTRDIFF_MIN INT64_MIN #define PTRDIFF_MAX INT64_MAX Modified: head/sys/powerpc/include/_types.h ============================================================================== --- head/sys/powerpc/include/_types.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/powerpc/include/_types.h Sat Jan 8 12:43:05 2011 (r217147) @@ -52,7 +52,7 @@ typedef short __int16_t; typedef unsigned short __uint16_t; typedef int __int32_t; typedef unsigned int __uint32_t; -#ifdef __powerpc64__ +#ifdef __LP64__ typedef long __int64_t; typedef unsigned long __uint64_t; #else @@ -75,7 +75,7 @@ typedef __uint32_t __clock_t; /* clock( typedef unsigned int __cpumask_t; typedef double __double_t; typedef double __float_t; -#ifdef __powerpc64__ +#ifdef __LP64__ typedef __int64_t __critical_t; typedef __int64_t __intfptr_t; typedef __int64_t __intptr_t; @@ -93,7 +93,7 @@ typedef __int8_t __int_least8_t; typedef __int16_t __int_least16_t; typedef __int32_t __int_least32_t; typedef __int64_t __int_least64_t; -#ifdef __powerpc64__ +#ifdef __LP64__ typedef __int64_t __ptrdiff_t; /* ptr1 - ptr2 */ typedef __int64_t __register_t; typedef __int64_t __segsz_t; /* segment size (in pages) */ @@ -121,7 +121,7 @@ typedef __uint8_t __uint_least8_t; typedef __uint16_t __uint_least16_t; typedef __uint32_t __uint_least32_t; typedef __uint64_t __uint_least64_t; -#ifdef __powerpc64__ +#ifdef __LP64__ typedef __uint64_t __u_register_t; typedef __uint64_t __vm_offset_t; typedef __uint64_t __vm_paddr_t; Modified: head/sys/sparc64/include/_stdint.h ============================================================================== --- head/sys/sparc64/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/sparc64/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -52,8 +52,8 @@ #define UINT32_C(c) (c ## U) #define UINT64_C(c) (c ## UL) -#define INTMAX_C(c) (c ## L) -#define UINTMAX_C(c) (c ## UL) +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ Modified: head/sys/sun4v/include/_stdint.h ============================================================================== --- head/sys/sun4v/include/_stdint.h Sat Jan 8 11:47:55 2011 (r217146) +++ head/sys/sun4v/include/_stdint.h Sat Jan 8 12:43:05 2011 (r217147) @@ -52,8 +52,8 @@ #define UINT32_C(c) (c ## U) #define UINT64_C(c) (c ## UL) -#define INTMAX_C(c) (c ## L) -#define UINTMAX_C(c) (c ## UL) +#define INTMAX_C(c) INT64_C(c) +#define UINTMAX_C(c) UINT64_C(c) #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */ From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 13:28:43 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B969C10656BA; Sat, 8 Jan 2011 13:28:43 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A8A538FC15; Sat, 8 Jan 2011 13:28:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08DShs3093341; Sat, 8 Jan 2011 13:28:43 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08DShCv093339; Sat, 8 Jan 2011 13:28:43 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201101081328.p08DShCv093339@svn.freebsd.org> From: Glen Barber Date: Sat, 8 Jan 2011 13:28:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217148 - head/share/man/man5 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 13:28:43 -0000 Author: gjb (doc committer) Date: Sat Jan 8 13:28:43 2011 New Revision: 217148 URL: http://svn.freebsd.org/changeset/base/217148 Log: Document rc.conf.d in rc.conf(5). PR: 140495 Submitted by: Tom Judge (tom of tomjudge com) Approved by: keramida (mentor) MFC after: 2 weeks Modified: head/share/man/man5/rc.conf.5 Modified: head/share/man/man5/rc.conf.5 ============================================================================== --- head/share/man/man5/rc.conf.5 Sat Jan 8 12:43:05 2011 (r217147) +++ head/share/man/man5/rc.conf.5 Sat Jan 8 13:28:43 2011 (r217148) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 24, 2010 +.Dd January 7, 2011 .Dt RC.CONF 5 .Os .Sh NAME @@ -64,7 +64,19 @@ The file is used to override settings in .Pa /etc/rc.conf for historical reasons. -See the +In addition to +.Pa /etc/rc.conf.local +you can also place smaller configuration files for each +.Xr rc +script in the +.Pa /etc/rc.conf.d +directory, which will be included by the +.Va load_rc_config +function. +For jail configurations you could use the file +.Pa /etc/rc.conf.d/jail +to store jail specific configuration options. +Also see the .Va rc_conf_files variable below. .Pp From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 16:02:15 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5751710656F8; Sat, 8 Jan 2011 16:02:15 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3C82A8FC0A; Sat, 8 Jan 2011 16:02:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08G2FdX096670; Sat, 8 Jan 2011 16:02:15 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08G2Fj0096668; Sat, 8 Jan 2011 16:02:15 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081602.p08G2Fj0096668@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 16:02:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217150 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 16:02:15 -0000 Author: kib Date: Sat Jan 8 16:02:14 2011 New Revision: 217150 URL: http://svn.freebsd.org/changeset/base/217150 Log: Collect code to translate between vm_prot_t and p_flags into helper functions. MFC after: 1 week Modified: head/sys/kern/imgact_elf.c Modified: head/sys/kern/imgact_elf.c ============================================================================== --- head/sys/kern/imgact_elf.c Sat Jan 8 15:59:14 2011 (r217149) +++ head/sys/kern/imgact_elf.c Sat Jan 8 16:02:14 2011 (r217150) @@ -92,6 +92,8 @@ static boolean_t __elfN(freebsd_trans_os static boolean_t kfreebsd_trans_osrel(const Elf_Note *note, int32_t *osrel); static boolean_t __elfN(check_note)(struct image_params *imgp, Elf_Brandnote *checknote, int32_t *osrel); +static vm_prot_t __elfN(trans_prot)(Elf_Word); +static Elf_Word __elfN(untrans_prot)(vm_prot_t); SYSCTL_NODE(_kern, OID_AUTO, __CONCAT(elf, __ELF_WORD_SIZE), CTLFLAG_RW, 0, ""); @@ -644,14 +646,7 @@ __elfN(load_file)(struct proc *p, const for (i = 0, numsegs = 0; i < hdr->e_phnum; i++) { if (phdr[i].p_type == PT_LOAD && phdr[i].p_memsz != 0) { /* Loadable segment */ - prot = 0; - if (phdr[i].p_flags & PF_X) - prot |= VM_PROT_EXECUTE; - if (phdr[i].p_flags & PF_W) - prot |= VM_PROT_WRITE; - if (phdr[i].p_flags & PF_R) - prot |= VM_PROT_READ; - + prot = __elfN(trans_prot)(phdr[i].p_flags); if ((error = __elfN(load_section)(vmspace, imgp->object, phdr[i].p_offset, (caddr_t)(uintptr_t)phdr[i].p_vaddr + rbase, @@ -792,13 +787,7 @@ __CONCAT(exec_, __elfN(imgact))(struct i case PT_LOAD: /* Loadable segment */ if (phdr[i].p_memsz == 0) break; - prot = 0; - if (phdr[i].p_flags & PF_X) - prot |= VM_PROT_EXECUTE; - if (phdr[i].p_flags & PF_W) - prot |= VM_PROT_WRITE; - if (phdr[i].p_flags & PF_R) - prot |= VM_PROT_READ; + prot = __elfN(trans_prot)(phdr[i].p_flags); #if defined(__ia64__) && __ELF_WORD_SIZE == 32 && defined(IA32_ME_HARDER) /* @@ -1172,13 +1161,7 @@ cb_put_phdr(entry, closure) phdr->p_paddr = 0; phdr->p_filesz = phdr->p_memsz = entry->end - entry->start; phdr->p_align = PAGE_SIZE; - phdr->p_flags = 0; - if (entry->protection & VM_PROT_READ) - phdr->p_flags |= PF_R; - if (entry->protection & VM_PROT_WRITE) - phdr->p_flags |= PF_W; - if (entry->protection & VM_PROT_EXECUTE) - phdr->p_flags |= PF_X; + phdr->p_flags = __elfN(untrans_prot)(entry->protection); phc->offset += phdr->p_filesz; phc->phdr++; @@ -1633,3 +1616,33 @@ compress_core (gzFile file, char *inbuf, return (error); } #endif /* COMPRESS_USER_CORES */ + +static vm_prot_t +__elfN(trans_prot)(Elf_Word flags) +{ + vm_prot_t prot; + + prot = 0; + if (flags & PF_X) + prot |= VM_PROT_EXECUTE; + if (flags & PF_W) + prot |= VM_PROT_WRITE; + if (flags & PF_R) + prot |= VM_PROT_READ; + return (prot); +} + +static Elf_Word +__elfN(untrans_prot)(vm_prot_t prot) +{ + Elf_Word flags; + + flags = 0; + if (prot & VM_PROT_EXECUTE) + flags |= PF_X; + if (prot & VM_PROT_READ) + flags |= PF_R; + if (prot & VM_PROT_WRITE) + flags |= PF_W; + return (flags); +} From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 16:13:45 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3D8AC1065670; Sat, 8 Jan 2011 16:13:45 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2AE928FC19; Sat, 8 Jan 2011 16:13:45 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08GDjaQ097005; Sat, 8 Jan 2011 16:13:45 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08GDijL096994; Sat, 8 Jan 2011 16:13:44 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081613.p08GDijL096994@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 16:13:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217151 - in head/sys: amd64/amd64 amd64/ia32 amd64/include compat/freebsd32 compat/ia32 kern sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 16:13:45 -0000 Author: kib Date: Sat Jan 8 16:13:44 2011 New Revision: 217151 URL: http://svn.freebsd.org/changeset/base/217151 Log: Create shared (readonly) page. Each ABI may specify the use of page by setting SV_SHP flag and providing pointer to the vm object and mapping address. Provide simple allocator to carve space in the page, tailored to put the code with alignment restrictions. Enable shared page use for amd64, both native and 32bit FreeBSD binaries. Page is private mapped at the top of the user address space, moving a start of the stack one page down. Move signal trampoline code from the top of the stack to the shared page. Reviewed by: alc Modified: head/sys/amd64/amd64/elf_machdep.c head/sys/amd64/amd64/machdep.c head/sys/amd64/ia32/ia32_signal.c head/sys/amd64/include/vmparam.h head/sys/compat/freebsd32/freebsd32_misc.c head/sys/compat/ia32/ia32_sysvec.c head/sys/compat/ia32/ia32_util.h head/sys/kern/kern_exec.c head/sys/sys/imgact.h head/sys/sys/sysent.h Modified: head/sys/amd64/amd64/elf_machdep.c ============================================================================== --- head/sys/amd64/amd64/elf_machdep.c Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/amd64/amd64/elf_machdep.c Sat Jan 8 16:13:44 2011 (r217151) @@ -75,11 +75,14 @@ struct sysentvec elf64_freebsd_sysvec = .sv_setregs = exec_setregs, .sv_fixlimit = NULL, .sv_maxssiz = NULL, - .sv_flags = SV_ABI_FREEBSD | SV_LP64, + .sv_flags = SV_ABI_FREEBSD | SV_LP64 | SV_SHP, .sv_set_syscall_retval = cpu_set_syscall_retval, .sv_fetch_syscall_args = cpu_fetch_syscall_args, .sv_syscallnames = syscallnames, + .sv_shared_page_base = SHAREDPAGE, + .sv_shared_page_len = PAGE_SIZE, }; +INIT_SYSENTVEC(elf64_sysvec, &elf64_freebsd_sysvec); static Elf64_Brandinfo freebsd_brand_info = { .brand = ELFOSABI_FREEBSD, @@ -129,7 +132,6 @@ SYSINIT(kelf64, SI_SUB_EXEC, SI_ORDER_AN (sysinit_cfunc_t) elf64_insert_brand_entry, &kfreebsd_brand_info); - void elf64_dump_thread(struct thread *td __unused, void *dst __unused, size_t *off __unused) Modified: head/sys/amd64/amd64/machdep.c ============================================================================== --- head/sys/amd64/amd64/machdep.c Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/amd64/amd64/machdep.c Sat Jan 8 16:13:44 2011 (r217151) @@ -386,7 +386,7 @@ sendsig(sig_t catcher, ksiginfo_t *ksi, } regs->tf_rsp = (long)sfp; - regs->tf_rip = PS_STRINGS - *(p->p_sysent->sv_szsigcode); + regs->tf_rip = p->p_sysent->sv_sigcode_base; regs->tf_rflags &= ~(PSL_T | PSL_D); regs->tf_cs = _ucodesel; regs->tf_ds = _udatasel; Modified: head/sys/amd64/ia32/ia32_signal.c ============================================================================== --- head/sys/amd64/ia32/ia32_signal.c Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/amd64/ia32/ia32_signal.c Sat Jan 8 16:13:44 2011 (r217151) @@ -393,7 +393,8 @@ freebsd4_ia32_sendsig(sig_t catcher, ksi } regs->tf_rsp = (uintptr_t)sfp; - regs->tf_rip = p->p_sysent->sv_psstrings - sz_freebsd4_ia32_sigcode; + regs->tf_rip = p->p_sysent->sv_sigcode_base + sz_ia32_sigcode - + sz_freebsd4_ia32_sigcode; regs->tf_rflags &= ~(PSL_T | PSL_D); regs->tf_cs = _ucode32sel; regs->tf_ss = _udatasel; @@ -514,7 +515,7 @@ ia32_sendsig(sig_t catcher, ksiginfo_t * } regs->tf_rsp = (uintptr_t)sfp; - regs->tf_rip = p->p_sysent->sv_psstrings - *(p->p_sysent->sv_szsigcode); + regs->tf_rip = p->p_sysent->sv_sigcode_base; regs->tf_rflags &= ~(PSL_T | PSL_D); regs->tf_cs = _ucode32sel; regs->tf_ss = _udatasel; Modified: head/sys/amd64/include/vmparam.h ============================================================================== --- head/sys/amd64/include/vmparam.h Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/amd64/include/vmparam.h Sat Jan 8 16:13:44 2011 (r217151) @@ -186,7 +186,8 @@ #define VM_MAXUSER_ADDRESS UVADDR(NUPML4E, 0, 0, 0) -#define USRSTACK VM_MAXUSER_ADDRESS +#define SHAREDPAGE (VM_MAXUSER_ADDRESS - PAGE_SIZE) +#define USRSTACK SHAREDPAGE #define VM_MAX_ADDRESS UPT_MAX_ADDRESS #define VM_MIN_ADDRESS (0) Modified: head/sys/compat/freebsd32/freebsd32_misc.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_misc.c Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/compat/freebsd32/freebsd32_misc.c Sat Jan 8 16:13:44 2011 (r217151) @@ -2546,7 +2546,10 @@ freebsd32_copyout_strings(struct image_p execpath_len = 0; arginfo = (struct freebsd32_ps_strings *)curproc->p_sysent-> sv_psstrings; - szsigcode = *(imgp->proc->p_sysent->sv_szsigcode); + if (imgp->proc->p_sysent->sv_sigcode_base == 0) + szsigcode = *(imgp->proc->p_sysent->sv_szsigcode); + else + szsigcode = 0; destp = (caddr_t)arginfo - szsigcode - SPARE_USRSPACE - roundup(execpath_len, sizeof(char *)) - roundup(sizeof(canary), sizeof(char *)) - @@ -2556,7 +2559,7 @@ freebsd32_copyout_strings(struct image_p /* * install sigcode */ - if (szsigcode) + if (szsigcode != 0) copyout(imgp->proc->p_sysent->sv_sigcode, ((caddr_t)arginfo - szsigcode), szsigcode); Modified: head/sys/compat/ia32/ia32_sysvec.c ============================================================================== --- head/sys/compat/ia32/ia32_sysvec.c Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/compat/ia32/ia32_sysvec.c Sat Jan 8 16:13:44 2011 (r217151) @@ -129,7 +129,7 @@ struct sysentvec ia32_freebsd_sysvec = { .sv_minsigstksz = MINSIGSTKSZ, .sv_pagesize = IA32_PAGE_SIZE, .sv_minuser = 0, - .sv_maxuser = FREEBSD32_USRSTACK, + .sv_maxuser = FREEBSD32_MAXUSER, .sv_usrstack = FREEBSD32_USRSTACK, .sv_psstrings = FREEBSD32_PS_STRINGS, .sv_stackprot = VM_PROT_ALL, @@ -137,12 +137,20 @@ struct sysentvec ia32_freebsd_sysvec = { .sv_setregs = ia32_setregs, .sv_fixlimit = ia32_fixlimit, .sv_maxssiz = &ia32_maxssiz, - .sv_flags = SV_ABI_FREEBSD | SV_IA32 | SV_ILP32, + .sv_flags = SV_ABI_FREEBSD | SV_IA32 | SV_ILP32 | +#ifdef __amd64__ + SV_SHP +#else + 0 +#endif + , .sv_set_syscall_retval = ia32_set_syscall_retval, .sv_fetch_syscall_args = ia32_fetch_syscall_args, .sv_syscallnames = freebsd32_syscallnames, + .sv_shared_page_base = FREEBSD32_SHAREDPAGE, + .sv_shared_page_len = PAGE_SIZE, }; - +INIT_SYSENTVEC(elf_ia32_sysvec, &ia32_freebsd_sysvec); static Elf32_Brandinfo ia32_brand_info = { .brand = ELFOSABI_FREEBSD, @@ -191,7 +199,6 @@ SYSINIT(kia32, SI_SUB_EXEC, SI_ORDER_ANY (sysinit_cfunc_t) elf32_insert_brand_entry, &kia32_brand_info); - void elf32_dump_thread(struct thread *td __unused, void *dst __unused, size_t *off __unused) Modified: head/sys/compat/ia32/ia32_util.h ============================================================================== --- head/sys/compat/ia32/ia32_util.h Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/compat/ia32/ia32_util.h Sat Jan 8 16:13:44 2011 (r217151) @@ -41,9 +41,13 @@ #include #ifdef __ia64__ -#define FREEBSD32_USRSTACK ((1ul << 32) - IA32_PAGE_SIZE * 2) +#define FREEBSD32_MAXUSER ((1ul << 32) - IA32_PAGE_SIZE * 2) +#define FREEBSD32_SHAREDPAGE 0 +#define FREEBSD32_USRSTACK FREEBSD32_MAXUSER #else -#define FREEBSD32_USRSTACK ((1ul << 32) - IA32_PAGE_SIZE) +#define FREEBSD32_MAXUSER ((1ul << 32) - IA32_PAGE_SIZE) +#define FREEBSD32_SHAREDPAGE (FREEBSD32_MAXUSER - IA32_PAGE_SIZE) +#define FREEBSD32_USRSTACK FREEBSD32_SHAREDPAGE #endif #define IA32_PAGE_SIZE 4096 Modified: head/sys/kern/kern_exec.c ============================================================================== --- head/sys/kern/kern_exec.c Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/kern/kern_exec.c Sat Jan 8 16:13:44 2011 (r217151) @@ -389,6 +389,7 @@ do_execve(td, args, mac_p) imgp->canarylen = 0; imgp->pagesizes = 0; imgp->pagesizeslen = 0; + imgp->stack_prot = 0; #ifdef MAC error = mac_execve_enter(imgp, mac_p); @@ -996,6 +997,7 @@ exec_new_vmspace(imgp, sv) int error; struct proc *p = imgp->proc; struct vmspace *vmspace = p->p_vmspace; + vm_object_t obj; vm_offset_t sv_minuser, stack_addr; vm_map_t map; u_long ssiz; @@ -1029,6 +1031,20 @@ exec_new_vmspace(imgp, sv) map = &vmspace->vm_map; } + /* Map a shared page */ + obj = sv->sv_shared_page_obj; + if (obj != NULL) { + vm_object_reference(obj); + error = vm_map_fixed(map, obj, 0, + sv->sv_shared_page_base, sv->sv_shared_page_len, + VM_PROT_READ | VM_PROT_EXECUTE, VM_PROT_ALL, + MAP_COPY_ON_WRITE | MAP_ACC_NO_CHARGE); + if (error) { + vm_object_deallocate(obj); + return (error); + } + } + /* Allocate a new stack */ if (sv->sv_maxssiz != NULL) ssiz = *sv->sv_maxssiz; @@ -1036,7 +1052,9 @@ exec_new_vmspace(imgp, sv) ssiz = maxssiz; stack_addr = sv->sv_usrstack - ssiz; error = vm_map_stack(map, stack_addr, (vm_size_t)ssiz, - sv->sv_stackprot, VM_PROT_ALL, MAP_STACK_GROWS_DOWN); + obj != NULL && imgp->stack_prot != 0 ? imgp->stack_prot : + sv->sv_stackprot, + VM_PROT_ALL, MAP_STACK_GROWS_DOWN); if (error) return (error); @@ -1208,8 +1226,10 @@ exec_copyout_strings(imgp) p = imgp->proc; szsigcode = 0; arginfo = (struct ps_strings *)p->p_sysent->sv_psstrings; - if (p->p_sysent->sv_szsigcode != NULL) - szsigcode = *(p->p_sysent->sv_szsigcode); + if (p->p_sysent->sv_sigcode_base == 0) { + if (p->p_sysent->sv_szsigcode != NULL) + szsigcode = *(p->p_sysent->sv_szsigcode); + } destp = (caddr_t)arginfo - szsigcode - SPARE_USRSPACE - roundup(execpath_len, sizeof(char *)) - roundup(sizeof(canary), sizeof(char *)) - @@ -1219,7 +1239,7 @@ exec_copyout_strings(imgp) /* * install sigcode */ - if (szsigcode) + if (szsigcode != 0) copyout(p->p_sysent->sv_sigcode, ((caddr_t)arginfo - szsigcode), szsigcode); @@ -1459,3 +1479,64 @@ exec_unregister(execsw_arg) execsw = newexecsw; return (0); } + +static vm_object_t shared_page_obj; +static int shared_page_free; + +int +shared_page_fill(int size, int align, const char *data) +{ + vm_page_t m; + struct sf_buf *s; + vm_offset_t sk; + int res; + + VM_OBJECT_LOCK(shared_page_obj); + m = vm_page_grab(shared_page_obj, 0, VM_ALLOC_RETRY); + res = roundup(shared_page_free, align); + if (res + size >= IDX_TO_OFF(shared_page_obj->size)) + res = -1; + else { + VM_OBJECT_UNLOCK(shared_page_obj); + s = sf_buf_alloc(m, SFB_DEFAULT); + sk = sf_buf_kva(s); + bcopy(data, (void *)(sk + res), size); + shared_page_free = res + size; + sf_buf_free(s); + VM_OBJECT_LOCK(shared_page_obj); + } + vm_page_wakeup(m); + VM_OBJECT_UNLOCK(shared_page_obj); + return (res); +} + +static void +shared_page_init(void *dummy __unused) +{ + vm_page_t m; + + shared_page_obj = vm_pager_allocate(OBJT_PHYS, 0, PAGE_SIZE, + VM_PROT_DEFAULT, 0, NULL); + VM_OBJECT_LOCK(shared_page_obj); + m = vm_page_grab(shared_page_obj, 0, VM_ALLOC_RETRY | VM_ALLOC_NOBUSY | + VM_ALLOC_ZERO); + m->valid = VM_PAGE_BITS_ALL; + VM_OBJECT_UNLOCK(shared_page_obj); +} + +SYSINIT(shp, SI_SUB_EXEC, SI_ORDER_FIRST, (sysinit_cfunc_t)shared_page_init, + NULL); + +void +exec_sysvec_init(void *param) +{ + struct sysentvec *sv; + + sv = (struct sysentvec *)param; + + if ((sv->sv_flags & SV_SHP) == 0) + return; + sv->sv_shared_page_obj = shared_page_obj; + sv->sv_sigcode_base = sv->sv_shared_page_base + + shared_page_fill(*(sv->sv_szsigcode), 16, sv->sv_sigcode); +} Modified: head/sys/sys/imgact.h ============================================================================== --- head/sys/sys/imgact.h Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/sys/imgact.h Sat Jan 8 16:13:44 2011 (r217151) @@ -34,6 +34,8 @@ #include +#include + #define MAXSHELLCMDLEN PAGE_SIZE struct image_args { @@ -75,6 +77,7 @@ struct image_params { int canarylen; unsigned long pagesizes; int pagesizeslen; + vm_prot_t stack_prot; }; #ifdef _KERNEL Modified: head/sys/sys/sysent.h ============================================================================== --- head/sys/sys/sysent.h Sat Jan 8 16:02:14 2011 (r217150) +++ head/sys/sys/sysent.h Sat Jan 8 16:13:44 2011 (r217151) @@ -116,12 +116,17 @@ struct sysentvec { int (*sv_fetch_syscall_args)(struct thread *, struct syscall_args *); const char **sv_syscallnames; + vm_offset_t sv_shared_page_base; + vm_offset_t sv_shared_page_len; + vm_offset_t sv_sigcode_base; + void *sv_shared_page_obj; }; #define SV_ILP32 0x000100 #define SV_LP64 0x000200 #define SV_IA32 0x004000 #define SV_AOUT 0x008000 +#define SV_SHP 0x010000 #define SV_ABI_MASK 0xff #define SV_CURPROC_FLAG(x) (curproc->p_sysent->sv_flags & (x)) @@ -222,6 +227,13 @@ int lkmressys(struct thread *, struct no int syscall_thread_enter(struct thread *td, struct sysent *se); void syscall_thread_exit(struct thread *td, struct sysent *se); +int shared_page_fill(int size, int align, const char *data); +void exec_sysvec_init(void *param); + +#define INIT_SYSENTVEC(name, sv) \ + SYSINIT(name, SI_SUB_EXEC, SI_ORDER_ANY, \ + (sysinit_cfunc_t)exec_sysvec_init, sv); + #endif /* _KERNEL */ #endif /* !_SYS_SYSENT_H_ */ From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 16:30:59 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EC9C610656B4; Sat, 8 Jan 2011 16:30:59 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C130B8FC13; Sat, 8 Jan 2011 16:30:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08GUxvK097393; Sat, 8 Jan 2011 16:30:59 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08GUxOC097391; Sat, 8 Jan 2011 16:30:59 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081630.p08GUxOC097391@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 16:30:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217152 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 16:31:00 -0000 Author: kib Date: Sat Jan 8 16:30:59 2011 New Revision: 217152 URL: http://svn.freebsd.org/changeset/base/217152 Log: In elf image activator, read and apply the stack protection mode from PT_GNU_STACK program header, if present and enabled. Two new sysctls are provided, kern.elf32.nxstack and kern.elf64.nxstack, that allow to enable PT_GNU_STACK for ABIs of specified bitsize, if ABI decided to support shared page. Inform rtld about access mode of the stack initial mapping by AT_STACKPROT aux vector. At the moment, the default is disabled, waiting for the usermode support bits. Modified: head/sys/kern/imgact_elf.c Modified: head/sys/kern/imgact_elf.c ============================================================================== --- head/sys/kern/imgact_elf.c Sat Jan 8 16:13:44 2011 (r217151) +++ head/sys/kern/imgact_elf.c Sat Jan 8 16:30:59 2011 (r217152) @@ -115,6 +115,11 @@ static int elf_legacy_coredump = 0; SYSCTL_INT(_debug, OID_AUTO, __elfN(legacy_coredump), CTLFLAG_RW, &elf_legacy_coredump, 0, ""); +static int __elfN(nxstack) = 0; +SYSCTL_INT(__CONCAT(_kern_elf, __ELF_WORD_SIZE), OID_AUTO, + nxstack, CTLFLAG_RW, &__elfN(nxstack), 0, + __XSTRING(__CONCAT(ELF, __ELF_WORD_SIZE)) ": enable non-executable stack"); + static Elf_Brandinfo *elf_brand_list[MAX_BRANDS]; #define trunc_page_ps(va, ps) ((va) & ~(ps - 1)) @@ -724,19 +729,24 @@ __CONCAT(exec_, __elfN(imgact))(struct i n = 0; baddr = 0; for (i = 0; i < hdr->e_phnum; i++) { - if (phdr[i].p_type == PT_LOAD) { + switch (phdr[i].p_type) { + case PT_LOAD: if (n == 0) baddr = phdr[i].p_vaddr; n++; - continue; - } - if (phdr[i].p_type == PT_INTERP) { + break; + case PT_INTERP: /* Path to interpreter */ if (phdr[i].p_filesz > MAXPATHLEN || phdr[i].p_offset + phdr[i].p_filesz > PAGE_SIZE) return (ENOEXEC); interp = imgp->image_header + phdr[i].p_offset; - continue; + break; + case PT_GNU_STACK: + if (__elfN(nxstack)) + imgp->stack_prot = + __elfN(trans_prot)(phdr[i].p_flags); + break; } } @@ -972,6 +982,8 @@ __elfN(freebsd_fixup)(register_t **stack AUXARGS_ENTRY(pos, AT_PAGESIZES, imgp->pagesizes); AUXARGS_ENTRY(pos, AT_PAGESIZESLEN, imgp->pagesizeslen); } + AUXARGS_ENTRY(pos, AT_STACKPROT, imgp->stack_prot != 0 ? + imgp->stack_prot : imgp->sysent->sv_stackprot); AUXARGS_ENTRY(pos, AT_NULL, 0); free(imgp->auxargs, M_TEMP); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 17:11:49 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 679A61065693; Sat, 8 Jan 2011 17:11:49 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 562058FC1E; Sat, 8 Jan 2011 17:11:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08HBnuk098261; Sat, 8 Jan 2011 17:11:49 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08HBnuA098255; Sat, 8 Jan 2011 17:11:49 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081711.p08HBnuA098255@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 17:11:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217153 - in head: libexec/rtld-elf sys/sys X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 17:11:49 -0000 Author: kib Date: Sat Jan 8 17:11:49 2011 New Revision: 217153 URL: http://svn.freebsd.org/changeset/base/217153 Log: In rtld, read the initial stack access mode from AT_STACKPROT as set by kernel, and parse PT_GNU_STACK phdr from linked and loaded dsos. If the loaded dso requires executable stack, as specified by PF_X bit of p_flags of PT_GNU_STACK phdr, but current stack protection does not permit execution, the __pthread_map_stacks_exec symbol is looked up and called. It should be implemented in libc or threading library and change the protection mode of all thread stacks to be executable. Provide a private interface _rtld_get_stack_prot() to export the stack access mode as calculated by rtld. Reviewed by: kan Modified: head/libexec/rtld-elf/Symbol.map head/libexec/rtld-elf/map_object.c head/libexec/rtld-elf/rtld.c head/libexec/rtld-elf/rtld.h head/sys/sys/link_elf.h Modified: head/libexec/rtld-elf/Symbol.map ============================================================================== --- head/libexec/rtld-elf/Symbol.map Sat Jan 8 16:30:59 2011 (r217152) +++ head/libexec/rtld-elf/Symbol.map Sat Jan 8 17:11:49 2011 (r217153) @@ -28,4 +28,5 @@ FBSDprivate_1.0 { _rtld_atfork_pre; _rtld_atfork_post; _rtld_addr_phdr; + _rtld_get_stack_prot; }; Modified: head/libexec/rtld-elf/map_object.c ============================================================================== --- head/libexec/rtld-elf/map_object.c Sat Jan 8 16:30:59 2011 (r217152) +++ head/libexec/rtld-elf/map_object.c Sat Jan 8 17:11:49 2011 (r217153) @@ -83,6 +83,7 @@ map_object(int fd, const char *path, con Elf_Addr bss_vaddr; Elf_Addr bss_vlimit; caddr_t bss_addr; + Elf_Word stack_flags; hdr = get_elf_header(fd, path); if (hdr == NULL) @@ -100,6 +101,7 @@ map_object(int fd, const char *path, con phdyn = phinterp = phtls = NULL; phdr_vaddr = 0; segs = alloca(sizeof(segs[0]) * hdr->e_phnum); + stack_flags = PF_X | PF_R | PF_W; while (phdr < phlimit) { switch (phdr->p_type) { @@ -128,6 +130,10 @@ map_object(int fd, const char *path, con case PT_TLS: phtls = phdr; break; + + case PT_GNU_STACK: + stack_flags = phdr->p_flags; + break; } ++phdr; @@ -261,6 +267,7 @@ map_object(int fd, const char *path, con obj->tlsinitsize = phtls->p_filesz; obj->tlsinit = mapbase + phtls->p_vaddr; } + obj->stack_flags = stack_flags; return obj; } Modified: head/libexec/rtld-elf/rtld.c ============================================================================== --- head/libexec/rtld-elf/rtld.c Sat Jan 8 16:30:59 2011 (r217152) +++ head/libexec/rtld-elf/rtld.c Sat Jan 8 17:11:49 2011 (r217153) @@ -103,6 +103,7 @@ static void unload_filtees(Obj_Entry *); static int load_needed_objects(Obj_Entry *, int); static int load_preload_objects(void); static Obj_Entry *load_object(const char *, const Obj_Entry *, int); +static void map_stacks_exec(void); static Obj_Entry *obj_from_addr(const void *); static void objlist_call_fini(Objlist *, Obj_Entry *, RtldLockState *); static void objlist_call_init(Objlist *, RtldLockState *); @@ -188,6 +189,9 @@ extern Elf_Dyn _DYNAMIC; int osreldate, pagesize; +static int stack_prot = PROT_READ | PROT_WRITE | PROT_EXEC; +static int max_stack_flags; + /* * Global declarations normally provided by crt1. The dynamic linker is * not built with crt1, so we have to provide them ourselves. @@ -382,6 +386,7 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ close(fd); if (obj_main == NULL) die(); + max_stack_flags = obj->stack_flags; } else { /* Main program already loaded. */ const Elf_Phdr *phdr; int phnum; @@ -421,6 +426,10 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ dbg("obj_main path %s", obj_main->path); obj_main->mainprog = true; + if (aux_info[AT_STACKPROT] != NULL && + aux_info[AT_STACKPROT]->a_un.a_val != 0) + stack_prot = aux_info[AT_STACKPROT]->a_un.a_val; + /* * Get the actual dynamic linker pathname from the executable if * possible. (It should always be possible.) That ensures that @@ -519,6 +528,8 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ r_debug_state(NULL, &obj_main->linkmap); /* say hello to gdb! */ + map_stacks_exec(); + wlock_acquire(rtld_bind_lock, &lockstate); objlist_call_init(&initlist, &lockstate); objlist_clear(&initlist); @@ -1031,6 +1042,8 @@ digest_phdr(const Elf_Phdr *phdr, int ph break; } + obj->stack_flags = PF_X | PF_R | PF_W; + for (ph = phdr; ph < phlimit; ph++) { switch (ph->p_type) { @@ -1062,6 +1075,10 @@ digest_phdr(const Elf_Phdr *phdr, int ph obj->tlsinitsize = ph->p_filesz; obj->tlsinit = (void*)(ph->p_vaddr + obj->relocbase); break; + + case PT_GNU_STACK: + obj->stack_flags = ph->p_flags; + break; } } if (nsegs < 1) { @@ -1679,6 +1696,7 @@ do_load_object(int fd, const char *name, obj_count++; obj_loads++; linkmap_add(obj); /* for GDB & dlinfo() */ + max_stack_flags |= obj->stack_flags; dbg(" %p .. %p: %s", obj->mapbase, obj->mapbase + obj->mapsize - 1, obj->path); @@ -2202,6 +2220,8 @@ dlopen_object(const char *name, Obj_Entr name); GDB_STATE(RT_CONSISTENT,obj ? &obj->linkmap : NULL); + map_stacks_exec(); + /* Call the init functions. */ objlist_call_init(&initlist, &lockstate); objlist_clear(&initlist); @@ -3872,6 +3892,28 @@ fetch_ventry(const Obj_Entry *obj, unsig return NULL; } +int +_rtld_get_stack_prot(void) +{ + + return (stack_prot); +} + +static void +map_stacks_exec(void) +{ + void (*thr_map_stacks_exec)(void); + + if ((max_stack_flags & PF_X) == 0 || (stack_prot & PROT_EXEC) != 0) + return; + thr_map_stacks_exec = (void (*)(void))(uintptr_t) + get_program_var_addr("__pthread_map_stacks_exec"); + if (thr_map_stacks_exec != NULL) { + stack_prot |= PROT_EXEC; + thr_map_stacks_exec(); + } +} + void symlook_init(SymLook *dst, const char *name) { Modified: head/libexec/rtld-elf/rtld.h ============================================================================== --- head/libexec/rtld-elf/rtld.h Sat Jan 8 16:30:59 2011 (r217152) +++ head/libexec/rtld-elf/rtld.h Sat Jan 8 17:11:49 2011 (r217153) @@ -157,6 +157,7 @@ typedef struct Struct_Obj_Entry { const Elf_Phdr *phdr; /* Program header if it is mapped, else NULL */ size_t phsize; /* Size of program header in bytes */ const char *interp; /* Pathname of the interpreter, if any */ + Elf_Word stack_flags; /* TLS information */ int tlsindex; /* Index in DTV for this module */ Modified: head/sys/sys/link_elf.h ============================================================================== --- head/sys/sys/link_elf.h Sat Jan 8 16:30:59 2011 (r217152) +++ head/sys/sys/link_elf.h Sat Jan 8 17:11:49 2011 (r217153) @@ -93,6 +93,7 @@ __BEGIN_DECLS typedef int (*__dl_iterate_hdr_callback)(struct dl_phdr_info *, size_t, void *); extern int dl_iterate_phdr(__dl_iterate_hdr_callback, void *); int _rtld_addr_phdr(const void *, struct dl_phdr_info *); +int _rtld_get_stack_prot(void); __END_DECLS From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 17:13:44 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0B75310656DD; Sat, 8 Jan 2011 17:13:44 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D4D658FC12; Sat, 8 Jan 2011 17:13:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08HDhvQ098533; Sat, 8 Jan 2011 17:13:43 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08HDhxq098527; Sat, 8 Jan 2011 17:13:43 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081713.p08HDhxq098527@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 17:13:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217154 - head/lib/libc/gen X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 17:13:44 -0000 Author: kib Date: Sat Jan 8 17:13:43 2011 New Revision: 217154 URL: http://svn.freebsd.org/changeset/base/217154 Log: Implement __pthread_map_stacks_exec() callback for libc, to change the stack protection to allow execution for single-threaded processes. Modified: head/lib/libc/gen/Symbol.map head/lib/libc/gen/dlfcn.c head/lib/libc/gen/elf_utils.c Modified: head/lib/libc/gen/Symbol.map ============================================================================== --- head/lib/libc/gen/Symbol.map Sat Jan 8 17:11:49 2011 (r217153) +++ head/lib/libc/gen/Symbol.map Sat Jan 8 17:13:43 2011 (r217154) @@ -453,6 +453,7 @@ FBSDprivate_1.0 { _rtld_atfork_pre; _rtld_atfork_post; _rtld_error; /* for private use */ + _rtld_get_stack_prot; _rtld_thread_init; /* for private use */ __elf_phdr_match_addr; _err; @@ -499,4 +500,5 @@ FBSDprivate_1.0 { _libc_sem_getvalue_compat; __elf_aux_vector; + __pthread_map_stacks_exec; }; Modified: head/lib/libc/gen/dlfcn.c ============================================================================== --- head/lib/libc/gen/dlfcn.c Sat Jan 8 17:11:49 2011 (r217153) +++ head/lib/libc/gen/dlfcn.c Sat Jan 8 17:13:43 2011 (r217154) @@ -30,6 +30,7 @@ __FBSDID("$FreeBSD$"); /* * Linkage to services provided by the dynamic linker. */ +#include #include #include #include @@ -165,3 +166,12 @@ _rtld_addr_phdr(const void *addr, struct return (0); } + +#pragma weak _rtld_get_stack_prot +int +_rtld_get_stack_prot(void) +{ + + return (PROT_EXEC | PROT_READ | PROT_WRITE); +} + Modified: head/lib/libc/gen/elf_utils.c ============================================================================== --- head/lib/libc/gen/elf_utils.c Sat Jan 8 17:11:49 2011 (r217153) +++ head/lib/libc/gen/elf_utils.c Sat Jan 8 17:13:43 2011 (r217154) @@ -26,7 +26,12 @@ * $FreeBSD$ */ +#include +#include +#include +#include #include +#include int __elf_phdr_match_addr(struct dl_phdr_info *phdr_info, void *addr) @@ -45,3 +50,25 @@ __elf_phdr_match_addr(struct dl_phdr_inf } return (i != phdr_info->dlpi_phnum); } + +#pragma weak __pthread_map_stacks_exec +void +__pthread_map_stacks_exec(void) +{ + int mib[2]; + struct rlimit rlim; + u_long usrstack; + size_t len; + + mib[0] = CTL_KERN; + mib[1] = KERN_USRSTACK; + len = sizeof(usrstack); + if (sysctl(mib, sizeof(mib) / sizeof(mib[0]), &usrstack, &len, NULL, 0) + == -1) + return; + if (getrlimit(RLIMIT_STACK, &rlim) == -1) + return; + mprotect((void *)(uintptr_t)(usrstack - rlim.rlim_cur), + rlim.rlim_cur, _rtld_get_stack_prot()); +} + From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 18:00:20 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 16E0210656FD; Sat, 8 Jan 2011 18:00:20 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 05A138FC12; Sat, 8 Jan 2011 18:00:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08I0Kql099669; Sat, 8 Jan 2011 18:00:20 GMT (envelope-from tijl@svn.freebsd.org) Received: (from tijl@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08I0J9H099666; Sat, 8 Jan 2011 18:00:19 GMT (envelope-from tijl@svn.freebsd.org) Message-Id: <201101081800.p08I0J9H099666@svn.freebsd.org> From: Tijl Coosemans Date: Sat, 8 Jan 2011 18:00:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217155 - in head/sys: mips/include powerpc/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 18:00:20 -0000 Author: tijl Date: Sat Jan 8 18:00:19 2011 New Revision: 217155 URL: http://svn.freebsd.org/changeset/base/217155 Log: Rename PRIreg helper macro to PRIptr to better reflect its use. Registers and pointers don't always have the same size, e.g. the __mips_n32 ABI (ILP32) has 64 bit registers but 32 bit pointers. On mips introduce PRIptr to fix the format specifier for (u)intptr_t. Prefix PRI64 and PRIptr with underscores because macro names starting with PRI[a-zX] are reserved for future use. Approved by: kib (mentor) Modified: head/sys/mips/include/_inttypes.h head/sys/powerpc/include/_inttypes.h Modified: head/sys/mips/include/_inttypes.h ============================================================================== --- head/sys/mips/include/_inttypes.h Sat Jan 8 17:13:43 2011 (r217154) +++ head/sys/mips/include/_inttypes.h Sat Jan 8 18:00:19 2011 (r217155) @@ -39,9 +39,11 @@ */ #ifdef __LP64__ -#define PRI64 "l" +#define __PRI64 "l" +#define __PRIptr "l" #else -#define PRI64 "ll" +#define __PRI64 "ll" +#define __PRIptr #endif /* fprintf(3) macros for signed integers. */ @@ -49,172 +51,172 @@ #define PRId8 "d" /* int8_t */ #define PRId16 "d" /* int16_t */ #define PRId32 "d" /* int32_t */ -#define PRId64 PRI64"d" /* int64_t */ +#define PRId64 __PRI64"d" /* int64_t */ #define PRIdLEAST8 "d" /* int_least8_t */ #define PRIdLEAST16 "d" /* int_least16_t */ #define PRIdLEAST32 "d" /* int_least32_t */ -#define PRIdLEAST64 PRI64"d" /* int_least64_t */ +#define PRIdLEAST64 __PRI64"d" /* int_least64_t */ #define PRIdFAST8 "d" /* int_fast8_t */ #define PRIdFAST16 "d" /* int_fast16_t */ #define PRIdFAST32 "d" /* int_fast32_t */ -#define PRIdFAST64 PRI64"d" /* int_fast64_t */ +#define PRIdFAST64 __PRI64"d" /* int_fast64_t */ #define PRIdMAX "jd" /* intmax_t */ -#define PRIdPTR "ld" /* intptr_t */ +#define PRIdPTR __PRIptr"d" /* intptr_t */ #define PRIi8 "i" /* int8_t */ #define PRIi16 "i" /* int16_t */ #define PRIi32 "i" /* int32_t */ -#define PRIi64 PRI64"i" /* int64_t */ +#define PRIi64 __PRI64"i" /* int64_t */ #define PRIiLEAST8 "i" /* int_least8_t */ #define PRIiLEAST16 "i" /* int_least16_t */ #define PRIiLEAST32 "i" /* int_least32_t */ -#define PRIiLEAST64 PRI64"i" /* int_least64_t */ +#define PRIiLEAST64 __PRI64"i" /* int_least64_t */ #define PRIiFAST8 "i" /* int_fast8_t */ #define PRIiFAST16 "i" /* int_fast16_t */ #define PRIiFAST32 "i" /* int_fast32_t */ -#define PRIiFAST64 PRI64"i" /* int_fast64_t */ +#define PRIiFAST64 __PRI64"i" /* int_fast64_t */ #define PRIiMAX "ji" /* intmax_t */ -#define PRIiPTR "li" /* intptr_t */ +#define PRIiPTR __PRIptr"i" /* intptr_t */ /* fprintf(3) macros for unsigned integers. */ #define PRIo8 "o" /* uint8_t */ #define PRIo16 "o" /* uint16_t */ #define PRIo32 "o" /* uint32_t */ -#define PRIo64 PRI64"o" /* uint64_t */ +#define PRIo64 __PRI64"o" /* uint64_t */ #define PRIoLEAST8 "o" /* uint_least8_t */ #define PRIoLEAST16 "o" /* uint_least16_t */ #define PRIoLEAST32 "o" /* uint_least32_t */ -#define PRIoLEAST64 PRI64"o" /* uint_least64_t */ +#define PRIoLEAST64 __PRI64"o" /* uint_least64_t */ #define PRIoFAST8 "o" /* uint_fast8_t */ #define PRIoFAST16 "o" /* uint_fast16_t */ #define PRIoFAST32 "o" /* uint_fast32_t */ -#define PRIoFAST64 PRI64"o" /* uint_fast64_t */ +#define PRIoFAST64 __PRI64"o" /* uint_fast64_t */ #define PRIoMAX "jo" /* uintmax_t */ -#define PRIoPTR "lo" /* uintptr_t */ +#define PRIoPTR __PRIptr"o" /* uintptr_t */ #define PRIu8 "u" /* uint8_t */ #define PRIu16 "u" /* uint16_t */ #define PRIu32 "u" /* uint32_t */ -#define PRIu64 PRI64"u" /* uint64_t */ +#define PRIu64 __PRI64"u" /* uint64_t */ #define PRIuLEAST8 "u" /* uint_least8_t */ #define PRIuLEAST16 "u" /* uint_least16_t */ #define PRIuLEAST32 "u" /* uint_least32_t */ -#define PRIuLEAST64 PRI64"u" /* uint_least64_t */ +#define PRIuLEAST64 __PRI64"u" /* uint_least64_t */ #define PRIuFAST8 "u" /* uint_fast8_t */ #define PRIuFAST16 "u" /* uint_fast16_t */ #define PRIuFAST32 "u" /* uint_fast32_t */ -#define PRIuFAST64 PRI64"u" /* uint_fast64_t */ +#define PRIuFAST64 __PRI64"u" /* uint_fast64_t */ #define PRIuMAX "ju" /* uintmax_t */ -#define PRIuPTR "lu" /* uintptr_t */ +#define PRIuPTR __PRIptr"u" /* uintptr_t */ #define PRIx8 "x" /* uint8_t */ #define PRIx16 "x" /* uint16_t */ #define PRIx32 "x" /* uint32_t */ -#define PRIx64 PRI64"x" /* uint64_t */ +#define PRIx64 __PRI64"x" /* uint64_t */ #define PRIxLEAST8 "x" /* uint_least8_t */ #define PRIxLEAST16 "x" /* uint_least16_t */ #define PRIxLEAST32 "x" /* uint_least32_t */ -#define PRIxLEAST64 PRI64"x" /* uint_least64_t */ +#define PRIxLEAST64 __PRI64"x" /* uint_least64_t */ #define PRIxFAST8 "x" /* uint_fast8_t */ #define PRIxFAST16 "x" /* uint_fast16_t */ #define PRIxFAST32 "x" /* uint_fast32_t */ -#define PRIxFAST64 PRI64"x" /* uint_fast64_t */ +#define PRIxFAST64 __PRI64"x" /* uint_fast64_t */ #define PRIxMAX "jx" /* uintmax_t */ -#define PRIxPTR "lx" /* uintptr_t */ +#define PRIxPTR __PRIptr"x" /* uintptr_t */ #define PRIX8 "X" /* uint8_t */ #define PRIX16 "X" /* uint16_t */ #define PRIX32 "X" /* uint32_t */ -#define PRIX64 PRI64"X" /* uint64_t */ +#define PRIX64 __PRI64"X" /* uint64_t */ #define PRIXLEAST8 "X" /* uint_least8_t */ #define PRIXLEAST16 "X" /* uint_least16_t */ #define PRIXLEAST32 "X" /* uint_least32_t */ -#define PRIXLEAST64 PRI64"X" /* uint_least64_t */ +#define PRIXLEAST64 __PRI64"X" /* uint_least64_t */ #define PRIXFAST8 "X" /* uint_fast8_t */ #define PRIXFAST16 "X" /* uint_fast16_t */ #define PRIXFAST32 "X" /* uint_fast32_t */ -#define PRIXFAST64 PRI64"X" /* uint_fast64_t */ +#define PRIXFAST64 __PRI64"X" /* uint_fast64_t */ #define PRIXMAX "jX" /* uintmax_t */ -#define PRIXPTR "lX" /* uintptr_t */ +#define PRIXPTR __PRIptr"X" /* uintptr_t */ /* fscanf(3) macros for signed integers. */ #define SCNd8 "hhd" /* int8_t */ #define SCNd16 "hd" /* int16_t */ #define SCNd32 "d" /* int32_t */ -#define SCNd64 PRI64"d" /* int64_t */ +#define SCNd64 __PRI64"d" /* int64_t */ #define SCNdLEAST8 "hhd" /* int_least8_t */ #define SCNdLEAST16 "hd" /* int_least16_t */ #define SCNdLEAST32 "d" /* int_least32_t */ -#define SCNdLEAST64 PRI64"d" /* int_least64_t */ +#define SCNdLEAST64 __PRI64"d" /* int_least64_t */ #define SCNdFAST8 "d" /* int_fast8_t */ #define SCNdFAST16 "d" /* int_fast16_t */ #define SCNdFAST32 "d" /* int_fast32_t */ -#define SCNdFAST64 PRI64"d" /* int_fast64_t */ +#define SCNdFAST64 __PRI64"d" /* int_fast64_t */ #define SCNdMAX "jd" /* intmax_t */ -#define SCNdPTR "ld" /* intptr_t */ +#define SCNdPTR __PRIptr"d" /* intptr_t */ #define SCNi8 "hhi" /* int8_t */ #define SCNi16 "hi" /* int16_t */ #define SCNi32 "i" /* int32_t */ -#define SCNi64 PRI64"i" /* int64_t */ +#define SCNi64 __PRI64"i" /* int64_t */ #define SCNiLEAST8 "hhi" /* int_least8_t */ #define SCNiLEAST16 "hi" /* int_least16_t */ #define SCNiLEAST32 "i" /* int_least32_t */ -#define SCNiLEAST64 PRI64"i" /* int_least64_t */ +#define SCNiLEAST64 __PRI64"i" /* int_least64_t */ #define SCNiFAST8 "i" /* int_fast8_t */ #define SCNiFAST16 "i" /* int_fast16_t */ #define SCNiFAST32 "i" /* int_fast32_t */ -#define SCNiFAST64 PRI64"i" /* int_fast64_t */ +#define SCNiFAST64 __PRI64"i" /* int_fast64_t */ #define SCNiMAX "ji" /* intmax_t */ -#define SCNiPTR "li" /* intptr_t */ +#define SCNiPTR __PRIptr"i" /* intptr_t */ /* fscanf(3) macros for unsigned integers. */ #define SCNo8 "hho" /* uint8_t */ #define SCNo16 "ho" /* uint16_t */ #define SCNo32 "o" /* uint32_t */ -#define SCNo64 PRI64"o" /* uint64_t */ +#define SCNo64 __PRI64"o" /* uint64_t */ #define SCNoLEAST8 "hho" /* uint_least8_t */ #define SCNoLEAST16 "ho" /* uint_least16_t */ #define SCNoLEAST32 "o" /* uint_least32_t */ -#define SCNoLEAST64 PRI64"o" /* uint_least64_t */ +#define SCNoLEAST64 __PRI64"o" /* uint_least64_t */ #define SCNoFAST8 "o" /* uint_fast8_t */ #define SCNoFAST16 "o" /* uint_fast16_t */ #define SCNoFAST32 "o" /* uint_fast32_t */ -#define SCNoFAST64 PRI64"o" /* uint_fast64_t */ +#define SCNoFAST64 __PRI64"o" /* uint_fast64_t */ #define SCNoMAX "jo" /* uintmax_t */ -#define SCNoPTR "lo" /* uintptr_t */ +#define SCNoPTR __PRIptr"o" /* uintptr_t */ #define SCNu8 "hhu" /* uint8_t */ #define SCNu16 "hu" /* uint16_t */ #define SCNu32 "u" /* uint32_t */ -#define SCNu64 PRI64"u" /* uint64_t */ +#define SCNu64 __PRI64"u" /* uint64_t */ #define SCNuLEAST8 "hhu" /* uint_least8_t */ #define SCNuLEAST16 "hu" /* uint_least16_t */ #define SCNuLEAST32 "u" /* uint_least32_t */ -#define SCNuLEAST64 PRI64"u" /* uint_least64_t */ +#define SCNuLEAST64 __PRI64"u" /* uint_least64_t */ #define SCNuFAST8 "u" /* uint_fast8_t */ #define SCNuFAST16 "u" /* uint_fast16_t */ #define SCNuFAST32 "u" /* uint_fast32_t */ -#define SCNuFAST64 PRI64"u" /* uint_fast64_t */ +#define SCNuFAST64 __PRI64"u" /* uint_fast64_t */ #define SCNuMAX "ju" /* uintmax_t */ -#define SCNuPTR "lu" /* uintptr_t */ +#define SCNuPTR __PRIptr"u" /* uintptr_t */ #define SCNx8 "hhx" /* uint8_t */ #define SCNx16 "hx" /* uint16_t */ #define SCNx32 "x" /* uint32_t */ -#define SCNx64 PRI64"x" /* uint64_t */ +#define SCNx64 __PRI64"x" /* uint64_t */ #define SCNxLEAST8 "hhx" /* uint_least8_t */ #define SCNxLEAST16 "hx" /* uint_least16_t */ #define SCNxLEAST32 "x" /* uint_least32_t */ -#define SCNxLEAST64 PRI64"x" /* uint_least64_t */ +#define SCNxLEAST64 __PRI64"x" /* uint_least64_t */ #define SCNxFAST8 "x" /* uint_fast8_t */ #define SCNxFAST16 "x" /* uint_fast16_t */ #define SCNxFAST32 "x" /* uint_fast32_t */ -#define SCNxFAST64 PRI64"x" /* uint_fast64_t */ +#define SCNxFAST64 __PRI64"x" /* uint_fast64_t */ #define SCNxMAX "jx" /* uintmax_t */ -#define SCNxPTR "lx" /* uintptr_t */ +#define SCNxPTR __PRIptr"x" /* uintptr_t */ #endif /* !_MACHINE_INTTYPES_H_ */ Modified: head/sys/powerpc/include/_inttypes.h ============================================================================== --- head/sys/powerpc/include/_inttypes.h Sat Jan 8 17:13:43 2011 (r217154) +++ head/sys/powerpc/include/_inttypes.h Sat Jan 8 18:00:19 2011 (r217155) @@ -38,11 +38,11 @@ */ #ifdef __LP64__ -#define PRI64 "l" -#define PRIreg "l" +#define __PRI64 "l" +#define __PRIptr "l" #else -#define PRI64 "ll" -#define PRIreg +#define __PRI64 "ll" +#define __PRIptr #endif /* fprintf(3) macros for signed integers. */ @@ -50,172 +50,172 @@ #define PRId8 "d" /* int8_t */ #define PRId16 "d" /* int16_t */ #define PRId32 "d" /* int32_t */ -#define PRId64 PRI64"d" /* int64_t */ +#define PRId64 __PRI64"d" /* int64_t */ #define PRIdLEAST8 "d" /* int_least8_t */ #define PRIdLEAST16 "d" /* int_least16_t */ #define PRIdLEAST32 "d" /* int_least32_t */ -#define PRIdLEAST64 PRI64"d" /* int_least64_t */ +#define PRIdLEAST64 __PRI64"d" /* int_least64_t */ #define PRIdFAST8 "d" /* int_fast8_t */ #define PRIdFAST16 "d" /* int_fast16_t */ #define PRIdFAST32 "d" /* int_fast32_t */ -#define PRIdFAST64 PRI64"d" /* int_fast64_t */ +#define PRIdFAST64 __PRI64"d" /* int_fast64_t */ #define PRIdMAX "jd" /* intmax_t */ -#define PRIdPTR PRIreg"d" /* intptr_t */ +#define PRIdPTR __PRIptr"d" /* intptr_t */ #define PRIi8 "i" /* int8_t */ #define PRIi16 "i" /* int16_t */ #define PRIi32 "i" /* int32_t */ -#define PRIi64 PRI64"i" /* int64_t */ +#define PRIi64 __PRI64"i" /* int64_t */ #define PRIiLEAST8 "i" /* int_least8_t */ #define PRIiLEAST16 "i" /* int_least16_t */ #define PRIiLEAST32 "i" /* int_least32_t */ -#define PRIiLEAST64 PRI64"i" /* int_least64_t */ +#define PRIiLEAST64 __PRI64"i" /* int_least64_t */ #define PRIiFAST8 "i" /* int_fast8_t */ #define PRIiFAST16 "i" /* int_fast16_t */ #define PRIiFAST32 "i" /* int_fast32_t */ -#define PRIiFAST64 PRI64"i" /* int_fast64_t */ +#define PRIiFAST64 __PRI64"i" /* int_fast64_t */ #define PRIiMAX "ji" /* intmax_t */ -#define PRIiPTR PRIreg"i" /* intptr_t */ +#define PRIiPTR __PRIptr"i" /* intptr_t */ /* fprintf(3) macros for unsigned integers. */ #define PRIo8 "o" /* uint8_t */ #define PRIo16 "o" /* uint16_t */ #define PRIo32 "o" /* uint32_t */ -#define PRIo64 PRI64"o" /* uint64_t */ +#define PRIo64 __PRI64"o" /* uint64_t */ #define PRIoLEAST8 "o" /* uint_least8_t */ #define PRIoLEAST16 "o" /* uint_least16_t */ #define PRIoLEAST32 "o" /* uint_least32_t */ -#define PRIoLEAST64 PRI64"o" /* uint_least64_t */ +#define PRIoLEAST64 __PRI64"o" /* uint_least64_t */ #define PRIoFAST8 "o" /* uint_fast8_t */ #define PRIoFAST16 "o" /* uint_fast16_t */ #define PRIoFAST32 "o" /* uint_fast32_t */ -#define PRIoFAST64 PRI64"o" /* uint_fast64_t */ +#define PRIoFAST64 __PRI64"o" /* uint_fast64_t */ #define PRIoMAX "jo" /* uintmax_t */ -#define PRIoPTR PRIreg"o" /* uintptr_t */ +#define PRIoPTR __PRIptr"o" /* uintptr_t */ #define PRIu8 "u" /* uint8_t */ #define PRIu16 "u" /* uint16_t */ #define PRIu32 "u" /* uint32_t */ -#define PRIu64 PRI64"u" /* uint64_t */ +#define PRIu64 __PRI64"u" /* uint64_t */ #define PRIuLEAST8 "u" /* uint_least8_t */ #define PRIuLEAST16 "u" /* uint_least16_t */ #define PRIuLEAST32 "u" /* uint_least32_t */ -#define PRIuLEAST64 PRI64"u" /* uint_least64_t */ +#define PRIuLEAST64 __PRI64"u" /* uint_least64_t */ #define PRIuFAST8 "u" /* uint_fast8_t */ #define PRIuFAST16 "u" /* uint_fast16_t */ #define PRIuFAST32 "u" /* uint_fast32_t */ -#define PRIuFAST64 PRI64"u" /* uint_fast64_t */ +#define PRIuFAST64 __PRI64"u" /* uint_fast64_t */ #define PRIuMAX "ju" /* uintmax_t */ -#define PRIuPTR PRIreg"u" /* uintptr_t */ +#define PRIuPTR __PRIptr"u" /* uintptr_t */ #define PRIx8 "x" /* uint8_t */ #define PRIx16 "x" /* uint16_t */ #define PRIx32 "x" /* uint32_t */ -#define PRIx64 PRI64"x" /* uint64_t */ +#define PRIx64 __PRI64"x" /* uint64_t */ #define PRIxLEAST8 "x" /* uint_least8_t */ #define PRIxLEAST16 "x" /* uint_least16_t */ #define PRIxLEAST32 "x" /* uint_least32_t */ -#define PRIxLEAST64 PRI64"x" /* uint_least64_t */ +#define PRIxLEAST64 __PRI64"x" /* uint_least64_t */ #define PRIxFAST8 "x" /* uint_fast8_t */ #define PRIxFAST16 "x" /* uint_fast16_t */ #define PRIxFAST32 "x" /* uint_fast32_t */ -#define PRIxFAST64 PRI64"x" /* uint_fast64_t */ +#define PRIxFAST64 __PRI64"x" /* uint_fast64_t */ #define PRIxMAX "jx" /* uintmax_t */ -#define PRIxPTR PRIreg"x" /* uintptr_t */ +#define PRIxPTR __PRIptr"x" /* uintptr_t */ #define PRIX8 "X" /* uint8_t */ #define PRIX16 "X" /* uint16_t */ #define PRIX32 "X" /* uint32_t */ -#define PRIX64 PRI64"X" /* uint64_t */ +#define PRIX64 __PRI64"X" /* uint64_t */ #define PRIXLEAST8 "X" /* uint_least8_t */ #define PRIXLEAST16 "X" /* uint_least16_t */ #define PRIXLEAST32 "X" /* uint_least32_t */ -#define PRIXLEAST64 PRI64"X" /* uint_least64_t */ +#define PRIXLEAST64 __PRI64"X" /* uint_least64_t */ #define PRIXFAST8 "X" /* uint_fast8_t */ #define PRIXFAST16 "X" /* uint_fast16_t */ #define PRIXFAST32 "X" /* uint_fast32_t */ -#define PRIXFAST64 PRI64"X" /* uint_fast64_t */ +#define PRIXFAST64 __PRI64"X" /* uint_fast64_t */ #define PRIXMAX "jX" /* uintmax_t */ -#define PRIXPTR PRIreg"X" /* uintptr_t */ +#define PRIXPTR __PRIptr"X" /* uintptr_t */ /* fscanf(3) macros for signed integers. */ #define SCNd8 "hhd" /* int8_t */ #define SCNd16 "hd" /* int16_t */ #define SCNd32 "d" /* int32_t */ -#define SCNd64 PRI64"d" /* int64_t */ +#define SCNd64 __PRI64"d" /* int64_t */ #define SCNdLEAST8 "hhd" /* int_least8_t */ #define SCNdLEAST16 "hd" /* int_least16_t */ #define SCNdLEAST32 "d" /* int_least32_t */ -#define SCNdLEAST64 PRI64"d" /* int_least64_t */ +#define SCNdLEAST64 __PRI64"d" /* int_least64_t */ #define SCNdFAST8 "d" /* int_fast8_t */ #define SCNdFAST16 "d" /* int_fast16_t */ #define SCNdFAST32 "d" /* int_fast32_t */ -#define SCNdFAST64 PRI64"d" /* int_fast64_t */ +#define SCNdFAST64 __PRI64"d" /* int_fast64_t */ #define SCNdMAX "jd" /* intmax_t */ -#define SCNdPTR PRIreg"d" /* intptr_t */ +#define SCNdPTR __PRIptr"d" /* intptr_t */ #define SCNi8 "hhi" /* int8_t */ #define SCNi16 "hi" /* int16_t */ #define SCNi32 "i" /* int32_t */ -#define SCNi64 PRI64"i" /* int64_t */ +#define SCNi64 __PRI64"i" /* int64_t */ #define SCNiLEAST8 "hhi" /* int_least8_t */ #define SCNiLEAST16 "hi" /* int_least16_t */ #define SCNiLEAST32 "i" /* int_least32_t */ -#define SCNiLEAST64 PRI64"i" /* int_least64_t */ +#define SCNiLEAST64 __PRI64"i" /* int_least64_t */ #define SCNiFAST8 "i" /* int_fast8_t */ #define SCNiFAST16 "i" /* int_fast16_t */ #define SCNiFAST32 "i" /* int_fast32_t */ -#define SCNiFAST64 PRI64"i" /* int_fast64_t */ +#define SCNiFAST64 __PRI64"i" /* int_fast64_t */ #define SCNiMAX "ji" /* intmax_t */ -#define SCNiPTR PRIreg"i" /* intptr_t */ +#define SCNiPTR __PRIptr"i" /* intptr_t */ /* fscanf(3) macros for unsigned integers. */ #define SCNo8 "hho" /* uint8_t */ #define SCNo16 "ho" /* uint16_t */ #define SCNo32 "o" /* uint32_t */ -#define SCNo64 PRI64"o" /* uint64_t */ +#define SCNo64 __PRI64"o" /* uint64_t */ #define SCNoLEAST8 "hho" /* uint_least8_t */ #define SCNoLEAST16 "ho" /* uint_least16_t */ #define SCNoLEAST32 "o" /* uint_least32_t */ -#define SCNoLEAST64 PRI64"o" /* uint_least64_t */ +#define SCNoLEAST64 __PRI64"o" /* uint_least64_t */ #define SCNoFAST8 "o" /* uint_fast8_t */ #define SCNoFAST16 "o" /* uint_fast16_t */ #define SCNoFAST32 "o" /* uint_fast32_t */ -#define SCNoFAST64 PRI64"o" /* uint_fast64_t */ +#define SCNoFAST64 __PRI64"o" /* uint_fast64_t */ #define SCNoMAX "jo" /* uintmax_t */ -#define SCNoPTR PRIreg"o" /* uintptr_t */ +#define SCNoPTR __PRIptr"o" /* uintptr_t */ #define SCNu8 "hhu" /* uint8_t */ #define SCNu16 "hu" /* uint16_t */ #define SCNu32 "u" /* uint32_t */ -#define SCNu64 PRI64"u" /* uint64_t */ +#define SCNu64 __PRI64"u" /* uint64_t */ #define SCNuLEAST8 "hhu" /* uint_least8_t */ #define SCNuLEAST16 "hu" /* uint_least16_t */ #define SCNuLEAST32 "u" /* uint_least32_t */ -#define SCNuLEAST64 PRI64"u" /* uint_least64_t */ +#define SCNuLEAST64 __PRI64"u" /* uint_least64_t */ #define SCNuFAST8 "u" /* uint_fast8_t */ #define SCNuFAST16 "u" /* uint_fast16_t */ #define SCNuFAST32 "u" /* uint_fast32_t */ -#define SCNuFAST64 PRI64"u" /* uint_fast64_t */ +#define SCNuFAST64 __PRI64"u" /* uint_fast64_t */ #define SCNuMAX "ju" /* uintmax_t */ -#define SCNuPTR PRIreg"u" /* uintptr_t */ +#define SCNuPTR __PRIptr"u" /* uintptr_t */ #define SCNx8 "hhx" /* uint8_t */ #define SCNx16 "hx" /* uint16_t */ #define SCNx32 "x" /* uint32_t */ -#define SCNx64 PRI64"x" /* uint64_t */ +#define SCNx64 __PRI64"x" /* uint64_t */ #define SCNxLEAST8 "hhx" /* uint_least8_t */ #define SCNxLEAST16 "hx" /* uint_least16_t */ #define SCNxLEAST32 "x" /* uint_least32_t */ -#define SCNxLEAST64 PRI64"x" /* uint_least64_t */ +#define SCNxLEAST64 __PRI64"x" /* uint_least64_t */ #define SCNxFAST8 "x" /* uint_fast8_t */ #define SCNxFAST16 "x" /* uint_fast16_t */ #define SCNxFAST32 "x" /* uint_fast32_t */ -#define SCNxFAST64 PRI64"x" /* uint_fast64_t */ +#define SCNxFAST64 __PRI64"x" /* uint_fast64_t */ #define SCNxMAX "jx" /* uintmax_t */ -#define SCNxPTR PRIreg"x" /* uintptr_t */ +#define SCNxPTR __PRIptr"x" /* uintptr_t */ #endif /* !_MACHINE_INTTYPES_H_ */ From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 18:02:47 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0161310656B6; Sat, 8 Jan 2011 18:02:47 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E433F8FC14; Sat, 8 Jan 2011 18:02:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08I2k1H099745; Sat, 8 Jan 2011 18:02:46 GMT (envelope-from tijl@svn.freebsd.org) Received: (from tijl@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08I2kF2099742; Sat, 8 Jan 2011 18:02:46 GMT (envelope-from tijl@svn.freebsd.org) Message-Id: <201101081802.p08I2kF2099742@svn.freebsd.org> From: Tijl Coosemans Date: Sat, 8 Jan 2011 18:02:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217156 - in head/sys: mips/include powerpc/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 18:02:47 -0000 Author: tijl Date: Sat Jan 8 18:02:46 2011 New Revision: 217156 URL: http://svn.freebsd.org/changeset/base/217156 Log: White space changes to align comments. The mips and powerpc _inttypes.h are now exactly the same. Approved by: kib (mentor) Modified: head/sys/mips/include/_inttypes.h head/sys/powerpc/include/_inttypes.h Modified: head/sys/mips/include/_inttypes.h ============================================================================== --- head/sys/mips/include/_inttypes.h Sat Jan 8 18:00:19 2011 (r217155) +++ head/sys/mips/include/_inttypes.h Sat Jan 8 18:02:46 2011 (r217156) @@ -48,175 +48,175 @@ /* fprintf(3) macros for signed integers. */ -#define PRId8 "d" /* int8_t */ -#define PRId16 "d" /* int16_t */ -#define PRId32 "d" /* int32_t */ +#define PRId8 "d" /* int8_t */ +#define PRId16 "d" /* int16_t */ +#define PRId32 "d" /* int32_t */ #define PRId64 __PRI64"d" /* int64_t */ -#define PRIdLEAST8 "d" /* int_least8_t */ -#define PRIdLEAST16 "d" /* int_least16_t */ -#define PRIdLEAST32 "d" /* int_least32_t */ +#define PRIdLEAST8 "d" /* int_least8_t */ +#define PRIdLEAST16 "d" /* int_least16_t */ +#define PRIdLEAST32 "d" /* int_least32_t */ #define PRIdLEAST64 __PRI64"d" /* int_least64_t */ -#define PRIdFAST8 "d" /* int_fast8_t */ -#define PRIdFAST16 "d" /* int_fast16_t */ -#define PRIdFAST32 "d" /* int_fast32_t */ +#define PRIdFAST8 "d" /* int_fast8_t */ +#define PRIdFAST16 "d" /* int_fast16_t */ +#define PRIdFAST32 "d" /* int_fast32_t */ #define PRIdFAST64 __PRI64"d" /* int_fast64_t */ -#define PRIdMAX "jd" /* intmax_t */ +#define PRIdMAX "jd" /* intmax_t */ #define PRIdPTR __PRIptr"d" /* intptr_t */ -#define PRIi8 "i" /* int8_t */ -#define PRIi16 "i" /* int16_t */ -#define PRIi32 "i" /* int32_t */ +#define PRIi8 "i" /* int8_t */ +#define PRIi16 "i" /* int16_t */ +#define PRIi32 "i" /* int32_t */ #define PRIi64 __PRI64"i" /* int64_t */ -#define PRIiLEAST8 "i" /* int_least8_t */ -#define PRIiLEAST16 "i" /* int_least16_t */ -#define PRIiLEAST32 "i" /* int_least32_t */ +#define PRIiLEAST8 "i" /* int_least8_t */ +#define PRIiLEAST16 "i" /* int_least16_t */ +#define PRIiLEAST32 "i" /* int_least32_t */ #define PRIiLEAST64 __PRI64"i" /* int_least64_t */ -#define PRIiFAST8 "i" /* int_fast8_t */ -#define PRIiFAST16 "i" /* int_fast16_t */ -#define PRIiFAST32 "i" /* int_fast32_t */ +#define PRIiFAST8 "i" /* int_fast8_t */ +#define PRIiFAST16 "i" /* int_fast16_t */ +#define PRIiFAST32 "i" /* int_fast32_t */ #define PRIiFAST64 __PRI64"i" /* int_fast64_t */ -#define PRIiMAX "ji" /* intmax_t */ +#define PRIiMAX "ji" /* intmax_t */ #define PRIiPTR __PRIptr"i" /* intptr_t */ /* fprintf(3) macros for unsigned integers. */ -#define PRIo8 "o" /* uint8_t */ -#define PRIo16 "o" /* uint16_t */ -#define PRIo32 "o" /* uint32_t */ +#define PRIo8 "o" /* uint8_t */ +#define PRIo16 "o" /* uint16_t */ +#define PRIo32 "o" /* uint32_t */ #define PRIo64 __PRI64"o" /* uint64_t */ -#define PRIoLEAST8 "o" /* uint_least8_t */ -#define PRIoLEAST16 "o" /* uint_least16_t */ -#define PRIoLEAST32 "o" /* uint_least32_t */ +#define PRIoLEAST8 "o" /* uint_least8_t */ +#define PRIoLEAST16 "o" /* uint_least16_t */ +#define PRIoLEAST32 "o" /* uint_least32_t */ #define PRIoLEAST64 __PRI64"o" /* uint_least64_t */ -#define PRIoFAST8 "o" /* uint_fast8_t */ -#define PRIoFAST16 "o" /* uint_fast16_t */ -#define PRIoFAST32 "o" /* uint_fast32_t */ +#define PRIoFAST8 "o" /* uint_fast8_t */ +#define PRIoFAST16 "o" /* uint_fast16_t */ +#define PRIoFAST32 "o" /* uint_fast32_t */ #define PRIoFAST64 __PRI64"o" /* uint_fast64_t */ -#define PRIoMAX "jo" /* uintmax_t */ +#define PRIoMAX "jo" /* uintmax_t */ #define PRIoPTR __PRIptr"o" /* uintptr_t */ -#define PRIu8 "u" /* uint8_t */ -#define PRIu16 "u" /* uint16_t */ -#define PRIu32 "u" /* uint32_t */ +#define PRIu8 "u" /* uint8_t */ +#define PRIu16 "u" /* uint16_t */ +#define PRIu32 "u" /* uint32_t */ #define PRIu64 __PRI64"u" /* uint64_t */ -#define PRIuLEAST8 "u" /* uint_least8_t */ -#define PRIuLEAST16 "u" /* uint_least16_t */ -#define PRIuLEAST32 "u" /* uint_least32_t */ +#define PRIuLEAST8 "u" /* uint_least8_t */ +#define PRIuLEAST16 "u" /* uint_least16_t */ +#define PRIuLEAST32 "u" /* uint_least32_t */ #define PRIuLEAST64 __PRI64"u" /* uint_least64_t */ -#define PRIuFAST8 "u" /* uint_fast8_t */ -#define PRIuFAST16 "u" /* uint_fast16_t */ -#define PRIuFAST32 "u" /* uint_fast32_t */ +#define PRIuFAST8 "u" /* uint_fast8_t */ +#define PRIuFAST16 "u" /* uint_fast16_t */ +#define PRIuFAST32 "u" /* uint_fast32_t */ #define PRIuFAST64 __PRI64"u" /* uint_fast64_t */ -#define PRIuMAX "ju" /* uintmax_t */ +#define PRIuMAX "ju" /* uintmax_t */ #define PRIuPTR __PRIptr"u" /* uintptr_t */ -#define PRIx8 "x" /* uint8_t */ -#define PRIx16 "x" /* uint16_t */ -#define PRIx32 "x" /* uint32_t */ +#define PRIx8 "x" /* uint8_t */ +#define PRIx16 "x" /* uint16_t */ +#define PRIx32 "x" /* uint32_t */ #define PRIx64 __PRI64"x" /* uint64_t */ -#define PRIxLEAST8 "x" /* uint_least8_t */ -#define PRIxLEAST16 "x" /* uint_least16_t */ -#define PRIxLEAST32 "x" /* uint_least32_t */ +#define PRIxLEAST8 "x" /* uint_least8_t */ +#define PRIxLEAST16 "x" /* uint_least16_t */ +#define PRIxLEAST32 "x" /* uint_least32_t */ #define PRIxLEAST64 __PRI64"x" /* uint_least64_t */ -#define PRIxFAST8 "x" /* uint_fast8_t */ -#define PRIxFAST16 "x" /* uint_fast16_t */ -#define PRIxFAST32 "x" /* uint_fast32_t */ +#define PRIxFAST8 "x" /* uint_fast8_t */ +#define PRIxFAST16 "x" /* uint_fast16_t */ +#define PRIxFAST32 "x" /* uint_fast32_t */ #define PRIxFAST64 __PRI64"x" /* uint_fast64_t */ -#define PRIxMAX "jx" /* uintmax_t */ +#define PRIxMAX "jx" /* uintmax_t */ #define PRIxPTR __PRIptr"x" /* uintptr_t */ -#define PRIX8 "X" /* uint8_t */ -#define PRIX16 "X" /* uint16_t */ -#define PRIX32 "X" /* uint32_t */ +#define PRIX8 "X" /* uint8_t */ +#define PRIX16 "X" /* uint16_t */ +#define PRIX32 "X" /* uint32_t */ #define PRIX64 __PRI64"X" /* uint64_t */ -#define PRIXLEAST8 "X" /* uint_least8_t */ -#define PRIXLEAST16 "X" /* uint_least16_t */ -#define PRIXLEAST32 "X" /* uint_least32_t */ +#define PRIXLEAST8 "X" /* uint_least8_t */ +#define PRIXLEAST16 "X" /* uint_least16_t */ +#define PRIXLEAST32 "X" /* uint_least32_t */ #define PRIXLEAST64 __PRI64"X" /* uint_least64_t */ -#define PRIXFAST8 "X" /* uint_fast8_t */ -#define PRIXFAST16 "X" /* uint_fast16_t */ -#define PRIXFAST32 "X" /* uint_fast32_t */ +#define PRIXFAST8 "X" /* uint_fast8_t */ +#define PRIXFAST16 "X" /* uint_fast16_t */ +#define PRIXFAST32 "X" /* uint_fast32_t */ #define PRIXFAST64 __PRI64"X" /* uint_fast64_t */ -#define PRIXMAX "jX" /* uintmax_t */ +#define PRIXMAX "jX" /* uintmax_t */ #define PRIXPTR __PRIptr"X" /* uintptr_t */ /* fscanf(3) macros for signed integers. */ -#define SCNd8 "hhd" /* int8_t */ -#define SCNd16 "hd" /* int16_t */ -#define SCNd32 "d" /* int32_t */ +#define SCNd8 "hhd" /* int8_t */ +#define SCNd16 "hd" /* int16_t */ +#define SCNd32 "d" /* int32_t */ #define SCNd64 __PRI64"d" /* int64_t */ -#define SCNdLEAST8 "hhd" /* int_least8_t */ -#define SCNdLEAST16 "hd" /* int_least16_t */ -#define SCNdLEAST32 "d" /* int_least32_t */ +#define SCNdLEAST8 "hhd" /* int_least8_t */ +#define SCNdLEAST16 "hd" /* int_least16_t */ +#define SCNdLEAST32 "d" /* int_least32_t */ #define SCNdLEAST64 __PRI64"d" /* int_least64_t */ -#define SCNdFAST8 "d" /* int_fast8_t */ -#define SCNdFAST16 "d" /* int_fast16_t */ -#define SCNdFAST32 "d" /* int_fast32_t */ +#define SCNdFAST8 "d" /* int_fast8_t */ +#define SCNdFAST16 "d" /* int_fast16_t */ +#define SCNdFAST32 "d" /* int_fast32_t */ #define SCNdFAST64 __PRI64"d" /* int_fast64_t */ -#define SCNdMAX "jd" /* intmax_t */ +#define SCNdMAX "jd" /* intmax_t */ #define SCNdPTR __PRIptr"d" /* intptr_t */ -#define SCNi8 "hhi" /* int8_t */ -#define SCNi16 "hi" /* int16_t */ -#define SCNi32 "i" /* int32_t */ +#define SCNi8 "hhi" /* int8_t */ +#define SCNi16 "hi" /* int16_t */ +#define SCNi32 "i" /* int32_t */ #define SCNi64 __PRI64"i" /* int64_t */ -#define SCNiLEAST8 "hhi" /* int_least8_t */ -#define SCNiLEAST16 "hi" /* int_least16_t */ -#define SCNiLEAST32 "i" /* int_least32_t */ +#define SCNiLEAST8 "hhi" /* int_least8_t */ +#define SCNiLEAST16 "hi" /* int_least16_t */ +#define SCNiLEAST32 "i" /* int_least32_t */ #define SCNiLEAST64 __PRI64"i" /* int_least64_t */ -#define SCNiFAST8 "i" /* int_fast8_t */ -#define SCNiFAST16 "i" /* int_fast16_t */ -#define SCNiFAST32 "i" /* int_fast32_t */ +#define SCNiFAST8 "i" /* int_fast8_t */ +#define SCNiFAST16 "i" /* int_fast16_t */ +#define SCNiFAST32 "i" /* int_fast32_t */ #define SCNiFAST64 __PRI64"i" /* int_fast64_t */ -#define SCNiMAX "ji" /* intmax_t */ +#define SCNiMAX "ji" /* intmax_t */ #define SCNiPTR __PRIptr"i" /* intptr_t */ /* fscanf(3) macros for unsigned integers. */ -#define SCNo8 "hho" /* uint8_t */ -#define SCNo16 "ho" /* uint16_t */ -#define SCNo32 "o" /* uint32_t */ +#define SCNo8 "hho" /* uint8_t */ +#define SCNo16 "ho" /* uint16_t */ +#define SCNo32 "o" /* uint32_t */ #define SCNo64 __PRI64"o" /* uint64_t */ -#define SCNoLEAST8 "hho" /* uint_least8_t */ -#define SCNoLEAST16 "ho" /* uint_least16_t */ -#define SCNoLEAST32 "o" /* uint_least32_t */ +#define SCNoLEAST8 "hho" /* uint_least8_t */ +#define SCNoLEAST16 "ho" /* uint_least16_t */ +#define SCNoLEAST32 "o" /* uint_least32_t */ #define SCNoLEAST64 __PRI64"o" /* uint_least64_t */ -#define SCNoFAST8 "o" /* uint_fast8_t */ -#define SCNoFAST16 "o" /* uint_fast16_t */ -#define SCNoFAST32 "o" /* uint_fast32_t */ +#define SCNoFAST8 "o" /* uint_fast8_t */ +#define SCNoFAST16 "o" /* uint_fast16_t */ +#define SCNoFAST32 "o" /* uint_fast32_t */ #define SCNoFAST64 __PRI64"o" /* uint_fast64_t */ -#define SCNoMAX "jo" /* uintmax_t */ +#define SCNoMAX "jo" /* uintmax_t */ #define SCNoPTR __PRIptr"o" /* uintptr_t */ -#define SCNu8 "hhu" /* uint8_t */ -#define SCNu16 "hu" /* uint16_t */ -#define SCNu32 "u" /* uint32_t */ +#define SCNu8 "hhu" /* uint8_t */ +#define SCNu16 "hu" /* uint16_t */ +#define SCNu32 "u" /* uint32_t */ #define SCNu64 __PRI64"u" /* uint64_t */ -#define SCNuLEAST8 "hhu" /* uint_least8_t */ -#define SCNuLEAST16 "hu" /* uint_least16_t */ -#define SCNuLEAST32 "u" /* uint_least32_t */ +#define SCNuLEAST8 "hhu" /* uint_least8_t */ +#define SCNuLEAST16 "hu" /* uint_least16_t */ +#define SCNuLEAST32 "u" /* uint_least32_t */ #define SCNuLEAST64 __PRI64"u" /* uint_least64_t */ -#define SCNuFAST8 "u" /* uint_fast8_t */ -#define SCNuFAST16 "u" /* uint_fast16_t */ -#define SCNuFAST32 "u" /* uint_fast32_t */ +#define SCNuFAST8 "u" /* uint_fast8_t */ +#define SCNuFAST16 "u" /* uint_fast16_t */ +#define SCNuFAST32 "u" /* uint_fast32_t */ #define SCNuFAST64 __PRI64"u" /* uint_fast64_t */ -#define SCNuMAX "ju" /* uintmax_t */ +#define SCNuMAX "ju" /* uintmax_t */ #define SCNuPTR __PRIptr"u" /* uintptr_t */ -#define SCNx8 "hhx" /* uint8_t */ -#define SCNx16 "hx" /* uint16_t */ -#define SCNx32 "x" /* uint32_t */ +#define SCNx8 "hhx" /* uint8_t */ +#define SCNx16 "hx" /* uint16_t */ +#define SCNx32 "x" /* uint32_t */ #define SCNx64 __PRI64"x" /* uint64_t */ -#define SCNxLEAST8 "hhx" /* uint_least8_t */ -#define SCNxLEAST16 "hx" /* uint_least16_t */ -#define SCNxLEAST32 "x" /* uint_least32_t */ +#define SCNxLEAST8 "hhx" /* uint_least8_t */ +#define SCNxLEAST16 "hx" /* uint_least16_t */ +#define SCNxLEAST32 "x" /* uint_least32_t */ #define SCNxLEAST64 __PRI64"x" /* uint_least64_t */ -#define SCNxFAST8 "x" /* uint_fast8_t */ -#define SCNxFAST16 "x" /* uint_fast16_t */ -#define SCNxFAST32 "x" /* uint_fast32_t */ +#define SCNxFAST8 "x" /* uint_fast8_t */ +#define SCNxFAST16 "x" /* uint_fast16_t */ +#define SCNxFAST32 "x" /* uint_fast32_t */ #define SCNxFAST64 __PRI64"x" /* uint_fast64_t */ -#define SCNxMAX "jx" /* uintmax_t */ +#define SCNxMAX "jx" /* uintmax_t */ #define SCNxPTR __PRIptr"x" /* uintptr_t */ #endif /* !_MACHINE_INTTYPES_H_ */ Modified: head/sys/powerpc/include/_inttypes.h ============================================================================== --- head/sys/powerpc/include/_inttypes.h Sat Jan 8 18:00:19 2011 (r217155) +++ head/sys/powerpc/include/_inttypes.h Sat Jan 8 18:02:46 2011 (r217156) @@ -31,7 +31,7 @@ */ #ifndef _MACHINE_INTTYPES_H_ -#define _MACHINE_INTTYPES_H_ +#define _MACHINE_INTTYPES_H_ /* * Macros for format specifiers. @@ -47,175 +47,175 @@ /* fprintf(3) macros for signed integers. */ -#define PRId8 "d" /* int8_t */ -#define PRId16 "d" /* int16_t */ -#define PRId32 "d" /* int32_t */ +#define PRId8 "d" /* int8_t */ +#define PRId16 "d" /* int16_t */ +#define PRId32 "d" /* int32_t */ #define PRId64 __PRI64"d" /* int64_t */ -#define PRIdLEAST8 "d" /* int_least8_t */ -#define PRIdLEAST16 "d" /* int_least16_t */ -#define PRIdLEAST32 "d" /* int_least32_t */ +#define PRIdLEAST8 "d" /* int_least8_t */ +#define PRIdLEAST16 "d" /* int_least16_t */ +#define PRIdLEAST32 "d" /* int_least32_t */ #define PRIdLEAST64 __PRI64"d" /* int_least64_t */ -#define PRIdFAST8 "d" /* int_fast8_t */ -#define PRIdFAST16 "d" /* int_fast16_t */ -#define PRIdFAST32 "d" /* int_fast32_t */ +#define PRIdFAST8 "d" /* int_fast8_t */ +#define PRIdFAST16 "d" /* int_fast16_t */ +#define PRIdFAST32 "d" /* int_fast32_t */ #define PRIdFAST64 __PRI64"d" /* int_fast64_t */ -#define PRIdMAX "jd" /* intmax_t */ +#define PRIdMAX "jd" /* intmax_t */ #define PRIdPTR __PRIptr"d" /* intptr_t */ -#define PRIi8 "i" /* int8_t */ -#define PRIi16 "i" /* int16_t */ -#define PRIi32 "i" /* int32_t */ +#define PRIi8 "i" /* int8_t */ +#define PRIi16 "i" /* int16_t */ +#define PRIi32 "i" /* int32_t */ #define PRIi64 __PRI64"i" /* int64_t */ -#define PRIiLEAST8 "i" /* int_least8_t */ -#define PRIiLEAST16 "i" /* int_least16_t */ -#define PRIiLEAST32 "i" /* int_least32_t */ +#define PRIiLEAST8 "i" /* int_least8_t */ +#define PRIiLEAST16 "i" /* int_least16_t */ +#define PRIiLEAST32 "i" /* int_least32_t */ #define PRIiLEAST64 __PRI64"i" /* int_least64_t */ -#define PRIiFAST8 "i" /* int_fast8_t */ -#define PRIiFAST16 "i" /* int_fast16_t */ -#define PRIiFAST32 "i" /* int_fast32_t */ +#define PRIiFAST8 "i" /* int_fast8_t */ +#define PRIiFAST16 "i" /* int_fast16_t */ +#define PRIiFAST32 "i" /* int_fast32_t */ #define PRIiFAST64 __PRI64"i" /* int_fast64_t */ -#define PRIiMAX "ji" /* intmax_t */ +#define PRIiMAX "ji" /* intmax_t */ #define PRIiPTR __PRIptr"i" /* intptr_t */ /* fprintf(3) macros for unsigned integers. */ -#define PRIo8 "o" /* uint8_t */ -#define PRIo16 "o" /* uint16_t */ -#define PRIo32 "o" /* uint32_t */ +#define PRIo8 "o" /* uint8_t */ +#define PRIo16 "o" /* uint16_t */ +#define PRIo32 "o" /* uint32_t */ #define PRIo64 __PRI64"o" /* uint64_t */ -#define PRIoLEAST8 "o" /* uint_least8_t */ -#define PRIoLEAST16 "o" /* uint_least16_t */ -#define PRIoLEAST32 "o" /* uint_least32_t */ +#define PRIoLEAST8 "o" /* uint_least8_t */ +#define PRIoLEAST16 "o" /* uint_least16_t */ +#define PRIoLEAST32 "o" /* uint_least32_t */ #define PRIoLEAST64 __PRI64"o" /* uint_least64_t */ -#define PRIoFAST8 "o" /* uint_fast8_t */ -#define PRIoFAST16 "o" /* uint_fast16_t */ -#define PRIoFAST32 "o" /* uint_fast32_t */ +#define PRIoFAST8 "o" /* uint_fast8_t */ +#define PRIoFAST16 "o" /* uint_fast16_t */ +#define PRIoFAST32 "o" /* uint_fast32_t */ #define PRIoFAST64 __PRI64"o" /* uint_fast64_t */ -#define PRIoMAX "jo" /* uintmax_t */ +#define PRIoMAX "jo" /* uintmax_t */ #define PRIoPTR __PRIptr"o" /* uintptr_t */ -#define PRIu8 "u" /* uint8_t */ -#define PRIu16 "u" /* uint16_t */ -#define PRIu32 "u" /* uint32_t */ +#define PRIu8 "u" /* uint8_t */ +#define PRIu16 "u" /* uint16_t */ +#define PRIu32 "u" /* uint32_t */ #define PRIu64 __PRI64"u" /* uint64_t */ -#define PRIuLEAST8 "u" /* uint_least8_t */ -#define PRIuLEAST16 "u" /* uint_least16_t */ -#define PRIuLEAST32 "u" /* uint_least32_t */ +#define PRIuLEAST8 "u" /* uint_least8_t */ +#define PRIuLEAST16 "u" /* uint_least16_t */ +#define PRIuLEAST32 "u" /* uint_least32_t */ #define PRIuLEAST64 __PRI64"u" /* uint_least64_t */ -#define PRIuFAST8 "u" /* uint_fast8_t */ -#define PRIuFAST16 "u" /* uint_fast16_t */ -#define PRIuFAST32 "u" /* uint_fast32_t */ +#define PRIuFAST8 "u" /* uint_fast8_t */ +#define PRIuFAST16 "u" /* uint_fast16_t */ +#define PRIuFAST32 "u" /* uint_fast32_t */ #define PRIuFAST64 __PRI64"u" /* uint_fast64_t */ -#define PRIuMAX "ju" /* uintmax_t */ +#define PRIuMAX "ju" /* uintmax_t */ #define PRIuPTR __PRIptr"u" /* uintptr_t */ -#define PRIx8 "x" /* uint8_t */ -#define PRIx16 "x" /* uint16_t */ -#define PRIx32 "x" /* uint32_t */ +#define PRIx8 "x" /* uint8_t */ +#define PRIx16 "x" /* uint16_t */ +#define PRIx32 "x" /* uint32_t */ #define PRIx64 __PRI64"x" /* uint64_t */ -#define PRIxLEAST8 "x" /* uint_least8_t */ -#define PRIxLEAST16 "x" /* uint_least16_t */ -#define PRIxLEAST32 "x" /* uint_least32_t */ +#define PRIxLEAST8 "x" /* uint_least8_t */ +#define PRIxLEAST16 "x" /* uint_least16_t */ +#define PRIxLEAST32 "x" /* uint_least32_t */ #define PRIxLEAST64 __PRI64"x" /* uint_least64_t */ -#define PRIxFAST8 "x" /* uint_fast8_t */ -#define PRIxFAST16 "x" /* uint_fast16_t */ -#define PRIxFAST32 "x" /* uint_fast32_t */ +#define PRIxFAST8 "x" /* uint_fast8_t */ +#define PRIxFAST16 "x" /* uint_fast16_t */ +#define PRIxFAST32 "x" /* uint_fast32_t */ #define PRIxFAST64 __PRI64"x" /* uint_fast64_t */ -#define PRIxMAX "jx" /* uintmax_t */ +#define PRIxMAX "jx" /* uintmax_t */ #define PRIxPTR __PRIptr"x" /* uintptr_t */ -#define PRIX8 "X" /* uint8_t */ -#define PRIX16 "X" /* uint16_t */ -#define PRIX32 "X" /* uint32_t */ +#define PRIX8 "X" /* uint8_t */ +#define PRIX16 "X" /* uint16_t */ +#define PRIX32 "X" /* uint32_t */ #define PRIX64 __PRI64"X" /* uint64_t */ -#define PRIXLEAST8 "X" /* uint_least8_t */ -#define PRIXLEAST16 "X" /* uint_least16_t */ -#define PRIXLEAST32 "X" /* uint_least32_t */ +#define PRIXLEAST8 "X" /* uint_least8_t */ +#define PRIXLEAST16 "X" /* uint_least16_t */ +#define PRIXLEAST32 "X" /* uint_least32_t */ #define PRIXLEAST64 __PRI64"X" /* uint_least64_t */ -#define PRIXFAST8 "X" /* uint_fast8_t */ -#define PRIXFAST16 "X" /* uint_fast16_t */ -#define PRIXFAST32 "X" /* uint_fast32_t */ +#define PRIXFAST8 "X" /* uint_fast8_t */ +#define PRIXFAST16 "X" /* uint_fast16_t */ +#define PRIXFAST32 "X" /* uint_fast32_t */ #define PRIXFAST64 __PRI64"X" /* uint_fast64_t */ -#define PRIXMAX "jX" /* uintmax_t */ +#define PRIXMAX "jX" /* uintmax_t */ #define PRIXPTR __PRIptr"X" /* uintptr_t */ /* fscanf(3) macros for signed integers. */ -#define SCNd8 "hhd" /* int8_t */ -#define SCNd16 "hd" /* int16_t */ -#define SCNd32 "d" /* int32_t */ +#define SCNd8 "hhd" /* int8_t */ +#define SCNd16 "hd" /* int16_t */ +#define SCNd32 "d" /* int32_t */ #define SCNd64 __PRI64"d" /* int64_t */ -#define SCNdLEAST8 "hhd" /* int_least8_t */ -#define SCNdLEAST16 "hd" /* int_least16_t */ -#define SCNdLEAST32 "d" /* int_least32_t */ +#define SCNdLEAST8 "hhd" /* int_least8_t */ +#define SCNdLEAST16 "hd" /* int_least16_t */ +#define SCNdLEAST32 "d" /* int_least32_t */ #define SCNdLEAST64 __PRI64"d" /* int_least64_t */ -#define SCNdFAST8 "d" /* int_fast8_t */ -#define SCNdFAST16 "d" /* int_fast16_t */ -#define SCNdFAST32 "d" /* int_fast32_t */ +#define SCNdFAST8 "d" /* int_fast8_t */ +#define SCNdFAST16 "d" /* int_fast16_t */ +#define SCNdFAST32 "d" /* int_fast32_t */ #define SCNdFAST64 __PRI64"d" /* int_fast64_t */ -#define SCNdMAX "jd" /* intmax_t */ +#define SCNdMAX "jd" /* intmax_t */ #define SCNdPTR __PRIptr"d" /* intptr_t */ -#define SCNi8 "hhi" /* int8_t */ -#define SCNi16 "hi" /* int16_t */ -#define SCNi32 "i" /* int32_t */ +#define SCNi8 "hhi" /* int8_t */ +#define SCNi16 "hi" /* int16_t */ +#define SCNi32 "i" /* int32_t */ #define SCNi64 __PRI64"i" /* int64_t */ -#define SCNiLEAST8 "hhi" /* int_least8_t */ -#define SCNiLEAST16 "hi" /* int_least16_t */ -#define SCNiLEAST32 "i" /* int_least32_t */ +#define SCNiLEAST8 "hhi" /* int_least8_t */ +#define SCNiLEAST16 "hi" /* int_least16_t */ +#define SCNiLEAST32 "i" /* int_least32_t */ #define SCNiLEAST64 __PRI64"i" /* int_least64_t */ -#define SCNiFAST8 "i" /* int_fast8_t */ -#define SCNiFAST16 "i" /* int_fast16_t */ -#define SCNiFAST32 "i" /* int_fast32_t */ +#define SCNiFAST8 "i" /* int_fast8_t */ +#define SCNiFAST16 "i" /* int_fast16_t */ +#define SCNiFAST32 "i" /* int_fast32_t */ #define SCNiFAST64 __PRI64"i" /* int_fast64_t */ -#define SCNiMAX "ji" /* intmax_t */ +#define SCNiMAX "ji" /* intmax_t */ #define SCNiPTR __PRIptr"i" /* intptr_t */ /* fscanf(3) macros for unsigned integers. */ -#define SCNo8 "hho" /* uint8_t */ -#define SCNo16 "ho" /* uint16_t */ -#define SCNo32 "o" /* uint32_t */ +#define SCNo8 "hho" /* uint8_t */ +#define SCNo16 "ho" /* uint16_t */ +#define SCNo32 "o" /* uint32_t */ #define SCNo64 __PRI64"o" /* uint64_t */ -#define SCNoLEAST8 "hho" /* uint_least8_t */ -#define SCNoLEAST16 "ho" /* uint_least16_t */ -#define SCNoLEAST32 "o" /* uint_least32_t */ +#define SCNoLEAST8 "hho" /* uint_least8_t */ +#define SCNoLEAST16 "ho" /* uint_least16_t */ +#define SCNoLEAST32 "o" /* uint_least32_t */ #define SCNoLEAST64 __PRI64"o" /* uint_least64_t */ -#define SCNoFAST8 "o" /* uint_fast8_t */ -#define SCNoFAST16 "o" /* uint_fast16_t */ -#define SCNoFAST32 "o" /* uint_fast32_t */ +#define SCNoFAST8 "o" /* uint_fast8_t */ +#define SCNoFAST16 "o" /* uint_fast16_t */ +#define SCNoFAST32 "o" /* uint_fast32_t */ #define SCNoFAST64 __PRI64"o" /* uint_fast64_t */ -#define SCNoMAX "jo" /* uintmax_t */ +#define SCNoMAX "jo" /* uintmax_t */ #define SCNoPTR __PRIptr"o" /* uintptr_t */ -#define SCNu8 "hhu" /* uint8_t */ -#define SCNu16 "hu" /* uint16_t */ -#define SCNu32 "u" /* uint32_t */ +#define SCNu8 "hhu" /* uint8_t */ +#define SCNu16 "hu" /* uint16_t */ +#define SCNu32 "u" /* uint32_t */ #define SCNu64 __PRI64"u" /* uint64_t */ -#define SCNuLEAST8 "hhu" /* uint_least8_t */ -#define SCNuLEAST16 "hu" /* uint_least16_t */ -#define SCNuLEAST32 "u" /* uint_least32_t */ +#define SCNuLEAST8 "hhu" /* uint_least8_t */ +#define SCNuLEAST16 "hu" /* uint_least16_t */ +#define SCNuLEAST32 "u" /* uint_least32_t */ #define SCNuLEAST64 __PRI64"u" /* uint_least64_t */ -#define SCNuFAST8 "u" /* uint_fast8_t */ -#define SCNuFAST16 "u" /* uint_fast16_t */ -#define SCNuFAST32 "u" /* uint_fast32_t */ +#define SCNuFAST8 "u" /* uint_fast8_t */ +#define SCNuFAST16 "u" /* uint_fast16_t */ +#define SCNuFAST32 "u" /* uint_fast32_t */ #define SCNuFAST64 __PRI64"u" /* uint_fast64_t */ -#define SCNuMAX "ju" /* uintmax_t */ +#define SCNuMAX "ju" /* uintmax_t */ #define SCNuPTR __PRIptr"u" /* uintptr_t */ -#define SCNx8 "hhx" /* uint8_t */ -#define SCNx16 "hx" /* uint16_t */ -#define SCNx32 "x" /* uint32_t */ +#define SCNx8 "hhx" /* uint8_t */ +#define SCNx16 "hx" /* uint16_t */ +#define SCNx32 "x" /* uint32_t */ #define SCNx64 __PRI64"x" /* uint64_t */ -#define SCNxLEAST8 "hhx" /* uint_least8_t */ -#define SCNxLEAST16 "hx" /* uint_least16_t */ -#define SCNxLEAST32 "x" /* uint_least32_t */ +#define SCNxLEAST8 "hhx" /* uint_least8_t */ +#define SCNxLEAST16 "hx" /* uint_least16_t */ +#define SCNxLEAST32 "x" /* uint_least32_t */ #define SCNxLEAST64 __PRI64"x" /* uint_least64_t */ -#define SCNxFAST8 "x" /* uint_fast8_t */ -#define SCNxFAST16 "x" /* uint_fast16_t */ -#define SCNxFAST32 "x" /* uint_fast32_t */ +#define SCNxFAST8 "x" /* uint_fast8_t */ +#define SCNxFAST16 "x" /* uint_fast16_t */ +#define SCNxFAST32 "x" /* uint_fast32_t */ #define SCNxFAST64 __PRI64"x" /* uint_fast64_t */ -#define SCNxMAX "jx" /* uintmax_t */ +#define SCNxMAX "jx" /* uintmax_t */ #define SCNxPTR __PRIptr"x" /* uintptr_t */ #endif /* !_MACHINE_INTTYPES_H_ */ From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 18:09:48 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7D03B10656B9; Sat, 8 Jan 2011 18:09:48 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6B0508FC21; Sat, 8 Jan 2011 18:09:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08I9mlf099910; Sat, 8 Jan 2011 18:09:48 GMT (envelope-from tijl@svn.freebsd.org) Received: (from tijl@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08I9mc8099905; Sat, 8 Jan 2011 18:09:48 GMT (envelope-from tijl@svn.freebsd.org) Message-Id: <201101081809.p08I9mc8099905@svn.freebsd.org> From: Tijl Coosemans Date: Sat, 8 Jan 2011 18:09:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217157 - in head/sys: amd64/include i386/include pc98/include x86/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 18:09:48 -0000 Author: tijl Date: Sat Jan 8 18:09:48 2011 New Revision: 217157 URL: http://svn.freebsd.org/changeset/base/217157 Log: Copy powerpc/include/_inttypes.h to x86 and replace i386/amd64/pc98 headers with stubs. Approved by: kib (mentor) Added: head/sys/x86/include/_inttypes.h - copied unchanged from r217156, head/sys/powerpc/include/_inttypes.h Modified: head/sys/amd64/include/_inttypes.h head/sys/i386/include/_inttypes.h head/sys/pc98/include/_inttypes.h Modified: head/sys/amd64/include/_inttypes.h ============================================================================== --- head/sys/amd64/include/_inttypes.h Sat Jan 8 18:02:46 2011 (r217156) +++ head/sys/amd64/include/_inttypes.h Sat Jan 8 18:09:48 2011 (r217157) @@ -1,213 +1,6 @@ /*- - * Copyright (c) 2001 The NetBSD Foundation, Inc. - * All rights reserved. - * - * This code is derived from software contributed to The NetBSD Foundation - * by Klaus Klein. - * - * 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 NETBSD FOUNDATION, INC. 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 FOUNDATION 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. - * - * From: $NetBSD: int_fmtio.h,v 1.2 2001/04/26 16:25:21 kleink Exp $ - * $FreeBSD$ + * This file is in the public domain. */ +/* $FreeBSD$ */ -#ifndef _MACHINE_INTTYPES_H_ -#define _MACHINE_INTTYPES_H_ - -/* - * Macros for format specifiers. - */ - -/* fprintf(3) macros for signed integers. */ - -#define PRId8 "d" /* int8_t */ -#define PRId16 "d" /* int16_t */ -#define PRId32 "d" /* int32_t */ -#define PRId64 "ld" /* int64_t */ -#define PRIdLEAST8 "d" /* int_least8_t */ -#define PRIdLEAST16 "d" /* int_least16_t */ -#define PRIdLEAST32 "d" /* int_least32_t */ -#define PRIdLEAST64 "ld" /* int_least64_t */ -#define PRIdFAST8 "d" /* int_fast8_t */ -#define PRIdFAST16 "d" /* int_fast16_t */ -#define PRIdFAST32 "d" /* int_fast32_t */ -#define PRIdFAST64 "ld" /* int_fast64_t */ -#define PRIdMAX "jd" /* intmax_t */ -#define PRIdPTR "ld" /* intptr_t */ - -#define PRIi8 "i" /* int8_t */ -#define PRIi16 "i" /* int16_t */ -#define PRIi32 "i" /* int32_t */ -#define PRIi64 "li" /* int64_t */ -#define PRIiLEAST8 "i" /* int_least8_t */ -#define PRIiLEAST16 "i" /* int_least16_t */ -#define PRIiLEAST32 "i" /* int_least32_t */ -#define PRIiLEAST64 "li" /* int_least64_t */ -#define PRIiFAST8 "i" /* int_fast8_t */ -#define PRIiFAST16 "i" /* int_fast16_t */ -#define PRIiFAST32 "i" /* int_fast32_t */ -#define PRIiFAST64 "li" /* int_fast64_t */ -#define PRIiMAX "ji" /* intmax_t */ -#define PRIiPTR "li" /* intptr_t */ - -/* fprintf(3) macros for unsigned integers. */ - -#define PRIo8 "o" /* uint8_t */ -#define PRIo16 "o" /* uint16_t */ -#define PRIo32 "o" /* uint32_t */ -#define PRIo64 "lo" /* uint64_t */ -#define PRIoLEAST8 "o" /* uint_least8_t */ -#define PRIoLEAST16 "o" /* uint_least16_t */ -#define PRIoLEAST32 "o" /* uint_least32_t */ -#define PRIoLEAST64 "lo" /* uint_least64_t */ -#define PRIoFAST8 "o" /* uint_fast8_t */ -#define PRIoFAST16 "o" /* uint_fast16_t */ -#define PRIoFAST32 "o" /* uint_fast32_t */ -#define PRIoFAST64 "lo" /* uint_fast64_t */ -#define PRIoMAX "jo" /* uintmax_t */ -#define PRIoPTR "lo" /* uintptr_t */ - -#define PRIu8 "u" /* uint8_t */ -#define PRIu16 "u" /* uint16_t */ -#define PRIu32 "u" /* uint32_t */ -#define PRIu64 "lu" /* uint64_t */ -#define PRIuLEAST8 "u" /* uint_least8_t */ -#define PRIuLEAST16 "u" /* uint_least16_t */ -#define PRIuLEAST32 "u" /* uint_least32_t */ -#define PRIuLEAST64 "lu" /* uint_least64_t */ -#define PRIuFAST8 "u" /* uint_fast8_t */ -#define PRIuFAST16 "u" /* uint_fast16_t */ -#define PRIuFAST32 "u" /* uint_fast32_t */ -#define PRIuFAST64 "lu" /* uint_fast64_t */ -#define PRIuMAX "ju" /* uintmax_t */ -#define PRIuPTR "lu" /* uintptr_t */ - -#define PRIx8 "x" /* uint8_t */ -#define PRIx16 "x" /* uint16_t */ -#define PRIx32 "x" /* uint32_t */ -#define PRIx64 "lx" /* uint64_t */ -#define PRIxLEAST8 "x" /* uint_least8_t */ -#define PRIxLEAST16 "x" /* uint_least16_t */ -#define PRIxLEAST32 "x" /* uint_least32_t */ -#define PRIxLEAST64 "lx" /* uint_least64_t */ -#define PRIxFAST8 "x" /* uint_fast8_t */ -#define PRIxFAST16 "x" /* uint_fast16_t */ -#define PRIxFAST32 "x" /* uint_fast32_t */ -#define PRIxFAST64 "lx" /* uint_fast64_t */ -#define PRIxMAX "jx" /* uintmax_t */ -#define PRIxPTR "lx" /* uintptr_t */ - -#define PRIX8 "X" /* uint8_t */ -#define PRIX16 "X" /* uint16_t */ -#define PRIX32 "X" /* uint32_t */ -#define PRIX64 "lX" /* uint64_t */ -#define PRIXLEAST8 "X" /* uint_least8_t */ -#define PRIXLEAST16 "X" /* uint_least16_t */ -#define PRIXLEAST32 "X" /* uint_least32_t */ -#define PRIXLEAST64 "lX" /* uint_least64_t */ -#define PRIXFAST8 "X" /* uint_fast8_t */ -#define PRIXFAST16 "X" /* uint_fast16_t */ -#define PRIXFAST32 "X" /* uint_fast32_t */ -#define PRIXFAST64 "lX" /* uint_fast64_t */ -#define PRIXMAX "jX" /* uintmax_t */ -#define PRIXPTR "lX" /* uintptr_t */ - -/* fscanf(3) macros for signed integers. */ - -#define SCNd8 "hhd" /* int8_t */ -#define SCNd16 "hd" /* int16_t */ -#define SCNd32 "d" /* int32_t */ -#define SCNd64 "ld" /* int64_t */ -#define SCNdLEAST8 "hhd" /* int_least8_t */ -#define SCNdLEAST16 "hd" /* int_least16_t */ -#define SCNdLEAST32 "d" /* int_least32_t */ -#define SCNdLEAST64 "ld" /* int_least64_t */ -#define SCNdFAST8 "d" /* int_fast8_t */ -#define SCNdFAST16 "d" /* int_fast16_t */ -#define SCNdFAST32 "d" /* int_fast32_t */ -#define SCNdFAST64 "ld" /* int_fast64_t */ -#define SCNdMAX "jd" /* intmax_t */ -#define SCNdPTR "ld" /* intptr_t */ - -#define SCNi8 "hhi" /* int8_t */ -#define SCNi16 "hi" /* int16_t */ -#define SCNi32 "i" /* int32_t */ -#define SCNi64 "li" /* int64_t */ -#define SCNiLEAST8 "hhi" /* int_least8_t */ -#define SCNiLEAST16 "hi" /* int_least16_t */ -#define SCNiLEAST32 "i" /* int_least32_t */ -#define SCNiLEAST64 "li" /* int_least64_t */ -#define SCNiFAST8 "i" /* int_fast8_t */ -#define SCNiFAST16 "i" /* int_fast16_t */ -#define SCNiFAST32 "i" /* int_fast32_t */ -#define SCNiFAST64 "li" /* int_fast64_t */ -#define SCNiMAX "ji" /* intmax_t */ -#define SCNiPTR "li" /* intptr_t */ - -/* fscanf(3) macros for unsigned integers. */ - -#define SCNo8 "hho" /* uint8_t */ -#define SCNo16 "ho" /* uint16_t */ -#define SCNo32 "o" /* uint32_t */ -#define SCNo64 "lo" /* uint64_t */ -#define SCNoLEAST8 "hho" /* uint_least8_t */ -#define SCNoLEAST16 "ho" /* uint_least16_t */ -#define SCNoLEAST32 "o" /* uint_least32_t */ -#define SCNoLEAST64 "lo" /* uint_least64_t */ -#define SCNoFAST8 "o" /* uint_fast8_t */ -#define SCNoFAST16 "o" /* uint_fast16_t */ -#define SCNoFAST32 "o" /* uint_fast32_t */ -#define SCNoFAST64 "lo" /* uint_fast64_t */ -#define SCNoMAX "jo" /* uintmax_t */ -#define SCNoPTR "lo" /* uintptr_t */ - -#define SCNu8 "hhu" /* uint8_t */ -#define SCNu16 "hu" /* uint16_t */ -#define SCNu32 "u" /* uint32_t */ -#define SCNu64 "lu" /* uint64_t */ -#define SCNuLEAST8 "hhu" /* uint_least8_t */ -#define SCNuLEAST16 "hu" /* uint_least16_t */ -#define SCNuLEAST32 "u" /* uint_least32_t */ -#define SCNuLEAST64 "lu" /* uint_least64_t */ -#define SCNuFAST8 "u" /* uint_fast8_t */ -#define SCNuFAST16 "u" /* uint_fast16_t */ -#define SCNuFAST32 "u" /* uint_fast32_t */ -#define SCNuFAST64 "lu" /* uint_fast64_t */ -#define SCNuMAX "ju" /* uintmax_t */ -#define SCNuPTR "lu" /* uintptr_t */ - -#define SCNx8 "hhx" /* uint8_t */ -#define SCNx16 "hx" /* uint16_t */ -#define SCNx32 "x" /* uint32_t */ -#define SCNx64 "lx" /* uint64_t */ -#define SCNxLEAST8 "hhx" /* uint_least8_t */ -#define SCNxLEAST16 "hx" /* uint_least16_t */ -#define SCNxLEAST32 "x" /* uint_least32_t */ -#define SCNxLEAST64 "lx" /* uint_least64_t */ -#define SCNxFAST8 "x" /* uint_fast8_t */ -#define SCNxFAST16 "x" /* uint_fast16_t */ -#define SCNxFAST32 "x" /* uint_fast32_t */ -#define SCNxFAST64 "lx" /* uint_fast64_t */ -#define SCNxMAX "jx" /* uintmax_t */ -#define SCNxPTR "lx" /* uintptr_t */ - -#endif /* !_MACHINE_INTTYPES_H_ */ +#include Modified: head/sys/i386/include/_inttypes.h ============================================================================== --- head/sys/i386/include/_inttypes.h Sat Jan 8 18:02:46 2011 (r217156) +++ head/sys/i386/include/_inttypes.h Sat Jan 8 18:09:48 2011 (r217157) @@ -1,213 +1,6 @@ /*- - * Copyright (c) 2001 The NetBSD Foundation, Inc. - * All rights reserved. - * - * This code is derived from software contributed to The NetBSD Foundation - * by Klaus Klein. - * - * 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 NETBSD FOUNDATION, INC. 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 FOUNDATION 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. - * - * From: $NetBSD: int_fmtio.h,v 1.2 2001/04/26 16:25:21 kleink Exp $ - * $FreeBSD$ + * This file is in the public domain. */ +/* $FreeBSD$ */ -#ifndef _MACHINE_INTTYPES_H_ -#define _MACHINE_INTTYPES_H_ - -/* - * Macros for format specifiers. - */ - -/* fprintf(3) macros for signed integers. */ - -#define PRId8 "d" /* int8_t */ -#define PRId16 "d" /* int16_t */ -#define PRId32 "d" /* int32_t */ -#define PRId64 "lld" /* int64_t */ -#define PRIdLEAST8 "d" /* int_least8_t */ -#define PRIdLEAST16 "d" /* int_least16_t */ -#define PRIdLEAST32 "d" /* int_least32_t */ -#define PRIdLEAST64 "lld" /* int_least64_t */ -#define PRIdFAST8 "d" /* int_fast8_t */ -#define PRIdFAST16 "d" /* int_fast16_t */ -#define PRIdFAST32 "d" /* int_fast32_t */ -#define PRIdFAST64 "lld" /* int_fast64_t */ -#define PRIdMAX "jd" /* intmax_t */ -#define PRIdPTR "d" /* intptr_t */ - -#define PRIi8 "i" /* int8_t */ -#define PRIi16 "i" /* int16_t */ -#define PRIi32 "i" /* int32_t */ -#define PRIi64 "lli" /* int64_t */ -#define PRIiLEAST8 "i" /* int_least8_t */ -#define PRIiLEAST16 "i" /* int_least16_t */ -#define PRIiLEAST32 "i" /* int_least32_t */ -#define PRIiLEAST64 "lli" /* int_least64_t */ -#define PRIiFAST8 "i" /* int_fast8_t */ -#define PRIiFAST16 "i" /* int_fast16_t */ -#define PRIiFAST32 "i" /* int_fast32_t */ -#define PRIiFAST64 "lli" /* int_fast64_t */ -#define PRIiMAX "ji" /* intmax_t */ -#define PRIiPTR "i" /* intptr_t */ - -/* fprintf(3) macros for unsigned integers. */ - -#define PRIo8 "o" /* uint8_t */ -#define PRIo16 "o" /* uint16_t */ -#define PRIo32 "o" /* uint32_t */ -#define PRIo64 "llo" /* uint64_t */ -#define PRIoLEAST8 "o" /* uint_least8_t */ -#define PRIoLEAST16 "o" /* uint_least16_t */ -#define PRIoLEAST32 "o" /* uint_least32_t */ -#define PRIoLEAST64 "llo" /* uint_least64_t */ -#define PRIoFAST8 "o" /* uint_fast8_t */ -#define PRIoFAST16 "o" /* uint_fast16_t */ -#define PRIoFAST32 "o" /* uint_fast32_t */ -#define PRIoFAST64 "llo" /* uint_fast64_t */ -#define PRIoMAX "jo" /* uintmax_t */ -#define PRIoPTR "o" /* uintptr_t */ - -#define PRIu8 "u" /* uint8_t */ -#define PRIu16 "u" /* uint16_t */ -#define PRIu32 "u" /* uint32_t */ -#define PRIu64 "llu" /* uint64_t */ -#define PRIuLEAST8 "u" /* uint_least8_t */ -#define PRIuLEAST16 "u" /* uint_least16_t */ -#define PRIuLEAST32 "u" /* uint_least32_t */ -#define PRIuLEAST64 "llu" /* uint_least64_t */ -#define PRIuFAST8 "u" /* uint_fast8_t */ -#define PRIuFAST16 "u" /* uint_fast16_t */ -#define PRIuFAST32 "u" /* uint_fast32_t */ -#define PRIuFAST64 "llu" /* uint_fast64_t */ -#define PRIuMAX "ju" /* uintmax_t */ -#define PRIuPTR "u" /* uintptr_t */ - -#define PRIx8 "x" /* uint8_t */ -#define PRIx16 "x" /* uint16_t */ -#define PRIx32 "x" /* uint32_t */ -#define PRIx64 "llx" /* uint64_t */ -#define PRIxLEAST8 "x" /* uint_least8_t */ -#define PRIxLEAST16 "x" /* uint_least16_t */ -#define PRIxLEAST32 "x" /* uint_least32_t */ -#define PRIxLEAST64 "llx" /* uint_least64_t */ -#define PRIxFAST8 "x" /* uint_fast8_t */ -#define PRIxFAST16 "x" /* uint_fast16_t */ -#define PRIxFAST32 "x" /* uint_fast32_t */ -#define PRIxFAST64 "llx" /* uint_fast64_t */ -#define PRIxMAX "jx" /* uintmax_t */ -#define PRIxPTR "x" /* uintptr_t */ - -#define PRIX8 "X" /* uint8_t */ -#define PRIX16 "X" /* uint16_t */ -#define PRIX32 "X" /* uint32_t */ -#define PRIX64 "llX" /* uint64_t */ -#define PRIXLEAST8 "X" /* uint_least8_t */ -#define PRIXLEAST16 "X" /* uint_least16_t */ -#define PRIXLEAST32 "X" /* uint_least32_t */ -#define PRIXLEAST64 "llX" /* uint_least64_t */ -#define PRIXFAST8 "X" /* uint_fast8_t */ -#define PRIXFAST16 "X" /* uint_fast16_t */ -#define PRIXFAST32 "X" /* uint_fast32_t */ -#define PRIXFAST64 "llX" /* uint_fast64_t */ -#define PRIXMAX "jX" /* uintmax_t */ -#define PRIXPTR "X" /* uintptr_t */ - -/* fscanf(3) macros for signed integers. */ - -#define SCNd8 "hhd" /* int8_t */ -#define SCNd16 "hd" /* int16_t */ -#define SCNd32 "d" /* int32_t */ -#define SCNd64 "lld" /* int64_t */ -#define SCNdLEAST8 "hhd" /* int_least8_t */ -#define SCNdLEAST16 "hd" /* int_least16_t */ -#define SCNdLEAST32 "d" /* int_least32_t */ -#define SCNdLEAST64 "lld" /* int_least64_t */ -#define SCNdFAST8 "d" /* int_fast8_t */ -#define SCNdFAST16 "d" /* int_fast16_t */ -#define SCNdFAST32 "d" /* int_fast32_t */ -#define SCNdFAST64 "lld" /* int_fast64_t */ -#define SCNdMAX "jd" /* intmax_t */ -#define SCNdPTR "d" /* intptr_t */ - -#define SCNi8 "hhi" /* int8_t */ -#define SCNi16 "hi" /* int16_t */ -#define SCNi32 "i" /* int32_t */ -#define SCNi64 "lli" /* int64_t */ -#define SCNiLEAST8 "hhi" /* int_least8_t */ -#define SCNiLEAST16 "hi" /* int_least16_t */ -#define SCNiLEAST32 "i" /* int_least32_t */ -#define SCNiLEAST64 "lli" /* int_least64_t */ -#define SCNiFAST8 "i" /* int_fast8_t */ -#define SCNiFAST16 "i" /* int_fast16_t */ -#define SCNiFAST32 "i" /* int_fast32_t */ -#define SCNiFAST64 "lli" /* int_fast64_t */ -#define SCNiMAX "ji" /* intmax_t */ -#define SCNiPTR "i" /* intptr_t */ - -/* fscanf(3) macros for unsigned integers. */ - -#define SCNo8 "hho" /* uint8_t */ -#define SCNo16 "ho" /* uint16_t */ -#define SCNo32 "o" /* uint32_t */ -#define SCNo64 "llo" /* uint64_t */ -#define SCNoLEAST8 "hho" /* uint_least8_t */ -#define SCNoLEAST16 "ho" /* uint_least16_t */ -#define SCNoLEAST32 "o" /* uint_least32_t */ -#define SCNoLEAST64 "llo" /* uint_least64_t */ -#define SCNoFAST8 "o" /* uint_fast8_t */ -#define SCNoFAST16 "o" /* uint_fast16_t */ -#define SCNoFAST32 "o" /* uint_fast32_t */ -#define SCNoFAST64 "llo" /* uint_fast64_t */ -#define SCNoMAX "jo" /* uintmax_t */ -#define SCNoPTR "o" /* uintptr_t */ - -#define SCNu8 "hhu" /* uint8_t */ -#define SCNu16 "hu" /* uint16_t */ -#define SCNu32 "u" /* uint32_t */ -#define SCNu64 "llu" /* uint64_t */ -#define SCNuLEAST8 "hhu" /* uint_least8_t */ -#define SCNuLEAST16 "hu" /* uint_least16_t */ -#define SCNuLEAST32 "u" /* uint_least32_t */ -#define SCNuLEAST64 "llu" /* uint_least64_t */ -#define SCNuFAST8 "u" /* uint_fast8_t */ -#define SCNuFAST16 "u" /* uint_fast16_t */ -#define SCNuFAST32 "u" /* uint_fast32_t */ -#define SCNuFAST64 "llu" /* uint_fast64_t */ -#define SCNuMAX "ju" /* uintmax_t */ -#define SCNuPTR "u" /* uintptr_t */ - -#define SCNx8 "hhx" /* uint8_t */ -#define SCNx16 "hx" /* uint16_t */ -#define SCNx32 "x" /* uint32_t */ -#define SCNx64 "llx" /* uint64_t */ -#define SCNxLEAST8 "hhx" /* uint_least8_t */ -#define SCNxLEAST16 "hx" /* uint_least16_t */ -#define SCNxLEAST32 "x" /* uint_least32_t */ -#define SCNxLEAST64 "llx" /* uint_least64_t */ -#define SCNxFAST8 "x" /* uint_fast8_t */ -#define SCNxFAST16 "x" /* uint_fast16_t */ -#define SCNxFAST32 "x" /* uint_fast32_t */ -#define SCNxFAST64 "llx" /* uint_fast64_t */ -#define SCNxMAX "jx" /* uintmax_t */ -#define SCNxPTR "x" /* uintptr_t */ - -#endif /* !_MACHINE_INTTYPES_H_ */ +#include Modified: head/sys/pc98/include/_inttypes.h ============================================================================== --- head/sys/pc98/include/_inttypes.h Sat Jan 8 18:02:46 2011 (r217156) +++ head/sys/pc98/include/_inttypes.h Sat Jan 8 18:09:48 2011 (r217157) @@ -3,4 +3,4 @@ */ /* $FreeBSD$ */ -#include +#include Copied: head/sys/x86/include/_inttypes.h (from r217156, head/sys/powerpc/include/_inttypes.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/x86/include/_inttypes.h Sat Jan 8 18:09:48 2011 (r217157, copy of r217156, head/sys/powerpc/include/_inttypes.h) @@ -0,0 +1,221 @@ +/*- + * Copyright (c) 2001 The NetBSD Foundation, Inc. + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Klaus Klein. + * + * 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 NETBSD FOUNDATION, INC. 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 FOUNDATION 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. + * + * From: $NetBSD: int_fmtio.h,v 1.2 2001/04/26 16:25:21 kleink Exp $ + * $FreeBSD$ + */ + +#ifndef _MACHINE_INTTYPES_H_ +#define _MACHINE_INTTYPES_H_ + +/* + * Macros for format specifiers. + */ + +#ifdef __LP64__ +#define __PRI64 "l" +#define __PRIptr "l" +#else +#define __PRI64 "ll" +#define __PRIptr +#endif + +/* fprintf(3) macros for signed integers. */ + +#define PRId8 "d" /* int8_t */ +#define PRId16 "d" /* int16_t */ +#define PRId32 "d" /* int32_t */ +#define PRId64 __PRI64"d" /* int64_t */ +#define PRIdLEAST8 "d" /* int_least8_t */ +#define PRIdLEAST16 "d" /* int_least16_t */ +#define PRIdLEAST32 "d" /* int_least32_t */ +#define PRIdLEAST64 __PRI64"d" /* int_least64_t */ +#define PRIdFAST8 "d" /* int_fast8_t */ +#define PRIdFAST16 "d" /* int_fast16_t */ +#define PRIdFAST32 "d" /* int_fast32_t */ +#define PRIdFAST64 __PRI64"d" /* int_fast64_t */ +#define PRIdMAX "jd" /* intmax_t */ +#define PRIdPTR __PRIptr"d" /* intptr_t */ + +#define PRIi8 "i" /* int8_t */ +#define PRIi16 "i" /* int16_t */ +#define PRIi32 "i" /* int32_t */ +#define PRIi64 __PRI64"i" /* int64_t */ +#define PRIiLEAST8 "i" /* int_least8_t */ +#define PRIiLEAST16 "i" /* int_least16_t */ +#define PRIiLEAST32 "i" /* int_least32_t */ +#define PRIiLEAST64 __PRI64"i" /* int_least64_t */ +#define PRIiFAST8 "i" /* int_fast8_t */ +#define PRIiFAST16 "i" /* int_fast16_t */ +#define PRIiFAST32 "i" /* int_fast32_t */ +#define PRIiFAST64 __PRI64"i" /* int_fast64_t */ +#define PRIiMAX "ji" /* intmax_t */ +#define PRIiPTR __PRIptr"i" /* intptr_t */ + +/* fprintf(3) macros for unsigned integers. */ + +#define PRIo8 "o" /* uint8_t */ +#define PRIo16 "o" /* uint16_t */ +#define PRIo32 "o" /* uint32_t */ +#define PRIo64 __PRI64"o" /* uint64_t */ +#define PRIoLEAST8 "o" /* uint_least8_t */ +#define PRIoLEAST16 "o" /* uint_least16_t */ +#define PRIoLEAST32 "o" /* uint_least32_t */ +#define PRIoLEAST64 __PRI64"o" /* uint_least64_t */ +#define PRIoFAST8 "o" /* uint_fast8_t */ +#define PRIoFAST16 "o" /* uint_fast16_t */ +#define PRIoFAST32 "o" /* uint_fast32_t */ +#define PRIoFAST64 __PRI64"o" /* uint_fast64_t */ +#define PRIoMAX "jo" /* uintmax_t */ +#define PRIoPTR __PRIptr"o" /* uintptr_t */ + +#define PRIu8 "u" /* uint8_t */ +#define PRIu16 "u" /* uint16_t */ +#define PRIu32 "u" /* uint32_t */ +#define PRIu64 __PRI64"u" /* uint64_t */ +#define PRIuLEAST8 "u" /* uint_least8_t */ +#define PRIuLEAST16 "u" /* uint_least16_t */ +#define PRIuLEAST32 "u" /* uint_least32_t */ +#define PRIuLEAST64 __PRI64"u" /* uint_least64_t */ +#define PRIuFAST8 "u" /* uint_fast8_t */ +#define PRIuFAST16 "u" /* uint_fast16_t */ +#define PRIuFAST32 "u" /* uint_fast32_t */ +#define PRIuFAST64 __PRI64"u" /* uint_fast64_t */ +#define PRIuMAX "ju" /* uintmax_t */ +#define PRIuPTR __PRIptr"u" /* uintptr_t */ + +#define PRIx8 "x" /* uint8_t */ +#define PRIx16 "x" /* uint16_t */ +#define PRIx32 "x" /* uint32_t */ +#define PRIx64 __PRI64"x" /* uint64_t */ +#define PRIxLEAST8 "x" /* uint_least8_t */ +#define PRIxLEAST16 "x" /* uint_least16_t */ +#define PRIxLEAST32 "x" /* uint_least32_t */ +#define PRIxLEAST64 __PRI64"x" /* uint_least64_t */ +#define PRIxFAST8 "x" /* uint_fast8_t */ +#define PRIxFAST16 "x" /* uint_fast16_t */ +#define PRIxFAST32 "x" /* uint_fast32_t */ +#define PRIxFAST64 __PRI64"x" /* uint_fast64_t */ +#define PRIxMAX "jx" /* uintmax_t */ +#define PRIxPTR __PRIptr"x" /* uintptr_t */ + +#define PRIX8 "X" /* uint8_t */ +#define PRIX16 "X" /* uint16_t */ +#define PRIX32 "X" /* uint32_t */ +#define PRIX64 __PRI64"X" /* uint64_t */ +#define PRIXLEAST8 "X" /* uint_least8_t */ +#define PRIXLEAST16 "X" /* uint_least16_t */ +#define PRIXLEAST32 "X" /* uint_least32_t */ +#define PRIXLEAST64 __PRI64"X" /* uint_least64_t */ +#define PRIXFAST8 "X" /* uint_fast8_t */ +#define PRIXFAST16 "X" /* uint_fast16_t */ +#define PRIXFAST32 "X" /* uint_fast32_t */ +#define PRIXFAST64 __PRI64"X" /* uint_fast64_t */ +#define PRIXMAX "jX" /* uintmax_t */ +#define PRIXPTR __PRIptr"X" /* uintptr_t */ + +/* fscanf(3) macros for signed integers. */ + +#define SCNd8 "hhd" /* int8_t */ +#define SCNd16 "hd" /* int16_t */ +#define SCNd32 "d" /* int32_t */ +#define SCNd64 __PRI64"d" /* int64_t */ +#define SCNdLEAST8 "hhd" /* int_least8_t */ +#define SCNdLEAST16 "hd" /* int_least16_t */ +#define SCNdLEAST32 "d" /* int_least32_t */ +#define SCNdLEAST64 __PRI64"d" /* int_least64_t */ +#define SCNdFAST8 "d" /* int_fast8_t */ +#define SCNdFAST16 "d" /* int_fast16_t */ +#define SCNdFAST32 "d" /* int_fast32_t */ +#define SCNdFAST64 __PRI64"d" /* int_fast64_t */ +#define SCNdMAX "jd" /* intmax_t */ +#define SCNdPTR __PRIptr"d" /* intptr_t */ + +#define SCNi8 "hhi" /* int8_t */ +#define SCNi16 "hi" /* int16_t */ +#define SCNi32 "i" /* int32_t */ +#define SCNi64 __PRI64"i" /* int64_t */ +#define SCNiLEAST8 "hhi" /* int_least8_t */ +#define SCNiLEAST16 "hi" /* int_least16_t */ +#define SCNiLEAST32 "i" /* int_least32_t */ +#define SCNiLEAST64 __PRI64"i" /* int_least64_t */ +#define SCNiFAST8 "i" /* int_fast8_t */ +#define SCNiFAST16 "i" /* int_fast16_t */ +#define SCNiFAST32 "i" /* int_fast32_t */ +#define SCNiFAST64 __PRI64"i" /* int_fast64_t */ +#define SCNiMAX "ji" /* intmax_t */ +#define SCNiPTR __PRIptr"i" /* intptr_t */ + +/* fscanf(3) macros for unsigned integers. */ + +#define SCNo8 "hho" /* uint8_t */ +#define SCNo16 "ho" /* uint16_t */ +#define SCNo32 "o" /* uint32_t */ +#define SCNo64 __PRI64"o" /* uint64_t */ +#define SCNoLEAST8 "hho" /* uint_least8_t */ +#define SCNoLEAST16 "ho" /* uint_least16_t */ +#define SCNoLEAST32 "o" /* uint_least32_t */ +#define SCNoLEAST64 __PRI64"o" /* uint_least64_t */ +#define SCNoFAST8 "o" /* uint_fast8_t */ +#define SCNoFAST16 "o" /* uint_fast16_t */ +#define SCNoFAST32 "o" /* uint_fast32_t */ +#define SCNoFAST64 __PRI64"o" /* uint_fast64_t */ +#define SCNoMAX "jo" /* uintmax_t */ +#define SCNoPTR __PRIptr"o" /* uintptr_t */ + +#define SCNu8 "hhu" /* uint8_t */ +#define SCNu16 "hu" /* uint16_t */ +#define SCNu32 "u" /* uint32_t */ +#define SCNu64 __PRI64"u" /* uint64_t */ +#define SCNuLEAST8 "hhu" /* uint_least8_t */ +#define SCNuLEAST16 "hu" /* uint_least16_t */ +#define SCNuLEAST32 "u" /* uint_least32_t */ +#define SCNuLEAST64 __PRI64"u" /* uint_least64_t */ +#define SCNuFAST8 "u" /* uint_fast8_t */ +#define SCNuFAST16 "u" /* uint_fast16_t */ +#define SCNuFAST32 "u" /* uint_fast32_t */ +#define SCNuFAST64 __PRI64"u" /* uint_fast64_t */ +#define SCNuMAX "ju" /* uintmax_t */ +#define SCNuPTR __PRIptr"u" /* uintptr_t */ + +#define SCNx8 "hhx" /* uint8_t */ +#define SCNx16 "hx" /* uint16_t */ +#define SCNx32 "x" /* uint32_t */ +#define SCNx64 __PRI64"x" /* uint64_t */ +#define SCNxLEAST8 "hhx" /* uint_least8_t */ +#define SCNxLEAST16 "hx" /* uint_least16_t */ +#define SCNxLEAST32 "x" /* uint_least32_t */ +#define SCNxLEAST64 __PRI64"x" /* uint_least64_t */ +#define SCNxFAST8 "x" /* uint_fast8_t */ +#define SCNxFAST16 "x" /* uint_fast16_t */ +#define SCNxFAST32 "x" /* uint_fast32_t */ +#define SCNxFAST64 __PRI64"x" /* uint_fast64_t */ +#define SCNxMAX "jx" /* uintmax_t */ +#define SCNxPTR __PRIptr"x" /* uintptr_t */ + +#endif /* !_MACHINE_INTTYPES_H_ */ From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 18:41:20 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2EC17106575E; Sat, 8 Jan 2011 18:41:20 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1E8148FC18; Sat, 8 Jan 2011 18:41:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08IfKfZ000908; Sat, 8 Jan 2011 18:41:20 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08IfKfa000906; Sat, 8 Jan 2011 18:41:20 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081841.p08IfKfa000906@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 18:41:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217160 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 18:41:20 -0000 Author: kib Date: Sat Jan 8 18:41:19 2011 New Revision: 217160 URL: http://svn.freebsd.org/changeset/base/217160 Log: Use the same expression to report stack protection mode for AT_STACKEXEC as the expression used by exec_new_vmspace(). Modified: head/sys/kern/imgact_elf.c Modified: head/sys/kern/imgact_elf.c ============================================================================== --- head/sys/kern/imgact_elf.c Sat Jan 8 18:31:23 2011 (r217159) +++ head/sys/kern/imgact_elf.c Sat Jan 8 18:41:19 2011 (r217160) @@ -982,8 +982,9 @@ __elfN(freebsd_fixup)(register_t **stack AUXARGS_ENTRY(pos, AT_PAGESIZES, imgp->pagesizes); AUXARGS_ENTRY(pos, AT_PAGESIZESLEN, imgp->pagesizeslen); } - AUXARGS_ENTRY(pos, AT_STACKPROT, imgp->stack_prot != 0 ? - imgp->stack_prot : imgp->sysent->sv_stackprot); + AUXARGS_ENTRY(pos, AT_STACKPROT, imgp->sysent->sv_shared_page_obj + != NULL && imgp->stack_prot != 0 ? imgp->stack_prot : + imgp->sysent->sv_stackprot); AUXARGS_ENTRY(pos, AT_NULL, 0); free(imgp->auxargs, M_TEMP); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 18:51:16 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3DCF61065693; Sat, 8 Jan 2011 18:51:16 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2CD8C8FC1C; Sat, 8 Jan 2011 18:51:16 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08IpGJx001146; Sat, 8 Jan 2011 18:51:16 GMT (envelope-from attilio@svn.freebsd.org) Received: (from attilio@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08IpGvH001144; Sat, 8 Jan 2011 18:51:16 GMT (envelope-from attilio@svn.freebsd.org) Message-Id: <201101081851.p08IpGvH001144@svn.freebsd.org> From: Attilio Rao Date: Sat, 8 Jan 2011 18:51:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217161 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 18:51:16 -0000 Author: attilio Date: Sat Jan 8 18:51:15 2011 New Revision: 217161 URL: http://svn.freebsd.org/changeset/base/217161 Log: Revert r216805. That revision is introducing a bug which is more visible than problems it is trying to fix. As long as my time is very limited in this period I am going to commit back this patch just once it is fully fixed. Reported by: dim, Nicholas Esborn Modified: head/sys/kern/kern_timeout.c Modified: head/sys/kern/kern_timeout.c ============================================================================== --- head/sys/kern/kern_timeout.c Sat Jan 8 18:41:19 2011 (r217160) +++ head/sys/kern/kern_timeout.c Sat Jan 8 18:51:15 2011 (r217161) @@ -56,10 +56,6 @@ __FBSDID("$FreeBSD$"); #include #include -#ifdef SMP -#include -#endif - SDT_PROVIDER_DEFINE(callout_execute); SDT_PROBE_DEFINE(callout_execute, kernel, , callout_start, callout-start); SDT_PROBE_ARGTYPE(callout_execute, kernel, , callout_start, 0, @@ -111,15 +107,11 @@ struct callout_cpu { struct callout *cc_next; struct callout *cc_curr; void *cc_cookie; - void (*cc_migration_func)(void *); - void *cc_migration_arg; int cc_ticks; int cc_softticks; int cc_cancel; int cc_waiting; int cc_firsttick; - int cc_migration_cpu; - int cc_migration_ticks; }; #ifdef SMP @@ -131,10 +123,8 @@ struct callout_cpu cc_cpu; #define CC_CPU(cpu) &cc_cpu #define CC_SELF() &cc_cpu #endif -#define CPUBLOCK MAXCPU #define CC_LOCK(cc) mtx_lock_spin(&(cc)->cc_lock) #define CC_UNLOCK(cc) mtx_unlock_spin(&(cc)->cc_lock) -#define CC_LOCK_ASSERT(cc) mtx_assert(&(cc)->cc_lock, MA_OWNED) static int timeout_cpu; void (*callout_new_inserted)(int cpu, int ticks) = NULL; @@ -198,7 +188,6 @@ callout_cpu_init(struct callout_cpu *cc) for (i = 0; i < callwheelsize; i++) { TAILQ_INIT(&cc->cc_callwheel[i]); } - cc->cc_migration_cpu = CPUBLOCK; if (cc->cc_callout == NULL) return; for (i = 0; i < ncallout; i++) { @@ -322,13 +311,6 @@ callout_lock(struct callout *c) for (;;) { cpu = c->c_cpu; -#ifdef SMP - if (cpu == CPUBLOCK) { - while (c->c_cpu == CPUBLOCK) - cpu_spinwait(); - continue; - } -#endif cc = CC_CPU(cpu); CC_LOCK(cc); if (cpu == c->c_cpu) @@ -338,29 +320,6 @@ callout_lock(struct callout *c) return (cc); } -static void -callout_cc_add(struct callout *c, struct callout_cpu *cc, int to_ticks, - void (*func)(void *), void *arg, int cpu) -{ - - CC_LOCK_ASSERT(cc); - - if (to_ticks <= 0) - to_ticks = 1; - c->c_arg = arg; - c->c_flags |= (CALLOUT_ACTIVE | CALLOUT_PENDING); - c->c_func = func; - c->c_time = ticks + to_ticks; - TAILQ_INSERT_TAIL(&cc->cc_callwheel[c->c_time & callwheelmask], - c, c_links.tqe); - if ((c->c_time - cc->cc_firsttick) < 0 && - callout_new_inserted != NULL) { - cc->cc_firsttick = c->c_time; - (*callout_new_inserted)(cpu, - to_ticks + (ticks - cc->cc_ticks)); - } -} - /* * The callout mechanism is based on the work of Adam M. Costello and * George Varghese, published in a technical report entitled "Redesigning @@ -431,14 +390,11 @@ softclock(void *arg) steps = 0; } } else { - struct callout_cpu *new_cc; void (*c_func)(void *); - void (*new_func)(void *); - void *c_arg, *new_arg; + void *c_arg; struct lock_class *class; struct lock_object *c_lock; int c_flags, sharedlock; - int new_cpu, new_ticks; cc->cc_next = TAILQ_NEXT(c, c_links.tqe); TAILQ_REMOVE(bucket, c, c_links.tqe); @@ -540,40 +496,7 @@ softclock(void *arg) c_links.sle); } cc->cc_curr = NULL; - - /* - * If the callout was scheduled for - * migration just perform it now. - */ - if (cc->cc_migration_cpu != CPUBLOCK) { - - /* - * There must not be any waiting - * thread now because the callout - * has a blocked CPU. - * Also, the callout must not be - * freed, but that is not easy to - * assert. - */ - MPASS(cc->cc_waiting == 0); - new_cpu = cc->cc_migration_cpu; - new_ticks = cc->cc_migration_ticks; - new_func = cc->cc_migration_func; - new_arg = cc->cc_migration_arg; - cc->cc_migration_cpu = CPUBLOCK; - cc->cc_migration_ticks = 0; - cc->cc_migration_func = NULL; - cc->cc_migration_arg = NULL; - CC_UNLOCK(cc); - new_cc = CC_CPU(new_cpu); - CC_LOCK(new_cc); - MPASS(c->c_cpu == CPUBLOCK); - c->c_cpu = new_cpu; - callout_cc_add(c, new_cc, new_ticks, - new_func, new_arg, new_cpu); - CC_UNLOCK(new_cc); - CC_LOCK(cc); - } else if (cc->cc_waiting) { + if (cc->cc_waiting) { /* * There is someone waiting * for the callout to complete. @@ -694,6 +617,7 @@ callout_reset_on(struct callout *c, int */ if (c->c_flags & CALLOUT_LOCAL_ALLOC) cpu = c->c_cpu; +retry: cc = callout_lock(c); if (cc->cc_curr == c) { /* @@ -725,34 +649,31 @@ callout_reset_on(struct callout *c, int cancelled = 1; c->c_flags &= ~(CALLOUT_ACTIVE | CALLOUT_PENDING); } -#ifdef SMP /* - * If the lock must migrate we have to block the callout locking - * until migration is completed. - * If the callout is currently running, just defer the migration - * to a more appropriate moment. + * If the lock must migrate we have to check the state again as + * we can't hold both the new and old locks simultaneously. */ if (c->c_cpu != cpu) { - c->c_cpu = CPUBLOCK; - if (cc->cc_curr == c) { - cc->cc_migration_cpu = cpu; - cc->cc_migration_ticks = to_ticks; - cc->cc_migration_func = ftn; - cc->cc_migration_arg = arg; - CTR5(KTR_CALLOUT, - "migration of %p func %p arg %p in %d to %u deferred", - c, c->c_func, c->c_arg, to_ticks, cpu); - CC_UNLOCK(cc); - return (cancelled); - } - CC_UNLOCK(cc); - cc = CC_CPU(cpu); - CC_LOCK(cc); c->c_cpu = cpu; + CC_UNLOCK(cc); + goto retry; } -#endif - callout_cc_add(c, cc, to_ticks, ftn, arg, cpu); + if (to_ticks <= 0) + to_ticks = 1; + + c->c_arg = arg; + c->c_flags |= (CALLOUT_ACTIVE | CALLOUT_PENDING); + c->c_func = ftn; + c->c_time = ticks + to_ticks; + TAILQ_INSERT_TAIL(&cc->cc_callwheel[c->c_time & callwheelmask], + c, c_links.tqe); + if ((c->c_time - cc->cc_firsttick) < 0 && + callout_new_inserted != NULL) { + cc->cc_firsttick = c->c_time; + (*callout_new_inserted)(cpu, + to_ticks + (ticks - cc->cc_ticks)); + } CTR5(KTR_CALLOUT, "%sscheduled %p func %p arg %p in %d", cancelled ? "re" : "", c, c->c_func, c->c_arg, to_ticks); CC_UNLOCK(cc); @@ -780,7 +701,7 @@ _callout_stop_safe(c, safe) struct callout *c; int safe; { - struct callout_cpu *cc, *old_cc; + struct callout_cpu *cc; struct lock_class *class; int use_lock, sq_locked; @@ -800,23 +721,8 @@ _callout_stop_safe(c, safe) use_lock = 0; sq_locked = 0; - old_cc = NULL; again: cc = callout_lock(c); - - /* - * If the callout was migrating while the callout cpu lock was - * dropped, just drop the sleepqueue lock and check the states - * again. - */ - if (sq_locked != 0 && cc != old_cc) { - CC_UNLOCK(cc); - sleepq_release(&old_cc->cc_waiting); - sq_locked = 0; - old_cc = NULL; - goto again; - } - /* * If the callout isn't pending, it's not on the queue, so * don't attempt to remove it from the queue. We can try to @@ -868,7 +774,6 @@ again: CC_UNLOCK(cc); sleepq_lock(&cc->cc_waiting); sq_locked = 1; - old_cc = cc; goto again; } cc->cc_waiting = 1; @@ -879,7 +784,6 @@ again: SLEEPQ_SLEEP, 0); sleepq_wait(&cc->cc_waiting, 0); sq_locked = 0; - old_cc = NULL; /* Reacquire locks previously released. */ PICKUP_GIANT(); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 19:50:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9EE3F1065670; Sat, 8 Jan 2011 19:50:13 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8E4C78FC14; Sat, 8 Jan 2011 19:50:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08JoDur002458; Sat, 8 Jan 2011 19:50:13 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08JoDN4002456; Sat, 8 Jan 2011 19:50:13 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201101081950.p08JoDN4002456@svn.freebsd.org> From: Nathan Whitehorn Date: Sat, 8 Jan 2011 19:50:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217163 - head/sys/kern X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 19:50:13 -0000 Author: nwhitehorn Date: Sat Jan 8 19:50:13 2011 New Revision: 217163 URL: http://svn.freebsd.org/changeset/base/217163 Log: Make RB_CDROM work. This should probably check for a disc in cd1 and acd1 as well. Modified: head/sys/kern/vfs_mountroot.c Modified: head/sys/kern/vfs_mountroot.c ============================================================================== --- head/sys/kern/vfs_mountroot.c Sat Jan 8 19:49:27 2011 (r217162) +++ head/sys/kern/vfs_mountroot.c Sat Jan 8 19:50:13 2011 (r217163) @@ -831,9 +831,9 @@ vfs_mountroot_conf0(struct sbuf *sb) sbuf_printf(sb, "%s\n", ROOTDEVNAME); #endif if (boothowto & RB_CDROM) { - sbuf_printf(sb, "cd9660:cd0\n"); + sbuf_printf(sb, "cd9660:/dev/cd0 ro\n"); sbuf_printf(sb, ".timeout 0\n"); - sbuf_printf(sb, "cd9660:acd0\n"); + sbuf_printf(sb, "cd9660:/dev/acd0 ro\n"); sbuf_printf(sb, ".timeout %d\n", root_mount_timeout); } s = getenv("vfs.root.mountfrom"); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 20:25:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C86501065670; Sat, 8 Jan 2011 20:25:00 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B68E08FC0A; Sat, 8 Jan 2011 20:25:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08KP02M003273; Sat, 8 Jan 2011 20:25:00 GMT (envelope-from jpaetzel@svn.freebsd.org) Received: (from jpaetzel@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08KP0AX003269; Sat, 8 Jan 2011 20:25:00 GMT (envelope-from jpaetzel@svn.freebsd.org) Message-Id: <201101082025.p08KP0AX003269@svn.freebsd.org> From: Josh Paetzel Date: Sat, 8 Jan 2011 20:25:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217164 - in head/usr.sbin/pc-sysinstall: backend backend-query X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 20:25:00 -0000 Author: jpaetzel (ports committer) Date: Sat Jan 8 20:25:00 2011 New Revision: 217164 URL: http://svn.freebsd.org/changeset/base/217164 Log: More elegant way to detect MBR vs. GPT Submitted by: nwhitehorn Approved by: imp Modified: head/usr.sbin/pc-sysinstall/backend-query/disk-part.sh head/usr.sbin/pc-sysinstall/backend/functions-disk.sh Modified: head/usr.sbin/pc-sysinstall/backend-query/disk-part.sh ============================================================================== --- head/usr.sbin/pc-sysinstall/backend-query/disk-part.sh Sat Jan 8 19:50:13 2011 (r217163) +++ head/usr.sbin/pc-sysinstall/backend-query/disk-part.sh Sat Jan 8 20:25:00 2011 (r217164) @@ -60,14 +60,8 @@ if [ "$?" != "0" ] ; then fi # Display if this is GPT or MBR formatted -gpart show ${1} | grep "GPT" >/dev/null 2>/dev/null -if [ "$?" = "0" ] ; then - echo "${1}-format: GPT" - TYPE="GPT" -else - echo "${1}-format: MBR" - TYPE="MBR" -fi +TYPE=`gpart show ${1} | awk '/^=>/ { printf("%s",$5); }'` +echo "${1}-format: $TYPE" # Set some search flags PART="0" Modified: head/usr.sbin/pc-sysinstall/backend/functions-disk.sh ============================================================================== --- head/usr.sbin/pc-sysinstall/backend/functions-disk.sh Sat Jan 8 19:50:13 2011 (r217163) +++ head/usr.sbin/pc-sysinstall/backend/functions-disk.sh Sat Jan 8 20:25:00 2011 (r217164) @@ -180,12 +180,7 @@ get_disk_partitions() return fi - gpart show ${1} | grep "MBR" >/dev/null 2>/dev/null - if [ "$?" = "0" ] ; then - type="MBR" - else - type="GPT" - fi + type=`gpart show ${1} | awk '/^=>/ { printf("%s",$5); }'` SLICES="`gpart show ${1} | grep -v ${1} | grep -v ' free ' |tr -s '\t' ' ' | cut -d ' ' -f 4 | sed '/^$/d'`" for i in ${SLICES} From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 20:31:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9046B106564A; Sat, 8 Jan 2011 20:31:13 +0000 (UTC) (envelope-from juli@clockworksquid.com) Received: from mail-wy0-f182.google.com (mail-wy0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id 997428FC0C; Sat, 8 Jan 2011 20:31:12 +0000 (UTC) Received: by wyf19 with SMTP id 19so18652024wyf.13 for ; Sat, 08 Jan 2011 12:31:11 -0800 (PST) Received: by 10.227.128.4 with SMTP id i4mr17415065wbs.109.1294518669963; Sat, 08 Jan 2011 12:31:09 -0800 (PST) MIME-Version: 1.0 Sender: juli@clockworksquid.com Received: by 10.227.153.210 with HTTP; Sat, 8 Jan 2011 12:30:49 -0800 (PST) In-Reply-To: <201101081243.p08Ch5vR092295@svn.freebsd.org> References: <201101081243.p08Ch5vR092295@svn.freebsd.org> From: Juli Mallett Date: Sat, 8 Jan 2011 12:30:49 -0800 X-Google-Sender-Auth: 1Umc75TMPLuCHmSmEq3pa6ratq0 Message-ID: To: Tijl Coosemans Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r217147 - in head/sys: amd64/include arm/include i386/include ia64/include mips/include powerpc/include sparc64/include sun4v/include X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 20:31:14 -0000 On Sat, Jan 8, 2011 at 04:43, Tijl Coosemans wrote: > Author: tijl > Date: Sat Jan =A08 12:43:05 2011 > New Revision: 217147 > URL: http://svn.freebsd.org/changeset/base/217147 > > Log: > =A0On mixed 32/64 bit architectures (mips, powerpc) use __LP64__ rather t= han > =A0architecture macros (__mips_n64, __powerpc64__) when 64 bit types (and > =A0corresponding macros) are different from 32 bit. [1] I don't know why you didn't talk with MIPS people at all about these changes. That they were reviewed by Bruce is very reassuring in aesthetic terms, but that's hardly sufficient. This and other changes have made it harder to support common MIPS configurations and compilation options on FreeBSD. I'm glad you're at least aware of n32 (as indicated in another message) and its implications, but the use of ABI-specific names was deliberate. Have you thought about -n32 with -mlong64? It isn't the same kind of dirty hack as Bruce talks about when he talks about 64-bit longs on x86. I understand that __LP64__ and the idea that there are two reasonable ABIs most (one 32-bit and one 64-bit) is appealing, but it's not true. In the case of PowerPC, it does look like they weren't ABI-specific macros, but MIPS's were. If nothing else, you make MIPS headers more inconsistent with themselves, where most of them are ABI-conditionalized and now some are instead LP64-centric. It seems like your end goal is probably consolidating these headers, which I would like, too, but please attempt to allow for more variation than just "longs are 32-bit and pointers are 32-bit, otherwise longs are 64-bit and pointers are 64-bit." We're trying to do the right thing with MIPS in terms of supporting multiple valid ABIs on a single port, something which is a lot harder when people restructure these critical headers without even asking us whether there are any evident problems; even if 'make universe', for instance, were enough, it leaves out some ABIs, and it certainly leaves out future plans wrt ABIs. Thanks, Juli. From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 22:33:46 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E52FA106564A; Sat, 8 Jan 2011 22:33:46 +0000 (UTC) (envelope-from deischen@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D47A78FC0A; Sat, 8 Jan 2011 22:33:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08MXkLv016126; Sat, 8 Jan 2011 22:33:46 GMT (envelope-from deischen@svn.freebsd.org) Received: (from deischen@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08MXkj5016123; Sat, 8 Jan 2011 22:33:46 GMT (envelope-from deischen@svn.freebsd.org) Message-Id: <201101082233.p08MXkj5016123@svn.freebsd.org> From: Daniel Eischen Date: Sat, 8 Jan 2011 22:33:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217169 - head/sys/netinet X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 22:33:47 -0000 Author: deischen Date: Sat Jan 8 22:33:46 2011 New Revision: 217169 URL: http://svn.freebsd.org/changeset/base/217169 Log: Make sure to always do source address selection on an unbound socket, regardless of any multicast options. If an address is specified via a multicast option, then let it override normal the source address selection. This fixes a bug where source address selection was not being performed when multicast options were present but without an interface being specified. Reviewed by: bz MFC after: 1 day Modified: head/sys/netinet/in_pcb.c Modified: head/sys/netinet/in_pcb.c ============================================================================== --- head/sys/netinet/in_pcb.c Sat Jan 8 22:08:23 2011 (r217168) +++ head/sys/netinet/in_pcb.c Sat Jan 8 22:33:46 2011 (r217169) @@ -874,9 +874,10 @@ in_pcbconnect_setup(struct inpcb *inp, s } } if (laddr.s_addr == INADDR_ANY) { + error = in_pcbladdr(inp, &faddr, &laddr, cred); /* * If the destination address is multicast and an outgoing - * interface has been set as a multicast option, use the + * interface has been set as a multicast option, prefer the * address of that interface as our source address. */ if (IN_MULTICAST(ntohl(faddr.s_addr)) && @@ -893,16 +894,16 @@ in_pcbconnect_setup(struct inpcb *inp, s break; if (ia == NULL) { IN_IFADDR_RUNLOCK(); - return (EADDRNOTAVAIL); + error = EADDRNOTAVAIL; + } else { + laddr = ia->ia_addr.sin_addr; + IN_IFADDR_RUNLOCK(); + error = 0; } - laddr = ia->ia_addr.sin_addr; - IN_IFADDR_RUNLOCK(); } - } else { - error = in_pcbladdr(inp, &faddr, &laddr, cred); - if (error) - return (error); } + if (error) + return (error); } oinp = in_pcblookup_hash(inp->inp_pcbinfo, faddr, fport, laddr, lport, 0, NULL); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 22:42:57 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EDF2E106566C; Sat, 8 Jan 2011 22:42:56 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DC9468FC0A; Sat, 8 Jan 2011 22:42:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08Mgu4m017089; Sat, 8 Jan 2011 22:42:56 GMT (envelope-from jpaetzel@svn.freebsd.org) Received: (from jpaetzel@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08Mguh6017086; Sat, 8 Jan 2011 22:42:56 GMT (envelope-from jpaetzel@svn.freebsd.org) Message-Id: <201101082242.p08Mguh6017086@svn.freebsd.org> From: Josh Paetzel Date: Sat, 8 Jan 2011 22:42:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217170 - head/usr.sbin/pc-sysinstall/backend X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 22:42:57 -0000 Author: jpaetzel (ports committer) Date: Sat Jan 8 22:42:56 2011 New Revision: 217170 URL: http://svn.freebsd.org/changeset/base/217170 Log: Push some PC-BSD specific fixes upstream. PR: bin/152894 Submitted by: Kris Moore Approved by: imp Modified: head/usr.sbin/pc-sysinstall/backend/functions-cleanup.sh head/usr.sbin/pc-sysinstall/backend/functions-networking.sh Modified: head/usr.sbin/pc-sysinstall/backend/functions-cleanup.sh ============================================================================== --- head/usr.sbin/pc-sysinstall/backend/functions-cleanup.sh Sat Jan 8 22:33:46 2011 (r217169) +++ head/usr.sbin/pc-sysinstall/backend/functions-cleanup.sh Sat Jan 8 22:42:56 2011 (r217170) @@ -233,7 +233,6 @@ setup_fstab() then echo "procfs /proc procfs rw 0 0" >> ${FSTAB} echo "linprocfs /compat/linux/proc linprocfs rw 0 0" >> ${FSTAB} - echo "tmpfs /tmp tmpfs rw,mode=1777 0 0" >> ${FSTAB} fi # If we have a dedicated /boot, run the post-install setup of it now Modified: head/usr.sbin/pc-sysinstall/backend/functions-networking.sh ============================================================================== --- head/usr.sbin/pc-sysinstall/backend/functions-networking.sh Sat Jan 8 22:33:46 2011 (r217169) +++ head/usr.sbin/pc-sysinstall/backend/functions-networking.sh Sat Jan 8 22:42:56 2011 (r217170) @@ -54,7 +54,7 @@ check_is_wifi() fi }; -# Function to get the first available wired nic, used for lagg0 setup +# Function to get the first available wired nic, used for setup get_first_wired_nic() { rm ${TMPDIR}/.niclist >/dev/null 2>/dev/null @@ -78,8 +78,9 @@ get_first_wired_nic() return }; -# Function which simply enables plain dhcp on all detected nics, not fancy lagg interface -enable_plain_dhcp_all() + +# Function which simply enables plain dhcp on all detected nics +enable_dhcp_all() { rm ${TMPDIR}/.niclist >/dev/null 2>/dev/null # start by getting a list of nics on this system @@ -111,57 +112,11 @@ enable_plain_dhcp_all() fi }; -# Function which enables fancy lagg dhcp on specified wifi -enable_lagg_dhcp() -{ - WIFINIC="$1" - - # Get the first wired nic - get_first_wired_nic - WIRENIC=$VAL - LAGGPORT="laggport ${WIFINIC}" - - echo "# Auto-Enabled NICs from pc-sysinstall" >>${FSMNT}/etc/rc.conf - if [ ! -z "$WIRENIC" ] - then - echo "ifconfig_${WIRENIC}=\"up\"" >> ${FSMNT}/etc/rc.conf - echo "ifconfig_${WIFINIC}=\"\`ifconfig ${WIRENIC} ether\`\"" >> ${FSMNT}/etc/rc.conf - echo "ifconfig_${WIFINIC}=\"ether \${ifconfig_${WIFINIC}##*ether }\"" >> ${FSMNT}/etc/rc.conf - LAGGPORT="laggport ${WIRENIC} ${LAGGPORT}" - fi - - echo "wlans_${WIFINIC}=\"wlan0\"" >> ${FSMNT}/etc/rc.conf - echo "cloned_interfaces=\"lagg0\"" >> ${FSMNT}/etc/rc.conf - echo "ifconfig_lagg0=\"laggproto failover ${LAGGPORT} DHCP\"" >> ${FSMNT}/etc/rc.conf - -}; -# Function which detects available nics, and runs them to DHCP on the +# Function which detects available nics, and enables dhcp on them save_auto_dhcp() { - rm ${TMPDIR}/.niclist >/dev/null 2>/dev/null - # start by getting a list of nics on this system - ${QUERYDIR}/detect-nics.sh > ${TMPDIR}/.niclist - if [ -e "${TMPDIR}/.niclist" ] - then - while read line - do - NIC="`echo $line | cut -d ':' -f 1`" - DESC="`echo $line | cut -d ':' -f 2`" - check_is_wifi "${NIC}" - if [ "$?" = "0" ] - then - # We have a wifi device, lets do fancy lagg interface - enable_lagg_dhcp "${NIC}" - return - fi - - done < ${TMPDIR}/.niclist - fi - - # Got here, looks like no wifi, so lets simply enable plain-ole-dhcp - enable_plain_dhcp_all - + enable_dhcp_all }; From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 22:45:23 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3410C1065693; Sat, 8 Jan 2011 22:45:23 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0929A8FC19; Sat, 8 Jan 2011 22:45:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08MjMTc017393; Sat, 8 Jan 2011 22:45:22 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08MjMKP017391; Sat, 8 Jan 2011 22:45:22 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201101082245.p08MjMKP017391@svn.freebsd.org> From: Alan Cox Date: Sat, 8 Jan 2011 22:45:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217171 - head/sys/vm X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 22:45:23 -0000 Author: alc Date: Sat Jan 8 22:45:22 2011 New Revision: 217171 URL: http://svn.freebsd.org/changeset/base/217171 Log: Eliminate the counting of vm_page_pa_tryrelock calls. We really don't need it anymore. Moreover, its implementation had a type mismatch, a long is not necessarily an uint64_t. (This mismatch was hidden by casting.) Move the remaining two counters up a level in the sysctl hierarchy. There is no reason for them to be under the vm.pmap node. Reviewed by: kib Modified: head/sys/vm/vm_page.c Modified: head/sys/vm/vm_page.c ============================================================================== --- head/sys/vm/vm_page.c Sat Jan 8 22:42:56 2011 (r217170) +++ head/sys/vm/vm_page.c Sat Jan 8 22:45:22 2011 (r217171) @@ -132,24 +132,6 @@ __FBSDID("$FreeBSD$"); #include -#if defined(__amd64__) || defined (__i386__) -extern struct sysctl_oid_list sysctl__vm_pmap_children; -#else -SYSCTL_NODE(_vm, OID_AUTO, pmap, CTLFLAG_RD, 0, "VM/pmap parameters"); -#endif - -static uint64_t pmap_tryrelock_calls; -SYSCTL_QUAD(_vm_pmap, OID_AUTO, tryrelock_calls, CTLFLAG_RD, - &pmap_tryrelock_calls, 0, "Number of tryrelock calls"); - -static int pmap_tryrelock_restart; -SYSCTL_INT(_vm_pmap, OID_AUTO, tryrelock_restart, CTLFLAG_RD, - &pmap_tryrelock_restart, 0, "Number of tryrelock restarts"); - -static int pmap_tryrelock_race; -SYSCTL_INT(_vm_pmap, OID_AUTO, tryrelock_race, CTLFLAG_RD, - &pmap_tryrelock_race, 0, "Number of tryrelock pmap race cases"); - /* * Associated with page of user-allocatable memory is a * page structure. @@ -171,6 +153,14 @@ TUNABLE_INT("vm.boot_pages", &boot_pages SYSCTL_INT(_vm, OID_AUTO, boot_pages, CTLFLAG_RD, &boot_pages, 0, "number of pages allocated for bootstrapping the VM system"); +static int pa_tryrelock_race; +SYSCTL_INT(_vm, OID_AUTO, tryrelock_race, CTLFLAG_RD, + &pa_tryrelock_race, 0, "Number of tryrelock race cases"); + +static int pa_tryrelock_restart; +SYSCTL_INT(_vm, OID_AUTO, tryrelock_restart, CTLFLAG_RD, + &pa_tryrelock_restart, 0, "Number of tryrelock restarts"); + static void vm_page_clear_dirty_mask(vm_page_t m, int pagebits); static void vm_page_queue_remove(int queue, vm_page_t m); static void vm_page_enqueue(int queue, vm_page_t m); @@ -195,7 +185,6 @@ vm_page_pa_tryrelock(pmap_t pmap, vm_pad uint32_t gen_count; gen_count = pmap->pm_gen_count; - atomic_add_long((volatile long *)&pmap_tryrelock_calls, 1); lockpa = *locked; *locked = pa; if (lockpa) { @@ -207,13 +196,13 @@ vm_page_pa_tryrelock(pmap_t pmap, vm_pad if (PA_TRYLOCK(pa)) return (0); PMAP_UNLOCK(pmap); - atomic_add_int((volatile int *)&pmap_tryrelock_restart, 1); + atomic_add_int(&pa_tryrelock_restart, 1); PA_LOCK(pa); PMAP_LOCK(pmap); if (pmap->pm_gen_count != gen_count + 1) { pmap->pm_retries++; - atomic_add_int((volatile int *)&pmap_tryrelock_race, 1); + atomic_add_int(&pa_tryrelock_race, 1); return (EAGAIN); } return (0); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 23:00:38 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B68FA1065672; Sat, 8 Jan 2011 23:00:38 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A5BFD8FC14; Sat, 8 Jan 2011 23:00:38 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08N0cRe018919; Sat, 8 Jan 2011 23:00:38 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08N0cuD018918; Sat, 8 Jan 2011 23:00:38 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201101082300.p08N0cuD018918@svn.freebsd.org> From: Jilles Tjoelker Date: Sat, 8 Jan 2011 23:00:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217172 - head/tools/regression/bin/sh/builtins X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 23:00:38 -0000 Author: jilles Date: Sat Jan 8 23:00:38 2011 New Revision: 217172 URL: http://svn.freebsd.org/changeset/base/217172 Log: sh: Add simple test for 'exit' without parameters. Added: head/tools/regression/bin/sh/builtins/exit2.8 (contents, props changed) Added: head/tools/regression/bin/sh/builtins/exit2.8 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/regression/bin/sh/builtins/exit2.8 Sat Jan 8 23:00:38 2011 (r217172) @@ -0,0 +1,7 @@ +# $FreeBSD$ + +# exit without arguments is the same as exit $? outside a trap. + +trap 'true; true' 0 +(exit 8) +exit From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 23:00:54 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AC4031065700; Sat, 8 Jan 2011 23:00:54 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 4C1E88FC08; Sat, 8 Jan 2011 23:00:54 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by harmony.bsdimp.com (8.14.3/8.14.1) with ESMTP id p08Mw8fa063313; Sat, 8 Jan 2011 15:58:08 -0700 (MST) (envelope-from imp@bsdimp.com) Message-ID: <4D28EBFE.10004@bsdimp.com> Date: Sat, 08 Jan 2011 15:58:06 -0700 From: Warner Losh User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.12) Gecko/20101029 Thunderbird/3.1.6 MIME-Version: 1.0 To: Doug Barton References: <201101062107.p06L7p9o028440@svn.freebsd.org> <4D27F295.1030609@FreeBSD.org> In-Reply-To: <4D27F295.1030609@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Warner Losh Subject: Re: svn commit: r217071 - head/lib/bind X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 23:00:54 -0000 On 01/07/2011 22:13, Doug Barton wrote: > I've said before that I like to have the opportunity to pre-commit > review patches in this area because at minimum it helps me to be aware > of them for potential MFC purposes. Thanks for the reminder Doug. Hope there's no hard feelings... > That said, I appreciate the help, especially with the more "exotic" > arches that I don't have experience with. > > A few comments below. me too... > > On 01/06/2011 13:07, Warner Losh wrote: >> Author: imp >> Date: Thu Jan 6 21:07:51 2011 >> New Revision: 217071 >> URL: http://svn.freebsd.org/changeset/base/217071 >> >> Log: >> Make this work on big endian MIPS, while not breaking it for small >> endian mips. This will also make it work automatically on all future >> big endian platforms. >> >> Modified: >> head/lib/bind/config.mk >> >> Modified: head/lib/bind/config.mk >> ============================================================================== >> >> --- head/lib/bind/config.mk Thu Jan 6 21:04:00 2011 (r217070) >> +++ head/lib/bind/config.mk Thu Jan 6 21:07:51 2011 (r217071) >> @@ -1,6 +1,7 @@ >> # $FreeBSD$ >> >> .include >> +.include >> >> # BIND version number >> .if defined(BIND_DIR)&& exists(${BIND_DIR}/version) >> @@ -45,7 +46,7 @@ CFLAGS+= -DOPENSSL >> CFLAGS+= -DUSE_MD5 >> >> # Endianness >> -.if ${MACHINE_CPUARCH} == "powerpc" || ${MACHINE_CPUARCH} == "sparc64" >> +.if ${TARGET_ENDIANNESS} == 4321 >> CFLAGS+= -DWORDS_BIGENDIAN >> .endif > > This is just the kind of solution I was hoping would be available, and > exactly the kind I prefer, the no-maintenance kind. :) Is this safe > to MFC, or does it require bits that are only in HEAD atm? If the > latter, can you please let me know when it's ready to go? Thanks. I think that bsd.endian.mk is -current only, but there's no reason it can't be MFC'd. I'll merge it to 7 and 8 here in a few minutes and let you know. > >> @@ -64,11 +65,7 @@ CFLAGS+= -I${LIB_BIND_DIR} >> .endif >> >> # Use the right version of the atomic.h file from lib/isc >> -.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" >> -ISC_ATOMIC_ARCH= x86_32 >> -.else >> -ISC_ATOMIC_ARCH= ${MACHINE_CPUARCH} >> -.endif >> +ISC_ATOMIC_ARCH=${MACHINE_CPUARCH:S/i386/x86_32/:S/amd64/x86_32/} > > This change I am less enthusiastic about. It seems to me that it does > the exact same thing, but while admittedly quite a bit more clever > than I am capable of I find it less readable. Unless this is doing > something more or better than the previous code I will likely revert > this. Damn. I missed that in my pre-commit review, or I'd have mentioned it in the commit log. Feel free to revert it if you don't like it, or I'd be happy to revert it if you wanted me to clean up my own mess. Warner > > > Doug > From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 23:03:25 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 400B2106567A; Sat, 8 Jan 2011 23:03:25 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2ED688FC27; Sat, 8 Jan 2011 23:03:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08N3PAl019028; Sat, 8 Jan 2011 23:03:25 GMT (envelope-from jpaetzel@svn.freebsd.org) Received: (from jpaetzel@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08N3PQU019026; Sat, 8 Jan 2011 23:03:25 GMT (envelope-from jpaetzel@svn.freebsd.org) Message-Id: <201101082303.p08N3PQU019026@svn.freebsd.org> From: Josh Paetzel Date: Sat, 8 Jan 2011 23:03:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217173 - head/usr.sbin/pc-sysinstall/backend-query X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 23:03:25 -0000 Author: jpaetzel (ports committer) Date: Sat Jan 8 23:03:24 2011 New Revision: 217173 URL: http://svn.freebsd.org/changeset/base/217173 Log: Take passwords out of debug log. Fix path problem that was preventing disk info from being in the log. PR: bin/151968 Submitted by: Kris Moore Approved by: imp Modified: head/usr.sbin/pc-sysinstall/backend-query/send-logs.sh Modified: head/usr.sbin/pc-sysinstall/backend-query/send-logs.sh ============================================================================== --- head/usr.sbin/pc-sysinstall/backend-query/send-logs.sh Sat Jan 8 23:00:38 2011 (r217172) +++ head/usr.sbin/pc-sysinstall/backend-query/send-logs.sh Sat Jan 8 23:03:24 2011 (r217173) @@ -50,7 +50,7 @@ if [ -e "/tmp/sys-install.cfg" ] then echo "" >>${TMPLOG} echo "# PC-SYSINSTALL CFG " >>${TMPLOG} - cat /tmp/sys-install.cfg >> ${TMPLOG} + cat /tmp/sys-install.cfg | grep -vE 'rootPass|userPass' >> ${TMPLOG} fi # Save dmesg output @@ -59,7 +59,7 @@ echo "# DMESG OUTPUT " >>${TMPLOG} dmesg >> ${TMPLOG} # Get gpart info on all disks -for i in `${PROGDIR}/pc-sysinstall disk-list | cut -d ':' -f 1` +for i in `pc-sysinstall disk-list | cut -d ':' -f 1` do echo "" >>${TMPLOG} echo "# DISK INFO $i " >>${TMPLOG} From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 23:06:54 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9A211106566B; Sat, 8 Jan 2011 23:06:54 +0000 (UTC) (envelope-from csjp@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 88F3A8FC17; Sat, 8 Jan 2011 23:06:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08N6sx5019151; Sat, 8 Jan 2011 23:06:54 GMT (envelope-from csjp@svn.freebsd.org) Received: (from csjp@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08N6sDw019147; Sat, 8 Jan 2011 23:06:54 GMT (envelope-from csjp@svn.freebsd.org) Message-Id: <201101082306.p08N6sDw019147@svn.freebsd.org> From: "Christian S.J. Peron" Date: Sat, 8 Jan 2011 23:06:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217174 - head/sys/netsmb X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 23:06:54 -0000 Author: csjp Date: Sat Jan 8 23:06:54 2011 New Revision: 217174 URL: http://svn.freebsd.org/changeset/base/217174 Log: Change some variables from int to size_t. This is more accurate since these variables represent sizes in one capacity or another. There is no reason to allow negative numbers. Change userspace shared structure elements that get used for the modified functions from int to uint32_t, since it's not clear what userspace programs use these fields, and we do not want to break binary compatibility. This fixes a panic when corrupt or bogus data is passed into the kernel. Obtained from: NetBSD MFC after: 3 weeks Modified: head/sys/netsmb/smb_dev.h head/sys/netsmb/smb_subr.c head/sys/netsmb/smb_subr.h Modified: head/sys/netsmb/smb_dev.h ============================================================================== --- head/sys/netsmb/smb_dev.h Sat Jan 8 23:03:24 2011 (r217173) +++ head/sys/netsmb/smb_dev.h Sat Jan 8 23:06:54 2011 (r217174) @@ -58,9 +58,9 @@ struct smbioc_ossn { int ioc_opt; - int ioc_svlen; /* size of ioc_server address */ + uint32_t ioc_svlen; /* size of ioc_server address */ struct sockaddr*ioc_server; - int ioc_lolen; /* size of ioc_local address */ + uint32_t ioc_lolen; /* size of ioc_local address */ struct sockaddr*ioc_local; char ioc_srvname[SMB_MAXSRVNAMELEN + 1]; int ioc_timeout; Modified: head/sys/netsmb/smb_subr.c ============================================================================== --- head/sys/netsmb/smb_subr.c Sat Jan 8 23:03:24 2011 (r217173) +++ head/sys/netsmb/smb_subr.c Sat Jan 8 23:06:54 2011 (r217174) @@ -93,7 +93,7 @@ char * smb_strdup(const char *s) { char *p; - int len; + size_t len; len = s ? strlen(s) + 1 : 1; p = malloc(len, M_SMBSTR, M_WAITOK); @@ -108,11 +108,13 @@ smb_strdup(const char *s) * duplicate string from a user space. */ char * -smb_strdupin(char *s, int maxlen) +smb_strdupin(char *s, size_t maxlen) { char *p, bt; - int error, len = 0; + int error; + size_t len; + len = 0; for (p = s; ;p++) { if (copyin(p, &bt, 1)) return NULL; @@ -135,7 +137,7 @@ smb_strdupin(char *s, int maxlen) * duplicate memory block from a user space. */ void * -smb_memdupin(void *umem, int len) +smb_memdupin(void *umem, size_t len) { char *p; @@ -178,7 +180,7 @@ smb_memfree(void *s) } void * -smb_zmalloc(unsigned long size, struct malloc_type *type, int flags) +smb_zmalloc(size_t size, struct malloc_type *type, int flags) { return malloc(size, type, flags | M_ZERO); @@ -197,12 +199,12 @@ smb_strtouni(u_int16_t *dst, const char void m_dumpm(struct mbuf *m) { char *p; - int len; + size_t len; printf("d="); while(m) { p=mtod(m,char *); len=m->m_len; - printf("(%d)",len); + printf("(%zu)",len); while(len--){ printf("%02x ",((int)*(p++)) & 0xff); } @@ -337,7 +339,7 @@ smb_copy_iconv(struct mbchain *mbp, c_ca int smb_put_dmem(struct mbchain *mbp, struct smb_vc *vcp, const char *src, - int size, int caseopt) + size_t size, int caseopt) { struct iconv_drv *dp = vcp->vc_toserver; Modified: head/sys/netsmb/smb_subr.h ============================================================================== --- head/sys/netsmb/smb_subr.h Sat Jan 8 23:03:24 2011 (r217173) +++ head/sys/netsmb/smb_subr.h Sat Jan 8 23:06:54 2011 (r217174) @@ -101,19 +101,19 @@ void smb_makescred(struct smb_cred *scre int smb_td_intr(struct thread *); char *smb_strdup(const char *s); void *smb_memdup(const void *umem, int len); -char *smb_strdupin(char *s, int maxlen); -void *smb_memdupin(void *umem, int len); +char *smb_strdupin(char *s, size_t maxlen); +void *smb_memdupin(void *umem, size_t len); void smb_strtouni(u_int16_t *dst, const char *src); void smb_strfree(char *s); void smb_memfree(void *s); -void *smb_zmalloc(unsigned long size, struct malloc_type *type, int flags); +void *smb_zmalloc(size_t size, struct malloc_type *type, int flags); int smb_calcmackey(struct smb_vc *vcp); int smb_encrypt(const u_char *apwd, u_char *C8, u_char *RN); int smb_ntencrypt(const u_char *apwd, u_char *C8, u_char *RN); int smb_maperror(int eclass, int eno); int smb_put_dmem(struct mbchain *mbp, struct smb_vc *vcp, - const char *src, int len, int caseopt); + const char *src, size_t len, int caseopt); int smb_put_dstring(struct mbchain *mbp, struct smb_vc *vcp, const char *src, int caseopt); int smb_put_string(struct smb_rq *rqp, const char *src); From owner-svn-src-head@FreeBSD.ORG Sat Jan 8 23:08:13 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A2453106564A; Sat, 8 Jan 2011 23:08:13 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 76DEA8FC0A; Sat, 8 Jan 2011 23:08:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08N8Dg9019223; Sat, 8 Jan 2011 23:08:13 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08N8DkS019218; Sat, 8 Jan 2011 23:08:13 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201101082308.p08N8DkS019218@svn.freebsd.org> From: Jilles Tjoelker Date: Sat, 8 Jan 2011 23:08:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217175 - in head: bin/sh tools/regression/bin/sh/builtins X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 23:08:13 -0000 Author: jilles Date: Sat Jan 8 23:08:13 2011 New Revision: 217175 URL: http://svn.freebsd.org/changeset/base/217175 Log: sh: Make exit without parameters from EXIT trap POSIX-compliant. It should use the original exit status, just like falling off the end of the trap handler. Outside an EXIT trap, 'exit' is still equivalent to 'exit $?'. Added: head/tools/regression/bin/sh/builtins/exit3.0 (contents, props changed) Modified: head/bin/sh/main.c head/bin/sh/trap.c head/bin/sh/trap.h Modified: head/bin/sh/main.c ============================================================================== --- head/bin/sh/main.c Sat Jan 8 23:06:54 2011 (r217174) +++ head/bin/sh/main.c Sat Jan 8 23:08:13 2011 (r217175) @@ -341,10 +341,7 @@ exitcmd(int argc, char **argv) if (stoppedjobs()) return 0; if (argc > 1) - exitstatus = number(argv[1]); + exitshell(number(argv[1])); else - exitstatus = oexitstatus; - exitshell(exitstatus); - /*NOTREACHED*/ - return 0; + exitshell_savedstatus(); } Modified: head/bin/sh/trap.c ============================================================================== --- head/bin/sh/trap.c Sat Jan 8 23:06:54 2011 (r217174) +++ head/bin/sh/trap.c Sat Jan 8 23:08:13 2011 (r217175) @@ -80,6 +80,9 @@ static volatile sig_atomic_t gotsig[NSIG static int ignore_sigchld; /* Used while handling SIGCHLD traps. */ volatile sig_atomic_t gotwinch; +static int exiting; /* exitshell() has been called */ +static int exiting_exitstatus; /* value passed to exitshell() */ + static int getsigaction(int, sig_t *); @@ -478,10 +481,21 @@ setinteractive(int on) void exitshell(int status) { + TRACE(("exitshell(%d) pid=%d\n", status, getpid())); + exiting = 1; + exiting_exitstatus = status; + exitshell_savedstatus(); +} + +void +exitshell_savedstatus(void) +{ struct jmploc loc1, loc2; char *p; - TRACE(("exitshell(%d) pid=%d\n", status, getpid())); + if (!exiting) + exiting_exitstatus = oexitstatus; + exitstatus = oexitstatus = exiting_exitstatus; if (setjmp(loc1.loc)) { goto l1; } @@ -498,5 +512,5 @@ l1: handler = &loc2; /* probably unn #if JOBS setjobctl(0); #endif -l2: _exit(status); +l2: _exit(exiting_exitstatus); } Modified: head/bin/sh/trap.h ============================================================================== --- head/bin/sh/trap.h Sat Jan 8 23:06:54 2011 (r217174) +++ head/bin/sh/trap.h Sat Jan 8 23:08:13 2011 (r217175) @@ -46,3 +46,4 @@ void onsig(int); void dotrap(void); void setinteractive(int); void exitshell(int) __dead2; +void exitshell_savedstatus(void) __dead2; Added: head/tools/regression/bin/sh/builtins/exit3.0 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/regression/bin/sh/builtins/exit3.0 Sat Jan 8 23:08:13 2011 (r217175) @@ -0,0 +1,5 @@ +# $FreeBSD$ + +# exit without arguments differs from exit $? in an EXIT trap. + +trap 'false; exit' 0