From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 00:04:24 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5C7571065670; Sun, 15 Apr 2012 00:04:24 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 46E768FC0C; Sun, 15 Apr 2012 00:04:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3F04Oa1055799; Sun, 15 Apr 2012 00:04:24 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3F04O7V055797; Sun, 15 Apr 2012 00:04:24 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204150004.q3F04O7V055797@svn.freebsd.org> From: Adrian Chadd Date: Sun, 15 Apr 2012 00:04: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: r234304 - head/sys/dev/ath X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 00:04:24 -0000 Author: adrian Date: Sun Apr 15 00:04:23 2012 New Revision: 234304 URL: http://svn.freebsd.org/changeset/base/234304 Log: Override some default values to work around various issues in the deep, dirty and murky past. * Override the default cache line size to be something reasonable if it's set to 0. Some NICs initialise with '0' (eg embedded ones) and there are comments in the driver stating that various OSes (eg older Linux ones) would incorrectly program things and 0 out this register. * Just default to overriding the latency timer. Every other driver does this. * Use a default cache line size of 32 bytes. It should be "reasonable enough". Obtained from: Linux ath9k, Atheros Modified: head/sys/dev/ath/if_ath_pci.c Modified: head/sys/dev/ath/if_ath_pci.c ============================================================================== --- head/sys/dev/ath/if_ath_pci.c Sat Apr 14 23:59:58 2012 (r234303) +++ head/sys/dev/ath/if_ath_pci.c Sun Apr 15 00:04:23 2012 (r234304) @@ -82,13 +82,27 @@ struct ath_pci_softc { #define PCIR_RETRY_TIMEOUT 0x41 #define PCIR_CFG_PMCSR 0x48 +#define DEFAULT_CACHESIZE 32 + static void ath_pci_setup(device_t dev) { -#ifdef ATH_PCI_LATENCY_WAR + uint8_t cz; + + /* XXX TODO: need to override the _system_ saved copies of this */ + + /* + * If the cache line size is 0, force it to a reasonable + * value. + */ + cz = pci_read_config(dev, PCIR_CACHELNSZ, 1); + if (cz == 0) { + pci_write_config(dev, PCIR_CACHELNSZ, + DEFAULT_CACHESIZE / 4, 1); + } + /* Override the system latency timer */ - pci_write_config(dev, PCIR_LATTIMER, 0x80, 1); -#endif + pci_write_config(dev, PCIR_LATTIMER, 0xa8, 1); /* If a PCI NIC, force wakeup */ #ifdef ATH_PCI_WAKEUP_WAR From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 01:27:59 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9987D1065673; Sun, 15 Apr 2012 01:27:59 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-ob0-f182.google.com (mail-ob0-f182.google.com [209.85.214.182]) by mx1.freebsd.org (Postfix) with ESMTP id 2E5608FC0C; Sun, 15 Apr 2012 01:27:59 +0000 (UTC) Received: by obqv19 with SMTP id v19so4646093obq.13 for ; Sat, 14 Apr 2012 18:27:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; bh=QP30u+I2nR8+m4iXU+tmsaOFU+4HJBjzFzsNgYwpGvE=; b=ZtTeyEWxA5TGe9bRMIlH5pj0o7fP7C+mhy+L5H1ohZi4HvhSWE7XAfW2bzifjH+R4P zZLUz3pyEpW/A+OohZR30trK7GY6CUJ7qGnURyUDO9+wWQmEA0y32PWqOFo/zCZ4H9Mt BwUWG1leawVN7VfyvWV4LgqH8cXBGg3Crc9DWjogQov7JCfPaglS+CtsGOXbButhWCmz eFM7qTk6bWHAow4u/9IbQP6FNojkuTPrkm41V+OC2KtPAuDhDchBaGfIXdJ71k1Hx01v 2B/wwS8PAaw3VMgHX7Q4YKoO/CLY/LxH2sK3KYt3/RikLj7Bo5RkDW7M0NPkTS7KWwNM t1Qg== Received: by 10.182.36.3 with SMTP id m3mr9303691obj.8.1334453277927; Sat, 14 Apr 2012 18:27:57 -0700 (PDT) Received: from [192.168.2.5] (dpc691939029.direcpc.com. [69.19.39.29]) by mx.google.com with ESMTPS id h2sm14971216obn.20.2012.04.14.18.27.47 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 14 Apr 2012 18:27:57 -0700 (PDT) Mime-Version: 1.0 (Apple Message framework v1257) Content-Type: text/plain; charset=windows-1252 From: Garrett Cooper In-Reply-To: <201204141644.q3EGiJ3h038632@svn.freebsd.org> Date: Sat, 14 Apr 2012 18:27:37 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <26482E9C-4636-4820-AD24-5F5642E5D0A5@gmail.com> References: <201204141644.q3EGiJ3h038632@svn.freebsd.org> To: Luigi Rizzo X-Mailer: Apple Mail (2.1257) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234290 - head/sys/dev/netmap X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 01:27:59 -0000 On Apr 14, 2012, at 9:44 AM, Luigi Rizzo wrote: > Author: luigi > Date: Sat Apr 14 16:44:18 2012 > New Revision: 234290 > URL: http://svn.freebsd.org/changeset/base/234290 >=20 > Log: > i prefer this fix for the -Wformat warning (just one cast, > all the other variables are already correct for %x). > My previous attempt put the cast in the wrong place. >=20 > Modified: > head/sys/dev/netmap/netmap_mem2.c >=20 > Modified: head/sys/dev/netmap/netmap_mem2.c > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=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/dev/netmap/netmap_mem2.c Sat Apr 14 16:42:17 2012 = (r234289) > +++ head/sys/dev/netmap/netmap_mem2.c Sat Apr 14 16:44:18 2012 = (r234290) > @@ -161,11 +161,9 @@ netmap_ofstophys(vm_offset_t offset) > return p[i]->lut[offset / p[i]->_objsize].paddr + > offset % p[i]->_objsize; > } > - D("invalid ofs 0x%jx out of 0x%jx 0x%jx 0x%jx", (uintmax_t)o, > - (uintmax_t)p[0]->_memtotal, > - (uintmax_t)(p[0]->_memtotal + p[1]->_memtotal), > - (uintmax_t)(p[0]->_memtotal + p[1]->_memtotal + > - p[2]->_memtotal)); > + D("invalid ofs 0x%x out of 0x%x 0x%x 0x%x", (u_int)o, > + p[0]->_memtotal, p[0]->_memtotal + p[1]->_memtotal, > + p[0]->_memtotal + p[1]->_memtotal + p[2]->_memtotal); > return 0; // XXX bad address > } As I mentioned before in private email, wouldn't it make more = sense to make `"%x=85", (u_int)o` into `%lx=85`, o because vm_offset_t = is uint32_t on 32-bit archs and uint64_t on 64-bit archs? What's done = above truncates the represented value for 64-bit archs. Thanks! -Garrett= From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 02:38:02 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 36D1C106564A; Sun, 15 Apr 2012 02:38:02 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 21EC48FC0A; Sun, 15 Apr 2012 02:38:02 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3F2c1Fb060786; Sun, 15 Apr 2012 02:38:01 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3F2c1Hh060784; Sun, 15 Apr 2012 02:38:01 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204150238.q3F2c1Hh060784@svn.freebsd.org> From: Adrian Chadd Date: Sun, 15 Apr 2012 02:38: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: r234306 - head/sys/mips/atheros X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 02:38:02 -0000 Author: adrian Date: Sun Apr 15 02:38:01 2012 New Revision: 234306 URL: http://svn.freebsd.org/changeset/base/234306 Log: Fix the mask logic when reading PCI configuration space registers. Modified: head/sys/mips/atheros/ar71xx_pci.c Modified: head/sys/mips/atheros/ar71xx_pci.c ============================================================================== --- head/sys/mips/atheros/ar71xx_pci.c Sun Apr 15 01:40:22 2012 (r234305) +++ head/sys/mips/atheros/ar71xx_pci.c Sun Apr 15 02:38:01 2012 (r234306) @@ -204,8 +204,12 @@ ar71xx_pci_read_config(device_t dev, u_i /* register access is 32-bit aligned */ shift = (reg & 3) * 8; - if (shift) - mask = (1 << shift) - 1; + + /* Create a mask based on the width, post-shift */ + if (bytes == 2) + mask = 0xffff; + else if (bytes == 1) + mask = 0xff; else mask = 0xffffffff; From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 13:01:17 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F20BA1065676; Sun, 15 Apr 2012 13:01:16 +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 547778FC25; Sun, 15 Apr 2012 13:01:16 +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 q3FD1F3R071247; Sun, 15 Apr 2012 15:01:15 +0200 (CEST) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id q3FD1E8i071246; Sun, 15 Apr 2012 15:01:14 +0200 (CEST) (envelope-from marius) Date: Sun, 15 Apr 2012 15:01:14 +0200 From: Marius Strobl To: "Justin T. Gibbs" Message-ID: <20120415130114.GB68446@alchemy.franken.de> References: <201204092241.q39MfJZn081610@svn.freebsd.org> <20120409230949.GB68111@alchemy.franken.de> <20120410114118.GB93449@alchemy.franken.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i Cc: Attilio Rao , svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org, John Baldwin Subject: Re: svn commit: r234074 - in head/sys: amd64/amd64 i386/i386 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 13:01:17 -0000 On Sat, Apr 14, 2012 at 05:05:35PM -0600, Justin T. Gibbs wrote: > > On Apr 10, 2012, at 5:41 AM, Marius Strobl wrote: > > > On Tue, Apr 10, 2012 at 01:03:56AM +0100, Attilio Rao wrote: > >> Il 10 aprile 2012 00:09, Marius Strobl ha scritto: > >>> On Mon, Apr 09, 2012 at 10:41:19PM +0000, Attilio Rao wrote: > >>>> Author: attilio > >>>> Date: Mon Apr ??9 22:41:19 2012 > >>>> New Revision: 234074 > >>>> URL: http://svn.freebsd.org/changeset/base/234074 > >>>> > >>>> Log: > >>>> ?? BSP is not added to the mask of valid target CPUs for interrupts > >>>> ?? in set_apic_interrupt_ids(). Besides, set_apic_interrupts_ids() is not > >>>> ?? called in the !SMP case too. > >>>> ?? Fix this by: > >>>> ?? - Adding the BSP as an interrupt target directly in cpu_startup(). > >>>> ?? - Remove an obsolete optimization where the BSP are skipped in > >>>> ?? ?? set_apic_interrupt_ids(). > >>>> > >>>> ?? Reported by: ?? ?? ?? ??jh > >>>> ?? Reviewed by: ?? ?? ?? ??jhb > >>>> ?? MFC after: ??3 days > >>>> ?? X-MFC: ?? ?? ?? ?? ?? ?? ??r233961 > >>>> ?? Pointy hat to: ?? ?? ??me > >>>> > >>>> Modified: > >>>> ?? head/sys/amd64/amd64/machdep.c > >>>> ?? head/sys/amd64/amd64/mp_machdep.c > >>>> ?? head/sys/i386/i386/machdep.c > >>>> ?? head/sys/i386/i386/mp_machdep.c > >>>> > >>>> Modified: head/sys/amd64/amd64/machdep.c > >>>> ============================================================================== > >>>> --- head/sys/amd64/amd64/machdep.c ?? ??Mon Apr ??9 22:01:43 2012 ?? ?? ?? ??(r234073) > >>>> +++ head/sys/amd64/amd64/machdep.c ?? ??Mon Apr ??9 22:41:19 2012 ?? ?? ?? ??(r234074) > >>>> @@ -295,6 +295,11 @@ cpu_startup(dummy) > >>>> ?? ?? ?? vm_pager_bufferinit(); > >>>> > >>>> ?? ?? ?? cpu_setregs(); > >>>> + > >>>> + ?? ?? /* > >>>> + ?? ?? ??* Add BSP as an interrupt target. > >>>> + ?? ?? ??*/ > >>>> + ?? ?? intr_add_cpu(0); > >>>> ??} > >>> > >>> If I'm not mistaken, intr_add_cpu() is under #ifdef SMP, so it should be > >>> here as well. > >> > >> You are right, sorry, I did forgot to test without SMP. > >> I think we still need intr_add_cpu() on cpu_startup() because of the > >> case smp_disabled = 1. > >> I think the attached patch should make its dirty job, opinion? > > > > I currently fail to see why the latter approach would be necessary, > > i.e. IMO wrapping the intr_add_cpu() calls in cpu_startup() should > > be sufficient. In case the kernel is compiled without SMP support, > > interrupt balancing support isn't available in the first place and > > the BSP is always the only available target (see the UP version of > > intr_next_cpu() at the end of x86/x86/intr_machdep.c), so there's > > no need to add the BSP as a valid target. If an SMP kernel is run > > on a UP machine or with SMP disabled, interrupt balancing support > > is available but the intr_add_cpu() calls in cpu_startup() will add > > the BSP as (the only) target, so everything should be fine. Maybe > > you can elaborate on why you think an SMP kernel with SMP disabled > > needs special handling. > > > > Marius > > While functionally correct, I believe that wrapping intr_add_cpu() > in machdep.c in "SMP ifdefs" is inferior to calling it in all cases. > It invites questions like, "In the UP case, don't we have to ensure > that CPU0 is a valid interrupt target?" This is because casual > visitors to this file don't know that intr_add_cpu() only impacts > interrupt distribution. Of course, this is just an artifact of the > current implementation. #ifdefs should be as close to the implemenation > as possible. This simplifies the task of making future enhancments. > This is why I'd prefer to see these within the body of intr_add_cpu() > than where they are now. > Well, feel free to change the code like that. However, my perspective is that if these #ifdef SMP (which also are just one amongst several in these machdep.c) cause the casual visitors to actually look at the bigger picture than this is a good thing. Doing so probably would have avoided the bugs in r222813 and r233961. Marius From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 13:25:52 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2DF47106564A; Sun, 15 Apr 2012 13:25:52 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 188CD8FC15; Sun, 15 Apr 2012 13:25:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FDPplm085762; Sun, 15 Apr 2012 13:25:51 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FDPpsM085758; Sun, 15 Apr 2012 13:25:51 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201204151325.q3FDPpsM085758@svn.freebsd.org> From: Baptiste Daroussin Date: Sun, 15 Apr 2012 13:25: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: r234310 - head/usr.bin/m4 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 13:25:52 -0000 Author: bapt Date: Sun Apr 15 13:25:51 2012 New Revision: 234310 URL: http://svn.freebsd.org/changeset/base/234310 Log: Improve m4 compatibility with GNU m4 extension ** (exponent) Submitted by: Marc Espie (espie@OpenBSD.org) Approved by: des@ (mentor) Modified: head/usr.bin/m4/eval.c head/usr.bin/m4/extern.h head/usr.bin/m4/main.c Modified: head/usr.bin/m4/eval.c ============================================================================== --- head/usr.bin/m4/eval.c Sun Apr 15 11:10:24 2012 (r234309) +++ head/usr.bin/m4/eval.c Sun Apr 15 13:25:51 2012 (r234310) @@ -269,10 +269,11 @@ expand_builtin(const char *argv[], int a case INCLTYPE: if (argc > 2) if (!doincl(argv[2])) { - if (mimic_gnu) + if (mimic_gnu) { warn("%s at line %lu: include(%s)", CURRENT_NAME, CURRENT_LINE, argv[2]); - else + exit_code = 1; + } else err(1, "%s at line %lu: include(%s)", CURRENT_NAME, CURRENT_LINE, argv[2]); } Modified: head/usr.bin/m4/extern.h ============================================================================== --- head/usr.bin/m4/extern.h Sun Apr 15 11:10:24 2012 (r234309) +++ head/usr.bin/m4/extern.h Sun Apr 15 13:25:51 2012 (r234310) @@ -87,6 +87,7 @@ extern ndptr macro_getbuiltin(const char /* main.c */ extern void outputstr(const char *); extern void do_emit_synchline(void); +extern int exit_code; #define emit_synchline() do { if (synch_lines) do_emit_synchline(); } while(0) /* misc.c */ Modified: head/usr.bin/m4/main.c ============================================================================== --- head/usr.bin/m4/main.c Sun Apr 15 11:10:24 2012 (r234309) +++ head/usr.bin/m4/main.c Sun Apr 15 13:25:51 2012 (r234310) @@ -164,6 +164,8 @@ static void enlarge_stack(void); int main(int, char *[]); +int exit_code = 0; + int main(int argc, char *argv[]) { @@ -282,7 +284,7 @@ main(int argc, char *argv[]) (void) fclose(outfile[0]); } - return 0; + return exit_code; } /* From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 13:39:39 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DF7721065672; Sun, 15 Apr 2012 13:39:39 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C9D6E8FC08; Sun, 15 Apr 2012 13:39:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FDddYu086276; Sun, 15 Apr 2012 13:39:39 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FDddej086273; Sun, 15 Apr 2012 13:39:39 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201204151339.q3FDddej086273@svn.freebsd.org> From: Dag-Erling Smorgrav Date: Sun, 15 Apr 2012 13:39: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: r234311 - head/usr.bin/unzip X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 13:39:40 -0000 Author: des Date: Sun Apr 15 13:39:39 2012 New Revision: 234311 URL: http://svn.freebsd.org/changeset/base/234311 Log: Correct my name in the copyright statement. Modified: head/usr.bin/unzip/unzip.1 head/usr.bin/unzip/unzip.c Modified: head/usr.bin/unzip/unzip.1 ============================================================================== --- head/usr.bin/unzip/unzip.1 Sun Apr 15 13:25:51 2012 (r234310) +++ head/usr.bin/unzip/unzip.1 Sun Apr 15 13:39:39 2012 (r234311) @@ -1,5 +1,5 @@ .\"- -.\" Copyright (c) 2007-2008 Dag-Erling Coïdan Smørgrav +.\" Copyright (c) 2007-2008 Dag-Erling Smørgrav .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without Modified: head/usr.bin/unzip/unzip.c ============================================================================== --- head/usr.bin/unzip/unzip.c Sun Apr 15 13:25:51 2012 (r234310) +++ head/usr.bin/unzip/unzip.c Sun Apr 15 13:39:39 2012 (r234311) @@ -1,6 +1,6 @@ /*- * Copyright (c) 2009 Joerg Sonnenberger - * Copyright (c) 2007-2008 Dag-Erling Coïdan Smørgrav + * Copyright (c) 2007-2008 Dag-Erling Smørgrav * All rights reserved. * * Redistribution and use in source and binary forms, with or without From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 15:13:30 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 51444106564A; Sun, 15 Apr 2012 15:13:30 +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 323118FC12; Sun, 15 Apr 2012 15:13:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FFDUfh089655; Sun, 15 Apr 2012 15:13:30 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FFDTWl089652; Sun, 15 Apr 2012 15:13:29 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204151513.q3FFDTWl089652@svn.freebsd.org> From: Edward Tomasz Napierala Date: Sun, 15 Apr 2012 15:13: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: r234312 - head/sbin/growfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 15:13:30 -0000 Author: trasz Date: Sun Apr 15 15:13:29 2012 New Revision: 234312 URL: http://svn.freebsd.org/changeset/base/234312 Log: Remove FSIRAND and FSMAXSWAP ifdefs, removing code unconditionally. Reviewed by: kib, mckusick Sponsored by: The FreeBSD Foundation Modified: head/sbin/growfs/debug.c head/sbin/growfs/growfs.c Modified: head/sbin/growfs/debug.c ============================================================================== --- head/sbin/growfs/debug.c Sun Apr 15 13:39:39 2012 (r234311) +++ head/sbin/growfs/debug.c Sun Apr 15 15:13:29 2012 (r234312) @@ -127,9 +127,7 @@ dbg_dump_hex(struct fs *sb, const char * void dbg_dump_fs(struct fs *sb, const char *comment) { -#ifdef FSMAXSNAP int j; -#endif /* FSMAXSNAP */ if (!dbg_log) return; @@ -299,7 +297,6 @@ dbg_dump_fs(struct fs *sb, const char *c fprintf(dbg_log, "pendinginodes int32_t 0x%08x\n", sb->fs_pendinginodes); -#ifdef FSMAXSNAP for (j = 0; j < FSMAXSNAP; j++) { fprintf(dbg_log, "snapinum int32_t[%2d] 0x%08x\n", j, sb->fs_snapinum[j]); @@ -307,7 +304,6 @@ dbg_dump_fs(struct fs *sb, const char *c break; } } -#endif /* FSMAXSNAP */ fprintf(dbg_log, "avgfilesize int32_t 0x%08x\n", sb->fs_avgfilesize); fprintf(dbg_log, "avgfpdir int32_t 0x%08x\n", Modified: head/sbin/growfs/growfs.c ============================================================================== --- head/sbin/growfs/growfs.c Sun Apr 15 13:39:39 2012 (r234311) +++ head/sbin/growfs/growfs.c Sun Apr 15 15:13:29 2012 (r234312) @@ -130,7 +130,6 @@ growfs(int fsi, int fso, unsigned int Nf uint cylno; int i, j, width; char tmpbuf[100]; -#ifdef FSIRAND static int randinit=0; DBG_ENTER; @@ -139,11 +138,6 @@ growfs(int fsi, int fso, unsigned int Nf randinit = 1; srandomdev(); } -#else /* not FSIRAND */ - - DBG_ENTER; - -#endif /* FSIRAND */ time(&modtime); /* @@ -319,11 +313,9 @@ initcg(int cylno, time_t modtime, int fs static caddr_t iobuf; long blkno, start; ufs2_daddr_t i, cbase, dmax; -#ifdef FSIRAND struct ufs1_dinode *dp1; -#endif struct csum *cs; - uint d, dupper, dlower; + uint j, d, dupper, dlower; if (iobuf == NULL && (iobuf = malloc(sblock.fs_bsize * 3)) == NULL) errx(37, "panic: cannot allocate I/O buffer"); @@ -399,13 +391,11 @@ initcg(int cylno, time_t modtime, int fs bzero(iobuf, sblock.fs_bsize); for (i = 0; i < sblock.fs_ipg / INOPF(&sblock); i += sblock.fs_frag) { -#ifdef FSIRAND dp1 = (struct ufs1_dinode *)(void *)iobuf; for (j = 0; j < INOPB(&sblock); j++) { dp1->di_gen = random(); dp1++; } -#endif wtfs(fsbtodb(&sblock, cgimin(&sblock, cylno) + i), sblock.fs_bsize, iobuf, fso, Nflag); } @@ -1303,9 +1293,7 @@ main(int argc, char **argv) int i, fsi, fso; u_int32_t p_size; char reply[5]; -#ifdef FSMAXSNAP int j; -#endif /* FSMAXSNAP */ DBG_ENTER; @@ -1442,8 +1430,6 @@ main(int argc, char **argv) (intmax_t)osblock.fs_size, (intmax_t)sblock.fs_size); } - -#ifdef FSMAXSNAP /* * Check if we find an active snapshot. */ @@ -1458,7 +1444,6 @@ main(int argc, char **argv) break; } } -#endif if (ExpertFlag == 0 && Nflag == 0) { printf("We strongly recommend you to make a backup " From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 15:13:36 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D44A11065780; Sun, 15 Apr 2012 15:13:36 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B0D6D8FC08; Sun, 15 Apr 2012 15:13:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FFDah1089697; Sun, 15 Apr 2012 15:13:36 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FFDaTu089692; Sun, 15 Apr 2012 15:13:36 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201204151513.q3FFDaTu089692@svn.freebsd.org> From: Baptiste Daroussin Date: Sun, 15 Apr 2012 15:13:36 +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: r234313 - in head/usr.sbin: . pkg X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 15:13:37 -0000 Author: bapt Date: Sun Apr 15 15:13:36 2012 New Revision: 234313 URL: http://svn.freebsd.org/changeset/base/234313 Log: add usr.sbin/pkg which is a bootstrap tool for pkgng. it respects PACKAGESITE, PACKAGEROOT, and a new environment variable ABI (if a user want to use a different API from the base one for its packages) it has no man page on purpose to avoid hidding the pkg(8) man page from the pkgng package. for now uses pkgbeta.FreeBSD.org as default mirror to find its package it respects MK_PKGTOOLS Approved by: des (mentor) Added: head/usr.sbin/pkg/ head/usr.sbin/pkg/Makefile (contents, props changed) head/usr.sbin/pkg/elf_tables.h (contents, props changed) head/usr.sbin/pkg/pkg.c (contents, props changed) Modified: head/usr.sbin/Makefile Modified: head/usr.sbin/Makefile ============================================================================== --- head/usr.sbin/Makefile Sun Apr 15 15:13:29 2012 (r234312) +++ head/usr.sbin/Makefile Sun Apr 15 15:13:36 2012 (r234313) @@ -256,6 +256,7 @@ SUBDIR+= ftp-proxy .if ${MK_PKGTOOLS} != "no" SUBDIR+= pkg_install +SUBDIR+= pkg .endif # XXX MK_TOOLCHAIN? Added: head/usr.sbin/pkg/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.sbin/pkg/Makefile Sun Apr 15 15:13:36 2012 (r234313) @@ -0,0 +1,9 @@ +# $FreeBSD$ + +PROG= pkg +SRC= pkg.c + +NO_MAN= yes +LDADD= -larchive -lelf -lfetch + +.include Added: head/usr.sbin/pkg/elf_tables.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.sbin/pkg/elf_tables.h Sun Apr 15 15:13:36 2012 (r234313) @@ -0,0 +1,79 @@ +/*- + * Copyright (c) 2012 Olivier Houchard + * Copyright (c) 2012 Baptiste Daroussin + * 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$ + */ + +#ifndef ELF_TABLES_H_ +#define ELF_TABLES_H_ +struct _elf_corres { + int elf_nb; + const char *string; +}; + +struct _elf_corres mach_corres[] = { + { EM_386, "x86" }, + { EM_AMD64, "x86" }, + { EM_ARM, "arm" }, + { EM_MIPS, "mips" }, + { EM_PPC, "powerpc" }, + { EM_PPC64, "powerpc" }, + { EM_SPARCV9, "sparc64" }, + { EM_IA_64, "ia64" }, + { -1, NULL }, +}; + +struct _elf_corres wordsize_corres[] = { + { ELFCLASS32, "32" }, + { ELFCLASS64, "64" }, + { -1, NULL}, +}; + +struct _elf_corres endian_corres[] = { + { ELFDATA2MSB, "eb" }, + { ELFDATA2LSB, "el" }, + { -1, NULL} +}; + +struct _elf_corres os_corres[] = { + { ELFOSABI_FREEBSD, "freebsd" }, + { -1, NULL } +}; + +#define EF_MIPS_ABI 0x0000F000 +#define E_MIPS_ABI_O32 0x00001000 +#define E_MIPS_ABI_N32 0x00000020 + +#define EF_ARM_NEW_ABI 0x80 +#define EF_ARM_OLD_ABI 0x100 + +#define EF_ARM_SOFT_FLOAT 0x200 +#define EF_ARM_VFP_FLOAT 0x400 + +#define NT_VERSION 1 +#define NT_ARCH 2 + +#endif /* ELF_TABLES_H_ */ Added: head/usr.sbin/pkg/pkg.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.sbin/pkg/pkg.c Sun Apr 15 15:13:36 2012 (r234313) @@ -0,0 +1,383 @@ +/*- + * Copyright (c) 2012 Baptiste Daroussin + * 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 +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "elf_tables.h" + +#define _LOCALBASE "/usr/local" +#define _PKGS_URL "http://pkgbeta.FreeBSD.org" +#define _DEFAULT_TMP "/tmp" + +static const char * +elf_corres_to_string(struct _elf_corres* m, int e) +{ + int i = 0; + + for (i = 0; m[i].string != NULL; i++) + if (m[i].elf_nb == e) + return (m[i].string); + + return ("unknown"); +} + +static int +pkg_get_myabi(char *dest, size_t sz) +{ + Elf *elf; + GElf_Ehdr elfhdr; + GElf_Shdr shdr; + Elf_Data *data; + Elf_Note note; + Elf_Scn *scn; + char *src, *osname; + const char *abi; + int fd, i, ret; + uint32_t version; + + version = 0; + ret = 0; + scn = NULL; + abi = NULL; + + if (elf_version(EV_CURRENT) == EV_NONE) { + warnx("ELF library initialization failed: %s", elf_errmsg(-1)); + return -1; + } + + if ((fd = open("/bin/sh", O_RDONLY)) < 0) { + warn("open()"); + return -1; + } + + if ((elf = elf_begin(fd, ELF_C_READ, NULL)) == NULL) { + ret = -1; + warnx("elf_begin() failed: %s.", elf_errmsg(-1)); + goto cleanup; + } + + if (gelf_getehdr(elf, &elfhdr) == NULL) { + ret = -1; + warn("getehdr() failed: %s.", elf_errmsg(-1)); + goto cleanup; + } + + while ((scn = elf_nextscn(elf, scn)) != NULL) { + if (gelf_getshdr(scn, &shdr) != &shdr) { + ret = -1; + warn("getshdr() failed: %s.", elf_errmsg(-1)); + goto cleanup; + } + + if (shdr.sh_type == SHT_NOTE) + break; + } + + if (scn == NULL) { + ret = -1; + warn("fail to get the note section"); + goto cleanup; + } + + data = elf_getdata(scn, NULL); + src = data->d_buf; + while (1) { + memcpy(¬e, src, sizeof(Elf_Note)); + src += sizeof(Elf_Note); + if (note.n_type == NT_VERSION) + break; + src += note.n_namesz + note.n_descsz; + } + osname = src; + src += note.n_namesz; + if (elfhdr.e_ident[EI_DATA] == ELFDATA2MSB) + version = be32dec(src); + else + version = le32dec(src); + + for (i = 0; osname[i] != '\0'; i++) + osname[i] = (char)tolower(osname[i]); + + snprintf(dest, sz, "%s:%d:%s:%s", + osname, + version / 100000, + elf_corres_to_string(mach_corres, (int) elfhdr.e_machine), + elf_corres_to_string(wordsize_corres, + (int)elfhdr.e_ident[EI_CLASS])); + + switch (elfhdr.e_machine) { + case EM_ARM: + snprintf(dest + strlen(dest), sz - strlen(dest), + ":%s:%s:%s", + elf_corres_to_string(endian_corres, + (int) elfhdr.e_ident[EI_DATA]), + (elfhdr.e_flags & EF_ARM_NEW_ABI) > 0 ? + "eabi" : "oabi", + (elfhdr.e_flags & EF_ARM_VFP_FLOAT) > 0 ? + "softfp" : "vfp"); + break; + case EM_MIPS: + /* + * this is taken from binutils sources: + * include/elf/mips.h + * mapping is figured out from binutils: + * gas/config/tc-mips.c + */ + switch (elfhdr.e_flags & EF_MIPS_ABI) { + case E_MIPS_ABI_O32: + abi = "o32"; + break; + case E_MIPS_ABI_N32: + abi = "n32"; + break; + default: + if (elfhdr.e_ident[EI_DATA] == + ELFCLASS32) + abi = "o32"; + else if (elfhdr.e_ident[EI_DATA] == + ELFCLASS64) + abi = "n64"; + break; + } + snprintf(dest + strlen(dest), sz - strlen(dest), + ":%s:%s", + elf_corres_to_string(endian_corres, + (int) elfhdr.e_ident[EI_DATA]), + abi); + break; + } + +cleanup: + if (elf != NULL) + elf_end(elf); + + close(fd); + return (ret); +} + +static int +extract_pkg_static(int fd, char *p, int sz) +{ + struct archive *a; + struct archive_entry *ae; + char *end; + int ret, r; + + ret = 0; + a = archive_read_new(); + archive_read_support_compression_all(a); + archive_read_support_format_tar(a); + + lseek(fd, 0, 0); + + if (archive_read_open_fd(a, fd, 4096) != ARCHIVE_OK) { + warnx("archive_read_open_fd: %s", + archive_error_string(a)); + ret = -1; + goto cleanup; + } + + ae = NULL; + while ((r = archive_read_next_header(a, &ae)) == ARCHIVE_OK) { + end = strrchr(archive_entry_pathname(ae), '/'); + if (end == NULL) + continue; + + if (strcmp(end, "/pkg-static") == 0) { + r = archive_read_extract(a, ae, + ARCHIVE_EXTRACT_OWNER |ARCHIVE_EXTRACT_PERM| + ARCHIVE_EXTRACT_TIME |ARCHIVE_EXTRACT_ACL | + ARCHIVE_EXTRACT_FFLAGS|ARCHIVE_EXTRACT_XATTR); + snprintf(p, sz, archive_entry_pathname(ae)); + break; + } + } + + if (r != ARCHIVE_OK) { + warnx("fail to extract pkg-static"); + ret = -1; + } + +cleanup: + archive_read_finish(a); + return ret; + +} + +static int +install_pkg_static(char *path, char *pkgpath) +{ + int pstat; + pid_t pid; + + switch ((pid = fork())) { + case -1: + return (-1); + case 0: + execl(path, "pkg-static", "add", pkgpath, (char *)NULL); + _exit(1); /* NOT REACHED */ + default: + break; + } + + while (waitpid(pid, &pstat, 0) == -1) { + if (errno != EINTR) + return (-1); + } + + return (WEXITSTATUS(pstat)); +} + +static int +bootstrap_pkg(void) +{ + struct url_stat st; + FILE *remote; + time_t begin_dl; + time_t now; + time_t last = 0; + char url[MAXPATHLEN]; + char abi[BUFSIZ]; + char tmppkg[MAXPATHLEN]; + char buf[10240]; + char pkgstatic[MAXPATHLEN]; + int fd, retry, ret; + off_t done, r; + + done = 0; + ret = 0; + retry = 3; + remote = NULL; + + printf("Bootstraping pkg please wait\n"); + + if (pkg_get_myabi(abi, MAXPATHLEN) != 0) { + warnx("fail to determine my abi"); + return -1; + } + + if (getenv("PACKAGESITE") != NULL) { + snprintf(url, MAXPATHLEN, "%s/pkg.txz", + getenv("PACKAGESITE")); + } else { + snprintf(url, MAXPATHLEN, "%s/%s/latest/Latest/pkg.txz", + getenv("PACKAGEROOT") ? getenv("PACKAGEROOT") : _PKGS_URL, + getenv("ABI") ? getenv("ABI") : abi); + } + + snprintf(tmppkg, MAXPATHLEN, "%s/pkg.txz.XXXXXX", + getenv("TMPDIR") ? getenv("TMPDIR") : "/tmp"); + + if ((fd = mkstemp(tmppkg)) == -1) { + warn("mkstemp()"); + return -1; + } + + while (remote == NULL) { + remote = fetchXGetURL(url, &st, ""); + if (remote == NULL) { + --retry; + if (retry == 0) { + warnx("Error fetching %s: %s", url, + fetchLastErrString); + ret = 1; + goto cleanup; + } + sleep(1); + } + } + + begin_dl = time(NULL); + while (done < st.size) { + if ((r = fread(buf, 1, sizeof(buf), remote)) < 1) + break; + + if (write(fd, buf, r) != r) { + warn("write()"); + ret = -1; + goto cleanup; + } + + done += r; + now = time(NULL); + if (now > last || done == st.size) { + last = now; + } + } + + if (ferror(remote)) { + warnx("Error fetching %s: %s", url, + fetchLastErrString); + ret = 1; + goto cleanup; + } + + if ((ret = extract_pkg_static(fd, pkgstatic, MAXPATHLEN)) == 0) + ret = install_pkg_static(pkgstatic, tmppkg); + +cleanup: + close(fd); + unlink(tmppkg); + + return 0; +} + +int +main(__unused int argc, char * argv[]) +{ + char pkgpath[MAXPATHLEN]; + + snprintf(pkgpath, MAXPATHLEN, "%s/sbin/pkg", + getenv("LOCALBASE") ? getenv("LOCALBASE"): _LOCALBASE); + + if (access(pkgpath, X_OK) == -1) + bootstrap_pkg(); + + execv(pkgpath, argv); + + return (EXIT_SUCCESS); +} From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 15:15:16 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D58A31065694; Sun, 15 Apr 2012 15:15:16 +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 C0DA28FC1F; Sun, 15 Apr 2012 15:15:16 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FFFGfs089797; Sun, 15 Apr 2012 15:15:16 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FFFGQM089795; Sun, 15 Apr 2012 15:15:16 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204151515.q3FFFGQM089795@svn.freebsd.org> From: Edward Tomasz Napierala Date: Sun, 15 Apr 2012 15:15: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: r234314 - head/sbin/growfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 15:15:16 -0000 Author: trasz Date: Sun Apr 15 15:15:16 2012 New Revision: 234314 URL: http://svn.freebsd.org/changeset/base/234314 Log: Style. Modified: head/sbin/growfs/growfs.c Modified: head/sbin/growfs/growfs.c ============================================================================== --- head/sbin/growfs/growfs.c Sun Apr 15 15:13:36 2012 (r234313) +++ head/sbin/growfs/growfs.c Sun Apr 15 15:15:16 2012 (r234314) @@ -130,7 +130,7 @@ growfs(int fsi, int fso, unsigned int Nf uint cylno; int i, j, width; char tmpbuf[100]; - static int randinit=0; + static int randinit = 0; DBG_ENTER; @@ -177,7 +177,7 @@ growfs(int fsi, int fso, unsigned int Nf /* * Dump out summary information about file system. */ -# define B2MBFACTOR (1 / (1024.0 * 1024.0)) +#define B2MBFACTOR (1 / (1024.0 * 1024.0)) printf("growfs: %.1fMB (%jd sectors) block size %d, fragment size %d\n", (float)sblock.fs_size * sblock.fs_fsize * B2MBFACTOR, (intmax_t)fsbtodb(&sblock, sblock.fs_size), sblock.fs_bsize, @@ -187,7 +187,7 @@ growfs(int fsi, int fso, unsigned int Nf sblock.fs_fpg / sblock.fs_frag, sblock.fs_ipg); if (sblock.fs_flags & FS_DOSOFTDEP) printf("\twith soft updates\n"); -# undef B2MBFACTOR +#undef B2MBFACTOR /* * Now build the cylinders group blocks and @@ -499,7 +499,7 @@ frag_adjust(ufs2_daddr_t frag, int sign) DBG_ENTER; - fragsize=0; + fragsize = 0; /* * Here frag only needs to point to any fragment in the block we want * to examine. @@ -579,7 +579,7 @@ updjcg(int cylno, time_t modtime, int fs if (cgbase(&osblock, cylno + 1) == osblock.fs_size) { if (sblock.fs_magic == FS_UFS1_MAGIC) - acg.cg_old_ncyl=sblock.fs_old_cpg; + acg.cg_old_ncyl = sblock.fs_old_cpg; wtfs(fsbtodb(&sblock, cgtod(&sblock, cylno)), (size_t)sblock.fs_cgsize, (void *)&acg, fso, Nflag); From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 16:00:33 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0519A1065670; Sun, 15 Apr 2012 16:00:33 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E35368FC08; Sun, 15 Apr 2012 16:00:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FG0Wpb091443; Sun, 15 Apr 2012 16:00:32 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FG0WuO091441; Sun, 15 Apr 2012 16:00:32 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201204151600.q3FG0WuO091441@svn.freebsd.org> From: Baptiste Daroussin Date: Sun, 15 Apr 2012 16:00: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: r234315 - head/usr.sbin/pkg X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 16:00:33 -0000 Author: bapt Date: Sun Apr 15 16:00:32 2012 New Revision: 234315 URL: http://svn.freebsd.org/changeset/base/234315 Log: Do not do double initialisation style(9) says for (;;) not while (1) Reported by: culot Approved by: des Modified: head/usr.sbin/pkg/pkg.c Modified: head/usr.sbin/pkg/pkg.c ============================================================================== --- head/usr.sbin/pkg/pkg.c Sun Apr 15 15:15:16 2012 (r234314) +++ head/usr.sbin/pkg/pkg.c Sun Apr 15 16:00:32 2012 (r234315) @@ -56,7 +56,7 @@ __FBSDID("$FreeBSD$"); static const char * elf_corres_to_string(struct _elf_corres* m, int e) { - int i = 0; + int i; for (i = 0; m[i].string != NULL; i++) if (m[i].elf_nb == e) @@ -125,7 +125,7 @@ pkg_get_myabi(char *dest, size_t sz) data = elf_getdata(scn, NULL); src = data->d_buf; - while (1) { + for (;;) { memcpy(¬e, src, sizeof(Elf_Note)); src += sizeof(Elf_Note); if (note.n_type == NT_VERSION) From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 16:52:49 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4EF74106566B; Sun, 15 Apr 2012 16:52:49 +0000 (UTC) (envelope-from netchild@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 36CAC8FC0A; Sun, 15 Apr 2012 16:52:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FGqnQq093277; Sun, 15 Apr 2012 16:52:49 GMT (envelope-from netchild@svn.freebsd.org) Received: (from netchild@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FGqns5093271; Sun, 15 Apr 2012 16:52:49 GMT (envelope-from netchild@svn.freebsd.org) Message-Id: <201204151652.q3FGqns5093271@svn.freebsd.org> From: Alexander Leidinger Date: Sun, 15 Apr 2012 16:52:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234316 - in stable/9/sys: amd64/linux32 i386/conf i386/linux kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 16:52:49 -0000 Author: netchild Date: Sun Apr 15 16:52:48 2012 New Revision: 234316 URL: http://svn.freebsd.org/changeset/base/234316 Log: MFC r232799: - add comments to syscalls.master and linux(32)_dummy about which linux kernel version introduced the sysctl (based upon a linux man-page) - add comments to syscalls.master regarding some names of sysctls which are different than the linux-names (based upon the linux unistd.h) - add some dummy sysctls - name an unimplemented sysctl Modified: stable/9/sys/amd64/linux32/linux32_dummy.c stable/9/sys/amd64/linux32/syscalls.master stable/9/sys/i386/linux/linux_dummy.c stable/9/sys/i386/linux/syscalls.master Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/amd64/linux32/linux32_dummy.c ============================================================================== --- stable/9/sys/amd64/linux32/linux32_dummy.c Sun Apr 15 16:00:32 2012 (r234315) +++ stable/9/sys/amd64/linux32/linux32_dummy.c Sun Apr 15 16:52:48 2012 (r234316) @@ -82,22 +82,69 @@ DUMMY(mq_notify); DUMMY(mq_getsetattr); DUMMY(kexec_load); DUMMY(waitid); +/* linux 2.6.11: */ DUMMY(add_key); DUMMY(request_key); DUMMY(keyctl); +/* linux 2.6.13: */ DUMMY(ioprio_set); DUMMY(ioprio_get); DUMMY(inotify_init); DUMMY(inotify_add_watch); DUMMY(inotify_rm_watch); +/* linux 2.6.16: */ DUMMY(migrate_pages); DUMMY(pselect6); DUMMY(ppoll); DUMMY(unshare); +/* linux 2.6.17: */ DUMMY(splice); DUMMY(sync_file_range); DUMMY(tee); DUMMY(vmsplice); +/* linux 2.6.18: */ +DUMMY(move_pages); +/* linux 2.6.19: */ +DUMMY(getcpu); +DUMMY(epoll_pwait); +/* linux 2.6.22: */ +DUMMY(utimensat); +DUMMY(signalfd); +DUMMY(timerfd_create); +DUMMY(eventfd); +/* linux 2.6.23: */ +DUMMY(fallocate); +/* linux 2.6.25: */ +DUMMY(timerfd_settime); +DUMMY(timerfd_gettime); +/* linux 2.6.27: */ +DUMMY(signalfd4); +DUMMY(eventfd2); +DUMMY(epoll_create1); +DUMMY(dup3); +DUMMY(pipe2); +DUMMY(inotify_init1); +/* linux 2.6.30: */ +DUMMY(preadv); +DUMMY(pwritev); +/* linux 2.6.31: */ +DUMMY(rt_tsigqueueinfo); +DUMMY(perf_event_open); +/* linux 2.6.33: */ +DUMMY(recvmmsg); +DUMMY(fanotify_init); +DUMMY(fanotify_mark); +/* linux 2.6.36: */ +DUMMY(prlimit64); +/* later: */ +DUMMY(name_to_handle_at); +DUMMY(open_by_handle_at); +DUMMY(clock_adjtime); +DUMMY(syncfs); +DUMMY(sendmmsg); +DUMMY(setns); +DUMMY(process_vm_readv); +DUMMY(process_vm_writev); #define DUMMY_XATTR(s) \ int \ Modified: stable/9/sys/amd64/linux32/syscalls.master ============================================================================== --- stable/9/sys/amd64/linux32/syscalls.master Sun Apr 15 16:00:32 2012 (r234315) +++ stable/9/sys/amd64/linux32/syscalls.master Sun Apr 15 16:52:48 2012 (r234316) @@ -157,6 +157,7 @@ 82 AUE_SELECT STD { int linux_old_select( \ struct l_old_select_argv *ptr); } 83 AUE_SYMLINK STD { int linux_symlink(char *path, char *to); } +; 84: oldlstat 84 AUE_LSTAT STD { int linux_lstat(char *path, struct linux_lstat *up); } 85 AUE_READLINK STD { int linux_readlink(char *name, char *buf, \ l_int count); } @@ -164,8 +165,10 @@ 87 AUE_SWAPON NOPROTO { int swapon(char *name); } 88 AUE_REBOOT STD { int linux_reboot(l_int magic1, \ l_int magic2, l_uint cmd, void *arg); } +; 89: old_readdir 89 AUE_GETDIRENTRIES STD { int linux_readdir(l_uint fd, \ struct l_dirent *dent, l_uint count); } +; 90: old_mmap 90 AUE_MMAP STD { int linux_mmap(struct l_mmap_argv *ptr); } 91 AUE_MUNMAP NOPROTO { int munmap(caddr_t addr, int len); } 92 AUE_TRUNCATE STD { int linux_truncate(char *path, \ @@ -197,6 +200,7 @@ struct l_newstat *buf); } 108 AUE_FSTAT STD { int linux_newfstat(l_uint fd, \ struct l_newstat *buf); } +; 109: olduname 109 AUE_NULL STD { int linux_uname(void); } 110 AUE_NULL STD { int linux_iopl(l_ulong level); } 111 AUE_NULL STD { int linux_vhangup(void); } @@ -244,6 +248,7 @@ l_uint whence); } 141 AUE_GETDIRENTRIES STD { int linux_getdents(l_uint fd, void *dent, \ l_uint count); } +; 142: newselect 142 AUE_SELECT STD { int linux_select(l_int nfds, \ l_fd_set *readfds, l_fd_set *writefds, \ l_fd_set *exceptfds, \ @@ -336,6 +341,7 @@ 188 AUE_GETPMSG UNIMPL getpmsg 189 AUE_PUTPMSG UNIMPL putpmsg 190 AUE_VFORK STD { int linux_vfork(void); } +; 191: ugetrlimit 191 AUE_GETRLIMIT STD { int linux_getrlimit(l_uint resource, \ struct l_rlimit *rlim); } 192 AUE_MMAP STD { int linux_mmap2(l_ulong addr, l_ulong len, \ @@ -447,10 +453,11 @@ 272 AUE_NULL STD { int linux_fadvise64_64(int fd, \ l_loff_t offset, l_loff_t len, \ int advice); } -273 AUE_NULL UNIMPL +273 AUE_NULL UNIMPL vserver 274 AUE_NULL STD { int linux_mbind(void); } 275 AUE_NULL STD { int linux_get_mempolicy(void); } 276 AUE_NULL STD { int linux_set_mempolicy(void); } +; linux 2.6.6: 277 AUE_NULL STD { int linux_mq_open(void); } 278 AUE_NULL STD { int linux_mq_unlink(void); } 279 AUE_NULL STD { int linux_mq_timedsend(void); } @@ -460,14 +467,17 @@ 283 AUE_NULL STD { int linux_kexec_load(void); } 284 AUE_NULL STD { int linux_waitid(void); } 285 AUE_NULL UNIMPL +; linux 2.6.11: 286 AUE_NULL STD { int linux_add_key(void); } 287 AUE_NULL STD { int linux_request_key(void); } 288 AUE_NULL STD { int linux_keyctl(void); } +; linux 2.6.13: 289 AUE_NULL STD { int linux_ioprio_set(void); } 290 AUE_NULL STD { int linux_ioprio_get(void); } 291 AUE_NULL STD { int linux_inotify_init(void); } 292 AUE_NULL STD { int linux_inotify_add_watch(void); } 293 AUE_NULL STD { int linux_inotify_rm_watch(void); } +; linux 2.6.16: 294 AUE_NULL STD { int linux_migrate_pages(void); } 295 AUE_OPEN_RWTC STD { int linux_openat(l_int dfd, const char *filename, \ l_int flags, l_int mode); } @@ -497,6 +507,7 @@ 308 AUE_NULL STD { int linux_pselect6(void); } 309 AUE_NULL STD { int linux_ppoll(void); } 310 AUE_NULL STD { int linux_unshare(void); } +; linux 2.6.17: 311 AUE_NULL STD { int linux_set_robust_list(struct linux_robust_list_head *head, \ l_size_t len); } 312 AUE_NULL STD { int linux_get_robust_list(l_int pid, struct linux_robust_list_head *head, \ @@ -505,3 +516,46 @@ 314 AUE_NULL STD { int linux_sync_file_range(void); } 315 AUE_NULL STD { int linux_tee(void); } 316 AUE_NULL STD { int linux_vmsplice(void); } +; linux 2.6.18: +317 AUE_NULL STD { int linux_move_pages(void); } +; linux 2.6.19: +318 AUE_NULL STD { int linux_getcpu(void); } +319 AUE_NULL STD { int linux_epoll_pwait(void); } +; linux 2.6.22: +320 AUE_NULL STD { int linux_utimensat(void); } +321 AUE_NULL STD { int linux_signalfd(void); } +322 AUE_NULL STD { int linux_timerfd_create(void); } +323 AUE_NULL STD { int linux_eventfd(void); } +; linux 2.6.23: +324 AUE_NULL STD { int linux_fallocate(void); } +; linux 2.6.25: +325 AUE_NULL STD { int linux_timerfd_settime(void); } +326 AUE_NULL STD { int linux_timerfd_gettime(void); } +; linux 2.6.27: +327 AUE_NULL STD { int linux_signalfd4(void); } +328 AUE_NULL STD { int linux_eventfd2(void); } +329 AUE_NULL STD { int linux_epoll_create1(void); } +330 AUE_NULL STD { int linux_dup3(void); } +331 AUE_NULL STD { int linux_pipe2(void); } +332 AUE_NULL STD { int linux_inotify_init1(void); } +; linux 2.6.30: +333 AUE_NULL STD { int linux_preadv(void); } +334 AUE_NULL STD { int linux_pwritev(void); } +; linux 2.6.31: +335 AUE_NULL STD { int linux_rt_tsigqueueinfo(void); } +336 AUE_NULL STD { int linux_perf_event_open(void); } +; linux 2.6.33: +337 AUE_NULL STD { int linux_recvmmsg(void); } +338 AUE_NULL STD { int linux_fanotify_init(void); } +339 AUE_NULL STD { int linux_fanotify_mark(void); } +; linux 2.6.36: +340 AUE_NULL STD { int linux_prlimit64(void); } +; later: +341 AUE_NULL STD { int linux_name_to_handle_at(void); } +342 AUE_NULL STD { int linux_open_by_handle_at(void); } +343 AUE_NULL STD { int linux_clock_adjtime(void); } +344 AUE_NULL STD { int linux_syncfs(void); } +345 AUE_NULL STD { int linux_sendmmsg(void); } +346 AUE_NULL STD { int linux_setns(void); } +347 AUE_NULL STD { int linux_process_vm_readv(void); } +348 AUE_NULL STD { int linux_process_vm_writev(void); } Modified: stable/9/sys/i386/linux/linux_dummy.c ============================================================================== --- stable/9/sys/i386/linux/linux_dummy.c Sun Apr 15 16:00:32 2012 (r234315) +++ stable/9/sys/i386/linux/linux_dummy.c Sun Apr 15 16:52:48 2012 (r234316) @@ -73,22 +73,69 @@ DUMMY(get_mempolicy); DUMMY(set_mempolicy); DUMMY(kexec_load); DUMMY(waitid); +/* linux 2.6.11: */ DUMMY(add_key); DUMMY(request_key); DUMMY(keyctl); +/* linux 2.6.13: */ DUMMY(ioprio_set); DUMMY(ioprio_get); DUMMY(inotify_init); DUMMY(inotify_add_watch); DUMMY(inotify_rm_watch); +/* linux 2.6.16: */ DUMMY(migrate_pages); DUMMY(pselect6); DUMMY(ppoll); DUMMY(unshare); +/* linux 2.6.17: */ DUMMY(splice); DUMMY(sync_file_range); DUMMY(tee); DUMMY(vmsplice); +/* linux 2.6.18: */ +DUMMY(move_pages); +/* linux 2.6.19: */ +DUMMY(getcpu); +DUMMY(epoll_pwait); +/* linux 2.6.22: */ +DUMMY(utimensat); +DUMMY(signalfd); +DUMMY(timerfd_create); +DUMMY(eventfd); +/* linux 2.6.23: */ +DUMMY(fallocate); +/* linux 2.6.25: */ +DUMMY(timerfd_settime); +DUMMY(timerfd_gettime); +/* linux 2.6.27: */ +DUMMY(signalfd4); +DUMMY(eventfd2); +DUMMY(epoll_create1); +DUMMY(dup3); +DUMMY(pipe2); +DUMMY(inotify_init1); +/* linux 2.6.30: */ +DUMMY(preadv); +DUMMY(pwritev); +/* linux 2.6.31 */ +DUMMY(rt_tsigqueueinfo); +DUMMY(perf_event_open); +/* linux 2.6.33: */ +DUMMY(recvmmsg); +DUMMY(fanotify_init); +DUMMY(fanotify_mark); +/* linux 2.6.36: */ +DUMMY(prlimit64); +/* later: */ +DUMMY(name_to_handle_at); +DUMMY(open_by_handle_at); +DUMMY(clock_adjtime); +DUMMY(syncfs); +DUMMY(sendmmsg); +DUMMY(setns); +DUMMY(process_vm_readv); +DUMMY(process_vm_writev); #define DUMMY_XATTR(s) \ int \ Modified: stable/9/sys/i386/linux/syscalls.master ============================================================================== --- stable/9/sys/i386/linux/syscalls.master Sun Apr 15 16:00:32 2012 (r234315) +++ stable/9/sys/i386/linux/syscalls.master Sun Apr 15 16:52:48 2012 (r234316) @@ -157,6 +157,7 @@ 82 AUE_SELECT STD { int linux_old_select( \ struct l_old_select_argv *ptr); } 83 AUE_SYMLINK STD { int linux_symlink(char *path, char *to); } +; 84: oldlstat 84 AUE_LSTAT STD { int linux_lstat(char *path, struct ostat *up); } 85 AUE_READLINK STD { int linux_readlink(char *name, char *buf, \ l_int count); } @@ -164,8 +165,10 @@ 87 AUE_SWAPON NOPROTO { int swapon(char *name); } 88 AUE_REBOOT STD { int linux_reboot(l_int magic1, \ l_int magic2, l_uint cmd, void *arg); } +; 89: old_readdir 89 AUE_GETDIRENTRIES STD { int linux_readdir(l_uint fd, \ struct l_dirent *dent, l_uint count); } +; 90: old_mmap 90 AUE_MMAP STD { int linux_mmap(struct l_mmap_argv *ptr); } 91 AUE_MUNMAP NOPROTO { int munmap(caddr_t addr, int len); } 92 AUE_TRUNCATE STD { int linux_truncate(char *path, \ @@ -198,6 +201,7 @@ struct l_newstat *buf); } 108 AUE_FSTAT STD { int linux_newfstat(l_uint fd, \ struct l_newstat *buf); } +; 109: olduname 109 AUE_NULL STD { int linux_uname(void); } 110 AUE_NULL STD { int linux_iopl(l_ulong level); } 111 AUE_NULL STD { int linux_vhangup(void); } @@ -246,6 +250,7 @@ l_uint whence); } 141 AUE_GETDIRENTRIES STD { int linux_getdents(l_uint fd, \ void *dent, l_uint count); } +; 142: newselect 142 AUE_SELECT STD { int linux_select(l_int nfds, \ l_fd_set *readfds, l_fd_set *writefds, \ l_fd_set *exceptfds, \ @@ -338,6 +343,7 @@ 188 AUE_GETPMSG UNIMPL getpmsg 189 AUE_PUTPMSG UNIMPL putpmsg 190 AUE_VFORK STD { int linux_vfork(void); } +; 191: ugetrlimit 191 AUE_GETRLIMIT STD { int linux_getrlimit(l_uint resource, \ struct l_rlimit *rlim); } 192 AUE_MMAP STD { int linux_mmap2(l_ulong addr, l_ulong len, \ @@ -451,10 +457,11 @@ 272 AUE_NULL STD { int linux_fadvise64_64(int fd, \ l_loff_t offset, l_loff_t len, \ int advice); } -273 AUE_NULL UNIMPL +273 AUE_NULL UNIMPL vserver 274 AUE_NULL STD { int linux_mbind(void); } 275 AUE_NULL STD { int linux_get_mempolicy(void); } 276 AUE_NULL STD { int linux_set_mempolicy(void); } +; linux 2.6.6: 277 AUE_NULL STD { int linux_mq_open(const char *name, int oflag, mode_t mode, \ struct mq_attr *attr); } 278 AUE_NULL STD { int linux_mq_unlink(const char *name); } @@ -470,14 +477,17 @@ 283 AUE_NULL STD { int linux_kexec_load(void); } 284 AUE_NULL STD { int linux_waitid(void); } 285 AUE_NULL UNIMPL +; linux 2.6.11: 286 AUE_NULL STD { int linux_add_key(void); } 287 AUE_NULL STD { int linux_request_key(void); } 288 AUE_NULL STD { int linux_keyctl(void); } +; linux 2.6.13: 289 AUE_NULL STD { int linux_ioprio_set(void); } 290 AUE_NULL STD { int linux_ioprio_get(void); } 291 AUE_NULL STD { int linux_inotify_init(void); } 292 AUE_NULL STD { int linux_inotify_add_watch(void); } 293 AUE_NULL STD { int linux_inotify_rm_watch(void); } +; linux 2.6.16: 294 AUE_NULL STD { int linux_migrate_pages(void); } 295 AUE_OPEN_RWTC STD { int linux_openat(l_int dfd, const char *filename, \ l_int flags, l_int mode); } @@ -507,6 +517,7 @@ 308 AUE_NULL STD { int linux_pselect6(void); } 309 AUE_NULL STD { int linux_ppoll(void); } 310 AUE_NULL STD { int linux_unshare(void); } +; linux 2.6.17: 311 AUE_NULL STD { int linux_set_robust_list(struct linux_robust_list_head *head, \ l_size_t len); } 312 AUE_NULL STD { int linux_get_robust_list(l_int pid, struct linux_robust_list_head **head, \ @@ -515,3 +526,46 @@ 314 AUE_NULL STD { int linux_sync_file_range(void); } 315 AUE_NULL STD { int linux_tee(void); } 316 AUE_NULL STD { int linux_vmsplice(void); } +; linux 2.6.18: +317 AUE_NULL STD { int linux_move_pages(void); } +; linux 2.6.19: +318 AUE_NULL STD { int linux_getcpu(void); } +319 AUE_NULL STD { int linux_epoll_pwait(void); } +; linux 2.6.22: +320 AUE_NULL STD { int linux_utimensat(void); } +321 AUE_NULL STD { int linux_signalfd(void); } +322 AUE_NULL STD { int linux_timerfd_create(void); } +323 AUE_NULL STD { int linux_eventfd(void); } +; linux 2.6.23: +324 AUE_NULL STD { int linux_fallocate(void); } +; linux 2.6.25: +325 AUE_NULL STD { int linux_timerfd_settime(void); } +326 AUE_NULL STD { int linux_timerfd_gettime(void); } +; linux 2.6.27: +327 AUE_NULL STD { int linux_signalfd4(void); } +328 AUE_NULL STD { int linux_eventfd2(void); } +329 AUE_NULL STD { int linux_epoll_create1(void); } +330 AUE_NULL STD { int linux_dup3(void); } +331 AUE_NULL STD { int linux_pipe2(void); } +332 AUE_NULL STD { int linux_inotify_init1(void); } +; linux 2.6.30: +333 AUE_NULL STD { int linux_preadv(void); } +334 AUE_NULL STD { int linux_pwritev(void); } +; linux 2.6.31: +335 AUE_NULL STD { int linux_rt_tsigqueueinfo(void); } +336 AUE_NULL STD { int linux_perf_event_open(void); } +; linux 2.6.33: +337 AUE_NULL STD { int linux_recvmmsg(void); } +338 AUE_NULL STD { int linux_fanotify_init(void); } +339 AUE_NULL STD { int linux_fanotify_mark(void); } +; linux 2.6.36: +340 AUE_NULL STD { int linux_prlimit64(void); } +; later: +341 AUE_NULL STD { int linux_name_to_handle_at(void); } +342 AUE_NULL STD { int linux_open_by_handle_at(void); } +343 AUE_NULL STD { int linux_clock_adjtime(void); } +344 AUE_NULL STD { int linux_syncfs(void); } +345 AUE_NULL STD { int linux_sendmmsg(void); } +346 AUE_NULL STD { int linux_setns(void); } +347 AUE_NULL STD { int linux_process_vm_readv(void); } +348 AUE_NULL STD { int linux_process_vm_writev(void); } From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 16:53:45 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DD77F106568D; Sun, 15 Apr 2012 16:53:45 +0000 (UTC) (envelope-from netchild@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 295AE8FC16; Sun, 15 Apr 2012 16:53:45 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FGrjT3093346; Sun, 15 Apr 2012 16:53:45 GMT (envelope-from netchild@svn.freebsd.org) Received: (from netchild@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FGrimL093335; Sun, 15 Apr 2012 16:53:44 GMT (envelope-from netchild@svn.freebsd.org) Message-Id: <201204151653.q3FGrimL093335@svn.freebsd.org> From: Alexander Leidinger Date: Sun, 15 Apr 2012 16:53:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234317 - in stable/9/sys: amd64/linux32 i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 16:53:46 -0000 Author: netchild Date: Sun Apr 15 16:53:44 2012 New Revision: 234317 URL: http://svn.freebsd.org/changeset/base/234317 Log: regen Modified: stable/9/sys/amd64/linux32/linux32_proto.h stable/9/sys/amd64/linux32/linux32_syscall.h stable/9/sys/amd64/linux32/linux32_syscalls.c stable/9/sys/amd64/linux32/linux32_sysent.c stable/9/sys/amd64/linux32/linux32_systrace_args.c stable/9/sys/i386/linux/linux_proto.h stable/9/sys/i386/linux/linux_syscall.h stable/9/sys/i386/linux/linux_syscalls.c stable/9/sys/i386/linux/linux_sysent.c stable/9/sys/i386/linux/linux_systrace_args.c Modified: stable/9/sys/amd64/linux32/linux32_proto.h ============================================================================== --- stable/9/sys/amd64/linux32/linux32_proto.h Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/amd64/linux32/linux32_proto.h Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ #ifndef _LINUX_SYSPROTO_H_ @@ -1001,6 +1001,102 @@ struct linux_tee_args { struct linux_vmsplice_args { register_t dummy; }; +struct linux_move_pages_args { + register_t dummy; +}; +struct linux_getcpu_args { + register_t dummy; +}; +struct linux_epoll_pwait_args { + register_t dummy; +}; +struct linux_utimensat_args { + register_t dummy; +}; +struct linux_signalfd_args { + register_t dummy; +}; +struct linux_timerfd_create_args { + register_t dummy; +}; +struct linux_eventfd_args { + register_t dummy; +}; +struct linux_fallocate_args { + register_t dummy; +}; +struct linux_timerfd_settime_args { + register_t dummy; +}; +struct linux_timerfd_gettime_args { + register_t dummy; +}; +struct linux_signalfd4_args { + register_t dummy; +}; +struct linux_eventfd2_args { + register_t dummy; +}; +struct linux_epoll_create1_args { + register_t dummy; +}; +struct linux_dup3_args { + register_t dummy; +}; +struct linux_pipe2_args { + register_t dummy; +}; +struct linux_inotify_init1_args { + register_t dummy; +}; +struct linux_preadv_args { + register_t dummy; +}; +struct linux_pwritev_args { + register_t dummy; +}; +struct linux_rt_tsigqueueinfo_args { + register_t dummy; +}; +struct linux_perf_event_open_args { + register_t dummy; +}; +struct linux_recvmmsg_args { + register_t dummy; +}; +struct linux_fanotify_init_args { + register_t dummy; +}; +struct linux_fanotify_mark_args { + register_t dummy; +}; +struct linux_prlimit64_args { + register_t dummy; +}; +struct linux_name_to_handle_at_args { + register_t dummy; +}; +struct linux_open_by_handle_at_args { + register_t dummy; +}; +struct linux_clock_adjtime_args { + register_t dummy; +}; +struct linux_syncfs_args { + register_t dummy; +}; +struct linux_sendmmsg_args { + register_t dummy; +}; +struct linux_setns_args { + register_t dummy; +}; +struct linux_process_vm_readv_args { + register_t dummy; +}; +struct linux_process_vm_writev_args { + register_t dummy; +}; #define nosys linux_nosys int linux_fork(struct thread *, struct linux_fork_args *); int linux_open(struct thread *, struct linux_open_args *); @@ -1244,6 +1340,38 @@ int linux_splice(struct thread *, struct int linux_sync_file_range(struct thread *, struct linux_sync_file_range_args *); int linux_tee(struct thread *, struct linux_tee_args *); int linux_vmsplice(struct thread *, struct linux_vmsplice_args *); +int linux_move_pages(struct thread *, struct linux_move_pages_args *); +int linux_getcpu(struct thread *, struct linux_getcpu_args *); +int linux_epoll_pwait(struct thread *, struct linux_epoll_pwait_args *); +int linux_utimensat(struct thread *, struct linux_utimensat_args *); +int linux_signalfd(struct thread *, struct linux_signalfd_args *); +int linux_timerfd_create(struct thread *, struct linux_timerfd_create_args *); +int linux_eventfd(struct thread *, struct linux_eventfd_args *); +int linux_fallocate(struct thread *, struct linux_fallocate_args *); +int linux_timerfd_settime(struct thread *, struct linux_timerfd_settime_args *); +int linux_timerfd_gettime(struct thread *, struct linux_timerfd_gettime_args *); +int linux_signalfd4(struct thread *, struct linux_signalfd4_args *); +int linux_eventfd2(struct thread *, struct linux_eventfd2_args *); +int linux_epoll_create1(struct thread *, struct linux_epoll_create1_args *); +int linux_dup3(struct thread *, struct linux_dup3_args *); +int linux_pipe2(struct thread *, struct linux_pipe2_args *); +int linux_inotify_init1(struct thread *, struct linux_inotify_init1_args *); +int linux_preadv(struct thread *, struct linux_preadv_args *); +int linux_pwritev(struct thread *, struct linux_pwritev_args *); +int linux_rt_tsigqueueinfo(struct thread *, struct linux_rt_tsigqueueinfo_args *); +int linux_perf_event_open(struct thread *, struct linux_perf_event_open_args *); +int linux_recvmmsg(struct thread *, struct linux_recvmmsg_args *); +int linux_fanotify_init(struct thread *, struct linux_fanotify_init_args *); +int linux_fanotify_mark(struct thread *, struct linux_fanotify_mark_args *); +int linux_prlimit64(struct thread *, struct linux_prlimit64_args *); +int linux_name_to_handle_at(struct thread *, struct linux_name_to_handle_at_args *); +int linux_open_by_handle_at(struct thread *, struct linux_open_by_handle_at_args *); +int linux_clock_adjtime(struct thread *, struct linux_clock_adjtime_args *); +int linux_syncfs(struct thread *, struct linux_syncfs_args *); +int linux_sendmmsg(struct thread *, struct linux_sendmmsg_args *); +int linux_setns(struct thread *, struct linux_setns_args *); +int linux_process_vm_readv(struct thread *, struct linux_process_vm_readv_args *); +int linux_process_vm_writev(struct thread *, struct linux_process_vm_writev_args *); #ifdef COMPAT_43 @@ -1514,6 +1642,38 @@ int linux_vmsplice(struct thread *, stru #define LINUX_SYS_AUE_linux_sync_file_range AUE_NULL #define LINUX_SYS_AUE_linux_tee AUE_NULL #define LINUX_SYS_AUE_linux_vmsplice AUE_NULL +#define LINUX_SYS_AUE_linux_move_pages AUE_NULL +#define LINUX_SYS_AUE_linux_getcpu AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_pwait AUE_NULL +#define LINUX_SYS_AUE_linux_utimensat AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_create AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd AUE_NULL +#define LINUX_SYS_AUE_linux_fallocate AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_settime AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_gettime AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd4 AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd2 AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_create1 AUE_NULL +#define LINUX_SYS_AUE_linux_dup3 AUE_NULL +#define LINUX_SYS_AUE_linux_pipe2 AUE_NULL +#define LINUX_SYS_AUE_linux_inotify_init1 AUE_NULL +#define LINUX_SYS_AUE_linux_preadv AUE_NULL +#define LINUX_SYS_AUE_linux_pwritev AUE_NULL +#define LINUX_SYS_AUE_linux_rt_tsigqueueinfo AUE_NULL +#define LINUX_SYS_AUE_linux_perf_event_open AUE_NULL +#define LINUX_SYS_AUE_linux_recvmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_init AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_mark AUE_NULL +#define LINUX_SYS_AUE_linux_prlimit64 AUE_NULL +#define LINUX_SYS_AUE_linux_name_to_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_open_by_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_clock_adjtime AUE_NULL +#define LINUX_SYS_AUE_linux_syncfs AUE_NULL +#define LINUX_SYS_AUE_linux_sendmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_setns AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_readv AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_writev AUE_NULL #undef PAD_ #undef PADL_ Modified: stable/9/sys/amd64/linux32/linux32_syscall.h ============================================================================== --- stable/9/sys/amd64/linux32/linux32_syscall.h Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/amd64/linux32/linux32_syscall.h Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ #define LINUX_SYS_exit 1 @@ -289,4 +289,36 @@ #define LINUX_SYS_linux_sync_file_range 314 #define LINUX_SYS_linux_tee 315 #define LINUX_SYS_linux_vmsplice 316 -#define LINUX_SYS_MAXSYSCALL 317 +#define LINUX_SYS_linux_move_pages 317 +#define LINUX_SYS_linux_getcpu 318 +#define LINUX_SYS_linux_epoll_pwait 319 +#define LINUX_SYS_linux_utimensat 320 +#define LINUX_SYS_linux_signalfd 321 +#define LINUX_SYS_linux_timerfd_create 322 +#define LINUX_SYS_linux_eventfd 323 +#define LINUX_SYS_linux_fallocate 324 +#define LINUX_SYS_linux_timerfd_settime 325 +#define LINUX_SYS_linux_timerfd_gettime 326 +#define LINUX_SYS_linux_signalfd4 327 +#define LINUX_SYS_linux_eventfd2 328 +#define LINUX_SYS_linux_epoll_create1 329 +#define LINUX_SYS_linux_dup3 330 +#define LINUX_SYS_linux_pipe2 331 +#define LINUX_SYS_linux_inotify_init1 332 +#define LINUX_SYS_linux_preadv 333 +#define LINUX_SYS_linux_pwritev 334 +#define LINUX_SYS_linux_rt_tsigqueueinfo 335 +#define LINUX_SYS_linux_perf_event_open 336 +#define LINUX_SYS_linux_recvmmsg 337 +#define LINUX_SYS_linux_fanotify_init 338 +#define LINUX_SYS_linux_fanotify_mark 339 +#define LINUX_SYS_linux_prlimit64 340 +#define LINUX_SYS_linux_name_to_handle_at 341 +#define LINUX_SYS_linux_open_by_handle_at 342 +#define LINUX_SYS_linux_clock_adjtime 343 +#define LINUX_SYS_linux_syncfs 344 +#define LINUX_SYS_linux_sendmmsg 345 +#define LINUX_SYS_linux_setns 346 +#define LINUX_SYS_linux_process_vm_readv 347 +#define LINUX_SYS_linux_process_vm_writev 348 +#define LINUX_SYS_MAXSYSCALL 349 Modified: stable/9/sys/amd64/linux32/linux32_syscalls.c ============================================================================== --- stable/9/sys/amd64/linux32/linux32_syscalls.c Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/amd64/linux32/linux32_syscalls.c Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ const char *linux_syscallnames[] = { @@ -281,7 +281,7 @@ const char *linux_syscallnames[] = { "linux_tgkill", /* 270 = linux_tgkill */ "linux_utimes", /* 271 = linux_utimes */ "linux_fadvise64_64", /* 272 = linux_fadvise64_64 */ - "#273", /* 273 = */ + "#273", /* 273 = vserver */ "linux_mbind", /* 274 = linux_mbind */ "linux_get_mempolicy", /* 275 = linux_get_mempolicy */ "linux_set_mempolicy", /* 276 = linux_set_mempolicy */ @@ -325,4 +325,36 @@ const char *linux_syscallnames[] = { "linux_sync_file_range", /* 314 = linux_sync_file_range */ "linux_tee", /* 315 = linux_tee */ "linux_vmsplice", /* 316 = linux_vmsplice */ + "linux_move_pages", /* 317 = linux_move_pages */ + "linux_getcpu", /* 318 = linux_getcpu */ + "linux_epoll_pwait", /* 319 = linux_epoll_pwait */ + "linux_utimensat", /* 320 = linux_utimensat */ + "linux_signalfd", /* 321 = linux_signalfd */ + "linux_timerfd_create", /* 322 = linux_timerfd_create */ + "linux_eventfd", /* 323 = linux_eventfd */ + "linux_fallocate", /* 324 = linux_fallocate */ + "linux_timerfd_settime", /* 325 = linux_timerfd_settime */ + "linux_timerfd_gettime", /* 326 = linux_timerfd_gettime */ + "linux_signalfd4", /* 327 = linux_signalfd4 */ + "linux_eventfd2", /* 328 = linux_eventfd2 */ + "linux_epoll_create1", /* 329 = linux_epoll_create1 */ + "linux_dup3", /* 330 = linux_dup3 */ + "linux_pipe2", /* 331 = linux_pipe2 */ + "linux_inotify_init1", /* 332 = linux_inotify_init1 */ + "linux_preadv", /* 333 = linux_preadv */ + "linux_pwritev", /* 334 = linux_pwritev */ + "linux_rt_tsigqueueinfo", /* 335 = linux_rt_tsigqueueinfo */ + "linux_perf_event_open", /* 336 = linux_perf_event_open */ + "linux_recvmmsg", /* 337 = linux_recvmmsg */ + "linux_fanotify_init", /* 338 = linux_fanotify_init */ + "linux_fanotify_mark", /* 339 = linux_fanotify_mark */ + "linux_prlimit64", /* 340 = linux_prlimit64 */ + "linux_name_to_handle_at", /* 341 = linux_name_to_handle_at */ + "linux_open_by_handle_at", /* 342 = linux_open_by_handle_at */ + "linux_clock_adjtime", /* 343 = linux_clock_adjtime */ + "linux_syncfs", /* 344 = linux_syncfs */ + "linux_sendmmsg", /* 345 = linux_sendmmsg */ + "linux_setns", /* 346 = linux_setns */ + "linux_process_vm_readv", /* 347 = linux_process_vm_readv */ + "linux_process_vm_writev", /* 348 = linux_process_vm_writev */ }; Modified: stable/9/sys/amd64/linux32/linux32_sysent.c ============================================================================== --- stable/9/sys/amd64/linux32/linux32_sysent.c Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/amd64/linux32/linux32_sysent.c Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/amd64/linux32/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ #include "opt_compat.h" @@ -292,7 +292,7 @@ struct sysent linux_sysent[] = { { AS(linux_tgkill_args), (sy_call_t *)linux_tgkill, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 270 = linux_tgkill */ { AS(linux_utimes_args), (sy_call_t *)linux_utimes, AUE_UTIMES, NULL, 0, 0, 0, SY_THR_STATIC }, /* 271 = linux_utimes */ { AS(linux_fadvise64_64_args), (sy_call_t *)linux_fadvise64_64, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 272 = linux_fadvise64_64 */ - { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 273 = */ + { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 273 = vserver */ { 0, (sy_call_t *)linux_mbind, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 274 = linux_mbind */ { 0, (sy_call_t *)linux_get_mempolicy, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 275 = linux_get_mempolicy */ { 0, (sy_call_t *)linux_set_mempolicy, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 276 = linux_set_mempolicy */ @@ -336,4 +336,36 @@ struct sysent linux_sysent[] = { { 0, (sy_call_t *)linux_sync_file_range, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 314 = linux_sync_file_range */ { 0, (sy_call_t *)linux_tee, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 315 = linux_tee */ { 0, (sy_call_t *)linux_vmsplice, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 316 = linux_vmsplice */ + { 0, (sy_call_t *)linux_move_pages, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 317 = linux_move_pages */ + { 0, (sy_call_t *)linux_getcpu, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 318 = linux_getcpu */ + { 0, (sy_call_t *)linux_epoll_pwait, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 319 = linux_epoll_pwait */ + { 0, (sy_call_t *)linux_utimensat, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 320 = linux_utimensat */ + { 0, (sy_call_t *)linux_signalfd, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 321 = linux_signalfd */ + { 0, (sy_call_t *)linux_timerfd_create, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 322 = linux_timerfd_create */ + { 0, (sy_call_t *)linux_eventfd, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 323 = linux_eventfd */ + { 0, (sy_call_t *)linux_fallocate, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 324 = linux_fallocate */ + { 0, (sy_call_t *)linux_timerfd_settime, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 325 = linux_timerfd_settime */ + { 0, (sy_call_t *)linux_timerfd_gettime, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 326 = linux_timerfd_gettime */ + { 0, (sy_call_t *)linux_signalfd4, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 327 = linux_signalfd4 */ + { 0, (sy_call_t *)linux_eventfd2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 328 = linux_eventfd2 */ + { 0, (sy_call_t *)linux_epoll_create1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 329 = linux_epoll_create1 */ + { 0, (sy_call_t *)linux_dup3, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 330 = linux_dup3 */ + { 0, (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 331 = linux_pipe2 */ + { 0, (sy_call_t *)linux_inotify_init1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 332 = linux_inotify_init1 */ + { 0, (sy_call_t *)linux_preadv, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 333 = linux_preadv */ + { 0, (sy_call_t *)linux_pwritev, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 334 = linux_pwritev */ + { 0, (sy_call_t *)linux_rt_tsigqueueinfo, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 335 = linux_rt_tsigqueueinfo */ + { 0, (sy_call_t *)linux_perf_event_open, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 336 = linux_perf_event_open */ + { 0, (sy_call_t *)linux_recvmmsg, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 337 = linux_recvmmsg */ + { 0, (sy_call_t *)linux_fanotify_init, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 338 = linux_fanotify_init */ + { 0, (sy_call_t *)linux_fanotify_mark, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 339 = linux_fanotify_mark */ + { 0, (sy_call_t *)linux_prlimit64, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 340 = linux_prlimit64 */ + { 0, (sy_call_t *)linux_name_to_handle_at, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 341 = linux_name_to_handle_at */ + { 0, (sy_call_t *)linux_open_by_handle_at, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 342 = linux_open_by_handle_at */ + { 0, (sy_call_t *)linux_clock_adjtime, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 343 = linux_clock_adjtime */ + { 0, (sy_call_t *)linux_syncfs, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 344 = linux_syncfs */ + { 0, (sy_call_t *)linux_sendmmsg, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 345 = linux_sendmmsg */ + { 0, (sy_call_t *)linux_setns, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 346 = linux_setns */ + { 0, (sy_call_t *)linux_process_vm_readv, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 347 = linux_process_vm_readv */ + { 0, (sy_call_t *)linux_process_vm_writev, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 348 = linux_process_vm_writev */ }; Modified: stable/9/sys/amd64/linux32/linux32_systrace_args.c ============================================================================== --- stable/9/sys/amd64/linux32/linux32_systrace_args.c Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/amd64/linux32/linux32_systrace_args.c Sun Apr 15 16:53:44 2012 (r234317) @@ -2099,6 +2099,166 @@ systrace_args(int sysnum, void *params, *n_args = 0; break; } + /* linux_move_pages */ + case 317: { + *n_args = 0; + break; + } + /* linux_getcpu */ + case 318: { + *n_args = 0; + break; + } + /* linux_epoll_pwait */ + case 319: { + *n_args = 0; + break; + } + /* linux_utimensat */ + case 320: { + *n_args = 0; + break; + } + /* linux_signalfd */ + case 321: { + *n_args = 0; + break; + } + /* linux_timerfd_create */ + case 322: { + *n_args = 0; + break; + } + /* linux_eventfd */ + case 323: { + *n_args = 0; + break; + } + /* linux_fallocate */ + case 324: { + *n_args = 0; + break; + } + /* linux_timerfd_settime */ + case 325: { + *n_args = 0; + break; + } + /* linux_timerfd_gettime */ + case 326: { + *n_args = 0; + break; + } + /* linux_signalfd4 */ + case 327: { + *n_args = 0; + break; + } + /* linux_eventfd2 */ + case 328: { + *n_args = 0; + break; + } + /* linux_epoll_create1 */ + case 329: { + *n_args = 0; + break; + } + /* linux_dup3 */ + case 330: { + *n_args = 0; + break; + } + /* linux_pipe2 */ + case 331: { + *n_args = 0; + break; + } + /* linux_inotify_init1 */ + case 332: { + *n_args = 0; + break; + } + /* linux_preadv */ + case 333: { + *n_args = 0; + break; + } + /* linux_pwritev */ + case 334: { + *n_args = 0; + break; + } + /* linux_rt_tsigqueueinfo */ + case 335: { + *n_args = 0; + break; + } + /* linux_perf_event_open */ + case 336: { + *n_args = 0; + break; + } + /* linux_recvmmsg */ + case 337: { + *n_args = 0; + break; + } + /* linux_fanotify_init */ + case 338: { + *n_args = 0; + break; + } + /* linux_fanotify_mark */ + case 339: { + *n_args = 0; + break; + } + /* linux_prlimit64 */ + case 340: { + *n_args = 0; + break; + } + /* linux_name_to_handle_at */ + case 341: { + *n_args = 0; + break; + } + /* linux_open_by_handle_at */ + case 342: { + *n_args = 0; + break; + } + /* linux_clock_adjtime */ + case 343: { + *n_args = 0; + break; + } + /* linux_syncfs */ + case 344: { + *n_args = 0; + break; + } + /* linux_sendmmsg */ + case 345: { + *n_args = 0; + break; + } + /* linux_setns */ + case 346: { + *n_args = 0; + break; + } + /* linux_process_vm_readv */ + case 347: { + *n_args = 0; + break; + } + /* linux_process_vm_writev */ + case 348: { + *n_args = 0; + break; + } default: *n_args = 0; break; @@ -5160,6 +5320,102 @@ systrace_setargdesc(int sysnum, int ndx, /* linux_vmsplice */ case 316: break; + /* linux_move_pages */ + case 317: + break; + /* linux_getcpu */ + case 318: + break; + /* linux_epoll_pwait */ + case 319: + break; + /* linux_utimensat */ + case 320: + break; + /* linux_signalfd */ + case 321: + break; + /* linux_timerfd_create */ + case 322: + break; + /* linux_eventfd */ + case 323: + break; + /* linux_fallocate */ + case 324: + break; + /* linux_timerfd_settime */ + case 325: + break; + /* linux_timerfd_gettime */ + case 326: + break; + /* linux_signalfd4 */ + case 327: + break; + /* linux_eventfd2 */ + case 328: + break; + /* linux_epoll_create1 */ + case 329: + break; + /* linux_dup3 */ + case 330: + break; + /* linux_pipe2 */ + case 331: + break; + /* linux_inotify_init1 */ + case 332: + break; + /* linux_preadv */ + case 333: + break; + /* linux_pwritev */ + case 334: + break; + /* linux_rt_tsigqueueinfo */ + case 335: + break; + /* linux_perf_event_open */ + case 336: + break; + /* linux_recvmmsg */ + case 337: + break; + /* linux_fanotify_init */ + case 338: + break; + /* linux_fanotify_mark */ + case 339: + break; + /* linux_prlimit64 */ + case 340: + break; + /* linux_name_to_handle_at */ + case 341: + break; + /* linux_open_by_handle_at */ + case 342: + break; + /* linux_clock_adjtime */ + case 343: + break; + /* linux_syncfs */ + case 344: + break; + /* linux_sendmmsg */ + case 345: + break; + /* linux_setns */ + case 346: + break; + /* linux_process_vm_readv */ + case 347: + break; + /* linux_process_vm_writev */ + case 348: + break; default: break; }; Modified: stable/9/sys/i386/linux/linux_proto.h ============================================================================== --- stable/9/sys/i386/linux/linux_proto.h Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/i386/linux/linux_proto.h Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ #ifndef _LINUX_SYSPROTO_H_ @@ -1020,6 +1020,102 @@ struct linux_tee_args { struct linux_vmsplice_args { register_t dummy; }; +struct linux_move_pages_args { + register_t dummy; +}; +struct linux_getcpu_args { + register_t dummy; +}; +struct linux_epoll_pwait_args { + register_t dummy; +}; +struct linux_utimensat_args { + register_t dummy; +}; +struct linux_signalfd_args { + register_t dummy; +}; +struct linux_timerfd_create_args { + register_t dummy; +}; +struct linux_eventfd_args { + register_t dummy; +}; +struct linux_fallocate_args { + register_t dummy; +}; +struct linux_timerfd_settime_args { + register_t dummy; +}; +struct linux_timerfd_gettime_args { + register_t dummy; +}; +struct linux_signalfd4_args { + register_t dummy; +}; +struct linux_eventfd2_args { + register_t dummy; +}; +struct linux_epoll_create1_args { + register_t dummy; +}; +struct linux_dup3_args { + register_t dummy; +}; +struct linux_pipe2_args { + register_t dummy; +}; +struct linux_inotify_init1_args { + register_t dummy; +}; +struct linux_preadv_args { + register_t dummy; +}; +struct linux_pwritev_args { + register_t dummy; +}; +struct linux_rt_tsigqueueinfo_args { + register_t dummy; +}; +struct linux_perf_event_open_args { + register_t dummy; +}; +struct linux_recvmmsg_args { + register_t dummy; +}; +struct linux_fanotify_init_args { + register_t dummy; +}; +struct linux_fanotify_mark_args { + register_t dummy; +}; +struct linux_prlimit64_args { + register_t dummy; +}; +struct linux_name_to_handle_at_args { + register_t dummy; +}; +struct linux_open_by_handle_at_args { + register_t dummy; +}; +struct linux_clock_adjtime_args { + register_t dummy; +}; +struct linux_syncfs_args { + register_t dummy; +}; +struct linux_sendmmsg_args { + register_t dummy; +}; +struct linux_setns_args { + register_t dummy; +}; +struct linux_process_vm_readv_args { + register_t dummy; +}; +struct linux_process_vm_writev_args { + register_t dummy; +}; #define nosys linux_nosys int linux_fork(struct thread *, struct linux_fork_args *); int linux_open(struct thread *, struct linux_open_args *); @@ -1264,6 +1360,38 @@ int linux_splice(struct thread *, struct int linux_sync_file_range(struct thread *, struct linux_sync_file_range_args *); int linux_tee(struct thread *, struct linux_tee_args *); int linux_vmsplice(struct thread *, struct linux_vmsplice_args *); +int linux_move_pages(struct thread *, struct linux_move_pages_args *); +int linux_getcpu(struct thread *, struct linux_getcpu_args *); +int linux_epoll_pwait(struct thread *, struct linux_epoll_pwait_args *); +int linux_utimensat(struct thread *, struct linux_utimensat_args *); +int linux_signalfd(struct thread *, struct linux_signalfd_args *); +int linux_timerfd_create(struct thread *, struct linux_timerfd_create_args *); +int linux_eventfd(struct thread *, struct linux_eventfd_args *); +int linux_fallocate(struct thread *, struct linux_fallocate_args *); +int linux_timerfd_settime(struct thread *, struct linux_timerfd_settime_args *); +int linux_timerfd_gettime(struct thread *, struct linux_timerfd_gettime_args *); +int linux_signalfd4(struct thread *, struct linux_signalfd4_args *); +int linux_eventfd2(struct thread *, struct linux_eventfd2_args *); +int linux_epoll_create1(struct thread *, struct linux_epoll_create1_args *); +int linux_dup3(struct thread *, struct linux_dup3_args *); +int linux_pipe2(struct thread *, struct linux_pipe2_args *); +int linux_inotify_init1(struct thread *, struct linux_inotify_init1_args *); +int linux_preadv(struct thread *, struct linux_preadv_args *); +int linux_pwritev(struct thread *, struct linux_pwritev_args *); +int linux_rt_tsigqueueinfo(struct thread *, struct linux_rt_tsigqueueinfo_args *); +int linux_perf_event_open(struct thread *, struct linux_perf_event_open_args *); +int linux_recvmmsg(struct thread *, struct linux_recvmmsg_args *); +int linux_fanotify_init(struct thread *, struct linux_fanotify_init_args *); +int linux_fanotify_mark(struct thread *, struct linux_fanotify_mark_args *); +int linux_prlimit64(struct thread *, struct linux_prlimit64_args *); +int linux_name_to_handle_at(struct thread *, struct linux_name_to_handle_at_args *); +int linux_open_by_handle_at(struct thread *, struct linux_open_by_handle_at_args *); +int linux_clock_adjtime(struct thread *, struct linux_clock_adjtime_args *); +int linux_syncfs(struct thread *, struct linux_syncfs_args *); +int linux_sendmmsg(struct thread *, struct linux_sendmmsg_args *); +int linux_setns(struct thread *, struct linux_setns_args *); +int linux_process_vm_readv(struct thread *, struct linux_process_vm_readv_args *); +int linux_process_vm_writev(struct thread *, struct linux_process_vm_writev_args *); #ifdef COMPAT_43 @@ -1535,6 +1663,38 @@ int linux_vmsplice(struct thread *, stru #define LINUX_SYS_AUE_linux_sync_file_range AUE_NULL #define LINUX_SYS_AUE_linux_tee AUE_NULL #define LINUX_SYS_AUE_linux_vmsplice AUE_NULL +#define LINUX_SYS_AUE_linux_move_pages AUE_NULL +#define LINUX_SYS_AUE_linux_getcpu AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_pwait AUE_NULL +#define LINUX_SYS_AUE_linux_utimensat AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_create AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd AUE_NULL +#define LINUX_SYS_AUE_linux_fallocate AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_settime AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_gettime AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd4 AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd2 AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_create1 AUE_NULL +#define LINUX_SYS_AUE_linux_dup3 AUE_NULL +#define LINUX_SYS_AUE_linux_pipe2 AUE_NULL +#define LINUX_SYS_AUE_linux_inotify_init1 AUE_NULL +#define LINUX_SYS_AUE_linux_preadv AUE_NULL +#define LINUX_SYS_AUE_linux_pwritev AUE_NULL +#define LINUX_SYS_AUE_linux_rt_tsigqueueinfo AUE_NULL +#define LINUX_SYS_AUE_linux_perf_event_open AUE_NULL +#define LINUX_SYS_AUE_linux_recvmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_init AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_mark AUE_NULL +#define LINUX_SYS_AUE_linux_prlimit64 AUE_NULL +#define LINUX_SYS_AUE_linux_name_to_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_open_by_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_clock_adjtime AUE_NULL +#define LINUX_SYS_AUE_linux_syncfs AUE_NULL +#define LINUX_SYS_AUE_linux_sendmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_setns AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_readv AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_writev AUE_NULL #undef PAD_ #undef PADL_ Modified: stable/9/sys/i386/linux/linux_syscall.h ============================================================================== --- stable/9/sys/i386/linux/linux_syscall.h Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/i386/linux/linux_syscall.h Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ #define LINUX_SYS_exit 1 @@ -296,4 +296,36 @@ #define LINUX_SYS_linux_sync_file_range 314 #define LINUX_SYS_linux_tee 315 #define LINUX_SYS_linux_vmsplice 316 -#define LINUX_SYS_MAXSYSCALL 317 +#define LINUX_SYS_linux_move_pages 317 +#define LINUX_SYS_linux_getcpu 318 +#define LINUX_SYS_linux_epoll_pwait 319 +#define LINUX_SYS_linux_utimensat 320 +#define LINUX_SYS_linux_signalfd 321 +#define LINUX_SYS_linux_timerfd_create 322 +#define LINUX_SYS_linux_eventfd 323 +#define LINUX_SYS_linux_fallocate 324 +#define LINUX_SYS_linux_timerfd_settime 325 +#define LINUX_SYS_linux_timerfd_gettime 326 +#define LINUX_SYS_linux_signalfd4 327 +#define LINUX_SYS_linux_eventfd2 328 +#define LINUX_SYS_linux_epoll_create1 329 +#define LINUX_SYS_linux_dup3 330 +#define LINUX_SYS_linux_pipe2 331 +#define LINUX_SYS_linux_inotify_init1 332 +#define LINUX_SYS_linux_preadv 333 +#define LINUX_SYS_linux_pwritev 334 +#define LINUX_SYS_linux_rt_tsigqueueinfo 335 +#define LINUX_SYS_linux_perf_event_open 336 +#define LINUX_SYS_linux_recvmmsg 337 +#define LINUX_SYS_linux_fanotify_init 338 +#define LINUX_SYS_linux_fanotify_mark 339 +#define LINUX_SYS_linux_prlimit64 340 +#define LINUX_SYS_linux_name_to_handle_at 341 +#define LINUX_SYS_linux_open_by_handle_at 342 +#define LINUX_SYS_linux_clock_adjtime 343 +#define LINUX_SYS_linux_syncfs 344 +#define LINUX_SYS_linux_sendmmsg 345 +#define LINUX_SYS_linux_setns 346 +#define LINUX_SYS_linux_process_vm_readv 347 +#define LINUX_SYS_linux_process_vm_writev 348 +#define LINUX_SYS_MAXSYSCALL 349 Modified: stable/9/sys/i386/linux/linux_syscalls.c ============================================================================== --- stable/9/sys/i386/linux/linux_syscalls.c Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/i386/linux/linux_syscalls.c Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ const char *linux_syscallnames[] = { @@ -281,7 +281,7 @@ const char *linux_syscallnames[] = { "linux_tgkill", /* 270 = linux_tgkill */ "linux_utimes", /* 271 = linux_utimes */ "linux_fadvise64_64", /* 272 = linux_fadvise64_64 */ - "#273", /* 273 = */ + "#273", /* 273 = vserver */ "linux_mbind", /* 274 = linux_mbind */ "linux_get_mempolicy", /* 275 = linux_get_mempolicy */ "linux_set_mempolicy", /* 276 = linux_set_mempolicy */ @@ -325,4 +325,36 @@ const char *linux_syscallnames[] = { "linux_sync_file_range", /* 314 = linux_sync_file_range */ "linux_tee", /* 315 = linux_tee */ "linux_vmsplice", /* 316 = linux_vmsplice */ + "linux_move_pages", /* 317 = linux_move_pages */ + "linux_getcpu", /* 318 = linux_getcpu */ + "linux_epoll_pwait", /* 319 = linux_epoll_pwait */ + "linux_utimensat", /* 320 = linux_utimensat */ + "linux_signalfd", /* 321 = linux_signalfd */ + "linux_timerfd_create", /* 322 = linux_timerfd_create */ + "linux_eventfd", /* 323 = linux_eventfd */ + "linux_fallocate", /* 324 = linux_fallocate */ + "linux_timerfd_settime", /* 325 = linux_timerfd_settime */ + "linux_timerfd_gettime", /* 326 = linux_timerfd_gettime */ + "linux_signalfd4", /* 327 = linux_signalfd4 */ + "linux_eventfd2", /* 328 = linux_eventfd2 */ + "linux_epoll_create1", /* 329 = linux_epoll_create1 */ + "linux_dup3", /* 330 = linux_dup3 */ + "linux_pipe2", /* 331 = linux_pipe2 */ + "linux_inotify_init1", /* 332 = linux_inotify_init1 */ + "linux_preadv", /* 333 = linux_preadv */ + "linux_pwritev", /* 334 = linux_pwritev */ + "linux_rt_tsigqueueinfo", /* 335 = linux_rt_tsigqueueinfo */ + "linux_perf_event_open", /* 336 = linux_perf_event_open */ + "linux_recvmmsg", /* 337 = linux_recvmmsg */ + "linux_fanotify_init", /* 338 = linux_fanotify_init */ + "linux_fanotify_mark", /* 339 = linux_fanotify_mark */ + "linux_prlimit64", /* 340 = linux_prlimit64 */ + "linux_name_to_handle_at", /* 341 = linux_name_to_handle_at */ + "linux_open_by_handle_at", /* 342 = linux_open_by_handle_at */ + "linux_clock_adjtime", /* 343 = linux_clock_adjtime */ + "linux_syncfs", /* 344 = linux_syncfs */ + "linux_sendmmsg", /* 345 = linux_sendmmsg */ + "linux_setns", /* 346 = linux_setns */ + "linux_process_vm_readv", /* 347 = linux_process_vm_readv */ + "linux_process_vm_writev", /* 348 = linux_process_vm_writev */ }; Modified: stable/9/sys/i386/linux/linux_sysent.c ============================================================================== --- stable/9/sys/i386/linux/linux_sysent.c Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/i386/linux/linux_sysent.c Sun Apr 15 16:53:44 2012 (r234317) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 231145 2012-02-07 19:11:54Z jhb + * created from FreeBSD: stable/9/sys/i386/linux/syscalls.master 234316 2012-04-15 16:52:48Z netchild */ #include @@ -291,7 +291,7 @@ struct sysent linux_sysent[] = { { AS(linux_tgkill_args), (sy_call_t *)linux_tgkill, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 270 = linux_tgkill */ { AS(linux_utimes_args), (sy_call_t *)linux_utimes, AUE_UTIMES, NULL, 0, 0, 0, SY_THR_STATIC }, /* 271 = linux_utimes */ { AS(linux_fadvise64_64_args), (sy_call_t *)linux_fadvise64_64, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 272 = linux_fadvise64_64 */ - { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 273 = */ + { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 273 = vserver */ { 0, (sy_call_t *)linux_mbind, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 274 = linux_mbind */ { 0, (sy_call_t *)linux_get_mempolicy, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 275 = linux_get_mempolicy */ { 0, (sy_call_t *)linux_set_mempolicy, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 276 = linux_set_mempolicy */ @@ -335,4 +335,36 @@ struct sysent linux_sysent[] = { { 0, (sy_call_t *)linux_sync_file_range, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 314 = linux_sync_file_range */ { 0, (sy_call_t *)linux_tee, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 315 = linux_tee */ { 0, (sy_call_t *)linux_vmsplice, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 316 = linux_vmsplice */ + { 0, (sy_call_t *)linux_move_pages, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 317 = linux_move_pages */ + { 0, (sy_call_t *)linux_getcpu, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 318 = linux_getcpu */ + { 0, (sy_call_t *)linux_epoll_pwait, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 319 = linux_epoll_pwait */ + { 0, (sy_call_t *)linux_utimensat, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 320 = linux_utimensat */ + { 0, (sy_call_t *)linux_signalfd, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 321 = linux_signalfd */ + { 0, (sy_call_t *)linux_timerfd_create, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 322 = linux_timerfd_create */ + { 0, (sy_call_t *)linux_eventfd, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 323 = linux_eventfd */ + { 0, (sy_call_t *)linux_fallocate, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 324 = linux_fallocate */ + { 0, (sy_call_t *)linux_timerfd_settime, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 325 = linux_timerfd_settime */ + { 0, (sy_call_t *)linux_timerfd_gettime, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 326 = linux_timerfd_gettime */ + { 0, (sy_call_t *)linux_signalfd4, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 327 = linux_signalfd4 */ + { 0, (sy_call_t *)linux_eventfd2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 328 = linux_eventfd2 */ + { 0, (sy_call_t *)linux_epoll_create1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 329 = linux_epoll_create1 */ + { 0, (sy_call_t *)linux_dup3, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 330 = linux_dup3 */ + { 0, (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 331 = linux_pipe2 */ + { 0, (sy_call_t *)linux_inotify_init1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 332 = linux_inotify_init1 */ + { 0, (sy_call_t *)linux_preadv, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 333 = linux_preadv */ + { 0, (sy_call_t *)linux_pwritev, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 334 = linux_pwritev */ + { 0, (sy_call_t *)linux_rt_tsigqueueinfo, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 335 = linux_rt_tsigqueueinfo */ + { 0, (sy_call_t *)linux_perf_event_open, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 336 = linux_perf_event_open */ + { 0, (sy_call_t *)linux_recvmmsg, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 337 = linux_recvmmsg */ + { 0, (sy_call_t *)linux_fanotify_init, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 338 = linux_fanotify_init */ + { 0, (sy_call_t *)linux_fanotify_mark, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 339 = linux_fanotify_mark */ + { 0, (sy_call_t *)linux_prlimit64, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 340 = linux_prlimit64 */ + { 0, (sy_call_t *)linux_name_to_handle_at, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 341 = linux_name_to_handle_at */ + { 0, (sy_call_t *)linux_open_by_handle_at, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 342 = linux_open_by_handle_at */ + { 0, (sy_call_t *)linux_clock_adjtime, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 343 = linux_clock_adjtime */ + { 0, (sy_call_t *)linux_syncfs, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 344 = linux_syncfs */ + { 0, (sy_call_t *)linux_sendmmsg, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 345 = linux_sendmmsg */ + { 0, (sy_call_t *)linux_setns, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 346 = linux_setns */ + { 0, (sy_call_t *)linux_process_vm_readv, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 347 = linux_process_vm_readv */ + { 0, (sy_call_t *)linux_process_vm_writev, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 348 = linux_process_vm_writev */ }; Modified: stable/9/sys/i386/linux/linux_systrace_args.c ============================================================================== --- stable/9/sys/i386/linux/linux_systrace_args.c Sun Apr 15 16:52:48 2012 (r234316) +++ stable/9/sys/i386/linux/linux_systrace_args.c Sun Apr 15 16:53:44 2012 (r234317) @@ -2190,6 +2190,166 @@ systrace_args(int sysnum, void *params, *n_args = 0; break; } + /* linux_move_pages */ + case 317: { + *n_args = 0; + break; + } + /* linux_getcpu */ + case 318: { + *n_args = 0; + break; + } + /* linux_epoll_pwait */ + case 319: { *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 16:55:26 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9B2D6106566B; Sun, 15 Apr 2012 16:55:26 +0000 (UTC) (envelope-from netchild@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 840038FC12; Sun, 15 Apr 2012 16:55:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FGtQsM093453; Sun, 15 Apr 2012 16:55:26 GMT (envelope-from netchild@svn.freebsd.org) Received: (from netchild@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FGtQSU093448; Sun, 15 Apr 2012 16:55:26 GMT (envelope-from netchild@svn.freebsd.org) Message-Id: <201204151655.q3FGtQSU093448@svn.freebsd.org> From: Alexander Leidinger Date: Sun, 15 Apr 2012 16:55:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234318 - in stable/8/sys: amd64/linux32 i386/conf i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 16:55:26 -0000 Author: netchild Date: Sun Apr 15 16:55:26 2012 New Revision: 234318 URL: http://svn.freebsd.org/changeset/base/234318 Log: MFC r232799: - add comments to syscalls.master and linux(32)_dummy about which linux kernel version introduced the sysctl (based upon a linux man-page) - add comments to syscalls.master regarding some names of sysctls which are different than the linux-names (based upon the linux unistd.h) - add some dummy sysctls - name an unimplemented sysctl Modified: stable/8/sys/amd64/linux32/linux32_dummy.c stable/8/sys/amd64/linux32/syscalls.master stable/8/sys/i386/linux/linux_dummy.c stable/8/sys/i386/linux/syscalls.master Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/e1000/ (props changed) stable/8/sys/i386/conf/XENHVM (props changed) Modified: stable/8/sys/amd64/linux32/linux32_dummy.c ============================================================================== --- stable/8/sys/amd64/linux32/linux32_dummy.c Sun Apr 15 16:53:44 2012 (r234317) +++ stable/8/sys/amd64/linux32/linux32_dummy.c Sun Apr 15 16:55:26 2012 (r234318) @@ -82,22 +82,69 @@ DUMMY(mq_notify); DUMMY(mq_getsetattr); DUMMY(kexec_load); DUMMY(waitid); +/* linux 2.6.11: */ DUMMY(add_key); DUMMY(request_key); DUMMY(keyctl); +/* linux 2.6.13: */ DUMMY(ioprio_set); DUMMY(ioprio_get); DUMMY(inotify_init); DUMMY(inotify_add_watch); DUMMY(inotify_rm_watch); +/* linux 2.6.16: */ DUMMY(migrate_pages); DUMMY(pselect6); DUMMY(ppoll); DUMMY(unshare); +/* linux 2.6.17: */ DUMMY(splice); DUMMY(sync_file_range); DUMMY(tee); DUMMY(vmsplice); +/* linux 2.6.18: */ +DUMMY(move_pages); +/* linux 2.6.19: */ +DUMMY(getcpu); +DUMMY(epoll_pwait); +/* linux 2.6.22: */ +DUMMY(utimensat); +DUMMY(signalfd); +DUMMY(timerfd_create); +DUMMY(eventfd); +/* linux 2.6.23: */ +DUMMY(fallocate); +/* linux 2.6.25: */ +DUMMY(timerfd_settime); +DUMMY(timerfd_gettime); +/* linux 2.6.27: */ +DUMMY(signalfd4); +DUMMY(eventfd2); +DUMMY(epoll_create1); +DUMMY(dup3); +DUMMY(pipe2); +DUMMY(inotify_init1); +/* linux 2.6.30: */ +DUMMY(preadv); +DUMMY(pwritev); +/* linux 2.6.31: */ +DUMMY(rt_tsigqueueinfo); +DUMMY(perf_event_open); +/* linux 2.6.33: */ +DUMMY(recvmmsg); +DUMMY(fanotify_init); +DUMMY(fanotify_mark); +/* linux 2.6.36: */ +DUMMY(prlimit64); +/* later: */ +DUMMY(name_to_handle_at); +DUMMY(open_by_handle_at); +DUMMY(clock_adjtime); +DUMMY(syncfs); +DUMMY(sendmmsg); +DUMMY(setns); +DUMMY(process_vm_readv); +DUMMY(process_vm_writev); #define DUMMY_XATTR(s) \ int \ Modified: stable/8/sys/amd64/linux32/syscalls.master ============================================================================== --- stable/8/sys/amd64/linux32/syscalls.master Sun Apr 15 16:53:44 2012 (r234317) +++ stable/8/sys/amd64/linux32/syscalls.master Sun Apr 15 16:55:26 2012 (r234318) @@ -157,6 +157,7 @@ 82 AUE_SELECT STD { int linux_old_select( \ struct l_old_select_argv *ptr); } 83 AUE_SYMLINK STD { int linux_symlink(char *path, char *to); } +; 84: oldlstat 84 AUE_LSTAT STD { int linux_lstat(char *path, struct linux_lstat *up); } 85 AUE_READLINK STD { int linux_readlink(char *name, char *buf, \ l_int count); } @@ -164,8 +165,10 @@ 87 AUE_SWAPON NOPROTO { int swapon(char *name); } 88 AUE_REBOOT STD { int linux_reboot(l_int magic1, \ l_int magic2, l_uint cmd, void *arg); } +; 89: old_readdir 89 AUE_GETDIRENTRIES STD { int linux_readdir(l_uint fd, \ struct l_dirent *dent, l_uint count); } +; 90: old_mmap 90 AUE_MMAP STD { int linux_mmap(struct l_mmap_argv *ptr); } 91 AUE_MUNMAP NOPROTO { int munmap(caddr_t addr, int len); } 92 AUE_TRUNCATE STD { int linux_truncate(char *path, \ @@ -197,6 +200,7 @@ struct l_newstat *buf); } 108 AUE_FSTAT STD { int linux_newfstat(l_uint fd, \ struct l_newstat *buf); } +; 109: olduname 109 AUE_NULL STD { int linux_uname(void); } 110 AUE_NULL STD { int linux_iopl(l_ulong level); } 111 AUE_NULL STD { int linux_vhangup(void); } @@ -244,6 +248,7 @@ l_uint whence); } 141 AUE_GETDIRENTRIES STD { int linux_getdents(l_uint fd, void *dent, \ l_uint count); } +; 142: newselect 142 AUE_SELECT STD { int linux_select(l_int nfds, \ l_fd_set *readfds, l_fd_set *writefds, \ l_fd_set *exceptfds, \ @@ -336,6 +341,7 @@ 188 AUE_GETPMSG UNIMPL getpmsg 189 AUE_PUTPMSG UNIMPL putpmsg 190 AUE_VFORK STD { int linux_vfork(void); } +; 191: ugetrlimit 191 AUE_GETRLIMIT STD { int linux_getrlimit(l_uint resource, \ struct l_rlimit *rlim); } 192 AUE_MMAP STD { int linux_mmap2(l_ulong addr, l_ulong len, \ @@ -447,10 +453,11 @@ 272 AUE_NULL STD { int linux_fadvise64_64(int fd, \ l_loff_t offset, l_loff_t len, \ int advice); } -273 AUE_NULL UNIMPL +273 AUE_NULL UNIMPL vserver 274 AUE_NULL STD { int linux_mbind(void); } 275 AUE_NULL STD { int linux_get_mempolicy(void); } 276 AUE_NULL STD { int linux_set_mempolicy(void); } +; linux 2.6.6: 277 AUE_NULL STD { int linux_mq_open(void); } 278 AUE_NULL STD { int linux_mq_unlink(void); } 279 AUE_NULL STD { int linux_mq_timedsend(void); } @@ -460,14 +467,17 @@ 283 AUE_NULL STD { int linux_kexec_load(void); } 284 AUE_NULL STD { int linux_waitid(void); } 285 AUE_NULL UNIMPL +; linux 2.6.11: 286 AUE_NULL STD { int linux_add_key(void); } 287 AUE_NULL STD { int linux_request_key(void); } 288 AUE_NULL STD { int linux_keyctl(void); } +; linux 2.6.13: 289 AUE_NULL STD { int linux_ioprio_set(void); } 290 AUE_NULL STD { int linux_ioprio_get(void); } 291 AUE_NULL STD { int linux_inotify_init(void); } 292 AUE_NULL STD { int linux_inotify_add_watch(void); } 293 AUE_NULL STD { int linux_inotify_rm_watch(void); } +; linux 2.6.16: 294 AUE_NULL STD { int linux_migrate_pages(void); } 295 AUE_OPEN_RWTC STD { int linux_openat(l_int dfd, const char *filename, \ l_int flags, l_int mode); } @@ -497,6 +507,7 @@ 308 AUE_NULL STD { int linux_pselect6(void); } 309 AUE_NULL STD { int linux_ppoll(void); } 310 AUE_NULL STD { int linux_unshare(void); } +; linux 2.6.17: 311 AUE_NULL STD { int linux_set_robust_list(struct linux_robust_list_head *head, \ l_size_t len); } 312 AUE_NULL STD { int linux_get_robust_list(l_int pid, struct linux_robust_list_head *head, \ @@ -505,3 +516,46 @@ 314 AUE_NULL STD { int linux_sync_file_range(void); } 315 AUE_NULL STD { int linux_tee(void); } 316 AUE_NULL STD { int linux_vmsplice(void); } +; linux 2.6.18: +317 AUE_NULL STD { int linux_move_pages(void); } +; linux 2.6.19: +318 AUE_NULL STD { int linux_getcpu(void); } +319 AUE_NULL STD { int linux_epoll_pwait(void); } +; linux 2.6.22: +320 AUE_NULL STD { int linux_utimensat(void); } +321 AUE_NULL STD { int linux_signalfd(void); } +322 AUE_NULL STD { int linux_timerfd_create(void); } +323 AUE_NULL STD { int linux_eventfd(void); } +; linux 2.6.23: +324 AUE_NULL STD { int linux_fallocate(void); } +; linux 2.6.25: +325 AUE_NULL STD { int linux_timerfd_settime(void); } +326 AUE_NULL STD { int linux_timerfd_gettime(void); } +; linux 2.6.27: +327 AUE_NULL STD { int linux_signalfd4(void); } +328 AUE_NULL STD { int linux_eventfd2(void); } +329 AUE_NULL STD { int linux_epoll_create1(void); } +330 AUE_NULL STD { int linux_dup3(void); } +331 AUE_NULL STD { int linux_pipe2(void); } +332 AUE_NULL STD { int linux_inotify_init1(void); } +; linux 2.6.30: +333 AUE_NULL STD { int linux_preadv(void); } +334 AUE_NULL STD { int linux_pwritev(void); } +; linux 2.6.31: +335 AUE_NULL STD { int linux_rt_tsigqueueinfo(void); } +336 AUE_NULL STD { int linux_perf_event_open(void); } +; linux 2.6.33: +337 AUE_NULL STD { int linux_recvmmsg(void); } +338 AUE_NULL STD { int linux_fanotify_init(void); } +339 AUE_NULL STD { int linux_fanotify_mark(void); } +; linux 2.6.36: +340 AUE_NULL STD { int linux_prlimit64(void); } +; later: +341 AUE_NULL STD { int linux_name_to_handle_at(void); } +342 AUE_NULL STD { int linux_open_by_handle_at(void); } +343 AUE_NULL STD { int linux_clock_adjtime(void); } +344 AUE_NULL STD { int linux_syncfs(void); } +345 AUE_NULL STD { int linux_sendmmsg(void); } +346 AUE_NULL STD { int linux_setns(void); } +347 AUE_NULL STD { int linux_process_vm_readv(void); } +348 AUE_NULL STD { int linux_process_vm_writev(void); } Modified: stable/8/sys/i386/linux/linux_dummy.c ============================================================================== --- stable/8/sys/i386/linux/linux_dummy.c Sun Apr 15 16:53:44 2012 (r234317) +++ stable/8/sys/i386/linux/linux_dummy.c Sun Apr 15 16:55:26 2012 (r234318) @@ -73,22 +73,69 @@ DUMMY(get_mempolicy); DUMMY(set_mempolicy); DUMMY(kexec_load); DUMMY(waitid); +/* linux 2.6.11: */ DUMMY(add_key); DUMMY(request_key); DUMMY(keyctl); +/* linux 2.6.13: */ DUMMY(ioprio_set); DUMMY(ioprio_get); DUMMY(inotify_init); DUMMY(inotify_add_watch); DUMMY(inotify_rm_watch); +/* linux 2.6.16: */ DUMMY(migrate_pages); DUMMY(pselect6); DUMMY(ppoll); DUMMY(unshare); +/* linux 2.6.17: */ DUMMY(splice); DUMMY(sync_file_range); DUMMY(tee); DUMMY(vmsplice); +/* linux 2.6.18: */ +DUMMY(move_pages); +/* linux 2.6.19: */ +DUMMY(getcpu); +DUMMY(epoll_pwait); +/* linux 2.6.22: */ +DUMMY(utimensat); +DUMMY(signalfd); +DUMMY(timerfd_create); +DUMMY(eventfd); +/* linux 2.6.23: */ +DUMMY(fallocate); +/* linux 2.6.25: */ +DUMMY(timerfd_settime); +DUMMY(timerfd_gettime); +/* linux 2.6.27: */ +DUMMY(signalfd4); +DUMMY(eventfd2); +DUMMY(epoll_create1); +DUMMY(dup3); +DUMMY(pipe2); +DUMMY(inotify_init1); +/* linux 2.6.30: */ +DUMMY(preadv); +DUMMY(pwritev); +/* linux 2.6.31 */ +DUMMY(rt_tsigqueueinfo); +DUMMY(perf_event_open); +/* linux 2.6.33: */ +DUMMY(recvmmsg); +DUMMY(fanotify_init); +DUMMY(fanotify_mark); +/* linux 2.6.36: */ +DUMMY(prlimit64); +/* later: */ +DUMMY(name_to_handle_at); +DUMMY(open_by_handle_at); +DUMMY(clock_adjtime); +DUMMY(syncfs); +DUMMY(sendmmsg); +DUMMY(setns); +DUMMY(process_vm_readv); +DUMMY(process_vm_writev); #define DUMMY_XATTR(s) \ int \ Modified: stable/8/sys/i386/linux/syscalls.master ============================================================================== --- stable/8/sys/i386/linux/syscalls.master Sun Apr 15 16:53:44 2012 (r234317) +++ stable/8/sys/i386/linux/syscalls.master Sun Apr 15 16:55:26 2012 (r234318) @@ -157,6 +157,7 @@ 82 AUE_SELECT STD { int linux_old_select( \ struct l_old_select_argv *ptr); } 83 AUE_SYMLINK STD { int linux_symlink(char *path, char *to); } +; 84: oldlstat 84 AUE_LSTAT STD { int linux_lstat(char *path, struct ostat *up); } 85 AUE_READLINK STD { int linux_readlink(char *name, char *buf, \ l_int count); } @@ -164,8 +165,10 @@ 87 AUE_SWAPON NOPROTO { int swapon(char *name); } 88 AUE_REBOOT STD { int linux_reboot(l_int magic1, \ l_int magic2, l_uint cmd, void *arg); } +; 89: old_readdir 89 AUE_GETDIRENTRIES STD { int linux_readdir(l_uint fd, \ struct l_dirent *dent, l_uint count); } +; 90: old_mmap 90 AUE_MMAP STD { int linux_mmap(struct l_mmap_argv *ptr); } 91 AUE_MUNMAP NOPROTO { int munmap(caddr_t addr, int len); } 92 AUE_TRUNCATE STD { int linux_truncate(char *path, \ @@ -198,6 +201,7 @@ struct l_newstat *buf); } 108 AUE_FSTAT STD { int linux_newfstat(l_uint fd, \ struct l_newstat *buf); } +; 109: olduname 109 AUE_NULL STD { int linux_uname(void); } 110 AUE_NULL STD { int linux_iopl(l_ulong level); } 111 AUE_NULL STD { int linux_vhangup(void); } @@ -246,6 +250,7 @@ l_uint whence); } 141 AUE_GETDIRENTRIES STD { int linux_getdents(l_uint fd, \ void *dent, l_uint count); } +; 142: newselect 142 AUE_SELECT STD { int linux_select(l_int nfds, \ l_fd_set *readfds, l_fd_set *writefds, \ l_fd_set *exceptfds, \ @@ -338,6 +343,7 @@ 188 AUE_GETPMSG UNIMPL getpmsg 189 AUE_PUTPMSG UNIMPL putpmsg 190 AUE_VFORK STD { int linux_vfork(void); } +; 191: ugetrlimit 191 AUE_GETRLIMIT STD { int linux_getrlimit(l_uint resource, \ struct l_rlimit *rlim); } 192 AUE_MMAP STD { int linux_mmap2(l_ulong addr, l_ulong len, \ @@ -451,10 +457,11 @@ 272 AUE_NULL STD { int linux_fadvise64_64(int fd, \ l_loff_t offset, l_loff_t len, \ int advice); } -273 AUE_NULL UNIMPL +273 AUE_NULL UNIMPL vserver 274 AUE_NULL STD { int linux_mbind(void); } 275 AUE_NULL STD { int linux_get_mempolicy(void); } 276 AUE_NULL STD { int linux_set_mempolicy(void); } +; linux 2.6.6: 277 AUE_NULL STD { int linux_mq_open(const char *name, int oflag, mode_t mode, \ struct mq_attr *attr); } 278 AUE_NULL STD { int linux_mq_unlink(const char *name); } @@ -470,14 +477,17 @@ 283 AUE_NULL STD { int linux_kexec_load(void); } 284 AUE_NULL STD { int linux_waitid(void); } 285 AUE_NULL UNIMPL +; linux 2.6.11: 286 AUE_NULL STD { int linux_add_key(void); } 287 AUE_NULL STD { int linux_request_key(void); } 288 AUE_NULL STD { int linux_keyctl(void); } +; linux 2.6.13: 289 AUE_NULL STD { int linux_ioprio_set(void); } 290 AUE_NULL STD { int linux_ioprio_get(void); } 291 AUE_NULL STD { int linux_inotify_init(void); } 292 AUE_NULL STD { int linux_inotify_add_watch(void); } 293 AUE_NULL STD { int linux_inotify_rm_watch(void); } +; linux 2.6.16: 294 AUE_NULL STD { int linux_migrate_pages(void); } 295 AUE_OPEN_RWTC STD { int linux_openat(l_int dfd, const char *filename, \ l_int flags, l_int mode); } @@ -507,6 +517,7 @@ 308 AUE_NULL STD { int linux_pselect6(void); } 309 AUE_NULL STD { int linux_ppoll(void); } 310 AUE_NULL STD { int linux_unshare(void); } +; linux 2.6.17: 311 AUE_NULL STD { int linux_set_robust_list(struct linux_robust_list_head *head, \ l_size_t len); } 312 AUE_NULL STD { int linux_get_robust_list(l_int pid, struct linux_robust_list_head **head, \ @@ -515,3 +526,46 @@ 314 AUE_NULL STD { int linux_sync_file_range(void); } 315 AUE_NULL STD { int linux_tee(void); } 316 AUE_NULL STD { int linux_vmsplice(void); } +; linux 2.6.18: +317 AUE_NULL STD { int linux_move_pages(void); } +; linux 2.6.19: +318 AUE_NULL STD { int linux_getcpu(void); } +319 AUE_NULL STD { int linux_epoll_pwait(void); } +; linux 2.6.22: +320 AUE_NULL STD { int linux_utimensat(void); } +321 AUE_NULL STD { int linux_signalfd(void); } +322 AUE_NULL STD { int linux_timerfd_create(void); } +323 AUE_NULL STD { int linux_eventfd(void); } +; linux 2.6.23: +324 AUE_NULL STD { int linux_fallocate(void); } +; linux 2.6.25: +325 AUE_NULL STD { int linux_timerfd_settime(void); } +326 AUE_NULL STD { int linux_timerfd_gettime(void); } +; linux 2.6.27: +327 AUE_NULL STD { int linux_signalfd4(void); } +328 AUE_NULL STD { int linux_eventfd2(void); } +329 AUE_NULL STD { int linux_epoll_create1(void); } +330 AUE_NULL STD { int linux_dup3(void); } +331 AUE_NULL STD { int linux_pipe2(void); } +332 AUE_NULL STD { int linux_inotify_init1(void); } +; linux 2.6.30: +333 AUE_NULL STD { int linux_preadv(void); } +334 AUE_NULL STD { int linux_pwritev(void); } +; linux 2.6.31: +335 AUE_NULL STD { int linux_rt_tsigqueueinfo(void); } +336 AUE_NULL STD { int linux_perf_event_open(void); } +; linux 2.6.33: +337 AUE_NULL STD { int linux_recvmmsg(void); } +338 AUE_NULL STD { int linux_fanotify_init(void); } +339 AUE_NULL STD { int linux_fanotify_mark(void); } +; linux 2.6.36: +340 AUE_NULL STD { int linux_prlimit64(void); } +; later: +341 AUE_NULL STD { int linux_name_to_handle_at(void); } +342 AUE_NULL STD { int linux_open_by_handle_at(void); } +343 AUE_NULL STD { int linux_clock_adjtime(void); } +344 AUE_NULL STD { int linux_syncfs(void); } +345 AUE_NULL STD { int linux_sendmmsg(void); } +346 AUE_NULL STD { int linux_setns(void); } +347 AUE_NULL STD { int linux_process_vm_readv(void); } +348 AUE_NULL STD { int linux_process_vm_writev(void); } From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 16:56:28 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BCE4F1065670; Sun, 15 Apr 2012 16:56:28 +0000 (UTC) (envelope-from netchild@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A571A8FC1B; Sun, 15 Apr 2012 16:56:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FGuSPY093529; Sun, 15 Apr 2012 16:56:28 GMT (envelope-from netchild@svn.freebsd.org) Received: (from netchild@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FGuSt9093518; Sun, 15 Apr 2012 16:56:28 GMT (envelope-from netchild@svn.freebsd.org) Message-Id: <201204151656.q3FGuSt9093518@svn.freebsd.org> From: Alexander Leidinger Date: Sun, 15 Apr 2012 16:56:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234319 - in stable/8/sys: amd64/linux32 i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 16:56:28 -0000 Author: netchild Date: Sun Apr 15 16:56:28 2012 New Revision: 234319 URL: http://svn.freebsd.org/changeset/base/234319 Log: regen Modified: stable/8/sys/amd64/linux32/linux32_proto.h stable/8/sys/amd64/linux32/linux32_syscall.h stable/8/sys/amd64/linux32/linux32_syscalls.c stable/8/sys/amd64/linux32/linux32_sysent.c stable/8/sys/amd64/linux32/linux32_systrace_args.c stable/8/sys/i386/linux/linux_proto.h stable/8/sys/i386/linux/linux_syscall.h stable/8/sys/i386/linux/linux_syscalls.c stable/8/sys/i386/linux/linux_sysent.c stable/8/sys/i386/linux/linux_systrace_args.c Modified: stable/8/sys/amd64/linux32/linux32_proto.h ============================================================================== --- stable/8/sys/amd64/linux32/linux32_proto.h Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/amd64/linux32/linux32_proto.h Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ #ifndef _LINUX_SYSPROTO_H_ @@ -1001,6 +1001,102 @@ struct linux_tee_args { struct linux_vmsplice_args { register_t dummy; }; +struct linux_move_pages_args { + register_t dummy; +}; +struct linux_getcpu_args { + register_t dummy; +}; +struct linux_epoll_pwait_args { + register_t dummy; +}; +struct linux_utimensat_args { + register_t dummy; +}; +struct linux_signalfd_args { + register_t dummy; +}; +struct linux_timerfd_create_args { + register_t dummy; +}; +struct linux_eventfd_args { + register_t dummy; +}; +struct linux_fallocate_args { + register_t dummy; +}; +struct linux_timerfd_settime_args { + register_t dummy; +}; +struct linux_timerfd_gettime_args { + register_t dummy; +}; +struct linux_signalfd4_args { + register_t dummy; +}; +struct linux_eventfd2_args { + register_t dummy; +}; +struct linux_epoll_create1_args { + register_t dummy; +}; +struct linux_dup3_args { + register_t dummy; +}; +struct linux_pipe2_args { + register_t dummy; +}; +struct linux_inotify_init1_args { + register_t dummy; +}; +struct linux_preadv_args { + register_t dummy; +}; +struct linux_pwritev_args { + register_t dummy; +}; +struct linux_rt_tsigqueueinfo_args { + register_t dummy; +}; +struct linux_perf_event_open_args { + register_t dummy; +}; +struct linux_recvmmsg_args { + register_t dummy; +}; +struct linux_fanotify_init_args { + register_t dummy; +}; +struct linux_fanotify_mark_args { + register_t dummy; +}; +struct linux_prlimit64_args { + register_t dummy; +}; +struct linux_name_to_handle_at_args { + register_t dummy; +}; +struct linux_open_by_handle_at_args { + register_t dummy; +}; +struct linux_clock_adjtime_args { + register_t dummy; +}; +struct linux_syncfs_args { + register_t dummy; +}; +struct linux_sendmmsg_args { + register_t dummy; +}; +struct linux_setns_args { + register_t dummy; +}; +struct linux_process_vm_readv_args { + register_t dummy; +}; +struct linux_process_vm_writev_args { + register_t dummy; +}; #define nosys linux_nosys int linux_fork(struct thread *, struct linux_fork_args *); int linux_open(struct thread *, struct linux_open_args *); @@ -1244,6 +1340,38 @@ int linux_splice(struct thread *, struct int linux_sync_file_range(struct thread *, struct linux_sync_file_range_args *); int linux_tee(struct thread *, struct linux_tee_args *); int linux_vmsplice(struct thread *, struct linux_vmsplice_args *); +int linux_move_pages(struct thread *, struct linux_move_pages_args *); +int linux_getcpu(struct thread *, struct linux_getcpu_args *); +int linux_epoll_pwait(struct thread *, struct linux_epoll_pwait_args *); +int linux_utimensat(struct thread *, struct linux_utimensat_args *); +int linux_signalfd(struct thread *, struct linux_signalfd_args *); +int linux_timerfd_create(struct thread *, struct linux_timerfd_create_args *); +int linux_eventfd(struct thread *, struct linux_eventfd_args *); +int linux_fallocate(struct thread *, struct linux_fallocate_args *); +int linux_timerfd_settime(struct thread *, struct linux_timerfd_settime_args *); +int linux_timerfd_gettime(struct thread *, struct linux_timerfd_gettime_args *); +int linux_signalfd4(struct thread *, struct linux_signalfd4_args *); +int linux_eventfd2(struct thread *, struct linux_eventfd2_args *); +int linux_epoll_create1(struct thread *, struct linux_epoll_create1_args *); +int linux_dup3(struct thread *, struct linux_dup3_args *); +int linux_pipe2(struct thread *, struct linux_pipe2_args *); +int linux_inotify_init1(struct thread *, struct linux_inotify_init1_args *); +int linux_preadv(struct thread *, struct linux_preadv_args *); +int linux_pwritev(struct thread *, struct linux_pwritev_args *); +int linux_rt_tsigqueueinfo(struct thread *, struct linux_rt_tsigqueueinfo_args *); +int linux_perf_event_open(struct thread *, struct linux_perf_event_open_args *); +int linux_recvmmsg(struct thread *, struct linux_recvmmsg_args *); +int linux_fanotify_init(struct thread *, struct linux_fanotify_init_args *); +int linux_fanotify_mark(struct thread *, struct linux_fanotify_mark_args *); +int linux_prlimit64(struct thread *, struct linux_prlimit64_args *); +int linux_name_to_handle_at(struct thread *, struct linux_name_to_handle_at_args *); +int linux_open_by_handle_at(struct thread *, struct linux_open_by_handle_at_args *); +int linux_clock_adjtime(struct thread *, struct linux_clock_adjtime_args *); +int linux_syncfs(struct thread *, struct linux_syncfs_args *); +int linux_sendmmsg(struct thread *, struct linux_sendmmsg_args *); +int linux_setns(struct thread *, struct linux_setns_args *); +int linux_process_vm_readv(struct thread *, struct linux_process_vm_readv_args *); +int linux_process_vm_writev(struct thread *, struct linux_process_vm_writev_args *); #ifdef COMPAT_43 @@ -1514,6 +1642,38 @@ int linux_vmsplice(struct thread *, stru #define LINUX_SYS_AUE_linux_sync_file_range AUE_NULL #define LINUX_SYS_AUE_linux_tee AUE_NULL #define LINUX_SYS_AUE_linux_vmsplice AUE_NULL +#define LINUX_SYS_AUE_linux_move_pages AUE_NULL +#define LINUX_SYS_AUE_linux_getcpu AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_pwait AUE_NULL +#define LINUX_SYS_AUE_linux_utimensat AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_create AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd AUE_NULL +#define LINUX_SYS_AUE_linux_fallocate AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_settime AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_gettime AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd4 AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd2 AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_create1 AUE_NULL +#define LINUX_SYS_AUE_linux_dup3 AUE_NULL +#define LINUX_SYS_AUE_linux_pipe2 AUE_NULL +#define LINUX_SYS_AUE_linux_inotify_init1 AUE_NULL +#define LINUX_SYS_AUE_linux_preadv AUE_NULL +#define LINUX_SYS_AUE_linux_pwritev AUE_NULL +#define LINUX_SYS_AUE_linux_rt_tsigqueueinfo AUE_NULL +#define LINUX_SYS_AUE_linux_perf_event_open AUE_NULL +#define LINUX_SYS_AUE_linux_recvmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_init AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_mark AUE_NULL +#define LINUX_SYS_AUE_linux_prlimit64 AUE_NULL +#define LINUX_SYS_AUE_linux_name_to_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_open_by_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_clock_adjtime AUE_NULL +#define LINUX_SYS_AUE_linux_syncfs AUE_NULL +#define LINUX_SYS_AUE_linux_sendmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_setns AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_readv AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_writev AUE_NULL #undef PAD_ #undef PADL_ Modified: stable/8/sys/amd64/linux32/linux32_syscall.h ============================================================================== --- stable/8/sys/amd64/linux32/linux32_syscall.h Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/amd64/linux32/linux32_syscall.h Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ #define LINUX_SYS_exit 1 @@ -289,4 +289,36 @@ #define LINUX_SYS_linux_sync_file_range 314 #define LINUX_SYS_linux_tee 315 #define LINUX_SYS_linux_vmsplice 316 -#define LINUX_SYS_MAXSYSCALL 317 +#define LINUX_SYS_linux_move_pages 317 +#define LINUX_SYS_linux_getcpu 318 +#define LINUX_SYS_linux_epoll_pwait 319 +#define LINUX_SYS_linux_utimensat 320 +#define LINUX_SYS_linux_signalfd 321 +#define LINUX_SYS_linux_timerfd_create 322 +#define LINUX_SYS_linux_eventfd 323 +#define LINUX_SYS_linux_fallocate 324 +#define LINUX_SYS_linux_timerfd_settime 325 +#define LINUX_SYS_linux_timerfd_gettime 326 +#define LINUX_SYS_linux_signalfd4 327 +#define LINUX_SYS_linux_eventfd2 328 +#define LINUX_SYS_linux_epoll_create1 329 +#define LINUX_SYS_linux_dup3 330 +#define LINUX_SYS_linux_pipe2 331 +#define LINUX_SYS_linux_inotify_init1 332 +#define LINUX_SYS_linux_preadv 333 +#define LINUX_SYS_linux_pwritev 334 +#define LINUX_SYS_linux_rt_tsigqueueinfo 335 +#define LINUX_SYS_linux_perf_event_open 336 +#define LINUX_SYS_linux_recvmmsg 337 +#define LINUX_SYS_linux_fanotify_init 338 +#define LINUX_SYS_linux_fanotify_mark 339 +#define LINUX_SYS_linux_prlimit64 340 +#define LINUX_SYS_linux_name_to_handle_at 341 +#define LINUX_SYS_linux_open_by_handle_at 342 +#define LINUX_SYS_linux_clock_adjtime 343 +#define LINUX_SYS_linux_syncfs 344 +#define LINUX_SYS_linux_sendmmsg 345 +#define LINUX_SYS_linux_setns 346 +#define LINUX_SYS_linux_process_vm_readv 347 +#define LINUX_SYS_linux_process_vm_writev 348 +#define LINUX_SYS_MAXSYSCALL 349 Modified: stable/8/sys/amd64/linux32/linux32_syscalls.c ============================================================================== --- stable/8/sys/amd64/linux32/linux32_syscalls.c Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/amd64/linux32/linux32_syscalls.c Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ const char *linux_syscallnames[] = { @@ -281,7 +281,7 @@ const char *linux_syscallnames[] = { "linux_tgkill", /* 270 = linux_tgkill */ "linux_utimes", /* 271 = linux_utimes */ "linux_fadvise64_64", /* 272 = linux_fadvise64_64 */ - "#273", /* 273 = */ + "#273", /* 273 = vserver */ "linux_mbind", /* 274 = linux_mbind */ "linux_get_mempolicy", /* 275 = linux_get_mempolicy */ "linux_set_mempolicy", /* 276 = linux_set_mempolicy */ @@ -325,4 +325,36 @@ const char *linux_syscallnames[] = { "linux_sync_file_range", /* 314 = linux_sync_file_range */ "linux_tee", /* 315 = linux_tee */ "linux_vmsplice", /* 316 = linux_vmsplice */ + "linux_move_pages", /* 317 = linux_move_pages */ + "linux_getcpu", /* 318 = linux_getcpu */ + "linux_epoll_pwait", /* 319 = linux_epoll_pwait */ + "linux_utimensat", /* 320 = linux_utimensat */ + "linux_signalfd", /* 321 = linux_signalfd */ + "linux_timerfd_create", /* 322 = linux_timerfd_create */ + "linux_eventfd", /* 323 = linux_eventfd */ + "linux_fallocate", /* 324 = linux_fallocate */ + "linux_timerfd_settime", /* 325 = linux_timerfd_settime */ + "linux_timerfd_gettime", /* 326 = linux_timerfd_gettime */ + "linux_signalfd4", /* 327 = linux_signalfd4 */ + "linux_eventfd2", /* 328 = linux_eventfd2 */ + "linux_epoll_create1", /* 329 = linux_epoll_create1 */ + "linux_dup3", /* 330 = linux_dup3 */ + "linux_pipe2", /* 331 = linux_pipe2 */ + "linux_inotify_init1", /* 332 = linux_inotify_init1 */ + "linux_preadv", /* 333 = linux_preadv */ + "linux_pwritev", /* 334 = linux_pwritev */ + "linux_rt_tsigqueueinfo", /* 335 = linux_rt_tsigqueueinfo */ + "linux_perf_event_open", /* 336 = linux_perf_event_open */ + "linux_recvmmsg", /* 337 = linux_recvmmsg */ + "linux_fanotify_init", /* 338 = linux_fanotify_init */ + "linux_fanotify_mark", /* 339 = linux_fanotify_mark */ + "linux_prlimit64", /* 340 = linux_prlimit64 */ + "linux_name_to_handle_at", /* 341 = linux_name_to_handle_at */ + "linux_open_by_handle_at", /* 342 = linux_open_by_handle_at */ + "linux_clock_adjtime", /* 343 = linux_clock_adjtime */ + "linux_syncfs", /* 344 = linux_syncfs */ + "linux_sendmmsg", /* 345 = linux_sendmmsg */ + "linux_setns", /* 346 = linux_setns */ + "linux_process_vm_readv", /* 347 = linux_process_vm_readv */ + "linux_process_vm_writev", /* 348 = linux_process_vm_writev */ }; Modified: stable/8/sys/amd64/linux32/linux32_sysent.c ============================================================================== --- stable/8/sys/amd64/linux32/linux32_sysent.c Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/amd64/linux32/linux32_sysent.c Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/amd64/linux32/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ #include "opt_compat.h" @@ -292,7 +292,7 @@ struct sysent linux_sysent[] = { { AS(linux_tgkill_args), (sy_call_t *)linux_tgkill, AUE_NULL, NULL, 0, 0, 0 }, /* 270 = linux_tgkill */ { AS(linux_utimes_args), (sy_call_t *)linux_utimes, AUE_UTIMES, NULL, 0, 0, 0 }, /* 271 = linux_utimes */ { AS(linux_fadvise64_64_args), (sy_call_t *)linux_fadvise64_64, AUE_NULL, NULL, 0, 0, 0 }, /* 272 = linux_fadvise64_64 */ - { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0 }, /* 273 = */ + { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0 }, /* 273 = vserver */ { 0, (sy_call_t *)linux_mbind, AUE_NULL, NULL, 0, 0, 0 }, /* 274 = linux_mbind */ { 0, (sy_call_t *)linux_get_mempolicy, AUE_NULL, NULL, 0, 0, 0 }, /* 275 = linux_get_mempolicy */ { 0, (sy_call_t *)linux_set_mempolicy, AUE_NULL, NULL, 0, 0, 0 }, /* 276 = linux_set_mempolicy */ @@ -336,4 +336,36 @@ struct sysent linux_sysent[] = { { 0, (sy_call_t *)linux_sync_file_range, AUE_NULL, NULL, 0, 0, 0 }, /* 314 = linux_sync_file_range */ { 0, (sy_call_t *)linux_tee, AUE_NULL, NULL, 0, 0, 0 }, /* 315 = linux_tee */ { 0, (sy_call_t *)linux_vmsplice, AUE_NULL, NULL, 0, 0, 0 }, /* 316 = linux_vmsplice */ + { 0, (sy_call_t *)linux_move_pages, AUE_NULL, NULL, 0, 0, 0 }, /* 317 = linux_move_pages */ + { 0, (sy_call_t *)linux_getcpu, AUE_NULL, NULL, 0, 0, 0 }, /* 318 = linux_getcpu */ + { 0, (sy_call_t *)linux_epoll_pwait, AUE_NULL, NULL, 0, 0, 0 }, /* 319 = linux_epoll_pwait */ + { 0, (sy_call_t *)linux_utimensat, AUE_NULL, NULL, 0, 0, 0 }, /* 320 = linux_utimensat */ + { 0, (sy_call_t *)linux_signalfd, AUE_NULL, NULL, 0, 0, 0 }, /* 321 = linux_signalfd */ + { 0, (sy_call_t *)linux_timerfd_create, AUE_NULL, NULL, 0, 0, 0 }, /* 322 = linux_timerfd_create */ + { 0, (sy_call_t *)linux_eventfd, AUE_NULL, NULL, 0, 0, 0 }, /* 323 = linux_eventfd */ + { 0, (sy_call_t *)linux_fallocate, AUE_NULL, NULL, 0, 0, 0 }, /* 324 = linux_fallocate */ + { 0, (sy_call_t *)linux_timerfd_settime, AUE_NULL, NULL, 0, 0, 0 }, /* 325 = linux_timerfd_settime */ + { 0, (sy_call_t *)linux_timerfd_gettime, AUE_NULL, NULL, 0, 0, 0 }, /* 326 = linux_timerfd_gettime */ + { 0, (sy_call_t *)linux_signalfd4, AUE_NULL, NULL, 0, 0, 0 }, /* 327 = linux_signalfd4 */ + { 0, (sy_call_t *)linux_eventfd2, AUE_NULL, NULL, 0, 0, 0 }, /* 328 = linux_eventfd2 */ + { 0, (sy_call_t *)linux_epoll_create1, AUE_NULL, NULL, 0, 0, 0 }, /* 329 = linux_epoll_create1 */ + { 0, (sy_call_t *)linux_dup3, AUE_NULL, NULL, 0, 0, 0 }, /* 330 = linux_dup3 */ + { 0, (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0 }, /* 331 = linux_pipe2 */ + { 0, (sy_call_t *)linux_inotify_init1, AUE_NULL, NULL, 0, 0, 0 }, /* 332 = linux_inotify_init1 */ + { 0, (sy_call_t *)linux_preadv, AUE_NULL, NULL, 0, 0, 0 }, /* 333 = linux_preadv */ + { 0, (sy_call_t *)linux_pwritev, AUE_NULL, NULL, 0, 0, 0 }, /* 334 = linux_pwritev */ + { 0, (sy_call_t *)linux_rt_tsigqueueinfo, AUE_NULL, NULL, 0, 0, 0 }, /* 335 = linux_rt_tsigqueueinfo */ + { 0, (sy_call_t *)linux_perf_event_open, AUE_NULL, NULL, 0, 0, 0 }, /* 336 = linux_perf_event_open */ + { 0, (sy_call_t *)linux_recvmmsg, AUE_NULL, NULL, 0, 0, 0 }, /* 337 = linux_recvmmsg */ + { 0, (sy_call_t *)linux_fanotify_init, AUE_NULL, NULL, 0, 0, 0 }, /* 338 = linux_fanotify_init */ + { 0, (sy_call_t *)linux_fanotify_mark, AUE_NULL, NULL, 0, 0, 0 }, /* 339 = linux_fanotify_mark */ + { 0, (sy_call_t *)linux_prlimit64, AUE_NULL, NULL, 0, 0, 0 }, /* 340 = linux_prlimit64 */ + { 0, (sy_call_t *)linux_name_to_handle_at, AUE_NULL, NULL, 0, 0, 0 }, /* 341 = linux_name_to_handle_at */ + { 0, (sy_call_t *)linux_open_by_handle_at, AUE_NULL, NULL, 0, 0, 0 }, /* 342 = linux_open_by_handle_at */ + { 0, (sy_call_t *)linux_clock_adjtime, AUE_NULL, NULL, 0, 0, 0 }, /* 343 = linux_clock_adjtime */ + { 0, (sy_call_t *)linux_syncfs, AUE_NULL, NULL, 0, 0, 0 }, /* 344 = linux_syncfs */ + { 0, (sy_call_t *)linux_sendmmsg, AUE_NULL, NULL, 0, 0, 0 }, /* 345 = linux_sendmmsg */ + { 0, (sy_call_t *)linux_setns, AUE_NULL, NULL, 0, 0, 0 }, /* 346 = linux_setns */ + { 0, (sy_call_t *)linux_process_vm_readv, AUE_NULL, NULL, 0, 0, 0 }, /* 347 = linux_process_vm_readv */ + { 0, (sy_call_t *)linux_process_vm_writev, AUE_NULL, NULL, 0, 0, 0 }, /* 348 = linux_process_vm_writev */ }; Modified: stable/8/sys/amd64/linux32/linux32_systrace_args.c ============================================================================== --- stable/8/sys/amd64/linux32/linux32_systrace_args.c Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/amd64/linux32/linux32_systrace_args.c Sun Apr 15 16:56:28 2012 (r234319) @@ -2099,6 +2099,166 @@ systrace_args(int sysnum, void *params, *n_args = 0; break; } + /* linux_move_pages */ + case 317: { + *n_args = 0; + break; + } + /* linux_getcpu */ + case 318: { + *n_args = 0; + break; + } + /* linux_epoll_pwait */ + case 319: { + *n_args = 0; + break; + } + /* linux_utimensat */ + case 320: { + *n_args = 0; + break; + } + /* linux_signalfd */ + case 321: { + *n_args = 0; + break; + } + /* linux_timerfd_create */ + case 322: { + *n_args = 0; + break; + } + /* linux_eventfd */ + case 323: { + *n_args = 0; + break; + } + /* linux_fallocate */ + case 324: { + *n_args = 0; + break; + } + /* linux_timerfd_settime */ + case 325: { + *n_args = 0; + break; + } + /* linux_timerfd_gettime */ + case 326: { + *n_args = 0; + break; + } + /* linux_signalfd4 */ + case 327: { + *n_args = 0; + break; + } + /* linux_eventfd2 */ + case 328: { + *n_args = 0; + break; + } + /* linux_epoll_create1 */ + case 329: { + *n_args = 0; + break; + } + /* linux_dup3 */ + case 330: { + *n_args = 0; + break; + } + /* linux_pipe2 */ + case 331: { + *n_args = 0; + break; + } + /* linux_inotify_init1 */ + case 332: { + *n_args = 0; + break; + } + /* linux_preadv */ + case 333: { + *n_args = 0; + break; + } + /* linux_pwritev */ + case 334: { + *n_args = 0; + break; + } + /* linux_rt_tsigqueueinfo */ + case 335: { + *n_args = 0; + break; + } + /* linux_perf_event_open */ + case 336: { + *n_args = 0; + break; + } + /* linux_recvmmsg */ + case 337: { + *n_args = 0; + break; + } + /* linux_fanotify_init */ + case 338: { + *n_args = 0; + break; + } + /* linux_fanotify_mark */ + case 339: { + *n_args = 0; + break; + } + /* linux_prlimit64 */ + case 340: { + *n_args = 0; + break; + } + /* linux_name_to_handle_at */ + case 341: { + *n_args = 0; + break; + } + /* linux_open_by_handle_at */ + case 342: { + *n_args = 0; + break; + } + /* linux_clock_adjtime */ + case 343: { + *n_args = 0; + break; + } + /* linux_syncfs */ + case 344: { + *n_args = 0; + break; + } + /* linux_sendmmsg */ + case 345: { + *n_args = 0; + break; + } + /* linux_setns */ + case 346: { + *n_args = 0; + break; + } + /* linux_process_vm_readv */ + case 347: { + *n_args = 0; + break; + } + /* linux_process_vm_writev */ + case 348: { + *n_args = 0; + break; + } default: *n_args = 0; break; @@ -5160,6 +5320,102 @@ systrace_setargdesc(int sysnum, int ndx, /* linux_vmsplice */ case 316: break; + /* linux_move_pages */ + case 317: + break; + /* linux_getcpu */ + case 318: + break; + /* linux_epoll_pwait */ + case 319: + break; + /* linux_utimensat */ + case 320: + break; + /* linux_signalfd */ + case 321: + break; + /* linux_timerfd_create */ + case 322: + break; + /* linux_eventfd */ + case 323: + break; + /* linux_fallocate */ + case 324: + break; + /* linux_timerfd_settime */ + case 325: + break; + /* linux_timerfd_gettime */ + case 326: + break; + /* linux_signalfd4 */ + case 327: + break; + /* linux_eventfd2 */ + case 328: + break; + /* linux_epoll_create1 */ + case 329: + break; + /* linux_dup3 */ + case 330: + break; + /* linux_pipe2 */ + case 331: + break; + /* linux_inotify_init1 */ + case 332: + break; + /* linux_preadv */ + case 333: + break; + /* linux_pwritev */ + case 334: + break; + /* linux_rt_tsigqueueinfo */ + case 335: + break; + /* linux_perf_event_open */ + case 336: + break; + /* linux_recvmmsg */ + case 337: + break; + /* linux_fanotify_init */ + case 338: + break; + /* linux_fanotify_mark */ + case 339: + break; + /* linux_prlimit64 */ + case 340: + break; + /* linux_name_to_handle_at */ + case 341: + break; + /* linux_open_by_handle_at */ + case 342: + break; + /* linux_clock_adjtime */ + case 343: + break; + /* linux_syncfs */ + case 344: + break; + /* linux_sendmmsg */ + case 345: + break; + /* linux_setns */ + case 346: + break; + /* linux_process_vm_readv */ + case 347: + break; + /* linux_process_vm_writev */ + case 348: + break; default: break; }; Modified: stable/8/sys/i386/linux/linux_proto.h ============================================================================== --- stable/8/sys/i386/linux/linux_proto.h Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/i386/linux/linux_proto.h Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ #ifndef _LINUX_SYSPROTO_H_ @@ -1020,6 +1020,102 @@ struct linux_tee_args { struct linux_vmsplice_args { register_t dummy; }; +struct linux_move_pages_args { + register_t dummy; +}; +struct linux_getcpu_args { + register_t dummy; +}; +struct linux_epoll_pwait_args { + register_t dummy; +}; +struct linux_utimensat_args { + register_t dummy; +}; +struct linux_signalfd_args { + register_t dummy; +}; +struct linux_timerfd_create_args { + register_t dummy; +}; +struct linux_eventfd_args { + register_t dummy; +}; +struct linux_fallocate_args { + register_t dummy; +}; +struct linux_timerfd_settime_args { + register_t dummy; +}; +struct linux_timerfd_gettime_args { + register_t dummy; +}; +struct linux_signalfd4_args { + register_t dummy; +}; +struct linux_eventfd2_args { + register_t dummy; +}; +struct linux_epoll_create1_args { + register_t dummy; +}; +struct linux_dup3_args { + register_t dummy; +}; +struct linux_pipe2_args { + register_t dummy; +}; +struct linux_inotify_init1_args { + register_t dummy; +}; +struct linux_preadv_args { + register_t dummy; +}; +struct linux_pwritev_args { + register_t dummy; +}; +struct linux_rt_tsigqueueinfo_args { + register_t dummy; +}; +struct linux_perf_event_open_args { + register_t dummy; +}; +struct linux_recvmmsg_args { + register_t dummy; +}; +struct linux_fanotify_init_args { + register_t dummy; +}; +struct linux_fanotify_mark_args { + register_t dummy; +}; +struct linux_prlimit64_args { + register_t dummy; +}; +struct linux_name_to_handle_at_args { + register_t dummy; +}; +struct linux_open_by_handle_at_args { + register_t dummy; +}; +struct linux_clock_adjtime_args { + register_t dummy; +}; +struct linux_syncfs_args { + register_t dummy; +}; +struct linux_sendmmsg_args { + register_t dummy; +}; +struct linux_setns_args { + register_t dummy; +}; +struct linux_process_vm_readv_args { + register_t dummy; +}; +struct linux_process_vm_writev_args { + register_t dummy; +}; #define nosys linux_nosys int linux_fork(struct thread *, struct linux_fork_args *); int linux_open(struct thread *, struct linux_open_args *); @@ -1264,6 +1360,38 @@ int linux_splice(struct thread *, struct int linux_sync_file_range(struct thread *, struct linux_sync_file_range_args *); int linux_tee(struct thread *, struct linux_tee_args *); int linux_vmsplice(struct thread *, struct linux_vmsplice_args *); +int linux_move_pages(struct thread *, struct linux_move_pages_args *); +int linux_getcpu(struct thread *, struct linux_getcpu_args *); +int linux_epoll_pwait(struct thread *, struct linux_epoll_pwait_args *); +int linux_utimensat(struct thread *, struct linux_utimensat_args *); +int linux_signalfd(struct thread *, struct linux_signalfd_args *); +int linux_timerfd_create(struct thread *, struct linux_timerfd_create_args *); +int linux_eventfd(struct thread *, struct linux_eventfd_args *); +int linux_fallocate(struct thread *, struct linux_fallocate_args *); +int linux_timerfd_settime(struct thread *, struct linux_timerfd_settime_args *); +int linux_timerfd_gettime(struct thread *, struct linux_timerfd_gettime_args *); +int linux_signalfd4(struct thread *, struct linux_signalfd4_args *); +int linux_eventfd2(struct thread *, struct linux_eventfd2_args *); +int linux_epoll_create1(struct thread *, struct linux_epoll_create1_args *); +int linux_dup3(struct thread *, struct linux_dup3_args *); +int linux_pipe2(struct thread *, struct linux_pipe2_args *); +int linux_inotify_init1(struct thread *, struct linux_inotify_init1_args *); +int linux_preadv(struct thread *, struct linux_preadv_args *); +int linux_pwritev(struct thread *, struct linux_pwritev_args *); +int linux_rt_tsigqueueinfo(struct thread *, struct linux_rt_tsigqueueinfo_args *); +int linux_perf_event_open(struct thread *, struct linux_perf_event_open_args *); +int linux_recvmmsg(struct thread *, struct linux_recvmmsg_args *); +int linux_fanotify_init(struct thread *, struct linux_fanotify_init_args *); +int linux_fanotify_mark(struct thread *, struct linux_fanotify_mark_args *); +int linux_prlimit64(struct thread *, struct linux_prlimit64_args *); +int linux_name_to_handle_at(struct thread *, struct linux_name_to_handle_at_args *); +int linux_open_by_handle_at(struct thread *, struct linux_open_by_handle_at_args *); +int linux_clock_adjtime(struct thread *, struct linux_clock_adjtime_args *); +int linux_syncfs(struct thread *, struct linux_syncfs_args *); +int linux_sendmmsg(struct thread *, struct linux_sendmmsg_args *); +int linux_setns(struct thread *, struct linux_setns_args *); +int linux_process_vm_readv(struct thread *, struct linux_process_vm_readv_args *); +int linux_process_vm_writev(struct thread *, struct linux_process_vm_writev_args *); #ifdef COMPAT_43 @@ -1535,6 +1663,38 @@ int linux_vmsplice(struct thread *, stru #define LINUX_SYS_AUE_linux_sync_file_range AUE_NULL #define LINUX_SYS_AUE_linux_tee AUE_NULL #define LINUX_SYS_AUE_linux_vmsplice AUE_NULL +#define LINUX_SYS_AUE_linux_move_pages AUE_NULL +#define LINUX_SYS_AUE_linux_getcpu AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_pwait AUE_NULL +#define LINUX_SYS_AUE_linux_utimensat AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_create AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd AUE_NULL +#define LINUX_SYS_AUE_linux_fallocate AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_settime AUE_NULL +#define LINUX_SYS_AUE_linux_timerfd_gettime AUE_NULL +#define LINUX_SYS_AUE_linux_signalfd4 AUE_NULL +#define LINUX_SYS_AUE_linux_eventfd2 AUE_NULL +#define LINUX_SYS_AUE_linux_epoll_create1 AUE_NULL +#define LINUX_SYS_AUE_linux_dup3 AUE_NULL +#define LINUX_SYS_AUE_linux_pipe2 AUE_NULL +#define LINUX_SYS_AUE_linux_inotify_init1 AUE_NULL +#define LINUX_SYS_AUE_linux_preadv AUE_NULL +#define LINUX_SYS_AUE_linux_pwritev AUE_NULL +#define LINUX_SYS_AUE_linux_rt_tsigqueueinfo AUE_NULL +#define LINUX_SYS_AUE_linux_perf_event_open AUE_NULL +#define LINUX_SYS_AUE_linux_recvmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_init AUE_NULL +#define LINUX_SYS_AUE_linux_fanotify_mark AUE_NULL +#define LINUX_SYS_AUE_linux_prlimit64 AUE_NULL +#define LINUX_SYS_AUE_linux_name_to_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_open_by_handle_at AUE_NULL +#define LINUX_SYS_AUE_linux_clock_adjtime AUE_NULL +#define LINUX_SYS_AUE_linux_syncfs AUE_NULL +#define LINUX_SYS_AUE_linux_sendmmsg AUE_NULL +#define LINUX_SYS_AUE_linux_setns AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_readv AUE_NULL +#define LINUX_SYS_AUE_linux_process_vm_writev AUE_NULL #undef PAD_ #undef PADL_ Modified: stable/8/sys/i386/linux/linux_syscall.h ============================================================================== --- stable/8/sys/i386/linux/linux_syscall.h Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/i386/linux/linux_syscall.h Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ #define LINUX_SYS_exit 1 @@ -296,4 +296,36 @@ #define LINUX_SYS_linux_sync_file_range 314 #define LINUX_SYS_linux_tee 315 #define LINUX_SYS_linux_vmsplice 316 -#define LINUX_SYS_MAXSYSCALL 317 +#define LINUX_SYS_linux_move_pages 317 +#define LINUX_SYS_linux_getcpu 318 +#define LINUX_SYS_linux_epoll_pwait 319 +#define LINUX_SYS_linux_utimensat 320 +#define LINUX_SYS_linux_signalfd 321 +#define LINUX_SYS_linux_timerfd_create 322 +#define LINUX_SYS_linux_eventfd 323 +#define LINUX_SYS_linux_fallocate 324 +#define LINUX_SYS_linux_timerfd_settime 325 +#define LINUX_SYS_linux_timerfd_gettime 326 +#define LINUX_SYS_linux_signalfd4 327 +#define LINUX_SYS_linux_eventfd2 328 +#define LINUX_SYS_linux_epoll_create1 329 +#define LINUX_SYS_linux_dup3 330 +#define LINUX_SYS_linux_pipe2 331 +#define LINUX_SYS_linux_inotify_init1 332 +#define LINUX_SYS_linux_preadv 333 +#define LINUX_SYS_linux_pwritev 334 +#define LINUX_SYS_linux_rt_tsigqueueinfo 335 +#define LINUX_SYS_linux_perf_event_open 336 +#define LINUX_SYS_linux_recvmmsg 337 +#define LINUX_SYS_linux_fanotify_init 338 +#define LINUX_SYS_linux_fanotify_mark 339 +#define LINUX_SYS_linux_prlimit64 340 +#define LINUX_SYS_linux_name_to_handle_at 341 +#define LINUX_SYS_linux_open_by_handle_at 342 +#define LINUX_SYS_linux_clock_adjtime 343 +#define LINUX_SYS_linux_syncfs 344 +#define LINUX_SYS_linux_sendmmsg 345 +#define LINUX_SYS_linux_setns 346 +#define LINUX_SYS_linux_process_vm_readv 347 +#define LINUX_SYS_linux_process_vm_writev 348 +#define LINUX_SYS_MAXSYSCALL 349 Modified: stable/8/sys/i386/linux/linux_syscalls.c ============================================================================== --- stable/8/sys/i386/linux/linux_syscalls.c Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/i386/linux/linux_syscalls.c Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ const char *linux_syscallnames[] = { @@ -281,7 +281,7 @@ const char *linux_syscallnames[] = { "linux_tgkill", /* 270 = linux_tgkill */ "linux_utimes", /* 271 = linux_utimes */ "linux_fadvise64_64", /* 272 = linux_fadvise64_64 */ - "#273", /* 273 = */ + "#273", /* 273 = vserver */ "linux_mbind", /* 274 = linux_mbind */ "linux_get_mempolicy", /* 275 = linux_get_mempolicy */ "linux_set_mempolicy", /* 276 = linux_set_mempolicy */ @@ -325,4 +325,36 @@ const char *linux_syscallnames[] = { "linux_sync_file_range", /* 314 = linux_sync_file_range */ "linux_tee", /* 315 = linux_tee */ "linux_vmsplice", /* 316 = linux_vmsplice */ + "linux_move_pages", /* 317 = linux_move_pages */ + "linux_getcpu", /* 318 = linux_getcpu */ + "linux_epoll_pwait", /* 319 = linux_epoll_pwait */ + "linux_utimensat", /* 320 = linux_utimensat */ + "linux_signalfd", /* 321 = linux_signalfd */ + "linux_timerfd_create", /* 322 = linux_timerfd_create */ + "linux_eventfd", /* 323 = linux_eventfd */ + "linux_fallocate", /* 324 = linux_fallocate */ + "linux_timerfd_settime", /* 325 = linux_timerfd_settime */ + "linux_timerfd_gettime", /* 326 = linux_timerfd_gettime */ + "linux_signalfd4", /* 327 = linux_signalfd4 */ + "linux_eventfd2", /* 328 = linux_eventfd2 */ + "linux_epoll_create1", /* 329 = linux_epoll_create1 */ + "linux_dup3", /* 330 = linux_dup3 */ + "linux_pipe2", /* 331 = linux_pipe2 */ + "linux_inotify_init1", /* 332 = linux_inotify_init1 */ + "linux_preadv", /* 333 = linux_preadv */ + "linux_pwritev", /* 334 = linux_pwritev */ + "linux_rt_tsigqueueinfo", /* 335 = linux_rt_tsigqueueinfo */ + "linux_perf_event_open", /* 336 = linux_perf_event_open */ + "linux_recvmmsg", /* 337 = linux_recvmmsg */ + "linux_fanotify_init", /* 338 = linux_fanotify_init */ + "linux_fanotify_mark", /* 339 = linux_fanotify_mark */ + "linux_prlimit64", /* 340 = linux_prlimit64 */ + "linux_name_to_handle_at", /* 341 = linux_name_to_handle_at */ + "linux_open_by_handle_at", /* 342 = linux_open_by_handle_at */ + "linux_clock_adjtime", /* 343 = linux_clock_adjtime */ + "linux_syncfs", /* 344 = linux_syncfs */ + "linux_sendmmsg", /* 345 = linux_sendmmsg */ + "linux_setns", /* 346 = linux_setns */ + "linux_process_vm_readv", /* 347 = linux_process_vm_readv */ + "linux_process_vm_writev", /* 348 = linux_process_vm_writev */ }; Modified: stable/8/sys/i386/linux/linux_sysent.c ============================================================================== --- stable/8/sys/i386/linux/linux_sysent.c Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/i386/linux/linux_sysent.c Sun Apr 15 16:56:28 2012 (r234319) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 231146 2012-02-07 19:12:21Z jhb + * created from FreeBSD: stable/8/sys/i386/linux/syscalls.master 234318 2012-04-15 16:55:26Z netchild */ #include @@ -291,7 +291,7 @@ struct sysent linux_sysent[] = { { AS(linux_tgkill_args), (sy_call_t *)linux_tgkill, AUE_NULL, NULL, 0, 0, 0 }, /* 270 = linux_tgkill */ { AS(linux_utimes_args), (sy_call_t *)linux_utimes, AUE_UTIMES, NULL, 0, 0, 0 }, /* 271 = linux_utimes */ { AS(linux_fadvise64_64_args), (sy_call_t *)linux_fadvise64_64, AUE_NULL, NULL, 0, 0, 0 }, /* 272 = linux_fadvise64_64 */ - { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0 }, /* 273 = */ + { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0 }, /* 273 = vserver */ { 0, (sy_call_t *)linux_mbind, AUE_NULL, NULL, 0, 0, 0 }, /* 274 = linux_mbind */ { 0, (sy_call_t *)linux_get_mempolicy, AUE_NULL, NULL, 0, 0, 0 }, /* 275 = linux_get_mempolicy */ { 0, (sy_call_t *)linux_set_mempolicy, AUE_NULL, NULL, 0, 0, 0 }, /* 276 = linux_set_mempolicy */ @@ -335,4 +335,36 @@ struct sysent linux_sysent[] = { { 0, (sy_call_t *)linux_sync_file_range, AUE_NULL, NULL, 0, 0, 0 }, /* 314 = linux_sync_file_range */ { 0, (sy_call_t *)linux_tee, AUE_NULL, NULL, 0, 0, 0 }, /* 315 = linux_tee */ { 0, (sy_call_t *)linux_vmsplice, AUE_NULL, NULL, 0, 0, 0 }, /* 316 = linux_vmsplice */ + { 0, (sy_call_t *)linux_move_pages, AUE_NULL, NULL, 0, 0, 0 }, /* 317 = linux_move_pages */ + { 0, (sy_call_t *)linux_getcpu, AUE_NULL, NULL, 0, 0, 0 }, /* 318 = linux_getcpu */ + { 0, (sy_call_t *)linux_epoll_pwait, AUE_NULL, NULL, 0, 0, 0 }, /* 319 = linux_epoll_pwait */ + { 0, (sy_call_t *)linux_utimensat, AUE_NULL, NULL, 0, 0, 0 }, /* 320 = linux_utimensat */ + { 0, (sy_call_t *)linux_signalfd, AUE_NULL, NULL, 0, 0, 0 }, /* 321 = linux_signalfd */ + { 0, (sy_call_t *)linux_timerfd_create, AUE_NULL, NULL, 0, 0, 0 }, /* 322 = linux_timerfd_create */ + { 0, (sy_call_t *)linux_eventfd, AUE_NULL, NULL, 0, 0, 0 }, /* 323 = linux_eventfd */ + { 0, (sy_call_t *)linux_fallocate, AUE_NULL, NULL, 0, 0, 0 }, /* 324 = linux_fallocate */ + { 0, (sy_call_t *)linux_timerfd_settime, AUE_NULL, NULL, 0, 0, 0 }, /* 325 = linux_timerfd_settime */ + { 0, (sy_call_t *)linux_timerfd_gettime, AUE_NULL, NULL, 0, 0, 0 }, /* 326 = linux_timerfd_gettime */ + { 0, (sy_call_t *)linux_signalfd4, AUE_NULL, NULL, 0, 0, 0 }, /* 327 = linux_signalfd4 */ + { 0, (sy_call_t *)linux_eventfd2, AUE_NULL, NULL, 0, 0, 0 }, /* 328 = linux_eventfd2 */ + { 0, (sy_call_t *)linux_epoll_create1, AUE_NULL, NULL, 0, 0, 0 }, /* 329 = linux_epoll_create1 */ + { 0, (sy_call_t *)linux_dup3, AUE_NULL, NULL, 0, 0, 0 }, /* 330 = linux_dup3 */ + { 0, (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0 }, /* 331 = linux_pipe2 */ + { 0, (sy_call_t *)linux_inotify_init1, AUE_NULL, NULL, 0, 0, 0 }, /* 332 = linux_inotify_init1 */ + { 0, (sy_call_t *)linux_preadv, AUE_NULL, NULL, 0, 0, 0 }, /* 333 = linux_preadv */ + { 0, (sy_call_t *)linux_pwritev, AUE_NULL, NULL, 0, 0, 0 }, /* 334 = linux_pwritev */ + { 0, (sy_call_t *)linux_rt_tsigqueueinfo, AUE_NULL, NULL, 0, 0, 0 }, /* 335 = linux_rt_tsigqueueinfo */ + { 0, (sy_call_t *)linux_perf_event_open, AUE_NULL, NULL, 0, 0, 0 }, /* 336 = linux_perf_event_open */ + { 0, (sy_call_t *)linux_recvmmsg, AUE_NULL, NULL, 0, 0, 0 }, /* 337 = linux_recvmmsg */ + { 0, (sy_call_t *)linux_fanotify_init, AUE_NULL, NULL, 0, 0, 0 }, /* 338 = linux_fanotify_init */ + { 0, (sy_call_t *)linux_fanotify_mark, AUE_NULL, NULL, 0, 0, 0 }, /* 339 = linux_fanotify_mark */ + { 0, (sy_call_t *)linux_prlimit64, AUE_NULL, NULL, 0, 0, 0 }, /* 340 = linux_prlimit64 */ + { 0, (sy_call_t *)linux_name_to_handle_at, AUE_NULL, NULL, 0, 0, 0 }, /* 341 = linux_name_to_handle_at */ + { 0, (sy_call_t *)linux_open_by_handle_at, AUE_NULL, NULL, 0, 0, 0 }, /* 342 = linux_open_by_handle_at */ + { 0, (sy_call_t *)linux_clock_adjtime, AUE_NULL, NULL, 0, 0, 0 }, /* 343 = linux_clock_adjtime */ + { 0, (sy_call_t *)linux_syncfs, AUE_NULL, NULL, 0, 0, 0 }, /* 344 = linux_syncfs */ + { 0, (sy_call_t *)linux_sendmmsg, AUE_NULL, NULL, 0, 0, 0 }, /* 345 = linux_sendmmsg */ + { 0, (sy_call_t *)linux_setns, AUE_NULL, NULL, 0, 0, 0 }, /* 346 = linux_setns */ + { 0, (sy_call_t *)linux_process_vm_readv, AUE_NULL, NULL, 0, 0, 0 }, /* 347 = linux_process_vm_readv */ + { 0, (sy_call_t *)linux_process_vm_writev, AUE_NULL, NULL, 0, 0, 0 }, /* 348 = linux_process_vm_writev */ }; Modified: stable/8/sys/i386/linux/linux_systrace_args.c ============================================================================== --- stable/8/sys/i386/linux/linux_systrace_args.c Sun Apr 15 16:55:26 2012 (r234318) +++ stable/8/sys/i386/linux/linux_systrace_args.c Sun Apr 15 16:56:28 2012 (r234319) @@ -2190,6 +2190,166 @@ systrace_args(int sysnum, void *params, *n_args = 0; break; } + /* linux_move_pages */ + case 317: { + *n_args = 0; + break; + } + /* linux_getcpu */ + case 318: { + *n_args = 0; + break; + } + /* linux_epoll_pwait */ + case 319: { *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 17:28:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C72F1106566B; Sun, 15 Apr 2012 17:28:47 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B24368FC08; Sun, 15 Apr 2012 17:28:47 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FHSlmK094624; Sun, 15 Apr 2012 17:28:47 GMT (envelope-from madpilot@svn.freebsd.org) Received: (from madpilot@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FHSlSg094622; Sun, 15 Apr 2012 17:28:47 GMT (envelope-from madpilot@svn.freebsd.org) Message-Id: <201204151728.q3FHSlSg094622@svn.freebsd.org> From: Guido Falsi Date: Sun, 15 Apr 2012 17:28: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: r234320 - head/usr.bin/calendar/calendars X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 17:28:47 -0000 Author: madpilot (ports committer) Date: Sun Apr 15 17:28:47 2012 New Revision: 234320 URL: http://svn.freebsd.org/changeset/base/234320 Log: Add myself to the calendar Approved by: creees (mentor) Modified: head/usr.bin/calendar/calendars/calendar.freebsd Modified: head/usr.bin/calendar/calendars/calendar.freebsd ============================================================================== --- head/usr.bin/calendar/calendars/calendar.freebsd Sun Apr 15 16:56:28 2012 (r234319) +++ head/usr.bin/calendar/calendars/calendar.freebsd Sun Apr 15 17:28:47 2012 (r234320) @@ -345,6 +345,7 @@ 12/22 Maxim Sobolev born in Dnepropetrovsk, Ukraine, 1976 12/23 Sean Chittenden born in Seattle, Washington, United States, 1979 12/23 Alejandro Pulver born in Buenos Aires, Argentina, 1989 +12/24 Guido Falsi born in Firenze, Italy, 1978 12/28 Soren Schmidt born in Maribo, Denmark, 1960 12/28 Ade Lovett born in London, England, 1969 12/28 Marius Strobl born in Cham, Bavaria, Germany, 1978 From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 18:25:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7ADD0106564A; Sun, 15 Apr 2012 18:25:18 +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 66DCE8FC08; Sun, 15 Apr 2012 18:25:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FIPIQq096517; Sun, 15 Apr 2012 18:25:18 GMT (envelope-from bschmidt@svn.freebsd.org) Received: (from bschmidt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FIPIMr096514; Sun, 15 Apr 2012 18:25:18 GMT (envelope-from bschmidt@svn.freebsd.org) Message-Id: <201204151825.q3FIPIMr096514@svn.freebsd.org> From: Bernhard Schmidt Date: Sun, 15 Apr 2012 18:25: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: r234321 - head/sys/dev/iwn X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 18:25:18 -0000 Author: bschmidt Date: Sun Apr 15 18:25:17 2012 New Revision: 234321 URL: http://svn.freebsd.org/changeset/base/234321 Log: Use the M_AMPDU_MPDU flag to determine when to manually set the seqno and use a BA queue. Modified: head/sys/dev/iwn/if_iwn.c Modified: head/sys/dev/iwn/if_iwn.c ============================================================================== --- head/sys/dev/iwn/if_iwn.c Sun Apr 15 17:28:47 2012 (r234320) +++ head/sys/dev/iwn/if_iwn.c Sun Apr 15 18:25:17 2012 (r234321) @@ -3308,18 +3308,15 @@ iwn_tx_data(struct iwn_softc *sc, struct tid = 0; } ac = M_WME_GETAC(m); - - if (IEEE80211_QOS_HAS_SEQ(wh) && - IEEE80211_AMPDU_RUNNING(&ni->ni_tx_ampdu[ac])) { + if (m->m_flags & M_AMPDU_MPDU) { struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[ac]; - ring = &sc->txq[*(int *)tap->txa_private]; + ac = *(int *)tap->txa_private; *(uint16_t *)wh->i_seq = htole16(ni->ni_txseqs[tid] << IEEE80211_SEQ_SEQ_SHIFT); ni->ni_txseqs[tid]++; - } else { - ring = &sc->txq[ac]; } + ring = &sc->txq[ac]; desc = &ring->desc[ring->cur]; data = &ring->data[ring->cur]; From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 18:32:15 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9CE51106566C; Sun, 15 Apr 2012 18:32:15 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7D9318FC0A; Sun, 15 Apr 2012 18:32:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FIWF0N096761; Sun, 15 Apr 2012 18:32:15 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FIWFK3096759; Sun, 15 Apr 2012 18:32:15 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201204151832.q3FIWFK3096759@svn.freebsd.org> From: Baptiste Daroussin Date: Sun, 15 Apr 2012 18:32: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: r234322 - head/usr.sbin/pkg X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 18:32:15 -0000 Author: bapt Date: Sun Apr 15 18:32:14 2012 New Revision: 234322 URL: http://svn.freebsd.org/changeset/base/234322 Log: - Fix style(9) bugs + inconsistencies Submitted by: marius Approved by: des (mentor) Modified: head/usr.sbin/pkg/pkg.c Modified: head/usr.sbin/pkg/pkg.c ============================================================================== --- head/usr.sbin/pkg/pkg.c Sun Apr 15 18:25:17 2012 (r234321) +++ head/usr.sbin/pkg/pkg.c Sun Apr 15 18:32:14 2012 (r234322) @@ -27,11 +27,10 @@ #include __FBSDID("$FreeBSD$"); -#include -#include #include #include #include +#include #include #include @@ -39,13 +38,13 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include #include #include #include -#include #include "elf_tables.h" @@ -54,7 +53,7 @@ __FBSDID("$FreeBSD$"); #define _DEFAULT_TMP "/tmp" static const char * -elf_corres_to_string(struct _elf_corres* m, int e) +elf_corres_to_string(struct _elf_corres *m, int e) { int i; @@ -85,13 +84,14 @@ pkg_get_myabi(char *dest, size_t sz) abi = NULL; if (elf_version(EV_CURRENT) == EV_NONE) { - warnx("ELF library initialization failed: %s", elf_errmsg(-1)); - return -1; + warnx("ELF library initialization failed: %s", + elf_errmsg(-1)); + return (-1); } if ((fd = open("/bin/sh", O_RDONLY)) < 0) { warn("open()"); - return -1; + return (-1); } if ((elf = elf_begin(fd, ELF_C_READ, NULL)) == NULL) { @@ -143,22 +143,20 @@ pkg_get_myabi(char *dest, size_t sz) osname[i] = (char)tolower(osname[i]); snprintf(dest, sz, "%s:%d:%s:%s", - osname, - version / 100000, - elf_corres_to_string(mach_corres, (int) elfhdr.e_machine), + osname, version / 100000, + elf_corres_to_string(mach_corres, (int)elfhdr.e_machine), elf_corres_to_string(wordsize_corres, - (int)elfhdr.e_ident[EI_CLASS])); + (int)elfhdr.e_ident[EI_CLASS])); switch (elfhdr.e_machine) { case EM_ARM: snprintf(dest + strlen(dest), sz - strlen(dest), - ":%s:%s:%s", - elf_corres_to_string(endian_corres, - (int) elfhdr.e_ident[EI_DATA]), + ":%s:%s:%s", elf_corres_to_string(endian_corres, + (int)elfhdr.e_ident[EI_DATA]), (elfhdr.e_flags & EF_ARM_NEW_ABI) > 0 ? - "eabi" : "oabi", + "eabi" : "oabi", (elfhdr.e_flags & EF_ARM_VFP_FLOAT) > 0 ? - "softfp" : "vfp"); + "softfp" : "vfp"); break; case EM_MIPS: /* @@ -184,10 +182,8 @@ pkg_get_myabi(char *dest, size_t sz) break; } snprintf(dest + strlen(dest), sz - strlen(dest), - ":%s:%s", - elf_corres_to_string(endian_corres, - (int) elfhdr.e_ident[EI_DATA]), - abi); + ":%s:%s", elf_corres_to_string(endian_corres, + (int)elfhdr.e_ident[EI_DATA]), abi); break; } @@ -229,9 +225,9 @@ extract_pkg_static(int fd, char *p, int if (strcmp(end, "/pkg-static") == 0) { r = archive_read_extract(a, ae, - ARCHIVE_EXTRACT_OWNER |ARCHIVE_EXTRACT_PERM| - ARCHIVE_EXTRACT_TIME |ARCHIVE_EXTRACT_ACL | - ARCHIVE_EXTRACT_FFLAGS|ARCHIVE_EXTRACT_XATTR); + ARCHIVE_EXTRACT_OWNER | ARCHIVE_EXTRACT_PERM | + ARCHIVE_EXTRACT_TIME | ARCHIVE_EXTRACT_ACL | + ARCHIVE_EXTRACT_FFLAGS | ARCHIVE_EXTRACT_XATTR); snprintf(p, sz, archive_entry_pathname(ae)); break; } @@ -244,7 +240,7 @@ extract_pkg_static(int fd, char *p, int cleanup: archive_read_finish(a); - return ret; + return (ret); } @@ -258,8 +254,9 @@ install_pkg_static(char *path, char *pkg case -1: return (-1); case 0: - execl(path, "pkg-static", "add", pkgpath, (char *)NULL); - _exit(1); /* NOT REACHED */ + execl(path, "pkg-static", "add", pkgpath, + (char *)NULL); + _exit(1); default: break; } @@ -297,7 +294,7 @@ bootstrap_pkg(void) if (pkg_get_myabi(abi, MAXPATHLEN) != 0) { warnx("fail to determine my abi"); - return -1; + return (-1); } if (getenv("PACKAGESITE") != NULL) { @@ -314,7 +311,7 @@ bootstrap_pkg(void) if ((fd = mkstemp(tmppkg)) == -1) { warn("mkstemp()"); - return -1; + return (-1); } while (remote == NULL) { @@ -363,21 +360,21 @@ cleanup: close(fd); unlink(tmppkg); - return 0; + return (0); } int -main(__unused int argc, char * argv[]) +main(__unused int argc, char *argv[]) { char pkgpath[MAXPATHLEN]; snprintf(pkgpath, MAXPATHLEN, "%s/sbin/pkg", - getenv("LOCALBASE") ? getenv("LOCALBASE"): _LOCALBASE); + getenv("LOCALBASE") ? getenv("LOCALBASE") : _LOCALBASE); if (access(pkgpath, X_OK) == -1) bootstrap_pkg(); execv(pkgpath, argv); - return (EXIT_SUCCESS); + return (EXIT_FAILURE); } From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 18:38:51 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C39E4106566B for ; Sun, 15 Apr 2012 18:38:51 +0000 (UTC) (envelope-from andrey@zonov.org) Received: from mail-lpp01m010-f54.google.com (mail-lpp01m010-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 3A06C8FC12 for ; Sun, 15 Apr 2012 18:38:51 +0000 (UTC) Received: by lagv3 with SMTP id v3so4418461lag.13 for ; Sun, 15 Apr 2012 11:38:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding :x-gm-message-state; bh=LP9z+4GdL9ButSHarlyMITEUWbx/0WfmFlnpg7W3rWw=; b=Lr23tYQcl14m4CM4HlGieQiD7ws5pAdmlfrG1yzLdHrL4icpS/iBjWtns2GEhuotlD +5S87++ueuqwQ+mKMaRHQ24fEYlAKNjhF/XKTpjyKhCgSjLTfzly+3FNFStTCzXU8xzG 14hRRIp4R76eXj7+KV28Lemw5CxwuF2Ltv1TcO0x+9JdymQAw2CmvU+hqIFRndMT1yUT zjUPl7SZCjPXkp70eooa9uPmp9lv/0DPOXRxBiF+NNpju2q1ADO9tNQyvs8ZehTuTFod O5uYfUCvB6V+K43c2lHZqzta0rV65fOVov7beGGw8lx6KCylzC8V0CFyrMcN4j6Da2u6 ATCg== Received: by 10.152.148.234 with SMTP id tv10mr7992210lab.41.1334515129842; Sun, 15 Apr 2012 11:38:49 -0700 (PDT) Received: from [10.254.254.77] (ppp95-165-130-108.pppoe.spdop.ru. [95.165.130.108]) by mx.google.com with ESMTPS id w10sm21327828lbe.14.2012.04.15.11.38.48 (version=SSLv3 cipher=OTHER); Sun, 15 Apr 2012 11:38:49 -0700 (PDT) Message-ID: <4F8B15B2.9090200@zonov.org> Date: Sun, 15 Apr 2012 22:38:42 +0400 From: Andrey Zonov User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; ru; rv:1.8.1.24) Gecko/20100228 Thunderbird/2.0.0.24 Mnenhy/0.7.6.0 MIME-Version: 1.0 To: Alexander Leidinger References: <201204151652.q3FGqns5093271@svn.freebsd.org> In-Reply-To: <201204151652.q3FGqns5093271@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Gm-Message-State: ALoCoQnRU79johuxJdMNu37vjYg57cGUhzvcrHNfsVblOBG22Q9yAwnK/3ch5tnUypLUs8zjN1KB Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r234316 - in stable/9/sys: amd64/linux32 i386/conf i386/linux kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 18:38:51 -0000 On 15.04.2012 20:52, Alexander Leidinger wrote: > Author: netchild > Date: Sun Apr 15 16:52:48 2012 > New Revision: 234316 > URL: http://svn.freebsd.org/changeset/base/234316 > > Log: > MFC r232799: > - add comments to syscalls.master and linux(32)_dummy about which linux > kernel version introduced the sysctl (based upon a linux man-page) > - add comments to syscalls.master regarding some names of sysctls which are > different than the linux-names (based upon the linux unistd.h) > - add some dummy sysctls > - name an unimplemented sysctl > Did you mean s/sysctl/syscall/? -- Andrey Zonov From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 19:07:41 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2ABD4106566C; Sun, 15 Apr 2012 19:07:41 +0000 (UTC) (envelope-from alexander@leidinger.net) Received: from mail.ebusiness-leidinger.de (mail.ebusiness-leidinger.de [217.11.53.44]) by mx1.freebsd.org (Postfix) with ESMTP id D0A5C8FC14; Sun, 15 Apr 2012 19:07:40 +0000 (UTC) Received: from outgoing.leidinger.net (p4FC432C0.dip.t-dialin.net [79.196.50.192]) by mail.ebusiness-leidinger.de (Postfix) with ESMTPSA id 15612844109; Sun, 15 Apr 2012 21:07:25 +0200 (CEST) Received: from unknown (IO.Leidinger.net [192.168.1.12]) by outgoing.leidinger.net (Postfix) with ESMTPS id 4BF3920BA; Sun, 15 Apr 2012 21:07:22 +0200 (CEST) Date: Sun, 15 Apr 2012 21:07:19 +0200 From: Alexander Leidinger To: Andrey Zonov Message-ID: <20120415210719.000031c7@unknown> In-Reply-To: <4F8B15B2.9090200@zonov.org> References: <201204151652.q3FGqns5093271@svn.freebsd.org> <4F8B15B2.9090200@zonov.org> X-Mailer: Claws Mail 3.7.10cvs42 (GTK+ 2.16.6; i586-pc-mingw32msvc) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-EBL-MailScanner-Information: Please contact the ISP for more information X-EBL-MailScanner-ID: 15612844109.A2AC5 X-EBL-MailScanner: Found to be clean X-EBL-MailScanner-SpamCheck: not spam, spamhaus-ZEN, SpamAssassin (not cached, score=-0.467, required 6, autolearn=disabled, ALL_TRUSTED -1.00, AWL -0.13, J_CHICKENPOX_45 0.60, TW_SV 0.08, T_RP_MATCHES_RCVD -0.01) X-EBL-MailScanner-From: alexander@leidinger.net X-EBL-MailScanner-Watermark: 1335121648.36859@flOU3YLs5YI5fKQ8yvvRVw X-EBL-Spam-Status: No Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Alexander Leidinger , svn-src-stable-9@freebsd.org Subject: Re: svn commit: r234316 - in stable/9/sys: amd64/linux32 i386/conf i386/linux kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 19:07:41 -0000 On Sun, 15 Apr 2012 22:38:42 +0400 Andrey Zonov wrote: > On 15.04.2012 20:52, Alexander Leidinger wrote: > > Author: netchild > > Date: Sun Apr 15 16:52:48 2012 > > New Revision: 234316 > > URL: http://svn.freebsd.org/changeset/base/234316 > > > > Log: > > MFC r232799: > > - add comments to syscalls.master and linux(32)_dummy about > > which linux kernel version introduced the sysctl (based upon a > > linux man-page) > > - add comments to syscalls.master regarding some names of > > sysctls which are different than the linux-names (based upon the > > linux unistd.h) > > - add some dummy sysctls > > - name an unimplemented sysctl > > > > Did you mean s/sysctl/syscall/? Yes, I already did it wrong in the original commit and overlooked it in the copy&paste (while fixing another typo). But it is obvious from the context of the change that it has to be "syscall" (sysctls do not belong into syscalls.master). Bye, Alexander. -- http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID = B0063FE7 http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID = 72077137 From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 19:54:22 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E62B71065673; Sun, 15 Apr 2012 19:54:22 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D18BF8FC15; Sun, 15 Apr 2012 19:54:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FJsMQb099283; Sun, 15 Apr 2012 19:54:22 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FJsMqd099281; Sun, 15 Apr 2012 19:54:22 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204151954.q3FJsMqd099281@svn.freebsd.org> From: Adrian Chadd Date: Sun, 15 Apr 2012 19:54: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: r234323 - head/sys/dev/ath X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 19:54:23 -0000 Author: adrian Date: Sun Apr 15 19:54:22 2012 New Revision: 234323 URL: http://svn.freebsd.org/changeset/base/234323 Log: Drop this down from 512 to 128 for now. This may result in a bit of a throughput drop. However, any throughput drop at this point should be investigated and root caused, as it's likely because TX scheduling (all the way down to how preemption, scheduler work, etc) is happening in a sub-optimal fashion. This also makes it much more likely to be reloadable on a live machine. Allocating 5120 TX ath_buf entries via contigmalloc is very unlikely after a few hours of using X/Chromium. Modified: head/sys/dev/ath/if_athvar.h Modified: head/sys/dev/ath/if_athvar.h ============================================================================== --- head/sys/dev/ath/if_athvar.h Sun Apr 15 18:32:14 2012 (r234322) +++ head/sys/dev/ath/if_athvar.h Sun Apr 15 19:54:22 2012 (r234323) @@ -47,7 +47,7 @@ * 802.11n requires more TX and RX buffers to do AMPDU. */ #ifdef ATH_ENABLE_11N -#define ATH_TXBUF 512 +#define ATH_TXBUF 128 #define ATH_RXBUF 512 #endif From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 20:29:40 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CA940106564A; Sun, 15 Apr 2012 20:29:40 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B42F88FC18; Sun, 15 Apr 2012 20:29:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FKTeqj000564; Sun, 15 Apr 2012 20:29:40 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FKTeAk000552; Sun, 15 Apr 2012 20:29:40 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204152029.q3FKTeAk000552@svn.freebsd.org> From: Adrian Chadd Date: Sun, 15 Apr 2012 20:29: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: r234324 - in head/sys: dev/ath dev/iwn dev/mwl net80211 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 20:29:40 -0000 Author: adrian Date: Sun Apr 15 20:29:39 2012 New Revision: 234324 URL: http://svn.freebsd.org/changeset/base/234324 Log: Migrate the net80211 TX aggregation state to be from per-AC to per-TID. TODO: * Test mwl(4) more thoroughly! Reviewed by: bschmidt (for iwn) Modified: head/sys/dev/ath/if_ath_tx.c head/sys/dev/iwn/if_iwn.c head/sys/dev/mwl/if_mwl.c head/sys/dev/mwl/if_mwlvar.h head/sys/net80211/ieee80211_ddb.c head/sys/net80211/ieee80211_ht.c head/sys/net80211/ieee80211_ht.h head/sys/net80211/ieee80211_node.h head/sys/net80211/ieee80211_output.c head/sys/net80211/ieee80211_superg.c Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/dev/ath/if_ath_tx.c Sun Apr 15 20:29:39 2012 (r234324) @@ -4214,14 +4214,11 @@ ath_tx_get_tx_tid(struct ath_node *an, i { struct ieee80211_node *ni = &an->an_node; struct ieee80211_tx_ampdu *tap; - int ac; if (tid == IEEE80211_NONQOS_TID) return NULL; - ac = TID_TO_WME_AC(tid); - - tap = &ni->ni_tx_ampdu[ac]; + tap = &ni->ni_tx_ampdu[tid]; return tap; } @@ -4279,7 +4276,7 @@ ath_addba_request(struct ieee80211_node int dialogtoken, int baparamset, int batimeout) { struct ath_softc *sc = ni->ni_ic->ic_ifp->if_softc; - int tid = WME_AC_TO_TID(tap->txa_ac); + int tid = tap->txa_tid; struct ath_node *an = ATH_NODE(ni); struct ath_tid *atid = &an->an_tid[tid]; @@ -4346,7 +4343,7 @@ ath_addba_response(struct ieee80211_node int status, int code, int batimeout) { struct ath_softc *sc = ni->ni_ic->ic_ifp->if_softc; - int tid = WME_AC_TO_TID(tap->txa_ac); + int tid = tap->txa_tid; struct ath_node *an = ATH_NODE(ni); struct ath_tid *atid = &an->an_tid[tid]; int r; @@ -4387,7 +4384,7 @@ void ath_addba_stop(struct ieee80211_node *ni, struct ieee80211_tx_ampdu *tap) { struct ath_softc *sc = ni->ni_ic->ic_ifp->if_softc; - int tid = WME_AC_TO_TID(tap->txa_ac); + int tid = tap->txa_tid; struct ath_node *an = ATH_NODE(ni); struct ath_tid *atid = &an->an_tid[tid]; @@ -4424,7 +4421,7 @@ ath_bar_response(struct ieee80211_node * int status) { struct ath_softc *sc = ni->ni_ic->ic_ifp->if_softc; - int tid = WME_AC_TO_TID(tap->txa_ac); + int tid = tap->txa_tid; struct ath_node *an = ATH_NODE(ni); struct ath_tid *atid = &an->an_tid[tid]; int attempts = tap->txa_attempts; @@ -4457,7 +4454,7 @@ ath_addba_response_timeout(struct ieee80 struct ieee80211_tx_ampdu *tap) { struct ath_softc *sc = ni->ni_ic->ic_ifp->if_softc; - int tid = WME_AC_TO_TID(tap->txa_ac); + int tid = tap->txa_tid; struct ath_node *an = ATH_NODE(ni); struct ath_tid *atid = &an->an_tid[tid]; Modified: head/sys/dev/iwn/if_iwn.c ============================================================================== --- head/sys/dev/iwn/if_iwn.c Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/dev/iwn/if_iwn.c Sun Apr 15 20:29:39 2012 (r234324) @@ -2445,7 +2445,7 @@ iwn_rx_compressed_ba(struct iwn_softc *s txq = &sc->txq[le16toh(ba->qid)]; tap = sc->qid2tap[le16toh(ba->qid)]; - tid = WME_AC_TO_TID(tap->txa_ac); + tid = tap->txa_tid; ni = tap->txa_ni; wn = (void *)ni; @@ -2804,7 +2804,7 @@ iwn_ampdu_tx_done(struct iwn_softc *sc, } tap = sc->qid2tap[qid]; if (tap != NULL) { - tid = WME_AC_TO_TID(tap->txa_ac); + tid = tap->txa_tid; wn = (void *)tap->txa_ni; wn->agg[tid].bitmap = bitmap; wn->agg[tid].startidx = start; @@ -5585,7 +5585,7 @@ iwn_addba_response(struct ieee80211_node { struct iwn_softc *sc = ni->ni_ic->ic_ifp->if_softc; int qid = *(int *)tap->txa_private; - uint8_t tid = WME_AC_TO_TID(tap->txa_ac); + uint8_t tid = tap->txa_tid; int ret; if (code == IEEE80211_STATUS_SUCCESS) { @@ -5609,7 +5609,7 @@ static int iwn_ampdu_tx_start(struct ieee80211com *ic, struct ieee80211_node *ni, uint8_t tid) { - struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[TID_TO_WME_AC(tid)]; + struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[tid]; struct iwn_softc *sc = ni->ni_ic->ic_ifp->if_softc; struct iwn_ops *ops = &sc->ops; struct iwn_node *wn = (void *)ni; @@ -5642,7 +5642,7 @@ iwn_ampdu_tx_stop(struct ieee80211_node { struct iwn_softc *sc = ni->ni_ic->ic_ifp->if_softc; struct iwn_ops *ops = &sc->ops; - uint8_t tid = WME_AC_TO_TID(tap->txa_ac); + uint8_t tid = tap->txa_tid; int qid; if (tap->txa_private == NULL) Modified: head/sys/dev/mwl/if_mwl.c ============================================================================== --- head/sys/dev/mwl/if_mwl.c Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/dev/mwl/if_mwl.c Sun Apr 15 20:29:39 2012 (r234324) @@ -3739,7 +3739,7 @@ mwl_addba_request(struct ieee80211_node /* NB: no held reference to ni */ sp = mwl_hal_bastream_alloc(MWL_VAP(vap)->mv_hvap, (baparamset & IEEE80211_BAPS_POLICY_IMMEDIATE) != 0, - ni->ni_macaddr, WME_AC_TO_TID(tap->txa_ac), ni->ni_htparam, + ni->ni_macaddr, tap->txa_tid, ni->ni_htparam, ni, tap); if (sp == NULL) { /* @@ -3776,8 +3776,8 @@ mwl_addba_response(struct ieee80211_node if (bas == NULL) { /* XXX should not happen */ DPRINTF(sc, MWL_DEBUG_AMPDU, - "%s: no BA stream allocated, AC %d\n", - __func__, tap->txa_ac); + "%s: no BA stream allocated, TID %d\n", + __func__, tap->txa_tid); sc->sc_stats.mst_addba_nostream++; return 0; } @@ -3805,18 +3805,18 @@ mwl_addba_response(struct ieee80211_node tap->txa_private = NULL; DPRINTF(sc, MWL_DEBUG_AMPDU, - "%s: create failed, error %d, bufsiz %d AC %d " + "%s: create failed, error %d, bufsiz %d TID %d " "htparam 0x%x\n", __func__, error, bufsiz, - tap->txa_ac, ni->ni_htparam); + tap->txa_tid, ni->ni_htparam); sc->sc_stats.mst_bacreate_failed++; return 0; } /* NB: cache txq to avoid ptr indirect */ - mwl_bastream_setup(bas, tap->txa_ac, bas->bastream->txq); + mwl_bastream_setup(bas, tap->txa_tid, bas->bastream->txq); DPRINTF(sc, MWL_DEBUG_AMPDU, - "%s: bastream %p assigned to txq %d AC %d bufsiz %d " + "%s: bastream %p assigned to txq %d TID %d bufsiz %d " "htparam 0x%x\n", __func__, bas->bastream, - bas->txq, tap->txa_ac, bufsiz, ni->ni_htparam); + bas->txq, tap->txa_tid, bufsiz, ni->ni_htparam); } else { /* * Other side NAK'd us; return the resources. Modified: head/sys/dev/mwl/if_mwlvar.h ============================================================================== --- head/sys/dev/mwl/if_mwlvar.h Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/dev/mwl/if_mwlvar.h Sun Apr 15 20:29:39 2012 (r234324) @@ -187,10 +187,10 @@ struct mwl_bastate { }; static __inline__ void -mwl_bastream_setup(struct mwl_bastate *bas, int ac, int txq) +mwl_bastream_setup(struct mwl_bastate *bas, int tid, int txq) { bas->txq = txq; - bas->qos = htole16(WME_AC_TO_TID(ac) | IEEE80211_QOS_ACKPOLICY_BA); + bas->qos = htole16(tid | IEEE80211_QOS_ACKPOLICY_BA); } static __inline__ void Modified: head/sys/net80211/ieee80211_ddb.c ============================================================================== --- head/sys/net80211/ieee80211_ddb.c Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/net80211/ieee80211_ddb.c Sun Apr 15 20:29:39 2012 (r234324) @@ -202,7 +202,7 @@ _db_show_txampdu(const char *sep, int ix { db_printf("%stxampdu[%d]: %p flags %b %s\n", sep, ix, tap, tap->txa_flags, IEEE80211_AGGR_BITS, - ieee80211_wme_acnames[tap->txa_ac]); + ieee80211_wme_acnames[TID_TO_WME_AC(tap->txa_tid)]); db_printf("%s token %u lastsample %d pkts %d avgpps %d qbytes %d qframes %d\n", sep, tap->txa_token, tap->txa_lastsample, tap->txa_pkts, tap->txa_avgpps, tap->txa_qbytes, tap->txa_qframes); @@ -293,7 +293,7 @@ _db_show_sta(const struct ieee80211_node ni->ni_htopmode, ni->ni_htstbc, ni->ni_chw); /* XXX ampdu state */ - for (i = 0; i < WME_NUM_AC; i++) + for (i = 0; i < WME_NUM_TID; i++) if (ni->ni_tx_ampdu[i].txa_flags & IEEE80211_AGGR_SETUP) _db_show_txampdu("\t", i, &ni->ni_tx_ampdu[i]); for (i = 0; i < WME_NUM_TID; i++) Modified: head/sys/net80211/ieee80211_ht.c ============================================================================== --- head/sys/net80211/ieee80211_ht.c Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/net80211/ieee80211_ht.c Sun Apr 15 20:29:39 2012 (r234324) @@ -1023,7 +1023,7 @@ void ieee80211_ht_node_init(struct ieee80211_node *ni) { struct ieee80211_tx_ampdu *tap; - int ac; + int tid; if (ni->ni_flags & IEEE80211_NODE_HT) { /* @@ -1033,9 +1033,9 @@ ieee80211_ht_node_init(struct ieee80211_ */ ieee80211_ht_node_cleanup(ni); } - for (ac = 0; ac < WME_NUM_AC; ac++) { - tap = &ni->ni_tx_ampdu[ac]; - tap->txa_ac = ac; + for (tid = 0; tid < WME_NUM_TID; tid++) { + tap = &ni->ni_tx_ampdu[tid]; + tap->txa_tid = tid; tap->txa_ni = ni; /* NB: further initialization deferred */ } @@ -1055,7 +1055,7 @@ ieee80211_ht_node_cleanup(struct ieee802 KASSERT(ni->ni_flags & IEEE80211_NODE_HT, ("not an HT node")); /* XXX optimize this */ - for (i = 0; i < WME_NUM_AC; i++) { + for (i = 0; i < WME_NUM_TID; i++) { struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[i]; if (tap->txa_flags & IEEE80211_AGGR_SETUP) ampdu_tx_stop(tap); @@ -1160,7 +1160,7 @@ ieee80211_ht_wds_init(struct ieee80211_n { struct ieee80211vap *vap = ni->ni_vap; struct ieee80211_tx_ampdu *tap; - int ac; + int tid; KASSERT(vap->iv_flags_ht & IEEE80211_FHT_HT, ("no HT requested")); @@ -1198,9 +1198,9 @@ ieee80211_ht_wds_init(struct ieee80211_n ni->ni_htopmode = 0; /* XXX need protection state */ ni->ni_htstbc = 0; /* XXX need info */ - for (ac = 0; ac < WME_NUM_AC; ac++) { - tap = &ni->ni_tx_ampdu[ac]; - tap->txa_ac = ac; + for (tid = 0; tid < WME_NUM_TID; tid++) { + tap = &ni->ni_tx_ampdu[tid]; + tap->txa_tid = tid; } /* NB: AMPDU tx/rx governed by IEEE80211_FHT_AMPDU_{TX,RX} */ ni->ni_flags |= IEEE80211_NODE_HT | IEEE80211_NODE_AMPDU; @@ -1685,7 +1685,8 @@ ampdu_tx_stop(struct ieee80211_tx_ampdu struct ieee80211com *ic = ni->ni_ic; KASSERT(tap->txa_flags & IEEE80211_AGGR_SETUP, - ("txa_flags 0x%x ac %d", tap->txa_flags, tap->txa_ac)); + ("txa_flags 0x%x tid %d ac %d", tap->txa_flags, tap->txa_tid, + TID_TO_WME_AC(tap->txa_tid))); /* * Stop BA stream if setup so driver has a chance @@ -1898,7 +1899,7 @@ ht_recv_action_ba_addba_response(struct struct ieee80211_tx_ampdu *tap; uint8_t dialogtoken, policy; uint16_t baparamset, batimeout, code; - int tid, ac, bufsiz; + int tid, bufsiz; dialogtoken = frm[2]; code = LE_READ_2(frm+3); @@ -1908,8 +1909,7 @@ ht_recv_action_ba_addba_response(struct policy = MS(baparamset, IEEE80211_BAPS_POLICY); batimeout = LE_READ_2(frm+7); - ac = TID_TO_WME_AC(tid); - tap = &ni->ni_tx_ampdu[ac]; + tap = &ni->ni_tx_ampdu[tid]; if ((tap->txa_flags & IEEE80211_AGGR_XCHGPEND) == 0) { IEEE80211_DISCARD_MAC(vap, IEEE80211_MSG_ACTION | IEEE80211_MSG_11N, @@ -1972,7 +1972,7 @@ ht_recv_action_ba_delba(struct ieee80211 struct ieee80211_rx_ampdu *rap; struct ieee80211_tx_ampdu *tap; uint16_t baparamset, code; - int tid, ac; + int tid; baparamset = LE_READ_2(frm+2); code = LE_READ_2(frm+4); @@ -1985,8 +1985,7 @@ ht_recv_action_ba_delba(struct ieee80211 MS(baparamset, IEEE80211_DELBAPS_INIT), code); if ((baparamset & IEEE80211_DELBAPS_INIT) == 0) { - ac = TID_TO_WME_AC(tid); - tap = &ni->ni_tx_ampdu[ac]; + tap = &ni->ni_tx_ampdu[tid]; ic->ic_addba_stop(ni, tap); } else { rap = &ni->ni_rx_ampdu[tid]; @@ -2058,7 +2057,8 @@ ieee80211_ampdu_enable(struct ieee80211_ { struct ieee80211vap *vap = ni->ni_vap; - if (tap->txa_avgpps < vap->iv_ampdu_mintraffic[tap->txa_ac]) + if (tap->txa_avgpps < + vap->iv_ampdu_mintraffic[TID_TO_WME_AC(tap->txa_tid)]) return 0; /* XXX check rssi? */ if (tap->txa_attempts >= ieee80211_addba_maxtries && @@ -2071,8 +2071,9 @@ ieee80211_ampdu_enable(struct ieee80211_ return 0; } IEEE80211_NOTE(vap, IEEE80211_MSG_11N, ni, - "enable AMPDU on %s, avgpps %d pkts %d", - ieee80211_wme_acnames[tap->txa_ac], tap->txa_avgpps, tap->txa_pkts); + "enable AMPDU on tid %d (%s), avgpps %d pkts %d", + tap->txa_tid, ieee80211_wme_acnames[TID_TO_WME_AC(tap->txa_tid)], + tap->txa_avgpps, tap->txa_pkts); return 1; } @@ -2099,7 +2100,7 @@ ieee80211_ampdu_request(struct ieee80211 tap->txa_flags &= ~IEEE80211_AGGR_NAK; dialogtoken = (tokens+1) % 63; /* XXX */ - tid = WME_AC_TO_TID(tap->txa_ac); + tid = tap->txa_tid; tap->txa_start = ni->ni_txseqs[tid]; args[0] = dialogtoken; @@ -2113,8 +2114,8 @@ ieee80211_ampdu_request(struct ieee80211 if (!ic->ic_addba_request(ni, tap, dialogtoken, args[2], args[3])) { /* unable to setup state, don't make request */ IEEE80211_NOTE(ni->ni_vap, IEEE80211_MSG_11N, - ni, "%s: could not setup BA stream for AC %d", - __func__, tap->txa_ac); + ni, "%s: could not setup BA stream for TID %d AC %d", + __func__, tap->txa_tid, TID_TO_WME_AC(tap->txa_tid)); /* defer next try so we don't slam the driver with requests */ tap->txa_attempts = ieee80211_addba_maxtries; /* NB: check in case driver wants to override */ @@ -2147,20 +2148,20 @@ ieee80211_ampdu_stop(struct ieee80211_no tap->txa_flags &= ~IEEE80211_AGGR_BARPEND; if (IEEE80211_AMPDU_RUNNING(tap)) { IEEE80211_NOTE(vap, IEEE80211_MSG_ACTION | IEEE80211_MSG_11N, - ni, "%s: stop BA stream for AC %d (reason %d)", - __func__, tap->txa_ac, reason); + ni, "%s: stop BA stream for TID %d (reason %d)", + __func__, tap->txa_tid, reason); vap->iv_stats.is_ampdu_stop++; ic->ic_addba_stop(ni, tap); - args[0] = WME_AC_TO_TID(tap->txa_ac); + args[0] = tap->txa_tid; args[1] = IEEE80211_DELBAPS_INIT; args[2] = reason; /* XXX reason code */ ic->ic_send_action(ni, IEEE80211_ACTION_CAT_BA, IEEE80211_ACTION_BA_DELBA, args); } else { IEEE80211_NOTE(vap, IEEE80211_MSG_ACTION | IEEE80211_MSG_11N, - ni, "%s: BA stream for AC %d not running (reason %d)", - __func__, tap->txa_ac, reason); + ni, "%s: BA stream for TID %d not running (reason %d)", + __func__, tap->txa_tid, reason); vap->iv_stats.is_ampdu_stop_failed++; } } @@ -2176,7 +2177,7 @@ bar_timeout(void *arg) IEEE80211_NOTE(ni->ni_vap, IEEE80211_MSG_11N, ni, "%s: tid %u flags 0x%x attempts %d", __func__, - tap->txa_ac, tap->txa_flags, tap->txa_attempts); + tap->txa_tid, tap->txa_flags, tap->txa_attempts); /* guard against race with bar_tx_complete */ if ((tap->txa_flags & IEEE80211_AGGR_BARPEND) == 0) @@ -2210,7 +2211,7 @@ bar_tx_complete(struct ieee80211_node *n IEEE80211_NOTE(ni->ni_vap, IEEE80211_MSG_11N, ni, "%s: tid %u flags 0x%x pending %d status %d", - __func__, tap->txa_ac, tap->txa_flags, + __func__, tap->txa_tid, tap->txa_flags, callout_pending(&tap->txa_timer), status); ni->ni_vap->iv_stats.is_ampdu_bar_tx++; @@ -2237,7 +2238,7 @@ ieee80211_bar_response(struct ieee80211_ tap->txa_start, IEEE80211_SEQ_ADD(tap->txa_start, tap->txa_wnd-1), tap->txa_qframes, tap->txa_seqpending, - WME_AC_TO_TID(tap->txa_ac)); + tap->txa_tid); /* NB: timer already stopped in bar_tx_complete */ tap->txa_start = tap->txa_seqpending; @@ -2292,7 +2293,7 @@ ieee80211_send_bar(struct ieee80211_node IEEE80211_ADDR_COPY(bar->i_ra, ni->ni_macaddr); IEEE80211_ADDR_COPY(bar->i_ta, vap->iv_myaddr); - tid = WME_AC_TO_TID(tap->txa_ac); + tid = tap->txa_tid; barctl = (tap->txa_flags & IEEE80211_AGGR_IMMEDIATE ? 0 : IEEE80211_BAR_NOACK) | IEEE80211_BAR_COMP Modified: head/sys/net80211/ieee80211_ht.h ============================================================================== --- head/sys/net80211/ieee80211_ht.h Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/net80211/ieee80211_ht.h Sun Apr 15 20:29:39 2012 (r234324) @@ -44,7 +44,7 @@ struct ieee80211_tx_ampdu { #define IEEE80211_AGGR_SETUP 0x0008 /* deferred state setup */ #define IEEE80211_AGGR_NAK 0x0010 /* peer NAK'd ADDBA request */ #define IEEE80211_AGGR_BARPEND 0x0020 /* BAR response pending */ - uint8_t txa_ac; + uint8_t txa_tid; uint8_t txa_token; /* dialog token */ int txa_lastsample; /* ticks @ last traffic sample */ int txa_pkts; /* packets over last sample interval */ Modified: head/sys/net80211/ieee80211_node.h ============================================================================== --- head/sys/net80211/ieee80211_node.h Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/net80211/ieee80211_node.h Sun Apr 15 20:29:39 2012 (r234324) @@ -214,7 +214,7 @@ struct ieee80211_node { uint8_t ni_htstbc; /* HT */ uint8_t ni_chw; /* negotiated channel width */ struct ieee80211_htrateset ni_htrates; /* negotiated ht rate set */ - struct ieee80211_tx_ampdu ni_tx_ampdu[WME_NUM_AC]; + struct ieee80211_tx_ampdu ni_tx_ampdu[WME_NUM_TID]; struct ieee80211_rx_ampdu ni_rx_ampdu[WME_NUM_TID]; /* others */ Modified: head/sys/net80211/ieee80211_output.c ============================================================================== --- head/sys/net80211/ieee80211_output.c Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/net80211/ieee80211_output.c Sun Apr 15 20:29:39 2012 (r234324) @@ -323,8 +323,8 @@ ieee80211_start(struct ifnet *ifp) if ((ni->ni_flags & IEEE80211_NODE_AMPDU_TX) && (vap->iv_flags_ht & IEEE80211_FHT_AMPDU_TX) && (m->m_flags & M_EAPOL) == 0) { - const int ac = M_WME_GETAC(m); - struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[ac]; + int tid = WME_AC_TO_TID(M_WME_GETAC(m)); + struct ieee80211_tx_ampdu *tap = &ni->ni_tx_ampdu[tid]; ieee80211_txampdu_count_packet(tap); if (IEEE80211_AMPDU_RUNNING(tap)) { @@ -589,7 +589,7 @@ ieee80211_send_setup( } *(uint16_t *)&wh->i_dur[0] = 0; - tap = &ni->ni_tx_ampdu[TID_TO_WME_AC(tid)]; + tap = &ni->ni_tx_ampdu[tid]; if (tid != IEEE80211_NONQOS_TID && IEEE80211_AMPDU_RUNNING(tap)) m->m_flags |= M_AMPDU_MPDU; else { Modified: head/sys/net80211/ieee80211_superg.c ============================================================================== --- head/sys/net80211/ieee80211_superg.c Sun Apr 15 19:54:22 2012 (r234323) +++ head/sys/net80211/ieee80211_superg.c Sun Apr 15 20:29:39 2012 (r234324) @@ -562,9 +562,11 @@ ieee80211_ff_age(struct ieee80211com *ic IEEE80211_LOCK(ic); head = sq->head; while ((m = sq->head) != NULL && M_AGE_GET(m) < quanta) { + int tid = WME_AC_TO_TID(M_WME_GETAC(m)); + /* clear tap ref to frame */ ni = (struct ieee80211_node *) m->m_pkthdr.rcvif; - tap = &ni->ni_tx_ampdu[M_WME_GETAC(m)]; + tap = &ni->ni_tx_ampdu[tid]; KASSERT(tap->txa_private == m, ("staging queue empty")); tap->txa_private = NULL; @@ -670,7 +672,7 @@ ieee80211_ff_check(struct ieee80211_node * be aggregated with other types of frames when encryption is on? */ IEEE80211_LOCK(ic); - tap = &ni->ni_tx_ampdu[pri]; + tap = &ni->ni_tx_ampdu[WME_AC_TO_TID(pri)]; mstaged = tap->txa_private; /* NB: we reuse AMPDU state */ ieee80211_txampdu_count_packet(tap); @@ -783,12 +785,14 @@ ieee80211_ff_node_cleanup(struct ieee802 struct ieee80211_superg *sg = ic->ic_superg; struct ieee80211_tx_ampdu *tap; struct mbuf *m, *head; - int ac; + int tid; IEEE80211_LOCK(ic); head = NULL; - for (ac = 0; ac < WME_NUM_AC; ac++) { - tap = &ni->ni_tx_ampdu[ac]; + for (tid = 0; tid < WME_NUM_TID; tid++) { + int ac = TID_TO_WME_AC(tid); + + tap = &ni->ni_tx_ampdu[tid]; m = tap->txa_private; if (m != NULL) { tap->txa_private = NULL; From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 21:17:10 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E15F4106566C; Sun, 15 Apr 2012 21:17:09 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-pz0-f44.google.com (mail-pz0-f44.google.com [209.85.210.44]) by mx1.freebsd.org (Postfix) with ESMTP id A0B668FC12; Sun, 15 Apr 2012 21:17:09 +0000 (UTC) Received: by dadz14 with SMTP id z14so21053361dad.17 for ; Sun, 15 Apr 2012 14:17:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=HZHLgiioQA5kP9zHTEM/LaSh3Sl6zrOKxE8bx/ums6U=; b=CKOyM8o8tVICJ7P37at1xMQ4lrhwKWfHUOSczGwO3N/9Ty5qOjgrlxKin4K6szOVtg y4oVmuyGjXnOEP3v7oLyj4/95QgjBK0wi2tyjcRyo29qzBzQchLhuC3O1guzy/Sfr2WH De1Yt7Qh6ZbPgaUhO9dY3+rfh1xZtuvfQlXd0sCE0YxPLY/u8bOK6izCcilDV1oTpWxq cWhFjVK5JYoOt/vvCihP9y+k7Oqja8AfhkpqJnC2MkcW12QxjECceY7AaVjNbv47Kkkv GE2qdZ+hHqU2zvlLD/CNTYEAQObttHfMwUZEkFG+kqDDJAmvxPpbPHuD9qh0hJb6WmWc c7MA== MIME-Version: 1.0 Received: by 10.68.134.133 with SMTP id pk5mr22955600pbb.17.1334524629242; Sun, 15 Apr 2012 14:17:09 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.142.101.9 with HTTP; Sun, 15 Apr 2012 14:17:09 -0700 (PDT) In-Reply-To: <4F7E9413.20602@FreeBSD.org> References: <201204060653.q366rwLa096182@svn.freebsd.org> <4F7E9413.20602@FreeBSD.org> Date: Sun, 15 Apr 2012 14:17:09 -0700 X-Google-Sender-Auth: ysbIXStc5nAztNcBsGisgOdHNQ4 Message-ID: From: Adrian Chadd To: "Alexander V. Chernikov" Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r233937 - in head/sys: kern net security/mac X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 21:17:10 -0000 Hi, This has broken (at least) net80211 and bpf, with LOR: # ifconfig wlan1 destroy panic: mutex bpf global lock now owned at ....../net/bpf.c:656 The stack: * ieee80211_vap_detach() * ether_ifdetach() * bpfdetach() * - I bet this is bpf_detachd() * _mtx_assert() From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 21:59:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 40060106566C; Sun, 15 Apr 2012 21:59:29 +0000 (UTC) (envelope-from gleb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2AF6B8FC15; Sun, 15 Apr 2012 21:59:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FLxTab003360; Sun, 15 Apr 2012 21:59:29 GMT (envelope-from gleb@svn.freebsd.org) Received: (from gleb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FLxSKB003358; Sun, 15 Apr 2012 21:59:28 GMT (envelope-from gleb@svn.freebsd.org) Message-Id: <201204152159.q3FLxSKB003358@svn.freebsd.org> From: Gleb Kurtsou Date: Sun, 15 Apr 2012 21:59: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: r234325 - head/sys/fs/tmpfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 21:59:29 -0000 Author: gleb Date: Sun Apr 15 21:59:28 2012 New Revision: 234325 URL: http://svn.freebsd.org/changeset/base/234325 Log: Provide better description for vfs.tmpfs.memory_reserved sysctl. Suggested by: Anton Yuzhaninov Modified: head/sys/fs/tmpfs/tmpfs_subr.c Modified: head/sys/fs/tmpfs/tmpfs_subr.c ============================================================================== --- head/sys/fs/tmpfs/tmpfs_subr.c Sun Apr 15 20:29:39 2012 (r234324) +++ head/sys/fs/tmpfs/tmpfs_subr.c Sun Apr 15 21:59:28 2012 (r234325) @@ -83,7 +83,8 @@ sysctl_mem_reserved(SYSCTL_HANDLER_ARGS) } SYSCTL_PROC(_vfs_tmpfs, OID_AUTO, memory_reserved, CTLTYPE_LONG|CTLFLAG_RW, - &tmpfs_pages_reserved, 0, sysctl_mem_reserved, "L", "reserved memory"); + &tmpfs_pages_reserved, 0, sysctl_mem_reserved, "L", + "Amount of available memory and swap below which tmpfs growth stops"); size_t tmpfs_mem_avail(void) From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 22:34:23 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 57FFE1065673; Sun, 15 Apr 2012 22:34:23 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2A4A58FC15; Sun, 15 Apr 2012 22:34:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FMYNet004574; Sun, 15 Apr 2012 22:34:23 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FMYMqx004570; Sun, 15 Apr 2012 22:34:22 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204152234.q3FMYMqx004570@svn.freebsd.org> From: Adrian Chadd Date: Sun, 15 Apr 2012 22:34: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: r234326 - head/sys/mips/atheros X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 22:34:23 -0000 Author: adrian Date: Sun Apr 15 22:34:22 2012 New Revision: 234326 URL: http://svn.freebsd.org/changeset/base/234326 Log: The AR913x MII speed configuration matches the AR71xx MII configuration. So share the code. Don't do it for the AR724x - that has a completely different set of PLL and MII configuration parameters. Modified: head/sys/mips/atheros/ar71xx_chip.c head/sys/mips/atheros/ar71xx_chip.h head/sys/mips/atheros/ar91xx_chip.c Modified: head/sys/mips/atheros/ar71xx_chip.c ============================================================================== --- head/sys/mips/atheros/ar71xx_chip.c Sun Apr 15 21:59:28 2012 (r234325) +++ head/sys/mips/atheros/ar71xx_chip.c Sun Apr 15 22:34:22 2012 (r234326) @@ -136,7 +136,7 @@ ar71xx_chip_device_stopped(uint32_t mask return ((reg & mask) == mask); } -static void +void ar71xx_chip_set_mii_speed(uint32_t unit, uint32_t speed) { uint32_t val, reg, ctrl; Modified: head/sys/mips/atheros/ar71xx_chip.h ============================================================================== --- head/sys/mips/atheros/ar71xx_chip.h Sun Apr 15 21:59:28 2012 (r234325) +++ head/sys/mips/atheros/ar71xx_chip.h Sun Apr 15 22:34:22 2012 (r234326) @@ -30,5 +30,6 @@ #define __AR71XX_CHIP_H__ extern struct ar71xx_cpu_def ar71xx_chip_def; +extern void ar71xx_chip_set_mii_speed(uint32_t unit, uint32_t speed); #endif Modified: head/sys/mips/atheros/ar91xx_chip.c ============================================================================== --- head/sys/mips/atheros/ar91xx_chip.c Sun Apr 15 21:59:28 2012 (r234325) +++ head/sys/mips/atheros/ar91xx_chip.c Sun Apr 15 22:34:22 2012 (r234326) @@ -53,6 +53,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include @@ -111,13 +112,6 @@ ar91xx_chip_device_stopped(uint32_t mask } static void -ar91xx_chip_set_mii_speed(uint32_t unit, uint32_t speed) -{ - /* XXX TODO */ -} - - -static void ar91xx_chip_set_pll_ge(int unit, int speed) { uint32_t pll; @@ -216,7 +210,7 @@ struct ar71xx_cpu_def ar91xx_chip_def = &ar91xx_chip_device_start, &ar91xx_chip_device_stopped, &ar91xx_chip_set_pll_ge, - &ar91xx_chip_set_mii_speed, + &ar71xx_chip_set_mii_speed, &ar91xx_chip_ddr_flush_ge, &ar91xx_chip_get_eth_pll, &ar91xx_chip_ddr_flush_ip2, From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 22:59:56 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F0430106564A; Sun, 15 Apr 2012 22:59:56 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DB0048FC17; Sun, 15 Apr 2012 22:59:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FMxuXs005376; Sun, 15 Apr 2012 22:59:56 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FMxupO005374; Sun, 15 Apr 2012 22:59:56 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204152259.q3FMxupO005374@svn.freebsd.org> From: Adrian Chadd Date: Sun, 15 Apr 2012 22:59: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: r234327 - head/sys/mips/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 22:59:57 -0000 Author: adrian Date: Sun Apr 15 22:59:56 2012 New Revision: 234327 URL: http://svn.freebsd.org/changeset/base/234327 Log: Add in the AP96 phy configuration from openwrt. * arge0 doesn't (yet) work via the switch PHY ports; I'm not sure why. * arge1 maps to the WAN port. That works. TODO: * The PLL register needs a different (non-default) value for Gigabit Ethernet. The board setup code needs to be extended a bit to allow for non-default pll_1000 values - right now, those values come out of hard-coded values in the per-chip set_pll_ge() routines. Obtained from: Linux / OpenWRT Modified: head/sys/mips/conf/AP96.hints Modified: head/sys/mips/conf/AP96.hints ============================================================================== --- head/sys/mips/conf/AP96.hints Sun Apr 15 22:34:22 2012 (r234326) +++ head/sys/mips/conf/AP96.hints Sun Apr 15 22:59:56 2012 (r234327) @@ -1,17 +1,15 @@ # $FreeBSD$ -hint.arge.0.phymask=0x000c -hint.arge.0.media=100 +# TODO: RGMII +hint.arge.0.phymask=0x0f +hint.arge.0.media=1000 hint.arge.0.fduplex=1 -# XXX grab these from uboot? -# hint.arge.0.eeprommac=0x1f01fc00 - -# The ath NICs have calibration data in flash. -# PCI slot 17 -# hint.ath.0.eepromaddr=0x1fff1000 -# PCI slot 18 -# hint.ath.1.eepromaddr=0x1fff5000 +# TODO: RGMII +# TODO: pll_1000 = 0x1f000000 +hint.arge.1.phymask=0x10 +# hint.arge.1.media=1000 +# hint.arge.1.fduplex=1 # ath0 - slot 17 hint.pcib.0.bus.0.17.0.ath_fixup_addr=0x1fff1000 From owner-svn-src-all@FreeBSD.ORG Sun Apr 15 23:56:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6E76F1065674; Sun, 15 Apr 2012 23:56:04 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 59F288FC12; Sun, 15 Apr 2012 23:56:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3FNu4WT007226; Sun, 15 Apr 2012 23:56:04 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3FNu4W4007224; Sun, 15 Apr 2012 23:56:04 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201204152356.q3FNu4W4007224@svn.freebsd.org> From: Eitan Adler Date: Sun, 15 Apr 2012 23:56: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: r234329 - head/lib/libc/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Apr 2012 23:56:04 -0000 Author: eadler Date: Sun Apr 15 23:56:03 2012 New Revision: 234329 URL: http://svn.freebsd.org/changeset/base/234329 Log: When searching for uninitialized memory usage add ensure that the entire struct is set to zero. PR: bin/166483 Submitted by: Roy Marples Reviewed by: delphij Approved by: cperciva MFC after: 3 days Modified: head/lib/libc/net/if_nametoindex.c Modified: head/lib/libc/net/if_nametoindex.c ============================================================================== --- head/lib/libc/net/if_nametoindex.c Sun Apr 15 23:50:13 2012 (r234328) +++ head/lib/libc/net/if_nametoindex.c Sun Apr 15 23:56:03 2012 (r234329) @@ -70,6 +70,9 @@ if_nametoindex(const char *ifname) s = _socket(AF_INET, SOCK_DGRAM, 0); if (s != -1) { +#ifdef PURIFY + memset(&ifr, 0, sizeof(ifr)); +#endif strlcpy(ifr.ifr_name, ifname, sizeof(ifr.ifr_name)); if (_ioctl(s, SIOCGIFINDEX, &ifr) != -1) { _close(s); From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 01:15:38 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AF5A4106566C; Mon, 16 Apr 2012 01:15:38 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 901A08FC14; Mon, 16 Apr 2012 01:15:38 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3G1FcT9009756; Mon, 16 Apr 2012 01:15:38 GMT (envelope-from kevlo@svn.freebsd.org) Received: (from kevlo@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3G1FcML009754; Mon, 16 Apr 2012 01:15:38 GMT (envelope-from kevlo@svn.freebsd.org) Message-Id: <201204160115.q3G1FcML009754@svn.freebsd.org> From: Kevin Lo Date: Mon, 16 Apr 2012 01:15:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234330 - stable/9/usr.bin/unzip X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 01:15:38 -0000 Author: kevlo Date: Mon Apr 16 01:15:38 2012 New Revision: 234330 URL: http://svn.freebsd.org/changeset/base/234330 Log: MFC r234206: Partially implement zipinfo (-Z) support. This fixes some test failures seen with perl 5.12 and 5.14. PR: bin/166895 Submitted by: swills Modified: stable/9/usr.bin/unzip/unzip.c Directory Properties: stable/9/usr.bin/ (props changed) Modified: stable/9/usr.bin/unzip/unzip.c ============================================================================== --- stable/9/usr.bin/unzip/unzip.c Sun Apr 15 23:56:03 2012 (r234329) +++ stable/9/usr.bin/unzip/unzip.c Mon Apr 16 01:15:38 2012 (r234330) @@ -65,6 +65,7 @@ static int q_opt; /* quiet */ static int t_opt; /* test */ static int u_opt; /* update */ static int v_opt; /* verbose/list */ +static int Z1_opt; /* zipinfo mode list files only */ /* time when unzip started */ static time_t now; @@ -72,6 +73,9 @@ static time_t now; /* debug flag */ static int unzip_debug; +/* zipinfo mode */ +static int zipinfo_mode; + /* running on tty? */ static int tty; @@ -802,17 +806,22 @@ list(struct archive *a, struct archive_e mtime = archive_entry_mtime(e); strftime(buf, sizeof(buf), "%m-%d-%g %R", localtime(&mtime)); - if (v_opt == 1) { - printf(" %8ju %s %s\n", - (uintmax_t)archive_entry_size(e), - buf, archive_entry_pathname(e)); - } else if (v_opt == 2) { - printf("%8ju Stored %7ju 0%% %s %08x %s\n", - (uintmax_t)archive_entry_size(e), - (uintmax_t)archive_entry_size(e), - buf, - 0U, - archive_entry_pathname(e)); + if (!zipinfo_mode) { + if (v_opt == 1) { + printf(" %8ju %s %s\n", + (uintmax_t)archive_entry_size(e), + buf, archive_entry_pathname(e)); + } else if (v_opt == 2) { + printf("%8ju Stored %7ju 0%% %s %08x %s\n", + (uintmax_t)archive_entry_size(e), + (uintmax_t)archive_entry_size(e), + buf, + 0U, + archive_entry_pathname(e)); + } + } else { + if (Z1_opt) + printf("%s\n",archive_entry_pathname(e)); } ac(archive_read_data_skip(a)); } @@ -870,14 +879,16 @@ unzip(const char *fn) ac(archive_read_support_format_zip(a)); ac(archive_read_open_fd(a, fd, 8192)); - if (!p_opt && !q_opt) - printf("Archive: %s\n", fn); - if (v_opt == 1) { - printf(" Length Date Time Name\n"); - printf(" -------- ---- ---- ----\n"); - } else if (v_opt == 2) { - printf(" Length Method Size Ratio Date Time CRC-32 Name\n"); - printf("-------- ------ ------- ----- ---- ---- ------ ----\n"); + if (!zipinfo_mode) { + if (!p_opt && !q_opt) + printf("Archive: %s\n", fn); + if (v_opt == 1) { + printf(" Length Date Time Name\n"); + printf(" -------- ---- ---- ----\n"); + } else if (v_opt == 2) { + printf(" Length Method Size Ratio Date Time CRC-32 Name\n"); + printf("-------- ------ ------- ----- ---- ---- ------ ----\n"); + } } total_size = 0; @@ -888,28 +899,35 @@ unzip(const char *fn) if (ret == ARCHIVE_EOF) break; ac(ret); - if (t_opt) - error_count += test(a, e); - else if (v_opt) - list(a, e); - else if (p_opt || c_opt) - extract_stdout(a, e); - else - extract(a, e); + if (!zipinfo_mode) { + if (t_opt) + error_count += test(a, e); + else if (v_opt) + list(a, e); + else if (p_opt || c_opt) + extract_stdout(a, e); + else + extract(a, e); + } else { + if (Z1_opt) + list(a, e); + } total_size += archive_entry_size(e); ++file_count; } - if (v_opt == 1) { - printf(" -------- -------\n"); - printf(" %8ju %ju file%s\n", - total_size, file_count, file_count != 1 ? "s" : ""); - } else if (v_opt == 2) { - printf("-------- ------- --- -------\n"); - printf("%8ju %7ju 0%% %ju file%s\n", - total_size, total_size, file_count, - file_count != 1 ? "s" : ""); + if (zipinfo_mode) { + if (v_opt == 1) { + printf(" -------- -------\n"); + printf(" %8ju %ju file%s\n", + total_size, file_count, file_count != 1 ? "s" : ""); + } else if (v_opt == 2) { + printf("-------- ------- --- -------\n"); + printf("%8ju %7ju 0%% %ju file%s\n", + total_size, total_size, file_count, + file_count != 1 ? "s" : ""); + } } ac(archive_read_close(a)); @@ -933,7 +951,7 @@ static void usage(void) { - fprintf(stderr, "usage: unzip [-aCcfjLlnopqtuv] [-d dir] [-x pattern] zipfile\n"); + fprintf(stderr, "usage: unzip [-aCcfjLlnopqtuvZ1] [-d dir] [-x pattern] zipfile\n"); exit(1); } @@ -943,8 +961,11 @@ getopts(int argc, char *argv[]) int opt; optreset = optind = 1; - while ((opt = getopt(argc, argv, "aCcd:fjLlnopqtuvx:")) != -1) + while ((opt = getopt(argc, argv, "aCcd:fjLlnopqtuvx:Z1")) != -1) switch (opt) { + case '1': + Z1_opt = 1; + break; case 'a': a_opt = 1; break; @@ -995,6 +1016,9 @@ getopts(int argc, char *argv[]) case 'x': add_pattern(&exclude, optarg); break; + case 'Z': + zipinfo_mode = 1; + break; default: usage(); } @@ -1024,6 +1048,15 @@ main(int argc, char *argv[]) */ nopts = getopts(argc, argv); + /* + * When more of the zipinfo mode options are implemented, this + * will need to change. + */ + if (zipinfo_mode && !Z1_opt) { + printf("Zipinfo mode needs additional options\n"); + exit(1); + } + if (argc <= nopts) usage(); zipfile = argv[nopts++]; From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 01:20:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5440A106564A; Mon, 16 Apr 2012 01:20:18 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 351D78FC18; Mon, 16 Apr 2012 01:20:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3G1KI4h009954; Mon, 16 Apr 2012 01:20:18 GMT (envelope-from kevlo@svn.freebsd.org) Received: (from kevlo@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3G1KH4W009952; Mon, 16 Apr 2012 01:20:17 GMT (envelope-from kevlo@svn.freebsd.org) Message-Id: <201204160120.q3G1KH4W009952@svn.freebsd.org> From: Kevin Lo Date: Mon, 16 Apr 2012 01:20:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234331 - stable/8/usr.bin/unzip X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 01:20:18 -0000 Author: kevlo Date: Mon Apr 16 01:20:17 2012 New Revision: 234331 URL: http://svn.freebsd.org/changeset/base/234331 Log: MFC r234206: Partially implement zipinfo (-Z) support. This fixes some test failures seen with perl 5.12 and 5.14. PR: bin/166895 Submitted by: swills Modified: stable/8/usr.bin/unzip/unzip.c Directory Properties: stable/8/usr.bin/ (props changed) stable/8/usr.bin/unzip/ (props changed) Modified: stable/8/usr.bin/unzip/unzip.c ============================================================================== --- stable/8/usr.bin/unzip/unzip.c Mon Apr 16 01:15:38 2012 (r234330) +++ stable/8/usr.bin/unzip/unzip.c Mon Apr 16 01:20:17 2012 (r234331) @@ -65,6 +65,7 @@ static int q_opt; /* quiet */ static int t_opt; /* test */ static int u_opt; /* update */ static int v_opt; /* verbose/list */ +static int Z1_opt; /* zipinfo mode list files only */ /* time when unzip started */ static time_t now; @@ -72,6 +73,9 @@ static time_t now; /* debug flag */ static int unzip_debug; +/* zipinfo mode */ +static int zipinfo_mode; + /* running on tty? */ static int tty; @@ -802,17 +806,22 @@ list(struct archive *a, struct archive_e mtime = archive_entry_mtime(e); strftime(buf, sizeof(buf), "%m-%d-%g %R", localtime(&mtime)); - if (v_opt == 1) { - printf(" %8ju %s %s\n", - (uintmax_t)archive_entry_size(e), - buf, archive_entry_pathname(e)); - } else if (v_opt == 2) { - printf("%8ju Stored %7ju 0%% %s %08x %s\n", - (uintmax_t)archive_entry_size(e), - (uintmax_t)archive_entry_size(e), - buf, - 0U, - archive_entry_pathname(e)); + if (!zipinfo_mode) { + if (v_opt == 1) { + printf(" %8ju %s %s\n", + (uintmax_t)archive_entry_size(e), + buf, archive_entry_pathname(e)); + } else if (v_opt == 2) { + printf("%8ju Stored %7ju 0%% %s %08x %s\n", + (uintmax_t)archive_entry_size(e), + (uintmax_t)archive_entry_size(e), + buf, + 0U, + archive_entry_pathname(e)); + } + } else { + if (Z1_opt) + printf("%s\n",archive_entry_pathname(e)); } ac(archive_read_data_skip(a)); } @@ -866,14 +875,16 @@ unzip(const char *fn) ac(archive_read_support_format_zip(a)); ac(archive_read_open_fd(a, fd, 8192)); - if (!p_opt && !q_opt) - printf("Archive: %s\n", fn); - if (v_opt == 1) { - printf(" Length Date Time Name\n"); - printf(" -------- ---- ---- ----\n"); - } else if (v_opt == 2) { - printf(" Length Method Size Ratio Date Time CRC-32 Name\n"); - printf("-------- ------ ------- ----- ---- ---- ------ ----\n"); + if (!zipinfo_mode) { + if (!p_opt && !q_opt) + printf("Archive: %s\n", fn); + if (v_opt == 1) { + printf(" Length Date Time Name\n"); + printf(" -------- ---- ---- ----\n"); + } else if (v_opt == 2) { + printf(" Length Method Size Ratio Date Time CRC-32 Name\n"); + printf("-------- ------ ------- ----- ---- ---- ------ ----\n"); + } } total_size = 0; @@ -884,28 +895,35 @@ unzip(const char *fn) if (ret == ARCHIVE_EOF) break; ac(ret); - if (t_opt) - error_count += test(a, e); - else if (v_opt) - list(a, e); - else if (p_opt || c_opt) - extract_stdout(a, e); - else - extract(a, e); + if (!zipinfo_mode) { + if (t_opt) + error_count += test(a, e); + else if (v_opt) + list(a, e); + else if (p_opt || c_opt) + extract_stdout(a, e); + else + extract(a, e); + } else { + if (Z1_opt) + list(a, e); + } total_size += archive_entry_size(e); ++file_count; } - if (v_opt == 1) { - printf(" -------- -------\n"); - printf(" %8ju %ju file%s\n", - total_size, file_count, file_count != 1 ? "s" : ""); - } else if (v_opt == 2) { - printf("-------- ------- --- -------\n"); - printf("%8ju %7ju 0%% %ju file%s\n", - total_size, total_size, file_count, - file_count != 1 ? "s" : ""); + if (zipinfo_mode) { + if (v_opt == 1) { + printf(" -------- -------\n"); + printf(" %8ju %ju file%s\n", + total_size, file_count, file_count != 1 ? "s" : ""); + } else if (v_opt == 2) { + printf("-------- ------- --- -------\n"); + printf("%8ju %7ju 0%% %ju file%s\n", + total_size, total_size, file_count, + file_count != 1 ? "s" : ""); + } } ac(archive_read_close(a)); @@ -929,7 +947,7 @@ static void usage(void) { - fprintf(stderr, "usage: unzip [-aCcfjLlnopqtuv] [-d dir] [-x pattern] zipfile\n"); + fprintf(stderr, "usage: unzip [-aCcfjLlnopqtuvZ1] [-d dir] [-x pattern] zipfile\n"); exit(1); } @@ -939,8 +957,11 @@ getopts(int argc, char *argv[]) int opt; optreset = optind = 1; - while ((opt = getopt(argc, argv, "aCcd:fjLlnopqtuvx:")) != -1) + while ((opt = getopt(argc, argv, "aCcd:fjLlnopqtuvx:Z1")) != -1) switch (opt) { + case '1': + Z1_opt = 1; + break; case 'a': a_opt = 1; break; @@ -991,6 +1012,9 @@ getopts(int argc, char *argv[]) case 'x': add_pattern(&exclude, optarg); break; + case 'Z': + zipinfo_mode = 1; + break; default: usage(); } @@ -1020,6 +1044,15 @@ main(int argc, char *argv[]) */ nopts = getopts(argc, argv); + /* + * When more of the zipinfo mode options are implemented, this + * will need to change. + */ + if (zipinfo_mode && !Z1_opt) { + printf("Zipinfo mode needs additional options\n"); + exit(1); + } + if (argc <= nopts) usage(); zipfile = argv[nopts++]; From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 04:33:38 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 88E1A106566B; Mon, 16 Apr 2012 04:33:38 +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 74EF28FC0A; Mon, 16 Apr 2012 04:33:38 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3G4XcsG016496; Mon, 16 Apr 2012 04:33:38 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3G4Xc3N016494; Mon, 16 Apr 2012 04:33:38 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201204160433.q3G4Xc3N016494@svn.freebsd.org> From: Warner Losh Date: Mon, 16 Apr 2012 04:33:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-svnadmin@freebsd.org X-SVN-Group: svnadmin MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234335 - svnadmin/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 04:33:38 -0000 Author: imp Date: Mon Apr 16 04:33:37 2012 New Revision: 234335 URL: http://svn.freebsd.org/changeset/base/234335 Log: Fly be free! Andrew Turner doesn't need my help anymore, and hasn't really needed it for quite a while. Approved by: core@ (implicit) Modified: svnadmin/conf/mentors Modified: svnadmin/conf/mentors ============================================================================== --- svnadmin/conf/mentors Mon Apr 16 02:52:32 2012 (r234334) +++ svnadmin/conf/mentors Mon Apr 16 04:33:37 2012 (r234335) @@ -11,7 +11,6 @@ # Mentee Mentor Optional comment anchie bz -andrew imp art avg Co-mentor: marcel bapt des benl philip Co-mentor: simon From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 06:34:54 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C2B98106564A; Mon, 16 Apr 2012 06:34:54 +0000 (UTC) (envelope-from melifaro@FreeBSD.org) Received: from mail.ipfw.ru (unknown [IPv6:2a01:4f8:120:6141::2]) by mx1.freebsd.org (Postfix) with ESMTP id 65D248FC0A; Mon, 16 Apr 2012 06:34:53 +0000 (UTC) Received: from v6.mpls.in ([2a02:978:2::5] helo=ws.su29.net) by mail.ipfw.ru with esmtpsa (TLSv1:CAMELLIA256-SHA:256) (Exim 4.76 (FreeBSD)) (envelope-from ) id 1SJfWd-000IBe-Dl; Mon, 16 Apr 2012 10:34:59 +0400 Message-ID: <4F8BBD4E.1040106@FreeBSD.org> Date: Mon, 16 Apr 2012 10:33:50 +0400 From: "Alexander V. Chernikov" User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:9.0) Gecko/20120121 Thunderbird/9.0 MIME-Version: 1.0 To: Adrian Chadd References: <201204060653.q366rwLa096182@svn.freebsd.org> <4F7E9413.20602@FreeBSD.org> In-Reply-To: Content-Type: multipart/mixed; boundary="------------010400080205040607050602" Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r233937 - in head/sys: kern net security/mac X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 06:34:54 -0000 This is a multi-part message in MIME format. --------------010400080205040607050602 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On 16.04.2012 01:17, Adrian Chadd wrote: > Hi, > > This has broken (at least) net80211 and bpf, with LOR: Yes, it is. Please try the attached patch > > # ifconfig wlan1 destroy > panic: mutex bpf global lock now owned at ....../net/bpf.c:656 > > > The stack: > > * ieee80211_vap_detach() > * ether_ifdetach() > * bpfdetach() > * - I bet this is bpf_detachd() > * _mtx_assert() > --------------010400080205040607050602 Content-Type: text/plain; name="bpf_cfglocks.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="bpf_cfglocks.diff" >From 5e621db1dae528f228e94374702d03501138fb1b Mon Sep 17 00:00:00 2001 From: "Alexander V. Chernikov" Date: Wed, 11 Apr 2012 20:04:58 +0400 Subject: [PATCH 1/1] * Final BPF locks patch --- sys/net/bpf.c | 379 +++++++++++++++++++++++++++++++++++++++-------------- sys/net/bpf.h | 1 + sys/net/bpfdesc.h | 2 + 3 files changed, 283 insertions(+), 99 deletions(-) diff --git a/sys/net/bpf.c b/sys/net/bpf.c index d87efc0..2556be4 100644 --- a/sys/net/bpf.c +++ b/sys/net/bpf.c @@ -147,6 +147,7 @@ static int bpf_bpfd_cnt; static void bpf_attachd(struct bpf_d *, struct bpf_if *); static void bpf_detachd(struct bpf_d *); +static void bpf_detachd_locked(struct bpf_d *); static void bpf_freed(struct bpf_d *); static int bpf_movein(struct uio *, int, struct ifnet *, struct mbuf **, struct sockaddr *, int *, struct bpf_insn *); @@ -206,6 +207,37 @@ static struct filterops bpfread_filtops = { .f_event = filt_bpfread, }; +eventhandler_tag bpf_ifdetach_cookie = NULL; + +/* + * LOCKING MODEL USED BY BPF: + * Locks: + * 1) global lock (BPF_LOCK). Mutex, used to protect interface addition/removal, + * some global counters and every bpf_if reference. + * 2) Interface lock. Rwlock, used to protect list of BPF descriptors and their filters. + * 3) Descriptor lock. Rwlock, used to protect BPF buffers and various structure fields + * used by bpf_mtap code. + * + * Lock order: + * + * Global lock, interface lock, descriptor lock + * + * We have to acquire interface lock before descriptor main lock due to BPF_MTAP[2] + * working model. In many places (like bpf_detachd) we start with BPF descriptor + * (and we need to at least rlock it to get reliable interface pointer). This + * gives us potential LOR. As a result, we use global lock to protect from bpf_if + * change in every such place. + * + * Changing d->bd_bif is protected by 1) global lock, 2) interface lock and + * 3) descriptor main wlock. + * Reading bd_bif can be protected by any of these locks, typically global lock. + * + * Changing read/write BPF filter is protected by the same three locks, + * the same applies for reading. + * + * Sleeping in global lock is not allowed due to bpfdetach() using it. + */ + /* * Wrapper functions for various buffering methods. If the set of buffer * modes expands, we will probably want to introduce a switch data structure @@ -577,6 +609,14 @@ bad: static void bpf_attachd(struct bpf_d *d, struct bpf_if *bp) { + int op_w; + + BPF_LOCK_ASSERT(); + + op_w = V_bpf_optimize_writers; + + if (d->bd_bif != NULL) + bpf_detachd_locked(d); /* * Point d at bp, and add d to the interface's list. * Since there are many applicaiotns using BPF for @@ -584,11 +624,13 @@ bpf_attachd(struct bpf_d *d, struct bpf_if *bp) * we can delay adding d to the list of active listeners until * some filter is configured. */ - d->bd_bif = bp; BPFIF_WLOCK(bp); + BPFD_WLOCK(d); + + d->bd_bif = bp; - if (V_bpf_optimize_writers != 0) { + if (op_w != 0) { /* Add to writers-only list */ LIST_INSERT_HEAD(&bp->bif_wlist, d, bd_next); /* @@ -600,16 +642,15 @@ bpf_attachd(struct bpf_d *d, struct bpf_if *bp) } else LIST_INSERT_HEAD(&bp->bif_dlist, d, bd_next); + BPFD_WUNLOCK(d); BPFIF_WUNLOCK(bp); - BPF_LOCK(); bpf_bpfd_cnt++; - BPF_UNLOCK(); CTR3(KTR_NET, "%s: bpf_attach called by pid %d, adding to %s list", __func__, d->bd_pid, d->bd_writer ? "writer" : "active"); - if (V_bpf_optimize_writers == 0) + if (op_w == 0) EVENTHANDLER_INVOKE(bpf_track, bp->bif_ifp, bp->bif_dlt, 1); } @@ -622,8 +663,20 @@ bpf_upgraded(struct bpf_d *d) { struct bpf_if *bp; + BPF_LOCK_ASSERT(); bp = d->bd_bif; + /* + * Filter can be set several times without specifying interface. + * Mark d as reader and exit. + */ + if (bp == NULL) { + BPFD_WLOCK(d); + d->bd_writer = 0; + BPFD_WUNLOCK(d); + return; + } + BPFIF_WLOCK(bp); BPFD_WLOCK(d); @@ -647,15 +700,26 @@ bpf_upgraded(struct bpf_d *d) static void bpf_detachd(struct bpf_d *d) { + BPF_LOCK(); + bpf_detachd_locked(d); + BPF_UNLOCK(); +} + +/* + * Detach a file from its interface. + */ +static void +bpf_detachd_locked(struct bpf_d *d) +{ int error; struct bpf_if *bp; struct ifnet *ifp; CTR2(KTR_NET, "%s: detach required by pid %d", __func__, d->bd_pid); - BPF_LOCK_ASSERT(); + if ((bp = d->bd_bif) == NULL) + return; - bp = d->bd_bif; BPFIF_WLOCK(bp); BPFD_WLOCK(d); @@ -672,7 +736,6 @@ bpf_detachd(struct bpf_d *d) BPFD_WUNLOCK(d); BPFIF_WUNLOCK(bp); - /* We're already protected by global lock. */ bpf_bpfd_cnt--; /* Call event handler iff d is attached */ @@ -716,10 +779,7 @@ bpf_dtor(void *data) d->bd_state = BPF_IDLE; BPFD_WUNLOCK(d); funsetown(&d->bd_sigio); - BPF_LOCK(); - if (d->bd_bif) - bpf_detachd(d); - BPF_UNLOCK(); + bpf_detachd(d); #ifdef MAC mac_bpfdesc_destroy(d); #endif /* MAC */ @@ -959,6 +1019,7 @@ bpfwrite(struct cdev *dev, struct uio *uio, int ioflag) BPF_PID_REFRESH_CUR(d); d->bd_wcount++; + /* XXX: locking required */ if (d->bd_bif == NULL) { d->bd_wdcount++; return (ENXIO); @@ -979,6 +1040,7 @@ bpfwrite(struct cdev *dev, struct uio *uio, int ioflag) bzero(&dst, sizeof(dst)); m = NULL; hlen = 0; + /* XXX: bpf_movein() can sleep */ error = bpf_movein(uio, (int)d->bd_bif->bif_dlt, ifp, &m, &dst, &hlen, d->bd_wfilter); if (error) { @@ -1158,7 +1220,9 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, case BIOCGDLTLIST32: case BIOCGRTIMEOUT32: case BIOCSRTIMEOUT32: + BPFD_WLOCK(d); d->bd_compat32 = 1; + BPFD_WUNLOCK(d); } #endif @@ -1176,11 +1240,11 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, { int n; - BPFD_WLOCK(d); + BPFD_RLOCK(d); n = d->bd_slen; - if (d->bd_hbuf) + if (d->bd_hbuf != 0) n += d->bd_hlen; - BPFD_WUNLOCK(d); + BPFD_RUNLOCK(d); *(int *)addr = n; break; @@ -1190,12 +1254,14 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, { struct ifnet *ifp; + BPF_LOCK(); if (d->bd_bif == NULL) error = EINVAL; else { ifp = d->bd_bif->bif_ifp; error = (*ifp->if_ioctl)(ifp, cmd, addr); } + BPF_UNLOCK(); break; } @@ -1203,7 +1269,9 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, * Get buffer len [for read()]. */ case BIOCGBLEN: + BPFD_RLOCK(d); *(u_int *)addr = d->bd_bufsize; + BPFD_RUNLOCK(d); break; /* @@ -1240,28 +1308,30 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, * Put interface into promiscuous mode. */ case BIOCPROMISC: + BPF_LOCK(); if (d->bd_bif == NULL) { /* * No interface attached yet. */ error = EINVAL; - break; - } - if (d->bd_promisc == 0) { + } else if (d->bd_promisc == 0) { error = ifpromisc(d->bd_bif->bif_ifp, 1); if (error == 0) d->bd_promisc = 1; } + BPF_UNLOCK(); break; /* * Get current data link type. */ case BIOCGDLT: + BPF_LOCK(); if (d->bd_bif == NULL) error = EINVAL; else *(u_int *)addr = d->bd_bif->bif_dlt; + BPF_UNLOCK(); break; /* @@ -1276,6 +1346,7 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, list32 = (struct bpf_dltlist32 *)addr; dltlist.bfl_len = list32->bfl_len; dltlist.bfl_list = PTRIN(list32->bfl_list); + BPF_LOCK(); if (d->bd_bif == NULL) error = EINVAL; else { @@ -1283,31 +1354,37 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, if (error == 0) list32->bfl_len = dltlist.bfl_len; } + BPF_UNLOCK(); break; } #endif case BIOCGDLTLIST: + BPF_LOCK(); if (d->bd_bif == NULL) error = EINVAL; else error = bpf_getdltlist(d, (struct bpf_dltlist *)addr); + BPF_UNLOCK(); break; /* * Set data link type. */ case BIOCSDLT: + BPF_LOCK(); if (d->bd_bif == NULL) error = EINVAL; else error = bpf_setdlt(d, *(u_int *)addr); + BPF_UNLOCK(); break; /* * Get interface name. */ case BIOCGETIF: + BPF_LOCK(); if (d->bd_bif == NULL) error = EINVAL; else { @@ -1317,13 +1394,16 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, strlcpy(ifr->ifr_name, ifp->if_xname, sizeof(ifr->ifr_name)); } + BPF_UNLOCK(); break; /* * Set interface. */ case BIOCSETIF: + BPF_LOCK(); error = bpf_setif(d, (struct ifreq *)addr); + BPF_UNLOCK(); break; /* @@ -1406,7 +1486,9 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, * Set immediate mode. */ case BIOCIMMEDIATE: + BPFD_WLOCK(d); d->bd_immediate = *(u_int *)addr; + BPFD_WUNLOCK(d); break; case BIOCVERSION: @@ -1422,21 +1504,27 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, * Get "header already complete" flag */ case BIOCGHDRCMPLT: + BPFD_RLOCK(d); *(u_int *)addr = d->bd_hdrcmplt; + BPFD_RUNLOCK(d); break; /* * Set "header already complete" flag */ case BIOCSHDRCMPLT: + BPFD_WLOCK(d); d->bd_hdrcmplt = *(u_int *)addr ? 1 : 0; + BPFD_WUNLOCK(d); break; /* * Get packet direction flag */ case BIOCGDIRECTION: + BPFD_RLOCK(d); *(u_int *)addr = d->bd_direction; + BPFD_RUNLOCK(d); break; /* @@ -1451,7 +1539,9 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, case BPF_D_IN: case BPF_D_INOUT: case BPF_D_OUT: + BPFD_WLOCK(d); d->bd_direction = direction; + BPFD_WUNLOCK(d); break; default: error = EINVAL; @@ -1463,7 +1553,9 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, * Get packet timestamp format and resolution. */ case BIOCGTSTAMP: + BPFD_RLOCK(d); *(u_int *)addr = d->bd_tstamp; + BPFD_RUNLOCK(d); break; /* @@ -1474,34 +1566,57 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, u_int func; func = *(u_int *)addr; - if (BPF_T_VALID(func)) + if (BPF_T_VALID(func)) { + BPFD_WLOCK(d); d->bd_tstamp = func; - else + BPFD_WUNLOCK(d); + } else error = EINVAL; } break; case BIOCFEEDBACK: + BPFD_WLOCK(d); d->bd_feedback = *(u_int *)addr; + BPFD_WUNLOCK(d); break; case BIOCLOCK: + BPFD_WLOCK(d); d->bd_locked = 1; + BPFD_WUNLOCK(d); break; case FIONBIO: /* Non-blocking I/O */ break; case FIOASYNC: /* Send signal on receive packets */ + BPFD_WLOCK(d); d->bd_async = *(int *)addr; + BPFD_WUNLOCK(d); break; case FIOSETOWN: - error = fsetown(*(int *)addr, &d->bd_sigio); + { + struct sigio *psio = d->bd_sigio; + + /* + * XXX: Add some sort of locking here? + * fsetown() can sleep. + * */ + error = fsetown(*(int *)addr, &psio); + if (error == 0) { + BPFD_WLOCK(d); + d->bd_sigio = psio; + BPFD_WUNLOCK(d); + } + } break; case FIOGETOWN: + BPFD_RLOCK(d); *(int *)addr = fgetown(&d->bd_sigio); + BPFD_RUNLOCK(d); break; /* This is deprecated, FIOSETOWN should be used instead. */ @@ -1522,16 +1637,23 @@ bpfioctl(struct cdev *dev, u_long cmd, caddr_t addr, int flags, if (sig >= NSIG) error = EINVAL; - else + else { + BPFD_WLOCK(d); d->bd_sig = sig; + BPFD_WUNLOCK(d); + } break; } case BIOCGRSIG: + BPFD_RLOCK(d); *(u_int *)addr = d->bd_sig; + BPFD_RUNLOCK(d); break; case BIOCGETBUFMODE: + BPFD_RLOCK(d); *(u_int *)addr = d->bd_bufmode; + BPFD_RUNLOCK(d); break; case BIOCSETBUFMODE: @@ -1609,6 +1731,20 @@ bpf_setf(struct bpf_d *d, struct bpf_program *fp, u_long cmd) cmd = BIOCSETWF; } #endif + + flen = fp->bf_len; + if ((flen > bpf_maxinsns) || ((fp->bf_insns == NULL) && (flen != 0))) + return (EINVAL); + + need_upgrade = 0; + size = flen * sizeof(*fp->bf_insns); + if (size > 0) + fcode = (struct bpf_insn *)malloc(size, M_BPF, M_WAITOK); + else + fcode = NULL; /* Make compiler happy */ + + BPF_LOCK(); + if (cmd == BIOCSETWF) { old = d->bd_wfilter; wfilter = 1; @@ -1623,13 +1759,12 @@ bpf_setf(struct bpf_d *d, struct bpf_program *fp, u_long cmd) #endif } if (fp->bf_insns == NULL) { - if (fp->bf_len != 0) - return (EINVAL); /* - * Protect filter change by interface lock, too. - * The same lock order is used by bpf_detachd(). + * Protect filter change by interface lock. + * Additionally, we are protected by global lock here. */ - BPFIF_WLOCK(d->bd_bif); + if (d->bd_bif != NULL) + BPFIF_WLOCK(d->bd_bif); BPFD_WLOCK(d); if (wfilter) d->bd_wfilter = NULL; @@ -1642,29 +1777,25 @@ bpf_setf(struct bpf_d *d, struct bpf_program *fp, u_long cmd) reset_d(d); } BPFD_WUNLOCK(d); - BPFIF_WUNLOCK(d->bd_bif); + if (d->bd_bif != NULL) + BPFIF_WUNLOCK(d->bd_bif); if (old != NULL) free((caddr_t)old, M_BPF); #ifdef BPF_JITTER if (ofunc != NULL) bpf_destroy_jit_filter(ofunc); #endif + BPF_UNLOCK(); return (0); } - flen = fp->bf_len; - if (flen > bpf_maxinsns) - return (EINVAL); - - need_upgrade = 0; - size = flen * sizeof(*fp->bf_insns); - fcode = (struct bpf_insn *)malloc(size, M_BPF, M_WAITOK); if (copyin((caddr_t)fp->bf_insns, (caddr_t)fcode, size) == 0 && bpf_validate(fcode, (int)flen)) { /* * Protect filter change by interface lock, too - * The same lock order is used by bpf_detachd(). + * Additionally, we are protected by global lock here. */ - BPFIF_WLOCK(d->bd_bif); + if (d->bd_bif != NULL) + BPFIF_WLOCK(d->bd_bif); BPFD_WLOCK(d); if (wfilter) d->bd_wfilter = fcode; @@ -1687,7 +1818,8 @@ bpf_setf(struct bpf_d *d, struct bpf_program *fp, u_long cmd) __func__, d->bd_pid, d->bd_writer, need_upgrade); } BPFD_WUNLOCK(d); - BPFIF_WUNLOCK(d->bd_bif); + if (d->bd_bif != NULL) + BPFIF_WUNLOCK(d->bd_bif); if (old != NULL) free((caddr_t)old, M_BPF); #ifdef BPF_JITTER @@ -1699,8 +1831,10 @@ bpf_setf(struct bpf_d *d, struct bpf_program *fp, u_long cmd) if (need_upgrade != 0) bpf_upgraded(d); + BPF_UNLOCK(); return (0); } + BPF_UNLOCK(); free((caddr_t)fcode, M_BPF); return (EINVAL); } @@ -1716,21 +1850,29 @@ bpf_setif(struct bpf_d *d, struct ifreq *ifr) struct bpf_if *bp; struct ifnet *theywant; + BPF_LOCK_ASSERT(); + theywant = ifunit(ifr->ifr_name); - if (theywant == NULL || theywant->if_bpf == NULL) + if (theywant == NULL || theywant->if_bpf == NULL) { return (ENXIO); + } bp = theywant->if_bpf; + BPFIF_RLOCK(bp); + if (bp->flags & BPFIF_FLAG_DYING) { + BPFIF_RUNLOCK(bp); + return (ENXIO); + } + BPFIF_RUNLOCK(bp); + /* * Behavior here depends on the buffering model. If we're using * kernel memory buffers, then we can allocate them here. If we're * using zero-copy, then the user process must have registered * buffers by the time we get here. If not, return an error. - * - * XXXRW: There are locking issues here with multi-threaded use: what - * if two threads try to set the interface at once? */ + switch (d->bd_bufmode) { case BPF_BUFMODE_BUFFER: if (d->bd_sbuf == NULL) @@ -1746,15 +1888,9 @@ bpf_setif(struct bpf_d *d, struct ifreq *ifr) default: panic("bpf_setif: bufmode %d", d->bd_bufmode); } - if (bp != d->bd_bif) { - if (d->bd_bif) - /* - * Detach if attached to something else. - */ - bpf_detachd(d); - + if (bp != d->bd_bif) bpf_attachd(d, bp); - } + BPFD_WLOCK(d); reset_d(d); BPFD_WUNLOCK(d); @@ -1942,22 +2078,22 @@ bpf_tap(struct bpf_if *bp, u_char *pkt, u_int pktlen) else #endif slen = bpf_filter(d->bd_rfilter, pkt, pktlen, pktlen); - if (slen != 0) { - /* - * Filter matches. Let's to acquire write lock. - */ - BPFD_WLOCK(d); + if (slen == 0) + continue; - d->bd_fcount++; - if (gottime < bpf_ts_quality(d->bd_tstamp)) - gottime = bpf_gettime(&bt, d->bd_tstamp, NULL); + /* + * Filter matches. Let's acquire write lock. + */ + BPFD_WLOCK(d); + + d->bd_fcount++; + if (gottime < bpf_ts_quality(d->bd_tstamp)) + gottime = bpf_gettime(&bt, d->bd_tstamp, NULL); #ifdef MAC - if (mac_bpfdesc_check_receive(d, bp->bif_ifp) == 0) + if (mac_bpfdesc_check_receive(d, bp->bif_ifp) == 0) #endif - catchpacket(d, pkt, pktlen, slen, - bpf_append_bytes, &bt); - BPFD_WUNLOCK(d); - } + catchpacket(d, pkt, pktlen, slen, bpf_append_bytes, &bt); + BPFD_WUNLOCK(d); } BPFIF_RUNLOCK(bp); } @@ -2004,19 +2140,19 @@ bpf_mtap(struct bpf_if *bp, struct mbuf *m) else #endif slen = bpf_filter(d->bd_rfilter, (u_char *)m, pktlen, 0); - if (slen != 0) { - BPFD_WLOCK(d); + if (slen == 0) + continue; + + BPFD_WLOCK(d); - d->bd_fcount++; - if (gottime < bpf_ts_quality(d->bd_tstamp)) - gottime = bpf_gettime(&bt, d->bd_tstamp, m); + d->bd_fcount++; + if (gottime < bpf_ts_quality(d->bd_tstamp)) + gottime = bpf_gettime(&bt, d->bd_tstamp, m); #ifdef MAC - if (mac_bpfdesc_check_receive(d, bp->bif_ifp) == 0) + if (mac_bpfdesc_check_receive(d, bp->bif_ifp) == 0) #endif - catchpacket(d, (u_char *)m, pktlen, slen, - bpf_append_mbuf, &bt); - BPFD_WUNLOCK(d); - } + catchpacket(d, (u_char *)m, pktlen, slen, bpf_append_mbuf, &bt); + BPFD_WUNLOCK(d); } BPFIF_RUNLOCK(bp); } @@ -2060,19 +2196,19 @@ bpf_mtap2(struct bpf_if *bp, void *data, u_int dlen, struct mbuf *m) continue; ++d->bd_rcount; slen = bpf_filter(d->bd_rfilter, (u_char *)&mb, pktlen, 0); - if (slen != 0) { - BPFD_WLOCK(d); + if (slen != 0) + continue; + + BPFD_WLOCK(d); - d->bd_fcount++; - if (gottime < bpf_ts_quality(d->bd_tstamp)) - gottime = bpf_gettime(&bt, d->bd_tstamp, m); + d->bd_fcount++; + if (gottime < bpf_ts_quality(d->bd_tstamp)) + gottime = bpf_gettime(&bt, d->bd_tstamp, m); #ifdef MAC - if (mac_bpfdesc_check_receive(d, bp->bif_ifp) == 0) + if (mac_bpfdesc_check_receive(d, bp->bif_ifp) == 0) #endif - catchpacket(d, (u_char *)&mb, pktlen, slen, - bpf_append_mbuf, &bt); - BPFD_WUNLOCK(d); - } + catchpacket(d, (u_char *)&mb, pktlen, slen, bpf_append_mbuf, &bt); + BPFD_WUNLOCK(d); } BPFIF_RUNLOCK(bp); } @@ -2352,19 +2488,20 @@ bpfattach2(struct ifnet *ifp, u_int dlt, u_int hdrlen, struct bpf_if **driverp) BPF_LOCK(); LIST_INSERT_HEAD(&bpf_iflist, bp, bif_next); - BPF_UNLOCK(); bp->bif_hdrlen = hdrlen; + BPF_UNLOCK(); if (bootverbose) if_printf(ifp, "bpf attached\n"); + CTR3(KTR_NET, "%s: Attaching BPF instance %p to interface %p", + __func__, bp, ifp); } /* - * Detach bpf from an interface. This involves detaching each descriptor - * associated with the interface, and leaving bd_bif NULL. Notify each - * descriptor as it's detached so that any sleepers wake up and get - * ENXIO. + * Detach bpf from an interface. This involves detaching each descriptor + * associated with the interface. Notify each descriptor as it's detached + * so that any sleepers wake up and get ENXIO. */ void bpfdetach(struct ifnet *ifp) @@ -2378,30 +2515,44 @@ bpfdetach(struct ifnet *ifp) #endif /* Find all bpf_if struct's which reference ifp and detach them. */ + BPF_LOCK(); do { - BPF_LOCK(); LIST_FOREACH(bp, &bpf_iflist, bif_next) { if (ifp == bp->bif_ifp) break; } if (bp != NULL) LIST_REMOVE(bp, bif_next); - BPF_UNLOCK(); if (bp != NULL) { #ifdef INVARIANTS ndetached++; #endif while ((d = LIST_FIRST(&bp->bif_dlist)) != NULL) { - bpf_detachd(d); + bpf_detachd_locked(d); BPFD_WLOCK(d); bpf_wakeup(d); BPFD_WUNLOCK(d); } - rw_destroy(&bp->bif_lock); - free(bp, M_BPF); + + while ((d = LIST_FIRST(&bp->bif_wlist)) != NULL) { + bpf_detachd_locked(d); + BPFD_WLOCK(d); + bpf_wakeup(d); + BPFD_WUNLOCK(d); + } + + /* + * Delay freing bp till interface is detached + * and all routes through this interface are removed. + * Mark bp as detached to restrict new consumers. + */ + BPFIF_WLOCK(bp); + bp->flags |= BPFIF_FLAG_DYING; + BPFIF_WUNLOCK(bp); } } while (bp != NULL); + BPF_UNLOCK(); #ifdef INVARIANTS if (ndetached == 0) @@ -2410,6 +2561,25 @@ bpfdetach(struct ifnet *ifp) } /* + * Interface departure handler + */ +static void +bpf_ifdetach(void *arg __unused, struct ifnet *ifp) +{ + struct bpf_if *bp; + + if ((bp = ifp->if_bpf) == NULL) + return; + + CTR3(KTR_NET, "%s: freing BPF instance %p for interface %p", + __func__, bp, ifp); + + ifp->if_bpf = NULL; + rw_destroy(&bp->bif_lock); + free(bp, M_BPF); +} + +/* * Get a list of available data link type of the interface. */ static int @@ -2419,16 +2589,16 @@ bpf_getdltlist(struct bpf_d *d, struct bpf_dltlist *bfl) struct ifnet *ifp; struct bpf_if *bp; + BPF_LOCK_ASSERT(); + ifp = d->bd_bif->bif_ifp; n = 0; error = 0; - BPF_LOCK(); LIST_FOREACH(bp, &bpf_iflist, bif_next) { if (bp->bif_ifp != ifp) continue; if (bfl->bfl_list != NULL) { if (n >= bfl->bfl_len) { - BPF_UNLOCK(); return (ENOMEM); } error = copyout(&bp->bif_dlt, @@ -2436,7 +2606,6 @@ bpf_getdltlist(struct bpf_d *d, struct bpf_dltlist *bfl) } n++; } - BPF_UNLOCK(); bfl->bfl_len = n; return (error); } @@ -2451,18 +2620,17 @@ bpf_setdlt(struct bpf_d *d, u_int dlt) struct ifnet *ifp; struct bpf_if *bp; + BPF_LOCK_ASSERT(); + if (d->bd_bif->bif_dlt == dlt) return (0); ifp = d->bd_bif->bif_ifp; - BPF_LOCK(); LIST_FOREACH(bp, &bpf_iflist, bif_next) { if (bp->bif_ifp == ifp && bp->bif_dlt == dlt) break; } - BPF_UNLOCK(); if (bp != NULL) { opromisc = d->bd_promisc; - bpf_detachd(d); bpf_attachd(d, bp); BPFD_WLOCK(d); reset_d(d); @@ -2477,6 +2645,7 @@ bpf_setdlt(struct bpf_d *d, u_int dlt) d->bd_promisc = 1; } } + return (bp == NULL ? EINVAL : 0); } @@ -2491,6 +2660,11 @@ bpf_drvinit(void *unused) dev = make_dev(&bpf_cdevsw, 0, UID_ROOT, GID_WHEEL, 0600, "bpf"); /* For compatibility */ make_dev_alias(dev, "bpf0"); + + /* Register interface departure handler */ + bpf_ifdetach_cookie = EVENTHANDLER_REGISTER( + ifnet_departure_event, bpf_ifdetach, NULL, + EVENTHANDLER_PRI_ANY); } /* @@ -2522,6 +2696,9 @@ bpf_zero_counters(void) BPF_UNLOCK(); } +/* + * Fill filter statistics + */ static void bpfstats_fill_xbpf(struct xbpf_d *d, struct bpf_d *bd) { @@ -2530,6 +2707,7 @@ bpfstats_fill_xbpf(struct xbpf_d *d, struct bpf_d *bd) BPFD_LOCK_ASSERT(bd); d->bd_structsize = sizeof(*d); d->bd_immediate = bd->bd_immediate; + /* XXX: reading should be protected by global lock */ d->bd_promisc = bd->bd_promisc; d->bd_hdrcmplt = bd->bd_hdrcmplt; d->bd_direction = bd->bd_direction; @@ -2553,6 +2731,9 @@ bpfstats_fill_xbpf(struct xbpf_d *d, struct bpf_d *bd) d->bd_bufmode = bd->bd_bufmode; } +/* + * Handle `netstat -B' stats request + */ static int bpf_stats_sysctl(SYSCTL_HANDLER_ARGS) { diff --git a/sys/net/bpf.h b/sys/net/bpf.h index fa34894..6a7e661 100644 --- a/sys/net/bpf.h +++ b/sys/net/bpf.h @@ -1105,6 +1105,7 @@ struct bpf_if { struct ifnet *bif_ifp; /* corresponding interface */ struct rwlock bif_lock; /* interface lock */ LIST_HEAD(, bpf_d) bif_wlist; /* writer-only list */ + int flags; /* Interface flags */ #endif }; diff --git a/sys/net/bpfdesc.h b/sys/net/bpfdesc.h index 842c018..23b6eb6 100644 --- a/sys/net/bpfdesc.h +++ b/sys/net/bpfdesc.h @@ -159,4 +159,6 @@ struct xbpf_d { #define BPFIF_WLOCK(bif) rw_wlock(&(bif)->bif_lock) #define BPFIF_WUNLOCK(bif) rw_wunlock(&(bif)->bif_lock) +#define BPFIF_FLAG_DYING 1 /* Reject new bpf consumers */ + #endif -- 1.7.9.4 --------------010400080205040607050602-- From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 07:02:50 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EF218106566C; Mon, 16 Apr 2012 07:02:50 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebius.int.ru (glebius.int.ru [81.19.64.117]) by mx1.freebsd.org (Postfix) with ESMTP id 69D478FC15; Mon, 16 Apr 2012 07:02:50 +0000 (UTC) Received: from cell.glebius.int.ru (localhost [127.0.0.1]) by cell.glebius.int.ru (8.14.5/8.14.5) with ESMTP id q3G72mvE088053; Mon, 16 Apr 2012 11:02:48 +0400 (MSK) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebius.int.ru (8.14.5/8.14.5/Submit) id q3G72mbW088052; Mon, 16 Apr 2012 11:02:48 +0400 (MSK) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebius.int.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Mon, 16 Apr 2012 11:02:48 +0400 From: Gleb Smirnoff To: Eitan Adler Message-ID: <20120416070248.GQ9391@FreeBSD.org> References: <201204152356.q3FNu4W4007224@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <201204152356.q3FNu4W4007224@svn.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: r234329 - head/lib/libc/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 07:02:51 -0000 On Sun, Apr 15, 2012 at 11:56:04PM +0000, Eitan Adler wrote: E> Author: eadler E> Date: Sun Apr 15 23:56:03 2012 E> New Revision: 234329 E> URL: http://svn.freebsd.org/changeset/base/234329 E> E> Log: E> When searching for uninitialized memory usage add ensure that the entire E> struct is set to zero. E> E> PR: bin/166483 E> Submitted by: Roy Marples E> Reviewed by: delphij E> Approved by: cperciva E> MFC after: 3 days E> E> Modified: E> head/lib/libc/net/if_nametoindex.c E> E> Modified: head/lib/libc/net/if_nametoindex.c E> ============================================================================== E> --- head/lib/libc/net/if_nametoindex.c Sun Apr 15 23:50:13 2012 (r234328) E> +++ head/lib/libc/net/if_nametoindex.c Sun Apr 15 23:56:03 2012 (r234329) E> @@ -70,6 +70,9 @@ if_nametoindex(const char *ifname) E> E> s = _socket(AF_INET, SOCK_DGRAM, 0); E> if (s != -1) { E> +#ifdef PURIFY E> + memset(&ifr, 0, sizeof(ifr)); E> +#endif E> strlcpy(ifr.ifr_name, ifname, sizeof(ifr.ifr_name)); E> if (_ioctl(s, SIOCGIFINDEX, &ifr) != -1) { E> _close(s); Is that PURIFY documented anywhere? -- Totus tuus, Glebius. From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 08:19:44 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4B89D106566B; Mon, 16 Apr 2012 08:19:44 +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 368968FC0A; Mon, 16 Apr 2012 08:19:44 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3G8JiCn023633; Mon, 16 Apr 2012 08:19:44 GMT (envelope-from mm@svn.freebsd.org) Received: (from mm@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3G8Ji0d023631; Mon, 16 Apr 2012 08:19:44 GMT (envelope-from mm@svn.freebsd.org) Message-Id: <201204160819.q3G8Ji0d023631@svn.freebsd.org> From: Martin Matuska Date: Mon, 16 Apr 2012 08:19: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: r234336 - head/cddl/contrib/opensolaris/cmd/zpool X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 08:19:44 -0000 Author: mm Date: Mon Apr 16 08:19:43 2012 New Revision: 234336 URL: http://svn.freebsd.org/changeset/base/234336 Log: Fix typo miror -> mirror Reported by: Glen Barber MFC after: 3 days Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 ============================================================================== --- head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Mon Apr 16 04:33:37 2012 (r234335) +++ head/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Mon Apr 16 08:19:43 2012 (r234336) @@ -1779,7 +1779,7 @@ The following command creates a storage pool consisting of two, two-way mirrors and mirrored log devices: .Bd -literal -offset 2n -.Li # Ic zpool create pool mirror da0 da1 mirror da2 da3 log miror da4 da5 +.Li # Ic zpool create pool mirror da0 da1 mirror da2 da3 log mirror da4 da5 .Ed .It Sy Example 14 No Adding Cache Devices to a Tn ZFS No Pool .Pp From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 09:38:21 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 55315106564A; Mon, 16 Apr 2012 09:38:21 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3E4468FC08; Mon, 16 Apr 2012 09:38:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3G9cLKx026098; Mon, 16 Apr 2012 09:38:21 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3G9cLmw026093; Mon, 16 Apr 2012 09:38:21 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201204160938.q3G9cLmw026093@svn.freebsd.org> From: Andrew Turner Date: Mon, 16 Apr 2012 09:38: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: r234337 - in head: lib/libc/arm/gen sys/arm/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 09:38:21 -0000 Author: andrew Date: Mon Apr 16 09:38:20 2012 New Revision: 234337 URL: http://svn.freebsd.org/changeset/base/234337 Log: Replace the C implementation of __aeabi_read_tp with an assembly version. This ensures we follow the ABI by preserving registers r1-r3. Reviewed by: jmallett, imp Added: head/lib/libc/arm/gen/__aeabi_read_tp.S (contents, props changed) Deleted: head/lib/libc/arm/gen/__aeabi_read_tp.c Modified: head/lib/libc/arm/gen/Makefile.inc head/sys/arm/include/armreg.h head/sys/arm/include/sysarch.h Modified: head/lib/libc/arm/gen/Makefile.inc ============================================================================== --- head/lib/libc/arm/gen/Makefile.inc Mon Apr 16 08:19:43 2012 (r234336) +++ head/lib/libc/arm/gen/Makefile.inc Mon Apr 16 09:38:20 2012 (r234337) @@ -3,4 +3,4 @@ SRCS+= _ctx_start.S _setjmp.S _set_tp.c alloca.S fabs.c \ getcontextx.c infinity.c ldexp.c makecontext.c \ - __aeabi_read_tp.c setjmp.S signalcontext.c sigsetjmp.S divsi3.S flt_rounds.c + __aeabi_read_tp.S setjmp.S signalcontext.c sigsetjmp.S divsi3.S flt_rounds.c Added: head/lib/libc/arm/gen/__aeabi_read_tp.S ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lib/libc/arm/gen/__aeabi_read_tp.S Mon Apr 16 09:38:20 2012 (r234337) @@ -0,0 +1,40 @@ +/*- + * Copyright (c) 2012 Oleksandr Tymoshenko + * Copyright (c) 2012 Andrew Turner + * 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 + +ENTRY(__aeabi_read_tp) + ldr r0, .Larm_tp_address + ldr r0, [r0] + RET + +.Larm_tp_address: + .word ARM_TP_ADDRESS + Modified: head/sys/arm/include/armreg.h ============================================================================== --- head/sys/arm/include/armreg.h Mon Apr 16 08:19:43 2012 (r234336) +++ head/sys/arm/include/armreg.h Mon Apr 16 09:38:20 2012 (r234337) @@ -316,8 +316,13 @@ /* * Address of the vector page, low and high versions. */ +#ifndef __ASSEMBLER__ #define ARM_VECTORS_LOW 0x00000000U #define ARM_VECTORS_HIGH 0xffff0000U +#else +#define ARM_VECTORS_LOW 0 +#define ARM_VECTORS_HIGH 0xffff0000 +#endif /* * ARM Instructions Modified: head/sys/arm/include/sysarch.h ============================================================================== --- head/sys/arm/include/sysarch.h Mon Apr 16 08:19:43 2012 (r234336) +++ head/sys/arm/include/sysarch.h Mon Apr 16 09:38:20 2012 (r234337) @@ -55,6 +55,7 @@ #define ARM_RAS_END (ARM_TP_ADDRESS + 8) #ifndef LOCORE +#ifndef __ASSEMBLER__ #include @@ -85,6 +86,7 @@ int sysarch(int, void *); __END_DECLS #endif +#endif /* __ASSEMBLER__ */ #endif /* LOCORE */ #endif /* !_ARM_SYSARCH_H_ */ From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 10:33:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6BB99106564A; Mon, 16 Apr 2012 10:33:47 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 57A908FC0C; Mon, 16 Apr 2012 10:33:47 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GAXl9F027902; Mon, 16 Apr 2012 10:33:47 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GAXlqa027900; Mon, 16 Apr 2012 10:33:47 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201204161033.q3GAXlqa027900@svn.freebsd.org> From: Andriy Gapon Date: Mon, 16 Apr 2012 10:33: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: r234338 - head/sys/pci X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 10:33:47 -0000 Author: avg Date: Mon Apr 16 10:33:46 2012 New Revision: 234338 URL: http://svn.freebsd.org/changeset/base/234338 Log: intpm: add ATI IXP400 pci id PR: kern/136762 Submitted by: Aurelien Mere Tested by: Jens Link MFC after: 5 days Modified: head/sys/pci/intpm.c Modified: head/sys/pci/intpm.c ============================================================================== --- head/sys/pci/intpm.c Mon Apr 16 09:38:20 2012 (r234337) +++ head/sys/pci/intpm.c Mon Apr 16 10:33:46 2012 (r234338) @@ -98,6 +98,9 @@ intsmb_probe(device_t dev) #endif device_set_desc(dev, "Intel PIIX4 SMBUS Interface"); break; + case 0x43721002: + device_set_desc(dev, "ATI IXP400 SMBus Controller"); + break; case 0x43851002: /* SB800 and newer can not be configured in a compatible way. */ if (pci_get_revid(dev) >= 0x40) From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 10:43:07 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 17181106566B; Mon, 16 Apr 2012 10:43:07 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 033D98FC14; Mon, 16 Apr 2012 10:43:07 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GAh60b028285; Mon, 16 Apr 2012 10:43:06 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GAh6NN028283; Mon, 16 Apr 2012 10:43:06 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201204161043.q3GAh6NN028283@svn.freebsd.org> From: Andriy Gapon Date: Mon, 16 Apr 2012 10:43: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: r234339 - head/sys/boot/i386/zfsboot X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 10:43:07 -0000 Author: avg Date: Mon Apr 16 10:43:06 2012 New Revision: 234339 URL: http://svn.freebsd.org/changeset/base/234339 Log: zfsboot: honor -q if it's present in boot.config Before r228267 the option was honored but the original content of boot.config was not preserved. I tried to fix that but missed the idea. Now the proper way of doing things is taken from i386/boo2. Also, a comment is added to explain this a little bit unobvious behavior. Inspired by: jhb MFC after: 5 days Modified: head/sys/boot/i386/zfsboot/zfsboot.c Modified: head/sys/boot/i386/zfsboot/zfsboot.c ============================================================================== --- head/sys/boot/i386/zfsboot/zfsboot.c Mon Apr 16 10:33:46 2012 (r234338) +++ head/sys/boot/i386/zfsboot/zfsboot.c Mon Apr 16 10:43:06 2012 (r234339) @@ -93,6 +93,7 @@ static const char *const dev_nm[NDEV] = static const unsigned char dev_maj[NDEV] = {30, 4, 2}; static char cmd[512]; +static char cmddup[512]; static char kname[1024]; static int comspeed = SIOSPD; static struct bootinfo bootinfo; @@ -541,10 +542,15 @@ main(void) } if (*cmd) { - if (!OPT_CHECK(RBX_QUIET)) - printf("%s: %s", PATH_CONFIG, cmd); + /* + * Note that parse() is destructive to cmd[] and we also want + * to honor RBX_QUIET option that could be present in cmd[]. + */ + memcpy(cmddup, cmd, sizeof(cmd)); if (parse()) autoboot = 0; + if (!OPT_CHECK(RBX_QUIET)) + printf("%s: %s", PATH_CONFIG, cmddup); /* Do not process this command twice */ *cmd = 0; } From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 12:49:19 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 97334106564A; Mon, 16 Apr 2012 12:49:19 +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 8190A8FC16; Mon, 16 Apr 2012 12:49:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GCnJao034220; Mon, 16 Apr 2012 12:49:19 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GCnJgr034217; Mon, 16 Apr 2012 12:49:19 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201204161249.q3GCnJgr034217@svn.freebsd.org> From: Gavin Atkinson Date: Mon, 16 Apr 2012 12:49:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234340 - stable/9/contrib/tnftp/src X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 12:49:19 -0000 Author: gavin Date: Mon Apr 16 12:49:19 2012 New Revision: 234340 URL: http://svn.freebsd.org/changeset/base/234340 Log: Merge r232779 from head: Move determination of socket buffer sizes from startup to the first time a socket is used. The previous code structure assumed that AF_INET sockets were always available, which is an invalid assumption on IPv6-only systems. This merges the fololowing revisions from NetBSD: src/usr.bin/ftp/main.c 1.120 src/usr.bin/ftp/util.c 1.156 PR: bin/162661 Obtained from: NetBSD Modified: stable/9/contrib/tnftp/src/main.c stable/9/contrib/tnftp/src/util.c Directory Properties: stable/9/contrib/tnftp/ (props changed) Modified: stable/9/contrib/tnftp/src/main.c ============================================================================== --- stable/9/contrib/tnftp/src/main.c Mon Apr 16 10:43:06 2012 (r234339) +++ stable/9/contrib/tnftp/src/main.c Mon Apr 16 12:49:19 2012 (r234340) @@ -146,9 +146,8 @@ main(int volatile argc, char **volatile struct passwd *pw; char *cp, *ep, *anonpass, *upload_path, *src_addr; const char *anonuser; - int dumbterm, s, isupload; + int dumbterm, isupload; size_t len; - socklen_t slen; tzset(); #if 0 /* tnftp */ /* XXX */ @@ -213,35 +212,6 @@ main(int volatile argc, char **volatile if (cp != NULL && strlcpy(netrc, cp, sizeof(netrc)) >= sizeof(netrc)) errx(1, "$NETRC `%s': %s", cp, strerror(ENAMETOOLONG)); - /* - * Get the default socket buffer sizes if we don't already have them. - * It doesn't matter which socket we do this to, because on the first - * call no socket buffer sizes will have been modified, so we are - * guaranteed to get the system defaults. - */ - s = socket(AF_INET, SOCK_STREAM, 0); - if (s == -1) - err(1, "Can't create socket to determine default socket sizes"); - slen = sizeof(rcvbuf_size); - if (getsockopt(s, SOL_SOCKET, SO_RCVBUF, - (void *)&rcvbuf_size, &slen) == -1) - err(1, "Unable to get default rcvbuf size"); - slen = sizeof(sndbuf_size); - if (getsockopt(s, SOL_SOCKET, SO_SNDBUF, - (void *)&sndbuf_size, &slen) == -1) - err(1, "Unable to get default sndbuf size"); - (void)close(s); - /* sanity check returned buffer sizes */ - if (rcvbuf_size <= 0) - rcvbuf_size = 8 * 1024; - if (sndbuf_size <= 0) - sndbuf_size = 8 * 1024; - - if (sndbuf_size > 8 * 1024 * 1024) - sndbuf_size = 8 * 1024 * 1024; - if (rcvbuf_size > 8 * 1024 * 1024) - rcvbuf_size = 8 * 1024 * 1024; - marg_sl = ftp_sl_init(); if ((tmpdir = getenv("TMPDIR")) == NULL) tmpdir = _PATH_TMP; Modified: stable/9/contrib/tnftp/src/util.c ============================================================================== --- stable/9/contrib/tnftp/src/util.c Mon Apr 16 10:43:06 2012 (r234339) +++ stable/9/contrib/tnftp/src/util.c Mon Apr 16 12:49:19 2012 (r234340) @@ -1060,6 +1060,32 @@ strsuftoi(const char *arg) void setupsockbufsize(int sock) { + socklen_t slen; + + if (0 == rcvbuf_size) { + slen = sizeof(rcvbuf_size); + if (getsockopt(sock, SOL_SOCKET, SO_RCVBUF, + (void *)&rcvbuf_size, &slen) == -1) + err(1, "Unable to determine rcvbuf size"); + if (rcvbuf_size <= 0) + rcvbuf_size = 8 * 1024; + if (rcvbuf_size > 8 * 1024 * 1024) + rcvbuf_size = 8 * 1024 * 1024; + DPRINTF("setupsockbufsize: rcvbuf_size determined as %d\n", + rcvbuf_size); + } + if (0 == sndbuf_size) { + slen = sizeof(sndbuf_size); + if (getsockopt(sock, SOL_SOCKET, SO_SNDBUF, + (void *)&sndbuf_size, &slen) == -1) + err(1, "Unable to determine sndbuf size"); + if (sndbuf_size <= 0) + sndbuf_size = 8 * 1024; + if (sndbuf_size > 8 * 1024 * 1024) + sndbuf_size = 8 * 1024 * 1024; + DPRINTF("setupsockbufsize: sndbuf_size determined as %d\n", + sndbuf_size); + } if (setsockopt(sock, SOL_SOCKET, SO_SNDBUF, (void *)&sndbuf_size, sizeof(sndbuf_size)) == -1) From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 13:41:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 875FB106566C; Mon, 16 Apr 2012 13:41:47 +0000 (UTC) (envelope-from zec@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 734A98FC0C; Mon, 16 Apr 2012 13:41:47 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GDflTU035960; Mon, 16 Apr 2012 13:41:47 GMT (envelope-from zec@svn.freebsd.org) Received: (from zec@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GDfl7B035958; Mon, 16 Apr 2012 13:41:47 GMT (envelope-from zec@svn.freebsd.org) Message-Id: <201204161341.q3GDfl7B035958@svn.freebsd.org> From: Marko Zec Date: Mon, 16 Apr 2012 13:41: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: r234341 - head/sys/netgraph X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 13:41:47 -0000 Author: zec Date: Mon Apr 16 13:41:46 2012 New Revision: 234341 URL: http://svn.freebsd.org/changeset/base/234341 Log: #include is no longer needed here. Spotted by: Ed Maste MFC after: 3 days. Modified: head/sys/netgraph/ng_source.c Modified: head/sys/netgraph/ng_source.c ============================================================================== --- head/sys/netgraph/ng_source.c Mon Apr 16 12:49:19 2012 (r234340) +++ head/sys/netgraph/ng_source.c Mon Apr 16 13:41:46 2012 (r234341) @@ -68,7 +68,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include #include #include From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 13:49:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 42170106566B; Mon, 16 Apr 2012 13:49:04 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2CBA88FC14; Mon, 16 Apr 2012 13:49:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GDn4Ng036233; Mon, 16 Apr 2012 13:49:04 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GDn3a2036228; Mon, 16 Apr 2012 13:49:03 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201204161349.q3GDn3a2036228@svn.freebsd.org> From: Gleb Smirnoff Date: Mon, 16 Apr 2012 13:49: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: r234342 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 13:49:04 -0000 Author: glebius Date: Mon Apr 16 13:49:03 2012 New Revision: 234342 URL: http://svn.freebsd.org/changeset/base/234342 Log: When we receive an ICMP unreach need fragmentation datagram, we take proposed MTU value from it and update the TCP host cache. Then tcp_mss_update() is called on the corresponding tcpcb. It finds the just allocated entry in the TCP host cache and updates MSS on the tcpcb. And then we do a fast retransmit of what we have in the tcp send buffer. This sequence gets broken if the TCP host cache is exausted. In this case allocation fails, and later called tcp_mss_update() finds nothing in cache. The fast retransmit is done with not reduced MSS and is immidiately replied by remote host with new ICMP datagrams and the cycle repeats. This ping-pong can go up to wirespeed. To fix this: - tcp_mss_update() gets new parameter - mtuoffer, that is like offer, but needs to have min_protoh subtracted. - tcp_mtudisc() as notification method renamed to tcp_mtudisc_notify(). - tcp_mtudisc() now accepts not a useless error argument, but proposed MTU value, that is passed to tcp_mss_update() as mtuoffer. Reported by: az Reported by: Andrey Zonov Reviewed by: andre (previous version of patch) Modified: head/sys/netinet/tcp_input.c head/sys/netinet/tcp_output.c head/sys/netinet/tcp_subr.c head/sys/netinet/tcp_var.h Modified: head/sys/netinet/tcp_input.c ============================================================================== --- head/sys/netinet/tcp_input.c Mon Apr 16 13:41:46 2012 (r234341) +++ head/sys/netinet/tcp_input.c Mon Apr 16 13:49:03 2012 (r234342) @@ -3288,22 +3288,19 @@ tcp_xmit_timer(struct tcpcb *tp, int rtt * are present. Store the upper limit of the length of options plus * data in maxopd. * - * In case of T/TCP, we call this routine during implicit connection - * setup as well (offer = -1), to initialize maxseg from the cached - * MSS of our peer. - * * NOTE that this routine is only called when we process an incoming - * segment. Outgoing SYN/ACK MSS settings are handled in tcp_mssopt(). + * segment, or an ICMP need fragmentation datagram. Outgoing SYN/ACK MSS + * settings are handled in tcp_mssopt(). */ void -tcp_mss_update(struct tcpcb *tp, int offer, +tcp_mss_update(struct tcpcb *tp, int offer, int mtuoffer, struct hc_metrics_lite *metricptr, int *mtuflags) { int mss = 0; u_long maxmtu = 0; struct inpcb *inp = tp->t_inpcb; struct hc_metrics_lite metrics; - int origoffer = offer; + int origoffer; #ifdef INET6 int isipv6 = ((inp->inp_vflag & INP_IPV6) != 0) ? 1 : 0; size_t min_protoh = isipv6 ? @@ -3315,6 +3312,12 @@ tcp_mss_update(struct tcpcb *tp, int off INP_WLOCK_ASSERT(tp->t_inpcb); + if (mtuoffer != -1) { + KASSERT(offer == -1, ("%s: conflict", __func__)); + offer = mtuoffer - min_protoh; + } + origoffer = offer; + /* Initialize. */ #ifdef INET6 if (isipv6) { @@ -3473,7 +3476,7 @@ tcp_mss(struct tcpcb *tp, int offer) KASSERT(tp != NULL, ("%s: tp == NULL", __func__)); - tcp_mss_update(tp, offer, &metrics, &mtuflags); + tcp_mss_update(tp, offer, -1, &metrics, &mtuflags); mss = tp->t_maxseg; inp = tp->t_inpcb; Modified: head/sys/netinet/tcp_output.c ============================================================================== --- head/sys/netinet/tcp_output.c Mon Apr 16 13:41:46 2012 (r234341) +++ head/sys/netinet/tcp_output.c Mon Apr 16 13:49:03 2012 (r234342) @@ -1293,7 +1293,7 @@ out: */ if (tso) tp->t_flags &= ~TF_TSO; - tcp_mtudisc(tp->t_inpcb, 0); + tcp_mtudisc(tp->t_inpcb, -1); return (0); case EHOSTDOWN: case EHOSTUNREACH: Modified: head/sys/netinet/tcp_subr.c ============================================================================== --- head/sys/netinet/tcp_subr.c Mon Apr 16 13:41:46 2012 (r234341) +++ head/sys/netinet/tcp_subr.c Mon Apr 16 13:49:03 2012 (r234342) @@ -222,6 +222,7 @@ VNET_DEFINE(uma_zone_t, sack_hole_zone); VNET_DEFINE(struct hhook_head *, tcp_hhh[HHOOK_TCP_LAST+1]); static struct inpcb *tcp_notify(struct inpcb *, int); +static struct inpcb *tcp_mtudisc_notify(struct inpcb *, int); static char * tcp_log_addr(struct in_conninfo *inc, struct tcphdr *th, void *ip4hdr, const void *ip6hdr); @@ -1337,7 +1338,7 @@ tcp_ctlinput(int cmd, struct sockaddr *s return; if (cmd == PRC_MSGSIZE) - notify = tcp_mtudisc; + notify = tcp_mtudisc_notify; else if (V_icmp_may_rst && (cmd == PRC_UNREACH_ADMIN_PROHIB || cmd == PRC_UNREACH_PORT || cmd == PRC_TIMXCEED_INTRANS) && ip) notify = tcp_drop_syn_sent; @@ -1410,9 +1411,10 @@ tcp_ctlinput(int cmd, struct sockaddr *s */ if (mtu <= tcp_maxmtu(&inc, NULL)) tcp_hc_updatemtu(&inc, mtu); - } - - inp = (*notify)(inp, inetctlerrmap[cmd]); + tcp_mtudisc(inp, mtu); + } else + inp = (*notify)(inp, + inetctlerrmap[cmd]); } } if (inp != NULL) @@ -1452,7 +1454,7 @@ tcp6_ctlinput(int cmd, struct sockaddr * return; if (cmd == PRC_MSGSIZE) - notify = tcp_mtudisc; + notify = tcp_mtudisc_notify; else if (!PRC_IS_REDIRECT(cmd) && ((unsigned)cmd >= PRC_NCMDS || inet6ctlerrmap[cmd] == 0)) return; @@ -1653,12 +1655,19 @@ tcp_drop_syn_sent(struct inpcb *inp, int /* * When `need fragmentation' ICMP is received, update our idea of the MSS - * based on the new value in the route. Also nudge TCP to send something, - * since we know the packet we just sent was dropped. + * based on the new value. Also nudge TCP to send something, since we + * know the packet we just sent was dropped. * This duplicates some code in the tcp_mss() function in tcp_input.c. */ +static struct inpcb * +tcp_mtudisc_notify(struct inpcb *inp, int error) +{ + + return (tcp_mtudisc(inp, -1)); +} + struct inpcb * -tcp_mtudisc(struct inpcb *inp, int errno) +tcp_mtudisc(struct inpcb *inp, int mtuoffer) { struct tcpcb *tp; struct socket *so; @@ -1671,7 +1680,7 @@ tcp_mtudisc(struct inpcb *inp, int errno tp = intotcpcb(inp); KASSERT(tp != NULL, ("tcp_mtudisc: tp == NULL")); - tcp_mss_update(tp, -1, NULL, NULL); + tcp_mss_update(tp, -1, mtuoffer, NULL, NULL); so = inp->inp_socket; SOCKBUF_LOCK(&so->so_snd); Modified: head/sys/netinet/tcp_var.h ============================================================================== --- head/sys/netinet/tcp_var.h Mon Apr 16 13:41:46 2012 (r234341) +++ head/sys/netinet/tcp_var.h Mon Apr 16 13:49:03 2012 (r234342) @@ -675,7 +675,8 @@ void tcp_reass_destroy(void); void tcp_input(struct mbuf *, int); u_long tcp_maxmtu(struct in_conninfo *, int *); u_long tcp_maxmtu6(struct in_conninfo *, int *); -void tcp_mss_update(struct tcpcb *, int, struct hc_metrics_lite *, int *); +void tcp_mss_update(struct tcpcb *, int, int, struct hc_metrics_lite *, + int *); void tcp_mss(struct tcpcb *, int); int tcp_mssopt(struct in_conninfo *); struct inpcb * From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 14:18:01 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B0710106566B; Mon, 16 Apr 2012 14:18:01 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 750768FC0C; Mon, 16 Apr 2012 14:18:01 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id C2B62B911; Mon, 16 Apr 2012 10:18:00 -0400 (EDT) From: John Baldwin To: Marius Strobl Date: Mon, 16 Apr 2012 09:50:47 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p10; KDE/4.5.5; amd64; ; ) References: <201204141121.q3EBLOmG027664@svn.freebsd.org> In-Reply-To: <201204141121.q3EBLOmG027664@svn.freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201204160950.47764.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Mon, 16 Apr 2012 10:18:00 -0400 (EDT) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234280 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 14:18:01 -0000 On Saturday, April 14, 2012 7:21:24 am Marius Strobl wrote: > Author: marius > Date: Sat Apr 14 11:21:24 2012 > New Revision: 234280 > URL: http://svn.freebsd.org/changeset/base/234280 > > Log: > Fix !DDB build after r234190. > > Modified: > head/sys/kern/subr_turnstile.c Doh, thanks for fixing! -- John Baldwin From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 14:18:02 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E8E631065673; Mon, 16 Apr 2012 14:18:02 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id A25828FC1B; Mon, 16 Apr 2012 14:18:02 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id DF20BB94A; Mon, 16 Apr 2012 10:18:01 -0400 (EDT) From: John Baldwin To: "Justin T. Gibbs" Date: Mon, 16 Apr 2012 09:54:00 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p10; KDE/4.5.5; amd64; ; ) References: <201204092241.q39MfJZn081610@svn.freebsd.org> <20120410114118.GB93449@alchemy.franken.de> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201204160954.00991.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Mon, 16 Apr 2012 10:18:02 -0400 (EDT) Cc: Attilio Rao , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Marius Strobl Subject: Re: svn commit: r234074 - in head/sys: amd64/amd64 i386/i386 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 14:18:03 -0000 On Saturday, April 14, 2012 7:05:35 pm Justin T. Gibbs wrote: > > On Apr 10, 2012, at 5:41 AM, Marius Strobl wrote: > > > On Tue, Apr 10, 2012 at 01:03:56AM +0100, Attilio Rao wrote: > >> Il 10 aprile 2012 00:09, Marius Strobl ha scritto: > >>> On Mon, Apr 09, 2012 at 10:41:19PM +0000, Attilio Rao wrote: > >>>> Author: attilio > >>>> Date: Mon Apr ??9 22:41:19 2012 > >>>> New Revision: 234074 > >>>> URL: http://svn.freebsd.org/changeset/base/234074 > >>>> > >>>> Log: > >>>> ?? BSP is not added to the mask of valid target CPUs for interrupts > >>>> ?? in set_apic_interrupt_ids(). Besides, set_apic_interrupts_ids() is not > >>>> ?? called in the !SMP case too. > >>>> ?? Fix this by: > >>>> ?? - Adding the BSP as an interrupt target directly in cpu_startup(). > >>>> ?? - Remove an obsolete optimization where the BSP are skipped in > >>>> ?? ?? set_apic_interrupt_ids(). > >>>> > >>>> ?? Reported by: ?? ?? ?? ??jh > >>>> ?? Reviewed by: ?? ?? ?? ??jhb > >>>> ?? MFC after: ??3 days > >>>> ?? X-MFC: ?? ?? ?? ?? ?? ?? ??r233961 > >>>> ?? Pointy hat to: ?? ?? ??me > >>>> > >>>> Modified: > >>>> ?? head/sys/amd64/amd64/machdep.c > >>>> ?? head/sys/amd64/amd64/mp_machdep.c > >>>> ?? head/sys/i386/i386/machdep.c > >>>> ?? head/sys/i386/i386/mp_machdep.c > >>>> > >>>> Modified: head/sys/amd64/amd64/machdep.c > >>>> ============================================================================== > >>>> --- head/sys/amd64/amd64/machdep.c ?? ??Mon Apr ??9 22:01:43 2012 ?? ?? ?? ??(r234073) > >>>> +++ head/sys/amd64/amd64/machdep.c ?? ??Mon Apr ??9 22:41:19 2012 ?? ?? ?? ??(r234074) > >>>> @@ -295,6 +295,11 @@ cpu_startup(dummy) > >>>> ?? ?? ?? vm_pager_bufferinit(); > >>>> > >>>> ?? ?? ?? cpu_setregs(); > >>>> + > >>>> + ?? ?? /* > >>>> + ?? ?? ??* Add BSP as an interrupt target. > >>>> + ?? ?? ??*/ > >>>> + ?? ?? intr_add_cpu(0); > >>>> ??} > >>> > >>> If I'm not mistaken, intr_add_cpu() is under #ifdef SMP, so it should be > >>> here as well. > >> > >> You are right, sorry, I did forgot to test without SMP. > >> I think we still need intr_add_cpu() on cpu_startup() because of the > >> case smp_disabled = 1. > >> I think the attached patch should make its dirty job, opinion? > > > > I currently fail to see why the latter approach would be necessary, > > i.e. IMO wrapping the intr_add_cpu() calls in cpu_startup() should > > be sufficient. In case the kernel is compiled without SMP support, > > interrupt balancing support isn't available in the first place and > > the BSP is always the only available target (see the UP version of > > intr_next_cpu() at the end of x86/x86/intr_machdep.c), so there's > > no need to add the BSP as a valid target. If an SMP kernel is run > > on a UP machine or with SMP disabled, interrupt balancing support > > is available but the intr_add_cpu() calls in cpu_startup() will add > > the BSP as (the only) target, so everything should be fine. Maybe > > you can elaborate on why you think an SMP kernel with SMP disabled > > needs special handling. > > > > Marius > > While functionally correct, I believe that wrapping intr_add_cpu() > in machdep.c in "SMP ifdefs" is inferior to calling it in all cases. > It invites questions like, "In the UP case, don't we have to ensure > that CPU0 is a valid interrupt target?" This is because casual > visitors to this file don't know that intr_add_cpu() only impacts > interrupt distribution. Of course, this is just an artifact of the > current implementation. #ifdefs should be as close to the implemenation > as possible. This simplifies the task of making future enhancments. > This is why I'd prefer to see these within the body of intr_add_cpu() > than where they are now. > > I also think the comment could be improved to be something like: > > /* > * The BSP/CPU0 is always an interrupt target even if > * our probe of MP hardware fails or MP mode is disabled. > */ > intr_add_cpu(0); This is why my original patch had this all self-contained inside the #ifdef SMP in sys/x86/x86/intr_machdep.c via a new SYSINIT(). -- John Baldwin From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 15:08:01 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A68731065689; Mon, 16 Apr 2012 15:08:01 +0000 (UTC) (envelope-from sperber@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 91F5D8FC19; Mon, 16 Apr 2012 15:08:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GF81SS038739; Mon, 16 Apr 2012 15:08:01 GMT (envelope-from sperber@svn.freebsd.org) Received: (from sperber@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GF81b7038736; Mon, 16 Apr 2012 15:08:01 GMT (envelope-from sperber@svn.freebsd.org) Message-Id: <201204161508.q3GF81b7038736@svn.freebsd.org> From: Armin Pirkovitsch Date: Mon, 16 Apr 2012 15:08: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: r234343 - head/share/misc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 15:08:01 -0000 Author: sperber (ports committer) Date: Mon Apr 16 15:08:01 2012 New Revision: 234343 URL: http://svn.freebsd.org/changeset/base/234343 Log: Add myself to committers-ports Approved by: beat (mentor) Modified: head/share/misc/committers-ports.dot Modified: head/share/misc/committers-ports.dot ============================================================================== --- head/share/misc/committers-ports.dot Mon Apr 16 13:49:03 2012 (r234342) +++ head/share/misc/committers-ports.dot Mon Apr 16 15:08:01 2012 (r234343) @@ -173,6 +173,7 @@ shaun [label="Shaun Amott\nshaun@FreeBSD simon [label="Simon L. Nielsen\nsimon@FreeBSD.org\n2005/01/08"] skreuzer [label="Steven Kreuzer\nskreuzer@FreeBSD.org\n2009/03/25"] sobomax[label="Maxim Sobolev\nsobomax@FreeBSD.org\n2000/05/17"] +sperber[label="Armin Pirkovitsch\nsperber@FreeBSD.org\n2012/04/15"] stas [label="Stanislav Sedov\nstas@FreeBSD.org\n2006/09/18"] stefan [label="Stefan Walter\nstefan@FreeBSD.org\n2006/05/07"] stephen [label="Stephen Montgomery-Smith\nstephen@FreeBSD.org\n2011/06/13"] @@ -224,6 +225,7 @@ bapt -> eadler bapt -> jlaffaye beat -> decke +beat -> sperber beat -> uqs beech -> glarkin @@ -243,6 +245,8 @@ clsung -> tabthorpe crees -> jgh crees -> madpilot +decke -> sperber + delphij -> nemoliu delphij -> rafan @@ -370,6 +374,7 @@ miwi -> nox miwi -> pawel miwi -> rm miwi -> sbz +miwi -> sperber miwi -> sylvio miwi -> tabthorpe miwi -> trasz From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 15:49:28 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 27B5E1065672 for ; Mon, 16 Apr 2012 15:49:28 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-we0-f182.google.com (mail-we0-f182.google.com [74.125.82.182]) by mx1.freebsd.org (Postfix) with ESMTP id 603838FC17 for ; Mon, 16 Apr 2012 15:49:27 +0000 (UTC) Received: by wern13 with SMTP id n13so4529956wer.13 for ; Mon, 16 Apr 2012 08:49:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=qgP71Zge9gd/wbZl6dGztnBp5+HVZYJOAzY4pCMGlik=; b=J3P5JhrTy3HsUtfk6kdspDPXREUbbv9StpB3zFx6aNkMGY6Jxgkpapm/Q0cHatEx88 Muj14XDzXtOxU8p+V+h2VwG447yaw2CL1IKalB7g7Fi6g5wskjsgsrYRj/bPhXB6cTBm h7IO0JdLR0ohO/k0RFah6gqj9Ogyu62dWQub8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :x-gm-message-state; bh=qgP71Zge9gd/wbZl6dGztnBp5+HVZYJOAzY4pCMGlik=; b=IMfiq+sjo7k2JSJBKDkcpzBccJYjQvQE0MhIxlE4vrhTAydYiggMyhcn/eMsqUduXM AJzDPb+h+M4RiP23LcmJVEdCKvTzj/gMVlzF9xRQgklHbs9vc1VEbT0L48jT+1IFELwD p3fTeO3l1lDJj41Iu2zZ/QCZ5z6HUwhe/KD3NJsZEVRN195PIhTJ7LUQ6bdEsMMuWJro nscnRadkWiDQF8lQ3gUUDW8M1T47LdnwDVUqy4dDRH1Lmd+0zk6MIJ1sP7xk+me4Lt0i ngc7sPnPCF5sz8yqMcvN2dtyu+VPQFSV6HK9bx2ANMaQ9GFid6GqwvhPnXjKYVzWgZ+p wGRQ== Received: by 10.180.92.228 with SMTP id cp4mr13448801wib.2.1334591359993; Mon, 16 Apr 2012 08:49:19 -0700 (PDT) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.223.63.4 with HTTP; Mon, 16 Apr 2012 08:48:49 -0700 (PDT) In-Reply-To: <20120416070248.GQ9391@FreeBSD.org> References: <201204152356.q3FNu4W4007224@svn.freebsd.org> <20120416070248.GQ9391@FreeBSD.org> From: Eitan Adler Date: Mon, 16 Apr 2012 11:48:49 -0400 X-Google-Sender-Auth: bH-wLNRjJtO9xD46sEYqwl37KeU Message-ID: To: Gleb Smirnoff Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQk3BmaOqvSXfNdNxzhfODLxiVfqCWI1i3s1YgCVMpS/CR2BPLobf0TlUK1AtQSgbZ1hc8NH Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234329 - head/lib/libc/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 15:49:28 -0000 2012/4/16 Gleb Smirnoff : > Is that PURIFY documented anywhere? I'm uncertain, but it isn't the only use in the source tree. -- Eitan Adler Source & Ports committer X11, Bugbusting teams From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 16:54:31 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 109641065675; Mon, 16 Apr 2012 16:54:31 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebius.int.ru (glebius.int.ru [81.19.64.117]) by mx1.freebsd.org (Postfix) with ESMTP id 7CD148FC0C; Mon, 16 Apr 2012 16:54:30 +0000 (UTC) Received: from cell.glebius.int.ru (localhost [127.0.0.1]) by cell.glebius.int.ru (8.14.5/8.14.5) with ESMTP id q3GGsMZC092773; Mon, 16 Apr 2012 20:54:22 +0400 (MSK) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebius.int.ru (8.14.5/8.14.5/Submit) id q3GGsMqL092772; Mon, 16 Apr 2012 20:54:22 +0400 (MSK) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebius.int.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Mon, 16 Apr 2012 20:54:22 +0400 From: Gleb Smirnoff To: Eitan Adler Message-ID: <20120416165422.GA92286@FreeBSD.org> References: <201204152356.q3FNu4W4007224@svn.freebsd.org> <20120416070248.GQ9391@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: 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: r234329 - head/lib/libc/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 16:54:31 -0000 On Mon, Apr 16, 2012 at 11:48:49AM -0400, Eitan Adler wrote: E> 2012/4/16 Gleb Smirnoff : E> > Is that PURIFY documented anywhere? E> E> I'm uncertain, but it isn't the only use in the source tree. Is there any build with it? (rhetoric question) I'm just afraid that committing fix under ifdef won't satisfy submitter of the patch. -- Totus tuus, Glebius. From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 17:30:20 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 506B51065673; Mon, 16 Apr 2012 17:30:20 +0000 (UTC) (envelope-from marck@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3B23D8FC18; Mon, 16 Apr 2012 17:30:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GHUKqj043214; Mon, 16 Apr 2012 17:30:20 GMT (envelope-from marck@svn.freebsd.org) Received: (from marck@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GHUKxf043212; Mon, 16 Apr 2012 17:30:20 GMT (envelope-from marck@svn.freebsd.org) Message-Id: <201204161730.q3GHUKxf043212@svn.freebsd.org> From: Dmitry Morozovsky Date: Mon, 16 Apr 2012 17:30: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: r234345 - head/sbin/fdisk X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 17:30:20 -0000 Author: marck (doc committer) Date: Mon Apr 16 17:30:19 2012 New Revision: 234345 URL: http://svn.freebsd.org/changeset/base/234345 Log: VMware environment is frequent nowadays. Add VMFS id. MFC after: 2 weeks Modified: head/sbin/fdisk/fdisk.c Modified: head/sbin/fdisk/fdisk.c ============================================================================== --- head/sbin/fdisk/fdisk.c Mon Apr 16 15:43:31 2012 (r234344) +++ head/sbin/fdisk/fdisk.c Mon Apr 16 17:30:19 2012 (r234345) @@ -218,6 +218,7 @@ static const char *const part_types[256] [0xF1] = "SpeedStor", [0xF2] = "DOS 3.3+ Secondary", [0xF4] = "SpeedStor large partition", + [0xFB] = "VMware VMFS", [0xFE] = "SpeedStor >1024 cyl. or LANstep", [0xFF] = "Xenix bad blocks table", }; From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 18:07:43 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AAEAC106566C; Mon, 16 Apr 2012 18:07:43 +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 7D1DE8FC12; Mon, 16 Apr 2012 18:07:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GI7hMo044410; Mon, 16 Apr 2012 18:07:43 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GI7hCc044407; Mon, 16 Apr 2012 18:07:43 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201204161807.q3GI7hCc044407@svn.freebsd.org> From: Jaakko Heinonen Date: Mon, 16 Apr 2012 18:07: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: r234346 - head/sys/fs/tmpfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 18:07:43 -0000 Author: jh Date: Mon Apr 16 18:07:42 2012 New Revision: 234346 URL: http://svn.freebsd.org/changeset/base/234346 Log: tmpfs: Allow update mounts only for certain options. Since r230208 update mounts were allowed if the list of mount options contained the "export" option. This is not correct as tmpfs doesn't really support updating all options. Reviewed by: kevlo, trociny Modified: head/sys/fs/tmpfs/tmpfs.h head/sys/fs/tmpfs/tmpfs_vfsops.c Modified: head/sys/fs/tmpfs/tmpfs.h ============================================================================== --- head/sys/fs/tmpfs/tmpfs.h Mon Apr 16 17:30:19 2012 (r234345) +++ head/sys/fs/tmpfs/tmpfs.h Mon Apr 16 18:07:42 2012 (r234346) @@ -387,6 +387,9 @@ struct tmpfs_mount { * tmpfs_pool.c. */ uma_zone_t tm_dirent_pool; uma_zone_t tm_node_pool; + + /* Read-only status. */ + int tm_ronly; }; #define TMPFS_LOCK(tm) mtx_lock(&(tm)->allnode_lock) #define TMPFS_UNLOCK(tm) mtx_unlock(&(tm)->allnode_lock) Modified: head/sys/fs/tmpfs/tmpfs_vfsops.c ============================================================================== --- head/sys/fs/tmpfs/tmpfs_vfsops.c Mon Apr 16 17:30:19 2012 (r234345) +++ head/sys/fs/tmpfs/tmpfs_vfsops.c Mon Apr 16 18:07:42 2012 (r234346) @@ -82,6 +82,10 @@ static const char *tmpfs_opts[] = { NULL }; +static const char *tmpfs_updateopts[] = { + "from", "export", NULL +}; + /* --------------------------------------------------------------------- */ static int @@ -150,12 +154,13 @@ tmpfs_mount(struct mount *mp) return (EINVAL); if (mp->mnt_flag & MNT_UPDATE) { - /* - * Only support update mounts for NFS export. - */ - if (vfs_flagopt(mp->mnt_optnew, "export", NULL, 0)) - return (0); - return (EOPNOTSUPP); + /* Only support update mounts for certain options. */ + if (vfs_filteropt(mp->mnt_optnew, tmpfs_updateopts) != 0) + return (EOPNOTSUPP); + if (vfs_flagopt(mp->mnt_optnew, "ro", NULL, 0) != + ((struct tmpfs_mount *)mp->mnt_data)->tm_ronly) + return (EOPNOTSUPP); + return (0); } vn_lock(mp->mnt_vnodecovered, LK_SHARED | LK_RETRY); @@ -228,6 +233,7 @@ tmpfs_mount(struct mount *mp) tmpfs_node_ctor, tmpfs_node_dtor, tmpfs_node_init, tmpfs_node_fini, UMA_ALIGN_PTR, 0); + tmp->tm_ronly = (mp->mnt_flag & MNT_RDONLY) != 0; /* Allocate the root node. */ error = tmpfs_alloc_node(tmp, VDIR, root_uid, From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 18:10:35 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B484E106566B; Mon, 16 Apr 2012 18:10:35 +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 86DC78FC1A; Mon, 16 Apr 2012 18:10:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GIAZ7m044531; Mon, 16 Apr 2012 18:10:35 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GIAZJe044529; Mon, 16 Apr 2012 18:10:35 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201204161810.q3GIAZJe044529@svn.freebsd.org> From: Jaakko Heinonen Date: Mon, 16 Apr 2012 18:10: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: r234347 - head/sys/fs/tmpfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 18:10:35 -0000 Author: jh Date: Mon Apr 16 18:10:34 2012 New Revision: 234347 URL: http://svn.freebsd.org/changeset/base/234347 Log: Sync tmpfs_chflags() with the recent changes to UFS: - Add a check for unsupported file flags. - Return EPERM when an user without PRIV_VFS_SYSFLAGS privilege attempts to toggle SF_SETTABLE flags. Modified: head/sys/fs/tmpfs/tmpfs_subr.c Modified: head/sys/fs/tmpfs/tmpfs_subr.c ============================================================================== --- head/sys/fs/tmpfs/tmpfs_subr.c Mon Apr 16 18:07:42 2012 (r234346) +++ head/sys/fs/tmpfs/tmpfs_subr.c Mon Apr 16 18:10:34 2012 (r234347) @@ -1078,6 +1078,11 @@ tmpfs_chflags(struct vnode *vp, int flag node = VP_TO_TMPFS_NODE(vp); + if ((flags & ~(UF_NODUMP | UF_IMMUTABLE | UF_APPEND | UF_OPAQUE | + UF_NOUNLINK | SF_ARCHIVED | SF_IMMUTABLE | SF_APPEND | + SF_NOUNLINK | SF_SNAPSHOT)) != 0) + return (EOPNOTSUPP); + /* Disallow this operation if the file system is mounted read-only. */ if (vp->v_mount->mnt_flag & MNT_RDONLY) return EROFS; @@ -1093,27 +1098,22 @@ tmpfs_chflags(struct vnode *vp, int flag * flags, or modify flags if any system flags are set. */ if (!priv_check_cred(cred, PRIV_VFS_SYSFLAGS, 0)) { - if (node->tn_flags - & (SF_NOUNLINK | SF_IMMUTABLE | SF_APPEND)) { + if (node->tn_flags & + (SF_NOUNLINK | SF_IMMUTABLE | SF_APPEND)) { error = securelevel_gt(cred, 0); if (error) return (error); } - /* Snapshot flag cannot be set or cleared */ - if (((flags & SF_SNAPSHOT) != 0 && - (node->tn_flags & SF_SNAPSHOT) == 0) || - ((flags & SF_SNAPSHOT) == 0 && - (node->tn_flags & SF_SNAPSHOT) != 0)) + /* The snapshot flag cannot be toggled. */ + if ((flags ^ node->tn_flags) & SF_SNAPSHOT) return (EPERM); - node->tn_flags = flags; } else { - if (node->tn_flags - & (SF_NOUNLINK | SF_IMMUTABLE | SF_APPEND) || - (flags & UF_SETTABLE) != flags) + if (node->tn_flags & + (SF_NOUNLINK | SF_IMMUTABLE | SF_APPEND) || + ((flags ^ node->tn_flags) & SF_SETTABLE)) return (EPERM); - node->tn_flags &= SF_SETTABLE; - node->tn_flags |= (flags & UF_SETTABLE); } + node->tn_flags = flags; node->tn_status |= TMPFS_NODE_CHANGED; MPASS(VOP_ISLOCKED(vp)); From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 18:29:07 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AFC9E106564A; Mon, 16 Apr 2012 18:29:07 +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 9A2BB8FC0C; Mon, 16 Apr 2012 18:29:07 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GIT7Qv045185; Mon, 16 Apr 2012 18:29:07 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GIT7Qd045183; Mon, 16 Apr 2012 18:29:07 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201204161829.q3GIT7Qd045183@svn.freebsd.org> From: Marius Strobl Date: Mon, 16 Apr 2012 18: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: r234348 - head/sys/sparc64/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 18:29:07 -0000 Author: marius Date: Mon Apr 16 18:29:07 2012 New Revision: 234348 URL: http://svn.freebsd.org/changeset/base/234348 Log: Turn on PREEMPTION by default. After fixing several bugs over time, the last show-stopper keeping PREEMPTION from being usable on sparc64 should have been dealt with in r230662. At least on 2-way systems, PREEMPTION causes a little bit of a degradation in worldstone performance. However, FreeBSD seems to have started building up regressions in !PREEMPTION cases so sparc64 better should not be an oddball in this regard. MFC after: 1 week Modified: head/sys/sparc64/conf/GENERIC Modified: head/sys/sparc64/conf/GENERIC ============================================================================== --- head/sys/sparc64/conf/GENERIC Mon Apr 16 18:10:34 2012 (r234347) +++ head/sys/sparc64/conf/GENERIC Mon Apr 16 18:29:07 2012 (r234348) @@ -27,7 +27,7 @@ makeoptions DEBUG=-g # Build kernel wit # At this time all platforms are supported, as-is. options SCHED_ULE # ULE scheduler -#options PREEMPTION # Enable kernel thread preemption +options PREEMPTION # Enable kernel thread preemption options INET # InterNETworking options INET6 # IPv6 communications protocols options SCTP # Stream Control Transmission Protocol From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 18:29:14 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DBD1C106576A; Mon, 16 Apr 2012 18:29:13 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 633608FC14; Mon, 16 Apr 2012 18:29:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GITDng045225; Mon, 16 Apr 2012 18:29:13 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GITDmV045223; Mon, 16 Apr 2012 18:29:13 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201204161829.q3GITDmV045223@svn.freebsd.org> From: Peter Grehan Date: Mon, 16 Apr 2012 18:29: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: r234349 - head/sys/dev/virtio/block X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 18:29:15 -0000 Author: grehan Date: Mon Apr 16 18:29:12 2012 New Revision: 234349 URL: http://svn.freebsd.org/changeset/base/234349 Log: Sync with Bryan Venteicher's virtio git repo: d04e609bdd1973cc7d2e8b38b7dcfae057b0962d virtio_blk: Use correct temporary variable in vtblk_poll_request Obtained from: Bryan Venteicher bryanv at daemoninthecloset dot org Modified: head/sys/dev/virtio/block/virtio_blk.c Modified: head/sys/dev/virtio/block/virtio_blk.c ============================================================================== --- head/sys/dev/virtio/block/virtio_blk.c Mon Apr 16 18:29:07 2012 (r234348) +++ head/sys/dev/virtio/block/virtio_blk.c Mon Apr 16 18:29:12 2012 (r234349) @@ -997,6 +997,7 @@ vtblk_poll_request(struct vtblk_softc *s { device_t dev; struct virtqueue *vq; + struct vtblk_request *r; int error; dev = sc->vtblk_dev; @@ -1011,7 +1012,8 @@ vtblk_poll_request(struct vtblk_softc *s virtqueue_notify(vq); - req = virtqueue_poll(vq, NULL); + r = virtqueue_poll(vq, NULL); + KASSERT(r == req, ("unexpected request response")); error = vtblk_request_error(req); if (error && bootverbose) { From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 19:31:44 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C9DC91065678; Mon, 16 Apr 2012 19:31:44 +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 9B7798FC0A; Mon, 16 Apr 2012 19:31:44 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GJVis3047157; Mon, 16 Apr 2012 19:31:44 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GJViWg047155; Mon, 16 Apr 2012 19:31:44 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204161931.q3GJViWg047155@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 19:31: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: r234350 - head/sys/i386/i386 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 19:31:44 -0000 Author: jkim Date: Mon Apr 16 19:31:44 2012 New Revision: 234350 URL: http://svn.freebsd.org/changeset/base/234350 Log: - When interrupt is not requested for VM86 call, make a fake exit point and push the address onto stack as we do for INTn emulation. This avoids stack underflow when we encounter RETF instruction in VM86 mode. Lack of this exit point actually caused page fault in VM86 mode with VESA module when we resume from suspend state[1]. - Remove unnecessary CLI and STI instructions from BIOS interrupt emulation. INTn and IRET must be able to emulate the flag correctly. Reported by: gavin [1] Tested by: gavin (early revision) MFC after: 3 days Modified: head/sys/i386/i386/vm86.c Modified: head/sys/i386/i386/vm86.c ============================================================================== --- head/sys/i386/i386/vm86.c Mon Apr 16 18:29:12 2012 (r234349) +++ head/sys/i386/i386/vm86.c Mon Apr 16 19:31:44 2012 (r234350) @@ -512,22 +512,27 @@ full: void vm86_prepcall(struct vm86frame *vmf) { - uintptr_t addr[] = { 0xA00, 0x1000 }; /* code, stack */ - u_char intcall[] = { - CLI, INTn, 0x00, STI, HLT - }; struct vm86_kernel *vm86; + uint32_t *stack; + uint8_t *code; + code = (void *)0xa00; + stack = (void *)(0x1000 - 2); /* keep aligned */ if ((vmf->vmf_trapno & PAGE_MASK) <= 0xff) { /* interrupt call requested */ - intcall[2] = (u_char)(vmf->vmf_trapno & 0xff); - memcpy((void *)addr[0], (void *)intcall, sizeof(intcall)); - vmf->vmf_ip = addr[0]; + code[0] = INTn; + code[1] = vmf->vmf_trapno & 0xff; + code[2] = HLT; + vmf->vmf_ip = (uintptr_t)code; vmf->vmf_cs = 0; + } else { + code[0] = HLT; + stack--; + stack[0] = MAKE_VEC(0, (uintptr_t)code); } - vmf->vmf_sp = addr[1] - 2; /* keep aligned */ - vmf->kernel_fs = vmf->kernel_es = vmf->kernel_ds = 0; + vmf->vmf_sp = (uintptr_t)stack; vmf->vmf_ss = 0; + vmf->kernel_fs = vmf->kernel_es = vmf->kernel_ds = 0; vmf->vmf_eflags = PSL_VIF | PSL_VM | PSL_USER; vm86 = &PCPU_GET(curpcb)->pcb_ext->ext_vm86; From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 19:42:00 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A7519106566B for ; Mon, 16 Apr 2012 19:42:00 +0000 (UTC) (envelope-from juli@clockworksquid.com) Received: from mail-wi0-f178.google.com (mail-wi0-f178.google.com [209.85.212.178]) by mx1.freebsd.org (Postfix) with ESMTP id 2E6E18FC15 for ; Mon, 16 Apr 2012 19:42:00 +0000 (UTC) Received: by wibhq7 with SMTP id hq7so4612076wib.13 for ; Mon, 16 Apr 2012 12:41:59 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :content-transfer-encoding:x-gm-message-state; bh=rNmGkBvCQJUVk9lqxQTO7VxH8nHjrb82rKjZaTy/4fw=; b=YbHS3i/gNnAXL9DyzhgQ0AmJJCsGp/CwTgrAB2J4/wTmgsiKMUSt9lpLKcmdztJi2I SoejMggSG+JwoswuNYfQi4CcF0EVx5rT37OvpBE6SGUpt1q3HxJpw/ttuPMeaWtmc/rE Ni56hzLUvTgU1NDwMnV50dD7ZVhAZ3Grrjq5Oovpqml1ifavHt2QxHhL/6Si5IfizDPd PpsHTldCltZEQnv/vePMuPxjhXhcjxbFPtC710U0JmTtMhw5BKQBCm7W+irATNSHI/Kf AVa51czB+ojJVDtdkofp4I9iWpww9SzSF14MPz2eJUzorTxeZ3THYFOSSisVel0aqEmD e+dg== Received: by 10.180.94.161 with SMTP id dd1mr21591909wib.16.1334605318948; Mon, 16 Apr 2012 12:41:58 -0700 (PDT) MIME-Version: 1.0 Sender: juli@clockworksquid.com Received: by 10.216.212.157 with HTTP; Mon, 16 Apr 2012 12:41:38 -0700 (PDT) In-Reply-To: <201204160938.q3G9cLmw026093@svn.freebsd.org> References: <201204160938.q3G9cLmw026093@svn.freebsd.org> From: Juli Mallett Date: Mon, 16 Apr 2012 12:41:38 -0700 X-Google-Sender-Auth: e-epkAv2KQ4NhIlF7igzh7EQC6I Message-ID: To: Andrew Turner Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Gm-Message-State: ALoCoQmrFyieX2JGR4EcsIt2PBooB+6C4EyP8+MUSbjz4bYZe9Gb29A7cMTxwELve2OMAlDs1x79 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234337 - in head: lib/libc/arm/gen sys/arm/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 19:42:00 -0000 On Mon, Apr 16, 2012 at 02:38, Andrew Turner wrote: > Log: > =C2=A0Replace the C implementation of __aeabi_read_tp with an assembly ve= rsion. > =C2=A0This ensures we follow the ABI by preserving registers r1-r3. > +ENTRY(__aeabi_read_tp) > + =C2=A0 =C2=A0 =C2=A0 ldr =C2=A0 =C2=A0 r0, .Larm_tp_address > + =C2=A0 =C2=A0 =C2=A0 ldr =C2=A0 =C2=A0 r0, [r0] > + =C2=A0 =C2=A0 =C2=A0 RET > + > +.Larm_tp_address: > + =C2=A0 =C2=A0 =C2=A0 .word ARM_TP_ADDRESS > + Why is this indirection required? Can't you just use ARM_TP_ADDRESS instead of loading it from data? Also, is our convention for ARM to use END() with ENTRY() or not? From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 20:01:35 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6C6DD106564A; Mon, 16 Apr 2012 20:01:35 +0000 (UTC) (envelope-from bzeeb-lists@lists.zabbadoz.net) Received: from mx1.sbone.de (mx1.sbone.de [IPv6:2a01:4f8:130:3ffc::401:25]) by mx1.freebsd.org (Postfix) with ESMTP id E83C48FC18; Mon, 16 Apr 2012 20:01:34 +0000 (UTC) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:31::2013:587]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.sbone.de (Postfix) with ESMTPS id EADFD25D3870; Mon, 16 Apr 2012 20:01:33 +0000 (UTC) Received: from content-filter.sbone.de (content-filter.sbone.de [IPv6:fde9:577b:c1a9:31::2013:2742]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id 0365EBE4FBB; Mon, 16 Apr 2012 20:01:33 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:31::2013:587]) by content-filter.sbone.de (content-filter.sbone.de [fde9:577b:c1a9:31::2013:2742]) (amavisd-new, port 10024) with ESMTP id aajPKvQqPHbw; Mon, 16 Apr 2012 20:01:32 +0000 (UTC) Received: from orange-en1.sbone.de (orange-en1.sbone.de [IPv6:fde9:577b:c1a9:31:cabc:c8ff:fecf:e8e3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id EC577BE4FBA; Mon, 16 Apr 2012 20:01:31 +0000 (UTC) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: "Bjoern A. Zeeb" In-Reply-To: Date: Mon, 16 Apr 2012 20:01:30 +0000 Content-Transfer-Encoding: 7bit Message-Id: References: <201204160938.q3G9cLmw026093@svn.freebsd.org> To: Juli Mallett X-Mailer: Apple Mail (2.1084) Cc: Andrew Turner , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234337 - in head: lib/libc/arm/gen sys/arm/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 20:01:35 -0000 On 16. Apr 2012, at 19:41 , Juli Mallett wrote: > On Mon, Apr 16, 2012 at 02:38, Andrew Turner wrote: >> Log: >> Replace the C implementation of __aeabi_read_tp with an assembly version. >> This ensures we follow the ABI by preserving registers r1-r3. > >> +ENTRY(__aeabi_read_tp) >> + ldr r0, .Larm_tp_address >> + ldr r0, [r0] >> + RET >> + >> +.Larm_tp_address: >> + .word ARM_TP_ADDRESS >> + > > Why is this indirection required? Can't you just use ARM_TP_ADDRESS > instead of loading it from data? Also, is our convention for ARM to > use END() with ENTRY() or not? Don't you generally want END() . ? -- Bjoern A. Zeeb You have to have visions! It does not matter how good you are. It matters what good you do! From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 20:03:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BC301106566C for ; Mon, 16 Apr 2012 20:03:18 +0000 (UTC) (envelope-from freebsd@damnhippie.dyndns.org) Received: from qmta08.emeryville.ca.mail.comcast.net (qmta08.emeryville.ca.mail.comcast.net [76.96.30.80]) by mx1.freebsd.org (Postfix) with ESMTP id 9B0F38FC16 for ; Mon, 16 Apr 2012 20:03:18 +0000 (UTC) Received: from omta19.emeryville.ca.mail.comcast.net ([76.96.30.76]) by qmta08.emeryville.ca.mail.comcast.net with comcast id yjfc1i0061eYJf8A8k3C12; Mon, 16 Apr 2012 20:03:12 +0000 Received: from damnhippie.dyndns.org ([24.8.232.202]) by omta19.emeryville.ca.mail.comcast.net with comcast id yk3A1i01l4NgCEG01k3B8u; Mon, 16 Apr 2012 20:03:12 +0000 Received: from [172.22.42.240] (revolution.hippie.lan [172.22.42.240]) by damnhippie.dyndns.org (8.14.3/8.14.3) with ESMTP id q3GK39fw064637; Mon, 16 Apr 2012 14:03:09 -0600 (MDT) (envelope-from freebsd@damnhippie.dyndns.org) From: Ian Lepore To: Juli Mallett In-Reply-To: References: <201204160938.q3G9cLmw026093@svn.freebsd.org> Content-Type: text/plain; charset="us-ascii" Date: Mon, 16 Apr 2012 14:03:09 -0600 Message-ID: <1334606589.1082.201.camel@revolution.hippie.lan> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: Andrew Turner , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234337 - in head: lib/libc/arm/gen sys/arm/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 20:03:18 -0000 On Mon, 2012-04-16 at 12:41 -0700, Juli Mallett wrote: > On Mon, Apr 16, 2012 at 02:38, Andrew Turner wrote: > > Log: > > Replace the C implementation of __aeabi_read_tp with an assembly version. > > This ensures we follow the ABI by preserving registers r1-r3. > > > +ENTRY(__aeabi_read_tp) > > + ldr r0, .Larm_tp_address > > + ldr r0, [r0] > > + RET > > + > > +.Larm_tp_address: > > + .word ARM_TP_ADDRESS > > + > > Why is this indirection required? Can't you just use ARM_TP_ADDRESS > instead of loading it from data? Also, is our convention for ARM to > use END() with ENTRY() or not? It used to be possible to directly load ARM_TP_ADDRESS into a register when it had a cleverly-crafted value that made use of ARM's ability to encode a constant value into an instruction if it can be expressed as an 8-bit value shifted by anything up to 31 bits. (iirc, it used to be 0xe0000000). At some point that address became a problem for someone and it got changed to a value which can no longer be encoded within the instruction. The alternative is to load it with a single instruction by using a pc-relative address, or use a series of load-and-shift instructions to form the new more complex constant. Ick. -- Ian From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 20:11:26 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 53E81106564A; Mon, 16 Apr 2012 20:11:26 +0000 (UTC) (envelope-from andrew@fubar.geek.nz) Received: from mailfilter25.ihug.co.nz (mailfilter25.ihug.co.nz [203.109.136.25]) by mx1.freebsd.org (Postfix) with ESMTP id 8AEAA8FC0C; Mon, 16 Apr 2012 20:11:25 +0000 (UTC) X-Cloudmark-SP-Filtered: true X-Cloudmark-SP-Result: v=1.0 c=1 a=jYCWiHupMkwA:10 a=IkcTkHD0fZMA:10 a=6I5d2MoRAAAA:8 a=7wJXP1UIrWQDR7MTTHwA:9 a=QEXdDO2ut3YA:10 a=SV7veod9ZcQA:10 a=etJkMkqoFThuCZDw:21 a=fmysP91ott2mn578:21 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av8EAA98jE/LdqpC/2dsb2JhbABEhWatLIEIggkBAQQBIzMjBQsIAw4KAgImAgI5HgYTiAkEpmySSYEvigOEf4EYBJVsAYVfilaCfIE/ X-IronPort-AV: E=Sophos;i="4.75,431,1330858800"; d="scan'208";a="429881908" Received: from 203-118-170-66.adsl.ihug.co.nz (HELO localhost) ([203.118.170.66]) by smtp.mailfilter5.ihug.co.nz with SMTP; 17 Apr 2012 08:10:12 +1200 Date: Tue, 17 Apr 2012 08:09:54 +1200 From: Andrew Turner To: Juli Mallett Message-ID: <20120417080954.42df316a@fubar.geek.nz> In-Reply-To: References: <201204160938.q3G9cLmw026093@svn.freebsd.org> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; i386-portbld-freebsd8.0) X-Pirate: Arrrr Mime-Version: 1.0 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: r234337 - in head: lib/libc/arm/gen sys/arm/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 20:11:26 -0000 On Mon, 16 Apr 2012 12:41:38 -0700 Juli Mallett wrote: > On Mon, Apr 16, 2012 at 02:38, Andrew Turner > wrote: > > Log: > > =C2=A0Replace the C implementation of __aeabi_read_tp with an assembly > > version. This ensures we follow the ABI by preserving registers > > r1-r3. >=20 > > +ENTRY(__aeabi_read_tp) > > + =C2=A0 =C2=A0 =C2=A0 ldr =C2=A0 =C2=A0 r0, .Larm_tp_address > > + =C2=A0 =C2=A0 =C2=A0 ldr =C2=A0 =C2=A0 r0, [r0] > > + =C2=A0 =C2=A0 =C2=A0 RET > > + > > +.Larm_tp_address: > > + =C2=A0 =C2=A0 =C2=A0 .word ARM_TP_ADDRESS > > + >=20 > Why is this indirection required? Can't you just use ARM_TP_ADDRESS > instead of loading it from data? ARM will let us load a limited number of values straight into registers with a move instruction. Unfortunately the value of ARM_TP_ADDRESS is not one of them. > Also, is our convention for ARM to > use END() with ENTRY() or not? There is no END() macro for ARM. Andrew From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 20:41:26 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C1C7F1065672; Mon, 16 Apr 2012 20:41:26 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AC5338FC0C; Mon, 16 Apr 2012 20:41:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GKfQrY049722; Mon, 16 Apr 2012 20:41:26 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GKfQHZ049719; Mon, 16 Apr 2012 20:41:26 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201204162041.q3GKfQHZ049719@svn.freebsd.org> From: Baptiste Daroussin Date: Mon, 16 Apr 2012 20:41: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: r234351 - head/usr.sbin/pkg X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 20:41:26 -0000 Author: bapt Date: Mon Apr 16 20:41:25 2012 New Revision: 234351 URL: http://svn.freebsd.org/changeset/base/234351 Log: - Use _PATH_TMP instead of hardcoded /tmp - more style(9) fixes - some refactoring - better error detection - Add the DPADD to Makefile Submitted by: Garrett Cooper Approved by: des (mentor) Modified: head/usr.sbin/pkg/Makefile head/usr.sbin/pkg/pkg.c Modified: head/usr.sbin/pkg/Makefile ============================================================================== --- head/usr.sbin/pkg/Makefile Mon Apr 16 19:31:44 2012 (r234350) +++ head/usr.sbin/pkg/Makefile Mon Apr 16 20:41:25 2012 (r234351) @@ -4,6 +4,7 @@ PROG= pkg SRC= pkg.c NO_MAN= yes +DPADD= ${LIBARCHIVE} ${LIBELF} ${LIBFETCH} LDADD= -larchive -lelf -lfetch .include Modified: head/usr.sbin/pkg/pkg.c ============================================================================== --- head/usr.sbin/pkg/pkg.c Mon Apr 16 19:31:44 2012 (r234350) +++ head/usr.sbin/pkg/pkg.c Mon Apr 16 20:41:25 2012 (r234351) @@ -40,6 +40,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include @@ -50,7 +51,6 @@ __FBSDID("$FreeBSD$"); #define _LOCALBASE "/usr/local" #define _PKGS_URL "http://pkgbeta.FreeBSD.org" -#define _DEFAULT_TMP "/tmp" static const char * elf_corres_to_string(struct _elf_corres *m, int e) @@ -68,18 +68,18 @@ static int pkg_get_myabi(char *dest, size_t sz) { Elf *elf; - GElf_Ehdr elfhdr; - GElf_Shdr shdr; Elf_Data *data; Elf_Note note; Elf_Scn *scn; char *src, *osname; const char *abi; + GElf_Ehdr elfhdr; + GElf_Shdr shdr; int fd, i, ret; uint32_t version; version = 0; - ret = 0; + ret = -1; scn = NULL; abi = NULL; @@ -119,7 +119,7 @@ pkg_get_myabi(char *dest, size_t sz) if (scn == NULL) { ret = -1; - warn("fail to get the note section"); + warn("failed to get the note section"); goto cleanup; } @@ -148,43 +148,45 @@ pkg_get_myabi(char *dest, size_t sz) elf_corres_to_string(wordsize_corres, (int)elfhdr.e_ident[EI_CLASS])); + ret = 0; + switch (elfhdr.e_machine) { - case EM_ARM: - snprintf(dest + strlen(dest), sz - strlen(dest), - ":%s:%s:%s", elf_corres_to_string(endian_corres, - (int)elfhdr.e_ident[EI_DATA]), - (elfhdr.e_flags & EF_ARM_NEW_ABI) > 0 ? - "eabi" : "oabi", - (elfhdr.e_flags & EF_ARM_VFP_FLOAT) > 0 ? - "softfp" : "vfp"); + case EM_ARM: + snprintf(dest + strlen(dest), sz - strlen(dest), + ":%s:%s:%s", elf_corres_to_string(endian_corres, + (int)elfhdr.e_ident[EI_DATA]), + (elfhdr.e_flags & EF_ARM_NEW_ABI) > 0 ? + "eabi" : "oabi", + (elfhdr.e_flags & EF_ARM_VFP_FLOAT) > 0 ? + "softfp" : "vfp"); + break; + case EM_MIPS: + /* + * this is taken from binutils sources: + * include/elf/mips.h + * mapping is figured out from binutils: + * gas/config/tc-mips.c + */ + switch (elfhdr.e_flags & EF_MIPS_ABI) { + case E_MIPS_ABI_O32: + abi = "o32"; + break; + case E_MIPS_ABI_N32: + abi = "n32"; break; - case EM_MIPS: - /* - * this is taken from binutils sources: - * include/elf/mips.h - * mapping is figured out from binutils: - * gas/config/tc-mips.c - */ - switch (elfhdr.e_flags & EF_MIPS_ABI) { - case E_MIPS_ABI_O32: - abi = "o32"; - break; - case E_MIPS_ABI_N32: - abi = "n32"; - break; - default: - if (elfhdr.e_ident[EI_DATA] == - ELFCLASS32) - abi = "o32"; - else if (elfhdr.e_ident[EI_DATA] == - ELFCLASS64) - abi = "n64"; - break; - } - snprintf(dest + strlen(dest), sz - strlen(dest), - ":%s:%s", elf_corres_to_string(endian_corres, - (int)elfhdr.e_ident[EI_DATA]), abi); + default: + if (elfhdr.e_ident[EI_DATA] == + ELFCLASS32) + abi = "o32"; + else if (elfhdr.e_ident[EI_DATA] == + ELFCLASS64) + abi = "n64"; break; + } + snprintf(dest + strlen(dest), sz - strlen(dest), + ":%s:%s", elf_corres_to_string(endian_corres, + (int)elfhdr.e_ident[EI_DATA]), abi); + break; } cleanup: @@ -203,17 +205,22 @@ extract_pkg_static(int fd, char *p, int char *end; int ret, r; - ret = 0; + ret = -1; a = archive_read_new(); + if (a == NULL) { + warn("archive_read_new"); + return (ret); + } archive_read_support_compression_all(a); archive_read_support_format_tar(a); - lseek(fd, 0, 0); + if (lseek(fd, 0, 0) == -1) { + warn("lseek"); + goto cleanup; + } if (archive_read_open_fd(a, fd, 4096) != ARCHIVE_OK) { - warnx("archive_read_open_fd: %s", - archive_error_string(a)); - ret = -1; + warnx("archive_read_open_fd: %s", archive_error_string(a)); goto cleanup; } @@ -228,15 +235,15 @@ extract_pkg_static(int fd, char *p, int ARCHIVE_EXTRACT_OWNER | ARCHIVE_EXTRACT_PERM | ARCHIVE_EXTRACT_TIME | ARCHIVE_EXTRACT_ACL | ARCHIVE_EXTRACT_FFLAGS | ARCHIVE_EXTRACT_XATTR); - snprintf(p, sz, archive_entry_pathname(ae)); + strlcpy(p, archive_entry_pathname(ae), sz); break; } } - if (r != ARCHIVE_OK) { + if (r == ARCHIVE_OK) + ret = 0; + else warnx("fail to extract pkg-static"); - ret = -1; - } cleanup: archive_read_finish(a); @@ -251,82 +258,78 @@ install_pkg_static(char *path, char *pkg pid_t pid; switch ((pid = fork())) { - case -1: - return (-1); - case 0: - execl(path, "pkg-static", "add", pkgpath, - (char *)NULL); - _exit(1); - default: - break; + case -1: + return (-1); + case 0: + execl(path, "pkg-static", "add", pkgpath, (char *)NULL); + _exit(1); + default: + break; } - while (waitpid(pid, &pstat, 0) == -1) { + while (waitpid(pid, &pstat, 0) == -1) if (errno != EINTR) return (-1); - } - return (WEXITSTATUS(pstat)); + if (WEXITSTATUS(pstat)) + return (WEXITSTATUS(pstat)); + else if (WIFSIGNALED(pstat)) + return (128 & (WTERMSIG(pstat))); + return (pstat); } static int bootstrap_pkg(void) { - struct url_stat st; FILE *remote; - time_t begin_dl; - time_t now; - time_t last = 0; char url[MAXPATHLEN]; char abi[BUFSIZ]; char tmppkg[MAXPATHLEN]; char buf[10240]; char pkgstatic[MAXPATHLEN]; int fd, retry, ret; + struct url_stat st; off_t done, r; + time_t begin_dl; + time_t now; + time_t last; done = 0; - ret = 0; - retry = 3; + last = 0; + ret = -1; remote = NULL; - printf("Bootstraping pkg please wait\n"); + printf("Bootstrapping pkg please wait\n"); if (pkg_get_myabi(abi, MAXPATHLEN) != 0) { - warnx("fail to determine my abi"); + warnx("failed to determine the system ABI"); return (-1); } - if (getenv("PACKAGESITE") != NULL) { - snprintf(url, MAXPATHLEN, "%s/pkg.txz", - getenv("PACKAGESITE")); - } else { + if (getenv("PACKAGESITE") != NULL) + snprintf(url, MAXPATHLEN, "%s/pkg.txz", getenv("PACKAGESITE")); + else snprintf(url, MAXPATHLEN, "%s/%s/latest/Latest/pkg.txz", getenv("PACKAGEROOT") ? getenv("PACKAGEROOT") : _PKGS_URL, getenv("ABI") ? getenv("ABI") : abi); - } snprintf(tmppkg, MAXPATHLEN, "%s/pkg.txz.XXXXXX", - getenv("TMPDIR") ? getenv("TMPDIR") : "/tmp"); + getenv("TMPDIR") ? getenv("TMPDIR") : _PATH_TMP); if ((fd = mkstemp(tmppkg)) == -1) { warn("mkstemp()"); return (-1); } - while (remote == NULL) { + retry = 3; + do { remote = fetchXGetURL(url, &st, ""); - if (remote == NULL) { - --retry; - if (retry == 0) { - warnx("Error fetching %s: %s", url, - fetchLastErrString); - ret = 1; - goto cleanup; - } + if (remote == NULL) sleep(1); - } - } + } while (remote == NULL && retry-- > 0); + + if (remote == NULL) + goto fetchfail; begin_dl = time(NULL); while (done < st.size) { @@ -335,32 +338,31 @@ bootstrap_pkg(void) if (write(fd, buf, r) != r) { warn("write()"); - ret = -1; goto cleanup; } done += r; now = time(NULL); - if (now > last || done == st.size) { + if (now > last || done == st.size) last = now; - } } - if (ferror(remote)) { - warnx("Error fetching %s: %s", url, - fetchLastErrString); - ret = 1; - goto cleanup; - } + if (ferror(remote)) + goto fetchfail; if ((ret = extract_pkg_static(fd, pkgstatic, MAXPATHLEN)) == 0) ret = install_pkg_static(pkgstatic, tmppkg); + goto cleanup; + +fetchfail: + warnx("Error fetching %s: %s", url, fetchLastErrString); + cleanup: close(fd); unlink(tmppkg); - return (0); + return (ret); } int @@ -372,9 +374,11 @@ main(__unused int argc, char *argv[]) getenv("LOCALBASE") ? getenv("LOCALBASE") : _LOCALBASE); if (access(pkgpath, X_OK) == -1) - bootstrap_pkg(); + if (bootstrap_pkg() != 0) + exit(EXIT_FAILURE); execv(pkgpath, argv); + /* NOT REACHED */ return (EXIT_FAILURE); } From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 21:22:03 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7EFE91065672; Mon, 16 Apr 2012 21:22: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 64A9B8FC12; Mon, 16 Apr 2012 21:22:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GLM3SK051056; Mon, 16 Apr 2012 21:22:03 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GLM23E051048; Mon, 16 Apr 2012 21:22:02 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204162122.q3GLM23E051048@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 21:22:02 +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: r234352 - in head/sys: amd64/linux32 compat/linux i386/linux kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 21:22:03 -0000 Author: jkim Date: Mon Apr 16 21:22:02 2012 New Revision: 234352 URL: http://svn.freebsd.org/changeset/base/234352 Log: - Implement pipe2 syscall for Linuxulator. This syscall appeared in 2.6.27 but GNU libc used it without checking its kernel version, e. g., Fedora 10. - Move pipe(2) implementation for Linuxulator from MD files to MI file, sys/compat/linux/linux_file.c. There is no MD code for this syscall at all. - Correct an argument type for pipe() from l_ulong * to l_int *. Probably this was the source of MI/MD confusion. Reviewed by: emulation Modified: head/sys/amd64/linux32/linux32_dummy.c head/sys/amd64/linux32/linux32_machdep.c head/sys/amd64/linux32/syscalls.master head/sys/compat/linux/linux_file.c head/sys/i386/linux/linux_dummy.c head/sys/i386/linux/linux_machdep.c head/sys/i386/linux/syscalls.master head/sys/kern/sys_pipe.c Modified: head/sys/amd64/linux32/linux32_dummy.c ============================================================================== --- head/sys/amd64/linux32/linux32_dummy.c Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/amd64/linux32/linux32_dummy.c Mon Apr 16 21:22:02 2012 (r234352) @@ -122,7 +122,6 @@ DUMMY(signalfd4); DUMMY(eventfd2); DUMMY(epoll_create1); DUMMY(dup3); -DUMMY(pipe2); DUMMY(inotify_init1); /* linux 2.6.30: */ DUMMY(preadv); Modified: head/sys/amd64/linux32/linux32_machdep.c ============================================================================== --- head/sys/amd64/linux32/linux32_machdep.c Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/amd64/linux32/linux32_machdep.c Mon Apr 16 21:22:02 2012 (r234352) @@ -698,25 +698,6 @@ linux_iopl(struct thread *td, struct lin } int -linux_pipe(struct thread *td, struct linux_pipe_args *args) -{ - int error; - int fildes[2]; - -#ifdef DEBUG - if (ldebug(pipe)) - printf(ARGS(pipe, "*")); -#endif - - error = kern_pipe(td, fildes); - if (error) - return (error); - - /* XXX: Close descriptors on error. */ - return (copyout(fildes, args->pipefds, sizeof fildes)); -} - -int linux_sigaction(struct thread *td, struct linux_sigaction_args *args) { l_osigaction_t osa; Modified: head/sys/amd64/linux32/syscalls.master ============================================================================== --- head/sys/amd64/linux32/syscalls.master Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/amd64/linux32/syscalls.master Mon Apr 16 21:22:02 2012 (r234352) @@ -95,7 +95,7 @@ 39 AUE_MKDIR STD { int linux_mkdir(char *path, l_int mode); } 40 AUE_RMDIR STD { int linux_rmdir(char *path); } 41 AUE_DUP NOPROTO { int dup(u_int fd); } -42 AUE_PIPE STD { int linux_pipe(l_ulong *pipefds); } +42 AUE_PIPE STD { int linux_pipe(l_int *pipefds); } 43 AUE_NULL STD { int linux_times(struct l_times_argv *buf); } 44 AUE_NULL UNIMPL prof 45 AUE_NULL STD { int linux_brk(l_ulong dsend); } @@ -536,7 +536,7 @@ 328 AUE_NULL STD { int linux_eventfd2(void); } 329 AUE_NULL STD { int linux_epoll_create1(void); } 330 AUE_NULL STD { int linux_dup3(void); } -331 AUE_NULL STD { int linux_pipe2(void); } +331 AUE_NULL STD { int linux_pipe2(l_int *pipefds, l_int flags); } 332 AUE_NULL STD { int linux_inotify_init1(void); } ; linux 2.6.30: 333 AUE_NULL STD { int linux_preadv(void); } Modified: head/sys/compat/linux/linux_file.c ============================================================================== --- head/sys/compat/linux/linux_file.c Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/compat/linux/linux_file.c Mon Apr 16 21:22:02 2012 (r234352) @@ -69,6 +69,9 @@ __FBSDID("$FreeBSD$"); #include #include +/* XXX */ +int do_pipe(struct thread *td, int fildes[2], int flags); + int linux_creat(struct thread *td, struct linux_creat_args *args) { @@ -1575,3 +1578,49 @@ linux_fadvise64_64(struct thread *td, st return (kern_posix_fadvise(td, args->fd, args->offset, args->len, advice)); } + +int +linux_pipe(struct thread *td, struct linux_pipe_args *args) +{ + int fildes[2]; + int error; + +#ifdef DEBUG + if (ldebug(pipe)) + printf(ARGS(pipe, "*")); +#endif + + error = do_pipe(td, fildes, 0); + if (error) + return (error); + + /* XXX: Close descriptors on error. */ + return (copyout(fildes, args->pipefds, sizeof(fildes))); +} + +int +linux_pipe2(struct thread *td, struct linux_pipe2_args *args) +{ + int fildes[2]; + int error, flags; + +#ifdef DEBUG + if (ldebug(pipe2)) + printf(ARGS(pipe2, "*, %d"), args->flags); +#endif + + if ((args->flags & ~(LINUX_O_NONBLOCK | LINUX_O_CLOEXEC)) != 0) + return (EINVAL); + + flags = 0; + if ((args->flags & LINUX_O_NONBLOCK) != 0) + flags |= O_NONBLOCK; + if ((args->flags & LINUX_O_CLOEXEC) != 0) + flags |= O_CLOEXEC; + error = do_pipe(td, fildes, flags); + if (error) + return (error); + + /* XXX: Close descriptors on error. */ + return (copyout(fildes, args->pipefds, sizeof(fildes))); +} Modified: head/sys/i386/linux/linux_dummy.c ============================================================================== --- head/sys/i386/linux/linux_dummy.c Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/i386/linux/linux_dummy.c Mon Apr 16 21:22:02 2012 (r234352) @@ -113,7 +113,6 @@ DUMMY(signalfd4); DUMMY(eventfd2); DUMMY(epoll_create1); DUMMY(dup3); -DUMMY(pipe2); DUMMY(inotify_init1); /* linux 2.6.30: */ DUMMY(preadv); Modified: head/sys/i386/linux/linux_machdep.c ============================================================================== --- head/sys/i386/linux/linux_machdep.c Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/i386/linux/linux_machdep.c Mon Apr 16 21:22:02 2012 (r234352) @@ -587,25 +587,6 @@ linux_mprotect(struct thread *td, struct } int -linux_pipe(struct thread *td, struct linux_pipe_args *args) -{ - int error; - int fildes[2]; - -#ifdef DEBUG - if (ldebug(pipe)) - printf(ARGS(pipe, "*")); -#endif - - error = kern_pipe(td, fildes); - if (error) - return (error); - - /* XXX: Close descriptors on error. */ - return (copyout(fildes, args->pipefds, sizeof fildes)); -} - -int linux_ioperm(struct thread *td, struct linux_ioperm_args *args) { int error; Modified: head/sys/i386/linux/syscalls.master ============================================================================== --- head/sys/i386/linux/syscalls.master Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/i386/linux/syscalls.master Mon Apr 16 21:22:02 2012 (r234352) @@ -95,7 +95,7 @@ 39 AUE_MKDIR STD { int linux_mkdir(char *path, l_int mode); } 40 AUE_RMDIR STD { int linux_rmdir(char *path); } 41 AUE_DUP NOPROTO { int dup(u_int fd); } -42 AUE_PIPE STD { int linux_pipe(l_ulong *pipefds); } +42 AUE_PIPE STD { int linux_pipe(l_int *pipefds); } 43 AUE_NULL STD { int linux_times(struct l_times_argv *buf); } 44 AUE_NULL UNIMPL prof 45 AUE_NULL STD { int linux_brk(l_ulong dsend); } @@ -546,7 +546,7 @@ 328 AUE_NULL STD { int linux_eventfd2(void); } 329 AUE_NULL STD { int linux_epoll_create1(void); } 330 AUE_NULL STD { int linux_dup3(void); } -331 AUE_NULL STD { int linux_pipe2(void); } +331 AUE_NULL STD { int linux_pipe2(l_int *pipefds, l_int flags); } 332 AUE_NULL STD { int linux_inotify_init1(void); } ; linux 2.6.30: 333 AUE_NULL STD { int linux_preadv(void); } Modified: head/sys/kern/sys_pipe.c ============================================================================== --- head/sys/kern/sys_pipe.c Mon Apr 16 20:41:25 2012 (r234351) +++ head/sys/kern/sys_pipe.c Mon Apr 16 21:22:02 2012 (r234352) @@ -129,6 +129,9 @@ __FBSDID("$FreeBSD$"); #include #include +/* XXX */ +int do_pipe(struct thread *td, int fildes[2], int flags); + /* * Use this define if you want to disable *fancy* VM things. Expect an * approx 30% decrease in transfer rate. This could be useful for @@ -405,11 +408,18 @@ pipe_dtor(struct pipe *dpipe) int kern_pipe(struct thread *td, int fildes[2]) { + + return (do_pipe(td, fildes, 0)); +} + +int +do_pipe(struct thread *td, int fildes[2], int flags) +{ struct filedesc *fdp; struct file *rf, *wf; struct pipe *rpipe, *wpipe; struct pipepair *pp; - int fd, error; + int fd, fflags, error; fdp = td->td_proc->p_fd; error = pipe_paircreate(td, &pp); @@ -417,7 +427,7 @@ kern_pipe(struct thread *td, int fildes[ return (error); rpipe = &pp->pp_rpipe; wpipe = &pp->pp_wpipe; - error = falloc(td, &rf, &fd, 0); + error = falloc(td, &rf, &fd, flags); if (error) { pipeclose(rpipe); pipeclose(wpipe); @@ -426,14 +436,18 @@ kern_pipe(struct thread *td, int fildes[ /* An extra reference on `rf' has been held for us by falloc(). */ fildes[0] = fd; + fflags = FREAD | FWRITE; + if ((flags & O_NONBLOCK) != 0) + fflags |= FNONBLOCK; + /* * Warning: once we've gotten past allocation of the fd for the * read-side, we can only drop the read side via fdrop() in order * to avoid races against processes which manage to dup() the read * side while we are blocked trying to allocate the write side. */ - finit(rf, FREAD | FWRITE, DTYPE_PIPE, rpipe, &pipeops); - error = falloc(td, &wf, &fd, 0); + finit(rf, fflags, DTYPE_PIPE, rpipe, &pipeops); + error = falloc(td, &wf, &fd, flags); if (error) { fdclose(fdp, rf, fildes[0], td); fdrop(rf, td); @@ -442,7 +456,7 @@ kern_pipe(struct thread *td, int fildes[ return (error); } /* An extra reference on `wf' has been held for us by falloc(). */ - finit(wf, FREAD | FWRITE, DTYPE_PIPE, wpipe, &pipeops); + finit(wf, fflags, DTYPE_PIPE, wpipe, &pipeops); fdrop(wf, td); fildes[1] = fd; fdrop(rf, td); From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 21:23:28 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 872AD106566B; Mon, 16 Apr 2012 21:23: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 6ACB68FC12; Mon, 16 Apr 2012 21:23:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GLNSUf051141; Mon, 16 Apr 2012 21:23:28 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GLNSr6051133; Mon, 16 Apr 2012 21:23:28 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204162123.q3GLNSr6051133@svn.freebsd.org> From: Dimitry Andric Date: Mon, 16 Apr 2012 21:23: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: r234353 - in head: . contrib/llvm contrib/llvm/include/llvm contrib/llvm/include/llvm-c contrib/llvm/include/llvm-c/Transforms contrib/llvm/include/llvm/ADT contrib/llvm/include/llvm/An... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 21:23:28 -0000 Author: dim Date: Mon Apr 16 21:23:25 2012 New Revision: 234353 URL: http://svn.freebsd.org/changeset/base/234353 Log: Upgrade our copy of llvm/clang to trunk r154661, in preparation of the upcoming 3.1 release (expected in a few weeks). Preliminary release notes can be found at: MFC after: 2 weeks Added: head/contrib/llvm/include/llvm-c/TargetMachine.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm-c/TargetMachine.h head/contrib/llvm/include/llvm-c/Transforms/Vectorize.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm-c/Transforms/Vectorize.h head/contrib/llvm/include/llvm/ADT/Hashing.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/Hashing.h head/contrib/llvm/include/llvm/ADT/SparseSet.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/SparseSet.h head/contrib/llvm/include/llvm/ADT/VariadicFunction.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/VariadicFunction.h head/contrib/llvm/include/llvm/ADT/edit_distance.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/edit_distance.h head/contrib/llvm/include/llvm/CodeGen/DFAPacketizer.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/DFAPacketizer.h head/contrib/llvm/include/llvm/CodeGen/LiveRangeEdit.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/LiveRangeEdit.h head/contrib/llvm/include/llvm/CodeGen/MachineInstrBundle.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/MachineInstrBundle.h head/contrib/llvm/include/llvm/CodeGen/MachineScheduler.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/MachineScheduler.h head/contrib/llvm/include/llvm/CodeGen/ResourcePriorityQueue.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/ResourcePriorityQueue.h head/contrib/llvm/include/llvm/CodeGen/ScheduleDAGInstrs.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/ScheduleDAGInstrs.h head/contrib/llvm/include/llvm/ExecutionEngine/IntelJITEventsWrapper.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ExecutionEngine/IntelJITEventsWrapper.h head/contrib/llvm/include/llvm/ExecutionEngine/OProfileWrapper.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ExecutionEngine/OProfileWrapper.h head/contrib/llvm/include/llvm/IntrinsicsHexagon.td - copied unchanged from r234301, vendor/llvm/dist/include/llvm/IntrinsicsHexagon.td head/contrib/llvm/include/llvm/MC/MCWinCOFFObjectWriter.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/MC/MCWinCOFFObjectWriter.h head/contrib/llvm/include/llvm/Object/ELF.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Object/ELF.h head/contrib/llvm/include/llvm/Support/DataStream.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/DataStream.h head/contrib/llvm/include/llvm/Support/JSONParser.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/JSONParser.h head/contrib/llvm/include/llvm/Support/LockFileManager.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/LockFileManager.h head/contrib/llvm/include/llvm/Support/SaveAndRestore.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/SaveAndRestore.h head/contrib/llvm/include/llvm/Support/StreamableMemoryObject.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/StreamableMemoryObject.h head/contrib/llvm/include/llvm/Support/YAMLParser.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/YAMLParser.h head/contrib/llvm/include/llvm/Transforms/Utils/CmpInstAnalysis.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Transforms/Utils/CmpInstAnalysis.h head/contrib/llvm/include/llvm/Transforms/Utils/ModuleUtils.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Transforms/Utils/ModuleUtils.h head/contrib/llvm/include/llvm/Transforms/Vectorize.h - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Transforms/Vectorize.h head/contrib/llvm/lib/Analysis/CodeMetrics.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Analysis/CodeMetrics.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfAccelTable.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfAccelTable.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfAccelTable.h - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfAccelTable.h head/contrib/llvm/lib/CodeGen/DFAPacketizer.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/DFAPacketizer.cpp head/contrib/llvm/lib/CodeGen/JITCodeEmitter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/JITCodeEmitter.cpp head/contrib/llvm/lib/CodeGen/MachineBlockPlacement.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineBlockPlacement.cpp head/contrib/llvm/lib/CodeGen/MachineCodeEmitter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineCodeEmitter.cpp head/contrib/llvm/lib/CodeGen/MachineCopyPropagation.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineCopyPropagation.cpp head/contrib/llvm/lib/CodeGen/MachineInstrBundle.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineInstrBundle.cpp head/contrib/llvm/lib/CodeGen/MachineScheduler.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineScheduler.cpp head/contrib/llvm/lib/CodeGen/RegAllocBase.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/RegAllocBase.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/ResourcePriorityQueue.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/SelectionDAG/ResourcePriorityQueue.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp head/contrib/llvm/lib/CodeGen/TargetFrameLoweringImpl.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/TargetFrameLoweringImpl.cpp head/contrib/llvm/lib/CodeGen/TargetOptionsImpl.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/TargetOptionsImpl.cpp head/contrib/llvm/lib/ExecutionEngine/EventListenerCommon.h - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/EventListenerCommon.h head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/ - copied from r234301, vendor/llvm/dist/lib/ExecutionEngine/IntelJITEvents/ head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJITMemoryManager.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/MCJIT/MCJITMemoryManager.cpp head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/ - copied from r234301, vendor/llvm/dist/lib/ExecutionEngine/OProfileJIT/ head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h head/contrib/llvm/lib/MC/MCDisassembler/EDMain.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/MC/MCDisassembler/EDMain.cpp head/contrib/llvm/lib/Support/DataStream.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Support/DataStream.cpp head/contrib/llvm/lib/Support/Hashing.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Support/Hashing.cpp head/contrib/llvm/lib/Support/IntrusiveRefCntPtr.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Support/IntrusiveRefCntPtr.cpp head/contrib/llvm/lib/Support/JSONParser.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Support/JSONParser.cpp head/contrib/llvm/lib/Support/LockFileManager.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Support/LockFileManager.cpp head/contrib/llvm/lib/Support/StreamableMemoryObject.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Support/StreamableMemoryObject.cpp head/contrib/llvm/lib/Support/YAMLParser.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Support/YAMLParser.cpp head/contrib/llvm/lib/TableGen/TableGenAction.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/TableGen/TableGenAction.cpp head/contrib/llvm/lib/Target/ARM/ARMMachineFunctionInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/ARM/ARMMachineFunctionInfo.cpp head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMELFObjectWriter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/ARM/MCTargetDesc/ARMELFObjectWriter.cpp head/contrib/llvm/lib/Target/CellSPU/SPUMachineFunction.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/CellSPU/SPUMachineFunction.cpp head/contrib/llvm/lib/Target/Hexagon/ - copied from r234301, vendor/llvm/dist/lib/Target/Hexagon/ head/contrib/llvm/lib/Target/MBlaze/MBlazeMachineFunction.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/MBlaze/MBlazeMachineFunction.cpp head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeELFObjectWriter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/MBlaze/MCTargetDesc/MBlazeELFObjectWriter.cpp head/contrib/llvm/lib/Target/MSP430/MSP430MachineFunctionInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/MSP430/MSP430MachineFunctionInfo.cpp head/contrib/llvm/lib/Target/Mips/AsmParser/ - copied from r234301, vendor/llvm/dist/lib/Target/Mips/AsmParser/ head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsELFObjectWriter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MCTargetDesc/MipsELFObjectWriter.cpp head/contrib/llvm/lib/Target/Mips/MipsAnalyzeImmediate.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsAnalyzeImmediate.cpp head/contrib/llvm/lib/Target/Mips/MipsAnalyzeImmediate.h - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsAnalyzeImmediate.h head/contrib/llvm/lib/Target/Mips/MipsCondMov.td - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsCondMov.td head/contrib/llvm/lib/Target/Mips/MipsMachineFunction.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsMachineFunction.cpp head/contrib/llvm/lib/Target/PTX/PTXMachineFunctionInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PTX/PTXMachineFunctionInfo.cpp head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCELFObjectWriter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/MCTargetDesc/PPCELFObjectWriter.cpp head/contrib/llvm/lib/Target/PowerPC/PPCMachineFunctionInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/PPCMachineFunctionInfo.cpp head/contrib/llvm/lib/Target/PowerPC/PPCSchedule440.td - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/PPCSchedule440.td head/contrib/llvm/lib/Target/PowerPC/PPCScheduleA2.td - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/PPCScheduleA2.td head/contrib/llvm/lib/Target/Sparc/SparcMachineFunctionInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Sparc/SparcMachineFunctionInfo.cpp head/contrib/llvm/lib/Target/TargetJITInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/TargetJITInfo.cpp head/contrib/llvm/lib/Target/TargetMachineC.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/TargetMachineC.cpp head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86ELFObjectWriter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/MCTargetDesc/X86ELFObjectWriter.cpp head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86WinCOFFObjectWriter.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/MCTargetDesc/X86WinCOFFObjectWriter.cpp head/contrib/llvm/lib/Target/X86/X86InstrSVM.td - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86InstrSVM.td head/contrib/llvm/lib/Target/X86/X86InstrXOP.td - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86InstrXOP.td head/contrib/llvm/lib/Target/X86/X86MachineFunctionInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86MachineFunctionInfo.cpp head/contrib/llvm/lib/Target/X86/X86Schedule.td - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86Schedule.td head/contrib/llvm/lib/Target/X86/X86ScheduleAtom.td - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86ScheduleAtom.td head/contrib/llvm/lib/Target/XCore/XCoreMachineFunctionInfo.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Target/XCore/XCoreMachineFunctionInfo.cpp head/contrib/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/AddressSanitizer.cpp head/contrib/llvm/lib/Transforms/Instrumentation/FunctionBlackList.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/FunctionBlackList.cpp head/contrib/llvm/lib/Transforms/Instrumentation/FunctionBlackList.h - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/FunctionBlackList.h head/contrib/llvm/lib/Transforms/Instrumentation/ThreadSanitizer.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/ThreadSanitizer.cpp head/contrib/llvm/lib/Transforms/Scalar/GlobalMerge.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Scalar/GlobalMerge.cpp head/contrib/llvm/lib/Transforms/Utils/CmpInstAnalysis.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Utils/CmpInstAnalysis.cpp head/contrib/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Utils/LoopUnrollRuntime.cpp head/contrib/llvm/lib/Transforms/Utils/ModuleUtils.cpp - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Utils/ModuleUtils.cpp head/contrib/llvm/lib/Transforms/Vectorize/ - copied from r234301, vendor/llvm/dist/lib/Transforms/Vectorize/ head/contrib/llvm/tools/clang/include/clang/AST/BuiltinTypes.def - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/BuiltinTypes.def head/contrib/llvm/tools/clang/include/clang/AST/DeclLookups.h - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/DeclLookups.h head/contrib/llvm/tools/clang/include/clang/AST/LambdaMangleContext.h - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/LambdaMangleContext.h head/contrib/llvm/tools/clang/include/clang/AST/NSAPI.h - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/NSAPI.h head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/Dominators.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Analysis/Analyses/Dominators.h head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/PostOrderCFGView.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Analysis/Analyses/PostOrderCFGView.h head/contrib/llvm/tools/clang/include/clang/Analysis/CallGraph.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Analysis/CallGraph.h head/contrib/llvm/tools/clang/include/clang/Basic/AllDiagnostics.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/AllDiagnostics.h head/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsHexagon.def - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/BuiltinsHexagon.def head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticSerializationKinds.td - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/DiagnosticSerializationKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/Lambda.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/Lambda.h head/contrib/llvm/tools/clang/include/clang/Basic/Module.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/Module.h head/contrib/llvm/tools/clang/include/clang/Edit/ - copied from r234301, vendor/clang/dist/include/clang/Edit/ head/contrib/llvm/tools/clang/include/clang/Frontend/ChainedIncludesSource.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/ChainedIncludesSource.h head/contrib/llvm/tools/clang/include/clang/Frontend/DiagnosticRenderer.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/DiagnosticRenderer.h head/contrib/llvm/tools/clang/include/clang/Frontend/LayoutOverrideSource.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/LayoutOverrideSource.h head/contrib/llvm/tools/clang/include/clang/Frontend/MigratorOptions.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/MigratorOptions.h head/contrib/llvm/tools/clang/include/clang/Frontend/SerializedDiagnosticPrinter.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/SerializedDiagnosticPrinter.h head/contrib/llvm/tools/clang/include/clang/Frontend/TextDiagnostic.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/TextDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Index/GlobalCallGraph.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Index/GlobalCallGraph.h head/contrib/llvm/tools/clang/include/clang/Lex/ModuleMap.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Lex/ModuleMap.h head/contrib/llvm/tools/clang/include/clang/Serialization/SerializationDiagnostic.h - copied unchanged from r234301, vendor/clang/dist/include/clang/Serialization/SerializationDiagnostic.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Checkers/CommonBugCategories.h - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Checkers/CommonBugCategories.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/FunctionSummary.h - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/FunctionSummary.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState_Fwd.h - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState_Fwd.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/TaintManager.h - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/TaintManager.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/TaintTag.h - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/TaintTag.h head/contrib/llvm/tools/clang/include/clang/Tooling/ - copied from r234301, vendor/clang/dist/include/clang/Tooling/ head/contrib/llvm/tools/clang/lib/ARCMigrate/ObjCMT.cpp - copied unchanged from r234301, vendor/clang/dist/lib/ARCMigrate/ObjCMT.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransGCAttrs.cpp - copied unchanged from r234301, vendor/clang/dist/lib/ARCMigrate/TransGCAttrs.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransGCCalls.cpp - copied unchanged from r234301, vendor/clang/dist/lib/ARCMigrate/TransGCCalls.cpp head/contrib/llvm/tools/clang/lib/AST/LambdaMangleContext.cpp - copied unchanged from r234301, vendor/clang/dist/lib/AST/LambdaMangleContext.cpp head/contrib/llvm/tools/clang/lib/AST/NSAPI.cpp - copied unchanged from r234301, vendor/clang/dist/lib/AST/NSAPI.cpp head/contrib/llvm/tools/clang/lib/Analysis/AnalysisDeclContext.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/AnalysisDeclContext.cpp head/contrib/llvm/tools/clang/lib/Analysis/CallGraph.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/CallGraph.cpp head/contrib/llvm/tools/clang/lib/Analysis/Dominators.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/Dominators.cpp head/contrib/llvm/tools/clang/lib/Analysis/PostOrderCFGView.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/PostOrderCFGView.cpp head/contrib/llvm/tools/clang/lib/Basic/Module.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Basic/Module.cpp head/contrib/llvm/tools/clang/lib/Driver/WindowsToolChain.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Driver/WindowsToolChain.cpp head/contrib/llvm/tools/clang/lib/Edit/ - copied from r234301, vendor/clang/dist/lib/Edit/ head/contrib/llvm/tools/clang/lib/Frontend/ChainedDiagnosticConsumer.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/ChainedDiagnosticConsumer.cpp head/contrib/llvm/tools/clang/lib/Frontend/ChainedIncludesSource.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/ChainedIncludesSource.cpp head/contrib/llvm/tools/clang/lib/Frontend/DependencyGraph.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/DependencyGraph.cpp head/contrib/llvm/tools/clang/lib/Frontend/DiagnosticRenderer.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/DiagnosticRenderer.cpp head/contrib/llvm/tools/clang/lib/Frontend/LayoutOverrideSource.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/LayoutOverrideSource.cpp head/contrib/llvm/tools/clang/lib/Frontend/SerializedDiagnosticPrinter.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/SerializedDiagnosticPrinter.cpp head/contrib/llvm/tools/clang/lib/Frontend/TextDiagnostic.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/TextDiagnostic.cpp head/contrib/llvm/tools/clang/lib/Headers/avx2intrin.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/avx2intrin.h head/contrib/llvm/tools/clang/lib/Headers/bmi2intrin.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/bmi2intrin.h head/contrib/llvm/tools/clang/lib/Headers/bmiintrin.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/bmiintrin.h head/contrib/llvm/tools/clang/lib/Headers/cpuid.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/cpuid.h head/contrib/llvm/tools/clang/lib/Headers/fma4intrin.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/fma4intrin.h head/contrib/llvm/tools/clang/lib/Headers/lzcntintrin.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/lzcntintrin.h head/contrib/llvm/tools/clang/lib/Headers/module.map - copied unchanged from r234301, vendor/clang/dist/lib/Headers/module.map head/contrib/llvm/tools/clang/lib/Headers/popcntintrin.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/popcntintrin.h head/contrib/llvm/tools/clang/lib/Headers/unwind.h - copied unchanged from r234301, vendor/clang/dist/lib/Headers/unwind.h head/contrib/llvm/tools/clang/lib/Index/GlobalCallGraph.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Index/GlobalCallGraph.cpp head/contrib/llvm/tools/clang/lib/Lex/ModuleMap.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Lex/ModuleMap.cpp head/contrib/llvm/tools/clang/lib/Lex/PPCallbacks.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Lex/PPCallbacks.cpp head/contrib/llvm/tools/clang/lib/Rewrite/RewriteModernObjC.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Rewrite/RewriteModernObjC.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaConsumer.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Sema/SemaConsumer.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaLambda.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Sema/SemaLambda.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaPseudoObject.cpp - copied unchanged from r234301, vendor/clang/dist/lib/Sema/SemaPseudoObject.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/BoolAssignmentChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/BoolAssignmentChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CStringSyntaxChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/CStringSyntaxChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckerDocumentation.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/CheckerDocumentation.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CommonBugCategories.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/CommonBugCategories.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/InterCheckerAPI.h - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/InterCheckerAPI.h head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCContainersASTChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/ObjCContainersASTChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCContainersChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/ObjCContainersChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/TaintTesterChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/TaintTesterChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/VirtualCallChecker.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/VirtualCallChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/FunctionSummary.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Core/FunctionSummary.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SubEngine.cpp - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Core/SubEngine.cpp head/contrib/llvm/tools/clang/lib/Tooling/ - copied from r234301, vendor/clang/dist/lib/Tooling/ head/contrib/llvm/tools/llvm-readobj/ - copied from r234301, vendor/llvm/dist/tools/llvm-readobj/ head/contrib/llvm/tools/llvm-stress/ - copied from r234301, vendor/llvm/dist/tools/llvm-stress/ head/contrib/llvm/utils/TableGen/DFAPacketizerEmitter.cpp - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/DFAPacketizerEmitter.cpp head/contrib/llvm/utils/TableGen/DFAPacketizerEmitter.h - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/DFAPacketizerEmitter.h head/contrib/llvm/utils/TableGen/SequenceToOffsetTable.h - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/SequenceToOffsetTable.h head/contrib/llvm/utils/TableGen/X86ModRMFilters.cpp - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/X86ModRMFilters.cpp head/lib/clang/include/MipsGenMCCodeEmitter.inc (contents, props changed) head/lib/clang/include/clang/Basic/DiagnosticSerializationKinds.inc (contents, props changed) head/lib/clang/include/clang/Config/ head/lib/clang/include/clang/Config/config.h (contents, props changed) head/lib/clang/include/clang/Sema/ head/lib/clang/include/clang/Sema/AttrParsedAttrKinds.inc (contents, props changed) head/lib/clang/include/clang/Sema/AttrParsedAttrList.inc (contents, props changed) head/lib/clang/include/clang/Sema/AttrTemplateInstantiate.inc (contents, props changed) head/lib/clang/libclangedit/ head/lib/clang/libclangedit/Makefile (contents, props changed) head/lib/clang/libllvmmipsasmparser/ head/lib/clang/libllvmmipsasmparser/Makefile (contents, props changed) head/lib/clang/libllvmvectorize/ head/lib/clang/libllvmvectorize/Makefile (contents, props changed) Deleted: head/contrib/llvm/include/llvm/ADT/VectorExtras.h head/contrib/llvm/include/llvm/CodeGen/BinaryObject.h head/contrib/llvm/include/llvm/CodeGen/ObjectCodeEmitter.h head/contrib/llvm/include/llvm/DebugInfoProbe.h head/contrib/llvm/include/llvm/IntrinsicsAlpha.td head/contrib/llvm/include/llvm/Transforms/Utils/BasicInliner.h head/contrib/llvm/lib/CodeGen/ELF.h head/contrib/llvm/lib/CodeGen/ELFCodeEmitter.cpp head/contrib/llvm/lib/CodeGen/ELFCodeEmitter.h head/contrib/llvm/lib/CodeGen/ELFWriter.cpp head/contrib/llvm/lib/CodeGen/ELFWriter.h head/contrib/llvm/lib/CodeGen/LiveRangeEdit.h head/contrib/llvm/lib/CodeGen/ObjectCodeEmitter.cpp head/contrib/llvm/lib/CodeGen/RegAllocLinearScan.cpp head/contrib/llvm/lib/CodeGen/ScheduleDAGEmit.cpp head/contrib/llvm/lib/CodeGen/ScheduleDAGInstrs.h head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp head/contrib/llvm/lib/CodeGen/Splitter.cpp head/contrib/llvm/lib/CodeGen/Splitter.h head/contrib/llvm/lib/CodeGen/VirtRegRewriter.cpp head/contrib/llvm/lib/CodeGen/VirtRegRewriter.h head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/CMakeLists.txt head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/LLVMBuild.txt head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/Makefile head/contrib/llvm/lib/ExecutionEngine/JIT/Intercept.cpp head/contrib/llvm/lib/ExecutionEngine/JIT/JITDebugRegisterer.cpp head/contrib/llvm/lib/ExecutionEngine/JIT/JITDebugRegisterer.h head/contrib/llvm/lib/ExecutionEngine/JIT/OProfileJITEventListener.cpp head/contrib/llvm/lib/ExecutionEngine/MCJIT/Intercept.cpp head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/CMakeLists.txt head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/LLVMBuild.txt head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/Makefile head/contrib/llvm/lib/MC/ELFObjectWriter.h head/contrib/llvm/lib/MC/MCELFStreamer.h head/contrib/llvm/lib/MC/MCLoggingStreamer.cpp head/contrib/llvm/lib/Target/ARM/ARMGlobalMerge.cpp head/contrib/llvm/lib/Target/Alpha/ head/contrib/llvm/lib/Target/Blackfin/ head/contrib/llvm/lib/Target/CBackend/ head/contrib/llvm/lib/Target/Hexagon/CMakeLists.txt head/contrib/llvm/lib/Target/Hexagon/InstPrinter/CMakeLists.txt head/contrib/llvm/lib/Target/Hexagon/InstPrinter/LLVMBuild.txt head/contrib/llvm/lib/Target/Hexagon/InstPrinter/Makefile head/contrib/llvm/lib/Target/Hexagon/LLVMBuild.txt head/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/CMakeLists.txt head/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/LLVMBuild.txt head/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/Makefile head/contrib/llvm/lib/Target/Hexagon/Makefile head/contrib/llvm/lib/Target/Hexagon/TargetInfo/CMakeLists.txt head/contrib/llvm/lib/Target/Hexagon/TargetInfo/LLVMBuild.txt head/contrib/llvm/lib/Target/Hexagon/TargetInfo/Makefile head/contrib/llvm/lib/Target/Mips/AsmParser/CMakeLists.txt head/contrib/llvm/lib/Target/Mips/AsmParser/LLVMBuild.txt head/contrib/llvm/lib/Target/Mips/AsmParser/Makefile head/contrib/llvm/lib/Target/Mips/MipsMCSymbolRefExpr.cpp head/contrib/llvm/lib/Target/Mips/MipsMCSymbolRefExpr.h head/contrib/llvm/lib/Target/SystemZ/ head/contrib/llvm/lib/Target/TargetFrameLowering.cpp head/contrib/llvm/lib/Transforms/Utils/BasicInliner.cpp head/contrib/llvm/lib/Transforms/Vectorize/CMakeLists.txt head/contrib/llvm/lib/Transforms/Vectorize/LLVMBuild.txt head/contrib/llvm/lib/Transforms/Vectorize/Makefile head/contrib/llvm/lib/VMCore/DebugInfoProbe.cpp head/contrib/llvm/tools/bugpoint/CMakeLists.txt head/contrib/llvm/tools/bugpoint/Makefile head/contrib/llvm/tools/clang/include/clang/AST/UsuallyTinyPtrVector.h head/contrib/llvm/tools/clang/include/clang/Analysis/Support/SaveAndRestore.h head/contrib/llvm/tools/clang/include/clang/Driver/HostInfo.h head/contrib/llvm/tools/clang/include/clang/Index/CallGraph.h head/contrib/llvm/tools/clang/include/clang/Sema/MultiInitializer.h head/contrib/llvm/tools/clang/include/clang/Serialization/ChainedIncludesSource.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngineBuilders.h head/contrib/llvm/tools/clang/lib/Analysis/AnalysisContext.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGException.h head/contrib/llvm/tools/clang/lib/CodeGen/CGTemporaries.cpp head/contrib/llvm/tools/clang/lib/Driver/HostInfo.cpp head/contrib/llvm/tools/clang/lib/Edit/CMakeLists.txt head/contrib/llvm/tools/clang/lib/Edit/Makefile head/contrib/llvm/tools/clang/lib/Index/CallGraph.cpp head/contrib/llvm/tools/clang/lib/Sema/MultiInitializer.cpp head/contrib/llvm/tools/clang/lib/Serialization/ChainedIncludesSource.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/AggExprVisitor.cpp head/contrib/llvm/tools/clang/lib/Tooling/CMakeLists.txt head/contrib/llvm/tools/clang/lib/Tooling/Makefile head/contrib/llvm/tools/clang/utils/TableGen/CMakeLists.txt head/contrib/llvm/tools/clang/utils/TableGen/Makefile head/contrib/llvm/tools/llc/CMakeLists.txt head/contrib/llvm/tools/llc/Makefile head/contrib/llvm/tools/lli/CMakeLists.txt head/contrib/llvm/tools/lli/Makefile head/contrib/llvm/tools/llvm-ar/CMakeLists.txt head/contrib/llvm/tools/llvm-ar/Makefile head/contrib/llvm/tools/llvm-as/CMakeLists.txt head/contrib/llvm/tools/llvm-as/Makefile head/contrib/llvm/tools/llvm-bcanalyzer/CMakeLists.txt head/contrib/llvm/tools/llvm-bcanalyzer/Makefile head/contrib/llvm/tools/llvm-diff/CMakeLists.txt head/contrib/llvm/tools/llvm-diff/Makefile head/contrib/llvm/tools/llvm-dis/CMakeLists.txt head/contrib/llvm/tools/llvm-dis/Makefile head/contrib/llvm/tools/llvm-extract/CMakeLists.txt head/contrib/llvm/tools/llvm-extract/Makefile head/contrib/llvm/tools/llvm-ld/CMakeLists.txt head/contrib/llvm/tools/llvm-ld/Makefile head/contrib/llvm/tools/llvm-link/CMakeLists.txt head/contrib/llvm/tools/llvm-link/Makefile head/contrib/llvm/tools/llvm-mc/CMakeLists.txt head/contrib/llvm/tools/llvm-mc/Makefile head/contrib/llvm/tools/llvm-nm/CMakeLists.txt head/contrib/llvm/tools/llvm-nm/Makefile head/contrib/llvm/tools/llvm-objdump/CMakeLists.txt head/contrib/llvm/tools/llvm-objdump/Makefile head/contrib/llvm/tools/llvm-prof/CMakeLists.txt head/contrib/llvm/tools/llvm-prof/Makefile head/contrib/llvm/tools/llvm-ranlib/CMakeLists.txt head/contrib/llvm/tools/llvm-ranlib/Makefile head/contrib/llvm/tools/llvm-readobj/CMakeLists.txt head/contrib/llvm/tools/llvm-readobj/LLVMBuild.txt head/contrib/llvm/tools/llvm-readobj/Makefile head/contrib/llvm/tools/llvm-rtdyld/CMakeLists.txt head/contrib/llvm/tools/llvm-rtdyld/Makefile head/contrib/llvm/tools/llvm-stress/CMakeLists.txt head/contrib/llvm/tools/llvm-stress/LLVMBuild.txt head/contrib/llvm/tools/llvm-stress/Makefile head/contrib/llvm/tools/llvm-stub/CMakeLists.txt head/contrib/llvm/tools/llvm-stub/Makefile head/contrib/llvm/tools/macho-dump/CMakeLists.txt head/contrib/llvm/tools/macho-dump/Makefile head/contrib/llvm/tools/opt/CMakeLists.txt head/contrib/llvm/tools/opt/Makefile head/contrib/llvm/utils/TableGen/ARMDecoderEmitter.cpp head/contrib/llvm/utils/TableGen/ARMDecoderEmitter.h head/contrib/llvm/utils/TableGen/InstrEnumEmitter.cpp head/contrib/llvm/utils/TableGen/InstrEnumEmitter.h Modified: head/ObsoleteFiles.inc head/contrib/llvm/LICENSE.TXT head/contrib/llvm/include/llvm-c/Analysis.h head/contrib/llvm/include/llvm-c/BitReader.h head/contrib/llvm/include/llvm-c/BitWriter.h head/contrib/llvm/include/llvm-c/Core.h head/contrib/llvm/include/llvm-c/Disassembler.h head/contrib/llvm/include/llvm-c/EnhancedDisassembly.h head/contrib/llvm/include/llvm-c/ExecutionEngine.h head/contrib/llvm/include/llvm-c/Initialization.h head/contrib/llvm/include/llvm-c/LinkTimeOptimizer.h head/contrib/llvm/include/llvm-c/Object.h head/contrib/llvm/include/llvm-c/Target.h head/contrib/llvm/include/llvm-c/Transforms/IPO.h head/contrib/llvm/include/llvm-c/Transforms/PassManagerBuilder.h head/contrib/llvm/include/llvm-c/Transforms/Scalar.h head/contrib/llvm/include/llvm-c/lto.h head/contrib/llvm/include/llvm/ADT/APFloat.h head/contrib/llvm/include/llvm/ADT/APInt.h head/contrib/llvm/include/llvm/ADT/ArrayRef.h head/contrib/llvm/include/llvm/ADT/BitVector.h head/contrib/llvm/include/llvm/ADT/DAGDeltaAlgorithm.h head/contrib/llvm/include/llvm/ADT/DenseMap.h head/contrib/llvm/include/llvm/ADT/DenseMapInfo.h head/contrib/llvm/include/llvm/ADT/FoldingSet.h head/contrib/llvm/include/llvm/ADT/GraphTraits.h head/contrib/llvm/include/llvm/ADT/ImmutableSet.h head/contrib/llvm/include/llvm/ADT/IntervalMap.h head/contrib/llvm/include/llvm/ADT/IntrusiveRefCntPtr.h head/contrib/llvm/include/llvm/ADT/PointerIntPair.h head/contrib/llvm/include/llvm/ADT/PointerUnion.h head/contrib/llvm/include/llvm/ADT/SetVector.h head/contrib/llvm/include/llvm/ADT/SmallBitVector.h head/contrib/llvm/include/llvm/ADT/SmallPtrSet.h head/contrib/llvm/include/llvm/ADT/SmallSet.h head/contrib/llvm/include/llvm/ADT/SmallString.h head/contrib/llvm/include/llvm/ADT/SmallVector.h head/contrib/llvm/include/llvm/ADT/SparseBitVector.h head/contrib/llvm/include/llvm/ADT/Statistic.h head/contrib/llvm/include/llvm/ADT/StringExtras.h head/contrib/llvm/include/llvm/ADT/StringMap.h head/contrib/llvm/include/llvm/ADT/StringRef.h head/contrib/llvm/include/llvm/ADT/TinyPtrVector.h head/contrib/llvm/include/llvm/ADT/Trie.h head/contrib/llvm/include/llvm/ADT/Triple.h head/contrib/llvm/include/llvm/ADT/Twine.h head/contrib/llvm/include/llvm/ADT/ValueMap.h head/contrib/llvm/include/llvm/ADT/ilist.h head/contrib/llvm/include/llvm/Analysis/AliasAnalysis.h head/contrib/llvm/include/llvm/Analysis/AliasSetTracker.h head/contrib/llvm/include/llvm/Analysis/BlockFrequencyImpl.h head/contrib/llvm/include/llvm/Analysis/BlockFrequencyInfo.h head/contrib/llvm/include/llvm/Analysis/BranchProbabilityInfo.h head/contrib/llvm/include/llvm/Analysis/CFGPrinter.h head/contrib/llvm/include/llvm/Analysis/CaptureTracking.h head/contrib/llvm/include/llvm/Analysis/CodeMetrics.h head/contrib/llvm/include/llvm/Analysis/ConstantFolding.h head/contrib/llvm/include/llvm/Analysis/DIBuilder.h head/contrib/llvm/include/llvm/Analysis/DOTGraphTraitsPass.h head/contrib/llvm/include/llvm/Analysis/DebugInfo.h head/contrib/llvm/include/llvm/Analysis/DominanceFrontier.h head/contrib/llvm/include/llvm/Analysis/DominatorInternals.h head/contrib/llvm/include/llvm/Analysis/Dominators.h head/contrib/llvm/include/llvm/Analysis/IVUsers.h head/contrib/llvm/include/llvm/Analysis/InlineCost.h head/contrib/llvm/include/llvm/Analysis/InstructionSimplify.h head/contrib/llvm/include/llvm/Analysis/IntervalIterator.h head/contrib/llvm/include/llvm/Analysis/LazyValueInfo.h head/contrib/llvm/include/llvm/Analysis/Loads.h head/contrib/llvm/include/llvm/Analysis/LoopInfo.h head/contrib/llvm/include/llvm/Analysis/MemoryDependenceAnalysis.h head/contrib/llvm/include/llvm/Analysis/PHITransAddr.h head/contrib/llvm/include/llvm/Analysis/ProfileInfo.h head/contrib/llvm/include/llvm/Analysis/RegionInfo.h head/contrib/llvm/include/llvm/Analysis/ScalarEvolution.h head/contrib/llvm/include/llvm/Analysis/ScalarEvolutionExpander.h head/contrib/llvm/include/llvm/Analysis/ScalarEvolutionExpressions.h head/contrib/llvm/include/llvm/Analysis/ValueTracking.h head/contrib/llvm/include/llvm/Argument.h head/contrib/llvm/include/llvm/Assembly/AssemblyAnnotationWriter.h head/contrib/llvm/include/llvm/Assembly/Parser.h head/contrib/llvm/include/llvm/Assembly/Writer.h head/contrib/llvm/include/llvm/Attributes.h head/contrib/llvm/include/llvm/AutoUpgrade.h head/contrib/llvm/include/llvm/BasicBlock.h head/contrib/llvm/include/llvm/Bitcode/Archive.h head/contrib/llvm/include/llvm/Bitcode/BitCodes.h head/contrib/llvm/include/llvm/Bitcode/BitstreamReader.h head/contrib/llvm/include/llvm/Bitcode/BitstreamWriter.h head/contrib/llvm/include/llvm/Bitcode/LLVMBitCodes.h head/contrib/llvm/include/llvm/Bitcode/ReaderWriter.h head/contrib/llvm/include/llvm/CodeGen/Analysis.h head/contrib/llvm/include/llvm/CodeGen/AsmPrinter.h head/contrib/llvm/include/llvm/CodeGen/CallingConvLower.h head/contrib/llvm/include/llvm/CodeGen/EdgeBundles.h head/contrib/llvm/include/llvm/CodeGen/FastISel.h head/contrib/llvm/include/llvm/CodeGen/FunctionLoweringInfo.h head/contrib/llvm/include/llvm/CodeGen/GCStrategy.h head/contrib/llvm/include/llvm/CodeGen/ISDOpcodes.h head/contrib/llvm/include/llvm/CodeGen/JITCodeEmitter.h head/contrib/llvm/include/llvm/CodeGen/LatencyPriorityQueue.h head/contrib/llvm/include/llvm/CodeGen/LexicalScopes.h head/contrib/llvm/include/llvm/CodeGen/LinkAllCodegenComponents.h head/contrib/llvm/include/llvm/CodeGen/LiveInterval.h head/contrib/llvm/include/llvm/CodeGen/LiveIntervalAnalysis.h head/contrib/llvm/include/llvm/CodeGen/LiveVariables.h head/contrib/llvm/include/llvm/CodeGen/MachineBasicBlock.h head/contrib/llvm/include/llvm/CodeGen/MachineBlockFrequencyInfo.h head/contrib/llvm/include/llvm/CodeGen/MachineBranchProbabilityInfo.h head/contrib/llvm/include/llvm/CodeGen/MachineCodeEmitter.h head/contrib/llvm/include/llvm/CodeGen/MachineConstantPool.h head/contrib/llvm/include/llvm/CodeGen/MachineDominators.h head/contrib/llvm/include/llvm/CodeGen/MachineFrameInfo.h head/contrib/llvm/include/llvm/CodeGen/MachineFunction.h head/contrib/llvm/include/llvm/CodeGen/MachineFunctionAnalysis.h head/contrib/llvm/include/llvm/CodeGen/MachineInstr.h head/contrib/llvm/include/llvm/CodeGen/MachineInstrBuilder.h head/contrib/llvm/include/llvm/CodeGen/MachineJumpTableInfo.h head/contrib/llvm/include/llvm/CodeGen/MachineMemOperand.h head/contrib/llvm/include/llvm/CodeGen/MachineModuleInfo.h head/contrib/llvm/include/llvm/CodeGen/MachineOperand.h head/contrib/llvm/include/llvm/CodeGen/MachinePassRegistry.h head/contrib/llvm/include/llvm/CodeGen/MachineRegisterInfo.h head/contrib/llvm/include/llvm/CodeGen/PBQP/Graph.h head/contrib/llvm/include/llvm/CodeGen/PBQP/HeuristicBase.h head/contrib/llvm/include/llvm/CodeGen/PBQP/Heuristics/Briggs.h head/contrib/llvm/include/llvm/CodeGen/Passes.h head/contrib/llvm/include/llvm/CodeGen/RegisterScavenging.h head/contrib/llvm/include/llvm/CodeGen/ScheduleDAG.h head/contrib/llvm/include/llvm/CodeGen/SchedulerRegistry.h head/contrib/llvm/include/llvm/CodeGen/SelectionDAG.h head/contrib/llvm/include/llvm/CodeGen/SelectionDAGISel.h head/contrib/llvm/include/llvm/CodeGen/SelectionDAGNodes.h head/contrib/llvm/include/llvm/CodeGen/SlotIndexes.h head/contrib/llvm/include/llvm/CodeGen/TargetLoweringObjectFileImpl.h head/contrib/llvm/include/llvm/CodeGen/ValueTypes.h head/contrib/llvm/include/llvm/CodeGen/ValueTypes.td head/contrib/llvm/include/llvm/Constant.h head/contrib/llvm/include/llvm/Constants.h head/contrib/llvm/include/llvm/DefaultPasses.h head/contrib/llvm/include/llvm/DerivedTypes.h head/contrib/llvm/include/llvm/ExecutionEngine/ExecutionEngine.h head/contrib/llvm/include/llvm/ExecutionEngine/JITEventListener.h head/contrib/llvm/include/llvm/ExecutionEngine/JITMemoryManager.h head/contrib/llvm/include/llvm/ExecutionEngine/RuntimeDyld.h head/contrib/llvm/include/llvm/Function.h head/contrib/llvm/include/llvm/GlobalValue.h head/contrib/llvm/include/llvm/InitializePasses.h head/contrib/llvm/include/llvm/InlineAsm.h head/contrib/llvm/include/llvm/InstrTypes.h head/contrib/llvm/include/llvm/Instruction.def head/contrib/llvm/include/llvm/Instruction.h head/contrib/llvm/include/llvm/Instructions.h head/contrib/llvm/include/llvm/IntrinsicInst.h head/contrib/llvm/include/llvm/Intrinsics.td head/contrib/llvm/include/llvm/IntrinsicsX86.td head/contrib/llvm/include/llvm/LLVMContext.h head/contrib/llvm/include/llvm/LinkAllPasses.h head/contrib/llvm/include/llvm/Linker.h head/contrib/llvm/include/llvm/MC/MCAsmBackend.h head/contrib/llvm/include/llvm/MC/MCAsmInfo.h head/contrib/llvm/include/llvm/MC/MCAsmInfoCOFF.h head/contrib/llvm/include/llvm/MC/MCAsmInfoDarwin.h head/contrib/llvm/include/llvm/MC/MCAsmLayout.h head/contrib/llvm/include/llvm/MC/MCAssembler.h head/contrib/llvm/include/llvm/MC/MCCodeEmitter.h head/contrib/llvm/include/llvm/MC/MCCodeGenInfo.h head/contrib/llvm/include/llvm/MC/MCContext.h head/contrib/llvm/include/llvm/MC/MCDisassembler.h head/contrib/llvm/include/llvm/MC/MCDwarf.h head/contrib/llvm/include/llvm/MC/MCELFObjectWriter.h head/contrib/llvm/include/llvm/MC/MCExpr.h head/contrib/llvm/include/llvm/MC/MCFixup.h head/contrib/llvm/include/llvm/MC/MCInst.h head/contrib/llvm/include/llvm/MC/MCInstPrinter.h head/contrib/llvm/include/llvm/MC/MCInstrAnalysis.h head/contrib/llvm/include/llvm/MC/MCInstrDesc.h head/contrib/llvm/include/llvm/MC/MCInstrInfo.h head/contrib/llvm/include/llvm/MC/MCObjectFileInfo.h head/contrib/llvm/include/llvm/MC/MCObjectStreamer.h head/contrib/llvm/include/llvm/MC/MCObjectWriter.h head/contrib/llvm/include/llvm/MC/MCParser/MCAsmLexer.h head/contrib/llvm/include/llvm/MC/MCParser/MCAsmParser.h head/contrib/llvm/include/llvm/MC/MCRegisterInfo.h head/contrib/llvm/include/llvm/MC/MCSection.h head/contrib/llvm/include/llvm/MC/MCSectionCOFF.h head/contrib/llvm/include/llvm/MC/MCSectionELF.h head/contrib/llvm/include/llvm/MC/MCSectionMachO.h head/contrib/llvm/include/llvm/MC/MCStreamer.h head/contrib/llvm/include/llvm/Metadata.h head/contrib/llvm/include/llvm/Module.h head/contrib/llvm/include/llvm/Object/Archive.h head/contrib/llvm/include/llvm/Object/Binary.h head/contrib/llvm/include/llvm/Object/COFF.h head/contrib/llvm/include/llvm/Object/MachO.h head/contrib/llvm/include/llvm/Object/MachOObject.h head/contrib/llvm/include/llvm/Object/ObjectFile.h head/contrib/llvm/include/llvm/Operator.h head/contrib/llvm/include/llvm/Pass.h head/contrib/llvm/include/llvm/PassAnalysisSupport.h head/contrib/llvm/include/llvm/PassManager.h head/contrib/llvm/include/llvm/PassManagers.h head/contrib/llvm/include/llvm/PassSupport.h head/contrib/llvm/include/llvm/Support/BlockFrequency.h head/contrib/llvm/include/llvm/Support/BranchProbability.h head/contrib/llvm/include/llvm/Support/CFG.h head/contrib/llvm/include/llvm/Support/COFF.h head/contrib/llvm/include/llvm/Support/CallSite.h head/contrib/llvm/include/llvm/Support/Capacity.h head/contrib/llvm/include/llvm/Support/CodeGen.h head/contrib/llvm/include/llvm/Support/CommandLine.h head/contrib/llvm/include/llvm/Support/Compiler.h head/contrib/llvm/include/llvm/Support/DOTGraphTraits.h head/contrib/llvm/include/llvm/Support/DataTypes.h.in head/contrib/llvm/include/llvm/Support/Debug.h head/contrib/llvm/include/llvm/Support/Dwarf.h head/contrib/llvm/include/llvm/Support/DynamicLibrary.h head/contrib/llvm/include/llvm/Support/ELF.h head/contrib/llvm/include/llvm/Support/Endian.h head/contrib/llvm/include/llvm/Support/FileSystem.h head/contrib/llvm/include/llvm/Support/GraphWriter.h head/contrib/llvm/include/llvm/Support/Host.h head/contrib/llvm/include/llvm/Support/IRReader.h head/contrib/llvm/include/llvm/Support/InstVisitor.h head/contrib/llvm/include/llvm/Support/MachO.h head/contrib/llvm/include/llvm/Support/ManagedStatic.h head/contrib/llvm/include/llvm/Support/MathExtras.h head/contrib/llvm/include/llvm/Support/MemoryObject.h head/contrib/llvm/include/llvm/Support/PathV1.h head/contrib/llvm/include/llvm/Support/PatternMatch.h head/contrib/llvm/include/llvm/Support/Process.h head/contrib/llvm/include/llvm/Support/Program.h head/contrib/llvm/include/llvm/Support/Recycler.h head/contrib/llvm/include/llvm/Support/SMLoc.h head/contrib/llvm/include/llvm/Support/SourceMgr.h head/contrib/llvm/include/llvm/Support/TargetRegistry.h head/contrib/llvm/include/llvm/Support/TargetSelect.h head/contrib/llvm/include/llvm/Support/Valgrind.h head/contrib/llvm/include/llvm/Support/ValueHandle.h head/contrib/llvm/include/llvm/Support/system_error.h head/contrib/llvm/include/llvm/Support/type_traits.h head/contrib/llvm/include/llvm/TableGen/Record.h head/contrib/llvm/include/llvm/TableGen/TableGenAction.h head/contrib/llvm/include/llvm/TableGen/TableGenBackend.h head/contrib/llvm/include/llvm/Target/Mangler.h head/contrib/llvm/include/llvm/Target/Target.td head/contrib/llvm/include/llvm/Target/TargetCallingConv.h head/contrib/llvm/include/llvm/Target/TargetCallingConv.td head/contrib/llvm/include/llvm/Target/TargetData.h head/contrib/llvm/include/llvm/Target/TargetELFWriterInfo.h head/contrib/llvm/include/llvm/Target/TargetFrameLowering.h head/contrib/llvm/include/llvm/Target/TargetInstrInfo.h head/contrib/llvm/include/llvm/Target/TargetJITInfo.h head/contrib/llvm/include/llvm/Target/TargetLibraryInfo.h head/contrib/llvm/include/llvm/Target/TargetLowering.h head/contrib/llvm/include/llvm/Target/TargetLoweringObjectFile.h head/contrib/llvm/include/llvm/Target/TargetMachine.h head/contrib/llvm/include/llvm/Target/TargetOpcodes.h head/contrib/llvm/include/llvm/Target/TargetOptions.h head/contrib/llvm/include/llvm/Target/TargetRegisterInfo.h head/contrib/llvm/include/llvm/Target/TargetSelectionDAG.td head/contrib/llvm/include/llvm/Target/TargetSubtargetInfo.h head/contrib/llvm/include/llvm/Transforms/IPO.h head/contrib/llvm/include/llvm/Transforms/IPO/InlinerPass.h head/contrib/llvm/include/llvm/Transforms/IPO/PassManagerBuilder.h head/contrib/llvm/include/llvm/Transforms/Instrumentation.h head/contrib/llvm/include/llvm/Transforms/Scalar.h head/contrib/llvm/include/llvm/Transforms/Utils/BasicBlockUtils.h head/contrib/llvm/include/llvm/Transforms/Utils/BuildLibCalls.h head/contrib/llvm/include/llvm/Transforms/Utils/Cloning.h head/contrib/llvm/include/llvm/Transforms/Utils/SSAUpdater.h head/contrib/llvm/include/llvm/Transforms/Utils/SSAUpdaterImpl.h head/contrib/llvm/include/llvm/Transforms/Utils/SimplifyIndVar.h head/contrib/llvm/include/llvm/Transforms/Utils/UnrollLoop.h head/contrib/llvm/include/llvm/Transforms/Utils/ValueMapper.h head/contrib/llvm/include/llvm/Type.h head/contrib/llvm/include/llvm/User.h head/contrib/llvm/include/llvm/Value.h head/contrib/llvm/lib/Analysis/AliasAnalysis.cpp head/contrib/llvm/lib/Analysis/AliasAnalysisCounter.cpp head/contrib/llvm/lib/Analysis/AliasAnalysisEvaluator.cpp head/contrib/llvm/lib/Analysis/AliasSetTracker.cpp head/contrib/llvm/lib/Analysis/BasicAliasAnalysis.cpp head/contrib/llvm/lib/Analysis/BlockFrequencyInfo.cpp head/contrib/llvm/lib/Analysis/BranchProbabilityInfo.cpp head/contrib/llvm/lib/Analysis/CFGPrinter.cpp head/contrib/llvm/lib/Analysis/CaptureTracking.cpp head/contrib/llvm/lib/Analysis/ConstantFolding.cpp head/contrib/llvm/lib/Analysis/DIBuilder.cpp head/contrib/llvm/lib/Analysis/DebugInfo.cpp head/contrib/llvm/lib/Analysis/DominanceFrontier.cpp head/contrib/llvm/lib/Analysis/IPA/CallGraph.cpp head/contrib/llvm/lib/Analysis/IPA/GlobalsModRef.cpp head/contrib/llvm/lib/Analysis/IVUsers.cpp head/contrib/llvm/lib/Analysis/InlineCost.cpp head/contrib/llvm/lib/Analysis/InstructionSimplify.cpp head/contrib/llvm/lib/Analysis/LazyValueInfo.cpp head/contrib/llvm/lib/Analysis/Lint.cpp head/contrib/llvm/lib/Analysis/Loads.cpp head/contrib/llvm/lib/Analysis/LoopDependenceAnalysis.cpp head/contrib/llvm/lib/Analysis/LoopInfo.cpp head/contrib/llvm/lib/Analysis/LoopPass.cpp head/contrib/llvm/lib/Analysis/MemDepPrinter.cpp head/contrib/llvm/lib/Analysis/MemoryBuiltins.cpp head/contrib/llvm/lib/Analysis/MemoryDependenceAnalysis.cpp head/contrib/llvm/lib/Analysis/PHITransAddr.cpp head/contrib/llvm/lib/Analysis/PathNumbering.cpp head/contrib/llvm/lib/Analysis/PathProfileVerifier.cpp head/contrib/llvm/lib/Analysis/ProfileEstimatorPass.cpp head/contrib/llvm/lib/Analysis/ProfileInfoLoaderPass.cpp head/contrib/llvm/lib/Analysis/ProfileVerifierPass.cpp head/contrib/llvm/lib/Analysis/RegionInfo.cpp head/contrib/llvm/lib/Analysis/ScalarEvolution.cpp head/contrib/llvm/lib/Analysis/ScalarEvolutionExpander.cpp head/contrib/llvm/lib/Analysis/ScalarEvolutionNormalization.cpp head/contrib/llvm/lib/Analysis/SparsePropagation.cpp head/contrib/llvm/lib/Analysis/Trace.cpp head/contrib/llvm/lib/Analysis/ValueTracking.cpp head/contrib/llvm/lib/Archive/ArchiveReader.cpp head/contrib/llvm/lib/Archive/ArchiveWriter.cpp head/contrib/llvm/lib/AsmParser/LLLexer.cpp head/contrib/llvm/lib/AsmParser/LLLexer.h head/contrib/llvm/lib/AsmParser/LLParser.cpp head/contrib/llvm/lib/AsmParser/LLParser.h head/contrib/llvm/lib/AsmParser/LLToken.h head/contrib/llvm/lib/AsmParser/Parser.cpp head/contrib/llvm/lib/Bitcode/Reader/BitcodeReader.cpp head/contrib/llvm/lib/Bitcode/Reader/BitcodeReader.h head/contrib/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp head/contrib/llvm/lib/Bitcode/Writer/ValueEnumerator.cpp head/contrib/llvm/lib/Bitcode/Writer/ValueEnumerator.h head/contrib/llvm/lib/CodeGen/AggressiveAntiDepBreaker.cpp head/contrib/llvm/lib/CodeGen/AllocationOrder.cpp head/contrib/llvm/lib/CodeGen/AllocationOrder.h head/contrib/llvm/lib/CodeGen/Analysis.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/ARMException.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/DIE.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/DIE.h head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCFIException.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.h head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfException.cpp head/contrib/llvm/lib/CodeGen/BranchFolding.cpp head/contrib/llvm/lib/CodeGen/CallingConvLower.cpp head/contrib/llvm/lib/CodeGen/CodeGen.cpp head/contrib/llvm/lib/CodeGen/CodePlacementOpt.cpp head/contrib/llvm/lib/CodeGen/CriticalAntiDepBreaker.cpp head/contrib/llvm/lib/CodeGen/CriticalAntiDepBreaker.h head/contrib/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp head/contrib/llvm/lib/CodeGen/DwarfEHPrepare.cpp head/contrib/llvm/lib/CodeGen/EdgeBundles.cpp head/contrib/llvm/lib/CodeGen/ExecutionDepsFix.cpp head/contrib/llvm/lib/CodeGen/ExpandISelPseudos.cpp head/contrib/llvm/lib/CodeGen/ExpandPostRAPseudos.cpp head/contrib/llvm/lib/CodeGen/GCMetadata.cpp head/contrib/llvm/lib/CodeGen/GCStrategy.cpp head/contrib/llvm/lib/CodeGen/IfConversion.cpp head/contrib/llvm/lib/CodeGen/InlineSpiller.cpp head/contrib/llvm/lib/CodeGen/InterferenceCache.cpp head/contrib/llvm/lib/CodeGen/InterferenceCache.h head/contrib/llvm/lib/CodeGen/IntrinsicLowering.cpp head/contrib/llvm/lib/CodeGen/LLVMTargetMachine.cpp head/contrib/llvm/lib/CodeGen/LatencyPriorityQueue.cpp head/contrib/llvm/lib/CodeGen/LexicalScopes.cpp head/contrib/llvm/lib/CodeGen/LiveDebugVariables.cpp head/contrib/llvm/lib/CodeGen/LiveInterval.cpp head/contrib/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp head/contrib/llvm/lib/CodeGen/LiveIntervalUnion.cpp head/contrib/llvm/lib/CodeGen/LiveIntervalUnion.h head/contrib/llvm/lib/CodeGen/LiveRangeCalc.cpp head/contrib/llvm/lib/CodeGen/LiveRangeEdit.cpp head/contrib/llvm/lib/CodeGen/LiveVariables.cpp head/contrib/llvm/lib/CodeGen/LocalStackSlotAllocation.cpp head/contrib/llvm/lib/CodeGen/MachineBasicBlock.cpp head/contrib/llvm/lib/CodeGen/MachineBlockFrequencyInfo.cpp head/contrib/llvm/lib/CodeGen/MachineBranchProbabilityInfo.cpp head/contrib/llvm/lib/CodeGen/MachineCSE.cpp head/contrib/llvm/lib/CodeGen/MachineFunction.cpp head/contrib/llvm/lib/CodeGen/MachineFunctionAnalysis.cpp head/contrib/llvm/lib/CodeGen/MachineInstr.cpp head/contrib/llvm/lib/CodeGen/MachineLICM.cpp head/contrib/llvm/lib/CodeGen/MachineModuleInfo.cpp head/contrib/llvm/lib/CodeGen/MachinePassRegistry.cpp head/contrib/llvm/lib/CodeGen/MachineRegisterInfo.cpp head/contrib/llvm/lib/CodeGen/MachineSSAUpdater.cpp head/contrib/llvm/lib/CodeGen/MachineSink.cpp head/contrib/llvm/lib/CodeGen/MachineVerifier.cpp head/contrib/llvm/lib/CodeGen/OptimizePHIs.cpp head/contrib/llvm/lib/CodeGen/PHIElimination.cpp head/contrib/llvm/lib/CodeGen/Passes.cpp head/contrib/llvm/lib/CodeGen/PeepholeOptimizer.cpp head/contrib/llvm/lib/CodeGen/PostRASchedulerList.cpp head/contrib/llvm/lib/CodeGen/ProcessImplicitDefs.cpp head/contrib/llvm/lib/CodeGen/PrologEpilogInserter.cpp head/contrib/llvm/lib/CodeGen/PrologEpilogInserter.h head/contrib/llvm/lib/CodeGen/PseudoSourceValue.cpp head/contrib/llvm/lib/CodeGen/RegAllocBase.h head/contrib/llvm/lib/CodeGen/RegAllocBasic.cpp head/contrib/llvm/lib/CodeGen/RegAllocFast.cpp head/contrib/llvm/lib/CodeGen/RegAllocGreedy.cpp head/contrib/llvm/lib/CodeGen/RegAllocPBQP.cpp head/contrib/llvm/lib/CodeGen/RegisterClassInfo.cpp head/contrib/llvm/lib/CodeGen/RegisterClassInfo.h head/contrib/llvm/lib/CodeGen/RegisterCoalescer.cpp head/contrib/llvm/lib/CodeGen/RegisterCoalescer.h head/contrib/llvm/lib/CodeGen/RegisterScavenging.cpp head/contrib/llvm/lib/CodeGen/RenderMachineFunction.cpp head/contrib/llvm/lib/CodeGen/ScheduleDAG.cpp head/contrib/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp head/contrib/llvm/lib/CodeGen/ScheduleDAGPrinter.cpp head/contrib/llvm/lib/CodeGen/ScoreboardHazardRecognizer.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypesGeneric.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.h head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp head/contrib/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp head/contrib/llvm/lib/CodeGen/ShadowStackGC.cpp head/contrib/llvm/lib/CodeGen/ShrinkWrapping.cpp head/contrib/llvm/lib/CodeGen/SjLjEHPrepare.cpp head/contrib/llvm/lib/CodeGen/SlotIndexes.cpp head/contrib/llvm/lib/CodeGen/Spiller.cpp head/contrib/llvm/lib/CodeGen/Spiller.h head/contrib/llvm/lib/CodeGen/SplitKit.cpp head/contrib/llvm/lib/CodeGen/SplitKit.h head/contrib/llvm/lib/CodeGen/StackProtector.cpp head/contrib/llvm/lib/CodeGen/StackSlotColoring.cpp head/contrib/llvm/lib/CodeGen/StrongPHIElimination.cpp head/contrib/llvm/lib/CodeGen/TailDuplication.cpp head/contrib/llvm/lib/CodeGen/TargetInstrInfoImpl.cpp head/contrib/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp head/contrib/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp head/contrib/llvm/lib/CodeGen/VirtRegMap.cpp head/contrib/llvm/lib/CodeGen/VirtRegMap.h head/contrib/llvm/lib/DebugInfo/DWARFContext.cpp head/contrib/llvm/lib/DebugInfo/DWARFContext.h head/contrib/llvm/lib/DebugInfo/DWARFDebugAbbrev.cpp head/contrib/llvm/lib/DebugInfo/DWARFDebugAbbrev.h head/contrib/llvm/lib/DebugInfo/DWARFDebugArangeSet.cpp head/contrib/llvm/lib/DebugInfo/DWARFDebugAranges.cpp head/contrib/llvm/lib/DebugInfo/DWARFDebugInfoEntry.cpp head/contrib/llvm/lib/DebugInfo/DWARFDebugInfoEntry.h head/contrib/llvm/lib/DebugInfo/DWARFDebugLine.cpp head/contrib/llvm/lib/DebugInfo/DWARFFormValue.cpp head/contrib/llvm/lib/ExecutionEngine/ExecutionEngine.cpp head/contrib/llvm/lib/ExecutionEngine/ExecutionEngineBindings.cpp head/contrib/llvm/lib/ExecutionEngine/Interpreter/Execution.cpp head/contrib/llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp head/contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.h head/contrib/llvm/lib/ExecutionEngine/JIT/JIT.cpp head/contrib/llvm/lib/ExecutionEngine/JIT/JIT.h head/contrib/llvm/lib/ExecutionEngine/JIT/JITDwarfEmitter.cpp head/contrib/llvm/lib/ExecutionEngine/JIT/JITEmitter.cpp head/contrib/llvm/lib/ExecutionEngine/JIT/JITMemoryManager.cpp head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJIT.h head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJITMemoryManager.h head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp head/contrib/llvm/lib/ExecutionEngine/TargetSelect.cpp head/contrib/llvm/lib/Linker/LinkArchives.cpp head/contrib/llvm/lib/Linker/LinkModules.cpp head/contrib/llvm/lib/Linker/Linker.cpp head/contrib/llvm/lib/MC/ELFObjectWriter.cpp head/contrib/llvm/lib/MC/MCAsmBackend.cpp head/contrib/llvm/lib/MC/MCAsmInfo.cpp head/contrib/llvm/lib/MC/MCAsmInfoCOFF.cpp head/contrib/llvm/lib/MC/MCAsmInfoDarwin.cpp head/contrib/llvm/lib/MC/MCAsmStreamer.cpp head/contrib/llvm/lib/MC/MCAssembler.cpp head/contrib/llvm/lib/MC/MCCodeGenInfo.cpp head/contrib/llvm/lib/MC/MCContext.cpp head/contrib/llvm/lib/MC/MCDisassembler/Disassembler.cpp head/contrib/llvm/lib/MC/MCDisassembler/Disassembler.h head/contrib/llvm/lib/MC/MCDisassembler/EDDisassembler.cpp head/contrib/llvm/lib/MC/MCDisassembler/EDDisassembler.h head/contrib/llvm/lib/MC/MCDisassembler/EDOperand.cpp head/contrib/llvm/lib/MC/MCDwarf.cpp head/contrib/llvm/lib/MC/MCELF.cpp head/contrib/llvm/lib/MC/MCELFObjectTargetWriter.cpp head/contrib/llvm/lib/MC/MCELFStreamer.cpp head/contrib/llvm/lib/MC/MCExpr.cpp head/contrib/llvm/lib/MC/MCInst.cpp head/contrib/llvm/lib/MC/MCInstPrinter.cpp head/contrib/llvm/lib/MC/MCMachOStreamer.cpp head/contrib/llvm/lib/MC/MCModule.cpp head/contrib/llvm/lib/MC/MCNullStreamer.cpp head/contrib/llvm/lib/MC/MCObjectFileInfo.cpp head/contrib/llvm/lib/MC/MCObjectStreamer.cpp head/contrib/llvm/lib/MC/MCObjectWriter.cpp head/contrib/llvm/lib/MC/MCParser/AsmParser.cpp head/contrib/llvm/lib/MC/MCParser/COFFAsmParser.cpp head/contrib/llvm/lib/MC/MCParser/ELFAsmParser.cpp head/contrib/llvm/lib/MC/MCParser/MCAsmLexer.cpp head/contrib/llvm/lib/MC/MCParser/MCAsmParser.cpp head/contrib/llvm/lib/MC/MCPureStreamer.cpp head/contrib/llvm/lib/MC/MCStreamer.cpp head/contrib/llvm/lib/MC/MCSymbol.cpp head/contrib/llvm/lib/MC/MachObjectWriter.cpp head/contrib/llvm/lib/MC/SubtargetFeature.cpp head/contrib/llvm/lib/MC/WinCOFFObjectWriter.cpp head/contrib/llvm/lib/MC/WinCOFFStreamer.cpp head/contrib/llvm/lib/Object/Archive.cpp head/contrib/llvm/lib/Object/COFFObjectFile.cpp head/contrib/llvm/lib/Object/ELFObjectFile.cpp head/contrib/llvm/lib/Object/MachOObject.cpp head/contrib/llvm/lib/Object/MachOObjectFile.cpp head/contrib/llvm/lib/Object/Object.cpp head/contrib/llvm/lib/Object/ObjectFile.cpp head/contrib/llvm/lib/Support/APFloat.cpp head/contrib/llvm/lib/Support/APInt.cpp head/contrib/llvm/lib/Support/Allocator.cpp head/contrib/llvm/lib/Support/Atomic.cpp head/contrib/llvm/lib/Support/BlockFrequency.cpp head/contrib/llvm/lib/Support/BranchProbability.cpp head/contrib/llvm/lib/Support/CommandLine.cpp head/contrib/llvm/lib/Support/ConstantRange.cpp head/contrib/llvm/lib/Support/CrashRecoveryContext.cpp head/contrib/llvm/lib/Support/DAGDeltaAlgorithm.cpp head/contrib/llvm/lib/Support/DataExtractor.cpp head/contrib/llvm/lib/Support/Dwarf.cpp head/contrib/llvm/lib/Support/FileUtilities.cpp head/contrib/llvm/lib/Support/FoldingSet.cpp head/contrib/llvm/lib/Support/GraphWriter.cpp head/contrib/llvm/lib/Support/Host.cpp head/contrib/llvm/lib/Support/ManagedStatic.cpp head/contrib/llvm/lib/Support/MemoryBuffer.cpp head/contrib/llvm/lib/Support/Mutex.cpp head/contrib/llvm/lib/Support/Path.cpp head/contrib/llvm/lib/Support/PathV2.cpp head/contrib/llvm/lib/Support/Program.cpp head/contrib/llvm/lib/Support/RWMutex.cpp head/contrib/llvm/lib/Support/SmallPtrSet.cpp head/contrib/llvm/lib/Support/SourceMgr.cpp head/contrib/llvm/lib/Support/Statistic.cpp head/contrib/llvm/lib/Support/StringExtras.cpp head/contrib/llvm/lib/Support/StringMap.cpp head/contrib/llvm/lib/Support/StringRef.cpp head/contrib/llvm/lib/Support/TargetRegistry.cpp head/contrib/llvm/lib/Support/ThreadLocal.cpp head/contrib/llvm/lib/Support/Threading.cpp head/contrib/llvm/lib/Support/Timer.cpp head/contrib/llvm/lib/Support/Triple.cpp head/contrib/llvm/lib/Support/Unix/Host.inc head/contrib/llvm/lib/Support/Unix/Path.inc head/contrib/llvm/lib/Support/Unix/PathV2.inc head/contrib/llvm/lib/Support/Unix/Process.inc head/contrib/llvm/lib/Support/Unix/Program.inc head/contrib/llvm/lib/Support/Unix/Signals.inc head/contrib/llvm/lib/Support/Valgrind.cpp head/contrib/llvm/lib/Support/Windows/Host.inc head/contrib/llvm/lib/Support/Windows/Path.inc head/contrib/llvm/lib/Support/Windows/PathV2.inc head/contrib/llvm/lib/Support/Windows/Process.inc head/contrib/llvm/lib/Support/Windows/Program.inc head/contrib/llvm/lib/Support/Windows/Signals.inc head/contrib/llvm/lib/Support/Windows/Windows.h head/contrib/llvm/lib/Support/raw_ostream.cpp head/contrib/llvm/lib/TableGen/Error.cpp head/contrib/llvm/lib/TableGen/Record.cpp head/contrib/llvm/lib/TableGen/TGLexer.cpp head/contrib/llvm/lib/TableGen/TGLexer.h head/contrib/llvm/lib/TableGen/TGParser.cpp head/contrib/llvm/lib/TableGen/TGParser.h head/contrib/llvm/lib/TableGen/TableGenBackend.cpp head/contrib/llvm/lib/Target/ARM/ARM.h head/contrib/llvm/lib/Target/ARM/ARM.td head/contrib/llvm/lib/Target/ARM/ARMAsmPrinter.cpp head/contrib/llvm/lib/Target/ARM/ARMAsmPrinter.h head/contrib/llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp head/contrib/llvm/lib/Target/ARM/ARMBaseInstrInfo.h head/contrib/llvm/lib/Target/ARM/ARMBaseRegisterInfo.cpp head/contrib/llvm/lib/Target/ARM/ARMBaseRegisterInfo.h head/contrib/llvm/lib/Target/ARM/ARMBuildAttrs.h head/contrib/llvm/lib/Target/ARM/ARMCallingConv.h head/contrib/llvm/lib/Target/ARM/ARMCallingConv.td head/contrib/llvm/lib/Target/ARM/ARMCodeEmitter.cpp head/contrib/llvm/lib/Target/ARM/ARMConstantIslandPass.cpp head/contrib/llvm/lib/Target/ARM/ARMConstantPoolValue.cpp head/contrib/llvm/lib/Target/ARM/ARMConstantPoolValue.h head/contrib/llvm/lib/Target/ARM/ARMELFWriterInfo.cpp head/contrib/llvm/lib/Target/ARM/ARMELFWriterInfo.h head/contrib/llvm/lib/Target/ARM/ARMExpandPseudoInsts.cpp head/contrib/llvm/lib/Target/ARM/ARMFastISel.cpp head/contrib/llvm/lib/Target/ARM/ARMFrameLowering.cpp head/contrib/llvm/lib/Target/ARM/ARMFrameLowering.h head/contrib/llvm/lib/Target/ARM/ARMHazardRecognizer.cpp head/contrib/llvm/lib/Target/ARM/ARMHazardRecognizer.h head/contrib/llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp head/contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp head/contrib/llvm/lib/Target/ARM/ARMISelLowering.h head/contrib/llvm/lib/Target/ARM/ARMInstrFormats.td head/contrib/llvm/lib/Target/ARM/ARMInstrInfo.cpp head/contrib/llvm/lib/Target/ARM/ARMInstrInfo.h head/contrib/llvm/lib/Target/ARM/ARMInstrInfo.td head/contrib/llvm/lib/Target/ARM/ARMInstrNEON.td head/contrib/llvm/lib/Target/ARM/ARMInstrThumb.td head/contrib/llvm/lib/Target/ARM/ARMInstrThumb2.td head/contrib/llvm/lib/Target/ARM/ARMInstrVFP.td head/contrib/llvm/lib/Target/ARM/ARMJITInfo.cpp head/contrib/llvm/lib/Target/ARM/ARMJITInfo.h head/contrib/llvm/lib/Target/ARM/ARMLoadStoreOptimizer.cpp head/contrib/llvm/lib/Target/ARM/ARMMCInstLower.cpp head/contrib/llvm/lib/Target/ARM/ARMMachineFunctionInfo.h head/contrib/llvm/lib/Target/ARM/ARMPerfectShuffle.h head/contrib/llvm/lib/Target/ARM/ARMRegisterInfo.cpp head/contrib/llvm/lib/Target/ARM/ARMRegisterInfo.h head/contrib/llvm/lib/Target/ARM/ARMRegisterInfo.td head/contrib/llvm/lib/Target/ARM/ARMRelocations.h head/contrib/llvm/lib/Target/ARM/ARMSchedule.td head/contrib/llvm/lib/Target/ARM/ARMScheduleA8.td head/contrib/llvm/lib/Target/ARM/ARMScheduleA9.td head/contrib/llvm/lib/Target/ARM/ARMScheduleV6.td head/contrib/llvm/lib/Target/ARM/ARMSelectionDAGInfo.cpp head/contrib/llvm/lib/Target/ARM/ARMSubtarget.cpp head/contrib/llvm/lib/Target/ARM/ARMSubtarget.h head/contrib/llvm/lib/Target/ARM/ARMTargetMachine.cpp head/contrib/llvm/lib/Target/ARM/ARMTargetMachine.h head/contrib/llvm/lib/Target/ARM/ARMTargetObjectFile.cpp head/contrib/llvm/lib/Target/ARM/ARMTargetObjectFile.h head/contrib/llvm/lib/Target/ARM/AsmParser/ARMAsmLexer.cpp head/contrib/llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp head/contrib/llvm/lib/Target/ARM/Disassembler/ARMDisassembler.cpp head/contrib/llvm/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp head/contrib/llvm/lib/Target/ARM/InstPrinter/ARMInstPrinter.h head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAddressingModes.h head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackend.cpp head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMBaseInfo.h head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMFixupKinds.h head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.h head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCCodeEmitter.cpp head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCExpr.cpp head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCExpr.h head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.h head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMachObjectWriter.cpp head/contrib/llvm/lib/Target/ARM/MLxExpansionPass.cpp head/contrib/llvm/lib/Target/ARM/Thumb1FrameLowering.cpp head/contrib/llvm/lib/Target/ARM/Thumb1InstrInfo.cpp head/contrib/llvm/lib/Target/ARM/Thumb1InstrInfo.h head/contrib/llvm/lib/Target/ARM/Thumb1RegisterInfo.cpp head/contrib/llvm/lib/Target/ARM/Thumb1RegisterInfo.h head/contrib/llvm/lib/Target/ARM/Thumb2ITBlockPass.cpp head/contrib/llvm/lib/Target/ARM/Thumb2InstrInfo.cpp head/contrib/llvm/lib/Target/ARM/Thumb2InstrInfo.h head/contrib/llvm/lib/Target/ARM/Thumb2RegisterInfo.cpp head/contrib/llvm/lib/Target/ARM/Thumb2RegisterInfo.h head/contrib/llvm/lib/Target/ARM/Thumb2SizeReduction.cpp head/contrib/llvm/lib/Target/CellSPU/CellSDKIntrinsics.td head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCAsmInfo.cpp head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCAsmInfo.h head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCTargetDesc.cpp head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCTargetDesc.h head/contrib/llvm/lib/Target/CellSPU/SPU.h head/contrib/llvm/lib/Target/CellSPU/SPU.td head/contrib/llvm/lib/Target/CellSPU/SPU128InstrInfo.td head/contrib/llvm/lib/Target/CellSPU/SPU64InstrInfo.td head/contrib/llvm/lib/Target/CellSPU/SPUAsmPrinter.cpp head/contrib/llvm/lib/Target/CellSPU/SPUCallingConv.td head/contrib/llvm/lib/Target/CellSPU/SPUFrameLowering.cpp head/contrib/llvm/lib/Target/CellSPU/SPUFrameLowering.h head/contrib/llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp head/contrib/llvm/lib/Target/CellSPU/SPUISelLowering.cpp head/contrib/llvm/lib/Target/CellSPU/SPUISelLowering.h head/contrib/llvm/lib/Target/CellSPU/SPUInstrBuilder.h head/contrib/llvm/lib/Target/CellSPU/SPUInstrFormats.td head/contrib/llvm/lib/Target/CellSPU/SPUInstrInfo.cpp head/contrib/llvm/lib/Target/CellSPU/SPUInstrInfo.h head/contrib/llvm/lib/Target/CellSPU/SPUMachineFunction.h head/contrib/llvm/lib/Target/CellSPU/SPUMathInstr.td head/contrib/llvm/lib/Target/CellSPU/SPUNodes.td head/contrib/llvm/lib/Target/CellSPU/SPUNopFiller.cpp head/contrib/llvm/lib/Target/CellSPU/SPUOperands.td head/contrib/llvm/lib/Target/CellSPU/SPURegisterInfo.cpp head/contrib/llvm/lib/Target/CellSPU/SPURegisterInfo.h head/contrib/llvm/lib/Target/CellSPU/SPURegisterInfo.td head/contrib/llvm/lib/Target/CellSPU/SPUSchedule.td head/contrib/llvm/lib/Target/CellSPU/SPUSubtarget.cpp head/contrib/llvm/lib/Target/CellSPU/SPUTargetMachine.cpp head/contrib/llvm/lib/Target/CellSPU/SPUTargetMachine.h head/contrib/llvm/lib/Target/CppBackend/CPPBackend.cpp head/contrib/llvm/lib/Target/CppBackend/CPPTargetMachine.h head/contrib/llvm/lib/Target/MBlaze/AsmParser/MBlazeAsmLexer.cpp head/contrib/llvm/lib/Target/MBlaze/AsmParser/MBlazeAsmParser.cpp head/contrib/llvm/lib/Target/MBlaze/Disassembler/MBlazeDisassembler.cpp head/contrib/llvm/lib/Target/MBlaze/Disassembler/MBlazeDisassembler.h head/contrib/llvm/lib/Target/MBlaze/InstPrinter/MBlazeInstPrinter.h head/contrib/llvm/lib/Target/MBlaze/MBlaze.td head/contrib/llvm/lib/Target/MBlaze/MBlazeAsmPrinter.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeDelaySlotFiller.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeELFWriterInfo.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeELFWriterInfo.h head/contrib/llvm/lib/Target/MBlaze/MBlazeFrameLowering.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeFrameLowering.h head/contrib/llvm/lib/Target/MBlaze/MBlazeISelLowering.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeISelLowering.h head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrFPU.td head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrFSL.td head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrFormats.td head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrInfo.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrInfo.h head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrInfo.td head/contrib/llvm/lib/Target/MBlaze/MBlazeIntrinsicInfo.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeIntrinsicInfo.h head/contrib/llvm/lib/Target/MBlaze/MBlazeIntrinsics.td head/contrib/llvm/lib/Target/MBlaze/MBlazeMCInstLower.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeMCInstLower.h head/contrib/llvm/lib/Target/MBlaze/MBlazeMachineFunction.h head/contrib/llvm/lib/Target/MBlaze/MBlazeRegisterInfo.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeRegisterInfo.h head/contrib/llvm/lib/Target/MBlaze/MBlazeRegisterInfo.td head/contrib/llvm/lib/Target/MBlaze/MBlazeRelocations.h head/contrib/llvm/lib/Target/MBlaze/MBlazeSchedule.td head/contrib/llvm/lib/Target/MBlaze/MBlazeSchedule3.td head/contrib/llvm/lib/Target/MBlaze/MBlazeSchedule5.td head/contrib/llvm/lib/Target/MBlaze/MBlazeSubtarget.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeSubtarget.h head/contrib/llvm/lib/Target/MBlaze/MBlazeTargetMachine.cpp head/contrib/llvm/lib/Target/MBlaze/MBlazeTargetMachine.h head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeAsmBackend.cpp head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeBaseInfo.h head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCAsmInfo.cpp head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCAsmInfo.h head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCCodeEmitter.cpp head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCTargetDesc.cpp head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCTargetDesc.h head/contrib/llvm/lib/Target/MSP430/InstPrinter/MSP430InstPrinter.cpp head/contrib/llvm/lib/Target/MSP430/InstPrinter/MSP430InstPrinter.h head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCAsmInfo.cpp head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCAsmInfo.h head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCTargetDesc.cpp head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCTargetDesc.h head/contrib/llvm/lib/Target/MSP430/MSP430.td head/contrib/llvm/lib/Target/MSP430/MSP430AsmPrinter.cpp head/contrib/llvm/lib/Target/MSP430/MSP430BranchSelector.cpp head/contrib/llvm/lib/Target/MSP430/MSP430FrameLowering.cpp head/contrib/llvm/lib/Target/MSP430/MSP430ISelLowering.cpp head/contrib/llvm/lib/Target/MSP430/MSP430ISelLowering.h head/contrib/llvm/lib/Target/MSP430/MSP430InstrFormats.td head/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.cpp head/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.h head/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.td head/contrib/llvm/lib/Target/MSP430/MSP430MCInstLower.cpp head/contrib/llvm/lib/Target/MSP430/MSP430MCInstLower.h head/contrib/llvm/lib/Target/MSP430/MSP430MachineFunctionInfo.h head/contrib/llvm/lib/Target/MSP430/MSP430RegisterInfo.cpp head/contrib/llvm/lib/Target/MSP430/MSP430RegisterInfo.h head/contrib/llvm/lib/Target/MSP430/MSP430RegisterInfo.td head/contrib/llvm/lib/Target/MSP430/MSP430Subtarget.cpp head/contrib/llvm/lib/Target/MSP430/MSP430Subtarget.h head/contrib/llvm/lib/Target/MSP430/MSP430TargetMachine.cpp head/contrib/llvm/lib/Target/MSP430/MSP430TargetMachine.h head/contrib/llvm/lib/Target/Mangler.cpp head/contrib/llvm/lib/Target/Mips/InstPrinter/MipsInstPrinter.cpp head/contrib/llvm/lib/Target/Mips/InstPrinter/MipsInstPrinter.h head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsBaseInfo.h head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsFixupKinds.h head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCAsmInfo.cpp head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCAsmInfo.h head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCCodeEmitter.cpp head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCTargetDesc.cpp head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCTargetDesc.h head/contrib/llvm/lib/Target/Mips/Mips.h head/contrib/llvm/lib/Target/Mips/Mips.td head/contrib/llvm/lib/Target/Mips/Mips64InstrInfo.td head/contrib/llvm/lib/Target/Mips/MipsAsmPrinter.cpp head/contrib/llvm/lib/Target/Mips/MipsAsmPrinter.h head/contrib/llvm/lib/Target/Mips/MipsCallingConv.td head/contrib/llvm/lib/Target/Mips/MipsCodeEmitter.cpp head/contrib/llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp head/contrib/llvm/lib/Target/Mips/MipsEmitGPRestore.cpp head/contrib/llvm/lib/Target/Mips/MipsExpandPseudo.cpp head/contrib/llvm/lib/Target/Mips/MipsFrameLowering.cpp head/contrib/llvm/lib/Target/Mips/MipsFrameLowering.h head/contrib/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp head/contrib/llvm/lib/Target/Mips/MipsISelLowering.cpp head/contrib/llvm/lib/Target/Mips/MipsISelLowering.h head/contrib/llvm/lib/Target/Mips/MipsInstrFPU.td head/contrib/llvm/lib/Target/Mips/MipsInstrFormats.td head/contrib/llvm/lib/Target/Mips/MipsInstrInfo.cpp head/contrib/llvm/lib/Target/Mips/MipsInstrInfo.h head/contrib/llvm/lib/Target/Mips/MipsInstrInfo.td head/contrib/llvm/lib/Target/Mips/MipsJITInfo.cpp head/contrib/llvm/lib/Target/Mips/MipsJITInfo.h head/contrib/llvm/lib/Target/Mips/MipsMCInstLower.cpp head/contrib/llvm/lib/Target/Mips/MipsMCInstLower.h head/contrib/llvm/lib/Target/Mips/MipsMachineFunction.h head/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.cpp head/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.h head/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.td head/contrib/llvm/lib/Target/Mips/MipsRelocations.h head/contrib/llvm/lib/Target/Mips/MipsSchedule.td head/contrib/llvm/lib/Target/Mips/MipsSubtarget.cpp head/contrib/llvm/lib/Target/Mips/MipsSubtarget.h head/contrib/llvm/lib/Target/Mips/MipsTargetMachine.cpp head/contrib/llvm/lib/Target/Mips/MipsTargetMachine.h head/contrib/llvm/lib/Target/Mips/MipsTargetObjectFile.cpp head/contrib/llvm/lib/Target/PTX/InstPrinter/PTXInstPrinter.cpp head/contrib/llvm/lib/Target/PTX/InstPrinter/PTXInstPrinter.h head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXBaseInfo.h head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCAsmInfo.cpp head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCAsmInfo.h head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCTargetDesc.cpp head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCTargetDesc.h head/contrib/llvm/lib/Target/PTX/PTX.h head/contrib/llvm/lib/Target/PTX/PTX.td head/contrib/llvm/lib/Target/PTX/PTXAsmPrinter.cpp head/contrib/llvm/lib/Target/PTX/PTXAsmPrinter.h head/contrib/llvm/lib/Target/PTX/PTXFPRoundingModePass.cpp head/contrib/llvm/lib/Target/PTX/PTXFrameLowering.cpp head/contrib/llvm/lib/Target/PTX/PTXFrameLowering.h head/contrib/llvm/lib/Target/PTX/PTXISelLowering.cpp head/contrib/llvm/lib/Target/PTX/PTXISelLowering.h head/contrib/llvm/lib/Target/PTX/PTXInstrFormats.td head/contrib/llvm/lib/Target/PTX/PTXInstrInfo.cpp head/contrib/llvm/lib/Target/PTX/PTXInstrInfo.h head/contrib/llvm/lib/Target/PTX/PTXInstrInfo.td head/contrib/llvm/lib/Target/PTX/PTXInstrLoadStore.td head/contrib/llvm/lib/Target/PTX/PTXIntrinsicInstrInfo.td head/contrib/llvm/lib/Target/PTX/PTXMCAsmStreamer.cpp head/contrib/llvm/lib/Target/PTX/PTXMFInfoExtract.cpp head/contrib/llvm/lib/Target/PTX/PTXMachineFunctionInfo.h head/contrib/llvm/lib/Target/PTX/PTXParamManager.cpp head/contrib/llvm/lib/Target/PTX/PTXParamManager.h head/contrib/llvm/lib/Target/PTX/PTXRegAlloc.cpp head/contrib/llvm/lib/Target/PTX/PTXRegisterInfo.cpp head/contrib/llvm/lib/Target/PTX/PTXRegisterInfo.h head/contrib/llvm/lib/Target/PTX/PTXRegisterInfo.td head/contrib/llvm/lib/Target/PTX/PTXSelectionDAGInfo.cpp head/contrib/llvm/lib/Target/PTX/PTXSubtarget.cpp head/contrib/llvm/lib/Target/PTX/PTXSubtarget.h head/contrib/llvm/lib/Target/PTX/PTXTargetMachine.cpp head/contrib/llvm/lib/Target/PTX/PTXTargetMachine.h head/contrib/llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp head/contrib/llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.h head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCAsmBackend.cpp head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCBaseInfo.h head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCAsmInfo.cpp head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCAsmInfo.h head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCCodeEmitter.cpp head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCTargetDesc.cpp head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCTargetDesc.h head/contrib/llvm/lib/Target/PowerPC/PPC.h head/contrib/llvm/lib/Target/PowerPC/PPC.td head/contrib/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp head/contrib/llvm/lib/Target/PowerPC/PPCBranchSelector.cpp head/contrib/llvm/lib/Target/PowerPC/PPCCallingConv.td head/contrib/llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.h head/contrib/llvm/lib/Target/PowerPC/PPCHazardRecognizers.cpp head/contrib/llvm/lib/Target/PowerPC/PPCHazardRecognizers.h head/contrib/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp head/contrib/llvm/lib/Target/PowerPC/PPCISelLowering.cpp head/contrib/llvm/lib/Target/PowerPC/PPCISelLowering.h head/contrib/llvm/lib/Target/PowerPC/PPCInstr64Bit.td head/contrib/llvm/lib/Target/PowerPC/PPCInstrAltivec.td head/contrib/llvm/lib/Target/PowerPC/PPCInstrFormats.td head/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp head/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.h head/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.td head/contrib/llvm/lib/Target/PowerPC/PPCJITInfo.cpp head/contrib/llvm/lib/Target/PowerPC/PPCJITInfo.h head/contrib/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp head/contrib/llvm/lib/Target/PowerPC/PPCMachineFunctionInfo.h head/contrib/llvm/lib/Target/PowerPC/PPCPerfectShuffle.h head/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp head/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.h head/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.td head/contrib/llvm/lib/Target/PowerPC/PPCRelocations.h head/contrib/llvm/lib/Target/PowerPC/PPCSchedule.td head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG3.td head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG4.td head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG4Plus.td head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG5.td head/contrib/llvm/lib/Target/PowerPC/PPCSubtarget.cpp head/contrib/llvm/lib/Target/PowerPC/PPCSubtarget.h head/contrib/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp head/contrib/llvm/lib/Target/PowerPC/PPCTargetMachine.h head/contrib/llvm/lib/Target/Sparc/DelaySlotFiller.cpp head/contrib/llvm/lib/Target/Sparc/FPMover.cpp head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCAsmInfo.cpp head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCAsmInfo.h head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCTargetDesc.cpp head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCTargetDesc.h head/contrib/llvm/lib/Target/Sparc/Sparc.h head/contrib/llvm/lib/Target/Sparc/Sparc.td head/contrib/llvm/lib/Target/Sparc/SparcAsmPrinter.cpp head/contrib/llvm/lib/Target/Sparc/SparcCallingConv.td head/contrib/llvm/lib/Target/Sparc/SparcFrameLowering.cpp head/contrib/llvm/lib/Target/Sparc/SparcFrameLowering.h head/contrib/llvm/lib/Target/Sparc/SparcISelDAGToDAG.cpp head/contrib/llvm/lib/Target/Sparc/SparcISelLowering.cpp head/contrib/llvm/lib/Target/Sparc/SparcISelLowering.h head/contrib/llvm/lib/Target/Sparc/SparcInstrFormats.td head/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.cpp head/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.h head/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.td head/contrib/llvm/lib/Target/Sparc/SparcMachineFunctionInfo.h head/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp head/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.h head/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.td head/contrib/llvm/lib/Target/Sparc/SparcSubtarget.cpp head/contrib/llvm/lib/Target/Sparc/SparcSubtarget.h head/contrib/llvm/lib/Target/Sparc/SparcTargetMachine.cpp head/contrib/llvm/lib/Target/Sparc/SparcTargetMachine.h head/contrib/llvm/lib/Target/TargetData.cpp head/contrib/llvm/lib/Target/TargetInstrInfo.cpp head/contrib/llvm/lib/Target/TargetLibraryInfo.cpp head/contrib/llvm/lib/Target/TargetLoweringObjectFile.cpp head/contrib/llvm/lib/Target/TargetMachine.cpp head/contrib/llvm/lib/Target/TargetRegisterInfo.cpp head/contrib/llvm/lib/Target/X86/AsmParser/X86AsmLexer.cpp head/contrib/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp head/contrib/llvm/lib/Target/X86/Disassembler/X86Disassembler.cpp head/contrib/llvm/lib/Target/X86/Disassembler/X86Disassembler.h head/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoder.c head/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoder.h head/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoderCommon.h head/contrib/llvm/lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp head/contrib/llvm/lib/Target/X86/InstPrinter/X86ATTInstPrinter.h head/contrib/llvm/lib/Target/X86/InstPrinter/X86InstComments.cpp head/contrib/llvm/lib/Target/X86/InstPrinter/X86InstComments.h head/contrib/llvm/lib/Target/X86/InstPrinter/X86IntelInstPrinter.cpp head/contrib/llvm/lib/Target/X86/InstPrinter/X86IntelInstPrinter.h head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86AsmBackend.cpp head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86FixupKinds.h head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.h head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h head/contrib/llvm/lib/Target/X86/Utils/X86ShuffleDecode.cpp head/contrib/llvm/lib/Target/X86/Utils/X86ShuffleDecode.h head/contrib/llvm/lib/Target/X86/X86.h head/contrib/llvm/lib/Target/X86/X86.td head/contrib/llvm/lib/Target/X86/X86AsmPrinter.cpp head/contrib/llvm/lib/Target/X86/X86AsmPrinter.h head/contrib/llvm/lib/Target/X86/X86COFFMachineModuleInfo.cpp head/contrib/llvm/lib/Target/X86/X86COFFMachineModuleInfo.h head/contrib/llvm/lib/Target/X86/X86CallingConv.td head/contrib/llvm/lib/Target/X86/X86CodeEmitter.cpp head/contrib/llvm/lib/Target/X86/X86ELFWriterInfo.cpp head/contrib/llvm/lib/Target/X86/X86FastISel.cpp head/contrib/llvm/lib/Target/X86/X86FloatingPoint.cpp head/contrib/llvm/lib/Target/X86/X86FrameLowering.cpp head/contrib/llvm/lib/Target/X86/X86FrameLowering.h head/contrib/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp head/contrib/llvm/lib/Target/X86/X86ISelLowering.cpp head/contrib/llvm/lib/Target/X86/X86ISelLowering.h head/contrib/llvm/lib/Target/X86/X86Instr3DNow.td head/contrib/llvm/lib/Target/X86/X86InstrArithmetic.td head/contrib/llvm/lib/Target/X86/X86InstrBuilder.h head/contrib/llvm/lib/Target/X86/X86InstrCMovSetCC.td head/contrib/llvm/lib/Target/X86/X86InstrCompiler.td head/contrib/llvm/lib/Target/X86/X86InstrControl.td head/contrib/llvm/lib/Target/X86/X86InstrExtension.td head/contrib/llvm/lib/Target/X86/X86InstrFMA.td head/contrib/llvm/lib/Target/X86/X86InstrFPStack.td head/contrib/llvm/lib/Target/X86/X86InstrFormats.td head/contrib/llvm/lib/Target/X86/X86InstrFragmentsSIMD.td head/contrib/llvm/lib/Target/X86/X86InstrInfo.cpp head/contrib/llvm/lib/Target/X86/X86InstrInfo.h head/contrib/llvm/lib/Target/X86/X86InstrInfo.td head/contrib/llvm/lib/Target/X86/X86InstrMMX.td head/contrib/llvm/lib/Target/X86/X86InstrSSE.td head/contrib/llvm/lib/Target/X86/X86InstrShiftRotate.td head/contrib/llvm/lib/Target/X86/X86InstrSystem.td head/contrib/llvm/lib/Target/X86/X86InstrVMX.td head/contrib/llvm/lib/Target/X86/X86JITInfo.cpp head/contrib/llvm/lib/Target/X86/X86JITInfo.h head/contrib/llvm/lib/Target/X86/X86MCInstLower.cpp head/contrib/llvm/lib/Target/X86/X86MCInstLower.h head/contrib/llvm/lib/Target/X86/X86MachineFunctionInfo.h head/contrib/llvm/lib/Target/X86/X86RegisterInfo.cpp head/contrib/llvm/lib/Target/X86/X86RegisterInfo.h head/contrib/llvm/lib/Target/X86/X86RegisterInfo.td head/contrib/llvm/lib/Target/X86/X86Relocations.h head/contrib/llvm/lib/Target/X86/X86SelectionDAGInfo.cpp head/contrib/llvm/lib/Target/X86/X86Subtarget.cpp head/contrib/llvm/lib/Target/X86/X86Subtarget.h head/contrib/llvm/lib/Target/X86/X86TargetMachine.cpp head/contrib/llvm/lib/Target/X86/X86TargetMachine.h head/contrib/llvm/lib/Target/X86/X86TargetObjectFile.cpp head/contrib/llvm/lib/Target/X86/X86TargetObjectFile.h head/contrib/llvm/lib/Target/X86/X86VZeroUpper.cpp head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCAsmInfo.cpp head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCAsmInfo.h head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCTargetDesc.cpp head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCTargetDesc.h head/contrib/llvm/lib/Target/XCore/XCore.h head/contrib/llvm/lib/Target/XCore/XCore.td head/contrib/llvm/lib/Target/XCore/XCoreFrameLowering.cpp head/contrib/llvm/lib/Target/XCore/XCoreFrameLowering.h head/contrib/llvm/lib/Target/XCore/XCoreISelDAGToDAG.cpp head/contrib/llvm/lib/Target/XCore/XCoreISelLowering.cpp head/contrib/llvm/lib/Target/XCore/XCoreISelLowering.h head/contrib/llvm/lib/Target/XCore/XCoreInstrFormats.td head/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.cpp head/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.h head/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.td head/contrib/llvm/lib/Target/XCore/XCoreMachineFunctionInfo.h head/contrib/llvm/lib/Target/XCore/XCoreRegisterInfo.cpp head/contrib/llvm/lib/Target/XCore/XCoreRegisterInfo.h head/contrib/llvm/lib/Target/XCore/XCoreRegisterInfo.td head/contrib/llvm/lib/Target/XCore/XCoreSubtarget.cpp head/contrib/llvm/lib/Target/XCore/XCoreSubtarget.h head/contrib/llvm/lib/Target/XCore/XCoreTargetMachine.cpp head/contrib/llvm/lib/Target/XCore/XCoreTargetMachine.h head/contrib/llvm/lib/Target/XCore/XCoreTargetObjectFile.h head/contrib/llvm/lib/Transforms/IPO/ConstantMerge.cpp head/contrib/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp head/contrib/llvm/lib/Transforms/IPO/FunctionAttrs.cpp head/contrib/llvm/lib/Transforms/IPO/GlobalOpt.cpp head/contrib/llvm/lib/Transforms/IPO/InlineAlways.cpp head/contrib/llvm/lib/Transforms/IPO/InlineSimple.cpp head/contrib/llvm/lib/Transforms/IPO/Inliner.cpp head/contrib/llvm/lib/Transforms/IPO/Internalize.cpp head/contrib/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp head/contrib/llvm/lib/Transforms/IPO/PruneEH.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombine.h head/contrib/llvm/lib/Transforms/InstCombine/InstCombineAddSub.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineCasts.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineMulDivRem.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp head/contrib/llvm/lib/Transforms/InstCombine/InstCombineWorklist.h head/contrib/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp head/contrib/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp head/contrib/llvm/lib/Transforms/Instrumentation/Instrumentation.cpp head/contrib/llvm/lib/Transforms/Instrumentation/OptimalEdgeProfiling.cpp head/contrib/llvm/lib/Transforms/Instrumentation/PathProfiling.cpp head/contrib/llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp head/contrib/llvm/lib/Transforms/Scalar/ConstantProp.cpp head/contrib/llvm/lib/Transforms/Scalar/CorrelatedValuePropagation.cpp head/contrib/llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp head/contrib/llvm/lib/Transforms/Scalar/EarlyCSE.cpp head/contrib/llvm/lib/Transforms/Scalar/GVN.cpp head/contrib/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp head/contrib/llvm/lib/Transforms/Scalar/JumpThreading.cpp head/contrib/llvm/lib/Transforms/Scalar/LICM.cpp head/contrib/llvm/lib/Transforms/Scalar/LoopInstSimplify.cpp head/contrib/llvm/lib/Transforms/Scalar/LoopRotation.cpp head/contrib/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp head/contrib/llvm/lib/Transforms/Scalar/LoopUnrollPass.cpp head/contrib/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp head/contrib/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp head/contrib/llvm/lib/Transforms/Scalar/ObjCARC.cpp head/contrib/llvm/lib/Transforms/Scalar/Reassociate.cpp head/contrib/llvm/lib/Transforms/Scalar/SCCP.cpp head/contrib/llvm/lib/Transforms/Scalar/Scalar.cpp head/contrib/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp head/contrib/llvm/lib/Transforms/Scalar/SimplifyLibCalls.cpp head/contrib/llvm/lib/Transforms/Scalar/Sink.cpp head/contrib/llvm/lib/Transforms/Utils/AddrModeMatcher.cpp head/contrib/llvm/lib/Transforms/Utils/BasicBlockUtils.cpp head/contrib/llvm/lib/Transforms/Utils/BreakCriticalEdges.cpp head/contrib/llvm/lib/Transforms/Utils/BuildLibCalls.cpp head/contrib/llvm/lib/Transforms/Utils/CloneFunction.cpp head/contrib/llvm/lib/Transforms/Utils/CodeExtractor.cpp head/contrib/llvm/lib/Transforms/Utils/DemoteRegToStack.cpp head/contrib/llvm/lib/Transforms/Utils/InlineFunction.cpp head/contrib/llvm/lib/Transforms/Utils/Local.cpp head/contrib/llvm/lib/Transforms/Utils/LoopSimplify.cpp head/contrib/llvm/lib/Transforms/Utils/LoopUnroll.cpp head/contrib/llvm/lib/Transforms/Utils/LowerExpectIntrinsic.cpp head/contrib/llvm/lib/Transforms/Utils/LowerInvoke.cpp head/contrib/llvm/lib/Transforms/Utils/LowerSwitch.cpp head/contrib/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp head/contrib/llvm/lib/Transforms/Utils/SSAUpdater.cpp head/contrib/llvm/lib/Transforms/Utils/SimplifyCFG.cpp head/contrib/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp head/contrib/llvm/lib/Transforms/Utils/SimplifyInstructions.cpp head/contrib/llvm/lib/Transforms/Utils/UnifyFunctionExitNodes.cpp head/contrib/llvm/lib/VMCore/AsmWriter.cpp head/contrib/llvm/lib/VMCore/Attributes.cpp head/contrib/llvm/lib/VMCore/AutoUpgrade.cpp head/contrib/llvm/lib/VMCore/BasicBlock.cpp head/contrib/llvm/lib/VMCore/ConstantFold.cpp head/contrib/llvm/lib/VMCore/Constants.cpp head/contrib/llvm/lib/VMCore/ConstantsContext.h head/contrib/llvm/lib/VMCore/Core.cpp head/contrib/llvm/lib/VMCore/DebugLoc.cpp head/contrib/llvm/lib/VMCore/Dominators.cpp head/contrib/llvm/lib/VMCore/Function.cpp head/contrib/llvm/lib/VMCore/GCOV.cpp head/contrib/llvm/lib/VMCore/IRBuilder.cpp head/contrib/llvm/lib/VMCore/Instruction.cpp head/contrib/llvm/lib/VMCore/Instructions.cpp head/contrib/llvm/lib/VMCore/LLVMContext.cpp head/contrib/llvm/lib/VMCore/LLVMContextImpl.cpp head/contrib/llvm/lib/VMCore/LLVMContextImpl.h head/contrib/llvm/lib/VMCore/Metadata.cpp head/contrib/llvm/lib/VMCore/Module.cpp head/contrib/llvm/lib/VMCore/Pass.cpp head/contrib/llvm/lib/VMCore/PassManager.cpp head/contrib/llvm/lib/VMCore/Type.cpp head/contrib/llvm/lib/VMCore/Use.cpp head/contrib/llvm/lib/VMCore/User.cpp head/contrib/llvm/lib/VMCore/Value.cpp head/contrib/llvm/lib/VMCore/ValueTypes.cpp head/contrib/llvm/lib/VMCore/Verifier.cpp head/contrib/llvm/tools/bugpoint/BugDriver.cpp head/contrib/llvm/tools/bugpoint/CrashDebugger.cpp head/contrib/llvm/tools/bugpoint/ExecutionDriver.cpp head/contrib/llvm/tools/bugpoint/ExtractFunction.cpp head/contrib/llvm/tools/bugpoint/Miscompilation.cpp head/contrib/llvm/tools/bugpoint/OptimizerDriver.cpp head/contrib/llvm/tools/bugpoint/ToolRunner.cpp head/contrib/llvm/tools/bugpoint/ToolRunner.h head/contrib/llvm/tools/bugpoint/bugpoint.cpp head/contrib/llvm/tools/clang/LICENSE.TXT head/contrib/llvm/tools/clang/include/clang-c/Index.h head/contrib/llvm/tools/clang/include/clang/ARCMigrate/ARCMT.h head/contrib/llvm/tools/clang/include/clang/ARCMigrate/ARCMTActions.h head/contrib/llvm/tools/clang/include/clang/ARCMigrate/FileRemapper.h head/contrib/llvm/tools/clang/include/clang/AST/APValue.h head/contrib/llvm/tools/clang/include/clang/AST/ASTConsumer.h head/contrib/llvm/tools/clang/include/clang/AST/ASTContext.h head/contrib/llvm/tools/clang/include/clang/AST/ASTDiagnostic.h head/contrib/llvm/tools/clang/include/clang/AST/ASTImporter.h head/contrib/llvm/tools/clang/include/clang/AST/ASTMutationListener.h head/contrib/llvm/tools/clang/include/clang/AST/Attr.h head/contrib/llvm/tools/clang/include/clang/AST/CanonicalType.h head/contrib/llvm/tools/clang/include/clang/AST/Decl.h head/contrib/llvm/tools/clang/include/clang/AST/DeclBase.h head/contrib/llvm/tools/clang/include/clang/AST/DeclCXX.h head/contrib/llvm/tools/clang/include/clang/AST/DeclFriend.h head/contrib/llvm/tools/clang/include/clang/AST/DeclObjC.h head/contrib/llvm/tools/clang/include/clang/AST/DeclTemplate.h head/contrib/llvm/tools/clang/include/clang/AST/DeclVisitor.h head/contrib/llvm/tools/clang/include/clang/AST/DeclarationName.h head/contrib/llvm/tools/clang/include/clang/AST/DependentDiagnostic.h head/contrib/llvm/tools/clang/include/clang/AST/Expr.h head/contrib/llvm/tools/clang/include/clang/AST/ExprCXX.h head/contrib/llvm/tools/clang/include/clang/AST/ExprObjC.h head/contrib/llvm/tools/clang/include/clang/AST/ExternalASTSource.h head/contrib/llvm/tools/clang/include/clang/AST/Mangle.h head/contrib/llvm/tools/clang/include/clang/AST/NestedNameSpecifier.h head/contrib/llvm/tools/clang/include/clang/AST/OperationKinds.h head/contrib/llvm/tools/clang/include/clang/AST/PrettyPrinter.h head/contrib/llvm/tools/clang/include/clang/AST/RecordLayout.h head/contrib/llvm/tools/clang/include/clang/AST/RecursiveASTVisitor.h head/contrib/llvm/tools/clang/include/clang/AST/Redeclarable.h head/contrib/llvm/tools/clang/include/clang/AST/Stmt.h head/contrib/llvm/tools/clang/include/clang/AST/StmtCXX.h head/contrib/llvm/tools/clang/include/clang/AST/StmtIterator.h head/contrib/llvm/tools/clang/include/clang/AST/StmtObjC.h head/contrib/llvm/tools/clang/include/clang/AST/StmtVisitor.h head/contrib/llvm/tools/clang/include/clang/AST/TemplateBase.h head/contrib/llvm/tools/clang/include/clang/AST/Type.h head/contrib/llvm/tools/clang/include/clang/AST/TypeLoc.h head/contrib/llvm/tools/clang/include/clang/AST/TypeVisitor.h head/contrib/llvm/tools/clang/include/clang/AST/VTableBuilder.h head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/FormatString.h head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/LiveVariables.h head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/ReachableCode.h head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/ThreadSafety.h head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/UninitializedValues.h head/contrib/llvm/tools/clang/include/clang/Analysis/AnalysisContext.h head/contrib/llvm/tools/clang/include/clang/Analysis/AnalysisDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Analysis/CFG.h head/contrib/llvm/tools/clang/include/clang/Analysis/DomainSpecific/CocoaConventions.h head/contrib/llvm/tools/clang/include/clang/Analysis/ProgramPoint.h head/contrib/llvm/tools/clang/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h head/contrib/llvm/tools/clang/include/clang/Basic/Attr.td head/contrib/llvm/tools/clang/include/clang/Basic/Builtins.def head/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsX86.def head/contrib/llvm/tools/clang/include/clang/Basic/ConvertUTF.h head/contrib/llvm/tools/clang/include/clang/Basic/DeclNodes.td head/contrib/llvm/tools/clang/include/clang/Basic/Diagnostic.h head/contrib/llvm/tools/clang/include/clang/Basic/Diagnostic.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticASTKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticAnalysisKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticCommonKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticDriverKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticFrontendKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticGroups.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticIDs.h head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticLexKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticParseKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticSemaKinds.td head/contrib/llvm/tools/clang/include/clang/Basic/ExpressionTraits.h head/contrib/llvm/tools/clang/include/clang/Basic/FileManager.h head/contrib/llvm/tools/clang/include/clang/Basic/FileSystemStatCache.h head/contrib/llvm/tools/clang/include/clang/Basic/IdentifierTable.h head/contrib/llvm/tools/clang/include/clang/Basic/LLVM.h head/contrib/llvm/tools/clang/include/clang/Basic/LangOptions.def head/contrib/llvm/tools/clang/include/clang/Basic/LangOptions.h head/contrib/llvm/tools/clang/include/clang/Basic/Linkage.h head/contrib/llvm/tools/clang/include/clang/Basic/OnDiskHashTable.h head/contrib/llvm/tools/clang/include/clang/Basic/PartialDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Basic/SourceLocation.h head/contrib/llvm/tools/clang/include/clang/Basic/SourceManager.h head/contrib/llvm/tools/clang/include/clang/Basic/Specifiers.h head/contrib/llvm/tools/clang/include/clang/Basic/StmtNodes.td head/contrib/llvm/tools/clang/include/clang/Basic/TargetBuiltins.h head/contrib/llvm/tools/clang/include/clang/Basic/TargetInfo.h head/contrib/llvm/tools/clang/include/clang/Basic/TokenKinds.def head/contrib/llvm/tools/clang/include/clang/Basic/TypeTraits.h head/contrib/llvm/tools/clang/include/clang/Basic/Version.h head/contrib/llvm/tools/clang/include/clang/CodeGen/CodeGenAction.h head/contrib/llvm/tools/clang/include/clang/CodeGen/ModuleBuilder.h head/contrib/llvm/tools/clang/include/clang/Driver/Action.h head/contrib/llvm/tools/clang/include/clang/Driver/ArgList.h head/contrib/llvm/tools/clang/include/clang/Driver/CC1AsOptions.td head/contrib/llvm/tools/clang/include/clang/Driver/CC1Options.td head/contrib/llvm/tools/clang/include/clang/Driver/Compilation.h head/contrib/llvm/tools/clang/include/clang/Driver/Driver.h head/contrib/llvm/tools/clang/include/clang/Driver/DriverDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Driver/Job.h head/contrib/llvm/tools/clang/include/clang/Driver/ObjCRuntime.h head/contrib/llvm/tools/clang/include/clang/Driver/OptTable.h head/contrib/llvm/tools/clang/include/clang/Driver/Options.td head/contrib/llvm/tools/clang/include/clang/Driver/Tool.h head/contrib/llvm/tools/clang/include/clang/Driver/ToolChain.h head/contrib/llvm/tools/clang/include/clang/Driver/Types.def head/contrib/llvm/tools/clang/include/clang/Frontend/ASTUnit.h head/contrib/llvm/tools/clang/include/clang/Frontend/Analyses.def head/contrib/llvm/tools/clang/include/clang/Frontend/AnalyzerOptions.h head/contrib/llvm/tools/clang/include/clang/Frontend/ChainedDiagnosticConsumer.h head/contrib/llvm/tools/clang/include/clang/Frontend/CodeGenOptions.h head/contrib/llvm/tools/clang/include/clang/Frontend/CompilerInstance.h head/contrib/llvm/tools/clang/include/clang/Frontend/CompilerInvocation.h head/contrib/llvm/tools/clang/include/clang/Frontend/DependencyOutputOptions.h head/contrib/llvm/tools/clang/include/clang/Frontend/DiagnosticOptions.h head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendAction.h head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendActions.h head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendOptions.h head/contrib/llvm/tools/clang/include/clang/Frontend/LangStandard.h head/contrib/llvm/tools/clang/include/clang/Frontend/LangStandards.def head/contrib/llvm/tools/clang/include/clang/Frontend/MultiplexConsumer.h head/contrib/llvm/tools/clang/include/clang/Frontend/PreprocessorOptions.h head/contrib/llvm/tools/clang/include/clang/Frontend/TextDiagnosticPrinter.h head/contrib/llvm/tools/clang/include/clang/Frontend/Utils.h head/contrib/llvm/tools/clang/include/clang/Frontend/VerifyDiagnosticConsumer.h head/contrib/llvm/tools/clang/include/clang/Index/ASTLocation.h head/contrib/llvm/tools/clang/include/clang/Lex/DirectoryLookup.h head/contrib/llvm/tools/clang/include/clang/Lex/ExternalPreprocessorSource.h head/contrib/llvm/tools/clang/include/clang/Lex/HeaderSearch.h head/contrib/llvm/tools/clang/include/clang/Lex/LexDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Lex/Lexer.h head/contrib/llvm/tools/clang/include/clang/Lex/LiteralSupport.h head/contrib/llvm/tools/clang/include/clang/Lex/MacroInfo.h head/contrib/llvm/tools/clang/include/clang/Lex/ModuleLoader.h head/contrib/llvm/tools/clang/include/clang/Lex/PPCallbacks.h head/contrib/llvm/tools/clang/include/clang/Lex/PreprocessingRecord.h head/contrib/llvm/tools/clang/include/clang/Lex/Preprocessor.h head/contrib/llvm/tools/clang/include/clang/Lex/PreprocessorLexer.h head/contrib/llvm/tools/clang/include/clang/Lex/Token.h head/contrib/llvm/tools/clang/include/clang/Parse/ParseAST.h head/contrib/llvm/tools/clang/include/clang/Parse/ParseDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Parse/Parser.h head/contrib/llvm/tools/clang/include/clang/Rewrite/ASTConsumers.h head/contrib/llvm/tools/clang/include/clang/Rewrite/FixItRewriter.h head/contrib/llvm/tools/clang/include/clang/Rewrite/FrontendActions.h head/contrib/llvm/tools/clang/include/clang/Rewrite/TokenRewriter.h head/contrib/llvm/tools/clang/include/clang/Sema/AttributeList.h head/contrib/llvm/tools/clang/include/clang/Sema/CodeCompleteConsumer.h head/contrib/llvm/tools/clang/include/clang/Sema/DeclSpec.h head/contrib/llvm/tools/clang/include/clang/Sema/DelayedDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Sema/ExternalSemaSource.h head/contrib/llvm/tools/clang/include/clang/Sema/IdentifierResolver.h head/contrib/llvm/tools/clang/include/clang/Sema/Initialization.h head/contrib/llvm/tools/clang/include/clang/Sema/LocInfoType.h head/contrib/llvm/tools/clang/include/clang/Sema/Lookup.h head/contrib/llvm/tools/clang/include/clang/Sema/Overload.h head/contrib/llvm/tools/clang/include/clang/Sema/ParsedTemplate.h head/contrib/llvm/tools/clang/include/clang/Sema/PrettyDeclStackTrace.h head/contrib/llvm/tools/clang/include/clang/Sema/Scope.h head/contrib/llvm/tools/clang/include/clang/Sema/ScopeInfo.h head/contrib/llvm/tools/clang/include/clang/Sema/Sema.h head/contrib/llvm/tools/clang/include/clang/Sema/SemaConsumer.h head/contrib/llvm/tools/clang/include/clang/Sema/SemaDiagnostic.h head/contrib/llvm/tools/clang/include/clang/Sema/SemaFixItUtils.h head/contrib/llvm/tools/clang/include/clang/Sema/Template.h head/contrib/llvm/tools/clang/include/clang/Sema/TemplateDeduction.h head/contrib/llvm/tools/clang/include/clang/Sema/TypoCorrection.h head/contrib/llvm/tools/clang/include/clang/Serialization/ASTBitCodes.h head/contrib/llvm/tools/clang/include/clang/Serialization/ASTDeserializationListener.h head/contrib/llvm/tools/clang/include/clang/Serialization/ASTReader.h head/contrib/llvm/tools/clang/include/clang/Serialization/ASTWriter.h head/contrib/llvm/tools/clang/include/clang/Serialization/ContinuousRangeMap.h head/contrib/llvm/tools/clang/include/clang/Serialization/Module.h head/contrib/llvm/tools/clang/include/clang/Serialization/ModuleManager.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporterVisitor.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugType.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/PathDiagnostic.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/Checker.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/CheckerRegistry.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathDiagnosticConsumers.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/AnalysisManager.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/BasicValueFactory.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CheckerContext.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ConstraintManager.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CoreEngine.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Environment.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExplodedGraph.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/MemRegion.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ObjCMessage.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramStateTrait.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SValBuilder.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SVals.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Store.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SubEngine.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SymbolManager.h head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/WorkList.h head/contrib/llvm/tools/clang/lib/ARCMigrate/ARCMT.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/ARCMTActions.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/FileRemapper.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/Internals.h head/contrib/llvm/tools/clang/lib/ARCMigrate/TransARCAssign.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransAutoreleasePool.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransBlockObjCVariable.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransEmptyStatementsAndDealloc.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransProperties.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransRetainReleaseDealloc.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransUnbridgedCasts.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransUnusedInitDelegate.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransZeroOutPropsInDealloc.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/TransformActions.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/Transforms.cpp head/contrib/llvm/tools/clang/lib/ARCMigrate/Transforms.h head/contrib/llvm/tools/clang/lib/AST/APValue.cpp head/contrib/llvm/tools/clang/lib/AST/ASTConsumer.cpp head/contrib/llvm/tools/clang/lib/AST/ASTContext.cpp head/contrib/llvm/tools/clang/lib/AST/ASTDiagnostic.cpp head/contrib/llvm/tools/clang/lib/AST/ASTImporter.cpp head/contrib/llvm/tools/clang/lib/AST/AttrImpl.cpp head/contrib/llvm/tools/clang/lib/AST/CXXInheritance.cpp head/contrib/llvm/tools/clang/lib/AST/Decl.cpp head/contrib/llvm/tools/clang/lib/AST/DeclBase.cpp head/contrib/llvm/tools/clang/lib/AST/DeclCXX.cpp head/contrib/llvm/tools/clang/lib/AST/DeclFriend.cpp head/contrib/llvm/tools/clang/lib/AST/DeclObjC.cpp head/contrib/llvm/tools/clang/lib/AST/DeclPrinter.cpp head/contrib/llvm/tools/clang/lib/AST/DeclTemplate.cpp head/contrib/llvm/tools/clang/lib/AST/DeclarationName.cpp head/contrib/llvm/tools/clang/lib/AST/DumpXML.cpp head/contrib/llvm/tools/clang/lib/AST/Expr.cpp head/contrib/llvm/tools/clang/lib/AST/ExprCXX.cpp head/contrib/llvm/tools/clang/lib/AST/ExprClassification.cpp head/contrib/llvm/tools/clang/lib/AST/ExprConstant.cpp head/contrib/llvm/tools/clang/lib/AST/ItaniumMangle.cpp head/contrib/llvm/tools/clang/lib/AST/Mangle.cpp head/contrib/llvm/tools/clang/lib/AST/MicrosoftMangle.cpp head/contrib/llvm/tools/clang/lib/AST/NestedNameSpecifier.cpp head/contrib/llvm/tools/clang/lib/AST/ParentMap.cpp head/contrib/llvm/tools/clang/lib/AST/RecordLayout.cpp head/contrib/llvm/tools/clang/lib/AST/RecordLayoutBuilder.cpp head/contrib/llvm/tools/clang/lib/AST/Stmt.cpp head/contrib/llvm/tools/clang/lib/AST/StmtDumper.cpp head/contrib/llvm/tools/clang/lib/AST/StmtPrinter.cpp head/contrib/llvm/tools/clang/lib/AST/StmtProfile.cpp head/contrib/llvm/tools/clang/lib/AST/TemplateBase.cpp head/contrib/llvm/tools/clang/lib/AST/TemplateName.cpp head/contrib/llvm/tools/clang/lib/AST/Type.cpp head/contrib/llvm/tools/clang/lib/AST/TypeLoc.cpp head/contrib/llvm/tools/clang/lib/AST/TypePrinter.cpp head/contrib/llvm/tools/clang/lib/AST/VTableBuilder.cpp head/contrib/llvm/tools/clang/lib/Analysis/CFG.cpp head/contrib/llvm/tools/clang/lib/Analysis/CocoaConventions.cpp head/contrib/llvm/tools/clang/lib/Analysis/FormatString.cpp head/contrib/llvm/tools/clang/lib/Analysis/FormatStringParsing.h head/contrib/llvm/tools/clang/lib/Analysis/LiveVariables.cpp head/contrib/llvm/tools/clang/lib/Analysis/PrintfFormatString.cpp head/contrib/llvm/tools/clang/lib/Analysis/ProgramPoint.cpp head/contrib/llvm/tools/clang/lib/Analysis/PseudoConstantAnalysis.cpp head/contrib/llvm/tools/clang/lib/Analysis/ReachableCode.cpp head/contrib/llvm/tools/clang/lib/Analysis/ScanfFormatString.cpp head/contrib/llvm/tools/clang/lib/Analysis/ThreadSafety.cpp head/contrib/llvm/tools/clang/lib/Analysis/UninitializedValues.cpp head/contrib/llvm/tools/clang/lib/Basic/Builtins.cpp head/contrib/llvm/tools/clang/lib/Basic/ConvertUTF.c head/contrib/llvm/tools/clang/lib/Basic/Diagnostic.cpp head/contrib/llvm/tools/clang/lib/Basic/DiagnosticIDs.cpp head/contrib/llvm/tools/clang/lib/Basic/FileManager.cpp head/contrib/llvm/tools/clang/lib/Basic/FileSystemStatCache.cpp head/contrib/llvm/tools/clang/lib/Basic/IdentifierTable.cpp head/contrib/llvm/tools/clang/lib/Basic/LangOptions.cpp head/contrib/llvm/tools/clang/lib/Basic/SourceLocation.cpp head/contrib/llvm/tools/clang/lib/Basic/SourceManager.cpp head/contrib/llvm/tools/clang/lib/Basic/TargetInfo.cpp head/contrib/llvm/tools/clang/lib/Basic/Targets.cpp head/contrib/llvm/tools/clang/lib/Basic/Version.cpp head/contrib/llvm/tools/clang/lib/CodeGen/ABIInfo.h head/contrib/llvm/tools/clang/lib/CodeGen/BackendUtil.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGBlocks.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGBlocks.h head/contrib/llvm/tools/clang/lib/CodeGen/CGBuiltin.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGCXX.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGCXXABI.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGCXXABI.h head/contrib/llvm/tools/clang/lib/CodeGen/CGCall.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGCall.h head/contrib/llvm/tools/clang/lib/CodeGen/CGClass.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGCleanup.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGDebugInfo.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGDebugInfo.h head/contrib/llvm/tools/clang/lib/CodeGen/CGDecl.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGDeclCXX.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGException.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGExpr.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGExprAgg.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGExprCXX.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGExprComplex.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGExprConstant.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGExprScalar.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGObjC.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCGNU.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCMac.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCRuntime.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCRuntime.h head/contrib/llvm/tools/clang/lib/CodeGen/CGRTTI.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGRecordLayoutBuilder.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGStmt.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGVTT.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGVTables.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CGValue.h head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenAction.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenFunction.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenFunction.h head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenModule.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenModule.h head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTBAA.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTBAA.h head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTypes.cpp head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTypes.h head/contrib/llvm/tools/clang/lib/CodeGen/ItaniumCXXABI.cpp head/contrib/llvm/tools/clang/lib/CodeGen/MicrosoftCXXABI.cpp head/contrib/llvm/tools/clang/lib/CodeGen/ModuleBuilder.cpp head/contrib/llvm/tools/clang/lib/CodeGen/TargetInfo.cpp head/contrib/llvm/tools/clang/lib/CodeGen/TargetInfo.h head/contrib/llvm/tools/clang/lib/Driver/Action.cpp head/contrib/llvm/tools/clang/lib/Driver/Arg.cpp head/contrib/llvm/tools/clang/lib/Driver/ArgList.cpp head/contrib/llvm/tools/clang/lib/Driver/CC1AsOptions.cpp head/contrib/llvm/tools/clang/lib/Driver/CC1Options.cpp head/contrib/llvm/tools/clang/lib/Driver/Compilation.cpp head/contrib/llvm/tools/clang/lib/Driver/Driver.cpp head/contrib/llvm/tools/clang/lib/Driver/DriverOptions.cpp head/contrib/llvm/tools/clang/lib/Driver/Job.cpp head/contrib/llvm/tools/clang/lib/Driver/Option.cpp head/contrib/llvm/tools/clang/lib/Driver/ToolChain.cpp head/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp head/contrib/llvm/tools/clang/lib/Driver/ToolChains.h head/contrib/llvm/tools/clang/lib/Driver/Tools.cpp head/contrib/llvm/tools/clang/lib/Driver/Tools.h head/contrib/llvm/tools/clang/lib/Driver/Types.cpp head/contrib/llvm/tools/clang/lib/Frontend/ASTConsumers.cpp head/contrib/llvm/tools/clang/lib/Frontend/ASTMerge.cpp head/contrib/llvm/tools/clang/lib/Frontend/ASTUnit.cpp head/contrib/llvm/tools/clang/lib/Frontend/CacheTokens.cpp head/contrib/llvm/tools/clang/lib/Frontend/CompilerInstance.cpp head/contrib/llvm/tools/clang/lib/Frontend/CompilerInvocation.cpp head/contrib/llvm/tools/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp head/contrib/llvm/tools/clang/lib/Frontend/DependencyFile.cpp head/contrib/llvm/tools/clang/lib/Frontend/FrontendAction.cpp head/contrib/llvm/tools/clang/lib/Frontend/FrontendActions.cpp head/contrib/llvm/tools/clang/lib/Frontend/HeaderIncludeGen.cpp head/contrib/llvm/tools/clang/lib/Frontend/InitHeaderSearch.cpp head/contrib/llvm/tools/clang/lib/Frontend/InitPreprocessor.cpp head/contrib/llvm/tools/clang/lib/Frontend/LangStandards.cpp head/contrib/llvm/tools/clang/lib/Frontend/LogDiagnosticPrinter.cpp head/contrib/llvm/tools/clang/lib/Frontend/MultiplexConsumer.cpp head/contrib/llvm/tools/clang/lib/Frontend/PrintPreprocessedOutput.cpp head/contrib/llvm/tools/clang/lib/Frontend/TextDiagnosticBuffer.cpp head/contrib/llvm/tools/clang/lib/Frontend/TextDiagnosticPrinter.cpp head/contrib/llvm/tools/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp head/contrib/llvm/tools/clang/lib/Frontend/Warnings.cpp head/contrib/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp head/contrib/llvm/tools/clang/lib/Headers/avxintrin.h head/contrib/llvm/tools/clang/lib/Headers/emmintrin.h head/contrib/llvm/tools/clang/lib/Headers/float.h head/contrib/llvm/tools/clang/lib/Headers/immintrin.h head/contrib/llvm/tools/clang/lib/Headers/mm3dnow.h head/contrib/llvm/tools/clang/lib/Headers/smmintrin.h head/contrib/llvm/tools/clang/lib/Headers/tgmath.h head/contrib/llvm/tools/clang/lib/Headers/tmmintrin.h head/contrib/llvm/tools/clang/lib/Headers/wmmintrin.h head/contrib/llvm/tools/clang/lib/Headers/x86intrin.h head/contrib/llvm/tools/clang/lib/Headers/xmmintrin.h head/contrib/llvm/tools/clang/lib/Index/ASTLocation.cpp head/contrib/llvm/tools/clang/lib/Index/Analyzer.cpp head/contrib/llvm/tools/clang/lib/Lex/HeaderMap.cpp head/contrib/llvm/tools/clang/lib/Lex/HeaderSearch.cpp head/contrib/llvm/tools/clang/lib/Lex/Lexer.cpp head/contrib/llvm/tools/clang/lib/Lex/LiteralSupport.cpp head/contrib/llvm/tools/clang/lib/Lex/MacroArgs.cpp head/contrib/llvm/tools/clang/lib/Lex/MacroInfo.cpp head/contrib/llvm/tools/clang/lib/Lex/PPCaching.cpp head/contrib/llvm/tools/clang/lib/Lex/PPDirectives.cpp head/contrib/llvm/tools/clang/lib/Lex/PPExpressions.cpp head/contrib/llvm/tools/clang/lib/Lex/PPLexerChange.cpp head/contrib/llvm/tools/clang/lib/Lex/PPMacroExpansion.cpp head/contrib/llvm/tools/clang/lib/Lex/PTHLexer.cpp head/contrib/llvm/tools/clang/lib/Lex/Pragma.cpp head/contrib/llvm/tools/clang/lib/Lex/PreprocessingRecord.cpp head/contrib/llvm/tools/clang/lib/Lex/Preprocessor.cpp head/contrib/llvm/tools/clang/lib/Lex/PreprocessorLexer.cpp head/contrib/llvm/tools/clang/lib/Lex/TokenConcatenation.cpp head/contrib/llvm/tools/clang/lib/Lex/TokenLexer.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseAST.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseCXXInlineMethods.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseDecl.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseDeclCXX.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseExpr.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseExprCXX.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseInit.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseObjc.cpp head/contrib/llvm/tools/clang/lib/Parse/ParsePragma.cpp head/contrib/llvm/tools/clang/lib/Parse/ParsePragma.h head/contrib/llvm/tools/clang/lib/Parse/ParseStmt.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseTemplate.cpp head/contrib/llvm/tools/clang/lib/Parse/ParseTentative.cpp head/contrib/llvm/tools/clang/lib/Parse/Parser.cpp head/contrib/llvm/tools/clang/lib/Rewrite/FixItRewriter.cpp head/contrib/llvm/tools/clang/lib/Rewrite/FrontendActions.cpp head/contrib/llvm/tools/clang/lib/Rewrite/HTMLPrint.cpp head/contrib/llvm/tools/clang/lib/Rewrite/HTMLRewrite.cpp head/contrib/llvm/tools/clang/lib/Rewrite/RewriteMacros.cpp head/contrib/llvm/tools/clang/lib/Rewrite/RewriteObjC.cpp head/contrib/llvm/tools/clang/lib/Rewrite/RewriteTest.cpp head/contrib/llvm/tools/clang/lib/Rewrite/Rewriter.cpp head/contrib/llvm/tools/clang/lib/Sema/AnalysisBasedWarnings.cpp head/contrib/llvm/tools/clang/lib/Sema/AttributeList.cpp head/contrib/llvm/tools/clang/lib/Sema/CodeCompleteConsumer.cpp head/contrib/llvm/tools/clang/lib/Sema/DeclSpec.cpp head/contrib/llvm/tools/clang/lib/Sema/DelayedDiagnostic.cpp head/contrib/llvm/tools/clang/lib/Sema/IdentifierResolver.cpp head/contrib/llvm/tools/clang/lib/Sema/JumpDiagnostics.cpp head/contrib/llvm/tools/clang/lib/Sema/Scope.cpp head/contrib/llvm/tools/clang/lib/Sema/Sema.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaAccess.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaAttr.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaCXXScopeSpec.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaCast.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaChecking.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaCodeComplete.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaDecl.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaDeclAttr.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaDeclObjC.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaExceptionSpec.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaExpr.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaExprCXX.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaExprMember.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaExprObjC.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaFixItUtils.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaInit.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaLookup.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaObjCProperty.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaOverload.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaStmt.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaTemplate.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateDeduction.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateInstantiate.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateVariadic.cpp head/contrib/llvm/tools/clang/lib/Sema/SemaType.cpp head/contrib/llvm/tools/clang/lib/Sema/TargetAttributesSema.cpp head/contrib/llvm/tools/clang/lib/Sema/TreeTransform.h head/contrib/llvm/tools/clang/lib/Serialization/ASTCommon.cpp head/contrib/llvm/tools/clang/lib/Serialization/ASTCommon.h head/contrib/llvm/tools/clang/lib/Serialization/ASTReader.cpp head/contrib/llvm/tools/clang/lib/Serialization/ASTReaderDecl.cpp head/contrib/llvm/tools/clang/lib/Serialization/ASTReaderInternals.h head/contrib/llvm/tools/clang/lib/Serialization/ASTReaderStmt.cpp head/contrib/llvm/tools/clang/lib/Serialization/ASTWriter.cpp head/contrib/llvm/tools/clang/lib/Serialization/ASTWriterDecl.cpp head/contrib/llvm/tools/clang/lib/Serialization/ASTWriterStmt.cpp head/contrib/llvm/tools/clang/lib/Serialization/GeneratePCH.cpp head/contrib/llvm/tools/clang/lib/Serialization/Module.cpp head/contrib/llvm/tools/clang/lib/Serialization/ModuleManager.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/AdjustedReturnValueChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/AnalyzerStatsChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ArrayBoundChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ArrayBoundCheckerV2.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/AttrNonNullChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/BasicObjCFoundationChecks.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/BuiltinFunctionChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CallAndMessageChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CastSizeChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CastToStructChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckObjCInstMethSignature.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckSecuritySyntaxOnly.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckSizeofPointer.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/Checkers.td head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ChrootChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ClangSACheckers.h head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DeadStoresChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DebugCheckers.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DereferenceChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/FixedAddressChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/IdempotentOperationChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/IteratorsChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/LLVMConventionsChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MacOSKeychainAPIChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MacOSXAPIChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocOverflowSecurityChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NSAutoreleasePoolChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NSErrorChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NoReturnFunctionChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/OSAtomicChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCAtSyncChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCSelfInitChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCUnusedIVarsChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PointerArithChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PointerSubChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ReturnPointerRangeChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ReturnUndefChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StackAddrEscapeChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefBranchChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefResultChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefinedArraySubscriptChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefinedAssignmentChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UnixAPIChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UnreachableCodeChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BasicConstraintManager.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BugReporter.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/Checker.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerContext.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerManager.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerRegistry.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/Environment.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExplodedGraph.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineC.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineObjC.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/MemRegion.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ObjCMessage.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/PathDiagnostic.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/PlistDiagnostics.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ProgramState.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/RangeConstraintManager.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/RegionStore.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SValBuilder.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SVals.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SimpleConstraintManager.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SimpleConstraintManager.h head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/Store.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SymbolManager.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/TextPathDiagnostics.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Frontend/CheckerRegistration.cpp head/contrib/llvm/tools/clang/tools/driver/cc1_main.cpp head/contrib/llvm/tools/clang/tools/driver/cc1as_main.cpp head/contrib/llvm/tools/clang/tools/driver/driver.cpp head/contrib/llvm/tools/clang/utils/TableGen/ClangAttrEmitter.cpp head/contrib/llvm/tools/clang/utils/TableGen/ClangAttrEmitter.h head/contrib/llvm/tools/clang/utils/TableGen/ClangDiagnosticsEmitter.cpp head/contrib/llvm/tools/clang/utils/TableGen/NeonEmitter.cpp head/contrib/llvm/tools/clang/utils/TableGen/NeonEmitter.h head/contrib/llvm/tools/clang/utils/TableGen/TableGen.cpp head/contrib/llvm/tools/llc/llc.cpp head/contrib/llvm/tools/lli/lli.cpp head/contrib/llvm/tools/llvm-as/llvm-as.cpp head/contrib/llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp head/contrib/llvm/tools/llvm-diff/DiffConsumer.cpp head/contrib/llvm/tools/llvm-diff/DiffConsumer.h head/contrib/llvm/tools/llvm-diff/DifferenceEngine.cpp head/contrib/llvm/tools/llvm-diff/DifferenceEngine.h head/contrib/llvm/tools/llvm-diff/llvm-diff.cpp head/contrib/llvm/tools/llvm-dis/llvm-dis.cpp head/contrib/llvm/tools/llvm-extract/llvm-extract.cpp head/contrib/llvm/tools/llvm-ld/llvm-ld.cpp head/contrib/llvm/tools/llvm-link/llvm-link.cpp head/contrib/llvm/tools/llvm-mc/Disassembler.cpp head/contrib/llvm/tools/llvm-mc/llvm-mc.cpp head/contrib/llvm/tools/llvm-nm/llvm-nm.cpp head/contrib/llvm/tools/llvm-objdump/MachODump.cpp head/contrib/llvm/tools/llvm-objdump/llvm-objdump.cpp head/contrib/llvm/tools/llvm-objdump/llvm-objdump.h head/contrib/llvm/tools/llvm-prof/llvm-prof.cpp head/contrib/llvm/tools/llvm-rtdyld/llvm-rtdyld.cpp head/contrib/llvm/tools/opt/PrintSCC.cpp head/contrib/llvm/tools/opt/opt.cpp head/contrib/llvm/utils/TableGen/AsmMatcherEmitter.cpp head/contrib/llvm/utils/TableGen/AsmWriterEmitter.cpp head/contrib/llvm/utils/TableGen/AsmWriterEmitter.h head/contrib/llvm/utils/TableGen/CallingConvEmitter.cpp head/contrib/llvm/utils/TableGen/CodeEmitterGen.cpp head/contrib/llvm/utils/TableGen/CodeGenDAGPatterns.cpp head/contrib/llvm/utils/TableGen/CodeGenDAGPatterns.h head/contrib/llvm/utils/TableGen/CodeGenInstruction.cpp head/contrib/llvm/utils/TableGen/CodeGenRegisters.cpp head/contrib/llvm/utils/TableGen/CodeGenRegisters.h head/contrib/llvm/utils/TableGen/CodeGenTarget.cpp head/contrib/llvm/utils/TableGen/CodeGenTarget.h head/contrib/llvm/utils/TableGen/DAGISelMatcher.cpp head/contrib/llvm/utils/TableGen/DAGISelMatcher.h head/contrib/llvm/utils/TableGen/DAGISelMatcherEmitter.cpp head/contrib/llvm/utils/TableGen/DAGISelMatcherGen.cpp head/contrib/llvm/utils/TableGen/DisassemblerEmitter.cpp head/contrib/llvm/utils/TableGen/EDEmitter.cpp head/contrib/llvm/utils/TableGen/FastISelEmitter.cpp head/contrib/llvm/utils/TableGen/FixedLenDecoderEmitter.cpp head/contrib/llvm/utils/TableGen/FixedLenDecoderEmitter.h head/contrib/llvm/utils/TableGen/InstrInfoEmitter.cpp head/contrib/llvm/utils/TableGen/InstrInfoEmitter.h head/contrib/llvm/utils/TableGen/IntrinsicEmitter.cpp head/contrib/llvm/utils/TableGen/IntrinsicEmitter.h head/contrib/llvm/utils/TableGen/PseudoLoweringEmitter.cpp head/contrib/llvm/utils/TableGen/RegisterInfoEmitter.cpp head/contrib/llvm/utils/TableGen/RegisterInfoEmitter.h head/contrib/llvm/utils/TableGen/SetTheory.cpp head/contrib/llvm/utils/TableGen/SetTheory.h head/contrib/llvm/utils/TableGen/StringToOffsetTable.h head/contrib/llvm/utils/TableGen/SubtargetEmitter.cpp head/contrib/llvm/utils/TableGen/TableGen.cpp head/contrib/llvm/utils/TableGen/X86DisassemblerTables.cpp head/contrib/llvm/utils/TableGen/X86ModRMFilters.h head/contrib/llvm/utils/TableGen/X86RecognizableInstr.cpp head/contrib/llvm/utils/TableGen/X86RecognizableInstr.h head/etc/mtree/BSD.include.dist head/lib/clang/Makefile head/lib/clang/clang.build.mk head/lib/clang/include/Makefile head/lib/clang/include/clang/Basic/Version.inc head/lib/clang/include/llvm/Config/config.h head/lib/clang/include/llvm/Config/llvm-config.h head/lib/clang/libclanganalysis/Makefile head/lib/clang/libclangarcmigrate/Makefile head/lib/clang/libclangast/Makefile head/lib/clang/libclangbasic/Makefile head/lib/clang/libclangcodegen/Makefile head/lib/clang/libclangdriver/Makefile head/lib/clang/libclangfrontend/Makefile head/lib/clang/libclangindex/Makefile head/lib/clang/libclanglex/Makefile head/lib/clang/libclangparse/Makefile head/lib/clang/libclangrewrite/Makefile head/lib/clang/libclangsema/Makefile head/lib/clang/libclangserialization/Makefile head/lib/clang/libclangstaticanalyzercheckers/Makefile head/lib/clang/libclangstaticanalyzercore/Makefile head/lib/clang/libllvmanalysis/Makefile head/lib/clang/libllvmarmcodegen/Makefile head/lib/clang/libllvmarmdesc/Makefile head/lib/clang/libllvmasmprinter/Makefile head/lib/clang/libllvmcodegen/Makefile head/lib/clang/libllvmcore/Makefile head/lib/clang/libllvminstrumentation/Makefile head/lib/clang/libllvmjit/Makefile head/lib/clang/libllvmmc/Makefile head/lib/clang/libllvmmcjit/Makefile head/lib/clang/libllvmmipscodegen/Makefile head/lib/clang/libllvmmipsdesc/Makefile head/lib/clang/libllvmpowerpccodegen/Makefile head/lib/clang/libllvmpowerpcdesc/Makefile head/lib/clang/libllvmruntimedyld/Makefile head/lib/clang/libllvmscalaropts/Makefile head/lib/clang/libllvmselectiondag/Makefile head/lib/clang/libllvmsupport/Makefile head/lib/clang/libllvmtablegen/Makefile head/lib/clang/libllvmtarget/Makefile head/lib/clang/libllvmtransformutils/Makefile head/lib/clang/libllvmx86codegen/Makefile head/lib/clang/libllvmx86desc/Makefile head/share/mk/bsd.sys.mk head/usr.bin/clang/bugpoint/Makefile head/usr.bin/clang/bugpoint/bugpoint.1 head/usr.bin/clang/clang/Makefile head/usr.bin/clang/clang/clang.1 head/usr.bin/clang/llc/llc.1 head/usr.bin/clang/lli/Makefile head/usr.bin/clang/lli/lli.1 head/usr.bin/clang/llvm-ar/llvm-ar.1 head/usr.bin/clang/llvm-as/llvm-as.1 head/usr.bin/clang/llvm-bcanalyzer/llvm-bcanalyzer.1 head/usr.bin/clang/llvm-diff/llvm-diff.1 head/usr.bin/clang/llvm-dis/llvm-dis.1 head/usr.bin/clang/llvm-extract/llvm-extract.1 head/usr.bin/clang/llvm-ld/Makefile head/usr.bin/clang/llvm-ld/llvm-ld.1 head/usr.bin/clang/llvm-link/llvm-link.1 head/usr.bin/clang/llvm-nm/llvm-nm.1 head/usr.bin/clang/llvm-prof/llvm-prof.1 head/usr.bin/clang/llvm-ranlib/llvm-ranlib.1 head/usr.bin/clang/opt/Makefile head/usr.bin/clang/opt/opt.1 head/usr.bin/clang/tblgen/Makefile head/usr.bin/clang/tblgen/tblgen.1 Directory Properties: head/contrib/llvm/ (props changed) head/contrib/llvm/tools/clang/ (props changed) Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Mon Apr 16 21:22:02 2012 (r234352) +++ head/ObsoleteFiles.inc Mon Apr 16 21:23:25 2012 (r234353) @@ -38,6 +38,22 @@ # xargs -n1 | sort | uniq -d; # done +# 20120415: new clang import which bumps version from 3.0 to 3.1 +OLD_FILES+=usr/include/clang/3.0/altivec.h +OLD_FILES+=usr/include/clang/3.0/avxintrin.h +OLD_FILES+=usr/include/clang/3.0/emmintrin.h +OLD_FILES+=usr/include/clang/3.0/immintrin.h +OLD_FILES+=usr/include/clang/3.0/mm3dnow.h +OLD_FILES+=usr/include/clang/3.0/mm_malloc.h +OLD_FILES+=usr/include/clang/3.0/mmintrin.h +OLD_FILES+=usr/include/clang/3.0/nmmintrin.h +OLD_FILES+=usr/include/clang/3.0/pmmintrin.h +OLD_FILES+=usr/include/clang/3.0/smmintrin.h +OLD_FILES+=usr/include/clang/3.0/tmmintrin.h +OLD_FILES+=usr/include/clang/3.0/wmmintrin.h +OLD_FILES+=usr/include/clang/3.0/x86intrin.h +OLD_FILES+=usr/include/clang/3.0/xmmintrin.h +OLD_DIRS+=usr/include/clang/3.0 # 20120322: Update heimdal to 1.5.1. OLD_FILES+=usr/include/krb5-v4compat.h \ usr/include/krb_err.h \ Modified: head/contrib/llvm/LICENSE.TXT ============================================================================== --- head/contrib/llvm/LICENSE.TXT Mon Apr 16 21:22:02 2012 (r234352) +++ head/contrib/llvm/LICENSE.TXT Mon Apr 16 21:23:25 2012 (r234353) @@ -4,7 +4,7 @@ LLVM Release License University of Illinois/NCSA Open Source License -Copyright (c) 2003-2011 University of Illinois at Urbana-Champaign. +Copyright (c) 2003-2012 University of Illinois at Urbana-Champaign. All rights reserved. Developed by: @@ -67,3 +67,4 @@ Autoconf llvm/autoconf CellSPU backend llvm/lib/Target/CellSPU/README.txt Google Test llvm/utils/unittest/googletest OpenBSD regex llvm/lib/Support/{reg*, COPYRIGHT.regex} +pyyaml tests llvm/test/YAMLParser/{*.data, LICENSE.TXT} Modified: head/contrib/llvm/include/llvm-c/Analysis.h ============================================================================== --- head/contrib/llvm/include/llvm-c/Analysis.h Mon Apr 16 21:22:02 2012 (r234352) +++ head/contrib/llvm/include/llvm-c/Analysis.h Mon Apr 16 21:23:25 2012 (r234353) @@ -25,6 +25,12 @@ extern "C" { #endif +/** + * @defgroup LLVMCAnalysis Analysis + * @ingroup LLVMC + * + * @{ + */ typedef enum { LLVMAbortProcessAction, /* verifier will print to stderr and abort() */ @@ -48,6 +54,10 @@ LLVMBool LLVMVerifyFunction(LLVMValueRef void LLVMViewFunctionCFG(LLVMValueRef Fn); void LLVMViewFunctionCFGOnly(LLVMValueRef Fn); +/** + * @} + */ + #ifdef __cplusplus } #endif Modified: head/contrib/llvm/include/llvm-c/BitReader.h ============================================================================== --- head/contrib/llvm/include/llvm-c/BitReader.h Mon Apr 16 21:22:02 2012 (r234352) +++ head/contrib/llvm/include/llvm-c/BitReader.h Mon Apr 16 21:23:25 2012 (r234353) @@ -25,6 +25,12 @@ extern "C" { #endif +/** + * @defgroup LLVMCBitReader Bit Reader + * @ingroup LLVMC + * + * @{ + */ /* Builds a module from the bitcode in the specified memory buffer, returning a reference to the module via the OutModule parameter. Returns 0 on success. @@ -59,6 +65,10 @@ LLVMBool LLVMGetBitcodeModuleProvider(LL LLVMModuleProviderRef *OutMP, char **OutMessage); +/** + * @} + */ + #ifdef __cplusplus } #endif Modified: head/contrib/llvm/include/llvm-c/BitWriter.h ============================================================================== --- head/contrib/llvm/include/llvm-c/BitWriter.h Mon Apr 16 21:22:02 2012 (r234352) +++ head/contrib/llvm/include/llvm-c/BitWriter.h Mon Apr 16 21:23:25 2012 (r234353) @@ -25,6 +25,12 @@ extern "C" { #endif +/** + * @defgroup LLVMCBitWriter Bit Writer + * @ingroup LLVMC + * + * @{ + */ /*===-- Operations on modules ---------------------------------------------===*/ @@ -39,6 +45,10 @@ int LLVMWriteBitcodeToFD(LLVMModuleRef M descriptor. Returns 0 on success. Closes the Handle. */ int LLVMWriteBitcodeToFileHandle(LLVMModuleRef M, int Handle); +/** + * @} + */ + #ifdef __cplusplus } #endif Modified: head/contrib/llvm/include/llvm-c/Core.h ============================================================================== --- head/contrib/llvm/include/llvm-c/Core.h Mon Apr 16 21:22:02 2012 (r234352) +++ head/contrib/llvm/include/llvm-c/Core.h Mon Apr 16 21:23:25 2012 (r234353) @@ -10,24 +10,6 @@ |* This header declares the C interface to libLLVMCore.a, which implements *| |* the LLVM intermediate representation. *| |* *| -|* LLVM uses a polymorphic type hierarchy which C cannot represent, therefore *| -|* parameters must be passed as base types. Despite the declared types, most *| -|* of the functions provided operate only on branches of the type hierarchy. *| -|* The declared parameter names are descriptive and specify which type is *| -|* required. Additionally, each type hierarchy is documented along with the *| -|* functions that operate upon it. For more detail, refer to LLVM's C++ code. *| -|* If in doubt, refer to Core.cpp, which performs paramter downcasts in the *| -|* form unwrap(Param). *| -|* *| -|* Many exotic languages can interoperate with C code but have a harder time *| -|* with C++ due to name mangling. So in addition to C, this interface enables *| -|* tools written in such languages. *| -|* *| -|* When included into a C++ source file, also declares 'wrap' and 'unwrap' *| -|* helpers to perform opaque reference<-->pointer conversions. These helpers *| -|* are shorter and more tightly typed than writing the casts by hand when *| -|* authoring bindings. In assert builds, they will do runtime type checking. *| -|* *| \*===----------------------------------------------------------------------===*/ #ifndef LLVM_C_CORE_H @@ -46,50 +28,121 @@ extern "C" { #endif +/** + * @defgroup LLVMC LLVM-C: C interface to LLVM + * + * This module exposes parts of the LLVM library as a C API. + * + * @{ + */ + +/** + * @defgroup LLVMCTransforms Transforms + */ + +/** + * @defgroup LLVMCCore Core + * + * This modules provide an interface to libLLVMCore, which implements + * the LLVM intermediate representation as well as other related types + * and utilities. + * + * LLVM uses a polymorphic type hierarchy which C cannot represent, therefore + * parameters must be passed as base types. Despite the declared types, most + * of the functions provided operate only on branches of the type hierarchy. + * The declared parameter names are descriptive and specify which type is + * required. Additionally, each type hierarchy is documented along with the + * functions that operate upon it. For more detail, refer to LLVM's C++ code. + * If in doubt, refer to Core.cpp, which performs paramter downcasts in the + * form unwrap(Param). + * + * Many exotic languages can interoperate with C code but have a harder time + * with C++ due to name mangling. So in addition to C, this interface enables + * tools written in such languages. + * + * When included into a C++ source file, also declares 'wrap' and 'unwrap' + * helpers to perform opaque reference<-->pointer conversions. These helpers + * are shorter and more tightly typed than writing the casts by hand when + * authoring bindings. In assert builds, they will do runtime type checking. + * + * @{ + */ + +/** + * @defgroup LLVMCCoreTypes Types and Enumerations + * + * @{ + */ typedef int LLVMBool; /* Opaque types. */ /** - * The top-level container for all LLVM global data. See the LLVMContext class. + * The top-level container for all LLVM global data. See the LLVMContext class. */ typedef struct LLVMOpaqueContext *LLVMContextRef; /** * The top-level container for all other LLVM Intermediate Representation (IR) - * objects. See the llvm::Module class. + * objects. + * + * @see llvm::Module */ typedef struct LLVMOpaqueModule *LLVMModuleRef; /** - * Each value in the LLVM IR has a type, an LLVMTypeRef. See the llvm::Type - * class. + * Each value in the LLVM IR has a type, an LLVMTypeRef. + * + * @see llvm::Type */ typedef struct LLVMOpaqueType *LLVMTypeRef; +/** + * Represents an individual value in LLVM IR. + * + * This models llvm::Value. + */ typedef struct LLVMOpaqueValue *LLVMValueRef; + +/** + * Represents a basic block of instruction in LLVM IR. + * + * This models llvm::BasicBlock. + */ typedef struct LLVMOpaqueBasicBlock *LLVMBasicBlockRef; + +/** + * Represents an LLVM basic block builder. + * + * This models llvm::IRBuilder. + */ typedef struct LLVMOpaqueBuilder *LLVMBuilderRef; -/* Interface used to provide a module to JIT or interpreter. This is now just a - * synonym for llvm::Module, but we have to keep using the different type to - * keep binary compatibility. +/** + * Interface used to provide a module to JIT or interpreter. + * This is now just a synonym for llvm::Module, but we have to keep using the + * different type to keep binary compatibility. */ typedef struct LLVMOpaqueModuleProvider *LLVMModuleProviderRef; -/* Used to provide a module to JIT or interpreter. - * See the llvm::MemoryBuffer class. +/** + * Used to provide a module to JIT or interpreter. + * + * @see llvm::MemoryBuffer */ typedef struct LLVMOpaqueMemoryBuffer *LLVMMemoryBufferRef; -/** See the llvm::PassManagerBase class. */ +/** @see llvm::PassManagerBase */ typedef struct LLVMOpaquePassManager *LLVMPassManagerRef; -/** See the llvm::PassRegistry class. */ +/** @see llvm::PassRegistry */ typedef struct LLVMOpaquePassRegistry *LLVMPassRegistryRef; -/** Used to get the users and usees of a Value. See the llvm::Use class. */ +/** + * Used to get the users and usees of a Value. + * + * @see llvm::Use */ typedef struct LLVMOpaqueUse *LLVMUseRef; typedef enum { @@ -119,6 +172,11 @@ typedef enum { LLVMReturnsTwice = 1 << 29, LLVMUWTable = 1 << 30, LLVMNonLazyBind = 1 << 31 + + // FIXME: This attribute is currently not included in the C API as + // a temporary measure until the API/ABI impact to the C API is understood + // and the path forward agreed upon. + //LLVMAddressSafety = 1ULL << 32 } LLVMAttribute; typedef enum { @@ -195,14 +253,13 @@ typedef enum { /* Exception Handling Operators */ LLVMResume = 58, - LLVMLandingPad = 59, - LLVMUnwind = 60 - + LLVMLandingPad = 59 } LLVMOpcode; typedef enum { LLVMVoidTypeKind, /**< type with no size */ + LLVMHalfTypeKind, /**< 16 bit floating point type */ LLVMFloatTypeKind, /**< 32 bit floating point type */ LLVMDoubleTypeKind, /**< 64 bit floating point type */ LLVMX86_FP80TypeKind, /**< 80 bit floating point type (X87) */ @@ -294,6 +351,10 @@ typedef enum { LLVMLandingPadFilter /**< A filter clause */ } LLVMLandingPadClauseTy; +/** + * @} + */ + void LLVMInitializeCore(LLVMPassRegistryRef R); @@ -302,49 +363,233 @@ void LLVMInitializeCore(LLVMPassRegistry void LLVMDisposeMessage(char *Message); -/*===-- Contexts ----------------------------------------------------------===*/ +/** + * @defgroup LLVMCCoreContext Contexts + * + * Contexts are execution states for the core LLVM IR system. + * + * Most types are tied to a context instance. Multiple contexts can + * exist simultaneously. A single context is not thread safe. However, + * different contexts can execute on different threads simultaneously. + * + * @{ + */ -/* Create and destroy contexts. */ +/** + * Create a new context. + * + * Every call to this function should be paired with a call to + * LLVMContextDispose() or the context will leak memory. + */ LLVMContextRef LLVMContextCreate(void); + +/** + * Obtain the global context instance. + */ LLVMContextRef LLVMGetGlobalContext(void); + +/** + * Destroy a context instance. + * + * This should be called for every call to LLVMContextCreate() or memory + * will be leaked. + */ void LLVMContextDispose(LLVMContextRef C); unsigned LLVMGetMDKindIDInContext(LLVMContextRef C, const char* Name, unsigned SLen); unsigned LLVMGetMDKindID(const char* Name, unsigned SLen); -/*===-- Modules -----------------------------------------------------------===*/ +/** + * @} + */ + +/** + * @defgroup LLVMCCoreModule Modules + * + * Modules represent the top-level structure in a LLVM program. An LLVM + * module is effectively a translation unit or a collection of + * translation units merged together. + * + * @{ + */ -/* Create and destroy modules. */ -/** See llvm::Module::Module. */ +/** + * Create a new, empty module in the global context. + * + * This is equivalent to calling LLVMModuleCreateWithNameInContext with + * LLVMGetGlobalContext() as the context parameter. + * + * Every invocation should be paired with LLVMDisposeModule() or memory + * will be leaked. + */ LLVMModuleRef LLVMModuleCreateWithName(const char *ModuleID); + +/** + * Create a new, empty module in a specific context. + * + * Every invocation should be paired with LLVMDisposeModule() or memory + * will be leaked. + */ LLVMModuleRef LLVMModuleCreateWithNameInContext(const char *ModuleID, LLVMContextRef C); -/** See llvm::Module::~Module. */ +/** + * Destroy a module instance. + * + * This must be called for every created module or memory will be + * leaked. + */ void LLVMDisposeModule(LLVMModuleRef M); -/** Data layout. See Module::getDataLayout. */ +/** + * Obtain the data layout for a module. + * + * @see Module::getDataLayout() + */ const char *LLVMGetDataLayout(LLVMModuleRef M); + +/** + * Set the data layout for a module. + * + * @see Module::setDataLayout() + */ void LLVMSetDataLayout(LLVMModuleRef M, const char *Triple); -/** Target triple. See Module::getTargetTriple. */ +/** + * Obtain the target triple for a module. + * + * @see Module::getTargetTriple() + */ const char *LLVMGetTarget(LLVMModuleRef M); + +/** + * Set the target triple for a module. + * + * @see Module::setTargetTriple() + */ void LLVMSetTarget(LLVMModuleRef M, const char *Triple); -/** See Module::dump. */ +/** + * Dump a representation of a module to stderr. + * + * @see Module::dump() + */ void LLVMDumpModule(LLVMModuleRef M); -/** See Module::setModuleInlineAsm. */ +/** + * Set inline assembly for a module. + * + * @see Module::setModuleInlineAsm() + */ void LLVMSetModuleInlineAsm(LLVMModuleRef M, const char *Asm); -/** See Module::getContext. */ +/** + * Obtain the context to which this module is associated. + * + * @see Module::getContext() + */ LLVMContextRef LLVMGetModuleContext(LLVMModuleRef M); -/*===-- Types -------------------------------------------------------------===*/ +/** + * Obtain a Type from a module by its registered name. + */ +LLVMTypeRef LLVMGetTypeByName(LLVMModuleRef M, const char *Name); + +/** + * Obtain the number of operands for named metadata in a module. + * + * @see llvm::Module::getNamedMetadata() + */ +unsigned LLVMGetNamedMetadataNumOperands(LLVMModuleRef M, const char* name); + +/** + * Obtain the named metadata operands for a module. + * + * The passed LLVMValueRef pointer should refer to an array of + * LLVMValueRef at least LLVMGetNamedMetadataNumOperands long. This + * array will be populated with the LLVMValueRef instances. Each + * instance corresponds to a llvm::MDNode. + * + * @see llvm::Module::getNamedMetadata() + * @see llvm::MDNode::getOperand() + */ +void LLVMGetNamedMetadataOperands(LLVMModuleRef M, const char* name, LLVMValueRef *Dest); + +/** + * Add an operand to named metadata. + * + * @see llvm::Module::getNamedMetadata() + * @see llvm::MDNode::addOperand() + */ +void LLVMAddNamedMetadataOperand(LLVMModuleRef M, const char* name, + LLVMValueRef Val); + +/** + * Add a function to a module under a specified name. + * + * @see llvm::Function::Create() + */ +LLVMValueRef LLVMAddFunction(LLVMModuleRef M, const char *Name, + LLVMTypeRef FunctionTy); + +/** + * Obtain a Function value from a Module by its name. + * + * The returned value corresponds to a llvm::Function value. + * + * @see llvm::Module::getFunction() + */ +LLVMValueRef LLVMGetNamedFunction(LLVMModuleRef M, const char *Name); + +/** + * Obtain an iterator to the first Function in a Module. + * + * @see llvm::Module::begin() + */ +LLVMValueRef LLVMGetFirstFunction(LLVMModuleRef M); + +/** + * Obtain an iterator to the last Function in a Module. + * + * @see llvm::Module::end() + */ +LLVMValueRef LLVMGetLastFunction(LLVMModuleRef M); + +/** + * Advance a Function iterator to the next Function. + * + * Returns NULL if the iterator was already at the end and there are no more + * functions. + */ +LLVMValueRef LLVMGetNextFunction(LLVMValueRef Fn); + +/** + * Decrement a Function iterator to the previous Function. + * + * Returns NULL if the iterator was already at the beginning and there are + * no previous functions. + */ +LLVMValueRef LLVMGetPreviousFunction(LLVMValueRef Fn); + +/** + * @} + */ -/* LLVM types conform to the following hierarchy: - * +/** + * @defgroup LLVMCCoreType Types + * + * Types represent the type of a value. + * + * Types are associated with a context instance. The context internally + * deduplicates types so there is only 1 instance of a specific type + * alive at a time. In other words, a unique type is shared among all + * consumers within a context. + * + * A Type in the C API corresponds to llvm::Type. + * + * Types have the following hierarchy: + * * types: * integer type * real type @@ -356,16 +601,44 @@ LLVMContextRef LLVMGetModuleContext(LLVM * void type * label type * opaque type + * + * @{ */ -/** See llvm::LLVMTypeKind::getTypeID. */ +/** + * Obtain the enumerated type of a Type instance. + * + * @see llvm::Type:getTypeID() + */ LLVMTypeKind LLVMGetTypeKind(LLVMTypeRef Ty); + +/** + * Whether the type has a known size. + * + * Things that don't have a size are abstract types, labels, and void.a + * + * @see llvm::Type::isSized() + */ LLVMBool LLVMTypeIsSized(LLVMTypeRef Ty); -/** See llvm::LLVMType::getContext. */ +/** + * Obtain the context to which this type instance is associated. + * + * @see llvm::Type::getContext() + */ LLVMContextRef LLVMGetTypeContext(LLVMTypeRef Ty); -/* Operations on integer types */ +/** + * @defgroup LLVMCCoreTypeInt Integer Types + * + * Functions in this section operate on integer types. + * + * @{ + */ + +/** + * Obtain an integer type from a context with specified bit width. + */ LLVMTypeRef LLVMInt1TypeInContext(LLVMContextRef C); LLVMTypeRef LLVMInt8TypeInContext(LLVMContextRef C); LLVMTypeRef LLVMInt16TypeInContext(LLVMContextRef C); @@ -373,6 +646,10 @@ LLVMTypeRef LLVMInt32TypeInContext(LLVMC LLVMTypeRef LLVMInt64TypeInContext(LLVMContextRef C); LLVMTypeRef LLVMIntTypeInContext(LLVMContextRef C, unsigned NumBits); +/** + * Obtain an integer type from the global context with a specified bit + * width. + */ LLVMTypeRef LLVMInt1Type(void); LLVMTypeRef LLVMInt8Type(void); LLVMTypeRef LLVMInt16Type(void); @@ -381,68 +658,336 @@ LLVMTypeRef LLVMInt64Type(void); LLVMTypeRef LLVMIntType(unsigned NumBits); unsigned LLVMGetIntTypeWidth(LLVMTypeRef IntegerTy); -/* Operations on real types */ +/** + * @} + */ + +/** + * @defgroup LLVMCCoreTypeFloat Floating Point Types + * + * @{ + */ + +/** + * Obtain a 16-bit floating point type from a context. + */ +LLVMTypeRef LLVMHalfTypeInContext(LLVMContextRef C); + +/** + * Obtain a 32-bit floating point type from a context. + */ LLVMTypeRef LLVMFloatTypeInContext(LLVMContextRef C); + +/** + * Obtain a 64-bit floating point type from a context. + */ LLVMTypeRef LLVMDoubleTypeInContext(LLVMContextRef C); + +/** + * Obtain a 80-bit floating point type (X87) from a context. + */ LLVMTypeRef LLVMX86FP80TypeInContext(LLVMContextRef C); + +/** + * Obtain a 128-bit floating point type (112-bit mantissa) from a + * context. + */ LLVMTypeRef LLVMFP128TypeInContext(LLVMContextRef C); + +/** + * Obtain a 128-bit floating point type (two 64-bits) from a context. + */ LLVMTypeRef LLVMPPCFP128TypeInContext(LLVMContextRef C); +/** + * Obtain a floating point type from the global context. + * + * These map to the functions in this group of the same name. + */ +LLVMTypeRef LLVMHalfType(void); LLVMTypeRef LLVMFloatType(void); LLVMTypeRef LLVMDoubleType(void); LLVMTypeRef LLVMX86FP80Type(void); LLVMTypeRef LLVMFP128Type(void); LLVMTypeRef LLVMPPCFP128Type(void); -/* Operations on function types */ +/** + * @} + */ + +/** + * @defgroup LLVMCCoreTypeFunction Function Types + * + * @{ + */ + +/** + * Obtain a function type consisting of a specified signature. + * + * The function is defined as a tuple of a return Type, a list of + * parameter types, and whether the function is variadic. + */ LLVMTypeRef LLVMFunctionType(LLVMTypeRef ReturnType, LLVMTypeRef *ParamTypes, unsigned ParamCount, LLVMBool IsVarArg); + +/** + * Returns whether a function type is variadic. + */ LLVMBool LLVMIsFunctionVarArg(LLVMTypeRef FunctionTy); + +/** + * Obtain the Type this function Type returns. + */ LLVMTypeRef LLVMGetReturnType(LLVMTypeRef FunctionTy); + +/** + * Obtain the number of parameters this function accepts. + */ unsigned LLVMCountParamTypes(LLVMTypeRef FunctionTy); + +/** + * Obtain the types of a function's parameters. + * + * The Dest parameter should point to a pre-allocated array of + * LLVMTypeRef at least LLVMCountParamTypes() large. On return, the + * first LLVMCountParamTypes() entries in the array will be populated + * with LLVMTypeRef instances. + * + * @param FunctionTy The function type to operate on. + * @param Dest Memory address of an array to be filled with result. + */ void LLVMGetParamTypes(LLVMTypeRef FunctionTy, LLVMTypeRef *Dest); -/* Operations on struct types */ +/** + * @} + */ + +/** + * @defgroup LLVMCCoreTypeStruct Structure Types + * + * These functions relate to LLVMTypeRef instances. + * + * @see llvm::StructType + * + * @{ + */ + +/** + * Create a new structure type in a context. + * + * A structure is specified by a list of inner elements/types and + * whether these can be packed together. + * + * @see llvm::StructType::create() + */ LLVMTypeRef LLVMStructTypeInContext(LLVMContextRef C, LLVMTypeRef *ElementTypes, unsigned ElementCount, LLVMBool Packed); + +/** + * Create a new structure type in the global context. + * + * @see llvm::StructType::create() + */ LLVMTypeRef LLVMStructType(LLVMTypeRef *ElementTypes, unsigned ElementCount, LLVMBool Packed); + +/** + * Create an empty structure in a context having a specified name. + * + * @see llvm::StructType::create() + */ LLVMTypeRef LLVMStructCreateNamed(LLVMContextRef C, const char *Name); + +/** + * Obtain the name of a structure. + * + * @see llvm::StructType::getName() + */ const char *LLVMGetStructName(LLVMTypeRef Ty); + +/** + * Set the contents of a structure type. + * + * @see llvm::StructType::setBody() + */ void LLVMStructSetBody(LLVMTypeRef StructTy, LLVMTypeRef *ElementTypes, unsigned ElementCount, LLVMBool Packed); +/** + * Get the number of elements defined inside the structure. + * + * @see llvm::StructType::getNumElements() + */ unsigned LLVMCountStructElementTypes(LLVMTypeRef StructTy); + +/** + * Get the elements within a structure. + * + * The function is passed the address of a pre-allocated array of + * LLVMTypeRef at least LLVMCountStructElementTypes() long. After + * invocation, this array will be populated with the structure's + * elements. The objects in the destination array will have a lifetime + * of the structure type itself, which is the lifetime of the context it + * is contained in. + */ void LLVMGetStructElementTypes(LLVMTypeRef StructTy, LLVMTypeRef *Dest); + +/** + * Determine whether a structure is packed. + * + * @see llvm::StructType::isPacked() + */ LLVMBool LLVMIsPackedStruct(LLVMTypeRef StructTy); + +/** + * Determine whether a structure is opaque. + * + * @see llvm::StructType::isOpaque() + */ LLVMBool LLVMIsOpaqueStruct(LLVMTypeRef StructTy); -LLVMTypeRef LLVMGetTypeByName(LLVMModuleRef M, const char *Name); +/** + * @} + */ -/* Operations on array, pointer, and vector types (sequence types) */ -LLVMTypeRef LLVMArrayType(LLVMTypeRef ElementType, unsigned ElementCount); -LLVMTypeRef LLVMPointerType(LLVMTypeRef ElementType, unsigned AddressSpace); -LLVMTypeRef LLVMVectorType(LLVMTypeRef ElementType, unsigned ElementCount); +/** + * @defgroup LLVMCCoreTypeSequential Sequential Types + * + * Sequential types represents "arrays" of types. This is a super class + * for array, vector, and pointer types. + * + * @{ + */ + +/** + * Obtain the type of elements within a sequential type. + * + * This works on array, vector, and pointer types. + * + * @see llvm::SequentialType::getElementType() + */ LLVMTypeRef LLVMGetElementType(LLVMTypeRef Ty); + +/** + * Create a fixed size array type that refers to a specific type. + * + * The created type will exist in the context that its element type + * exists in. + * + * @see llvm::ArrayType::get() + */ +LLVMTypeRef LLVMArrayType(LLVMTypeRef ElementType, unsigned ElementCount); + +/** + * Obtain the length of an array type. + * + * This only works on types that represent arrays. + * + * @see llvm::ArrayType::getNumElements() + */ unsigned LLVMGetArrayLength(LLVMTypeRef ArrayTy); + +/** + * Create a pointer type that points to a defined type. + * + * The created type will exist in the context that its pointee type + * exists in. + * + * @see llvm::PointerType::get() + */ +LLVMTypeRef LLVMPointerType(LLVMTypeRef ElementType, unsigned AddressSpace); + +/** + * Obtain the address space of a pointer type. + * + * This only works on types that represent pointers. + * + * @see llvm::PointerType::getAddressSpace() + */ unsigned LLVMGetPointerAddressSpace(LLVMTypeRef PointerTy); + +/** + * Create a vector type that contains a defined type and has a specific + * number of elements. + * + * The created type will exist in the context thats its element type + * exists in. + * + * @see llvm::VectorType::get() + */ +LLVMTypeRef LLVMVectorType(LLVMTypeRef ElementType, unsigned ElementCount); + +/** + * Obtain the number of elements in a vector type. + * + * This only works on types that represent vectors. + * + * @see llvm::VectorType::getNumElements() + */ unsigned LLVMGetVectorSize(LLVMTypeRef VectorTy); -/* Operations on other types */ +/** + * @} + */ + +/** + * @defgroup LLVMCCoreTypeOther Other Types + * + * @{ + */ + +/** + * Create a void type in a context. + */ LLVMTypeRef LLVMVoidTypeInContext(LLVMContextRef C); + +/** + * Create a label type in a context. + */ LLVMTypeRef LLVMLabelTypeInContext(LLVMContextRef C); + +/** + * Create a X86 MMX type in a context. + */ LLVMTypeRef LLVMX86MMXTypeInContext(LLVMContextRef C); +/** + * These are similar to the above functions except they operate on the + * global context. + */ LLVMTypeRef LLVMVoidType(void); LLVMTypeRef LLVMLabelType(void); LLVMTypeRef LLVMX86MMXType(void); -/*===-- Values ------------------------------------------------------------===*/ +/** + * @} + */ + +/** + * @} + */ -/* The bulk of LLVM's object model consists of values, which comprise a very +/** + * @defgroup LLVMCCoreValues Values + * + * The bulk of LLVM's object model consists of values, which comprise a very * rich type hierarchy. + * + * LLVMValueRef essentially represents llvm::Value. There is a rich + * hierarchy of classes within this type. Depending on the instance + * obtain, not all APIs are available. + * + * Callers can determine the type of a LLVMValueRef by calling the + * LLVMIsA* family of functions (e.g. LLVMIsAArgument()). These + * functions are defined by a macro, so it isn't obvious which are + * available by looking at the Doxygen source code. Instead, look at the + * source definition of LLVM_FOR_EACH_VALUE_SUBCLASS and note the list + * of value names given. These value names also correspond to classes in + * the llvm::Value hierarchy. + * + * @{ */ #define LLVM_FOR_EACH_VALUE_SUBCLASS(macro) \ @@ -473,8 +1018,6 @@ LLVMTypeRef LLVMX86MMXType(void); macro(IntrinsicInst) \ macro(DbgInfoIntrinsic) \ macro(DbgDeclareInst) \ - macro(EHExceptionInst) \ - macro(EHSelectorInst) \ macro(MemIntrinsic) \ macro(MemCpyInst) \ macro(MemMoveInst) \ @@ -518,92 +1061,399 @@ LLVMTypeRef LLVMX86MMXType(void); macro(LoadInst) \ macro(VAArgInst) -/* Operations on all values */ -LLVMTypeRef LLVMTypeOf(LLVMValueRef Val); +/** + * @defgroup LLVMCCoreValueGeneral General APIs + * + * Functions in this section work on all LLVMValueRef instances, + * regardless of their sub-type. They correspond to functions available + * on llvm::Value. + * + * @{ + */ + *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 21:24:24 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 11D511065687; Mon, 16 Apr 2012 21:24:24 +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 EFADF8FC15; Mon, 16 Apr 2012 21:24:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GLONKL051211; Mon, 16 Apr 2012 21:24:23 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GLONgW051200; Mon, 16 Apr 2012 21:24:23 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204162124.q3GLONgW051200@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 21:24: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: r234354 - in head/sys: amd64/linux32 i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 21:24:24 -0000 Author: jkim Date: Mon Apr 16 21:24:23 2012 New Revision: 234354 URL: http://svn.freebsd.org/changeset/base/234354 Log: Regen for r234352. Modified: head/sys/amd64/linux32/linux32_proto.h head/sys/amd64/linux32/linux32_syscall.h head/sys/amd64/linux32/linux32_syscalls.c head/sys/amd64/linux32/linux32_sysent.c head/sys/amd64/linux32/linux32_systrace_args.c head/sys/i386/linux/linux_proto.h head/sys/i386/linux/linux_syscall.h head/sys/i386/linux/linux_syscalls.c head/sys/i386/linux/linux_sysent.c head/sys/i386/linux/linux_systrace_args.c Modified: head/sys/amd64/linux32/linux32_proto.h ============================================================================== --- head/sys/amd64/linux32/linux32_proto.h Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/amd64/linux32/linux32_proto.h Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ #ifndef _LINUX_SYSPROTO_H_ @@ -153,7 +153,7 @@ struct linux_rmdir_args { char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; }; struct linux_pipe_args { - char pipefds_l_[PADL_(l_ulong *)]; l_ulong * pipefds; char pipefds_r_[PADR_(l_ulong *)]; + char pipefds_l_[PADL_(l_int *)]; l_int * pipefds; char pipefds_r_[PADR_(l_int *)]; }; struct linux_times_args { char buf_l_[PADL_(struct l_times_argv *)]; struct l_times_argv * buf; char buf_r_[PADR_(struct l_times_argv *)]; @@ -1046,7 +1046,8 @@ struct linux_dup3_args { register_t dummy; }; struct linux_pipe2_args { - register_t dummy; + char pipefds_l_[PADL_(l_int *)]; l_int * pipefds; char pipefds_r_[PADR_(l_int *)]; + char flags_l_[PADL_(l_int)]; l_int flags; char flags_r_[PADR_(l_int)]; }; struct linux_inotify_init1_args { register_t dummy; Modified: head/sys/amd64/linux32/linux32_syscall.h ============================================================================== --- head/sys/amd64/linux32/linux32_syscall.h Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/amd64/linux32/linux32_syscall.h Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ #define LINUX_SYS_exit 1 Modified: head/sys/amd64/linux32/linux32_syscalls.c ============================================================================== --- head/sys/amd64/linux32/linux32_syscalls.c Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/amd64/linux32/linux32_syscalls.c Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ const char *linux_syscallnames[] = { Modified: head/sys/amd64/linux32/linux32_sysent.c ============================================================================== --- head/sys/amd64/linux32/linux32_sysent.c Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/amd64/linux32/linux32_sysent.c Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ #include "opt_compat.h" @@ -350,7 +350,7 @@ struct sysent linux_sysent[] = { { 0, (sy_call_t *)linux_eventfd2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 328 = linux_eventfd2 */ { 0, (sy_call_t *)linux_epoll_create1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 329 = linux_epoll_create1 */ { 0, (sy_call_t *)linux_dup3, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 330 = linux_dup3 */ - { 0, (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 331 = linux_pipe2 */ + { AS(linux_pipe2_args), (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 331 = linux_pipe2 */ { 0, (sy_call_t *)linux_inotify_init1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 332 = linux_inotify_init1 */ { 0, (sy_call_t *)linux_preadv, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 333 = linux_preadv */ { 0, (sy_call_t *)linux_pwritev, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 334 = linux_pwritev */ Modified: head/sys/amd64/linux32/linux32_systrace_args.c ============================================================================== --- head/sys/amd64/linux32/linux32_systrace_args.c Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/amd64/linux32/linux32_systrace_args.c Mon Apr 16 21:24:23 2012 (r234354) @@ -287,7 +287,7 @@ systrace_args(int sysnum, void *params, /* linux_pipe */ case 42: { struct linux_pipe_args *p = params; - uarg[0] = (intptr_t) p->pipefds; /* l_ulong * */ + uarg[0] = (intptr_t) p->pipefds; /* l_int * */ *n_args = 1; break; } @@ -2172,7 +2172,10 @@ systrace_args(int sysnum, void *params, } /* linux_pipe2 */ case 331: { - *n_args = 0; + struct linux_pipe2_args *p = params; + uarg[0] = (intptr_t) p->pipefds; /* l_int * */ + iarg[1] = p->flags; /* l_int */ + *n_args = 2; break; } /* linux_inotify_init1 */ @@ -2689,7 +2692,7 @@ systrace_entry_setargdesc(int sysnum, in case 42: switch(ndx) { case 0: - p = "l_ulong *"; + p = "l_int *"; break; default: break; @@ -5368,6 +5371,16 @@ systrace_entry_setargdesc(int sysnum, in break; /* linux_pipe2 */ case 331: + switch(ndx) { + case 0: + p = "l_int *"; + break; + case 1: + p = "l_int"; + break; + default: + break; + }; break; /* linux_inotify_init1 */ case 332: @@ -6621,6 +6634,9 @@ systrace_return_setargdesc(int sysnum, i case 330: /* linux_pipe2 */ case 331: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_inotify_init1 */ case 332: /* linux_preadv */ Modified: head/sys/i386/linux/linux_proto.h ============================================================================== --- head/sys/i386/linux/linux_proto.h Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/i386/linux/linux_proto.h Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ #ifndef _LINUX_SYSPROTO_H_ @@ -157,7 +157,7 @@ struct linux_rmdir_args { char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; }; struct linux_pipe_args { - char pipefds_l_[PADL_(l_ulong *)]; l_ulong * pipefds; char pipefds_r_[PADR_(l_ulong *)]; + char pipefds_l_[PADL_(l_int *)]; l_int * pipefds; char pipefds_r_[PADR_(l_int *)]; }; struct linux_times_args { char buf_l_[PADL_(struct l_times_argv *)]; struct l_times_argv * buf; char buf_r_[PADR_(struct l_times_argv *)]; @@ -1065,7 +1065,8 @@ struct linux_dup3_args { register_t dummy; }; struct linux_pipe2_args { - register_t dummy; + char pipefds_l_[PADL_(l_int *)]; l_int * pipefds; char pipefds_r_[PADR_(l_int *)]; + char flags_l_[PADL_(l_int)]; l_int flags; char flags_r_[PADR_(l_int)]; }; struct linux_inotify_init1_args { register_t dummy; Modified: head/sys/i386/linux/linux_syscall.h ============================================================================== --- head/sys/i386/linux/linux_syscall.h Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/i386/linux/linux_syscall.h Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ #define LINUX_SYS_exit 1 Modified: head/sys/i386/linux/linux_syscalls.c ============================================================================== --- head/sys/i386/linux/linux_syscalls.c Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/i386/linux/linux_syscalls.c Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ const char *linux_syscallnames[] = { Modified: head/sys/i386/linux/linux_sysent.c ============================================================================== --- head/sys/i386/linux/linux_sysent.c Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/i386/linux/linux_sysent.c Mon Apr 16 21:24:23 2012 (r234354) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 232799 2012-03-10 23:10:18Z netchild + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim */ #include @@ -349,7 +349,7 @@ struct sysent linux_sysent[] = { { 0, (sy_call_t *)linux_eventfd2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 328 = linux_eventfd2 */ { 0, (sy_call_t *)linux_epoll_create1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 329 = linux_epoll_create1 */ { 0, (sy_call_t *)linux_dup3, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 330 = linux_dup3 */ - { 0, (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 331 = linux_pipe2 */ + { AS(linux_pipe2_args), (sy_call_t *)linux_pipe2, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 331 = linux_pipe2 */ { 0, (sy_call_t *)linux_inotify_init1, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 332 = linux_inotify_init1 */ { 0, (sy_call_t *)linux_preadv, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 333 = linux_preadv */ { 0, (sy_call_t *)linux_pwritev, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 334 = linux_pwritev */ Modified: head/sys/i386/linux/linux_systrace_args.c ============================================================================== --- head/sys/i386/linux/linux_systrace_args.c Mon Apr 16 21:23:25 2012 (r234353) +++ head/sys/i386/linux/linux_systrace_args.c Mon Apr 16 21:24:23 2012 (r234354) @@ -295,7 +295,7 @@ systrace_args(int sysnum, void *params, /* linux_pipe */ case 42: { struct linux_pipe_args *p = params; - uarg[0] = (intptr_t) p->pipefds; /* l_ulong * */ + uarg[0] = (intptr_t) p->pipefds; /* l_int * */ *n_args = 1; break; } @@ -2263,7 +2263,10 @@ systrace_args(int sysnum, void *params, } /* linux_pipe2 */ case 331: { - *n_args = 0; + struct linux_pipe2_args *p = params; + uarg[0] = (intptr_t) p->pipefds; /* l_int * */ + iarg[1] = p->flags; /* l_int */ + *n_args = 2; break; } /* linux_inotify_init1 */ @@ -2793,7 +2796,7 @@ systrace_entry_setargdesc(int sysnum, in case 42: switch(ndx) { case 0: - p = "l_ulong *"; + p = "l_int *"; break; default: break; @@ -5664,6 +5667,16 @@ systrace_entry_setargdesc(int sysnum, in break; /* linux_pipe2 */ case 331: + switch(ndx) { + case 0: + p = "l_int *"; + break; + case 1: + p = "l_int"; + break; + default: + break; + }; break; /* linux_inotify_init1 */ case 332: @@ -6979,6 +6992,9 @@ systrace_return_setargdesc(int sysnum, i case 330: /* linux_pipe2 */ case 331: + if (ndx == 0 || ndx == 1) + p = "int"; + break; /* linux_inotify_init1 */ case 332: /* linux_preadv */ From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 21:28:05 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7608A106564A; Mon, 16 Apr 2012 21:28:05 +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 61DE08FC15; Mon, 16 Apr 2012 21:28:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GLS5m6051358; Mon, 16 Apr 2012 21:28:05 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GLS5v7051356; Mon, 16 Apr 2012 21:28:05 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204162128.q3GLS5v7051356@svn.freebsd.org> From: Dimitry Andric Date: Mon, 16 Apr 2012 21:28: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: r234355 - head/sys/sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 21:28:05 -0000 Author: dim Date: Mon Apr 16 21:28:04 2012 New Revision: 234355 URL: http://svn.freebsd.org/changeset/base/234355 Log: Bump __FreeBSD_version due to the import of a new clang 3.1 prerelease snapshot. Modified: head/sys/sys/param.h Modified: head/sys/sys/param.h ============================================================================== --- head/sys/sys/param.h Mon Apr 16 21:24:23 2012 (r234354) +++ head/sys/sys/param.h Mon Apr 16 21:28:04 2012 (r234355) @@ -58,7 +58,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 1000010 /* Master, propagated to newvers */ +#define __FreeBSD_version 1000011 /* Master, propagated to newvers */ /* * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 21:29:41 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 158331065672; Mon, 16 Apr 2012 21:29:41 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-pz0-f44.google.com (mail-pz0-f44.google.com [209.85.210.44]) by mx1.freebsd.org (Postfix) with ESMTP id C7D6D8FC12; Mon, 16 Apr 2012 21:29:40 +0000 (UTC) Received: by dadz14 with SMTP id z14so25028126dad.17 for ; Mon, 16 Apr 2012 14:29:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=1S/c8x13R0trSl964ZV5Zv5iU8CCHFlXYqVJZjkasfw=; b=du6a9vLampuejXN7Ul8romNJHMASY+PPnjhWoc0wpTr9rczH2Y6EicsCP4JtFzBHA7 lk1g9WDmfGh06FxQUlAtyByM7UPMdAoq9HBjvyi4kaChrdG97tj3wHJdlQ3+yIFghjUn N9T6+0XGy7TZiQ5wkmY29O2fKw46q2zUKwF7OteLwTTOm884JsWV7UmYiPm2znI/O+hi A71e+B0TunXvTyG/Lv0KIOXXksyPRn4CZeG/IsW7tKpoOnK3rIMFrRul29nwCAgEtkJV qkT8DmaFRGQcnaI+YcexBNvma/BB3kPs7Uj6vOxoypWWD4SwXzZdzNXl93mau2W7CW5H HFKg== MIME-Version: 1.0 Received: by 10.68.202.168 with SMTP id kj8mr30783615pbc.86.1334611780650; Mon, 16 Apr 2012 14:29:40 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.142.101.9 with HTTP; Mon, 16 Apr 2012 14:29:40 -0700 (PDT) In-Reply-To: <4F8BBD4E.1040106@FreeBSD.org> References: <201204060653.q366rwLa096182@svn.freebsd.org> <4F7E9413.20602@FreeBSD.org> <4F8BBD4E.1040106@FreeBSD.org> Date: Mon, 16 Apr 2012 14:29:40 -0700 X-Google-Sender-Auth: nBBpe069Sf7q0Mpb9opgifHk294 Message-ID: From: Adrian Chadd To: "Alexander V. Chernikov" Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r233937 - in head/sys: kern net security/mac X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 21:29:41 -0000 On 15 April 2012 23:33, Alexander V. Chernikov wrote: > On 16.04.2012 01:17, Adrian Chadd wrote: >> >> Hi, >> >> This has broken (at least) net80211 and bpf, with LOR: > > Yes, it is. Please try the attached patch Hi, This seems like a very, very complicated diff. * You've removed BPF_LOCK_ASSERT() inside bpf_detachd_locked() - why'd you do that? * You removed a comment ("We're already protected by the global lock") which is still relevant/valid * There are lots of modifications to the read/write locks here - I'm not sure whether they're at all relevant to my immediate problem and may belong in separate commits Is there a document somewhere which describes what the "new" style BPF locking should be? I "just" added BPF_LOCK() / BPF_UNLOCK() around all the calls to bpf_detachd() which weren't locked (there were a few.) One final question - should the BPF global lock be recursive? thanks, Adrian From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 21:36:56 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 757D2106564A; Mon, 16 Apr 2012 21:36:56 +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 4723B8FC0C; Mon, 16 Apr 2012 21:36:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GLauXC051671; Mon, 16 Apr 2012 21:36:56 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GLaurU051667; Mon, 16 Apr 2012 21:36:56 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204162136.q3GLaurU051667@svn.freebsd.org> From: Dimitry Andric Date: Mon, 16 Apr 2012 21:36: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: r234356 - in head: gnu/lib/csu lib/clang lib/csu/powerpc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 21:36:56 -0000 Author: dim Date: Mon Apr 16 21:36:55 2012 New Revision: 234356 URL: http://svn.freebsd.org/changeset/base/234356 Log: Work around an issue on 32-bit PowerPC, where clang executable can get too big, causing 'relocation truncated to fit' errors at link time. Reviewed by: nwhitehorn Modified: head/gnu/lib/csu/Makefile head/lib/clang/clang.build.mk head/lib/csu/powerpc/Makefile Modified: head/gnu/lib/csu/Makefile ============================================================================== --- head/gnu/lib/csu/Makefile Mon Apr 16 21:28:04 2012 (r234355) +++ head/gnu/lib/csu/Makefile Mon Apr 16 21:36:55 2012 (r234356) @@ -34,6 +34,7 @@ CFLAGS+= -include osreldate.h .if ${MACHINE_CPUARCH} == "powerpc" TGTOBJS= crtsavres.o SRCS+= crtsavres.asm +CFLAGS+= -mlongcall .endif .if ${MACHINE_CPUARCH} == "sparc64" TGTOBJS= crtfastmath.o Modified: head/lib/clang/clang.build.mk ============================================================================== --- head/lib/clang/clang.build.mk Mon Apr 16 21:28:04 2012 (r234355) +++ head/lib/clang/clang.build.mk Mon Apr 16 21:36:55 2012 (r234356) @@ -11,6 +11,12 @@ CFLAGS+=-I${LLVM_SRCS}/include -I${CLANG # LLVM is not strict aliasing safe as of 12/31/2011 CFLAGS+= -fno-strict-aliasing +# Work around an issue on 32-bit PowerPC, where the clang executable can get +# too big, causing 'relocation truncated to fit' errors at link time. +.if ${MACHINE_ARCH} == "powerpc" +CFLAGS+=-mlongcall +.endif + TARGET_ARCH?= ${MACHINE_ARCH} CFLAGS+=-DLLVM_DEFAULT_TARGET_TRIPLE=\"${TARGET_ARCH:C/amd64/x86_64/}-unknown-freebsd10.0\" Modified: head/lib/csu/powerpc/Makefile ============================================================================== --- head/lib/csu/powerpc/Makefile Mon Apr 16 21:28:04 2012 (r234355) +++ head/lib/csu/powerpc/Makefile Mon Apr 16 21:36:55 2012 (r234356) @@ -6,7 +6,8 @@ SRCS= crt1.c crti.S crtn.S OBJS= ${SRCS:N*.h:R:S/$/.o/g} OBJS+= Scrt1.o gcrt1.o CFLAGS+= -I${.CURDIR}/../common \ - -I${.CURDIR}/../../libc/include + -I${.CURDIR}/../../libc/include \ + -mlongcall all: ${OBJS} From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 22:38:27 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DF2E8106564A; Mon, 16 Apr 2012 22:38:27 +0000 (UTC) (envelope-from bzeeb-lists@lists.zabbadoz.net) Received: from mx1.sbone.de (mx1.sbone.de [IPv6:2a01:4f8:130:3ffc::401:25]) by mx1.freebsd.org (Postfix) with ESMTP id 8F9218FC15; Mon, 16 Apr 2012 22:38:27 +0000 (UTC) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:31::2013:587]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.sbone.de (Postfix) with ESMTPS id A7ADF25D3A82; Mon, 16 Apr 2012 22:38:26 +0000 (UTC) Received: from content-filter.sbone.de (content-filter.sbone.de [IPv6:fde9:577b:c1a9:31::2013:2742]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id D6557BE4FDD; Mon, 16 Apr 2012 22:38:25 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:31::2013:587]) by content-filter.sbone.de (content-filter.sbone.de [fde9:577b:c1a9:31::2013:2742]) (amavisd-new, port 10024) with ESMTP id 70SAus6Xay+R; Mon, 16 Apr 2012 22:38:24 +0000 (UTC) Received: from orange-en1.sbone.de (orange-en1.sbone.de [IPv6:fde9:577b:c1a9:31:cabc:c8ff:fecf:e8e3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id BF705BE4FDA; Mon, 16 Apr 2012 22:38:24 +0000 (UTC) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: "Bjoern A. Zeeb" In-Reply-To: <201204162128.q3GLS5v7051356@svn.freebsd.org> Date: Mon, 16 Apr 2012 22:38:24 +0000 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201204162128.q3GLS5v7051356@svn.freebsd.org> To: Dimitry Andric X-Mailer: Apple Mail (2.1084) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234355 - head/sys/sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 22:38:28 -0000 On 16. Apr 2012, at 21:28 , Dimitry Andric wrote: > Author: dim > Date: Mon Apr 16 21:28:04 2012 > New Revision: 234355 > URL: http://svn.freebsd.org/changeset/base/234355 >=20 > Log: > Bump __FreeBSD_version due to the import of a new clang 3.1 = prerelease > snapshot. >=20 With SVN can we please try to get these bumps done more atomically with = the real changes and if we do not maybe reference which revision forced = the bump? That said, why does 3.1-pre need a bump? > Modified: > head/sys/sys/param.h >=20 > Modified: head/sys/sys/param.h > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=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/sys/param.h Mon Apr 16 21:24:23 2012 = (r234354) > +++ head/sys/sys/param.h Mon Apr 16 21:28:04 2012 = (r234355) > @@ -58,7 +58,7 @@ > * in the range 5 to 9. > */ > #undef __FreeBSD_version > -#define __FreeBSD_version 1000010 /* Master, propagated to newvers = */ > +#define __FreeBSD_version 1000011 /* Master, propagated to newvers = */ >=20 > /* > * __FreeBSD_kernel__ indicates that this system uses the kernel of = FreeBSD, --=20 Bjoern A. Zeeb You have to have visions! It does not matter how good you are. It matters what good you do! From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 22:58:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 80095106564A; Mon, 16 Apr 2012 22:58: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 517B98FC0C; Mon, 16 Apr 2012 22:58:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GMwTcg054905; Mon, 16 Apr 2012 22:58:29 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GMwT8a054902; Mon, 16 Apr 2012 22:58:29 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204162258.q3GMwT8a054902@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 22:58: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: r234357 - in head/sys: amd64/linux32 i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 22:58:29 -0000 Author: jkim Date: Mon Apr 16 22:58:28 2012 New Revision: 234357 URL: http://svn.freebsd.org/changeset/base/234357 Log: Correct arguments of stat64, fstat64 and lstat64 syscalls for Linuxulator. Modified: head/sys/amd64/linux32/syscalls.master head/sys/i386/linux/syscalls.master Modified: head/sys/amd64/linux32/syscalls.master ============================================================================== --- head/sys/amd64/linux32/syscalls.master Mon Apr 16 21:36:55 2012 (r234356) +++ head/sys/amd64/linux32/syscalls.master Mon Apr 16 22:58:28 2012 (r234357) @@ -351,12 +351,12 @@ l_loff_t length); } 194 AUE_FTRUNCATE STD { int linux_ftruncate64(l_uint fd, \ l_loff_t length); } -195 AUE_STAT STD { int linux_stat64(char *filename, \ - struct l_stat64 *statbuf, l_long flags); } -196 AUE_LSTAT STD { int linux_lstat64(char *filename, \ - struct l_stat64 *statbuf, l_long flags); } -197 AUE_FSTAT STD { int linux_fstat64(l_ulong fd, \ - struct l_stat64 *statbuf, l_long flags); } +195 AUE_STAT STD { int linux_stat64(const char *filename, \ + struct l_stat64 *statbuf); } +196 AUE_LSTAT STD { int linux_lstat64(const char *filename, \ + struct l_stat64 *statbuf); } +197 AUE_FSTAT STD { int linux_fstat64(l_int fd, \ + struct l_stat64 *statbuf); } 198 AUE_LCHOWN STD { int linux_lchown(char *path, l_uid_t uid, \ l_gid_t gid); } 199 AUE_GETUID STD { int linux_getuid(void); } Modified: head/sys/i386/linux/syscalls.master ============================================================================== --- head/sys/i386/linux/syscalls.master Mon Apr 16 21:36:55 2012 (r234356) +++ head/sys/i386/linux/syscalls.master Mon Apr 16 22:58:28 2012 (r234357) @@ -353,12 +353,12 @@ l_loff_t length); } 194 AUE_FTRUNCATE STD { int linux_ftruncate64(l_uint fd, \ l_loff_t length); } -195 AUE_STAT STD { int linux_stat64(char *filename, \ - struct l_stat64 *statbuf, l_long flags); } -196 AUE_LSTAT STD { int linux_lstat64(char *filename, \ - struct l_stat64 *statbuf, l_long flags); } -197 AUE_FSTAT STD { int linux_fstat64(l_ulong fd, \ - struct l_stat64 *statbuf, l_long flags); } +195 AUE_STAT STD { int linux_stat64(const char *filename, \ + struct l_stat64 *statbuf); } +196 AUE_LSTAT STD { int linux_lstat64(const char *filename, \ + struct l_stat64 *statbuf); } +197 AUE_FSTAT STD { int linux_fstat64(l_int fd, \ + struct l_stat64 *statbuf); } 198 AUE_LCHOWN STD { int linux_lchown(char *path, l_uid_t uid, \ l_gid_t gid); } 199 AUE_GETUID STD { int linux_getuid(void); } From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 22:59:51 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CC15C106564A; Mon, 16 Apr 2012 22:59:51 +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 B6B3E8FC12; Mon, 16 Apr 2012 22:59:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GMxpHF054984; Mon, 16 Apr 2012 22:59:51 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GMxpdL054973; Mon, 16 Apr 2012 22:59:51 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204162259.q3GMxpdL054973@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 22:59: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: r234358 - in head/sys: amd64/linux32 i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 22:59:51 -0000 Author: jkim Date: Mon Apr 16 22:59:51 2012 New Revision: 234358 URL: http://svn.freebsd.org/changeset/base/234358 Log: Regen for r234357. Modified: head/sys/amd64/linux32/linux32_proto.h head/sys/amd64/linux32/linux32_syscall.h head/sys/amd64/linux32/linux32_syscalls.c head/sys/amd64/linux32/linux32_sysent.c head/sys/amd64/linux32/linux32_systrace_args.c head/sys/i386/linux/linux_proto.h head/sys/i386/linux/linux_syscall.h head/sys/i386/linux/linux_syscalls.c head/sys/i386/linux/linux_sysent.c head/sys/i386/linux/linux_systrace_args.c Modified: head/sys/amd64/linux32/linux32_proto.h ============================================================================== --- head/sys/amd64/linux32/linux32_proto.h Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/amd64/linux32/linux32_proto.h Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ #ifndef _LINUX_SYSPROTO_H_ @@ -628,19 +628,16 @@ struct linux_ftruncate64_args { char length_l_[PADL_(l_loff_t)]; l_loff_t length; char length_r_[PADR_(l_loff_t)]; }; struct linux_stat64_args { - char filename_l_[PADL_(char *)]; char * filename; char filename_r_[PADR_(char *)]; + char filename_l_[PADL_(const char *)]; const char * filename; char filename_r_[PADR_(const char *)]; char statbuf_l_[PADL_(struct l_stat64 *)]; struct l_stat64 * statbuf; char statbuf_r_[PADR_(struct l_stat64 *)]; - char flags_l_[PADL_(l_long)]; l_long flags; char flags_r_[PADR_(l_long)]; }; struct linux_lstat64_args { - char filename_l_[PADL_(char *)]; char * filename; char filename_r_[PADR_(char *)]; + char filename_l_[PADL_(const char *)]; const char * filename; char filename_r_[PADR_(const char *)]; char statbuf_l_[PADL_(struct l_stat64 *)]; struct l_stat64 * statbuf; char statbuf_r_[PADR_(struct l_stat64 *)]; - char flags_l_[PADL_(l_long)]; l_long flags; char flags_r_[PADR_(l_long)]; }; struct linux_fstat64_args { - char fd_l_[PADL_(l_ulong)]; l_ulong fd; char fd_r_[PADR_(l_ulong)]; + char fd_l_[PADL_(l_int)]; l_int fd; char fd_r_[PADR_(l_int)]; char statbuf_l_[PADL_(struct l_stat64 *)]; struct l_stat64 * statbuf; char statbuf_r_[PADR_(struct l_stat64 *)]; - char flags_l_[PADL_(l_long)]; l_long flags; char flags_r_[PADR_(l_long)]; }; struct linux_lchown_args { char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; Modified: head/sys/amd64/linux32/linux32_syscall.h ============================================================================== --- head/sys/amd64/linux32/linux32_syscall.h Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/amd64/linux32/linux32_syscall.h Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ #define LINUX_SYS_exit 1 Modified: head/sys/amd64/linux32/linux32_syscalls.c ============================================================================== --- head/sys/amd64/linux32/linux32_syscalls.c Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/amd64/linux32/linux32_syscalls.c Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ const char *linux_syscallnames[] = { Modified: head/sys/amd64/linux32/linux32_sysent.c ============================================================================== --- head/sys/amd64/linux32/linux32_sysent.c Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/amd64/linux32/linux32_sysent.c Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ #include "opt_compat.h" Modified: head/sys/amd64/linux32/linux32_systrace_args.c ============================================================================== --- head/sys/amd64/linux32/linux32_systrace_args.c Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/amd64/linux32/linux32_systrace_args.c Mon Apr 16 22:59:51 2012 (r234358) @@ -1355,28 +1355,25 @@ systrace_args(int sysnum, void *params, /* linux_stat64 */ case 195: { struct linux_stat64_args *p = params; - uarg[0] = (intptr_t) p->filename; /* char * */ + uarg[0] = (intptr_t) p->filename; /* const char * */ uarg[1] = (intptr_t) p->statbuf; /* struct l_stat64 * */ - iarg[2] = p->flags; /* l_long */ - *n_args = 3; + *n_args = 2; break; } /* linux_lstat64 */ case 196: { struct linux_lstat64_args *p = params; - uarg[0] = (intptr_t) p->filename; /* char * */ + uarg[0] = (intptr_t) p->filename; /* const char * */ uarg[1] = (intptr_t) p->statbuf; /* struct l_stat64 * */ - iarg[2] = p->flags; /* l_long */ - *n_args = 3; + *n_args = 2; break; } /* linux_fstat64 */ case 197: { struct linux_fstat64_args *p = params; - iarg[0] = p->fd; /* l_ulong */ + iarg[0] = p->fd; /* l_int */ uarg[1] = (intptr_t) p->statbuf; /* struct l_stat64 * */ - iarg[2] = p->flags; /* l_long */ - *n_args = 3; + *n_args = 2; break; } /* linux_lchown */ @@ -4342,14 +4339,11 @@ systrace_entry_setargdesc(int sysnum, in case 195: switch(ndx) { case 0: - p = "char *"; + p = "const char *"; break; case 1: p = "struct l_stat64 *"; break; - case 2: - p = "l_long"; - break; default: break; }; @@ -4358,14 +4352,11 @@ systrace_entry_setargdesc(int sysnum, in case 196: switch(ndx) { case 0: - p = "char *"; + p = "const char *"; break; case 1: p = "struct l_stat64 *"; break; - case 2: - p = "l_long"; - break; default: break; }; @@ -4374,14 +4365,11 @@ systrace_entry_setargdesc(int sysnum, in case 197: switch(ndx) { case 0: - p = "l_ulong"; + p = "l_int"; break; case 1: p = "struct l_stat64 *"; break; - case 2: - p = "l_long"; - break; default: break; }; Modified: head/sys/i386/linux/linux_proto.h ============================================================================== --- head/sys/i386/linux/linux_proto.h Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/i386/linux/linux_proto.h Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ #ifndef _LINUX_SYSPROTO_H_ @@ -625,19 +625,16 @@ struct linux_ftruncate64_args { char length_l_[PADL_(l_loff_t)]; l_loff_t length; char length_r_[PADR_(l_loff_t)]; }; struct linux_stat64_args { - char filename_l_[PADL_(char *)]; char * filename; char filename_r_[PADR_(char *)]; + char filename_l_[PADL_(const char *)]; const char * filename; char filename_r_[PADR_(const char *)]; char statbuf_l_[PADL_(struct l_stat64 *)]; struct l_stat64 * statbuf; char statbuf_r_[PADR_(struct l_stat64 *)]; - char flags_l_[PADL_(l_long)]; l_long flags; char flags_r_[PADR_(l_long)]; }; struct linux_lstat64_args { - char filename_l_[PADL_(char *)]; char * filename; char filename_r_[PADR_(char *)]; + char filename_l_[PADL_(const char *)]; const char * filename; char filename_r_[PADR_(const char *)]; char statbuf_l_[PADL_(struct l_stat64 *)]; struct l_stat64 * statbuf; char statbuf_r_[PADR_(struct l_stat64 *)]; - char flags_l_[PADL_(l_long)]; l_long flags; char flags_r_[PADR_(l_long)]; }; struct linux_fstat64_args { - char fd_l_[PADL_(l_ulong)]; l_ulong fd; char fd_r_[PADR_(l_ulong)]; + char fd_l_[PADL_(l_int)]; l_int fd; char fd_r_[PADR_(l_int)]; char statbuf_l_[PADL_(struct l_stat64 *)]; struct l_stat64 * statbuf; char statbuf_r_[PADR_(struct l_stat64 *)]; - char flags_l_[PADL_(l_long)]; l_long flags; char flags_r_[PADR_(l_long)]; }; struct linux_lchown_args { char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; Modified: head/sys/i386/linux/linux_syscall.h ============================================================================== --- head/sys/i386/linux/linux_syscall.h Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/i386/linux/linux_syscall.h Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ #define LINUX_SYS_exit 1 Modified: head/sys/i386/linux/linux_syscalls.c ============================================================================== --- head/sys/i386/linux/linux_syscalls.c Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/i386/linux/linux_syscalls.c Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ const char *linux_syscallnames[] = { Modified: head/sys/i386/linux/linux_sysent.c ============================================================================== --- head/sys/i386/linux/linux_sysent.c Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/i386/linux/linux_sysent.c Mon Apr 16 22:59:51 2012 (r234358) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234352 2012-04-16 21:22:02Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim */ #include Modified: head/sys/i386/linux/linux_systrace_args.c ============================================================================== --- head/sys/i386/linux/linux_systrace_args.c Mon Apr 16 22:58:28 2012 (r234357) +++ head/sys/i386/linux/linux_systrace_args.c Mon Apr 16 22:59:51 2012 (r234358) @@ -1398,28 +1398,25 @@ systrace_args(int sysnum, void *params, /* linux_stat64 */ case 195: { struct linux_stat64_args *p = params; - uarg[0] = (intptr_t) p->filename; /* char * */ + uarg[0] = (intptr_t) p->filename; /* const char * */ uarg[1] = (intptr_t) p->statbuf; /* struct l_stat64 * */ - iarg[2] = p->flags; /* l_long */ - *n_args = 3; + *n_args = 2; break; } /* linux_lstat64 */ case 196: { struct linux_lstat64_args *p = params; - uarg[0] = (intptr_t) p->filename; /* char * */ + uarg[0] = (intptr_t) p->filename; /* const char * */ uarg[1] = (intptr_t) p->statbuf; /* struct l_stat64 * */ - iarg[2] = p->flags; /* l_long */ - *n_args = 3; + *n_args = 2; break; } /* linux_fstat64 */ case 197: { struct linux_fstat64_args *p = params; - iarg[0] = p->fd; /* l_ulong */ + iarg[0] = p->fd; /* l_int */ uarg[1] = (intptr_t) p->statbuf; /* struct l_stat64 * */ - iarg[2] = p->flags; /* l_long */ - *n_args = 3; + *n_args = 2; break; } /* linux_lchown */ @@ -4494,14 +4491,11 @@ systrace_entry_setargdesc(int sysnum, in case 195: switch(ndx) { case 0: - p = "char *"; + p = "const char *"; break; case 1: p = "struct l_stat64 *"; break; - case 2: - p = "l_long"; - break; default: break; }; @@ -4510,14 +4504,11 @@ systrace_entry_setargdesc(int sysnum, in case 196: switch(ndx) { case 0: - p = "char *"; + p = "const char *"; break; case 1: p = "struct l_stat64 *"; break; - case 2: - p = "l_long"; - break; default: break; }; @@ -4526,14 +4517,11 @@ systrace_entry_setargdesc(int sysnum, in case 197: switch(ndx) { case 0: - p = "l_ulong"; + p = "l_int"; break; case 1: p = "struct l_stat64 *"; break; - case 2: - p = "l_long"; - break; default: break; }; From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 23:16:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B124C106564A; Mon, 16 Apr 2012 23:16:18 +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 9CA818FC18; Mon, 16 Apr 2012 23:16:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GNGIbu055547; Mon, 16 Apr 2012 23:16:18 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GNGIm9055543; Mon, 16 Apr 2012 23:16:18 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204162316.q3GNGIm9055543@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 23:16: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: r234359 - in head/sys: amd64/linux32 i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 23:16:18 -0000 Author: jkim Date: Mon Apr 16 23:16:18 2012 New Revision: 234359 URL: http://svn.freebsd.org/changeset/base/234359 Log: Correct an argument type of iopl syscall for Linuxulator. This also fixes a warning from Clang, i. e., "args->level < 0 is always false". Modified: head/sys/amd64/linux32/syscalls.master head/sys/i386/linux/syscalls.master Modified: head/sys/amd64/linux32/syscalls.master ============================================================================== --- head/sys/amd64/linux32/syscalls.master Mon Apr 16 22:59:51 2012 (r234358) +++ head/sys/amd64/linux32/syscalls.master Mon Apr 16 23:16:18 2012 (r234359) @@ -202,7 +202,7 @@ struct l_newstat *buf); } ; 109: olduname 109 AUE_NULL STD { int linux_uname(void); } -110 AUE_NULL STD { int linux_iopl(l_ulong level); } +110 AUE_NULL STD { int linux_iopl(l_int level); } 111 AUE_NULL STD { int linux_vhangup(void); } 112 AUE_NULL UNIMPL idle 113 AUE_NULL UNIMPL vm86old Modified: head/sys/i386/linux/syscalls.master ============================================================================== --- head/sys/i386/linux/syscalls.master Mon Apr 16 22:59:51 2012 (r234358) +++ head/sys/i386/linux/syscalls.master Mon Apr 16 23:16:18 2012 (r234359) @@ -203,7 +203,7 @@ struct l_newstat *buf); } ; 109: olduname 109 AUE_NULL STD { int linux_uname(void); } -110 AUE_NULL STD { int linux_iopl(l_ulong level); } +110 AUE_NULL STD { int linux_iopl(l_int level); } 111 AUE_NULL STD { int linux_vhangup(void); } 112 AUE_NULL UNIMPL idle 113 AUE_NULL STD { int linux_vm86old(void); } From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 23:17:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E702C1065670; Mon, 16 Apr 2012 23:17: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 D19E68FC19; Mon, 16 Apr 2012 23:17:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GNHTX5055630; Mon, 16 Apr 2012 23:17:29 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GNHTMH055619; Mon, 16 Apr 2012 23:17:29 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204162317.q3GNHTMH055619@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 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: r234360 - in head/sys: amd64/linux32 i386/linux X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 23:17:30 -0000 Author: jkim Date: Mon Apr 16 23:17:29 2012 New Revision: 234360 URL: http://svn.freebsd.org/changeset/base/234360 Log: Regen for r234359. Modified: head/sys/amd64/linux32/linux32_proto.h head/sys/amd64/linux32/linux32_syscall.h head/sys/amd64/linux32/linux32_syscalls.c head/sys/amd64/linux32/linux32_sysent.c head/sys/amd64/linux32/linux32_systrace_args.c head/sys/i386/linux/linux_proto.h head/sys/i386/linux/linux_syscall.h head/sys/i386/linux/linux_syscalls.c head/sys/i386/linux/linux_sysent.c head/sys/i386/linux/linux_systrace_args.c Modified: head/sys/amd64/linux32/linux32_proto.h ============================================================================== --- head/sys/amd64/linux32/linux32_proto.h Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/amd64/linux32/linux32_proto.h Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ #ifndef _LINUX_SYSPROTO_H_ @@ -344,7 +344,7 @@ struct linux_uname_args { register_t dummy; }; struct linux_iopl_args { - char level_l_[PADL_(l_ulong)]; l_ulong level; char level_r_[PADR_(l_ulong)]; + char level_l_[PADL_(l_int)]; l_int level; char level_r_[PADR_(l_int)]; }; struct linux_vhangup_args { register_t dummy; Modified: head/sys/amd64/linux32/linux32_syscall.h ============================================================================== --- head/sys/amd64/linux32/linux32_syscall.h Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/amd64/linux32/linux32_syscall.h Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ #define LINUX_SYS_exit 1 Modified: head/sys/amd64/linux32/linux32_syscalls.c ============================================================================== --- head/sys/amd64/linux32/linux32_syscalls.c Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/amd64/linux32/linux32_syscalls.c Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ const char *linux_syscallnames[] = { Modified: head/sys/amd64/linux32/linux32_sysent.c ============================================================================== --- head/sys/amd64/linux32/linux32_sysent.c Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/amd64/linux32/linux32_sysent.c Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/amd64/linux32/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ #include "opt_compat.h" Modified: head/sys/amd64/linux32/linux32_systrace_args.c ============================================================================== --- head/sys/amd64/linux32/linux32_systrace_args.c Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/amd64/linux32/linux32_systrace_args.c Mon Apr 16 23:17:29 2012 (r234360) @@ -748,7 +748,7 @@ systrace_args(int sysnum, void *params, /* linux_iopl */ case 110: { struct linux_iopl_args *p = params; - iarg[0] = p->level; /* l_ulong */ + iarg[0] = p->level; /* l_int */ *n_args = 1; break; } @@ -3392,7 +3392,7 @@ systrace_entry_setargdesc(int sysnum, in case 110: switch(ndx) { case 0: - p = "l_ulong"; + p = "l_int"; break; default: break; Modified: head/sys/i386/linux/linux_proto.h ============================================================================== --- head/sys/i386/linux/linux_proto.h Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/i386/linux/linux_proto.h Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ #ifndef _LINUX_SYSPROTO_H_ @@ -344,7 +344,7 @@ struct linux_uname_args { register_t dummy; }; struct linux_iopl_args { - char level_l_[PADL_(l_ulong)]; l_ulong level; char level_r_[PADR_(l_ulong)]; + char level_l_[PADL_(l_int)]; l_int level; char level_r_[PADR_(l_int)]; }; struct linux_vhangup_args { register_t dummy; Modified: head/sys/i386/linux/linux_syscall.h ============================================================================== --- head/sys/i386/linux/linux_syscall.h Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/i386/linux/linux_syscall.h Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ #define LINUX_SYS_exit 1 Modified: head/sys/i386/linux/linux_syscalls.c ============================================================================== --- head/sys/i386/linux/linux_syscalls.c Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/i386/linux/linux_syscalls.c Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ const char *linux_syscallnames[] = { Modified: head/sys/i386/linux/linux_sysent.c ============================================================================== --- head/sys/i386/linux/linux_sysent.c Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/i386/linux/linux_sysent.c Mon Apr 16 23:17:29 2012 (r234360) @@ -3,7 +3,7 @@ * * DO NOT EDIT-- this file is automatically generated. * $FreeBSD$ - * created from FreeBSD: head/sys/i386/linux/syscalls.master 234357 2012-04-16 22:58:28Z jkim + * created from FreeBSD: head/sys/i386/linux/syscalls.master 234359 2012-04-16 23:16:18Z jkim */ #include Modified: head/sys/i386/linux/linux_systrace_args.c ============================================================================== --- head/sys/i386/linux/linux_systrace_args.c Mon Apr 16 23:16:18 2012 (r234359) +++ head/sys/i386/linux/linux_systrace_args.c Mon Apr 16 23:17:29 2012 (r234360) @@ -772,7 +772,7 @@ systrace_args(int sysnum, void *params, /* linux_iopl */ case 110: { struct linux_iopl_args *p = params; - iarg[0] = p->level; /* l_ulong */ + iarg[0] = p->level; /* l_int */ *n_args = 1; break; } @@ -3522,7 +3522,7 @@ systrace_entry_setargdesc(int sysnum, in case 110: switch(ndx) { case 0: - p = "l_ulong"; + p = "l_int"; break; default: break; From owner-svn-src-all@FreeBSD.ORG Mon Apr 16 23:29:12 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A4EDD106566B; Mon, 16 Apr 2012 23:29:12 +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 8FF998FC15; Mon, 16 Apr 2012 23:29:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3GNTCi9056056; Mon, 16 Apr 2012 23:29:12 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3GNTC2L056054; Mon, 16 Apr 2012 23:29:12 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204162329.q3GNTC2L056054@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 16 Apr 2012 23:29: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: r234362 - head/sys/dev/fb X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Apr 2012 23:29:12 -0000 Author: jkim Date: Mon Apr 16 23:29:12 2012 New Revision: 234362 URL: http://svn.freebsd.org/changeset/base/234362 Log: Fix a Clang warning. Submitted by: arundel Modified: head/sys/dev/fb/s3_pci.c Modified: head/sys/dev/fb/s3_pci.c ============================================================================== --- head/sys/dev/fb/s3_pci.c Mon Apr 16 23:19:21 2012 (r234361) +++ head/sys/dev/fb/s3_pci.c Mon Apr 16 23:29:12 2012 (r234362) @@ -513,7 +513,7 @@ s3pci_attach(device_t dev) /* Attach the driver to the VGA/VESA framework */ for (i = 0; (adp = vid_get_adapter(i)) != NULL; ++i) { - if ((adp->va_type == KD_VGA)) + if (adp->va_type == KD_VGA) break; } From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 00:54:39 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 86A1A1065678; Tue, 17 Apr 2012 00:54:39 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 718FD8FC0C; Tue, 17 Apr 2012 00:54:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H0sdlO058623; Tue, 17 Apr 2012 00:54:39 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H0sdnP058621; Tue, 17 Apr 2012 00:54:39 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201204170054.q3H0sdnP058621@svn.freebsd.org> From: Peter Grehan Date: Tue, 17 Apr 2012 00:54: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: r234364 - head/sys/x86/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 00:54:39 -0000 Author: grehan Date: Tue Apr 17 00:54:38 2012 New Revision: 234364 URL: http://svn.freebsd.org/changeset/base/234364 Log: Add x2apic MSR definitions Reviewed by: jhb Obtained from: bhyve via Neel via NetApp Modified: head/sys/x86/include/specialreg.h Modified: head/sys/x86/include/specialreg.h ============================================================================== --- head/sys/x86/include/specialreg.h Mon Apr 16 23:32:12 2012 (r234363) +++ head/sys/x86/include/specialreg.h Tue Apr 17 00:54:38 2012 (r234364) @@ -359,10 +359,44 @@ #define MSR_MC4_MISC 0x413 /* + * X2APIC MSRs + */ +#define MSR_APIC_ID 0x802 +#define MSR_APIC_VERSION 0x803 +#define MSR_APIC_TPR 0x808 +#define MSR_APIC_EOI 0x80b +#define MSR_APIC_LDR 0x80d +#define MSR_APIC_SVR 0x80f +#define MSR_APIC_ISR0 0x810 +#define MSR_APIC_ISR1 0x811 +#define MSR_APIC_ISR2 0x812 +#define MSR_APIC_ISR3 0x813 +#define MSR_APIC_ISR4 0x814 +#define MSR_APIC_ISR5 0x815 +#define MSR_APIC_ISR6 0x816 +#define MSR_APIC_ISR7 0x817 +#define MSR_APIC_TMR0 0x818 +#define MSR_APIC_IRR0 0x820 +#define MSR_APIC_ESR 0x828 +#define MSR_APIC_LVT_CMCI 0x82F +#define MSR_APIC_ICR 0x830 +#define MSR_APIC_LVT_TIMER 0x832 +#define MSR_APIC_LVT_THERMAL 0x833 +#define MSR_APIC_LVT_PCINT 0x834 +#define MSR_APIC_LVT_LINT0 0x835 +#define MSR_APIC_LVT_LINT1 0x836 +#define MSR_APIC_LVT_ERROR 0x837 +#define MSR_APIC_ICR_TIMER 0x838 +#define MSR_APIC_CCR_TIMER 0x839 +#define MSR_APIC_DCR_TIMER 0x83e +#define MSR_APIC_SELF_IPI 0x83f + +/* * Constants related to MSR's. */ -#define APICBASE_RESERVED 0x000006ff +#define APICBASE_RESERVED 0x000002ff #define APICBASE_BSP 0x00000100 +#define APICBASE_X2APIC 0x00000400 #define APICBASE_ENABLED 0x00000800 #define APICBASE_ADDRESS 0xfffff000 From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 01:23:00 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1C365106564A; Tue, 17 Apr 2012 01:23:00 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 06C368FC15; Tue, 17 Apr 2012 01:23:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H1MxcP059608; Tue, 17 Apr 2012 01:22:59 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H1MxYP059606; Tue, 17 Apr 2012 01:22:59 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204170122.q3H1MxYP059606@svn.freebsd.org> From: Adrian Chadd Date: Tue, 17 Apr 2012 01:22: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: r234365 - head/sys/mips/atheros X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 01:23:00 -0000 Author: adrian Date: Tue Apr 17 01:22:59 2012 New Revision: 234365 URL: http://svn.freebsd.org/changeset/base/234365 Log: Protect the PCI space registers behind a mutex. Obtained from: Linux/OpenWRT, Atheros Modified: head/sys/mips/atheros/ar71xx_pci.c Modified: head/sys/mips/atheros/ar71xx_pci.c ============================================================================== --- head/sys/mips/atheros/ar71xx_pci.c Tue Apr 17 00:54:38 2012 (r234364) +++ head/sys/mips/atheros/ar71xx_pci.c Tue Apr 17 01:22:59 2012 (r234365) @@ -39,6 +39,8 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include +#include #include #include @@ -72,6 +74,10 @@ __FBSDID("$FreeBSD$"); #define dprintf(x, arg...) #endif +struct mtx ar71xx_pci_mtx; +MTX_SYSINIT(ar71xx_pci_mtx, &ar71xx_pci_mtx, "ar71xx PCI space mutex", + MTX_SPIN); + struct ar71xx_pci_softc { device_t sc_dev; @@ -97,6 +103,7 @@ ar71xx_pci_mask_irq(void *source) uint32_t reg; unsigned int irq = (unsigned int)source; + /* XXX is the PCI lock required here? */ reg = ATH_READ_REG(AR71XX_PCI_INTR_MASK); /* flush */ reg = ATH_READ_REG(AR71XX_PCI_INTR_MASK); @@ -109,6 +116,7 @@ ar71xx_pci_unmask_irq(void *source) uint32_t reg; unsigned int irq = (unsigned int)source; + /* XXX is the PCI lock required here? */ reg = ATH_READ_REG(AR71XX_PCI_INTR_MASK); ATH_WRITE_REG(AR71XX_PCI_INTR_MASK, reg | (1 << irq)); /* flush */ @@ -140,6 +148,9 @@ static int ar71xx_pci_check_bus_error(void) { uint32_t error, addr, has_errors = 0; + + mtx_assert(&ar71xx_pci_mtx, MA_OWNED); + error = ATH_READ_REG(AR71XX_PCI_ERROR) & 0x3; dprintf("%s: PCI error = %02x\n", __func__, error); if (error) { @@ -185,7 +196,9 @@ ar71xx_pci_conf_setup(int bus, int slot, { uint32_t addr = ar71xx_pci_make_addr(bus, slot, func, (reg & ~3)); cmd |= (ar71xx_get_bytes_to_read(reg, bytes) << 4); - + + mtx_assert(&ar71xx_pci_mtx, MA_OWNED); + ATH_WRITE_REG(AR71XX_PCI_CONF_ADDR, addr); ATH_WRITE_REG(AR71XX_PCI_CONF_CMD, cmd); @@ -216,11 +229,13 @@ ar71xx_pci_read_config(device_t dev, u_i dprintf("%s: tag (%x, %x, %x) reg %d(%d)\n", __func__, bus, slot, func, reg, bytes); + mtx_lock_spin(&ar71xx_pci_mtx); if (ar71xx_pci_conf_setup(bus, slot, func, reg, bytes, PCI_CONF_CMD_READ) == 0) data = ATH_READ_REG(AR71XX_PCI_CONF_READ_DATA); else data = -1; + mtx_unlock_spin(&ar71xx_pci_mtx); /* get request bytes from 32-bit word */ data = (data >> shift) & mask; @@ -241,8 +256,10 @@ ar71xx_pci_local_write(device_t dev, uin cmd = PCI_LCONF_CMD_WRITE | (reg & ~3); cmd |= (ar71xx_get_bytes_to_read(reg, bytes) << 20); + mtx_lock_spin(&ar71xx_pci_mtx); ATH_WRITE_REG(AR71XX_PCI_LCONF_CMD, cmd); ATH_WRITE_REG(AR71XX_PCI_LCONF_WRITE_DATA, data); + mtx_unlock_spin(&ar71xx_pci_mtx); } static void @@ -255,9 +272,11 @@ ar71xx_pci_write_config(device_t dev, u_ data = data << (8*(reg % 4)); + mtx_lock_spin(&ar71xx_pci_mtx); if (ar71xx_pci_conf_setup(bus, slot, func, reg, bytes, PCI_CONF_CMD_WRITE) == 0) ATH_WRITE_REG(AR71XX_PCI_CONF_WRITE_DATA, data); + mtx_unlock_spin(&ar71xx_pci_mtx); } #ifdef AR71XX_ATH_EEPROM @@ -457,7 +476,9 @@ ar71xx_pci_attach(device_t dev) ATH_WRITE_REG(AR71XX_PCI_WINDOW7, PCI_WINDOW7_CONF_ADDR); DELAY(100000); + mtx_lock_spin(&ar71xx_pci_mtx); ar71xx_pci_check_bus_error(); + mtx_unlock_spin(&ar71xx_pci_mtx); /* Fixup internal PCI bridge */ ar71xx_pci_local_write(dev, PCIR_COMMAND, From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 01:34:50 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 54DE5106566B; Tue, 17 Apr 2012 01:34:50 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 361E38FC08; Tue, 17 Apr 2012 01:34:50 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H1YoGP060003; Tue, 17 Apr 2012 01:34:50 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H1YopS060001; Tue, 17 Apr 2012 01:34:50 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204170134.q3H1YopS060001@svn.freebsd.org> From: Adrian Chadd Date: Tue, 17 Apr 2012 01:34: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: r234366 - head/sys/mips/atheros X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 01:34:50 -0000 Author: adrian Date: Tue Apr 17 01:34:49 2012 New Revision: 234366 URL: http://svn.freebsd.org/changeset/base/234366 Log: Style(9) and white space fixes. Modified: head/sys/mips/atheros/ar71xx_pci.c Modified: head/sys/mips/atheros/ar71xx_pci.c ============================================================================== --- head/sys/mips/atheros/ar71xx_pci.c Tue Apr 17 01:22:59 2012 (r234365) +++ head/sys/mips/atheros/ar71xx_pci.c Tue Apr 17 01:34:49 2012 (r234366) @@ -67,11 +67,11 @@ __FBSDID("$FreeBSD$"); #include #endif /* AR71XX_ATH_EEPROM */ -#undef AR71XX_PCI_DEBUG -#ifdef AR71XX_PCI_DEBUG -#define dprintf printf +#undef AR71XX_PCI_DEBUG +#ifdef AR71XX_PCI_DEBUG +#define dprintf printf #else -#define dprintf(x, arg...) +#define dprintf(x, arg...) #endif struct mtx ar71xx_pci_mtx; @@ -97,7 +97,7 @@ static int ar71xx_pci_teardown_intr(devi void *); static int ar71xx_pci_intr(void *); -static void +static void ar71xx_pci_mask_irq(void *source) { uint32_t reg; @@ -110,7 +110,7 @@ ar71xx_pci_mask_irq(void *source) ATH_WRITE_REG(AR71XX_PCI_INTR_MASK, reg & ~(1 << irq)); } -static void +static void ar71xx_pci_unmask_irq(void *source) { uint32_t reg; @@ -123,15 +123,16 @@ ar71xx_pci_unmask_irq(void *source) reg = ATH_READ_REG(AR71XX_PCI_INTR_MASK); } -/* - * get bitmask for bytes of interest: - * 0 - we want this byte, 1 - ignore it. e.g: we read 1 byte +/* + * get bitmask for bytes of interest: + * 0 - we want this byte, 1 - ignore it. e.g: we read 1 byte * from register 7. Bitmask would be: 0111 */ static uint32_t ar71xx_get_bytes_to_read(int reg, int bytes) { uint32_t bytes_to_read = 0; + if ((bytes % 4) == 0) bytes_to_read = 0; else if ((bytes % 4) == 1) @@ -144,7 +145,7 @@ ar71xx_get_bytes_to_read(int reg, int by return (bytes_to_read); } -static int +static int ar71xx_pci_check_bus_error(void) { uint32_t error, addr, has_errors = 0; @@ -185,20 +186,20 @@ ar71xx_pci_make_addr(int bus, int slot, if (bus == 0) { return ((1 << slot) | (func << 8) | (reg & ~3)); } else { - return ((bus << 16) | (slot << 11) | (func << 8) + return ((bus << 16) | (slot << 11) | (func << 8) | (reg & ~3) | 1); } } static int -ar71xx_pci_conf_setup(int bus, int slot, int func, int reg, int bytes, +ar71xx_pci_conf_setup(int bus, int slot, int func, int reg, int bytes, uint32_t cmd) { uint32_t addr = ar71xx_pci_make_addr(bus, slot, func, (reg & ~3)); - cmd |= (ar71xx_get_bytes_to_read(reg, bytes) << 4); mtx_assert(&ar71xx_pci_mtx, MA_OWNED); + cmd |= (ar71xx_get_bytes_to_read(reg, bytes) << 4); ATH_WRITE_REG(AR71XX_PCI_CONF_ADDR, addr); ATH_WRITE_REG(AR71XX_PCI_CONF_CMD, cmd); @@ -209,7 +210,7 @@ ar71xx_pci_conf_setup(int bus, int slot, } static uint32_t -ar71xx_pci_read_config(device_t dev, u_int bus, u_int slot, u_int func, +ar71xx_pci_read_config(device_t dev, u_int bus, u_int slot, u_int func, u_int reg, int bytes) { uint32_t data; @@ -240,7 +241,7 @@ ar71xx_pci_read_config(device_t dev, u_i /* get request bytes from 32-bit word */ data = (data >> shift) & mask; - dprintf("%s: read 0x%x\n", __func__, data); + dprintf("%s: read 0x%x\n", __func__, data); return (data); } @@ -253,7 +254,6 @@ ar71xx_pci_local_write(device_t dev, uin dprintf("%s: local write reg %d(%d)\n", __func__, reg, bytes); data = data << (8*(reg % 4)); - cmd = PCI_LCONF_CMD_WRITE | (reg & ~3); cmd |= (ar71xx_get_bytes_to_read(reg, bytes) << 20); mtx_lock_spin(&ar71xx_pci_mtx); @@ -271,7 +271,6 @@ ar71xx_pci_write_config(device_t dev, u_ func, reg, bytes); data = data << (8*(reg % 4)); - mtx_lock_spin(&ar71xx_pci_mtx); if (ar71xx_pci_conf_setup(bus, slot, func, reg, bytes, PCI_CONF_CMD_WRITE) == 0) @@ -453,7 +452,7 @@ ar71xx_pci_attach(device_t dev) if ((bus_setup_intr(dev, sc->sc_irq, INTR_TYPE_MISC, ar71xx_pci_intr, NULL, sc, &sc->sc_ih))) { - device_printf(dev, + device_printf(dev, "WARNING: unable to register interrupt handler\n"); return ENXIO; } @@ -501,7 +500,8 @@ ar71xx_pci_attach(device_t dev) } static int -ar71xx_pci_read_ivar(device_t dev, device_t child, int which, uintptr_t *result) +ar71xx_pci_read_ivar(device_t dev, device_t child, int which, + uintptr_t *result) { struct ar71xx_pci_softc *sc = device_get_softc(dev); @@ -518,7 +518,8 @@ ar71xx_pci_read_ivar(device_t dev, devic } static int -ar71xx_pci_write_ivar(device_t dev, device_t child, int which, uintptr_t result) +ar71xx_pci_write_ivar(device_t dev, device_t child, int which, + uintptr_t result) { struct ar71xx_pci_softc * sc = device_get_softc(dev); @@ -536,7 +537,7 @@ ar71xx_pci_alloc_resource(device_t bus, u_long start, u_long end, u_long count, u_int flags) { - struct ar71xx_pci_softc *sc = device_get_softc(bus); + struct ar71xx_pci_softc *sc = device_get_softc(bus); struct resource *rv; struct rman *rm; @@ -563,13 +564,10 @@ ar71xx_pci_alloc_resource(device_t bus, rman_release_resource(rv); return (NULL); } - } - - + } return (rv); } - static int ar71xx_pci_activate_resource(device_t bus, device_t child, int type, int rid, struct resource *r) @@ -585,16 +583,13 @@ ar71xx_pci_activate_resource(device_t bu break; } } - return (res); } - - static int ar71xx_pci_setup_intr(device_t bus, device_t child, struct resource *ires, - int flags, driver_filter_t *filt, driver_intr_t *handler, - void *arg, void **cookiep) + int flags, driver_filter_t *filt, driver_intr_t *handler, + void *arg, void **cookiep) { struct ar71xx_pci_softc *sc = device_get_softc(bus); struct intr_event *event; @@ -617,7 +612,7 @@ ar71xx_pci_setup_intr(device_t bus, devi mips_intrcnt_create(event->ie_name); } else - return error; + return (error); } intr_event_add_handler(event, device_get_nameunit(child), filt, From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 04:31:51 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3A4BF106564A; Tue, 17 Apr 2012 04:31:51 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0C43D8FC15; Tue, 17 Apr 2012 04:31:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H4Vo2s065584; Tue, 17 Apr 2012 04:31:50 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H4Vo0k065582; Tue, 17 Apr 2012 04:31:50 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204170431.q3H4Vo0k065582@svn.freebsd.org> From: Adrian Chadd Date: Tue, 17 Apr 2012 04:31:50 +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: r234367 - head/sys/dev/mwl X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 04:31:51 -0000 Author: adrian Date: Tue Apr 17 04:31:50 2012 New Revision: 234367 URL: http://svn.freebsd.org/changeset/base/234367 Log: Add missing #include Modified: head/sys/dev/mwl/if_mwl.c Modified: head/sys/dev/mwl/if_mwl.c ============================================================================== --- head/sys/dev/mwl/if_mwl.c Tue Apr 17 01:34:49 2012 (r234366) +++ head/sys/dev/mwl/if_mwl.c Tue Apr 17 04:31:50 2012 (r234367) @@ -37,6 +37,7 @@ __FBSDID("$FreeBSD$"); #include "opt_inet.h" #include "opt_mwl.h" +#include "opt_wlan.h" #include #include From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 04:52:58 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 37EA61065740; Tue, 17 Apr 2012 04:52:58 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 23B638FC08; Tue, 17 Apr 2012 04:52:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H4qvoB066249; Tue, 17 Apr 2012 04:52:57 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H4qvml066247; Tue, 17 Apr 2012 04:52:57 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204170452.q3H4qvml066247@svn.freebsd.org> From: Adrian Chadd Date: Tue, 17 Apr 2012 04:52: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: r234368 - head/sys/dev/mwl X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 04:52:58 -0000 Author: adrian Date: Tue Apr 17 04:52:57 2012 New Revision: 234368 URL: http://svn.freebsd.org/changeset/base/234368 Log: Fix the RX free list locking creation and destruction to be consistent even in the face of errors. If the RX descriptor list fails, the RX lock won't be initialised, but then the DMA free path wil try freeing it. This commit is brought to you by a working mwl(4). Modified: head/sys/dev/mwl/if_mwl.c Modified: head/sys/dev/mwl/if_mwl.c ============================================================================== --- head/sys/dev/mwl/if_mwl.c Tue Apr 17 04:31:50 2012 (r234367) +++ head/sys/dev/mwl/if_mwl.c Tue Apr 17 04:52:57 2012 (r234368) @@ -310,6 +310,12 @@ mwl_attach(uint16_t devid, struct mwl_so } ic = ifp->if_l2com; + /* + * Setup the RX free list lock early, so it can be consistently + * removed. + */ + MWL_RXFREE_INIT(sc); + /* set these up early for if_printf use */ if_initname(ifp, device_get_name(sc->sc_dev), device_get_unit(sc->sc_dev)); @@ -531,6 +537,7 @@ bad2: bad1: mwl_hal_detach(mh); bad: + MWL_RXFREE_DESTROY(sc); if_free(ifp); sc->sc_invalid = 1; return error; @@ -561,6 +568,7 @@ mwl_detach(struct mwl_softc *sc) ieee80211_ifdetach(ic); callout_drain(&sc->sc_watchdog); mwl_dma_cleanup(sc); + MWL_RXFREE_DESTROY(sc); mwl_tx_cleanup(sc); mwl_hal_detach(sc->sc_mh); if_free(ifp); @@ -2274,7 +2282,6 @@ mwl_rxdma_setup(struct mwl_softc *sc) SLIST_INSERT_HEAD(&sc->sc_rxfree, rbuf, next); sc->sc_nrxfree++; } - MWL_RXFREE_INIT(sc); return 0; } #undef DS2PHYS @@ -2298,7 +2305,6 @@ mwl_rxdma_cleanup(struct mwl_softc *sc) } if (sc->sc_rxdma.dd_desc_len != 0) mwl_desc_cleanup(sc, &sc->sc_rxdma); - MWL_RXFREE_DESTROY(sc); } static int From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 05:32:42 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 61E45106566B; Tue, 17 Apr 2012 05:32:42 +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 1C9BB8FC19; Tue, 17 Apr 2012 05:32:42 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:920:4d88:e4b9:4d05] (unknown [IPv6:2001:7b8:3a7:0:920:4d88:e4b9:4d05]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 5DFFD5C37; Tue, 17 Apr 2012 07:32:41 +0200 (CEST) Message-ID: <4F8D0077.3000502@FreeBSD.org> Date: Tue, 17 Apr 2012 07:32:39 +0200 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20120410 Thunderbird/12.0 MIME-Version: 1.0 To: "Bjoern A. Zeeb" References: <201204162128.q3GLS5v7051356@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 Subject: Re: svn commit: r234355 - head/sys/sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 05:32:42 -0000 On 2012-04-17 00:38, Bjoern A. Zeeb wrote: > On 16. Apr 2012, at 21:28 , Dimitry Andric wrote: >> Author: dim >> Date: Mon Apr 16 21:28:04 2012 >> New Revision: 234355 >> URL: http://svn.freebsd.org/changeset/base/234355 >> >> Log: >> Bump __FreeBSD_version due to the import of a new clang 3.1 prerelease >> snapshot. > > With SVN can we please try to get these bumps done more atomically with the real changes and if we do not maybe reference which revision forced the bump? I thought it was clearer to do this in a separate commit, since the import modifies a large number of files, sort of "drowning out" this change. > That said, why does 3.1-pre need a bump? To make it easier for ports people to detect there is a new version. Some command line options have changed, some new behaviour has been introduced, etc. From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 06:02:42 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5D097106566B; Tue, 17 Apr 2012 06:02:42 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 47C0A8FC08; Tue, 17 Apr 2012 06:02:42 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H62gAN068515; Tue, 17 Apr 2012 06:02:42 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H62ffG068512; Tue, 17 Apr 2012 06:02:41 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204170602.q3H62ffG068512@svn.freebsd.org> From: Adrian Chadd Date: Tue, 17 Apr 2012 06:02: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: r234369 - head/sys/dev/ath X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 06:02:42 -0000 Author: adrian Date: Tue Apr 17 06:02:41 2012 New Revision: 234369 URL: http://svn.freebsd.org/changeset/base/234369 Log: Run the fatal proc as a proc, rather than where it currently is. Otherwise the reset path will sleep, which it can't do in this context. Modified: head/sys/dev/ath/if_ath.c head/sys/dev/ath/if_athvar.h Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Tue Apr 17 04:52:57 2012 (r234368) +++ head/sys/dev/ath/if_ath.c Tue Apr 17 06:02:41 2012 (r234369) @@ -402,6 +402,7 @@ ath_attach(u_int16_t devid, struct ath_s TASK_INIT(&sc->sc_bstucktask,0, ath_bstuck_proc, sc); TASK_INIT(&sc->sc_resettask,0, ath_reset_proc, sc); TASK_INIT(&sc->sc_txqtask,0, ath_txq_sched_tasklet, sc); + TASK_INIT(&sc->sc_fataltask,0, ath_fatal_proc, sc); /* * Allocate hardware transmit queues: one queue for @@ -1527,7 +1528,7 @@ ath_intr(void *arg) if (status & HAL_INT_FATAL) { sc->sc_stats.ast_hardware++; ath_hal_intrset(ah, 0); /* disable intr's until reset */ - ath_fatal_proc(sc, 0); + taskqueue_enqueue(sc->sc_tq, &sc->sc_fataltask); } else { if (status & HAL_INT_SWBA) { /* Modified: head/sys/dev/ath/if_athvar.h ============================================================================== --- head/sys/dev/ath/if_athvar.h Tue Apr 17 04:52:57 2012 (r234368) +++ head/sys/dev/ath/if_athvar.h Tue Apr 17 06:02:41 2012 (r234369) @@ -508,6 +508,7 @@ struct ath_softc { struct task sc_bmisstask; /* bmiss int processing */ struct task sc_bstucktask; /* stuck beacon processing */ struct task sc_resettask; /* interface reset task */ + struct task sc_fataltask; /* fatal task */ enum { OK, /* no change needed */ UPDATE, /* update pending */ From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 06:59:33 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id ABE831065670; Tue, 17 Apr 2012 06:59:33 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from mail-lpp01m010-f54.google.com (mail-lpp01m010-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id B55CB8FC0A; Tue, 17 Apr 2012 06:59:12 +0000 (UTC) Received: by lagv3 with SMTP id v3so5753470lag.13 for ; Mon, 16 Apr 2012 23:59:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type :content-transfer-encoding; bh=KXbVHEwsiVpiziD1ZNAfnyaGvQSL3vcN2ope2Aju6Dc=; b=MoBcRL8oprhZVP/i5tbIr5vrqaYAv8O4uKDqvyI6FN/SvoHdwc7Z0UQvWRw1ZXGxo7 HZNgvs0x1H4hu19LOqBPjE/E2PBsJ54Oq8Zt32lo9H1Pk76wVhbgSyyHCmg1mFFjRd0i r1Ss1++/dWwStA/RTP9BvloEBBo6aPpOLyzgN2r9hiS8RomCsTeDWqcB5ThOEeciUOyW Og/D0hcVLjJeuR3vXffQNu91z3V2iHZYKoTGw/XhJ0TWEpnrPFOhiRoqPihr+bCp8I/b fNJGPsqVwLH9lObYzYIe4z4CZYK7TeRs1DVJc8xHOxL/9T36CVG3AWzPAY5nKc7boQ7g cNZA== MIME-Version: 1.0 Received: by 10.112.25.130 with SMTP id c2mr6501496lbg.107.1334645951707; Mon, 16 Apr 2012 23:59:11 -0700 (PDT) Sender: pluknet@gmail.com Received: by 10.152.25.69 with HTTP; Mon, 16 Apr 2012 23:59:11 -0700 (PDT) In-Reply-To: <20120414113132.GA71196@felucia.tataz.chchile.org> References: <201203220942.q2M9gSvv017339@svn.freebsd.org> <20120414113132.GA71196@felucia.tataz.chchile.org> Date: Tue, 17 Apr 2012 10:59:11 +0400 X-Google-Sender-Auth: 06QgVKWVBC9yqsJkm049qXa0_ps Message-ID: From: Sergey Kandaurov To: Jeremie Le Hen , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: Subject: Re: svn commit: r233296 - head/lib/libc/gen X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 06:59:33 -0000 On 14 April 2012 15:31, Jeremie Le Hen wrote: > Hi Sergey, > > On Thu, Mar 22, 2012 at 09:42:28AM +0000, Sergey Kandaurov wrote: >> Author: pluknet >> Date: Thu Mar 22 09:42:27 2012 >> New Revision: 233296 >> URL: http://svn.freebsd.org/changeset/base/233296 >> >> Log: >> =A0 Prevent fs_file NULL pointer dereference in fixfsfile() uncovered af= ter r1.5 >> =A0 when passing damaged user-supplied fstab file data. >> >> =A0 MFC after: =A01 week >> >> Modified: >> =A0 head/lib/libc/gen/fstab.c >> >> Modified: head/lib/libc/gen/fstab.c >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=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/gen/fstab.c Thu Mar 22 09:29:07 2012 =A0 =A0 =A0 =A0(r= 233295) >> +++ head/lib/libc/gen/fstab.c Thu Mar 22 09:42:27 2012 =A0 =A0 =A0 =A0(r= 233296) >> @@ -91,7 +91,7 @@ fixfsfile() >> =A0 =A0 =A0 struct stat sb; >> =A0 =A0 =A0 struct statfs sf; >> >> - =A0 =A0 if (strcmp(_fs_fstab.fs_file, "/") !=3D 0) >> + =A0 =A0 if (_fs_fstab.fs_file !=3D NULL &&strcmp(_fs_fstab.fs_file, "/= ") !=3D 0) >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 return; >> =A0 =A0 =A0 if (statfs("/", &sf) !=3D 0) >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 return; > > Would you mind MFC'ing this please? =A0It bit me today :). > > Thanks. Ah, sure. I will today. [I was AFK for some time, and now I'm here again.] --=20 wbr, pluknet From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 07:22:15 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1378F1065673; Tue, 17 Apr 2012 07:22:15 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id ECF818FC0A; Tue, 17 Apr 2012 07:22:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H7MEIH070944; Tue, 17 Apr 2012 07:22:14 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H7ME6A070934; Tue, 17 Apr 2012 07:22:14 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201204170722.q3H7ME6A070934@svn.freebsd.org> From: Jason Evans Date: Tue, 17 Apr 2012 07:22: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: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 07:22:15 -0000 Author: jasone Date: Tue Apr 17 07:22:14 2012 New Revision: 234370 URL: http://svn.freebsd.org/changeset/base/234370 Log: Import jemalloc 9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa (dev branch, prior to 3.0.0 release) as contrib/jemalloc, and integrate it into libc. The code being imported by this commit diverged from lib/libc/stdlib/malloc.c in March 2010, which means that a portion of the jemalloc 1.0.0 ChangeLog entries are relevant, as are the entries for all subsequent releases. Added: head/contrib/jemalloc/ head/contrib/jemalloc/COPYING head/contrib/jemalloc/ChangeLog head/contrib/jemalloc/FREEBSD-Xlist head/contrib/jemalloc/FREEBSD-diffs head/contrib/jemalloc/FREEBSD-upgrade (contents, props changed) head/contrib/jemalloc/VERSION head/contrib/jemalloc/doc/ head/contrib/jemalloc/doc/jemalloc.3 head/contrib/jemalloc/include/ head/contrib/jemalloc/include/jemalloc/ head/contrib/jemalloc/include/jemalloc/internal/ head/contrib/jemalloc/include/jemalloc/internal/arena.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/atomic.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/base.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/bitmap.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/chunk.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/chunk_dss.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/chunk_mmap.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/ckh.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/ctl.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/extent.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/hash.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/huge.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/mb.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/mutex.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/prng.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/prof.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/ql.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/qr.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/quarantine.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/rb.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/rtree.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/size_classes.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/stats.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/tcache.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/tsd.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/internal/util.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/jemalloc.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/jemalloc_FreeBSD.h (contents, props changed) head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h (contents, props changed) head/contrib/jemalloc/src/ head/contrib/jemalloc/src/arena.c (contents, props changed) head/contrib/jemalloc/src/atomic.c (contents, props changed) head/contrib/jemalloc/src/base.c (contents, props changed) head/contrib/jemalloc/src/bitmap.c (contents, props changed) head/contrib/jemalloc/src/chunk.c (contents, props changed) head/contrib/jemalloc/src/chunk_dss.c (contents, props changed) head/contrib/jemalloc/src/chunk_mmap.c (contents, props changed) head/contrib/jemalloc/src/ckh.c (contents, props changed) head/contrib/jemalloc/src/ctl.c (contents, props changed) head/contrib/jemalloc/src/extent.c (contents, props changed) head/contrib/jemalloc/src/hash.c (contents, props changed) head/contrib/jemalloc/src/huge.c (contents, props changed) head/contrib/jemalloc/src/jemalloc.c (contents, props changed) head/contrib/jemalloc/src/mb.c (contents, props changed) head/contrib/jemalloc/src/mutex.c (contents, props changed) head/contrib/jemalloc/src/prof.c (contents, props changed) head/contrib/jemalloc/src/quarantine.c (contents, props changed) head/contrib/jemalloc/src/rtree.c (contents, props changed) head/contrib/jemalloc/src/stats.c (contents, props changed) head/contrib/jemalloc/src/tcache.c (contents, props changed) head/contrib/jemalloc/src/tsd.c (contents, props changed) head/contrib/jemalloc/src/util.c (contents, props changed) head/lib/libc/stdlib/jemalloc/ head/lib/libc/stdlib/jemalloc/Makefile.inc (contents, props changed) head/lib/libc/stdlib/jemalloc/Symbol.map (contents, props changed) head/lib/libc/stdlib/reallocf.3 - copied, changed from r234194, head/lib/libc/stdlib/malloc.3 Deleted: head/lib/libc/stdlib/aligned_alloc.3 head/lib/libc/stdlib/malloc.3 head/lib/libc/stdlib/malloc.c head/lib/libc/stdlib/ql.h head/lib/libc/stdlib/qr.h head/lib/libc/stdlib/rb.h Modified: head/include/malloc_np.h head/include/stdlib.h head/lib/libc/Makefile head/lib/libc/gen/tls.c head/lib/libc/stdlib/Makefile.inc head/lib/libc/stdlib/Symbol.map Added: head/contrib/jemalloc/COPYING ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/jemalloc/COPYING Tue Apr 17 07:22:14 2012 (r234370) @@ -0,0 +1,27 @@ +Unless otherwise specified, files in the jemalloc source distribution are +subject to the following license: +-------------------------------------------------------------------------------- +Copyright (C) 2002-2012 Jason Evans . +All rights reserved. +Copyright (C) 2007-2012 Mozilla Foundation. All rights reserved. +Copyright (C) 2009-2012 Facebook, Inc. 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(s), + this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright notice(s), + 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 COPYRIGHT HOLDER(S) ``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 COPYRIGHT HOLDER(S) 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. +-------------------------------------------------------------------------------- Added: head/contrib/jemalloc/ChangeLog ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/jemalloc/ChangeLog Tue Apr 17 07:22:14 2012 (r234370) @@ -0,0 +1,322 @@ +Following are change highlights associated with official releases. Important +bug fixes are all mentioned, but internal enhancements are omitted here for +brevity (even though they are more fun to write about). Much more detail can be +found in the git revision history: + + http://www.canonware.com/cgi-bin/gitweb.cgi?p=jemalloc.git + git://canonware.com/jemalloc.git + +* 3.0.0 (XXX not yet released) + + Although this version adds some major new features, the primary focus is on + internal code cleanup that facilitates maintainability and portability, most + of which is not reflected in the ChangeLog. This is the first release to + incorporate substantial contributions from numerous other developers, and the + result is a more broadly useful allocator (see the git revision history for + contribution details). Note that the license has been unified, thanks to + Facebook granting a license under the same terms as the other copyright + holders (see COPYING). + + New features: + - Implement Valgrind support, redzones, and quarantine. + - Add support for additional operating systems: + + FreeBSD + + Mac OS X Lion + - Add support for additional architectures: + + MIPS + + SH4 + + Tilera + - Add support for cross compiling. + - Add nallocm(), which rounds a request size up to the nearest size class + without actually allocating. + - Implement aligned_alloc() (blame C11). + - Add the --disable-munmap option, and make it the default on Linux. + - Add the --with-mangling option. + - Add the --disable-experimental option. + - Add the "thread.tcache.enabled" mallctl. + + Incompatible changes: + - Enable stats by default. + - Enable fill by default. + - Disable lazy locking by default. + - Rename the "tcache.flush" mallctl to "thread.tcache.flush". + - Rename the "arenas.pagesize" mallctl to "arenas.page". + + Removed features: + - Remove the swap feature, including the "config.swap", "swap.avail", + "swap.prezeroed", "swap.nfds", and "swap.fds" mallctls. + - Remove highruns statistics, including the + "stats.arenas..bins..highruns" and + "stats.arenas..lruns..highruns" mallctls. + - As part of small size class refactoring, remove the "opt.lg_[qc]space_max", + "arenas.cacheline", "arenas.subpage", "arenas.[tqcs]space_{min,max}", and + "arenas.[tqcs]bins" mallctls. + - Remove the "arenas.chunksize" mallctl. + - Remove the "opt.lg_prof_tcmax" option. + - Remove the "opt.lg_prof_bt_max" option. + - Remove the "opt.lg_tcache_gc_sweep" option. + - Remove the --disable-tiny option, including the "config.tiny" mallctl. + - Remove the --enable-dynamic-page-shift configure option. + - Remove the --enable-sysv configure option. + + Bug fixes: + - Fix fork-related bugs that could cause deadlock in children between fork + and exec. + - Fix a statistics-related bug in the "thread.arena" mallctl that could cause + invalid statistics and crashes. + - Work around TLS dallocation via free() on Linux. This bug could cause + write-after-free memory corruption. + - Fix malloc_stats_print() to honor 'b' and 'l' in the opts parameter. + - Fix realloc(p, 0) to act like free(p). + - Do not enforce minimum alignment in memalign(). + - Check for NULL pointer in malloc_usable_size(). + - Fix bin->runcur management to fix a layout policy bug. This bug did not + affect correctness. + - Fix a bug in choose_arena_hard() that potentially caused more arenas to be + initialized than necessary. + - Add missing "opt.lg_tcache_max" mallctl implementation. + - Use glibc allocator hooks to make mixed allocator usage less likely. + - Fix build issues for --disable-tcache. + +* 2.2.5 (November 14, 2011) + + Bug fixes: + - Fix huge_ralloc() race when using mremap(2). This is a serious bug that + could cause memory corruption and/or crashes. + - Fix huge_ralloc() to maintain chunk statistics. + - Fix malloc_stats_print(..., "a") output. + +* 2.2.4 (November 5, 2011) + + Bug fixes: + - Initialize arenas_tsd before using it. This bug existed for 2.2.[0-3], as + well as for --disable-tls builds in earlier releases. + - Do not assume a 4 KiB page size in test/rallocm.c. + +* 2.2.3 (August 31, 2011) + + This version fixes numerous bugs related to heap profiling. + + Bug fixes: + - Fix a prof-related race condition. This bug could cause memory corruption, + but only occurred in non-default configurations (prof_accum:false). + - Fix off-by-one backtracing issues (make sure that prof_alloc_prep() is + excluded from backtraces). + - Fix a prof-related bug in realloc() (only triggered by OOM errors). + - Fix prof-related bugs in allocm() and rallocm(). + - Fix prof_tdata_cleanup() for --disable-tls builds. + - Fix a relative include path, to fix objdir builds. + +* 2.2.2 (July 30, 2011) + + Bug fixes: + - Fix a build error for --disable-tcache. + - Fix assertions in arena_purge() (for real this time). + - Add the --with-private-namespace option. This is a workaround for symbol + conflicts that can inadvertently arise when using static libraries. + +* 2.2.1 (March 30, 2011) + + Bug fixes: + - Implement atomic operations for x86/x64. This fixes compilation failures + for versions of gcc that are still in wide use. + - Fix an assertion in arena_purge(). + +* 2.2.0 (March 22, 2011) + + This version incorporates several improvements to algorithms and data + structures that tend to reduce fragmentation and increase speed. + + New features: + - Add the "stats.cactive" mallctl. + - Update pprof (from google-perftools 1.7). + - Improve backtracing-related configuration logic, and add the + --disable-prof-libgcc option. + + Bug fixes: + - Change default symbol visibility from "internal", to "hidden", which + decreases the overhead of library-internal function calls. + - Fix symbol visibility so that it is also set on OS X. + - Fix a build dependency regression caused by the introduction of the .pic.o + suffix for PIC object files. + - Add missing checks for mutex initialization failures. + - Don't use libgcc-based backtracing except on x64, where it is known to work. + - Fix deadlocks on OS X that were due to memory allocation in + pthread_mutex_lock(). + - Heap profiling-specific fixes: + + Fix memory corruption due to integer overflow in small region index + computation, when using a small enough sample interval that profiling + context pointers are stored in small run headers. + + Fix a bootstrap ordering bug that only occurred with TLS disabled. + + Fix a rallocm() rsize bug. + + Fix error detection bugs for aligned memory allocation. + +* 2.1.3 (March 14, 2011) + + Bug fixes: + - Fix a cpp logic regression (due to the "thread.{de,}allocatedp" mallctl fix + for OS X in 2.1.2). + - Fix a "thread.arena" mallctl bug. + - Fix a thread cache stats merging bug. + +* 2.1.2 (March 2, 2011) + + Bug fixes: + - Fix "thread.{de,}allocatedp" mallctl for OS X. + - Add missing jemalloc.a to build system. + +* 2.1.1 (January 31, 2011) + + Bug fixes: + - Fix aligned huge reallocation (affected allocm()). + - Fix the ALLOCM_LG_ALIGN macro definition. + - Fix a heap dumping deadlock. + - Fix a "thread.arena" mallctl bug. + +* 2.1.0 (December 3, 2010) + + This version incorporates some optimizations that can't quite be considered + bug fixes. + + New features: + - Use Linux's mremap(2) for huge object reallocation when possible. + - Avoid locking in mallctl*() when possible. + - Add the "thread.[de]allocatedp" mallctl's. + - Convert the manual page source from roff to DocBook, and generate both roff + and HTML manuals. + + Bug fixes: + - Fix a crash due to incorrect bootstrap ordering. This only impacted + --enable-debug --enable-dss configurations. + - Fix a minor statistics bug for mallctl("swap.avail", ...). + +* 2.0.1 (October 29, 2010) + + Bug fixes: + - Fix a race condition in heap profiling that could cause undefined behavior + if "opt.prof_accum" were disabled. + - Add missing mutex unlocks for some OOM error paths in the heap profiling + code. + - Fix a compilation error for non-C99 builds. + +* 2.0.0 (October 24, 2010) + + This version focuses on the experimental *allocm() API, and on improved + run-time configuration/introspection. Nonetheless, numerous performance + improvements are also included. + + New features: + - Implement the experimental {,r,s,d}allocm() API, which provides a superset + of the functionality available via malloc(), calloc(), posix_memalign(), + realloc(), malloc_usable_size(), and free(). These functions can be used to + allocate/reallocate aligned zeroed memory, ask for optional extra memory + during reallocation, prevent object movement during reallocation, etc. + - Replace JEMALLOC_OPTIONS/JEMALLOC_PROF_PREFIX with MALLOC_CONF, which is + more human-readable, and more flexible. For example: + JEMALLOC_OPTIONS=AJP + is now: + MALLOC_CONF=abort:true,fill:true,stats_print:true + - Port to Apple OS X. Sponsored by Mozilla. + - Make it possible for the application to control thread-->arena mappings via + the "thread.arena" mallctl. + - Add compile-time support for all TLS-related functionality via pthreads TSD. + This is mainly of interest for OS X, which does not support TLS, but has a + TSD implementation with similar performance. + - Override memalign() and valloc() if they are provided by the system. + - Add the "arenas.purge" mallctl, which can be used to synchronously purge all + dirty unused pages. + - Make cumulative heap profiling data optional, so that it is possible to + limit the amount of memory consumed by heap profiling data structures. + - Add per thread allocation counters that can be accessed via the + "thread.allocated" and "thread.deallocated" mallctls. + + Incompatible changes: + - Remove JEMALLOC_OPTIONS and malloc_options (see MALLOC_CONF above). + - Increase default backtrace depth from 4 to 128 for heap profiling. + - Disable interval-based profile dumps by default. + + Bug fixes: + - Remove bad assertions in fork handler functions. These assertions could + cause aborts for some combinations of configure settings. + - Fix strerror_r() usage to deal with non-standard semantics in GNU libc. + - Fix leak context reporting. This bug tended to cause the number of contexts + to be underreported (though the reported number of objects and bytes were + correct). + - Fix a realloc() bug for large in-place growing reallocation. This bug could + cause memory corruption, but it was hard to trigger. + - Fix an allocation bug for small allocations that could be triggered if + multiple threads raced to create a new run of backing pages. + - Enhance the heap profiler to trigger samples based on usable size, rather + than request size. + - Fix a heap profiling bug due to sometimes losing track of requested object + size for sampled objects. + +* 1.0.3 (August 12, 2010) + + Bug fixes: + - Fix the libunwind-based implementation of stack backtracing (used for heap + profiling). This bug could cause zero-length backtraces to be reported. + - Add a missing mutex unlock in library initialization code. If multiple + threads raced to initialize malloc, some of them could end up permanently + blocked. + +* 1.0.2 (May 11, 2010) + + Bug fixes: + - Fix junk filling of large objects, which could cause memory corruption. + - Add MAP_NORESERVE support for chunk mapping, because otherwise virtual + memory limits could cause swap file configuration to fail. Contributed by + Jordan DeLong. + +* 1.0.1 (April 14, 2010) + + Bug fixes: + - Fix compilation when --enable-fill is specified. + - Fix threads-related profiling bugs that affected accuracy and caused memory + to be leaked during thread exit. + - Fix dirty page purging race conditions that could cause crashes. + - Fix crash in tcache flushing code during thread destruction. + +* 1.0.0 (April 11, 2010) + + This release focuses on speed and run-time introspection. Numerous + algorithmic improvements make this release substantially faster than its + predecessors. + + New features: + - Implement autoconf-based configuration system. + - Add mallctl*(), for the purposes of introspection and run-time + configuration. + - Make it possible for the application to manually flush a thread's cache, via + the "tcache.flush" mallctl. + - Base maximum dirty page count on proportion of active memory. + - Compute various addtional run-time statistics, including per size class + statistics for large objects. + - Expose malloc_stats_print(), which can be called repeatedly by the + application. + - Simplify the malloc_message() signature to only take one string argument, + and incorporate an opaque data pointer argument for use by the application + in combination with malloc_stats_print(). + - Add support for allocation backed by one or more swap files, and allow the + application to disable over-commit if swap files are in use. + - Implement allocation profiling and leak checking. + + Removed features: + - Remove the dynamic arena rebalancing code, since thread-specific caching + reduces its utility. + + Bug fixes: + - Modify chunk allocation to work when address space layout randomization + (ASLR) is in use. + - Fix thread cleanup bugs related to TLS destruction. + - Handle 0-size allocation requests in posix_memalign(). + - Fix a chunk leak. The leaked chunks were never touched, so this impacted + virtual memory usage, but not physical memory usage. + +* linux_2008082[78]a (August 27/28, 2008) + + These snapshot releases are the simple result of incorporating Linux-specific + support into the FreeBSD malloc sources. + +-------------------------------------------------------------------------------- +vim:filetype=text:textwidth=80 Added: head/contrib/jemalloc/FREEBSD-Xlist ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/jemalloc/FREEBSD-Xlist Tue Apr 17 07:22:14 2012 (r234370) @@ -0,0 +1,23 @@ +$FreeBSD$ +.git +.gitignore +FREEBSD-* +INSTALL +Makefile* +README +autogen.sh +autom4te.cache/ +bin/ +config.* +configure* +doc/*.in +doc/*.xml +doc/*.xsl +doc/*.html +include/jemalloc/internal/jemalloc_internal.h.in +include/jemalloc/internal/size_classes.sh +include/jemalloc/jemalloc.h.in +include/jemalloc/jemalloc_defs.h.in +install-sh +src/zone.c +test/ Added: head/contrib/jemalloc/FREEBSD-diffs ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/jemalloc/FREEBSD-diffs Tue Apr 17 07:22:14 2012 (r234370) @@ -0,0 +1,247 @@ +diff --git a/doc/jemalloc.xml.in b/doc/jemalloc.xml.in +index 98d0ba4..23d2152 100644 +--- a/doc/jemalloc.xml.in ++++ b/doc/jemalloc.xml.in +@@ -51,12 +51,23 @@ + This manual describes jemalloc @jemalloc_version@. More information + can be found at the jemalloc website. ++ ++ The following configuration options are enabled in libc's built-in ++ jemalloc: , ++ , , ++ , , ++ , , ++ , , and ++ . Additionally, ++ is enabled in development versions of ++ FreeBSD (controlled by the MALLOC_PRODUCTION make ++ variable). + + + SYNOPSIS + + #include <stdlib.h> +-#include <jemalloc/jemalloc.h> ++#include <malloc_np.h> + + Standard API + +@@ -2080,4 +2091,16 @@ malloc_conf = "lg_chunk:24";]]> + The posix_memalign function conforms + to IEEE Std 1003.1-2001 (“POSIX.1”). + ++ ++ HISTORY ++ The malloc_usable_size and ++ posix_memalign functions first appeared in ++ FreeBSD 7.0. ++ ++ The aligned_alloc, ++ malloc_stats_print, ++ mallctl*, and ++ *allocm functions first appeared in ++ FreeBSD 10.0. ++ + +diff --git a/include/jemalloc/internal/jemalloc_internal.h.in b/include/jemalloc/internal/jemalloc_internal.h.in +index aa21aa5..e0f5fed 100644 +--- a/include/jemalloc/internal/jemalloc_internal.h.in ++++ b/include/jemalloc/internal/jemalloc_internal.h.in +@@ -1,3 +1,6 @@ ++#include "libc_private.h" ++#include "namespace.h" ++ + #include + #include + #include +@@ -33,6 +36,9 @@ + #include + #include + ++#include "un-namespace.h" ++#include "libc_private.h" ++ + #define JEMALLOC_NO_DEMANGLE + #include "../jemalloc@install_suffix@.h" + +diff --git a/include/jemalloc/internal/mutex.h b/include/jemalloc/internal/mutex.h +index c46feee..d7133f4 100644 +--- a/include/jemalloc/internal/mutex.h ++++ b/include/jemalloc/internal/mutex.h +@@ -39,8 +39,6 @@ struct malloc_mutex_s { + + #ifdef JEMALLOC_LAZY_LOCK + extern bool isthreaded; +-#else +-# define isthreaded true + #endif + + bool malloc_mutex_init(malloc_mutex_t *mutex); +diff --git a/include/jemalloc/jemalloc.h.in b/include/jemalloc/jemalloc.h.in +index f0581db..f26d8bc 100644 +--- a/include/jemalloc/jemalloc.h.in ++++ b/include/jemalloc/jemalloc.h.in +@@ -15,6 +15,7 @@ extern "C" { + #define JEMALLOC_VERSION_GID "@jemalloc_version_gid@" + + #include "jemalloc_defs@install_suffix@.h" ++#include "jemalloc_FreeBSD.h" + + #ifdef JEMALLOC_EXPERIMENTAL + #define ALLOCM_LG_ALIGN(la) (la) +diff --git a/include/jemalloc/jemalloc_FreeBSD.h b/include/jemalloc/jemalloc_FreeBSD.h +new file mode 100644 +index 0000000..2c5797f +--- /dev/null ++++ b/include/jemalloc/jemalloc_FreeBSD.h +@@ -0,0 +1,76 @@ ++/* ++ * Override settings that were generated in jemalloc_defs.h as necessary. ++ */ ++ ++#undef JEMALLOC_OVERRIDE_VALLOC ++ ++#ifndef MALLOC_PRODUCTION ++#define JEMALLOC_DEBUG ++#endif ++ ++/* ++ * The following are architecture-dependent, so conditionally define them for ++ * each supported architecture. ++ */ ++#undef CPU_SPINWAIT ++#undef JEMALLOC_TLS_MODEL ++#undef STATIC_PAGE_SHIFT ++#undef LG_SIZEOF_PTR ++#undef LG_SIZEOF_INT ++#undef LG_SIZEOF_LONG ++#undef LG_SIZEOF_INTMAX_T ++ ++#ifdef __i386__ ++# define LG_SIZEOF_PTR 2 ++# define CPU_SPINWAIT __asm__ volatile("pause") ++# define JEMALLOC_TLS_MODEL __attribute__((tls_model("initial-exec"))) ++#endif ++#ifdef __ia64__ ++# define LG_SIZEOF_PTR 3 ++#endif ++#ifdef __sparc64__ ++# define LG_SIZEOF_PTR 3 ++# define JEMALLOC_TLS_MODEL __attribute__((tls_model("initial-exec"))) ++#endif ++#ifdef __amd64__ ++# define LG_SIZEOF_PTR 3 ++# define CPU_SPINWAIT __asm__ volatile("pause") ++# define JEMALLOC_TLS_MODEL __attribute__((tls_model("initial-exec"))) ++#endif ++#ifdef __arm__ ++# define LG_SIZEOF_PTR 2 ++#endif ++#ifdef __mips__ ++# define LG_SIZEOF_PTR 2 ++#endif ++#ifdef __powerpc64__ ++# define LG_SIZEOF_PTR 3 ++#elif defined(__powerpc__) ++# define LG_SIZEOF_PTR 2 ++#endif ++ ++#ifndef JEMALLOC_TLS_MODEL ++# define JEMALLOC_TLS_MODEL /* Default. */ ++#endif ++#ifdef __clang__ ++# undef JEMALLOC_TLS_MODEL ++# define JEMALLOC_TLS_MODEL /* clang does not support tls_model yet. */ ++#endif ++ ++#define STATIC_PAGE_SHIFT PAGE_SHIFT ++#define LG_SIZEOF_INT 2 ++#define LG_SIZEOF_LONG LG_SIZEOF_PTR ++#define LG_SIZEOF_INTMAX_T 3 ++ ++/* Disable lazy-lock machinery, mangle isthreaded, and adjust its type. */ ++#undef JEMALLOC_LAZY_LOCK ++extern int __isthreaded; ++#define isthreaded ((bool)__isthreaded) ++ ++/* Mangle. */ ++#define open _open ++#define read _read ++#define write _write ++#define close _close ++#define pthread_mutex_lock _pthread_mutex_lock ++#define pthread_mutex_unlock _pthread_mutex_unlock +diff --git a/src/jemalloc.c b/src/jemalloc.c +index 0decd8a..73fad29 100644 +--- a/src/jemalloc.c ++++ b/src/jemalloc.c +@@ -8,6 +8,9 @@ malloc_tsd_data(, arenas, arena_t *, NULL) + malloc_tsd_data(, thread_allocated, thread_allocated_t, + THREAD_ALLOCATED_INITIALIZER) + ++const char *__malloc_options_1_0; ++__sym_compat(_malloc_options, __malloc_options_1_0, FBSD_1.0); ++ + /* Runtime configuration options. */ + const char *je_malloc_conf JEMALLOC_ATTR(visibility("default")); + #ifdef JEMALLOC_DEBUG +@@ -401,7 +404,8 @@ malloc_conf_init(void) + #endif + ; + +- if ((opts = getenv(envname)) != NULL) { ++ if (issetugid() == 0 && (opts = getenv(envname)) != ++ NULL) { + /* + * Do nothing; opts is already initialized to + * the value of the MALLOC_CONF environment +diff --git a/src/mutex.c b/src/mutex.c +index 4b8ce57..7be5fc9 100644 +--- a/src/mutex.c ++++ b/src/mutex.c +@@ -63,6 +63,17 @@ pthread_create(pthread_t *__restrict thread, + #ifdef JEMALLOC_MUTEX_INIT_CB + int _pthread_mutex_init_calloc_cb(pthread_mutex_t *mutex, + void *(calloc_cb)(size_t, size_t)); ++ ++__weak_reference(_pthread_mutex_init_calloc_cb_stub, ++ _pthread_mutex_init_calloc_cb); ++ ++int ++_pthread_mutex_init_calloc_cb_stub(pthread_mutex_t *mutex, ++ void *(calloc_cb)(size_t, size_t)) ++{ ++ ++ return (0); ++} + #endif + + bool +diff --git a/src/util.c b/src/util.c +index 2aab61f..8b05042 100644 +--- a/src/util.c ++++ b/src/util.c +@@ -60,6 +60,22 @@ wrtmessage(void *cbopaque, const char *s) + void (*je_malloc_message)(void *, const char *s) + JEMALLOC_ATTR(visibility("default")) = wrtmessage; + ++JEMALLOC_CATTR(visibility("hidden"), static) ++void ++wrtmessage_1_0(const char *s1, const char *s2, const char *s3, ++ const char *s4) ++{ ++ ++ wrtmessage(NULL, s1); ++ wrtmessage(NULL, s2); ++ wrtmessage(NULL, s3); ++ wrtmessage(NULL, s4); ++} ++ ++void (*__malloc_message_1_0)(const char *s1, const char *s2, const char *s3, ++ const char *s4) = wrtmessage_1_0; ++__sym_compat(_malloc_message, __malloc_message_1_0, FBSD_1.0); ++ + /* + * glibc provides a non-standard strerror_r() when _GNU_SOURCE is defined, so + * provide a wrapper. Added: head/contrib/jemalloc/FREEBSD-upgrade ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/jemalloc/FREEBSD-upgrade Tue Apr 17 07:22:14 2012 (r234370) @@ -0,0 +1,122 @@ +#!/bin/sh +# $FreeBSD$ +# +# Usage: cd /usr/src/contrib/jemalloc +# ./FREEBSD-upgrade [args] +# +# At least the following ports are required when importing jemalloc: +# - devel/autoconf +# - devel/git +# - devel/gmake +# - textproc/docbook-xsl +# +# The normal workflow for importing a new release is: +# +# cd /usr/src/contrib/jemalloc +# +# Merge local changes that were made since the previous import: +# +# ./FREEBSD-upgrade merge-changes +# ./FREEBSD-upgrade rediff +# +# Extract latest jemalloc release. +# +# ./FREEBSD-upgrade extract +# +# Fix patch conflicts as necessary, then regenerate diffs to update line +# offsets: +# +# ./FREEBSD-upgrade rediff +# ./FREEBSD-upgrade extract +# +# Do multiple buildworld/installworld rounds. If problems arise and patches +# are needed, edit the code in ${work} as necessary, then: +# +# ./FREEBSD-upgrade rediff +# ./FREEBSD-upgrade extract +# +# The rediff/extract order is important because rediff saves the local +# changes, then extract blows away the work tree and re-creates it with the +# diffs applied. +# +# Finally, to clean up: +# +# ./FREEBSD-upgrade clean + +set -e + +if [ ! -x "FREEBSD-upgrade" ] ; then + echo "Run from within src/contrib/jemalloc/" >&2 + exit 1 +fi + +src=`pwd` +workname="jemalloc.git" +work="${src}/../${workname}" # merge-changes expects ${workname} in "..". +changes="${src}/FREEBSD-changes" + +do_extract() { + local rev=$1 + # Clone. + rm -rf ${work} + git clone git://canonware.com/jemalloc.git ${work} + ( + cd ${work} + if [ "x${rev}" != "x" ] ; then + # Use optional rev argument to check out a revision other than HEAD on + # master. + git checkout ${rev} + fi + # Apply diffs before generating files. + patch -p1 < "${src}/FREEBSD-diffs" + find . -name '*.orig' -delete + # Generate various files. + ./autogen.sh --enable-cc-silence --enable-dss --enable-xmalloc \ + --enable-utrace --with-xslroot=/usr/local/share/xsl/docbook + gmake dist + ) +} + +do_diff() { + (cd ${work}; git add -A; git diff --cached) > FREEBSD-diffs +} + +command=$1 +shift +case "${command}" in + merge-changes) # Merge local changes that were made since the previous import. + rev=`cat VERSION |tr 'g' ' ' |awk '{print $2}'` + # Extract code corresponding to most recent import. + do_extract ${rev} + # Compute local differences to the upstream+patches and apply them. + ( + cd .. + diff -ru -X ${src}/FREEBSD-Xlist ${workname} jemalloc > ${changes} || true + ) + ( + cd ${work} + patch -p1 < ${changes} + find . -name '*.orig' -delete + ) + # Update diff. + do_diff + ;; + extract) # Extract upstream sources, apply patches, copy to contrib/jemalloc. + rev=$1 + do_extract ${rev} + # Delete existing files so that cruft doesn't silently remain. + rm -rf ChangeLog COPYING VERSION doc include src + # Copy files over. + tar cf - -C ${work} -X FREEBSD-Xlist . |tar xvf - + ;; + rediff) # Regenerate diffs based on working tree. + do_diff + ;; + clean) # Remove working tree and temporary files. + rm -rf ${work} ${changes} + ;; + *) + echo "Unsupported command: \"${command}\"" >&2 + exit 1 + ;; +esac Added: head/contrib/jemalloc/VERSION ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/jemalloc/VERSION Tue Apr 17 07:22:14 2012 (r234370) @@ -0,0 +1 @@ +1.0.0-258-g9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa Added: head/contrib/jemalloc/doc/jemalloc.3 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/jemalloc/doc/jemalloc.3 Tue Apr 17 07:22:14 2012 (r234370) @@ -0,0 +1,1464 @@ +'\" t +.\" Title: JEMALLOC +.\" Author: Jason Evans +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 04/16/2012 +.\" Manual: User Manual +.\" Source: jemalloc 1.0.0-258-g9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa +.\" Language: English +.\" +.TH "JEMALLOC" "3" "04/16/2012" "jemalloc 1.0.0-258-g9ef7f5dc34" "User Manual" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +jemalloc \- general purpose memory allocation functions +.SH "LIBRARY" +.PP +This manual describes jemalloc 1\&.0\&.0\-258\-g9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa\&. More information can be found at the +\m[blue]\fBjemalloc website\fR\m[]\&\s-2\u[1]\d\s+2\&. +.PP +The following configuration options are enabled in libc\*(Aqs built\-in jemalloc: +\fB\-\-enable\-dss\fR, +\fB\-\-enable\-experimental\fR, +\fB\-\-enable\-fill\fR, +\fB\-\-enable\-lazy\-lock\fR, +\fB\-\-enable\-munmap\fR, +\fB\-\-enable\-stats\fR, +\fB\-\-enable\-tcache\fR, +\fB\-\-enable\-tls\fR, +\fB\-\-enable\-utrace\fR, and +\fB\-\-enable\-xmalloc\fR\&. Additionally, +\fB\-\-enable\-debug\fR +is enabled in development versions of FreeBSD (controlled by the +\fBMALLOC_PRODUCTION\fR +make variable)\&. +.SH "SYNOPSIS" +.sp +.ft B +.nf +#include +#include +.fi +.ft +.SS "Standard API" +.HP \w'void\ *malloc('u +.BI "void *malloc(size_t\ " "size" ");" +.HP \w'void\ *calloc('u +.BI "void *calloc(size_t\ " "number" ", size_t\ " "size" ");" +.HP \w'int\ posix_memalign('u +.BI "int posix_memalign(void\ **" "ptr" ", size_t\ " "alignment" ", size_t\ " "size" ");" +.HP \w'void\ *aligned_alloc('u +.BI "void *aligned_alloc(size_t\ " "alignment" ", size_t\ " "size" ");" +.HP \w'void\ *realloc('u +.BI "void *realloc(void\ *" "ptr" ", size_t\ " "size" ");" +.HP \w'void\ free('u +.BI "void free(void\ *" "ptr" ");" +.SS "Non\-standard API" +.HP \w'size_t\ malloc_usable_size('u +.BI "size_t malloc_usable_size(const\ void\ *" "ptr" ");" +.HP \w'void\ malloc_stats_print('u +.BI "void malloc_stats_print(void\ " "(*write_cb)" "\ (void\ *,\ const\ char\ *), void\ *" "cbopaque" ", const\ char\ *" "opts" ");" +.HP \w'int\ mallctl('u +.BI "int mallctl(const\ char\ *" "name" ", void\ *" "oldp" ", size_t\ *" "oldlenp" ", void\ *" "newp" ", size_t\ " "newlen" ");" +.HP \w'int\ mallctlnametomib('u +.BI "int mallctlnametomib(const\ char\ *" "name" ", size_t\ *" "mibp" ", size_t\ *" "miblenp" ");" +.HP \w'int\ mallctlbymib('u +.BI "int mallctlbymib(const\ size_t\ *" "mib" ", size_t\ " "miblen" ", void\ *" "oldp" ", size_t\ *" "oldlenp" ", void\ *" "newp" ", size_t\ " "newlen" ");" +.HP \w'void\ (*malloc_message)('u +.BI "void (*malloc_message)(void\ *" "cbopaque" ", const\ char\ *" "s" ");" +.PP +const char *\fImalloc_conf\fR; +.SS "Experimental API" +.HP \w'int\ allocm('u +.BI "int allocm(void\ **" "ptr" ", size_t\ *" "rsize" ", size_t\ " "size" ", int\ " "flags" ");" +.HP \w'int\ rallocm('u +.BI "int rallocm(void\ **" "ptr" ", size_t\ *" "rsize" ", size_t\ " "size" ", size_t\ " "extra" ", int\ " "flags" ");" +.HP \w'int\ sallocm('u +.BI "int sallocm(const\ void\ *" "ptr" ", size_t\ *" "rsize" ", int\ " "flags" ");" +.HP \w'int\ dallocm('u +.BI "int dallocm(void\ *" "ptr" ", int\ " "flags" ");" +.HP \w'int\ nallocm('u +.BI "int nallocm(size_t\ *" "rsize" ", size_t\ " "size" ", int\ " "flags" ");" +.SH "DESCRIPTION" +.SS "Standard API" +.PP +The +\fBmalloc\fR\fB\fR +function allocates +\fIsize\fR +bytes of uninitialized memory\&. The allocated space is suitably aligned (after possible pointer coercion) for storage of any type of object\&. +.PP +The +\fBcalloc\fR\fB\fR +function allocates space for +\fInumber\fR +objects, each +\fIsize\fR +bytes in length\&. The result is identical to calling +\fBmalloc\fR\fB\fR +with an argument of +\fInumber\fR +* +\fIsize\fR, with the exception that the allocated memory is explicitly initialized to zero bytes\&. +.PP +The +\fBposix_memalign\fR\fB\fR +function allocates +\fIsize\fR +bytes of memory such that the allocation\*(Aqs base address is an even multiple of +\fIalignment\fR, and returns the allocation in the value pointed to by +\fIptr\fR\&. The requested +\fIalignment\fR +must be a power of 2 at least as large as +sizeof(\fBvoid *\fR)\&. +.PP +The +\fBaligned_alloc\fR\fB\fR +function allocates +\fIsize\fR +bytes of memory such that the allocation\*(Aqs base address is an even multiple of +\fIalignment\fR\&. The requested +\fIalignment\fR +must be a power of 2\&. Behavior is undefined if +\fIsize\fR +is not an integral multiple of +\fIalignment\fR\&. +.PP +The +\fBrealloc\fR\fB\fR +function changes the size of the previously allocated memory referenced by +\fIptr\fR +to +\fIsize\fR +bytes\&. The contents of the memory are unchanged up to the lesser of the new and old sizes\&. If the new size is larger, the contents of the newly allocated portion of the memory are undefined\&. Upon success, the memory referenced by +\fIptr\fR +is freed and a pointer to the newly allocated memory is returned\&. Note that +\fBrealloc\fR\fB\fR +may move the memory allocation, resulting in a different return value than +\fIptr\fR\&. If +\fIptr\fR +is +\fBNULL\fR, the +\fBrealloc\fR\fB\fR +function behaves identically to +\fBmalloc\fR\fB\fR +for the specified size\&. +.PP +The +\fBfree\fR\fB\fR +function causes the allocated memory referenced by +\fIptr\fR +to be made available for future allocations\&. If +\fIptr\fR +is +\fBNULL\fR, no action occurs\&. +.SS "Non\-standard API" +.PP +The +\fBmalloc_usable_size\fR\fB\fR +function returns the usable size of the allocation pointed to by +\fIptr\fR\&. The return value may be larger than the size that was requested during allocation\&. The +\fBmalloc_usable_size\fR\fB\fR +function is not a mechanism for in\-place +\fBrealloc\fR\fB\fR; rather it is provided solely as a tool for introspection purposes\&. Any discrepancy between the requested allocation size and the size reported by +\fBmalloc_usable_size\fR\fB\fR +should not be depended on, since such behavior is entirely implementation\-dependent\&. +.PP +The +\fBmalloc_stats_print\fR\fB\fR +function writes human\-readable summary statistics via the +\fIwrite_cb\fR +callback function pointer and +\fIcbopaque\fR +data passed to +\fIwrite_cb\fR, or +\fBmalloc_message\fR\fB\fR +if +\fIwrite_cb\fR +is +\fBNULL\fR\&. This function can be called repeatedly\&. General information that never changes during execution can be omitted by specifying "g" as a character within the +\fIopts\fR +string\&. Note that +\fBmalloc_message\fR\fB\fR +uses the +\fBmallctl*\fR\fB\fR +functions internally, so inconsistent statistics can be reported if multiple threads use these functions simultaneously\&. If +\fB\-\-enable\-stats\fR +is specified during configuration, \(lqm\(rq and \(lqa\(rq can be specified to omit merged arena and per arena statistics, respectively; \(lqb\(rq and \(lql\(rq can be specified to omit per size class statistics for bins and large objects, respectively\&. Unrecognized characters are silently ignored\&. Note that thread caching may prevent some statistics from being completely up to date, since extra locking would be required to merge counters that track thread cache operations\&. +.PP +The +\fBmallctl\fR\fB\fR +function provides a general interface for introspecting the memory allocator, as well as setting modifiable parameters and triggering actions\&. The period\-separated +\fIname\fR +argument specifies a location in a tree\-structured namespace; see the +MALLCTL NAMESPACE +section for documentation on the tree contents\&. To read a value, pass a pointer via +\fIoldp\fR +to adequate space to contain the value, and a pointer to its length via +\fIoldlenp\fR; otherwise pass +\fBNULL\fR +and +\fBNULL\fR\&. Similarly, to write a value, pass a pointer to the value via +\fInewp\fR, and its length via +\fInewlen\fR; otherwise pass +\fBNULL\fR +and +\fB0\fR\&. +.PP +The +\fBmallctlnametomib\fR\fB\fR +function provides a way to avoid repeated name lookups for applications that repeatedly query the same portion of the namespace, by translating a name to a \(lqManagement Information Base\(rq (MIB) that can be passed repeatedly to +\fBmallctlbymib\fR\fB\fR\&. Upon successful return from +\fBmallctlnametomib\fR\fB\fR, +\fImibp\fR +contains an array of +\fI*miblenp\fR +integers, where +\fI*miblenp\fR +is the lesser of the number of components in +\fIname\fR +and the input value of *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 09:02:56 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 78D23106566C; Tue, 17 Apr 2012 09:02:56 +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 592918FC08; Tue, 17 Apr 2012 09:02:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H92uDr073981; Tue, 17 Apr 2012 09:02:56 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H92u11073978; Tue, 17 Apr 2012 09:02:56 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201204170902.q3H92u11073978@svn.freebsd.org> From: David Xu Date: Tue, 17 Apr 2012 09:02:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234371 - in stable/9/sys: kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 09:02:56 -0000 Author: davidxu Date: Tue Apr 17 09:02:55 2012 New Revision: 234371 URL: http://svn.freebsd.org/changeset/base/234371 Log: MFC r233912: mtx operation UMTX_OP_MUTEX_WAKE has a side-effect that it accesses a mutex after a thread has unlocked it, it event writes data to the mutex memory to clear contention bit, there is a race that other threads can lock it and unlock it, then destroy it, so it should not write data to the mutex memory if there isn't any waiter. The new operation UMTX_OP_MUTEX_WAKE2 try to fix the problem. It requires thread library to clear the lock word entirely, then call the WAKE2 operation to check if there is any waiter in kernel, and try to wake up a thread, if necessary, the contention bit is set again by the operation. This also mitgates the chance that other threads find the contention bit and try to enter kernel to compete with each other to wake up sleeping thread, this is unnecessary. With this change, the mutex owner is no longer holding the mutex until it reaches a point where kernel umtx queue is locked, it releases the mutex as soon as possible. Performance is improved when the mutex is contensted heavily. On Intel i3-2310M, the runtime of a benchmark program is reduced from 26.87 seconds to 2.39 seconds, it even is better than UMTX_OP_MUTEX_WAKE which is deprecated now. http://people.freebsd.org/~davidxu/bench/mutex_perf.c Modified: stable/9/sys/kern/kern_umtx.c stable/9/sys/sys/umtx.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/kern_umtx.c ============================================================================== --- stable/9/sys/kern/kern_umtx.c Tue Apr 17 07:22:14 2012 (r234370) +++ stable/9/sys/kern/kern_umtx.c Tue Apr 17 09:02:55 2012 (r234371) @@ -1276,6 +1276,78 @@ do_wake_umutex(struct thread *td, struct return (0); } +/* + * Check if the mutex has waiters and tries to fix contention bit. + */ +static int +do_wake2_umutex(struct thread *td, struct umutex *m, uint32_t flags) +{ + struct umtx_key key; + uint32_t owner, old; + int type; + int error; + int count; + + switch(flags & (UMUTEX_PRIO_INHERIT | UMUTEX_PRIO_PROTECT)) { + case 0: + type = TYPE_NORMAL_UMUTEX; + break; + case UMUTEX_PRIO_INHERIT: + type = TYPE_PI_UMUTEX; + break; + case UMUTEX_PRIO_PROTECT: + type = TYPE_PP_UMUTEX; + break; + default: + return (EINVAL); + } + if ((error = umtx_key_get(m, type, GET_SHARE(flags), + &key)) != 0) + return (error); + + owner = 0; + umtxq_lock(&key); + umtxq_busy(&key); + count = umtxq_count(&key); + umtxq_unlock(&key); + /* + * Only repair contention bit if there is a waiter, this means the mutex + * is still being referenced by userland code, otherwise don't update + * any memory. + */ + if (count > 1) { + owner = fuword32(__DEVOLATILE(uint32_t *, &m->m_owner)); + while ((owner & UMUTEX_CONTESTED) ==0) { + old = casuword32(&m->m_owner, owner, + owner|UMUTEX_CONTESTED); + if (old == owner) + break; + owner = old; + } + } else if (count == 1) { + owner = fuword32(__DEVOLATILE(uint32_t *, &m->m_owner)); + while ((owner & ~UMUTEX_CONTESTED) != 0 && + (owner & UMUTEX_CONTESTED) == 0) { + old = casuword32(&m->m_owner, owner, + owner|UMUTEX_CONTESTED); + if (old == owner) + break; + owner = old; + } + } + umtxq_lock(&key); + if (owner == -1) { + error = EFAULT; + umtxq_signal(&key, INT_MAX); + } + else if (count != 0 && (owner & ~UMUTEX_CONTESTED) == 0) + umtxq_signal(&key, 1); + umtxq_unbusy(&key); + umtxq_unlock(&key); + umtx_key_release(&key); + return (error); +} + static inline struct umtx_pi * umtx_pi_alloc(int flags) { @@ -3183,6 +3255,12 @@ __umtx_op_sem_wake(struct thread *td, st return do_sem_wake(td, uap->obj); } +static int +__umtx_op_wake2_umutex(struct thread *td, struct _umtx_op_args *uap) +{ + return do_wake2_umutex(td, uap->obj, uap->val); +} + typedef int (*_umtx_op_func)(struct thread *td, struct _umtx_op_args *uap); static _umtx_op_func op_table[] = { @@ -3207,7 +3285,8 @@ static _umtx_op_func op_table[] = { __umtx_op_wake_umutex, /* UMTX_OP_UMUTEX_WAKE */ __umtx_op_sem_wait, /* UMTX_OP_SEM_WAIT */ __umtx_op_sem_wake, /* UMTX_OP_SEM_WAKE */ - __umtx_op_nwake_private /* UMTX_OP_NWAKE_PRIVATE */ + __umtx_op_nwake_private, /* UMTX_OP_NWAKE_PRIVATE */ + __umtx_op_wake2_umutex /* UMTX_OP_UMUTEX_WAKE2 */ }; int @@ -3473,7 +3552,8 @@ static _umtx_op_func op_table_compat32[] __umtx_op_wake_umutex, /* UMTX_OP_UMUTEX_WAKE */ __umtx_op_sem_wait_compat32, /* UMTX_OP_SEM_WAIT */ __umtx_op_sem_wake, /* UMTX_OP_SEM_WAKE */ - __umtx_op_nwake_private32 /* UMTX_OP_NWAKE_PRIVATE */ + __umtx_op_nwake_private32, /* UMTX_OP_NWAKE_PRIVATE */ + __umtx_op_wake2_umutex /* UMTX_OP_UMUTEX_WAKE2 */ }; int Modified: stable/9/sys/sys/umtx.h ============================================================================== --- stable/9/sys/sys/umtx.h Tue Apr 17 07:22:14 2012 (r234370) +++ stable/9/sys/sys/umtx.h Tue Apr 17 09:02:55 2012 (r234371) @@ -76,11 +76,12 @@ #define UMTX_OP_WAIT_UINT_PRIVATE 15 #define UMTX_OP_WAKE_PRIVATE 16 #define UMTX_OP_MUTEX_WAIT 17 -#define UMTX_OP_MUTEX_WAKE 18 +#define UMTX_OP_MUTEX_WAKE 18 /* deprecated */ #define UMTX_OP_SEM_WAIT 19 #define UMTX_OP_SEM_WAKE 20 #define UMTX_OP_NWAKE_PRIVATE 21 -#define UMTX_OP_MAX 22 +#define UMTX_OP_MUTEX_WAKE2 22 +#define UMTX_OP_MAX 23 /* Flags for UMTX_OP_CV_WAIT */ #define CVWAIT_CHECK_UNPARKING 0x01 From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 09:09:15 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 09277106564A; Tue, 17 Apr 2012 09:09:15 +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 DE6F68FC08; Tue, 17 Apr 2012 09:09:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H99Ecp074493; Tue, 17 Apr 2012 09:09:14 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H99E1E074489; Tue, 17 Apr 2012 09:09:14 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201204170909.q3H99E1E074489@svn.freebsd.org> From: David Xu Date: Tue, 17 Apr 2012 09:09:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234372 - stable/9/lib/libthr/thread X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 09:09:15 -0000 Author: davidxu Date: Tue Apr 17 09:09:14 2012 New Revision: 234372 URL: http://svn.freebsd.org/changeset/base/234372 Log: Merge 233103, 233912 from head: 233103: Some software think a mutex can be destroyed after it owned it, for example, it uses a serialization point like following: pthread_mutex_lock(&mutex); pthread_mutex_unlock(&mutex); pthread_mutex_destroy(&muetx); They think a previous lock holder should have already left the mutex and is no longer referencing it, so they destroy it. To be maximum compatible with such code, we use IA64 version to unlock the mutex in kernel, remove the two steps unlocking code. 233912: umtx operation UMTX_OP_MUTEX_WAKE has a side-effect that it accesses a mutex after a thread has unlocked it, it event writes data to the mutex memory to clear contention bit, there is a race that other threads can lock it and unlock it, then destroy it, so it should not write data to the mutex memory if there isn't any waiter. The new operation UMTX_OP_MUTEX_WAKE2 try to fix the problem. It requires thread library to clear the lock word entirely, then call the WAKE2 operation to check if there is any waiter in kernel, and try to wake up a thread, if necessary, the contention bit is set again by the operation. This also mitgates the chance that other threads find the contention bit and try to enter kernel to compete with each other to wake up sleeping thread, this is unnecessary. With this change, the mutex owner is no longer holding the mutex until it reaches a point where kernel umtx queue is locked, it releases the mutex as soon as possible. Performance is improved when the mutex is contensted heavily. On Intel i3-2310M, the runtime of a benchmark program is reduced from 26.87 seconds to 2.39 seconds, it even is better than UMTX_OP_MUTEX_WAKE which is deprecated now. http://people.freebsd.org/~davidxu/bench/mutex_perf.c Special code for stable/9: And add code to detect if the UMTX_OP_MUTEX_WAKE2 is available. Modified: stable/9/lib/libthr/thread/thr_private.h stable/9/lib/libthr/thread/thr_umtx.c stable/9/lib/libthr/thread/thr_umtx.h Directory Properties: stable/9/lib/libthr/ (props changed) Modified: stable/9/lib/libthr/thread/thr_private.h ============================================================================== --- stable/9/lib/libthr/thread/thr_private.h Tue Apr 17 09:02:55 2012 (r234371) +++ stable/9/lib/libthr/thread/thr_private.h Tue Apr 17 09:09:14 2012 (r234372) @@ -832,8 +832,6 @@ ssize_t __sys_write(int, const void *, s void __sys_exit(int); #endif -int _umtx_op_err(void *, int op, u_long, void *, void *) __hidden; - static inline int _thr_isthreaded(void) { Modified: stable/9/lib/libthr/thread/thr_umtx.c ============================================================================== --- stable/9/lib/libthr/thread/thr_umtx.c Tue Apr 17 09:02:55 2012 (r234371) +++ stable/9/lib/libthr/thread/thr_umtx.c Tue Apr 17 09:09:14 2012 (r234372) @@ -152,13 +152,35 @@ __thr_umutex_timedlock(struct umutex *mt int __thr_umutex_unlock(struct umutex *mtx, uint32_t id) { -#ifndef __ia64__ - /* XXX this logic has a race-condition on ia64. */ - if ((mtx->m_flags & (UMUTEX_PRIO_PROTECT | UMUTEX_PRIO_INHERIT)) == 0) { - atomic_cmpset_rel_32(&mtx->m_owner, id | UMUTEX_CONTESTED, UMUTEX_CONTESTED); - return _umtx_op_err(mtx, UMTX_OP_MUTEX_WAKE, 0, 0, 0); + static int wake2_avail = 0; + + if (__predict_false(wake2_avail == 0)) { + struct umutex test = DEFAULT_UMUTEX; + + if (_umtx_op(&test, UMTX_OP_MUTEX_WAKE2, test.m_flags, 0, 0) == -1) + wake2_avail = -1; + else + wake2_avail = 1; + } + + if (wake2_avail != 1) + goto unlock; + + uint32_t flags = mtx->m_flags; + + if ((flags & (UMUTEX_PRIO_PROTECT | UMUTEX_PRIO_INHERIT)) == 0) { + uint32_t owner; + do { + owner = mtx->m_owner; + if (__predict_false((owner & ~UMUTEX_CONTESTED) != id)) + return (EPERM); + } while (__predict_false(!atomic_cmpset_rel_32(&mtx->m_owner, + owner, UMUTEX_UNOWNED))); + if ((owner & UMUTEX_CONTESTED)) + (void)_umtx_op_err(mtx, UMTX_OP_MUTEX_WAKE2, flags, 0, 0); + return (0); } -#endif /* __ia64__ */ +unlock: return _umtx_op_err(mtx, UMTX_OP_MUTEX_UNLOCK, 0, 0, 0); } Modified: stable/9/lib/libthr/thread/thr_umtx.h ============================================================================== --- stable/9/lib/libthr/thread/thr_umtx.h Tue Apr 17 09:02:55 2012 (r234371) +++ stable/9/lib/libthr/thread/thr_umtx.h Tue Apr 17 09:09:14 2012 (r234372) @@ -35,6 +35,7 @@ #define DEFAULT_UMUTEX {0,0,{0,0},{0,0,0,0}} #define DEFAULT_URWLOCK {0,0,0,0,{0,0,0,0}} +int _umtx_op_err(void *, int op, u_long, void *, void *) __hidden; int __thr_umutex_lock(struct umutex *mtx, uint32_t id) __hidden; int __thr_umutex_lock_spin(struct umutex *mtx, uint32_t id) __hidden; int __thr_umutex_timedlock(struct umutex *mtx, uint32_t id, @@ -119,9 +120,9 @@ _thr_umutex_timedlock(struct umutex *mtx static inline int _thr_umutex_unlock(struct umutex *mtx, uint32_t id) { - if (atomic_cmpset_rel_32(&mtx->m_owner, id, UMUTEX_UNOWNED)) - return (0); - return (__thr_umutex_unlock(mtx, id)); + if (atomic_cmpset_rel_32(&mtx->m_owner, id, UMUTEX_UNOWNED)) + return (0); + return (__thr_umutex_unlock(mtx, id)); } static inline int From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 09:18:07 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 16C59106566C; Tue, 17 Apr 2012 09:18:07 +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 01AA38FC0A; Tue, 17 Apr 2012 09:18:07 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3H9I60V074847; Tue, 17 Apr 2012 09:18:06 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3H9I6YL074845; Tue, 17 Apr 2012 09:18:06 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201204170918.q3H9I6YL074845@svn.freebsd.org> From: David Xu Date: Tue, 17 Apr 2012 09:18:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234373 - stable/8/lib/libthr/thread X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 09:18:07 -0000 Author: davidxu Date: Tue Apr 17 09:18:06 2012 New Revision: 234373 URL: http://svn.freebsd.org/changeset/base/234373 Log: Merge 233103 from head: Some software think a mutex can be destroyed after it owned it, for example, it uses a serialization point like following: pthread_mutex_lock(&mutex); pthread_mutex_unlock(&mutex); pthread_mutex_destroy(&muetx); They think a previous lock holder should have already left the mutex and is no longer referencing it, so they destroy it. To be maximum compatible with such code, we use IA64 version to unlock the mutex in kernel, remove the two steps unlocking code. Modified: stable/8/lib/libthr/thread/thr_umtx.c Directory Properties: stable/8/lib/libthr/ (props changed) Modified: stable/8/lib/libthr/thread/thr_umtx.c ============================================================================== --- stable/8/lib/libthr/thread/thr_umtx.c Tue Apr 17 09:09:14 2012 (r234372) +++ stable/8/lib/libthr/thread/thr_umtx.c Tue Apr 17 09:18:06 2012 (r234373) @@ -112,13 +112,6 @@ __thr_umutex_timedlock(struct umutex *mt int __thr_umutex_unlock(struct umutex *mtx, uint32_t id) { -#ifndef __ia64__ - /* XXX this logic has a race-condition on ia64. */ - if ((mtx->m_flags & (UMUTEX_PRIO_PROTECT | UMUTEX_PRIO_INHERIT)) == 0) { - atomic_cmpset_rel_32(&mtx->m_owner, id | UMUTEX_CONTESTED, UMUTEX_CONTESTED); - return _umtx_op_err(mtx, UMTX_OP_MUTEX_WAKE, 0, 0, 0); - } -#endif /* __ia64__ */ return _umtx_op_err(mtx, UMTX_OP_MUTEX_UNLOCK, 0, 0, 0); } From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 09:35:12 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 41B081065675; Tue, 17 Apr 2012 09:35:12 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mx1.sbone.de (mx1.sbone.de [IPv6:2a01:4f8:130:3ffc::401:25]) by mx1.freebsd.org (Postfix) with ESMTP id E54E58FC19; Tue, 17 Apr 2012 09:35:11 +0000 (UTC) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:31::2013:587]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.sbone.de (Postfix) with ESMTPS id 0560B25D385D; Tue, 17 Apr 2012 09:35:10 +0000 (UTC) Received: from content-filter.sbone.de (content-filter.sbone.de [IPv6:fde9:577b:c1a9:31::2013:2742]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id 32C44BE505F; Tue, 17 Apr 2012 09:35:10 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:31::2013:587]) by content-filter.sbone.de (content-filter.sbone.de [fde9:577b:c1a9:31::2013:2742]) (amavisd-new, port 10024) with ESMTP id WRr16rG-MoQN; Tue, 17 Apr 2012 09:35:09 +0000 (UTC) Received: from orange-en1.sbone.de (orange-en1.sbone.de [IPv6:fde9:577b:c1a9:31:cabc:c8ff:fecf:e8e3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id 1A34DBE505D; Tue, 17 Apr 2012 09:35:09 +0000 (UTC) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: "Bjoern A. Zeeb" In-Reply-To: <201204170722.q3H7ME6A070934@svn.freebsd.org> Date: Tue, 17 Apr 2012 09:35:08 +0000 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> To: Jason Evans X-Mailer: Apple Mail (2.1084) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 09:35:12 -0000 On 17. Apr 2012, at 07:22 , Jason Evans wrote: > Author: jasone > Date: Tue Apr 17 07:22:14 2012 > New Revision: 234370 > URL: http://svn.freebsd.org/changeset/base/234370 >=20 > Log: > Import jemalloc 9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa (dev branch, > prior to 3.0.0 release) as contrib/jemalloc, and integrate it into = libc. > The code being imported by this commit diverged from > lib/libc/stdlib/malloc.c in March 2010, which means that a portion of > the jemalloc 1.0.0 ChangeLog entries are relevant, as are the entries > for all subsequent releases. I am seeing a lot of build failures on all archs with: = /scratch/tmp/bz/obj//i386.i386/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_sub_and_fetch_8' = /scratch/tmp/bz/obj//i386.i386/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_add_and_fetch_8' = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_sub_and_fetch_8' = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_sub_and_fetch_4' = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_add_and_fetch_4' = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_add_and_fetch_8' ... ... --=20 Bjoern A. Zeeb You have to have visions! It does not matter how good you are. It matters what good you do! From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 09:43:49 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C0C81106564A; Tue, 17 Apr 2012 09:43:49 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mx1.sbone.de (mx1.sbone.de [IPv6:2a01:4f8:130:3ffc::401:25]) by mx1.freebsd.org (Postfix) with ESMTP id 4FDC58FC08; Tue, 17 Apr 2012 09:43:49 +0000 (UTC) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:31::2013:587]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.sbone.de (Postfix) with ESMTPS id E4C6F25D385D; Tue, 17 Apr 2012 09:43:47 +0000 (UTC) Received: from content-filter.sbone.de (content-filter.sbone.de [IPv6:fde9:577b:c1a9:31::2013:2742]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id 1414BBE5061; Tue, 17 Apr 2012 09:43:47 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:31::2013:587]) by content-filter.sbone.de (content-filter.sbone.de [fde9:577b:c1a9:31::2013:2742]) (amavisd-new, port 10024) with ESMTP id Ee7hz+KlFQ1T; Tue, 17 Apr 2012 09:43:45 +0000 (UTC) Received: from orange-en1.sbone.de (orange-en1.sbone.de [IPv6:fde9:577b:c1a9:31:cabc:c8ff:fecf:e8e3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id 596BBBE5060; Tue, 17 Apr 2012 09:43:45 +0000 (UTC) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: "Bjoern A. Zeeb" In-Reply-To: Date: Tue, 17 Apr 2012 09:43:44 +0000 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> To: Jason Evans X-Mailer: Apple Mail (2.1084) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 09:43:49 -0000 On 17. Apr 2012, at 09:35 , Bjoern A. Zeeb wrote: >=20 > On 17. Apr 2012, at 07:22 , Jason Evans wrote: >=20 >> Author: jasone >> Date: Tue Apr 17 07:22:14 2012 >> New Revision: 234370 >> URL: http://svn.freebsd.org/changeset/base/234370 >>=20 >> Log: >> Import jemalloc 9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa (dev branch, >> prior to 3.0.0 release) as contrib/jemalloc, and integrate it into = libc. >> The code being imported by this commit diverged from >> lib/libc/stdlib/malloc.c in March 2010, which means that a portion of >> the jemalloc 1.0.0 ChangeLog entries are relevant, as are the entries >> for all subsequent releases. >=20 > I am seeing a lot of build failures on all archs with: >=20 > = /scratch/tmp/bz/obj//i386.i386/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_sub_and_fetch_8' > = /scratch/tmp/bz/obj//i386.i386/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_add_and_fetch_8' >=20 > = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_sub_and_fetch_8' > = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_sub_and_fetch_4' > = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_add_and_fetch_4' > = /scratch/tmp/bz/obj//arm.armeb/scratch/tmp/bz/head.svn/tmp/usr/lib/libc.so= : undefined reference to `__sync_add_and_fetch_8' Actually it seems these failed: arm.armeb buildworld failed, check _.arm.armeb.buildworld for details arm.arm buildworld failed, check _.arm.arm.buildworld for details mips.mips64 buildworld failed, check _.mips.mips64.buildworld for = details mips.mipsel buildworld failed, check _.mips.mipsel.buildworld for = details mips.mips64el buildworld failed, check _.mips.mips64el.buildworld for = details mips.mipsn32 buildworld failed, check _.mips.mipsn32.buildworld for = details mips.mips buildworld failed, check _.mips.mips.buildworld for details i386.i386 buildworld failed, check _.i386.i386.buildworld for details pc98.i386 buildworld failed, check _.pc98.i386.buildworld for details powerpc.powerpc buildworld failed, check _.powerpc.powerpc.buildworld = for details powerpc.powerpc64 buildworld failed, check = _.powerpc.powerpc64.buildworld for details --=20 Bjoern A. Zeeb You have to have visions! It does not matter how good you are. It matters what good you do! From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 10:44:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0F7FB106564A; Tue, 17 Apr 2012 10:44:29 +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 EE6A88FC15; Tue, 17 Apr 2012 10:44:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HAiS1f078765; Tue, 17 Apr 2012 10:44:28 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HAiSUL078763; Tue, 17 Apr 2012 10:44:28 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204171044.q3HAiSUL078763@svn.freebsd.org> From: Edward Tomasz Napierala Date: Tue, 17 Apr 2012 10:44: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: r234374 - head/sys/cam/scsi X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 10:44:29 -0000 Author: trasz Date: Tue Apr 17 10:44:28 2012 New Revision: 234374 URL: http://svn.freebsd.org/changeset/base/234374 Log: Fix panic at boot with SD/MMC readers with no media present, introduced at r234177. Note that this is a temporary fix, until I come up with something prettier. Modified: head/sys/cam/scsi/scsi_da.c Modified: head/sys/cam/scsi/scsi_da.c ============================================================================== --- head/sys/cam/scsi/scsi_da.c Tue Apr 17 09:18:06 2012 (r234373) +++ head/sys/cam/scsi/scsi_da.c Tue Apr 17 10:44:28 2012 (r234374) @@ -938,7 +938,9 @@ daopen(struct disk *dp) if (error != 0) xpt_print(periph->path, "unable to retrieve capacity data"); - if (periph->flags & CAM_PERIPH_INVALID) + if (periph->flags & CAM_PERIPH_INVALID || + softc->disk->d_sectorsize == 0 || + softc->disk->d_mediasize == 0) error = ENXIO; if (error == 0 && (softc->flags & DA_FLAG_PACK_REMOVABLE) != 0 && From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 11:01:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 27EE81065672; Tue, 17 Apr 2012 11:01:18 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1238F8FC1F; Tue, 17 Apr 2012 11:01:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HB1H8K079345; Tue, 17 Apr 2012 11:01:17 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HB1H1o079343; Tue, 17 Apr 2012 11:01:17 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201204171101.q3HB1H1o079343@svn.freebsd.org> From: Sergey Kandaurov Date: Tue, 17 Apr 2012 11:01:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234375 - stable/9/sys/dev/xen/balloon X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 11:01:18 -0000 Author: pluknet Date: Tue Apr 17 11:01:17 2012 New Revision: 234375 URL: http://svn.freebsd.org/changeset/base/234375 Log: MFC r233939: Free ballooned pages with the corresponding malloc type. Modified: stable/9/sys/dev/xen/balloon/balloon.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/dev/xen/balloon/balloon.c ============================================================================== --- stable/9/sys/dev/xen/balloon/balloon.c Tue Apr 17 10:44:28 2012 (r234374) +++ stable/9/sys/dev/xen/balloon/balloon.c Tue Apr 17 11:01:17 2012 (r234375) @@ -140,7 +140,7 @@ balloon_retrieve(void) STAILQ_REMOVE_HEAD(&ballooned_pages, list); page = entry->page; - free(entry, M_DEVBUF); + free(entry, M_BALLOON); bs.balloon_low--; From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 11:13:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8EBD7106564A; Tue, 17 Apr 2012 11:13:04 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7AC958FC16; Tue, 17 Apr 2012 11:13:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HBD4JR079748; Tue, 17 Apr 2012 11:13:04 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HBD4SZ079746; Tue, 17 Apr 2012 11:13:04 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201204171113.q3HBD4SZ079746@svn.freebsd.org> From: Alexander Motin Date: Tue, 17 Apr 2012 11:13: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: r234376 - head/share/misc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 11:13:04 -0000 Author: mav Date: Tue Apr 17 11:13:03 2012 New Revision: 234376 URL: http://svn.freebsd.org/changeset/base/234376 Log: Add some more SCSI mode pages from SPC-4 spec. MFC after: 1 week Modified: head/share/misc/scsi_modes Modified: head/share/misc/scsi_modes ============================================================================== --- head/share/misc/scsi_modes Tue Apr 17 11:01:17 2012 (r234375) +++ head/share/misc/scsi_modes Tue Apr 17 11:13:03 2012 (r234376) @@ -92,6 +92,25 @@ {Reserved} *i1 } +0x15 "Extended Page"; + +0x16 "Extended Device-Type Specific Page"; + +0x1c "Informational Exceptions Control Page" { + {PERF} t1 + {Reserved} *t1 + {EBF} t1 + {EWasc} t1 + {DExcpt} t1 + {TEST} t1 + {EBACKERR} t1 + {LogErr} t1 + {Reserved} *t4 + {MRIE} b4 + {Interval Timer} i4 + {Report Count} i4 +} + 0x09 "Peripheral Device Page" { {Interface Identifier} i2 {Reserved} *i1 @@ -100,7 +119,7 @@ {Reserved} *i1 } -0x1a "Power Control" { +0x1a "Power Condition Page" { {Reserved} *i1 {Reserved} *t6 {Idle} t1 @@ -109,6 +128,10 @@ {Standby Condition Timer} i4 } +0x18 "Protocol-Specific LUN Page"; + +0x19 "Protocol-Specific Port Page"; + # DIRECT ACCESS DEVICES 0x08 "Caching Page" { {IC} t1 From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 11:49:21 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8B8841065672; Tue, 17 Apr 2012 11:49:21 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 75FE98FC0C; Tue, 17 Apr 2012 11:49:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HBnLbG080898; Tue, 17 Apr 2012 11:49:21 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HBnLsh080896; Tue, 17 Apr 2012 11:49:21 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201204171149.q3HBnLsh080896@svn.freebsd.org> From: Sergey Kandaurov Date: Tue, 17 Apr 2012 11:49:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234377 - stable/8/sys/dev/xen/balloon X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 11:49:21 -0000 Author: pluknet Date: Tue Apr 17 11:49:21 2012 New Revision: 234377 URL: http://svn.freebsd.org/changeset/base/234377 Log: MFC r233939: Free ballooned pages with the corresponding malloc type. Modified: stable/8/sys/dev/xen/balloon/balloon.c Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/dev/xen/balloon/balloon.c ============================================================================== --- stable/8/sys/dev/xen/balloon/balloon.c Tue Apr 17 11:13:03 2012 (r234376) +++ stable/8/sys/dev/xen/balloon/balloon.c Tue Apr 17 11:49:21 2012 (r234377) @@ -140,7 +140,7 @@ balloon_retrieve(void) STAILQ_REMOVE_HEAD(&ballooned_pages, list); page = entry->page; - free(entry, M_DEVBUF); + free(entry, M_BALLOON); bs.balloon_low--; From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 11:54:01 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A970E106566B; Tue, 17 Apr 2012 11:54:01 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 943778FC19; Tue, 17 Apr 2012 11:54:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HBs1mF081084; Tue, 17 Apr 2012 11:54:01 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HBs1SL081082; Tue, 17 Apr 2012 11:54:01 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201204171154.q3HBs1SL081082@svn.freebsd.org> From: Sergey Kandaurov Date: Tue, 17 Apr 2012 11:54:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234378 - stable/9/lib/libc/gen X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 11:54:01 -0000 Author: pluknet Date: Tue Apr 17 11:54:01 2012 New Revision: 234378 URL: http://svn.freebsd.org/changeset/base/234378 Log: MFC 233296,233300: Prevent fs_file NULL pointer dereference. Modified: stable/9/lib/libc/gen/fstab.c Directory Properties: stable/9/lib/libc/ (props changed) Modified: stable/9/lib/libc/gen/fstab.c ============================================================================== --- stable/9/lib/libc/gen/fstab.c Tue Apr 17 11:49:21 2012 (r234377) +++ stable/9/lib/libc/gen/fstab.c Tue Apr 17 11:54:01 2012 (r234378) @@ -91,7 +91,7 @@ fixfsfile() struct stat sb; struct statfs sf; - if (strcmp(_fs_fstab.fs_file, "/") != 0) + if (_fs_fstab.fs_file != NULL && strcmp(_fs_fstab.fs_file, "/") != 0) return; if (statfs("/", &sf) != 0) return; From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 11:55:19 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D57711065670; Tue, 17 Apr 2012 11:55:19 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C02148FC19; Tue, 17 Apr 2012 11:55:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HBtJwr081188; Tue, 17 Apr 2012 11:55:19 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HBtJnJ081186; Tue, 17 Apr 2012 11:55:19 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201204171155.q3HBtJnJ081186@svn.freebsd.org> From: Sergey Kandaurov Date: Tue, 17 Apr 2012 11:55:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234379 - stable/8/lib/libc/gen X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 11:55:20 -0000 Author: pluknet Date: Tue Apr 17 11:55:19 2012 New Revision: 234379 URL: http://svn.freebsd.org/changeset/base/234379 Log: MFC 233296,233300: Prevent fs_file NULL pointer dereference. Modified: stable/8/lib/libc/gen/fstab.c Directory Properties: stable/8/lib/libc/ (props changed) Modified: stable/8/lib/libc/gen/fstab.c ============================================================================== --- stable/8/lib/libc/gen/fstab.c Tue Apr 17 11:54:01 2012 (r234378) +++ stable/8/lib/libc/gen/fstab.c Tue Apr 17 11:55:19 2012 (r234379) @@ -91,7 +91,7 @@ fixfsfile() struct stat sb; struct statfs sf; - if (strcmp(_fs_fstab.fs_file, "/") != 0) + if (_fs_fstab.fs_file != NULL && strcmp(_fs_fstab.fs_file, "/") != 0) return; if (statfs("/", &sf) != 0) return; From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 11:55:55 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0BAE3106564A; Tue, 17 Apr 2012 11:55:55 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from mail-lb0-f182.google.com (mail-lb0-f182.google.com [209.85.217.182]) by mx1.freebsd.org (Postfix) with ESMTP id 1414C8FC15; Tue, 17 Apr 2012 11:55:53 +0000 (UTC) Received: by lbbgm6 with SMTP id gm6so381483lbb.13 for ; Tue, 17 Apr 2012 04:55:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type :content-transfer-encoding; bh=iQJzSib89+Dp9sw4yZtSTh2hgTDfZ0loNAT2iWgxgN4=; b=UwP3LD0RSbdkvt6+9xJRDtJ698vTy2YADyv6m620cyTyE8O/D35xGrTF8+1Rw7wW1A 7xB5jREdv1MbyfVWxn3moRwaJyJv4E/EBIAVP/zLVLZklgOAOkn0TgG2iGhVwYzIQvp3 t+qsKsucP9DfgGkIgYiGHi26lNw1gR+hxPFPSdLkffucVFc5gtsgvlf94lOmIkczR9e1 vOnPTmeLwXkBEuR4LUq8hqvqwBw28TobHjA//KPdQJmO7qMZGcCzVIEInUBHdeEkPNne KChleJN95MZ4z63ZYFVakhiR8ZvEh3ppj52mmCK6g3U+/IXmvzJ0ODiiJ3pFChwdgCHw l5gQ== MIME-Version: 1.0 Received: by 10.112.26.10 with SMTP id h10mr6829642lbg.79.1334663752798; Tue, 17 Apr 2012 04:55:52 -0700 (PDT) Sender: pluknet@gmail.com Received: by 10.152.25.69 with HTTP; Tue, 17 Apr 2012 04:55:52 -0700 (PDT) In-Reply-To: <20120414113132.GA71196@felucia.tataz.chchile.org> References: <201203220942.q2M9gSvv017339@svn.freebsd.org> <20120414113132.GA71196@felucia.tataz.chchile.org> Date: Tue, 17 Apr 2012 15:55:52 +0400 X-Google-Sender-Auth: 5tu11rMultZFEMWFftEkO-qA3Ug Message-ID: From: Sergey Kandaurov To: Jeremie Le Hen , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: Subject: Re: svn commit: r233296 - head/lib/libc/gen X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 11:55:55 -0000 On 14 April 2012 15:31, Jeremie Le Hen wrote: > Hi Sergey, > > On Thu, Mar 22, 2012 at 09:42:28AM +0000, Sergey Kandaurov wrote: >> Author: pluknet >> Date: Thu Mar 22 09:42:27 2012 >> New Revision: 233296 >> URL: http://svn.freebsd.org/changeset/base/233296 >> >> Log: >> =A0 Prevent fs_file NULL pointer dereference in fixfsfile() uncovered af= ter r1.5 >> =A0 when passing damaged user-supplied fstab file data. >> >> =A0 MFC after: =A01 week >> >> Modified: >> =A0 head/lib/libc/gen/fstab.c >> >> Modified: head/lib/libc/gen/fstab.c >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=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/gen/fstab.c Thu Mar 22 09:29:07 2012 =A0 =A0 =A0 =A0(r= 233295) >> +++ head/lib/libc/gen/fstab.c Thu Mar 22 09:42:27 2012 =A0 =A0 =A0 =A0(r= 233296) >> @@ -91,7 +91,7 @@ fixfsfile() >> =A0 =A0 =A0 struct stat sb; >> =A0 =A0 =A0 struct statfs sf; >> >> - =A0 =A0 if (strcmp(_fs_fstab.fs_file, "/") !=3D 0) >> + =A0 =A0 if (_fs_fstab.fs_file !=3D NULL &&strcmp(_fs_fstab.fs_file, "/= ") !=3D 0) >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 return; >> =A0 =A0 =A0 if (statfs("/", &sf) !=3D 0) >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 return; > > Would you mind MFC'ing this please? =A0It bit me today :). > Merged. Thanks for reminding. --=20 wbr, pluknet From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 13:28:14 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B8EC01065670; Tue, 17 Apr 2012 13:28:14 +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 A3D358FC0C; Tue, 17 Apr 2012 13:28:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HDSEpS084050; Tue, 17 Apr 2012 13:28:14 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HDSEEa084048; Tue, 17 Apr 2012 13:28:14 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204171328.q3HDSEEa084048@svn.freebsd.org> From: Edward Tomasz Napierala Date: Tue, 17 Apr 2012 13:28: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: r234380 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 13:28:14 -0000 Author: trasz Date: Tue Apr 17 13:28:14 2012 New Revision: 234380 URL: http://svn.freebsd.org/changeset/base/234380 Log: Enforce upper bound on the input buffer length. Reported by: Mateusz Guzik Modified: head/sys/kern/kern_rctl.c Modified: head/sys/kern/kern_rctl.c ============================================================================== --- head/sys/kern/kern_rctl.c Tue Apr 17 11:55:19 2012 (r234379) +++ head/sys/kern/kern_rctl.c Tue Apr 17 13:28:14 2012 (r234380) @@ -73,6 +73,7 @@ FEATURE(rctl, "Resource Limits"); /* Default buffer size for rctl_get_rules(2). */ #define RCTL_DEFAULT_BUFSIZE 4096 +#define RCTL_MAX_INBUFLEN 4096 #define RCTL_LOG_BUFSIZE 128 /* @@ -1191,6 +1192,8 @@ rctl_read_inbuf(char **inputstr, const c if (inbuflen <= 0) return (EINVAL); + if (inbuflen > RCTL_MAX_INBUFLEN) + return (E2BIG); str = malloc(inbuflen + 1, M_RCTL, M_WAITOK); error = copyinstr(inbufp, str, inbuflen, NULL); From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 13:44:41 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 331521065689; Tue, 17 Apr 2012 13:44: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 1F0978FC1A; Tue, 17 Apr 2012 13:44:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HDie4m084587; Tue, 17 Apr 2012 13:44:40 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HDie9x084585; Tue, 17 Apr 2012 13:44:40 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204171344.q3HDie9x084585@svn.freebsd.org> From: Edward Tomasz Napierala Date: Tue, 17 Apr 2012 13:44: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: r234381 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 13:44:41 -0000 Author: trasz Date: Tue Apr 17 13:44:40 2012 New Revision: 234381 URL: http://svn.freebsd.org/changeset/base/234381 Log: Fix panic, triggered like this: "int main() { thr_exit(); }" Submitted by: Mateusz Guzik Modified: head/sys/kern/kern_thr.c Modified: head/sys/kern/kern_thr.c ============================================================================== --- head/sys/kern/kern_thr.c Tue Apr 17 13:28:14 2012 (r234380) +++ head/sys/kern/kern_thr.c Tue Apr 17 13:44:40 2012 (r234381) @@ -317,13 +317,13 @@ sys_thr_exit(struct thread *td, struct t rw_wlock(&tidhash_lock); PROC_LOCK(p); - racct_sub(p, RACCT_NTHR, 1); /* * Shutting down last thread in the proc. This will actually * call exit() in the trampoline when it returns. */ if (p->p_numthreads != 1) { + racct_sub(p, RACCT_NTHR, 1); LIST_REMOVE(td, td_hash); rw_wunlock(&tidhash_lock); tdsigcleanup(td); From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 14:31:03 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 42B6D1065670; Tue, 17 Apr 2012 14:31:03 +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 2CD628FC18; Tue, 17 Apr 2012 14:31:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HEV3dY086131; Tue, 17 Apr 2012 14:31:03 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HEV2mx086128; Tue, 17 Apr 2012 14:31:02 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204171431.q3HEV2mx086128@svn.freebsd.org> From: Edward Tomasz Napierala Date: Tue, 17 Apr 2012 14:31:02 +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: r234383 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 14:31:03 -0000 Author: trasz Date: Tue Apr 17 14:31:02 2012 New Revision: 234383 URL: http://svn.freebsd.org/changeset/base/234383 Log: Stop treating system processes as special. This fixes panics like the one triggered by this: # kldload geom_vinum # pwait `pgrep -S gv_worker` & # kldunload geom_vinum or this: GEOM_JOURNAL: Shutting down geom gjournal 3464572051. panic: destroying non-empty racct: 1 allocated for resource 6 which were tracked by jh@ to be caused by checking p->p_flag, while it wasn't initialised yet. Basically, during fork, the code checked p_flag, concluded the process isn't marked as P_SYSTEM, incremented the counter, and later on, when exiting, checked that the process was marked as P_SYSTEM, and thus didn't decrement it. Also, I believe there wasn't any good reason for checking P_SYSTEM in the first place. Tested by: jh Modified: head/sys/kern/kern_racct.c head/sys/kern/kern_rctl.c Modified: head/sys/kern/kern_racct.c ============================================================================== --- head/sys/kern/kern_racct.c Tue Apr 17 14:26:55 2012 (r234382) +++ head/sys/kern/kern_racct.c Tue Apr 17 14:31:02 2012 (r234383) @@ -267,9 +267,6 @@ racct_add_locked(struct proc *p, int res int error; #endif - if (p->p_flag & P_SYSTEM) - return (0); - SDT_PROBE(racct, kernel, rusage, add, p, resource, amount, 0, 0); /* @@ -344,9 +341,6 @@ void racct_add_force(struct proc *p, int resource, uint64_t amount) { - if (p->p_flag & P_SYSTEM) - return; - SDT_PROBE(racct, kernel, rusage, add_force, p, resource, amount, 0, 0); /* @@ -368,9 +362,6 @@ racct_set_locked(struct proc *p, int res int error; #endif - if (p->p_flag & P_SYSTEM) - return (0); - SDT_PROBE(racct, kernel, rusage, set, p, resource, amount, 0, 0); /* @@ -426,9 +417,6 @@ racct_set_force(struct proc *p, int reso { int64_t diff; - if (p->p_flag & P_SYSTEM) - return; - SDT_PROBE(racct, kernel, rusage, set, p, resource, amount, 0, 0); /* @@ -487,9 +475,6 @@ void racct_sub(struct proc *p, int resource, uint64_t amount) { - if (p->p_flag & P_SYSTEM) - return; - SDT_PROBE(racct, kernel, rusage, sub, p, resource, amount, 0, 0); /* @@ -556,12 +541,6 @@ racct_proc_fork(struct proc *parent, str */ racct_create(&child->p_racct); - /* - * No resource accounting for kernel processes. - */ - if (child->p_flag & P_SYSTEM) - return (0); - PROC_LOCK(parent); PROC_LOCK(child); mtx_lock(&racct_lock); @@ -723,8 +702,6 @@ racctd(void) FOREACH_PROC_IN_SYSTEM(p) { if (p->p_state != PRS_NORMAL) continue; - if (p->p_flag & P_SYSTEM) - continue; microuptime(&wallclock); timevalsub(&wallclock, &p->p_stats->p_start); Modified: head/sys/kern/kern_rctl.c ============================================================================== --- head/sys/kern/kern_rctl.c Tue Apr 17 14:26:55 2012 (r234382) +++ head/sys/kern/kern_rctl.c Tue Apr 17 14:31:02 2012 (r234383) @@ -994,11 +994,6 @@ rctl_rule_add(struct rctl_rule *rule) case RCTL_SUBJECT_TYPE_PROCESS: p = rule->rr_subject.rs_proc; KASSERT(p != NULL, ("rctl_rule_add: NULL proc")); - /* - * No resource limits for system processes. - */ - if (p->p_flag & P_SYSTEM) - return (EPERM); rctl_racct_add_rule(p->p_racct, rule); /* @@ -1036,8 +1031,6 @@ rctl_rule_add(struct rctl_rule *rule) */ sx_assert(&allproc_lock, SA_LOCKED); FOREACH_PROC_IN_SYSTEM(p) { - if (p->p_flag & P_SYSTEM) - continue; cred = p->p_ucred; switch (rule->rr_subject_type) { case RCTL_SUBJECT_TYPE_USER: @@ -1284,10 +1277,6 @@ sys_rctl_get_racct(struct thread *td, st error = EINVAL; goto out; } - if (p->p_flag & P_SYSTEM) { - error = EINVAL; - goto out; - } outputsbuf = rctl_racct_to_sbuf(p->p_racct, 0); break; case RCTL_SUBJECT_TYPE_USER: @@ -1719,20 +1708,7 @@ rctl_proc_fork(struct proc *parent, stru LIST_INIT(&child->p_racct->r_rule_links); - /* - * No limits for kernel processes. - */ - if (child->p_flag & P_SYSTEM) - return (0); - - /* - * Nothing to inherit from P_SYSTEM parents. - */ - if (parent->p_racct == NULL) { - KASSERT(parent->p_flag & P_SYSTEM, - ("non-system process without racct; p = %p", parent)); - return (0); - } + KASSERT(parent->p_racct != NULL, ("process without racct; p = %p", parent)); rw_wlock(&rctl_lock); From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 14:54:00 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DC2041065672; Tue, 17 Apr 2012 14:54:00 +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 C6C2B8FC0A; Tue, 17 Apr 2012 14:54:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HEs0hn086887; Tue, 17 Apr 2012 14:54:00 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HEs0cE086885; Tue, 17 Apr 2012 14:54:00 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204171454.q3HEs0cE086885@svn.freebsd.org> From: Edward Tomasz Napierala Date: Tue, 17 Apr 2012 14:54: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: r234385 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 14:54:01 -0000 Author: trasz Date: Tue Apr 17 14:54:00 2012 New Revision: 234385 URL: http://svn.freebsd.org/changeset/base/234385 Log: Fix bug where NFSv4 ACL enforcement code wouldn't unconditionally allow the owner to read and write ACL and file attributes when there was no entry with subject matching the owner. In other words, 'getfacl meh' shouldn't fail for the owner if the ACL looks like this: # file: meh # owner: trasz # group: wheel user:root:------a-------:------:allow Reported by: kientzle Modified: head/sys/kern/subr_acl_nfs4.c Modified: head/sys/kern/subr_acl_nfs4.c ============================================================================== --- head/sys/kern/subr_acl_nfs4.c Tue Apr 17 14:37:29 2012 (r234384) +++ head/sys/kern/subr_acl_nfs4.c Tue Apr 17 14:54:00 2012 (r234385) @@ -162,6 +162,9 @@ _acl_denies(const struct acl *aclp, int return (0); } + if (access_mask == 0) + return (0); + return (1); } From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 16:28:23 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0A587106564A; Tue, 17 Apr 2012 16:28:23 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E63258FC14; Tue, 17 Apr 2012 16:28:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HGSMgf089837; Tue, 17 Apr 2012 16:28:22 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HGSM9P089821; Tue, 17 Apr 2012 16:28:22 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204171628.q3HGSM9P089821@svn.freebsd.org> From: Kirk McKusick Date: Tue, 17 Apr 2012 16:28: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: r234386 - in head/sys: fs/coda fs/ext2fs fs/msdosfs fs/nfsclient kern nfsclient sys ufs/ffs ufs/ufs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 16:28:23 -0000 Author: mckusick Date: Tue Apr 17 16:28:22 2012 New Revision: 234386 URL: http://svn.freebsd.org/changeset/base/234386 Log: Replace the MNT_VNODE_FOREACH interface with MNT_VNODE_FOREACH_ALL. The primary changes are that the user of the interface no longer needs to manage the mount-mutex locking and that the vnode that is returned has its mutex locked (thus avoiding the need to check to see if its is DOOMED or other possible end of life senarios). To minimize compatibility issues for third-party developers, the old MNT_VNODE_FOREACH interface will remain available so that this change can be MFC'ed to 9. Following the MFC to 9, MNT_VNODE_FOREACH will be removed in head. The reason for this update is to prepare for the addition of the MNT_VNODE_FOREACH_ACTIVE interface that will loop over just the active vnodes associated with a mount point (typically less than 1% of the vnodes associated with the mount point). Reviewed by: kib Tested by: Peter Holm MFC after: 2 weeks Modified: head/sys/fs/coda/coda_subr.c head/sys/fs/ext2fs/ext2_vfsops.c head/sys/fs/msdosfs/msdosfs_vfsops.c head/sys/fs/nfsclient/nfs_clsubs.c head/sys/fs/nfsclient/nfs_clvfsops.c head/sys/kern/vfs_default.c head/sys/kern/vfs_mount.c head/sys/kern/vfs_subr.c head/sys/nfsclient/nfs_subs.c head/sys/nfsclient/nfs_vfsops.c head/sys/sys/mount.h head/sys/ufs/ffs/ffs_snapshot.c head/sys/ufs/ffs/ffs_softdep.c head/sys/ufs/ffs/ffs_vfsops.c head/sys/ufs/ufs/ufs_quota.c Modified: head/sys/fs/coda/coda_subr.c ============================================================================== --- head/sys/fs/coda/coda_subr.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/fs/coda/coda_subr.c Tue Apr 17 16:28:22 2012 (r234386) @@ -365,13 +365,7 @@ coda_checkunmounting(struct mount *mp) struct cnode *cp; int count = 0, bad = 0; - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, nvp) { - VI_LOCK(vp); - if (vp->v_iflag & VI_DOOMED) { - VI_UNLOCK(vp); - continue; - } + MNT_VNODE_FOREACH_ALL(vp, mp, nvp) { cp = VTOC(vp); count++; if (!(cp->c_flags & C_UNMOUNTING)) { @@ -381,7 +375,6 @@ coda_checkunmounting(struct mount *mp) } VI_UNLOCK(vp); } - MNT_IUNLOCK(mp); } void Modified: head/sys/fs/ext2fs/ext2_vfsops.c ============================================================================== --- head/sys/fs/ext2fs/ext2_vfsops.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/fs/ext2fs/ext2_vfsops.c Tue Apr 17 16:28:22 2012 (r234386) @@ -480,19 +480,12 @@ ext2_reload(struct mount *mp, struct thr } loop: - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - if (vp->v_iflag & VI_DOOMED) { - VI_UNLOCK(vp); - continue; - } - MNT_IUNLOCK(mp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { /* * Step 4: invalidate all cached file data. */ if (vget(vp, LK_EXCLUSIVE | LK_INTERLOCK, td)) { - MNT_VNODE_FOREACH_ABORT(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } if (vinvalbuf(vp, 0, 0, 0)) @@ -507,7 +500,7 @@ loop: if (error) { VOP_UNLOCK(vp, 0); vrele(vp); - MNT_VNODE_FOREACH_ABORT(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); return (error); } ext2_ei2i((struct ext2fs_dinode *) ((char *)bp->b_data + @@ -515,9 +508,7 @@ loop: brelse(bp); VOP_UNLOCK(vp, 0); vrele(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); return (0); } @@ -841,27 +832,24 @@ ext2_sync(struct mount *mp, int waitfor) */ MNT_ILOCK(mp); loop: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - if (vp->v_type == VNON || (vp->v_iflag & VI_DOOMED)) { + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { + if (vp->v_type == VNON) { VI_UNLOCK(vp); continue; } - MNT_IUNLOCK(mp); ip = VTOI(vp); if ((ip->i_flag & (IN_ACCESS | IN_CHANGE | IN_MODIFIED | IN_UPDATE)) == 0 && (vp->v_bufobj.bo_dirty.bv_cnt == 0 || waitfor == MNT_LAZY)) { VI_UNLOCK(vp); - MNT_ILOCK(mp); continue; } error = vget(vp, LK_EXCLUSIVE | LK_NOWAIT | LK_INTERLOCK, td); if (error) { MNT_ILOCK(mp); if (error == ENOENT) { - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } continue; @@ -870,9 +858,7 @@ loop: allerror = error; VOP_UNLOCK(vp, 0); vrele(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); /* * Force stale file system control information to be flushed. Modified: head/sys/fs/msdosfs/msdosfs_vfsops.c ============================================================================== --- head/sys/fs/msdosfs/msdosfs_vfsops.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/fs/msdosfs/msdosfs_vfsops.c Tue Apr 17 16:28:22 2012 (r234386) @@ -923,27 +923,22 @@ msdosfs_sync(struct mount *mp, int waitf /* * Write back each (modified) denode. */ - MNT_ILOCK(mp); loop: - MNT_VNODE_FOREACH(vp, mp, nvp) { - VI_LOCK(vp); - if (vp->v_type == VNON || (vp->v_iflag & VI_DOOMED)) { + MNT_VNODE_FOREACH_ALL(vp, mp, nvp) { + if (vp->v_type == VNON) { VI_UNLOCK(vp); continue; } - MNT_IUNLOCK(mp); dep = VTODE(vp); if ((dep->de_flag & (DE_ACCESS | DE_CREATE | DE_UPDATE | DE_MODIFIED)) == 0 && (vp->v_bufobj.bo_dirty.bv_cnt == 0 || waitfor == MNT_LAZY)) { VI_UNLOCK(vp); - MNT_ILOCK(mp); continue; } error = vget(vp, LK_EXCLUSIVE | LK_NOWAIT | LK_INTERLOCK, td); if (error) { - MNT_ILOCK(mp); if (error == ENOENT) goto loop; continue; @@ -953,9 +948,7 @@ loop: allerror = error; VOP_UNLOCK(vp, 0); vrele(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); /* * Flush filesystem control info. Modified: head/sys/fs/nfsclient/nfs_clsubs.c ============================================================================== --- head/sys/fs/nfsclient/nfs_clsubs.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/fs/nfsclient/nfs_clsubs.c Tue Apr 17 16:28:22 2012 (r234386) @@ -367,17 +367,10 @@ ncl_clearcommit(struct mount *mp) struct buf *bp, *nbp; struct bufobj *bo; - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, nvp) { + MNT_VNODE_FOREACH_ALL(vp, mp, nvp) { bo = &vp->v_bufobj; - VI_LOCK(vp); - if (vp->v_iflag & VI_DOOMED) { - VI_UNLOCK(vp); - continue; - } vholdl(vp); VI_UNLOCK(vp); - MNT_IUNLOCK(mp); BO_LOCK(bo); TAILQ_FOREACH_SAFE(bp, &bo->bo_dirty.bv_hd, b_bobufs, nbp) { if (!BUF_ISLOCKED(bp) && @@ -387,9 +380,7 @@ ncl_clearcommit(struct mount *mp) } BO_UNLOCK(bo); vdrop(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); } /* Modified: head/sys/fs/nfsclient/nfs_clvfsops.c ============================================================================== --- head/sys/fs/nfsclient/nfs_clvfsops.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/fs/nfsclient/nfs_clvfsops.c Tue Apr 17 16:28:22 2012 (r234386) @@ -1508,24 +1508,21 @@ nfs_sync(struct mount *mp, int waitfor) MNT_IUNLOCK(mp); return (EBADF); } + MNT_IUNLOCK(mp); /* * Force stale buffer cache information to be flushed. */ loop: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - MNT_IUNLOCK(mp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { /* XXX Racy bv_cnt check. */ if (NFSVOPISLOCKED(vp) || vp->v_bufobj.bo_dirty.bv_cnt == 0 || waitfor == MNT_LAZY) { VI_UNLOCK(vp); - MNT_ILOCK(mp); continue; } if (vget(vp, LK_EXCLUSIVE | LK_INTERLOCK, td)) { - MNT_ILOCK(mp); - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } error = VOP_FSYNC(vp, waitfor, td); @@ -1533,10 +1530,7 @@ loop: allerror = error; NFSVOPUNLOCK(vp, 0); vrele(vp); - - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); return (allerror); } Modified: head/sys/kern/vfs_default.c ============================================================================== --- head/sys/kern/vfs_default.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/kern/vfs_default.c Tue Apr 17 16:28:22 2012 (r234386) @@ -1114,18 +1114,15 @@ vfs_stdsync(mp, waitfor) /* * Force stale buffer cache information to be flushed. */ - MNT_ILOCK(mp); loop: - MNT_VNODE_FOREACH(vp, mp, mvp) { - /* bv_cnt is an acceptable race here. */ - if (vp->v_bufobj.bo_dirty.bv_cnt == 0) + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { + if (vp->v_bufobj.bo_dirty.bv_cnt == 0) { + VI_UNLOCK(vp); continue; - VI_LOCK(vp); - MNT_IUNLOCK(mp); + } if ((error = vget(vp, lockreq, td)) != 0) { - MNT_ILOCK(mp); if (error == ENOENT) { - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } continue; @@ -1134,9 +1131,7 @@ loop: if (error) allerror = error; vput(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); return (allerror); } Modified: head/sys/kern/vfs_mount.c ============================================================================== --- head/sys/kern/vfs_mount.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/kern/vfs_mount.c Tue Apr 17 16:28:22 2012 (r234386) @@ -81,7 +81,6 @@ SYSCTL_INT(_vfs, OID_AUTO, usermount, CT "Unprivileged users may mount and unmount file systems"); MALLOC_DEFINE(M_MOUNT, "mount", "vfs mount structure"); -static MALLOC_DEFINE(M_VNODE_MARKER, "vnodemarker", "vnode marker"); static uma_zone_t mount_zone; /* List of mounted filesystems. */ @@ -1720,10 +1719,14 @@ vfs_copyopt(opts, name, dest, len) } /* - * This is a helper function for filesystems to traverse their - * vnodes. See MNT_VNODE_FOREACH() in sys/mount.h + * These are helper functions for filesystems to traverse all + * their vnodes. See MNT_VNODE_FOREACH() in sys/mount.h. + * + * This interface has been deprecated in favor of MNT_VNODE_FOREACH_ALL. */ +MALLOC_DECLARE(M_VNODE_MARKER); + struct vnode * __mnt_vnode_next(struct vnode **mvp, struct mount *mp) { @@ -1812,7 +1815,6 @@ __mnt_vnode_markerfree(struct vnode **mv MNT_REL(mp); } - int __vfs_statfs(struct mount *mp, struct statfs *sbp) { Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/kern/vfs_subr.c Tue Apr 17 16:28:22 2012 (r234386) @@ -2467,17 +2467,13 @@ vflush(struct mount *mp, int rootrefs, i } vput(rootvp); } - MNT_ILOCK(mp); loop: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { vholdl(vp); - MNT_IUNLOCK(mp); error = vn_lock(vp, LK_INTERLOCK | LK_EXCLUSIVE); if (error) { vdrop(vp); - MNT_ILOCK(mp); - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } /* @@ -2486,7 +2482,6 @@ loop: if ((flags & SKIPSYSTEM) && (vp->v_vflag & VV_SYSTEM)) { VOP_UNLOCK(vp, 0); vdrop(vp); - MNT_ILOCK(mp); continue; } /* @@ -2504,7 +2499,7 @@ loop: if (error != 0) { VOP_UNLOCK(vp, 0); vdrop(vp); - MNT_VNODE_FOREACH_ABORT(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); return (error); } error = VOP_GETATTR(vp, &vattr, td->td_ucred); @@ -2515,7 +2510,6 @@ loop: (vp->v_writecount == 0 || vp->v_type != VREG)) { VOP_UNLOCK(vp, 0); vdropl(vp); - MNT_ILOCK(mp); continue; } } else @@ -2540,9 +2534,7 @@ loop: } VOP_UNLOCK(vp, 0); vdropl(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); if (rootrefs > 0 && (flags & FORCECLOSE) == 0) { /* * If just the root vnode is busy, and if its refcount @@ -3279,19 +3271,15 @@ vfs_msync(struct mount *mp, int flags) struct vm_object *obj; CTR2(KTR_VFS, "%s: mp %p", __func__, mp); - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { obj = vp->v_object; if (obj != NULL && (obj->flags & OBJ_MIGHTBEDIRTY) != 0 && (flags == MNT_WAIT || VOP_ISLOCKED(vp) == 0)) { - MNT_IUNLOCK(mp); if (!vget(vp, LK_EXCLUSIVE | LK_RETRY | LK_INTERLOCK, curthread)) { if (vp->v_vflag & VV_NOSYNC) { /* unlinked */ vput(vp); - MNT_ILOCK(mp); continue; } @@ -3305,11 +3293,9 @@ vfs_msync(struct mount *mp, int flags) } vput(vp); } - MNT_ILOCK(mp); } else VI_UNLOCK(vp); } - MNT_IUNLOCK(mp); } /* @@ -4504,3 +4490,90 @@ vfs_unixify_accmode(accmode_t *accmode) return (0); } + +/* + * These are helper functions for filesystems to traverse all + * their vnodes. See MNT_VNODE_FOREACH_ALL() in sys/mount.h. + * + * This interface replaces MNT_VNODE_FOREACH. + */ + +MALLOC_DEFINE(M_VNODE_MARKER, "vnodemarker", "vnode marker"); + +struct vnode * +__mnt_vnode_next_all(struct vnode **mvp, struct mount *mp) +{ + struct vnode *vp; + + if (should_yield()) + kern_yield(PRI_UNCHANGED); + MNT_ILOCK(mp); + KASSERT((*mvp)->v_mount == mp, ("marker vnode mount list mismatch")); + vp = TAILQ_NEXT(*mvp, v_nmntvnodes); + while (vp != NULL && (vp->v_type == VMARKER || + (vp->v_iflag & VI_DOOMED) != 0)) + vp = TAILQ_NEXT(vp, v_nmntvnodes); + + /* Check if we are done */ + if (vp == NULL) { + __mnt_vnode_markerfree_all(mvp, mp); + /* MNT_IUNLOCK(mp); -- done in above function */ + mtx_assert(MNT_MTX(mp), MA_NOTOWNED); + return (NULL); + } + TAILQ_REMOVE(&mp->mnt_nvnodelist, *mvp, v_nmntvnodes); + TAILQ_INSERT_AFTER(&mp->mnt_nvnodelist, vp, *mvp, v_nmntvnodes); + VI_LOCK(vp); + MNT_IUNLOCK(mp); + return (vp); +} + +struct vnode * +__mnt_vnode_first_all(struct vnode **mvp, struct mount *mp) +{ + struct vnode *vp; + + *mvp = malloc(sizeof(struct vnode), M_VNODE_MARKER, M_WAITOK | M_ZERO); + MNT_ILOCK(mp); + MNT_REF(mp); + (*mvp)->v_type = VMARKER; + + vp = TAILQ_FIRST(&mp->mnt_nvnodelist); + while (vp != NULL && (vp->v_type == VMARKER || + (vp->v_iflag & VI_DOOMED) != 0)) + vp = TAILQ_NEXT(vp, v_nmntvnodes); + + /* Check if we are done */ + if (vp == NULL) { + *mvp = NULL; + MNT_REL(mp); + MNT_IUNLOCK(mp); + free(*mvp, M_VNODE_MARKER); + return (NULL); + } + (*mvp)->v_mount = mp; + TAILQ_INSERT_AFTER(&mp->mnt_nvnodelist, vp, *mvp, v_nmntvnodes); + VI_LOCK(vp); + MNT_IUNLOCK(mp); + return (vp); +} + + +void +__mnt_vnode_markerfree_all(struct vnode **mvp, struct mount *mp) +{ + + if (*mvp == NULL) { + MNT_IUNLOCK(mp); + return; + } + + mtx_assert(MNT_MTX(mp), MA_OWNED); + + KASSERT((*mvp)->v_mount == mp, ("marker vnode mount list mismatch")); + TAILQ_REMOVE(&mp->mnt_nvnodelist, *mvp, v_nmntvnodes); + MNT_REL(mp); + MNT_IUNLOCK(mp); + free(*mvp, M_VNODE_MARKER); + *mvp = NULL; +} Modified: head/sys/nfsclient/nfs_subs.c ============================================================================== --- head/sys/nfsclient/nfs_subs.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/nfsclient/nfs_subs.c Tue Apr 17 16:28:22 2012 (r234386) @@ -866,16 +866,10 @@ nfs_clearcommit(struct mount *mp) struct bufobj *bo; MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, nvp) { + MNT_VNODE_FOREACH_ALL(vp, mp, nvp) { bo = &vp->v_bufobj; - VI_LOCK(vp); - if (vp->v_iflag & VI_DOOMED) { - VI_UNLOCK(vp); - continue; - } vholdl(vp); VI_UNLOCK(vp); - MNT_IUNLOCK(mp); BO_LOCK(bo); TAILQ_FOREACH_SAFE(bp, &bo->bo_dirty.bv_hd, b_bobufs, nbp) { if (!BUF_ISLOCKED(bp) && @@ -885,9 +879,7 @@ nfs_clearcommit(struct mount *mp) } BO_UNLOCK(bo); vdrop(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); } /* Modified: head/sys/nfsclient/nfs_vfsops.c ============================================================================== --- head/sys/nfsclient/nfs_vfsops.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/nfsclient/nfs_vfsops.c Tue Apr 17 16:28:22 2012 (r234386) @@ -1457,19 +1457,15 @@ nfs_sync(struct mount *mp, int waitfor) * Force stale buffer cache information to be flushed. */ loop: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - MNT_IUNLOCK(mp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { /* XXX Racy bv_cnt check. */ if (VOP_ISLOCKED(vp) || vp->v_bufobj.bo_dirty.bv_cnt == 0 || waitfor == MNT_LAZY) { VI_UNLOCK(vp); - MNT_ILOCK(mp); continue; } if (vget(vp, LK_EXCLUSIVE | LK_INTERLOCK, td)) { - MNT_ILOCK(mp); - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } error = VOP_FSYNC(vp, waitfor, td); @@ -1477,10 +1473,7 @@ loop: allerror = error; VOP_UNLOCK(vp, 0); vrele(vp); - - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); return (allerror); } Modified: head/sys/sys/mount.h ============================================================================== --- head/sys/sys/mount.h Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/sys/mount.h Tue Apr 17 16:28:22 2012 (r234386) @@ -187,6 +187,30 @@ struct mount { struct lock mnt_explock; /* vfs_export walkers lock */ }; +/* + * Definitions for MNT_VNODE_FOREACH_ALL. + */ +struct vnode *__mnt_vnode_next_all(struct vnode **mvp, struct mount *mp); +struct vnode *__mnt_vnode_first_all(struct vnode **mvp, struct mount *mp); +void __mnt_vnode_markerfree_all(struct vnode **mvp, struct mount *mp); + +#define MNT_VNODE_FOREACH_ALL(vp, mp, mvp) \ + for (vp = __mnt_vnode_first_all(&(mvp), (mp)); \ + (vp) != NULL; vp = __mnt_vnode_next_all(&(mvp), (mp))) + +#define MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp) \ + do { \ + MNT_ILOCK(mp); \ + __mnt_vnode_markerfree_all(&(mvp), (mp)); \ + /* MNT_IUNLOCK(mp); -- done in above function */ \ + mtx_assert(MNT_MTX(mp), MA_NOTOWNED); \ + } while (0) + +/* + * Definitions for MNT_VNODE_FOREACH. + * + * This interface has been deprecated in favor of MNT_VNODE_FOREACH_ALL. + */ struct vnode *__mnt_vnode_next(struct vnode **mvp, struct mount *mp); struct vnode *__mnt_vnode_first(struct vnode **mvp, struct mount *mp); void __mnt_vnode_markerfree(struct vnode **mvp, struct mount *mp); Modified: head/sys/ufs/ffs/ffs_snapshot.c ============================================================================== --- head/sys/ufs/ffs/ffs_snapshot.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/ufs/ffs/ffs_snapshot.c Tue Apr 17 16:28:22 2012 (r234386) @@ -522,17 +522,14 @@ restart: FSMAXSNAP + 1 /* superblock */ + 1 /* last block */ + 1 /* size */; MNT_ILOCK(mp); mp->mnt_kern_flag &= ~MNTK_SUSPENDED; + MNT_IUNLOCK(mp); loop: - MNT_VNODE_FOREACH(xvp, mp, mvp) { - VI_LOCK(xvp); - MNT_IUNLOCK(mp); - if ((xvp->v_iflag & VI_DOOMED) || - (xvp->v_usecount == 0 && + MNT_VNODE_FOREACH_ALL(xvp, mp, mvp) { + if ((xvp->v_usecount == 0 && (xvp->v_iflag & (VI_OWEINACT | VI_DOINGINACT)) == 0) || xvp->v_type == VNON || IS_SNAPSHOT(VTOI(xvp))) { VI_UNLOCK(xvp); - MNT_ILOCK(mp); continue; } /* @@ -541,13 +538,11 @@ loop: */ if (xvp == nd.ni_dvp) { VI_UNLOCK(xvp); - MNT_ILOCK(mp); continue; } vholdl(xvp); if (vn_lock(xvp, LK_EXCLUSIVE | LK_INTERLOCK) != 0) { - MNT_ILOCK(mp); - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); vdrop(xvp); goto loop; } @@ -557,7 +552,6 @@ loop: VI_UNLOCK(xvp); VOP_UNLOCK(xvp, 0); vdrop(xvp); - MNT_ILOCK(mp); continue; } VI_UNLOCK(xvp); @@ -567,14 +561,12 @@ loop: vat.va_nlink > 0) { VOP_UNLOCK(xvp, 0); vdrop(xvp); - MNT_ILOCK(mp); continue; } xp = VTOI(xvp); if (ffs_checkfreefile(copy_fs, vp, xp->i_number)) { VOP_UNLOCK(xvp, 0); vdrop(xvp); - MNT_ILOCK(mp); continue; } /* @@ -610,12 +602,10 @@ loop: free(copy_fs->fs_csp, M_UFSMNT); free(copy_fs, M_UFSMNT); copy_fs = NULL; - MNT_VNODE_FOREACH_ABORT(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto out1; } - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); /* * Erase the journal file from the snapshot. */ @@ -2532,31 +2522,26 @@ process_deferred_inactive(struct mount * td = curthread; (void) vn_start_secondary_write(NULL, &mp, V_WAIT); - MNT_ILOCK(mp); loop: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { /* * IN_LAZYACCESS is checked here without holding any * vnode lock, but this flag is set only while holding * vnode interlock. */ - if (vp->v_type == VNON || (vp->v_iflag & VI_DOOMED) != 0 || + if (vp->v_type == VNON || ((VTOI(vp)->i_flag & IN_LAZYACCESS) == 0 && - ((vp->v_iflag & VI_OWEINACT) == 0 || - vp->v_usecount > 0))) { + ((vp->v_iflag & VI_OWEINACT) == 0 || vp->v_usecount > 0))) { VI_UNLOCK(vp); continue; } - MNT_IUNLOCK(mp); vholdl(vp); error = vn_lock(vp, LK_EXCLUSIVE | LK_INTERLOCK); if (error != 0) { vdrop(vp); - MNT_ILOCK(mp); if (error == ENOENT) continue; /* vnode recycled */ - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } ip = VTOI(vp); @@ -2569,7 +2554,6 @@ process_deferred_inactive(struct mount * VI_UNLOCK(vp); VOP_UNLOCK(vp, 0); vdrop(vp); - MNT_ILOCK(mp); continue; } vinactive(vp, td); @@ -2578,9 +2562,7 @@ process_deferred_inactive(struct mount * VI_UNLOCK(vp); VOP_UNLOCK(vp, 0); vdrop(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); vn_finished_secondary_write(mp); } Modified: head/sys/ufs/ffs/ffs_softdep.c ============================================================================== --- head/sys/ufs/ffs/ffs_softdep.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/ufs/ffs/ffs_softdep.c Tue Apr 17 16:28:22 2012 (r234386) @@ -12642,29 +12642,21 @@ retry: fs->fs_cstotal.cs_nbfree <= needed) || (resource == FLUSH_INODES_WAIT && fs->fs_pendinginodes > 0 && fs->fs_cstotal.cs_nifree <= needed)) { - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(lvp, mp, mvp) { - VI_LOCK(lvp); + MNT_VNODE_FOREACH_ALL(lvp, mp, mvp) { if (TAILQ_FIRST(&lvp->v_bufobj.bo_dirty.bv_hd) == 0) { VI_UNLOCK(lvp); continue; } - MNT_IUNLOCK(mp); if (vget(lvp, LK_EXCLUSIVE | LK_INTERLOCK | LK_NOWAIT, - curthread)) { - MNT_ILOCK(mp); + curthread)) continue; - } if (lvp->v_vflag & VV_NOSYNC) { /* unlinked */ vput(lvp); - MNT_ILOCK(mp); continue; } (void) ffs_syncvnode(lvp, MNT_NOWAIT, 0); vput(lvp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); lvp = ump->um_devvp; if (vn_lock(lvp, LK_EXCLUSIVE | LK_NOWAIT) == 0) { VOP_FSYNC(lvp, MNT_NOWAIT, curthread); Modified: head/sys/ufs/ffs/ffs_vfsops.c ============================================================================== --- head/sys/ufs/ffs/ffs_vfsops.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/ufs/ffs/ffs_vfsops.c Tue Apr 17 16:28:22 2012 (r234386) @@ -705,19 +705,12 @@ ffs_reload(struct mount *mp, struct thre } loop: - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - if (vp->v_iflag & VI_DOOMED) { - VI_UNLOCK(vp); - continue; - } - MNT_IUNLOCK(mp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { /* * Step 4: invalidate all cached file data. */ if (vget(vp, LK_EXCLUSIVE | LK_INTERLOCK, td)) { - MNT_VNODE_FOREACH_ABORT(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } if (vinvalbuf(vp, 0, 0, 0)) @@ -732,7 +725,7 @@ loop: if (error) { VOP_UNLOCK(vp, 0); vrele(vp); - MNT_VNODE_FOREACH_ABORT(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); return (error); } ffs_load_inode(bp, ip, fs, ip->i_number); @@ -740,9 +733,7 @@ loop: brelse(bp); VOP_UNLOCK(vp, 0); vrele(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); return (0); } @@ -1441,10 +1432,8 @@ ffs_sync_lazy(mp) td = curthread; if ((mp->mnt_flag & MNT_NOATIME) != 0) goto qupdate; - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - if (vp->v_iflag & VI_DOOMED || vp->v_type == VNON) { + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { + if (vp->v_type == VNON) { VI_UNLOCK(vp); continue; } @@ -1462,19 +1451,14 @@ ffs_sync_lazy(mp) VI_UNLOCK(vp); continue; } - MNT_IUNLOCK(mp); if ((error = vget(vp, LK_EXCLUSIVE | LK_NOWAIT | LK_INTERLOCK, - td)) != 0) { - MNT_ILOCK(mp); + td)) != 0) continue; - } error = ffs_update(vp, 0); if (error != 0) allerror = error; vput(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); qupdate: #ifdef QUOTA @@ -1538,41 +1522,37 @@ ffs_sync(mp, waitfor) lockreq = LK_EXCLUSIVE; } lockreq |= LK_INTERLOCK | LK_SLEEPFAIL; - MNT_ILOCK(mp); loop: /* Grab snapshot of secondary write counts */ + MNT_ILOCK(mp); secondary_writes = mp->mnt_secondary_writes; secondary_accwrites = mp->mnt_secondary_accwrites; + MNT_IUNLOCK(mp); /* Grab snapshot of softdep dependency counts */ - MNT_IUNLOCK(mp); softdep_get_depcounts(mp, &softdep_deps, &softdep_accdeps); - MNT_ILOCK(mp); - MNT_VNODE_FOREACH(vp, mp, mvp) { + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { /* * Depend on the vnode interlock to keep things stable enough * for a quick test. Since there might be hundreds of * thousands of vnodes, we cannot afford even a subroutine * call unless there's a good chance that we have work to do. */ - VI_LOCK(vp); - if (vp->v_iflag & VI_DOOMED) { + if (vp->v_type == VNON) { VI_UNLOCK(vp); continue; } ip = VTOI(vp); - if (vp->v_type == VNON || ((ip->i_flag & + if ((ip->i_flag & (IN_ACCESS | IN_CHANGE | IN_MODIFIED | IN_UPDATE)) == 0 && - vp->v_bufobj.bo_dirty.bv_cnt == 0)) { + vp->v_bufobj.bo_dirty.bv_cnt == 0) { VI_UNLOCK(vp); continue; } - MNT_IUNLOCK(mp); if ((error = vget(vp, lockreq, td)) != 0) { - MNT_ILOCK(mp); if (error == ENOENT || error == ENOLCK) { - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto loop; } continue; @@ -1580,9 +1560,7 @@ loop: if ((error = ffs_syncvnode(vp, waitfor, 0)) != 0) allerror = error; vput(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); /* * Force stale filesystem control information to be flushed. */ @@ -1590,10 +1568,8 @@ loop: if ((error = softdep_flushworklist(ump->um_mountp, &count, td))) allerror = error; /* Flushed work items may create new vnodes to clean */ - if (allerror == 0 && count) { - MNT_ILOCK(mp); + if (allerror == 0 && count) goto loop; - } } #ifdef QUOTA qsync(mp); @@ -1608,18 +1584,18 @@ loop: if ((error = VOP_FSYNC(devvp, waitfor, td)) != 0) allerror = error; VOP_UNLOCK(devvp, 0); - if (allerror == 0 && waitfor == MNT_WAIT) { - MNT_ILOCK(mp); + if (allerror == 0 && waitfor == MNT_WAIT) goto loop; - } } else if (suspend != 0) { if (softdep_check_suspend(mp, devvp, softdep_deps, softdep_accdeps, secondary_writes, - secondary_accwrites) != 0) + secondary_accwrites) != 0) { + MNT_IUNLOCK(mp); goto loop; /* More work needed */ + } mtx_assert(MNT_MTX(mp), MA_OWNED); mp->mnt_kern_flag |= MNTK_SUSPEND2 | MNTK_SUSPENDED; MNT_IUNLOCK(mp); Modified: head/sys/ufs/ufs/ufs_quota.c ============================================================================== --- head/sys/ufs/ufs/ufs_quota.c Tue Apr 17 14:54:00 2012 (r234385) +++ head/sys/ufs/ufs/ufs_quota.c Tue Apr 17 16:28:22 2012 (r234386) @@ -598,32 +598,25 @@ quotaon(struct thread *td, struct mount * adding references to quota file being opened. * NB: only need to add dquot's for inodes being modified. */ - MNT_ILOCK(mp); again: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - MNT_IUNLOCK(mp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { if (vget(vp, LK_EXCLUSIVE | LK_INTERLOCK, td)) { - MNT_ILOCK(mp); - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto again; } if (vp->v_type == VNON || vp->v_writecount == 0) { VOP_UNLOCK(vp, 0); vrele(vp); - MNT_ILOCK(mp); continue; } error = getinoquota(VTOI(vp)); VOP_UNLOCK(vp, 0); vrele(vp); - MNT_ILOCK(mp); if (error) { - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); break; } } - MNT_IUNLOCK(mp); if (error) quotaoff_inchange(td, mp, type); @@ -669,19 +662,14 @@ quotaoff1(struct thread *td, struct moun * Search vnodes associated with this mount point, * deleting any references to quota file being closed. */ - MNT_ILOCK(mp); again: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); - MNT_IUNLOCK(mp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { if (vp->v_type == VNON) { VI_UNLOCK(vp); - MNT_ILOCK(mp); continue; } if (vget(vp, LK_EXCLUSIVE | LK_INTERLOCK, td)) { - MNT_ILOCK(mp); - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto again; } ip = VTOI(vp); @@ -690,9 +678,7 @@ again: dqrele(vp, dq); VOP_UNLOCK(vp, 0); vrele(vp); - MNT_ILOCK(mp); } - MNT_IUNLOCK(mp); dqflush(qvp); /* Clear um_quotas before closing the quota vnode to prevent @@ -1057,20 +1043,16 @@ qsync(struct mount *mp) * Search vnodes associated with this mount point, * synchronizing any modified dquot structures. */ - MNT_ILOCK(mp); again: - MNT_VNODE_FOREACH(vp, mp, mvp) { - VI_LOCK(vp); + MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { if (vp->v_type == VNON) { VI_UNLOCK(vp); continue; } - MNT_IUNLOCK(mp); error = vget(vp, LK_EXCLUSIVE | LK_INTERLOCK, td); if (error) { - MNT_ILOCK(mp); if (error == ENOENT) { - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); + MNT_VNODE_FOREACH_ALL_ABORT(mp, mvp); goto again; } continue; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 18:05:09 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 95AA71065708; Tue, 17 Apr 2012 18:05:09 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 101438FC19; Tue, 17 Apr 2012 18:05:09 +0000 (UTC) Received: by pbcwz17 with SMTP id wz17so8403535pbc.13 for ; Tue, 17 Apr 2012 11:05:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=dGY8QDnze1bOMue+x9lApVac6lDdN4WH1pSF2yXgfoA=; b=gJL01PIiNIOQGIrNW8r/xul8lmI4oIxVwHiNHaVTD0hpSYgJ6h8HgWGshMLz/ZLFnh +gmS49xBs5l/RPiIih0Dm3qdd+PGeGn+tcbldGkVHLhPii9yAWzGJE6eMlSIncoGX9Q5 TwGdzLGQgg27lQRtsB2SdHy0H5M80f6x54TOlp2FhFlIVnwBG+MEFHISKH8Q45kZMq8H 1wZPkxF9+r7DElhVE00dpptuzVu1Bv1DZom0SLd5JW5avUMGEPu/Gniddlu3WpRErK1A qRDskJZfykSKR79qMMMiq5QgkW+r345z52/pRZqfHYQqcCO0DfzSO/aQySAp37zKDe54 /uvw== MIME-Version: 1.0 Received: by 10.68.225.132 with SMTP id rk4mr36841844pbc.157.1334685908858; Tue, 17 Apr 2012 11:05:08 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.142.101.9 with HTTP; Tue, 17 Apr 2012 11:05:08 -0700 (PDT) In-Reply-To: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> Date: Tue, 17 Apr 2012 11:05:08 -0700 X-Google-Sender-Auth: 17WB5I7ri3NqEBnm5FbDl9Mp7Lg Message-ID: From: Adrian Chadd To: "Bjoern A. Zeeb" Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Jason Evans Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 18:05:09 -0000 On 17 April 2012 02:43, Bjoern A. Zeeb wrote: > Actually it seems these failed: > > arm.armeb buildworld failed, check _.arm.armeb.buildworld for details > arm.arm buildworld failed, check _.arm.arm.buildworld for details > mips.mips64 buildworld failed, check _.mips.mips64.buildworld for details > mips.mipsel buildworld failed, check _.mips.mipsel.buildworld for details > mips.mips64el buildworld failed, check _.mips.mips64el.buildworld for details > mips.mipsn32 buildworld failed, check _.mips.mipsn32.buildworld for details > mips.mips buildworld failed, check _.mips.mips.buildworld for details > i386.i386 buildworld failed, check _.i386.i386.buildworld for details > pc98.i386 buildworld failed, check _.pc98.i386.buildworld for details > powerpc.powerpc buildworld failed, check _.powerpc.powerpc.buildworld for details > powerpc.powerpc64 buildworld failed, check _.powerpc.powerpc64.buildworld for details This looks like it only works on amd64 and sparc64. Lucky them. :) Adrian From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 18:58:43 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B1DED106564A; Tue, 17 Apr 2012 18:58:43 +0000 (UTC) (envelope-from jasone@canonware.com) Received: from canonware.com (10140.x.rootbsd.net [204.109.63.53]) by mx1.freebsd.org (Postfix) with ESMTP id 8686B8FC0C; Tue, 17 Apr 2012 18:58:43 +0000 (UTC) Received: from [172.25.16.174] (unknown [173.252.71.3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by canonware.com (Postfix) with ESMTPSA id 79B0528417; Tue, 17 Apr 2012 11:58:42 -0700 (PDT) Mime-Version: 1.0 (Apple Message framework v1257) Content-Type: text/plain; charset=iso-8859-1 From: Jason Evans In-Reply-To: Date: Tue, 17 Apr 2012 11:58:41 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <99DAC0D4-CF0F-4277-8C44-C6890EBCFB45@canonware.com> References: <201204170722.q3H7ME6A070934@svn.freebsd.org> To: Adrian Chadd X-Mailer: Apple Mail (2.1257) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, "Bjoern A. Zeeb" , src-committers@freebsd.org, Jason Evans Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 18:58:43 -0000 On Apr 17, 2012, at 11:05 AM, Adrian Chadd wrote: > On 17 April 2012 02:43, Bjoern A. Zeeb wrote: >=20 >> Actually it seems these failed: >>=20 >> arm.armeb buildworld failed, check _.arm.armeb.buildworld for details >> arm.arm buildworld failed, check _.arm.arm.buildworld for details >> mips.mips64 buildworld failed, check _.mips.mips64.buildworld for = details >> mips.mipsel buildworld failed, check _.mips.mipsel.buildworld for = details >> mips.mips64el buildworld failed, check _.mips.mips64el.buildworld for = details >> mips.mipsn32 buildworld failed, check _.mips.mipsn32.buildworld for = details >> mips.mips buildworld failed, check _.mips.mips.buildworld for details >> i386.i386 buildworld failed, check _.i386.i386.buildworld for details >> pc98.i386 buildworld failed, check _.pc98.i386.buildworld for details >> powerpc.powerpc buildworld failed, check _.powerpc.powerpc.buildworld = for details >> powerpc.powerpc64 buildworld failed, check = _.powerpc.powerpc64.buildworld for details >=20 > This looks like it only works on amd64 and sparc64. Lucky them. :) It could have been worse; I only tested on amd64. ;-) Seriously though, I should be able to get this straightened out today. Jason= From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 19:04:54 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AF7C81065687; Tue, 17 Apr 2012 19:04:54 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-pz0-f44.google.com (mail-pz0-f44.google.com [209.85.210.44]) by mx1.freebsd.org (Postfix) with ESMTP id 637878FC22; Tue, 17 Apr 2012 19:04:54 +0000 (UTC) Received: by dadz14 with SMTP id z14so28901533dad.17 for ; Tue, 17 Apr 2012 12:04:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=eZaSLO0Ev7aeUsXTzKn6ZKY7XeXguuxONOHApl9bViY=; b=MvR+Q08lpRTaDGZ6nvHvVdbcSQ+buzj3f8TYXs91oOTKFdSolNfDfAbOuMeSW32tkF Gi1KNyXTEYwGRqrnjo8lElsOen68wObo7nm355PYZeTwaPndbGY9+OMTWiRRL9hywhoh sI0ystGmdAayvoJcj8aTMSyMu+IwzZpEWQTv6ThFODt3FI2j5m0LlGkI+M0Fe9Jbsf0g LMs54WqkK5XAHjI0izu47TL1Llz7NsIEMHljElrrK6aqUKhJr0PztGYf5XnAW94VyKkR bH2iTGO7iP4O8EaFJTvtxHsjADfv1EJoXmXnf1/dQm7LuHeJh+gvYhxWrbXw8QOHtmLA bOkQ== MIME-Version: 1.0 Received: by 10.68.236.101 with SMTP id ut5mr2102938pbc.85.1334689494156; Tue, 17 Apr 2012 12:04:54 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.142.101.9 with HTTP; Tue, 17 Apr 2012 12:04:54 -0700 (PDT) In-Reply-To: <99DAC0D4-CF0F-4277-8C44-C6890EBCFB45@canonware.com> References: <201204170722.q3H7ME6A070934@svn.freebsd.org> <99DAC0D4-CF0F-4277-8C44-C6890EBCFB45@canonware.com> Date: Tue, 17 Apr 2012 12:04:54 -0700 X-Google-Sender-Auth: Mtj1ea1oyX-ckWUgVVWlr2PkjZA Message-ID: From: Adrian Chadd To: Jason Evans Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, "Bjoern A. Zeeb" , src-committers@freebsd.org, Jason Evans Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 19:04:54 -0000 I can ship you some mips hardware if you'd like. :-) Adrian From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 19:55:32 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 795BF106564A; Tue, 17 Apr 2012 19:55:32 +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 5A4748FC0C; Tue, 17 Apr 2012 19:55:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HJtWKU096658; Tue, 17 Apr 2012 19:55:32 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HJtWc5096653; Tue, 17 Apr 2012 19:55:32 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201204171955.q3HJtWc5096653@svn.freebsd.org> From: John Baldwin Date: Tue, 17 Apr 2012 19:55:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234391 - in stable/9/sys: amd64/amd64 amd64/include i386/conf i386/i386 i386/include kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 19:55:32 -0000 Author: jhb Date: Tue Apr 17 19:55:31 2012 New Revision: 234391 URL: http://svn.freebsd.org/changeset/base/234391 Log: MFC 234059: Recognize the RDRAND instruction feature. Modified: stable/9/sys/amd64/amd64/identcpu.c stable/9/sys/amd64/include/specialreg.h stable/9/sys/i386/i386/identcpu.c stable/9/sys/i386/include/specialreg.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/amd64/amd64/identcpu.c ============================================================================== --- stable/9/sys/amd64/amd64/identcpu.c Tue Apr 17 19:42:55 2012 (r234390) +++ stable/9/sys/amd64/amd64/identcpu.c Tue Apr 17 19:55:31 2012 (r234391) @@ -303,7 +303,7 @@ printcpuinfo(void) "\034OSXSAVE" /* OS-Enabled State Management*/ "\035AVX" /* Advanced Vector Extensions */ "\036F16C" /* Half-precision conversions */ - "\037" + "\037RDRAND" /* RDRAND Instruction */ "\040HV" /* Hypervisor */ ); } Modified: stable/9/sys/amd64/include/specialreg.h ============================================================================== --- stable/9/sys/amd64/include/specialreg.h Tue Apr 17 19:42:55 2012 (r234390) +++ stable/9/sys/amd64/include/specialreg.h Tue Apr 17 19:55:31 2012 (r234391) @@ -153,6 +153,7 @@ #define CPUID2_OSXSAVE 0x08000000 #define CPUID2_AVX 0x10000000 #define CPUID2_F16C 0x20000000 +#define CPUID2_RDRAND 0x40000000 #define CPUID2_HV 0x80000000 /* Modified: stable/9/sys/i386/i386/identcpu.c ============================================================================== --- stable/9/sys/i386/i386/identcpu.c Tue Apr 17 19:42:55 2012 (r234390) +++ stable/9/sys/i386/i386/identcpu.c Tue Apr 17 19:55:31 2012 (r234391) @@ -779,7 +779,7 @@ printcpuinfo(void) "\034OSXSAVE" /* OS-Enabled State Management*/ "\035AVX" /* Advanced Vector Extensions */ "\036F16C" /* Half-precision conversions */ - "\037" + "\037RDRAND" /* RDRAND Instruction */ "\040HV" /* Hypervisor */ ); } Modified: stable/9/sys/i386/include/specialreg.h ============================================================================== --- stable/9/sys/i386/include/specialreg.h Tue Apr 17 19:42:55 2012 (r234390) +++ stable/9/sys/i386/include/specialreg.h Tue Apr 17 19:55:31 2012 (r234391) @@ -138,6 +138,7 @@ #define CPUID2_OSXSAVE 0x08000000 #define CPUID2_AVX 0x10000000 #define CPUID2_F16C 0x20000000 +#define CPUID2_RDRAND 0x40000000 #define CPUID2_HV 0x80000000 /* From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 19:55:56 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 38AF71065688; Tue, 17 Apr 2012 19:55: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 08A128FC15; Tue, 17 Apr 2012 19:55:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HJttqD096707; Tue, 17 Apr 2012 19:55:55 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HJtt1b096702; Tue, 17 Apr 2012 19:55:55 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201204171955.q3HJtt1b096702@svn.freebsd.org> From: John Baldwin Date: Tue, 17 Apr 2012 19:55:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234392 - in stable/8/sys: amd64/amd64 amd64/include i386/conf i386/i386 i386/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 19:55:56 -0000 Author: jhb Date: Tue Apr 17 19:55:55 2012 New Revision: 234392 URL: http://svn.freebsd.org/changeset/base/234392 Log: MFC 234059: Recognize the RDRAND instruction feature. Modified: stable/8/sys/amd64/amd64/identcpu.c stable/8/sys/amd64/include/specialreg.h stable/8/sys/i386/i386/identcpu.c stable/8/sys/i386/include/specialreg.h Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/e1000/ (props changed) stable/8/sys/i386/conf/XENHVM (props changed) Modified: stable/8/sys/amd64/amd64/identcpu.c ============================================================================== --- stable/8/sys/amd64/amd64/identcpu.c Tue Apr 17 19:55:31 2012 (r234391) +++ stable/8/sys/amd64/amd64/identcpu.c Tue Apr 17 19:55:55 2012 (r234392) @@ -299,7 +299,7 @@ printcpuinfo(void) "\034OSXSAVE" /* OS-Enabled State Management*/ "\035AVX" /* Advanced Vector Extensions */ "\036F16C" /* Half-precision conversions */ - "\037" + "\037RDRAND" /* RDRAND Instruction */ "\040HV" /* Hypervisor */ ); } Modified: stable/8/sys/amd64/include/specialreg.h ============================================================================== --- stable/8/sys/amd64/include/specialreg.h Tue Apr 17 19:55:31 2012 (r234391) +++ stable/8/sys/amd64/include/specialreg.h Tue Apr 17 19:55:55 2012 (r234392) @@ -140,6 +140,7 @@ #define CPUID2_OSXSAVE 0x08000000 #define CPUID2_AVX 0x10000000 #define CPUID2_F16C 0x20000000 +#define CPUID2_RDRAND 0x40000000 #define CPUID2_HV 0x80000000 /* Modified: stable/8/sys/i386/i386/identcpu.c ============================================================================== --- stable/8/sys/i386/i386/identcpu.c Tue Apr 17 19:55:31 2012 (r234391) +++ stable/8/sys/i386/i386/identcpu.c Tue Apr 17 19:55:55 2012 (r234392) @@ -762,7 +762,7 @@ printcpuinfo(void) "\034OSXSAVE" /* OS-Enabled State Management*/ "\035AVX" /* Advanced Vector Extensions */ "\036F16C" /* Half-precision conversions */ - "\037" + "\037RDRAND" /* RDRAND Instruction */ "\040HV" /* Hypervisor */ ); } Modified: stable/8/sys/i386/include/specialreg.h ============================================================================== --- stable/8/sys/i386/include/specialreg.h Tue Apr 17 19:55:31 2012 (r234391) +++ stable/8/sys/i386/include/specialreg.h Tue Apr 17 19:55:55 2012 (r234392) @@ -137,6 +137,7 @@ #define CPUID2_OSXSAVE 0x08000000 #define CPUID2_AVX 0x10000000 #define CPUID2_F16C 0x20000000 +#define CPUID2_RDRAND 0x40000000 #define CPUID2_HV 0x80000000 /* From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 20:21:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EEB731065673; Tue, 17 Apr 2012 20:21:04 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DA85C8FC1A; Tue, 17 Apr 2012 20:21:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HKL4kS097660; Tue, 17 Apr 2012 20:21:04 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HKL4o9097658; Tue, 17 Apr 2012 20:21:04 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201204172021.q3HKL4o9097658@svn.freebsd.org> From: Jason Evans Date: Tue, 17 Apr 2012 20:21: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: r234395 - head X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 20:21:05 -0000 Author: jasone Date: Tue Apr 17 20:21:04 2012 New Revision: 234395 URL: http://svn.freebsd.org/changeset/base/234395 Log: Add an UPDATING entry for the contrib/jemalloc import. Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Tue Apr 17 20:16:49 2012 (r234394) +++ head/UPDATING Tue Apr 17 20:21:04 2012 (r234395) @@ -22,6 +22,15 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10 machines to maximize performance. (To disable malloc debugging, run ln -s aj /etc/malloc.conf.) +20120417: + The malloc(3) implementation embedded in libc now uses sources imported + as contrib/jemalloc. The most disruptive API change is to + /etc/malloc.conf. If your system has an old-style /etc/malloc.conf, + delete it prior to installworld, and optionally re-create it using the + new format after rebooting. See malloc.conf(5) for details + (specifically the TUNING section and the "opt.*" entries in the MALLCTL + NAMESPACE section). + 20120328: Big-endian MIPS TARGET_ARCH values no longer end in "eb". mips64eb is now spelled mips64. mipsn32eb is now spelled mipsn32. mipseb is From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 20:24:19 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 455AC106566B; Tue, 17 Apr 2012 20:24:19 +0000 (UTC) (envelope-from lists@jnielsen.net) Received: from ns1.jnielsen.net (secure.freebsdsolutions.net [69.55.234.48]) by mx1.freebsd.org (Postfix) with ESMTP id 0B0D48FC24; Tue, 17 Apr 2012 20:24:19 +0000 (UTC) Received: from jnielsen.socialserve.com ([12.249.176.26]) (authenticated bits=0) by ns1.jnielsen.net (8.14.4/8.14.4) with ESMTP id q3HKOFbR067132 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NOT); Tue, 17 Apr 2012 16:24:16 -0400 (EDT) (envelope-from lists@jnielsen.net) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: John Nielsen In-Reply-To: <201204172021.q3HKL4o9097658@svn.freebsd.org> Date: Tue, 17 Apr 2012 16:24:12 -0400 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201204172021.q3HKL4o9097658@svn.freebsd.org> To: Jason Evans X-Mailer: Apple Mail (2.1084) X-DCC-x.dcc-servers-Metrics: ns1.jnielsen.net 104; Body=4 Fuz1=4 Fuz2=4 X-Virus-Scanned: clamav-milter 0.97.2 at ns1.jnielsen.net X-Virus-Status: Clean Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234395 - head X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 20:24:19 -0000 On Apr 17, 2012, at 4:21 PM, Jason Evans wrote: > Author: jasone > Date: Tue Apr 17 20:21:04 2012 > New Revision: 234395 > URL: http://svn.freebsd.org/changeset/base/234395 >=20 > Log: > Add an UPDATING entry for the contrib/jemalloc import. >=20 > Modified: > head/UPDATING >=20 > Modified: head/UPDATING > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=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/UPDATING Tue Apr 17 20:16:49 2012 (r234394) > +++ head/UPDATING Tue Apr 17 20:21:04 2012 (r234395) > @@ -22,6 +22,15 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10 > machines to maximize performance. (To disable malloc debugging, = run > ln -s aj /etc/malloc.conf.) Thanks! Note also the above (which I wouldn't have thought of if it = hadn't been in this diff). Want to omit or modify the malloc.conf advice = at the top of the file? > +20120417: > + The malloc(3) implementation embedded in libc now uses sources = imported > + as contrib/jemalloc. The most disruptive API change is to > + /etc/malloc.conf. If your system has an old-style = /etc/malloc.conf, > + delete it prior to installworld, and optionally re-create it = using the > + new format after rebooting. See malloc.conf(5) for details > + (specifically the TUNING section and the "opt.*" entries in the = MALLCTL > + NAMESPACE section). > + > 20120328: > Big-endian MIPS TARGET_ARCH values no longer end in "eb". = mips64eb > is now spelled mips64. mipsn32eb is now spelled mipsn32. = mipseb is > _______________________________________________ > svn-src-head@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/svn-src-head > To unsubscribe, send any mail to = "svn-src-head-unsubscribe@freebsd.org" >=20 From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 20:24:42 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D7A2B1065674; Tue, 17 Apr 2012 20:24:42 +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 8E9948FC18; Tue, 17 Apr 2012 20:24:42 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:920:4d88:e4b9:4d05] (unknown [IPv6:2001:7b8:3a7:0:920:4d88:e4b9:4d05]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id CB1F75C37; Tue, 17 Apr 2012 22:24:41 +0200 (CEST) Message-ID: <4F8DD186.6060306@FreeBSD.org> Date: Tue, 17 Apr 2012 22:24:38 +0200 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20120410 Thunderbird/12.0 MIME-Version: 1.0 To: John Baldwin References: <201203301257.q2UCvE4l042042@svn.freebsd.org> <20120330133045.GD1423@mole.fafoe.narf.at> <4F760E5F.5030300@FreeBSD.org> <201204020752.52596.jhb@freebsd.org> In-Reply-To: <201204020752.52596.jhb@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, Scott Long , Stefan Farfeleder , David Xu , svn-src-head@freebsd.org Subject: Re: svn commit: r233700 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 20:24:43 -0000 On 2012-04-02 13:52, John Baldwin wrote: ... >> It seems the for loop walks the list until the end, then tacks 'sc' onto >> it. >> >> So to 'fix' the warning, and make the meaning more explicit, we should >> probably rewrite that fragment as: >> >> LIST_INIT(&(sc->ha_ccb)); >> /* Link us into the HA list */ >> for (ha =&Asr_softc_list; *ha; ha =&((*ha)->ha_next)) >> ; >> *(ha) = sc; >> >> Is this OK? > > Can we just make that code use a STAILQ() instead of doing it obscurely by > hand? That would be a more invasive change, and since this driver is essentially unmaintained, I'd like to change as little as possible. :) Another solution is to just silence the warning for this driver. From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 20:25:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 40672106566C; Tue, 17 Apr 2012 20:25:04 +0000 (UTC) (envelope-from fidaj@ukr.net) Received: from fsm1.ukr.net (fsm1.ukr.net [195.214.192.120]) by mx1.freebsd.org (Postfix) with ESMTP id DBD2E8FC0C; Tue, 17 Apr 2012 20:25:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=ukr.net; s=fsm; h=Content-Transfer-Encoding:Content-Type:Mime-Version:References:In-Reply-To:Message-ID:Subject:Cc:To:From:Date; bh=TanKpKNmyT7XejX9ORMzf85bo/R9L89TvwX8ff/GQ2k=; b=nvj4kZ9/WniZFY2Ja6Ni4djkK6bQi3H/i+iexHDxUa48RwBoBvJ1MFL7Zy9QSWqb4fC2MKP8qZ9J90aMYvUS2M77oUV8KCSrjfOCJv8kBQWiNh6Vc3U2RUkWKP7IO9KswcLpCNo5GbT5cgix5ZTpR/3tan1/yH4Ejyamh+QOPqg=; Received: from [178.137.138.140] (helo=nonamehost.) by fsm1.ukr.net with esmtpsa ID 1SKExR-000OTu-Px ; Tue, 17 Apr 2012 23:25:02 +0300 Date: Tue, 17 Apr 2012 23:24:59 +0300 From: Ivan Klymenko To: Jason Evans Message-ID: <20120417232459.7d42ea4a@nonamehost.> In-Reply-To: <201204172021.q3HKL4o9097658@svn.freebsd.org> References: <201204172021.q3HKL4o9097658@svn.freebsd.org> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAFVBMVEWpqak/Pz/i4uIfHx8GBwZwcHAQEBA6o92AAAACHElEQVQ4jWWUTY7bMAyF6QzUPSEoa8PFHEBgqwuM4bVVg7MvZOj+R+ijpMTpjIwgkT7z75EKrdfattpXERG6zqvUOtAr2LCRYfEKcB4l/Q+2cc6XjQH7hv+2YZYreIk5nevZEPvuzUzptizHLzgDMnC5Wpbl7ewJlOEqlQF+DlCjgVLki0WV6FMDMsBxjlJiQulIznwZ+DxHiQyDyIg0wN3Oo6o6ZQ5s5AIfar+W2Wlmz+kCcb8tg6j3voMEwNrBQk69dDBDqw/urpqJH+m+Q6u/4QnoAeYpnUXC/s1iup9rhCd6xMgAqdDyAyFegbKkVAHeLCcOulPLawaoUIDos4M88iLNrVkU7uu5ccTDO6naJzWLum51C6Yb7y4HKKbdArLWir0PBiS8glJRBZHeyHl7J9lENpAC6qT9NlNG4u5hsVYDyJP6mlJJtY3oVju4WSUzHal1sDU17NASoBWSk40J2eBLBJhYrVmzC5gVALGpNIAiQgN6eGstOp9Oa6zFbbLTISYi28BGZDRUJKWeroECkCEkzXjUtbmmaKMfAx2RfbT69/cO+tgHcmx6AfyZOmj3NDIah0F0GB66d4CrdIoplNFFGHSpSheRxbo0W4S8azNItEoMWbw3uXAeJgCrmX5joz7CGXqSg6PcryEhnFr/C1C2ntPxBOYbdwY+8dO3+wZJyFlbMX9s8zNnvp/tLwAv03NB4j3HVpn8Awwm+GrlP6MVAAAAAElFTkSuQmCC Mime-Version: 1.0 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: r234395 - head X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 20:25:04 -0000 =D0=92 Tue, 17 Apr 2012 20:21:04 +0000 (UTC) Jason Evans =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > Author: jasone > Date: Tue Apr 17 20:21:04 2012 > New Revision: 234395 > URL: http://svn.freebsd.org/changeset/base/234395 >=20 > Log: > Add an UPDATING entry for the contrib/jemalloc import. >=20 > Modified: > head/UPDATING >=20 > Modified: head/UPDATING > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=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/UPDATING Tue Apr 17 20:16:49 2012 (r234394) > +++ head/UPDATING Tue Apr 17 20:21:04 2012 (r234395) > @@ -22,6 +22,15 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10 > machines to maximize performance. (To disable malloc > debugging, run ln -s aj /etc/malloc.conf.) > =20 > +20120417: > + The malloc(3) implementation embedded in libc now uses > sources imported > + as contrib/jemalloc. The most disruptive API change is to > + /etc/malloc.conf. If your system has an > old-style /etc/malloc.conf, > + delete it prior to installworld, and optionally re-create it > using the > + new format after rebooting. See malloc.conf(5) for details > + (specifically the TUNING section and the "opt.*" entries in > the MALLCTL > + NAMESPACE section). > + > 20120328: > Big-endian MIPS TARGET_ARCH values no longer end in "eb". > mips64eb is now spelled mips64. mipsn32eb is now spelled mipsn32. > mipseb is _______________________________________________ > svn-src-all@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" >=20 >=20 That this line is also not true "(To disable malloc debugging, run ln -s aj /etc/malloc.conf.)" ? From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 20:35:54 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E6A6D1065673; Tue, 17 Apr 2012 20:35:54 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D2D528FC1F; Tue, 17 Apr 2012 20:35:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HKZshm098142; Tue, 17 Apr 2012 20:35:54 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HKZsVT098140; Tue, 17 Apr 2012 20:35:54 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201204172035.q3HKZsVT098140@svn.freebsd.org> From: Jason Evans Date: Tue, 17 Apr 2012 20:35: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: r234396 - head X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 20:35:55 -0000 Author: jasone Date: Tue Apr 17 20:35:54 2012 New Revision: 234396 URL: http://svn.freebsd.org/changeset/base/234396 Log: Update directions on how to disable malloc debugging. Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Tue Apr 17 20:21:04 2012 (r234395) +++ head/UPDATING Tue Apr 17 20:35:54 2012 (r234396) @@ -19,8 +19,10 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10 includes various WITNESS- related kernel options, INVARIANTS, malloc debugging flags in userland, and various verbose features in the kernel. Many developers choose to disable these features on build - machines to maximize performance. (To disable malloc debugging, run - ln -s aj /etc/malloc.conf.) + machines to maximize performance. (To completely disable malloc + debugging, define MALLOC_PRODUCTION in /etc/make.conf, or to merely + disable the most expensive debugging functionality run + "ln -s 'abort:false,junk:false' /etc/malloc.conf".) 20120417: The malloc(3) implementation embedded in libc now uses sources imported From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 20:44:48 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 62C561065673; Tue, 17 Apr 2012 20:44:48 +0000 (UTC) (envelope-from fidaj@ukr.net) Received: from fsm1.ukr.net (fsm1.ukr.net [195.214.192.120]) by mx1.freebsd.org (Postfix) with ESMTP id 0A5778FC0A; Tue, 17 Apr 2012 20:44:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=ukr.net; s=fsm; h=Content-Transfer-Encoding:Content-Type:Mime-Version:References:In-Reply-To:Message-ID:Subject:Cc:To:From:Date; bh=eiBRnbi2cd8+3kq4rc7NKPMRun4XepDuir1OnxXUxr0=; b=t5q6JP4kVTpbBF7eKIKWYt3zrXJlzxKXCIEvHtm7WIpQl1Icl+Q4zAFzMx8AcUPsgr8MsRvWIqmZYJUapV+kVLGj85ZmhMXaro0/m2YX1WpMztUwin/6gfxe9MqMaXk+V8PAzEQY22bjs/UkYD9lY0Mj9APmAhr6DL/ls+0CN84=; Received: from [178.137.138.140] (helo=nonamehost.) by fsm1.ukr.net with esmtpsa ID 1SKFGZ-0002nw-39 ; Tue, 17 Apr 2012 23:44:47 +0300 Date: Tue, 17 Apr 2012 23:44:45 +0300 From: Ivan Klymenko To: Jason Evans Message-ID: <20120417234445.1f695681@nonamehost.> In-Reply-To: <201204172035.q3HKZsVT098140@svn.freebsd.org> References: <201204172035.q3HKZsVT098140@svn.freebsd.org> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAFVBMVEWpqak/Pz/i4uIfHx8GBwZwcHAQEBA6o92AAAACHElEQVQ4jWWUTY7bMAyF6QzUPSEoa8PFHEBgqwuM4bVVg7MvZOj+R+ijpMTpjIwgkT7z75EKrdfattpXERG6zqvUOtAr2LCRYfEKcB4l/Q+2cc6XjQH7hv+2YZYreIk5nevZEPvuzUzptizHLzgDMnC5Wpbl7ewJlOEqlQF+DlCjgVLki0WV6FMDMsBxjlJiQulIznwZ+DxHiQyDyIg0wN3Oo6o6ZQ5s5AIfar+W2Wlmz+kCcb8tg6j3voMEwNrBQk69dDBDqw/urpqJH+m+Q6u/4QnoAeYpnUXC/s1iup9rhCd6xMgAqdDyAyFegbKkVAHeLCcOulPLawaoUIDos4M88iLNrVkU7uu5ccTDO6naJzWLum51C6Yb7y4HKKbdArLWir0PBiS8glJRBZHeyHl7J9lENpAC6qT9NlNG4u5hsVYDyJP6mlJJtY3oVju4WSUzHal1sDU17NASoBWSk40J2eBLBJhYrVmzC5gVALGpNIAiQgN6eGstOp9Oa6zFbbLTISYi28BGZDRUJKWeroECkCEkzXjUtbmmaKMfAx2RfbT69/cO+tgHcmx6AfyZOmj3NDIah0F0GB66d4CrdIoplNFFGHSpSheRxbo0W4S8azNItEoMWbw3uXAeJgCrmX5joz7CGXqSg6PcryEhnFr/C1C2ntPxBOYbdwY+8dO3+wZJyFlbMX9s8zNnvp/tLwAv03NB4j3HVpn8Awwm+GrlP6MVAAAAAElFTkSuQmCC Mime-Version: 1.0 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: r234396 - head X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 20:44:48 -0000 =D0=92 Tue, 17 Apr 2012 20:35:54 +0000 (UTC) Jason Evans =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > Author: jasone > Date: Tue Apr 17 20:35:54 2012 > New Revision: 234396 > URL: http://svn.freebsd.org/changeset/base/234396 >=20 > Log: > Update directions on how to disable malloc debugging. >=20 > Modified: > head/UPDATING >=20 > Modified: head/UPDATING > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=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/UPDATING Tue Apr 17 20:21:04 2012 (r234395) > +++ head/UPDATING Tue Apr 17 20:35:54 2012 (r234396) > @@ -19,8 +19,10 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10 > includes various WITNESS- related kernel options, > INVARIANTS, malloc debugging flags in userland, and various verbose > features in the kernel. Many developers choose to disable these > features on build > - machines to maximize performance. (To disable malloc > debugging, run > - ln -s aj /etc/malloc.conf.) > + machines to maximize performance. (To completely disable > malloc > + debugging, define MALLOC_PRODUCTION in /etc/make.conf, or to > merely > + disable the most expensive debugging functionality run > + "ln -s 'abort:false,junk:false' /etc/malloc.conf".) > =20 > 20120417: > The malloc(3) implementation embedded in libc now uses > sources imported _______________________________________________ > svn-src-all@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" >=20 >=20 Thank you. From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 20:49:27 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EEBED106564A; Tue, 17 Apr 2012 20:49:27 +0000 (UTC) (envelope-from fidaj@ukr.net) Received: from fsm1.ukr.net (fsm1.ukr.net [195.214.192.120]) by mx1.freebsd.org (Postfix) with ESMTP id 961288FC0A; Tue, 17 Apr 2012 20:49:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=ukr.net; s=fsm; h=Content-Transfer-Encoding:Content-Type:Mime-Version:References:In-Reply-To:Message-ID:Subject:Cc:To:From:Date; bh=eEABlqcYUHr8I9xG6Yxf0AVUsSXl8aAI4+YgMVkWSnc=; b=N+elCqXBP6c4CXT3q0Sl1ZB95EP3Yct4sEfYVqSM8HRIYAjVG7KCj6svveJuj7zNEUhobkFMWqEJ4vwPyJjuirKSocHndFDMEFhntPMuVpXf8Jq3RDFfJJUkWqf22nTDupBsn6V57nycywb+8Gjto5dZ76h6fCoG1KJItk9+DZ8=; Received: from [178.137.138.140] (helo=nonamehost.) by fsm1.ukr.net with esmtpsa ID 1SKFL4-0003nv-NP ; Tue, 17 Apr 2012 23:49:26 +0300 Date: Tue, 17 Apr 2012 23:49:25 +0300 From: Ivan Klymenko To: Jason Evans Message-ID: <20120417234925.345c133e@nonamehost.> In-Reply-To: <201204172035.q3HKZsVT098140@svn.freebsd.org> References: <201204172035.q3HKZsVT098140@svn.freebsd.org> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAFVBMVEWpqak/Pz/i4uIfHx8GBwZwcHAQEBA6o92AAAACHElEQVQ4jWWUTY7bMAyF6QzUPSEoa8PFHEBgqwuM4bVVg7MvZOj+R+ijpMTpjIwgkT7z75EKrdfattpXERG6zqvUOtAr2LCRYfEKcB4l/Q+2cc6XjQH7hv+2YZYreIk5nevZEPvuzUzptizHLzgDMnC5Wpbl7ewJlOEqlQF+DlCjgVLki0WV6FMDMsBxjlJiQulIznwZ+DxHiQyDyIg0wN3Oo6o6ZQ5s5AIfar+W2Wlmz+kCcb8tg6j3voMEwNrBQk69dDBDqw/urpqJH+m+Q6u/4QnoAeYpnUXC/s1iup9rhCd6xMgAqdDyAyFegbKkVAHeLCcOulPLawaoUIDos4M88iLNrVkU7uu5ccTDO6naJzWLum51C6Yb7y4HKKbdArLWir0PBiS8glJRBZHeyHl7J9lENpAC6qT9NlNG4u5hsVYDyJP6mlJJtY3oVju4WSUzHal1sDU17NASoBWSk40J2eBLBJhYrVmzC5gVALGpNIAiQgN6eGstOp9Oa6zFbbLTISYi28BGZDRUJKWeroECkCEkzXjUtbmmaKMfAx2RfbT69/cO+tgHcmx6AfyZOmj3NDIah0F0GB66d4CrdIoplNFFGHSpSheRxbo0W4S8azNItEoMWbw3uXAeJgCrmX5joz7CGXqSg6PcryEhnFr/C1C2ntPxBOYbdwY+8dO3+wZJyFlbMX9s8zNnvp/tLwAv03NB4j3HVpn8Awwm+GrlP6MVAAAAAElFTkSuQmCC Mime-Version: 1.0 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: r234396 - head X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 20:49:28 -0000 =D0=92 Tue, 17 Apr 2012 20:35:54 +0000 (UTC) Jason Evans =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > Author: jasone > Date: Tue Apr 17 20:35:54 2012 > New Revision: 234396 > URL: http://svn.freebsd.org/changeset/base/234396 >=20 > Log: > Update directions on how to disable malloc debugging. >=20 > Modified: > head/UPDATING >=20 > Modified: head/UPDATING > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=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/UPDATING Tue Apr 17 20:21:04 2012 (r234395) > +++ head/UPDATING Tue Apr 17 20:35:54 2012 (r234396) > @@ -19,8 +19,10 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 10 > includes various WITNESS- related kernel options, > INVARIANTS, malloc debugging flags in userland, and various verbose > features in the kernel. Many developers choose to disable these > features on build > - machines to maximize performance. (To disable malloc > debugging, run > - ln -s aj /etc/malloc.conf.) > + machines to maximize performance. (To completely disable > malloc > + debugging, define MALLOC_PRODUCTION in /etc/make.conf, or to > merely > + disable the most expensive debugging functionality run > + "ln -s 'abort:false,junk:false' /etc/malloc.conf".) > =20 > 20120417: > The malloc(3) implementation embedded in libc now uses > sources imported _______________________________________________ > svn-src-all@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" >=20 >=20 Ooops... :( ln -s 'abort:false,junk:false' /etc/malloc.conf ... c++: (malloc) Unsupported character in malloc options: 'b' c++: (malloc) Unsupported character in malloc options: 'o' c++: (malloc) Unsupported character in malloc options: 'r' c++: (malloc) Unsupported character in malloc options: 't' c++: (malloc) Unsupported character in malloc options: ':' c++: (malloc) Unsupported character in malloc options: 'l' c++: (malloc) Unsupported character in malloc options: 's' c++: (malloc) Unsupported character in malloc options: ',' c++: (malloc) Unsupported character in malloc options: ':' c++: (malloc) Unsupported character in malloc options: 'l' c++: (malloc) Unsupported character in malloc options: 's' ... From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 21:46:59 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EF2191065672; Tue, 17 Apr 2012 21:46:59 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CBCF38FC15; Tue, 17 Apr 2012 21:46:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HLkxTo000739; Tue, 17 Apr 2012 21:46:59 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HLkxS6000736; Tue, 17 Apr 2012 21:46:59 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204172146.q3HLkxS6000736@svn.freebsd.org> From: Kirk McKusick Date: Tue, 17 Apr 2012 21:46: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: r234400 - in head/sys: kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 21:47:00 -0000 Author: mckusick Date: Tue Apr 17 21:46:59 2012 New Revision: 234400 URL: http://svn.freebsd.org/changeset/base/234400 Log: Drop export of vdestroy() function from kern/vfs_subr.c as it is used only as a helper function in that file. Replace sole call to vbusy() with inline code in vholdl(). Replace sole calls to vfree() and vdestroy() with inline code in vdropl(). The Clang compiler already inlines these functions, so they do not show up in a kernel backtrace which is confusing. Also you cannot set their frame in kgdb which means that it is impossible to view their local variables. So, while the produced code is unchanged, the debugging should be easier. Discussed with: kib MFC after: 2 weeks Modified: head/sys/kern/vfs_subr.c head/sys/sys/vnode.h Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Tue Apr 17 20:54:32 2012 (r234399) +++ head/sys/kern/vfs_subr.c Tue Apr 17 21:46:59 2012 (r234400) @@ -102,12 +102,10 @@ static int flushbuflist(struct bufv *buf int slpflag, int slptimeo); static void syncer_shutdown(void *arg, int howto); static int vtryrecycle(struct vnode *vp); -static void vbusy(struct vnode *vp); static void v_incr_usecount(struct vnode *); static void v_decr_usecount(struct vnode *); static void v_decr_useonly(struct vnode *); static void v_upgrade_usecount(struct vnode *); -static void vfree(struct vnode *); static void vnlru_free(int); static void vgonel(struct vnode *); static void vfs_knllock(void *arg); @@ -118,8 +116,7 @@ static void destroy_vpollinfo(struct vpo /* * Number of vnodes in existence. Increased whenever getnewvnode() - * allocates a new vnode, decreased on vdestroy() called on VI_DOOMed - * vnode. + * allocates a new vnode, decreased in vdropl() for VI_DOOMED vnode. */ static unsigned long numvnodes; @@ -878,46 +875,6 @@ SYSINIT(vnlru, SI_SUB_KTHREAD_UPDATE, SI * Routines having to do with the management of the vnode table. */ -void -vdestroy(struct vnode *vp) -{ - struct bufobj *bo; - - CTR2(KTR_VFS, "%s: vp %p", __func__, vp); - mtx_lock(&vnode_free_list_mtx); - numvnodes--; - mtx_unlock(&vnode_free_list_mtx); - bo = &vp->v_bufobj; - VNASSERT((vp->v_iflag & VI_FREE) == 0, vp, - ("cleaned vnode still on the free list.")); - VNASSERT(vp->v_data == NULL, vp, ("cleaned vnode isn't")); - VNASSERT(vp->v_holdcnt == 0, vp, ("Non-zero hold count")); - VNASSERT(vp->v_usecount == 0, vp, ("Non-zero use count")); - VNASSERT(vp->v_writecount == 0, vp, ("Non-zero write count")); - VNASSERT(bo->bo_numoutput == 0, vp, ("Clean vnode has pending I/O's")); - VNASSERT(bo->bo_clean.bv_cnt == 0, vp, ("cleanbufcnt not 0")); - VNASSERT(bo->bo_clean.bv_root == NULL, vp, ("cleanblkroot not NULL")); - VNASSERT(bo->bo_dirty.bv_cnt == 0, vp, ("dirtybufcnt not 0")); - VNASSERT(bo->bo_dirty.bv_root == NULL, vp, ("dirtyblkroot not NULL")); - VNASSERT(TAILQ_EMPTY(&vp->v_cache_dst), vp, ("vp has namecache dst")); - VNASSERT(LIST_EMPTY(&vp->v_cache_src), vp, ("vp has namecache src")); - VNASSERT(vp->v_cache_dd == NULL, vp, ("vp has namecache for ..")); - VI_UNLOCK(vp); -#ifdef MAC - mac_vnode_destroy(vp); -#endif - if (vp->v_pollinfo != NULL) - destroy_vpollinfo(vp->v_pollinfo); -#ifdef INVARIANTS - /* XXX Elsewhere we can detect an already freed vnode via NULL v_op. */ - vp->v_op = NULL; -#endif - lockdestroy(vp->v_vnlock); - mtx_destroy(&vp->v_interlock); - mtx_destroy(BO_MTX(bo)); - uma_zfree(vnode_zone, vp); -} - /* * Try to recycle a freed vnode. We abort if anyone picks up a reference * before we actually vgone(). This function must be called with the vnode @@ -2346,19 +2303,33 @@ vhold(struct vnode *vp) VI_UNLOCK(vp); } +/* + * Increase the hold count and activate if this is the first reference. + */ void vholdl(struct vnode *vp) { CTR2(KTR_VFS, "%s: vp %p", __func__, vp); vp->v_holdcnt++; - if (VSHOULDBUSY(vp)) - vbusy(vp); + if (!VSHOULDBUSY(vp)) + return; + ASSERT_VI_LOCKED(vp, "vholdl"); + VNASSERT((vp->v_iflag & VI_FREE) != 0, vp, ("vnode not free")); + VNASSERT(vp->v_op != NULL, vp, ("vholdl: vnode already reclaimed.")); + /* + * Remove a vnode from the free list and mark it as in use. + */ + mtx_lock(&vnode_free_list_mtx); + TAILQ_REMOVE(&vnode_free_list, vp, v_freelist); + freevnodes--; + vp->v_iflag &= ~(VI_FREE|VI_AGE); + mtx_unlock(&vnode_free_list_mtx); } /* - * Note that there is one less who cares about this vnode. vdrop() is the - * opposite of vhold(). + * Note that there is one less who cares about this vnode. + * vdrop() is the opposite of vhold(). */ void vdrop(struct vnode *vp) @@ -2370,28 +2341,84 @@ vdrop(struct vnode *vp) /* * Drop the hold count of the vnode. If this is the last reference to - * the vnode we will free it if it has been vgone'd otherwise it is - * placed on the free list. + * the vnode we place it on the free list unless it has been vgone'd + * (marked VI_DOOMED) in which case we will free it. */ void vdropl(struct vnode *vp) { + struct bufobj *bo; ASSERT_VI_LOCKED(vp, "vdropl"); CTR2(KTR_VFS, "%s: vp %p", __func__, vp); if (vp->v_holdcnt <= 0) panic("vdrop: holdcnt %d", vp->v_holdcnt); vp->v_holdcnt--; - if (vp->v_holdcnt == 0) { - if (vp->v_iflag & VI_DOOMED) { - CTR2(KTR_VFS, "%s: destroying the vnode %p", __func__, - vp); - vdestroy(vp); - return; - } else - vfree(vp); + if (vp->v_holdcnt > 0) { + VI_UNLOCK(vp); + return; + } + if ((vp->v_iflag & VI_DOOMED) == 0) { + /* + * Mark a vnode as free, putting it up for recycling. + */ + mtx_lock(&vnode_free_list_mtx); + VNASSERT(vp->v_op != NULL, vp, + ("vdropl: vnode already reclaimed.")); + VNASSERT((vp->v_iflag & VI_FREE) == 0, vp, + ("vnode already free")); + VNASSERT(VSHOULDFREE(vp), vp, + ("vdropl: freeing when we shouldn't")); + VNASSERT((vp->v_iflag & VI_DOOMED) == 0, vp, + ("vdropl: Freeing doomed vnode")); + if (vp->v_iflag & VI_AGE) { + TAILQ_INSERT_HEAD(&vnode_free_list, vp, v_freelist); + } else { + TAILQ_INSERT_TAIL(&vnode_free_list, vp, v_freelist); + } + freevnodes++; + vp->v_iflag &= ~VI_AGE; + vp->v_iflag |= VI_FREE; + mtx_unlock(&vnode_free_list_mtx); + VI_UNLOCK(vp); + return; } + /* + * The vnode has been marked for destruction, so free it. + */ + CTR2(KTR_VFS, "%s: destroying the vnode %p", __func__, vp); + mtx_lock(&vnode_free_list_mtx); + numvnodes--; + mtx_unlock(&vnode_free_list_mtx); + bo = &vp->v_bufobj; + VNASSERT((vp->v_iflag & VI_FREE) == 0, vp, + ("cleaned vnode still on the free list.")); + VNASSERT(vp->v_data == NULL, vp, ("cleaned vnode isn't")); + VNASSERT(vp->v_holdcnt == 0, vp, ("Non-zero hold count")); + VNASSERT(vp->v_usecount == 0, vp, ("Non-zero use count")); + VNASSERT(vp->v_writecount == 0, vp, ("Non-zero write count")); + VNASSERT(bo->bo_numoutput == 0, vp, ("Clean vnode has pending I/O's")); + VNASSERT(bo->bo_clean.bv_cnt == 0, vp, ("cleanbufcnt not 0")); + VNASSERT(bo->bo_clean.bv_root == NULL, vp, ("cleanblkroot not NULL")); + VNASSERT(bo->bo_dirty.bv_cnt == 0, vp, ("dirtybufcnt not 0")); + VNASSERT(bo->bo_dirty.bv_root == NULL, vp, ("dirtyblkroot not NULL")); + VNASSERT(TAILQ_EMPTY(&vp->v_cache_dst), vp, ("vp has namecache dst")); + VNASSERT(LIST_EMPTY(&vp->v_cache_src), vp, ("vp has namecache src")); + VNASSERT(vp->v_cache_dd == NULL, vp, ("vp has namecache for ..")); VI_UNLOCK(vp); +#ifdef MAC + mac_vnode_destroy(vp); +#endif + if (vp->v_pollinfo != NULL) + destroy_vpollinfo(vp->v_pollinfo); +#ifdef INVARIANTS + /* XXX Elsewhere we detect an already freed vnode via NULL v_op. */ + vp->v_op = NULL; +#endif + lockdestroy(vp->v_vnlock); + mtx_destroy(&vp->v_interlock); + mtx_destroy(BO_MTX(bo)); + uma_zfree(vnode_zone, vp); } /* @@ -3298,50 +3325,6 @@ vfs_msync(struct mount *mp, int flags) } } -/* - * Mark a vnode as free, putting it up for recycling. - */ -static void -vfree(struct vnode *vp) -{ - - ASSERT_VI_LOCKED(vp, "vfree"); - mtx_lock(&vnode_free_list_mtx); - VNASSERT(vp->v_op != NULL, vp, ("vfree: vnode already reclaimed.")); - VNASSERT((vp->v_iflag & VI_FREE) == 0, vp, ("vnode already free")); - VNASSERT(VSHOULDFREE(vp), vp, ("vfree: freeing when we shouldn't")); - VNASSERT((vp->v_iflag & VI_DOOMED) == 0, vp, - ("vfree: Freeing doomed vnode")); - CTR2(KTR_VFS, "%s: vp %p", __func__, vp); - if (vp->v_iflag & VI_AGE) { - TAILQ_INSERT_HEAD(&vnode_free_list, vp, v_freelist); - } else { - TAILQ_INSERT_TAIL(&vnode_free_list, vp, v_freelist); - } - freevnodes++; - vp->v_iflag &= ~VI_AGE; - vp->v_iflag |= VI_FREE; - mtx_unlock(&vnode_free_list_mtx); -} - -/* - * Opposite of vfree() - mark a vnode as in use. - */ -static void -vbusy(struct vnode *vp) -{ - ASSERT_VI_LOCKED(vp, "vbusy"); - VNASSERT((vp->v_iflag & VI_FREE) != 0, vp, ("vnode not free")); - VNASSERT(vp->v_op != NULL, vp, ("vbusy: vnode already reclaimed.")); - CTR2(KTR_VFS, "%s: vp %p", __func__, vp); - - mtx_lock(&vnode_free_list_mtx); - TAILQ_REMOVE(&vnode_free_list, vp, v_freelist); - freevnodes--; - vp->v_iflag &= ~(VI_FREE|VI_AGE); - mtx_unlock(&vnode_free_list_mtx); -} - static void destroy_vpollinfo(struct vpollinfo *vi) { Modified: head/sys/sys/vnode.h ============================================================================== --- head/sys/sys/vnode.h Tue Apr 17 20:54:32 2012 (r234399) +++ head/sys/sys/vnode.h Tue Apr 17 21:46:59 2012 (r234400) @@ -626,7 +626,6 @@ void vattr_null(struct vattr *vap); int vcount(struct vnode *vp); void vdrop(struct vnode *); void vdropl(struct vnode *); -void vdestroy(struct vnode *); int vflush(struct mount *mp, int rootrefs, int flags, struct thread *td); int vget(struct vnode *vp, int lockflag, struct thread *td); void vgone(struct vnode *vp); From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 22:05:56 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3685F106566B; Tue, 17 Apr 2012 22:05:56 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 200908FC08; Tue, 17 Apr 2012 22:05:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3HM5tX3001507; Tue, 17 Apr 2012 22:05:55 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3HM5to8001499; Tue, 17 Apr 2012 22:05:55 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201204172205.q3HM5to8001499@svn.freebsd.org> From: Jason Evans Date: Tue, 17 Apr 2012 22:05: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: r234402 - in head/contrib/jemalloc: . doc include/jemalloc include/jemalloc/internal X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 22:05:56 -0000 Author: jasone Date: Tue Apr 17 22:05:55 2012 New Revision: 234402 URL: http://svn.freebsd.org/changeset/base/234402 Log: Import jemalloc b57d3ec571c6551231be62b7bf92c084a8c8291c (dev branch, prior to 3.0.0 release), which supports atomic operations based on atomic(9). This should fix build failures for several platforms. Modified: head/contrib/jemalloc/FREEBSD-diffs head/contrib/jemalloc/VERSION head/contrib/jemalloc/doc/jemalloc.3 head/contrib/jemalloc/include/jemalloc/internal/atomic.h head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h head/contrib/jemalloc/include/jemalloc/jemalloc.h head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h Modified: head/contrib/jemalloc/FREEBSD-diffs ============================================================================== --- head/contrib/jemalloc/FREEBSD-diffs Tue Apr 17 21:55:35 2012 (r234401) +++ head/contrib/jemalloc/FREEBSD-diffs Tue Apr 17 22:05:55 2012 (r234402) @@ -45,17 +45,19 @@ index 98d0ba4..23d2152 100644 + diff --git a/include/jemalloc/internal/jemalloc_internal.h.in b/include/jemalloc/internal/jemalloc_internal.h.in -index aa21aa5..e0f5fed 100644 +index 905653a..b235a0d 100644 --- a/include/jemalloc/internal/jemalloc_internal.h.in +++ b/include/jemalloc/internal/jemalloc_internal.h.in -@@ -1,3 +1,6 @@ +@@ -1,5 +1,8 @@ + #ifndef JEMALLOC_INTERNAL_H + #define JEMALLOC_INTERNAL_H +#include "libc_private.h" +#include "namespace.h" + #include #include #include -@@ -33,6 +36,9 @@ +@@ -35,6 +38,9 @@ #include #include Modified: head/contrib/jemalloc/VERSION ============================================================================== --- head/contrib/jemalloc/VERSION Tue Apr 17 21:55:35 2012 (r234401) +++ head/contrib/jemalloc/VERSION Tue Apr 17 22:05:55 2012 (r234402) @@ -1 +1 @@ -1.0.0-258-g9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa +1.0.0-266-gb57d3ec571c6551231be62b7bf92c084a8c8291c Modified: head/contrib/jemalloc/doc/jemalloc.3 ============================================================================== --- head/contrib/jemalloc/doc/jemalloc.3 Tue Apr 17 21:55:35 2012 (r234401) +++ head/contrib/jemalloc/doc/jemalloc.3 Tue Apr 17 22:05:55 2012 (r234402) @@ -2,12 +2,12 @@ .\" Title: JEMALLOC .\" Author: Jason Evans .\" Generator: DocBook XSL Stylesheets v1.76.1 -.\" Date: 04/16/2012 +.\" Date: 04/17/2012 .\" Manual: User Manual -.\" Source: jemalloc 1.0.0-258-g9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa +.\" Source: jemalloc 1.0.0-266-gb57d3ec571c6551231be62b7bf92c084a8c8291c .\" Language: English .\" -.TH "JEMALLOC" "3" "04/16/2012" "jemalloc 1.0.0-258-g9ef7f5dc34" "User Manual" +.TH "JEMALLOC" "3" "04/17/2012" "jemalloc 1.0.0-266-gb57d3ec571" "User Manual" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- @@ -31,7 +31,7 @@ jemalloc \- general purpose memory allocation functions .SH "LIBRARY" .PP -This manual describes jemalloc 1\&.0\&.0\-258\-g9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa\&. More information can be found at the +This manual describes jemalloc 1\&.0\&.0\-266\-gb57d3ec571c6551231be62b7bf92c084a8c8291c\&. More information can be found at the \m[blue]\fBjemalloc website\fR\m[]\&\s-2\u[1]\d\s+2\&. .PP The following configuration options are enabled in libc\*(Aqs built\-in jemalloc: Modified: head/contrib/jemalloc/include/jemalloc/internal/atomic.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/atomic.h Tue Apr 17 21:55:35 2012 (r234401) +++ head/contrib/jemalloc/include/jemalloc/internal/atomic.h Tue Apr 17 22:05:55 2012 (r234402) @@ -32,7 +32,8 @@ unsigned atomic_sub_u(unsigned *p, unsig #if (defined(JEMALLOC_ENABLE_INLINE) || defined(JEMALLOC_ATOMIC_C_)) /******************************************************************************/ /* 64-bit operations. */ -#ifdef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 +#if (LG_SIZEOF_PTR == 3 || LG_SIZEOF_INT == 3) +# ifdef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 JEMALLOC_INLINE uint64_t atomic_add_uint64(uint64_t *p, uint64_t x) { @@ -60,7 +61,7 @@ atomic_sub_uint64(uint64_t *p, uint64_t return (OSAtomicAdd64(-((int64_t)x), (int64_t *)p)); } -#elif (defined(__amd64__) || defined(__x86_64__)) +# elif (defined(__amd64__) || defined(__x86_64__)) JEMALLOC_INLINE uint64_t atomic_add_uint64(uint64_t *p, uint64_t x) { @@ -87,7 +88,29 @@ atomic_sub_uint64(uint64_t *p, uint64_t return (x); } -#elif (defined(JE_FORCE_SYNC_COMPARE_AND_SWAP_8)) +# elif (defined(JEMALLOC_ATOMIC9)) +JEMALLOC_INLINE uint64_t +atomic_add_uint64(uint64_t *p, uint64_t x) +{ + + /* + * atomic_fetchadd_64() doesn't exist, but we only ever use this + * function on LP64 systems, so atomic_fetchadd_long() will do. + */ + assert(sizeof(uint64_t) == sizeof(unsigned long)); + + return (atomic_fetchadd_long(p, (unsigned long)x) + x); +} + +JEMALLOC_INLINE uint64_t +atomic_sub_uint64(uint64_t *p, uint64_t x) +{ + + assert(sizeof(uint64_t) == sizeof(unsigned long)); + + return (atomic_fetchadd_long(p, (unsigned long)(-(long)x)) - x); +} +# elif (defined(JE_FORCE_SYNC_COMPARE_AND_SWAP_8)) JEMALLOC_INLINE uint64_t atomic_add_uint64(uint64_t *p, uint64_t x) { @@ -101,8 +124,7 @@ atomic_sub_uint64(uint64_t *p, uint64_t return (__sync_sub_and_fetch(p, x)); } -#else -# if (LG_SIZEOF_PTR == 3) +# else # error "Missing implementation for 64-bit atomic operations" # endif #endif @@ -164,6 +186,20 @@ atomic_sub_uint32(uint32_t *p, uint32_t return (x); } +#elif (defined(JEMALLOC_ATOMIC9)) +JEMALLOC_INLINE uint32_t +atomic_add_uint32(uint32_t *p, uint32_t x) +{ + + return (atomic_fetchadd_32(p, x) + x); +} + +JEMALLOC_INLINE uint32_t +atomic_sub_uint32(uint32_t *p, uint32_t x) +{ + + return (atomic_fetchadd_32(p, (uint32_t)(-(int32_t)x)) - x); +} #elif (defined(JE_FORCE_SYNC_COMPARE_AND_SWAP_4)) JEMALLOC_INLINE uint32_t atomic_add_uint32(uint32_t *p, uint32_t x) Modified: head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h Tue Apr 17 21:55:35 2012 (r234401) +++ head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h Tue Apr 17 22:05:55 2012 (r234402) @@ -1,3 +1,5 @@ +#ifndef JEMALLOC_INTERNAL_H +#define JEMALLOC_INTERNAL_H #include "libc_private.h" #include "namespace.h" @@ -165,6 +167,10 @@ static const bool config_ivsalloc = #endif ; +#ifdef JEMALLOC_ATOMIC9 +#include +#endif + #if (defined(JEMALLOC_OSATOMIC) || defined(JEMALLOC_OSSPIN)) #include #endif @@ -874,3 +880,4 @@ malloc_tsd_funcs(JEMALLOC_INLINE, thread #undef JEMALLOC_H_INLINES /******************************************************************************/ +#endif /* JEMALLOC_INTERNAL_H */ Modified: head/contrib/jemalloc/include/jemalloc/jemalloc.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/jemalloc.h Tue Apr 17 21:55:35 2012 (r234401) +++ head/contrib/jemalloc/include/jemalloc/jemalloc.h Tue Apr 17 22:05:55 2012 (r234402) @@ -7,12 +7,12 @@ extern "C" { #include #include -#define JEMALLOC_VERSION "1.0.0-258-g9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa" +#define JEMALLOC_VERSION "1.0.0-266-gb57d3ec571c6551231be62b7bf92c084a8c8291c" #define JEMALLOC_VERSION_MAJOR 1 #define JEMALLOC_VERSION_MINOR 0 #define JEMALLOC_VERSION_BUGFIX 0 -#define JEMALLOC_VERSION_NREV 258 -#define JEMALLOC_VERSION_GID "9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa" +#define JEMALLOC_VERSION_NREV 266 +#define JEMALLOC_VERSION_GID "b57d3ec571c6551231be62b7bf92c084a8c8291c" #include "jemalloc_defs.h" #include "jemalloc_FreeBSD.h" Modified: head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h Tue Apr 17 21:55:35 2012 (r234401) +++ head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h Tue Apr 17 22:05:55 2012 (r234402) @@ -48,6 +48,9 @@ */ #define CPU_SPINWAIT __asm__ volatile("pause") +/* Defined if the equivalent of FreeBSD's atomic(9) functions are available. */ +#define JEMALLOC_ATOMIC9 1 + /* * Defined if OSAtomic*() functions are available, as provided by Darwin, and * documented in the atomic(3) manual page. @@ -60,7 +63,7 @@ * __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 not being defined (which means the * functions are defined in libgcc instead of being inlines) */ -#define JE_FORCE_SYNC_COMPARE_AND_SWAP_4 +/* #undef JE_FORCE_SYNC_COMPARE_AND_SWAP_4 */ /* * Defined if __sync_add_and_fetch(uint64_t *, uint64_t) and @@ -68,7 +71,7 @@ * __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8 not being defined (which means the * functions are defined in libgcc instead of being inlines) */ -#define JE_FORCE_SYNC_COMPARE_AND_SWAP_8 +/* #undef JE_FORCE_SYNC_COMPARE_AND_SWAP_8 */ /* * Defined if OSSpin*() functions are available, as provided by Darwin, and From owner-svn-src-all@FreeBSD.ORG Tue Apr 17 22:27:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx2.freebsd.org (mx2.freebsd.org [IPv6:2001:4f8:fff6::35]) by hub.freebsd.org (Postfix) with ESMTP id 5D3EF106566C; Tue, 17 Apr 2012 22:27:18 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from opti.dougb.net (hub.freebsd.org [IPv6:2001:4f8:fff6::36]) by mx2.freebsd.org (Postfix) with ESMTP id B4213150192; Tue, 17 Apr 2012 22:27:17 +0000 (UTC) Message-ID: <4F8DEE45.3080709@FreeBSD.org> Date: Tue, 17 Apr 2012 15:27:17 -0700 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:10.0.3) Gecko/20120404 Thunderbird/10.0.3 MIME-Version: 1.0 To: Jason Evans References: <201204170722.q3H7ME6A070934@svn.freebsd.org> In-Reply-To: <201204170722.q3H7ME6A070934@svn.freebsd.org> X-Enigmail-Version: 1.4 OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Apr 2012 22:27:18 -0000 On 04/17/2012 00:22, Jason Evans wrote: > Import jemalloc 9ef7f5dc34ff02f50d401e41c8d9a4a928e7c2aa (dev branch, > prior to 3.0.0 release) as contrib/jemalloc Isn't stuff in src/contrib supposed to have a vendor/ branch? I think obrien mentioned this to you ... See vendor/bind9/dist/FREEBSD-Upgrade for an example if necessary. Doug -- This .signature sanitized for your protection From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 01:39:15 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8913810656B1; Wed, 18 Apr 2012 01:39:15 +0000 (UTC) (envelope-from thompsa@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2D1D08FC12; Wed, 18 Apr 2012 01:39:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I1dFUM008426; Wed, 18 Apr 2012 01:39:15 GMT (envelope-from thompsa@svn.freebsd.org) Received: (from thompsa@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I1dEPZ008424; Wed, 18 Apr 2012 01:39:14 GMT (envelope-from thompsa@svn.freebsd.org) Message-Id: <201204180139.q3I1dEPZ008424@svn.freebsd.org> From: Andrew Thompson Date: Wed, 18 Apr 2012 01:39: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: r234403 - head/sys/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 01:39:15 -0000 Author: thompsa Date: Wed Apr 18 01:39:14 2012 New Revision: 234403 URL: http://svn.freebsd.org/changeset/base/234403 Log: Remove KASSERTS, they do not add any value here since the pointer is about to be derefernced anyway. Modified: head/sys/net/if.c Modified: head/sys/net/if.c ============================================================================== --- head/sys/net/if.c Tue Apr 17 22:05:55 2012 (r234402) +++ head/sys/net/if.c Wed Apr 18 01:39:14 2012 (r234403) @@ -1909,14 +1909,10 @@ do_link_state_change(void *arg, int pend (*ng_ether_link_state_p)(ifp, link_state); if (ifp->if_carp) (*carp_linkstate_p)(ifp); - if (ifp->if_bridge) { - KASSERT(bstp_linkstate_p != NULL,("if_bridge bstp not loaded!")); + if (ifp->if_bridge) (*bstp_linkstate_p)(ifp, link_state); - } - if (ifp->if_lagg) { - KASSERT(lagg_linkstate_p != NULL,("if_lagg not loaded!")); + if (ifp->if_lagg) (*lagg_linkstate_p)(ifp, link_state); - } if (IS_DEFAULT_VNET(curvnet)) devctl_notify("IFNET", ifp->if_xname, From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 02:16:25 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 929201065675; Wed, 18 Apr 2012 02:16:25 +0000 (UTC) (envelope-from peterjeremy@acm.org) Received: from mail16.syd.optusnet.com.au (mail16.syd.optusnet.com.au [211.29.132.197]) by mx1.freebsd.org (Postfix) with ESMTP id F10388FC16; Wed, 18 Apr 2012 02:16:24 +0000 (UTC) Received: from server.vk2pj.dyndns.org (c220-239-251-180.belrs5.nsw.optusnet.com.au [220.239.251.180]) by mail16.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id q3I2GGr2025345 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 18 Apr 2012 12:16:17 +1000 X-Bogosity: Ham, spamicity=0.000000 Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by server.vk2pj.dyndns.org (8.14.5/8.14.4) with ESMTP id q3I2GFxQ068667; Wed, 18 Apr 2012 12:16:15 +1000 (EST) (envelope-from peter@server.vk2pj.dyndns.org) Received: (from peter@localhost) by server.vk2pj.dyndns.org (8.14.5/8.14.5/Submit) id q3I2GF62068664; Wed, 18 Apr 2012 12:16:15 +1000 (EST) (envelope-from peter) Date: Wed, 18 Apr 2012 12:16:14 +1000 From: Peter Jeremy To: Andrew Thompson Message-ID: <20120418021614.GA37269@server.vk2pj.dyndns.org> References: <201204180139.q3I1dEPZ008424@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="xHFwDpU9dbj6ez1V" Content-Disposition: inline In-Reply-To: <201204180139.q3I1dEPZ008424@svn.freebsd.org> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc 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: r234403 - head/sys/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 02:16:25 -0000 --xHFwDpU9dbj6ez1V Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2012-Apr-18 01:39:14 +0000, Andrew Thompson wrote: >Log: > Remove KASSERTS, they do not add any value here since the pointer is abo= ut to > be derefernced anyway. Could you give a bit more background to this commit. You get a crash in both cases but the KASSERT() at least tells you which variable was NULL without needing to trawl through the crashdump to find what caused the NULL pointer dereference trap. --=20 Peter Jeremy --xHFwDpU9dbj6ez1V Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAk+OI+4ACgkQ/opHv/APuIe/lgCeIrbn2hu/S8ycTqu9d9vRPdnE vEAAn32jtvIzlauomHYzInuwJbFfyUBB =sL1q -----END PGP SIGNATURE----- --xHFwDpU9dbj6ez1V-- From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 02:22:57 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 97243106566C for ; Wed, 18 Apr 2012 02:22:57 +0000 (UTC) (envelope-from andy@fud.org.nz) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 644E78FC16 for ; Wed, 18 Apr 2012 02:22:57 +0000 (UTC) Received: by pbcwz17 with SMTP id wz17so8839367pbc.13 for ; Tue, 17 Apr 2012 19:22:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding:x-gm-message-state; bh=QzlKT1v87OHZQu3jTK63EUSMVlOR4ov8PEhEA6PJ3YQ=; b=lvx/BokNlSNHeByrlnWaYSfd1OBQUoLxtxj2anHgT0+T/EPOTAgpB+8L59CNhyJ2MG w9/5nRjQ1AqhnHVLEN0C323ZNxUwHhZDMRpfS6vWHMxMfVwIaoHSEL8l7pHxbBSkQKoX zSbnH7HKXyQHO+kxxQ0VwVvSepzoIVdYlKfqJ4g4RPAnkDOrXUx9IGn365ZPsTVoXw5Q RCxWRQj2dFJaTmvlEhYjV5Jf0nlJgoP+dBAFF702153JDzSiBLzmDRp+M5a/svlcusib LWwx+FdEC1sV8AMoE/vYbIJJc1yhDgZhnb/a+DPIHktk7ti3kQnV9LjvVgSvIuFJuDYj 1ZEg== MIME-Version: 1.0 Received: by 10.68.219.72 with SMTP id pm8mr2146391pbc.116.1334715776927; Tue, 17 Apr 2012 19:22:56 -0700 (PDT) Sender: andy@fud.org.nz Received: by 10.68.239.164 with HTTP; Tue, 17 Apr 2012 19:22:56 -0700 (PDT) In-Reply-To: <20120418021614.GA37269@server.vk2pj.dyndns.org> References: <201204180139.q3I1dEPZ008424@svn.freebsd.org> <20120418021614.GA37269@server.vk2pj.dyndns.org> Date: Wed, 18 Apr 2012 14:22:56 +1200 X-Google-Sender-Auth: g0vQvWTOMFYBAd3eiJ1INdei7XE Message-ID: From: Andrew Thompson To: Peter Jeremy Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Gm-Message-State: ALoCoQn6eWw1z+bjjpFdOHtaZkmkvLM8WmkdTvi2syrD4AgyCQFSfi8kR4mxRSwMNEhzMf9W1eZB Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234403 - head/sys/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 02:22:57 -0000 On 18 April 2012 14:16, Peter Jeremy wrote: > On 2012-Apr-18 01:39:14 +0000, Andrew Thompson wrot= e: >>Log: >> =A0Remove KASSERTS, they do not add any value here since the pointer is = about to >> =A0be derefernced anyway. > > Could you give a bit more background to this commit. =A0You get a crash i= n > both cases but the KASSERT() at least tells you which variable was NULL > without needing to trawl through the crashdump to find what caused the > NULL pointer dereference trap. Out of the five linkstate function pointers in this block of code only these two had a kassert so it was just about making it more consistent. It is something that is not possible within the code anyway (sans memory corruption). Andrew From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 04:29:49 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 63CDD106566B; Wed, 18 Apr 2012 04:29:49 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail01.syd.optusnet.com.au (mail01.syd.optusnet.com.au [211.29.132.182]) by mx1.freebsd.org (Postfix) with ESMTP id D7AA48FC0A; Wed, 18 Apr 2012 04:29:48 +0000 (UTC) Received: from c211-30-171-136.carlnfd1.nsw.optusnet.com.au (c211-30-171-136.carlnfd1.nsw.optusnet.com.au [211.30.171.136]) by mail01.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id q3I4TevX006328 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 18 Apr 2012 14:29:41 +1000 Date: Wed, 18 Apr 2012 14:29:40 +1000 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Kirk McKusick In-Reply-To: <201204172146.q3HLkxS6000736@svn.freebsd.org> Message-ID: <20120418135636.C1082@besplex.bde.org> References: <201204172146.q3HLkxS6000736@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: r234400 - in head/sys: kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 04:29:49 -0000 On Tue, 17 Apr 2012, Kirk McKusick wrote: > Log: > Drop export of vdestroy() function from kern/vfs_subr.c as it is > used only as a helper function in that file. Replace sole call to > vbusy() with inline code in vholdl(). Replace sole calls to vfree() > and vdestroy() with inline code in vdropl(). > > The Clang compiler already inlines these functions, so they do not > show up in a kernel backtrace which is confusing. Also you cannot > set their frame in kgdb which means that it is impossible to view > their local variables. So, while the produced code is unchanged, > the debugging should be easier. gcc-4.2.1 has the same bug, but you can avoid it using -fno-inline-functions-called-once (not the default). Unfortunately, this flag is not even a no-op with clang (it generates an error message). Inlining of functions called once also breaks profiling. The breakage for debugging is especially large for primitive debuggers like ddb. Without line numbers, it is difficult to even find the code for small functions when they are inlined into big functions. With full symbol table info, it should be possible to display inlined functions as if they weren't inlined, especially if they aren't declared inline, but I've never seen a debugger than can even step over them properly using 'n'. Bruce From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 04:39:13 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 46AFA106566C; Wed, 18 Apr 2012 04:39:13 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 30F7B8FC08; Wed, 18 Apr 2012 04:39:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I4dDOY014518; Wed, 18 Apr 2012 04:39:13 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I4dCD7014516; Wed, 18 Apr 2012 04:39:12 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180439.q3I4dCD7014516@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 04:39:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234404 - stable/9/sys/geom/part X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 04:39:13 -0000 Author: ae Date: Wed Apr 18 04:39:12 2012 New Revision: 234404 URL: http://svn.freebsd.org/changeset/base/234404 Log: MFC r233175: Make kern.geom.part node not static. Also add CTLFLAG_TUN to the check_integrity sysctl. Modified: stable/9/sys/geom/part/g_part.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/geom/part/g_part.c ============================================================================== --- stable/9/sys/geom/part/g_part.c Wed Apr 18 01:39:14 2012 (r234403) +++ stable/9/sys/geom/part/g_part.c Wed Apr 18 04:39:12 2012 (r234404) @@ -106,11 +106,13 @@ struct g_part_alias_list { }; SYSCTL_DECL(_kern_geom); -SYSCTL_NODE(_kern_geom, OID_AUTO, part, CTLFLAG_RW, 0, "GEOM_PART stuff"); +SYSCTL_NODE(_kern_geom, OID_AUTO, part, CTLFLAG_RW, 0, + "GEOM_PART stuff"); static u_int check_integrity = 1; TUNABLE_INT("kern.geom.part.check_integrity", &check_integrity); -SYSCTL_UINT(_kern_geom_part, OID_AUTO, check_integrity, CTLFLAG_RW, - &check_integrity, 1, "Enable integrity checking"); +SYSCTL_UINT(_kern_geom_part, OID_AUTO, check_integrity, + CTLFLAG_RW | CTLFLAG_TUN, &check_integrity, 1, + "Enable integrity checking"); /* * The GEOM partitioning class. From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 04:39:37 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C0FB71065673; Wed, 18 Apr 2012 04:39:37 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AB6C38FC19; Wed, 18 Apr 2012 04:39:37 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I4dbK5014564; Wed, 18 Apr 2012 04:39:37 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I4db3n014562; Wed, 18 Apr 2012 04:39:37 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180439.q3I4db3n014562@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 04:39:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234405 - stable/8/sys/geom/part X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 04:39:37 -0000 Author: ae Date: Wed Apr 18 04:39:37 2012 New Revision: 234405 URL: http://svn.freebsd.org/changeset/base/234405 Log: MFC r233175: Make kern.geom.part node not static. Also add CTLFLAG_TUN to the check_integrity sysctl. Modified: stable/8/sys/geom/part/g_part.c Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/geom/part/g_part.c ============================================================================== --- stable/8/sys/geom/part/g_part.c Wed Apr 18 04:39:12 2012 (r234404) +++ stable/8/sys/geom/part/g_part.c Wed Apr 18 04:39:37 2012 (r234405) @@ -106,11 +106,13 @@ struct g_part_alias_list { }; SYSCTL_DECL(_kern_geom); -SYSCTL_NODE(_kern_geom, OID_AUTO, part, CTLFLAG_RW, 0, "GEOM_PART stuff"); +SYSCTL_NODE(_kern_geom, OID_AUTO, part, CTLFLAG_RW, 0, + "GEOM_PART stuff"); static u_int check_integrity = 0; TUNABLE_INT("kern.geom.part.check_integrity", &check_integrity); -SYSCTL_UINT(_kern_geom_part, OID_AUTO, check_integrity, CTLFLAG_RW, - &check_integrity, 0, "Enable integrity checking"); +SYSCTL_UINT(_kern_geom_part, OID_AUTO, check_integrity, + CTLFLAG_RW | CTLFLAG_TUN, &check_integrity, 0, + "Enable integrity checking"); /* * The GEOM partitioning class. From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 04:59:48 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 87B231065670; Wed, 18 Apr 2012 04:59:48 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6FB978FC12; Wed, 18 Apr 2012 04:59:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I4xmhj015222; Wed, 18 Apr 2012 04:59:48 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I4xmsh015215; Wed, 18 Apr 2012 04:59:48 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180459.q3I4xmsh015215@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 04:59:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234406 - in stable/9/sys: conf geom/part modules/geom/geom_part modules/geom/geom_part/geom_part_ldm X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 04:59:48 -0000 Author: ae Date: Wed Apr 18 04:59:47 2012 New Revision: 234406 URL: http://svn.freebsd.org/changeset/base/234406 Log: MFC r233176: Add new GEOM_PART_LDM module that implements the Logical Disk Manager scheme. The LDM is a logical volume manager for MS Windows NT and it is also known as dynamic volumes. It supports about 2000 partitions and also provides the capability for software RAID implementations. This version implements only partitioning scheme capability and based on the linux-ntfs project documentation and several publications across the Web. NOTE: JBOD, RAID0 and RAID5 volumes aren't supported. An access to the LDM metadata is read-only. When LDM is on the disk partitioned with MBR we can also destroy metadata. For the GPT partitioned disks destroy action is not supported. MFC r233177: Connect geom_part_ldm module to the build. MFC r233178: Connect geom_part_ldm to the kernel build. MFC r233181: Add CTLFLAG_TUN to sysctls. MFC r233651: Do proper cleanup for the GPT case when an error occurs. MFC r233652: VMDB offset should be greater than logical volume size only for MBR. Added: stable/9/sys/geom/part/g_part_ldm.c - copied, changed from r233176, head/sys/geom/part/g_part_ldm.c stable/9/sys/modules/geom/geom_part/geom_part_ldm/ - copied from r233177, head/sys/modules/geom/geom_part/geom_part_ldm/ Modified: stable/9/sys/conf/NOTES stable/9/sys/conf/files stable/9/sys/conf/options stable/9/sys/modules/geom/geom_part/Makefile Directory Properties: stable/9/sys/ (props changed) stable/9/sys/conf/ (props changed) Modified: stable/9/sys/conf/NOTES ============================================================================== --- stable/9/sys/conf/NOTES Wed Apr 18 04:39:37 2012 (r234405) +++ stable/9/sys/conf/NOTES Wed Apr 18 04:59:47 2012 (r234406) @@ -159,6 +159,7 @@ options GEOM_PART_BSD # BSD disklabel options GEOM_PART_EBR # Extended Boot Records options GEOM_PART_EBR_COMPAT # Backward compatible partition names options GEOM_PART_GPT # GPT partitioning +options GEOM_PART_LDM # Logical Disk Manager options GEOM_PART_MBR # MBR partitioning options GEOM_PART_PC98 # PC-9800 disk partitioning options GEOM_PART_VTOC8 # SMI VTOC8 disk label Modified: stable/9/sys/conf/files ============================================================================== --- stable/9/sys/conf/files Wed Apr 18 04:39:37 2012 (r234405) +++ stable/9/sys/conf/files Wed Apr 18 04:59:47 2012 (r234406) @@ -2241,6 +2241,7 @@ geom/part/g_part_apm.c optional geom_pa geom/part/g_part_bsd.c optional geom_part_bsd geom/part/g_part_ebr.c optional geom_part_ebr geom/part/g_part_gpt.c optional geom_part_gpt +geom/part/g_part_ldm.c optional geom_part_ldm geom/part/g_part_mbr.c optional geom_part_mbr geom/part/g_part_pc98.c optional geom_part_pc98 geom/part/g_part_vtoc8.c optional geom_part_vtoc8 Modified: stable/9/sys/conf/options ============================================================================== --- stable/9/sys/conf/options Wed Apr 18 04:39:37 2012 (r234405) +++ stable/9/sys/conf/options Wed Apr 18 04:59:47 2012 (r234406) @@ -101,6 +101,7 @@ GEOM_PART_BSD opt_geom.h GEOM_PART_EBR opt_geom.h GEOM_PART_EBR_COMPAT opt_geom.h GEOM_PART_GPT opt_geom.h +GEOM_PART_LDM opt_geom.h GEOM_PART_MBR opt_geom.h GEOM_PART_PC98 opt_geom.h GEOM_PART_VTOC8 opt_geom.h Copied and modified: stable/9/sys/geom/part/g_part_ldm.c (from r233176, head/sys/geom/part/g_part_ldm.c) ============================================================================== --- head/sys/geom/part/g_part_ldm.c Mon Mar 19 13:14:44 2012 (r233176, copy source) +++ stable/9/sys/geom/part/g_part_ldm.c Wed Apr 18 04:59:47 2012 (r234406) @@ -56,8 +56,8 @@ static SYSCTL_NODE(_kern_geom_part, OID_ static u_int ldm_debug = 0; TUNABLE_INT("kern.geom.part.ldm.debug", &ldm_debug); -SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, debug, CTLFLAG_RW, - &ldm_debug, 0, "Debug level"); +SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, debug, + CTLFLAG_RW | CTLFLAG_TUN, &ldm_debug, 0, "Debug level"); /* * This allows access to mirrored LDM volumes. Since we do not @@ -65,8 +65,8 @@ SYSCTL_UINT(_kern_geom_part_ldm, OID_AUT */ static u_int show_mirrors = 0; TUNABLE_INT("kern.geom.part.ldm.show_mirrors", &show_mirrors); -SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, show_mirrors, CTLFLAG_RW, - &show_mirrors, 0, "Show mirrored volumes"); +SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, show_mirrors, + CTLFLAG_RW | CTLFLAG_TUN, &show_mirrors, 0, "Show mirrored volumes"); #define LDM_DEBUG(lvl, fmt, ...) do { \ if (ldm_debug >= (lvl)) { \ @@ -495,7 +495,7 @@ ldm_privhdr_check(struct ldm_db *db, str g_free(buf); if (hdr.start > last || hdr.start + hdr.size - 1 > last || - (hdr.start + hdr.size - 1 > hdr.db_offset && is_gpt) || + (hdr.start + hdr.size - 1 > hdr.db_offset && !is_gpt) || hdr.db_size != LDM_DB_SIZE || hdr.db_offset + LDM_DB_SIZE - 1 > last || hdr.th_offset[0] >= LDM_DB_SIZE || @@ -1371,14 +1371,15 @@ g_part_ldm_read(struct g_part_table *bas /* Read and parse LDM private headers. */ error = ldm_privhdr_check(&db, cp, table->is_gpt); if (error != 0) - return (error); + goto gpt_cleanup; basetable->gpt_first = table->is_gpt ? 0: db.ph.start; basetable->gpt_last = basetable->gpt_first + db.ph.size - 1; table->db_offset = db.ph.db_offset; /* Make additional checks for GPT */ if (table->is_gpt) { - if (ldm_gpt_check(&db, cp) != 0) - return (ENXIO); + error = ldm_gpt_check(&db, cp); + if (error != 0) + goto gpt_cleanup; /* * Now we should reset database offset to zero, because our * consumer cp is attached to the ms-ldm-metadata partition @@ -1389,12 +1390,25 @@ g_part_ldm_read(struct g_part_table *bas /* Read and parse LDM TOC headers. */ error = ldm_tochdr_check(&db, cp); if (error != 0) - return (error); + goto gpt_cleanup; /* Read and parse LDM VMDB header. */ error = ldm_vmdbhdr_check(&db, cp); if (error != 0) - return (error); + goto gpt_cleanup; error = ldm_vmdb_parse(&db, cp); + /* + * For the GPT case we must detach and destroy + * second consumer before return. + */ +gpt_cleanup: + if (table->is_gpt) { + g_topology_lock(); + g_access(cp, -1, 0, 0); + g_detach(cp); + g_destroy_consumer(cp); + g_topology_unlock(); + cp = cp2; + } if (error != 0) return (error); /* Search current disk in the disk list. */ @@ -1408,15 +1422,6 @@ g_part_ldm_read(struct g_part_table *bas ldm_vmdb_free(&db); return (ENXIO); } - if (table->is_gpt) { - /* Second consumer is no longer needed. */ - g_topology_lock(); - g_access(cp, -1, 0, 0); - g_detach(cp); - g_destroy_consumer(cp); - g_topology_unlock(); - cp = cp2; - } index = 1; LIST_FOREACH(vol, &db.volumes, entry) { LIST_FOREACH(comp, &vol->components, entry) { Modified: stable/9/sys/modules/geom/geom_part/Makefile ============================================================================== --- stable/9/sys/modules/geom/geom_part/Makefile Wed Apr 18 04:39:37 2012 (r234405) +++ stable/9/sys/modules/geom/geom_part/Makefile Wed Apr 18 04:59:47 2012 (r234406) @@ -4,6 +4,7 @@ SUBDIR= geom_part_apm \ geom_part_bsd \ geom_part_ebr \ geom_part_gpt \ + geom_part_ldm \ geom_part_mbr \ geom_part_pc98 \ geom_part_vtoc8 From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 05:00:26 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 99AF21065700; Wed, 18 Apr 2012 05:00:26 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 82A508FC15; Wed, 18 Apr 2012 05:00:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I50Qwf015312; Wed, 18 Apr 2012 05:00:26 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I50QsR015306; Wed, 18 Apr 2012 05:00:26 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180500.q3I50QsR015306@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 05:00:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234407 - in stable/8/sys: conf geom/part modules/geom/geom_part modules/geom/geom_part/geom_part_ldm X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 05:00:26 -0000 Author: ae Date: Wed Apr 18 05:00:25 2012 New Revision: 234407 URL: http://svn.freebsd.org/changeset/base/234407 Log: MFC r233176: Add new GEOM_PART_LDM module that implements the Logical Disk Manager scheme. The LDM is a logical volume manager for MS Windows NT and it is also known as dynamic volumes. It supports about 2000 partitions and also provides the capability for software RAID implementations. This version implements only partitioning scheme capability and based on the linux-ntfs project documentation and several publications across the Web. NOTE: JBOD, RAID0 and RAID5 volumes aren't supported. An access to the LDM metadata is read-only. When LDM is on the disk partitioned with MBR we can also destroy metadata. For the GPT partitioned disks destroy action is not supported. MFC r233177: Connect geom_part_ldm module to the build. MFC r233178: Connect geom_part_ldm to the kernel build. MFC r233181: Add CTLFLAG_TUN to sysctls. MFC r233651: Do proper cleanup for the GPT case when an error occurs. MFC r233652: VMDB offset should be greater than logical volume size only for MBR. Added: stable/8/sys/geom/part/g_part_ldm.c - copied, changed from r233176, head/sys/geom/part/g_part_ldm.c stable/8/sys/modules/geom/geom_part/geom_part_ldm/ - copied from r233177, head/sys/modules/geom/geom_part/geom_part_ldm/ Modified: stable/8/sys/conf/NOTES stable/8/sys/conf/files stable/8/sys/conf/options stable/8/sys/modules/geom/geom_part/Makefile Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/conf/NOTES ============================================================================== --- stable/8/sys/conf/NOTES Wed Apr 18 04:59:47 2012 (r234406) +++ stable/8/sys/conf/NOTES Wed Apr 18 05:00:25 2012 (r234407) @@ -150,6 +150,7 @@ options GEOM_PART_BSD # BSD disklabel options GEOM_PART_EBR # Extended Boot Records options GEOM_PART_EBR_COMPAT # Backward compatible partition names options GEOM_PART_GPT # GPT partitioning +options GEOM_PART_LDM # Logical Disk Manager options GEOM_PART_MBR # MBR partitioning options GEOM_PART_PC98 # PC-9800 disk partitioning options GEOM_PART_VTOC8 # SMI VTOC8 disk label Modified: stable/8/sys/conf/files ============================================================================== --- stable/8/sys/conf/files Wed Apr 18 04:59:47 2012 (r234406) +++ stable/8/sys/conf/files Wed Apr 18 05:00:25 2012 (r234407) @@ -2054,6 +2054,7 @@ geom/part/g_part_apm.c optional geom_pa geom/part/g_part_bsd.c optional geom_part_bsd geom/part/g_part_ebr.c optional geom_part_ebr geom/part/g_part_gpt.c optional geom_part_gpt +geom/part/g_part_ldm.c optional geom_part_ldm geom/part/g_part_mbr.c optional geom_part_mbr geom/part/g_part_pc98.c optional geom_part_pc98 geom/part/g_part_vtoc8.c optional geom_part_vtoc8 Modified: stable/8/sys/conf/options ============================================================================== --- stable/8/sys/conf/options Wed Apr 18 04:59:47 2012 (r234406) +++ stable/8/sys/conf/options Wed Apr 18 05:00:25 2012 (r234407) @@ -96,6 +96,7 @@ GEOM_PART_BSD opt_geom.h GEOM_PART_EBR opt_geom.h GEOM_PART_EBR_COMPAT opt_geom.h GEOM_PART_GPT opt_geom.h +GEOM_PART_LDM opt_geom.h GEOM_PART_MBR opt_geom.h GEOM_PART_PC98 opt_geom.h GEOM_PART_VTOC8 opt_geom.h Copied and modified: stable/8/sys/geom/part/g_part_ldm.c (from r233176, head/sys/geom/part/g_part_ldm.c) ============================================================================== --- head/sys/geom/part/g_part_ldm.c Mon Mar 19 13:14:44 2012 (r233176, copy source) +++ stable/8/sys/geom/part/g_part_ldm.c Wed Apr 18 05:00:25 2012 (r234407) @@ -56,8 +56,8 @@ static SYSCTL_NODE(_kern_geom_part, OID_ static u_int ldm_debug = 0; TUNABLE_INT("kern.geom.part.ldm.debug", &ldm_debug); -SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, debug, CTLFLAG_RW, - &ldm_debug, 0, "Debug level"); +SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, debug, + CTLFLAG_RW | CTLFLAG_TUN, &ldm_debug, 0, "Debug level"); /* * This allows access to mirrored LDM volumes. Since we do not @@ -65,8 +65,8 @@ SYSCTL_UINT(_kern_geom_part_ldm, OID_AUT */ static u_int show_mirrors = 0; TUNABLE_INT("kern.geom.part.ldm.show_mirrors", &show_mirrors); -SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, show_mirrors, CTLFLAG_RW, - &show_mirrors, 0, "Show mirrored volumes"); +SYSCTL_UINT(_kern_geom_part_ldm, OID_AUTO, show_mirrors, + CTLFLAG_RW | CTLFLAG_TUN, &show_mirrors, 0, "Show mirrored volumes"); #define LDM_DEBUG(lvl, fmt, ...) do { \ if (ldm_debug >= (lvl)) { \ @@ -495,7 +495,7 @@ ldm_privhdr_check(struct ldm_db *db, str g_free(buf); if (hdr.start > last || hdr.start + hdr.size - 1 > last || - (hdr.start + hdr.size - 1 > hdr.db_offset && is_gpt) || + (hdr.start + hdr.size - 1 > hdr.db_offset && !is_gpt) || hdr.db_size != LDM_DB_SIZE || hdr.db_offset + LDM_DB_SIZE - 1 > last || hdr.th_offset[0] >= LDM_DB_SIZE || @@ -1371,14 +1371,15 @@ g_part_ldm_read(struct g_part_table *bas /* Read and parse LDM private headers. */ error = ldm_privhdr_check(&db, cp, table->is_gpt); if (error != 0) - return (error); + goto gpt_cleanup; basetable->gpt_first = table->is_gpt ? 0: db.ph.start; basetable->gpt_last = basetable->gpt_first + db.ph.size - 1; table->db_offset = db.ph.db_offset; /* Make additional checks for GPT */ if (table->is_gpt) { - if (ldm_gpt_check(&db, cp) != 0) - return (ENXIO); + error = ldm_gpt_check(&db, cp); + if (error != 0) + goto gpt_cleanup; /* * Now we should reset database offset to zero, because our * consumer cp is attached to the ms-ldm-metadata partition @@ -1389,12 +1390,25 @@ g_part_ldm_read(struct g_part_table *bas /* Read and parse LDM TOC headers. */ error = ldm_tochdr_check(&db, cp); if (error != 0) - return (error); + goto gpt_cleanup; /* Read and parse LDM VMDB header. */ error = ldm_vmdbhdr_check(&db, cp); if (error != 0) - return (error); + goto gpt_cleanup; error = ldm_vmdb_parse(&db, cp); + /* + * For the GPT case we must detach and destroy + * second consumer before return. + */ +gpt_cleanup: + if (table->is_gpt) { + g_topology_lock(); + g_access(cp, -1, 0, 0); + g_detach(cp); + g_destroy_consumer(cp); + g_topology_unlock(); + cp = cp2; + } if (error != 0) return (error); /* Search current disk in the disk list. */ @@ -1408,15 +1422,6 @@ g_part_ldm_read(struct g_part_table *bas ldm_vmdb_free(&db); return (ENXIO); } - if (table->is_gpt) { - /* Second consumer is no longer needed. */ - g_topology_lock(); - g_access(cp, -1, 0, 0); - g_detach(cp); - g_destroy_consumer(cp); - g_topology_unlock(); - cp = cp2; - } index = 1; LIST_FOREACH(vol, &db.volumes, entry) { LIST_FOREACH(comp, &vol->components, entry) { Modified: stable/8/sys/modules/geom/geom_part/Makefile ============================================================================== --- stable/8/sys/modules/geom/geom_part/Makefile Wed Apr 18 04:59:47 2012 (r234406) +++ stable/8/sys/modules/geom/geom_part/Makefile Wed Apr 18 05:00:25 2012 (r234407) @@ -4,6 +4,7 @@ SUBDIR= geom_part_apm \ geom_part_bsd \ geom_part_ebr \ geom_part_gpt \ + geom_part_ldm \ geom_part_mbr \ geom_part_pc98 \ geom_part_vtoc8 From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 05:11:52 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id ED396106566B; Wed, 18 Apr 2012 05:11:52 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CDDF58FC0C; Wed, 18 Apr 2012 05:11:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I5Bq4p015725; Wed, 18 Apr 2012 05:11:52 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I5Bq59015723; Wed, 18 Apr 2012 05:11:52 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180511.q3I5Bq59015723@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 05:11:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234408 - stable/9/sbin/geom/class/part X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 05:11:53 -0000 Author: ae Date: Wed Apr 18 05:11:52 2012 New Revision: 234408 URL: http://svn.freebsd.org/changeset/base/234408 Log: MFC r233179: Document GEOM_PART_LDM scheme and partition types. Modified: stable/9/sbin/geom/class/part/gpart.8 Directory Properties: stable/9/sbin/geom/class/part/ (props changed) Modified: stable/9/sbin/geom/class/part/gpart.8 ============================================================================== --- stable/9/sbin/geom/class/part/gpart.8 Wed Apr 18 05:00:25 2012 (r234407) +++ stable/9/sbin/geom/class/part/gpart.8 Wed Apr 18 05:11:52 2012 (r234408) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 8, 2012 +.Dd March 19, 2012 .Dt GPART 8 .Os .Sh NAME @@ -38,6 +38,7 @@ lines in the kernel configuration file: .Cd "options GEOM_PART_APM" .Cd "options GEOM_PART_BSD" .Cd "options GEOM_PART_GPT" +.Cd "options GEOM_PART_LDM" .Cd "options GEOM_PART_MBR" .Cd "options GEOM_PART_EBR" .Cd "options GEOM_PART_EBR_COMPAT" @@ -511,6 +512,12 @@ called Requires the .Cm GEOM_PART_BSD kernel option. +.It Cm LDM +The Logical Disk Manager is an implementation of volume manager for +Microsoft Windows NT. +Requires the +.Cd GEOM_PART_LDM +kernel option. .It Cm GPT GUID Partition Table is used on Intel-based Macintosh computers and gradually replacing MBR on most PCs and other systems. @@ -559,7 +566,7 @@ The utility also allows the user to specify scheme-specific partition types for partition types that do not have symbolic names. Symbolic names currently understood are: -.Bl -tag -width ".Cm freebsd-vinum" +.Bl -tag -width ".Cm ms-ldm-metadata" .It Cm bios-boot The system partition dedicated to second stage of the boot loader program. Usually it is used by the GRUB 2 loader for GPT partitioning schemes. @@ -634,6 +641,18 @@ A partition that is sub-partitioned by a This type is known as .Qq Li "!024dee41-33e7-11d3-9d69-0008c781f39f" by GPT. +.It Cm ms-ldm-data +A partition that contains Logical Disk Manager (LDM) volumes. +The scheme-specific types are +.Qq Li "!66" +for MBR, +.Qq Li "!af9b60a0-1431-4f62-bc68-3311714a69ad" +for GPT. +.It Cm ms-ldm-metadata +A partition that contains Logical Disk Manager (LDM) database. +The scheme-specifig type is +.Qq Li "!5808c8aa-7e8f-42e0-85d2-e1e90434cfb3" +for GPT. .El .Sh ATTRIBUTES The scheme-specific attributes for EBR: @@ -938,6 +957,23 @@ disk metadata. If some inconsistency is detected, the partition table will be rejected with a diagnostic message: .Sy "GEOM_PART: Integrity check failed (provider, scheme)" . +.It Va kern.geom.part.ldm.debug : No 0 +Debug level of the Logical Disk Manager (LDM) module. +This can be set to a number between 0 and 2 inclusive. +If set to 0 minimal debug information is printed, +and if set to 2 the maximum amount of debug information is printed. +.It Va kern.geom.part.ldm.show_mirrors : No 0 +This variable controls how the Logical Disk Manager (LDM) module handles +mirrored volumes. +By default mirrored volumes are shown as partitions with type +.Cm ms-ldm-data +(see the +.Sx "PARTITION TYPES" +section). +If this variable set to 1 each component of the mirrored volume will be +present as independet partition. +.Em NOTE : +This may break a mirrored volume and lead to data damage. .El .Sh EXIT STATUS Exit status is 0 on success, and 1 if the command fails. From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 05:12:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 34BF11065780; Wed, 18 Apr 2012 05:12:18 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 15C898FC14; Wed, 18 Apr 2012 05:12:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I5CHZD015777; Wed, 18 Apr 2012 05:12:17 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I5CHmY015775; Wed, 18 Apr 2012 05:12:17 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180512.q3I5CHmY015775@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 05:12:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234409 - stable/8/sbin/geom/class/part X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 05:12:18 -0000 Author: ae Date: Wed Apr 18 05:12:17 2012 New Revision: 234409 URL: http://svn.freebsd.org/changeset/base/234409 Log: MFC r233179: Document GEOM_PART_LDM scheme and partition types. Modified: stable/8/sbin/geom/class/part/gpart.8 Directory Properties: stable/8/sbin/geom/class/part/ (props changed) Modified: stable/8/sbin/geom/class/part/gpart.8 ============================================================================== --- stable/8/sbin/geom/class/part/gpart.8 Wed Apr 18 05:11:52 2012 (r234408) +++ stable/8/sbin/geom/class/part/gpart.8 Wed Apr 18 05:12:17 2012 (r234409) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 8, 2012 +.Dd March 19, 2012 .Dt GPART 8 .Os .Sh NAME @@ -38,6 +38,7 @@ lines in the kernel configuration file: .Cd "options GEOM_PART_APM" .Cd "options GEOM_PART_BSD" .Cd "options GEOM_PART_GPT" +.Cd "options GEOM_PART_LDM" .Cd "options GEOM_PART_MBR" .Cd "options GEOM_PART_EBR" .Cd "options GEOM_PART_EBR_COMPAT" @@ -511,6 +512,12 @@ called Requires the .Cm GEOM_PART_BSD kernel option. +.It Cm LDM +The Logical Disk Manager is an implementation of volume manager for +Microsoft Windows NT. +Requires the +.Cd GEOM_PART_LDM +kernel option. .It Cm GPT GUID Partition Table is used on Intel-based Macintosh computers and gradually replacing MBR on most PCs and other systems. @@ -559,7 +566,7 @@ The utility also allows the user to specify scheme-specific partition types for partition types that do not have symbolic names. Symbolic names currently understood are: -.Bl -tag -width ".Cm freebsd-vinum" +.Bl -tag -width ".Cm ms-ldm-metadata" .It Cm bios-boot The system partition dedicated to second stage of the boot loader program. Usually it is used by the GRUB 2 loader for GPT partitioning schemes. @@ -634,6 +641,18 @@ A partition that is sub-partitioned by a This type is known as .Qq Li "!024dee41-33e7-11d3-9d69-0008c781f39f" by GPT. +.It Cm ms-ldm-data +A partition that contains Logical Disk Manager (LDM) volumes. +The scheme-specific types are +.Qq Li "!66" +for MBR, +.Qq Li "!af9b60a0-1431-4f62-bc68-3311714a69ad" +for GPT. +.It Cm ms-ldm-metadata +A partition that contains Logical Disk Manager (LDM) database. +The scheme-specifig type is +.Qq Li "!5808c8aa-7e8f-42e0-85d2-e1e90434cfb3" +for GPT. .El .Sh ATTRIBUTES The scheme-specific attributes for EBR: @@ -938,6 +957,23 @@ disk metadata. If some inconsistency is detected, the partition table will be rejected with a diagnostic message: .Sy "GEOM_PART: Integrity check failed (provider, scheme)" . +.It Va kern.geom.part.ldm.debug : No 0 +Debug level of the Logical Disk Manager (LDM) module. +This can be set to a number between 0 and 2 inclusive. +If set to 0 minimal debug information is printed, +and if set to 2 the maximum amount of debug information is printed. +.It Va kern.geom.part.ldm.show_mirrors : No 0 +This variable controls how the Logical Disk Manager (LDM) module handles +mirrored volumes. +By default mirrored volumes are shown as partitions with type +.Cm ms-ldm-data +(see the +.Sx "PARTITION TYPES" +section). +If this variable set to 1 each component of the mirrored volume will be +present as independet partition. +.Em NOTE : +This may break a mirrored volume and lead to data damage. .El .Sh EXIT STATUS Exit status is 0 on success, and 1 if the command fails. From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 05:16:03 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2E1F8106566C; Wed, 18 Apr 2012 05:16:03 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 18C158FC16; Wed, 18 Apr 2012 05:16:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I5G23U015951; Wed, 18 Apr 2012 05:16:02 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I5G2NG015949; Wed, 18 Apr 2012 05:16:02 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180516.q3I5G2NG015949@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 05:16:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234410 - stable/9/sbin/bsdlabel X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 05:16:03 -0000 Author: ae Date: Wed Apr 18 05:16:02 2012 New Revision: 234410 URL: http://svn.freebsd.org/changeset/base/234410 Log: MFC r234122: It seems that libdisk(3) incorrectly sets d_secperunit value. Automatically fix it like GEOM_PART_BSD does. PR: bin/165789 Modified: stable/9/sbin/bsdlabel/bsdlabel.c Directory Properties: stable/9/sbin/bsdlabel/ (props changed) Modified: stable/9/sbin/bsdlabel/bsdlabel.c ============================================================================== --- stable/9/sbin/bsdlabel/bsdlabel.c Wed Apr 18 05:12:17 2012 (r234409) +++ stable/9/sbin/bsdlabel/bsdlabel.c Wed Apr 18 05:16:02 2012 (r234410) @@ -1194,7 +1194,8 @@ checklabel(struct disklabel *lp) lp->d_interleave = vl->d_interleave; if (lp->d_secpercyl == 0) lp->d_secpercyl = vl->d_secpercyl; - if (lp->d_secperunit == 0) + if (lp->d_secperunit == 0 || + lp->d_secperunit > vl->d_secperunit) lp->d_secperunit = vl->d_secperunit; if (lp->d_bbsize == 0) lp->d_bbsize = vl->d_bbsize; From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 05:16:20 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CE60A10657EA; Wed, 18 Apr 2012 05:16:20 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B92528FC19; Wed, 18 Apr 2012 05:16:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I5GKO6015994; Wed, 18 Apr 2012 05:16:20 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I5GKhd015992; Wed, 18 Apr 2012 05:16:20 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201204180516.q3I5GKhd015992@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Wed, 18 Apr 2012 05:16:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234411 - stable/8/sbin/bsdlabel X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 05:16:20 -0000 Author: ae Date: Wed Apr 18 05:16:20 2012 New Revision: 234411 URL: http://svn.freebsd.org/changeset/base/234411 Log: MFC r234122: It seems that libdisk(3) incorrectly sets d_secperunit value. Automatically fix it like GEOM_PART_BSD does. PR: bin/165789 Modified: stable/8/sbin/bsdlabel/bsdlabel.c Directory Properties: stable/8/sbin/bsdlabel/ (props changed) Modified: stable/8/sbin/bsdlabel/bsdlabel.c ============================================================================== --- stable/8/sbin/bsdlabel/bsdlabel.c Wed Apr 18 05:16:02 2012 (r234410) +++ stable/8/sbin/bsdlabel/bsdlabel.c Wed Apr 18 05:16:20 2012 (r234411) @@ -1187,7 +1187,8 @@ checklabel(struct disklabel *lp) lp->d_interleave = vl->d_interleave; if (lp->d_secpercyl == 0) lp->d_secpercyl = vl->d_secpercyl; - if (lp->d_secperunit == 0) + if (lp->d_secperunit == 0 || + lp->d_secperunit > vl->d_secperunit) lp->d_secperunit = vl->d_secperunit; if (lp->d_bbsize == 0) lp->d_bbsize = vl->d_bbsize; From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 07:02:54 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 40B0A1065679; Wed, 18 Apr 2012 07:02:54 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2BDE48FC15; Wed, 18 Apr 2012 07:02:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I72s0d019259; Wed, 18 Apr 2012 07:02:54 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I72rpC019257; Wed, 18 Apr 2012 07:02:53 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201204180702.q3I72rpC019257@svn.freebsd.org> From: Sergey Kandaurov Date: Wed, 18 Apr 2012 07:02:53 +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: r234412 - head/lib/libkse X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 07:02:54 -0000 Author: pluknet Date: Wed Apr 18 07:02:53 2012 New Revision: 234412 URL: http://svn.freebsd.org/changeset/base/234412 Log: Fix typo in ".PATH" Modified: head/lib/libkse/Makefile Modified: head/lib/libkse/Makefile ============================================================================== --- head/lib/libkse/Makefile Wed Apr 18 05:16:20 2012 (r234411) +++ head/lib/libkse/Makefile Wed Apr 18 07:02:53 2012 (r234412) @@ -38,7 +38,7 @@ SYMBOL_MAPS=${.CURDIR}/kse.map PRECIOUSLIB= -.path: ${.CURDIR}/arch/${MACHINE_CPUARCH}/${MACHINE_CPUARCH} +.PATH: ${.CURDIR}/arch/${MACHINE_CPUARCH}/${MACHINE_CPUARCH} .include "${.CURDIR}/arch/${MACHINE_CPUARCH}/Makefile.inc" .include "${.CURDIR}/support/Makefile.inc" From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 08:15:56 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8E3641065672; Wed, 18 Apr 2012 08:15:56 +0000 (UTC) (envelope-from hrs@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 76F548FC0C; Wed, 18 Apr 2012 08:15:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I8FufV021614; Wed, 18 Apr 2012 08:15:56 GMT (envelope-from hrs@svn.freebsd.org) Received: (from hrs@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I8Fu5g021609; Wed, 18 Apr 2012 08:15:56 GMT (envelope-from hrs@svn.freebsd.org) Message-Id: <201204180815.q3I8Fu5g021609@svn.freebsd.org> From: Hiroki Sato Date: Wed, 18 Apr 2012 08:15:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234413 - in stable/8/release/doc: en_US.ISO8859-1 en_US.ISO8859-1/installation share/sgml X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 08:15:56 -0000 Author: hrs Date: Wed Apr 18 08:15:55 2012 New Revision: 234413 URL: http://svn.freebsd.org/changeset/base/234413 Log: Add installation/upgrade instructions for 8.3R. Added: stable/8/release/doc/en_US.ISO8859-1/installation/ stable/8/release/doc/en_US.ISO8859-1/installation/Makefile (contents, props changed) stable/8/release/doc/en_US.ISO8859-1/installation/article.sgml (contents, props changed) Modified: stable/8/release/doc/en_US.ISO8859-1/Makefile stable/8/release/doc/share/sgml/release.ent Modified: stable/8/release/doc/en_US.ISO8859-1/Makefile ============================================================================== --- stable/8/release/doc/en_US.ISO8859-1/Makefile Wed Apr 18 07:02:53 2012 (r234412) +++ stable/8/release/doc/en_US.ISO8859-1/Makefile Wed Apr 18 08:15:55 2012 (r234413) @@ -6,6 +6,7 @@ SUBDIR = relnotes SUBDIR+= hardware SUBDIR+= readme SUBDIR+= errata +SUBDIR+= installation COMPAT_SYMLINK = en Added: stable/8/release/doc/en_US.ISO8859-1/installation/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/8/release/doc/en_US.ISO8859-1/installation/Makefile Wed Apr 18 08:15:55 2012 (r234413) @@ -0,0 +1,19 @@ +# $FreeBSD$ + +RELN_ROOT?= ${.CURDIR}/../.. +.ifdef NO_LANGCODE_IN_DESTDIR +DESTDIR?= ${DOCDIR}/installation +.else +DESTDIR?= ${DOCDIR}/en_US.ISO8859-1/installation +.endif + +DOC?= article +FORMATS?= html +INSTALL_COMPRESSED?= gz +INSTALL_ONLY_COMPRESSED?= + +# SGML content +SRCS+= article.sgml + +.include "${RELN_ROOT}/share/mk/doc.relnotes.mk" +.include "${DOC_PREFIX}/share/mk/doc.project.mk" Added: stable/8/release/doc/en_US.ISO8859-1/installation/article.sgml ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/8/release/doc/en_US.ISO8859-1/installation/article.sgml Wed Apr 18 08:15:55 2012 (r234413) @@ -0,0 +1,111 @@ + +%articles.ent; + + +%release; +]> + +
+ + &os; &release.current; Installation Instructions + + The &os; Project + + $FreeBSD$ + + + 2012 + + The &os; Documentation Project + + + + &tm-attrib.freebsd; + &tm-attrib.intel; + &tm-attrib.sparc; + &tm-attrib.general; + + + + + This article gives some brief instructions on installing + &os; &release.current; and upgrading the systems running earlier + releases. + + + + Installing &os; + + For instructions on installing FreeBSD, please see Chapter 2 + of The FreeBSD Handbook. It provides a complete installation + walk-through for users new to FreeBSD, and can be found online + at: + + + + Upgrading &os; + + + Upgrading from Source + + The procedure for doing a source code based update is + described in + and + . + + The branch tag to use for updating the source is + RELENG_8_3 for CVS. For SVN use + releng/8.3. + + + + Upgrading Using <quote>&os; Update</quote> + + The &man.freebsd-update.8; utility supports binary + upgrades of &arch.i386; and &arch.amd64; systems running + earlier FreeBSD releases. Systems running + 7.[01234]-RELEASE, + 8.[012]-RELEASE, + 8.3-BETA1, or + 8.3-RC[12] can upgrade as follows: + + &prompt.root; freebsd-update upgrade -r 8.3-RELEASE + + During this process, FreeBSD Update may ask the user to + help by merging some configuration files or by confirming that + the automatically performed merging was done correctly. + + &prompt.root; freebsd-update install + + The system must be rebooted with the newly installed + kernel before continuing. + + &prompt.root; shutdown -r now + + After rebooting, &man.freebsd-update.8; needs to be run + again to install the new userland components: + + &prompt.root; freebsd-update install + + At this point, users of systems being upgraded from + FreeBSD 7.4-RELEASE or earlier will be prompted by + freebsd-update to rebuild all third-party applications (e.g., + ports installed from the ports tree) due to updates in system + libraries. + + After updating installed third-party applications (and + again, only if &man.freebsd-update.8; printed a message + indicating that this was necessary), run + &man.freebsd-update.8; again so that it can delete the old (no + longer used) system libraries: + + &prompt.root; freebsd-update install + + Finally, reboot into &release.current; + + &prompt.root; shutdown -r now + + +
Modified: stable/8/release/doc/share/sgml/release.ent ============================================================================== --- stable/8/release/doc/share/sgml/release.ent Wed Apr 18 07:02:53 2012 (r234412) +++ stable/8/release/doc/share/sgml/release.ent Wed Apr 18 08:15:55 2012 (r234413) @@ -6,18 +6,18 @@ - + - + - + - + From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 08:33:03 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 98C46106566C; Wed, 18 Apr 2012 08:33:03 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from mail-lpp01m010-f54.google.com (mail-lpp01m010-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id B101F8FC17; Wed, 18 Apr 2012 08:33:02 +0000 (UTC) Received: by lagv3 with SMTP id v3so6911996lag.13 for ; Wed, 18 Apr 2012 01:32:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type :content-transfer-encoding; bh=ZQUOKg1vX1qiRAdSUPvCaF6oKhtmn/dfMb8I9HMrCMk=; b=KC8gaEQdGiIFTvIiZJG/aoPrtWWo9qirDGZwWlHvIAXKX3i8jh5Fo2YIwHC6mKMhP5 WUhdSwLZyUfDC8AvksZBjYIFLuaFoaMEeYdqLda7gtGOq9zBTRKm7Fe6o486uz6MZh+j fsiucNmGmEA93yoevd0Tts0ut+5awazOtv1DPgrOr4ef8IC9VEU49JE+wONbFGxrKgGr fRwbRcuU/nFJHeVpAJsuTiG7YYtBeeDnV0R9mQs0HDSvgyXkHH/oUsVYEUjm70NZyL6K uiu8LQA6HP4hStq4W9IMFAJJHvwKkMLVHYhgfvXWkF6Z2c//tmcBdaSe2z98If3+DFj4 9Ycw== MIME-Version: 1.0 Received: by 10.152.127.136 with SMTP id ng8mr1290709lab.16.1334737976063; Wed, 18 Apr 2012 01:32:56 -0700 (PDT) Sender: pluknet@gmail.com Received: by 10.152.25.69 with HTTP; Wed, 18 Apr 2012 01:32:56 -0700 (PDT) In-Reply-To: <201204180702.q3I72rpC019257@svn.freebsd.org> References: <201204180702.q3I72rpC019257@svn.freebsd.org> Date: Wed, 18 Apr 2012 12:32:56 +0400 X-Google-Sender-Auth: INSVrUjMewb14mWlVp5CJusn160 Message-ID: From: Sergey Kandaurov To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: Subject: Re: svn commit: r234412 - head/lib/libkse X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 08:33:03 -0000 On 18 April 2012 11:02, Sergey Kandaurov wrote: > Author: pluknet > Date: Wed Apr 18 07:02:53 2012 > New Revision: 234412 > URL: http://svn.freebsd.org/changeset/base/234412 > > Log: > =A0Fix typo in ".PATH" > > Modified: > =A0head/lib/libkse/Makefile > Since kernel part of KSE has gone in r177091, any reason to keep it in tree= ? --=20 wbr, pluknet From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 08:55:27 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2517C1065670; Wed, 18 Apr 2012 08:55:27 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 107898FC0C; Wed, 18 Apr 2012 08:55:27 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I8tQrl022830; Wed, 18 Apr 2012 08:55:26 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I8tQWd022827; Wed, 18 Apr 2012 08:55:26 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201204180855.q3I8tQWd022827@svn.freebsd.org> From: Alexander Motin Date: Wed, 18 Apr 2012 08:55: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: r234414 - head/sys/cam/ata X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 08:55:27 -0000 Author: mav Date: Wed Apr 18 08:55:26 2012 New Revision: 234414 URL: http://svn.freebsd.org/changeset/base/234414 Log: Alike to SCSI make adaclose() to not return error if device gone. This fixes KASSERT panic inside GEOM if kernel built with INVARIANTS. MFC after: 1 week Modified: head/sys/cam/ata/ata_da.c Modified: head/sys/cam/ata/ata_da.c ============================================================================== --- head/sys/cam/ata/ata_da.c Wed Apr 18 08:15:55 2012 (r234413) +++ head/sys/cam/ata/ata_da.c Wed Apr 18 08:55:26 2012 (r234414) @@ -456,17 +456,16 @@ adaclose(struct disk *dp) struct cam_periph *periph; struct ada_softc *softc; union ccb *ccb; - int error; periph = (struct cam_periph *)dp->d_drv1; if (periph == NULL) return (ENXIO); cam_periph_lock(periph); - if ((error = cam_periph_hold(periph, PRIBIO)) != 0) { + if (cam_periph_hold(periph, PRIBIO) != 0) { cam_periph_unlock(periph); cam_periph_release(periph); - return (error); + return (0); } softc = (struct ada_softc *)periph->softc; From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 09:42:15 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2B83D106566B; Wed, 18 Apr 2012 09:42:15 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0D0ED8FC0A; Wed, 18 Apr 2012 09:42:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3I9gEhK024371; Wed, 18 Apr 2012 09:42:14 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3I9gEo9024367; Wed, 18 Apr 2012 09:42:14 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201204180942.q3I9gEo9024367@svn.freebsd.org> From: Alexander Motin Date: Wed, 18 Apr 2012 09:42: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: r234415 - in head: sbin/geom/class/multipath sys/geom/multipath X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 09:42:15 -0000 Author: mav Date: Wed Apr 18 09:42:14 2012 New Revision: 234415 URL: http://svn.freebsd.org/changeset/base/234415 Log: Some improvements to GEOM MULTIPATH: - Implement "configure" command to allow switching operation mode of running device on-fly without destroying and recreation. - Implement Active/Read mode as hybrid of Active/Active and Active/Passive. In this mode all paths not marked FAIL may handle reads same time, but unlike Active/Active only one path handles write requests at any point in time. It allows to closer follow original write request order if above layers need it for data consistency (not waiting for requisite write completion before sending dependent write). - Hide duplicate messages about device status change. - Remove periodic thread wake up with 10Hz rate. MFC after: 2 weeks Sponsored by: iXsystems, Inc. Modified: head/sbin/geom/class/multipath/geom_multipath.c head/sbin/geom/class/multipath/gmultipath.8 head/sys/geom/multipath/g_multipath.c Modified: head/sbin/geom/class/multipath/geom_multipath.c ============================================================================== --- head/sbin/geom/class/multipath/geom_multipath.c Wed Apr 18 08:55:26 2012 (r234414) +++ head/sbin/geom/class/multipath/geom_multipath.c Wed Apr 18 09:42:14 2012 (r234415) @@ -55,17 +55,28 @@ struct g_command class_commands[] = { "create", G_FLAG_VERBOSE | G_FLAG_LOADKLD, NULL, { { 'A', "active_active", NULL, G_TYPE_BOOL }, + { 'R', "active_read", NULL, G_TYPE_BOOL }, G_OPT_SENTINEL }, - "[-vA] name prov ..." + "[-vAR] name prov ..." }, { "label", G_FLAG_VERBOSE | G_FLAG_LOADKLD, mp_main, { { 'A', "active_active", NULL, G_TYPE_BOOL }, + { 'R', "active_read", NULL, G_TYPE_BOOL }, G_OPT_SENTINEL }, - "[-vA] name prov ..." + "[-vAR] name prov ..." + }, + { "configure", G_FLAG_VERBOSE, NULL, + { + { 'A', "active_active", NULL, G_TYPE_BOOL }, + { 'P', "active_passive", NULL, G_TYPE_BOOL }, + { 'R', "active_read", NULL, G_TYPE_BOOL }, + G_OPT_SENTINEL + }, + "[-vAPR] name" }, { "add", G_FLAG_VERBOSE, NULL, G_NULL_OPTS, @@ -196,6 +207,8 @@ mp_label(struct gctl_req *req) } strlcpy(md.md_uuid, ptr, sizeof (md.md_uuid)); md.md_active_active = gctl_get_int(req, "active_active"); + if (gctl_get_int(req, "active_read")) + md.md_active_active = 2; free(ptr); /* Modified: head/sbin/geom/class/multipath/gmultipath.8 ============================================================================== --- head/sbin/geom/class/multipath/gmultipath.8 Wed Apr 18 08:55:26 2012 (r234414) +++ head/sbin/geom/class/multipath/gmultipath.8 Wed Apr 18 09:42:14 2012 (r234415) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 31, 2011 +.Dd April 18, 2012 .Dt GMULTIPATH 8 .Os .Sh NAME @@ -33,15 +33,19 @@ .Sh SYNOPSIS .Nm .Cm create -.Op Fl Av +.Op Fl ARv .Ar name .Ar prov ... .Nm .Cm label -.Op Fl Av +.Op Fl ARv .Ar name .Ar prov ... .Nm +.Cm configure +.Op Fl APRv +.Ar name +.Nm .Cm add .Op Fl v .Ar name prov @@ -121,7 +125,9 @@ Kernel will only check that all given pr sector sizes. .Pp .Fl A -option enables Active/Active mode, otherwise Active/Passive mode is used +option enables Active/Active mode, +.Fl R +option enables Active/Read mode, otherwise Active/Passive mode is used by default. .It Cm label Create multipath device with @@ -134,8 +140,19 @@ It reliably protects against specifying Providers with no matching metadata detected will not be added to the device. .Pp .Fl A -option enables Active/Active mode, otherwise Active/Passive mode is used +option enables Active/Active mode, +.Fl R +option enables Active/Read mode, otherwise Active/Passive mode is used by default. +.It Cm configure +Configure the given multipath device. +.Pp +.Fl A +option enables Active/Active mode, +.Fl P +option enables Active/Passive mode, +.Fl R +option enables Active/Read mode. .It Cm add Add the given provider as a path to the given multipath device. Should normally be used only for devices created with @@ -221,7 +238,8 @@ of multiple pathnames refer to the same system operator who will use tools and knowledge of their own storage subsystem to make the correct configuration selection. .Pp -There are Active/Passive and Active/Active operation modes supported. +There are Active/Passive, Active/Read and Active/Active operation modes +supported. In Active/Passive mode only one path has I/O moving on it at any point in time. This I/O continues until an I/O is returned with @@ -231,6 +249,12 @@ in a list is selected as active and the In Active/Active mode all paths not marked FAIL may handle I/O same time. Requests are distributed between paths to equalize load. For capable devices it allows to utilize bandwidth of all paths. +In Active/Read mode all paths not marked FAIL may handle reads same time, +but unlike Active/Active only one path handles write requests at any +point in time. +It allows to closer follow original write request order if above layer +needs it for data consistency (not waiting for requisite write completion +before sending dependent write). .Pp When new devices are added to the system the .Nm MULTIPATH Modified: head/sys/geom/multipath/g_multipath.c ============================================================================== --- head/sys/geom/multipath/g_multipath.c Wed Apr 18 08:55:26 2012 (r234414) +++ head/sys/geom/multipath/g_multipath.c Wed Apr 18 09:42:14 2012 (r234415) @@ -151,20 +151,21 @@ g_multipath_fault(struct g_consumer *cp, if (sc->sc_active == NULL) { printf("GEOM_MULTIPATH: out of providers for %s\n", sc->sc_name); - } else if (!sc->sc_active_active) { + } else if (sc->sc_active_active != 1) { printf("GEOM_MULTIPATH: %s is now active path in %s\n", sc->sc_active->provider->name, sc->sc_name); } } static struct g_consumer * -g_multipath_choose(struct g_geom *gp) +g_multipath_choose(struct g_geom *gp, struct bio *bp) { struct g_multipath_softc *sc; struct g_consumer *best, *cp; sc = gp->softc; - if (!sc->sc_active_active) + if (sc->sc_active_active == 0 || + (sc->sc_active_active == 2 && bp->bio_cmd != BIO_READ)) return (sc->sc_active); best = NULL; LIST_FOREACH(cp, &gp->consumer, consumer) { @@ -253,7 +254,7 @@ g_multipath_start(struct bio *bp) return; } mtx_lock(&sc->sc_mtx); - cp = g_multipath_choose(gp); + cp = g_multipath_choose(gp, bp); if (cp == NULL) { mtx_unlock(&sc->sc_mtx); g_destroy_bio(cbp); @@ -323,9 +324,11 @@ g_multipath_done_error(struct bio *bp) cnt = (uintptr_t *)&cp->private; mtx_lock(&sc->sc_mtx); - printf("GEOM_MULTIPATH: Error %d, %s in %s marked FAIL\n", - bp->bio_error, pp->name, sc->sc_name); - g_multipath_fault(cp, MP_FAIL); + if ((cp->index & MP_FAIL) == 0) { + printf("GEOM_MULTIPATH: Error %d, %s in %s marked FAIL\n", + bp->bio_error, pp->name, sc->sc_name); + g_multipath_fault(cp, MP_FAIL); + } (*cnt)--; if (*cnt == 0 && (cp->index & (MP_LOST | MP_POSTED)) == MP_LOST) { cp->index |= MP_POSTED; @@ -363,8 +366,10 @@ g_multipath_kt(void *arg) g_multipath_done_error(bp); mtx_lock(&gmtbq_mtx); } + if (g_multipath_kt_state != GKT_RUN) + break; msleep(&g_multipath_kt_state, &gmtbq_mtx, PRIBIO, - "gkt:wait", hz / 10); + "gkt:wait", 0); } mtx_unlock(&gmtbq_mtx); wakeup(&g_multipath_kt_state); @@ -525,7 +530,7 @@ g_multipath_add_disk(struct g_geom *gp, pp->name, sc->sc_name); if (sc->sc_active == NULL) { sc->sc_active = cp; - if (!sc->sc_active_active) + if (sc->sc_active_active != 1) printf("GEOM_MULTIPATH: %s is now active path in %s\n", pp->name, sc->sc_name); } @@ -599,7 +604,7 @@ g_multipath_rotate(struct g_geom *gp) } if (lcp) { sc->sc_active = lcp; - if (!sc->sc_active_active) + if (sc->sc_active_active != 1) printf("GEOM_MULTIPATH: %s is now active path in %s\n", lcp->provider->name, sc->sc_name); } @@ -611,8 +616,7 @@ g_multipath_init(struct g_class *mp) { bioq_init(&gmtbq); mtx_init(&gmtbq_mtx, "gmtbq", NULL, MTX_DEF); - if (kproc_create(g_multipath_kt, mp, NULL, 0, 0, "g_mp_kt") == 0) - g_multipath_kt_state = GKT_RUN; + kproc_create(g_multipath_kt, mp, NULL, 0, 0, "g_mp_kt"); } static void @@ -879,7 +883,7 @@ g_multipath_ctl_create(struct gctl_req * struct g_geom *gp; const char *mpname, *name; char param[16]; - int *nargs, i, *active_active; + int *nargs, i, *val; g_topology_assert(); @@ -908,10 +912,13 @@ g_multipath_ctl_create(struct gctl_req * md.md_size = 0; md.md_sectorsize = 0; md.md_uuid[0] = 0; - active_active = gctl_get_paraml(req, "active_active", - sizeof(*active_active)); - md.md_active_active = - (active_active == NULL || *active_active == 0) ? 0 : 1; + md.md_active_active = 0; + val = gctl_get_paraml(req, "active_active", sizeof(*val)); + if (val != NULL && *val != 0) + md.md_active_active = 1; + val = gctl_get_paraml(req, "active_read", sizeof(*val)); + if (val != NULL && *val != 0) + md.md_active_active = 2; gp = g_multipath_create(mp, &md); if (gp == NULL) { gctl_error(req, "GEOM_MULTIPATH: cannot create geom %s/%s\n", @@ -931,6 +938,67 @@ g_multipath_ctl_create(struct gctl_req * } static void +g_multipath_ctl_configure(struct gctl_req *req, struct g_class *mp) +{ + struct g_multipath_softc *sc; + struct g_geom *gp; + struct g_consumer *cp; + struct g_provider *pp; + struct g_multipath_metadata *md; + const char *name; + int error, *val; + void *buf; + + g_topology_assert(); + + name = gctl_get_asciiparam(req, "arg0"); + if (name == NULL) { + gctl_error(req, "No 'arg0' argument"); + return; + } + gp = g_multipath_find_geom(mp, name); + if (gp == NULL) { + gctl_error(req, "Device %s is invalid", name); + return; + } + sc = gp->softc; + val = gctl_get_paraml(req, "active_active", sizeof(*val)); + if (val != NULL && *val != 0) + sc->sc_active_active = 1; + val = gctl_get_paraml(req, "active_read", sizeof(*val)); + if (val != NULL && *val != 0) + sc->sc_active_active = 2; + val = gctl_get_paraml(req, "active_passive", sizeof(*val)); + if (val != NULL && *val != 0) + sc->sc_active_active = 0; + if (sc->sc_uuid[0] != 0 && sc->sc_active != NULL) { + cp = sc->sc_active; + pp = cp->provider; + error = g_access(cp, 1, 1, 1); + if (error != 0) { + gctl_error(req, "Can't open %s (%d)", pp->name, error); + return; + } + g_topology_unlock(); + md = buf = g_malloc(pp->sectorsize, M_WAITOK | M_ZERO); + strlcpy(md->md_magic, G_MULTIPATH_MAGIC, sizeof(md->md_magic)); + memcpy(md->md_uuid, sc->sc_uuid, sizeof (sc->sc_uuid)); + strlcpy(md->md_name, name, sizeof(md->md_name)); + md->md_version = G_MULTIPATH_VERSION; + md->md_size = pp->mediasize; + md->md_sectorsize = pp->sectorsize; + md->md_active_active = sc->sc_active_active; + error = g_write_data(cp, pp->mediasize - pp->sectorsize, + buf, pp->sectorsize); + g_topology_lock(); + g_access(cp, -1, -1, -1); + if (error != 0) + gctl_error(req, "Can't update metadata on %s (%d)", + pp->name, error); + } +} + +static void g_multipath_ctl_fail(struct gctl_req *req, struct g_class *mp, int fail) { struct g_multipath_softc *sc; @@ -964,6 +1032,8 @@ g_multipath_ctl_fail(struct gctl_req *re strcmp(cp->provider->name, name) == 0 && (cp->index & MP_LOST) == 0) { found = 1; + if (!fail == !(cp->index & MP_FAIL)) + continue; printf("GEOM_MULTIPATH: %s in %s is marked %s.\n", name, sc->sc_name, fail ? "FAIL" : "OK"); if (fail) { @@ -1172,7 +1242,7 @@ g_multipath_ctl_getactive(struct gctl_re return; } sc = gp->softc; - if (sc->sc_active_active) { + if (sc->sc_active_active == 1) { empty = 1; LIST_FOREACH(cp, &gp->consumer, consumer) { if (cp->index & MP_BAD) @@ -1209,6 +1279,8 @@ g_multipath_config(struct gctl_req *req, g_multipath_ctl_add(req, mp); } else if (strcmp(verb, "create") == 0) { g_multipath_ctl_create(req, mp); + } else if (strcmp(verb, "configure") == 0) { + g_multipath_ctl_configure(req, mp); } else if (strcmp(verb, "stop") == 0) { g_multipath_ctl_stop(req, mp); } else if (strcmp(verb, "destroy") == 0) { @@ -1245,8 +1317,9 @@ g_multipath_dumpconf(struct sbuf *sb, co (cp->index & MP_NEW) ? "NEW" : (cp->index & MP_LOST) ? "LOST" : (cp->index & MP_FAIL) ? "FAIL" : - (sc->sc_active_active || sc->sc_active == cp) ? - "ACTIVE" : "PASSIVE"); + (sc->sc_active_active == 1 || sc->sc_active == cp) ? + "ACTIVE" : + sc->sc_active_active == 2 ? "READ" : "PASSIVE"); } else { good = g_multipath_good(gp); sbuf_printf(sb, "%s%s", indent, @@ -1257,7 +1330,8 @@ g_multipath_dumpconf(struct sbuf *sb, co if (cp == NULL && pp == NULL) { sbuf_printf(sb, "%s%s", indent, sc->sc_uuid); sbuf_printf(sb, "%sActive/%s", indent, - sc->sc_active_active ? "Active" : "Passive"); + sc->sc_active_active == 2 ? "Read" : + sc->sc_active_active == 1 ? "Active" : "Passive"); sbuf_printf(sb, "%s%s", indent, sc->sc_uuid[0] == 0 ? "MANUAL" : "AUTOMATIC"); } From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 10:23:42 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E01A2106566C; Wed, 18 Apr 2012 10:23:42 +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 CC5808FC19; Wed, 18 Apr 2012 10:23:42 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IANgAg027598; Wed, 18 Apr 2012 10:23:42 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IANgRV027596; Wed, 18 Apr 2012 10:23:42 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201204181023.q3IANgRV027596@svn.freebsd.org> From: Konstantin Belousov Date: Wed, 18 Apr 2012 10:23: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: r234416 - head/usr.bin/top X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 10:23:43 -0000 Author: kib Date: Wed Apr 18 10:23:42 2012 New Revision: 234416 URL: http://svn.freebsd.org/changeset/base/234416 Log: Fix string buffer overflow when preparing the line of output. PR: bin/161739 Submitted by: Jeremy Chadwick MFC after: 1 week Modified: head/usr.bin/top/machine.c Modified: head/usr.bin/top/machine.c ============================================================================== --- head/usr.bin/top/machine.c Wed Apr 18 09:42:14 2012 (r234415) +++ head/usr.bin/top/machine.c Wed Apr 18 10:23:42 2012 (r234416) @@ -933,7 +933,7 @@ format_next_process(caddr_t handle, char p_tot = rup->ru_inblock + rup->ru_oublock + rup->ru_majflt; s_tot = total_inblock + total_oublock + total_majflt; - sprintf(fmt, io_Proc_format, + snprintf(fmt, sizeof(fmt), io_Proc_format, pp->ki_pid, jid_buf, namelength, namelength, (*get_userid)(pp->ki_ruid), @@ -961,7 +961,7 @@ format_next_process(caddr_t handle, char snprintf(thr_buf, sizeof(thr_buf), "%*d ", sizeof(thr_buf) - 2, pp->ki_numthreads); - sprintf(fmt, proc_fmt, + snprintf(fmt, sizeof(fmt), proc_fmt, pp->ki_pid, jid_buf, namelength, namelength, (*get_userid)(pp->ki_ruid), From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 11:09:32 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B4C0D106564A; Wed, 18 Apr 2012 11:09:32 +0000 (UTC) (envelope-from asmrookie@gmail.com) Received: from mail-lb0-f182.google.com (mail-lb0-f182.google.com [209.85.217.182]) by mx1.freebsd.org (Postfix) with ESMTP id 9C41D8FC0A; Wed, 18 Apr 2012 11:09:31 +0000 (UTC) Received: by lbbgm6 with SMTP id gm6so1448719lbb.13 for ; Wed, 18 Apr 2012 04:09:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=jPy4vKNd9LRgZ6E4PYQKudyugzYMwSuMMfXiUTeKQgE=; b=iT3xp4+L4pg4q/El2v8BT0rMl1Hpf6BVUG7GSYMQDdKDIXcPo7WiU5Xmr0XMspQR7y NEklv9NYY1XYjWX473bfGOziftBoXXhwZ7AP6UgEraTW8rNlGQg/Yl38m6gDFczONCf+ Ug02L0gpMJVocrQbdbazDc4P9BE5M8ESw1C7FfA1n0lk1pSc8+kc80g4Je2QDOicY95q HJkyYq2YS6MSYZ6H0+c84AhHuzi3piKkPA4u1Be4VlEHpWqZCLPAqgsosKN+1C0j9lUA lxkjrKO9Tx17V1jWCmq5N7iVWHIQBtKiCwyCPkrs4N+wfefVn3CRFkJvohnRarVMHpVd 4SuA== MIME-Version: 1.0 Received: by 10.152.132.166 with SMTP id ov6mr1832893lab.35.1334747370491; Wed, 18 Apr 2012 04:09:30 -0700 (PDT) Sender: asmrookie@gmail.com Received: by 10.112.93.138 with HTTP; Wed, 18 Apr 2012 04:09:30 -0700 (PDT) In-Reply-To: <201204172146.q3HLkxS6000736@svn.freebsd.org> References: <201204172146.q3HLkxS6000736@svn.freebsd.org> Date: Wed, 18 Apr 2012 12:09:30 +0100 X-Google-Sender-Auth: c5pgDhhvUln9LwUUBBUjNdR-8UA Message-ID: From: Attilio Rao To: Kirk McKusick Content-Type: text/plain; charset=UTF-8 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234400 - in head/sys: kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 11:09:32 -0000 2012/4/17, Kirk McKusick : > Author: mckusick > Date: Tue Apr 17 21:46:59 2012 > New Revision: 234400 > URL: http://svn.freebsd.org/changeset/base/234400 > > Log: > Drop export of vdestroy() function from kern/vfs_subr.c as it is > used only as a helper function in that file. Replace sole call to > vbusy() with inline code in vholdl(). Replace sole calls to vfree() > and vdestroy() with inline code in vdropl(). Thanks, I wanted to do this since some time. Attilio -- Peace can only be achieved by understanding - A. Einstein From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 11:52:25 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 84E591065672; Wed, 18 Apr 2012 11:52:25 +0000 (UTC) (envelope-from giovanni.trematerra@gmail.com) Received: from mail-qa0-f42.google.com (mail-qa0-f42.google.com [209.85.216.42]) by mx1.freebsd.org (Postfix) with ESMTP id E447B8FC12; Wed, 18 Apr 2012 11:52:24 +0000 (UTC) Received: by qafi31 with SMTP id i31so443358qaf.15 for ; Wed, 18 Apr 2012 04:52:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=csasRlL1/kHz4bu95JdDODXNE/3e/lGqPfXJZfkXZPI=; b=KQPkkj3yg+WT0v538zI9FDMkBVM2x/r3A+S7f+qcxMZhzumyUVfS53DLbQlTw2ySff r+udkbQtnedSLkeY2Ga5b+wQuxkj0PTNVJ52+1X0Yx4Rxg0clQf5CpMxScVmRzSyhfNm Exl06hiVOBz5c1VnE7igvrl+yT4+y9KJy39Dw6bOQCyzHnN1rbg3+tQVFfOPLS08wmBQ 1+9fsIfYRc6QHp1bc1ceY27IQjkQ84lFTfnQ8p1HC4zGKsq9CODwCg0295FiP97rZXv2 4d6vrXgxzoeamq7ajQ3fFh89P1QVFmzpZJ4l7Rpr2ZkYi2071Jzyjb87e54RMOz+6p+5 ctWA== MIME-Version: 1.0 Received: by 10.229.137.149 with SMTP id w21mr741411qct.27.1334749944162; Wed, 18 Apr 2012 04:52:24 -0700 (PDT) Sender: giovanni.trematerra@gmail.com Received: by 10.229.137.18 with HTTP; Wed, 18 Apr 2012 04:52:24 -0700 (PDT) In-Reply-To: <201204162122.q3GLM23E051048@svn.freebsd.org> References: <201204162122.q3GLM23E051048@svn.freebsd.org> Date: Wed, 18 Apr 2012 13:52:24 +0200 X-Google-Sender-Auth: QMLYRhqzO6ugetb5pKdEEWM-nDY Message-ID: From: Giovanni Trematerra To: Jung-uk Kim 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: r234352 - in head/sys: amd64/linux32 compat/linux i386/linux kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 11:52:25 -0000 On Mon, Apr 16, 2012 at 11:22 PM, Jung-uk Kim wrote: > Author: jkim > Date: Mon Apr 16 21:22:02 2012 > New Revision: 234352 > URL: http://svn.freebsd.org/changeset/base/234352 > > Log: > =A0- Implement pipe2 syscall for Linuxulator. =A0This syscall appeared in= 2.6.27 > =A0but GNU libc used it without checking its kernel version, e. g., Fedor= a 10. > =A0- Move pipe(2) implementation for Linuxulator from MD files to MI file= , > =A0sys/compat/linux/linux_file.c. =A0There is no MD code for this syscall= at all. > =A0- Correct an argument type for pipe() from l_ulong * to l_int *. =A0Pr= obably > =A0this was the source of MI/MD confusion. > > =A0Reviewed by: =A0emulation > > Modified: > =A0head/sys/amd64/linux32/linux32_dummy.c > =A0head/sys/amd64/linux32/linux32_machdep.c > =A0head/sys/amd64/linux32/syscalls.master > =A0head/sys/compat/linux/linux_file.c > =A0head/sys/i386/linux/linux_dummy.c > =A0head/sys/i386/linux/linux_machdep.c > =A0head/sys/i386/linux/syscalls.master > =A0head/sys/kern/sys_pipe.c > I don't think it's worth to change sys/kern/sys_pipe.c just to implement linux_pipe2 in linuxator. You can just revert the changes in sys_pipe.c and call kern_fcntl in linux_= pipe2 to set appropriate flags for the pipes after you created them with kern_pip= e. Please, take a look at this patch http://www.trematerra.net/patches/linux_pipe2.patch It's only test-compiled though. Thank you. -- Giovanni Trematerra From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 11:59:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1AA8A106566B; Wed, 18 Apr 2012 11:59:04 +0000 (UTC) (envelope-from marck@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id EF5068FC14; Wed, 18 Apr 2012 11:59:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IBx3Y1030613; Wed, 18 Apr 2012 11:59:03 GMT (envelope-from marck@svn.freebsd.org) Received: (from marck@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IBx3lo030605; Wed, 18 Apr 2012 11:59:03 GMT (envelope-from marck@svn.freebsd.org) Message-Id: <201204181159.q3IBx3lo030605@svn.freebsd.org> From: Dmitry Morozovsky Date: Wed, 18 Apr 2012 11:59: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: r234417 - in head/sys: geom/part sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 11:59:04 -0000 Author: marck (doc committer) Date: Wed Apr 18 11:59:03 2012 New Revision: 234417 URL: http://svn.freebsd.org/changeset/base/234417 Log: VMware environments are not unusual now. Add VMware partitions recognition (both MBR for ESXi <= 4.1 and GPT for ESXi 5) to g_part. Reviewed by: ae Approved by: ae MFC after: 2 weeks Modified: head/sys/geom/part/g_part.c head/sys/geom/part/g_part.h head/sys/geom/part/g_part_gpt.c head/sys/geom/part/g_part_mbr.c head/sys/sys/diskmbr.h head/sys/sys/gpt.h Modified: head/sys/geom/part/g_part.c ============================================================================== --- head/sys/geom/part/g_part.c Wed Apr 18 10:23:42 2012 (r234416) +++ head/sys/geom/part/g_part.c Wed Apr 18 11:59:03 2012 (r234417) @@ -103,6 +103,9 @@ struct g_part_alias_list { { "netbsd-lfs", G_PART_ALIAS_NETBSD_LFS }, { "netbsd-raid", G_PART_ALIAS_NETBSD_RAID }, { "netbsd-swap", G_PART_ALIAS_NETBSD_SWAP }, + { "vmware-vmfs", G_PART_ALIAS_VMFS }, + { "vmware-vmkdiag", G_PART_ALIAS_VMKDIAG }, + { "vmware-reserved", G_PART_ALIAS_VMRESERVED }, }; SYSCTL_DECL(_kern_geom); Modified: head/sys/geom/part/g_part.h ============================================================================== --- head/sys/geom/part/g_part.h Wed Apr 18 10:23:42 2012 (r234416) +++ head/sys/geom/part/g_part.h Wed Apr 18 11:59:03 2012 (r234417) @@ -69,6 +69,9 @@ enum g_part_alias { G_PART_ALIAS_EBR, /* A EBR partition entry. */ G_PART_ALIAS_MS_FAT32, /* A Microsoft FAT32 partition entry. */ G_PART_ALIAS_BIOS_BOOT, /* A GRUB 2 boot partition entry. */ + G_PART_ALIAS_VMFS, /* A VMware VMFS partition entry */ + G_PART_ALIAS_VMKDIAG, /* A VMware vmkDiagnostic partition entry */ + G_PART_ALIAS_VMRESERVED, /* A VMware reserved partition entry */ /* Keep the following last */ G_PART_ALIAS_COUNT }; Modified: head/sys/geom/part/g_part_gpt.c ============================================================================== --- head/sys/geom/part/g_part_gpt.c Wed Apr 18 10:23:42 2012 (r234416) +++ head/sys/geom/part/g_part_gpt.c Wed Apr 18 11:59:03 2012 (r234417) @@ -163,6 +163,9 @@ static struct uuid gpt_uuid_linux_data = static struct uuid gpt_uuid_linux_lvm = GPT_ENT_TYPE_LINUX_LVM; static struct uuid gpt_uuid_linux_raid = GPT_ENT_TYPE_LINUX_RAID; static struct uuid gpt_uuid_linux_swap = GPT_ENT_TYPE_LINUX_SWAP; +static struct uuid gpt_uuid_vmfs = GPT_ENT_TYPE_VMFS; +static struct uuid gpt_uuid_vmkdiag = GPT_ENT_TYPE_VMKDIAG; +static struct uuid gpt_uuid_vmreserved = GPT_ENT_TYPE_VMRESERVED; static struct uuid gpt_uuid_ms_basic_data = GPT_ENT_TYPE_MS_BASIC_DATA; static struct uuid gpt_uuid_ms_reserved = GPT_ENT_TYPE_MS_RESERVED; static struct uuid gpt_uuid_ms_ldm_data = GPT_ENT_TYPE_MS_LDM_DATA; @@ -200,6 +203,9 @@ static struct g_part_uuid_alias { { &gpt_uuid_linux_lvm, G_PART_ALIAS_LINUX_LVM, 0 }, { &gpt_uuid_linux_raid, G_PART_ALIAS_LINUX_RAID, 0 }, { &gpt_uuid_linux_swap, G_PART_ALIAS_LINUX_SWAP, 0 }, + { &gpt_uuid_vmfs, G_PART_ALIAS_VMFS, 0 }, + { &gpt_uuid_vmkdiag, G_PART_ALIAS_VMKDIAG, 0 }, + { &gpt_uuid_vmreserved, G_PART_ALIAS_VMRESERVED, 0 }, { &gpt_uuid_mbr, G_PART_ALIAS_MBR, 0 }, { &gpt_uuid_ms_basic_data, G_PART_ALIAS_MS_BASIC_DATA, 0x0b }, { &gpt_uuid_ms_ldm_data, G_PART_ALIAS_MS_LDM_DATA, 0 }, Modified: head/sys/geom/part/g_part_mbr.c ============================================================================== --- head/sys/geom/part/g_part_mbr.c Wed Apr 18 10:23:42 2012 (r234416) +++ head/sys/geom/part/g_part_mbr.c Wed Apr 18 11:59:03 2012 (r234417) @@ -126,6 +126,8 @@ static struct g_part_mbr_alias { { DOSPTYP_LINLVM, G_PART_ALIAS_LINUX_LVM }, { DOSPTYP_LINRAID, G_PART_ALIAS_LINUX_RAID }, { DOSPTYP_PPCBOOT, G_PART_ALIAS_FREEBSD_BOOT }, + { DOSPTYP_VMFS, G_PART_ALIAS_VMFS }, + { DOSPTYP_VMKDIAG, G_PART_ALIAS_VMKDIAG }, }; static int Modified: head/sys/sys/diskmbr.h ============================================================================== --- head/sys/sys/diskmbr.h Wed Apr 18 10:23:42 2012 (r234416) +++ head/sys/sys/diskmbr.h Wed Apr 18 11:59:03 2012 (r234417) @@ -55,6 +55,8 @@ #define DOSPTYP_LINUX 0x83 /* Linux partition */ #define DOSPTYP_LINLVM 0x8e /* Linux LVM partition */ #define DOSPTYP_PMBR 0xee /* GPT Protective MBR */ +#define DOSPTYP_VMFS 0xfb /* VMware VMFS partition */ +#define DOSPTYP_VMKDIAG 0xfc /* VMware vmkDiagnostic partition */ #define DOSPTYP_LINRAID 0xfd /* Linux raid partition */ struct dos_partition { Modified: head/sys/sys/gpt.h ============================================================================== --- head/sys/sys/gpt.h Wed Apr 18 10:23:42 2012 (r234416) +++ head/sys/sys/gpt.h Wed Apr 18 11:59:03 2012 (r234417) @@ -120,6 +120,13 @@ struct gpt_ent { #define GPT_ENT_TYPE_LINUX_LVM \ {0xe6d6d379,0xf507,0x44c2,0xa2,0x3c,{0x23,0x8f,0x2a,0x3d,0xf9,0x28}} +#define GPT_ENT_TYPE_VMFS \ + {0xaa31e02a,0x400f,0x11db,0x95,0x90,{0x00,0x0c,0x29,0x11,0xd1,0xb8}} +#define GPT_ENT_TYPE_VMKDIAG \ + {0x9d275380,0x40ad,0x11db,0xbf,0x97,{0x00,0x0c,0x29,0x11,0xd1,0xb8}} +#define GPT_ENT_TYPE_VMRESERVED \ + {0x9198effc,0x31c0,0x11db,0x8f,0x78,{0x00,0x0c,0x29,0x11,0xd1,0xb8}} + #define GPT_ENT_TYPE_APPLE_BOOT \ {0x426F6F74,0x0000,0x11aa,0xaa,0x11,{0x00,0x30,0x65,0x43,0xec,0xac}} #define GPT_ENT_TYPE_APPLE_HFS \ From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 12:16:12 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 35DF3106564A; Wed, 18 Apr 2012 12:16:12 +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 BFE4E8FC14; Wed, 18 Apr 2012 12:16:11 +0000 (UTC) Received: from skuns.kiev.zoral.com.ua (localhost [127.0.0.1]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id q3ICG0cj011127; Wed, 18 Apr 2012 15:16:00 +0300 (EEST) (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.5/8.14.5) with ESMTP id q3ICFxOo099208; Wed, 18 Apr 2012 15:15:59 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.5/8.14.5/Submit) id q3ICFxRi099207; Wed, 18 Apr 2012 15:15:59 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Wed, 18 Apr 2012 15:15:59 +0300 From: Konstantin Belousov To: Giovanni Trematerra Message-ID: <20120418121559.GY2358@deviant.kiev.zoral.com.ua> References: <201204162122.q3GLM23E051048@svn.freebsd.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="vsmlMR5OrJFuyy4J" 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=-4.0 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham 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, Jung-uk Kim Subject: Re: svn commit: r234352 - in head/sys: amd64/linux32 compat/linux i386/linux kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 12:16:12 -0000 --vsmlMR5OrJFuyy4J Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Apr 18, 2012 at 01:52:24PM +0200, Giovanni Trematerra wrote: > On Mon, Apr 16, 2012 at 11:22 PM, Jung-uk Kim wrote: > > Author: jkim > > Date: Mon Apr 16 21:22:02 2012 > > New Revision: 234352 > > URL: http://svn.freebsd.org/changeset/base/234352 > > > > Log: > > =9A- Implement pipe2 syscall for Linuxulator. =9AThis syscall appeared = in 2.6.27 > > =9Abut GNU libc used it without checking its kernel version, e. g., Fed= ora 10. > > =9A- Move pipe(2) implementation for Linuxulator from MD files to MI fi= le, > > =9Asys/compat/linux/linux_file.c. =9AThere is no MD code for this sysca= ll at all. > > =9A- Correct an argument type for pipe() from l_ulong * to l_int *. =9A= Probably > > =9Athis was the source of MI/MD confusion. > > > > =9AReviewed by: =9Aemulation > > > > Modified: > > =9Ahead/sys/amd64/linux32/linux32_dummy.c > > =9Ahead/sys/amd64/linux32/linux32_machdep.c > > =9Ahead/sys/amd64/linux32/syscalls.master > > =9Ahead/sys/compat/linux/linux_file.c > > =9Ahead/sys/i386/linux/linux_dummy.c > > =9Ahead/sys/i386/linux/linux_machdep.c > > =9Ahead/sys/i386/linux/syscalls.master > > =9Ahead/sys/kern/sys_pipe.c > > >=20 > I don't think it's worth to change sys/kern/sys_pipe.c just to implement > linux_pipe2 in linuxator. > You can just revert the changes in sys_pipe.c and call kern_fcntl in linu= x_pipe2 > to set appropriate flags for the pipes after you created them with kern_p= ipe. > Please, take a look at this patch > http://www.trematerra.net/patches/linux_pipe2.patch >=20 > It's only test-compiled though. > Thank you. I do think that what Jung-uk did is the right approach, and your suggestion is wrong. The way it is done in r234352 serves the purpose of pipe2(2), namely, the atomicity of setting O_CLOEXEC and O_NONBLOCK with respect to execve(2). You may argue that kern_execve() applies single-threading around the syscall implementation, so our thread cannot be inside the kern_pipe() while other thread performs execve(2). But unfortunately, this is only true for FreeBSD ABI, while linuxolator has very flawed execve() (and fork()) implementation. In particular, other threads are running while some thread performs fork or exec. So I think that the do_pipe() should be kept as is. --vsmlMR5OrJFuyy4J Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (FreeBSD) iEYEARECAAYFAk+OsH8ACgkQC3+MBN1Mb4hIxQCgrhHCS8tE9SKscWjtpeefDpQ4 1GwAoO2ppUfaJBadJuGbEMy7/UCCyu0W =hkko -----END PGP SIGNATURE----- --vsmlMR5OrJFuyy4J-- From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 12:50:14 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2C230106566B; Wed, 18 Apr 2012 12:50:14 +0000 (UTC) (envelope-from thomas@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1812C8FC14; Wed, 18 Apr 2012 12:50:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3ICoD12032191; Wed, 18 Apr 2012 12:50:13 GMT (envelope-from thomas@svn.freebsd.org) Received: (from thomas@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3ICoDNF032189; Wed, 18 Apr 2012 12:50:13 GMT (envelope-from thomas@svn.freebsd.org) Message-Id: <201204181250.q3ICoDNF032189@svn.freebsd.org> From: Thomas Quinot Date: Wed, 18 Apr 2012 12: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: r234418 - head/sys/dev/usb/serial X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 12:50:14 -0000 Author: thomas Date: Wed Apr 18 12:50:13 2012 New Revision: 234418 URL: http://svn.freebsd.org/changeset/base/234418 Log: Fix typo in comment Modified: head/sys/dev/usb/serial/umodem.c Modified: head/sys/dev/usb/serial/umodem.c ============================================================================== --- head/sys/dev/usb/serial/umodem.c Wed Apr 18 11:59:03 2012 (r234417) +++ head/sys/dev/usb/serial/umodem.c Wed Apr 18 12:50:13 2012 (r234418) @@ -139,7 +139,7 @@ static const STRUCT_USB_HOST_ID umodem_d }; /* - * As speeds for umodem deivces increase, these numbers will need to + * As speeds for umodem devices increase, these numbers will need to * be increased. They should be good for G3 speeds and below. * * TODO: The TTY buffers should be increased! From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 13:50:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2CBBD106564A; Wed, 18 Apr 2012 13:50:18 +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 966CC8FC12; Wed, 18 Apr 2012 13:50:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IDoHQE034230; Wed, 18 Apr 2012 13:50:17 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IDoHdx034228; Wed, 18 Apr 2012 13:50:17 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204181350.q3IDoHdx034228@svn.freebsd.org> From: Edward Tomasz Napierala Date: Wed, 18 Apr 2012 13:50: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: r234420 - head/sbin/growfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 13:50:18 -0000 Author: trasz Date: Wed Apr 18 13:50:17 2012 New Revision: 234420 URL: http://svn.freebsd.org/changeset/base/234420 Log: Style. Modified: head/sbin/growfs/growfs.c Modified: head/sbin/growfs/growfs.c ============================================================================== --- head/sbin/growfs/growfs.c Wed Apr 18 12:51:48 2012 (r234419) +++ head/sbin/growfs/growfs.c Wed Apr 18 13:50:17 2012 (r234420) @@ -1235,7 +1235,7 @@ charsperline(void) columns = 80; /* last resort */ DBG_LEAVE; - return columns; + return (columns); } /* @@ -1526,7 +1526,7 @@ main(int argc, char **argv) DBG_CLOSE; DBG_LEAVE; - return 0; + return (0); } /* From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 13:54:55 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E0611106564A; Wed, 18 Apr 2012 13:54:55 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id B232C8FC16; Wed, 18 Apr 2012 13:54:55 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 263B6B960; Wed, 18 Apr 2012 09:54:55 -0400 (EDT) From: John Baldwin To: Dimitry Andric Date: Wed, 18 Apr 2012 09:54:14 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p13; KDE/4.5.5; amd64; ; ) References: <201203301257.q2UCvE4l042042@svn.freebsd.org> <201204020752.52596.jhb@freebsd.org> <4F8DD186.6060306@FreeBSD.org> In-Reply-To: <4F8DD186.6060306@FreeBSD.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201204180954.14236.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Wed, 18 Apr 2012 09:54:55 -0400 (EDT) Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, Scott Long , Stefan Farfeleder , David Xu , svn-src-head@freebsd.org Subject: Re: svn commit: r233700 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 13:54:56 -0000 On Tuesday, April 17, 2012 4:24:38 pm Dimitry Andric wrote: > On 2012-04-02 13:52, John Baldwin wrote: > ... > >> It seems the for loop walks the list until the end, then tacks 'sc' onto > >> it. > >> > >> So to 'fix' the warning, and make the meaning more explicit, we should > >> probably rewrite that fragment as: > >> > >> LIST_INIT(&(sc->ha_ccb)); > >> /* Link us into the HA list */ > >> for (ha =&Asr_softc_list; *ha; ha =&((*ha)->ha_next)) > >> ; > >> *(ha) = sc; > >> > >> Is this OK? > > > > Can we just make that code use a STAILQ() instead of doing it obscurely by > > hand? > > That would be a more invasive change, and since this driver is > essentially unmaintained, I'd like to change as little as possible. :) > > Another solution is to just silence the warning for this driver. http://www.FreeBSD.org/~jhb/patches/asr_stailq.patch -- John Baldwin From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 15:19:01 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 40B3E106566B; Wed, 18 Apr 2012 15:19:01 +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 2C1FE8FC0A; Wed, 18 Apr 2012 15:19:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IFJ1BH037240; Wed, 18 Apr 2012 15:19:01 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IFJ0p4037238; Wed, 18 Apr 2012 15:19:00 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201204181519.q3IFJ0p4037238@svn.freebsd.org> From: Jaakko Heinonen Date: Wed, 18 Apr 2012 15:19: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: r234421 - head/sys/ufs/ufs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 15:19:01 -0000 Author: jh Date: Wed Apr 18 15:19:00 2012 New Revision: 234421 URL: http://svn.freebsd.org/changeset/base/234421 Log: The part about exec atime no longer applies in the comment. Pointed out by: bde Modified: head/sys/ufs/ufs/ufs_vnops.c Modified: head/sys/ufs/ufs/ufs_vnops.c ============================================================================== --- head/sys/ufs/ufs/ufs_vnops.c Wed Apr 18 13:50:17 2012 (r234420) +++ head/sys/ufs/ufs/ufs_vnops.c Wed Apr 18 15:19:00 2012 (r234421) @@ -573,9 +573,8 @@ ufs_setattr(ap) } /* * If immutable or append, no one can change any of its attributes - * except the ones already handled (exec atime and, in some cases - * for the superuser, file flags including the immutability flags - * themselves). + * except the ones already handled (in some cases, file flags + * including the immutability flags themselves for the superuser). */ if (ip->i_flags & (IMMUTABLE | APPEND)) return (EPERM); From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 15:22:07 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 50A7B106564A; Wed, 18 Apr 2012 15:22:07 +0000 (UTC) (envelope-from giovanni.trematerra@gmail.com) Received: from mail-qc0-f182.google.com (mail-qc0-f182.google.com [209.85.216.182]) by mx1.freebsd.org (Postfix) with ESMTP id B556F8FC08; Wed, 18 Apr 2012 15:22:06 +0000 (UTC) Received: by qcsg15 with SMTP id g15so5497444qcs.13 for ; Wed, 18 Apr 2012 08:22:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=ZaBoh4kgQsWbZuh7+abGq8Qp4TZAWYzyBTOglxYw3II=; b=bYnm6EJyPvCfSRNtj2cScaMr0PEFVHBSjpy4gV0j1qMN67ZwK1IkGn4H4WyCbtrnZP NVZRHV6t5QlR7XLq3s2MUCt3pu1/x2ZszafgGDqPaVP06A214Ii45q4nJOiXfO+qngP0 qK00WwhrUOLwWAEcjFvUorVS2uZd6D5hjqTaxPQHWGN0gmZ84QR9sa9zr1KCmi+bYsDQ a2Zi3ujoYl1l5ndLxao91c/ZhHQCR8RxQZYMu771M3CpBrLS9QKOAK2doLvzVT1X5Dg9 TJvNNnhrOA/kvx0tcOUf/iDLSJf+RPfpmu+7YlgvyTwD7Is/KNq0sThI1J81eybEB2Av SOBQ== MIME-Version: 1.0 Received: by 10.229.106.33 with SMTP id v33mr1082879qco.47.1334762526020; Wed, 18 Apr 2012 08:22:06 -0700 (PDT) Sender: giovanni.trematerra@gmail.com Received: by 10.229.137.18 with HTTP; Wed, 18 Apr 2012 08:22:04 -0700 (PDT) In-Reply-To: <20120418121559.GY2358@deviant.kiev.zoral.com.ua> References: <201204162122.q3GLM23E051048@svn.freebsd.org> <20120418121559.GY2358@deviant.kiev.zoral.com.ua> Date: Wed, 18 Apr 2012 17:22:04 +0200 X-Google-Sender-Auth: TioQpolz7rQt4upIr6TcViElMsQ Message-ID: From: Giovanni Trematerra 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, Jung-uk Kim Subject: Re: svn commit: r234352 - in head/sys: amd64/linux32 compat/linux i386/linux kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 15:22:07 -0000 2012/4/18 Konstantin Belousov : > On Wed, Apr 18, 2012 at 01:52:24PM +0200, Giovanni Trematerra wrote: >> On Mon, Apr 16, 2012 at 11:22 PM, Jung-uk Kim wrote: >> > Author: jkim >> > Date: Mon Apr 16 21:22:02 2012 >> > New Revision: 234352 >> > URL: http://svn.freebsd.org/changeset/base/234352 >> > >> > Log: >> > =A0- Implement pipe2 syscall for Linuxulator. =A0This syscall appeared= in 2.6.27 >> > =A0but GNU libc used it without checking its kernel version, e. g., Fe= dora 10. >> > =A0- Move pipe(2) implementation for Linuxulator from MD files to MI f= ile, >> > =A0sys/compat/linux/linux_file.c. =A0There is no MD code for this sysc= all at all. >> > =A0- Correct an argument type for pipe() from l_ulong * to l_int *. = =A0Probably >> > =A0this was the source of MI/MD confusion. >> > >> > =A0Reviewed by: =A0emulation >> > >> > Modified: >> > =A0head/sys/amd64/linux32/linux32_dummy.c >> > =A0head/sys/amd64/linux32/linux32_machdep.c >> > =A0head/sys/amd64/linux32/syscalls.master >> > =A0head/sys/compat/linux/linux_file.c >> > =A0head/sys/i386/linux/linux_dummy.c >> > =A0head/sys/i386/linux/linux_machdep.c >> > =A0head/sys/i386/linux/syscalls.master >> > =A0head/sys/kern/sys_pipe.c >> > >> >> I don't think it's worth to change sys/kern/sys_pipe.c just to implement >> linux_pipe2 in linuxator. >> You can just revert the changes in sys_pipe.c and call kern_fcntl in lin= ux_pipe2 >> to set appropriate flags for the pipes after you created them with kern_= pipe. >> Please, take a look at this patch >> http://www.trematerra.net/patches/linux_pipe2.patch >> >> It's only test-compiled though. >> Thank you. > > I do think that what Jung-uk did is the right approach, and your suggesti= on > is wrong. The way it is done in r234352 serves the purpose of pipe2(2), > namely, the atomicity of setting O_CLOEXEC and O_NONBLOCK with respect > to execve(2). Uhm I'm overlooked that linux threads in linuxolator are actual processes a= s you pointed me out in private. Sorry for the noise. From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 15:22:09 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 04D32106566B; Wed, 18 Apr 2012 15:22:09 +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 E4BD58FC0A; Wed, 18 Apr 2012 15:22:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IFM8Ph037393; Wed, 18 Apr 2012 15:22:08 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IFM81K037391; Wed, 18 Apr 2012 15:22:08 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201204181522.q3IFM81K037391@svn.freebsd.org> From: Jaakko Heinonen Date: Wed, 18 Apr 2012 15:22: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: r234422 - head/sys/fs/tmpfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 15:22:09 -0000 Author: jh Date: Wed Apr 18 15:22:08 2012 New Revision: 234422 URL: http://svn.freebsd.org/changeset/base/234422 Log: Return EOPNOTSUPP rather than EPERM for the SF_SNAPSHOT flag because tmpfs doesn't support snapshots. Suggested by: bde Modified: head/sys/fs/tmpfs/tmpfs_subr.c Modified: head/sys/fs/tmpfs/tmpfs_subr.c ============================================================================== --- head/sys/fs/tmpfs/tmpfs_subr.c Wed Apr 18 15:19:00 2012 (r234421) +++ head/sys/fs/tmpfs/tmpfs_subr.c Wed Apr 18 15:22:08 2012 (r234422) @@ -1080,7 +1080,7 @@ tmpfs_chflags(struct vnode *vp, int flag if ((flags & ~(UF_NODUMP | UF_IMMUTABLE | UF_APPEND | UF_OPAQUE | UF_NOUNLINK | SF_ARCHIVED | SF_IMMUTABLE | SF_APPEND | - SF_NOUNLINK | SF_SNAPSHOT)) != 0) + SF_NOUNLINK)) != 0) return (EOPNOTSUPP); /* Disallow this operation if the file system is mounted read-only. */ @@ -1104,9 +1104,6 @@ tmpfs_chflags(struct vnode *vp, int flag if (error) return (error); } - /* The snapshot flag cannot be toggled. */ - if ((flags ^ node->tn_flags) & SF_SNAPSHOT) - return (EPERM); } else { if (node->tn_flags & (SF_NOUNLINK | SF_IMMUTABLE | SF_APPEND) || From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 15:23:22 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 795D81065673; Wed, 18 Apr 2012 15:23:22 +0000 (UTC) (envelope-from maxim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4C1968FC1E; Wed, 18 Apr 2012 15:23:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IFNMwY037461; Wed, 18 Apr 2012 15:23:22 GMT (envelope-from maxim@svn.freebsd.org) Received: (from maxim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IFNMar037459; Wed, 18 Apr 2012 15:23:22 GMT (envelope-from maxim@svn.freebsd.org) Message-Id: <201204181523.q3IFNMar037459@svn.freebsd.org> From: Maxim Konovalov Date: Wed, 18 Apr 2012 15:23: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: r234423 - head/share/misc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 15:23:22 -0000 Author: maxim Date: Wed Apr 18 15:23:21 2012 New Revision: 234423 URL: http://svn.freebsd.org/changeset/base/234423 Log: o FreeBSD 8.3-RELEASE added. Modified: head/share/misc/bsd-family-tree Modified: head/share/misc/bsd-family-tree ============================================================================== --- head/share/misc/bsd-family-tree Wed Apr 18 15:22:08 2012 (r234422) +++ head/share/misc/bsd-family-tree Wed Apr 18 15:23:21 2012 (r234423) @@ -246,13 +246,14 @@ FreeBSD 5.2 | | | | | | | NetBSD 5.1 | | | FreeBSD FreeBSD | | | | | 8.2 7.4 | | | DragonFly 2.10.1 - | v | | OpenBSD 4.9 | - | Mac OS X | | | - | 10.7 | | | - | | | OpenBSD 5.0 | - +--FreeBSD | | | | - | 9.0 | | | DragonFly 3.0.1 - | v | | | | + | | | | OpenBSD 4.9 | + | `-----. Mac OS X | | | + | \ 10.7 | | | + | | | | OpenBSD 5.0 | + *--FreeBSD | | | | | + | 9.0 | | | | DragonFly 3.0.1 + | v FreeBSD | | | | + | 8.3 | | | | | | | | | FreeBSD 10 -current | NetBSD -current OpenBSD -current | | | | | | @@ -544,6 +545,7 @@ Mac OS X 10.7 2011-07-20 [APL] OpenBSD 5.0 2011-11-01 [OBD] FreeBSD 9.0 2012-01-12 [FBD] DragonFly 3.0.1 2012-02-21 [DFB] +FreeBSD 8.3 2012-04-18 [FBD] Bibliography ------------------------ From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 16:29:55 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EF75A106564A; Wed, 18 Apr 2012 16:29:55 +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 DA4338FC17; Wed, 18 Apr 2012 16:29:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IGTtt6039864; Wed, 18 Apr 2012 16:29:55 GMT (envelope-from gnn@svn.freebsd.org) Received: (from gnn@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IGTtVq039861; Wed, 18 Apr 2012 16:29:55 GMT (envelope-from gnn@svn.freebsd.org) Message-Id: <201204181629.q3IGTtVq039861@svn.freebsd.org> From: "George V. Neville-Neil" Date: Wed, 18 Apr 2012 16:29: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: r234424 - head/lib/libthr/thread X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 16:29:56 -0000 Author: gnn Date: Wed Apr 18 16:29:55 2012 New Revision: 234424 URL: http://svn.freebsd.org/changeset/base/234424 Log: Set SIGCANCEL to SIGTHR as part of some cleanup of DTrace code. Reviewed by: davidxu@ MFC after: 1 week Modified: head/lib/libthr/thread/thr_private.h Modified: head/lib/libthr/thread/thr_private.h ============================================================================== --- head/lib/libthr/thread/thr_private.h Wed Apr 18 15:23:21 2012 (r234423) +++ head/lib/libthr/thread/thr_private.h Wed Apr 18 16:29:55 2012 (r234424) @@ -80,7 +80,7 @@ typedef TAILQ_HEAD(atfork_head, pthread_ TAILQ_HEAD(mutex_queue, pthread_mutex); /* Signal to do cancellation */ -#define SIGCANCEL 32 +#define SIGCANCEL SIGTHR /* * Kernel fatal error handler macro. From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 16:47:58 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 35FFA1065676; Wed, 18 Apr 2012 16:47:58 +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 159448FC16; Wed, 18 Apr 2012 16:47:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IGlvbG040767; Wed, 18 Apr 2012 16:47:57 GMT (envelope-from jpaetzel@svn.freebsd.org) Received: (from jpaetzel@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IGlvjq040763; Wed, 18 Apr 2012 16:47:57 GMT (envelope-from jpaetzel@svn.freebsd.org) Message-Id: <201204181647.q3IGlvjq040763@svn.freebsd.org> From: Josh Paetzel Date: Wed, 18 Apr 2012 16:47: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: r234425 - in head: sbin/iscontrol sys/modules/iscsi/initiator X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 16:47:58 -0000 Author: jpaetzel Date: Wed Apr 18 16:47:57 2012 New Revision: 234425 URL: http://svn.freebsd.org/changeset/base/234425 Log: Unbreak tinderbox. Fix FreeBSD paradigms in the upstream code. PR: bin/166933 Submitted by: Garrett Cooper Modified: head/sbin/iscontrol/Makefile head/sbin/iscontrol/iscontrol.c head/sys/modules/iscsi/initiator/Makefile Modified: head/sbin/iscontrol/Makefile ============================================================================== --- head/sbin/iscontrol/Makefile Wed Apr 18 16:29:55 2012 (r234424) +++ head/sbin/iscontrol/Makefile Wed Apr 18 16:47:57 2012 (r234425) @@ -7,8 +7,7 @@ LDADD= -lcam -lmd S= ${.CURDIR}/../../sys WARNS?= 3 -CFLAGS += -I$S -CFLAGS += -g -DDEBUG +CFLAGS+= -I$S MAN= iscsi.conf.5 iscontrol.8 Modified: head/sbin/iscontrol/iscontrol.c ============================================================================== --- head/sbin/iscontrol/iscontrol.c Wed Apr 18 16:29:55 2012 (r234424) +++ head/sbin/iscontrol/iscontrol.c Wed Apr 18 16:47:57 2012 (r234425) @@ -44,13 +44,15 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include -#include -#include -#include +#include #include #include +#include +#include +#include +#include #include +#include #include #include @@ -111,6 +113,13 @@ isc_opt_t opvals = { .immediateData = TRUE, }; +static void +usage(const char *pname) +{ + fprintf(stderr, "usage: %s " USAGE "\n", pname); + exit(1); +} + int lookup(token_t *tbl, char *m) { @@ -135,8 +144,8 @@ main(int cc, char **vv) iscsidev = "/dev/"ISCSIDEV; fd = NULL; pname = vv[0]; - if((p = strrchr(pname, '/')) != NULL) - pname = p + 1; + if ((pname = basename(pname)) == NULL) + err(1, "basename"); kw = ta = 0; disco = 0; @@ -145,17 +154,21 @@ main(int cc, char **vv) | check for driver & controller version match */ n = 0; - if(sysctlbyname("net.iscsi_initiator.driver_version", 0, &n, 0, 0) != 0) - perror("sysctlbyname"); - v = malloc(n+1); - if(sysctlbyname("net.iscsi_initiator.driver_version", v, &n, 0, 0) != 0) - perror("sysctlbyname"); - - if(strncmp(version, v, 3)) { - fprintf(stderr, "versions missmatch\n"); - exit(1); +#define VERSION_OID_S "net.iscsi_initiator.driver_version" + if (sysctlbyname(VERSION_OID_S, 0, &n, 0, 0) != 0) { + if (errno == ENOENT) + errx(1, "sysctlbyname(\"" VERSION_OID_S "\") " + "failed; is the iscsi driver loaded?"); + err(1, "sysctlbyname(\"" VERSION_OID_S "\")"); } + v = malloc(n+1); + if (v == NULL) + err(1, "malloc"); + if (sysctlbyname(VERSION_OID_S, v, &n, 0, 0) != 0) + err(1, "sysctlbyname"); + if (strncmp(version, v, 3) != 0) + errx(1, "versions mismatch"); while((ch = getopt(cc, vv, OPTIONS)) != -1) { switch(ch) { @@ -164,10 +177,8 @@ main(int cc, char **vv) break; case 'c': fd = fopen(optarg, "r"); - if(fd == NULL) { - perror(optarg); - exit(1); - } + if (fd == NULL) + err(1, "fopen(\"%s\")", optarg); break; case 'd': disco = 1; @@ -182,9 +193,7 @@ main(int cc, char **vv) pidfile = optarg; break; default: - badu: - fprintf(stderr, "Usage: %s %s\n", pname, USAGE); - exit(1); + usage(pname); } } if(fd == NULL) @@ -205,8 +214,8 @@ main(int cc, char **vv) op->targetAddress = ta; if(op->targetAddress == NULL) { - fprintf(stderr, "No target!\n"); - goto badu; + warnx("no target specified!"); + usage(pname); } q = op->targetAddress; if(*q == '[' && (q = strchr(q, ']')) != NULL) { @@ -224,7 +233,7 @@ main(int cc, char **vv) op->targetPortalGroupTag = atoi(p); } if(op->initiatorName == 0) { - char hostname[256]; + char hostname[MAXHOSTNAMELEN]; if(op->iqn) { if(gethostname(hostname, sizeof(hostname)) == 0) Modified: head/sys/modules/iscsi/initiator/Makefile ============================================================================== --- head/sys/modules/iscsi/initiator/Makefile Wed Apr 18 16:29:55 2012 (r234424) +++ head/sys/modules/iscsi/initiator/Makefile Wed Apr 18 16:47:57 2012 (r234425) @@ -10,7 +10,9 @@ SRCS+= iscsi.c isc_cam.c isc_soc.c isc_s SRCS+= opt_cam.h opt_iscsi_initiator.h SRCS+= bus_if.h device_if.h #CFLAGS+= -DNO_USE_MBUF +CFLAGS+= -DISCSI_INITIATOR_DEBUG=2 #CFLAGS+= -DISCSI_INITIATOR_DEBUG=2 +CFLAGS+= -DINVARIANTS CFLAGS+= -I$S CFLAGS+= -DINVARIANTS .include From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 17:44:05 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BFD1A106566B; Wed, 18 Apr 2012 17:44:05 +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 AAE768FC15; Wed, 18 Apr 2012 17:44:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IHi5ZA042600; Wed, 18 Apr 2012 17:44:05 GMT (envelope-from marcel@svn.freebsd.org) Received: (from marcel@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IHi5vH042598; Wed, 18 Apr 2012 17:44:05 GMT (envelope-from marcel@svn.freebsd.org) Message-Id: <201204181744.q3IHi5vH042598@svn.freebsd.org> From: Marcel Moolenaar Date: Wed, 18 Apr 2012 17:44: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: r234427 - head/sys/modules/uart X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 17:44:05 -0000 Author: marcel Date: Wed Apr 18 17:44:05 2012 New Revision: 234427 URL: http://svn.freebsd.org/changeset/base/234427 Log: Compensate for the replacement of uart_cpu_{amd64|i386}.c with uart_cpu_x86.c Pointy hat: marcel Modified: head/sys/modules/uart/Makefile Modified: head/sys/modules/uart/Makefile ============================================================================== --- head/sys/modules/uart/Makefile Wed Apr 18 17:12:04 2012 (r234426) +++ head/sys/modules/uart/Makefile Wed Apr 18 17:44:05 2012 (r234427) @@ -7,16 +7,23 @@ uart_bus_ebus= uart_bus_ebus.c ofw_bus_if= ofw_bus_if.h .endif +.if ${MACHINE} == "i386" || ${MACHINE} == "amd64" +_uart_cpu=uart_cpu_x86.c +.else +_uart_cpu=uart_cpu_${MACHINE}.c +.endif +.if exists(${.CURDIR:H:H}/dev/uart/${_uart_cpu}) +uart_cpu_machine= ${_uart_cpu} +.endif + KMOD= uart SRCS= uart_bus_acpi.c ${uart_bus_ebus} uart_bus_isa.c uart_bus_pccard.c \ uart_bus_pci.c uart_bus_puc.c uart_bus_scc.c \ - uart_core.c uart_dbg.c \ + uart_core.c ${uart_cpu_machine} uart_dbg.c \ uart_dev_ns8250.c uart_dev_quicc.c uart_dev_sab82532.c \ uart_dev_z8530.c \ uart_if.c uart_if.h uart_subr.c uart_tty.c -.if exists(${.CURDIR}/../../dev/uart/uart_cpu_${MACHINE}.c) -SRCS+= uart_cpu_${MACHINE}.c -.endif + SRCS+= bus_if.h card_if.h device_if.h isa_if.h ${ofw_bus_if} pci_if.h \ power_if.h pccarddevs.h serdev_if.h From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 18:31:11 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DC5171065670; Wed, 18 Apr 2012 18:31:11 +0000 (UTC) (envelope-from ambrisko@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C3A7C8FC08; Wed, 18 Apr 2012 18:31:11 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IIVBhM045145; Wed, 18 Apr 2012 18:31:11 GMT (envelope-from ambrisko@svn.freebsd.org) Received: (from ambrisko@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IIVBjd045141; Wed, 18 Apr 2012 18:31:11 GMT (envelope-from ambrisko@svn.freebsd.org) Message-Id: <201204181831.q3IIVBjd045141@svn.freebsd.org> From: Doug Ambrisko Date: Wed, 18 Apr 2012 18:31:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234429 - in stable/9/sys: conf dev/mfi modules/mfi X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 18:31:12 -0000 Author: ambrisko Date: Wed Apr 18 18:31:11 2012 New Revision: 234429 URL: http://svn.freebsd.org/changeset/base/234429 Log: MFC r233711: Major update to driver to support for Drake Skinny and ThunderBolt cards. MFC r233768: Change typedef atomic_t to struct mfi_atomic to avoid name space collision and some couple more style changes. MFC r233805: Move struct megasas_sge from mfi_ioctl.h to mfivar.h so we can remove including machine/bus.h. Add some more mfi_ prefixes to avoid name space pollution. MFC r233877: - Do not include machine/atomic.h. It is no longer necessary since r233768. - Remove bogus "atomic" macros and a read-only variable from softc. Added: stable/9/sys/dev/mfi/mfi_syspd.c - copied unchanged from r233711, head/sys/dev/mfi/mfi_syspd.c stable/9/sys/dev/mfi/mfi_tbolt.c - copied, changed from r233711, head/sys/dev/mfi/mfi_tbolt.c Modified: stable/9/sys/conf/files stable/9/sys/dev/mfi/mfi.c stable/9/sys/dev/mfi/mfi_cam.c stable/9/sys/dev/mfi/mfi_debug.c stable/9/sys/dev/mfi/mfi_disk.c stable/9/sys/dev/mfi/mfi_ioctl.h stable/9/sys/dev/mfi/mfi_linux.c stable/9/sys/dev/mfi/mfi_pci.c stable/9/sys/dev/mfi/mfireg.h stable/9/sys/dev/mfi/mfivar.h stable/9/sys/modules/mfi/Makefile Directory Properties: stable/9/sys/ (props changed) stable/9/sys/conf/ (props changed) Modified: stable/9/sys/conf/files ============================================================================== --- stable/9/sys/conf/files Wed Apr 18 18:11:32 2012 (r234428) +++ stable/9/sys/conf/files Wed Apr 18 18:31:11 2012 (r234429) @@ -1414,6 +1414,8 @@ dev/mfi/mfi.c optional mfi dev/mfi/mfi_debug.c optional mfi dev/mfi/mfi_pci.c optional mfi pci dev/mfi/mfi_disk.c optional mfi +dev/mfi/mfi_syspd.c optional mfi +dev/mfi/mfi_tbolt.c optional mfi dev/mfi/mfi_linux.c optional mfi compat_linux dev/mfi/mfi_cam.c optional mfip scbus dev/mii/acphy.c optional miibus | acphy Modified: stable/9/sys/dev/mfi/mfi.c ============================================================================== --- stable/9/sys/dev/mfi/mfi.c Wed Apr 18 18:11:32 2012 (r234428) +++ stable/9/sys/dev/mfi/mfi.c Wed Apr 18 18:31:11 2012 (r234429) @@ -53,6 +53,7 @@ #include __FBSDID("$FreeBSD$"); +#include "opt_compat.h" #include "opt_mfi.h" #include @@ -72,6 +73,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include @@ -79,10 +81,11 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include +#include static int mfi_alloc_commands(struct mfi_softc *); static int mfi_comms_init(struct mfi_softc *); -static int mfi_wait_command(struct mfi_softc *, struct mfi_command *); static int mfi_get_controller_info(struct mfi_softc *); static int mfi_get_log_state(struct mfi_softc *, struct mfi_evt_log_state **); @@ -93,29 +96,39 @@ static void mfi_data_cb(void *, bus_dma_ static void mfi_startup(void *arg); static void mfi_intr(void *arg); static void mfi_ldprobe(struct mfi_softc *sc); +static void mfi_syspdprobe(struct mfi_softc *sc); +static void mfi_handle_evt(void *context, int pending); static int mfi_aen_register(struct mfi_softc *sc, int seq, int locale); static void mfi_aen_complete(struct mfi_command *); -static int mfi_aen_setup(struct mfi_softc *, uint32_t); static int mfi_add_ld(struct mfi_softc *sc, int); static void mfi_add_ld_complete(struct mfi_command *); +static int mfi_add_sys_pd(struct mfi_softc *sc, int); +static void mfi_add_sys_pd_complete(struct mfi_command *); static struct mfi_command * mfi_bio_command(struct mfi_softc *); static void mfi_bio_complete(struct mfi_command *); -static int mfi_mapcmd(struct mfi_softc *, struct mfi_command *); +static struct mfi_command *mfi_build_ldio(struct mfi_softc *,struct bio*); +static struct mfi_command *mfi_build_syspdio(struct mfi_softc *,struct bio*); static int mfi_send_frame(struct mfi_softc *, struct mfi_command *); -static void mfi_complete(struct mfi_softc *, struct mfi_command *); static int mfi_abort(struct mfi_softc *, struct mfi_command *); static int mfi_linux_ioctl_int(struct cdev *, u_long, caddr_t, int, struct thread *); static void mfi_timeout(void *); static int mfi_user_command(struct mfi_softc *, struct mfi_ioc_passthru *); -static void mfi_enable_intr_xscale(struct mfi_softc *sc); -static void mfi_enable_intr_ppc(struct mfi_softc *sc); -static int32_t mfi_read_fw_status_xscale(struct mfi_softc *sc); -static int32_t mfi_read_fw_status_ppc(struct mfi_softc *sc); -static int mfi_check_clear_intr_xscale(struct mfi_softc *sc); -static int mfi_check_clear_intr_ppc(struct mfi_softc *sc); -static void mfi_issue_cmd_xscale(struct mfi_softc *sc,uint32_t bus_add,uint32_t frame_cnt); -static void mfi_issue_cmd_ppc(struct mfi_softc *sc,uint32_t bus_add,uint32_t frame_cnt); +static void mfi_enable_intr_xscale(struct mfi_softc *sc); +static void mfi_enable_intr_ppc(struct mfi_softc *sc); +static int32_t mfi_read_fw_status_xscale(struct mfi_softc *sc); +static int32_t mfi_read_fw_status_ppc(struct mfi_softc *sc); +static int mfi_check_clear_intr_xscale(struct mfi_softc *sc); +static int mfi_check_clear_intr_ppc(struct mfi_softc *sc); +static void mfi_issue_cmd_xscale(struct mfi_softc *sc, bus_addr_t bus_add, + uint32_t frame_cnt); +static void mfi_issue_cmd_ppc(struct mfi_softc *sc, bus_addr_t bus_add, + uint32_t frame_cnt); +static int mfi_config_lock(struct mfi_softc *sc, uint32_t opcode); +static void mfi_config_unlock(struct mfi_softc *sc, int locked); +static int mfi_check_command_pre(struct mfi_softc *sc, struct mfi_command *cm); +static void mfi_check_command_post(struct mfi_softc *sc, struct mfi_command *cm); +static int mfi_check_for_sscd(struct mfi_softc *sc, struct mfi_command *cm); SYSCTL_NODE(_hw, OID_AUTO, mfi, CTLFLAG_RD, 0, "MFI driver parameters"); static int mfi_event_locale = MFI_EVT_LOCALE_ALL; @@ -133,6 +146,11 @@ TUNABLE_INT("hw.mfi.max_cmds", &mfi_max_ SYSCTL_INT(_hw_mfi, OID_AUTO, max_cmds, CTLFLAG_RD, &mfi_max_cmds, 0, "Max commands"); +static int mfi_detect_jbod_change = 1; +TUNABLE_INT("hw.mfi.detect_jbod_change", &mfi_detect_jbod_change); +SYSCTL_INT(_hw_mfi, OID_AUTO, detect_jbod_change, CTLFLAG_RW, + &mfi_detect_jbod_change, 0, "Detect a change to a JBOD"); + /* Management interface */ static d_open_t mfi_open; static d_close_t mfi_close; @@ -152,6 +170,7 @@ static struct cdevsw mfi_cdevsw = { MALLOC_DEFINE(M_MFIBUF, "mfibuf", "Buffers for the MFI driver"); #define MFI_INQ_LENGTH SHORT_INQUIRY_LENGTH +struct mfi_skinny_dma_info mfi_skinny; static void mfi_enable_intr_xscale(struct mfi_softc *sc) @@ -162,12 +181,17 @@ mfi_enable_intr_xscale(struct mfi_softc static void mfi_enable_intr_ppc(struct mfi_softc *sc) { - MFI_WRITE4(sc, MFI_ODCR0, 0xFFFFFFFF); if (sc->mfi_flags & MFI_FLAGS_1078) { + MFI_WRITE4(sc, MFI_ODCR0, 0xFFFFFFFF); MFI_WRITE4(sc, MFI_OMSK, ~MFI_1078_EIM); - } else if (sc->mfi_flags & MFI_FLAGS_GEN2) { + } + else if (sc->mfi_flags & MFI_FLAGS_GEN2) { + MFI_WRITE4(sc, MFI_ODCR0, 0xFFFFFFFF); MFI_WRITE4(sc, MFI_OMSK, ~MFI_GEN2_EIM); } + else if (sc->mfi_flags & MFI_FLAGS_SKINNY) { + MFI_WRITE4(sc, MFI_OMSK, ~0x00000001); + } } static int32_t @@ -205,35 +229,51 @@ mfi_check_clear_intr_ppc(struct mfi_soft if (!(status & MFI_1078_RM)) { return 1; } - } else if (sc->mfi_flags & MFI_FLAGS_GEN2) { + } + else if (sc->mfi_flags & MFI_FLAGS_GEN2) { if (!(status & MFI_GEN2_RM)) { return 1; } } - - MFI_WRITE4(sc, MFI_ODCR0, status); + else if (sc->mfi_flags & MFI_FLAGS_SKINNY) { + if (!(status & MFI_SKINNY_RM)) { + return 1; + } + } + if (sc->mfi_flags & MFI_FLAGS_SKINNY) + MFI_WRITE4(sc, MFI_OSTS, status); + else + MFI_WRITE4(sc, MFI_ODCR0, status); return 0; } static void -mfi_issue_cmd_xscale(struct mfi_softc *sc,uint32_t bus_add,uint32_t frame_cnt) +mfi_issue_cmd_xscale(struct mfi_softc *sc, bus_addr_t bus_add, uint32_t frame_cnt) { MFI_WRITE4(sc, MFI_IQP,(bus_add >>3)|frame_cnt); } static void -mfi_issue_cmd_ppc(struct mfi_softc *sc,uint32_t bus_add,uint32_t frame_cnt) +mfi_issue_cmd_ppc(struct mfi_softc *sc, bus_addr_t bus_add, uint32_t frame_cnt) { - MFI_WRITE4(sc, MFI_IQP, (bus_add |frame_cnt <<1)|1 ); + if (sc->mfi_flags & MFI_FLAGS_SKINNY) { + MFI_WRITE4(sc, MFI_IQPL, (bus_add | frame_cnt <<1)|1 ); + MFI_WRITE4(sc, MFI_IQPH, 0x00000000); + } else { + MFI_WRITE4(sc, MFI_IQP, (bus_add | frame_cnt <<1)|1 ); + } } -static int +int mfi_transition_firmware(struct mfi_softc *sc) { uint32_t fw_state, cur_state; int max_wait, i; + uint32_t cur_abs_reg_val = 0; + uint32_t prev_abs_reg_val = 0; - fw_state = sc->mfi_read_fw_status(sc)& MFI_FWSTATE_MASK; + cur_abs_reg_val = sc->mfi_read_fw_status(sc); + fw_state = cur_abs_reg_val & MFI_FWSTATE_MASK; while (fw_state != MFI_FWSTATE_READY) { if (bootverbose) device_printf(sc->mfi_dev, "Waiting for firmware to " @@ -244,38 +284,60 @@ mfi_transition_firmware(struct mfi_softc device_printf(sc->mfi_dev, "Firmware fault\n"); return (ENXIO); case MFI_FWSTATE_WAIT_HANDSHAKE: - MFI_WRITE4(sc, MFI_IDB, MFI_FWINIT_CLEAR_HANDSHAKE); - max_wait = 2; + if (sc->mfi_flags & MFI_FLAGS_SKINNY || sc->mfi_flags & MFI_FLAGS_TBOLT) + MFI_WRITE4(sc, MFI_SKINNY_IDB, MFI_FWINIT_CLEAR_HANDSHAKE); + else + MFI_WRITE4(sc, MFI_IDB, MFI_FWINIT_CLEAR_HANDSHAKE); + max_wait = MFI_RESET_WAIT_TIME; break; case MFI_FWSTATE_OPERATIONAL: - MFI_WRITE4(sc, MFI_IDB, MFI_FWINIT_READY); - max_wait = 10; + if (sc->mfi_flags & MFI_FLAGS_SKINNY || sc->mfi_flags & MFI_FLAGS_TBOLT) + MFI_WRITE4(sc, MFI_SKINNY_IDB, 7); + else + MFI_WRITE4(sc, MFI_IDB, MFI_FWINIT_READY); + max_wait = MFI_RESET_WAIT_TIME; break; case MFI_FWSTATE_UNDEFINED: case MFI_FWSTATE_BB_INIT: - max_wait = 2; + max_wait = MFI_RESET_WAIT_TIME; + break; + case MFI_FWSTATE_FW_INIT_2: + max_wait = MFI_RESET_WAIT_TIME; break; case MFI_FWSTATE_FW_INIT: - case MFI_FWSTATE_DEVICE_SCAN: case MFI_FWSTATE_FLUSH_CACHE: - max_wait = 20; + max_wait = MFI_RESET_WAIT_TIME; + break; + case MFI_FWSTATE_DEVICE_SCAN: + max_wait = MFI_RESET_WAIT_TIME; /* wait for 180 seconds */ + prev_abs_reg_val = cur_abs_reg_val; break; case MFI_FWSTATE_BOOT_MESSAGE_PENDING: - MFI_WRITE4(sc, MFI_IDB, MFI_FWINIT_HOTPLUG); - max_wait = 10; + if (sc->mfi_flags & MFI_FLAGS_SKINNY || sc->mfi_flags & MFI_FLAGS_TBOLT) + MFI_WRITE4(sc, MFI_SKINNY_IDB, MFI_FWINIT_HOTPLUG); + else + MFI_WRITE4(sc, MFI_IDB, MFI_FWINIT_HOTPLUG); + max_wait = MFI_RESET_WAIT_TIME; break; default: - device_printf(sc->mfi_dev,"Unknown firmware state %#x\n", + device_printf(sc->mfi_dev, "Unknown firmware state %#x\n", fw_state); return (ENXIO); } for (i = 0; i < (max_wait * 10); i++) { - fw_state = sc->mfi_read_fw_status(sc) & MFI_FWSTATE_MASK; + cur_abs_reg_val = sc->mfi_read_fw_status(sc); + fw_state = cur_abs_reg_val & MFI_FWSTATE_MASK; if (fw_state == cur_state) DELAY(100000); else break; } + if (fw_state == MFI_FWSTATE_DEVICE_SCAN) { + /* Check the device scanning progress */ + if (prev_abs_reg_val != cur_abs_reg_val) { + continue; + } + } if (fw_state == cur_state) { device_printf(sc->mfi_dev, "Firmware stuck in state " "%#x\n", fw_state); @@ -286,26 +348,35 @@ mfi_transition_firmware(struct mfi_softc } static void -mfi_addr32_cb(void *arg, bus_dma_segment_t *segs, int nsegs, int error) +mfi_addr_cb(void *arg, bus_dma_segment_t *segs, int nsegs, int error) { - uint32_t *addr; + bus_addr_t *addr; addr = arg; *addr = segs[0].ds_addr; } + int mfi_attach(struct mfi_softc *sc) { uint32_t status; int error, commsz, framessz, sensesz; int frames, unit, max_fw_sge; + uint32_t tb_mem_size = 0; + + if (sc == NULL) + return EINVAL; - device_printf(sc->mfi_dev, "Megaraid SAS driver Ver 3.00 \n"); + device_printf(sc->mfi_dev, "Megaraid SAS driver Ver %s \n", + MEGASAS_VERSION); mtx_init(&sc->mfi_io_lock, "MFI I/O lock", NULL, MTX_DEF); sx_init(&sc->mfi_config_lock, "MFI config"); TAILQ_INIT(&sc->mfi_ld_tqh); + TAILQ_INIT(&sc->mfi_syspd_tqh); + TAILQ_INIT(&sc->mfi_evt_queue); + TASK_INIT(&sc->mfi_evt_task, 0, mfi_handle_evt, sc); TAILQ_INIT(&sc->mfi_aen_pids); TAILQ_INIT(&sc->mfi_cam_ccbq); @@ -314,15 +385,29 @@ mfi_attach(struct mfi_softc *sc) mfi_initq_busy(sc); mfi_initq_bio(sc); + sc->adpreset = 0; + sc->last_seq_num = 0; + sc->disableOnlineCtrlReset = 1; + sc->issuepend_done = 1; + sc->hw_crit_error = 0; + if (sc->mfi_flags & MFI_FLAGS_1064R) { sc->mfi_enable_intr = mfi_enable_intr_xscale; sc->mfi_read_fw_status = mfi_read_fw_status_xscale; sc->mfi_check_clear_intr = mfi_check_clear_intr_xscale; sc->mfi_issue_cmd = mfi_issue_cmd_xscale; - } - else { + } else if (sc->mfi_flags & MFI_FLAGS_TBOLT) { + sc->mfi_enable_intr = mfi_tbolt_enable_intr_ppc; + sc->mfi_disable_intr = mfi_tbolt_disable_intr_ppc; + sc->mfi_read_fw_status = mfi_tbolt_read_fw_status_ppc; + sc->mfi_check_clear_intr = mfi_tbolt_check_clear_intr_ppc; + sc->mfi_issue_cmd = mfi_tbolt_issue_cmd_ppc; + sc->mfi_adp_reset = mfi_tbolt_adp_reset; + sc->mfi_tbolt = 1; + TAILQ_INIT(&sc->mfi_cmd_tbolt_tqh); + } else { sc->mfi_enable_intr = mfi_enable_intr_ppc; - sc->mfi_read_fw_status = mfi_read_fw_status_ppc; + sc->mfi_read_fw_status = mfi_read_fw_status_ppc; sc->mfi_check_clear_intr = mfi_check_clear_intr_ppc; sc->mfi_issue_cmd = mfi_issue_cmd_ppc; } @@ -335,6 +420,32 @@ mfi_attach(struct mfi_softc *sc) return (ENXIO); } + /* Start: LSIP200113393 */ + if (bus_dma_tag_create( sc->mfi_parent_dmat, /* parent */ + 1, 0, /* algnmnt, boundary */ + BUS_SPACE_MAXADDR_32BIT,/* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + MEGASAS_MAX_NAME*sizeof(bus_addr_t), /* maxsize */ + 1, /* msegments */ + MEGASAS_MAX_NAME*sizeof(bus_addr_t), /* maxsegsize */ + 0, /* flags */ + NULL, NULL, /* lockfunc, lockarg */ + &sc->verbuf_h_dmat)) { + device_printf(sc->mfi_dev, "Cannot allocate verbuf_h_dmat DMA tag\n"); + return (ENOMEM); + } + if (bus_dmamem_alloc(sc->verbuf_h_dmat, (void **)&sc->verbuf, + BUS_DMA_NOWAIT, &sc->verbuf_h_dmamap)) { + device_printf(sc->mfi_dev, "Cannot allocate verbuf_h_dmamap memory\n"); + return (ENOMEM); + } + bzero(sc->verbuf, MEGASAS_MAX_NAME*sizeof(bus_addr_t)); + bus_dmamap_load(sc->verbuf_h_dmat, sc->verbuf_h_dmamap, + sc->verbuf, MEGASAS_MAX_NAME*sizeof(bus_addr_t), + mfi_addr_cb, &sc->verbuf_h_busaddr, 0); + /* End: LSIP200113393 */ + /* * Get information needed for sizing the contiguous memory for the * frame pool. Size down the sgl parameter since we know that @@ -347,6 +458,100 @@ mfi_attach(struct mfi_softc *sc) max_fw_sge = (status & MFI_FWSTATE_MAXSGL_MASK) >> 16; sc->mfi_max_sge = min(max_fw_sge, ((MFI_MAXPHYS / PAGE_SIZE) + 1)); + /* ThunderBolt Support get the contiguous memory */ + + if (sc->mfi_flags & MFI_FLAGS_TBOLT) { + mfi_tbolt_init_globals(sc); + device_printf(sc->mfi_dev, "MaxCmd = %x MaxSgl = %x state = %x \n", + sc->mfi_max_fw_cmds, sc->mfi_max_sge, status); + tb_mem_size = mfi_tbolt_get_memory_requirement(sc); + + if (bus_dma_tag_create( sc->mfi_parent_dmat, /* parent */ + 1, 0, /* algnmnt, boundary */ + BUS_SPACE_MAXADDR_32BIT,/* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + tb_mem_size, /* maxsize */ + 1, /* msegments */ + tb_mem_size, /* maxsegsize */ + 0, /* flags */ + NULL, NULL, /* lockfunc, lockarg */ + &sc->mfi_tb_dmat)) { + device_printf(sc->mfi_dev, "Cannot allocate comms DMA tag\n"); + return (ENOMEM); + } + if (bus_dmamem_alloc(sc->mfi_tb_dmat, (void **)&sc->request_message_pool, + BUS_DMA_NOWAIT, &sc->mfi_tb_dmamap)) { + device_printf(sc->mfi_dev, "Cannot allocate comms memory\n"); + return (ENOMEM); + } + bzero(sc->request_message_pool, tb_mem_size); + bus_dmamap_load(sc->mfi_tb_dmat, sc->mfi_tb_dmamap, + sc->request_message_pool, tb_mem_size, mfi_addr_cb, &sc->mfi_tb_busaddr, 0); + + /* For ThunderBolt memory init */ + if (bus_dma_tag_create( sc->mfi_parent_dmat, /* parent */ + 0x100, 0, /* alignmnt, boundary */ + BUS_SPACE_MAXADDR_32BIT,/* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + MFI_FRAME_SIZE, /* maxsize */ + 1, /* msegments */ + MFI_FRAME_SIZE, /* maxsegsize */ + 0, /* flags */ + NULL, NULL, /* lockfunc, lockarg */ + &sc->mfi_tb_init_dmat)) { + device_printf(sc->mfi_dev, "Cannot allocate init DMA tag\n"); + return (ENOMEM); + } + if (bus_dmamem_alloc(sc->mfi_tb_init_dmat, (void **)&sc->mfi_tb_init, + BUS_DMA_NOWAIT, &sc->mfi_tb_init_dmamap)) { + device_printf(sc->mfi_dev, "Cannot allocate init memory\n"); + return (ENOMEM); + } + bzero(sc->mfi_tb_init, MFI_FRAME_SIZE); + bus_dmamap_load(sc->mfi_tb_init_dmat, sc->mfi_tb_init_dmamap, + sc->mfi_tb_init, MFI_FRAME_SIZE, mfi_addr_cb, + &sc->mfi_tb_init_busaddr, 0); + if (mfi_tbolt_init_desc_pool(sc, sc->request_message_pool, + tb_mem_size)) { + device_printf(sc->mfi_dev, + "Thunderbolt pool preparation error\n"); + return 0; + } + + /* + Allocate DMA memory mapping for MPI2 IOC Init descriptor, + we are taking it diffrent from what we have allocated for Request + and reply descriptors to avoid confusion later + */ + tb_mem_size = sizeof(struct MPI2_IOC_INIT_REQUEST); + if (bus_dma_tag_create( sc->mfi_parent_dmat, /* parent */ + 1, 0, /* algnmnt, boundary */ + BUS_SPACE_MAXADDR_32BIT,/* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + tb_mem_size, /* maxsize */ + 1, /* msegments */ + tb_mem_size, /* maxsegsize */ + 0, /* flags */ + NULL, NULL, /* lockfunc, lockarg */ + &sc->mfi_tb_ioc_init_dmat)) { + device_printf(sc->mfi_dev, + "Cannot allocate comms DMA tag\n"); + return (ENOMEM); + } + if (bus_dmamem_alloc(sc->mfi_tb_ioc_init_dmat, + (void **)&sc->mfi_tb_ioc_init_desc, + BUS_DMA_NOWAIT, &sc->mfi_tb_ioc_init_dmamap)) { + device_printf(sc->mfi_dev, "Cannot allocate comms memory\n"); + return (ENOMEM); + } + bzero(sc->mfi_tb_ioc_init_desc, tb_mem_size); + bus_dmamap_load(sc->mfi_tb_ioc_init_dmat, sc->mfi_tb_ioc_init_dmamap, + sc->mfi_tb_ioc_init_desc, tb_mem_size, mfi_addr_cb, + &sc->mfi_tb_ioc_init_busaddr, 0); + } /* * Create the dma tag for data buffers. Used both for block I/O * and for various internal data queries. @@ -396,8 +601,7 @@ mfi_attach(struct mfi_softc *sc) } bzero(sc->mfi_comms, commsz); bus_dmamap_load(sc->mfi_comms_dmat, sc->mfi_comms_dmamap, - sc->mfi_comms, commsz, mfi_addr32_cb, &sc->mfi_comms_busaddr, 0); - + sc->mfi_comms, commsz, mfi_addr_cb, &sc->mfi_comms_busaddr, 0); /* * Allocate DMA memory for the command frames. Keep them in the * lower 4GB for efficiency. Calculate the size of the commands at @@ -414,6 +618,8 @@ mfi_attach(struct mfi_softc *sc) } else { sc->mfi_sge_size = sizeof(struct mfi_sg32); } + if (sc->mfi_flags & MFI_FLAGS_SKINNY) + sc->mfi_sge_size = sizeof(struct mfi_sg_skinny); frames = (sc->mfi_sge_size * sc->mfi_max_sge - 1) / MFI_FRAME_SIZE + 2; sc->mfi_cmd_size = frames * MFI_FRAME_SIZE; framessz = sc->mfi_cmd_size * sc->mfi_max_fw_cmds; @@ -438,8 +644,7 @@ mfi_attach(struct mfi_softc *sc) } bzero(sc->mfi_frames, framessz); bus_dmamap_load(sc->mfi_frames_dmat, sc->mfi_frames_dmamap, - sc->mfi_frames, framessz, mfi_addr32_cb, &sc->mfi_frames_busaddr,0); - + sc->mfi_frames, framessz, mfi_addr_cb, &sc->mfi_frames_busaddr,0); /* * Allocate DMA memory for the frame sense data. Keep them in the * lower 4GB for efficiency @@ -465,32 +670,47 @@ mfi_attach(struct mfi_softc *sc) return (ENOMEM); } bus_dmamap_load(sc->mfi_sense_dmat, sc->mfi_sense_dmamap, - sc->mfi_sense, sensesz, mfi_addr32_cb, &sc->mfi_sense_busaddr, 0); - + sc->mfi_sense, sensesz, mfi_addr_cb, &sc->mfi_sense_busaddr, 0); if ((error = mfi_alloc_commands(sc)) != 0) return (error); - if ((error = mfi_comms_init(sc)) != 0) - return (error); + /* Before moving the FW to operational state, check whether + * hostmemory is required by the FW or not + */ - if ((error = mfi_get_controller_info(sc)) != 0) - return (error); + /* ThunderBolt MFI_IOC2 INIT */ + if (sc->mfi_flags & MFI_FLAGS_TBOLT) { + sc->mfi_disable_intr(sc); + if ((error = mfi_tbolt_init_MFI_queue(sc)) != 0) { + device_printf(sc->mfi_dev, + "TB Init has failed with error %d\n",error); + return error; + } - mtx_lock(&sc->mfi_io_lock); - if ((error = mfi_aen_setup(sc, 0), 0) != 0) { - mtx_unlock(&sc->mfi_io_lock); - return (error); - } - mtx_unlock(&sc->mfi_io_lock); + if ((error = mfi_tbolt_alloc_cmd(sc)) != 0) + return error; + if (bus_setup_intr(sc->mfi_dev, sc->mfi_irq, + INTR_MPSAFE|INTR_TYPE_BIO, NULL, mfi_intr_tbolt, sc, + &sc->mfi_intr)) { + device_printf(sc->mfi_dev, "Cannot set up interrupt\n"); + return (EINVAL); + } + sc->mfi_enable_intr(sc); + sc->map_id = 0; + } else { + if ((error = mfi_comms_init(sc)) != 0) + return (error); - /* - * Set up the interrupt handler. - */ - if (bus_setup_intr(sc->mfi_dev, sc->mfi_irq, INTR_MPSAFE|INTR_TYPE_BIO, - NULL, mfi_intr, sc, &sc->mfi_intr)) { - device_printf(sc->mfi_dev, "Cannot set up interrupt\n"); - return (EINVAL); + if (bus_setup_intr(sc->mfi_dev, sc->mfi_irq, + INTR_MPSAFE|INTR_TYPE_BIO, NULL, mfi_intr, sc, &sc->mfi_intr)) { + device_printf(sc->mfi_dev, "Cannot set up interrupt\n"); + return (EINVAL); + } + sc->mfi_enable_intr(sc); } + if ((error = mfi_get_controller_info(sc)) != 0) + return (error); + sc->disableOnlineCtrlReset = 0; /* Register a config hook to probe the bus for arrays */ sc->mfi_ich.ich_func = mfi_startup; @@ -500,6 +720,10 @@ mfi_attach(struct mfi_softc *sc) "hook\n"); return (EINVAL); } + if ((error = mfi_aen_setup(sc, 0), 0) != 0) { + mtx_unlock(&sc->mfi_io_lock); + return (error); + } /* * Register a shutdown handler. @@ -571,8 +795,11 @@ mfi_alloc_commands(struct mfi_softc *sc) cm->cm_sc = sc; cm->cm_index = i; if (bus_dmamap_create(sc->mfi_buffer_dmat, 0, - &cm->cm_dmamap) == 0) + &cm->cm_dmamap) == 0) { + mtx_lock(&sc->mfi_io_lock); mfi_release_command(cm); + mtx_unlock(&sc->mfi_io_lock); + } else break; sc->mfi_total_cmds++; @@ -587,6 +814,8 @@ mfi_release_command(struct mfi_command * struct mfi_frame_header *hdr; uint32_t *hdr_data; + mtx_assert(&cm->cm_sc->mfi_io_lock, MA_OWNED); + /* * Zero out the important fields of the frame, but make sure the * context field is preserved. For efficiency, handle the fields @@ -611,24 +840,31 @@ mfi_release_command(struct mfi_command * cm->cm_data = NULL; cm->cm_sg = 0; cm->cm_total_frame_size = 0; + cm->retry_for_fw_reset = 0; mfi_enqueue_free(cm); } static int -mfi_dcmd_command(struct mfi_softc *sc, struct mfi_command **cmp, uint32_t opcode, - void **bufp, size_t bufsize) +mfi_dcmd_command(struct mfi_softc *sc, struct mfi_command **cmp, + uint32_t opcode, void **bufp, size_t bufsize) { struct mfi_command *cm; struct mfi_dcmd_frame *dcmd; void *buf = NULL; - + uint32_t context = 0; + mtx_assert(&sc->mfi_io_lock, MA_OWNED); - + cm = mfi_dequeue_free(sc); if (cm == NULL) return (EBUSY); + /* Zero out the MFI frame */ + context = cm->cm_frame->header.context; + bzero(cm->cm_frame, sizeof(union mfi_frame)); + cm->cm_frame->header.context = context; + if ((bufsize > 0) && (bufp != NULL)) { if (*bufp == NULL) { buf = malloc(bufsize, M_MFIBUF, M_NOWAIT|M_ZERO); @@ -648,6 +884,7 @@ mfi_dcmd_command(struct mfi_softc *sc, s dcmd->header.timeout = 0; dcmd->header.flags = 0; dcmd->header.data_len = bufsize; + dcmd->header.scsi_status = 0; dcmd->opcode = opcode; cm->cm_sg = &dcmd->sgl; cm->cm_total_frame_size = MFI_DCMD_FRAME_SIZE; @@ -669,11 +906,17 @@ mfi_comms_init(struct mfi_softc *sc) struct mfi_init_frame *init; struct mfi_init_qinfo *qinfo; int error; + uint32_t context = 0; mtx_lock(&sc->mfi_io_lock); if ((cm = mfi_dequeue_free(sc)) == NULL) return (EBUSY); + /* Zero out the MFI frame */ + context = cm->cm_frame->header.context; + bzero(cm->cm_frame, sizeof(union mfi_frame)); + cm->cm_frame->header.context = context; + /* * Abuse the SG list area of the frame to hold the init_qinfo * object; @@ -734,9 +977,11 @@ mfi_get_controller_info(struct mfi_softc BUS_DMASYNC_POSTREAD); bus_dmamap_unload(sc->mfi_buffer_dmat, cm->cm_dmamap); - max_sectors_1 = (1 << ci->stripe_sz_ops.min) * ci->max_strips_per_io; + max_sectors_1 = (1 << ci->stripe_sz_ops.max) * ci->max_strips_per_io; max_sectors_2 = ci->max_request_size; sc->mfi_max_io = min(max_sectors_1, max_sectors_2); + sc->disableOnlineCtrlReset = + ci->properties.OnOffProperties.disableOnlineCtrlReset; out: if (ci) @@ -753,6 +998,7 @@ mfi_get_log_state(struct mfi_softc *sc, struct mfi_command *cm = NULL; int error; + mtx_lock(&sc->mfi_io_lock); error = mfi_dcmd_command(sc, &cm, MFI_DCMD_CTRL_EVENT_GETINFO, (void **)log_state, sizeof(**log_state)); if (error) @@ -771,11 +1017,12 @@ mfi_get_log_state(struct mfi_softc *sc, out: if (cm) mfi_release_command(cm); + mtx_unlock(&sc->mfi_io_lock); return (error); } -static int +int mfi_aen_setup(struct mfi_softc *sc, uint32_t seq_start) { struct mfi_evt_log_state *log_state = NULL; @@ -789,6 +1036,7 @@ mfi_aen_setup(struct mfi_softc *sc, uint if (seq_start == 0) { error = mfi_get_log_state(sc, &log_state); + sc->mfi_boot_seq_num = log_state->boot_seq_num; if (error) { if (log_state) free(log_state, M_MFIBUF); @@ -810,7 +1058,7 @@ mfi_aen_setup(struct mfi_softc *sc, uint return 0; } -static int +int mfi_wait_command(struct mfi_softc *sc, struct mfi_command *cm) { @@ -883,6 +1131,64 @@ mfi_free(struct mfi_softc *sc) if (sc->mfi_comms_dmat != NULL) bus_dma_tag_destroy(sc->mfi_comms_dmat); + /* ThunderBolt contiguous memory free here */ + if (sc->mfi_flags & MFI_FLAGS_TBOLT) { + if (sc->mfi_tb_busaddr != 0) + bus_dmamap_unload(sc->mfi_tb_dmat, sc->mfi_tb_dmamap); + if (sc->request_message_pool != NULL) + bus_dmamem_free(sc->mfi_tb_dmat, sc->request_message_pool, + sc->mfi_tb_dmamap); + if (sc->mfi_tb_dmat != NULL) + bus_dma_tag_destroy(sc->mfi_tb_dmat); + + /* Version buffer memory free */ + /* Start LSIP200113393 */ + if (sc->verbuf_h_busaddr != 0) + bus_dmamap_unload(sc->verbuf_h_dmat, sc->verbuf_h_dmamap); + if (sc->verbuf != NULL) + bus_dmamem_free(sc->verbuf_h_dmat, sc->verbuf, + sc->verbuf_h_dmamap); + if (sc->verbuf_h_dmat != NULL) + bus_dma_tag_destroy(sc->verbuf_h_dmat); + + /* End LSIP200113393 */ + /* ThunderBolt INIT packet memory Free */ + if (sc->mfi_tb_init_busaddr != 0) + bus_dmamap_unload(sc->mfi_tb_init_dmat, sc->mfi_tb_init_dmamap); + if (sc->mfi_tb_init != NULL) + bus_dmamem_free(sc->mfi_tb_init_dmat, sc->mfi_tb_init, + sc->mfi_tb_init_dmamap); + if (sc->mfi_tb_init_dmat != NULL) + bus_dma_tag_destroy(sc->mfi_tb_init_dmat); + + /* ThunderBolt IOC Init Desc memory free here */ + if (sc->mfi_tb_ioc_init_busaddr != 0) + bus_dmamap_unload(sc->mfi_tb_ioc_init_dmat, + sc->mfi_tb_ioc_init_dmamap); + if (sc->mfi_tb_ioc_init_desc != NULL) + bus_dmamem_free(sc->mfi_tb_ioc_init_dmat, + sc->mfi_tb_ioc_init_desc, + sc->mfi_tb_ioc_init_dmamap); + if (sc->mfi_tb_ioc_init_dmat != NULL) + bus_dma_tag_destroy(sc->mfi_tb_ioc_init_dmat); + for (int i = 0; i < sc->mfi_max_fw_cmds; i++) { + if (sc->mfi_cmd_pool_tbolt != NULL) { + if (sc->mfi_cmd_pool_tbolt[i] != NULL) { + free(sc->mfi_cmd_pool_tbolt[i], + M_MFIBUF); + sc->mfi_cmd_pool_tbolt[i] = NULL; + } + } + } + if (sc->mfi_cmd_pool_tbolt != NULL) { + free(sc->mfi_cmd_pool_tbolt, M_MFIBUF); + sc->mfi_cmd_pool_tbolt = NULL; + } + if (sc->request_desc_pool != NULL) { + free(sc->request_desc_pool, M_MFIBUF); + sc->request_desc_pool = NULL; + } + } if (sc->mfi_buffer_dmat != NULL) bus_dma_tag_destroy(sc->mfi_buffer_dmat); if (sc->mfi_parent_dmat != NULL) @@ -909,6 +1215,8 @@ mfi_startup(void *arg) sx_xlock(&sc->mfi_config_lock); mtx_lock(&sc->mfi_io_lock); mfi_ldprobe(sc); + if (sc->mfi_flags & MFI_FLAGS_SKINNY) + mfi_syspdprobe(sc); mtx_unlock(&sc->mfi_io_lock); sx_xunlock(&sc->mfi_config_lock); } @@ -925,12 +1233,7 @@ mfi_intr(void *arg) if (sc->mfi_check_clear_intr(sc)) return; - /* - * Do a dummy read to flush the interrupt ACK that we just performed, - * ensuring that everything is really, truly consistent. - */ - (void)sc->mfi_read_fw_status(sc); - +restart: pi = sc->mfi_comms->hw_pi; ci = sc->mfi_comms->hw_ci; mtx_lock(&sc->mfi_io_lock); @@ -955,6 +1258,14 @@ mfi_intr(void *arg) mfi_startio(sc); mtx_unlock(&sc->mfi_io_lock); + /* + * Dummy read to flush the bus; this ensures that the indexes are up + * to date. Restart processing if more commands have come it. + */ + (void)sc->mfi_read_fw_status(sc); + if (pi != sc->mfi_comms->hw_pi) + goto restart; + return; } @@ -975,6 +1286,9 @@ mfi_shutdown(struct mfi_softc *sc) if (sc->mfi_aen_cm != NULL) mfi_abort(sc, sc->mfi_aen_cm); + if (sc->map_update_cmd != NULL) + mfi_abort(sc, sc->map_update_cmd); + dcmd = &cm->cm_frame->dcmd; dcmd->header.flags = MFI_FRAME_DIR_NONE; cm->cm_flags = MFI_CMD_POLLED; @@ -990,6 +1304,81 @@ mfi_shutdown(struct mfi_softc *sc) } static void +mfi_syspdprobe(struct mfi_softc *sc) +{ + struct mfi_frame_header *hdr; + struct mfi_command *cm = NULL; + struct mfi_pd_list *pdlist = NULL; + struct mfi_system_pd *syspd, *tmp; + int error, i, found; + + sx_assert(&sc->mfi_config_lock, SA_XLOCKED); + mtx_assert(&sc->mfi_io_lock, MA_OWNED); + /* Add SYSTEM PD's */ + error = mfi_dcmd_command(sc, &cm, MFI_DCMD_PD_LIST_QUERY, + (void **)&pdlist, sizeof(*pdlist)); + if (error){ + device_printf(sc->mfi_dev, + "Error while forming SYSTEM PD list\n"); + goto out; + } + + cm->cm_flags = MFI_CMD_DATAIN | MFI_CMD_POLLED; + cm->cm_frame->dcmd.mbox[0] = MR_PD_QUERY_TYPE_EXPOSED_TO_HOST; + cm->cm_frame->dcmd.mbox[1] = 0; + if (mfi_mapcmd(sc, cm) != 0) { + device_printf(sc->mfi_dev, + "Failed to get syspd device listing\n"); + goto out; + } + bus_dmamap_sync(sc->mfi_buffer_dmat,cm->cm_dmamap, + BUS_DMASYNC_POSTREAD); + bus_dmamap_unload(sc->mfi_buffer_dmat, cm->cm_dmamap); + hdr = &cm->cm_frame->header; + if (hdr->cmd_status != MFI_STAT_OK) { + device_printf(sc->mfi_dev, + "MFI_DCMD_PD_LIST_QUERY failed %x\n", hdr->cmd_status); + goto out; + } + /* Get each PD and add it to the system */ + for (i = 0; i < pdlist->count; i++) { + if (pdlist->addr[i].device_id == + pdlist->addr[i].encl_device_id) + continue; + found = 0; + TAILQ_FOREACH(syspd, &sc->mfi_syspd_tqh, pd_link) { + if (syspd->pd_id == pdlist->addr[i].device_id) + found = 1; + } + if (found == 0) + mfi_add_sys_pd(sc, pdlist->addr[i].device_id); + } + /* Delete SYSPD's whose state has been changed */ + TAILQ_FOREACH_SAFE(syspd, &sc->mfi_syspd_tqh, pd_link, tmp) { + found = 0; + for (i = 0; i < pdlist->count; i++) { + if (syspd->pd_id == pdlist->addr[i].device_id) + found = 1; + } + if (found == 0) { + printf("DELETE\n"); + mtx_unlock(&sc->mfi_io_lock); + mtx_lock(&Giant); + device_delete_child(sc->mfi_dev, syspd->pd_dev); + mtx_unlock(&Giant); + mtx_lock(&sc->mfi_io_lock); + } + } +out: + if (pdlist) + free(pdlist, M_MFIBUF); + if (cm) + mfi_release_command(cm); + + return; +} + +static void mfi_ldprobe(struct mfi_softc *sc) { struct mfi_frame_header *hdr; @@ -1083,10 +1472,124 @@ format_class(int8_t class) static void mfi_decode_evt(struct mfi_softc *sc, struct mfi_evt_detail *detail) { + struct mfi_system_pd *syspd = NULL; device_printf(sc->mfi_dev, "%d (%s/0x%04x/%s) - %s\n", detail->seq, format_timestamp(detail->time), detail->evt_class.members.locale, - format_class(detail->evt_class.members.evt_class), detail->description); + format_class(detail->evt_class.members.evt_class), + detail->description); + + /* Don't act on old AEN's or while shutting down */ + if (detail->seq < sc->mfi_boot_seq_num || sc->mfi_detaching) + return; + + switch (detail->arg_type) { + case MR_EVT_ARGS_NONE: + if (detail->code == MR_EVT_CTRL_HOST_BUS_SCAN_REQUESTED) { + device_printf(sc->mfi_dev, "HostBus scan raised\n"); + if (mfi_detect_jbod_change) { + /* + * Probe for new SYSPD's and Delete + * invalid SYSPD's + */ + sx_xlock(&sc->mfi_config_lock); + mtx_lock(&sc->mfi_io_lock); + mfi_syspdprobe(sc); + mtx_unlock(&sc->mfi_io_lock); + sx_xunlock(&sc->mfi_config_lock); + } + } + break; + case MR_EVT_ARGS_LD_STATE: + /* During load time driver reads all the events starting + * from the one that has been logged after shutdown. Avoid + * these old events. + */ + if (detail->args.ld_state.new_state == MFI_LD_STATE_OFFLINE ) { + /* Remove the LD */ + struct mfi_disk *ld; + TAILQ_FOREACH(ld, &sc->mfi_ld_tqh, ld_link) { + if (ld->ld_id == + detail->args.ld_state.ld.target_id) + break; + } + /* + Fix: for kernel panics when SSCD is removed + KASSERT(ld != NULL, ("volume dissappeared")); + */ + if (ld != NULL) { + mtx_lock(&Giant); + device_delete_child(sc->mfi_dev, ld->ld_dev); + mtx_unlock(&Giant); + } + } + break; + case MR_EVT_ARGS_PD: + if (detail->code == MR_EVT_PD_REMOVED) { + if (mfi_detect_jbod_change) { + /* + * If the removed device is a SYSPD then + * delete it + */ + TAILQ_FOREACH(syspd, &sc->mfi_syspd_tqh, + pd_link) { + if (syspd->pd_id == + detail->args.pd.device_id) { + mtx_lock(&Giant); + device_delete_child( + sc->mfi_dev, + syspd->pd_dev); + mtx_unlock(&Giant); + break; + } + } + } + } + if (detail->code == MR_EVT_PD_INSERTED) { + if (mfi_detect_jbod_change) { + /* Probe for new SYSPD's */ + sx_xlock(&sc->mfi_config_lock); + mtx_lock(&sc->mfi_io_lock); + mfi_syspdprobe(sc); + mtx_unlock(&sc->mfi_io_lock); + sx_xunlock(&sc->mfi_config_lock); + } + } + break; + } +} *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 18:35:20 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 74A2F106564A; Wed, 18 Apr 2012 18:35:20 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 5F18A8FC08; Wed, 18 Apr 2012 18:35:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IIZK8D045307; Wed, 18 Apr 2012 18:35:20 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IIZKJ4045305; Wed, 18 Apr 2012 18:35:20 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201204181835.q3IIZKJ4045305@svn.freebsd.org> From: Devin Teske Date: Wed, 18 Apr 2012 18:35: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: r234430 - head/share/misc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 18:35:20 -0000 Author: dteske Date: Wed Apr 18 18:35:19 2012 New Revision: 234430 URL: http://svn.freebsd.org/changeset/base/234430 Log: Add myself as a new committer. Approved by: emaste (mentor) Modified: head/share/misc/committers-src.dot Modified: head/share/misc/committers-src.dot ============================================================================== --- head/share/misc/committers-src.dot Wed Apr 18 18:31:11 2012 (r234429) +++ head/share/misc/committers-src.dot Wed Apr 18 18:35:19 2012 (r234430) @@ -127,6 +127,7 @@ dfr [label="Doug Rabson\ndfr@FreeBSD.org dg [label="David Greenman\ndg@FreeBSD.org\n1993/06/14"] dim [label="Dimitry Andric\ndim@FreeBSD.org\n2010/08/30"] dougb [label="Doug Barton\ndougb@FreeBSD.org\n2000/10/26"] +dteske [label="Devin Teske\ndteske@FreeBSD.org\n2012/04/10"] dwmalone [label="David Malone\ndwmalone@FreeBSD.org\n2000/07/11"] ed [label="Ed Schouten\ned@FreeBSD.org\n2008/05/22"] edwin [label="Edwin Groothuis\nedwin@FreeBSD.org\n2007/06/25"] @@ -362,6 +363,7 @@ eivind -> des eivind -> rwatson emaste -> rstone +emaste -> dteske emax -> markus From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 18:58:19 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7CA141065672; Wed, 18 Apr 2012 18:58:19 +0000 (UTC) (envelope-from ambrisko@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 437D38FC1B; Wed, 18 Apr 2012 18:58:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IIwJSo046159; Wed, 18 Apr 2012 18:58:19 GMT (envelope-from ambrisko@svn.freebsd.org) Received: (from ambrisko@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IIwJoD046156; Wed, 18 Apr 2012 18:58:19 GMT (envelope-from ambrisko@svn.freebsd.org) Message-Id: <201204181858.q3IIwJoD046156@svn.freebsd.org> From: Doug Ambrisko Date: Wed, 18 Apr 2012 18:58:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234433 - stable/9/usr.sbin/mfiutil X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 18:58:19 -0000 Author: ambrisko Date: Wed Apr 18 18:58:18 2012 New Revision: 234433 URL: http://svn.freebsd.org/changeset/base/234433 Log: MFC r233713 Remove the magic mfi_array is 288 bytes and just use the sizeof the array since it is not 288 bytes. Change reporting of a "SYSTEM" disk to "JBOD" to match LSI MegaCli and firmware reporting. This means that mfiutil command to "create jbod" is now a little confusing since a RAID per drive is not really what LSI defines JBOD to be. This should be fixed in the future and support added to really create LSI JBOD and enable that feature on cards that support it. Modified: stable/9/usr.sbin/mfiutil/mfi_config.c stable/9/usr.sbin/mfiutil/mfi_drive.c Directory Properties: stable/9/ (props changed) stable/9/usr.sbin/mfiutil/ (props changed) Modified: stable/9/usr.sbin/mfiutil/mfi_config.c ============================================================================== --- stable/9/usr.sbin/mfiutil/mfi_config.c Wed Apr 18 18:43:01 2012 (r234432) +++ stable/9/usr.sbin/mfiutil/mfi_config.c Wed Apr 18 18:58:18 2012 (r234433) @@ -211,9 +211,8 @@ clear_config(int ac, char **av) } MFI_COMMAND(top, clear, clear_config); -#define MFI_ARRAY_SIZE 288 -#define MAX_DRIVES_PER_ARRAY \ - ((MFI_ARRAY_SIZE - sizeof(struct mfi_array)) / 8) +#define MAX_DRIVES_PER_ARRAY MFI_MAX_ROW_SIZE +#define MFI_ARRAY_SIZE sizeof(struct mfi_array) #define RT_RAID0 0 #define RT_RAID1 1 @@ -305,7 +304,7 @@ parse_array(int fd, int raid_type, char /* Validate the number of drives for this array. */ if (count >= MAX_DRIVES_PER_ARRAY) { - warnx("Too many drives for a single array: max is %zu", + warnx("Too many drives for a single array: max is %d", MAX_DRIVES_PER_ARRAY); return (EINVAL); } Modified: stable/9/usr.sbin/mfiutil/mfi_drive.c ============================================================================== --- stable/9/usr.sbin/mfiutil/mfi_drive.c Wed Apr 18 18:43:01 2012 (r234432) +++ stable/9/usr.sbin/mfiutil/mfi_drive.c Wed Apr 18 18:58:18 2012 (r234433) @@ -149,7 +149,7 @@ mfi_pdstate(enum mfi_pd_state state) case MFI_PD_STATE_COPYBACK: return ("COPYBACK"); case MFI_PD_STATE_SYSTEM: - return ("SYSTEM"); + return ("JBOD"); default: sprintf(buf, "PSTATE 0x%04x", state); return (buf); From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 19:16:00 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8A1E9106566C; Wed, 18 Apr 2012 19:16:00 +0000 (UTC) (envelope-from ambrisko@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 74B058FC17; Wed, 18 Apr 2012 19:16:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IJG08v046884; Wed, 18 Apr 2012 19:16:00 GMT (envelope-from ambrisko@svn.freebsd.org) Received: (from ambrisko@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IJG0lV046882; Wed, 18 Apr 2012 19:16:00 GMT (envelope-from ambrisko@svn.freebsd.org) Message-Id: <201204181916.q3IJG0lV046882@svn.freebsd.org> From: Doug Ambrisko Date: Wed, 18 Apr 2012 19:16:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234438 - stable/9/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 19:16:00 -0000 Author: ambrisko Date: Wed Apr 18 19:15:59 2012 New Revision: 234438 URL: http://svn.freebsd.org/changeset/base/234438 Log: MFC r230778 When detaching an AIO or LIO requests grab the lock and tell knlist_remove that we have the lock now. This cleans up a locking panic ASSERT when knlist_empty is called without a lock when INVARIANTS etc. are turned. Modified: stable/9/sys/kern/vfs_aio.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/vfs_aio.c ============================================================================== --- stable/9/sys/kern/vfs_aio.c Wed Apr 18 19:11:21 2012 (r234437) +++ stable/9/sys/kern/vfs_aio.c Wed Apr 18 19:15:59 2012 (r234438) @@ -2535,10 +2535,13 @@ filt_aioattach(struct knote *kn) static void filt_aiodetach(struct knote *kn) { - struct aiocblist *aiocbe = kn->kn_ptr.p_aio; + struct knlist *knl; - if (!knlist_empty(&aiocbe->klist)) - knlist_remove(&aiocbe->klist, kn, 0); + knl = &kn->kn_ptr.p_aio->klist; + knl->kl_lock(knl->kl_lockarg); + if (!knlist_empty(knl)) + knlist_remove(knl, kn, 1); + knl->kl_unlock(knl->kl_lockarg); } /* kqueue filter function */ @@ -2580,10 +2583,13 @@ filt_lioattach(struct knote *kn) static void filt_liodetach(struct knote *kn) { - struct aioliojob * lj = kn->kn_ptr.p_lio; + struct knlist *knl; - if (!knlist_empty(&lj->klist)) - knlist_remove(&lj->klist, kn, 0); + knl = &kn->kn_ptr.p_lio->klist; + knl->kl_lock(knl->kl_lockarg); + if (!knlist_empty(knl)) + knlist_remove(knl, kn, 1); + knl->kl_unlock(knl->kl_lockarg); } /* kqueue filter function */ From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 19:30:22 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D7F281065675; Wed, 18 Apr 2012 19:30:22 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C36D38FC1C; Wed, 18 Apr 2012 19:30:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IJUMIt047416; Wed, 18 Apr 2012 19:30:22 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IJUMs4047414; Wed, 18 Apr 2012 19:30:22 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204181930.q3IJUMs4047414@svn.freebsd.org> From: Kirk McKusick Date: Wed, 18 Apr 2012 19:30: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: r234441 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 19:30:22 -0000 Author: mckusick Date: Wed Apr 18 19:30:22 2012 New Revision: 234441 URL: http://svn.freebsd.org/changeset/base/234441 Log: Fix a memory leak of M_VNODE_MARKER introduced in 234386. Found by: Peter Holm Modified: head/sys/kern/vfs_subr.c Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Wed Apr 18 19:25:37 2012 (r234440) +++ head/sys/kern/vfs_subr.c Wed Apr 18 19:30:22 2012 (r234441) @@ -4528,10 +4528,10 @@ __mnt_vnode_first_all(struct vnode **mvp /* Check if we are done */ if (vp == NULL) { - *mvp = NULL; MNT_REL(mp); MNT_IUNLOCK(mp); free(*mvp, M_VNODE_MARKER); + *mvp = NULL; return (NULL); } (*mvp)->v_mount = mp; From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 19:34:21 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5E31B1065673; Wed, 18 Apr 2012 19:34:21 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 49C408FC0C; Wed, 18 Apr 2012 19:34:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IJYL3L047646; Wed, 18 Apr 2012 19:34:21 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IJYLXI047644; Wed, 18 Apr 2012 19:34:21 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204181934.q3IJYLXI047644@svn.freebsd.org> From: Kirk McKusick Date: Wed, 18 Apr 2012 19:34: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: r234443 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 19:34:21 -0000 Author: mckusick Date: Wed Apr 18 19:34:20 2012 New Revision: 234443 URL: http://svn.freebsd.org/changeset/base/234443 Log: Delete a no longer useful VNASSERT missed during changes in 234400. Suggested by: kib Modified: head/sys/kern/vfs_subr.c Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Wed Apr 18 19:31:52 2012 (r234442) +++ head/sys/kern/vfs_subr.c Wed Apr 18 19:34:20 2012 (r234443) @@ -2369,8 +2369,6 @@ vdropl(struct vnode *vp) ("vnode already free")); VNASSERT(VSHOULDFREE(vp), vp, ("vdropl: freeing when we shouldn't")); - VNASSERT((vp->v_iflag & VI_DOOMED) == 0, vp, - ("vdropl: Freeing doomed vnode")); if (vp->v_iflag & VI_AGE) { TAILQ_INSERT_HEAD(&vnode_free_list, vp, v_freelist); } else { From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 20:10:05 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9D42C1065674; Wed, 18 Apr 2012 20:10:05 +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 543738FC16; Wed, 18 Apr 2012 20:10:05 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:b953:ef4c:fb7e:5a5f] (unknown [IPv6:2001:7b8:3a7:0:b953:ef4c:fb7e:5a5f]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 7EF1E5C37; Wed, 18 Apr 2012 22:10:04 +0200 (CEST) Message-ID: <4F8F1F99.8060408@FreeBSD.org> Date: Wed, 18 Apr 2012 22:10:01 +0200 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20120410 Thunderbird/12.0 MIME-Version: 1.0 To: John Baldwin References: <201203301257.q2UCvE4l042042@svn.freebsd.org> <201204020752.52596.jhb@freebsd.org> <4F8DD186.6060306@FreeBSD.org> <201204180954.14236.jhb@freebsd.org> In-Reply-To: <201204180954.14236.jhb@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, Scott Long , Stefan Farfeleder , David Xu , svn-src-head@freebsd.org Subject: Re: svn commit: r233700 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 20:10:05 -0000 On 2012-04-18 15:54, John Baldwin wrote: ... > http://www.FreeBSD.org/~jhb/patches/asr_stailq.patch Yes, that seems to work just fine, at least for the list juggling. Thanks! The only additional fix needed now is the following. Shall I commit that including your patch? Index: sys/dev/asr/asr.c =================================================================== --- sys/dev/asr/asr.c (revision 234390) +++ sys/dev/asr/asr.c (working copy) @@ -2700,7 +2701,7 @@ asr_action(struct cam_sim *sim, union ccb *ccb) ccb->ccb_h.spriv_ptr0 = sc = (struct Asr_softc *)cam_sim_softc(sim); - switch (ccb->ccb_h.func_code) { + switch ((int)ccb->ccb_h.func_code) { /* Common cases first */ case XPT_SCSI_IO: /* Execute the requested I/O operation */ From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 20:32:08 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D2D641065678; Wed, 18 Apr 2012 20:32: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 A38A18FC0C; Wed, 18 Apr 2012 20:32:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IKW8Ch049442; Wed, 18 Apr 2012 20:32:08 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IKW8dS049438; Wed, 18 Apr 2012 20:32:08 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204182032.q3IKW8dS049438@svn.freebsd.org> From: Dimitry Andric Date: Wed, 18 Apr 2012 20:32:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234444 - in stable/9/usr.bin: kdump truss X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 20:32:08 -0000 Author: dim Date: Wed Apr 18 20:32:07 2012 New Revision: 234444 URL: http://svn.freebsd.org/changeset/base/234444 Log: MFC r234058: In kdump's mkioctls script, use '${CPP}' instead of hardcodedly using 'gcc -E'. This fixes building when WITH_CLANG_IS_CC is in effect. Report by: Niclas Zeising MFC r234060: Since truss also uses kdump's mkioctls script, pass the value of ${CPP} there too, similar to r234058. Modified: stable/9/usr.bin/kdump/Makefile stable/9/usr.bin/kdump/mkioctls stable/9/usr.bin/truss/Makefile Directory Properties: stable/9/usr.bin/kdump/ (props changed) stable/9/usr.bin/truss/ (props changed) Modified: stable/9/usr.bin/kdump/Makefile ============================================================================== --- stable/9/usr.bin/kdump/Makefile Wed Apr 18 19:34:20 2012 (r234443) +++ stable/9/usr.bin/kdump/Makefile Wed Apr 18 20:32:07 2012 (r234444) @@ -20,7 +20,8 @@ WARNS?= 0 CLEANFILES= ioctl.c kdump_subr.c linux_syscalls.c ioctl.c: mkioctls - sh ${.CURDIR}/mkioctls ${DESTDIR}/usr/include > ${.TARGET} + env CPP="${CPP}" \ + sh ${.CURDIR}/mkioctls ${DESTDIR}/usr/include > ${.TARGET} kdump_subr.c: mksubr sh ${.CURDIR}/mksubr ${DESTDIR}/usr/include > ${.TARGET} Modified: stable/9/usr.bin/kdump/mkioctls ============================================================================== --- stable/9/usr.bin/kdump/mkioctls Wed Apr 18 19:34:20 2012 (r234443) +++ stable/9/usr.bin/kdump/mkioctls Wed Apr 18 20:32:07 2012 (r234444) @@ -29,7 +29,7 @@ ioctl_includes=` ` awk -v x="$ioctl_includes" 'BEGIN {print x}' | - gcc -E -I$1 -dM -DCOMPAT_43TTY - | + $CPP -I$1 -dM -DCOMPAT_43TTY - | awk -v ioctl_includes="$ioctl_includes" -v use_switch="$use_switch" ' BEGIN { print "/* XXX obnoxious prerequisites. */" Modified: stable/9/usr.bin/truss/Makefile ============================================================================== --- stable/9/usr.bin/truss/Makefile Wed Apr 18 19:34:20 2012 (r234443) +++ stable/9/usr.bin/truss/Makefile Wed Apr 18 20:32:07 2012 (r234444) @@ -23,7 +23,8 @@ syscalls.h: syscalls.master ${.CURDIR}/i386.conf ioctl.c: ${.CURDIR}/../kdump/mkioctls - sh ${.CURDIR}/../kdump/mkioctls ${DESTDIR}/usr/include > ${.TARGET} + env CPP="${CPP}" \ + sh ${.CURDIR}/../kdump/mkioctls ${DESTDIR}/usr/include > ${.TARGET} .if ${MACHINE_CPUARCH} == "i386" SRCS+= i386-linux.c linux_syscalls.h From owner-svn-src-all@FreeBSD.ORG Wed Apr 18 22:56:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5216C106564A; Wed, 18 Apr 2012 22:56:47 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3CE938FC08; Wed, 18 Apr 2012 22:56:47 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3IMulWX054117; Wed, 18 Apr 2012 22:56:47 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3IMulR0054115; Wed, 18 Apr 2012 22:56:47 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201204182256.q3IMulR0054115@svn.freebsd.org> From: Devin Teske Date: Wed, 18 Apr 2012 22:56: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: r234446 - head/usr.bin/calendar/calendars X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Apr 2012 22:56:47 -0000 Author: dteske Date: Wed Apr 18 22:56:46 2012 New Revision: 234446 URL: http://svn.freebsd.org/changeset/base/234446 Log: Add my birth date/place to the calendar as new committer. Approved by: emaste (mentor) Modified: head/usr.bin/calendar/calendars/calendar.freebsd Modified: head/usr.bin/calendar/calendars/calendar.freebsd ============================================================================== --- head/usr.bin/calendar/calendars/calendar.freebsd Wed Apr 18 21:08:53 2012 (r234445) +++ head/usr.bin/calendar/calendars/calendar.freebsd Wed Apr 18 22:56:46 2012 (r234446) @@ -181,6 +181,7 @@ 06/04 Justin Gibbs born in San Pedro, California, United States, 1973 06/04 Jason Evans born in Greeley, Colorado, United States, 1973 06/04 Thomas Moestl born in Braunschweig, Niedersachsen, Germany, 1980 +06/04 Devin Teske born in Arcadia, California, United States, 1982 06/04 Zack Kirsch born in Memphis, Tennessee, United States, 1982 06/06 Sergei Kolobov born in Karpinsk, Russian Federation, 1972 06/06 Alan Eldridge died in Denver, Colorado, 2003 From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 02:48:33 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A4E2F106564A; Thu, 19 Apr 2012 02:48:33 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 5FA3F8FC0A; Thu, 19 Apr 2012 02:48:33 +0000 (UTC) Received: by pbcwz17 with SMTP id wz17so10282412pbc.13 for ; Wed, 18 Apr 2012 19:48:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=references:in-reply-to:mime-version:content-type :content-transfer-encoding:message-id:cc:x-mailer:from:subject:date :to; bh=fBXDzGd0AwyzdhAT7MFq+j0t5UbterKoD5zH65vjqs4=; b=AFXczCb34Qt6ugQX0LLAfIiAQYFUP2wBDDU335u1KJNwz0Yvn2g4IzGfxTotN46WW8 2OA9YS9UzR1bapz1qIK5aEGVsInkF1jqCr931UnQtxzE3PSo7lKFbw8YesVrqtvzl18s l2Q3HG49Q4w0xBRt7ZL6uUf5qW9+tBExKw9/0amjXqzoXGc6k1emnAKp+dwPAgelPEK6 c1AdiDRjMutbN9Bp5+ctIKi1uwrcgUqF7GJwaF+jLiyPWGmMPLQqPKKnjjHwhLTRrSQn j8UhpsxQjopGJ0C1gTMClD+SQNZxBPdDRWU8p5a9WiEPdktSQOxSByyhTAEh1xUBm4U1 sA5w== Received: by 10.68.221.74 with SMTP id qc10mr1189964pbc.80.1334803712827; Wed, 18 Apr 2012 19:48:32 -0700 (PDT) Received: from [10.67.255.244] (mobile-166-147-082-087.mycingular.net. [166.147.82.87]) by mx.google.com with ESMTPS id i1sm867332pbj.70.2012.04.18.19.48.28 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 18 Apr 2012 19:48:31 -0700 (PDT) References: <201204181647.q3IGlvjq040763@svn.freebsd.org> In-Reply-To: <201204181647.q3IGlvjq040763@svn.freebsd.org> Mime-Version: 1.0 (1.0) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Message-Id: X-Mailer: iPhone Mail (9B176) From: Garrett Cooper Date: Wed, 18 Apr 2012 19:48:19 -0700 To: Josh Paetzel Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" Subject: Re: svn commit: r234425 - in head: sbin/iscontrol sys/modules/iscsi/initiator X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 02:48:33 -0000 On Apr 18, 2012, at 9:47 AM, Josh Paetzel wrote: > Author: jpaetzel > Date: Wed Apr 18 16:47:57 2012 > New Revision: 234425 > URL: http://svn.freebsd.org/changeset/base/234425 >=20 > Log: > Unbreak tinderbox. >=20 > Fix FreeBSD paradigms in the upstream code. >=20 > PR: bin/166933 > Submitted by: Garrett Cooper >=20 > Modified: > head/sbin/iscontrol/Makefile > head/sbin/iscontrol/iscontrol.c > head/sys/modules/iscsi/initiator/Makefile >=20 > Modified: head/sbin/iscontrol/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/sbin/iscontrol/Makefile Wed Apr 18 16:29:55 2012 (r234424) > +++ head/sbin/iscontrol/Makefile Wed Apr 18 16:47:57 2012 (r234425) > @@ -7,8 +7,7 @@ LDADD=3D -lcam -lmd > S=3D ${.CURDIR}/../../sys >=20 > WARNS?=3D 3 > -CFLAGS +=3D -I$S > -CFLAGS +=3D -g -DDEBUG > +CFLAGS+=3D -I$S >=20 > MAN=3D iscsi.conf.5 iscontrol.8 >=20 >=20 > Modified: head/sbin/iscontrol/iscontrol.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=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/sbin/iscontrol/iscontrol.c Wed Apr 18 16:29:55 2012 (r23442= 4) > +++ head/sbin/iscontrol/iscontrol.c Wed Apr 18 16:47:57 2012 (r23442= 5) > @@ -44,13 +44,15 @@ __FBSDID("$FreeBSD$"); > #include > #include > #include > -#include > -#include > -#include > -#include > +#include > #include > #include > +#include > +#include > +#include > +#include > #include > +#include > #include >=20 > #include > @@ -111,6 +113,13 @@ isc_opt_t opvals =3D { > .immediateData =3D TRUE, > }; >=20 > +static void > +usage(const char *pname) > +{ > + fprintf(stderr, "usage: %s " USAGE "\n", pname); > + exit(1); > +} > + > int > lookup(token_t *tbl, char *m) > { > @@ -135,8 +144,8 @@ main(int cc, char **vv) > iscsidev =3D "/dev/"ISCSIDEV; > fd =3D NULL; > pname =3D vv[0]; > - if((p =3D strrchr(pname, '/')) !=3D NULL) > - pname =3D p + 1; > + if ((pname =3D basename(pname)) =3D=3D NULL) > + err(1, "basename"); >=20 > kw =3D ta =3D 0; > disco =3D 0; > @@ -145,17 +154,21 @@ main(int cc, char **vv) > | check for driver & controller version match > */ > n =3D 0; > - if(sysctlbyname("net.iscsi_initiator.driver_version", 0, &n, 0, 0) != =3D 0) > - perror("sysctlbyname"); > - v =3D malloc(n+1); > - if(sysctlbyname("net.iscsi_initiator.driver_version", v, &n, 0, 0) != =3D 0) > - perror("sysctlbyname"); > - > - if(strncmp(version, v, 3)) { > - fprintf(stderr, "versions missmatch\n"); > - exit(1); > +#define VERSION_OID_S "net.iscsi_initiator.driver_version" > + if (sysctlbyname(VERSION_OID_S, 0, &n, 0, 0) !=3D 0) { > + if (errno =3D=3D ENOENT) > + errx(1, "sysctlbyname(\"" VERSION_OID_S "\") " > + "failed; is the iscsi driver loaded?"); > + err(1, "sysctlbyname(\"" VERSION_OID_S "\")"); > } > + v =3D malloc(n+1); > + if (v =3D=3D NULL) > + err(1, "malloc"); > + if (sysctlbyname(VERSION_OID_S, v, &n, 0, 0) !=3D 0) > + err(1, "sysctlbyname"); >=20 > + if (strncmp(version, v, 3) !=3D 0) > + errx(1, "versions mismatch"); >=20 > while((ch =3D getopt(cc, vv, OPTIONS)) !=3D -1) { > switch(ch) { > @@ -164,10 +177,8 @@ main(int cc, char **vv) > break; > case 'c': > fd =3D fopen(optarg, "r"); > - if(fd =3D=3D NULL) { > - perror(optarg); > - exit(1); > - } > + if (fd =3D=3D NULL) > + err(1, "fopen(\"%s\")", optarg); > break; > case 'd': > disco =3D 1; > @@ -182,9 +193,7 @@ main(int cc, char **vv) > pidfile =3D optarg; > break; > default: > - badu: > - fprintf(stderr, "Usage: %s %s\n", pname, USAGE); > - exit(1); > + usage(pname); > } > } > if(fd =3D=3D NULL) > @@ -205,8 +214,8 @@ main(int cc, char **vv) > op->targetAddress =3D ta; >=20 > if(op->targetAddress =3D=3D NULL) { > - fprintf(stderr, "No target!\n"); > - goto badu; > + warnx("no target specified!"); > + usage(pname); > } > q =3D op->targetAddress; > if(*q =3D=3D '[' && (q =3D strchr(q, ']')) !=3D NULL) { > @@ -224,7 +233,7 @@ main(int cc, char **vv) > op->targetPortalGroupTag =3D atoi(p); > } > if(op->initiatorName =3D=3D 0) { > - char hostname[256]; > + char hostname[MAXHOSTNAMELEN]; >=20 > if(op->iqn) { > if(gethostname(hostname, sizeof(hostname)) =3D=3D 0) >=20 > Modified: head/sys/modules/iscsi/initiator/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/sys/modules/iscsi/initiator/Makefile Wed Apr 18 16:29:55 2012 = (r234424) > +++ head/sys/modules/iscsi/initiator/Makefile Wed Apr 18 16:47:57 2012 = (r234425) > @@ -10,7 +10,9 @@ SRCS+=3D iscsi.c isc_cam.c isc_soc.c isc_s > SRCS+=3D opt_cam.h opt_iscsi_initiator.h > SRCS+=3D bus_if.h device_if.h > #CFLAGS+=3D -DNO_USE_MBUF > +CFLAGS+=3D -DISCSI_INITIATOR_DEBUG=3D2 > #CFLAGS+=3D -DISCSI_INITIATOR_DEBUG=3D2 > +CFLAGS+=3D -DINVARIANTS > CFLAGS+=3D -I$S > CFLAGS+=3D -DINVARIANTS > .include Uh... Somehow the diff I provided got reversed. This commit broke tinderbox [= again] ;/... -Garrett From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 02:55:14 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 78E3B106566B; Thu, 19 Apr 2012 02:55:14 +0000 (UTC) (envelope-from obrien@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 63B338FC15; Thu, 19 Apr 2012 02:55:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3J2tEbW061755; Thu, 19 Apr 2012 02:55:14 GMT (envelope-from obrien@svn.freebsd.org) Received: (from obrien@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3J2tEaY061753; Thu, 19 Apr 2012 02:55:14 GMT (envelope-from obrien@svn.freebsd.org) Message-Id: <201204190255.q3J2tEaY061753@svn.freebsd.org> From: "David E. O'Brien" Date: Thu, 19 Apr 2012 02:55:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234448 - stable/7/sys/sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 02:55:14 -0000 Author: obrien Date: Thu Apr 19 02:55:13 2012 New Revision: 234448 URL: http://svn.freebsd.org/changeset/base/234448 Log: MFC r215821: Add a missing CTL description from CVS revision 1.147. Modified: stable/7/sys/sys/sysctl.h Directory Properties: stable/7/ (props changed) stable/7/sys/ (props changed) Modified: stable/7/sys/sys/sysctl.h ============================================================================== --- stable/7/sys/sys/sysctl.h Thu Apr 19 02:30:04 2012 (r234447) +++ stable/7/sys/sys/sysctl.h Thu Apr 19 02:55:13 2012 (r234448) @@ -452,6 +452,7 @@ TAILQ_HEAD(sysctl_ctx_list, sysctl_ctx_e { "logsigexit", CTLTYPE_INT }, \ { "iov_max", CTLTYPE_INT }, \ { "hostuuid", CTLTYPE_STRING }, \ + { "arc4rand", CTLTYPE_OPAQUE }, \ } /* From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 03:20:14 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5E73A106564A; Thu, 19 Apr 2012 03:20:14 +0000 (UTC) (envelope-from obrien@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4761C8FC12; Thu, 19 Apr 2012 03:20:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3J3KEnc062906; Thu, 19 Apr 2012 03:20:14 GMT (envelope-from obrien@svn.freebsd.org) Received: (from obrien@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3J3KD2h062891; Thu, 19 Apr 2012 03:20:13 GMT (envelope-from obrien@svn.freebsd.org) Message-Id: <201204190320.q3J3KD2h062891@svn.freebsd.org> From: "David E. O'Brien" Date: Thu, 19 Apr 2012 03:20: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: r234449 - in head: contrib/file contrib/file/Magdir contrib/file/tests lib/libmagic usr.bin/file X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 03:20:14 -0000 Author: obrien Date: Thu Apr 19 03:20:13 2012 New Revision: 234449 URL: http://svn.freebsd.org/changeset/base/234449 Log: Update file(1) to version 5.11. Added: head/contrib/file/Magdir/assembler - copied unchanged from r234250, vendor/file/dist/Magdir/assembler head/contrib/file/Magdir/blcr - copied unchanged from r234250, vendor/file/dist/Magdir/blcr head/contrib/file/Magdir/bsi - copied unchanged from r234250, vendor/file/dist/Magdir/bsi head/contrib/file/Magdir/cups - copied unchanged from r234250, vendor/file/dist/Magdir/cups head/contrib/file/Magdir/ebml - copied unchanged from r234250, vendor/file/dist/Magdir/ebml head/contrib/file/Magdir/fusecompress - copied unchanged from r234250, vendor/file/dist/Magdir/fusecompress head/contrib/file/Magdir/geo - copied unchanged from r234250, vendor/file/dist/Magdir/geo head/contrib/file/Magdir/guile - copied unchanged from r234250, vendor/file/dist/Magdir/guile head/contrib/file/Magdir/isz - copied unchanged from r234250, vendor/file/dist/Magdir/isz head/contrib/file/Magdir/m4 - copied unchanged from r234250, vendor/file/dist/Magdir/m4 head/contrib/file/Magdir/make - copied unchanged from r234250, vendor/file/dist/Magdir/make head/contrib/file/Magdir/marc21 - copied unchanged from r234250, vendor/file/dist/Magdir/marc21 head/contrib/file/Magdir/metastore - copied unchanged from r234250, vendor/file/dist/Magdir/metastore head/contrib/file/Magdir/msooxml - copied unchanged from r234250, vendor/file/dist/Magdir/msooxml head/contrib/file/Magdir/music - copied unchanged from r234250, vendor/file/dist/Magdir/music head/contrib/file/Magdir/oasis - copied unchanged from r234250, vendor/file/dist/Magdir/oasis head/contrib/file/Magdir/parrot - copied unchanged from r234250, vendor/file/dist/Magdir/parrot head/contrib/file/Magdir/pascal - copied unchanged from r234250, vendor/file/dist/Magdir/pascal head/contrib/file/Magdir/rinex - copied unchanged from r234250, vendor/file/dist/Magdir/rinex head/contrib/file/Magdir/selinux - copied unchanged from r234250, vendor/file/dist/Magdir/selinux head/contrib/file/Magdir/sisu - copied unchanged from r234250, vendor/file/dist/Magdir/sisu head/contrib/file/Magdir/smile - copied unchanged from r234250, vendor/file/dist/Magdir/smile head/contrib/file/Magdir/ssh - copied unchanged from r234250, vendor/file/dist/Magdir/ssh head/contrib/file/Magdir/ssl - copied unchanged from r234250, vendor/file/dist/Magdir/ssl head/contrib/file/Magdir/tcl - copied unchanged from r234250, vendor/file/dist/Magdir/tcl head/contrib/file/Magdir/virtual - copied unchanged from r234250, vendor/file/dist/Magdir/virtual head/contrib/file/Magdir/wsdl - copied unchanged from r234250, vendor/file/dist/Magdir/wsdl head/contrib/file/Magdir/zfs - copied unchanged from r234250, vendor/file/dist/Magdir/zfs head/contrib/file/getline.c - copied unchanged from r234250, vendor/file/dist/getline.c Deleted: head/contrib/file/Magdir/alpha head/contrib/file/Magdir/psion head/contrib/file/patchlevel.h Modified: head/contrib/file/ChangeLog head/contrib/file/Header head/contrib/file/INSTALL head/contrib/file/Magdir/acorn head/contrib/file/Magdir/adi head/contrib/file/Magdir/adventure head/contrib/file/Magdir/allegro head/contrib/file/Magdir/alliant head/contrib/file/Magdir/amanda head/contrib/file/Magdir/amigaos head/contrib/file/Magdir/animation head/contrib/file/Magdir/apl head/contrib/file/Magdir/apple head/contrib/file/Magdir/applix head/contrib/file/Magdir/archive head/contrib/file/Magdir/asterix head/contrib/file/Magdir/att3b head/contrib/file/Magdir/audio head/contrib/file/Magdir/basis head/contrib/file/Magdir/bflt head/contrib/file/Magdir/blender head/contrib/file/Magdir/blit head/contrib/file/Magdir/bout head/contrib/file/Magdir/bsdi head/contrib/file/Magdir/btsnoop head/contrib/file/Magdir/c-lang head/contrib/file/Magdir/c64 head/contrib/file/Magdir/cad head/contrib/file/Magdir/cafebabe head/contrib/file/Magdir/cddb head/contrib/file/Magdir/chord head/contrib/file/Magdir/cisco head/contrib/file/Magdir/citrus head/contrib/file/Magdir/clarion head/contrib/file/Magdir/claris head/contrib/file/Magdir/clipper head/contrib/file/Magdir/commands head/contrib/file/Magdir/communications head/contrib/file/Magdir/compress head/contrib/file/Magdir/console head/contrib/file/Magdir/convex head/contrib/file/Magdir/cracklib head/contrib/file/Magdir/ctags head/contrib/file/Magdir/dact head/contrib/file/Magdir/database head/contrib/file/Magdir/diamond head/contrib/file/Magdir/diff head/contrib/file/Magdir/digital head/contrib/file/Magdir/dolby head/contrib/file/Magdir/dump head/contrib/file/Magdir/dyadic head/contrib/file/Magdir/editors head/contrib/file/Magdir/efi head/contrib/file/Magdir/elf head/contrib/file/Magdir/encore head/contrib/file/Magdir/epoc head/contrib/file/Magdir/erlang head/contrib/file/Magdir/esri head/contrib/file/Magdir/fcs head/contrib/file/Magdir/filesystems head/contrib/file/Magdir/flash head/contrib/file/Magdir/fonts head/contrib/file/Magdir/fortran head/contrib/file/Magdir/frame head/contrib/file/Magdir/freebsd head/contrib/file/Magdir/fsav head/contrib/file/Magdir/games head/contrib/file/Magdir/gcc head/contrib/file/Magdir/geos head/contrib/file/Magdir/gimp head/contrib/file/Magdir/gnome-keyring head/contrib/file/Magdir/gnu head/contrib/file/Magdir/gnumeric head/contrib/file/Magdir/grace head/contrib/file/Magdir/graphviz head/contrib/file/Magdir/gringotts head/contrib/file/Magdir/hitachi-sh head/contrib/file/Magdir/hp head/contrib/file/Magdir/human68k head/contrib/file/Magdir/ibm370 head/contrib/file/Magdir/ibm6000 head/contrib/file/Magdir/iff head/contrib/file/Magdir/images head/contrib/file/Magdir/inform head/contrib/file/Magdir/intel head/contrib/file/Magdir/interleaf head/contrib/file/Magdir/island head/contrib/file/Magdir/ispell head/contrib/file/Magdir/java head/contrib/file/Magdir/jpeg head/contrib/file/Magdir/karma head/contrib/file/Magdir/kde head/contrib/file/Magdir/kml head/contrib/file/Magdir/lecter head/contrib/file/Magdir/lex head/contrib/file/Magdir/lif head/contrib/file/Magdir/linux head/contrib/file/Magdir/lisp head/contrib/file/Magdir/llvm head/contrib/file/Magdir/lua head/contrib/file/Magdir/luks head/contrib/file/Magdir/mach head/contrib/file/Magdir/macintosh head/contrib/file/Magdir/magic head/contrib/file/Magdir/mail.news head/contrib/file/Magdir/maple head/contrib/file/Magdir/mathcad head/contrib/file/Magdir/mathematica head/contrib/file/Magdir/matroska head/contrib/file/Magdir/mcrypt head/contrib/file/Magdir/mercurial head/contrib/file/Magdir/mime head/contrib/file/Magdir/mips head/contrib/file/Magdir/mirage head/contrib/file/Magdir/misctools head/contrib/file/Magdir/mkid head/contrib/file/Magdir/mlssa head/contrib/file/Magdir/mmdf head/contrib/file/Magdir/modem head/contrib/file/Magdir/motorola head/contrib/file/Magdir/mozilla head/contrib/file/Magdir/msdos head/contrib/file/Magdir/msvc head/contrib/file/Magdir/mup head/contrib/file/Magdir/natinst head/contrib/file/Magdir/ncr head/contrib/file/Magdir/netbsd head/contrib/file/Magdir/netscape head/contrib/file/Magdir/netware head/contrib/file/Magdir/news head/contrib/file/Magdir/nitpicker head/contrib/file/Magdir/ocaml head/contrib/file/Magdir/octave head/contrib/file/Magdir/ole2compounddocs head/contrib/file/Magdir/olf head/contrib/file/Magdir/os2 head/contrib/file/Magdir/os400 head/contrib/file/Magdir/os9 head/contrib/file/Magdir/osf1 head/contrib/file/Magdir/palm head/contrib/file/Magdir/parix head/contrib/file/Magdir/pbm head/contrib/file/Magdir/pdf head/contrib/file/Magdir/pdp head/contrib/file/Magdir/perl head/contrib/file/Magdir/pgp head/contrib/file/Magdir/pkgadd head/contrib/file/Magdir/plan9 head/contrib/file/Magdir/plus5 head/contrib/file/Magdir/printer head/contrib/file/Magdir/project head/contrib/file/Magdir/psdbms head/contrib/file/Magdir/pulsar head/contrib/file/Magdir/pyramid head/contrib/file/Magdir/python head/contrib/file/Magdir/revision head/contrib/file/Magdir/riff head/contrib/file/Magdir/rpm head/contrib/file/Magdir/rtf head/contrib/file/Magdir/ruby head/contrib/file/Magdir/sc head/contrib/file/Magdir/sccs head/contrib/file/Magdir/scientific head/contrib/file/Magdir/securitycerts head/contrib/file/Magdir/sendmail head/contrib/file/Magdir/sequent head/contrib/file/Magdir/sgi head/contrib/file/Magdir/sgml head/contrib/file/Magdir/sharc head/contrib/file/Magdir/sinclair head/contrib/file/Magdir/sketch head/contrib/file/Magdir/smalltalk head/contrib/file/Magdir/sniffer head/contrib/file/Magdir/softquad head/contrib/file/Magdir/spec head/contrib/file/Magdir/spectrum head/contrib/file/Magdir/sql head/contrib/file/Magdir/sun head/contrib/file/Magdir/sysex head/contrib/file/Magdir/teapot head/contrib/file/Magdir/terminfo head/contrib/file/Magdir/tex head/contrib/file/Magdir/tgif head/contrib/file/Magdir/ti-8x head/contrib/file/Magdir/timezone head/contrib/file/Magdir/troff head/contrib/file/Magdir/tuxedo head/contrib/file/Magdir/typeset head/contrib/file/Magdir/unicode head/contrib/file/Magdir/unknown head/contrib/file/Magdir/uuencode head/contrib/file/Magdir/varied.out head/contrib/file/Magdir/varied.script head/contrib/file/Magdir/vax head/contrib/file/Magdir/vicar head/contrib/file/Magdir/virtutech head/contrib/file/Magdir/visx head/contrib/file/Magdir/vms head/contrib/file/Magdir/vmware head/contrib/file/Magdir/vorbis head/contrib/file/Magdir/vxl head/contrib/file/Magdir/warc head/contrib/file/Magdir/weak head/contrib/file/Magdir/windows head/contrib/file/Magdir/wireless head/contrib/file/Magdir/wordprocessors head/contrib/file/Magdir/xdelta head/contrib/file/Magdir/xenix head/contrib/file/Magdir/xilinx head/contrib/file/Magdir/xo65 head/contrib/file/Magdir/xwindows head/contrib/file/Magdir/zilog head/contrib/file/Magdir/zyxel head/contrib/file/Makefile.am head/contrib/file/Makefile.am-src head/contrib/file/Makefile.in head/contrib/file/README head/contrib/file/TODO head/contrib/file/acinclude.m4 head/contrib/file/aclocal.m4 head/contrib/file/apprentice.c head/contrib/file/apptype.c head/contrib/file/ascmagic.c head/contrib/file/asprintf.c head/contrib/file/cdf.c head/contrib/file/cdf.h head/contrib/file/cdf_time.c head/contrib/file/compile head/contrib/file/compress.c head/contrib/file/config.h.in head/contrib/file/configure head/contrib/file/configure.ac head/contrib/file/elfclass.h head/contrib/file/encoding.c head/contrib/file/file.c head/contrib/file/file.h head/contrib/file/file.man head/contrib/file/file_opts.h head/contrib/file/fsmagic.c head/contrib/file/funcs.c head/contrib/file/install-sh head/contrib/file/is_tar.c head/contrib/file/libmagic.man head/contrib/file/magic.c head/contrib/file/magic.h head/contrib/file/magic.man head/contrib/file/print.c head/contrib/file/readcdf.c head/contrib/file/readelf.c head/contrib/file/readelf.h head/contrib/file/softmagic.c head/contrib/file/tar.h head/contrib/file/tests/Makefile.am head/contrib/file/tests/Makefile.in head/contrib/file/vasprintf.c head/lib/libmagic/Makefile head/lib/libmagic/config.h head/usr.bin/file/Makefile Directory Properties: head/contrib/file/ (props changed) Modified: head/contrib/file/ChangeLog ============================================================================== --- head/contrib/file/ChangeLog Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/ChangeLog Thu Apr 19 03:20:13 2012 (r234449) @@ -1,3 +1,309 @@ +2012-02-20 17:33 Christos Zoulas + + * Fix CDF parsing issues found by CERT's fuzzing tool (Will Dormann) + +2011-12-15 12:17 Chris Metcalf + + * Support Tilera architectures (tile64, tilepro, tilegx). + +2011-12-16 16:33 Reuben Thomas + + * Add magic for /usr/bin/env Perl scripts + * Weaken generic script magic to avoid clashing with + language-specific magic. + +2011-12-08 13:37 Reuben Thomas + + * Simplify if (p) free(p) to free(p). + +2011-12-08 13:07 Reuben Thomas + + * Remove hardwired token finding (names.h), turning it into soft + magic. Patterns are either anchored regexs or search/8192. English + language detection and PL/1 detection have been removed as they + were too fragile. -e tokens is still accepted for backwards + compatibility. + * Move 3ds patterns (which are commented out anyway) into autodesk + (they were, oddly, in c-lang). + +2011-12-06 00:16 Reuben Thomas + + * Tweak strength of generic hash-bang detectors to be less than + specific ones. + * Make an inconsistent description of Python scripts consistent. + +2011-12-05 23:58 Reuben Thomas + + * Fix minor error in file(1). + +2011-11-05 00:00 Reuben Thomas + + * Fix issue #150 (I hope). + +2011-09-22 12:57 Christos Zoulas + + * Python3 binding fixes from Kelly Anderson + +2011-09-20 11:32 Christos Zoulas + + * If a string type magic entry is marked as text or binary + only match text files against text entries and binary + files against binary entries. + +2011-09-01 12:12 Christos Zoulas + + * Don't wait for any subprocess, just the one we forked. + +2011-08-26 16:40 Christos Zoulas + + * If the application name is not set in a cdf file, try to see + if it has a directory with the application name on it. + +2011-08-17 14:32 Christos Zoulas + + * Fix ELF lseek(2) madness. Inspired by PR/134 by Jan Kaluza + +2011-08-14 09:03 Christos Zoulas + + * Don't use variable string formats. + +2011-07-12 12:32 Reuben Thomas + + * Fix detection of Zip files (Mantis #128). + * Make some minor improvements to file(1). + * Rename MIME types for filesystem objects for consistency with + xdg-utils. Typically this means that application/x-foo becomes + inode/foo, but some names also change slightly, e.g. + application/x-character-device becomes inode/chardevice. + +2011-05-10 20:57 Christos Zoulas + + * fix mingw compilation (Abradoks) + +2011-05-10 20:57 Christos Zoulas + + * remove patchlevel.h + * Fix read past allocated memory caused by double-incrementing + a pointer in a loop (reported by Roberto Maar) + +2011-03-30 15:45 Christos Zoulas + + * Fix cdf string buffer setting (Sven Anders) + +2011-03-20 16:35 Christos Zoulas + + * Eliminate MAXPATHLEN and use dynamic allocation for + path and file buffers. + +2011-03-15 18:15 Christos Zoulas + + * binary tests on magic entries with masks could spuriously + get converted to ascii. + +2011-03-12 18:06 Reuben Thomas + + * Improve file.man (remove BUGS, present email addresses consistently). + +2011-03-07 19:38 Christos Zoulas + + * add lrzip support (from Ville Skytta) + +2011-02-10 16:36 Christos Zoulas + + * fix CDF bounds checking (Guy Helmer) + +2011-02-10 12:03 Christos Zoulas + + * add cdf_ctime() that prints a meaningful error when time cannot + be converted. + +2011-02-02 20:40 Christos Zoulas + + * help and version output to stdout. + + * When matching softmagic for ascii files, don't just print + the softmagic classification, keep going and print the + text classification too. This fixes broken troff files when + we moved them from keyword recognition to softmagic + (they stopped printing "with CRLF" etc.) + Reported by Doug McIlroy. + +2011-01-16 19:31 Reuben Thomas + + * Fix two potential buffer overruns in apprentice_list. + +2011-01-14 22:33 Reuben Thomas + + * New Python binding in pure Python. + * Update libmagic(3). + +2011-01-06 21:40 Reuben Thomas + + * Fix Python bindings (including recent Python 3 compatibility + update). + +2011-01-04 18:43 Reuben Thomas + + * magic/Makefile.am: make it easier to recover from magic build failures. + * Fix pstring length specifier parsing to avoid generating invalid + magic files. + * Add pstring length "J" (for "JPEG") to specify that the length + include itself. + * Fix JPEG comment parsing at last using pstring/HJ! + * Ignore section 5 man pages in doc/.cvsignore. + +2010-12-22 13:12 Christos Zoulas + + * Add pstring/BHhLl to specify the type of the length of pascal + strings. + +2010-11-26 18:39 Reuben Thomas + + * Fix "-e soft": it was ignored when softmagic was called + during asciimagic. + * Improve comments and use "unsigned char" in tar.h/is_tar.c. + +2010-11-05 17:26 Reuben Thomas + + * Make bug reporting addresses more visible. + +2010-11-01 18:35 Reuben Thomas + + * Add tcl magic from Gustaf Neumann + +2010-10-24 10:42 Christos Zoulas + + * Fix the whitespace comparing code (Christopher Chittleborough) + +2010-10-06 21:05 Christos Zoulas + + * allow string/t to work (Jan Kaluza) + +2010-09-20 22:11 Reuben Thomas + + * Apply some patches from Ubuntu and Fedora. + +2010-09-20 21:16 Reuben Thomas + + * Apply all patches from Debian package 5.04-6 which have not + already been applied and are not Debian-specific. + +2010-09-20 15:24 Reuben Thomas + + * Minor security fix to softmagic.c (don't use untrusted + string as printf format). + +2010-07-21 12:20 Christos Zoulas + + * MINGW32 portability from LRN + + * Don't warn about escaping magic regex chars when we are in a regex. + +2010-07-19 10:55 Christos Zoulas + + * Only try to print prpsinfo for core files. (Jan Kaluza) + +2010-04-22 12:55 Christos Zoulas + + * Try more elf offsets for Debian core files. (Arnaud Giersch) + +2010-02-20 15:18 Reuben Thomas + + * Clarify which sort of CDF we mean. + +2010-02-14 22:58 Reuben Thomas + + * Re-jig Zip file type magic so that unsupported special + Zip types (those with "mimetype" at offset 30) can be + recognized. + +2010-02-02 21:50 Reuben Thomas + + * Add support for OCF (EPUB) files (application/epub+zip) + +2010-01-28 18:25 Christos Zoulas + + * Fix core-dump from unbound loop: + https://bugzilla.redhat.com/show_bug.cgi?id=533245 + +2010-01-22 15:45 Christos Zoulas + + * print proper mime for crystal reports file + + * print the last summary information of a cdf document, not the + first so that nested documents print the right info + +2010-01-16 18:42 Charles Longeau + + * bring back some fixes from OpenBSD: + - make gcc2 builds file + - fix typos in a magic file comment + +2009-11-17 18:35 Christos Zoulas + + * ctime/asctime can return NULL on some OS's although + they should not (Toshit Antani) + +2009-09-14 13:49 Christos Zoulas + + * Centralize magic path handling routines and remove the + special-casing from file.c so that the python module for + example comes up with the same magic path (Fixes ~/.magic + handling) (from Gab) + +2009-09-11 23:38 Reuben Thomas + + * When magic argument is a directory, read the files in + strcmp-sorted order (fixes Debian bug #488562 and our own FIXME). + +2009-09-11 13:11 Reuben Thomas + + * Combine overlapping epoc and psion magic files into one (epoc). + + * Add some more EPOC MIME types. + +2009-08-19 15:55 Christos Zoulas + + * Fix 3 bugs (From Ian Darwin): + - file_showstr could move one past the end of the array + - parse_apple did not nul terminate the string in the overflow case + - parse_mime truncated the wrong string in the overflow case + +2009-08-12 12:28 Robert Byrnes + + * Include Localstuff when compiling magic. + +2009-07-15 10:05 Christos Zoulas + + * Fix logic for including mygetopts.h + + * Make cdf.c compile again with debugging + + * Add the necessary field handling for crystal reports files to work + +2009-06-23 01:34 Reuben Thomas + + * Stop "(if" identifying Lisp files, that's plain dumb! + +2009-06-09 22:13 Reuben Thomas + + * Add a couple of missing MP3 MIME types. + +2009-05-27 23:00 Reuben Thomas + + * Add full range of hash-bang tests for Python and Ruby. + + * Add MIME types for Python and Ruby scripts. + +2009-05-13 10:44 Christos Zoulas + + * off by one in parsing hw capabilities in elf + (Cheng Renquan) + +2009-05-08 13:40 Christos Zoulas + + * lint fixes and more from NetBSD + 2009-05-06 10:25 Christos Zoulas * Avoid null dereference in cdf code (Drew Yao) Modified: head/contrib/file/Header ============================================================================== --- head/contrib/file/Header Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Header Thu Apr 19 03:20:13 2012 (r234449) @@ -1,5 +1,5 @@ -# Magic # Magic data for file(1) command. -# Machine-generated from src/cmd/file/magdir/*; edit there only! # Format is described in magic(files), where: -# files is 5 on V7 and BSD, 4 on SV, and ?? in the SVID. +# files is 5 on V7 and BSD, 4 on SV, and ?? on SVID. +# Don't edit this file, edit /etc/magic or send your magic improvements +# to the maintainers, at file@mx.gw.com Modified: head/contrib/file/INSTALL ============================================================================== --- head/contrib/file/INSTALL Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/INSTALL Thu Apr 19 03:20:13 2012 (r234449) @@ -2,18 +2,24 @@ Installation Instructions ************************* Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005, -2006 Free Software Foundation, Inc. +2006, 2007, 2008, 2009 Free Software Foundation, Inc. -This file is free documentation; the Free Software Foundation gives -unlimited permission to copy, distribute and modify it. + Copying and distribution of this file, with or without modification, +are permitted in any medium without royalty provided the copyright +notice and this notice are preserved. This file is offered as-is, +without warranty of any kind. Basic Installation ================== -Briefly, the shell commands `./configure; make; make install' should + Briefly, the shell commands `./configure; make; make install' should configure, build, and install this package. The following more-detailed instructions are generic; see the `README' file for -instructions specific to this package. +instructions specific to this package. Some packages provide this +`INSTALL' file but do not implement all of the features documented +below. The lack of an optional feature in a given package is not +necessarily a bug. More recommendations for GNU packages can be found +in *note Makefile Conventions: (standards)Makefile Conventions. The `configure' shell script attempts to guess correct values for various system-dependent variables used during compilation. It uses @@ -42,7 +48,7 @@ may remove or edit it. you want to change it or regenerate `configure' using a newer version of `autoconf'. -The simplest way to compile this package is: + The simplest way to compile this package is: 1. `cd' to the directory containing the package's source code and type `./configure' to configure the package for your system. @@ -53,12 +59,22 @@ The simplest way to compile this package 2. Type `make' to compile the package. 3. Optionally, type `make check' to run any self-tests that come with - the package. + the package, generally using the just-built uninstalled binaries. 4. Type `make install' to install the programs and any data files and - documentation. + documentation. When installing into a prefix owned by root, it is + recommended that the package be configured and built as a regular + user, and only the `make install' phase executed with root + privileges. + + 5. Optionally, type `make installcheck' to repeat any self-tests, but + this time using the binaries in their final installed location. + This target does not install anything. Running this target as a + regular user, particularly if the prior `make install' required + root privileges, verifies that the installation completed + correctly. - 5. You can remove the program binaries and object files from the + 6. You can remove the program binaries and object files from the source code directory by typing `make clean'. To also remove the files that `configure' created (so you can compile the package for a different kind of computer), type `make distclean'. There is @@ -67,12 +83,22 @@ The simplest way to compile this package all sorts of other programs in order to regenerate files that came with the distribution. + 7. Often, you can also type `make uninstall' to remove the installed + files again. In practice, not all packages have tested that + uninstallation works correctly, even though it is required by the + GNU Coding Standards. + + 8. Some packages, particularly those that use Automake, provide `make + distcheck', which can by used by developers to test that all other + targets like `make install' and `make uninstall' work correctly. + This target is generally not run by end users. + Compilers and Options ===================== -Some systems require unusual options for compilation or linking that the -`configure' script does not know about. Run `./configure --help' for -details on some of the pertinent environment variables. + Some systems require unusual options for compilation or linking that +the `configure' script does not know about. Run `./configure --help' +for details on some of the pertinent environment variables. You can give `configure' initial values for configuration parameters by setting variables in the command line or in the environment. Here @@ -85,25 +111,41 @@ is an example: Compiling For Multiple Architectures ==================================== -You can compile the package for more than one kind of computer at the + You can compile the package for more than one kind of computer at the same time, by placing the object files for each architecture in their own directory. To do this, you can use GNU `make'. `cd' to the directory where you want the object files and executables to go and run the `configure' script. `configure' automatically checks for the -source code in the directory that `configure' is in and in `..'. +source code in the directory that `configure' is in and in `..'. This +is known as a "VPATH" build. With a non-GNU `make', it is safer to compile the package for one architecture at a time in the source code directory. After you have installed the package for one architecture, use `make distclean' before reconfiguring for another architecture. + On MacOS X 10.5 and later systems, you can create libraries and +executables that work on multiple system types--known as "fat" or +"universal" binaries--by specifying multiple `-arch' options to the +compiler but only a single `-arch' option to the preprocessor. Like +this: + + ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ + CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ + CPP="gcc -E" CXXCPP="g++ -E" + + This is not guaranteed to produce working output in all cases, you +may have to build one architecture at a time and combine the results +using the `lipo' tool if you have problems. + Installation Names ================== -By default, `make install' installs the package's commands under + By default, `make install' installs the package's commands under `/usr/local/bin', include files under `/usr/local/include', etc. You can specify an installation prefix other than `/usr/local' by giving -`configure' the option `--prefix=PREFIX'. +`configure' the option `--prefix=PREFIX', where PREFIX must be an +absolute file name. You can specify separate installation prefixes for architecture-specific files and architecture-independent files. If you @@ -114,16 +156,47 @@ Documentation and other data files still In addition, if you use an unusual directory layout you can give options like `--bindir=DIR' to specify different values for particular kinds of files. Run `configure --help' for a list of the directories -you can set and what kinds of files go in them. +you can set and what kinds of files go in them. In general, the +default for these options is expressed in terms of `${prefix}', so that +specifying just `--prefix' will affect all of the other directory +specifications that were not explicitly provided. + + The most portable way to affect installation locations is to pass the +correct locations to `configure'; however, many packages provide one or +both of the following shortcuts of passing variable assignments to the +`make install' command line to change installation locations without +having to reconfigure or recompile. + + The first method involves providing an override variable for each +affected directory. For example, `make install +prefix=/alternate/directory' will choose an alternate location for all +directory configuration variables that were expressed in terms of +`${prefix}'. Any directories that were specified during `configure', +but not in terms of `${prefix}', must each be overridden at install +time for the entire installation to be relocated. The approach of +makefile variable overrides for each directory variable is required by +the GNU Coding Standards, and ideally causes no recompilation. +However, some platforms have known limitations with the semantics of +shared libraries that end up requiring recompilation when using this +method, particularly noticeable in packages that use GNU Libtool. + + The second method involves providing the `DESTDIR' variable. For +example, `make install DESTDIR=/alternate/directory' will prepend +`/alternate/directory' before all installation names. The approach of +`DESTDIR' overrides is not required by the GNU Coding Standards, and +does not work on platforms that have drive letters. On the other hand, +it does better at avoiding recompilation issues, and works well even +when some directory options were not specified in terms of `${prefix}' +at `configure' time. + +Optional Features +================= If the package supports it, you can cause programs to be installed with an extra prefix or suffix on their names by giving `configure' the option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. -Optional Features -================= - -Some packages pay attention to `--enable-FEATURE' options to + Some packages pay attention to `--enable-FEATURE' options to `configure', where FEATURE indicates an optional part of the package. They may also pay attention to `--with-PACKAGE' options, where PACKAGE is something like `gnu-as' or `x' (for the X Window System). The @@ -135,14 +208,53 @@ find the X include and library files aut you can use the `configure' options `--x-includes=DIR' and `--x-libraries=DIR' to specify their locations. + Some packages offer the ability to configure how verbose the +execution of `make' will be. For these packages, running `./configure +--enable-silent-rules' sets the default to minimal output, which can be +overridden with `make V=1'; while running `./configure +--disable-silent-rules' sets the default to verbose, which can be +overridden with `make V=0'. + +Particular systems +================== + + On HP-UX, the default C compiler is not ANSI C compatible. If GNU +CC is not installed, it is recommended to use the following options in +order to use an ANSI C compiler: + + ./configure CC="cc -Ae -D_XOPEN_SOURCE=500" + +and if that doesn't work, install pre-built binaries of GCC for HP-UX. + + On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot +parse its `' header file. The option `-nodtk' can be used as +a workaround. If GNU CC is not installed, it is therefore recommended +to try + + ./configure CC="cc" + +and if that doesn't work, try + + ./configure CC="cc -nodtk" + + On Solaris, don't put `/usr/ucb' early in your `PATH'. This +directory contains several dysfunctional programs; working variants of +these programs are available in `/usr/bin'. So, if you need `/usr/ucb' +in your `PATH', put it _after_ `/usr/bin'. + + On Haiku, software installed for all users goes in `/boot/common', +not `/usr/local'. It is recommended to use the following options: + + ./configure --prefix=/boot/common + Specifying the System Type ========================== -There may be some features `configure' cannot figure out automatically, -but needs to determine by the type of machine the package will run on. -Usually, assuming the package is built to be run on the _same_ -architectures, `configure' can figure that out, but if it prints a -message saying it cannot guess the machine type, give it the + There may be some features `configure' cannot figure out +automatically, but needs to determine by the type of machine the package +will run on. Usually, assuming the package is built to be run on the +_same_ architectures, `configure' can figure that out, but if it prints +a message saying it cannot guess the machine type, give it the `--build=TYPE' option. TYPE can either be a short name for the system type, such as `sun4', or a canonical name which has the form: @@ -150,7 +262,8 @@ type, such as `sun4', or a canonical nam where SYSTEM can have one of these forms: - OS KERNEL-OS + OS + KERNEL-OS See the file `config.sub' for the possible values of each field. If `config.sub' isn't included in this package, then this package doesn't @@ -168,9 +281,9 @@ eventually be run) with `--host=TYPE'. Sharing Defaults ================ -If you want to set default values for `configure' scripts to share, you -can create a site shell script called `config.site' that gives default -values for variables like `CC', `cache_file', and `prefix'. + If you want to set default values for `configure' scripts to share, +you can create a site shell script called `config.site' that gives +default values for variables like `CC', `cache_file', and `prefix'. `configure' looks for `PREFIX/share/config.site' if it exists, then `PREFIX/etc/config.site' if it exists. Or, you can set the `CONFIG_SITE' environment variable to the location of the site script. @@ -179,7 +292,7 @@ A warning: not all `configure' scripts l Defining Variables ================== -Variables not defined in a site shell script can be set in the + Variables not defined in a site shell script can be set in the environment passed to `configure'. However, some packages may run configure again during the build, and the customized values of these variables may be lost. In order to avoid this problem, you should set @@ -198,11 +311,19 @@ an Autoconf bug. Until the bug is fixed `configure' Invocation ====================== -`configure' recognizes the following options to control how it operates. + `configure' recognizes the following options to control how it +operates. `--help' `-h' - Print a summary of the options to `configure', and exit. + Print a summary of all of the options to `configure', and exit. + +`--help=short' +`--help=recursive' + Print a summary of the options unique to this package's + `configure', and exit. The `short' variant lists options used + only in the top level, while the `recursive' variant lists options + also present in any nested packages. `--version' `-V' @@ -229,6 +350,16 @@ an Autoconf bug. Until the bug is fixed Look for the package's source code in directory DIR. Usually `configure' can determine that directory automatically. +`--prefix=DIR' + Use DIR as the installation prefix. *note Installation Names:: + for more details, including other options available for fine-tuning + the installation locations. + +`--no-create' +`-n' + Run the configure checks, but stop before creating any output + files. + `configure' also accepts some other, not widely useful, options. Run `configure --help' for more details. Modified: head/contrib/file/Magdir/acorn ============================================================================== --- head/contrib/file/Magdir/acorn Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/acorn Thu Apr 19 03:20:13 2012 (r234449) @@ -1,4 +1,6 @@ + #------------------------------------------------------------------------------ +# $File: acorn,v 1.5 2009/09/19 16:28:07 christos Exp $ # acorn: file(1) magic for files found on Acorn systems # Modified: head/contrib/file/Magdir/adi ============================================================================== --- head/contrib/file/Magdir/adi Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/adi Thu Apr 19 03:20:13 2012 (r234449) @@ -1,5 +1,6 @@ #------------------------------------------------------------------------------ +# $File: adi,v 1.4 2009/09/19 16:28:07 christos Exp $ # adi: file(1) magic for ADi's objects # From Gregory McGarry # Modified: head/contrib/file/Magdir/adventure ============================================================================== --- head/contrib/file/Magdir/adventure Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/adventure Thu Apr 19 03:20:13 2012 (r234449) @@ -1,5 +1,6 @@ #------------------------------------------------------------------------------ +# $File: adventure,v 1.13 2010/12/31 16:32:54 christos Exp $ # adventure: file(1) magic for Adventure game files # # from Allen Garvin @@ -16,18 +17,26 @@ # Infocom (see z-machine) #------------------------------------------------------------------------------ # Z-machine: file(1) magic for Z-machine binaries. +# Updated by Adam Buchbinder # -# This will match ${TEX_BASE}/texmf/omega/ocp/char2uni/inbig5.ocp which -# appears to be a version-0 Z-machine binary. -# -# The (false match) message is to correct that behavior. Perhaps it is -# not needed. -# -16 belong&0xfe00f0f0 0x3030 Infocom game data ->0 ubyte 0 (false match) ->0 ubyte >0 (Z-machine %d, ->>2 ubeshort x Release %d / ->>18 string >\0 Serial %.6s) +#http://www.gnelson.demon.co.uk/zspec/sect11.html +#http://www.jczorkmid.net/~jpenney/ZSpec11-latest.txt +#http://en.wikipedia.org/wiki/Z-machine +# The first byte is the Z-machine revision; it is always between 1 and 8. We +# had false matches (for instance, inbig5.ocp from the Omega TeX extension as +# well as an occasional MP3 file), so we sanity-check the version number. +# +# It might be possible to sanity-check the release number as well, as it seems +# (at least in classic Infocom games) to always be a relatively small number, +# always under 150 or so, but as this isn't rigorous, we'll wait on that until +# it becomes clear that it's needed. +# +0 ubyte >0 +>0 ubyte <9 +>>16 belong&0xfe00f0f0 0x3030 Infocom game data +>>>0 ubyte x (Z-machine %d, +>>>>2 ubeshort x Release %d / +>>>>18 string >\0 Serial %.6s) #------------------------------------------------------------------------------ # Glulx: file(1) magic for Glulx binaries. @@ -45,10 +54,9 @@ # For Quetzal and blorb magic see iff -# TADS (Text Adventure Development System) +# TADS (Text Adventure Development System) version 2 # All files are machine-independent (games compile to byte-code) and are tagged -# with a version string of the form "V2..\0" (but TADS 3 is -# on the way). +# with a version string of the form "V2..\0". # Game files start with "TADS2 bin\n\r\032\0" then the compiler version. 0 string TADS2\ bin TADS >9 belong !0x0A0D1A00 game data, CORRUPTED @@ -73,6 +81,19 @@ >10 belong 0x0A0D1A00 >>14 string >\0 %s saved game data +# TADS (Text Adventure Development System) version 3 +# Game files start with "T3-image\015\012\032" +0 string T3-image\015\012\032 +>11 leshort x TADS 3 game data (format version %d) +# Saved game files start with "T3-state-v####\015\012\032" +# where #### is a format version number +0 string T3-state-v +>14 string \015\012\032 TADS 3 saved game data (format version +>>10 byte x %c +>>11 byte x \b%c +>>12 byte x \b%c +>>13 byte x \b%c) + # Danny Milosavljevic # this are adrift (adventure game standard) game files, extension .taf # depending on version magic continues with 0x93453E6139FA (V 4.0) Modified: head/contrib/file/Magdir/allegro ============================================================================== --- head/contrib/file/Magdir/allegro Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/allegro Thu Apr 19 03:20:13 2012 (r234449) @@ -1,4 +1,6 @@ + #------------------------------------------------------------------------------ +# $File: allegro,v 1.4 2009/09/19 16:28:07 christos Exp $ # allegro: file(1) magic for Allegro datafiles # Toby Deshane # Modified: head/contrib/file/Magdir/alliant ============================================================================== --- head/contrib/file/Magdir/alliant Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/alliant Thu Apr 19 03:20:13 2012 (r234449) @@ -1,5 +1,6 @@ #------------------------------------------------------------------------------ +# $File: alliant,v 1.7 2009/09/19 16:28:07 christos Exp $ # alliant: file(1) magic for Alliant FX series a.out files # # If the FX series is the one that had a processor with a 68K-derived Modified: head/contrib/file/Magdir/amanda ============================================================================== --- head/contrib/file/Magdir/amanda Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/amanda Thu Apr 19 03:20:13 2012 (r234449) @@ -1,4 +1,6 @@ + #------------------------------------------------------------------------------ +# $File: amanda,v 1.5 2009/09/19 16:28:07 christos Exp $ # amanda: file(1) magic for amanda file format # 0 string AMANDA:\ AMANDA Modified: head/contrib/file/Magdir/amigaos ============================================================================== --- head/contrib/file/Magdir/amigaos Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/amigaos Thu Apr 19 03:20:13 2012 (r234449) @@ -1,4 +1,6 @@ + #------------------------------------------------------------------------------ +# $File: amigaos,v 1.14 2009/09/19 16:28:07 christos Exp $ # amigaos: file(1) magic for AmigaOS binary formats: # Modified: head/contrib/file/Magdir/animation ============================================================================== --- head/contrib/file/Magdir/animation Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/animation Thu Apr 19 03:20:13 2012 (r234449) @@ -1,5 +1,6 @@ #------------------------------------------------------------------------------ +# $File: animation,v 1.45 2011/09/06 11:00:06 christos Exp $ # animation: file(1) magic for animation/movie formats # # animation formats @@ -29,7 +30,7 @@ #!:mime image/x-quicktime 4 string pckg Apple QuickTime compressed archive !:mime application/x-quicktime-player -4 string/B jP JPEG 2000 image +4 string/W jP JPEG 2000 image !:mime image/jp2 4 string ftyp ISO Media >8 string isom \b, MPEG v4 system, version 1 @@ -41,10 +42,18 @@ !:mime video/mp4 >8 string mp7t \b, MPEG v4 system, MPEG v7 XML >8 string mp7b \b, MPEG v4 system, MPEG v7 binary XML ->8 string/B jp2 \b, JPEG 2000 +>8 string/W jp2 \b, JPEG 2000 !:mime image/jp2 +>8 string 3ge \b, MPEG v4 system, 3GPP +!:mime video/3gpp +>8 string 3gg \b, MPEG v4 system, 3GPP +!:mime video/3gpp >8 string 3gp \b, MPEG v4 system, 3GPP !:mime video/3gpp +>8 string 3gs \b, MPEG v4 system, 3GPP +!:mime video/3gpp +>8 string 3g2 \b, MPEG v4 system, 3GPP2 +!:mime video/3gpp2 >>11 byte 4 \b v4 (H.263/AMR GSM 6.10) >>11 byte 5 \b v5 (H.263/AMR GSM 6.10) >>11 byte 6 \b v6 (ITU H.264/AMR GSM 6.10) @@ -52,13 +61,13 @@ !:mime video/mp4 >8 string avc1 \b, MPEG v4 system, 3GPP JVT AVC !:mime video/3gpp ->8 string/B M4A \b, MPEG v4 system, iTunes AAC-LC +>8 string/W M4A \b, MPEG v4 system, iTunes AAC-LC !:mime audio/mp4 ->8 string/B M4V \b, MPEG v4 system, iTunes AVC-LC +>8 string/W M4V \b, MPEG v4 system, iTunes AVC-LC !:mime video/mp4 ->8 string/B M4P \b, MPEG v4 system, iTunes AES encrypted ->8 string/B M4B \b, MPEG v4 system, iTunes bookmarked ->8 string/B qt \b, Apple QuickTime movie +>8 string/W M4P \b, MPEG v4 system, iTunes AES encrypted +>8 string/W M4B \b, MPEG v4 system, iTunes bookmarked +>8 string/W qt \b, Apple QuickTime movie !:mime video/quicktime # MPEG sequences @@ -71,6 +80,7 @@ >>7 byte x \b @ L %u 0 belong&0xFFFFFF00 0x00000100 >3 byte 0xBA MPEG sequence +!:mime video/mpeg >>4 byte &0x40 \b, v2, program multiplex >>4 byte ^0x40 \b, v1, system multiplex >3 byte 0xBB MPEG sequence, v1/2, multiplex (missing pack header) @@ -80,6 +90,7 @@ >>4 byte 88 \b, extended >>6 byte x \b @ L %u >3 byte 0xB0 MPEG sequence, v4 +!:mime video/mpeg4-generic >>5 belong 0x000001B5 >>>9 byte &0x80 >>>>10 byte&0xF0 16 \b, video @@ -149,6 +160,7 @@ >>4 byte 252 \b, FGS @ L4 >>4 byte 253 \b, FGS @ L5 >3 byte 0xB5 MPEG sequence, v4 +!:mime video/mpeg4-generic >>4 byte &0x80 >>>5 byte&0xF0 16 \b, video (missing profile header) >>>5 byte&0xF0 32 \b, still texture (missing profile header) @@ -159,6 +171,7 @@ >>4 byte&0xF8 24 \b, mesh (missing profile header) >>4 byte&0xF8 32 \b, face (missing profile header) >3 byte 0xB3 MPEG sequence +!:mime video/mpeg >>12 belong 0x000001B8 \b, v1, progressive Y'CbCr 4:2:0 video >>12 belong 0x000001B2 \b, v1, progressive Y'CbCr 4:2:0 video >>12 belong 0x000001B5 \b, v2, @@ -469,6 +482,7 @@ # MPA, M2A 0 beshort&0xFFFE 0xFFF6 MPEG ADTS, layer I, v2 +!:mime audio/mpeg # rate >2 byte&0xF0 0x10 \b, 32 kbps >2 byte&0xF0 0x20 \b, 48 kbps @@ -503,6 +517,7 @@ # MP3, M25A 0 beshort&0xFFFE 0xFFE2 MPEG ADTS, layer III, v2.5 +!:mime audio/mpeg # rate >2 byte&0xF0 0x10 \b, 8 kbps >2 byte&0xF0 0x20 \b, 16 kbps @@ -697,6 +712,7 @@ # Microsoft Advanced Streaming Format (ASF) 0 belong 0x3026b275 Microsoft ASF +!:mime video/x-ms-asf # MNG Video Format, 0 string \x8aMNG MNG video data, @@ -718,16 +734,16 @@ 3 string \x0D\x0AVersion:Vivo Vivo video data # VRML (Virtual Reality Modelling Language) -0 string/b #VRML\ V1.0\ ascii VRML 1 file +0 string/w #VRML\ V1.0\ ascii VRML 1 file !:mime model/vrml -0 string/b #VRML\ V2.0\ utf8 ISO/IEC 14772 VRML 97 file +0 string/w #VRML\ V2.0\ utf8 ISO/IEC 14772 VRML 97 file !:mime model/vrml # X3D (Extensible 3D) [http://www.web3d.org/specifications/x3d-3.0.dtd] # From Michel Briand -0 string \20 search/1000/cb \20 search/1000/cw \ 2008-07-18 0 string BIK Bink Video >3 regex =[a-z] rev.%s @@ -813,3 +830,66 @@ >>51 byte&0x20 !0 stereo #>>51 byte&0x10 0 FFT #>>51 byte&0x10 !0 DCT + +# Type: NUT Container +# URL: http://wiki.multimedia.cx/index.php?title=NUT +# From: Adam Buchbinder +0 string nut/multimedia\ container\0 NUT multimedia container + +# Type: Nullsoft Video (NSV) +# URL: http://wiki.multimedia.cx/index.php?title=Nullsoft_Video +# From: Mike Melanson +0 string NSVf Nullsoft Video + +# Type: REDCode Video +# URL: http://www.red.com/ ; http://wiki.multimedia.cx/index.php?title=REDCode +# From: Mike Melanson +4 string RED1 REDCode Video + +# Type: MTV Multimedia File +# URL: http://wiki.multimedia.cx/index.php?title=MTV +# From: Mike Melanson +0 string AMVS MTV Multimedia File + +# Type: ARMovie +# URL: http://wiki.multimedia.cx/index.php?title=ARMovie +# From: Mike Melanson +0 string ARMovie\012 ARMovie + +# Type: Interplay MVE Movie +# URL: http://wiki.multimedia.cx/index.php?title=Interplay_MVE +# From: Mike Melanson +0 string Interplay\040MVE\040File\032 Interplay MVE Movie + +# Type: Windows Television DVR File +# URL: http://wiki.multimedia.cx/index.php?title=WTV +# From: Mike Melanson +# This takes the form of a Windows-style GUID +0 bequad 0xB7D800203749DA11 +>8 bequad 0xA64E0007E95EAD8D Windows Television DVR Media + +# Type: Sega FILM/CPK Multimedia +# URL: http://wiki.multimedia.cx/index.php?title=Sega_FILM +# From: Mike Melanson +0 string FILM Sega FILM/CPK Multimedia, +>32 belong x %d x +>28 belong x %d + +# Type: Nintendo THP Multimedia +# URL: http://wiki.multimedia.cx/index.php?title=THP +# From: Mike Melanson +0 string THP\0 Nintendo THP Multimedia + +# Type: BBC Dirac Video +# URL: http://wiki.multimedia.cx/index.php?title=Dirac +# From: Mike Melanson +0 string BBCD BBC Dirac Video + +# Type: RAD Game Tools Smacker Multimedia +# URL: http://wiki.multimedia.cx/index.php?title=Smacker +# From: Mike Melanson +0 string SMK RAD Game Tools Smacker Multimedia +>3 byte x version %c, +>4 lelong x %d x +>8 lelong x %d, +>12 lelong x %d frames Modified: head/contrib/file/Magdir/apl ============================================================================== --- head/contrib/file/Magdir/apl Thu Apr 19 02:55:13 2012 (r234448) +++ head/contrib/file/Magdir/apl Thu Apr 19 03:20:13 2012 (r234449) @@ -1,5 +1,6 @@ #------------------------------------------------------------------------------ +# $File: apl,v 1.6 2009/09/19 16:28:07 christos Exp $ # apl: file(1) magic for APL (see also "pdp" and "vax" for other APL # workspaces) # Modified: head/contrib/file/Magdir/apple ============================================================================== --- head/contrib/file/Magdir/apple Thu Apr 19 02:55:13 2012 (r234448) *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 03:26:22 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0E6C4106566C; Thu, 19 Apr 2012 03:26:22 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id EB6288FC08; Thu, 19 Apr 2012 03:26:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3J3QLUj063143; Thu, 19 Apr 2012 03:26:21 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3J3QLIV063135; Thu, 19 Apr 2012 03:26:21 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204190326.q3J3QLIV063135@svn.freebsd.org> From: Adrian Chadd Date: Thu, 19 Apr 2012 03:26: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: r234450 - in head/sys/dev/ath: . ath_hal/ar5210 ath_hal/ar5211 ath_hal/ar5212 ath_hal/ar5312 ath_hal/ar5416 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 03:26:22 -0000 Author: adrian Date: Thu Apr 19 03:26:21 2012 New Revision: 234450 URL: http://svn.freebsd.org/changeset/base/234450 Log: Stop using the hardware register value byte order swapping for now, at least until I can root cause what's going on. The only platform I've seen this on is the AR9220 when attached to the AR71xx CPUs. I get immediate PCIe bus errors and all subsequent accesses cause further MIPS bus exceptions. I don't have any other big-endian platforms to test this on. If I get a chance (or two), I'll try to whack this on a bus analyser and see exactly what happens. I'd rather leave this on, especially for slower, embedded platforms. But the #ifdef hell is something I'm trying to avoid. Modified: head/sys/dev/ath/ah_osdep.c head/sys/dev/ath/ah_osdep.h head/sys/dev/ath/ath_hal/ar5210/ar5210_reset.c head/sys/dev/ath/ath_hal/ar5211/ar5211_reset.c head/sys/dev/ath/ath_hal/ar5212/ar5212_reset.c head/sys/dev/ath/ath_hal/ar5312/ar5312_reset.c head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c Modified: head/sys/dev/ath/ah_osdep.c ============================================================================== --- head/sys/dev/ath/ah_osdep.c Thu Apr 19 03:20:13 2012 (r234449) +++ head/sys/dev/ath/ah_osdep.c Thu Apr 19 03:26:21 2012 (r234450) @@ -267,12 +267,7 @@ ath_hal_reg_write(struct ath_hal *ah, u_ } if (ah->ah_config.ah_serialise_reg_war) mtx_lock_spin(&ah_regser_mtx); -#if _BYTE_ORDER == _BIG_ENDIAN - if (OS_REG_UNSWAPPED(reg)) - bus_space_write_4(tag, h, reg, val); - else -#endif - bus_space_write_stream_4(tag, h, reg, val); + bus_space_write_4(tag, h, reg, val); if (ah->ah_config.ah_serialise_reg_war) mtx_unlock_spin(&ah_regser_mtx); } @@ -286,12 +281,7 @@ ath_hal_reg_read(struct ath_hal *ah, u_i if (ah->ah_config.ah_serialise_reg_war) mtx_lock_spin(&ah_regser_mtx); -#if _BYTE_ORDER == _BIG_ENDIAN - if (OS_REG_UNSWAPPED(reg)) - val = bus_space_read_4(tag, h, reg); - else -#endif - val = bus_space_read_stream_4(tag, h, reg); + val = bus_space_read_4(tag, h, reg); if (ah->ah_config.ah_serialise_reg_war) mtx_unlock_spin(&ah_regser_mtx); if (ath_hal_alq) { @@ -343,12 +333,7 @@ ath_hal_reg_write(struct ath_hal *ah, u_ if (ah->ah_config.ah_serialise_reg_war) mtx_lock_spin(&ah_regser_mtx); -#if _BYTE_ORDER == _BIG_ENDIAN - if (OS_REG_UNSWAPPED(reg)) - bus_space_write_4(tag, h, reg, val); - else -#endif - bus_space_write_stream_4(tag, h, reg, val); + bus_space_write_4(tag, h, reg, val); if (ah->ah_config.ah_serialise_reg_war) mtx_unlock_spin(&ah_regser_mtx); } @@ -362,12 +347,7 @@ ath_hal_reg_read(struct ath_hal *ah, u_i if (ah->ah_config.ah_serialise_reg_war) mtx_lock_spin(&ah_regser_mtx); -#if _BYTE_ORDER == _BIG_ENDIAN - if (OS_REG_UNSWAPPED(reg)) - val = bus_space_read_4(tag, h, reg); - else -#endif - val = bus_space_read_stream_4(tag, h, reg); + val = bus_space_read_4(tag, h, reg); if (ah->ah_config.ah_serialise_reg_war) mtx_unlock_spin(&ah_regser_mtx); return val; Modified: head/sys/dev/ath/ah_osdep.h ============================================================================== --- head/sys/dev/ath/ah_osdep.h Thu Apr 19 03:20:13 2012 (r234449) +++ head/sys/dev/ath/ah_osdep.h Thu Apr 19 03:26:21 2012 (r234450) @@ -97,39 +97,13 @@ struct ath_hal; extern void ath_hal_reg_write(struct ath_hal *ah, u_int reg, u_int32_t val); extern u_int32_t ath_hal_reg_read(struct ath_hal *ah, u_int reg); #else -/* - * The hardware registers are native little-endian byte order. - * Big-endian hosts are handled by enabling hardware byte-swap - * of register reads and writes at reset. But the PCI clock - * domain registers are not byte swapped! Thus, on big-endian - * platforms we have to explicitly byte-swap those registers. - * Most of this code is collapsed at compile time because the - * register values are constants. - */ -#if _BYTE_ORDER == _BIG_ENDIAN -#define OS_REG_WRITE(_ah, _reg, _val) do { \ - if (OS_REG_UNSWAPPED(_reg)) \ - bus_space_write_4((bus_space_tag_t)(_ah)->ah_st, \ - (bus_space_handle_t)(_ah)->ah_sh, (_reg), (_val)); \ - else \ - bus_space_write_stream_4((bus_space_tag_t)(_ah)->ah_st, \ - (bus_space_handle_t)(_ah)->ah_sh, (_reg), (_val)); \ -} while (0) -#define OS_REG_READ(_ah, _reg) \ - (OS_REG_UNSWAPPED(_reg) ? \ - bus_space_read_4((bus_space_tag_t)(_ah)->ah_st, \ - (bus_space_handle_t)(_ah)->ah_sh, (_reg)) : \ - bus_space_read_stream_4((bus_space_tag_t)(_ah)->ah_st, \ - (bus_space_handle_t)(_ah)->ah_sh, (_reg))) -#else /* _BYTE_ORDER == _LITTLE_ENDIAN */ #define OS_REG_WRITE(_ah, _reg, _val) \ bus_space_write_4((bus_space_tag_t)(_ah)->ah_st, \ (bus_space_handle_t)(_ah)->ah_sh, (_reg), (_val)) #define OS_REG_READ(_ah, _reg) \ bus_space_read_4((bus_space_tag_t)(_ah)->ah_st, \ (bus_space_handle_t)(_ah)->ah_sh, (_reg)) -#endif /* _BYTE_ORDER */ -#endif /* AH_DEBUG || AH_REGFUNC || AH_DEBUG_ALQ */ +#endif #ifdef AH_DEBUG_ALQ extern void OS_MARK(struct ath_hal *, u_int id, u_int32_t value); Modified: head/sys/dev/ath/ath_hal/ar5210/ar5210_reset.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5210/ar5210_reset.c Thu Apr 19 03:20:13 2012 (r234449) +++ head/sys/dev/ath/ath_hal/ar5210/ar5210_reset.c Thu Apr 19 03:26:21 2012 (r234450) @@ -594,12 +594,10 @@ ar5210SetResetReg(struct ath_hal *ah, ui if ((resetMask & AR_RC_RMAC) == 0) { if (isBigEndian()) { /* - * Set CFG, little-endian for register - * and descriptor accesses. + * Set CFG, little-endian for descriptor accesses. */ - mask = INIT_CONFIG_STATUS | - AR_CFG_SWTD | AR_CFG_SWRD | AR_CFG_SWRG; - OS_REG_WRITE(ah, AR_CFG, LE_READ_4(&mask)); + mask = INIT_CONFIG_STATUS | AR_CFG_SWTD | AR_CFG_SWRD; + OS_REG_WRITE(ah, AR_CFG, mask); } else OS_REG_WRITE(ah, AR_CFG, INIT_CONFIG_STATUS); } Modified: head/sys/dev/ath/ath_hal/ar5211/ar5211_reset.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5211/ar5211_reset.c Thu Apr 19 03:20:13 2012 (r234449) +++ head/sys/dev/ath/ath_hal/ar5211/ar5211_reset.c Thu Apr 19 03:26:21 2012 (r234450) @@ -764,12 +764,10 @@ ar5211SetResetReg(struct ath_hal *ah, ui if ((resetMask & AR_RC_MAC) == 0) { if (isBigEndian()) { /* - * Set CFG, little-endian for register - * and descriptor accesses. + * Set CFG, little-endian for descriptor accesses. */ - mask = INIT_CONFIG_STATUS | - AR_CFG_SWTD | AR_CFG_SWRD | AR_CFG_SWRG; - OS_REG_WRITE(ah, AR_CFG, LE_READ_4(&mask)); + mask = INIT_CONFIG_STATUS | AR_CFG_SWTD | AR_CFG_SWRD; + OS_REG_WRITE(ah, AR_CFG, mask); } else OS_REG_WRITE(ah, AR_CFG, INIT_CONFIG_STATUS); } Modified: head/sys/dev/ath/ath_hal/ar5212/ar5212_reset.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5212/ar5212_reset.c Thu Apr 19 03:20:13 2012 (r234449) +++ head/sys/dev/ath/ath_hal/ar5212/ar5212_reset.c Thu Apr 19 03:26:21 2012 (r234450) @@ -1273,14 +1273,13 @@ ar5212SetResetReg(struct ath_hal *ah, ui if ((resetMask & AR_RC_MAC) == 0) { if (isBigEndian()) { /* - * Set CFG, little-endian for register - * and descriptor accesses. + * Set CFG, little-endian for descriptor accesses. */ - mask = INIT_CONFIG_STATUS | AR_CFG_SWRD | AR_CFG_SWRG; + mask = INIT_CONFIG_STATUS | AR_CFG_SWRD; #ifndef AH_NEED_DESC_SWAP mask |= AR_CFG_SWTD; #endif - OS_REG_WRITE(ah, AR_CFG, LE_READ_4(&mask)); + OS_REG_WRITE(ah, AR_CFG, mask); } else OS_REG_WRITE(ah, AR_CFG, INIT_CONFIG_STATUS); if (ar5212SetPowerMode(ah, HAL_PM_AWAKE, AH_TRUE)) Modified: head/sys/dev/ath/ath_hal/ar5312/ar5312_reset.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5312/ar5312_reset.c Thu Apr 19 03:20:13 2012 (r234449) +++ head/sys/dev/ath/ath_hal/ar5312/ar5312_reset.c Thu Apr 19 03:26:21 2012 (r234450) @@ -740,8 +740,7 @@ ar5312SetResetReg(struct ath_hal *ah, ui if ((resetMask & AR_RC_MAC) == 0) { if (isBigEndian()) { /* - * Set CFG, little-endian for register - * and descriptor accesses. + * Set CFG, little-endian for descriptor accesses. */ #ifdef AH_NEED_DESC_SWAP mask = INIT_CONFIG_STATUS | AR_CFG_SWRD; Modified: head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c Thu Apr 19 03:20:13 2012 (r234449) +++ head/sys/dev/ath/ath_hal/ar5416/ar5416_reset.c Thu Apr 19 03:26:21 2012 (r234450) @@ -1387,16 +1387,15 @@ ar5416SetReset(struct ath_hal *ah, int t if (type == HAL_RESET_COLD) { if (isBigEndian()) { /* - * Set CFG, little-endian for register - * and descriptor accesses. + * Set CFG, little-endian for descriptor accesses. */ - mask = INIT_CONFIG_STATUS | AR_CFG_SWRD | AR_CFG_SWRG; + mask = INIT_CONFIG_STATUS | AR_CFG_SWRD; #ifndef AH_NEED_DESC_SWAP mask |= AR_CFG_SWTD; #endif HALDEBUG(ah, HAL_DEBUG_RESET, "%s Applying descriptor swap\n", __func__); - OS_REG_WRITE(ah, AR_CFG, LE_READ_4(&mask)); + OS_REG_WRITE(ah, AR_CFG, mask); } else OS_REG_WRITE(ah, AR_CFG, INIT_CONFIG_STATUS); } From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 07:43:28 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A62E9106564A; Thu, 19 Apr 2012 07:43:28 +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 913F08FC0C; Thu, 19 Apr 2012 07:43:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3J7hSmD071293; Thu, 19 Apr 2012 07:43:28 GMT (envelope-from mm@svn.freebsd.org) Received: (from mm@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3J7hSNY071291; Thu, 19 Apr 2012 07:43:28 GMT (envelope-from mm@svn.freebsd.org) Message-Id: <201204190743.q3J7hSNY071291@svn.freebsd.org> From: Martin Matuska Date: Thu, 19 Apr 2012 07:43:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234452 - stable/9/cddl/contrib/opensolaris/cmd/zpool X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 07:43:28 -0000 Author: mm Date: Thu Apr 19 07:43:28 2012 New Revision: 234452 URL: http://svn.freebsd.org/changeset/base/234452 Log: MFC r234336: Fix typo miror -> mirror Reported by: Glen Barber Modified: stable/9/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Directory Properties: stable/9/cddl/contrib/opensolaris/ (props changed) Modified: stable/9/cddl/contrib/opensolaris/cmd/zpool/zpool.8 ============================================================================== --- stable/9/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Thu Apr 19 04:07:55 2012 (r234451) +++ stable/9/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Thu Apr 19 07:43:28 2012 (r234452) @@ -1779,7 +1779,7 @@ The following command creates a storage pool consisting of two, two-way mirrors and mirrored log devices: .Bd -literal -offset 2n -.Li # Ic zpool create pool mirror da0 da1 mirror da2 da3 log miror da4 da5 +.Li # Ic zpool create pool mirror da0 da1 mirror da2 da3 log mirror da4 da5 .Ed .It Sy Example 14 No Adding Cache Devices to a Tn ZFS No Pool .Pp From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 07:43:45 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6C280106566B; Thu, 19 Apr 2012 07:43:45 +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 56D908FC0C; Thu, 19 Apr 2012 07:43:45 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3J7hjBh071336; Thu, 19 Apr 2012 07:43:45 GMT (envelope-from mm@svn.freebsd.org) Received: (from mm@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3J7hjho071334; Thu, 19 Apr 2012 07:43:45 GMT (envelope-from mm@svn.freebsd.org) Message-Id: <201204190743.q3J7hjho071334@svn.freebsd.org> From: Martin Matuska Date: Thu, 19 Apr 2012 07:43:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234453 - stable/8/cddl/contrib/opensolaris/cmd/zpool X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 07:43:45 -0000 Author: mm Date: Thu Apr 19 07:43:44 2012 New Revision: 234453 URL: http://svn.freebsd.org/changeset/base/234453 Log: MFC r234336: Fix typo miror -> mirror Reported by: Glen Barber Modified: stable/8/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Directory Properties: stable/8/cddl/contrib/opensolaris/ (props changed) Modified: stable/8/cddl/contrib/opensolaris/cmd/zpool/zpool.8 ============================================================================== --- stable/8/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Thu Apr 19 07:43:28 2012 (r234452) +++ stable/8/cddl/contrib/opensolaris/cmd/zpool/zpool.8 Thu Apr 19 07:43:44 2012 (r234453) @@ -1779,7 +1779,7 @@ The following command creates a storage pool consisting of two, two-way mirrors and mirrored log devices: .Bd -literal -offset 2n -.Li # Ic zpool create pool mirror da0 da1 mirror da2 da3 log miror da4 da5 +.Li # Ic zpool create pool mirror da0 da1 mirror da2 da3 log mirror da4 da5 .Ed .It Sy Example 14 No Adding Cache Devices to a Tn ZFS No Pool .Pp From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 10:17:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1EA16106566B; Thu, 19 Apr 2012 10:17: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 03B7D8FC0C; Thu, 19 Apr 2012 10:17:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JAHSFC081165; Thu, 19 Apr 2012 10:17:28 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JAHS41081163; Thu, 19 Apr 2012 10:17:28 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201204191017.q3JAHS41081163@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 19 Apr 2012 10:17:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234454 - stable/9/libexec/rtld-elf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 10:17:29 -0000 Author: kib Date: Thu Apr 19 10:17:28 2012 New Revision: 234454 URL: http://svn.freebsd.org/changeset/base/234454 Log: MFC r234170: Propagate the current state of rtld_bind_lock to dlopen_object() calls through the filter loading call chain. This fixes attempts to write-lock the already locked rtld_bind_lock when filter loading is initiated by relocation of dlopening dso. Modified: stable/9/libexec/rtld-elf/rtld.c Directory Properties: stable/9/libexec/rtld-elf/ (props changed) Modified: stable/9/libexec/rtld-elf/rtld.c ============================================================================== --- stable/9/libexec/rtld-elf/rtld.c Thu Apr 19 07:43:44 2012 (r234453) +++ stable/9/libexec/rtld-elf/rtld.c Thu Apr 19 10:17:28 2012 (r234454) @@ -85,7 +85,7 @@ static void digest_dynamic(Obj_Entry *, static Obj_Entry *digest_phdr(const Elf_Phdr *, int, caddr_t, const char *); static Obj_Entry *dlcheck(void *); static Obj_Entry *dlopen_object(const char *name, int fd, Obj_Entry *refobj, - int lo_flags, int mode); + int lo_flags, int mode, RtldLockState *lockstate); static Obj_Entry *do_load_object(int, const char *, char *, struct stat *, int); static int do_search_info(const Obj_Entry *obj, int, struct dl_serinfo *); static bool donelist_check(DoneList *, const Obj_Entry *); @@ -1672,13 +1672,14 @@ unload_filtees(Obj_Entry *obj) } static void -load_filtee1(Obj_Entry *obj, Needed_Entry *needed, int flags) +load_filtee1(Obj_Entry *obj, Needed_Entry *needed, int flags, + RtldLockState *lockstate) { for (; needed != NULL; needed = needed->next) { needed->obj = dlopen_object(obj->strtab + needed->name, -1, obj, flags, ((ld_loadfltr || obj->z_loadfltr) ? RTLD_NOW : RTLD_LAZY) | - RTLD_LOCAL); + RTLD_LOCAL, lockstate); } } @@ -1688,8 +1689,8 @@ load_filtees(Obj_Entry *obj, int flags, lock_restart_for_upgrade(lockstate); if (!obj->filtees_loaded) { - load_filtee1(obj, obj->needed_filtees, flags); - load_filtee1(obj, obj->needed_aux_filtees, flags); + load_filtee1(obj, obj->needed_filtees, flags, lockstate); + load_filtee1(obj, obj->needed_aux_filtees, flags, lockstate); obj->filtees_loaded = true; } } @@ -2489,7 +2490,7 @@ rtld_dlopen(const char *name, int fd, in lo_flags |= RTLD_LO_TRACE; return (dlopen_object(name, fd, obj_main, lo_flags, - mode & (RTLD_MODEMASK | RTLD_GLOBAL))); + mode & (RTLD_MODEMASK | RTLD_GLOBAL), NULL)); } static void @@ -2504,17 +2505,20 @@ dlopen_cleanup(Obj_Entry *obj) static Obj_Entry * dlopen_object(const char *name, int fd, Obj_Entry *refobj, int lo_flags, - int mode) + int mode, RtldLockState *lockstate) { Obj_Entry **old_obj_tail; Obj_Entry *obj; Objlist initlist; - RtldLockState lockstate; + RtldLockState mlockstate; int result; objlist_init(&initlist); - wlock_acquire(rtld_bind_lock, &lockstate); + if (lockstate == NULL && !(lo_flags & RTLD_LO_EARLY)) { + wlock_acquire(rtld_bind_lock, &mlockstate); + lockstate = &mlockstate; + } GDB_STATE(RT_ADD,NULL); old_obj_tail = obj_tail; @@ -2543,7 +2547,7 @@ dlopen_object(const char *name, int fd, if (result == -1 || (relocate_objects(obj, (mode & RTLD_MODEMASK) == RTLD_NOW, &obj_rtld, (lo_flags & RTLD_LO_EARLY) ? SYMLOOK_EARLY : 0, - &lockstate)) == -1) { + lockstate)) == -1) { dlopen_cleanup(obj); obj = NULL; } else if (lo_flags & RTLD_LO_EARLY) { @@ -2587,28 +2591,31 @@ dlopen_object(const char *name, int fd, GDB_STATE(RT_CONSISTENT,obj ? &obj->linkmap : NULL); if (!(lo_flags & RTLD_LO_EARLY)) { - map_stacks_exec(&lockstate); + map_stacks_exec(lockstate); } if (initlist_objects_ifunc(&initlist, (mode & RTLD_MODEMASK) == RTLD_NOW, (lo_flags & RTLD_LO_EARLY) ? SYMLOOK_EARLY : 0, - &lockstate) == -1) { + lockstate) == -1) { objlist_clear(&initlist); dlopen_cleanup(obj); - lock_release(rtld_bind_lock, &lockstate); + if (lockstate == &mlockstate) + lock_release(rtld_bind_lock, lockstate); return (NULL); } if (!(lo_flags & RTLD_LO_EARLY)) { /* Call the init functions. */ - objlist_call_init(&initlist, &lockstate); + objlist_call_init(&initlist, lockstate); } objlist_clear(&initlist); - lock_release(rtld_bind_lock, &lockstate); + if (lockstate == &mlockstate) + lock_release(rtld_bind_lock, lockstate); return obj; trace: trace_loaded_objects(obj); - lock_release(rtld_bind_lock, &lockstate); + if (lockstate == &mlockstate) + lock_release(rtld_bind_lock, lockstate); exit(0); } From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 10:36:24 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7375A1065673; Thu, 19 Apr 2012 10:36: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 44FAA8FC16; Thu, 19 Apr 2012 10:36:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JAaOtB081845; Thu, 19 Apr 2012 10:36:24 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JAaOcC081841; Thu, 19 Apr 2012 10:36:24 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201204191036.q3JAaOcC081841@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 19 Apr 2012 10:36:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234455 - in stable/9/sys: kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 10:36:24 -0000 Author: kib Date: Thu Apr 19 10:36:23 2012 New Revision: 234455 URL: http://svn.freebsd.org/changeset/base/234455 Log: MFC r234172: Add thread-private flag to indicate that error value is already placed in td_errno. Flag is supposed to be used by syscalls returning EJUSTRETURN because errno was already placed into the usermode frame by a call to set_syscall_retval(9). Both ktrace and dtrace get errno value from td_errno if the flag is set. Use the flag to fix sigsuspend(2) error return ktrace records. Modified: stable/9/sys/kern/kern_sig.c stable/9/sys/kern/subr_syscall.c stable/9/sys/sys/proc.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/kern_sig.c ============================================================================== --- stable/9/sys/kern/kern_sig.c Thu Apr 19 10:17:28 2012 (r234454) +++ stable/9/sys/kern/kern_sig.c Thu Apr 19 10:36:23 2012 (r234455) @@ -1465,6 +1465,8 @@ kern_sigsuspend(struct thread *td, sigse mtx_unlock(&p->p_sigacts->ps_mtx); } PROC_UNLOCK(p); + td->td_errno = EINTR; + td->td_pflags |= TDP_NERRNO; return (EJUSTRETURN); } Modified: stable/9/sys/kern/subr_syscall.c ============================================================================== --- stable/9/sys/kern/subr_syscall.c Thu Apr 19 10:17:28 2012 (r234454) +++ stable/9/sys/kern/subr_syscall.c Thu Apr 19 10:36:23 2012 (r234455) @@ -136,7 +136,8 @@ syscallenter(struct thread *td, struct s AUDIT_SYSCALL_EXIT(error, td); /* Save the latest error return value. */ - td->td_errno = error; + if ((td->td_pflags & TDP_NERRNO) == 0) + td->td_errno = error; #ifdef KDTRACE_HOOKS /* @@ -191,9 +192,12 @@ syscallret(struct thread *td, int error, syscallname(p, sa->code), td, td->td_proc->p_pid, td->td_name); #ifdef KTRACE - if (KTRPOINT(td, KTR_SYSRET)) - ktrsysret(sa->code, error, td->td_retval[0]); + if (KTRPOINT(td, KTR_SYSRET)) { + ktrsysret(sa->code, (td->td_pflags & TDP_NERRNO) == 0 ? + error : td->td_errno, td->td_retval[0]); + } #endif + td->td_pflags &= ~TDP_NERRNO; if (p->p_flag & P_TRACED) { traced = 1; Modified: stable/9/sys/sys/proc.h ============================================================================== --- stable/9/sys/sys/proc.h Thu Apr 19 10:17:28 2012 (r234454) +++ stable/9/sys/sys/proc.h Thu Apr 19 10:36:23 2012 (r234455) @@ -417,6 +417,7 @@ do { \ #define TDP_AUDITREC 0x01000000 /* Audit record pending on thread */ #define TDP_RFPPWAIT 0x02000000 /* Handle RFPPWAIT on syscall exit */ #define TDP_RESETSPUR 0x04000000 /* Reset spurious page fault history. */ +#define TDP_NERRNO 0x08000000 /* Last errno is already in td_errno */ /* * Reasons that the current thread can not be run yet. From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 10:53:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0EB4B106564A; Thu, 19 Apr 2012 10:53:18 +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 D3D278FC08; Thu, 19 Apr 2012 10:53:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JArHcX085659; Thu, 19 Apr 2012 10:53:17 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JArHKj085655; Thu, 19 Apr 2012 10:53:17 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201204191053.q3JArHKj085655@svn.freebsd.org> From: Konstantin Belousov Date: Thu, 19 Apr 2012 10:53:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234457 - in stable/8/sys: kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 10:53:18 -0000 Author: kib Date: Thu Apr 19 10:53:17 2012 New Revision: 234457 URL: http://svn.freebsd.org/changeset/base/234457 Log: MFC r234172: Add thread-private flag to indicate that error value is already placed in td_errno. Flag is supposed to be used by syscalls returning EJUSTRETURN because errno was already placed into the usermode frame by a call to set_syscall_retval(9). Both ktrace and dtrace get errno value from td_errno if the flag is set. Use the flag to fix sigsuspend(2) error return ktrace records. Modified: stable/8/sys/kern/kern_sig.c stable/8/sys/kern/subr_syscall.c stable/8/sys/sys/proc.h Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/kern/kern_sig.c ============================================================================== --- stable/8/sys/kern/kern_sig.c Thu Apr 19 10:48:25 2012 (r234456) +++ stable/8/sys/kern/kern_sig.c Thu Apr 19 10:53:17 2012 (r234457) @@ -1489,6 +1489,8 @@ kern_sigsuspend(struct thread *td, sigse mtx_unlock(&p->p_sigacts->ps_mtx); } PROC_UNLOCK(p); + td->td_errno = EINTR; + td->td_pflags |= TDP_NERRNO; return (EJUSTRETURN); } Modified: stable/8/sys/kern/subr_syscall.c ============================================================================== --- stable/8/sys/kern/subr_syscall.c Thu Apr 19 10:48:25 2012 (r234456) +++ stable/8/sys/kern/subr_syscall.c Thu Apr 19 10:53:17 2012 (r234457) @@ -115,7 +115,8 @@ syscallenter(struct thread *td, struct s AUDIT_SYSCALL_EXIT(error, td); /* Save the latest error return value. */ - td->td_errno = error; + if ((td->td_pflags & TDP_NERRNO) == 0) + td->td_errno = error; #ifdef KDTRACE_HOOKS /* @@ -169,9 +170,12 @@ syscallret(struct thread *td, int error, syscallname(p, sa->code), td, td->td_proc->p_pid, td->td_name); #ifdef KTRACE - if (KTRPOINT(td, KTR_SYSRET)) - ktrsysret(sa->code, error, td->td_retval[0]); + if (KTRPOINT(td, KTR_SYSRET)) { + ktrsysret(sa->code, (td->td_pflags & TDP_NERRNO) == 0 ? + error : td->td_errno, td->td_retval[0]); + } #endif + td->td_pflags &= ~TDP_NERRNO; if (p->p_flag & P_TRACED) { traced = 1; Modified: stable/8/sys/sys/proc.h ============================================================================== --- stable/8/sys/sys/proc.h Thu Apr 19 10:48:25 2012 (r234456) +++ stable/8/sys/sys/proc.h Thu Apr 19 10:53:17 2012 (r234457) @@ -410,6 +410,7 @@ do { \ #define TDP_IGNSUSP 0x00800000 /* Permission to ignore the MNTK_SUSPEND* */ #define TDP_AUDITREC 0x01000000 /* Audit record pending on thread */ #define TDP_RESETSPUR 0x04000000 /* Reset spurious page fault history. */ +#define TDP_NERRNO 0x08000000 /* Last errno is already in td_errno */ /* * Reasons that the current thread can not be run yet. From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 11:48:33 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 34DE91065672; Thu, 19 Apr 2012 11:48:33 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 05FBD8FC08; Thu, 19 Apr 2012 11:48:33 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 6CFD4B943; Thu, 19 Apr 2012 07:48:32 -0400 (EDT) From: John Baldwin To: Dimitry Andric Date: Thu, 19 Apr 2012 07:39:40 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p13; KDE/4.5.5; amd64; ; ) References: <201203301257.q2UCvE4l042042@svn.freebsd.org> <201204180954.14236.jhb@freebsd.org> <4F8F1F99.8060408@FreeBSD.org> In-Reply-To: <4F8F1F99.8060408@FreeBSD.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201204190739.41086.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Thu, 19 Apr 2012 07:48:32 -0400 (EDT) Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, Scott Long , Stefan Farfeleder , David Xu , svn-src-head@freebsd.org Subject: Re: svn commit: r233700 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 11:48:33 -0000 On Wednesday, April 18, 2012 4:10:01 pm Dimitry Andric wrote: > On 2012-04-18 15:54, John Baldwin wrote: > ... > > http://www.FreeBSD.org/~jhb/patches/asr_stailq.patch > > Yes, that seems to work just fine, at least for the list juggling. Thanks! > > The only additional fix needed now is the following. Shall I commit > that including your patch? Sure. > Index: sys/dev/asr/asr.c > =================================================================== > --- sys/dev/asr/asr.c (revision 234390) > +++ sys/dev/asr/asr.c (working copy) > @@ -2700,7 +2701,7 @@ asr_action(struct cam_sim *sim, union ccb *ccb) > > ccb->ccb_h.spriv_ptr0 = sc = (struct Asr_softc *)cam_sim_softc(sim); > > - switch (ccb->ccb_h.func_code) { > + switch ((int)ccb->ccb_h.func_code) { > > /* Common cases first */ > case XPT_SCSI_IO: /* Execute the requested I/O operation */ > -- John Baldwin From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 12:30:13 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 80D121065670; Thu, 19 Apr 2012 12:30:13 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 68D768FC08; Thu, 19 Apr 2012 12:30:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JCUDew088837; Thu, 19 Apr 2012 12:30:13 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JCUDbK088825; Thu, 19 Apr 2012 12:30:13 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201204191230.q3JCUDbK088825@svn.freebsd.org> From: Alexander Motin Date: Thu, 19 Apr 2012 12:30: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: r234458 - in head: sbin/geom/class/raid sys/conf sys/geom/raid sys/modules/geom/geom_raid X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 12:30:13 -0000 Author: mav Date: Thu Apr 19 12:30:12 2012 New Revision: 234458 URL: http://svn.freebsd.org/changeset/base/234458 Log: Add to GEOM RAID class module for reading non-degraded RAID5 volumes and some environment to differentiate 4 possible RAID5 on-disk layouts. Tested with Intel and AMD RAID BIOSes. MFC after: 2 weeks Added: head/sys/geom/raid/tr_raid5.c (contents, props changed) Modified: head/sbin/geom/class/raid/graid.8 head/sys/conf/files head/sys/geom/raid/g_raid.c head/sys/geom/raid/g_raid.h head/sys/geom/raid/md_intel.c head/sys/geom/raid/md_jmicron.c head/sys/geom/raid/md_nvidia.c head/sys/geom/raid/md_promise.c head/sys/geom/raid/md_sii.c head/sys/modules/geom/geom_raid/Makefile Modified: head/sbin/geom/class/raid/graid.8 ============================================================================== --- head/sbin/geom/class/raid/graid.8 Thu Apr 19 10:53:17 2012 (r234457) +++ head/sbin/geom/class/raid/graid.8 Thu Apr 19 12:30:12 2012 (r234458) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 26, 2011 +.Dd April 19, 2012 .Dt GRAID 8 .Os .Sh NAME @@ -242,7 +242,8 @@ own risk: RAID1 (3+ disks), RAID10 (6+ d The GEOM RAID class follows a modular design, allowing different RAID levels to be used. Support for the following RAID levels is currently implemented: RAID0, RAID1, -RAID1E, RAID10, SINGLE, CONCAT. +RAID1E, RAID5, RAID10, SINGLE, CONCAT. +RAID5 support is read-only and only for volumes in optimal state. .Sh RAID LEVEL MIGRATION The GEOM RAID class has no support for RAID level migration, allowed by some metadata formats. Modified: head/sys/conf/files ============================================================================== --- head/sys/conf/files Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/conf/files Thu Apr 19 12:30:12 2012 (r234458) @@ -2405,6 +2405,7 @@ geom/raid/tr_concat.c optional geom_rai geom/raid/tr_raid0.c optional geom_raid geom/raid/tr_raid1.c optional geom_raid geom/raid/tr_raid1e.c optional geom_raid +geom/raid/tr_raid5.c optional geom_raid geom/raid3/g_raid3.c optional geom_raid3 geom/raid3/g_raid3_ctl.c optional geom_raid3 geom/shsec/g_shsec.c optional geom_shsec Modified: head/sys/geom/raid/g_raid.c ============================================================================== --- head/sys/geom/raid/g_raid.c Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/geom/raid/g_raid.c Thu Apr 19 12:30:12 2012 (r234458) @@ -281,6 +281,14 @@ g_raid_volume_level2str(int level, int q case G_RAID_VOLUME_RL_RAID4: return ("RAID4"); case G_RAID_VOLUME_RL_RAID5: + if (qual == G_RAID_VOLUME_RLQ_R5RA) + return ("RAID5RA"); + if (qual == G_RAID_VOLUME_RLQ_R5RS) + return ("RAID5RS"); + if (qual == G_RAID_VOLUME_RLQ_R5LA) + return ("RAID5LA"); + if (qual == G_RAID_VOLUME_RLQ_R5LS) + return ("RAID5LS"); return ("RAID5"); case G_RAID_VOLUME_RL_RAID6: return ("RAID6"); @@ -313,9 +321,20 @@ g_raid_volume_str2level(const char *str, *level = G_RAID_VOLUME_RL_RAID3; else if (strcasecmp(str, "RAID4") == 0) *level = G_RAID_VOLUME_RL_RAID4; - else if (strcasecmp(str, "RAID5") == 0) + else if (strcasecmp(str, "RAID5RA") == 0) { *level = G_RAID_VOLUME_RL_RAID5; - else if (strcasecmp(str, "RAID6") == 0) + *qual = G_RAID_VOLUME_RLQ_R5RA; + } else if (strcasecmp(str, "RAID5RS") == 0) { + *level = G_RAID_VOLUME_RL_RAID5; + *qual = G_RAID_VOLUME_RLQ_R5RS; + } else if (strcasecmp(str, "RAID5") == 0 || + strcasecmp(str, "RAID5LA") == 0) { + *level = G_RAID_VOLUME_RL_RAID5; + *qual = G_RAID_VOLUME_RLQ_R5LA; + } else if (strcasecmp(str, "RAID5LS") == 0) { + *level = G_RAID_VOLUME_RL_RAID5; + *qual = G_RAID_VOLUME_RLQ_R5LS; + } else if (strcasecmp(str, "RAID6") == 0) *level = G_RAID_VOLUME_RL_RAID6; else if (strcasecmp(str, "RAID10") == 0 || strcasecmp(str, "RAID1E") == 0) Modified: head/sys/geom/raid/g_raid.h ============================================================================== --- head/sys/geom/raid/g_raid.h Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/geom/raid/g_raid.h Thu Apr 19 12:30:12 2012 (r234458) @@ -227,6 +227,10 @@ struct g_raid_subdisk { #define G_RAID_VOLUME_RL_UNKNOWN 0xff #define G_RAID_VOLUME_RLQ_NONE 0x00 +#define G_RAID_VOLUME_RLQ_R5RA 0x00 +#define G_RAID_VOLUME_RLQ_R5RS 0x01 +#define G_RAID_VOLUME_RLQ_R5LA 0x02 +#define G_RAID_VOLUME_RLQ_R5LS 0x03 #define G_RAID_VOLUME_RLQ_UNKNOWN 0xff struct g_raid_volume; Modified: head/sys/geom/raid/md_intel.c ============================================================================== --- head/sys/geom/raid/md_intel.c Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/geom/raid/md_intel.c Thu Apr 19 12:30:12 2012 (r234458) @@ -682,11 +682,13 @@ g_raid_md_intel_supported(int level, int return (0); if (!force && disks > 6) return (0); + if (qual != G_RAID_VOLUME_RLQ_R5LA) + return (0); break; default: return (0); } - if (qual != G_RAID_VOLUME_RLQ_NONE) + if (level != G_RAID_VOLUME_RL_RAID5 && qual != G_RAID_VOLUME_RLQ_NONE) return (0); return (1); } @@ -1029,6 +1031,7 @@ g_raid_md_intel_start(struct g_raid_soft mmap = intel_get_map(mvol, 0); vol = g_raid_create_volume(sc, mvol->name, -1); vol->v_md_data = (void *)(intptr_t)i; + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; if (mmap->type == INTEL_T_RAID0) vol->v_raid_level = G_RAID_VOLUME_RL_RAID0; else if (mmap->type == INTEL_T_RAID1 && @@ -1045,11 +1048,11 @@ g_raid_md_intel_start(struct g_raid_soft vol->v_raid_level = G_RAID_VOLUME_RL_RAID1; else vol->v_raid_level = G_RAID_VOLUME_RL_RAID1E; - } else if (mmap->type == INTEL_T_RAID5) + } else if (mmap->type == INTEL_T_RAID5) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID5; - else + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_R5LA; + } else vol->v_raid_level = G_RAID_VOLUME_RL_UNKNOWN; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; vol->v_strip_size = (u_int)mmap->strip_sectors * 512; //ZZZ vol->v_disks_count = mmap->total_disks; vol->v_mediasize = (off_t)mvol->total_sectors * 512; //ZZZ @@ -1485,6 +1488,8 @@ g_raid_md_ctl_intel(struct g_raid_md_obj gctl_error(req, "No RAID level."); return (-3); } + if (strcasecmp(levelname, "RAID5") == 0) + levelname = "RAID5LA"; if (g_raid_volume_str2level(levelname, &level, &qual)) { gctl_error(req, "Unknown RAID level '%s'.", levelname); return (-4); @@ -1631,7 +1636,7 @@ g_raid_md_ctl_intel(struct g_raid_md_obj vol = g_raid_create_volume(sc, volname, -1); vol->v_md_data = (void *)(intptr_t)0; vol->v_raid_level = level; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; + vol->v_raid_level_qualifier = qual; vol->v_strip_size = strip; vol->v_disks_count = numdisks; if (level == G_RAID_VOLUME_RL_RAID0) @@ -1658,8 +1663,12 @@ g_raid_md_ctl_intel(struct g_raid_md_obj if (sd->sd_disk->d_consumer != NULL) { g_raid_change_disk_state(disk, G_RAID_DISK_S_ACTIVE); - g_raid_change_subdisk_state(sd, - G_RAID_SUBDISK_S_ACTIVE); + if (level == G_RAID_VOLUME_RL_RAID5) + g_raid_change_subdisk_state(sd, + G_RAID_SUBDISK_S_UNINITIALIZED); + else + g_raid_change_subdisk_state(sd, + G_RAID_SUBDISK_S_ACTIVE); g_raid_event_send(sd, G_RAID_SUBDISK_E_NEW, G_RAID_EVENT_SUBDISK); } else { @@ -1694,6 +1703,8 @@ g_raid_md_ctl_intel(struct g_raid_md_obj gctl_error(req, "No RAID level."); return (-3); } + if (strcasecmp(levelname, "RAID5") == 0) + levelname = "RAID5LA"; if (g_raid_volume_str2level(levelname, &level, &qual)) { gctl_error(req, "Unknown RAID level '%s'.", levelname); return (-4); @@ -1818,7 +1829,7 @@ g_raid_md_ctl_intel(struct g_raid_md_obj vol = g_raid_create_volume(sc, volname, -1); vol->v_md_data = (void *)(intptr_t)i; vol->v_raid_level = level; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; + vol->v_raid_level_qualifier = qual; vol->v_strip_size = strip; vol->v_disks_count = numdisks; if (level == G_RAID_VOLUME_RL_RAID0) @@ -1843,8 +1854,12 @@ g_raid_md_ctl_intel(struct g_raid_md_obj sd->sd_size = size; TAILQ_INSERT_TAIL(&disk->d_subdisks, sd, sd_next); if (disk->d_state == G_RAID_DISK_S_ACTIVE) { - g_raid_change_subdisk_state(sd, - G_RAID_SUBDISK_S_ACTIVE); + if (level == G_RAID_VOLUME_RL_RAID5) + g_raid_change_subdisk_state(sd, + G_RAID_SUBDISK_S_UNINITIALIZED); + else + g_raid_change_subdisk_state(sd, + G_RAID_SUBDISK_S_ACTIVE); g_raid_event_send(sd, G_RAID_SUBDISK_E_NEW, G_RAID_EVENT_SUBDISK); } @@ -2245,6 +2260,9 @@ g_raid_md_write_intel(struct g_raid_md_o mmap0->status = INTEL_S_FAILURE; else if (vol->v_state == G_RAID_VOLUME_S_DEGRADED) mmap0->status = INTEL_S_DEGRADED; + else if (g_raid_nsubdisks(vol, G_RAID_SUBDISK_S_UNINITIALIZED) + == g_raid_nsubdisks(vol, -1)) + mmap0->status = INTEL_S_UNINITIALIZED; else mmap0->status = INTEL_S_READY; if (vol->v_raid_level == G_RAID_VOLUME_RL_RAID0) @@ -2288,7 +2306,8 @@ g_raid_md_write_intel(struct g_raid_md_o sd->sd_state == G_RAID_SUBDISK_S_RESYNC) { mmap1->disk_idx[sdi] |= INTEL_DI_RBLD; } else if (sd->sd_state != G_RAID_SUBDISK_S_ACTIVE && - sd->sd_state != G_RAID_SUBDISK_S_STALE) { + sd->sd_state != G_RAID_SUBDISK_S_STALE && + sd->sd_state != G_RAID_SUBDISK_S_UNINITIALIZED) { mmap0->disk_idx[sdi] |= INTEL_DI_RBLD; if (mvol->migr_state) mmap1->disk_idx[sdi] |= INTEL_DI_RBLD; Modified: head/sys/geom/raid/md_jmicron.c ============================================================================== --- head/sys/geom/raid/md_jmicron.c Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/geom/raid/md_jmicron.c Thu Apr 19 12:30:12 2012 (r234458) @@ -400,13 +400,15 @@ g_raid_md_jmicron_supported(int level, i case G_RAID_VOLUME_RL_RAID5: if (disks < 3) return (0); + if (qual != G_RAID_VOLUME_RLQ_R5LA) + return (0); if (!force) return (0); break; default: return (0); } - if (qual != G_RAID_VOLUME_RLQ_NONE) + if (level != G_RAID_VOLUME_RL_RAID5 && qual != G_RAID_VOLUME_RLQ_NONE) return (0); return (1); } @@ -657,6 +659,7 @@ g_raid_md_jmicron_start(struct g_raid_so vol = g_raid_create_volume(sc, buf, -1); size = ((off_t)meta->disk_sectors_high << 16) + meta->disk_sectors_low; size *= 512; //ZZZ + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; if (meta->type == JMICRON_T_RAID0) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID0; vol->v_mediasize = size * mdi->mdio_total_disks; @@ -674,12 +677,12 @@ g_raid_md_jmicron_start(struct g_raid_so vol->v_mediasize = 0; } else if (meta->type == JMICRON_T_RAID5) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID5; + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_R5LA; vol->v_mediasize = size * (mdi->mdio_total_disks - 1); } else { vol->v_raid_level = G_RAID_VOLUME_RL_UNKNOWN; vol->v_mediasize = 0; } - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; vol->v_strip_size = 1024 << meta->stripe_shift; //ZZZ vol->v_disks_count = mdi->mdio_total_disks; vol->v_sectorsize = 512; //ZZZ @@ -1057,6 +1060,8 @@ g_raid_md_ctl_jmicron(struct g_raid_md_o gctl_error(req, "No RAID level."); return (-3); } + if (strcasecmp(levelname, "RAID5") == 0) + levelname = "RAID5LA"; if (g_raid_volume_str2level(levelname, &level, &qual)) { gctl_error(req, "Unknown RAID level '%s'.", levelname); return (-4); @@ -1192,7 +1197,7 @@ g_raid_md_ctl_jmicron(struct g_raid_md_o vol = g_raid_create_volume(sc, volname, -1); vol->v_md_data = (void *)(intptr_t)0; vol->v_raid_level = level; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; + vol->v_raid_level_qualifier = qual; vol->v_strip_size = strip; vol->v_disks_count = numdisks; if (level == G_RAID_VOLUME_RL_RAID0 || Modified: head/sys/geom/raid/md_nvidia.c ============================================================================== --- head/sys/geom/raid/md_nvidia.c Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/geom/raid/md_nvidia.c Thu Apr 19 12:30:12 2012 (r234458) @@ -407,11 +407,14 @@ g_raid_md_nvidia_supported(int level, in case G_RAID_VOLUME_RL_RAID5: if (disks < 3) return (0); + if (qual != G_RAID_VOLUME_RLQ_R5LA && + qual != G_RAID_VOLUME_RLQ_R5LS) + return (0); break; default: return (0); } - if (qual != G_RAID_VOLUME_RLQ_NONE) + if (level != G_RAID_VOLUME_RL_RAID5 && qual != G_RAID_VOLUME_RLQ_NONE) return (0); return (1); } @@ -679,10 +682,11 @@ g_raid_md_nvidia_start(struct g_raid_sof size = 0; } else if (meta->type == NVIDIA_T_RAID5) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID5; + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_R5LA; size = vol->v_mediasize / (mdi->mdio_total_disks - 1); } else if (meta->type == NVIDIA_T_RAID5_SYM) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID5; -// vol->v_raid_level_qualifier = 0x03; + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_R5LS; size = vol->v_mediasize / (mdi->mdio_total_disks - 1); } else { vol->v_raid_level = G_RAID_VOLUME_RL_UNKNOWN; @@ -1059,6 +1063,8 @@ g_raid_md_ctl_nvidia(struct g_raid_md_ob gctl_error(req, "No RAID level."); return (-3); } + if (strcasecmp(levelname, "RAID5") == 0) + levelname = "RAID5LS"; if (g_raid_volume_str2level(levelname, &level, &qual)) { gctl_error(req, "Unknown RAID level '%s'.", levelname); return (-4); @@ -1206,7 +1212,7 @@ g_raid_md_ctl_nvidia(struct g_raid_md_ob vol = g_raid_create_volume(sc, volname, -1); vol->v_md_data = (void *)(intptr_t)0; vol->v_raid_level = level; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; + vol->v_raid_level_qualifier = qual; vol->v_strip_size = strip; vol->v_disks_count = numdisks; vol->v_mediasize = volsize; @@ -1454,8 +1460,8 @@ g_raid_md_write_nvidia(struct g_raid_md_ else if (vol->v_raid_level == G_RAID_VOLUME_RL_CONCAT || vol->v_raid_level == G_RAID_VOLUME_RL_SINGLE) meta->type = NVIDIA_T_CONCAT; -// else if (vol->v_raid_level_qualifier == 0) -// meta->type = NVIDIA_T_RAID5; + else if (vol->v_raid_level_qualifier == G_RAID_VOLUME_RLQ_R5LA) + meta->type = NVIDIA_T_RAID5; else meta->type = NVIDIA_T_RAID5_SYM; meta->strip_sectors = vol->v_strip_size / vol->v_sectorsize; Modified: head/sys/geom/raid/md_promise.c ============================================================================== --- head/sys/geom/raid/md_promise.c Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/geom/raid/md_promise.c Thu Apr 19 12:30:12 2012 (r234458) @@ -595,11 +595,13 @@ g_raid_md_promise_supported(int level, i case G_RAID_VOLUME_RL_RAID5: if (disks < 3) return (0); + if (qual != G_RAID_VOLUME_RLQ_R5LA) + return (0); break; default: return (0); } - if (qual != G_RAID_VOLUME_RLQ_NONE) + if (level != G_RAID_VOLUME_RL_RAID5 && qual != G_RAID_VOLUME_RLQ_NONE) return (0); return (1); } @@ -848,6 +850,7 @@ g_raid_md_promise_start(struct g_raid_vo pv = vol->v_md_data; meta = pv->pv_meta; + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; if (meta->type == PROMISE_T_RAID0) vol->v_raid_level = G_RAID_VOLUME_RL_RAID0; else if (meta->type == PROMISE_T_RAID1) { @@ -857,15 +860,15 @@ g_raid_md_promise_start(struct g_raid_vo vol->v_raid_level = G_RAID_VOLUME_RL_RAID1E; } else if (meta->type == PROMISE_T_RAID3) vol->v_raid_level = G_RAID_VOLUME_RL_RAID3; - else if (meta->type == PROMISE_T_RAID5) + else if (meta->type == PROMISE_T_RAID5) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID5; - else if (meta->type == PROMISE_T_SPAN) + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_R5LA; + } else if (meta->type == PROMISE_T_SPAN) vol->v_raid_level = G_RAID_VOLUME_RL_CONCAT; else if (meta->type == PROMISE_T_JBOD) vol->v_raid_level = G_RAID_VOLUME_RL_SINGLE; else vol->v_raid_level = G_RAID_VOLUME_RL_UNKNOWN; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; vol->v_strip_size = 512 << meta->stripe_shift; //ZZZ vol->v_disks_count = meta->total_disks; vol->v_mediasize = (off_t)meta->total_sectors * 512; //ZZZ @@ -1241,6 +1244,8 @@ g_raid_md_ctl_promise(struct g_raid_md_o gctl_error(req, "No RAID level."); return (-3); } + if (strcasecmp(levelname, "RAID5") == 0) + levelname = "RAID5LA"; if (g_raid_volume_str2level(levelname, &level, &qual)) { gctl_error(req, "Unknown RAID level '%s'.", levelname); return (-4); @@ -1415,7 +1420,7 @@ g_raid_md_ctl_promise(struct g_raid_md_o vol = g_raid_create_volume(sc, volname, -1); vol->v_md_data = pv; vol->v_raid_level = level; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; + vol->v_raid_level_qualifier = qual; vol->v_strip_size = strip; vol->v_disks_count = numdisks; if (level == G_RAID_VOLUME_RL_RAID0 || Modified: head/sys/geom/raid/md_sii.c ============================================================================== --- head/sys/geom/raid/md_sii.c Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/geom/raid/md_sii.c Thu Apr 19 12:30:12 2012 (r234458) @@ -456,11 +456,13 @@ g_raid_md_sii_supported(int level, int q case G_RAID_VOLUME_RL_RAID5: if (disks < 3) return (0); + if (qual != G_RAID_VOLUME_RLQ_R5LS) + return (0); break; default: return (0); } - if (qual != G_RAID_VOLUME_RLQ_NONE) + if (level != G_RAID_VOLUME_RL_RAID5 && qual != G_RAID_VOLUME_RLQ_NONE) return (0); return (1); } @@ -719,6 +721,7 @@ g_raid_md_sii_start(struct g_raid_softc sii_meta_get_name(meta, buf); vol = g_raid_create_volume(sc, buf, -1); vol->v_mediasize = (off_t)meta->total_sectors * 512; + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; if (meta->type == SII_T_RAID0) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID0; size = vol->v_mediasize / mdi->mdio_total_disks; @@ -736,6 +739,7 @@ g_raid_md_sii_start(struct g_raid_softc size = 0; } else if (meta->type == SII_T_RAID5) { vol->v_raid_level = G_RAID_VOLUME_RL_RAID5; + vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_R5LS; size = vol->v_mediasize / (mdi->mdio_total_disks - 1); } else if (meta->type == SII_T_JBOD) { vol->v_raid_level = G_RAID_VOLUME_RL_SINGLE; @@ -744,7 +748,6 @@ g_raid_md_sii_start(struct g_raid_softc vol->v_raid_level = G_RAID_VOLUME_RL_UNKNOWN; size = 0; } - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; vol->v_strip_size = meta->strip_sectors * 512; //ZZZ vol->v_disks_count = mdi->mdio_total_disks; vol->v_sectorsize = 512; //ZZZ @@ -1144,6 +1147,8 @@ g_raid_md_ctl_sii(struct g_raid_md_objec gctl_error(req, "No RAID level."); return (-3); } + if (strcasecmp(levelname, "RAID5") == 0) + levelname = "RAID5LS"; if (g_raid_volume_str2level(levelname, &level, &qual)) { gctl_error(req, "Unknown RAID level '%s'.", levelname); return (-4); @@ -1278,7 +1283,7 @@ g_raid_md_ctl_sii(struct g_raid_md_objec vol = g_raid_create_volume(sc, volname, -1); vol->v_md_data = (void *)(intptr_t)0; vol->v_raid_level = level; - vol->v_raid_level_qualifier = G_RAID_VOLUME_RLQ_NONE; + vol->v_raid_level_qualifier = qual; vol->v_strip_size = strip; vol->v_disks_count = numdisks; if (level == G_RAID_VOLUME_RL_RAID0 || Added: head/sys/geom/raid/tr_raid5.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/geom/raid/tr_raid5.c Thu Apr 19 12:30:12 2012 (r234458) @@ -0,0 +1,376 @@ +/*- + * Copyright (c) 2012 Alexander Motin + * 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 AUTHORS 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 AUTHORS 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 +#include +#include +#include +#include +#include +#include +#include +#include +#include "geom/raid/g_raid.h" +#include "g_raid_tr_if.h" + +SYSCTL_DECL(_kern_geom_raid); + +static MALLOC_DEFINE(M_TR_RAID5, "tr_raid5_data", "GEOM_RAID RAID5 data"); + +#define TR_RAID5_NONE 0 +#define TR_RAID5_REBUILD 1 +#define TR_RAID5_RESYNC 2 + +#define TR_RAID5_F_DOING_SOME 0x1 +#define TR_RAID5_F_LOCKED 0x2 +#define TR_RAID5_F_ABORT 0x4 + +struct g_raid_tr_raid5_object { + struct g_raid_tr_object trso_base; + int trso_starting; + int trso_stopping; + int trso_type; + int trso_recover_slabs; /* slabs before rest */ + int trso_fair_io; + int trso_meta_update; + int trso_flags; + struct g_raid_subdisk *trso_failed_sd; /* like per volume */ + void *trso_buffer; /* Buffer space */ + struct bio trso_bio; +}; + +static g_raid_tr_taste_t g_raid_tr_taste_raid5; +static g_raid_tr_event_t g_raid_tr_event_raid5; +static g_raid_tr_start_t g_raid_tr_start_raid5; +static g_raid_tr_stop_t g_raid_tr_stop_raid5; +static g_raid_tr_iostart_t g_raid_tr_iostart_raid5; +static g_raid_tr_iodone_t g_raid_tr_iodone_raid5; +static g_raid_tr_kerneldump_t g_raid_tr_kerneldump_raid5; +static g_raid_tr_locked_t g_raid_tr_locked_raid5; +static g_raid_tr_free_t g_raid_tr_free_raid5; + +static kobj_method_t g_raid_tr_raid5_methods[] = { + KOBJMETHOD(g_raid_tr_taste, g_raid_tr_taste_raid5), + KOBJMETHOD(g_raid_tr_event, g_raid_tr_event_raid5), + KOBJMETHOD(g_raid_tr_start, g_raid_tr_start_raid5), + KOBJMETHOD(g_raid_tr_stop, g_raid_tr_stop_raid5), + KOBJMETHOD(g_raid_tr_iostart, g_raid_tr_iostart_raid5), + KOBJMETHOD(g_raid_tr_iodone, g_raid_tr_iodone_raid5), + KOBJMETHOD(g_raid_tr_kerneldump, g_raid_tr_kerneldump_raid5), + KOBJMETHOD(g_raid_tr_locked, g_raid_tr_locked_raid5), + KOBJMETHOD(g_raid_tr_free, g_raid_tr_free_raid5), + { 0, 0 } +}; + +static struct g_raid_tr_class g_raid_tr_raid5_class = { + "RAID5", + g_raid_tr_raid5_methods, + sizeof(struct g_raid_tr_raid5_object), + .trc_priority = 100 +}; + +static int +g_raid_tr_taste_raid5(struct g_raid_tr_object *tr, struct g_raid_volume *vol) +{ + struct g_raid_tr_raid5_object *trs; + u_int qual; + + trs = (struct g_raid_tr_raid5_object *)tr; + qual = tr->tro_volume->v_raid_level_qualifier; + if (tr->tro_volume->v_raid_level == G_RAID_VOLUME_RL_RAID5 && + qual >= 0 && qual <= 3) { + /* RAID5 */ + } else + return (G_RAID_TR_TASTE_FAIL); + trs->trso_starting = 1; + return (G_RAID_TR_TASTE_SUCCEED); +} + +static int +g_raid_tr_update_state_raid5(struct g_raid_volume *vol, + struct g_raid_subdisk *sd) +{ + struct g_raid_tr_raid5_object *trs; + struct g_raid_softc *sc; + u_int s; + int na, ns, nu; + + sc = vol->v_softc; + trs = (struct g_raid_tr_raid5_object *)vol->v_tr; + if (trs->trso_stopping && + (trs->trso_flags & TR_RAID5_F_DOING_SOME) == 0) + s = G_RAID_VOLUME_S_STOPPED; + else if (trs->trso_starting) + s = G_RAID_VOLUME_S_STARTING; + else { + na = g_raid_nsubdisks(vol, G_RAID_SUBDISK_S_ACTIVE); + ns = g_raid_nsubdisks(vol, G_RAID_SUBDISK_S_STALE) + + g_raid_nsubdisks(vol, G_RAID_SUBDISK_S_RESYNC); + nu = g_raid_nsubdisks(vol, G_RAID_SUBDISK_S_UNINITIALIZED); + if (na == vol->v_disks_count) + s = G_RAID_VOLUME_S_OPTIMAL; + else if (na + ns == vol->v_disks_count || + na + ns + nu == vol->v_disks_count /* XXX: Temporary. */) + s = G_RAID_VOLUME_S_SUBOPTIMAL; + else if (na == vol->v_disks_count - 1 || + na + ns + nu == vol->v_disks_count) + s = G_RAID_VOLUME_S_DEGRADED; + else + s = G_RAID_VOLUME_S_BROKEN; + } + if (s != vol->v_state) { + g_raid_event_send(vol, G_RAID_VOLUME_S_ALIVE(s) ? + G_RAID_VOLUME_E_UP : G_RAID_VOLUME_E_DOWN, + G_RAID_EVENT_VOLUME); + g_raid_change_volume_state(vol, s); + if (!trs->trso_starting && !trs->trso_stopping) + g_raid_write_metadata(sc, vol, NULL, NULL); + } + return (0); +} + +static int +g_raid_tr_event_raid5(struct g_raid_tr_object *tr, + struct g_raid_subdisk *sd, u_int event) +{ + + g_raid_tr_update_state_raid5(tr->tro_volume, sd); + return (0); +} + +static int +g_raid_tr_start_raid5(struct g_raid_tr_object *tr) +{ + struct g_raid_tr_raid5_object *trs; + struct g_raid_volume *vol; + + trs = (struct g_raid_tr_raid5_object *)tr; + vol = tr->tro_volume; + trs->trso_starting = 0; + g_raid_tr_update_state_raid5(vol, NULL); + return (0); +} + +static int +g_raid_tr_stop_raid5(struct g_raid_tr_object *tr) +{ + struct g_raid_tr_raid5_object *trs; + struct g_raid_volume *vol; + + trs = (struct g_raid_tr_raid5_object *)tr; + vol = tr->tro_volume; + trs->trso_starting = 0; + trs->trso_stopping = 1; + g_raid_tr_update_state_raid5(vol, NULL); + return (0); +} + +static void +g_raid_tr_iostart_raid5_read(struct g_raid_tr_object *tr, struct bio *bp) +{ + struct g_raid_volume *vol; + struct g_raid_subdisk *sd; + struct bio_queue_head queue; + struct bio *cbp; + char *addr; + off_t offset, start, length, nstripe, remain; + int no, pno; + u_int strip_size, qual; + + vol = tr->tro_volume; + addr = bp->bio_data; + strip_size = vol->v_strip_size; + qual = tr->tro_volume->v_raid_level_qualifier; + + /* Stripe number. */ + nstripe = bp->bio_offset / strip_size; + /* Start position in stripe. */ + start = bp->bio_offset % strip_size; + /* Parity disk number. */ + pno = nstripe / (vol->v_disks_count - 1) % vol->v_disks_count; + if (qual >= 2) + pno = (vol->v_disks_count - 1) - pno; + /* Disk number. */ + no = nstripe % (vol->v_disks_count - 1); + if (qual & 1) { + no = (pno + no + 1) % vol->v_disks_count; + } else if (no >= pno) + no++; + /* Stripe start position in disk. */ + offset = (nstripe / (vol->v_disks_count - 1)) * strip_size; + /* Length of data to operate. */ + remain = bp->bio_length; + + bioq_init(&queue); + do { + length = MIN(strip_size - start, remain); + cbp = g_clone_bio(bp); + if (cbp == NULL) + goto failure; + cbp->bio_offset = offset + start; + cbp->bio_data = addr; + cbp->bio_length = length; + cbp->bio_caller1 = &vol->v_subdisks[no]; + bioq_insert_tail(&queue, cbp); + no++; + if (qual & 1) { + no %= vol->v_disks_count; + if (no == pno) { + if (qual < 2) { + pno = (pno + 1) % vol->v_disks_count; + no = (no + 2) % vol->v_disks_count; + } else if (pno == 0) + pno = vol->v_disks_count - 1; + else + pno--; + offset += strip_size; + } + } else { + if (no == pno) + no++; + if (no >= vol->v_disks_count) { + no %= vol->v_disks_count; + if (qual < 2) + pno = (pno + 1) % vol->v_disks_count; + else if (pno == 0) + pno = vol->v_disks_count - 1; + else + pno--; + offset += strip_size; + } + if (no == pno) + no++; + } + remain -= length; + addr += length; + start = 0; + } while (remain > 0); + for (cbp = bioq_first(&queue); cbp != NULL; + cbp = bioq_first(&queue)) { + bioq_remove(&queue, cbp); + sd = cbp->bio_caller1; + cbp->bio_caller1 = NULL; + g_raid_subdisk_iostart(sd, cbp); + } + return; +failure: + for (cbp = bioq_first(&queue); cbp != NULL; + cbp = bioq_first(&queue)) { + bioq_remove(&queue, cbp); + g_destroy_bio(cbp); + } + if (bp->bio_error == 0) + bp->bio_error = ENOMEM; + g_raid_iodone(bp, bp->bio_error); +} + +static void +g_raid_tr_iostart_raid5(struct g_raid_tr_object *tr, struct bio *bp) +{ + struct g_raid_volume *vol; + struct g_raid_tr_raid5_object *trs; + + vol = tr->tro_volume; + trs = (struct g_raid_tr_raid5_object *)tr; + if (vol->v_state < G_RAID_VOLUME_S_SUBOPTIMAL) { + g_raid_iodone(bp, EIO); + return; + } + switch (bp->bio_cmd) { + case BIO_READ: + g_raid_tr_iostart_raid5_read(tr, bp); + break; + case BIO_WRITE: + case BIO_DELETE: + case BIO_FLUSH: + g_raid_iodone(bp, ENODEV); + break; + default: + KASSERT(1 == 0, ("Invalid command here: %u (volume=%s)", + bp->bio_cmd, vol->v_name)); + break; + } +} + +static void +g_raid_tr_iodone_raid5(struct g_raid_tr_object *tr, + struct g_raid_subdisk *sd, struct bio *bp) +{ + struct bio *pbp; + int error; + + pbp = bp->bio_parent; + pbp->bio_inbed++; + error = bp->bio_error; + g_destroy_bio(bp); + if (pbp->bio_children == pbp->bio_inbed) { + pbp->bio_completed = pbp->bio_length; + g_raid_iodone(pbp, error); + } +} + +static int +g_raid_tr_kerneldump_raid5(struct g_raid_tr_object *tr, + void *virtual, vm_offset_t physical, off_t offset, size_t length) +{ + + return (ENODEV); +} + +static int +g_raid_tr_locked_raid5(struct g_raid_tr_object *tr, void *argp) +{ + struct bio *bp; + struct g_raid_subdisk *sd; + + bp = (struct bio *)argp; + sd = (struct g_raid_subdisk *)bp->bio_caller1; + g_raid_subdisk_iostart(sd, bp); + + return (0); +} + +static int +g_raid_tr_free_raid5(struct g_raid_tr_object *tr) +{ + struct g_raid_tr_raid5_object *trs; + + trs = (struct g_raid_tr_raid5_object *)tr; + + if (trs->trso_buffer != NULL) { + free(trs->trso_buffer, M_TR_RAID5); + trs->trso_buffer = NULL; + } + return (0); +} + +G_RAID_TR_DECLARE(g_raid_tr_raid5); Modified: head/sys/modules/geom/geom_raid/Makefile ============================================================================== --- head/sys/modules/geom/geom_raid/Makefile Thu Apr 19 10:53:17 2012 (r234457) +++ head/sys/modules/geom/geom_raid/Makefile Thu Apr 19 12:30:12 2012 (r234458) @@ -11,7 +11,7 @@ SRCS+= g_raid_tr_if.h g_raid_tr_if.c SRCS+= md_intel.c md_jmicron.c md_nvidia.c md_promise.c md_sii.c -SRCS+= tr_concat.c tr_raid0.c tr_raid1.c tr_raid1e.c +SRCS+= tr_concat.c tr_raid0.c tr_raid1.c tr_raid1e.c tr_raid5.c MFILES= kern/bus_if.m kern/device_if.m MFILES+= geom/raid/g_raid_md_if.m geom/raid/g_raid_tr_if.m From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 12:43:20 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BC93B1065673; Thu, 19 Apr 2012 12:43:20 +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 8E21A8FC0C; Thu, 19 Apr 2012 12:43:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JChKVW089308; Thu, 19 Apr 2012 12:43:20 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JChKR4089305; Thu, 19 Apr 2012 12:43:20 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201204191243.q3JChKR4089305@svn.freebsd.org> From: Michael Tuexen Date: Thu, 19 Apr 2012 12:43: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: r234459 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 12:43:20 -0000 Author: tuexen Date: Thu Apr 19 12:43:19 2012 New Revision: 234459 URL: http://svn.freebsd.org/changeset/base/234459 Log: Fix a bug where we copy out more data from a mbuf chain that are actually in it. This happens when SCTP receives an unknown chunk, which requires the sending of an ERROR chunk, and there is no final padding but the chunk is not 4-byte aligned. Reported by yueting via rwatson@ MFC after: 3 days Modified: head/sys/netinet/sctp_indata.c head/sys/netinet/sctp_input.c Modified: head/sys/netinet/sctp_indata.c ============================================================================== --- head/sys/netinet/sctp_indata.c Thu Apr 19 12:30:12 2012 (r234458) +++ head/sys/netinet/sctp_indata.c Thu Apr 19 12:43:19 2012 (r234459) @@ -2746,11 +2746,13 @@ sctp_process_data(struct mbuf **mm, int phd->param_length = htons(chk_length + sizeof(*phd)); SCTP_BUF_LEN(merr) = sizeof(*phd); - SCTP_BUF_NEXT(merr) = SCTP_M_COPYM(m, *offset, - SCTP_SIZE32(chk_length), - M_DONTWAIT); + SCTP_BUF_NEXT(merr) = SCTP_M_COPYM(m, *offset, chk_length, M_DONTWAIT); if (SCTP_BUF_NEXT(merr)) { - sctp_queue_op_err(stcb, merr); + if (sctp_pad_lastmbuf(SCTP_BUF_NEXT(merr), SCTP_SIZE32(chk_length) - chk_length, NULL)) { + sctp_m_freem(merr); + } else { + sctp_queue_op_err(stcb, merr); + } } else { sctp_m_freem(merr); } Modified: head/sys/netinet/sctp_input.c ============================================================================== --- head/sys/netinet/sctp_input.c Thu Apr 19 12:30:12 2012 (r234458) +++ head/sys/netinet/sctp_input.c Thu Apr 19 12:43:19 2012 (r234459) @@ -5461,23 +5461,26 @@ process_control_chunks: phd->param_type = htons(SCTP_CAUSE_UNRECOG_CHUNK); phd->param_length = htons(chk_length + sizeof(*phd)); SCTP_BUF_LEN(mm) = sizeof(*phd); - SCTP_BUF_NEXT(mm) = SCTP_M_COPYM(m, *offset, SCTP_SIZE32(chk_length), - M_DONTWAIT); + SCTP_BUF_NEXT(mm) = SCTP_M_COPYM(m, *offset, chk_length, M_DONTWAIT); if (SCTP_BUF_NEXT(mm)) { + if (sctp_pad_lastmbuf(SCTP_BUF_NEXT(mm), SCTP_SIZE32(chk_length) - chk_length, NULL)) { + sctp_m_freem(mm); + } else { #ifdef SCTP_MBUF_LOGGING - if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { - struct mbuf *mat; + if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { + struct mbuf *mat; - mat = SCTP_BUF_NEXT(mm); - while (mat) { - if (SCTP_BUF_IS_EXTENDED(mat)) { - sctp_log_mb(mat, SCTP_MBUF_ICOPY); + mat = SCTP_BUF_NEXT(mm); + while (mat) { + if (SCTP_BUF_IS_EXTENDED(mat)) { + sctp_log_mb(mat, SCTP_MBUF_ICOPY); + } + mat = SCTP_BUF_NEXT(mat); } - mat = SCTP_BUF_NEXT(mat); } - } #endif - sctp_queue_op_err(stcb, mm); + sctp_queue_op_err(stcb, mm); + } } else { sctp_m_freem(mm); } From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 12:47:19 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9141E106566B; Thu, 19 Apr 2012 12:47:19 +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 7CC038FC14; Thu, 19 Apr 2012 12:47:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JClJMY089475; Thu, 19 Apr 2012 12:47:19 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JClJDO089473; Thu, 19 Apr 2012 12:47:19 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201204191247.q3JClJDO089473@svn.freebsd.org> From: Michael Tuexen Date: Thu, 19 Apr 2012 12:47: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: r234460 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 12:47:19 -0000 Author: tuexen Date: Thu Apr 19 12:47:18 2012 New Revision: 234460 URL: http://svn.freebsd.org/changeset/base/234460 Log: Fix reported errno. MFC after: 3 days Modified: head/sys/netinet/sctputil.c Modified: head/sys/netinet/sctputil.c ============================================================================== --- head/sys/netinet/sctputil.c Thu Apr 19 12:43:19 2012 (r234459) +++ head/sys/netinet/sctputil.c Thu Apr 19 12:47:18 2012 (r234460) @@ -2553,8 +2553,8 @@ sctp_add_pad_tombuf(struct mbuf *m, int tmp = sctp_get_mbuf_for_msg(padlen, 0, M_DONTWAIT, 1, MT_DATA); if (tmp == NULL) { /* Out of space GAK! we are in big trouble. */ - SCTP_LTRACE_ERR_RET_PKT(m, NULL, NULL, NULL, SCTP_FROM_SCTPUTIL, EINVAL); - return (ENOSPC); + SCTP_LTRACE_ERR_RET_PKT(m, NULL, NULL, NULL, SCTP_FROM_SCTPUTIL, ENOBUFS); + return (ENOBUFS); } /* setup and insert in middle */ SCTP_BUF_LEN(tmp) = padlen; From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 13:11:18 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 707861065744; Thu, 19 Apr 2012 13:11:18 +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 50B958FC1A; Thu, 19 Apr 2012 13:11:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JDBItf090253; Thu, 19 Apr 2012 13:11:18 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JDBIZj090250; Thu, 19 Apr 2012 13:11:18 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201204191311.q3JDBIZj090250@svn.freebsd.org> From: Michael Tuexen Date: Thu, 19 Apr 2012 13:11: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: r234461 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 13:11:18 -0000 Author: tuexen Date: Thu Apr 19 13:11:17 2012 New Revision: 234461 URL: http://svn.freebsd.org/changeset/base/234461 Log: Use the same pattern for mbuf logging everywhere. MFC after: 3 days Modified: head/sys/netinet/sctp_input.c head/sys/netinet/sctp_output.c Modified: head/sys/netinet/sctp_input.c ============================================================================== --- head/sys/netinet/sctp_input.c Thu Apr 19 12:47:18 2012 (r234460) +++ head/sys/netinet/sctp_input.c Thu Apr 19 13:11:17 2012 (r234461) @@ -2463,12 +2463,10 @@ sctp_handle_cookie_echo(struct mbuf *m, if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = m_sig; - while (mat) { + for (mat = m_sig; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_SPLIT); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -5470,12 +5468,10 @@ process_control_chunks: if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = SCTP_BUF_NEXT(mm); - while (mat) { + for (mat = SCTP_BUF_NEXT(mm); mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -5808,10 +5804,6 @@ sctp_print_mbuf_chain(struct mbuf *m) void sctp_input_with_port(struct mbuf *i_pak, int off, uint16_t port) { -#ifdef SCTP_MBUF_LOGGING - struct mbuf *mat; - -#endif struct mbuf *m; int iphlen; uint32_t vrf_id = 0; @@ -5846,6 +5838,8 @@ sctp_input_with_port(struct mbuf *i_pak, #ifdef SCTP_MBUF_LOGGING /* Log in any input mbufs */ if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { + struct mbuf *mat; + for (mat = m; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_INPUT); Modified: head/sys/netinet/sctp_output.c ============================================================================== --- head/sys/netinet/sctp_output.c Thu Apr 19 12:47:18 2012 (r234460) +++ head/sys/netinet/sctp_output.c Thu Apr 19 13:11:17 2012 (r234461) @@ -3714,12 +3714,10 @@ sctp_add_cookie(struct mbuf *init, int i if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = copy_init; - while (mat) { + for (mat = copy_init; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -3734,12 +3732,10 @@ sctp_add_cookie(struct mbuf *init, int i if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = copy_initack; - while (mat) { + for (mat = copy_initack; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -6446,12 +6442,10 @@ error_out: if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = appendchain; - while (mat) { + for (mat = appendchain; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -6547,12 +6541,10 @@ sctp_sendall_iterator(struct sctp_inpcb if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = m; - while (mat) { + for (mat = m; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -7350,12 +7342,10 @@ dont_do_it: if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = chk->data; - while (mat) { + for (mat = chk->data; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -8953,12 +8943,10 @@ sctp_send_cookie_echo(struct mbuf *m, if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = cookie; - while (mat) { + for (mat = cookie; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -9027,12 +9015,10 @@ sctp_send_heartbeat_ack(struct sctp_tcb if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = outchain; - while (mat) { + for (mat = outchain; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif @@ -9313,12 +9299,10 @@ sctp_send_asconf_ack(struct sctp_tcb *st if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_MBUF_LOGGING_ENABLE) { struct mbuf *mat; - mat = m_ack; - while (mat) { + for (mat = m_ack; mat; mat = SCTP_BUF_NEXT(mat)) { if (SCTP_BUF_IS_EXTENDED(mat)) { sctp_log_mb(mat, SCTP_MBUF_ICOPY); } - mat = SCTP_BUF_NEXT(mat); } } #endif From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 14:16:06 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B0EE3106566C; Thu, 19 Apr 2012 14:16:06 +0000 (UTC) (envelope-from conrads@cox.net) Received: from eastrmfepo201.cox.net (eastrmfepo201.cox.net [68.230.241.216]) by mx1.freebsd.org (Postfix) with ESMTP id E2E698FC14; Thu, 19 Apr 2012 14:16:05 +0000 (UTC) Received: from eastrmimpo209.cox.net ([68.230.241.224]) by eastrmfepo201.cox.net (InterMail vM.8.01.04.00 201-2260-137-20101110) with ESMTP id <20120419141605.JKMR5450.eastrmfepo201.cox.net@eastrmimpo209.cox.net>; Thu, 19 Apr 2012 10:16:05 -0400 Received: from serene.no-ip.org ([98.164.83.206]) by eastrmimpo209.cox.net with bizsmtp id zqG41i00D4T5sES02qG49Y; Thu, 19 Apr 2012 10:16:05 -0400 X-CT-Class: Clean X-CT-Score: 0.00 X-CT-RefID: str=0001.0A020203.4F901E25.004B,ss=1,re=0.000,fgs=0 X-CT-Spam: 0 X-Authority-Analysis: v=1.1 cv=VU6xqV7QUVMoFuYfc/i7GKH2czOHNOYjjc3mdSfZ1wc= c=1 sm=1 a=N17yZKeAuoQA:10 a=G8Uczd0VNMoA:10 a=kj9zAlcOel0A:10 a=cRs4AX/51puMaUeRAuoQtw==:17 a=6I5d2MoRAAAA:8 a=kviXuzpPAAAA:8 a=aYuT87YwLntIWVnZH2QA:9 a=ZmCsHU5ByYXempQmqHsA:7 a=CjuIK1q_8ugA:10 a=SV7veod9ZcQA:10 a=4vB-4DCPJfMA:10 a=cRs4AX/51puMaUeRAuoQtw==:117 X-CM-Score: 0.00 Authentication-Results: cox.net; none Received: from cox.net (localhost [127.0.0.1]) by serene.no-ip.org (8.14.5/8.14.5) with ESMTP id q3JEG4DU076796; Thu, 19 Apr 2012 09:16:04 -0500 (CDT) (envelope-from conrads@cox.net) Date: Thu, 19 Apr 2012 09:15:58 -0500 From: "Conrad J. Sabatier" To: Adrian Chadd Message-ID: <20120419091558.2ae655a0@cox.net> In-Reply-To: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: svn-src-all@freebsd.org, "Bjoern A. Zeeb" , src-committers@freebsd.org, Jason Evans Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 14:16:06 -0000 On Tue, 17 Apr 2012 11:05:08 -0700 Adrian Chadd wrote: > On 17 April 2012 02:43, Bjoern A. Zeeb wrote: > > > Actually it seems these failed: > > > > arm.armeb buildworld failed, check _.arm.armeb.buildworld for > > details arm.arm buildworld failed, check _.arm.arm.buildworld for > > details mips.mips64 buildworld failed, check > > _.mips.mips64.buildworld for details mips.mipsel buildworld failed, > > check _.mips.mipsel.buildworld for details mips.mips64el buildworld > > failed, check _.mips.mips64el.buildworld for details mips.mipsn32 > > buildworld failed, check _.mips.mipsn32.buildworld for details > > mips.mips buildworld failed, check _.mips.mips.buildworld for > > details i386.i386 buildworld failed, check _.i386.i386.buildworld > > for details pc98.i386 buildworld failed, check > > _.pc98.i386.buildworld for details powerpc.powerpc buildworld > > failed, check _.powerpc.powerpc.buildworld for details > > powerpc.powerpc64 buildworld failed, check > > _.powerpc.powerpc64.buildworld for details > > This looks like it only works on amd64 and sparc64. Lucky them. :) Actually, I keep getting "undefined reference to _malloc_options" while building libexec/atrun on amd64. Not sure what the problem may be. Could it have something to do with doing a debug build (with -g)? ===> libexec/atrun (all) clang -Wno-error -O2 -g -pipe -fno-strict-aliasing -march=native -DATJOB_DIR=\"/var/at/jobs/\" -DLFILE=\"/var/at/jobs/.lockfile\" -DLOADAVG_MX=1.5 -DATSPOOL_DIR=\"/var/at/spool\" -DVERSION=\"2.9\" -DDAEMON_UID=1 -DDAEMON_GID=1 -DDEFAULT_BATCH_QUEUE=\'E\' -DDEFAULT_AT_QUEUE=\'c\' -DPERM_PATH=\"/var/at/\" -I/usr/src/libexec/atrun/../../usr.bin/at -I/usr/src/libexec/atrun -DLOGIN_CAP -DPAM -DNDEBUG -std=gnu99 -Qunused-arguments -Wsystem-headers -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -Wno-tautological-compare -Wno-unused-value -Wno-parentheses-equality -Wno-unused-function -Wno-conversion -Wno-switch -Wno-switch-enum -c /usr/src/libexec/atrun/atrun.c clang -Wno-error -O2 -g -pipe -fno-strict-aliasing -march=native -DATJOB_DIR=\"/var/at/jobs/\" -DLFILE=\"/var/at/jobs/.lockfile\" -DLOADAVG_MX=1.5 -DATSPOOL_DIR=\"/var/at/spool\" -DVERSION=\"2.9\" -DDAEMON_UID=1 -DDAEMON_GID=1 -DDEFAULT_BATCH_QUEUE=\'E\' -DDEFAULT_AT_QUEUE=\'c\' -DPERM_PATH=\"/var/at/\" -I/usr/src/libexec/atrun/../../usr.bin/at -I/usr/src/libexec/atrun -DLOGIN_CAP -DPAM -DNDEBUG -std=gnu99 -Qunused-arguments -Wsystem-headers -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -Wno-tautological-compare -Wno-unused-value -Wno-parentheses-equality -Wno-unused-function -Wno-conversion -Wno-switch -Wno-switch-enum -c /usr/src/libexec/atrun/gloadavg.c clang -Wno-error -O2 -g -pipe -fno-strict-aliasing -march=native -DATJOB_DIR=\"/var/at/jobs/\" -DLFILE=\"/var/at/jobs/.lockfile\" -DLOADAVG_MX=1.5 -DATSPOOL_DIR=\"/var/at/spool\" -DVERSION=\"2.9\" -DDAEMON_UID=1 -DDAEMON_GID=1 -DDEFAULT_BATCH_QUEUE=\'E\' -DDEFAULT_AT_QUEUE=\'c\' -DPERM_PATH=\"/var/at/\" -I/usr/src/libexec/atrun/../../usr.bin/at -I/usr/src/libexec/atrun -DLOGIN_CAP -DPAM -DNDEBUG -std=gnu99 -Qunused-arguments -Wsystem-headers -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -Wno-tautological-compare -Wno-unused-value -Wno-parentheses-equality -Wno-unused-function -Wno-conversion -Wno-switch -Wno-switch-enum -o atrun atrun.o gloadavg.o -lpam -lutil /usr/obj/usr/src/tmp/usr/lib/libc.so: undefined reference to `_malloc_options' clang: error: linker command failed with exit code 1 (use -v to see invocation) *** [atrun] Error code 1 Stop in /usr/src/libexec/atrun. *** [all] Error code 1 Stop in /usr/src/libexec. *** [libexec.all__D] Error code 1 Stop in /usr/src. *** [everything] Error code 1 Stop in /usr/src. *** [buildworld] Error code 1 Stop in /usr/src. -- Conrad J. Sabatier conrads@cox.net From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 14:18:19 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3732D106564A; Thu, 19 Apr 2012 14:18:19 +0000 (UTC) (envelope-from bz@FreeBSD.org) Received: from mx1.sbone.de (mx1.sbone.de [IPv6:2a01:4f8:130:3ffc::401:25]) by mx1.freebsd.org (Postfix) with ESMTP id D8BFA8FC0C; Thu, 19 Apr 2012 14:18:18 +0000 (UTC) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:31::2013:587]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.sbone.de (Postfix) with ESMTPS id BEF6E25D389C; Thu, 19 Apr 2012 14:18:17 +0000 (UTC) Received: from content-filter.sbone.de (content-filter.sbone.de [IPv6:fde9:577b:c1a9:31::2013:2742]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id DB93DBE52D4; Thu, 19 Apr 2012 14:18:16 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:31::2013:587]) by content-filter.sbone.de (content-filter.sbone.de [fde9:577b:c1a9:31::2013:2742]) (amavisd-new, port 10024) with ESMTP id vl2Ofjydk7Xk; Thu, 19 Apr 2012 14:18:16 +0000 (UTC) Received: from orange-en1.sbone.de (orange-en1.sbone.de [IPv6:fde9:577b:c1a9:31:cabc:c8ff:fecf:e8e3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id 0B39FBE52D8; Thu, 19 Apr 2012 14:18:16 +0000 (UTC) Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: "Bjoern A. Zeeb" In-Reply-To: <20120419091558.2ae655a0@cox.net> Date: Thu, 19 Apr 2012 14:18:15 +0000 Content-Transfer-Encoding: 7bit Message-Id: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> <20120419091558.2ae655a0@cox.net> To: "Conrad J. Sabatier" X-Mailer: Apple Mail (2.1084) Cc: svn-src-all@freebsd.org, src-committers@freebsd.org, Jason Evans Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 14:18:19 -0000 On 19. Apr 2012, at 14:15 , Conrad J. Sabatier wrote: > Actually, I keep getting "undefined reference to _malloc_options" while > building libexec/atrun on amd64. Not sure what the problem may be. > Could it have something to do with doing a debug build (with -g)? See UPDATING entry. -- Bjoern A. Zeeb You have to have visions! It does not matter how good you are. It matters what good you do! From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 15:08:21 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B09BB106566B; Thu, 19 Apr 2012 15:08:21 +0000 (UTC) (envelope-from conrads@cox.net) Received: from eastrmfepo203.cox.net (eastrmfepo203.cox.net [68.230.241.218]) by mx1.freebsd.org (Postfix) with ESMTP id DFF4F8FC16; Thu, 19 Apr 2012 15:08:20 +0000 (UTC) Received: from eastrmimpo306.cox.net ([68.230.241.238]) by eastrmfepo203.cox.net (InterMail vM.8.01.04.00 201-2260-137-20101110) with ESMTP id <20120419150814.PJKF18532.eastrmfepo203.cox.net@eastrmimpo306.cox.net>; Thu, 19 Apr 2012 11:08:14 -0400 Received: from serene.no-ip.org ([98.164.83.206]) by eastrmimpo306.cox.net with bizsmtp id zr8D1i00W4T5sES02r8EC6; Thu, 19 Apr 2012 11:08:14 -0400 X-CT-Class: Clean X-CT-Score: 0.00 X-CT-RefID: str=0001.0A020208.4F902A5E.00C6,ss=1,re=0.000,fgs=0 X-CT-Spam: 0 X-Authority-Analysis: v=1.1 cv=CRPD+Qc8oD39miT01U+idCnfgtTI0UgUfEDugnPCZ2w= c=1 sm=1 a=N17yZKeAuoQA:10 a=G8Uczd0VNMoA:10 a=kj9zAlcOel0A:10 a=cRs4AX/51puMaUeRAuoQtw==:17 a=6I5d2MoRAAAA:8 a=kviXuzpPAAAA:8 a=LLzJKdKonVJDgpNP_EMA:9 a=14or1Kahr9lXTiFcAG8A:7 a=CjuIK1q_8ugA:10 a=SV7veod9ZcQA:10 a=4vB-4DCPJfMA:10 a=cRs4AX/51puMaUeRAuoQtw==:117 X-CM-Score: 0.00 Authentication-Results: cox.net; none Received: from cox.net (localhost [127.0.0.1]) by serene.no-ip.org (8.14.5/8.14.5) with ESMTP id q3JF8DQ6051413; Thu, 19 Apr 2012 10:08:13 -0500 (CDT) (envelope-from conrads@cox.net) Date: Thu, 19 Apr 2012 10:08:08 -0500 From: "Conrad J. Sabatier" To: "Bjoern A. Zeeb" Message-ID: <20120419100808.3e7e3645@cox.net> In-Reply-To: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> <20120419091558.2ae655a0@cox.net> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: svn-src-all@freebsd.org, src-committers@freebsd.org, Jason Evans Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 15:08:21 -0000 On Thu, 19 Apr 2012 14:18:15 +0000 "Bjoern A. Zeeb" wrote: > On 19. Apr 2012, at 14:15 , Conrad J. Sabatier wrote: > > > Actually, I keep getting "undefined reference to _malloc_options" > > while building libexec/atrun on amd64. Not sure what the problem > > may be. Could it have something to do with doing a debug build > > (with -g)? > > See UPDATING entry. > Yes, that's what's so strange here; I've already done that. Deleted my old /etc/malloc.conf symlink when I first came across that information, and haven't created a new one yet. Thought it may have been due to having MALLOC_PRODUCTION defined in /etc/make.conf and/or /etc/src.conf, so disabled that, too. Still the problem persists. Quite mystifying at this point. :-) -- Conrad J. Sabatier conrads@cox.net From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 15:28:15 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BCA9C1065675; Thu, 19 Apr 2012 15:28:15 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A93E68FC15; Thu, 19 Apr 2012 15:28:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JFSF5J094524; Thu, 19 Apr 2012 15:28:15 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JFSFQp094522; Thu, 19 Apr 2012 15:28:15 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201204191528.q3JFSFQp094522@svn.freebsd.org> From: Ed Schouten Date: Thu, 19 Apr 2012 15:28: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: r234462 - head/lib/libulog X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 15:28:15 -0000 Author: ed Date: Thu Apr 19 15:28:15 2012 New Revision: 234462 URL: http://svn.freebsd.org/changeset/base/234462 Log: Properly use SHA1_Final() instead of SHA_Final(). In this case it doesn't really matter, as long as we turn a TTY name into a set of shuffled bytes. Still, for correctness we should use the proper function. MFC after: 2 weeks Modified: head/lib/libulog/ulog_login.c Modified: head/lib/libulog/ulog_login.c ============================================================================== --- head/lib/libulog/ulog_login.c Thu Apr 19 13:11:17 2012 (r234461) +++ head/lib/libulog/ulog_login.c Thu Apr 19 15:28:15 2012 (r234462) @@ -55,7 +55,7 @@ ulog_fill(struct utmpx *utx, const char SHA1_Init(&c); SHA1_Update(&c, "libulog", 7); SHA1_Update(&c, utx->ut_line, sizeof utx->ut_line); - SHA_Final(id, &c); + SHA1_Final(id, &c); memcpy(utx->ut_id, id, MIN(sizeof utx->ut_id, sizeof id)); } From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 15:29:10 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AC4771065675; Thu, 19 Apr 2012 15:29:10 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7BD788FC1A; Thu, 19 Apr 2012 15:29:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JFTACX094589; Thu, 19 Apr 2012 15:29:10 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JFTAho094586; Thu, 19 Apr 2012 15:29:10 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201204191529.q3JFTAho094586@svn.freebsd.org> From: Sergey Kandaurov Date: Thu, 19 Apr 2012 15:29: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: r234463 - head/share/man/man9 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 15:29:10 -0000 Author: pluknet Date: Thu Apr 19 15:29:09 2012 New Revision: 234463 URL: http://svn.freebsd.org/changeset/base/234463 Log: Document swi_remove(9). Reviewed by: jhb MFC after: 1 week Modified: head/share/man/man9/Makefile head/share/man/man9/swi.9 Modified: head/share/man/man9/Makefile ============================================================================== --- head/share/man/man9/Makefile Thu Apr 19 15:28:15 2012 (r234462) +++ head/share/man/man9/Makefile Thu Apr 19 15:29:09 2012 (r234463) @@ -1250,6 +1250,7 @@ MLINKS+=store.9 subyte.9 \ store.9 suword32.9 \ store.9 suword64.9 MLINKS+=swi.9 swi_add.9 \ + swi.9 swi_remove.9 \ swi.9 swi_sched.9 MLINKS+=sx.9 sx_assert.9 \ sx.9 sx_destroy.9 \ Modified: head/share/man/man9/swi.9 ============================================================================== --- head/share/man/man9/swi.9 Thu Apr 19 15:28:15 2012 (r234462) +++ head/share/man/man9/swi.9 Thu Apr 19 15:29:09 2012 (r234463) @@ -24,11 +24,12 @@ .\" .\" $FreeBSD$ .\" -.Dd April 12, 2012 +.Dd April 19, 2012 .Dt SWI 9 .Os .Sh NAME .Nm swi_add , +.Nm swi_remove , .Nm swi_sched .Nd register and schedule software interrupt handlers .Sh SYNOPSIS @@ -50,6 +51,8 @@ .Fa "enum intr_type flags" .Fa "void **cookiep" .Fc +.Ft int +.Fn swi_remove "void *cookie" .Ft void .Fn swi_sched "void *cookie" "int flags" .Sh DESCRIPTION @@ -114,6 +117,14 @@ This cookie will be set to a value that and is used to schedule the handler for execution later on. .Pp The +.Fn swi_remove +function is used to teardown an interrupt handler pointed to by the +.Fa cookie +argument. +It detaches the interrupt handler from the associated interrupt event +and frees its memory. +.Pp +The .Fn swi_sched function is used to schedule an interrupt handler and its associated thread to run. @@ -164,7 +175,9 @@ networking stack, clock interrupt, and V .Sh RETURN VALUES The .Fn swi_add -function returns zero on success and non-zero on failure. +and +.Fn swi_remove +functions return zero on success and non-zero on failure. .Sh ERRORS The .Fn swi_add @@ -201,6 +214,17 @@ flag is specified and the interrupt even already has at least one handler, or the interrupt event already has an exclusive handler. .El +.Pp +The +.Fn swi_remove +function will fail if: +.Bl -tag -width Er +.It Bq Er EINVAL +A software interrupt handler pointed to by +.Fa cookie +is +.Dv NULL . +.El .Sh SEE ALSO .Xr ithread 9 , .Xr taskqueue 9 @@ -221,6 +245,10 @@ and .Fn schedsoft* functions which date back to at least .Bx 4.4 . +The +.Fn swi_remove +function first appeared in +.Fx 6.1 . .Sh BUGS Most of the global variables described in this manual page should not be global, or at the very least should not be declared in From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 15:30:16 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0DB67106564A; Thu, 19 Apr 2012 15:30:16 +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 ED25C8FC1E; Thu, 19 Apr 2012 15:30:15 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JFUFs8094667; Thu, 19 Apr 2012 15:30:15 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JFUFIl094664; Thu, 19 Apr 2012 15:30:15 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201204191530.q3JFUFIl094664@svn.freebsd.org> From: Michael Tuexen Date: Thu, 19 Apr 2012 15:30: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: r234464 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 15:30:16 -0000 Author: tuexen Date: Thu Apr 19 15:30:15 2012 New Revision: 234464 URL: http://svn.freebsd.org/changeset/base/234464 Log: Whitespace changes. MFC after: 3 days Modified: head/sys/netinet/sctp_usrreq.c head/sys/netinet/sctp_var.h Modified: head/sys/netinet/sctp_usrreq.c ============================================================================== --- head/sys/netinet/sctp_usrreq.c Thu Apr 19 15:29:09 2012 (r234463) +++ head/sys/netinet/sctp_usrreq.c Thu Apr 19 15:30:15 2012 (r234464) @@ -1616,7 +1616,7 @@ out_now: } -#define SCTP_CHECK_AND_CAST(destp, srcp, type, size) {\ +#define SCTP_CHECK_AND_CAST(destp, srcp, type, size) {\ if (size < sizeof(type)) { \ SCTP_LTRACE_ERR_RET(inp, NULL, NULL, SCTP_FROM_SCTP_USRREQ, EINVAL); \ error = EINVAL; \ Modified: head/sys/netinet/sctp_var.h ============================================================================== --- head/sys/netinet/sctp_var.h Thu Apr 19 15:29:09 2012 (r234463) +++ head/sys/netinet/sctp_var.h Thu Apr 19 15:30:15 2012 (r234464) @@ -157,7 +157,7 @@ extern struct pr_usrreqs sctp_usrreqs; } #define sctp_alloc_a_chunk(_stcb, _chk) { \ - if (TAILQ_EMPTY(&(_stcb)->asoc.free_chunks)) { \ + if (TAILQ_EMPTY(&(_stcb)->asoc.free_chunks)) { \ (_chk) = SCTP_ZONE_GET(SCTP_BASE_INFO(ipi_zone_chunk), struct sctp_tmit_chunk); \ if ((_chk)) { \ SCTP_INCR_CHK_COUNT(); \ From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 16:13:16 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2A244106566C; Thu, 19 Apr 2012 16:13:16 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1544C8FC12; Thu, 19 Apr 2012 16:13:16 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JGDFNe096008; Thu, 19 Apr 2012 16:13:15 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JGDFFO096006; Thu, 19 Apr 2012 16:13:15 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201204191613.q3JGDFFO096006@svn.freebsd.org> From: Sergey Kandaurov Date: Thu, 19 Apr 2012 16:13: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: r234465 - head/share/man/man9 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 16:13:16 -0000 Author: pluknet Date: Thu Apr 19 16:13:15 2012 New Revision: 234465 URL: http://svn.freebsd.org/changeset/base/234465 Log: - Update the rest of struct ithd references. - net_ih and softclock_ih cookies have gone away. MFC after: 1 week Modified: head/share/man/man9/swi.9 Modified: head/share/man/man9/swi.9 ============================================================================== --- head/share/man/man9/swi.9 Thu Apr 19 15:30:15 2012 (r234464) +++ head/share/man/man9/swi.9 Thu Apr 19 16:13:15 2012 (r234465) @@ -36,10 +36,8 @@ .In sys/param.h .In sys/bus.h .In sys/interrupt.h -.Vt "extern struct ithd *tty_ithd" ; -.Vt "extern struct ithd *clk_ithd" ; -.Vt "extern void *net_ih" ; -.Vt "extern void *softclock_ih" ; +.Vt "extern struct intr_event *tty_intr_event" ; +.Vt "extern struct intr_event *clk_intr_event" ; .Vt "extern void *vm_ih" ; .Ft int .Fo swi_add @@ -152,26 +150,23 @@ in earlier versions of .El .Pp The -.Va tty_ithd +.Va tty_intr_event and -.Va clk_ithd -variables contain pointers to the software interrupt threads for the tty and +.Va clk_intr_event +variables contain pointers to the software interrupt handlers for the tty and clock software interrupts, respectively. -.Va tty_ithd +.Va tty_intr_event is used to hang tty software interrupt handlers off of the same thread. -.Va clk_ithd +.Va clk_intr_event is used to hang delayed handlers off of the clock software interrupt thread so that the functionality of .Fn setdelayed can be obtained in conjunction with .Dv SWI_DELAY . The -.Va net_ih , -.Va softclock_ih , -and .Va vm_ih -handler cookies are used to schedule software interrupt threads to run for the -networking stack, clock interrupt, and VM subsystem respectively. +handler cookie is used to schedule software interrupt threads to run for the +VM subsystem. .Sh RETURN VALUES The .Fn swi_add From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 18:03:25 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1FD43106564A; Thu, 19 Apr 2012 18:03:25 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 08D008FC08; Thu, 19 Apr 2012 18:03:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JI3O7M000268; Thu, 19 Apr 2012 18:03:24 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JI3O5k000262; Thu, 19 Apr 2012 18:03:24 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204191803.q3JI3O5k000262@svn.freebsd.org> From: Kirk McKusick Date: Thu, 19 Apr 2012 18:03:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234466 - in stable/9/sys: fs/msdosfs geom i386/conf kern sys ufs/ffs vm X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 18:03:25 -0000 Author: mckusick Date: Thu Apr 19 18:03:24 2012 New Revision: 234466 URL: http://svn.freebsd.org/changeset/base/234466 Log: MFC of 233627, 234024, 234025, and 234026 Restore per mount-point counts of synchronous and asynchronous reads and writes associated with UFS and MSDOS filesystems. MFS 233627: Keep track of the mount point associated with a special device to enable the collection of counts of synchronous and asynchronous reads and writes for its associated filesystem. The counts are displayed using `mount -v'. Ensure that buffers used for paging indicate the vnode from which they are operating so that counts of paging I/O operations from the filesystem are collected. This checkin only adds the setting of the mount point for the UFS/FFS filesystem, but it would be trivial to add the setting and clearing of the mount point at filesystem mount/unmount time for other filesystems too. Reviewed by: kib MFC 234024: Drop an unnecessary setting of si_mountpt when updating a UFS mount point. Clearly it must have been set when the mount was done. Reviewed by: kib MFC 234025: Add I/O accounting to msdos filesystem. Suggested and reviewed by: kib MFC 234026: Expand locking around identification of filesystem mount point when accounting for I/O counts at completion of I/O operation. Also switch from using global devmtx to vnode mutex to reduce contention. Suggested and reviewed by: kib Modified: stable/9/sys/fs/msdosfs/msdosfs_vfsops.c stable/9/sys/geom/geom_vfs.c stable/9/sys/sys/conf.h stable/9/sys/ufs/ffs/ffs_vfsops.c stable/9/sys/vm/vnode_pager.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/fs/msdosfs/msdosfs_vfsops.c ============================================================================== --- stable/9/sys/fs/msdosfs/msdosfs_vfsops.c Thu Apr 19 16:13:15 2012 (r234465) +++ stable/9/sys/fs/msdosfs/msdosfs_vfsops.c Thu Apr 19 18:03:24 2012 (r234466) @@ -401,6 +401,8 @@ msdosfs_mount(struct mount *mp) return error; } + if (devvp->v_type == VCHR && devvp->v_rdev != NULL) + devvp->v_rdev->si_mountpt = mp; vfs_mountedfrom(mp, from); #ifdef MSDOSFS_DEBUG printf("msdosfs_mount(): mp %p, pmp %p, inusemap %p\n", mp, pmp, pmp->pm_inusemap); @@ -843,6 +845,8 @@ msdosfs_unmount(struct mount *mp, int mn } #endif DROP_GIANT(); + if (pmp->pm_devvp->v_type == VCHR && pmp->pm_devvp->v_rdev != NULL) + pmp->pm_devvp->v_rdev->si_mountpt = NULL; g_topology_lock(); g_vfs_close(pmp->pm_cp); g_topology_unlock(); Modified: stable/9/sys/geom/geom_vfs.c ============================================================================== --- stable/9/sys/geom/geom_vfs.c Thu Apr 19 16:13:15 2012 (r234465) +++ stable/9/sys/geom/geom_vfs.c Thu Apr 19 18:03:24 2012 (r234466) @@ -70,6 +70,9 @@ g_vfs_done(struct bio *bip) { struct buf *bp; int vfslocked; + struct mount *mp; + struct vnode *vp; + struct cdev *cdevp; /* * Provider ('bio_to') could have withered away sometime @@ -81,12 +84,50 @@ g_vfs_done(struct bio *bip) if (bip->bio_from->provider == NULL) bip->bio_to = NULL; + /* + * Collect statistics on synchronous and asynchronous read + * and write counts for disks that have associated filesystems. + * Since this is run by the g_up thread it is single threaded and + * we do not need to use atomic increments on the counters. + */ + bp = bip->bio_caller2; + vp = bp->b_vp; + if (vp == NULL) { + mp = NULL; + } else { + /* + * If not a disk vnode, use its associated mount point + * otherwise use the mountpoint associated with the disk. + */ + VI_LOCK(vp); + if (vp->v_type != VCHR || + (cdevp = vp->v_rdev) == NULL || + cdevp->si_devsw == NULL || + (cdevp->si_devsw->d_flags & D_DISK) == 0) + mp = vp->v_mount; + else + mp = cdevp->si_mountpt; + VI_UNLOCK(vp); + } + if (mp != NULL) { + if (bp->b_iocmd == BIO_WRITE) { + if (LK_HOLDER(bp->b_lock.lk_lock) == LK_KERNPROC) + mp->mnt_stat.f_asyncwrites++; + else + mp->mnt_stat.f_syncwrites++; + } else { + if (LK_HOLDER(bp->b_lock.lk_lock) == LK_KERNPROC) + mp->mnt_stat.f_asyncreads++; + else + mp->mnt_stat.f_syncreads++; + } + } + if (bip->bio_error) { printf("g_vfs_done():"); g_print_bio(bip); printf("error = %d\n", bip->bio_error); } - bp = bip->bio_caller2; bp->b_error = bip->bio_error; bp->b_ioflags = bip->bio_flags; if (bip->bio_error) Modified: stable/9/sys/sys/conf.h ============================================================================== --- stable/9/sys/sys/conf.h Thu Apr 19 16:13:15 2012 (r234465) +++ stable/9/sys/sys/conf.h Thu Apr 19 18:03:24 2012 (r234466) @@ -52,7 +52,7 @@ struct cdevsw; struct file; struct cdev { - void *__si_reserved; + struct mount *si_mountpt; u_int si_flags; #define SI_ETERNAL 0x0001 /* never destroyed */ #define SI_ALIAS 0x0002 /* carrier of alias name */ Modified: stable/9/sys/ufs/ffs/ffs_vfsops.c ============================================================================== --- stable/9/sys/ufs/ffs/ffs_vfsops.c Thu Apr 19 16:13:15 2012 (r234465) +++ stable/9/sys/ufs/ffs/ffs_vfsops.c Thu Apr 19 18:03:24 2012 (r234466) @@ -1050,6 +1050,8 @@ ffs_mountfs(devvp, mp, td) ffs_flushfiles(mp, FORCECLOSE, td); goto out; } + if (devvp->v_type == VCHR && devvp->v_rdev != NULL) + devvp->v_rdev->si_mountpt = mp; if (fs->fs_snapinum[0] != 0) ffs_snapshot_mount(mp); fs->fs_fmod = 1; @@ -1295,6 +1297,8 @@ ffs_unmount(mp, mntflags) g_vfs_close(ump->um_cp); g_topology_unlock(); PICKUP_GIANT(); + if (ump->um_devvp->v_type == VCHR && ump->um_devvp->v_rdev != NULL) + ump->um_devvp->v_rdev->si_mountpt = NULL; vrele(ump->um_devvp); dev_rel(ump->um_dev); mtx_destroy(UFS_MTX(ump)); Modified: stable/9/sys/vm/vnode_pager.c ============================================================================== --- stable/9/sys/vm/vnode_pager.c Thu Apr 19 16:13:15 2012 (r234465) +++ stable/9/sys/vm/vnode_pager.c Thu Apr 19 18:03:24 2012 (r234466) @@ -541,6 +541,7 @@ vnode_pager_input_smlfs(object, m) bp->b_data = (caddr_t)sf_buf_kva(sf) + i * bsize; bp->b_blkno = fileaddr; pbgetbo(bo, bp); + bp->b_vp = vp; bp->b_bcount = bsize; bp->b_bufsize = bsize; bp->b_runningbufspace = bp->b_bufsize; @@ -558,6 +559,7 @@ vnode_pager_input_smlfs(object, m) /* * free the buffer header back to the swap buffer pool */ + bp->b_vp = NULL; pbrelbo(bp); relpbuf(bp, &vnode_pbuf_freecnt); if (error) @@ -916,6 +918,7 @@ vnode_pager_generic_getpages(vp, m, byte bp->b_wcred = crhold(curthread->td_ucred); bp->b_blkno = firstaddr; pbgetbo(bo, bp); + bp->b_vp = vp; bp->b_bcount = size; bp->b_bufsize = size; bp->b_runningbufspace = bp->b_bufsize; @@ -942,6 +945,7 @@ vnode_pager_generic_getpages(vp, m, byte /* * free the buffer header back to the swap buffer pool */ + bp->b_vp = NULL; pbrelbo(bp); relpbuf(bp, &vnode_pbuf_freecnt); From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 18:44:33 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BD4C0106564A; Thu, 19 Apr 2012 18:44:33 +0000 (UTC) (envelope-from jasone@freebsd.org) Received: from canonware.com (10140.x.rootbsd.net [204.109.63.53]) by mx1.freebsd.org (Postfix) with ESMTP id 968478FC0C; Thu, 19 Apr 2012 18:44:33 +0000 (UTC) Received: from [172.25.16.174] (unknown [173.252.71.3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by canonware.com (Postfix) with ESMTPSA id 70E1E28473; Thu, 19 Apr 2012 11:44:27 -0700 (PDT) Mime-Version: 1.0 (Apple Message framework v1257) Content-Type: text/plain; charset=windows-1252 From: Jason Evans In-Reply-To: <20120419091558.2ae655a0@cox.net> Date: Thu, 19 Apr 2012 11:44:29 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> <20120419091558.2ae655a0@cox.net> To: Conrad J. Sabatier X-Mailer: Apple Mail (2.1257) Cc: svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 18:44:33 -0000 On Apr 19, 2012, at 7:15 AM, Conrad J. Sabatier wrote: > Actually, I keep getting "undefined reference to _malloc_options" = while > building libexec/atrun on amd64. Not sure what the problem may be. > Could it have something to do with doing a debug build (with -g)? >=20 > =3D=3D=3D> libexec/atrun (all) > [=85] > -lutil /usr/obj/usr/src/tmp/usr/lib/libc.so: undefined reference to > `_malloc_options' clang: error: linker command failed with exit code 1 > (use -v to see invocation) *** [atrun] Error code 1 Perhaps this is related to using clang rather than gcc. I'll start a = clang-based buildworld to see if it reproduces here. Jason= From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 20:11:44 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 03A9810657BD; Thu, 19 Apr 2012 20:11:44 +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 C80878FC14; Thu, 19 Apr 2012 20:11:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JKBhRn005387; Thu, 19 Apr 2012 20:11:43 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JKBhku005384; Thu, 19 Apr 2012 20:11:43 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204192011.q3JKBhku005384@svn.freebsd.org> From: Jung-uk Kim Date: Thu, 19 Apr 2012 20:11:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234467 - stable/9/sys/i386/i386 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 20:11:44 -0000 Author: jkim Date: Thu Apr 19 20:11:43 2012 New Revision: 234467 URL: http://svn.freebsd.org/changeset/base/234467 Log: MFC: r234350 - When interrupt is not requested for VM86 call, make a fake exit point and push the address onto stack as we do for INTn emulation. This avoids stack underflow when we encounter RETF instruction in VM86 mode. Lack of this exit point actually caused page fault in VM86 mode with VESA module when we resume from suspend state. - Remove unnecessary CLI and STI instructions from BIOS interrupt emulation. INTn and IRET must be able to emulate the flag correctly. Modified: stable/9/sys/i386/i386/vm86.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/i386/i386/vm86.c ============================================================================== --- stable/9/sys/i386/i386/vm86.c Thu Apr 19 18:03:24 2012 (r234466) +++ stable/9/sys/i386/i386/vm86.c Thu Apr 19 20:11:43 2012 (r234467) @@ -512,22 +512,27 @@ full: void vm86_prepcall(struct vm86frame *vmf) { - uintptr_t addr[] = { 0xA00, 0x1000 }; /* code, stack */ - u_char intcall[] = { - CLI, INTn, 0x00, STI, HLT - }; struct vm86_kernel *vm86; + uint32_t *stack; + uint8_t *code; + code = (void *)0xa00; + stack = (void *)(0x1000 - 2); /* keep aligned */ if ((vmf->vmf_trapno & PAGE_MASK) <= 0xff) { /* interrupt call requested */ - intcall[2] = (u_char)(vmf->vmf_trapno & 0xff); - memcpy((void *)addr[0], (void *)intcall, sizeof(intcall)); - vmf->vmf_ip = addr[0]; + code[0] = INTn; + code[1] = vmf->vmf_trapno & 0xff; + code[2] = HLT; + vmf->vmf_ip = (uintptr_t)code; vmf->vmf_cs = 0; + } else { + code[0] = HLT; + stack--; + stack[0] = MAKE_VEC(0, (uintptr_t)code); } - vmf->vmf_sp = addr[1] - 2; /* keep aligned */ - vmf->kernel_fs = vmf->kernel_es = vmf->kernel_ds = 0; + vmf->vmf_sp = (uintptr_t)stack; vmf->vmf_ss = 0; + vmf->kernel_fs = vmf->kernel_es = vmf->kernel_ds = 0; vmf->vmf_eflags = PSL_VIF | PSL_VM | PSL_USER; vm86 = &PCPU_GET(curpcb)->pcb_ext->ext_vm86; From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 20:44:40 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9C764106564A; Thu, 19 Apr 2012 20:44:40 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8669C8FC1F; Thu, 19 Apr 2012 20:44:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JKiexc006572; Thu, 19 Apr 2012 20:44:40 GMT (envelope-from dougb@svn.freebsd.org) Received: (from dougb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JKieVp006570; Thu, 19 Apr 2012 20:44:40 GMT (envelope-from dougb@svn.freebsd.org) Message-Id: <201204192044.q3JKieVp006570@svn.freebsd.org> From: Doug Barton Date: Thu, 19 Apr 2012 20:44:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234468 - in stable/9: contrib/bind9 share/doc/bind9 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 20:44:40 -0000 Author: dougb Date: Thu Apr 19 20:44:40 2012 New Revision: 234468 URL: http://svn.freebsd.org/changeset/base/234468 Log: MFV r234164/MFC r234165: The BIND 9.8.2 tarball was re-rolled to remove 9.8.1 release notes. This change was noticed by ISC at: https://lists.isc.org/pipermail/bind-users/2012-April/087345.html and verified by me both by comparing the contents of the old and new distfiles and by verifying the PGP signature on the new distfile. Deleted: stable/9/contrib/bind9/RELEASE-NOTES-BIND-9.8.1.html stable/9/contrib/bind9/RELEASE-NOTES-BIND-9.8.1.pdf stable/9/contrib/bind9/RELEASE-NOTES-BIND-9.8.1.txt stable/9/contrib/bind9/release-notes.css Modified: stable/9/share/doc/bind9/Makefile Directory Properties: stable/9/contrib/bind9/ (props changed) stable/9/share/doc/bind9/ (props changed) Modified: stable/9/share/doc/bind9/Makefile ============================================================================== --- stable/9/share/doc/bind9/Makefile Thu Apr 19 20:11:43 2012 (r234467) +++ stable/9/share/doc/bind9/Makefile Thu Apr 19 20:44:40 2012 (r234468) @@ -8,9 +8,7 @@ SRCDIR= ${BIND_DIR}/doc NO_OBJ= FILESGROUPS= TOP ARM MISC -TOP= CHANGES COPYRIGHT FAQ HISTORY README \ - RELEASE-NOTES-BIND-9.8.1.pdf RELEASE-NOTES-BIND-9.8.1.txt \ - RELEASE-NOTES-BIND-9.8.1.html release-notes.css +TOP= CHANGES COPYRIGHT FAQ HISTORY README TOPDIR= ${DOCDIR}/bind9 ARM= Bv9ARM.ch01.html Bv9ARM.ch02.html Bv9ARM.ch03.html \ Bv9ARM.ch04.html Bv9ARM.ch05.html Bv9ARM.ch06.html \ From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 21:12:09 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 267BC106566B; Thu, 19 Apr 2012 21:12:09 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 111208FC0C; Thu, 19 Apr 2012 21:12:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JLC8QI007496; Thu, 19 Apr 2012 21:12:08 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JLC8RU007494; Thu, 19 Apr 2012 21:12:08 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201204192112.q3JLC8RU007494@svn.freebsd.org> From: Ed Schouten Date: Thu, 19 Apr 2012 21:12: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: r234469 - head/libexec/ulog-helper X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 21:12:09 -0000 Author: ed Date: Thu Apr 19 21:12:08 2012 New Revision: 234469 URL: http://svn.freebsd.org/changeset/base/234469 Log: Do a better job at determining the username of the login session. When multiple users share the same UID, the old code will simply pick an arbitrary username to attach to the utmpx entries. Make the code a bit more accurate by first checking whether getlogin() returns a username which corresponds to the uid of the calling process. If this fails, simply fall back to picking an arbitrary username. Reported by: saurik on GitHub MFC after: 2 weeks Modified: head/libexec/ulog-helper/ulog-helper.c Modified: head/libexec/ulog-helper/ulog-helper.c ============================================================================== --- head/libexec/ulog-helper/ulog-helper.c Thu Apr 19 20:44:40 2012 (r234468) +++ head/libexec/ulog-helper/ulog-helper.c Thu Apr 19 21:12:08 2012 (r234469) @@ -46,6 +46,28 @@ __FBSDID("$FreeBSD$"); * username. It does allow users to log arbitrary hostnames. */ +static const char * +get_username(void) +{ + const struct passwd *pw; + const char *login; + uid_t uid; + + /* + * Attempt to determine the username corresponding to this login + * session. First, validate the results of getlogin() against + * the password database. If getlogin() returns invalid data, + * return an arbitrary username corresponding to this uid. + */ + uid = getuid(); + if ((login = getlogin()) != NULL && (pw = getpwnam(login)) != NULL && + pw->pw_uid == uid) + return (login); + if ((pw = getpwuid(uid)) != NULL) + return (pw->pw_name); + return (NULL); +} + int main(int argc, char *argv[]) { @@ -57,7 +79,7 @@ main(int argc, char *argv[]) if ((argc == 2 || argc == 3) && strcmp(argv[1], "login") == 0) { /* Username. */ - user = user_from_uid(getuid(), 1); + user = get_username(); if (user == NULL) return (EX_OSERR); From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 21:14:41 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 3380D106567C; Thu, 19 Apr 2012 21:14:41 +0000 (UTC) Date: Thu, 19 Apr 2012 21:14:41 +0000 From: Alexander Best To: Dimitry Andric Message-ID: <20120419211441.GA7744@freebsd.org> References: <201204162123.q3GLNSr6051133@svn.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201204162123.q3GLNSr6051133@svn.freebsd.org> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234353 - in head: . contrib/llvm contrib/llvm/include/llvm contrib/llvm/include/llvm-c contrib/llvm/include/llvm-c/Transforms contrib/llvm/include/llvm/ADT contrib/llvm/include/llvm/An... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 21:14:41 -0000 On Mon Apr 16 12, Dimitry Andric wrote: > Author: dim > Date: Mon Apr 16 21:23:25 2012 > New Revision: 234353 > URL: http://svn.freebsd.org/changeset/base/234353 > > Log: > Upgrade our copy of llvm/clang to trunk r154661, in preparation of the > upcoming 3.1 release (expected in a few weeks). Preliminary release > notes can be found at: very nice. :) any reason '-fformat-extensions'-support still hasn't been pushed upstream as something like '-fbsd-extensions'? cheers. alex > > MFC after: 2 weeks > > Added: > head/contrib/llvm/include/llvm-c/TargetMachine.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm-c/TargetMachine.h > head/contrib/llvm/include/llvm-c/Transforms/Vectorize.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm-c/Transforms/Vectorize.h > head/contrib/llvm/include/llvm/ADT/Hashing.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/Hashing.h > head/contrib/llvm/include/llvm/ADT/SparseSet.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/SparseSet.h > head/contrib/llvm/include/llvm/ADT/VariadicFunction.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/VariadicFunction.h > head/contrib/llvm/include/llvm/ADT/edit_distance.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ADT/edit_distance.h > head/contrib/llvm/include/llvm/CodeGen/DFAPacketizer.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/DFAPacketizer.h > head/contrib/llvm/include/llvm/CodeGen/LiveRangeEdit.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/LiveRangeEdit.h > head/contrib/llvm/include/llvm/CodeGen/MachineInstrBundle.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/MachineInstrBundle.h > head/contrib/llvm/include/llvm/CodeGen/MachineScheduler.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/MachineScheduler.h > head/contrib/llvm/include/llvm/CodeGen/ResourcePriorityQueue.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/ResourcePriorityQueue.h > head/contrib/llvm/include/llvm/CodeGen/ScheduleDAGInstrs.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/CodeGen/ScheduleDAGInstrs.h > head/contrib/llvm/include/llvm/ExecutionEngine/IntelJITEventsWrapper.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ExecutionEngine/IntelJITEventsWrapper.h > head/contrib/llvm/include/llvm/ExecutionEngine/OProfileWrapper.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/ExecutionEngine/OProfileWrapper.h > head/contrib/llvm/include/llvm/IntrinsicsHexagon.td > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/IntrinsicsHexagon.td > head/contrib/llvm/include/llvm/MC/MCWinCOFFObjectWriter.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/MC/MCWinCOFFObjectWriter.h > head/contrib/llvm/include/llvm/Object/ELF.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Object/ELF.h > head/contrib/llvm/include/llvm/Support/DataStream.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/DataStream.h > head/contrib/llvm/include/llvm/Support/JSONParser.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/JSONParser.h > head/contrib/llvm/include/llvm/Support/LockFileManager.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/LockFileManager.h > head/contrib/llvm/include/llvm/Support/SaveAndRestore.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/SaveAndRestore.h > head/contrib/llvm/include/llvm/Support/StreamableMemoryObject.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/StreamableMemoryObject.h > head/contrib/llvm/include/llvm/Support/YAMLParser.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Support/YAMLParser.h > head/contrib/llvm/include/llvm/Transforms/Utils/CmpInstAnalysis.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Transforms/Utils/CmpInstAnalysis.h > head/contrib/llvm/include/llvm/Transforms/Utils/ModuleUtils.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Transforms/Utils/ModuleUtils.h > head/contrib/llvm/include/llvm/Transforms/Vectorize.h > - copied unchanged from r234301, vendor/llvm/dist/include/llvm/Transforms/Vectorize.h > head/contrib/llvm/lib/Analysis/CodeMetrics.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Analysis/CodeMetrics.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfAccelTable.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfAccelTable.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfAccelTable.h > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfAccelTable.h > head/contrib/llvm/lib/CodeGen/DFAPacketizer.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/DFAPacketizer.cpp > head/contrib/llvm/lib/CodeGen/JITCodeEmitter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/JITCodeEmitter.cpp > head/contrib/llvm/lib/CodeGen/MachineBlockPlacement.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineBlockPlacement.cpp > head/contrib/llvm/lib/CodeGen/MachineCodeEmitter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineCodeEmitter.cpp > head/contrib/llvm/lib/CodeGen/MachineCopyPropagation.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineCopyPropagation.cpp > head/contrib/llvm/lib/CodeGen/MachineInstrBundle.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineInstrBundle.cpp > head/contrib/llvm/lib/CodeGen/MachineScheduler.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/MachineScheduler.cpp > head/contrib/llvm/lib/CodeGen/RegAllocBase.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/RegAllocBase.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/ResourcePriorityQueue.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/SelectionDAG/ResourcePriorityQueue.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp > head/contrib/llvm/lib/CodeGen/TargetFrameLoweringImpl.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/TargetFrameLoweringImpl.cpp > head/contrib/llvm/lib/CodeGen/TargetOptionsImpl.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/CodeGen/TargetOptionsImpl.cpp > head/contrib/llvm/lib/ExecutionEngine/EventListenerCommon.h > - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/EventListenerCommon.h > head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/ > - copied from r234301, vendor/llvm/dist/lib/ExecutionEngine/IntelJITEvents/ > head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJITMemoryManager.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/MCJIT/MCJITMemoryManager.cpp > head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/ > - copied from r234301, vendor/llvm/dist/lib/ExecutionEngine/OProfileJIT/ > head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp > head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h > - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h > head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h > - copied unchanged from r234301, vendor/llvm/dist/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h > head/contrib/llvm/lib/MC/MCDisassembler/EDMain.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/MC/MCDisassembler/EDMain.cpp > head/contrib/llvm/lib/Support/DataStream.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Support/DataStream.cpp > head/contrib/llvm/lib/Support/Hashing.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Support/Hashing.cpp > head/contrib/llvm/lib/Support/IntrusiveRefCntPtr.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Support/IntrusiveRefCntPtr.cpp > head/contrib/llvm/lib/Support/JSONParser.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Support/JSONParser.cpp > head/contrib/llvm/lib/Support/LockFileManager.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Support/LockFileManager.cpp > head/contrib/llvm/lib/Support/StreamableMemoryObject.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Support/StreamableMemoryObject.cpp > head/contrib/llvm/lib/Support/YAMLParser.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Support/YAMLParser.cpp > head/contrib/llvm/lib/TableGen/TableGenAction.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/TableGen/TableGenAction.cpp > head/contrib/llvm/lib/Target/ARM/ARMMachineFunctionInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/ARM/ARMMachineFunctionInfo.cpp > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMELFObjectWriter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/ARM/MCTargetDesc/ARMELFObjectWriter.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUMachineFunction.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/CellSPU/SPUMachineFunction.cpp > head/contrib/llvm/lib/Target/Hexagon/ > - copied from r234301, vendor/llvm/dist/lib/Target/Hexagon/ > head/contrib/llvm/lib/Target/MBlaze/MBlazeMachineFunction.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/MBlaze/MBlazeMachineFunction.cpp > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeELFObjectWriter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/MBlaze/MCTargetDesc/MBlazeELFObjectWriter.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430MachineFunctionInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/MSP430/MSP430MachineFunctionInfo.cpp > head/contrib/llvm/lib/Target/Mips/AsmParser/ > - copied from r234301, vendor/llvm/dist/lib/Target/Mips/AsmParser/ > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsELFObjectWriter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MCTargetDesc/MipsELFObjectWriter.cpp > head/contrib/llvm/lib/Target/Mips/MipsAnalyzeImmediate.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsAnalyzeImmediate.cpp > head/contrib/llvm/lib/Target/Mips/MipsAnalyzeImmediate.h > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsAnalyzeImmediate.h > head/contrib/llvm/lib/Target/Mips/MipsCondMov.td > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsCondMov.td > head/contrib/llvm/lib/Target/Mips/MipsMachineFunction.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Mips/MipsMachineFunction.cpp > head/contrib/llvm/lib/Target/PTX/PTXMachineFunctionInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PTX/PTXMachineFunctionInfo.cpp > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCELFObjectWriter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/MCTargetDesc/PPCELFObjectWriter.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCMachineFunctionInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/PPCMachineFunctionInfo.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCSchedule440.td > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/PPCSchedule440.td > head/contrib/llvm/lib/Target/PowerPC/PPCScheduleA2.td > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/PowerPC/PPCScheduleA2.td > head/contrib/llvm/lib/Target/Sparc/SparcMachineFunctionInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/Sparc/SparcMachineFunctionInfo.cpp > head/contrib/llvm/lib/Target/TargetJITInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/TargetJITInfo.cpp > head/contrib/llvm/lib/Target/TargetMachineC.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/TargetMachineC.cpp > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86ELFObjectWriter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/MCTargetDesc/X86ELFObjectWriter.cpp > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86WinCOFFObjectWriter.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/MCTargetDesc/X86WinCOFFObjectWriter.cpp > head/contrib/llvm/lib/Target/X86/X86InstrSVM.td > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86InstrSVM.td > head/contrib/llvm/lib/Target/X86/X86InstrXOP.td > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86InstrXOP.td > head/contrib/llvm/lib/Target/X86/X86MachineFunctionInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86MachineFunctionInfo.cpp > head/contrib/llvm/lib/Target/X86/X86Schedule.td > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86Schedule.td > head/contrib/llvm/lib/Target/X86/X86ScheduleAtom.td > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/X86/X86ScheduleAtom.td > head/contrib/llvm/lib/Target/XCore/XCoreMachineFunctionInfo.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Target/XCore/XCoreMachineFunctionInfo.cpp > head/contrib/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/AddressSanitizer.cpp > head/contrib/llvm/lib/Transforms/Instrumentation/FunctionBlackList.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/FunctionBlackList.cpp > head/contrib/llvm/lib/Transforms/Instrumentation/FunctionBlackList.h > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/FunctionBlackList.h > head/contrib/llvm/lib/Transforms/Instrumentation/ThreadSanitizer.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Instrumentation/ThreadSanitizer.cpp > head/contrib/llvm/lib/Transforms/Scalar/GlobalMerge.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Scalar/GlobalMerge.cpp > head/contrib/llvm/lib/Transforms/Utils/CmpInstAnalysis.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Utils/CmpInstAnalysis.cpp > head/contrib/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Utils/LoopUnrollRuntime.cpp > head/contrib/llvm/lib/Transforms/Utils/ModuleUtils.cpp > - copied unchanged from r234301, vendor/llvm/dist/lib/Transforms/Utils/ModuleUtils.cpp > head/contrib/llvm/lib/Transforms/Vectorize/ > - copied from r234301, vendor/llvm/dist/lib/Transforms/Vectorize/ > head/contrib/llvm/tools/clang/include/clang/AST/BuiltinTypes.def > - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/BuiltinTypes.def > head/contrib/llvm/tools/clang/include/clang/AST/DeclLookups.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/DeclLookups.h > head/contrib/llvm/tools/clang/include/clang/AST/LambdaMangleContext.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/LambdaMangleContext.h > head/contrib/llvm/tools/clang/include/clang/AST/NSAPI.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/AST/NSAPI.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/Dominators.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Analysis/Analyses/Dominators.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/PostOrderCFGView.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Analysis/Analyses/PostOrderCFGView.h > head/contrib/llvm/tools/clang/include/clang/Analysis/CallGraph.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Analysis/CallGraph.h > head/contrib/llvm/tools/clang/include/clang/Basic/AllDiagnostics.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/AllDiagnostics.h > head/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsHexagon.def > - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/BuiltinsHexagon.def > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticSerializationKinds.td > - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/DiagnosticSerializationKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/Lambda.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/Lambda.h > head/contrib/llvm/tools/clang/include/clang/Basic/Module.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Basic/Module.h > head/contrib/llvm/tools/clang/include/clang/Edit/ > - copied from r234301, vendor/clang/dist/include/clang/Edit/ > head/contrib/llvm/tools/clang/include/clang/Frontend/ChainedIncludesSource.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/ChainedIncludesSource.h > head/contrib/llvm/tools/clang/include/clang/Frontend/DiagnosticRenderer.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/DiagnosticRenderer.h > head/contrib/llvm/tools/clang/include/clang/Frontend/LayoutOverrideSource.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/LayoutOverrideSource.h > head/contrib/llvm/tools/clang/include/clang/Frontend/MigratorOptions.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/MigratorOptions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/SerializedDiagnosticPrinter.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/SerializedDiagnosticPrinter.h > head/contrib/llvm/tools/clang/include/clang/Frontend/TextDiagnostic.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Frontend/TextDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Index/GlobalCallGraph.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Index/GlobalCallGraph.h > head/contrib/llvm/tools/clang/include/clang/Lex/ModuleMap.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Lex/ModuleMap.h > head/contrib/llvm/tools/clang/include/clang/Serialization/SerializationDiagnostic.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/Serialization/SerializationDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Checkers/CommonBugCategories.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Checkers/CommonBugCategories.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/FunctionSummary.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/FunctionSummary.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState_Fwd.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState_Fwd.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/TaintManager.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/TaintManager.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/TaintTag.h > - copied unchanged from r234301, vendor/clang/dist/include/clang/StaticAnalyzer/Core/PathSensitive/TaintTag.h > head/contrib/llvm/tools/clang/include/clang/Tooling/ > - copied from r234301, vendor/clang/dist/include/clang/Tooling/ > head/contrib/llvm/tools/clang/lib/ARCMigrate/ObjCMT.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/ARCMigrate/ObjCMT.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransGCAttrs.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/ARCMigrate/TransGCAttrs.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransGCCalls.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/ARCMigrate/TransGCCalls.cpp > head/contrib/llvm/tools/clang/lib/AST/LambdaMangleContext.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/AST/LambdaMangleContext.cpp > head/contrib/llvm/tools/clang/lib/AST/NSAPI.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/AST/NSAPI.cpp > head/contrib/llvm/tools/clang/lib/Analysis/AnalysisDeclContext.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/AnalysisDeclContext.cpp > head/contrib/llvm/tools/clang/lib/Analysis/CallGraph.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/CallGraph.cpp > head/contrib/llvm/tools/clang/lib/Analysis/Dominators.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/Dominators.cpp > head/contrib/llvm/tools/clang/lib/Analysis/PostOrderCFGView.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Analysis/PostOrderCFGView.cpp > head/contrib/llvm/tools/clang/lib/Basic/Module.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Basic/Module.cpp > head/contrib/llvm/tools/clang/lib/Driver/WindowsToolChain.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Driver/WindowsToolChain.cpp > head/contrib/llvm/tools/clang/lib/Edit/ > - copied from r234301, vendor/clang/dist/lib/Edit/ > head/contrib/llvm/tools/clang/lib/Frontend/ChainedDiagnosticConsumer.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/ChainedDiagnosticConsumer.cpp > head/contrib/llvm/tools/clang/lib/Frontend/ChainedIncludesSource.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/ChainedIncludesSource.cpp > head/contrib/llvm/tools/clang/lib/Frontend/DependencyGraph.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/DependencyGraph.cpp > head/contrib/llvm/tools/clang/lib/Frontend/DiagnosticRenderer.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/DiagnosticRenderer.cpp > head/contrib/llvm/tools/clang/lib/Frontend/LayoutOverrideSource.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/LayoutOverrideSource.cpp > head/contrib/llvm/tools/clang/lib/Frontend/SerializedDiagnosticPrinter.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/SerializedDiagnosticPrinter.cpp > head/contrib/llvm/tools/clang/lib/Frontend/TextDiagnostic.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Frontend/TextDiagnostic.cpp > head/contrib/llvm/tools/clang/lib/Headers/avx2intrin.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/avx2intrin.h > head/contrib/llvm/tools/clang/lib/Headers/bmi2intrin.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/bmi2intrin.h > head/contrib/llvm/tools/clang/lib/Headers/bmiintrin.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/bmiintrin.h > head/contrib/llvm/tools/clang/lib/Headers/cpuid.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/cpuid.h > head/contrib/llvm/tools/clang/lib/Headers/fma4intrin.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/fma4intrin.h > head/contrib/llvm/tools/clang/lib/Headers/lzcntintrin.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/lzcntintrin.h > head/contrib/llvm/tools/clang/lib/Headers/module.map > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/module.map > head/contrib/llvm/tools/clang/lib/Headers/popcntintrin.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/popcntintrin.h > head/contrib/llvm/tools/clang/lib/Headers/unwind.h > - copied unchanged from r234301, vendor/clang/dist/lib/Headers/unwind.h > head/contrib/llvm/tools/clang/lib/Index/GlobalCallGraph.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Index/GlobalCallGraph.cpp > head/contrib/llvm/tools/clang/lib/Lex/ModuleMap.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Lex/ModuleMap.cpp > head/contrib/llvm/tools/clang/lib/Lex/PPCallbacks.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Lex/PPCallbacks.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/RewriteModernObjC.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Rewrite/RewriteModernObjC.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaConsumer.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Sema/SemaConsumer.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaLambda.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Sema/SemaLambda.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaPseudoObject.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/Sema/SemaPseudoObject.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/BoolAssignmentChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/BoolAssignmentChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CStringSyntaxChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/CStringSyntaxChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckerDocumentation.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/CheckerDocumentation.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CommonBugCategories.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/CommonBugCategories.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/InterCheckerAPI.h > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/InterCheckerAPI.h > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/MallocSizeofChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCContainersASTChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/ObjCContainersASTChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCContainersChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/ObjCContainersChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/TaintTesterChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/TaintTesterChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/VirtualCallChecker.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Checkers/VirtualCallChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/FunctionSummary.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Core/FunctionSummary.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SubEngine.cpp > - copied unchanged from r234301, vendor/clang/dist/lib/StaticAnalyzer/Core/SubEngine.cpp > head/contrib/llvm/tools/clang/lib/Tooling/ > - copied from r234301, vendor/clang/dist/lib/Tooling/ > head/contrib/llvm/tools/llvm-readobj/ > - copied from r234301, vendor/llvm/dist/tools/llvm-readobj/ > head/contrib/llvm/tools/llvm-stress/ > - copied from r234301, vendor/llvm/dist/tools/llvm-stress/ > head/contrib/llvm/utils/TableGen/DFAPacketizerEmitter.cpp > - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/DFAPacketizerEmitter.cpp > head/contrib/llvm/utils/TableGen/DFAPacketizerEmitter.h > - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/DFAPacketizerEmitter.h > head/contrib/llvm/utils/TableGen/SequenceToOffsetTable.h > - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/SequenceToOffsetTable.h > head/contrib/llvm/utils/TableGen/X86ModRMFilters.cpp > - copied unchanged from r234301, vendor/llvm/dist/utils/TableGen/X86ModRMFilters.cpp > head/lib/clang/include/MipsGenMCCodeEmitter.inc (contents, props changed) > head/lib/clang/include/clang/Basic/DiagnosticSerializationKinds.inc (contents, props changed) > head/lib/clang/include/clang/Config/ > head/lib/clang/include/clang/Config/config.h (contents, props changed) > head/lib/clang/include/clang/Sema/ > head/lib/clang/include/clang/Sema/AttrParsedAttrKinds.inc (contents, props changed) > head/lib/clang/include/clang/Sema/AttrParsedAttrList.inc (contents, props changed) > head/lib/clang/include/clang/Sema/AttrTemplateInstantiate.inc (contents, props changed) > head/lib/clang/libclangedit/ > head/lib/clang/libclangedit/Makefile (contents, props changed) > head/lib/clang/libllvmmipsasmparser/ > head/lib/clang/libllvmmipsasmparser/Makefile (contents, props changed) > head/lib/clang/libllvmvectorize/ > head/lib/clang/libllvmvectorize/Makefile (contents, props changed) > Deleted: > head/contrib/llvm/include/llvm/ADT/VectorExtras.h > head/contrib/llvm/include/llvm/CodeGen/BinaryObject.h > head/contrib/llvm/include/llvm/CodeGen/ObjectCodeEmitter.h > head/contrib/llvm/include/llvm/DebugInfoProbe.h > head/contrib/llvm/include/llvm/IntrinsicsAlpha.td > head/contrib/llvm/include/llvm/Transforms/Utils/BasicInliner.h > head/contrib/llvm/lib/CodeGen/ELF.h > head/contrib/llvm/lib/CodeGen/ELFCodeEmitter.cpp > head/contrib/llvm/lib/CodeGen/ELFCodeEmitter.h > head/contrib/llvm/lib/CodeGen/ELFWriter.cpp > head/contrib/llvm/lib/CodeGen/ELFWriter.h > head/contrib/llvm/lib/CodeGen/LiveRangeEdit.h > head/contrib/llvm/lib/CodeGen/ObjectCodeEmitter.cpp > head/contrib/llvm/lib/CodeGen/RegAllocLinearScan.cpp > head/contrib/llvm/lib/CodeGen/ScheduleDAGEmit.cpp > head/contrib/llvm/lib/CodeGen/ScheduleDAGInstrs.h > head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp > head/contrib/llvm/lib/CodeGen/Splitter.cpp > head/contrib/llvm/lib/CodeGen/Splitter.h > head/contrib/llvm/lib/CodeGen/VirtRegRewriter.cpp > head/contrib/llvm/lib/CodeGen/VirtRegRewriter.h > head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/CMakeLists.txt > head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/LLVMBuild.txt > head/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/Makefile > head/contrib/llvm/lib/ExecutionEngine/JIT/Intercept.cpp > head/contrib/llvm/lib/ExecutionEngine/JIT/JITDebugRegisterer.cpp > head/contrib/llvm/lib/ExecutionEngine/JIT/JITDebugRegisterer.h > head/contrib/llvm/lib/ExecutionEngine/JIT/OProfileJITEventListener.cpp > head/contrib/llvm/lib/ExecutionEngine/MCJIT/Intercept.cpp > head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/CMakeLists.txt > head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/LLVMBuild.txt > head/contrib/llvm/lib/ExecutionEngine/OProfileJIT/Makefile > head/contrib/llvm/lib/MC/ELFObjectWriter.h > head/contrib/llvm/lib/MC/MCELFStreamer.h > head/contrib/llvm/lib/MC/MCLoggingStreamer.cpp > head/contrib/llvm/lib/Target/ARM/ARMGlobalMerge.cpp > head/contrib/llvm/lib/Target/Alpha/ > head/contrib/llvm/lib/Target/Blackfin/ > head/contrib/llvm/lib/Target/CBackend/ > head/contrib/llvm/lib/Target/Hexagon/CMakeLists.txt > head/contrib/llvm/lib/Target/Hexagon/InstPrinter/CMakeLists.txt > head/contrib/llvm/lib/Target/Hexagon/InstPrinter/LLVMBuild.txt > head/contrib/llvm/lib/Target/Hexagon/InstPrinter/Makefile > head/contrib/llvm/lib/Target/Hexagon/LLVMBuild.txt > head/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/CMakeLists.txt > head/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/LLVMBuild.txt > head/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/Makefile > head/contrib/llvm/lib/Target/Hexagon/Makefile > head/contrib/llvm/lib/Target/Hexagon/TargetInfo/CMakeLists.txt > head/contrib/llvm/lib/Target/Hexagon/TargetInfo/LLVMBuild.txt > head/contrib/llvm/lib/Target/Hexagon/TargetInfo/Makefile > head/contrib/llvm/lib/Target/Mips/AsmParser/CMakeLists.txt > head/contrib/llvm/lib/Target/Mips/AsmParser/LLVMBuild.txt > head/contrib/llvm/lib/Target/Mips/AsmParser/Makefile > head/contrib/llvm/lib/Target/Mips/MipsMCSymbolRefExpr.cpp > head/contrib/llvm/lib/Target/Mips/MipsMCSymbolRefExpr.h > head/contrib/llvm/lib/Target/SystemZ/ > head/contrib/llvm/lib/Target/TargetFrameLowering.cpp > head/contrib/llvm/lib/Transforms/Utils/BasicInliner.cpp > head/contrib/llvm/lib/Transforms/Vectorize/CMakeLists.txt > head/contrib/llvm/lib/Transforms/Vectorize/LLVMBuild.txt > head/contrib/llvm/lib/Transforms/Vectorize/Makefile > head/contrib/llvm/lib/VMCore/DebugInfoProbe.cpp > head/contrib/llvm/tools/bugpoint/CMakeLists.txt > head/contrib/llvm/tools/bugpoint/Makefile > head/contrib/llvm/tools/clang/include/clang/AST/UsuallyTinyPtrVector.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Support/SaveAndRestore.h > head/contrib/llvm/tools/clang/include/clang/Driver/HostInfo.h > head/contrib/llvm/tools/clang/include/clang/Index/CallGraph.h > head/contrib/llvm/tools/clang/include/clang/Sema/MultiInitializer.h > head/contrib/llvm/tools/clang/include/clang/Serialization/ChainedIncludesSource.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngineBuilders.h > head/contrib/llvm/tools/clang/lib/Analysis/AnalysisContext.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGException.h > head/contrib/llvm/tools/clang/lib/CodeGen/CGTemporaries.cpp > head/contrib/llvm/tools/clang/lib/Driver/HostInfo.cpp > head/contrib/llvm/tools/clang/lib/Edit/CMakeLists.txt > head/contrib/llvm/tools/clang/lib/Edit/Makefile > head/contrib/llvm/tools/clang/lib/Index/CallGraph.cpp > head/contrib/llvm/tools/clang/lib/Sema/MultiInitializer.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ChainedIncludesSource.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/AggExprVisitor.cpp > head/contrib/llvm/tools/clang/lib/Tooling/CMakeLists.txt > head/contrib/llvm/tools/clang/lib/Tooling/Makefile > head/contrib/llvm/tools/clang/utils/TableGen/CMakeLists.txt > head/contrib/llvm/tools/clang/utils/TableGen/Makefile > head/contrib/llvm/tools/llc/CMakeLists.txt > head/contrib/llvm/tools/llc/Makefile > head/contrib/llvm/tools/lli/CMakeLists.txt > head/contrib/llvm/tools/lli/Makefile > head/contrib/llvm/tools/llvm-ar/CMakeLists.txt > head/contrib/llvm/tools/llvm-ar/Makefile > head/contrib/llvm/tools/llvm-as/CMakeLists.txt > head/contrib/llvm/tools/llvm-as/Makefile > head/contrib/llvm/tools/llvm-bcanalyzer/CMakeLists.txt > head/contrib/llvm/tools/llvm-bcanalyzer/Makefile > head/contrib/llvm/tools/llvm-diff/CMakeLists.txt > head/contrib/llvm/tools/llvm-diff/Makefile > head/contrib/llvm/tools/llvm-dis/CMakeLists.txt > head/contrib/llvm/tools/llvm-dis/Makefile > head/contrib/llvm/tools/llvm-extract/CMakeLists.txt > head/contrib/llvm/tools/llvm-extract/Makefile > head/contrib/llvm/tools/llvm-ld/CMakeLists.txt > head/contrib/llvm/tools/llvm-ld/Makefile > head/contrib/llvm/tools/llvm-link/CMakeLists.txt > head/contrib/llvm/tools/llvm-link/Makefile > head/contrib/llvm/tools/llvm-mc/CMakeLists.txt > head/contrib/llvm/tools/llvm-mc/Makefile > head/contrib/llvm/tools/llvm-nm/CMakeLists.txt > head/contrib/llvm/tools/llvm-nm/Makefile > head/contrib/llvm/tools/llvm-objdump/CMakeLists.txt > head/contrib/llvm/tools/llvm-objdump/Makefile > head/contrib/llvm/tools/llvm-prof/CMakeLists.txt > head/contrib/llvm/tools/llvm-prof/Makefile > head/contrib/llvm/tools/llvm-ranlib/CMakeLists.txt > head/contrib/llvm/tools/llvm-ranlib/Makefile > head/contrib/llvm/tools/llvm-readobj/CMakeLists.txt > head/contrib/llvm/tools/llvm-readobj/LLVMBuild.txt > head/contrib/llvm/tools/llvm-readobj/Makefile > head/contrib/llvm/tools/llvm-rtdyld/CMakeLists.txt > head/contrib/llvm/tools/llvm-rtdyld/Makefile > head/contrib/llvm/tools/llvm-stress/CMakeLists.txt > head/contrib/llvm/tools/llvm-stress/LLVMBuild.txt > head/contrib/llvm/tools/llvm-stress/Makefile > head/contrib/llvm/tools/llvm-stub/CMakeLists.txt > head/contrib/llvm/tools/llvm-stub/Makefile > head/contrib/llvm/tools/macho-dump/CMakeLists.txt > head/contrib/llvm/tools/macho-dump/Makefile > head/contrib/llvm/tools/opt/CMakeLists.txt > head/contrib/llvm/tools/opt/Makefile > head/contrib/llvm/utils/TableGen/ARMDecoderEmitter.cpp > head/contrib/llvm/utils/TableGen/ARMDecoderEmitter.h > head/contrib/llvm/utils/TableGen/InstrEnumEmitter.cpp > head/contrib/llvm/utils/TableGen/InstrEnumEmitter.h > Modified: > head/ObsoleteFiles.inc > head/contrib/llvm/LICENSE.TXT > head/contrib/llvm/include/llvm-c/Analysis.h > head/contrib/llvm/include/llvm-c/BitReader.h > head/contrib/llvm/include/llvm-c/BitWriter.h > head/contrib/llvm/include/llvm-c/Core.h > head/contrib/llvm/include/llvm-c/Disassembler.h > head/contrib/llvm/include/llvm-c/EnhancedDisassembly.h > head/contrib/llvm/include/llvm-c/ExecutionEngine.h > head/contrib/llvm/include/llvm-c/Initialization.h > head/contrib/llvm/include/llvm-c/LinkTimeOptimizer.h > head/contrib/llvm/include/llvm-c/Object.h > head/contrib/llvm/include/llvm-c/Target.h > head/contrib/llvm/include/llvm-c/Transforms/IPO.h > head/contrib/llvm/include/llvm-c/Transforms/PassManagerBuilder.h > head/contrib/llvm/include/llvm-c/Transforms/Scalar.h > head/contrib/llvm/include/llvm-c/lto.h > head/contrib/llvm/include/llvm/ADT/APFloat.h > head/contrib/llvm/include/llvm/ADT/APInt.h > head/contrib/llvm/include/llvm/ADT/ArrayRef.h > head/contrib/llvm/include/llvm/ADT/BitVector.h > head/contrib/llvm/include/llvm/ADT/DAGDeltaAlgorithm.h > head/contrib/llvm/include/llvm/ADT/DenseMap.h > head/contrib/llvm/include/llvm/ADT/DenseMapInfo.h > head/contrib/llvm/include/llvm/ADT/FoldingSet.h > head/contrib/llvm/include/llvm/ADT/GraphTraits.h > head/contrib/llvm/include/llvm/ADT/ImmutableSet.h > head/contrib/llvm/include/llvm/ADT/IntervalMap.h > head/contrib/llvm/include/llvm/ADT/IntrusiveRefCntPtr.h > head/contrib/llvm/include/llvm/ADT/PointerIntPair.h > head/contrib/llvm/include/llvm/ADT/PointerUnion.h > head/contrib/llvm/include/llvm/ADT/SetVector.h > head/contrib/llvm/include/llvm/ADT/SmallBitVector.h > head/contrib/llvm/include/llvm/ADT/SmallPtrSet.h > head/contrib/llvm/include/llvm/ADT/SmallSet.h > head/contrib/llvm/include/llvm/ADT/SmallString.h > head/contrib/llvm/include/llvm/ADT/SmallVector.h > head/contrib/llvm/include/llvm/ADT/SparseBitVector.h > head/contrib/llvm/include/llvm/ADT/Statistic.h > head/contrib/llvm/include/llvm/ADT/StringExtras.h > head/contrib/llvm/include/llvm/ADT/StringMap.h > head/contrib/llvm/include/llvm/ADT/StringRef.h > head/contrib/llvm/include/llvm/ADT/TinyPtrVector.h > head/contrib/llvm/include/llvm/ADT/Trie.h > head/contrib/llvm/include/llvm/ADT/Triple.h > head/contrib/llvm/include/llvm/ADT/Twine.h > head/contrib/llvm/include/llvm/ADT/ValueMap.h > head/contrib/llvm/include/llvm/ADT/ilist.h > head/contrib/llvm/include/llvm/Analysis/AliasAnalysis.h > head/contrib/llvm/include/llvm/Analysis/AliasSetTracker.h > head/contrib/llvm/include/llvm/Analysis/BlockFrequencyImpl.h > head/contrib/llvm/include/llvm/Analysis/BlockFrequencyInfo.h > head/contrib/llvm/include/llvm/Analysis/BranchProbabilityInfo.h > head/contrib/llvm/include/llvm/Analysis/CFGPrinter.h > head/contrib/llvm/include/llvm/Analysis/CaptureTracking.h > head/contrib/llvm/include/llvm/Analysis/CodeMetrics.h > head/contrib/llvm/include/llvm/Analysis/ConstantFolding.h > head/contrib/llvm/include/llvm/Analysis/DIBuilder.h > head/contrib/llvm/include/llvm/Analysis/DOTGraphTraitsPass.h > head/contrib/llvm/include/llvm/Analysis/DebugInfo.h > head/contrib/llvm/include/llvm/Analysis/DominanceFrontier.h > head/contrib/llvm/include/llvm/Analysis/DominatorInternals.h > head/contrib/llvm/include/llvm/Analysis/Dominators.h > head/contrib/llvm/include/llvm/Analysis/IVUsers.h > head/contrib/llvm/include/llvm/Analysis/InlineCost.h > head/contrib/llvm/include/llvm/Analysis/InstructionSimplify.h > head/contrib/llvm/include/llvm/Analysis/IntervalIterator.h > head/contrib/llvm/include/llvm/Analysis/LazyValueInfo.h > head/contrib/llvm/include/llvm/Analysis/Loads.h > head/contrib/llvm/include/llvm/Analysis/LoopInfo.h > head/contrib/llvm/include/llvm/Analysis/MemoryDependenceAnalysis.h > head/contrib/llvm/include/llvm/Analysis/PHITransAddr.h > head/contrib/llvm/include/llvm/Analysis/ProfileInfo.h > head/contrib/llvm/include/llvm/Analysis/RegionInfo.h > head/contrib/llvm/include/llvm/Analysis/ScalarEvolution.h > head/contrib/llvm/include/llvm/Analysis/ScalarEvolutionExpander.h > head/contrib/llvm/include/llvm/Analysis/ScalarEvolutionExpressions.h > head/contrib/llvm/include/llvm/Analysis/ValueTracking.h > head/contrib/llvm/include/llvm/Argument.h > head/contrib/llvm/include/llvm/Assembly/AssemblyAnnotationWriter.h > head/contrib/llvm/include/llvm/Assembly/Parser.h > head/contrib/llvm/include/llvm/Assembly/Writer.h > head/contrib/llvm/include/llvm/Attributes.h > head/contrib/llvm/include/llvm/AutoUpgrade.h > head/contrib/llvm/include/llvm/BasicBlock.h > head/contrib/llvm/include/llvm/Bitcode/Archive.h > head/contrib/llvm/include/llvm/Bitcode/BitCodes.h > head/contrib/llvm/include/llvm/Bitcode/BitstreamReader.h > head/contrib/llvm/include/llvm/Bitcode/BitstreamWriter.h > head/contrib/llvm/include/llvm/Bitcode/LLVMBitCodes.h > head/contrib/llvm/include/llvm/Bitcode/ReaderWriter.h > head/contrib/llvm/include/llvm/CodeGen/Analysis.h > head/contrib/llvm/include/llvm/CodeGen/AsmPrinter.h > head/contrib/llvm/include/llvm/CodeGen/CallingConvLower.h > head/contrib/llvm/include/llvm/CodeGen/EdgeBundles.h > head/contrib/llvm/include/llvm/CodeGen/FastISel.h > head/contrib/llvm/include/llvm/CodeGen/FunctionLoweringInfo.h > head/contrib/llvm/include/llvm/CodeGen/GCStrategy.h > head/contrib/llvm/include/llvm/CodeGen/ISDOpcodes.h > head/contrib/llvm/include/llvm/CodeGen/JITCodeEmitter.h > head/contrib/llvm/include/llvm/CodeGen/LatencyPriorityQueue.h > head/contrib/llvm/include/llvm/CodeGen/LexicalScopes.h > head/contrib/llvm/include/llvm/CodeGen/LinkAllCodegenComponents.h > head/contrib/llvm/include/llvm/CodeGen/LiveInterval.h > head/contrib/llvm/include/llvm/CodeGen/LiveIntervalAnalysis.h > head/contrib/llvm/include/llvm/CodeGen/LiveVariables.h > head/contrib/llvm/include/llvm/CodeGen/MachineBasicBlock.h > head/contrib/llvm/include/llvm/CodeGen/MachineBlockFrequencyInfo.h > head/contrib/llvm/include/llvm/CodeGen/MachineBranchProbabilityInfo.h > head/contrib/llvm/include/llvm/CodeGen/MachineCodeEmitter.h > head/contrib/llvm/include/llvm/CodeGen/MachineConstantPool.h > head/contrib/llvm/include/llvm/CodeGen/MachineDominators.h > head/contrib/llvm/include/llvm/CodeGen/MachineFrameInfo.h > head/contrib/llvm/include/llvm/CodeGen/MachineFunction.h > head/contrib/llvm/include/llvm/CodeGen/MachineFunctionAnalysis.h > head/contrib/llvm/include/llvm/CodeGen/MachineInstr.h > head/contrib/llvm/include/llvm/CodeGen/MachineInstrBuilder.h > head/contrib/llvm/include/llvm/CodeGen/MachineJumpTableInfo.h > head/contrib/llvm/include/llvm/CodeGen/MachineMemOperand.h > head/contrib/llvm/include/llvm/CodeGen/MachineModuleInfo.h > head/contrib/llvm/include/llvm/CodeGen/MachineOperand.h > head/contrib/llvm/include/llvm/CodeGen/MachinePassRegistry.h > head/contrib/llvm/include/llvm/CodeGen/MachineRegisterInfo.h > head/contrib/llvm/include/llvm/CodeGen/PBQP/Graph.h > head/contrib/llvm/include/llvm/CodeGen/PBQP/HeuristicBase.h > head/contrib/llvm/include/llvm/CodeGen/PBQP/Heuristics/Briggs.h > head/contrib/llvm/include/llvm/CodeGen/Passes.h > head/contrib/llvm/include/llvm/CodeGen/RegisterScavenging.h > head/contrib/llvm/include/llvm/CodeGen/ScheduleDAG.h > head/contrib/llvm/include/llvm/CodeGen/SchedulerRegistry.h > head/contrib/llvm/include/llvm/CodeGen/SelectionDAG.h > head/contrib/llvm/include/llvm/CodeGen/SelectionDAGISel.h > head/contrib/llvm/include/llvm/CodeGen/SelectionDAGNodes.h > head/contrib/llvm/include/llvm/CodeGen/SlotIndexes.h > head/contrib/llvm/include/llvm/CodeGen/TargetLoweringObjectFileImpl.h > head/contrib/llvm/include/llvm/CodeGen/ValueTypes.h > head/contrib/llvm/include/llvm/CodeGen/ValueTypes.td > head/contrib/llvm/include/llvm/Constant.h > head/contrib/llvm/include/llvm/Constants.h > head/contrib/llvm/include/llvm/DefaultPasses.h > head/contrib/llvm/include/llvm/DerivedTypes.h > head/contrib/llvm/include/llvm/ExecutionEngine/ExecutionEngine.h > head/contrib/llvm/include/llvm/ExecutionEngine/JITEventListener.h > head/contrib/llvm/include/llvm/ExecutionEngine/JITMemoryManager.h > head/contrib/llvm/include/llvm/ExecutionEngine/RuntimeDyld.h > head/contrib/llvm/include/llvm/Function.h > head/contrib/llvm/include/llvm/GlobalValue.h > head/contrib/llvm/include/llvm/InitializePasses.h > head/contrib/llvm/include/llvm/InlineAsm.h > head/contrib/llvm/include/llvm/InstrTypes.h > head/contrib/llvm/include/llvm/Instruction.def > head/contrib/llvm/include/llvm/Instruction.h > head/contrib/llvm/include/llvm/Instructions.h > head/contrib/llvm/include/llvm/IntrinsicInst.h > head/contrib/llvm/include/llvm/Intrinsics.td > head/contrib/llvm/include/llvm/IntrinsicsX86.td > head/contrib/llvm/include/llvm/LLVMContext.h > head/contrib/llvm/include/llvm/LinkAllPasses.h > head/contrib/llvm/include/llvm/Linker.h > head/contrib/llvm/include/llvm/MC/MCAsmBackend.h > head/contrib/llvm/include/llvm/MC/MCAsmInfo.h > head/contrib/llvm/include/llvm/MC/MCAsmInfoCOFF.h > head/contrib/llvm/include/llvm/MC/MCAsmInfoDarwin.h > head/contrib/llvm/include/llvm/MC/MCAsmLayout.h > head/contrib/llvm/include/llvm/MC/MCAssembler.h > head/contrib/llvm/include/llvm/MC/MCCodeEmitter.h > head/contrib/llvm/include/llvm/MC/MCCodeGenInfo.h > head/contrib/llvm/include/llvm/MC/MCContext.h > head/contrib/llvm/include/llvm/MC/MCDisassembler.h > head/contrib/llvm/include/llvm/MC/MCDwarf.h > head/contrib/llvm/include/llvm/MC/MCELFObjectWriter.h > head/contrib/llvm/include/llvm/MC/MCExpr.h > head/contrib/llvm/include/llvm/MC/MCFixup.h > head/contrib/llvm/include/llvm/MC/MCInst.h > head/contrib/llvm/include/llvm/MC/MCInstPrinter.h > head/contrib/llvm/include/llvm/MC/MCInstrAnalysis.h > head/contrib/llvm/include/llvm/MC/MCInstrDesc.h > head/contrib/llvm/include/llvm/MC/MCInstrInfo.h > head/contrib/llvm/include/llvm/MC/MCObjectFileInfo.h > head/contrib/llvm/include/llvm/MC/MCObjectStreamer.h > head/contrib/llvm/include/llvm/MC/MCObjectWriter.h > head/contrib/llvm/include/llvm/MC/MCParser/MCAsmLexer.h > head/contrib/llvm/include/llvm/MC/MCParser/MCAsmParser.h > head/contrib/llvm/include/llvm/MC/MCRegisterInfo.h > head/contrib/llvm/include/llvm/MC/MCSection.h > head/contrib/llvm/include/llvm/MC/MCSectionCOFF.h > head/contrib/llvm/include/llvm/MC/MCSectionELF.h > head/contrib/llvm/include/llvm/MC/MCSectionMachO.h > head/contrib/llvm/include/llvm/MC/MCStreamer.h > head/contrib/llvm/include/llvm/Metadata.h > head/contrib/llvm/include/llvm/Module.h > head/contrib/llvm/include/llvm/Object/Archive.h > head/contrib/llvm/include/llvm/Object/Binary.h > head/contrib/llvm/include/llvm/Object/COFF.h > head/contrib/llvm/include/llvm/Object/MachO.h > head/contrib/llvm/include/llvm/Object/MachOObject.h > head/contrib/llvm/include/llvm/Object/ObjectFile.h > head/contrib/llvm/include/llvm/Operator.h > head/contrib/llvm/include/llvm/Pass.h > head/contrib/llvm/include/llvm/PassAnalysisSupport.h > head/contrib/llvm/include/llvm/PassManager.h > head/contrib/llvm/include/llvm/PassManagers.h > head/contrib/llvm/include/llvm/PassSupport.h > head/contrib/llvm/include/llvm/Support/BlockFrequency.h > head/contrib/llvm/include/llvm/Support/BranchProbability.h > head/contrib/llvm/include/llvm/Support/CFG.h > head/contrib/llvm/include/llvm/Support/COFF.h > head/contrib/llvm/include/llvm/Support/CallSite.h > head/contrib/llvm/include/llvm/Support/Capacity.h > head/contrib/llvm/include/llvm/Support/CodeGen.h > head/contrib/llvm/include/llvm/Support/CommandLine.h > head/contrib/llvm/include/llvm/Support/Compiler.h > head/contrib/llvm/include/llvm/Support/DOTGraphTraits.h > head/contrib/llvm/include/llvm/Support/DataTypes.h.in > head/contrib/llvm/include/llvm/Support/Debug.h > head/contrib/llvm/include/llvm/Support/Dwarf.h > head/contrib/llvm/include/llvm/Support/DynamicLibrary.h > head/contrib/llvm/include/llvm/Support/ELF.h > head/contrib/llvm/include/llvm/Support/Endian.h > head/contrib/llvm/include/llvm/Support/FileSystem.h > head/contrib/llvm/include/llvm/Support/GraphWriter.h > head/contrib/llvm/include/llvm/Support/Host.h > head/contrib/llvm/include/llvm/Support/IRReader.h > head/contrib/llvm/include/llvm/Support/InstVisitor.h > head/contrib/llvm/include/llvm/Support/MachO.h > head/contrib/llvm/include/llvm/Support/ManagedStatic.h > head/contrib/llvm/include/llvm/Support/MathExtras.h > head/contrib/llvm/include/llvm/Support/MemoryObject.h > head/contrib/llvm/include/llvm/Support/PathV1.h > head/contrib/llvm/include/llvm/Support/PatternMatch.h > head/contrib/llvm/include/llvm/Support/Process.h > head/contrib/llvm/include/llvm/Support/Program.h > head/contrib/llvm/include/llvm/Support/Recycler.h > head/contrib/llvm/include/llvm/Support/SMLoc.h > head/contrib/llvm/include/llvm/Support/SourceMgr.h > head/contrib/llvm/include/llvm/Support/TargetRegistry.h > head/contrib/llvm/include/llvm/Support/TargetSelect.h > head/contrib/llvm/include/llvm/Support/Valgrind.h > head/contrib/llvm/include/llvm/Support/ValueHandle.h > head/contrib/llvm/include/llvm/Support/system_error.h > head/contrib/llvm/include/llvm/Support/type_traits.h > head/contrib/llvm/include/llvm/TableGen/Record.h > head/contrib/llvm/include/llvm/TableGen/TableGenAction.h > head/contrib/llvm/include/llvm/TableGen/TableGenBackend.h > head/contrib/llvm/include/llvm/Target/Mangler.h > head/contrib/llvm/include/llvm/Target/Target.td > head/contrib/llvm/include/llvm/Target/TargetCallingConv.h > head/contrib/llvm/include/llvm/Target/TargetCallingConv.td > head/contrib/llvm/include/llvm/Target/TargetData.h > head/contrib/llvm/include/llvm/Target/TargetELFWriterInfo.h > head/contrib/llvm/include/llvm/Target/TargetFrameLowering.h > head/contrib/llvm/include/llvm/Target/TargetInstrInfo.h > head/contrib/llvm/include/llvm/Target/TargetJITInfo.h > head/contrib/llvm/include/llvm/Target/TargetLibraryInfo.h > head/contrib/llvm/include/llvm/Target/TargetLowering.h > head/contrib/llvm/include/llvm/Target/TargetLoweringObjectFile.h > head/contrib/llvm/include/llvm/Target/TargetMachine.h > head/contrib/llvm/include/llvm/Target/TargetOpcodes.h > head/contrib/llvm/include/llvm/Target/TargetOptions.h > head/contrib/llvm/include/llvm/Target/TargetRegisterInfo.h > head/contrib/llvm/include/llvm/Target/TargetSelectionDAG.td > head/contrib/llvm/include/llvm/Target/TargetSubtargetInfo.h > head/contrib/llvm/include/llvm/Transforms/IPO.h > head/contrib/llvm/include/llvm/Transforms/IPO/InlinerPass.h > head/contrib/llvm/include/llvm/Transforms/IPO/PassManagerBuilder.h > head/contrib/llvm/include/llvm/Transforms/Instrumentation.h > head/contrib/llvm/include/llvm/Transforms/Scalar.h > head/contrib/llvm/include/llvm/Transforms/Utils/BasicBlockUtils.h > head/contrib/llvm/include/llvm/Transforms/Utils/BuildLibCalls.h > head/contrib/llvm/include/llvm/Transforms/Utils/Cloning.h > head/contrib/llvm/include/llvm/Transforms/Utils/SSAUpdater.h > head/contrib/llvm/include/llvm/Transforms/Utils/SSAUpdaterImpl.h > head/contrib/llvm/include/llvm/Transforms/Utils/SimplifyIndVar.h > head/contrib/llvm/include/llvm/Transforms/Utils/UnrollLoop.h > head/contrib/llvm/include/llvm/Transforms/Utils/ValueMapper.h > head/contrib/llvm/include/llvm/Type.h > head/contrib/llvm/include/llvm/User.h > head/contrib/llvm/include/llvm/Value.h > head/contrib/llvm/lib/Analysis/AliasAnalysis.cpp > head/contrib/llvm/lib/Analysis/AliasAnalysisCounter.cpp > head/contrib/llvm/lib/Analysis/AliasAnalysisEvaluator.cpp > head/contrib/llvm/lib/Analysis/AliasSetTracker.cpp > head/contrib/llvm/lib/Analysis/BasicAliasAnalysis.cpp > head/contrib/llvm/lib/Analysis/BlockFrequencyInfo.cpp > head/contrib/llvm/lib/Analysis/BranchProbabilityInfo.cpp > head/contrib/llvm/lib/Analysis/CFGPrinter.cpp > head/contrib/llvm/lib/Analysis/CaptureTracking.cpp > head/contrib/llvm/lib/Analysis/ConstantFolding.cpp > head/contrib/llvm/lib/Analysis/DIBuilder.cpp > head/contrib/llvm/lib/Analysis/DebugInfo.cpp > head/contrib/llvm/lib/Analysis/DominanceFrontier.cpp > head/contrib/llvm/lib/Analysis/IPA/CallGraph.cpp > head/contrib/llvm/lib/Analysis/IPA/GlobalsModRef.cpp > head/contrib/llvm/lib/Analysis/IVUsers.cpp > head/contrib/llvm/lib/Analysis/InlineCost.cpp > head/contrib/llvm/lib/Analysis/InstructionSimplify.cpp > head/contrib/llvm/lib/Analysis/LazyValueInfo.cpp > head/contrib/llvm/lib/Analysis/Lint.cpp > head/contrib/llvm/lib/Analysis/Loads.cpp > head/contrib/llvm/lib/Analysis/LoopDependenceAnalysis.cpp > head/contrib/llvm/lib/Analysis/LoopInfo.cpp > head/contrib/llvm/lib/Analysis/LoopPass.cpp > head/contrib/llvm/lib/Analysis/MemDepPrinter.cpp > head/contrib/llvm/lib/Analysis/MemoryBuiltins.cpp > head/contrib/llvm/lib/Analysis/MemoryDependenceAnalysis.cpp > head/contrib/llvm/lib/Analysis/PHITransAddr.cpp > head/contrib/llvm/lib/Analysis/PathNumbering.cpp > head/contrib/llvm/lib/Analysis/PathProfileVerifier.cpp > head/contrib/llvm/lib/Analysis/ProfileEstimatorPass.cpp > head/contrib/llvm/lib/Analysis/ProfileInfoLoaderPass.cpp > head/contrib/llvm/lib/Analysis/ProfileVerifierPass.cpp > head/contrib/llvm/lib/Analysis/RegionInfo.cpp > head/contrib/llvm/lib/Analysis/ScalarEvolution.cpp > head/contrib/llvm/lib/Analysis/ScalarEvolutionExpander.cpp > head/contrib/llvm/lib/Analysis/ScalarEvolutionNormalization.cpp > head/contrib/llvm/lib/Analysis/SparsePropagation.cpp > head/contrib/llvm/lib/Analysis/Trace.cpp > head/contrib/llvm/lib/Analysis/ValueTracking.cpp > head/contrib/llvm/lib/Archive/ArchiveReader.cpp > head/contrib/llvm/lib/Archive/ArchiveWriter.cpp > head/contrib/llvm/lib/AsmParser/LLLexer.cpp > head/contrib/llvm/lib/AsmParser/LLLexer.h > head/contrib/llvm/lib/AsmParser/LLParser.cpp > head/contrib/llvm/lib/AsmParser/LLParser.h > head/contrib/llvm/lib/AsmParser/LLToken.h > head/contrib/llvm/lib/AsmParser/Parser.cpp > head/contrib/llvm/lib/Bitcode/Reader/BitcodeReader.cpp > head/contrib/llvm/lib/Bitcode/Reader/BitcodeReader.h > head/contrib/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp > head/contrib/llvm/lib/Bitcode/Writer/ValueEnumerator.cpp > head/contrib/llvm/lib/Bitcode/Writer/ValueEnumerator.h > head/contrib/llvm/lib/CodeGen/AggressiveAntiDepBreaker.cpp > head/contrib/llvm/lib/CodeGen/AllocationOrder.cpp > head/contrib/llvm/lib/CodeGen/AllocationOrder.h > head/contrib/llvm/lib/CodeGen/Analysis.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/ARMException.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/DIE.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/DIE.h > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCFIException.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.h > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h > head/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfException.cpp > head/contrib/llvm/lib/CodeGen/BranchFolding.cpp > head/contrib/llvm/lib/CodeGen/CallingConvLower.cpp > head/contrib/llvm/lib/CodeGen/CodeGen.cpp > head/contrib/llvm/lib/CodeGen/CodePlacementOpt.cpp > head/contrib/llvm/lib/CodeGen/CriticalAntiDepBreaker.cpp > head/contrib/llvm/lib/CodeGen/CriticalAntiDepBreaker.h > head/contrib/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp > head/contrib/llvm/lib/CodeGen/DwarfEHPrepare.cpp > head/contrib/llvm/lib/CodeGen/EdgeBundles.cpp > head/contrib/llvm/lib/CodeGen/ExecutionDepsFix.cpp > head/contrib/llvm/lib/CodeGen/ExpandISelPseudos.cpp > head/contrib/llvm/lib/CodeGen/ExpandPostRAPseudos.cpp > head/contrib/llvm/lib/CodeGen/GCMetadata.cpp > head/contrib/llvm/lib/CodeGen/GCStrategy.cpp > head/contrib/llvm/lib/CodeGen/IfConversion.cpp > head/contrib/llvm/lib/CodeGen/InlineSpiller.cpp > head/contrib/llvm/lib/CodeGen/InterferenceCache.cpp > head/contrib/llvm/lib/CodeGen/InterferenceCache.h > head/contrib/llvm/lib/CodeGen/IntrinsicLowering.cpp > head/contrib/llvm/lib/CodeGen/LLVMTargetMachine.cpp > head/contrib/llvm/lib/CodeGen/LatencyPriorityQueue.cpp > head/contrib/llvm/lib/CodeGen/LexicalScopes.cpp > head/contrib/llvm/lib/CodeGen/LiveDebugVariables.cpp > head/contrib/llvm/lib/CodeGen/LiveInterval.cpp > head/contrib/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp > head/contrib/llvm/lib/CodeGen/LiveIntervalUnion.cpp > head/contrib/llvm/lib/CodeGen/LiveIntervalUnion.h > head/contrib/llvm/lib/CodeGen/LiveRangeCalc.cpp > head/contrib/llvm/lib/CodeGen/LiveRangeEdit.cpp > head/contrib/llvm/lib/CodeGen/LiveVariables.cpp > head/contrib/llvm/lib/CodeGen/LocalStackSlotAllocation.cpp > head/contrib/llvm/lib/CodeGen/MachineBasicBlock.cpp > head/contrib/llvm/lib/CodeGen/MachineBlockFrequencyInfo.cpp > head/contrib/llvm/lib/CodeGen/MachineBranchProbabilityInfo.cpp > head/contrib/llvm/lib/CodeGen/MachineCSE.cpp > head/contrib/llvm/lib/CodeGen/MachineFunction.cpp > head/contrib/llvm/lib/CodeGen/MachineFunctionAnalysis.cpp > head/contrib/llvm/lib/CodeGen/MachineInstr.cpp > head/contrib/llvm/lib/CodeGen/MachineLICM.cpp > head/contrib/llvm/lib/CodeGen/MachineModuleInfo.cpp > head/contrib/llvm/lib/CodeGen/MachinePassRegistry.cpp > head/contrib/llvm/lib/CodeGen/MachineRegisterInfo.cpp > head/contrib/llvm/lib/CodeGen/MachineSSAUpdater.cpp > head/contrib/llvm/lib/CodeGen/MachineSink.cpp > head/contrib/llvm/lib/CodeGen/MachineVerifier.cpp > head/contrib/llvm/lib/CodeGen/OptimizePHIs.cpp > head/contrib/llvm/lib/CodeGen/PHIElimination.cpp > head/contrib/llvm/lib/CodeGen/Passes.cpp > head/contrib/llvm/lib/CodeGen/PeepholeOptimizer.cpp > head/contrib/llvm/lib/CodeGen/PostRASchedulerList.cpp > head/contrib/llvm/lib/CodeGen/ProcessImplicitDefs.cpp > head/contrib/llvm/lib/CodeGen/PrologEpilogInserter.cpp > head/contrib/llvm/lib/CodeGen/PrologEpilogInserter.h > head/contrib/llvm/lib/CodeGen/PseudoSourceValue.cpp > head/contrib/llvm/lib/CodeGen/RegAllocBase.h > head/contrib/llvm/lib/CodeGen/RegAllocBasic.cpp > head/contrib/llvm/lib/CodeGen/RegAllocFast.cpp > head/contrib/llvm/lib/CodeGen/RegAllocGreedy.cpp > head/contrib/llvm/lib/CodeGen/RegAllocPBQP.cpp > head/contrib/llvm/lib/CodeGen/RegisterClassInfo.cpp > head/contrib/llvm/lib/CodeGen/RegisterClassInfo.h > head/contrib/llvm/lib/CodeGen/RegisterCoalescer.cpp > head/contrib/llvm/lib/CodeGen/RegisterCoalescer.h > head/contrib/llvm/lib/CodeGen/RegisterScavenging.cpp > head/contrib/llvm/lib/CodeGen/RenderMachineFunction.cpp > head/contrib/llvm/lib/CodeGen/ScheduleDAG.cpp > head/contrib/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp > head/contrib/llvm/lib/CodeGen/ScheduleDAGPrinter.cpp > head/contrib/llvm/lib/CodeGen/ScoreboardHazardRecognizer.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypesGeneric.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.h > head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h > head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp > head/contrib/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp > head/contrib/llvm/lib/CodeGen/ShadowStackGC.cpp > head/contrib/llvm/lib/CodeGen/ShrinkWrapping.cpp > head/contrib/llvm/lib/CodeGen/SjLjEHPrepare.cpp > head/contrib/llvm/lib/CodeGen/SlotIndexes.cpp > head/contrib/llvm/lib/CodeGen/Spiller.cpp > head/contrib/llvm/lib/CodeGen/Spiller.h > head/contrib/llvm/lib/CodeGen/SplitKit.cpp > head/contrib/llvm/lib/CodeGen/SplitKit.h > head/contrib/llvm/lib/CodeGen/StackProtector.cpp > head/contrib/llvm/lib/CodeGen/StackSlotColoring.cpp > head/contrib/llvm/lib/CodeGen/StrongPHIElimination.cpp > head/contrib/llvm/lib/CodeGen/TailDuplication.cpp > head/contrib/llvm/lib/CodeGen/TargetInstrInfoImpl.cpp > head/contrib/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp > head/contrib/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp > head/contrib/llvm/lib/CodeGen/VirtRegMap.cpp > head/contrib/llvm/lib/CodeGen/VirtRegMap.h > head/contrib/llvm/lib/DebugInfo/DWARFContext.cpp > head/contrib/llvm/lib/DebugInfo/DWARFContext.h > head/contrib/llvm/lib/DebugInfo/DWARFDebugAbbrev.cpp > head/contrib/llvm/lib/DebugInfo/DWARFDebugAbbrev.h > head/contrib/llvm/lib/DebugInfo/DWARFDebugArangeSet.cpp > head/contrib/llvm/lib/DebugInfo/DWARFDebugAranges.cpp > head/contrib/llvm/lib/DebugInfo/DWARFDebugInfoEntry.cpp > head/contrib/llvm/lib/DebugInfo/DWARFDebugInfoEntry.h > head/contrib/llvm/lib/DebugInfo/DWARFDebugLine.cpp > head/contrib/llvm/lib/DebugInfo/DWARFFormValue.cpp > head/contrib/llvm/lib/ExecutionEngine/ExecutionEngine.cpp > head/contrib/llvm/lib/ExecutionEngine/ExecutionEngineBindings.cpp > head/contrib/llvm/lib/ExecutionEngine/Interpreter/Execution.cpp > head/contrib/llvm/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp > head/contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.h > head/contrib/llvm/lib/ExecutionEngine/JIT/JIT.cpp > head/contrib/llvm/lib/ExecutionEngine/JIT/JIT.h > head/contrib/llvm/lib/ExecutionEngine/JIT/JITDwarfEmitter.cpp > head/contrib/llvm/lib/ExecutionEngine/JIT/JITEmitter.cpp > head/contrib/llvm/lib/ExecutionEngine/JIT/JITMemoryManager.cpp > head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp > head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJIT.h > head/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJITMemoryManager.h > head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp > head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h > head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp > head/contrib/llvm/lib/ExecutionEngine/TargetSelect.cpp > head/contrib/llvm/lib/Linker/LinkArchives.cpp > head/contrib/llvm/lib/Linker/LinkModules.cpp > head/contrib/llvm/lib/Linker/Linker.cpp > head/contrib/llvm/lib/MC/ELFObjectWriter.cpp > head/contrib/llvm/lib/MC/MCAsmBackend.cpp > head/contrib/llvm/lib/MC/MCAsmInfo.cpp > head/contrib/llvm/lib/MC/MCAsmInfoCOFF.cpp > head/contrib/llvm/lib/MC/MCAsmInfoDarwin.cpp > head/contrib/llvm/lib/MC/MCAsmStreamer.cpp > head/contrib/llvm/lib/MC/MCAssembler.cpp > head/contrib/llvm/lib/MC/MCCodeGenInfo.cpp > head/contrib/llvm/lib/MC/MCContext.cpp > head/contrib/llvm/lib/MC/MCDisassembler/Disassembler.cpp > head/contrib/llvm/lib/MC/MCDisassembler/Disassembler.h > head/contrib/llvm/lib/MC/MCDisassembler/EDDisassembler.cpp > head/contrib/llvm/lib/MC/MCDisassembler/EDDisassembler.h > head/contrib/llvm/lib/MC/MCDisassembler/EDOperand.cpp > head/contrib/llvm/lib/MC/MCDwarf.cpp > head/contrib/llvm/lib/MC/MCELF.cpp > head/contrib/llvm/lib/MC/MCELFObjectTargetWriter.cpp > head/contrib/llvm/lib/MC/MCELFStreamer.cpp > head/contrib/llvm/lib/MC/MCExpr.cpp > head/contrib/llvm/lib/MC/MCInst.cpp > head/contrib/llvm/lib/MC/MCInstPrinter.cpp > head/contrib/llvm/lib/MC/MCMachOStreamer.cpp > head/contrib/llvm/lib/MC/MCModule.cpp > head/contrib/llvm/lib/MC/MCNullStreamer.cpp > head/contrib/llvm/lib/MC/MCObjectFileInfo.cpp > head/contrib/llvm/lib/MC/MCObjectStreamer.cpp > head/contrib/llvm/lib/MC/MCObjectWriter.cpp > head/contrib/llvm/lib/MC/MCParser/AsmParser.cpp > head/contrib/llvm/lib/MC/MCParser/COFFAsmParser.cpp > head/contrib/llvm/lib/MC/MCParser/ELFAsmParser.cpp > head/contrib/llvm/lib/MC/MCParser/MCAsmLexer.cpp > head/contrib/llvm/lib/MC/MCParser/MCAsmParser.cpp > head/contrib/llvm/lib/MC/MCPureStreamer.cpp > head/contrib/llvm/lib/MC/MCStreamer.cpp > head/contrib/llvm/lib/MC/MCSymbol.cpp > head/contrib/llvm/lib/MC/MachObjectWriter.cpp > head/contrib/llvm/lib/MC/SubtargetFeature.cpp > head/contrib/llvm/lib/MC/WinCOFFObjectWriter.cpp > head/contrib/llvm/lib/MC/WinCOFFStreamer.cpp > head/contrib/llvm/lib/Object/Archive.cpp > head/contrib/llvm/lib/Object/COFFObjectFile.cpp > head/contrib/llvm/lib/Object/ELFObjectFile.cpp > head/contrib/llvm/lib/Object/MachOObject.cpp > head/contrib/llvm/lib/Object/MachOObjectFile.cpp > head/contrib/llvm/lib/Object/Object.cpp > head/contrib/llvm/lib/Object/ObjectFile.cpp > head/contrib/llvm/lib/Support/APFloat.cpp > head/contrib/llvm/lib/Support/APInt.cpp > head/contrib/llvm/lib/Support/Allocator.cpp > head/contrib/llvm/lib/Support/Atomic.cpp > head/contrib/llvm/lib/Support/BlockFrequency.cpp > head/contrib/llvm/lib/Support/BranchProbability.cpp > head/contrib/llvm/lib/Support/CommandLine.cpp > head/contrib/llvm/lib/Support/ConstantRange.cpp > head/contrib/llvm/lib/Support/CrashRecoveryContext.cpp > head/contrib/llvm/lib/Support/DAGDeltaAlgorithm.cpp > head/contrib/llvm/lib/Support/DataExtractor.cpp > head/contrib/llvm/lib/Support/Dwarf.cpp > head/contrib/llvm/lib/Support/FileUtilities.cpp > head/contrib/llvm/lib/Support/FoldingSet.cpp > head/contrib/llvm/lib/Support/GraphWriter.cpp > head/contrib/llvm/lib/Support/Host.cpp > head/contrib/llvm/lib/Support/ManagedStatic.cpp > head/contrib/llvm/lib/Support/MemoryBuffer.cpp > head/contrib/llvm/lib/Support/Mutex.cpp > head/contrib/llvm/lib/Support/Path.cpp > head/contrib/llvm/lib/Support/PathV2.cpp > head/contrib/llvm/lib/Support/Program.cpp > head/contrib/llvm/lib/Support/RWMutex.cpp > head/contrib/llvm/lib/Support/SmallPtrSet.cpp > head/contrib/llvm/lib/Support/SourceMgr.cpp > head/contrib/llvm/lib/Support/Statistic.cpp > head/contrib/llvm/lib/Support/StringExtras.cpp > head/contrib/llvm/lib/Support/StringMap.cpp > head/contrib/llvm/lib/Support/StringRef.cpp > head/contrib/llvm/lib/Support/TargetRegistry.cpp > head/contrib/llvm/lib/Support/ThreadLocal.cpp > head/contrib/llvm/lib/Support/Threading.cpp > head/contrib/llvm/lib/Support/Timer.cpp > head/contrib/llvm/lib/Support/Triple.cpp > head/contrib/llvm/lib/Support/Unix/Host.inc > head/contrib/llvm/lib/Support/Unix/Path.inc > head/contrib/llvm/lib/Support/Unix/PathV2.inc > head/contrib/llvm/lib/Support/Unix/Process.inc > head/contrib/llvm/lib/Support/Unix/Program.inc > head/contrib/llvm/lib/Support/Unix/Signals.inc > head/contrib/llvm/lib/Support/Valgrind.cpp > head/contrib/llvm/lib/Support/Windows/Host.inc > head/contrib/llvm/lib/Support/Windows/Path.inc > head/contrib/llvm/lib/Support/Windows/PathV2.inc > head/contrib/llvm/lib/Support/Windows/Process.inc > head/contrib/llvm/lib/Support/Windows/Program.inc > head/contrib/llvm/lib/Support/Windows/Signals.inc > head/contrib/llvm/lib/Support/Windows/Windows.h > head/contrib/llvm/lib/Support/raw_ostream.cpp > head/contrib/llvm/lib/TableGen/Error.cpp > head/contrib/llvm/lib/TableGen/Record.cpp > head/contrib/llvm/lib/TableGen/TGLexer.cpp > head/contrib/llvm/lib/TableGen/TGLexer.h > head/contrib/llvm/lib/TableGen/TGParser.cpp > head/contrib/llvm/lib/TableGen/TGParser.h > head/contrib/llvm/lib/TableGen/TableGenBackend.cpp > head/contrib/llvm/lib/Target/ARM/ARM.h > head/contrib/llvm/lib/Target/ARM/ARM.td > head/contrib/llvm/lib/Target/ARM/ARMAsmPrinter.cpp > head/contrib/llvm/lib/Target/ARM/ARMAsmPrinter.h > head/contrib/llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp > head/contrib/llvm/lib/Target/ARM/ARMBaseInstrInfo.h > head/contrib/llvm/lib/Target/ARM/ARMBaseRegisterInfo.cpp > head/contrib/llvm/lib/Target/ARM/ARMBaseRegisterInfo.h > head/contrib/llvm/lib/Target/ARM/ARMBuildAttrs.h > head/contrib/llvm/lib/Target/ARM/ARMCallingConv.h > head/contrib/llvm/lib/Target/ARM/ARMCallingConv.td > head/contrib/llvm/lib/Target/ARM/ARMCodeEmitter.cpp > head/contrib/llvm/lib/Target/ARM/ARMConstantIslandPass.cpp > head/contrib/llvm/lib/Target/ARM/ARMConstantPoolValue.cpp > head/contrib/llvm/lib/Target/ARM/ARMConstantPoolValue.h > head/contrib/llvm/lib/Target/ARM/ARMELFWriterInfo.cpp > head/contrib/llvm/lib/Target/ARM/ARMELFWriterInfo.h > head/contrib/llvm/lib/Target/ARM/ARMExpandPseudoInsts.cpp > head/contrib/llvm/lib/Target/ARM/ARMFastISel.cpp > head/contrib/llvm/lib/Target/ARM/ARMFrameLowering.cpp > head/contrib/llvm/lib/Target/ARM/ARMFrameLowering.h > head/contrib/llvm/lib/Target/ARM/ARMHazardRecognizer.cpp > head/contrib/llvm/lib/Target/ARM/ARMHazardRecognizer.h > head/contrib/llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp > head/contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp > head/contrib/llvm/lib/Target/ARM/ARMISelLowering.h > head/contrib/llvm/lib/Target/ARM/ARMInstrFormats.td > head/contrib/llvm/lib/Target/ARM/ARMInstrInfo.cpp > head/contrib/llvm/lib/Target/ARM/ARMInstrInfo.h > head/contrib/llvm/lib/Target/ARM/ARMInstrInfo.td > head/contrib/llvm/lib/Target/ARM/ARMInstrNEON.td > head/contrib/llvm/lib/Target/ARM/ARMInstrThumb.td > head/contrib/llvm/lib/Target/ARM/ARMInstrThumb2.td > head/contrib/llvm/lib/Target/ARM/ARMInstrVFP.td > head/contrib/llvm/lib/Target/ARM/ARMJITInfo.cpp > head/contrib/llvm/lib/Target/ARM/ARMJITInfo.h > head/contrib/llvm/lib/Target/ARM/ARMLoadStoreOptimizer.cpp > head/contrib/llvm/lib/Target/ARM/ARMMCInstLower.cpp > head/contrib/llvm/lib/Target/ARM/ARMMachineFunctionInfo.h > head/contrib/llvm/lib/Target/ARM/ARMPerfectShuffle.h > head/contrib/llvm/lib/Target/ARM/ARMRegisterInfo.cpp > head/contrib/llvm/lib/Target/ARM/ARMRegisterInfo.h > head/contrib/llvm/lib/Target/ARM/ARMRegisterInfo.td > head/contrib/llvm/lib/Target/ARM/ARMRelocations.h > head/contrib/llvm/lib/Target/ARM/ARMSchedule.td > head/contrib/llvm/lib/Target/ARM/ARMScheduleA8.td > head/contrib/llvm/lib/Target/ARM/ARMScheduleA9.td > head/contrib/llvm/lib/Target/ARM/ARMScheduleV6.td > head/contrib/llvm/lib/Target/ARM/ARMSelectionDAGInfo.cpp > head/contrib/llvm/lib/Target/ARM/ARMSubtarget.cpp > head/contrib/llvm/lib/Target/ARM/ARMSubtarget.h > head/contrib/llvm/lib/Target/ARM/ARMTargetMachine.cpp > head/contrib/llvm/lib/Target/ARM/ARMTargetMachine.h > head/contrib/llvm/lib/Target/ARM/ARMTargetObjectFile.cpp > head/contrib/llvm/lib/Target/ARM/ARMTargetObjectFile.h > head/contrib/llvm/lib/Target/ARM/AsmParser/ARMAsmLexer.cpp > head/contrib/llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp > head/contrib/llvm/lib/Target/ARM/Disassembler/ARMDisassembler.cpp > head/contrib/llvm/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp > head/contrib/llvm/lib/Target/ARM/InstPrinter/ARMInstPrinter.h > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAddressingModes.h > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackend.cpp > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMBaseInfo.h > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMFixupKinds.h > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.h > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCCodeEmitter.cpp > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCExpr.cpp > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCExpr.h > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.h > head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMachObjectWriter.cpp > head/contrib/llvm/lib/Target/ARM/MLxExpansionPass.cpp > head/contrib/llvm/lib/Target/ARM/Thumb1FrameLowering.cpp > head/contrib/llvm/lib/Target/ARM/Thumb1InstrInfo.cpp > head/contrib/llvm/lib/Target/ARM/Thumb1InstrInfo.h > head/contrib/llvm/lib/Target/ARM/Thumb1RegisterInfo.cpp > head/contrib/llvm/lib/Target/ARM/Thumb1RegisterInfo.h > head/contrib/llvm/lib/Target/ARM/Thumb2ITBlockPass.cpp > head/contrib/llvm/lib/Target/ARM/Thumb2InstrInfo.cpp > head/contrib/llvm/lib/Target/ARM/Thumb2InstrInfo.h > head/contrib/llvm/lib/Target/ARM/Thumb2RegisterInfo.cpp > head/contrib/llvm/lib/Target/ARM/Thumb2RegisterInfo.h > head/contrib/llvm/lib/Target/ARM/Thumb2SizeReduction.cpp > head/contrib/llvm/lib/Target/CellSPU/CellSDKIntrinsics.td > head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCAsmInfo.cpp > head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCAsmInfo.h > head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCTargetDesc.cpp > head/contrib/llvm/lib/Target/CellSPU/MCTargetDesc/SPUMCTargetDesc.h > head/contrib/llvm/lib/Target/CellSPU/SPU.h > head/contrib/llvm/lib/Target/CellSPU/SPU.td > head/contrib/llvm/lib/Target/CellSPU/SPU128InstrInfo.td > head/contrib/llvm/lib/Target/CellSPU/SPU64InstrInfo.td > head/contrib/llvm/lib/Target/CellSPU/SPUAsmPrinter.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUCallingConv.td > head/contrib/llvm/lib/Target/CellSPU/SPUFrameLowering.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUFrameLowering.h > head/contrib/llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUISelLowering.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUISelLowering.h > head/contrib/llvm/lib/Target/CellSPU/SPUInstrBuilder.h > head/contrib/llvm/lib/Target/CellSPU/SPUInstrFormats.td > head/contrib/llvm/lib/Target/CellSPU/SPUInstrInfo.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUInstrInfo.h > head/contrib/llvm/lib/Target/CellSPU/SPUMachineFunction.h > head/contrib/llvm/lib/Target/CellSPU/SPUMathInstr.td > head/contrib/llvm/lib/Target/CellSPU/SPUNodes.td > head/contrib/llvm/lib/Target/CellSPU/SPUNopFiller.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUOperands.td > head/contrib/llvm/lib/Target/CellSPU/SPURegisterInfo.cpp > head/contrib/llvm/lib/Target/CellSPU/SPURegisterInfo.h > head/contrib/llvm/lib/Target/CellSPU/SPURegisterInfo.td > head/contrib/llvm/lib/Target/CellSPU/SPUSchedule.td > head/contrib/llvm/lib/Target/CellSPU/SPUSubtarget.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUTargetMachine.cpp > head/contrib/llvm/lib/Target/CellSPU/SPUTargetMachine.h > head/contrib/llvm/lib/Target/CppBackend/CPPBackend.cpp > head/contrib/llvm/lib/Target/CppBackend/CPPTargetMachine.h > head/contrib/llvm/lib/Target/MBlaze/AsmParser/MBlazeAsmLexer.cpp > head/contrib/llvm/lib/Target/MBlaze/AsmParser/MBlazeAsmParser.cpp > head/contrib/llvm/lib/Target/MBlaze/Disassembler/MBlazeDisassembler.cpp > head/contrib/llvm/lib/Target/MBlaze/Disassembler/MBlazeDisassembler.h > head/contrib/llvm/lib/Target/MBlaze/InstPrinter/MBlazeInstPrinter.h > head/contrib/llvm/lib/Target/MBlaze/MBlaze.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeAsmPrinter.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeDelaySlotFiller.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeELFWriterInfo.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeELFWriterInfo.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeFrameLowering.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeFrameLowering.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeISelLowering.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeISelLowering.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrFPU.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrFSL.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrFormats.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrInfo.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrInfo.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeInstrInfo.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeIntrinsicInfo.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeIntrinsicInfo.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeIntrinsics.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeMCInstLower.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeMCInstLower.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeMachineFunction.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeRegisterInfo.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeRegisterInfo.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeRegisterInfo.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeRelocations.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeSchedule.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeSchedule3.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeSchedule5.td > head/contrib/llvm/lib/Target/MBlaze/MBlazeSubtarget.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeSubtarget.h > head/contrib/llvm/lib/Target/MBlaze/MBlazeTargetMachine.cpp > head/contrib/llvm/lib/Target/MBlaze/MBlazeTargetMachine.h > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeAsmBackend.cpp > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeBaseInfo.h > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCAsmInfo.cpp > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCAsmInfo.h > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCCodeEmitter.cpp > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCTargetDesc.cpp > head/contrib/llvm/lib/Target/MBlaze/MCTargetDesc/MBlazeMCTargetDesc.h > head/contrib/llvm/lib/Target/MSP430/InstPrinter/MSP430InstPrinter.cpp > head/contrib/llvm/lib/Target/MSP430/InstPrinter/MSP430InstPrinter.h > head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCAsmInfo.cpp > head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCAsmInfo.h > head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCTargetDesc.cpp > head/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCTargetDesc.h > head/contrib/llvm/lib/Target/MSP430/MSP430.td > head/contrib/llvm/lib/Target/MSP430/MSP430AsmPrinter.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430BranchSelector.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430FrameLowering.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430ISelLowering.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430ISelLowering.h > head/contrib/llvm/lib/Target/MSP430/MSP430InstrFormats.td > head/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.h > head/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.td > head/contrib/llvm/lib/Target/MSP430/MSP430MCInstLower.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430MCInstLower.h > head/contrib/llvm/lib/Target/MSP430/MSP430MachineFunctionInfo.h > head/contrib/llvm/lib/Target/MSP430/MSP430RegisterInfo.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430RegisterInfo.h > head/contrib/llvm/lib/Target/MSP430/MSP430RegisterInfo.td > head/contrib/llvm/lib/Target/MSP430/MSP430Subtarget.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430Subtarget.h > head/contrib/llvm/lib/Target/MSP430/MSP430TargetMachine.cpp > head/contrib/llvm/lib/Target/MSP430/MSP430TargetMachine.h > head/contrib/llvm/lib/Target/Mangler.cpp > head/contrib/llvm/lib/Target/Mips/InstPrinter/MipsInstPrinter.cpp > head/contrib/llvm/lib/Target/Mips/InstPrinter/MipsInstPrinter.h > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsBaseInfo.h > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsFixupKinds.h > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCAsmInfo.cpp > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCAsmInfo.h > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCCodeEmitter.cpp > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCTargetDesc.cpp > head/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCTargetDesc.h > head/contrib/llvm/lib/Target/Mips/Mips.h > head/contrib/llvm/lib/Target/Mips/Mips.td > head/contrib/llvm/lib/Target/Mips/Mips64InstrInfo.td > head/contrib/llvm/lib/Target/Mips/MipsAsmPrinter.cpp > head/contrib/llvm/lib/Target/Mips/MipsAsmPrinter.h > head/contrib/llvm/lib/Target/Mips/MipsCallingConv.td > head/contrib/llvm/lib/Target/Mips/MipsCodeEmitter.cpp > head/contrib/llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp > head/contrib/llvm/lib/Target/Mips/MipsEmitGPRestore.cpp > head/contrib/llvm/lib/Target/Mips/MipsExpandPseudo.cpp > head/contrib/llvm/lib/Target/Mips/MipsFrameLowering.cpp > head/contrib/llvm/lib/Target/Mips/MipsFrameLowering.h > head/contrib/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp > head/contrib/llvm/lib/Target/Mips/MipsISelLowering.cpp > head/contrib/llvm/lib/Target/Mips/MipsISelLowering.h > head/contrib/llvm/lib/Target/Mips/MipsInstrFPU.td > head/contrib/llvm/lib/Target/Mips/MipsInstrFormats.td > head/contrib/llvm/lib/Target/Mips/MipsInstrInfo.cpp > head/contrib/llvm/lib/Target/Mips/MipsInstrInfo.h > head/contrib/llvm/lib/Target/Mips/MipsInstrInfo.td > head/contrib/llvm/lib/Target/Mips/MipsJITInfo.cpp > head/contrib/llvm/lib/Target/Mips/MipsJITInfo.h > head/contrib/llvm/lib/Target/Mips/MipsMCInstLower.cpp > head/contrib/llvm/lib/Target/Mips/MipsMCInstLower.h > head/contrib/llvm/lib/Target/Mips/MipsMachineFunction.h > head/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.cpp > head/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.h > head/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.td > head/contrib/llvm/lib/Target/Mips/MipsRelocations.h > head/contrib/llvm/lib/Target/Mips/MipsSchedule.td > head/contrib/llvm/lib/Target/Mips/MipsSubtarget.cpp > head/contrib/llvm/lib/Target/Mips/MipsSubtarget.h > head/contrib/llvm/lib/Target/Mips/MipsTargetMachine.cpp > head/contrib/llvm/lib/Target/Mips/MipsTargetMachine.h > head/contrib/llvm/lib/Target/Mips/MipsTargetObjectFile.cpp > head/contrib/llvm/lib/Target/PTX/InstPrinter/PTXInstPrinter.cpp > head/contrib/llvm/lib/Target/PTX/InstPrinter/PTXInstPrinter.h > head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXBaseInfo.h > head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCAsmInfo.cpp > head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCAsmInfo.h > head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCTargetDesc.cpp > head/contrib/llvm/lib/Target/PTX/MCTargetDesc/PTXMCTargetDesc.h > head/contrib/llvm/lib/Target/PTX/PTX.h > head/contrib/llvm/lib/Target/PTX/PTX.td > head/contrib/llvm/lib/Target/PTX/PTXAsmPrinter.cpp > head/contrib/llvm/lib/Target/PTX/PTXAsmPrinter.h > head/contrib/llvm/lib/Target/PTX/PTXFPRoundingModePass.cpp > head/contrib/llvm/lib/Target/PTX/PTXFrameLowering.cpp > head/contrib/llvm/lib/Target/PTX/PTXFrameLowering.h > head/contrib/llvm/lib/Target/PTX/PTXISelLowering.cpp > head/contrib/llvm/lib/Target/PTX/PTXISelLowering.h > head/contrib/llvm/lib/Target/PTX/PTXInstrFormats.td > head/contrib/llvm/lib/Target/PTX/PTXInstrInfo.cpp > head/contrib/llvm/lib/Target/PTX/PTXInstrInfo.h > head/contrib/llvm/lib/Target/PTX/PTXInstrInfo.td > head/contrib/llvm/lib/Target/PTX/PTXInstrLoadStore.td > head/contrib/llvm/lib/Target/PTX/PTXIntrinsicInstrInfo.td > head/contrib/llvm/lib/Target/PTX/PTXMCAsmStreamer.cpp > head/contrib/llvm/lib/Target/PTX/PTXMFInfoExtract.cpp > head/contrib/llvm/lib/Target/PTX/PTXMachineFunctionInfo.h > head/contrib/llvm/lib/Target/PTX/PTXParamManager.cpp > head/contrib/llvm/lib/Target/PTX/PTXParamManager.h > head/contrib/llvm/lib/Target/PTX/PTXRegAlloc.cpp > head/contrib/llvm/lib/Target/PTX/PTXRegisterInfo.cpp > head/contrib/llvm/lib/Target/PTX/PTXRegisterInfo.h > head/contrib/llvm/lib/Target/PTX/PTXRegisterInfo.td > head/contrib/llvm/lib/Target/PTX/PTXSelectionDAGInfo.cpp > head/contrib/llvm/lib/Target/PTX/PTXSubtarget.cpp > head/contrib/llvm/lib/Target/PTX/PTXSubtarget.h > head/contrib/llvm/lib/Target/PTX/PTXTargetMachine.cpp > head/contrib/llvm/lib/Target/PTX/PTXTargetMachine.h > head/contrib/llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp > head/contrib/llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.h > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCAsmBackend.cpp > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCBaseInfo.h > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCAsmInfo.cpp > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCAsmInfo.h > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCCodeEmitter.cpp > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCTargetDesc.cpp > head/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCTargetDesc.h > head/contrib/llvm/lib/Target/PowerPC/PPC.h > head/contrib/llvm/lib/Target/PowerPC/PPC.td > head/contrib/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCBranchSelector.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCCallingConv.td > head/contrib/llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.h > head/contrib/llvm/lib/Target/PowerPC/PPCHazardRecognizers.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCHazardRecognizers.h > head/contrib/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCISelLowering.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCISelLowering.h > head/contrib/llvm/lib/Target/PowerPC/PPCInstr64Bit.td > head/contrib/llvm/lib/Target/PowerPC/PPCInstrAltivec.td > head/contrib/llvm/lib/Target/PowerPC/PPCInstrFormats.td > head/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.h > head/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.td > head/contrib/llvm/lib/Target/PowerPC/PPCJITInfo.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCJITInfo.h > head/contrib/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCMachineFunctionInfo.h > head/contrib/llvm/lib/Target/PowerPC/PPCPerfectShuffle.h > head/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.h > head/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.td > head/contrib/llvm/lib/Target/PowerPC/PPCRelocations.h > head/contrib/llvm/lib/Target/PowerPC/PPCSchedule.td > head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG3.td > head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG4.td > head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG4Plus.td > head/contrib/llvm/lib/Target/PowerPC/PPCScheduleG5.td > head/contrib/llvm/lib/Target/PowerPC/PPCSubtarget.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCSubtarget.h > head/contrib/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp > head/contrib/llvm/lib/Target/PowerPC/PPCTargetMachine.h > head/contrib/llvm/lib/Target/Sparc/DelaySlotFiller.cpp > head/contrib/llvm/lib/Target/Sparc/FPMover.cpp > head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCAsmInfo.cpp > head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCAsmInfo.h > head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCTargetDesc.cpp > head/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCTargetDesc.h > head/contrib/llvm/lib/Target/Sparc/Sparc.h > head/contrib/llvm/lib/Target/Sparc/Sparc.td > head/contrib/llvm/lib/Target/Sparc/SparcAsmPrinter.cpp > head/contrib/llvm/lib/Target/Sparc/SparcCallingConv.td > head/contrib/llvm/lib/Target/Sparc/SparcFrameLowering.cpp > head/contrib/llvm/lib/Target/Sparc/SparcFrameLowering.h > head/contrib/llvm/lib/Target/Sparc/SparcISelDAGToDAG.cpp > head/contrib/llvm/lib/Target/Sparc/SparcISelLowering.cpp > head/contrib/llvm/lib/Target/Sparc/SparcISelLowering.h > head/contrib/llvm/lib/Target/Sparc/SparcInstrFormats.td > head/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.cpp > head/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.h > head/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.td > head/contrib/llvm/lib/Target/Sparc/SparcMachineFunctionInfo.h > head/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp > head/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.h > head/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.td > head/contrib/llvm/lib/Target/Sparc/SparcSubtarget.cpp > head/contrib/llvm/lib/Target/Sparc/SparcSubtarget.h > head/contrib/llvm/lib/Target/Sparc/SparcTargetMachine.cpp > head/contrib/llvm/lib/Target/Sparc/SparcTargetMachine.h > head/contrib/llvm/lib/Target/TargetData.cpp > head/contrib/llvm/lib/Target/TargetInstrInfo.cpp > head/contrib/llvm/lib/Target/TargetLibraryInfo.cpp > head/contrib/llvm/lib/Target/TargetLoweringObjectFile.cpp > head/contrib/llvm/lib/Target/TargetMachine.cpp > head/contrib/llvm/lib/Target/TargetRegisterInfo.cpp > head/contrib/llvm/lib/Target/X86/AsmParser/X86AsmLexer.cpp > head/contrib/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp > head/contrib/llvm/lib/Target/X86/Disassembler/X86Disassembler.cpp > head/contrib/llvm/lib/Target/X86/Disassembler/X86Disassembler.h > head/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoder.c > head/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoder.h > head/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoderCommon.h > head/contrib/llvm/lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp > head/contrib/llvm/lib/Target/X86/InstPrinter/X86ATTInstPrinter.h > head/contrib/llvm/lib/Target/X86/InstPrinter/X86InstComments.cpp > head/contrib/llvm/lib/Target/X86/InstPrinter/X86InstComments.h > head/contrib/llvm/lib/Target/X86/InstPrinter/X86IntelInstPrinter.cpp > head/contrib/llvm/lib/Target/X86/InstPrinter/X86IntelInstPrinter.h > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86AsmBackend.cpp > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86FixupKinds.h > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.h > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp > head/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h > head/contrib/llvm/lib/Target/X86/Utils/X86ShuffleDecode.cpp > head/contrib/llvm/lib/Target/X86/Utils/X86ShuffleDecode.h > head/contrib/llvm/lib/Target/X86/X86.h > head/contrib/llvm/lib/Target/X86/X86.td > head/contrib/llvm/lib/Target/X86/X86AsmPrinter.cpp > head/contrib/llvm/lib/Target/X86/X86AsmPrinter.h > head/contrib/llvm/lib/Target/X86/X86COFFMachineModuleInfo.cpp > head/contrib/llvm/lib/Target/X86/X86COFFMachineModuleInfo.h > head/contrib/llvm/lib/Target/X86/X86CallingConv.td > head/contrib/llvm/lib/Target/X86/X86CodeEmitter.cpp > head/contrib/llvm/lib/Target/X86/X86ELFWriterInfo.cpp > head/contrib/llvm/lib/Target/X86/X86FastISel.cpp > head/contrib/llvm/lib/Target/X86/X86FloatingPoint.cpp > head/contrib/llvm/lib/Target/X86/X86FrameLowering.cpp > head/contrib/llvm/lib/Target/X86/X86FrameLowering.h > head/contrib/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp > head/contrib/llvm/lib/Target/X86/X86ISelLowering.cpp > head/contrib/llvm/lib/Target/X86/X86ISelLowering.h > head/contrib/llvm/lib/Target/X86/X86Instr3DNow.td > head/contrib/llvm/lib/Target/X86/X86InstrArithmetic.td > head/contrib/llvm/lib/Target/X86/X86InstrBuilder.h > head/contrib/llvm/lib/Target/X86/X86InstrCMovSetCC.td > head/contrib/llvm/lib/Target/X86/X86InstrCompiler.td > head/contrib/llvm/lib/Target/X86/X86InstrControl.td > head/contrib/llvm/lib/Target/X86/X86InstrExtension.td > head/contrib/llvm/lib/Target/X86/X86InstrFMA.td > head/contrib/llvm/lib/Target/X86/X86InstrFPStack.td > head/contrib/llvm/lib/Target/X86/X86InstrFormats.td > head/contrib/llvm/lib/Target/X86/X86InstrFragmentsSIMD.td > head/contrib/llvm/lib/Target/X86/X86InstrInfo.cpp > head/contrib/llvm/lib/Target/X86/X86InstrInfo.h > head/contrib/llvm/lib/Target/X86/X86InstrInfo.td > head/contrib/llvm/lib/Target/X86/X86InstrMMX.td > head/contrib/llvm/lib/Target/X86/X86InstrSSE.td > head/contrib/llvm/lib/Target/X86/X86InstrShiftRotate.td > head/contrib/llvm/lib/Target/X86/X86InstrSystem.td > head/contrib/llvm/lib/Target/X86/X86InstrVMX.td > head/contrib/llvm/lib/Target/X86/X86JITInfo.cpp > head/contrib/llvm/lib/Target/X86/X86JITInfo.h > head/contrib/llvm/lib/Target/X86/X86MCInstLower.cpp > head/contrib/llvm/lib/Target/X86/X86MCInstLower.h > head/contrib/llvm/lib/Target/X86/X86MachineFunctionInfo.h > head/contrib/llvm/lib/Target/X86/X86RegisterInfo.cpp > head/contrib/llvm/lib/Target/X86/X86RegisterInfo.h > head/contrib/llvm/lib/Target/X86/X86RegisterInfo.td > head/contrib/llvm/lib/Target/X86/X86Relocations.h > head/contrib/llvm/lib/Target/X86/X86SelectionDAGInfo.cpp > head/contrib/llvm/lib/Target/X86/X86Subtarget.cpp > head/contrib/llvm/lib/Target/X86/X86Subtarget.h > head/contrib/llvm/lib/Target/X86/X86TargetMachine.cpp > head/contrib/llvm/lib/Target/X86/X86TargetMachine.h > head/contrib/llvm/lib/Target/X86/X86TargetObjectFile.cpp > head/contrib/llvm/lib/Target/X86/X86TargetObjectFile.h > head/contrib/llvm/lib/Target/X86/X86VZeroUpper.cpp > head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCAsmInfo.cpp > head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCAsmInfo.h > head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCTargetDesc.cpp > head/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCTargetDesc.h > head/contrib/llvm/lib/Target/XCore/XCore.h > head/contrib/llvm/lib/Target/XCore/XCore.td > head/contrib/llvm/lib/Target/XCore/XCoreFrameLowering.cpp > head/contrib/llvm/lib/Target/XCore/XCoreFrameLowering.h > head/contrib/llvm/lib/Target/XCore/XCoreISelDAGToDAG.cpp > head/contrib/llvm/lib/Target/XCore/XCoreISelLowering.cpp > head/contrib/llvm/lib/Target/XCore/XCoreISelLowering.h > head/contrib/llvm/lib/Target/XCore/XCoreInstrFormats.td > head/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.cpp > head/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.h > head/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.td > head/contrib/llvm/lib/Target/XCore/XCoreMachineFunctionInfo.h > head/contrib/llvm/lib/Target/XCore/XCoreRegisterInfo.cpp > head/contrib/llvm/lib/Target/XCore/XCoreRegisterInfo.h > head/contrib/llvm/lib/Target/XCore/XCoreRegisterInfo.td > head/contrib/llvm/lib/Target/XCore/XCoreSubtarget.cpp > head/contrib/llvm/lib/Target/XCore/XCoreSubtarget.h > head/contrib/llvm/lib/Target/XCore/XCoreTargetMachine.cpp > head/contrib/llvm/lib/Target/XCore/XCoreTargetMachine.h > head/contrib/llvm/lib/Target/XCore/XCoreTargetObjectFile.h > head/contrib/llvm/lib/Transforms/IPO/ConstantMerge.cpp > head/contrib/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp > head/contrib/llvm/lib/Transforms/IPO/FunctionAttrs.cpp > head/contrib/llvm/lib/Transforms/IPO/GlobalOpt.cpp > head/contrib/llvm/lib/Transforms/IPO/InlineAlways.cpp > head/contrib/llvm/lib/Transforms/IPO/InlineSimple.cpp > head/contrib/llvm/lib/Transforms/IPO/Inliner.cpp > head/contrib/llvm/lib/Transforms/IPO/Internalize.cpp > head/contrib/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp > head/contrib/llvm/lib/Transforms/IPO/PruneEH.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombine.h > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineAddSub.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineCasts.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineMulDivRem.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp > head/contrib/llvm/lib/Transforms/InstCombine/InstCombineWorklist.h > head/contrib/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp > head/contrib/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp > head/contrib/llvm/lib/Transforms/Instrumentation/Instrumentation.cpp > head/contrib/llvm/lib/Transforms/Instrumentation/OptimalEdgeProfiling.cpp > head/contrib/llvm/lib/Transforms/Instrumentation/PathProfiling.cpp > head/contrib/llvm/lib/Transforms/Scalar/CodeGenPrepare.cpp > head/contrib/llvm/lib/Transforms/Scalar/ConstantProp.cpp > head/contrib/llvm/lib/Transforms/Scalar/CorrelatedValuePropagation.cpp > head/contrib/llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp > head/contrib/llvm/lib/Transforms/Scalar/EarlyCSE.cpp > head/contrib/llvm/lib/Transforms/Scalar/GVN.cpp > head/contrib/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp > head/contrib/llvm/lib/Transforms/Scalar/JumpThreading.cpp > head/contrib/llvm/lib/Transforms/Scalar/LICM.cpp > head/contrib/llvm/lib/Transforms/Scalar/LoopInstSimplify.cpp > head/contrib/llvm/lib/Transforms/Scalar/LoopRotation.cpp > head/contrib/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp > head/contrib/llvm/lib/Transforms/Scalar/LoopUnrollPass.cpp > head/contrib/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp > head/contrib/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp > head/contrib/llvm/lib/Transforms/Scalar/ObjCARC.cpp > head/contrib/llvm/lib/Transforms/Scalar/Reassociate.cpp > head/contrib/llvm/lib/Transforms/Scalar/SCCP.cpp > head/contrib/llvm/lib/Transforms/Scalar/Scalar.cpp > head/contrib/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp > head/contrib/llvm/lib/Transforms/Scalar/SimplifyLibCalls.cpp > head/contrib/llvm/lib/Transforms/Scalar/Sink.cpp > head/contrib/llvm/lib/Transforms/Utils/AddrModeMatcher.cpp > head/contrib/llvm/lib/Transforms/Utils/BasicBlockUtils.cpp > head/contrib/llvm/lib/Transforms/Utils/BreakCriticalEdges.cpp > head/contrib/llvm/lib/Transforms/Utils/BuildLibCalls.cpp > head/contrib/llvm/lib/Transforms/Utils/CloneFunction.cpp > head/contrib/llvm/lib/Transforms/Utils/CodeExtractor.cpp > head/contrib/llvm/lib/Transforms/Utils/DemoteRegToStack.cpp > head/contrib/llvm/lib/Transforms/Utils/InlineFunction.cpp > head/contrib/llvm/lib/Transforms/Utils/Local.cpp > head/contrib/llvm/lib/Transforms/Utils/LoopSimplify.cpp > head/contrib/llvm/lib/Transforms/Utils/LoopUnroll.cpp > head/contrib/llvm/lib/Transforms/Utils/LowerExpectIntrinsic.cpp > head/contrib/llvm/lib/Transforms/Utils/LowerInvoke.cpp > head/contrib/llvm/lib/Transforms/Utils/LowerSwitch.cpp > head/contrib/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp > head/contrib/llvm/lib/Transforms/Utils/SSAUpdater.cpp > head/contrib/llvm/lib/Transforms/Utils/SimplifyCFG.cpp > head/contrib/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp > head/contrib/llvm/lib/Transforms/Utils/SimplifyInstructions.cpp > head/contrib/llvm/lib/Transforms/Utils/UnifyFunctionExitNodes.cpp > head/contrib/llvm/lib/VMCore/AsmWriter.cpp > head/contrib/llvm/lib/VMCore/Attributes.cpp > head/contrib/llvm/lib/VMCore/AutoUpgrade.cpp > head/contrib/llvm/lib/VMCore/BasicBlock.cpp > head/contrib/llvm/lib/VMCore/ConstantFold.cpp > head/contrib/llvm/lib/VMCore/Constants.cpp > head/contrib/llvm/lib/VMCore/ConstantsContext.h > head/contrib/llvm/lib/VMCore/Core.cpp > head/contrib/llvm/lib/VMCore/DebugLoc.cpp > head/contrib/llvm/lib/VMCore/Dominators.cpp > head/contrib/llvm/lib/VMCore/Function.cpp > head/contrib/llvm/lib/VMCore/GCOV.cpp > head/contrib/llvm/lib/VMCore/IRBuilder.cpp > head/contrib/llvm/lib/VMCore/Instruction.cpp > head/contrib/llvm/lib/VMCore/Instructions.cpp > head/contrib/llvm/lib/VMCore/LLVMContext.cpp > head/contrib/llvm/lib/VMCore/LLVMContextImpl.cpp > head/contrib/llvm/lib/VMCore/LLVMContextImpl.h > head/contrib/llvm/lib/VMCore/Metadata.cpp > head/contrib/llvm/lib/VMCore/Module.cpp > head/contrib/llvm/lib/VMCore/Pass.cpp > head/contrib/llvm/lib/VMCore/PassManager.cpp > head/contrib/llvm/lib/VMCore/Type.cpp > head/contrib/llvm/lib/VMCore/Use.cpp > head/contrib/llvm/lib/VMCore/User.cpp > head/contrib/llvm/lib/VMCore/Value.cpp > head/contrib/llvm/lib/VMCore/ValueTypes.cpp > head/contrib/llvm/lib/VMCore/Verifier.cpp > head/contrib/llvm/tools/bugpoint/BugDriver.cpp > head/contrib/llvm/tools/bugpoint/CrashDebugger.cpp > head/contrib/llvm/tools/bugpoint/ExecutionDriver.cpp > head/contrib/llvm/tools/bugpoint/ExtractFunction.cpp > head/contrib/llvm/tools/bugpoint/Miscompilation.cpp > head/contrib/llvm/tools/bugpoint/OptimizerDriver.cpp > head/contrib/llvm/tools/bugpoint/ToolRunner.cpp > head/contrib/llvm/tools/bugpoint/ToolRunner.h > head/contrib/llvm/tools/bugpoint/bugpoint.cpp > head/contrib/llvm/tools/clang/LICENSE.TXT > head/contrib/llvm/tools/clang/include/clang-c/Index.h > head/contrib/llvm/tools/clang/include/clang/ARCMigrate/ARCMT.h > head/contrib/llvm/tools/clang/include/clang/ARCMigrate/ARCMTActions.h > head/contrib/llvm/tools/clang/include/clang/ARCMigrate/FileRemapper.h > head/contrib/llvm/tools/clang/include/clang/AST/APValue.h > head/contrib/llvm/tools/clang/include/clang/AST/ASTConsumer.h > head/contrib/llvm/tools/clang/include/clang/AST/ASTContext.h > head/contrib/llvm/tools/clang/include/clang/AST/ASTDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/AST/ASTImporter.h > head/contrib/llvm/tools/clang/include/clang/AST/ASTMutationListener.h > head/contrib/llvm/tools/clang/include/clang/AST/Attr.h > head/contrib/llvm/tools/clang/include/clang/AST/CanonicalType.h > head/contrib/llvm/tools/clang/include/clang/AST/Decl.h > head/contrib/llvm/tools/clang/include/clang/AST/DeclBase.h > head/contrib/llvm/tools/clang/include/clang/AST/DeclCXX.h > head/contrib/llvm/tools/clang/include/clang/AST/DeclFriend.h > head/contrib/llvm/tools/clang/include/clang/AST/DeclObjC.h > head/contrib/llvm/tools/clang/include/clang/AST/DeclTemplate.h > head/contrib/llvm/tools/clang/include/clang/AST/DeclVisitor.h > head/contrib/llvm/tools/clang/include/clang/AST/DeclarationName.h > head/contrib/llvm/tools/clang/include/clang/AST/DependentDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/AST/Expr.h > head/contrib/llvm/tools/clang/include/clang/AST/ExprCXX.h > head/contrib/llvm/tools/clang/include/clang/AST/ExprObjC.h > head/contrib/llvm/tools/clang/include/clang/AST/ExternalASTSource.h > head/contrib/llvm/tools/clang/include/clang/AST/Mangle.h > head/contrib/llvm/tools/clang/include/clang/AST/NestedNameSpecifier.h > head/contrib/llvm/tools/clang/include/clang/AST/OperationKinds.h > head/contrib/llvm/tools/clang/include/clang/AST/PrettyPrinter.h > head/contrib/llvm/tools/clang/include/clang/AST/RecordLayout.h > head/contrib/llvm/tools/clang/include/clang/AST/RecursiveASTVisitor.h > head/contrib/llvm/tools/clang/include/clang/AST/Redeclarable.h > head/contrib/llvm/tools/clang/include/clang/AST/Stmt.h > head/contrib/llvm/tools/clang/include/clang/AST/StmtCXX.h > head/contrib/llvm/tools/clang/include/clang/AST/StmtIterator.h > head/contrib/llvm/tools/clang/include/clang/AST/StmtObjC.h > head/contrib/llvm/tools/clang/include/clang/AST/StmtVisitor.h > head/contrib/llvm/tools/clang/include/clang/AST/TemplateBase.h > head/contrib/llvm/tools/clang/include/clang/AST/Type.h > head/contrib/llvm/tools/clang/include/clang/AST/TypeLoc.h > head/contrib/llvm/tools/clang/include/clang/AST/TypeVisitor.h > head/contrib/llvm/tools/clang/include/clang/AST/VTableBuilder.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/FormatString.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/LiveVariables.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/ReachableCode.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/ThreadSafety.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/UninitializedValues.h > head/contrib/llvm/tools/clang/include/clang/Analysis/AnalysisContext.h > head/contrib/llvm/tools/clang/include/clang/Analysis/AnalysisDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Analysis/CFG.h > head/contrib/llvm/tools/clang/include/clang/Analysis/DomainSpecific/CocoaConventions.h > head/contrib/llvm/tools/clang/include/clang/Analysis/ProgramPoint.h > head/contrib/llvm/tools/clang/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h > head/contrib/llvm/tools/clang/include/clang/Basic/Attr.td > head/contrib/llvm/tools/clang/include/clang/Basic/Builtins.def > head/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsX86.def > head/contrib/llvm/tools/clang/include/clang/Basic/ConvertUTF.h > head/contrib/llvm/tools/clang/include/clang/Basic/DeclNodes.td > head/contrib/llvm/tools/clang/include/clang/Basic/Diagnostic.h > head/contrib/llvm/tools/clang/include/clang/Basic/Diagnostic.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticASTKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticAnalysisKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticCommonKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticDriverKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticFrontendKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticGroups.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticIDs.h > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticLexKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticParseKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticSemaKinds.td > head/contrib/llvm/tools/clang/include/clang/Basic/ExpressionTraits.h > head/contrib/llvm/tools/clang/include/clang/Basic/FileManager.h > head/contrib/llvm/tools/clang/include/clang/Basic/FileSystemStatCache.h > head/contrib/llvm/tools/clang/include/clang/Basic/IdentifierTable.h > head/contrib/llvm/tools/clang/include/clang/Basic/LLVM.h > head/contrib/llvm/tools/clang/include/clang/Basic/LangOptions.def > head/contrib/llvm/tools/clang/include/clang/Basic/LangOptions.h > head/contrib/llvm/tools/clang/include/clang/Basic/Linkage.h > head/contrib/llvm/tools/clang/include/clang/Basic/OnDiskHashTable.h > head/contrib/llvm/tools/clang/include/clang/Basic/PartialDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Basic/SourceLocation.h > head/contrib/llvm/tools/clang/include/clang/Basic/SourceManager.h > head/contrib/llvm/tools/clang/include/clang/Basic/Specifiers.h > head/contrib/llvm/tools/clang/include/clang/Basic/StmtNodes.td > head/contrib/llvm/tools/clang/include/clang/Basic/TargetBuiltins.h > head/contrib/llvm/tools/clang/include/clang/Basic/TargetInfo.h > head/contrib/llvm/tools/clang/include/clang/Basic/TokenKinds.def > head/contrib/llvm/tools/clang/include/clang/Basic/TypeTraits.h > head/contrib/llvm/tools/clang/include/clang/Basic/Version.h > head/contrib/llvm/tools/clang/include/clang/CodeGen/CodeGenAction.h > head/contrib/llvm/tools/clang/include/clang/CodeGen/ModuleBuilder.h > head/contrib/llvm/tools/clang/include/clang/Driver/Action.h > head/contrib/llvm/tools/clang/include/clang/Driver/ArgList.h > head/contrib/llvm/tools/clang/include/clang/Driver/CC1AsOptions.td > head/contrib/llvm/tools/clang/include/clang/Driver/CC1Options.td > head/contrib/llvm/tools/clang/include/clang/Driver/Compilation.h > head/contrib/llvm/tools/clang/include/clang/Driver/Driver.h > head/contrib/llvm/tools/clang/include/clang/Driver/DriverDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Driver/Job.h > head/contrib/llvm/tools/clang/include/clang/Driver/ObjCRuntime.h > head/contrib/llvm/tools/clang/include/clang/Driver/OptTable.h > head/contrib/llvm/tools/clang/include/clang/Driver/Options.td > head/contrib/llvm/tools/clang/include/clang/Driver/Tool.h > head/contrib/llvm/tools/clang/include/clang/Driver/ToolChain.h > head/contrib/llvm/tools/clang/include/clang/Driver/Types.def > head/contrib/llvm/tools/clang/include/clang/Frontend/ASTUnit.h > head/contrib/llvm/tools/clang/include/clang/Frontend/Analyses.def > head/contrib/llvm/tools/clang/include/clang/Frontend/AnalyzerOptions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/ChainedDiagnosticConsumer.h > head/contrib/llvm/tools/clang/include/clang/Frontend/CodeGenOptions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/CompilerInstance.h > head/contrib/llvm/tools/clang/include/clang/Frontend/CompilerInvocation.h > head/contrib/llvm/tools/clang/include/clang/Frontend/DependencyOutputOptions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/DiagnosticOptions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendAction.h > head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendActions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Frontend/FrontendOptions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/LangStandard.h > head/contrib/llvm/tools/clang/include/clang/Frontend/LangStandards.def > head/contrib/llvm/tools/clang/include/clang/Frontend/MultiplexConsumer.h > head/contrib/llvm/tools/clang/include/clang/Frontend/PreprocessorOptions.h > head/contrib/llvm/tools/clang/include/clang/Frontend/TextDiagnosticPrinter.h > head/contrib/llvm/tools/clang/include/clang/Frontend/Utils.h > head/contrib/llvm/tools/clang/include/clang/Frontend/VerifyDiagnosticConsumer.h > head/contrib/llvm/tools/clang/include/clang/Index/ASTLocation.h > head/contrib/llvm/tools/clang/include/clang/Lex/DirectoryLookup.h > head/contrib/llvm/tools/clang/include/clang/Lex/ExternalPreprocessorSource.h > head/contrib/llvm/tools/clang/include/clang/Lex/HeaderSearch.h > head/contrib/llvm/tools/clang/include/clang/Lex/LexDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Lex/Lexer.h > head/contrib/llvm/tools/clang/include/clang/Lex/LiteralSupport.h > head/contrib/llvm/tools/clang/include/clang/Lex/MacroInfo.h > head/contrib/llvm/tools/clang/include/clang/Lex/ModuleLoader.h > head/contrib/llvm/tools/clang/include/clang/Lex/PPCallbacks.h > head/contrib/llvm/tools/clang/include/clang/Lex/PreprocessingRecord.h > head/contrib/llvm/tools/clang/include/clang/Lex/Preprocessor.h > head/contrib/llvm/tools/clang/include/clang/Lex/PreprocessorLexer.h > head/contrib/llvm/tools/clang/include/clang/Lex/Token.h > head/contrib/llvm/tools/clang/include/clang/Parse/ParseAST.h > head/contrib/llvm/tools/clang/include/clang/Parse/ParseDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Parse/Parser.h > head/contrib/llvm/tools/clang/include/clang/Rewrite/ASTConsumers.h > head/contrib/llvm/tools/clang/include/clang/Rewrite/FixItRewriter.h > head/contrib/llvm/tools/clang/include/clang/Rewrite/FrontendActions.h > head/contrib/llvm/tools/clang/include/clang/Rewrite/TokenRewriter.h > head/contrib/llvm/tools/clang/include/clang/Sema/AttributeList.h > head/contrib/llvm/tools/clang/include/clang/Sema/CodeCompleteConsumer.h > head/contrib/llvm/tools/clang/include/clang/Sema/DeclSpec.h > head/contrib/llvm/tools/clang/include/clang/Sema/DelayedDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Sema/ExternalSemaSource.h > head/contrib/llvm/tools/clang/include/clang/Sema/IdentifierResolver.h > head/contrib/llvm/tools/clang/include/clang/Sema/Initialization.h > head/contrib/llvm/tools/clang/include/clang/Sema/LocInfoType.h > head/contrib/llvm/tools/clang/include/clang/Sema/Lookup.h > head/contrib/llvm/tools/clang/include/clang/Sema/Overload.h > head/contrib/llvm/tools/clang/include/clang/Sema/ParsedTemplate.h > head/contrib/llvm/tools/clang/include/clang/Sema/PrettyDeclStackTrace.h > head/contrib/llvm/tools/clang/include/clang/Sema/Scope.h > head/contrib/llvm/tools/clang/include/clang/Sema/ScopeInfo.h > head/contrib/llvm/tools/clang/include/clang/Sema/Sema.h > head/contrib/llvm/tools/clang/include/clang/Sema/SemaConsumer.h > head/contrib/llvm/tools/clang/include/clang/Sema/SemaDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/Sema/SemaFixItUtils.h > head/contrib/llvm/tools/clang/include/clang/Sema/Template.h > head/contrib/llvm/tools/clang/include/clang/Sema/TemplateDeduction.h > head/contrib/llvm/tools/clang/include/clang/Sema/TypoCorrection.h > head/contrib/llvm/tools/clang/include/clang/Serialization/ASTBitCodes.h > head/contrib/llvm/tools/clang/include/clang/Serialization/ASTDeserializationListener.h > head/contrib/llvm/tools/clang/include/clang/Serialization/ASTReader.h > head/contrib/llvm/tools/clang/include/clang/Serialization/ASTWriter.h > head/contrib/llvm/tools/clang/include/clang/Serialization/ContinuousRangeMap.h > head/contrib/llvm/tools/clang/include/clang/Serialization/Module.h > head/contrib/llvm/tools/clang/include/clang/Serialization/ModuleManager.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporterVisitor.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugType.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/PathDiagnostic.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/Checker.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/CheckerRegistry.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathDiagnosticConsumers.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/AnalysisManager.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/BasicValueFactory.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CheckerContext.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ConstraintManager.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CoreEngine.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Environment.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExplodedGraph.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/MemRegion.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ObjCMessage.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramStateTrait.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SValBuilder.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SVals.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Store.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SubEngine.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SymbolManager.h > head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/WorkList.h > head/contrib/llvm/tools/clang/lib/ARCMigrate/ARCMT.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/ARCMTActions.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/FileRemapper.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/Internals.h > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransARCAssign.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransAutoreleasePool.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransBlockObjCVariable.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransEmptyStatementsAndDealloc.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransProperties.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransRetainReleaseDealloc.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransUnbridgedCasts.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransUnusedInitDelegate.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransZeroOutPropsInDealloc.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/TransformActions.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/Transforms.cpp > head/contrib/llvm/tools/clang/lib/ARCMigrate/Transforms.h > head/contrib/llvm/tools/clang/lib/AST/APValue.cpp > head/contrib/llvm/tools/clang/lib/AST/ASTConsumer.cpp > head/contrib/llvm/tools/clang/lib/AST/ASTContext.cpp > head/contrib/llvm/tools/clang/lib/AST/ASTDiagnostic.cpp > head/contrib/llvm/tools/clang/lib/AST/ASTImporter.cpp > head/contrib/llvm/tools/clang/lib/AST/AttrImpl.cpp > head/contrib/llvm/tools/clang/lib/AST/CXXInheritance.cpp > head/contrib/llvm/tools/clang/lib/AST/Decl.cpp > head/contrib/llvm/tools/clang/lib/AST/DeclBase.cpp > head/contrib/llvm/tools/clang/lib/AST/DeclCXX.cpp > head/contrib/llvm/tools/clang/lib/AST/DeclFriend.cpp > head/contrib/llvm/tools/clang/lib/AST/DeclObjC.cpp > head/contrib/llvm/tools/clang/lib/AST/DeclPrinter.cpp > head/contrib/llvm/tools/clang/lib/AST/DeclTemplate.cpp > head/contrib/llvm/tools/clang/lib/AST/DeclarationName.cpp > head/contrib/llvm/tools/clang/lib/AST/DumpXML.cpp > head/contrib/llvm/tools/clang/lib/AST/Expr.cpp > head/contrib/llvm/tools/clang/lib/AST/ExprCXX.cpp > head/contrib/llvm/tools/clang/lib/AST/ExprClassification.cpp > head/contrib/llvm/tools/clang/lib/AST/ExprConstant.cpp > head/contrib/llvm/tools/clang/lib/AST/ItaniumMangle.cpp > head/contrib/llvm/tools/clang/lib/AST/Mangle.cpp > head/contrib/llvm/tools/clang/lib/AST/MicrosoftMangle.cpp > head/contrib/llvm/tools/clang/lib/AST/NestedNameSpecifier.cpp > head/contrib/llvm/tools/clang/lib/AST/ParentMap.cpp > head/contrib/llvm/tools/clang/lib/AST/RecordLayout.cpp > head/contrib/llvm/tools/clang/lib/AST/RecordLayoutBuilder.cpp > head/contrib/llvm/tools/clang/lib/AST/Stmt.cpp > head/contrib/llvm/tools/clang/lib/AST/StmtDumper.cpp > head/contrib/llvm/tools/clang/lib/AST/StmtPrinter.cpp > head/contrib/llvm/tools/clang/lib/AST/StmtProfile.cpp > head/contrib/llvm/tools/clang/lib/AST/TemplateBase.cpp > head/contrib/llvm/tools/clang/lib/AST/TemplateName.cpp > head/contrib/llvm/tools/clang/lib/AST/Type.cpp > head/contrib/llvm/tools/clang/lib/AST/TypeLoc.cpp > head/contrib/llvm/tools/clang/lib/AST/TypePrinter.cpp > head/contrib/llvm/tools/clang/lib/AST/VTableBuilder.cpp > head/contrib/llvm/tools/clang/lib/Analysis/CFG.cpp > head/contrib/llvm/tools/clang/lib/Analysis/CocoaConventions.cpp > head/contrib/llvm/tools/clang/lib/Analysis/FormatString.cpp > head/contrib/llvm/tools/clang/lib/Analysis/FormatStringParsing.h > head/contrib/llvm/tools/clang/lib/Analysis/LiveVariables.cpp > head/contrib/llvm/tools/clang/lib/Analysis/PrintfFormatString.cpp > head/contrib/llvm/tools/clang/lib/Analysis/ProgramPoint.cpp > head/contrib/llvm/tools/clang/lib/Analysis/PseudoConstantAnalysis.cpp > head/contrib/llvm/tools/clang/lib/Analysis/ReachableCode.cpp > head/contrib/llvm/tools/clang/lib/Analysis/ScanfFormatString.cpp > head/contrib/llvm/tools/clang/lib/Analysis/ThreadSafety.cpp > head/contrib/llvm/tools/clang/lib/Analysis/UninitializedValues.cpp > head/contrib/llvm/tools/clang/lib/Basic/Builtins.cpp > head/contrib/llvm/tools/clang/lib/Basic/ConvertUTF.c > head/contrib/llvm/tools/clang/lib/Basic/Diagnostic.cpp > head/contrib/llvm/tools/clang/lib/Basic/DiagnosticIDs.cpp > head/contrib/llvm/tools/clang/lib/Basic/FileManager.cpp > head/contrib/llvm/tools/clang/lib/Basic/FileSystemStatCache.cpp > head/contrib/llvm/tools/clang/lib/Basic/IdentifierTable.cpp > head/contrib/llvm/tools/clang/lib/Basic/LangOptions.cpp > head/contrib/llvm/tools/clang/lib/Basic/SourceLocation.cpp > head/contrib/llvm/tools/clang/lib/Basic/SourceManager.cpp > head/contrib/llvm/tools/clang/lib/Basic/TargetInfo.cpp > head/contrib/llvm/tools/clang/lib/Basic/Targets.cpp > head/contrib/llvm/tools/clang/lib/Basic/Version.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/ABIInfo.h > head/contrib/llvm/tools/clang/lib/CodeGen/BackendUtil.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGBlocks.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGBlocks.h > head/contrib/llvm/tools/clang/lib/CodeGen/CGBuiltin.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGCXX.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGCXXABI.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGCXXABI.h > head/contrib/llvm/tools/clang/lib/CodeGen/CGCall.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGCall.h > head/contrib/llvm/tools/clang/lib/CodeGen/CGClass.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGCleanup.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGDebugInfo.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGDebugInfo.h > head/contrib/llvm/tools/clang/lib/CodeGen/CGDecl.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGDeclCXX.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGException.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGExpr.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGExprAgg.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGExprCXX.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGExprComplex.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGExprConstant.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGExprScalar.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGObjC.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCGNU.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCMac.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCRuntime.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGObjCRuntime.h > head/contrib/llvm/tools/clang/lib/CodeGen/CGRTTI.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGRecordLayoutBuilder.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGStmt.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGVTT.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGVTables.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CGValue.h > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenAction.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenFunction.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenFunction.h > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenModule.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenModule.h > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTBAA.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTBAA.h > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTypes.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTypes.h > head/contrib/llvm/tools/clang/lib/CodeGen/ItaniumCXXABI.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/MicrosoftCXXABI.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/ModuleBuilder.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/TargetInfo.cpp > head/contrib/llvm/tools/clang/lib/CodeGen/TargetInfo.h > head/contrib/llvm/tools/clang/lib/Driver/Action.cpp > head/contrib/llvm/tools/clang/lib/Driver/Arg.cpp > head/contrib/llvm/tools/clang/lib/Driver/ArgList.cpp > head/contrib/llvm/tools/clang/lib/Driver/CC1AsOptions.cpp > head/contrib/llvm/tools/clang/lib/Driver/CC1Options.cpp > head/contrib/llvm/tools/clang/lib/Driver/Compilation.cpp > head/contrib/llvm/tools/clang/lib/Driver/Driver.cpp > head/contrib/llvm/tools/clang/lib/Driver/DriverOptions.cpp > head/contrib/llvm/tools/clang/lib/Driver/Job.cpp > head/contrib/llvm/tools/clang/lib/Driver/Option.cpp > head/contrib/llvm/tools/clang/lib/Driver/ToolChain.cpp > head/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp > head/contrib/llvm/tools/clang/lib/Driver/ToolChains.h > head/contrib/llvm/tools/clang/lib/Driver/Tools.cpp > head/contrib/llvm/tools/clang/lib/Driver/Tools.h > head/contrib/llvm/tools/clang/lib/Driver/Types.cpp > head/contrib/llvm/tools/clang/lib/Frontend/ASTConsumers.cpp > head/contrib/llvm/tools/clang/lib/Frontend/ASTMerge.cpp > head/contrib/llvm/tools/clang/lib/Frontend/ASTUnit.cpp > head/contrib/llvm/tools/clang/lib/Frontend/CacheTokens.cpp > head/contrib/llvm/tools/clang/lib/Frontend/CompilerInstance.cpp > head/contrib/llvm/tools/clang/lib/Frontend/CompilerInvocation.cpp > head/contrib/llvm/tools/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp > head/contrib/llvm/tools/clang/lib/Frontend/DependencyFile.cpp > head/contrib/llvm/tools/clang/lib/Frontend/FrontendAction.cpp > head/contrib/llvm/tools/clang/lib/Frontend/FrontendActions.cpp > head/contrib/llvm/tools/clang/lib/Frontend/HeaderIncludeGen.cpp > head/contrib/llvm/tools/clang/lib/Frontend/InitHeaderSearch.cpp > head/contrib/llvm/tools/clang/lib/Frontend/InitPreprocessor.cpp > head/contrib/llvm/tools/clang/lib/Frontend/LangStandards.cpp > head/contrib/llvm/tools/clang/lib/Frontend/LogDiagnosticPrinter.cpp > head/contrib/llvm/tools/clang/lib/Frontend/MultiplexConsumer.cpp > head/contrib/llvm/tools/clang/lib/Frontend/PrintPreprocessedOutput.cpp > head/contrib/llvm/tools/clang/lib/Frontend/TextDiagnosticBuffer.cpp > head/contrib/llvm/tools/clang/lib/Frontend/TextDiagnosticPrinter.cpp > head/contrib/llvm/tools/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp > head/contrib/llvm/tools/clang/lib/Frontend/Warnings.cpp > head/contrib/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp > head/contrib/llvm/tools/clang/lib/Headers/avxintrin.h > head/contrib/llvm/tools/clang/lib/Headers/emmintrin.h > head/contrib/llvm/tools/clang/lib/Headers/float.h > head/contrib/llvm/tools/clang/lib/Headers/immintrin.h > head/contrib/llvm/tools/clang/lib/Headers/mm3dnow.h > head/contrib/llvm/tools/clang/lib/Headers/smmintrin.h > head/contrib/llvm/tools/clang/lib/Headers/tgmath.h > head/contrib/llvm/tools/clang/lib/Headers/tmmintrin.h > head/contrib/llvm/tools/clang/lib/Headers/wmmintrin.h > head/contrib/llvm/tools/clang/lib/Headers/x86intrin.h > head/contrib/llvm/tools/clang/lib/Headers/xmmintrin.h > head/contrib/llvm/tools/clang/lib/Index/ASTLocation.cpp > head/contrib/llvm/tools/clang/lib/Index/Analyzer.cpp > head/contrib/llvm/tools/clang/lib/Lex/HeaderMap.cpp > head/contrib/llvm/tools/clang/lib/Lex/HeaderSearch.cpp > head/contrib/llvm/tools/clang/lib/Lex/Lexer.cpp > head/contrib/llvm/tools/clang/lib/Lex/LiteralSupport.cpp > head/contrib/llvm/tools/clang/lib/Lex/MacroArgs.cpp > head/contrib/llvm/tools/clang/lib/Lex/MacroInfo.cpp > head/contrib/llvm/tools/clang/lib/Lex/PPCaching.cpp > head/contrib/llvm/tools/clang/lib/Lex/PPDirectives.cpp > head/contrib/llvm/tools/clang/lib/Lex/PPExpressions.cpp > head/contrib/llvm/tools/clang/lib/Lex/PPLexerChange.cpp > head/contrib/llvm/tools/clang/lib/Lex/PPMacroExpansion.cpp > head/contrib/llvm/tools/clang/lib/Lex/PTHLexer.cpp > head/contrib/llvm/tools/clang/lib/Lex/Pragma.cpp > head/contrib/llvm/tools/clang/lib/Lex/PreprocessingRecord.cpp > head/contrib/llvm/tools/clang/lib/Lex/Preprocessor.cpp > head/contrib/llvm/tools/clang/lib/Lex/PreprocessorLexer.cpp > head/contrib/llvm/tools/clang/lib/Lex/TokenConcatenation.cpp > head/contrib/llvm/tools/clang/lib/Lex/TokenLexer.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseAST.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseCXXInlineMethods.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseDecl.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseDeclCXX.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseExpr.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseExprCXX.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseInit.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseObjc.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParsePragma.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParsePragma.h > head/contrib/llvm/tools/clang/lib/Parse/ParseStmt.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseTemplate.cpp > head/contrib/llvm/tools/clang/lib/Parse/ParseTentative.cpp > head/contrib/llvm/tools/clang/lib/Parse/Parser.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/FixItRewriter.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/FrontendActions.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/HTMLPrint.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/HTMLRewrite.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/RewriteMacros.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/RewriteObjC.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/RewriteTest.cpp > head/contrib/llvm/tools/clang/lib/Rewrite/Rewriter.cpp > head/contrib/llvm/tools/clang/lib/Sema/AnalysisBasedWarnings.cpp > head/contrib/llvm/tools/clang/lib/Sema/AttributeList.cpp > head/contrib/llvm/tools/clang/lib/Sema/CodeCompleteConsumer.cpp > head/contrib/llvm/tools/clang/lib/Sema/DeclSpec.cpp > head/contrib/llvm/tools/clang/lib/Sema/DelayedDiagnostic.cpp > head/contrib/llvm/tools/clang/lib/Sema/IdentifierResolver.cpp > head/contrib/llvm/tools/clang/lib/Sema/JumpDiagnostics.cpp > head/contrib/llvm/tools/clang/lib/Sema/Scope.cpp > head/contrib/llvm/tools/clang/lib/Sema/Sema.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaAccess.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaAttr.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaCXXScopeSpec.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaCast.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaChecking.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaCodeComplete.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaDecl.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaDeclAttr.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaDeclObjC.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaExceptionSpec.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaExpr.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaExprCXX.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaExprMember.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaExprObjC.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaFixItUtils.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaInit.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaLookup.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaObjCProperty.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaOverload.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaStmt.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaTemplate.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateDeduction.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateInstantiate.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaTemplateVariadic.cpp > head/contrib/llvm/tools/clang/lib/Sema/SemaType.cpp > head/contrib/llvm/tools/clang/lib/Sema/TargetAttributesSema.cpp > head/contrib/llvm/tools/clang/lib/Sema/TreeTransform.h > head/contrib/llvm/tools/clang/lib/Serialization/ASTCommon.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ASTCommon.h > head/contrib/llvm/tools/clang/lib/Serialization/ASTReader.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ASTReaderDecl.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ASTReaderInternals.h > head/contrib/llvm/tools/clang/lib/Serialization/ASTReaderStmt.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ASTWriter.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ASTWriterDecl.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ASTWriterStmt.cpp > head/contrib/llvm/tools/clang/lib/Serialization/GeneratePCH.cpp > head/contrib/llvm/tools/clang/lib/Serialization/Module.cpp > head/contrib/llvm/tools/clang/lib/Serialization/ModuleManager.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/AdjustedReturnValueChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/AnalyzerStatsChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ArrayBoundChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ArrayBoundCheckerV2.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/AttrNonNullChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/BasicObjCFoundationChecks.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/BuiltinFunctionChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CallAndMessageChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CastSizeChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CastToStructChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckObjCInstMethSignature.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckSecuritySyntaxOnly.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckSizeofPointer.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/Checkers.td > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ChrootChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ClangSACheckers.h > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DeadStoresChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DebugCheckers.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DereferenceChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/FixedAddressChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/IdempotentOperationChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/IteratorsChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/LLVMConventionsChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MacOSKeychainAPIChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MacOSXAPIChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocOverflowSecurityChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NSAutoreleasePoolChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NSErrorChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NoReturnFunctionChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/OSAtomicChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCAtSyncChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCSelfInitChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCUnusedIVarsChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PointerArithChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PointerSubChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ReturnPointerRangeChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ReturnUndefChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StackAddrEscapeChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StreamChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefBranchChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefResultChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefinedArraySubscriptChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefinedAssignmentChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UnixAPIChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UnreachableCodeChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/AnalysisManager.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BasicConstraintManager.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BugReporter.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/Checker.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerContext.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerManager.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerRegistry.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/Environment.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExplodedGraph.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineC.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineObjC.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/MemRegion.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ObjCMessage.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/PathDiagnostic.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/PlistDiagnostics.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ProgramState.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/RangeConstraintManager.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/RegionStore.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SValBuilder.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SVals.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SimpleConstraintManager.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SimpleConstraintManager.h > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/Store.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SymbolManager.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/TextPathDiagnostics.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp > head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Frontend/CheckerRegistration.cpp > head/contrib/llvm/tools/clang/tools/driver/cc1_main.cpp > head/contrib/llvm/tools/clang/tools/driver/cc1as_main.cpp > head/contrib/llvm/tools/clang/tools/driver/driver.cpp > head/contrib/llvm/tools/clang/utils/TableGen/ClangAttrEmitter.cpp > head/contrib/llvm/tools/clang/utils/TableGen/ClangAttrEmitter.h > head/contrib/llvm/tools/clang/utils/TableGen/ClangDiagnosticsEmitter.cpp > head/contrib/llvm/tools/clang/utils/TableGen/NeonEmitter.cpp > head/contrib/llvm/tools/clang/utils/TableGen/NeonEmitter.h > head/contrib/llvm/tools/clang/utils/TableGen/TableGen.cpp > head/contrib/llvm/tools/llc/llc.cpp > head/contrib/llvm/tools/lli/lli.cpp > head/contrib/llvm/tools/llvm-as/llvm-as.cpp > head/contrib/llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp > head/contrib/llvm/tools/llvm-diff/DiffConsumer.cpp > head/contrib/llvm/tools/llvm-diff/DiffConsumer.h > head/contrib/llvm/tools/llvm-diff/DifferenceEngine.cpp > head/contrib/llvm/tools/llvm-diff/DifferenceEngine.h > head/contrib/llvm/tools/llvm-diff/llvm-diff.cpp > head/contrib/llvm/tools/llvm-dis/llvm-dis.cpp > head/contrib/llvm/tools/llvm-extract/llvm-extract.cpp > head/contrib/llvm/tools/llvm-ld/llvm-ld.cpp > head/contrib/llvm/tools/llvm-link/llvm-link.cpp > head/contrib/llvm/tools/llvm-mc/Disassembler.cpp > head/contrib/llvm/tools/llvm-mc/llvm-mc.cpp > head/contrib/llvm/tools/llvm-nm/llvm-nm.cpp > head/contrib/llvm/tools/llvm-objdump/MachODump.cpp > head/contrib/llvm/tools/llvm-objdump/llvm-objdump.cpp > head/contrib/llvm/tools/llvm-objdump/llvm-objdump.h > head/contrib/llvm/tools/llvm-prof/llvm-prof.cpp > head/contrib/llvm/tools/llvm-rtdyld/llvm-rtdyld.cpp > head/contrib/llvm/tools/opt/PrintSCC.cpp > head/contrib/llvm/tools/opt/opt.cpp > head/contrib/llvm/utils/TableGen/AsmMatcherEmitter.cpp > head/contrib/llvm/utils/TableGen/AsmWriterEmitter.cpp > head/contrib/llvm/utils/TableGen/AsmWriterEmitter.h > head/contrib/llvm/utils/TableGen/CallingConvEmitter.cpp > head/contrib/llvm/utils/TableGen/CodeEmitterGen.cpp > head/contrib/llvm/utils/TableGen/CodeGenDAGPatterns.cpp > head/contrib/llvm/utils/TableGen/CodeGenDAGPatterns.h > head/contrib/llvm/utils/TableGen/CodeGenInstruction.cpp > head/contrib/llvm/utils/TableGen/CodeGenRegisters.cpp > head/contrib/llvm/utils/TableGen/CodeGenRegisters.h > head/contrib/llvm/utils/TableGen/CodeGenTarget.cpp > head/contrib/llvm/utils/TableGen/CodeGenTarget.h > head/contrib/llvm/utils/TableGen/DAGISelMatcher.cpp > head/contrib/llvm/utils/TableGen/DAGISelMatcher.h > head/contrib/llvm/utils/TableGen/DAGISelMatcherEmitter.cpp > head/contrib/llvm/utils/TableGen/DAGISelMatcherGen.cpp > head/contrib/llvm/utils/TableGen/DisassemblerEmitter.cpp > head/contrib/llvm/utils/TableGen/EDEmitter.cpp > head/contrib/llvm/utils/TableGen/FastISelEmitter.cpp > head/contrib/llvm/utils/TableGen/FixedLenDecoderEmitter.cpp > head/contrib/llvm/utils/TableGen/FixedLenDecoderEmitter.h > head/contrib/llvm/utils/TableGen/InstrInfoEmitter.cpp > head/contrib/llvm/utils/TableGen/InstrInfoEmitter.h > head/contrib/llvm/utils/TableGen/IntrinsicEmitter.cpp > head/contrib/llvm/utils/TableGen/IntrinsicEmitter.h > head/contrib/llvm/utils/TableGen/PseudoLoweringEmitter.cpp > head/contrib/llvm/utils/TableGen/RegisterInfoEmitter.cpp > head/contrib/llvm/utils/TableGen/RegisterInfoEmitter.h > head/contrib/llvm/utils/TableGen/SetTheory.cpp > head/contrib/llvm/utils/TableGen/SetTheory.h > head/contrib/llvm/utils/TableGen/StringToOffsetTable.h > head/contrib/llvm/utils/TableGen/SubtargetEmitter.cpp > head/contrib/llvm/utils/TableGen/TableGen.cpp > head/contrib/llvm/utils/TableGen/X86DisassemblerTables.cpp > head/contrib/llvm/utils/TableGen/X86ModRMFilters.h > head/contrib/llvm/utils/TableGen/X86RecognizableInstr.cpp > head/contrib/llvm/utils/TableGen/X86RecognizableInstr.h > head/etc/mtree/BSD.include.dist > head/lib/clang/Makefile > head/lib/clang/clang.build.mk > head/lib/clang/include/Makefile > head/lib/clang/include/clang/Basic/Version.inc > head/lib/clang/include/llvm/Config/config.h > head/lib/clang/include/llvm/Config/llvm-config.h > head/lib/clang/libclanganalysis/Makefile > head/lib/clang/libclangarcmigrate/Makefile > head/lib/clang/libclangast/Makefile > head/lib/clang/libclangbasic/Makefile > head/lib/clang/libclangcodegen/Makefile > head/lib/clang/libclangdriver/Makefile > head/lib/clang/libclangfrontend/Makefile > head/lib/clang/libclangindex/Makefile > head/lib/clang/libclanglex/Makefile > head/lib/clang/libclangparse/Makefile > head/lib/clang/libclangrewrite/Makefile > head/lib/clang/libclangsema/Makefile > head/lib/clang/libclangserialization/Makefile > head/lib/clang/libclangstaticanalyzercheckers/Makefile > head/lib/clang/libclangstaticanalyzercore/Makefile > head/lib/clang/libllvmanalysis/Makefile > head/lib/clang/libllvmarmcodegen/Makefile > head/lib/clang/libllvmarmdesc/Makefile > head/lib/clang/libllvmasmprinter/Makefile > head/lib/clang/libllvmcodegen/Makefile > head/lib/clang/libllvmcore/Makefile > head/lib/clang/libllvminstrumentation/Makefile > head/lib/clang/libllvmjit/Makefile > head/lib/clang/libllvmmc/Makefile > head/lib/clang/libllvmmcjit/Makefile > head/lib/clang/libllvmmipscodegen/Makefile > head/lib/clang/libllvmmipsdesc/Makefile > head/lib/clang/libllvmpowerpccodegen/Makefile > head/lib/clang/libllvmpowerpcdesc/Makefile > head/lib/clang/libllvmruntimedyld/Makefile > head/lib/clang/libllvmscalaropts/Makefile > head/lib/clang/libllvmselectiondag/Makefile > head/lib/clang/libllvmsupport/Makefile > head/lib/clang/libllvmtablegen/Makefile > head/lib/clang/libllvmtarget/Makefile > head/lib/clang/libllvmtransformutils/Makefile > head/lib/clang/libllvmx86codegen/Makefile > head/lib/clang/libllvmx86desc/Makefile > head/share/mk/bsd.sys.mk > head/usr.bin/clang/bugpoint/Makefile > head/usr.bin/clang/bugpoint/bugpoint.1 > head/usr.bin/clang/clang/Makefile > head/usr.bin/clang/clang/clang.1 > head/usr.bin/clang/llc/llc.1 > head/usr.bin/clang/lli/Makefile > head/usr.bin/clang/lli/lli.1 > head/usr.bin/clang/llvm-ar/llvm-ar.1 > head/usr.bin/clang/llvm-as/llvm-as.1 > head/usr.bin/clang/llvm-bcanalyzer/llvm-bcanalyzer.1 > head/usr.bin/clang/llvm-diff/llvm-diff.1 > head/usr.bin/clang/llvm-dis/llvm-dis.1 > head/usr.bin/clang/llvm-extract/llvm-extract.1 > head/usr.bin/clang/llvm-ld/Makefile > head/usr.bin/clang/llvm-ld/llvm-ld.1 > head/usr.bin/clang/llvm-link/llvm-link.1 > head/usr.bin/clang/llvm-nm/llvm-nm.1 > head/usr.bin/clang/llvm-prof/llvm-prof.1 > head/usr.bin/clang/llvm-ranlib/llvm-ranlib.1 > head/usr.bin/clang/opt/Makefile > head/usr.bin/clang/opt/opt.1 > head/usr.bin/clang/tblgen/Makefile > head/usr.bin/clang/tblgen/tblgen.1 > Directory Properties: > head/contrib/llvm/ (props changed) > head/contrib/llvm/tools/clang/ (props changed) > > Modified: head/ObsoleteFiles.inc > ============================================================================== > --- head/ObsoleteFiles.inc Mon Apr 16 21:22:02 2012 (r234352) > +++ head/ObsoleteFiles.inc Mon Apr 16 21:23:25 2012 (r234353) > @@ -38,6 +38,22 @@ > # xargs -n1 | sort | uniq -d; > # done > > +# 20120415: new clang import which bumps version from 3.0 to 3.1 > +OLD_FILES+=usr/include/clang/3.0/altivec.h > +OLD_FILES+=usr/include/clang/3.0/avxintrin.h > +OLD_FILES+=usr/include/clang/3.0/emmintrin.h > +OLD_FILES+=usr/include/clang/3.0/immintrin.h > +OLD_FILES+=usr/include/clang/3.0/mm3dnow.h > +OLD_FILES+=usr/include/clang/3.0/mm_malloc.h > +OLD_FILES+=usr/include/clang/3.0/mmintrin.h > +OLD_FILES+=usr/include/clang/3.0/nmmintrin.h > +OLD_FILES+=usr/include/clang/3.0/pmmintrin.h > +OLD_FILES+=usr/include/clang/3.0/smmintrin.h > +OLD_FILES+=usr/include/clang/3.0/tmmintrin.h > +OLD_FILES+=usr/include/clang/3.0/wmmintrin.h > +OLD_FILES+=usr/include/clang/3.0/x86intrin.h > +OLD_FILES+=usr/include/clang/3.0/xmmintrin.h > +OLD_DIRS+=usr/include/clang/3.0 > # 20120322: Update heimdal to 1.5.1. > OLD_FILES+=usr/include/krb5-v4compat.h \ > usr/include/krb_err.h \ > > Modified: head/contrib/llvm/LICENSE.TXT > ============================================================================== > --- head/contrib/llvm/LICENSE.TXT Mon Apr 16 21:22:02 2012 (r234352) > +++ head/contrib/llvm/LICENSE.TXT Mon Apr 16 21:23:25 2012 (r234353) > @@ -4,7 +4,7 @@ LLVM Release License > University of Illinois/NCSA > Open Source License > > -Copyright (c) 2003-2011 University of Illinois at Urbana-Champaign. > +Copyright (c) 2003-2012 University of Illinois at Urbana-Champaign. > All rights reserved. > > Developed by: > @@ -67,3 +67,4 @@ Autoconf llvm/autoconf > CellSPU backend llvm/lib/Target/CellSPU/README.txt > Google Test llvm/utils/unittest/googletest > OpenBSD regex llvm/lib/Support/{reg*, COPYRIGHT.regex} > +pyyaml tests llvm/test/YAMLParser/{*.data, LICENSE.TXT} > > Modified: head/contrib/llvm/include/llvm-c/Analysis.h > ============================================================================== > --- head/contrib/llvm/include/llvm-c/Analysis.h Mon Apr 16 21:22:02 2012 (r234352) > +++ head/contrib/llvm/include/llvm-c/Analysis.h Mon Apr 16 21:23:25 2012 (r234353) > @@ -25,6 +25,12 @@ > extern "C" { > #endif > > +/** > + * @defgroup LLVMCAnalysis Analysis > + * @ingroup LLVMC > + * > + * @{ > + */ > > typedef enum { > LLVMAbortProcessAction, /* verifier will print to stderr and abort() */ > @@ -48,6 +54,10 @@ LLVMBool LLVMVerifyFunction(LLVMValueRef > void LLVMViewFunctionCFG(LLVMValueRef Fn); > void LLVMViewFunctionCFGOnly(LLVMValueRef Fn); > > +/** > + * @} > + */ > + > #ifdef __cplusplus > } > #endif > > Modified: head/contrib/llvm/include/llvm-c/BitReader.h > ============================================================================== > --- head/contrib/llvm/include/llvm-c/BitReader.h Mon Apr 16 21:22:02 2012 (r234352) > +++ head/contrib/llvm/include/llvm-c/BitReader.h Mon Apr 16 21:23:25 2012 (r234353) > @@ -25,6 +25,12 @@ > extern "C" { > #endif > > +/** > + * @defgroup LLVMCBitReader Bit Reader > + * @ingroup LLVMC > + * > + * @{ > + */ > > /* Builds a module from the bitcode in the specified memory buffer, returning a > reference to the module via the OutModule parameter. Returns 0 on success. > @@ -59,6 +65,10 @@ LLVMBool LLVMGetBitcodeModuleProvider(LL > LLVMModuleProviderRef *OutMP, > char **OutMessage); > > +/** > + * @} > + */ > + > #ifdef __cplusplus > } > #endif > > Modified: head/contrib/llvm/include/llvm-c/BitWriter.h > ============================================================================== > --- head/contrib/llvm/include/llvm-c/BitWriter.h Mon Apr 16 21:22:02 2012 (r234352) > +++ head/contrib/llvm/include/llvm-c/BitWriter.h Mon Apr 16 21:23:25 2012 (r234353) > @@ -25,6 +25,12 @@ > extern "C" { > #endif > > +/** > + * @defgroup LLVMCBitWriter Bit Writer > + * @ingroup LLVMC > + * > + * @{ > + */ > > /*===-- Operations on modules ---------------------------------------------===*/ > > @@ -39,6 +45,10 @@ int LLVMWriteBitcodeToFD(LLVMModuleRef M > descriptor. Returns 0 on success. Closes the Handle. */ > int LLVMWriteBitcodeToFileHandle(LLVMModuleRef M, int Handle); > > +/** > + * @} > + */ > + > #ifdef __cplusplus > } > #endif > > Modified: head/contrib/llvm/include/llvm-c/Core.h > ============================================================================== > --- head/contrib/llvm/include/llvm-c/Core.h Mon Apr 16 21:22:02 2012 (r234352) > +++ head/contrib/llvm/include/llvm-c/Core.h Mon Apr 16 21:23:25 2012 (r234353) > @@ -10,24 +10,6 @@ > |* This header declares the C interface to libLLVMCore.a, which implements *| > |* the LLVM intermediate representation. *| > |* *| > -|* LLVM uses a polymorphic type hierarchy which C cannot represent, therefore *| > -|* parameters must be passed as base types. Despite the declared types, most *| > -|* of the functions provided operate only on branches of the type hierarchy. *| > -|* The declared parameter names are descriptive and specify which type is *| > -|* required. Additionally, each type hierarchy is documented along with the *| > -|* functions that operate upon it. For more detail, refer to LLVM's C++ code. *| > -|* If in doubt, refer to Core.cpp, which performs paramter downcasts in the *| > -|* form unwrap(Param). *| > -|* *| > -|* Many exotic languages can interoperate with C code but have a harder time *| > -|* with C++ due to name mangling. So in addition to C, this interface enables *| > -|* tools written in such languages. *| > -|* *| > -|* When included into a C++ source file, also declares 'wrap' and 'unwrap' *| > -|* helpers to perform opaque reference<-->pointer conversions. These helpers *| > -|* are shorter and more tightly typed than writing the casts by hand when *| > -|* authoring bindings. In assert builds, they will do runtime type checking. *| > -|* *| > \*===----------------------------------------------------------------------===*/ > > #ifndef LLVM_C_CORE_H > @@ -46,50 +28,121 @@ > extern "C" { > #endif > > +/** > + * @defgroup LLVMC LLVM-C: C interface to LLVM > + * > + * This module exposes parts of the LLVM library as a C API. > + * > + * @{ > + */ > + > +/** > + * @defgroup LLVMCTransforms Transforms > + */ > + > +/** > + * @defgroup LLVMCCore Core > + * > + * This modules provide an interface to libLLVMCore, which implements > + * the LLVM intermediate representation as well as other related types > + * and utilities. > + * > + * LLVM uses a polymorphic type hierarchy which C cannot represent, therefore > + * parameters must be passed as base types. Despite the declared types, most > + * of the functions provided operate only on branches of the type hierarchy. > + * The declared parameter names are descriptive and specify which type is > + * required. Additionally, each type hierarchy is documented along with the > + * functions that operate upon it. For more detail, refer to LLVM's C++ code. > + * If in doubt, refer to Core.cpp, which performs paramter downcasts in the > + * form unwrap(Param). > + * > + * Many exotic languages can interoperate with C code but have a harder time > + * with C++ due to name mangling. So in addition to C, this interface enables > + * tools written in such languages. > + * > + * When included into a C++ source file, also declares 'wrap' and 'unwrap' > + * helpers to perform opaque reference<-->pointer conversions. These helpers > + * are shorter and more tightly typed than writing the casts by hand when > + * authoring bindings. In assert builds, they will do runtime type checking. > + * > + * @{ > + */ > + > +/** > + * @defgroup LLVMCCoreTypes Types and Enumerations > + * > + * @{ > + */ > > typedef int LLVMBool; > > /* Opaque types. */ > > /** > - * The top-level container for all LLVM global data. See the LLVMContext class. > + * The top-level container for all LLVM global data. See the LLVMContext class. > */ > typedef struct LLVMOpaqueContext *LLVMContextRef; > > /** > * The top-level container for all other LLVM Intermediate Representation (IR) > - * objects. See the llvm::Module class. > + * objects. > + * > + * @see llvm::Module > */ > typedef struct LLVMOpaqueModule *LLVMModuleRef; > > /** > - * Each value in the LLVM IR has a type, an LLVMTypeRef. See the llvm::Type > - * class. > + * Each value in the LLVM IR has a type, an LLVMTypeRef. > + * > + * @see llvm::Type > */ > typedef struct LLVMOpaqueType *LLVMTypeRef; > > +/** > + * Represents an individual value in LLVM IR. > + * > + * This models llvm::Value. > + */ > typedef struct LLVMOpaqueValue *LLVMValueRef; > + > +/** > + * Represents a basic block of instruction in LLVM IR. > + * > + * This models llvm::BasicBlock. > + */ > typedef struct LLVMOpaqueBasicBlock *LLVMBasicBlockRef; > + > +/** > + * Represents an LLVM basic block builder. > + * > + * This models llvm::IRBuilder. > + */ > typedef struct LLVMOpaqueBuilder *LLVMBuilderRef; > > -/* Interface used to provide a module to JIT or interpreter. This is now just a > - * synonym for llvm::Module, but we have to keep using the different type to > - * keep binary compatibility. > +/** > + * Interface used to provide a module to JIT or interpreter. > + * This is now just a synonym for llvm::Module, but we have to keep using the > + * different type to keep binary compatibility. > */ > typedef struct LLVMOpaqueModuleProvider *LLVMModuleProviderRef; > > -/* Used to provide a module to JIT or interpreter. > - * See the llvm::MemoryBuffer class. > +/** > + * Used to provide a module to JIT or interpreter. > + * > + * @see llvm::MemoryBuffer > */ > typedef struct LLVMOpaqueMemoryBuffer *LLVMMemoryBufferRef; > > -/** See the llvm::PassManagerBase class. */ > +/** @see llvm::PassManagerBase */ > typedef struct LLVMOpaquePassManager *LLVMPassManagerRef; > > -/** See the llvm::PassRegistry class. */ > +/** @see llvm::PassRegistry */ > typedef struct LLVMOpaquePassRegistry *LLVMPassRegistryRef; > > -/** Used to get the users and usees of a Value. See the llvm::Use class. */ > +/** > + * Used to get the users and usees of a Value. > + * > + * @see llvm::Use */ > typedef struct LLVMOpaqueUse *LLVMUseRef; > > typedef enum { > @@ -119,6 +172,11 @@ typedef enum { > LLVMReturnsTwice = 1 << 29, > LLVMUWTable = 1 << 30, > LLVMNonLazyBind = 1 << 31 > + > + // FIXME: This attribute is currently not included in the C API as > + // a temporary measure until the API/ABI impact to the C API is understood > + // and the path forward agreed upon. > + //LLVMAddressSafety = 1ULL << 32 > } LLVMAttribute; > > typedef enum { > @@ -195,14 +253,13 @@ typedef enum { > > /* Exception Handling Operators */ > LLVMResume = 58, > - LLVMLandingPad = 59, > - LLVMUnwind = 60 > - > + LLVMLandingPad = 59 > > } LLVMOpcode; > > typedef enum { > LLVMVoidTypeKind, /**< type with no size */ > + LLVMHalfTypeKind, /**< 16 bit floating point type */ > LLVMFloatTypeKind, /**< 32 bit floating point type */ > LLVMDoubleTypeKind, /**< 64 bit floating point type */ > LLVMX86_FP80TypeKind, /**< 80 bit floating point type (X87) */ > @@ -294,6 +351,10 @@ typedef enum { > LLVMLandingPadFilter /**< A filter clause */ > } LLVMLandingPadClauseTy; > > +/** > + * @} > + */ > + > void LLVMInitializeCore(LLVMPassRegistryRef R); > > > @@ -302,49 +363,233 @@ void LLVMInitializeCore(LLVMPassRegistry > void LLVMDisposeMessage(char *Message); > > > -/*===-- Contexts ----------------------------------------------------------===*/ > +/** > + * @defgroup LLVMCCoreContext Contexts > + * > + * Contexts are execution states for the core LLVM IR system. > + * > + * Most types are tied to a context instance. Multiple contexts can > + * exist simultaneously. A single context is not thread safe. However, > + * different contexts can execute on different threads simultaneously. > + * > + * @{ > + */ > > -/* Create and destroy contexts. */ > +/** > + * Create a new context. > + * > + * Every call to this function should be paired with a call to > + * LLVMContextDispose() or the context will leak memory. > + */ > LLVMContextRef LLVMContextCreate(void); > + > +/** > + * Obtain the global context instance. > + */ > LLVMContextRef LLVMGetGlobalContext(void); > + > +/** > + * Destroy a context instance. > + * > + * This should be called for every call to LLVMContextCreate() or memory > + * will be leaked. > + */ > void LLVMContextDispose(LLVMContextRef C); > > unsigned LLVMGetMDKindIDInContext(LLVMContextRef C, const char* Name, > unsigned SLen); > unsigned LLVMGetMDKindID(const char* Name, unsigned SLen); > > -/*===-- Modules -----------------------------------------------------------===*/ > +/** > + * @} > + */ > + > +/** > + * @defgroup LLVMCCoreModule Modules > + * > + * Modules represent the top-level structure in a LLVM program. An LLVM > + * module is effectively a translation unit or a collection of > + * translation units merged together. > + * > + * @{ > + */ > > -/* Create and destroy modules. */ > -/** See llvm::Module::Module. */ > +/** > + * Create a new, empty module in the global context. > + * > + * This is equivalent to calling LLVMModuleCreateWithNameInContext with > + * LLVMGetGlobalContext() as the context parameter. > + * > + * Every invocation should be paired with LLVMDisposeModule() or memory > + * will be leaked. > + */ > LLVMModuleRef LLVMModuleCreateWithName(const char *ModuleID); > + > +/** > + * Create a new, empty module in a specific context. > + * > + * Every invocation should be paired with LLVMDisposeModule() or memory > + * will be leaked. > + */ > LLVMModuleRef LLVMModuleCreateWithNameInContext(const char *ModuleID, > LLVMContextRef C); > > -/** See llvm::Module::~Module. */ > +/** > + * Destroy a module instance. > + * > + * This must be called for every created module or memory will be > + * leaked. > + */ > void LLVMDisposeModule(LLVMModuleRef M); > > -/** Data layout. See Module::getDataLayout. */ > +/** > + * Obtain the data layout for a module. > + * > + * @see Module::getDataLayout() > + */ > const char *LLVMGetDataLayout(LLVMModuleRef M); > + > +/** > + * Set the data layout for a module. > + * > + * @see Module::setDataLayout() > + */ > void LLVMSetDataLayout(LLVMModuleRef M, const char *Triple); > > -/** Target triple. See Module::getTargetTriple. */ > +/** > + * Obtain the target triple for a module. > + * > + * @see Module::getTargetTriple() > + */ > const char *LLVMGetTarget(LLVMModuleRef M); > + > +/** > + * Set the target triple for a module. > + * > + * @see Module::setTargetTriple() > + */ > void LLVMSetTarget(LLVMModuleRef M, const char *Triple); > > -/** See Module::dump. */ > +/** > + * Dump a representation of a module to stderr. > + * > + * @see Module::dump() > + */ > void LLVMDumpModule(LLVMModuleRef M); > > -/** See Module::setModuleInlineAsm. */ > +/** > + * Set inline assembly for a module. > + * > + * @see Module::setModuleInlineAsm() > + */ > void LLVMSetModuleInlineAsm(LLVMModuleRef M, const char *Asm); > > -/** See Module::getContext. */ > +/** > + * Obtain the context to which this module is associated. > + * > + * @see Module::getContext() > + */ > LLVMContextRef LLVMGetModuleContext(LLVMModuleRef M); > > -/*===-- Types -------------------------------------------------------------===*/ > +/** > + * Obtain a Type from a module by its registered name. > + */ > +LLVMTypeRef LLVMGetTypeByName(LLVMModuleRef M, const char *Name); > + > +/** > + * Obtain the number of operands for named metadata in a module. > + * > + * @see llvm::Module::getNamedMetadata() > + */ > +unsigned LLVMGetNamedMetadataNumOperands(LLVMModuleRef M, const char* name); > + > +/** > + * Obtain the named metadata operands for a module. > + * > + * The passed LLVMValueRef pointer should refer to an array of > + * LLVMValueRef at least LLVMGetNamedMetadataNumOperands long. This > + * array will be populated with the LLVMValueRef instances. Each > + * instance corresponds to a llvm::MDNode. > + * > + * @see llvm::Module::getNamedMetadata() > + * @see llvm::MDNode::getOperand() > + */ > +void LLVMGetNamedMetadataOperands(LLVMModuleRef M, const char* name, LLVMValueRef *Dest); > + > +/** > + * Add an operand to named metadata. > + * > + * @see llvm::Module::getNamedMetadata() > + * @see llvm::MDNode::addOperand() > + */ > +void LLVMAddNamedMetadataOperand(LLVMModuleRef M, const char* name, > + LLVMValueRef Val); > + > +/** > + * Add a function to a module under a specified name. > + * > + * @see llvm::Function::Create() > + */ > +LLVMValueRef LLVMAddFunction(LLVMModuleRef M, const char *Name, > + LLVMTypeRef FunctionTy); > + > +/** > + * Obtain a Function value from a Module by its name. > + * > + * The returned value corresponds to a llvm::Function value. > + * > + * @see llvm::Module::getFunction() > + */ > +LLVMValueRef LLVMGetNamedFunction(LLVMModuleRef M, const char *Name); > + > +/** > + * Obtain an iterator to the first Function in a Module. > + * > + * @see llvm::Module::begin() > + */ > +LLVMValueRef LLVMGetFirstFunction(LLVMModuleRef M); > + > +/** > + * Obtain an iterator to the last Function in a Module. > + * > + * @see llvm::Module::end() > + */ > +LLVMValueRef LLVMGetLastFunction(LLVMModuleRef M); > + > +/** > + * Advance a Function iterator to the next Function. > + * > + * Returns NULL if the iterator was already at the end and there are no more > + * functions. > + */ > +LLVMValueRef LLVMGetNextFunction(LLVMValueRef Fn); > + > +/** > + * Decrement a Function iterator to the previous Function. > + * > + * Returns NULL if the iterator was already at the beginning and there are > + * no previous functions. > + */ > +LLVMValueRef LLVMGetPreviousFunction(LLVMValueRef Fn); > + > +/** > + * @} > + */ > > -/* LLVM types conform to the following hierarchy: > - * > +/** > + * @defgroup LLVMCCoreType Types > + * > + * Types represent the type of a value. > + * > + * Types are associated with a context instance. The context internally > + * deduplicates types so there is only 1 instance of a specific type > + * alive at a time. In other words, a unique type is shared among all > + * consumers within a context. > + * > + * A Type in the C API corresponds to llvm::Type. > + * > + * Types have the following hierarchy: > + * > * types: > * integer type > * real type > @@ -356,16 +601,44 @@ LLVMContextRef LLVMGetModuleContext(LLVM > * void type > * label type > * opaque type > + * > + * @{ > */ > > -/** See llvm::LLVMTypeKind::getTypeID. */ > +/** > + * Obtain the enumerated type of a Type instance. > + * > + * @see llvm::Type:getTypeID() > + */ > LLVMTypeKind LLVMGetTypeKind(LLVMTypeRef Ty); > + > +/** > + * Whether the type has a known size. > + * > + * Things that don't have a size are abstract types, labels, and void.a > + * > + * @see llvm::Type::isSized() > + */ > LLVMBool LLVMTypeIsSized(LLVMTypeRef Ty); > > -/** See llvm::LLVMType::getContext. */ > +/** > + * Obtain the context to which this type instance is associated. > + * > + * @see llvm::Type::getContext() > + */ > LLVMContextRef LLVMGetTypeContext(LLVMTypeRef Ty); > > -/* Operations on integer types */ > +/** > + * @defgroup LLVMCCoreTypeInt Integer Types > + * > + * Functions in this section operate on integer types. > + * > + * @{ > + */ > + > +/** > + * Obtain an integer type from a context with specified bit width. > + */ > LLVMTypeRef LLVMInt1TypeInContext(LLVMContextRef C); > LLVMTypeRef LLVMInt8TypeInContext(LLVMContextRef C); > LLVMTypeRef LLVMInt16TypeInContext(LLVMContextRef C); > @@ -373,6 +646,10 @@ LLVMTypeRef LLVMInt32TypeInContext(LLVMC > LLVMTypeRef LLVMInt64TypeInContext(LLVMContextRef C); > LLVMTypeRef LLVMIntTypeInContext(LLVMContextRef C, unsigned NumBits); > > +/** > + * Obtain an integer type from the global context with a specified bit > + * width. > + */ > LLVMTypeRef LLVMInt1Type(void); > LLVMTypeRef LLVMInt8Type(void); > LLVMTypeRef LLVMInt16Type(void); > @@ -381,68 +658,336 @@ LLVMTypeRef LLVMInt64Type(void); > LLVMTypeRef LLVMIntType(unsigned NumBits); > unsigned LLVMGetIntTypeWidth(LLVMTypeRef IntegerTy); > > -/* Operations on real types */ > +/** > + * @} > + */ > + > +/** > + * @defgroup LLVMCCoreTypeFloat Floating Point Types > + * > + * @{ > + */ > + > +/** > + * Obtain a 16-bit floating point type from a context. > + */ > +LLVMTypeRef LLVMHalfTypeInContext(LLVMContextRef C); > + > +/** > + * Obtain a 32-bit floating point type from a context. > + */ > LLVMTypeRef LLVMFloatTypeInContext(LLVMContextRef C); > + > +/** > + * Obtain a 64-bit floating point type from a context. > + */ > LLVMTypeRef LLVMDoubleTypeInContext(LLVMContextRef C); > + > +/** > + * Obtain a 80-bit floating point type (X87) from a context. > + */ > LLVMTypeRef LLVMX86FP80TypeInContext(LLVMContextRef C); > + > +/** > + * Obtain a 128-bit floating point type (112-bit mantissa) from a > + * context. > + */ > LLVMTypeRef LLVMFP128TypeInContext(LLVMContextRef C); > + > +/** > + * Obtain a 128-bit floating point type (two 64-bits) from a context. > + */ > LLVMTypeRef LLVMPPCFP128TypeInContext(LLVMContextRef C); > > +/** > + * Obtain a floating point type from the global context. > + * > + * These map to the functions in this group of the same name. > + */ > +LLVMTypeRef LLVMHalfType(void); > LLVMTypeRef LLVMFloatType(void); > LLVMTypeRef LLVMDoubleType(void); > LLVMTypeRef LLVMX86FP80Type(void); > LLVMTypeRef LLVMFP128Type(void); > LLVMTypeRef LLVMPPCFP128Type(void); > > -/* Operations on function types */ > +/** > + * @} > + */ > + > +/** > + * @defgroup LLVMCCoreTypeFunction Function Types > + * > + * @{ > + */ > + > +/** > + * Obtain a function type consisting of a specified signature. > + * > + * The function is defined as a tuple of a return Type, a list of > + * parameter types, and whether the function is variadic. > + */ > LLVMTypeRef LLVMFunctionType(LLVMTypeRef ReturnType, > LLVMTypeRef *ParamTypes, unsigned ParamCount, > LLVMBool IsVarArg); > + > +/** > + * Returns whether a function type is variadic. > + */ > LLVMBool LLVMIsFunctionVarArg(LLVMTypeRef FunctionTy); > + > +/** > + * Obtain the Type this function Type returns. > + */ > LLVMTypeRef LLVMGetReturnType(LLVMTypeRef FunctionTy); > + > +/** > + * Obtain the number of parameters this function accepts. > + */ > unsigned LLVMCountParamTypes(LLVMTypeRef FunctionTy); > + > +/** > + * Obtain the types of a function's parameters. > + * > + * The Dest parameter should point to a pre-allocated array of > + * LLVMTypeRef at least LLVMCountParamTypes() large. On return, the > + * first LLVMCountParamTypes() entries in the array will be populated > + * with LLVMTypeRef instances. > + * > + * @param FunctionTy The function type to operate on. > + * @param Dest Memory address of an array to be filled with result. > + */ > void LLVMGetParamTypes(LLVMTypeRef FunctionTy, LLVMTypeRef *Dest); > > -/* Operations on struct types */ > +/** > + * @} > + */ > + > +/** > + * @defgroup LLVMCCoreTypeStruct Structure Types > + * > + * These functions relate to LLVMTypeRef instances. > + * > + * @see llvm::StructType > + * > + * @{ > + */ > + > +/** > + * Create a new structure type in a context. > + * > + * A structure is specified by a list of inner elements/types and > + * whether these can be packed together. > + * > + * @see llvm::StructType::create() > + */ > LLVMTypeRef LLVMStructTypeInContext(LLVMContextRef C, LLVMTypeRef *ElementTypes, > unsigned ElementCount, LLVMBool Packed); > + > +/** > + * Create a new structure type in the global context. > + * > + * @see llvm::StructType::create() > + */ > LLVMTypeRef LLVMStructType(LLVMTypeRef *ElementTypes, unsigned ElementCount, > LLVMBool Packed); > + > +/** > + * Create an empty structure in a context having a specified name. > + * > + * @see llvm::StructType::create() > + */ > LLVMTypeRef LLVMStructCreateNamed(LLVMContextRef C, const char *Name); > + > +/** > + * Obtain the name of a structure. > + * > + * @see llvm::StructType::getName() > + */ > const char *LLVMGetStructName(LLVMTypeRef Ty); > + > +/** > + * Set the contents of a structure type. > + * > + * @see llvm::StructType::setBody() > + */ > void LLVMStructSetBody(LLVMTypeRef StructTy, LLVMTypeRef *ElementTypes, > unsigned ElementCount, LLVMBool Packed); > > +/** > + * Get the number of elements defined inside the structure. > + * > + * @see llvm::StructType::getNumElements() > + */ > unsigned LLVMCountStructElementTypes(LLVMTypeRef StructTy); > + > +/** > + * Get the elements within a structure. > + * > + * The function is passed the address of a pre-allocated array of > + * LLVMTypeRef at least LLVMCountStructElementTypes() long. After > + * invocation, this array will be populated with the structure's > + * elements. The objects in the destination array will have a lifetime > + * of the structure type itself, which is the lifetime of the context it > + * is contained in. > + */ > void LLVMGetStructElementTypes(LLVMTypeRef StructTy, LLVMTypeRef *Dest); > + > +/** > + * Determine whether a structure is packed. > + * > + * @see llvm::StructType::isPacked() > + */ > LLVMBool LLVMIsPackedStruct(LLVMTypeRef StructTy); > + > +/** > + * Determine whether a structure is opaque. > + * > + * @see llvm::StructType::isOpaque() > + */ > LLVMBool LLVMIsOpaqueStruct(LLVMTypeRef StructTy); > > -LLVMTypeRef LLVMGetTypeByName(LLVMModuleRef M, const char *Name); > +/** > + * @} > + */ > > -/* Operations on array, pointer, and vector types (sequence types) */ > -LLVMTypeRef LLVMArrayType(LLVMTypeRef ElementType, unsigned ElementCount); > -LLVMTypeRef LLVMPointerType(LLVMTypeRef ElementType, unsigned AddressSpace); > -LLVMTypeRef LLVMVectorType(LLVMTypeRef ElementType, unsigned ElementCount); > > +/** > + * @defgroup LLVMCCoreTypeSequential Sequential Types > + * > + * Sequential types represents "arrays" of types. This is a super class > + * for array, vector, and pointer types. > + * > + * @{ > + */ > + > +/** > + * Obtain the type of elements within a sequential type. > + * > + * This works on array, vector, and pointer types. > + * > + * @see llvm::SequentialType::getElementType() > + */ > LLVMTypeRef LLVMGetElementType(LLVMTypeRef Ty); > + > +/** > + * Create a fixed size array type that refers to a specific type. > + * > + * The created type will exist in the context that its element type > + * exists in. > + * > + * @see llvm::ArrayType::get() > + */ > +LLVMTypeRef LLVMArrayType(LLVMTypeRef ElementType, unsigned ElementCount); > + > +/** > + * Obtain the length of an array type. > + * > + * This only works on types that represent arrays. > + * > + * @see llvm::ArrayType::getNumElements() > + */ > unsigned LLVMGetArrayLength(LLVMTypeRef ArrayTy); > + > +/** > + * Create a pointer type that points to a defined type. > + * > + * The created type will exist in the context that its pointee type > + * exists in. > + * > + * @see llvm::PointerType::get() > + */ > +LLVMTypeRef LLVMPointerType(LLVMTypeRef ElementType, unsigned AddressSpace); > + > +/** > + * Obtain the address space of a pointer type. > + * > + * This only works on types that represent pointers. > + * > + * @see llvm::PointerType::getAddressSpace() > + */ > unsigned LLVMGetPointerAddressSpace(LLVMTypeRef PointerTy); > + > +/** > + * Create a vector type that contains a defined type and has a specific > + * number of elements. > + * > + * The created type will exist in the context thats its element type > + * exists in. > + * > + * @see llvm::VectorType::get() > + */ > +LLVMTypeRef LLVMVectorType(LLVMTypeRef ElementType, unsigned ElementCount); > + > +/** > + * Obtain the number of elements in a vector type. > + * > + * This only works on types that represent vectors. > + * > + * @see llvm::VectorType::getNumElements() > + */ > unsigned LLVMGetVectorSize(LLVMTypeRef VectorTy); > > -/* Operations on other types */ > +/** > + * @} > + */ > + > +/** > + * @defgroup LLVMCCoreTypeOther Other Types > + * > + * @{ > + */ > + > +/** > + * Create a void type in a context. > + */ > LLVMTypeRef LLVMVoidTypeInContext(LLVMContextRef C); > + > +/** > + * Create a label type in a context. > + */ > LLVMTypeRef LLVMLabelTypeInContext(LLVMContextRef C); > + > +/** > + * Create a X86 MMX type in a context. > + */ > LLVMTypeRef LLVMX86MMXTypeInContext(LLVMContextRef C); > > +/** > + * These are similar to the above functions except they operate on the > + * global context. > + */ > LLVMTypeRef LLVMVoidType(void); > LLVMTypeRef LLVMLabelType(void); > LLVMTypeRef LLVMX86MMXType(void); > > -/*===-- Values ------------------------------------------------------------===*/ > +/** > + * @} > + */ > + > +/** > + * @} > + */ > > -/* The bulk of LLVM's object model consists of values, which comprise a very > +/** > + * @defgroup LLVMCCoreValues Values > + * > + * The bulk of LLVM's object model consists of values, which comprise a very > * rich type hierarchy. > + * > + * LLVMValueRef essentially represents llvm::Value. There is a rich > + * hierarchy of classes within this type. Depending on the instance > + * obtain, not all APIs are available. > + * > + * Callers can determine the type of a LLVMValueRef by calling the > + * LLVMIsA* family of functions (e.g. LLVMIsAArgument()). These > + * functions are defined by a macro, so it isn't obvious which are > + * available by looking at the Doxygen source code. Instead, look at the > + * source definition of LLVM_FOR_EACH_VALUE_SUBCLASS and note the list > + * of value names given. These value names also correspond to classes in > + * the llvm::Value hierarchy. > + * > + * @{ > */ > > #define LLVM_FOR_EACH_VALUE_SUBCLASS(macro) \ > @@ -473,8 +1018,6 @@ LLVMTypeRef LLVMX86MMXType(void); > macro(IntrinsicInst) \ > macro(DbgInfoIntrinsic) \ > macro(DbgDeclareInst) \ > - macro(EHExceptionInst) \ > - macro(EHSelectorInst) \ > macro(MemIntrinsic) \ > macro(MemCpyInst) \ > macro(MemMoveInst) \ > @@ -518,92 +1061,399 @@ LLVMTypeRef LLVMX86MMXType(void); > macro(LoadInst) \ > macro(VAArgInst) > > -/* Operations on all values */ > -LLVMTypeRef LLVMTypeOf(LLVMValueRef Val); > +/** > + * @defgroup LLVMCCoreValueGeneral General APIs > + * > + * Functions in this section work on all LLVMValueRef instances, > + * regardless of their sub-type. They correspond to functions available > + * on llvm::Value. > + * > + * @{ > + */ > + > > *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 21:45:31 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8C820106566C for ; Thu, 19 Apr 2012 21:45:31 +0000 (UTC) (envelope-from joerg@britannica.bec.de) Received: from mo6-p00-ob.rzone.de (mo6-p00-ob.rzone.de [IPv6:2a01:238:20a:202:5300::1]) by mx1.freebsd.org (Postfix) with ESMTP id 1B29B8FC1C for ; Thu, 19 Apr 2012 21:45:30 +0000 (UTC) X-RZG-AUTH: :JiIXek6mfvEEUpFQdo7Fj1/zg48CFjWjQv0cW+St/nW/avgusCdvwXOZ/NA7x/bslxlDPy6G726REW7piU2JIqNTwRM= X-RZG-CLASS-ID: mo00 Received: from britannica.bec.de ([2001:6f8:13f0:0:5e26:aff:fe1e:99a9]) by smtp.strato.de (josoe mo66) (RZmta 28.10 AUTH) with (DHE-RSA-AES128-SHA encrypted) ESMTPA id L058fdo3JIRtfv for ; Thu, 19 Apr 2012 23:45:28 +0200 (CEST) Received: by britannica.bec.de (sSMTP sendmail emulation); Thu, 19 Apr 2012 23:45:26 +0200 Date: Thu, 19 Apr 2012 23:45:26 +0200 From: Joerg Sonnenberger To: svn-src-all@freebsd.org Message-ID: <20120419214526.GA24945@britannica.bec.de> References: <201204162123.q3GLNSr6051133@svn.freebsd.org> <20120419211441.GA7744@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20120419211441.GA7744@freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Subject: Re: svn commit: r234353 - in head: . contrib/llvm contrib/llvm/include/llvm contrib/llvm/include/llvm-c contrib/llvm/include/llvm-c/Transforms contrib/llvm/include/llvm/ADT contrib/llvm/include/llvm/An... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 21:45:31 -0000 On Thu, Apr 19, 2012 at 09:14:41PM +0000, Alexander Best wrote: > On Mon Apr 16 12, Dimitry Andric wrote: > > Author: dim > > Date: Mon Apr 16 21:23:25 2012 > > New Revision: 234353 > > URL: http://svn.freebsd.org/changeset/base/234353 > > > > Log: > > Upgrade our copy of llvm/clang to trunk r154661, in preparation of the > > upcoming 3.1 release (expected in a few weeks). Preliminary release > > notes can be found at: > > very nice. :) > > any reason '-fformat-extensions'-support still hasn't been pushed upstream as > something like '-fbsd-extensions'? I think it's the wrong approach. What about adding a freebsd_printf format modifer (similar to the existing gnu_printf) and tagging the kernel printf accordingly? Joerg From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 22:22:22 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 61E9D1065675; Thu, 19 Apr 2012 22:22:22 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4A6EA8FC1B; Thu, 19 Apr 2012 22:22:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JMMM28009893; Thu, 19 Apr 2012 22:22:22 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JMMM1e009890; Thu, 19 Apr 2012 22:22:22 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204192222.q3JMMM1e009890@svn.freebsd.org> From: Kirk McKusick Date: Thu, 19 Apr 2012 22:22:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234470 - in stable/9/sys: i386/conf kern ufs/ffs ufs/ufs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 22:22:22 -0000 Author: mckusick Date: Thu Apr 19 22:22:21 2012 New Revision: 234470 URL: http://svn.freebsd.org/changeset/base/234470 Log: MFC of 233817: A file cannot be deallocated until its last name has been removed and it is no longer referenced by a user process. The inode for a file whose name has been removed, but is still referenced at the time of a crash will still be allocated in the filesystem, but will have no references (e.g., they will have no names referencing them from any directory). With traditional soft updates these unreferenced inodes will be found and reclaimed when the background fsck is run. When using journaled soft updates, the kernel must keep track of these inodes so that it can find and reclaim them during the cleanup process. Their existence cannot be stored in the journal as the journal only handles short-term events, and they may persist for days. So, they are tracked by keeping them in a linked list whose head pointer is stored in the superblock. The journal tracks them only until their linked list pointers have been commited to disk. Part of the cleanup process involves traversing the list of unreferenced inodes and reclaiming them. This bug was triggered when confusion arose in the commit steps of keeping the unreferenced-inode linked list coherent on disk. Notably, a race between the link() system call adding a link-count to a file and the unlink() system call removing a link-count to the file. Here if the unlink() ran after link() had looked up the file but before link() had incremented the link-count of the file, the file's link-count would drop to zero before the link() incremented it back up to one. If the file was referenced by a user process, the first transition through zero made it appear that it should be added to the unreferenced-inode list when in fact it should not have been added. If the new name created by link() was deleted within a few seconds (with the file still referenced by a user process) it would legitimately be a candidate for addition to the unreferenced-inode list. The result was that there were two attempts to add the same inode to the unreferenced-inode list which scrambled the unreferenced-inode list's pointers leading to a panic. The fix is to detect and avoid the false attempt at adding it to the unreferenced-inode list by having the link() system call check to see if the link count is zero before it increments it. If it is, the link() fails with ENOENT (showing that it has failed the link()/unlink() race). While tracking down this bug, we have added additional assertions to detect the problem sooner and also simplified some of the code. Reported by: Kirk Russell Fix submitted by: Jeff Roberson Tested by: Peter Holm PR: kern/159971 Modified: stable/9/sys/ufs/ffs/ffs_softdep.c stable/9/sys/ufs/ufs/ufs_vnops.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/ufs/ffs/ffs_softdep.c ============================================================================== --- stable/9/sys/ufs/ffs/ffs_softdep.c Thu Apr 19 21:12:08 2012 (r234469) +++ stable/9/sys/ufs/ffs/ffs_softdep.c Thu Apr 19 22:22:21 2012 (r234470) @@ -4322,6 +4322,7 @@ inodedep_lookup_ip(ip) (void) inodedep_lookup(UFSTOVFS(ip->i_ump), ip->i_number, dflags, &inodedep); inodedep->id_nlinkdelta = ip->i_nlink - ip->i_effnlink; + KASSERT((inodedep->id_state & UNLINKED) == 0, ("inode unlinked")); return (inodedep); } @@ -8454,6 +8455,7 @@ softdep_setup_remove(bp, dp, ip, isrmdir if (inodedep_lookup(UFSTOVFS(ip->i_ump), ip->i_number, 0, &inodedep) == 0) panic("softdep_setup_remove: Lost inodedep."); + KASSERT((inodedep->id_state & UNLINKED) == 0, ("inode unlinked")); dirrem->dm_state |= ONDEPLIST; LIST_INSERT_HEAD(&inodedep->id_dirremhd, dirrem, dm_inonext); @@ -8986,6 +8988,7 @@ first_unlinked_inodedep(ump) struct inodedep *inodedep; struct inodedep *idp; + mtx_assert(&lk, MA_OWNED); for (inodedep = TAILQ_LAST(&ump->softdep_unlinked, inodedeplst); inodedep; inodedep = idp) { if ((inodedep->id_state & UNLINKNEXT) == 0) @@ -8994,11 +8997,8 @@ first_unlinked_inodedep(ump) if (idp == NULL || (idp->id_state & UNLINKNEXT) == 0) break; if ((inodedep->id_state & UNLINKPREV) == 0) - panic("first_unlinked_inodedep: prev != next"); + break; } - if (inodedep == NULL) - return (NULL); - return (inodedep); } @@ -9037,8 +9037,12 @@ handle_written_sbdep(sbdep, bp) struct mount *mp; struct fs *fs; + mtx_assert(&lk, MA_OWNED); fs = sbdep->sb_fs; mp = UFSTOVFS(sbdep->sb_ump); + /* + * If the superblock doesn't match the in-memory list start over. + */ inodedep = first_unlinked_inodedep(sbdep->sb_ump); if ((inodedep && fs->fs_sujfree != inodedep->id_ino) || (inodedep == NULL && fs->fs_sujfree != 0)) { @@ -9048,8 +9052,6 @@ handle_written_sbdep(sbdep, bp) WORKITEM_FREE(sbdep, D_SBDEP); if (fs->fs_sujfree == 0) return (0); - if (inodedep_lookup(mp, fs->fs_sujfree, 0, &inodedep) == 0) - panic("handle_written_sbdep: lost inodedep"); /* * Now that we have a record of this inode in stable store allow it * to be written to free up pending work. Inodes may see a lot of @@ -9077,10 +9079,13 @@ unlinked_inodedep(mp, inodedep) { struct ufsmount *ump; + mtx_assert(&lk, MA_OWNED); if (MOUNTEDSUJ(mp) == 0) return; ump = VFSTOUFS(mp); ump->um_fs->fs_fmod = 1; + if (inodedep->id_state & UNLINKED) + panic("unlinked_inodedep: %p already unlinked\n", inodedep); inodedep->id_state |= UNLINKED; TAILQ_INSERT_HEAD(&ump->softdep_unlinked, inodedep, id_unlinked); } @@ -9108,6 +9113,10 @@ clear_unlinked_inodedep(inodedep) ino = inodedep->id_ino; error = 0; for (;;) { + mtx_assert(&lk, MA_OWNED); + KASSERT((inodedep->id_state & UNLINKED) != 0, + ("clear_unlinked_inodedep: inodedep %p not unlinked", + inodedep)); /* * If nothing has yet been written simply remove us from * the in memory list and return. This is the most common @@ -9165,36 +9174,19 @@ clear_unlinked_inodedep(inodedep) ACQUIRE_LOCK(&lk); continue; } + nino = 0; + idn = TAILQ_NEXT(inodedep, id_unlinked); + if (idn) + nino = idn->id_ino; /* * Remove us from the in memory list. After this we cannot * access the inodedep. */ - idn = TAILQ_NEXT(inodedep, id_unlinked); - inodedep->id_state &= ~(UNLINKED | UNLINKLINKS); + KASSERT((inodedep->id_state & UNLINKED) != 0, + ("clear_unlinked_inodedep: inodedep %p not unlinked", + inodedep)); + inodedep->id_state &= ~(UNLINKED | UNLINKLINKS | UNLINKONLIST); TAILQ_REMOVE(&ump->softdep_unlinked, inodedep, id_unlinked); - /* - * Determine the next inode number. - */ - nino = 0; - if (idn) { - /* - * If next isn't on the list we can just clear prev's - * state and schedule it to be fixed later. No need - * to synchronously write if we're not in the real - * list. - */ - if ((idn->id_state & UNLINKPREV) == 0 && pino != 0) { - idp->id_state &= ~UNLINKNEXT; - if ((idp->id_state & ONWORKLIST) == 0) - WORKLIST_INSERT(&bp->b_dep, - &idp->id_list); - FREE_LOCK(&lk); - bawrite(bp); - ACQUIRE_LOCK(&lk); - return; - } - nino = idn->id_ino; - } FREE_LOCK(&lk); /* * The predecessor's next pointer is manually updated here @@ -9233,13 +9225,14 @@ clear_unlinked_inodedep(inodedep) bwrite(bp); ACQUIRE_LOCK(&lk); } + if (fs->fs_sujfree != ino) return; panic("clear_unlinked_inodedep: Failed to clear free head"); } if (inodedep->id_ino == fs->fs_sujfree) panic("clear_unlinked_inodedep: Freeing head of free list"); - inodedep->id_state &= ~(UNLINKED | UNLINKLINKS); + inodedep->id_state &= ~(UNLINKED | UNLINKLINKS | UNLINKONLIST); TAILQ_REMOVE(&ump->softdep_unlinked, inodedep, id_unlinked); return; } @@ -9838,18 +9831,6 @@ initiate_write_inodeblock_ufs2(inodedep, inon = TAILQ_NEXT(inodedep, id_unlinked); dp->di_freelink = inon ? inon->id_ino : 0; } - if ((inodedep->id_state & (UNLINKED | UNLINKNEXT)) == - (UNLINKED | UNLINKNEXT)) { - struct inodedep *inon; - ino_t freelink; - - inon = TAILQ_NEXT(inodedep, id_unlinked); - freelink = inon ? inon->id_ino : 0; - if (freelink != dp->di_freelink) - panic("ino %p(0x%X) %d, %d != %d", - inodedep, inodedep->id_state, inodedep->id_ino, - freelink, dp->di_freelink); - } /* * If the bitmap is not yet written, then the allocated * inode cannot be written to disk. @@ -10848,10 +10829,9 @@ handle_written_inodeblock(inodedep, bp) freelink = dp2->di_freelink; } /* - * If we wrote a valid freelink pointer during the last write - * record it here. + * Leave this inodeblock dirty until it's in the list. */ - if ((inodedep->id_state & (UNLINKED | UNLINKNEXT)) == UNLINKED) { + if ((inodedep->id_state & (UNLINKED | UNLINKONLIST)) == UNLINKED) { struct inodedep *inon; inon = TAILQ_NEXT(inodedep, id_unlinked); @@ -10860,12 +10840,9 @@ handle_written_inodeblock(inodedep, bp) if (inon) inon->id_state |= UNLINKPREV; inodedep->id_state |= UNLINKNEXT; - } else - hadchanges = 1; - } - /* Leave this inodeblock dirty until it's in the list. */ - if ((inodedep->id_state & (UNLINKED | UNLINKONLIST)) == UNLINKED) + } hadchanges = 1; + } /* * If we had to rollback the inode allocation because of * bitmaps being incomplete, then simply restore it. Modified: stable/9/sys/ufs/ufs/ufs_vnops.c ============================================================================== --- stable/9/sys/ufs/ufs/ufs_vnops.c Thu Apr 19 21:12:08 2012 (r234469) +++ stable/9/sys/ufs/ufs/ufs_vnops.c Thu Apr 19 22:22:21 2012 (r234470) @@ -1002,6 +1002,14 @@ ufs_link(ap) error = EMLINK; goto out; } + /* + * The file may have been removed after namei droped the original + * lock. + */ + if (ip->i_effnlink == 0) { + error = ENOENT; + goto out; + } if (ip->i_flags & (IMMUTABLE | APPEND)) { error = EPERM; goto out; From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 22:23:42 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 170A7106566C; Thu, 19 Apr 2012 22:23:42 +0000 (UTC) (envelope-from jasone@freebsd.org) Received: from canonware.com (10140.x.rootbsd.net [204.109.63.53]) by mx1.freebsd.org (Postfix) with ESMTP id E2C7E8FC21; Thu, 19 Apr 2012 22:23:41 +0000 (UTC) Received: from [172.25.16.174] (unknown [173.252.71.3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by canonware.com (Postfix) with ESMTPSA id 9107D28417; Thu, 19 Apr 2012 15:23:40 -0700 (PDT) Mime-Version: 1.0 (Apple Message framework v1257) Content-Type: text/plain; charset=windows-1252 From: Jason Evans In-Reply-To: Date: Thu, 19 Apr 2012 15:23:39 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> <20120419091558.2ae655a0@cox.net> To: Conrad J. Sabatier X-Mailer: Apple Mail (2.1257) Cc: svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 22:23:42 -0000 On Apr 19, 2012, at 11:44 AM, Jason Evans wrote: > On Apr 19, 2012, at 7:15 AM, Conrad J. Sabatier wrote: >> Actually, I keep getting "undefined reference to _malloc_options" = while >> building libexec/atrun on amd64. Not sure what the problem may be. >> Could it have something to do with doing a debug build (with -g)? >>=20 >> =3D=3D=3D> libexec/atrun (all) >> [=85] >> -lutil /usr/obj/usr/src/tmp/usr/lib/libc.so: undefined reference to >> `_malloc_options' clang: error: linker command failed with exit code = 1 >> (use -v to see invocation) *** [atrun] Error code 1 >=20 > Perhaps this is related to using clang rather than gcc. I'll start a = clang-based buildworld to see if it reproduces here. >=20 > Jason With /etc/make.conf as: CFLAGS+=3D-g STRIP=3D CC=3Dclang CXX=3Dclang++ CPP=3Dclang-cpp I got this buildworld failure: --- clang -O2 -pipe -g -I/usr/src/lib/csu/amd64/../common = -I/usr/src/lib/csu/amd64/../../libc/include -fno-omit-frame-pointer = -std=3Dgnu99 -Qunused-arguments -Wsystem-headers -Werror -Wall = -Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes = -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual = -Wwrite-strin gs -Wswitch -Wshadow -Wunused-parameter -Wcast-align -Wchar-subscripts = -Winline -Wnested-externs -Wredundant-decls -Wold-style-definition = -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -c -o crt1.o = crt1.scrt1.s:8:2: error: input can't have .file dwarf directives when -g = is used to generate dwarf debug info for assembly code .file 1 "/usr/src/lib/csu/amd64/crt1.c" ^ crt1.s:8:8: error: file number already allocated .file 1 = "/usr/src/lib/csu/amd64/crt1.c" ^crt1.s:9:2: error: input can't have .file dwarf = directives when -g is used to generate dwarf debug info for assembly = code .file 2 "/usr/src/lib/csu/amd64/../common/crtbrand.c" = ^crt1.s:10:2: error: input can't have .file dwarf directives when -g is = used to generate dwarf debug info for assembly code .file 3 "/usr/src/lib/csu/amd64/../common/ignore_init.c" = ^ --- I removed the CFLAGS+=3D-g line, and buildworld succeeded. Jason= From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 22:28:43 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BB44D1065674; Thu, 19 Apr 2012 22:28:43 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8C2EE8FC0A; Thu, 19 Apr 2012 22:28:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JMSh30010126; Thu, 19 Apr 2012 22:28:43 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JMSh5T010124; Thu, 19 Apr 2012 22:28:43 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204192228.q3JMSh5T010124@svn.freebsd.org> From: Kirk McKusick Date: Thu, 19 Apr 2012 22:28:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234471 - in stable/9/sys: i386/conf kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 22:28:43 -0000 Author: mckusick Date: Thu Apr 19 22:28:42 2012 New Revision: 234471 URL: http://svn.freebsd.org/changeset/base/234471 Log: MFC of 234157: Whitespace cleanup. Modified: stable/9/sys/sys/mount.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/sys/mount.h ============================================================================== --- stable/9/sys/sys/mount.h Thu Apr 19 22:22:21 2012 (r234470) +++ stable/9/sys/sys/mount.h Thu Apr 19 22:28:42 2012 (r234471) @@ -200,10 +200,10 @@ void __mnt_vnode_markerfree(str __mnt_vnode_markerfree(&(mvp), (mp)) #define MNT_VNODE_FOREACH_ABORT(mp, mvp) \ - do { \ - MNT_ILOCK(mp); \ - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); \ - MNT_IUNLOCK(mp); \ + do { \ + MNT_ILOCK(mp); \ + MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); \ + MNT_IUNLOCK(mp); \ } while (0) #define MNT_ILOCK(mp) mtx_lock(&(mp)->mnt_mtx) @@ -212,7 +212,7 @@ void __mnt_vnode_markerfree(str #define MNT_MTX(mp) (&(mp)->mnt_mtx) #define MNT_REF(mp) (mp)->mnt_ref++ #define MNT_REL(mp) do { \ - KASSERT((mp)->mnt_ref > 0, ("negative mnt_ref")); \ + KASSERT((mp)->mnt_ref > 0, ("negative mnt_ref")); \ (mp)->mnt_ref--; \ if ((mp)->mnt_ref == 0) \ wakeup((mp)); \ From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 22:37:25 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9267C106564A; Thu, 19 Apr 2012 22:37:25 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7C4FA8FC17; Thu, 19 Apr 2012 22:37:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JMbPOr010473; Thu, 19 Apr 2012 22:37:25 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JMbPTY010471; Thu, 19 Apr 2012 22:37:25 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204192237.q3JMbPTY010471@svn.freebsd.org> From: Kirk McKusick Date: Thu, 19 Apr 2012 22:37:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234472 - in stable/8/sys: i386/conf sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 22:37:25 -0000 Author: mckusick Date: Thu Apr 19 22:37:24 2012 New Revision: 234472 URL: http://svn.freebsd.org/changeset/base/234472 Log: MFC of 234157: Whitespace cleanup. Modified: stable/8/sys/sys/mount.h Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/e1000/ (props changed) stable/8/sys/i386/conf/XENHVM (props changed) Modified: stable/8/sys/sys/mount.h ============================================================================== --- stable/8/sys/sys/mount.h Thu Apr 19 22:28:42 2012 (r234471) +++ stable/8/sys/sys/mount.h Thu Apr 19 22:37:24 2012 (r234472) @@ -201,10 +201,10 @@ void __mnt_vnode_markerfree(str __mnt_vnode_markerfree(&(mvp), (mp)) #define MNT_VNODE_FOREACH_ABORT(mp, mvp) \ - do { \ - MNT_ILOCK(mp); \ - MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); \ - MNT_IUNLOCK(mp); \ + do { \ + MNT_ILOCK(mp); \ + MNT_VNODE_FOREACH_ABORT_ILOCKED(mp, mvp); \ + MNT_IUNLOCK(mp); \ } while (0) #define MNT_ILOCK(mp) mtx_lock(&(mp)->mnt_mtx) @@ -213,7 +213,7 @@ void __mnt_vnode_markerfree(str #define MNT_MTX(mp) (&(mp)->mnt_mtx) #define MNT_REF(mp) (mp)->mnt_ref++ #define MNT_REL(mp) do { \ - KASSERT((mp)->mnt_ref > 0, ("negative mnt_ref")); \ + KASSERT((mp)->mnt_ref > 0, ("negative mnt_ref")); \ (mp)->mnt_ref--; \ if ((mp)->mnt_ref == 0) \ wakeup((mp)); \ From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 22:42:28 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B74FC106567A; Thu, 19 Apr 2012 22:42:28 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A0BA38FC18; Thu, 19 Apr 2012 22:42:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JMgS5e010679; Thu, 19 Apr 2012 22:42:28 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JMgSpR010675; Thu, 19 Apr 2012 22:42:28 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204192242.q3JMgSpR010675@svn.freebsd.org> From: Kirk McKusick Date: Thu, 19 Apr 2012 22:42:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234473 - in stable/9/sys: i386/conf kern sys ufs/ffs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 22:42:29 -0000 Author: mckusick Date: Thu Apr 19 22:42:28 2012 New Revision: 234473 URL: http://svn.freebsd.org/changeset/base/234473 Log: MFC of 234158: Export vinactive() from kern/vfs_subr.c (e.g., make it no longer static and declare its prototype in sys/vnode.h) so that it can be called from process_deferred_inactive() (in ufs/ffs/ffs_snapshot.c) instead of the body of vinactive() being cut and pasted into process_deferred_inactive(). Reviewed by: kib MFC after: 2 weeks Modified: stable/9/sys/kern/vfs_subr.c stable/9/sys/sys/vnode.h stable/9/sys/ufs/ffs/ffs_snapshot.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/kern/vfs_subr.c ============================================================================== --- stable/9/sys/kern/vfs_subr.c Thu Apr 19 22:37:24 2012 (r234472) +++ stable/9/sys/kern/vfs_subr.c Thu Apr 19 22:42:28 2012 (r234473) @@ -103,7 +103,6 @@ static int flushbuflist(struct bufv *buf static void syncer_shutdown(void *arg, int howto); static int vtryrecycle(struct vnode *vp); static void vbusy(struct vnode *vp); -static void vinactive(struct vnode *, struct thread *); static void v_incr_usecount(struct vnode *); static void v_decr_usecount(struct vnode *); static void v_decr_useonly(struct vnode *); @@ -2401,7 +2400,7 @@ vdropl(struct vnode *vp) * OWEINACT tracks whether a vnode missed a call to inactive due to a * failed lock upgrade. */ -static void +void vinactive(struct vnode *vp, struct thread *td) { Modified: stable/9/sys/sys/vnode.h ============================================================================== --- stable/9/sys/sys/vnode.h Thu Apr 19 22:37:24 2012 (r234472) +++ stable/9/sys/sys/vnode.h Thu Apr 19 22:42:28 2012 (r234473) @@ -635,6 +635,7 @@ int vget(struct vnode *vp, int lockflag, void vgone(struct vnode *vp); void vhold(struct vnode *); void vholdl(struct vnode *); +void vinactive(struct vnode *, struct thread *); int vinvalbuf(struct vnode *vp, int save, int slpflag, int slptimeo); int vtruncbuf(struct vnode *vp, struct ucred *cred, struct thread *td, off_t length, int blksize); Modified: stable/9/sys/ufs/ffs/ffs_snapshot.c ============================================================================== --- stable/9/sys/ufs/ffs/ffs_snapshot.c Thu Apr 19 22:37:24 2012 (r234472) +++ stable/9/sys/ufs/ffs/ffs_snapshot.c Thu Apr 19 22:42:28 2012 (r234473) @@ -2572,20 +2572,9 @@ process_deferred_inactive(struct mount * MNT_ILOCK(mp); continue; } - - VNASSERT((vp->v_iflag & VI_DOINGINACT) == 0, vp, - ("process_deferred_inactive: " - "recursed on VI_DOINGINACT")); - vp->v_iflag |= VI_DOINGINACT; - vp->v_iflag &= ~VI_OWEINACT; - VI_UNLOCK(vp); - (void) VOP_INACTIVE(vp, td); - VI_LOCK(vp); - VNASSERT(vp->v_iflag & VI_DOINGINACT, vp, - ("process_deferred_inactive: lost VI_DOINGINACT")); + vinactive(vp, td); VNASSERT((vp->v_iflag & VI_OWEINACT) == 0, vp, ("process_deferred_inactive: got VI_OWEINACT")); - vp->v_iflag &= ~VI_DOINGINACT; VI_UNLOCK(vp); VOP_UNLOCK(vp, 0); vdrop(vp); From owner-svn-src-all@FreeBSD.ORG Thu Apr 19 23:04:36 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A6FF3106564A; Thu, 19 Apr 2012 23:04:36 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 913558FC08; Thu, 19 Apr 2012 23:04:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3JN4aLP011468; Thu, 19 Apr 2012 23:04:36 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3JN4aFH011464; Thu, 19 Apr 2012 23:04:36 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204192304.q3JN4aFH011464@svn.freebsd.org> From: Kirk McKusick Date: Thu, 19 Apr 2012 23:04:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234474 - in stable/8/sys: i386/conf kern sys ufs/ffs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Apr 2012 23:04:36 -0000 Author: mckusick Date: Thu Apr 19 23:04:35 2012 New Revision: 234474 URL: http://svn.freebsd.org/changeset/base/234474 Log: MFC of 234158: Export vinactive() from kern/vfs_subr.c (e.g., make it no longer static and declare its prototype in sys/vnode.h) so that it can be called from process_deferred_inactive() (in ufs/ffs/ffs_snapshot.c) instead of the body of vinactive() being cut and pasted into process_deferred_inactive(). Reviewed by: kib Modified: stable/8/sys/kern/vfs_subr.c stable/8/sys/sys/vnode.h stable/8/sys/ufs/ffs/ffs_snapshot.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/e1000/ (props changed) stable/8/sys/i386/conf/XENHVM (props changed) Modified: stable/8/sys/kern/vfs_subr.c ============================================================================== --- stable/8/sys/kern/vfs_subr.c Thu Apr 19 22:42:28 2012 (r234473) +++ stable/8/sys/kern/vfs_subr.c Thu Apr 19 23:04:35 2012 (r234474) @@ -103,7 +103,6 @@ static int flushbuflist(struct bufv *buf static void syncer_shutdown(void *arg, int howto); static int vtryrecycle(struct vnode *vp); static void vbusy(struct vnode *vp); -static void vinactive(struct vnode *, struct thread *); static void v_incr_usecount(struct vnode *); static void v_decr_usecount(struct vnode *); static void v_decr_useonly(struct vnode *); @@ -2404,7 +2403,7 @@ vdropl(struct vnode *vp) * OWEINACT tracks whether a vnode missed a call to inactive due to a * failed lock upgrade. */ -static void +void vinactive(struct vnode *vp, struct thread *td) { Modified: stable/8/sys/sys/vnode.h ============================================================================== --- stable/8/sys/sys/vnode.h Thu Apr 19 22:42:28 2012 (r234473) +++ stable/8/sys/sys/vnode.h Thu Apr 19 23:04:35 2012 (r234474) @@ -637,6 +637,7 @@ int vget(struct vnode *vp, int lockflag, void vgone(struct vnode *vp); void vhold(struct vnode *); void vholdl(struct vnode *); +void vinactive(struct vnode *, struct thread *); int vinvalbuf(struct vnode *vp, int save, int slpflag, int slptimeo); int vtruncbuf(struct vnode *vp, struct ucred *cred, struct thread *td, off_t length, int blksize); Modified: stable/8/sys/ufs/ffs/ffs_snapshot.c ============================================================================== --- stable/8/sys/ufs/ffs/ffs_snapshot.c Thu Apr 19 22:42:28 2012 (r234473) +++ stable/8/sys/ufs/ffs/ffs_snapshot.c Thu Apr 19 23:04:35 2012 (r234474) @@ -2441,20 +2441,9 @@ process_deferred_inactive(struct mount * MNT_ILOCK(mp); continue; } - - VNASSERT((vp->v_iflag & VI_DOINGINACT) == 0, vp, - ("process_deferred_inactive: " - "recursed on VI_DOINGINACT")); - vp->v_iflag |= VI_DOINGINACT; - vp->v_iflag &= ~VI_OWEINACT; - VI_UNLOCK(vp); - (void) VOP_INACTIVE(vp, td); - VI_LOCK(vp); - VNASSERT(vp->v_iflag & VI_DOINGINACT, vp, - ("process_deferred_inactive: lost VI_DOINGINACT")); + vinactive(vp, td); VNASSERT((vp->v_iflag & VI_OWEINACT) == 0, vp, ("process_deferred_inactive: got VI_OWEINACT")); - vp->v_iflag &= ~VI_DOINGINACT; VI_UNLOCK(vp); VOP_UNLOCK(vp, 0); vdrop(vp); From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 00:45:24 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5F1F41065672; Fri, 20 Apr 2012 00:45: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 476C58FC18; Fri, 20 Apr 2012 00:45:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3K0jOT4014826; Fri, 20 Apr 2012 00:45:24 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3K0jO65014820; Fri, 20 Apr 2012 00:45:24 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201204200045.q3K0jO65014820@svn.freebsd.org> From: Nathan Whitehorn Date: Fri, 20 Apr 2012 00:45:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234476 - in stable/9/sys: powerpc/aim vm X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 00:45:24 -0000 Author: nwhitehorn Date: Fri Apr 20 00:45:23 2012 New Revision: 234476 URL: http://svn.freebsd.org/changeset/base/234476 Log: MFC r233949,233957,233964,234149,234155: More PMAP concurrency and performance improvements by only flushing icaches when needed and executing ptesync only when architecturally required. Modified: stable/9/sys/powerpc/aim/machdep.c stable/9/sys/powerpc/aim/mmu_oea.c stable/9/sys/powerpc/aim/mmu_oea64.c stable/9/sys/powerpc/aim/moea64_native.c stable/9/sys/vm/vm_page.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/powerpc/aim/machdep.c ============================================================================== --- stable/9/sys/powerpc/aim/machdep.c Fri Apr 20 00:34:15 2012 (r234475) +++ stable/9/sys/powerpc/aim/machdep.c Fri Apr 20 00:45:23 2012 (r234476) @@ -400,6 +400,9 @@ powerpc_init(vm_offset_t startkernel, vm cacheline_size = 32; } + /* Make sure the kernel icache is valid before we go too much further */ + __syncicache((caddr_t)startkernel, endkernel - startkernel); + #ifndef __powerpc64__ /* * Figure out whether we need to use the 64 bit PMAP. This works by Modified: stable/9/sys/powerpc/aim/mmu_oea.c ============================================================================== --- stable/9/sys/powerpc/aim/mmu_oea.c Fri Apr 20 00:34:15 2012 (r234475) +++ stable/9/sys/powerpc/aim/mmu_oea.c Fri Apr 20 00:45:23 2012 (r234476) @@ -1055,7 +1055,7 @@ moea_enter_locked(pmap_t pmap, vm_offset struct pvo_head *pvo_head; uma_zone_t zone; vm_page_t pg; - u_int pte_lo, pvo_flags, was_exec; + u_int pte_lo, pvo_flags; int error; if (!moea_initialized) { @@ -1063,13 +1063,11 @@ moea_enter_locked(pmap_t pmap, vm_offset zone = moea_upvo_zone; pvo_flags = 0; pg = NULL; - was_exec = PTE_EXEC; } else { pvo_head = vm_page_to_pvoh(m); pg = m; zone = moea_mpvo_zone; pvo_flags = PVO_MANAGED; - was_exec = 0; } if (pmap_bootstrapped) mtx_assert(&vm_page_queue_mtx, MA_OWNED); @@ -1085,18 +1083,6 @@ moea_enter_locked(pmap_t pmap, vm_offset zone = moea_upvo_zone; } - /* - * If this is a managed page, and it's the first reference to the page, - * clear the execness of the page. Otherwise fetch the execness. - */ - if ((pg != NULL) && ((m->oflags & VPO_UNMANAGED) == 0)) { - if (LIST_EMPTY(pvo_head)) { - moea_attr_clear(pg, PTE_EXEC); - } else { - was_exec = moea_attr_fetch(pg) & PTE_EXEC; - } - } - pte_lo = moea_calc_wimg(VM_PAGE_TO_PHYS(m), pmap_page_get_memattr(m)); if (prot & VM_PROT_WRITE) { @@ -1117,22 +1103,14 @@ moea_enter_locked(pmap_t pmap, vm_offset pte_lo, pvo_flags); /* - * Flush the real page from the instruction cache if this page is - * mapped executable and cacheable and was not previously mapped (or - * was not mapped executable). + * Flush the real page from the instruction cache. This has be done + * for all user mappings to prevent information leakage via the + * instruction cache. moea_pvo_enter() returns ENOENT for the first + * mapping for a page. */ - if (error == 0 && (pvo_flags & PVO_EXECUTABLE) && - (pte_lo & PTE_I) == 0 && was_exec == 0) { - /* - * Flush the real memory from the cache. - */ + if (pmap != kernel_pmap && error == ENOENT && + (pte_lo & (PTE_I | PTE_G)) == 0) moea_syncicache(VM_PAGE_TO_PHYS(m), PAGE_SIZE); - if (pg != NULL) - moea_attr_save(pg, PTE_EXEC); - } - - /* XXX syncicache always until problems are sorted */ - moea_syncicache(VM_PAGE_TO_PHYS(m), PAGE_SIZE); } /* @@ -1454,12 +1432,6 @@ moea_kenter_attr(mmu_t mmu, vm_offset_t panic("moea_kenter: failed to enter va %#x pa %#x: %d", va, pa, error); - /* - * Flush the real memory from the instruction cache. - */ - if ((pte_lo & (PTE_I | PTE_G)) == 0) { - moea_syncicache(pa, PAGE_SIZE); - } PMAP_UNLOCK(kernel_pmap); } Modified: stable/9/sys/powerpc/aim/mmu_oea64.c ============================================================================== --- stable/9/sys/powerpc/aim/mmu_oea64.c Fri Apr 20 00:34:15 2012 (r234475) +++ stable/9/sys/powerpc/aim/mmu_oea64.c Fri Apr 20 00:45:23 2012 (r234476) @@ -283,8 +283,6 @@ static struct pvo_entry *moea64_pvo_find /* * Utility routines. */ -static void moea64_enter_locked(mmu_t, pmap_t, vm_offset_t, - vm_page_t, vm_prot_t, boolean_t); static boolean_t moea64_query_bit(mmu_t, vm_page_t, u_int64_t); static u_int moea64_clear_bit(mmu_t, vm_page_t, u_int64_t); static void moea64_kremove(mmu_t, vm_offset_t); @@ -1167,30 +1165,11 @@ moea64_zero_page_idle(mmu_t mmu, vm_page * target pmap with the protection requested. If specified the page * will be wired down. */ + void moea64_enter(mmu_t mmu, pmap_t pmap, vm_offset_t va, vm_page_t m, vm_prot_t prot, boolean_t wired) { - - LOCK_TABLE_WR(); - PMAP_LOCK(pmap); - moea64_enter_locked(mmu, pmap, va, m, prot, wired); - UNLOCK_TABLE_WR(); - PMAP_UNLOCK(pmap); -} - -/* - * Map the given physical page at the specified virtual address in the - * target pmap with the protection requested. If specified the page - * will be wired down. - * - * The table (write) and pmap must be locked. - */ - -static void -moea64_enter_locked(mmu_t mmu, pmap_t pmap, vm_offset_t va, vm_page_t m, - vm_prot_t prot, boolean_t wired) -{ struct pvo_head *pvo_head; uma_zone_t zone; vm_page_t pg; @@ -1210,10 +1189,9 @@ moea64_enter_locked(mmu_t mmu, pmap_t pm pvo_flags = PVO_MANAGED; } - PMAP_LOCK_ASSERT(pmap, MA_OWNED); KASSERT((m->oflags & (VPO_UNMANAGED | VPO_BUSY)) != 0 || VM_OBJECT_LOCKED(m->object), - ("moea64_enter_locked: page %p is not busy", m)); + ("moea64_enter: page %p is not busy", m)); /* XXX change the pvo head for fake pages */ if ((m->oflags & VPO_UNMANAGED) != 0) { @@ -1238,15 +1216,22 @@ moea64_enter_locked(mmu_t mmu, pmap_t pm if (wired) pvo_flags |= PVO_WIRED; + LOCK_TABLE_WR(); + PMAP_LOCK(pmap); error = moea64_pvo_enter(mmu, pmap, zone, pvo_head, va, VM_PAGE_TO_PHYS(m), pte_lo, pvo_flags); + PMAP_UNLOCK(pmap); + UNLOCK_TABLE_WR(); /* * Flush the page from the instruction cache if this page is * mapped executable and cacheable. */ - if ((pte_lo & (LPTE_I | LPTE_G | LPTE_NOEXEC)) == 0) + if (pmap != kernel_pmap && !(m->aflags & PGA_EXECUTABLE) && + (pte_lo & (LPTE_I | LPTE_G | LPTE_NOEXEC)) == 0) { + vm_page_aflag_set(m, PGA_EXECUTABLE); moea64_syncicache(mmu, pmap, va, VM_PAGE_TO_PHYS(m), PAGE_SIZE); + } } static void @@ -1307,15 +1292,11 @@ moea64_enter_object(mmu_t mmu, pmap_t pm psize = atop(end - start); m = m_start; - LOCK_TABLE_WR(); - PMAP_LOCK(pm); while (m != NULL && (diff = m->pindex - m_start->pindex) < psize) { - moea64_enter_locked(mmu, pm, start + ptoa(diff), m, prot & + moea64_enter(mmu, pm, start + ptoa(diff), m, prot & (VM_PROT_READ | VM_PROT_EXECUTE), FALSE); m = TAILQ_NEXT(m, listq); } - UNLOCK_TABLE_WR(); - PMAP_UNLOCK(pm); } void @@ -1323,12 +1304,8 @@ moea64_enter_quick(mmu_t mmu, pmap_t pm, vm_prot_t prot) { - LOCK_TABLE_WR(); - PMAP_LOCK(pm); - moea64_enter_locked(mmu, pm, va, m, + moea64_enter(mmu, pm, va, m, prot & (VM_PROT_READ | VM_PROT_EXECUTE), FALSE); - UNLOCK_TABLE_WR(); - PMAP_UNLOCK(pm); } vm_paddr_t @@ -1664,12 +1641,6 @@ moea64_kenter_attr(mmu_t mmu, vm_offset_ if (error != 0 && error != ENOENT) panic("moea64_kenter: failed to enter va %#zx pa %#zx: %d", va, pa, error); - - /* - * Flush the memory from the instruction cache. - */ - if ((pte_lo & (LPTE_I | LPTE_G)) == 0) - __syncicache((void *)va, PAGE_SIZE); } void @@ -1900,6 +1871,7 @@ static void moea64_pvo_protect(mmu_t mmu, pmap_t pm, struct pvo_entry *pvo, vm_prot_t prot) { uintptr_t pt; + struct vm_page *pg; uint64_t oldlo; PMAP_LOCK_ASSERT(pm, MA_OWNED); @@ -1923,18 +1895,20 @@ moea64_pvo_protect(mmu_t mmu, pmap_t pm else pvo->pvo_pte.lpte.pte_lo |= LPTE_BR; + pg = PHYS_TO_VM_PAGE(pvo->pvo_pte.lpte.pte_lo & LPTE_RPGN); + /* * If the PVO is in the page table, update that pte as well. */ - if (pt != -1) { + if (pt != -1) MOEA64_PTE_CHANGE(mmu, pt, &pvo->pvo_pte.lpte, pvo->pvo_vpn); - if ((pvo->pvo_pte.lpte.pte_lo & - (LPTE_I | LPTE_G | LPTE_NOEXEC)) == 0) { - moea64_syncicache(mmu, pm, PVO_VADDR(pvo), - pvo->pvo_pte.lpte.pte_lo & LPTE_RPGN, - PAGE_SIZE); - } + if (pm != kernel_pmap && pg != NULL && !(pg->aflags & PGA_EXECUTABLE) && + (pvo->pvo_pte.lpte.pte_lo & (LPTE_I | LPTE_G | LPTE_NOEXEC)) == 0) { + if ((pg->oflags & VPO_UNMANAGED) == 0) + vm_page_aflag_set(pg, PGA_EXECUTABLE); + moea64_syncicache(mmu, pm, PVO_VADDR(pvo), + pvo->pvo_pte.lpte.pte_lo & LPTE_RPGN, PAGE_SIZE); } /* @@ -1943,9 +1917,6 @@ moea64_pvo_protect(mmu_t mmu, pmap_t pm */ if ((pvo->pvo_vaddr & PVO_MANAGED) == PVO_MANAGED && (oldlo & LPTE_PP) != LPTE_BR && !(prot && VM_PROT_WRITE)) { - struct vm_page *pg; - - pg = PHYS_TO_VM_PAGE(pvo->pvo_pte.lpte.pte_lo & LPTE_RPGN); if (pg != NULL) { if (pvo->pvo_pte.lpte.pte_lo & LPTE_CHG) vm_page_dirty(pg); @@ -2128,15 +2099,11 @@ moea64_remove(mmu_t mmu, pmap_t pm, vm_o void moea64_remove_all(mmu_t mmu, vm_page_t m) { - struct pvo_head *pvo_head; struct pvo_entry *pvo, *next_pvo; pmap_t pmap; - pvo_head = vm_page_to_pvoh(m); LOCK_TABLE_WR(); - for (pvo = LIST_FIRST(pvo_head); pvo != NULL; pvo = next_pvo) { - next_pvo = LIST_NEXT(pvo, pvo_vlink); - + LIST_FOREACH_SAFE(pvo, vm_page_to_pvoh(m), pvo_vlink, next_pvo) { pmap = pvo->pvo_pmap; PMAP_LOCK(pmap); moea64_pvo_remove(mmu, pvo); @@ -2146,6 +2113,7 @@ moea64_remove_all(mmu_t mmu, vm_page_t m if ((m->aflags & PGA_WRITEABLE) && moea64_is_modified(mmu, m)) vm_page_dirty(m); vm_page_aflag_clear(m, PGA_WRITEABLE); + vm_page_aflag_clear(m, PGA_EXECUTABLE); } /* @@ -2350,6 +2318,7 @@ moea64_pvo_enter(mmu_t mmu, pmap_t pm, u static void moea64_pvo_remove(mmu_t mmu, struct pvo_entry *pvo) { + struct vm_page *pg; uintptr_t pt; PMAP_LOCK_ASSERT(pvo->pvo_pmap, MA_OWNED); @@ -2389,12 +2358,10 @@ moea64_pvo_remove(mmu_t mmu, struct pvo_ /* * Update vm about the REF/CHG bits if the page is managed. */ - if ((pvo->pvo_vaddr & PVO_MANAGED) == PVO_MANAGED && - (pvo->pvo_pte.lpte.pte_lo & LPTE_PP) != LPTE_BR) { - struct vm_page *pg; + pg = PHYS_TO_VM_PAGE(pvo->pvo_pte.lpte.pte_lo & LPTE_RPGN); - pg = PHYS_TO_VM_PAGE(pvo->pvo_pte.lpte.pte_lo & LPTE_RPGN); - if (pg != NULL) { + if ((pvo->pvo_vaddr & PVO_MANAGED) == PVO_MANAGED && pg != NULL) { + if ((pvo->pvo_pte.lpte.pte_lo & LPTE_PP) != LPTE_BR) { if (pvo->pvo_pte.lpte.pte_lo & LPTE_CHG) vm_page_dirty(pg); if (pvo->pvo_pte.lpte.pte_lo & LPTE_REF) @@ -2402,6 +2369,8 @@ moea64_pvo_remove(mmu_t mmu, struct pvo_ if (LIST_EMPTY(vm_page_to_pvoh(pg))) vm_page_aflag_clear(pg, PGA_WRITEABLE); } + if (LIST_EMPTY(vm_page_to_pvoh(pg))) + vm_page_aflag_clear(pg, PGA_EXECUTABLE); } moea64_pvo_entries--; Modified: stable/9/sys/powerpc/aim/moea64_native.c ============================================================================== --- stable/9/sys/powerpc/aim/moea64_native.c Fri Apr 20 00:34:15 2012 (r234475) +++ stable/9/sys/powerpc/aim/moea64_native.c Fri Apr 20 00:45:23 2012 (r234476) @@ -153,13 +153,10 @@ TLBIE(uint64_t vpn) { vpn &= ~(0xffffULL << 48); #ifdef __powerpc64__ - sched_pin(); - __asm __volatile("ptesync"); mtx_lock(&tlbie_mutex); __asm __volatile("tlbie %0" :: "r"(vpn) : "memory"); mtx_unlock(&tlbie_mutex); __asm __volatile("eieio; tlbsync; ptesync"); - sched_unpin(); #else vpn_hi = (uint32_t)(vpn >> 32); vpn_lo = (uint32_t)vpn; @@ -171,7 +168,6 @@ TLBIE(uint64_t vpn) { mr %1, %0; \ insrdi %1,%5,1,0; \ mtmsrd %1; isync; \ - ptesync; \ \ sld %1,%2,%4; \ or %1,%1,%3; \ @@ -265,7 +261,9 @@ moea64_pte_clear_native(mmu_t mmu, uintp * As shown in Section 7.6.3.2.3 */ pt->pte_lo &= ~ptebit; + sched_pin(); TLBIE(vpn); + sched_unpin(); } static void @@ -295,21 +293,16 @@ moea64_pte_unset_native(mmu_t mmu, uintp { struct lpte *pt = (struct lpte *)pt_cookie; - pvo_pt->pte_hi &= ~LPTE_VALID; - - /* Finish all pending operations */ - isync(); - - /* - * Force the reg & chg bits back into the PTEs. - */ - SYNC(); - /* * Invalidate the pte. */ + isync(); + sched_pin(); + pvo_pt->pte_hi &= ~LPTE_VALID; pt->pte_hi &= ~LPTE_VALID; + PTESYNC(); TLBIE(vpn); + sched_unpin(); /* * Save the reg & chg bits. Modified: stable/9/sys/vm/vm_page.h ============================================================================== --- stable/9/sys/vm/vm_page.h Fri Apr 20 00:34:15 2012 (r234475) +++ stable/9/sys/vm/vm_page.h Fri Apr 20 00:45:23 2012 (r234476) @@ -248,9 +248,13 @@ extern struct vpglocks pa_lock[]; * * PGA_WRITEABLE is set exclusively on managed pages by pmap_enter(). When it * does so, the page must be VPO_BUSY. + * + * PGA_EXECUTABLE may be set by pmap routines, and indicates that a page has + * at least one executable mapping. It is not consumed by the VM layer. */ #define PGA_WRITEABLE 0x01 /* page may be mapped writeable */ #define PGA_REFERENCED 0x02 /* page has been referenced */ +#define PGA_EXECUTABLE 0x04 /* page may be mapped executable */ /* * Page flags. If changed at any other time than page allocation or From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 03:11:43 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 65FE0106566B; Fri, 20 Apr 2012 03:11:43 +0000 (UTC) (envelope-from conrads@cox.net) Received: from eastrmfepo102.cox.net (eastrmfepo102.cox.net [68.230.241.214]) by mx1.freebsd.org (Postfix) with ESMTP id B42F78FC08; Fri, 20 Apr 2012 03:11:42 +0000 (UTC) Received: from eastrmimpo109.cox.net ([68.230.241.222]) by eastrmfepo102.cox.net (InterMail vM.8.01.04.00 201-2260-137-20101110) with ESMTP id <20120420031142.OQWU26743.eastrmfepo102.cox.net@eastrmimpo109.cox.net>; Thu, 19 Apr 2012 23:11:42 -0400 Received: from serene.no-ip.org ([98.164.83.206]) by eastrmimpo109.cox.net with bizsmtp id 03Bg1j0054T5sES023BhdP; Thu, 19 Apr 2012 23:11:41 -0400 X-CT-Class: Clean X-CT-Score: 0.00 X-CT-RefID: str=0001.0A020207.4F90D3ED.008F,ss=1,re=0.000,fgs=0 X-CT-Spam: 0 X-Authority-Analysis: v=1.1 cv=oCnpYUhdmvqPuxLMq7fsn3FqY3je+Ql30gwju2dxGGE= c=1 sm=1 a=N17yZKeAuoQA:10 a=G8Uczd0VNMoA:10 a=N659UExz7-8A:10 a=cRs4AX/51puMaUeRAuoQtw==:17 a=6I5d2MoRAAAA:8 a=kviXuzpPAAAA:8 a=xZUYSu7jEuJQdHkjCekA:9 a=34ZU6qr-9c-gozTNuREA:7 a=pILNOxqGKmIA:10 a=SV7veod9ZcQA:10 a=4vB-4DCPJfMA:10 a=cRs4AX/51puMaUeRAuoQtw==:117 X-CM-Score: 0.00 Authentication-Results: cox.net; none Received: from cox.net (localhost [127.0.0.1]) by serene.no-ip.org (8.14.5/8.14.5) with ESMTP id q3K3Bdu4066311; Thu, 19 Apr 2012 22:11:39 -0500 (CDT) (envelope-from conrads@cox.net) Date: Thu, 19 Apr 2012 22:11:34 -0500 From: "Conrad J. Sabatier" To: Jason Evans Message-ID: <20120419221134.76128edc@cox.net> In-Reply-To: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> <20120419091558.2ae655a0@cox.net> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.6; amd64-portbld-freebsd10.0) Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Cc: svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 03:11:43 -0000 On Thu, 19 Apr 2012 15:23:39 -0700 Jason Evans wrote: > On Apr 19, 2012, at 11:44 AM, Jason Evans wrote: > > On Apr 19, 2012, at 7:15 AM, Conrad J. Sabatier wrote: > >> Actually, I keep getting "undefined reference to _malloc_options" > >> while building libexec/atrun on amd64. Not sure what the problem > >> may be. Could it have something to do with doing a debug build > >> (with -g)? > >> > >> ===> libexec/atrun (all) > >> […] > >> -lutil /usr/obj/usr/src/tmp/usr/lib/libc.so: undefined reference to > >> `_malloc_options' clang: error: linker command failed with exit > >> code 1 (use -v to see invocation) *** [atrun] Error code 1 > > > > Perhaps this is related to using clang rather than gcc. I'll start > > a clang-based buildworld to see if it reproduces here. > > > > Jason > > > With /etc/make.conf as: > > CFLAGS+=-g > STRIP= > CC=clang > CXX=clang++ > CPP=clang-cpp > > I got this buildworld failure: > --- > clang -O2 -pipe -g -I/usr/src/lib/csu/amd64/../common > -I/usr/src/lib/csu/amd64/../../libc/include -fno-omit-frame-pointer > -std=gnu99 -Qunused-arguments -Wsystem-headers -Werror -Wall > -Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes > -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual > -Wwrite-strin gs -Wswitch -Wshadow -Wunused-parameter -Wcast-align > -Wchar-subscripts -Winline -Wnested-externs -Wredundant-decls > -Wold-style-definition -Wno-pointer-sign -Wno-empty-body > -Wno-string-plus-int -c -o crt1.o crt1.scrt1.s:8:2: error: input > can't have .file dwarf directives when -g is used to generate dwarf > debug info for assembly code .file 1 > "/usr/src/lib/csu/amd64/crt1.c" ^ crt1.s:8:8: error: file > number already allocated .file 1 > "/usr/src/lib/csu/amd64/crt1.c" ^crt1.s:9:2: error: input can't > have .file dwarf directives when -g is used to generate dwarf debug > info for assembly code .file 2 > "/usr/src/lib/csu/amd64/../common/crtbrand.c" ^crt1.s:10:2: > error: input can't have .file dwarf directives when -g is used to > generate dwarf debug info for assembly code .file 3 > "/usr/src/lib/csu/amd64/../common/ignore_init.c" ^ --- > > I removed the CFLAGS+=-g line, and buildworld succeeded. > > Jason Yes, I've seen exactly the same on other, earlier builds (I've been using essentially exactly the same make.conf settings as what you just posted, as well as using "make -j8"). That other error output I posted earlier in this thread resulted after I had already seen the above, and tried another buildworld without -j8. So, apparently, the thing to do for now is *not* attempt to build a debug world, it would seem. I suspected as much. :-) Thank you very much for giving your attention to this matter. -- Conrad J. Sabatier conrads@cox.net From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 04:40:40 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 285D61065673; Fri, 20 Apr 2012 04:40:40 +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 12D428FC0A; Fri, 20 Apr 2012 04:40:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3K4ed9D022610; Fri, 20 Apr 2012 04:40:39 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3K4edlW022608; Fri, 20 Apr 2012 04:40:39 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201204200440.q3K4edlW022608@svn.freebsd.org> From: Xin LI Date: Fri, 20 Apr 2012 04:40: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: r234481 - head/sys/modules/iscsi/initiator X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 04:40:40 -0000 Author: delphij Date: Fri Apr 20 04:40:39 2012 New Revision: 234481 URL: http://svn.freebsd.org/changeset/base/234481 Log: Fix build. Modified: head/sys/modules/iscsi/initiator/Makefile Modified: head/sys/modules/iscsi/initiator/Makefile ============================================================================== --- head/sys/modules/iscsi/initiator/Makefile Fri Apr 20 03:12:02 2012 (r234480) +++ head/sys/modules/iscsi/initiator/Makefile Fri Apr 20 04:40:39 2012 (r234481) @@ -1,18 +1,14 @@ # $FreeBSD$ -S= ${.CURDIR}/../../.. -.PATH: $S/dev/iscsi/initiator - +.PATH: ${.CURDIR}/../../../dev/iscsi/initiator KMOD=iscsi_initiator SRCS= iscsi.h iscsivar.h SRCS+= iscsi.c isc_cam.c isc_soc.c isc_sm.c isc_subr.c iscsi_subr.c SRCS+= opt_cam.h opt_iscsi_initiator.h SRCS+= bus_if.h device_if.h -#CFLAGS+= -DNO_USE_MBUF -CFLAGS+= -DISCSI_INITIATOR_DEBUG=2 -#CFLAGS+= -DISCSI_INITIATOR_DEBUG=2 -CFLAGS+= -DINVARIANTS -CFLAGS+= -I$S -CFLAGS+= -DINVARIANTS + +# Debugging +# CFLAGS+= -DISCSI_INITIATOR_DEBUG=9 + .include From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 06:50:45 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 14126106566B; Fri, 20 Apr 2012 06:50:45 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id F161F8FC12; Fri, 20 Apr 2012 06:50:44 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3K6oiBF026680; Fri, 20 Apr 2012 06:50:44 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3K6oiqO026673; Fri, 20 Apr 2012 06:50:44 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204200650.q3K6oiqO026673@svn.freebsd.org> From: Kirk McKusick Date: Fri, 20 Apr 2012 06:50: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: r234482 - in head/sys: fs/msdosfs fs/nfsserver kern sys X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 06:50:45 -0000 Author: mckusick Date: Fri Apr 20 06:50:44 2012 New Revision: 234482 URL: http://svn.freebsd.org/changeset/base/234482 Log: This change creates a new list of active vnodes associated with a mount point. Active vnodes are those with a non-zero use or hold count, e.g., those vnodes that are not on the free list. Note that this list is in addition to the list of all the vnodes associated with a mount point. To avoid adding another set of linkage pointers to the vnode structure, the active list uses the existing linkage pointers used by the free list (previously named v_freelist, now renamed v_actfreelist). This update adds the MNT_VNODE_FOREACH_ACTIVE interface that loops over just the active vnodes associated with a mount point (typically less than 1% of the vnodes associated with the mount point). Reviewed by: kib Tested by: Peter Holm MFC after: 2 weeks Modified: head/sys/fs/msdosfs/msdosfs_vfsops.c head/sys/fs/nfsserver/nfs_nfsdport.c head/sys/kern/vfs_mount.c head/sys/kern/vfs_subr.c head/sys/sys/mount.h head/sys/sys/vnode.h Modified: head/sys/fs/msdosfs/msdosfs_vfsops.c ============================================================================== --- head/sys/fs/msdosfs/msdosfs_vfsops.c Fri Apr 20 04:40:39 2012 (r234481) +++ head/sys/fs/msdosfs/msdosfs_vfsops.c Fri Apr 20 06:50:44 2012 (r234482) @@ -834,7 +834,7 @@ msdosfs_unmount(struct mount *mp, int mn vn_printf(vp, "msdosfs_umount(): just before calling VOP_CLOSE()\n"); printf("freef %p, freeb %p, mount %p\n", - TAILQ_NEXT(vp, v_freelist), vp->v_freelist.tqe_prev, + TAILQ_NEXT(vp, v_actfreelist), vp->v_actfreelist.tqe_prev, vp->v_mount); printf("cleanblkhd %p, dirtyblkhd %p, numoutput %ld, type %d\n", TAILQ_FIRST(&vp->v_bufobj.bo_clean.bv_hd), Modified: head/sys/fs/nfsserver/nfs_nfsdport.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdport.c Fri Apr 20 04:40:39 2012 (r234481) +++ head/sys/fs/nfsserver/nfs_nfsdport.c Fri Apr 20 06:50:44 2012 (r234482) @@ -2907,12 +2907,14 @@ nfsd_mntinit(void) inited = 1; nfsv4root_mnt.mnt_flag = (MNT_RDONLY | MNT_EXPORTED); TAILQ_INIT(&nfsv4root_mnt.mnt_nvnodelist); + TAILQ_INIT(&nfsv4root_mnt.mnt_activevnodelist); nfsv4root_mnt.mnt_export = NULL; TAILQ_INIT(&nfsv4root_opt); TAILQ_INIT(&nfsv4root_newopt); nfsv4root_mnt.mnt_opt = &nfsv4root_opt; nfsv4root_mnt.mnt_optnew = &nfsv4root_newopt; nfsv4root_mnt.mnt_nvnodelistsize = 0; + nfsv4root_mnt.mnt_activevnodelistsize = 0; } /* Modified: head/sys/kern/vfs_mount.c ============================================================================== --- head/sys/kern/vfs_mount.c Fri Apr 20 04:40:39 2012 (r234481) +++ head/sys/kern/vfs_mount.c Fri Apr 20 06:50:44 2012 (r234482) @@ -461,6 +461,8 @@ vfs_mount_alloc(struct vnode *vp, struct __rangeof(struct mount, mnt_startzero, mnt_endzero)); TAILQ_INIT(&mp->mnt_nvnodelist); mp->mnt_nvnodelistsize = 0; + TAILQ_INIT(&mp->mnt_activevnodelist); + mp->mnt_activevnodelistsize = 0; mp->mnt_ref = 0; (void) vfs_busy(mp, MBF_NOWAIT); mp->mnt_op = vfsp->vfc_vfsops; @@ -514,6 +516,8 @@ vfs_mount_destroy(struct mount *mp) } if (mp->mnt_nvnodelistsize != 0) panic("vfs_mount_destroy: nonzero nvnodelistsize"); + if (mp->mnt_activevnodelistsize != 0) + panic("vfs_mount_destroy: nonzero activevnodelistsize"); if (mp->mnt_lockref != 0) panic("vfs_mount_destroy: nonzero lock refcount"); MNT_IUNLOCK(mp); Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Fri Apr 20 04:40:39 2012 (r234481) +++ head/sys/kern/vfs_subr.c Fri Apr 20 06:50:44 2012 (r234482) @@ -775,12 +775,16 @@ vnlru_free(int count) break; VNASSERT(vp->v_op != NULL, vp, ("vnlru_free: vnode already reclaimed.")); - TAILQ_REMOVE(&vnode_free_list, vp, v_freelist); + KASSERT((vp->v_iflag & VI_FREE) != 0, + ("Removing vnode not on freelist")); + KASSERT((vp->v_iflag & VI_ACTIVE) == 0, + ("Mangling active vnode")); + TAILQ_REMOVE(&vnode_free_list, vp, v_actfreelist); /* * Don't recycle if we can't get the interlock. */ if (!VI_TRYLOCK(vp)) { - TAILQ_INSERT_TAIL(&vnode_free_list, vp, v_freelist); + TAILQ_INSERT_TAIL(&vnode_free_list, vp, v_actfreelist); continue; } VNASSERT(VCANRECYCLE(vp), vp, @@ -1035,12 +1039,26 @@ static void delmntque(struct vnode *vp) { struct mount *mp; + int active; mp = vp->v_mount; if (mp == NULL) return; MNT_ILOCK(mp); + VI_LOCK(vp); + KASSERT(mp->mnt_activevnodelistsize <= mp->mnt_nvnodelistsize, + ("Active vnode list size %d > Vnode list size %d", + mp->mnt_activevnodelistsize, mp->mnt_nvnodelistsize)); + active = vp->v_iflag & VI_ACTIVE; + vp->v_iflag &= ~VI_ACTIVE; + if (active) { + mtx_lock(&vnode_free_list_mtx); + TAILQ_REMOVE(&mp->mnt_activevnodelist, vp, v_actfreelist); + mp->mnt_activevnodelistsize--; + mtx_unlock(&vnode_free_list_mtx); + } vp->v_mount = NULL; + VI_UNLOCK(vp); VNASSERT(mp->mnt_nvnodelistsize > 0, vp, ("bad mount point vnode list size")); TAILQ_REMOVE(&mp->mnt_nvnodelist, vp, v_nmntvnodes); @@ -1080,13 +1098,24 @@ insmntque1(struct vnode *vp, struct moun ASSERT_VOP_ELOCKED(vp, "insmntque: mp-safe fs and non-locked vp"); #endif + /* + * We acquire the vnode interlock early to ensure that the + * vnode cannot be recycled by another process releasing a + * holdcnt on it before we get it on both the vnode list + * and the active vnode list. The mount mutex protects only + * manipulation of the vnode list and the vnode freelist + * mutex protects only manipulation of the active vnode list. + * Hence the need to hold the vnode interlock throughout. + */ MNT_ILOCK(mp); + VI_LOCK(vp); if ((mp->mnt_kern_flag & MNTK_NOINSMNTQ) != 0 && ((mp->mnt_kern_flag & MNTK_UNMOUNTF) != 0 || mp->mnt_nvnodelistsize == 0)) { locked = VOP_ISLOCKED(vp); if (!locked || (locked == LK_EXCLUSIVE && (vp->v_vflag & VV_FORCEINSMQ) == 0)) { + VI_UNLOCK(vp); MNT_IUNLOCK(mp); if (dtr != NULL) dtr(vp, dtr_arg); @@ -1099,6 +1128,14 @@ insmntque1(struct vnode *vp, struct moun VNASSERT(mp->mnt_nvnodelistsize >= 0, vp, ("neg mount point vnode list size")); mp->mnt_nvnodelistsize++; + KASSERT((vp->v_iflag & VI_ACTIVE) == 0, + ("Activating already active vnode")); + vp->v_iflag |= VI_ACTIVE; + mtx_lock(&vnode_free_list_mtx); + TAILQ_INSERT_HEAD(&mp->mnt_activevnodelist, vp, v_actfreelist); + mp->mnt_activevnodelistsize++; + mtx_unlock(&vnode_free_list_mtx); + VI_UNLOCK(vp); MNT_IUNLOCK(mp); return (0); } @@ -2309,6 +2346,7 @@ vhold(struct vnode *vp) void vholdl(struct vnode *vp) { + struct mount *mp; CTR2(KTR_VFS, "%s: vp %p", __func__, vp); vp->v_holdcnt++; @@ -2318,12 +2356,19 @@ vholdl(struct vnode *vp) VNASSERT((vp->v_iflag & VI_FREE) != 0, vp, ("vnode not free")); VNASSERT(vp->v_op != NULL, vp, ("vholdl: vnode already reclaimed.")); /* - * Remove a vnode from the free list and mark it as in use. + * Remove a vnode from the free list, mark it as in use, + * and put it on the active list. */ mtx_lock(&vnode_free_list_mtx); - TAILQ_REMOVE(&vnode_free_list, vp, v_freelist); + TAILQ_REMOVE(&vnode_free_list, vp, v_actfreelist); freevnodes--; vp->v_iflag &= ~(VI_FREE|VI_AGE); + KASSERT((vp->v_iflag & VI_ACTIVE) == 0, + ("Activating already active vnode")); + vp->v_iflag |= VI_ACTIVE; + mp = vp->v_mount; + TAILQ_INSERT_HEAD(&mp->mnt_activevnodelist, vp, v_actfreelist); + mp->mnt_activevnodelistsize++; mtx_unlock(&vnode_free_list_mtx); } @@ -2348,6 +2393,8 @@ void vdropl(struct vnode *vp) { struct bufobj *bo; + struct mount *mp; + int active; ASSERT_VI_LOCKED(vp, "vdropl"); CTR2(KTR_VFS, "%s: vp %p", __func__, vp); @@ -2360,19 +2407,28 @@ vdropl(struct vnode *vp) } if ((vp->v_iflag & VI_DOOMED) == 0) { /* - * Mark a vnode as free, putting it up for recycling. + * Mark a vnode as free: remove it from its active list + * and put it up for recycling on the freelist. */ - mtx_lock(&vnode_free_list_mtx); VNASSERT(vp->v_op != NULL, vp, ("vdropl: vnode already reclaimed.")); VNASSERT((vp->v_iflag & VI_FREE) == 0, vp, ("vnode already free")); VNASSERT(VSHOULDFREE(vp), vp, ("vdropl: freeing when we shouldn't")); + active = vp->v_iflag & VI_ACTIVE; + vp->v_iflag &= ~VI_ACTIVE; + mp = vp->v_mount; + mtx_lock(&vnode_free_list_mtx); + if (active) { + TAILQ_REMOVE(&mp->mnt_activevnodelist, vp, + v_actfreelist); + mp->mnt_activevnodelistsize--; + } if (vp->v_iflag & VI_AGE) { - TAILQ_INSERT_HEAD(&vnode_free_list, vp, v_freelist); + TAILQ_INSERT_HEAD(&vnode_free_list, vp, v_actfreelist); } else { - TAILQ_INSERT_TAIL(&vnode_free_list, vp, v_freelist); + TAILQ_INSERT_TAIL(&vnode_free_list, vp, v_actfreelist); } freevnodes++; vp->v_iflag &= ~VI_AGE; @@ -3010,6 +3066,8 @@ DB_SHOW_COMMAND(mount, db_show_mount) db_printf(" mnt_ref = %d\n", mp->mnt_ref); db_printf(" mnt_gen = %d\n", mp->mnt_gen); db_printf(" mnt_nvnodelistsize = %d\n", mp->mnt_nvnodelistsize); + db_printf(" mnt_activevnodelistsize = %d\n", + mp->mnt_activevnodelistsize); db_printf(" mnt_writeopcount = %d\n", mp->mnt_writeopcount); db_printf(" mnt_maxsymlinklen = %d\n", mp->mnt_maxsymlinklen); db_printf(" mnt_iosize_max = %d\n", mp->mnt_iosize_max); @@ -3019,15 +3077,23 @@ DB_SHOW_COMMAND(mount, db_show_mount) mp->mnt_secondary_accwrites); db_printf(" mnt_gjprovider = %s\n", mp->mnt_gjprovider != NULL ? mp->mnt_gjprovider : "NULL"); - db_printf("\n"); - TAILQ_FOREACH(vp, &mp->mnt_nvnodelist, v_nmntvnodes) { + db_printf("\n\nList of active vnodes\n"); + TAILQ_FOREACH(vp, &mp->mnt_activevnodelist, v_actfreelist) { if (vp->v_type != VMARKER) { vn_printf(vp, "vnode "); if (db_pager_quit) break; } } + db_printf("\n\nList of inactive vnodes\n"); + TAILQ_FOREACH(vp, &mp->mnt_nvnodelist, v_nmntvnodes) { + if (vp->v_type != VMARKER && (vp->v_iflag & VI_ACTIVE) == 0) { + vn_printf(vp, "vnode "); + if (db_pager_quit) + break; + } + } } #endif /* DDB */ @@ -4558,3 +4624,100 @@ __mnt_vnode_markerfree_all(struct vnode free(*mvp, M_VNODE_MARKER); *mvp = NULL; } + +/* + * These are helper functions for filesystems to traverse their + * active vnodes. See MNT_VNODE_FOREACH_ACTIVE() in sys/mount.h + */ +struct vnode * +__mnt_vnode_next_active(struct vnode **mvp, struct mount *mp) +{ + struct vnode *vp, *nvp; + + if (should_yield()) + kern_yield(PRI_UNCHANGED); + MNT_ILOCK(mp); + KASSERT((*mvp)->v_mount == mp, ("marker vnode mount list mismatch")); + vp = TAILQ_NEXT(*mvp, v_actfreelist); + while (vp != NULL) { + VI_LOCK(vp); + if (vp->v_mount == mp && vp->v_type != VMARKER && + (vp->v_iflag & VI_DOOMED) == 0) + break; + nvp = TAILQ_NEXT(vp, v_actfreelist); + VI_UNLOCK(vp); + vp = nvp; + } + + /* Check if we are done */ + if (vp == NULL) { + __mnt_vnode_markerfree_active(mvp, mp); + /* MNT_IUNLOCK(mp); -- done in above function */ + mtx_assert(MNT_MTX(mp), MA_NOTOWNED); + return (NULL); + } + mtx_lock(&vnode_free_list_mtx); + TAILQ_REMOVE(&mp->mnt_activevnodelist, *mvp, v_actfreelist); + TAILQ_INSERT_AFTER(&mp->mnt_activevnodelist, vp, *mvp, v_actfreelist); + mtx_unlock(&vnode_free_list_mtx); + MNT_IUNLOCK(mp); + return (vp); +} + +struct vnode * +__mnt_vnode_first_active(struct vnode **mvp, struct mount *mp) +{ + struct vnode *vp, *nvp; + + *mvp = malloc(sizeof(struct vnode), M_VNODE_MARKER, M_WAITOK | M_ZERO); + MNT_ILOCK(mp); + MNT_REF(mp); + (*mvp)->v_type = VMARKER; + + vp = TAILQ_NEXT(*mvp, v_actfreelist); + while (vp != NULL) { + VI_LOCK(vp); + if (vp->v_mount == mp && vp->v_type != VMARKER && + (vp->v_iflag & VI_DOOMED) == 0) + break; + nvp = TAILQ_NEXT(vp, v_actfreelist); + VI_UNLOCK(vp); + vp = nvp; + } + + /* Check if we are done */ + if (vp == NULL) { + MNT_REL(mp); + MNT_IUNLOCK(mp); + free(*mvp, M_VNODE_MARKER); + *mvp = NULL; + return (NULL); + } + (*mvp)->v_mount = mp; + mtx_lock(&vnode_free_list_mtx); + TAILQ_INSERT_AFTER(&mp->mnt_activevnodelist, vp, *mvp, v_actfreelist); + mtx_unlock(&vnode_free_list_mtx); + MNT_IUNLOCK(mp); + return (vp); +} + +void +__mnt_vnode_markerfree_active(struct vnode **mvp, struct mount *mp) +{ + + if (*mvp == NULL) { + MNT_IUNLOCK(mp); + return; + } + + mtx_assert(MNT_MTX(mp), MA_OWNED); + + KASSERT((*mvp)->v_mount == mp, ("marker vnode mount list mismatch")); + mtx_lock(&vnode_free_list_mtx); + TAILQ_REMOVE(&mp->mnt_activevnodelist, *mvp, v_actfreelist); + mtx_unlock(&vnode_free_list_mtx); + MNT_REL(mp); + MNT_IUNLOCK(mp); + free(*mvp, M_VNODE_MARKER); + *mvp = NULL; +} Modified: head/sys/sys/mount.h ============================================================================== --- head/sys/sys/mount.h Fri Apr 20 04:40:39 2012 (r234481) +++ head/sys/sys/mount.h Fri Apr 20 06:50:44 2012 (r234482) @@ -164,6 +164,8 @@ struct mount { int mnt_ref; /* (i) Reference count */ struct vnodelst mnt_nvnodelist; /* (i) list of vnodes */ int mnt_nvnodelistsize; /* (i) # of vnodes */ + struct vnodelst mnt_activevnodelist; /* (i) list of active vnodes */ + int mnt_activevnodelistsize;/* (i) # of active vnodes */ int mnt_writeopcount; /* (i) write syscalls pending */ int mnt_kern_flag; /* (i) kernel only flags */ uint64_t mnt_flag; /* (i) flags shared with user */ @@ -207,6 +209,25 @@ void __mnt_vnode_markerfree_all } while (0) /* + * Definitions for MNT_VNODE_FOREACH_ACTIVE. + */ +struct vnode *__mnt_vnode_next_active(struct vnode **mvp, struct mount *mp); +struct vnode *__mnt_vnode_first_active(struct vnode **mvp, struct mount *mp); +void __mnt_vnode_markerfree_active(struct vnode **mvp, struct mount *); + +#define MNT_VNODE_FOREACH_ACTIVE(vp, mp, mvp) \ + for (vp = __mnt_vnode_first_active(&(mvp), (mp)); \ + (vp) != NULL; vp = __mnt_vnode_next_active(&(mvp), (mp))) + +#define MNT_VNODE_FOREACH_ACTIVE_ABORT(mp, mvp) \ + do { \ + MNT_ILOCK(mp); \ + __mnt_vnode_markerfree_active(&(mvp), (mp)); \ + /* MNT_IUNLOCK(mp); -- done in above function */ \ + mtx_assert(MNT_MTX(mp), MA_NOTOWNED); \ + } while (0) + +/* * Definitions for MNT_VNODE_FOREACH. * * This interface has been deprecated in favor of MNT_VNODE_FOREACH_ALL. Modified: head/sys/sys/vnode.h ============================================================================== --- head/sys/sys/vnode.h Fri Apr 20 04:40:39 2012 (r234481) +++ head/sys/sys/vnode.h Fri Apr 20 06:50:44 2012 (r234482) @@ -156,7 +156,7 @@ struct vnode { /* * The machinery of being a vnode */ - TAILQ_ENTRY(vnode) v_freelist; /* f vnode freelist */ + TAILQ_ENTRY(vnode) v_actfreelist; /* f vnode active/free lists */ struct bufobj v_bufobj; /* * Buffer cache object */ /* @@ -232,6 +232,7 @@ struct xvnode { #define VI_AGE 0x0040 /* Insert vnode at head of free list */ #define VI_DOOMED 0x0080 /* This vnode is being recycled */ #define VI_FREE 0x0100 /* This vnode is on the freelist */ +#define VI_ACTIVE 0x0200 /* This vnode is on the active list */ #define VI_DOINGINACT 0x0800 /* VOP_INACTIVE is in progress */ #define VI_OWEINACT 0x1000 /* Need to call inactive */ From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 07:00:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B6D501065678; Fri, 20 Apr 2012 07:00:29 +0000 (UTC) (envelope-from mckusick@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A14638FC08; Fri, 20 Apr 2012 07:00:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3K70T27027036; Fri, 20 Apr 2012 07:00:29 GMT (envelope-from mckusick@svn.freebsd.org) Received: (from mckusick@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3K70TNk027030; Fri, 20 Apr 2012 07:00:29 GMT (envelope-from mckusick@svn.freebsd.org) Message-Id: <201204200700.q3K70TNk027030@svn.freebsd.org> From: Kirk McKusick Date: Fri, 20 Apr 2012 07:00: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: r234483 - in head/sys: kern ufs/ffs ufs/ufs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 07:00:29 -0000 Author: mckusick Date: Fri Apr 20 07:00:28 2012 New Revision: 234483 URL: http://svn.freebsd.org/changeset/base/234483 Log: This update uses the MNT_VNODE_FOREACH_ACTIVE interface that loops over just the active vnodes associated with a mount point to replace MNT_VNODE_FOREACH_ALL in the vfs_msync, ffs_sync_lazy, and qsync routines. The vfs_msync routine is run every 30 seconds for every writably mounted filesystem. It ensures that any files mmap'ed from the filesystem with modified pages have those pages queued to be written back to the file from which they are mapped. The ffs_lazy_sync and qsync routines are run every 30 seconds for every writably mounted UFS/FFS filesystem. The ffs_lazy_sync routine ensures that any files that have been accessed in the previous 30 seconds have had their access times queued for updating in the filesystem. The qsync routine ensures that any files with modified quotas have those quotas queued to be written back to their associated quota file. In a system configured with 250,000 vnodes, less than 1000 are typically active at any point in time. Prior to this change all 250,000 vnodes would be locked and inspected twice every minute by the syncer. For UFS/FFS filesystems they would be locked and inspected six times every minute (twice by each of these three routines since each of these routines does its own pass over the vnodes associated with a mount point). With this change the syncer now locks and inspects only the tiny set of vnodes that are active. Reviewed by: kib Tested by: Peter Holm MFC after: 2 weeks Modified: head/sys/kern/vfs_subr.c head/sys/ufs/ffs/ffs_vfsops.c head/sys/ufs/ufs/quota.h head/sys/ufs/ufs/ufs_inode.c head/sys/ufs/ufs/ufs_quota.c Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Fri Apr 20 06:50:44 2012 (r234482) +++ head/sys/kern/vfs_subr.c Fri Apr 20 07:00:28 2012 (r234483) @@ -2484,6 +2484,7 @@ vdropl(struct vnode *vp) void vinactive(struct vnode *vp, struct thread *td) { + struct vm_object *obj; ASSERT_VOP_ELOCKED(vp, "vinactive"); ASSERT_VI_LOCKED(vp, "vinactive"); @@ -2493,6 +2494,17 @@ vinactive(struct vnode *vp, struct threa vp->v_iflag |= VI_DOINGINACT; vp->v_iflag &= ~VI_OWEINACT; VI_UNLOCK(vp); + /* + * Before moving off the active list, we must be sure that any + * modified pages are on the vnode's dirty list since these will + * no longer be checked once the vnode is on the inactive list. + */ + obj = vp->v_object; + if (obj != NULL && (obj->flags & OBJ_MIGHTBEDIRTY) != 0) { + VM_OBJECT_LOCK(obj); + vm_object_page_clean(obj, 0, 0, OBJPC_NOSYNC); + VM_OBJECT_UNLOCK(obj); + } VOP_INACTIVE(vp, td); VI_LOCK(vp); VNASSERT(vp->v_iflag & VI_DOINGINACT, vp, @@ -3362,7 +3374,7 @@ vfs_msync(struct mount *mp, int flags) struct vm_object *obj; CTR2(KTR_VFS, "%s: mp %p", __func__, mp); - MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { + MNT_VNODE_FOREACH_ACTIVE(vp, mp, mvp) { obj = vp->v_object; if (obj != NULL && (obj->flags & OBJ_MIGHTBEDIRTY) != 0 && (flags == MNT_WAIT || VOP_ISLOCKED(vp) == 0)) { Modified: head/sys/ufs/ffs/ffs_vfsops.c ============================================================================== --- head/sys/ufs/ffs/ffs_vfsops.c Fri Apr 20 06:50:44 2012 (r234482) +++ head/sys/ufs/ffs/ffs_vfsops.c Fri Apr 20 07:00:28 2012 (r234483) @@ -1432,7 +1432,7 @@ ffs_sync_lazy(mp) td = curthread; if ((mp->mnt_flag & MNT_NOATIME) != 0) goto qupdate; - MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { + MNT_VNODE_FOREACH_ACTIVE(vp, mp, mvp) { if (vp->v_type == VNON) { VI_UNLOCK(vp); continue; Modified: head/sys/ufs/ufs/quota.h ============================================================================== --- head/sys/ufs/ufs/quota.h Fri Apr 20 06:50:44 2012 (r234482) +++ head/sys/ufs/ufs/quota.h Fri Apr 20 07:00:28 2012 (r234483) @@ -227,9 +227,10 @@ void dqinit(void); void dqrele(struct vnode *, struct dquot *); void dquninit(void); int getinoquota(struct inode *); -int qsync(struct mount *mp); -int quotaoff(struct thread *td, struct mount *, int); -int quotaon(struct thread *td, struct mount *, int, void *); +int qsync(struct mount *); +int qsyncvp(struct vnode *); +int quotaoff(struct thread *, struct mount *, int); +int quotaon(struct thread *, struct mount *, int, void *); int getquota32(struct thread *, struct mount *, u_long, int, void *); int setquota32(struct thread *, struct mount *, u_long, int, void *); int setuse32(struct thread *, struct mount *, u_long, int, void *); Modified: head/sys/ufs/ufs/ufs_inode.c ============================================================================== --- head/sys/ufs/ufs/ufs_inode.c Fri Apr 20 06:50:44 2012 (r234482) +++ head/sys/ufs/ufs/ufs_inode.c Fri Apr 20 07:00:28 2012 (r234483) @@ -88,6 +88,14 @@ ufs_inactive(ap) #ifdef UFS_GJOURNAL ufs_gjournal_close(vp); #endif +#ifdef QUOTA + /* + * Before moving off the active list, we must be sure that + * any modified quotas have been pushed since these will no + * longer be checked once the vnode is on the inactive list. + */ + qsyncvp(vp); +#endif if ((ip->i_effnlink == 0 && DOINGSOFTDEP(vp)) || (ip->i_nlink <= 0 && !UFS_RDONLY(ip))) { loop: Modified: head/sys/ufs/ufs/ufs_quota.c ============================================================================== --- head/sys/ufs/ufs/ufs_quota.c Fri Apr 20 06:50:44 2012 (r234482) +++ head/sys/ufs/ufs/ufs_quota.c Fri Apr 20 07:00:28 2012 (r234483) @@ -1044,7 +1044,7 @@ qsync(struct mount *mp) * synchronizing any modified dquot structures. */ again: - MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { + MNT_VNODE_FOREACH_ACTIVE(vp, mp, mvp) { if (vp->v_type == VNON) { VI_UNLOCK(vp); continue; @@ -1068,6 +1068,39 @@ again: } /* + * Sync quota file for given vnode to disk. + */ +int +qsyncvp(struct vnode *vp) +{ + struct ufsmount *ump = VFSTOUFS(vp->v_mount); + struct dquot *dq; + int i; + + /* + * Check if the mount point has any quotas. + * If not, simply return. + */ + UFS_LOCK(ump); + for (i = 0; i < MAXQUOTAS; i++) + if (ump->um_quotas[i] != NULLVP) + break; + UFS_UNLOCK(ump); + if (i == MAXQUOTAS) + return (0); + /* + * Search quotas associated with this vnode + * synchronizing any modified dquot structures. + */ + for (i = 0; i < MAXQUOTAS; i++) { + dq = VTOI(vp)->i_dquot[i]; + if (dq != NODQUOT) + dqsync(vp, dq); + } + return (0); +} + +/* * Code pertaining to management of the in-core dquot data structures. */ #define DQHASH(dqvp, id) \ From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 08:26:05 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CE208106566B; Fri, 20 Apr 2012 08:26:05 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AD4588FC08; Fri, 20 Apr 2012 08:26:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3K8Q5JR029784; Fri, 20 Apr 2012 08:26:05 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3K8Q5bY029779; Fri, 20 Apr 2012 08:26:05 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204200826.q3K8Q5bY029779@svn.freebsd.org> From: Adrian Chadd Date: Fri, 20 Apr 2012 08:26: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: r234485 - head/sys/mips/atheros X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 08:26:05 -0000 Author: adrian Date: Fri Apr 20 08:26:05 2012 New Revision: 234485 URL: http://svn.freebsd.org/changeset/base/234485 Log: Introduce the matching PCI ath(4) fixup code from ar71xx_pci into ar724x_pci.c. * Move out the code which populates the firmware into ar71xx_fixup.c * Shuffle around the ar724x fixup code to match what the ar71xx fixup code does. I've validated this on an AR7240 with AR9285 on-board NIC. It doesn't yet load, as the AR9285 EEPROM code needs to be made "flash aware." TODO: * Validate that I haven't broken AR71xx * Test AR9285/AR9287 onboard NICs, complete with EEPROM code changes * Port over the needed BAR hacks for AR7240, AR7241 and AR7242 from Linux OpenWRT. The current WAR has only been tested on the AR7240 and I'm not sure the way the BAR register is treated is "right". The "fixup" method here is right when setting the BAR for local access - ie, the BAR address is either 0xffff (AR7240) or 0x1000ffff (AR7241/AR7242), but the ath9k-fixup.c code (Linux OpenWRT) does this when setting the initial "fixup" BAR. It then restores the original BAR. I'll have to read the ar724x PCI bus glue to see what other special cases await. Added: head/sys/mips/atheros/ar71xx_fixup.c (contents, props changed) head/sys/mips/atheros/ar71xx_fixup.h (contents, props changed) Modified: head/sys/mips/atheros/ar71xx_pci.c head/sys/mips/atheros/ar724x_pci.c head/sys/mips/atheros/files.ar71xx Added: head/sys/mips/atheros/ar71xx_fixup.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/mips/atheros/ar71xx_fixup.c Fri Apr 20 08:26:05 2012 (r234485) @@ -0,0 +1,153 @@ +/*- + * Copyright (c) 2009, Oleksandr Tymoshenko + * 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 unmodified, 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 "opt_ar71xx.h" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include +#include +#include +#include + +#include +#include + +#include +#include "pcib_if.h" + +#include +#include + +#include + +#include +#include + +#include + +/* + * Take a copy of the EEPROM contents and squirrel it away in a firmware. + * The SPI flash will eventually cease to be memory-mapped, so we need + * to take a copy of this before the SPI driver initialises. + */ +void +ar71xx_pci_slot_create_eeprom_firmware(device_t dev, u_int bus, u_int slot, + u_int func, long int flash_addr, int size) +{ + char buf[64]; + uint16_t *cal_data = (uint16_t *) MIPS_PHYS_TO_KSEG1(flash_addr); + void *eeprom = NULL; + const struct firmware *fw = NULL; + + device_printf(dev, "EEPROM firmware: 0x%lx @ %d bytes\n", + flash_addr, size); + + eeprom = malloc(size, M_DEVBUF, M_WAITOK | M_ZERO); + if (! eeprom) { + device_printf(dev, + "%s: malloc failed for '%s', aborting EEPROM\n", + __func__, buf); + return; + } + + memcpy(eeprom, cal_data, size); + + /* + * Generate a flash EEPROM 'firmware' from the given memory + * region. Since the SPI controller will eventually + * go into port-IO mode instead of memory-mapped IO + * mode, a copy of the EEPROM contents is required. + */ + snprintf(buf, sizeof(buf), "%s.%d.bus.%d.%d.%d.eeprom_firmware", + device_get_name(dev), device_get_unit(dev), bus, slot, func); + fw = firmware_register(buf, eeprom, size, 1, NULL); + if (fw == NULL) { + device_printf(dev, "%s: firmware_register (%s) failed\n", + __func__, buf); + free(eeprom, M_DEVBUF); + return; + } + device_printf(dev, "device EEPROM '%s' registered\n", buf); +} + +#if 0 +static void +ar71xx_pci_slot_fixup(device_t dev, u_int bus, u_int slot, u_int func) +{ + long int flash_addr; + char buf[64]; + int size; + + /* + * Check whether the given slot has a hint to poke. + */ + if (bootverbose) + device_printf(dev, "%s: checking dev %s, %d/%d/%d\n", + __func__, device_get_nameunit(dev), bus, slot, func); + + snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_addr", + bus, slot, func); + + if (resource_long_value(device_get_name(dev), device_get_unit(dev), + buf, &flash_addr) == 0) { + snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_size", + bus, slot, func); + if (resource_int_value(device_get_name(dev), + device_get_unit(dev), buf, &size) != 0) { + device_printf(dev, + "%s: missing hint '%s', aborting EEPROM\n", + __func__, buf); + return; + } + + + device_printf(dev, "found EEPROM at 0x%lx on %d.%d.%d\n", + flash_addr, bus, slot, func); + ar71xx_pci_fixup(dev, bus, slot, func, flash_addr, size); + ar71xx_pci_slot_create_eeprom_firmware(dev, bus, slot, func, + flash_addr, size); + } +} +#endif /* 0 */ Added: head/sys/mips/atheros/ar71xx_fixup.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/mips/atheros/ar71xx_fixup.h Fri Apr 20 08:26:05 2012 (r234485) @@ -0,0 +1,36 @@ +/*- + * Copyright (c) 2012, Adrian Chadd + * 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 unmodified, 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$ + */ + +#ifndef __ATHEROS_AR71XX_FIXUP_H__ +#define __ATHEROS_AR71XX_FIXUP_H__ + +extern void ar71xx_pci_slot_create_eeprom_firmware(device_t dev, + u_int bus, u_int slot, u_int func, long int flash_addr, int size); + +#endif /* __ATHEROS_AR71XX_FIXUP_H__ */ Modified: head/sys/mips/atheros/ar71xx_pci.c ============================================================================== --- head/sys/mips/atheros/ar71xx_pci.c Fri Apr 20 07:24:54 2012 (r234484) +++ head/sys/mips/atheros/ar71xx_pci.c Fri Apr 20 08:26:05 2012 (r234485) @@ -63,8 +63,7 @@ __FBSDID("$FreeBSD$"); #include #ifdef AR71XX_ATH_EEPROM -#include -#include +#include #endif /* AR71XX_ATH_EEPROM */ #undef AR71XX_PCI_DEBUG @@ -288,7 +287,7 @@ ar71xx_pci_write_config(device_t dev, u_ */ static void ar71xx_pci_fixup(device_t dev, u_int bus, u_int slot, u_int func, - long flash_addr) + long flash_addr, int len) { uint16_t *cal_data = (uint16_t *) MIPS_PHYS_TO_KSEG1(flash_addr); uint32_t reg, val, bar0; @@ -328,67 +327,12 @@ ar71xx_pci_fixup(device_t dev, u_int bus ar71xx_pci_write_config(dev, bus, slot, func, PCIR_BAR(0), bar0, 4); } -/* - * Take a copy of the EEPROM contents and squirrel it away in a firmware. - * The SPI flash will eventually cease to be memory-mapped, so we need - * to take a copy of this before the SPI driver initialises. - */ -static void -ar71xx_pci_slot_create_eeprom_firmware(device_t dev, u_int bus, u_int slot, - u_int func, long int flash_addr) -{ - char buf[64]; - uint16_t *cal_data = (uint16_t *) MIPS_PHYS_TO_KSEG1(flash_addr); - void *eeprom = NULL; - const struct firmware *fw = NULL; - int len; - - snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_size", - bus, slot, func); - - if (resource_int_value(device_get_name(dev), device_get_unit(dev), - buf, &len) != 0) { - device_printf(dev, "%s: missing hint '%s', aborting EEPROM\n", - __func__, buf); - return; - } - - device_printf(dev, "EEPROM firmware: 0x%lx @ %d bytes\n", - flash_addr, len); - - eeprom = malloc(len, M_DEVBUF, M_WAITOK | M_ZERO); - if (! eeprom) { - device_printf(dev, - "%s: malloc failed for '%s', aborting EEPROM\n", - __func__, buf); - return; - } - - memcpy(eeprom, cal_data, len); - - /* - * Generate a flash EEPROM 'firmware' from the given memory - * region. Since the SPI controller will eventually - * go into port-IO mode instead of memory-mapped IO - * mode, a copy of the EEPROM contents is required. - */ - snprintf(buf, sizeof(buf), "%s.%d.bus.%d.%d.%d.eeprom_firmware", - device_get_name(dev), device_get_unit(dev), bus, slot, func); - fw = firmware_register(buf, eeprom, len, 1, NULL); - if (fw == NULL) { - device_printf(dev, "%s: firmware_register (%s) failed\n", - __func__, buf); - free(eeprom, M_DEVBUF); - return; - } - device_printf(dev, "device EEPROM '%s' registered\n", buf); -} - static void ar71xx_pci_slot_fixup(device_t dev, u_int bus, u_int slot, u_int func) { long int flash_addr; - char buf[32]; + char buf[64]; + int size; /* * Check whether the given slot has a hint to poke. @@ -396,16 +340,28 @@ ar71xx_pci_slot_fixup(device_t dev, u_in if (bootverbose) device_printf(dev, "%s: checking dev %s, %d/%d/%d\n", __func__, device_get_nameunit(dev), bus, slot, func); + snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_addr", bus, slot, func); if (resource_long_value(device_get_name(dev), device_get_unit(dev), buf, &flash_addr) == 0) { + snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_size", + bus, slot, func); + if (resource_int_value(device_get_name(dev), + device_get_unit(dev), buf, &size) != 0) { + device_printf(dev, + "%s: missing hint '%s', aborting EEPROM\n", + __func__, buf); + return; + } + + device_printf(dev, "found EEPROM at 0x%lx on %d.%d.%d\n", flash_addr, bus, slot, func); - ar71xx_pci_fixup(dev, bus, slot, func, flash_addr); + ar71xx_pci_fixup(dev, bus, slot, func, flash_addr, size); ar71xx_pci_slot_create_eeprom_firmware(dev, bus, slot, func, - flash_addr); + flash_addr, size); } } #endif /* AR71XX_ATH_EEPROM */ Modified: head/sys/mips/atheros/ar724x_pci.c ============================================================================== --- head/sys/mips/atheros/ar724x_pci.c Fri Apr 20 07:24:54 2012 (r234484) +++ head/sys/mips/atheros/ar724x_pci.c Fri Apr 20 08:26:05 2012 (r234485) @@ -29,6 +29,8 @@ #include __FBSDID("$FreeBSD$"); +#include "opt_ar71xx.h" + #include #include @@ -61,6 +63,10 @@ __FBSDID("$FreeBSD$"); #include +#ifdef AR71XX_ATH_EEPROM +#include +#endif /* AR71XX_ATH_EEPROM */ + #undef AR724X_PCI_DEBUG #ifdef AR724X_PCI_DEBUG #define dprintf printf @@ -243,27 +249,21 @@ ar724x_pci_setup(device_t dev) return (0); } +#ifdef AR71XX_ATH_EEPROM #define AR5416_EEPROM_MAGIC 0xa55a /* * XXX - This should not be here ! And this looks like Atheros (if_ath) only. */ static void -ar724x_load_eeprom_data(device_t dev) +ar724x_pci_fixup(device_t dev, long flash_addr, int len) { - uint32_t bar0, hint, reg, val; - uint16_t *data = NULL; - - /* Search for a hint of eeprom data offset */ - if (resource_int_value(device_get_name(dev), - device_get_unit(dev), "eepromdata", &hint) != 0) - return; - - device_printf(dev, "Loading the eeprom fixup data from %#x\n", hint); - data = (uint16_t *)MIPS_PHYS_TO_KSEG1(hint); + uint32_t bar0, reg, val; + uint16_t *cal_data = (uint16_t *) MIPS_PHYS_TO_KSEG1(flash_addr); - if (*data != AR5416_EEPROM_MAGIC) { - device_printf(dev, "Invalid calibration data from %#x\n", hint); + if (cal_data[0] != AR5416_EEPROM_MAGIC) { + device_printf(dev, "%s: Invalid calibration data from 0x%x\n", + __func__, (uintptr_t) flash_addr); return; } @@ -275,11 +275,14 @@ ar724x_load_eeprom_data(device_t dev) ar724x_pci_write_config(dev, 0, 0, 0, PCIR_COMMAND, val, 2); /* set pointer to first reg address */ - data += 3; - while (*data != 0xffff) { - reg = *data++; - val = *data++; - val |= (*data++) << 16; + cal_data += 3; + while (*cal_data != 0xffff) { + reg = *cal_data++; + val = *cal_data++; + val |= (*cal_data++) << 16; + + if (bootverbose) + printf(" 0x%08x=0x%04x\n", reg, val); /* Write eeprom fixup data to device memory */ ATH_WRITE_REG(AR71XX_PCI_MEM_BASE + reg, val); @@ -293,9 +296,51 @@ ar724x_load_eeprom_data(device_t dev) /* Write the saved bar(0) address */ ar724x_pci_write_config(dev, 0, 0, 0, PCIR_BAR(0), bar0, 4); } - #undef AR5416_EEPROM_MAGIC +/* + * XXX This is (mostly) duplicated with ar71xx_pci.c. + * It should at some point be fixed. + */ +static void +ar724x_pci_slot_fixup(device_t dev) +{ + long int flash_addr; + char buf[64]; + int size; + + /* + * Check whether the given slot has a hint to poke. + */ + if (bootverbose) + device_printf(dev, "%s: checking dev %s, %d/%d/%d\n", + __func__, device_get_nameunit(dev), 0, 0, 0); + + snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_addr", + 0, 0, 0); + + if (resource_long_value(device_get_name(dev), device_get_unit(dev), + buf, &flash_addr) == 0) { + snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_size", + 0, 0, 0); + if (resource_int_value(device_get_name(dev), + device_get_unit(dev), buf, &size) != 0) { + device_printf(dev, + "%s: missing hint '%s', aborting EEPROM\n", + __func__, buf); + return; + } + + + device_printf(dev, "found EEPROM at 0x%lx on %d.%d.%d\n", + flash_addr, 0, 0, 0); + ar724x_pci_fixup(dev, flash_addr, size); + ar71xx_pci_slot_create_eeprom_firmware(dev, 0, 0, 0, + flash_addr, size); + } +} +#endif /* AR71XX_ATH_EEPROM */ + static int ar724x_pci_probe(device_t dev) { @@ -357,8 +402,9 @@ ar724x_pci_attach(device_t dev) if (ar724x_pci_setup(dev)) return (ENXIO); - /* XXX - Load eeprom fixup data */ - ar724x_load_eeprom_data(dev); +#ifdef AR71XX_ATH_EEPROM + ar724x_pci_slot_fixup(dev); +#endif /* AR71XX_ATH_EEPROM */ /* Fixup internal PCI bridge */ ar724x_pci_write_config(dev, 0, 0, 0, PCIR_COMMAND, Modified: head/sys/mips/atheros/files.ar71xx ============================================================================== --- head/sys/mips/atheros/files.ar71xx Fri Apr 20 07:24:54 2012 (r234484) +++ head/sys/mips/atheros/files.ar71xx Fri Apr 20 08:26:05 2012 (r234485) @@ -21,5 +21,6 @@ mips/atheros/ar71xx_setup.c standard mips/atheros/ar71xx_chip.c standard mips/atheros/ar724x_chip.c standard mips/atheros/ar91xx_chip.c standard +mips/atheros/ar71xx_fixup.c optional ar71xx_ath_eeprom dev/hwpmc/hwpmc_mips24k.c optional hwpmc From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 08:57:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E18C9106566B; Fri, 20 Apr 2012 08:57:47 +0000 (UTC) (envelope-from melifaro@ipfw.ru) Received: from mail.ipfw.ru (unknown [IPv6:2a01:4f8:120:6141::2]) by mx1.freebsd.org (Postfix) with ESMTP id 7481A8FC08; Fri, 20 Apr 2012 08:57:47 +0000 (UTC) Received: from [2a02:6b8:0:401:222:4dff:fe50:cd2f] (helo=dhcp170-36-red.yandex.net) by mail.ipfw.ru with esmtpsa (TLSv1:CAMELLIA256-SHA:256) (Exim 4.76 (FreeBSD)) (envelope-from ) id 1SL9f7-0004Sc-OK; Fri, 20 Apr 2012 12:57:53 +0400 Message-ID: <4F91240C.3050703@ipfw.ru> Date: Fri, 20 Apr 2012 12:53:32 +0400 From: "Alexander V. Chernikov" User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:8.0) Gecko/20111117 Thunderbird/8.0 MIME-Version: 1.0 To: Adrian Chadd References: <201204060653.q366rwLa096182@svn.freebsd.org> <4F7E9413.20602@FreeBSD.org> <4F8BBD4E.1040106@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, freebsd-net@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r233937 - in head/sys: kern net security/mac X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 08:57:48 -0000 On 17.04.2012 01:29, Adrian Chadd wrote: > On 15 April 2012 23:33, Alexander V. Chernikov wrote: >> On 16.04.2012 01:17, Adrian Chadd wrote: >>> >>> Hi, >>> >>> This has broken (at least) net80211 and bpf, with LOR: >> >> Yes, it is. Please try the attached patch > > Hi, Hello! Sorry for the late reply, answering for both letters. > > This seems like a very, very complicated diff. > > * You've removed BPF_LOCK_ASSERT() inside bpf_detachd_locked() - why'd > you do that? > * You removed a comment ("We're already protected by the global lock") > which is still relevant/valid Both should be added back, thanks. > * There are lots of modifications to the read/write locks here - I'm > not sure whether they're at all relevant to my immediate problem and > may belong in separate commits Most of the patch is not directly relevant to the problem. It solves several new problems and a bunch of very old bugs due to lack of locking. > > Is there a document somewhere which describes what the "new" style BPF > locking should be? Are there any other places (except src) where such documentation should reside? > > I "just" added BPF_LOCK() / BPF_UNLOCK() around all the calls to > bpf_detachd() which weren't locked (there were a few.) Unfortunately, this is not enough. There is possibility that bpf_setif() is called immediately before rw_destroy() in bpfdetach(). For example, you can easily trigger panic on any 8/9/current SMP system with 'while true; do ifconfig vlan222 create vlan 222 vlandev em0 up ; tcpdump -pi vlan222 & ; ifconfig vlan222 destroy ; done' There is also possible use-after-free for bpfif structure (since we're freeing it _before_ interface routes are cleaned up). This is why delayed free is needed. > > One final question - should the BPF global lock be recursive? It seems it really should be recursive now. > > thanks, > > > > Adrian > From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 09:55:51 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 585BE106566B; Fri, 20 Apr 2012 09:55:51 +0000 (UTC) (envelope-from thompsa@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 434F88FC15; Fri, 20 Apr 2012 09:55:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3K9tpMu032780; Fri, 20 Apr 2012 09:55:51 GMT (envelope-from thompsa@svn.freebsd.org) Received: (from thompsa@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3K9toPQ032775; Fri, 20 Apr 2012 09:55:50 GMT (envelope-from thompsa@svn.freebsd.org) Message-Id: <201204200955.q3K9toPQ032775@svn.freebsd.org> From: Andrew Thompson Date: Fri, 20 Apr 2012 09:55:50 +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: r234487 - head/sys/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 09:55:51 -0000 Author: thompsa Date: Fri Apr 20 09:55:50 2012 New Revision: 234487 URL: http://svn.freebsd.org/changeset/base/234487 Log: Add linkstate to bridge(4), set the link to up when at least one underlying interface is up, otherwise the link is down. This, among other things, allows carp to work on a bridge. Prodded by: glebius Tested by: Alexander Lunev Modified: head/sys/net/bridgestp.c head/sys/net/bridgestp.h head/sys/net/if.c head/sys/net/if_bridge.c Modified: head/sys/net/bridgestp.c ============================================================================== --- head/sys/net/bridgestp.c Fri Apr 20 09:43:42 2012 (r234486) +++ head/sys/net/bridgestp.c Fri Apr 20 09:55:50 2012 (r234487) @@ -1767,28 +1767,16 @@ bstp_notify_rtage(void *arg, int pending } void -bstp_linkstate(struct ifnet *ifp, int state) +bstp_linkstate(struct bstp_port *bp) { - struct bstp_state *bs; - struct bstp_port *bp; + struct bstp_state *bs = bp->bp_bs; - /* search for the stp port */ - mtx_lock(&bstp_list_mtx); - LIST_FOREACH(bs, &bstp_list, bs_list) { - BSTP_LOCK(bs); - LIST_FOREACH(bp, &bs->bs_bplist, bp_next) { - if (bp->bp_ifp == ifp) { - bstp_ifupdstatus(bs, bp); - bstp_update_state(bs, bp); - /* it only exists once so return */ - BSTP_UNLOCK(bs); - mtx_unlock(&bstp_list_mtx); - return; - } - } - BSTP_UNLOCK(bs); + BSTP_LOCK(bs); + if (bp->bp_active) { + bstp_ifupdstatus(bs, bp); + bstp_update_state(bs, bp); } - mtx_unlock(&bstp_list_mtx); + BSTP_UNLOCK(bs); } static void @@ -2103,10 +2091,8 @@ bstp_modevent(module_t mod, int type, vo case MOD_LOAD: mtx_init(&bstp_list_mtx, "bridgestp list", NULL, MTX_DEF); LIST_INIT(&bstp_list); - bstp_linkstate_p = bstp_linkstate; break; case MOD_UNLOAD: - bstp_linkstate_p = NULL; mtx_destroy(&bstp_list_mtx); break; default: Modified: head/sys/net/bridgestp.h ============================================================================== --- head/sys/net/bridgestp.h Fri Apr 20 09:43:42 2012 (r234486) +++ head/sys/net/bridgestp.h Fri Apr 20 09:55:50 2012 (r234487) @@ -369,8 +369,6 @@ struct bstp_state { extern const uint8_t bstp_etheraddr[]; -extern void (*bstp_linkstate_p)(struct ifnet *ifp, int state); - void bstp_attach(struct bstp_state *, struct bstp_cb_ops *); void bstp_detach(struct bstp_state *); void bstp_init(struct bstp_state *); @@ -379,7 +377,7 @@ int bstp_create(struct bstp_state *, str int bstp_enable(struct bstp_port *); void bstp_disable(struct bstp_port *); void bstp_destroy(struct bstp_port *); -void bstp_linkstate(struct ifnet *, int); +void bstp_linkstate(struct bstp_port *); int bstp_set_htime(struct bstp_state *, int); int bstp_set_fdelay(struct bstp_state *, int); int bstp_set_maxage(struct bstp_state *, int); Modified: head/sys/net/if.c ============================================================================== --- head/sys/net/if.c Fri Apr 20 09:43:42 2012 (r234486) +++ head/sys/net/if.c Fri Apr 20 09:55:50 2012 (r234487) @@ -124,7 +124,7 @@ static MALLOC_DEFINE(M_IFDESCR, "ifdescr static struct sx ifdescr_sx; SX_SYSINIT(ifdescr_sx, &ifdescr_sx, "ifnet descr"); -void (*bstp_linkstate_p)(struct ifnet *ifp, int state); +void (*bridge_linkstate_p)(struct ifnet *ifp); void (*ng_ether_link_state_p)(struct ifnet *ifp, int state); void (*lagg_linkstate_p)(struct ifnet *ifp, int state); /* These are external hooks for CARP. */ @@ -1910,7 +1910,7 @@ do_link_state_change(void *arg, int pend if (ifp->if_carp) (*carp_linkstate_p)(ifp); if (ifp->if_bridge) - (*bstp_linkstate_p)(ifp, link_state); + (*bridge_linkstate_p)(ifp); if (ifp->if_lagg) (*lagg_linkstate_p)(ifp, link_state); Modified: head/sys/net/if_bridge.c ============================================================================== --- head/sys/net/if_bridge.c Fri Apr 20 09:43:42 2012 (r234486) +++ head/sys/net/if_bridge.c Fri Apr 20 09:55:50 2012 (r234487) @@ -333,6 +333,9 @@ static int bridge_ip6_checkbasic(struct #endif /* INET6 */ static int bridge_fragment(struct ifnet *, struct mbuf *, struct ether_header *, int, struct llc *); +static void bridge_linkstate(struct ifnet *ifp); + +extern void (*bridge_linkstate_p)(struct ifnet *ifp); /* The default bridge vlan is 1 (IEEE 802.1Q-2003 Table 9-2) */ #define VLANTAGOF(_m) \ @@ -496,6 +499,7 @@ bridge_modevent(module_t mod, int type, bridge_input_p = bridge_input; bridge_output_p = bridge_output; bridge_dn_p = bridge_dummynet; + bridge_linkstate_p = bridge_linkstate; bridge_detach_cookie = EVENTHANDLER_REGISTER( ifnet_departure_event, bridge_ifdetach, NULL, EVENTHANDLER_PRI_ANY); @@ -508,6 +512,7 @@ bridge_modevent(module_t mod, int type, bridge_input_p = NULL; bridge_output_p = NULL; bridge_dn_p = NULL; + bridge_linkstate_p = NULL; mtx_destroy(&bridge_list_mtx); break; default: @@ -988,6 +993,7 @@ bridge_delete_member(struct bridge_softc bridge_set_ifcap(sc, bif, bif->bif_savedcaps); } bstp_destroy(&bif->bif_stp); /* prepare to free */ + bridge_linkstate(ifs); BRIDGE_LOCK(sc); free(bif, M_DEVBUF); } @@ -1087,17 +1093,17 @@ bridge_ioctl_add(struct bridge_softc *sc /* Set interface capabilities to the intersection set of all members */ bridge_mutecaps(sc); + BRIDGE_UNLOCK(sc); + /* Update the linkstate for the bridge */ + bridge_linkstate(ifs); + /* Place the interface into promiscuous mode */ switch (ifs->if_type) { - case IFT_ETHER: - case IFT_L2VLAN: - /* - * Place the interface into promiscuous mode. - */ - BRIDGE_UNLOCK(sc); - error = ifpromisc(ifs, 1); - BRIDGE_LOCK(sc); - break; + case IFT_ETHER: + case IFT_L2VLAN: + error = ifpromisc(ifs, 1); + break; } + BRIDGE_LOCK(sc); if (error) bridge_delete_member(sc, bif, 0); out: @@ -3475,3 +3481,38 @@ out: m_freem(m); return (error); } + +static void +bridge_linkstate(struct ifnet *ifp) +{ + struct bridge_softc *sc = ifp->if_bridge; + struct bridge_iflist *bif, *bif2; + int new_link, hasls; + + BRIDGE_LOCK(sc); + bif = bridge_lookup_member_if(sc, ifp); + if (bif == NULL) { + BRIDGE_UNLOCK(sc); + return; + } + new_link = LINK_STATE_DOWN; + hasls = 0; + /* Our link is considered up if at least one of our ports is active */ + LIST_FOREACH(bif2, &sc->sc_iflist, bif_next) { + if (bif2->bif_ifp->if_capabilities & IFCAP_LINKSTATE) + hasls++; + if (bif2->bif_ifp->if_link_state == LINK_STATE_UP) { + new_link = LINK_STATE_UP; + break; + } + } + if (!LIST_EMPTY(&sc->sc_iflist) && !hasls) { + /* If no interfaces support link-state then we default to up */ + new_link = LINK_STATE_UP; + } + if_link_state_change(sc->sc_ifp, new_link); + BRIDGE_UNLOCK(sc); + + bstp_linkstate(&bif->bif_stp); +} + From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 10:06:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8D40C106566C; Fri, 20 Apr 2012 10:06:29 +0000 (UTC) (envelope-from thompsa@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6DF1D8FC14; Fri, 20 Apr 2012 10:06:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KA6TYx034504; Fri, 20 Apr 2012 10:06:29 GMT (envelope-from thompsa@svn.freebsd.org) Received: (from thompsa@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KA6T6B034501; Fri, 20 Apr 2012 10:06:29 GMT (envelope-from thompsa@svn.freebsd.org) Message-Id: <201204201006.q3KA6T6B034501@svn.freebsd.org> From: Andrew Thompson Date: Fri, 20 Apr 2012 10:06: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: r234488 - head/sys/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 10:06:29 -0000 Author: thompsa Date: Fri Apr 20 10:06:28 2012 New Revision: 234488 URL: http://svn.freebsd.org/changeset/base/234488 Log: Move the interface media check to a taskqueue, some interfaces (usb) sleep during SIOCGIFMEDIA and we were holding locks. Modified: head/sys/net/bridgestp.c head/sys/net/bridgestp.h Modified: head/sys/net/bridgestp.c ============================================================================== --- head/sys/net/bridgestp.c Fri Apr 20 09:55:50 2012 (r234487) +++ head/sys/net/bridgestp.c Fri Apr 20 10:06:28 2012 (r234488) @@ -127,7 +127,7 @@ static int bstp_rerooted(struct bstp_sta static uint32_t bstp_calc_path_cost(struct bstp_port *); static void bstp_notify_state(void *, int); static void bstp_notify_rtage(void *, int); -static void bstp_ifupdstatus(struct bstp_state *, struct bstp_port *); +static void bstp_ifupdstatus(void *, int); static void bstp_enable_port(struct bstp_state *, struct bstp_port *); static void bstp_disable_port(struct bstp_state *, struct bstp_port *); static void bstp_tick(void *); @@ -1677,7 +1677,7 @@ bstp_set_autoptp(struct bstp_port *bp, i if (set) { bp->bp_flags |= BSTP_PORT_AUTOPTP; if (bp->bp_role != BSTP_ROLE_DISABLED) - bstp_ifupdstatus(bs, bp); + taskqueue_enqueue(taskqueue_swi, &bp->bp_mediatask); } else bp->bp_flags &= ~BSTP_PORT_AUTOPTP; BSTP_UNLOCK(bs); @@ -1771,69 +1771,89 @@ bstp_linkstate(struct bstp_port *bp) { struct bstp_state *bs = bp->bp_bs; + if (!bp->bp_active) + return; + + bstp_ifupdstatus(bp, 0); BSTP_LOCK(bs); - if (bp->bp_active) { - bstp_ifupdstatus(bs, bp); - bstp_update_state(bs, bp); - } + bstp_update_state(bs, bp); BSTP_UNLOCK(bs); } static void -bstp_ifupdstatus(struct bstp_state *bs, struct bstp_port *bp) +bstp_ifupdstatus(void *arg, int pending) { + struct bstp_port *bp = (struct bstp_port *)arg; + struct bstp_state *bs = bp->bp_bs; struct ifnet *ifp = bp->bp_ifp; struct ifmediareq ifmr; - int error = 0; + int error, changed; - BSTP_LOCK_ASSERT(bs); + if (!bp->bp_active) + return; bzero((char *)&ifmr, sizeof(ifmr)); error = (*ifp->if_ioctl)(ifp, SIOCGIFMEDIA, (caddr_t)&ifmr); + BSTP_LOCK(bs); + changed = 0; if ((error == 0) && (ifp->if_flags & IFF_UP)) { if (ifmr.ifm_status & IFM_ACTIVE) { /* A full-duplex link is assumed to be point to point */ if (bp->bp_flags & BSTP_PORT_AUTOPTP) { - bp->bp_ptp_link = - ifmr.ifm_active & IFM_FDX ? 1 : 0; + int fdx; + + fdx = ifmr.ifm_active & IFM_FDX ? 1 : 0; + if (bp->bp_ptp_link ^ fdx) { + bp->bp_ptp_link = fdx; + changed = 1; + } } /* Calc the cost if the link was down previously */ if (bp->bp_flags & BSTP_PORT_PNDCOST) { - bp->bp_path_cost = bstp_calc_path_cost(bp); + uint32_t cost; + + cost = bstp_calc_path_cost(bp); + if (bp->bp_path_cost != cost) { + bp->bp_path_cost = cost; + changed = 1; + } bp->bp_flags &= ~BSTP_PORT_PNDCOST; } - if (bp->bp_role == BSTP_ROLE_DISABLED) + if (bp->bp_role == BSTP_ROLE_DISABLED) { bstp_enable_port(bs, bp); + changed = 1; + } } else { if (bp->bp_role != BSTP_ROLE_DISABLED) { bstp_disable_port(bs, bp); + changed = 1; if ((bp->bp_flags & BSTP_PORT_ADMEDGE) && bp->bp_protover == BSTP_PROTO_RSTP) bp->bp_operedge = 1; } } - return; - } - - if (bp->bp_infois != BSTP_INFO_DISABLED) + } else if (bp->bp_infois != BSTP_INFO_DISABLED) { bstp_disable_port(bs, bp); + changed = 1; + } + if (changed) + bstp_assign_roles(bs); + BSTP_UNLOCK(bs); } static void bstp_enable_port(struct bstp_state *bs, struct bstp_port *bp) { bp->bp_infois = BSTP_INFO_AGED; - bstp_assign_roles(bs); } static void bstp_disable_port(struct bstp_state *bs, struct bstp_port *bp) { bp->bp_infois = BSTP_INFO_DISABLED; - bstp_assign_roles(bs); } static void @@ -1853,7 +1873,7 @@ bstp_tick(void *arg) if (bstp_timer_dectest(&bs->bs_link_timer)) { LIST_FOREACH(bp, &bs->bs_bplist, bp_next) { if (!(bp->bp_ifp->if_capabilities & IFCAP_LINKSTATE)) - bstp_ifupdstatus(bs, bp); + taskqueue_enqueue(taskqueue_swi, &bp->bp_mediatask); } bstp_timer_start(&bs->bs_link_timer, BSTP_LINK_TIMER); } @@ -2063,7 +2083,7 @@ bstp_reinit(struct bstp_state *bs) LIST_FOREACH(bp, &bs->bs_bplist, bp_next) { bp->bp_port_id = (bp->bp_priority << 8) | (bp->bp_ifp->if_index & 0xfff); - bstp_ifupdstatus(bs, bp); + taskqueue_enqueue(taskqueue_swi, &bp->bp_mediatask); } bstp_assign_roles(bs); @@ -2184,6 +2204,7 @@ bstp_create(struct bstp_state *bs, struc bp->bp_priority = BSTP_DEFAULT_PORT_PRIORITY; TASK_INIT(&bp->bp_statetask, 0, bstp_notify_state, bp); TASK_INIT(&bp->bp_rtagetask, 0, bstp_notify_rtage, bp); + TASK_INIT(&bp->bp_mediatask, 0, bstp_ifupdstatus, bp); /* Init state */ bp->bp_infois = BSTP_INFO_DISABLED; @@ -2247,4 +2268,5 @@ bstp_destroy(struct bstp_port *bp) KASSERT(bp->bp_active == 0, ("port is still attached")); taskqueue_drain(taskqueue_swi, &bp->bp_statetask); taskqueue_drain(taskqueue_swi, &bp->bp_rtagetask); + taskqueue_drain(taskqueue_swi, &bp->bp_mediatask); } Modified: head/sys/net/bridgestp.h ============================================================================== --- head/sys/net/bridgestp.h Fri Apr 20 09:55:50 2012 (r234487) +++ head/sys/net/bridgestp.h Fri Apr 20 10:06:28 2012 (r234488) @@ -326,6 +326,7 @@ struct bstp_port { uint8_t bp_txcount; struct task bp_statetask; struct task bp_rtagetask; + struct task bp_mediatask; }; /* From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 10:08:31 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 23383106564A; Fri, 20 Apr 2012 10:08:31 +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 0EB2D8FC08; Fri, 20 Apr 2012 10:08:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KA8UIb034600; Fri, 20 Apr 2012 10:08:30 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KA8UUm034598; Fri, 20 Apr 2012 10:08:30 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201204201008.q3KA8UUm034598@svn.freebsd.org> From: Jaakko Heinonen Date: Fri, 20 Apr 2012 10:08: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: r234489 - head/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 10:08:31 -0000 Author: jh Date: Fri Apr 20 10:08:30 2012 New Revision: 234489 URL: http://svn.freebsd.org/changeset/base/234489 Log: The value of flags matching VNOVAL can't be supported. Return EOPNOTSUPP from setfflags() in this case. This fixes the return value of chflags(path, -1). Discussed with: bde MFC after: 2 weeks Modified: head/sys/kern/vfs_syscalls.c Modified: head/sys/kern/vfs_syscalls.c ============================================================================== --- head/sys/kern/vfs_syscalls.c Fri Apr 20 10:06:28 2012 (r234488) +++ head/sys/kern/vfs_syscalls.c Fri Apr 20 10:08:30 2012 (r234489) @@ -2744,6 +2744,10 @@ setfflags(td, vp, flags) struct mount *mp; struct vattr vattr; + /* We can't support the value matching VNOVAL. */ + if (flags == VNOVAL) + return (EOPNOTSUPP); + /* * Prevent non-root users from setting flags on devices. When * a device is reused, users can retain ownership of the device From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 11:59:20 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3126C1065673; Fri, 20 Apr 2012 11:59:20 +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 99C258FC17; Fri, 20 Apr 2012 11:59:19 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:5452:d047:6eb8:2b2e] (unknown [IPv6:2001:7b8:3a7:0:5452:d047:6eb8:2b2e]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id C7D8E5C37; Fri, 20 Apr 2012 13:59:18 +0200 (CEST) Message-ID: <4F914F99.3090205@FreeBSD.org> Date: Fri, 20 Apr 2012 13:59:21 +0200 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20120410 Thunderbird/12.0 MIME-Version: 1.0 To: Jason Evans References: <201204170722.q3H7ME6A070934@svn.freebsd.org> <20120419091558.2ae655a0@cox.net> In-Reply-To: Content-Type: multipart/mixed; boundary="------------040702070908020206000406" Cc: "Conrad J. Sabatier" , src-committers@freebsd.org, svn-src-all@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 11:59:20 -0000 This is a multi-part message in MIME format. --------------040702070908020206000406 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit On 2012-04-20 00:23, Jason Evans wrote: ... > With /etc/make.conf as: > > CFLAGS+=-g > STRIP= > CC=clang > CXX=clang++ > CPP=clang-cpp > > I got this buildworld failure: > --- > clang -O2 -pipe -g -I/usr/src/lib/csu/amd64/../common -I/usr/src/lib/csu/amd64/../../libc/include -fno-omit-frame-pointer -std=gnu99 -Qunused-arguments -Wsystem-headers -Werror -Wall -Wno-format-y2k -W -Wno-unused-parameter -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wreturn-type -Wcast-qual -Wwrite-strin > gs -Wswitch -Wshadow -Wunused-parameter -Wcast-align -Wchar-subscripts -Winline -Wnested-externs -Wredundant-decls -Wold-style-definition -Wno-pointer-sign -Wno-empty-body -Wno-string-plus-int -c -o crt1.o crt1.scrt1.s:8:2: error: input can't have .file dwarf directives when -g is used to generate dwarf debug info for assembly code > .file 1 "/usr/src/lib/csu/amd64/crt1.c" ^ > crt1.s:8:8: error: file number already allocated .file 1 "/usr/src/lib/csu/amd64/crt1.c" > ^crt1.s:9:2: error: input can't have .file dwarf directives when -g is used to generate dwarf debug info for assembly code > .file 2 "/usr/src/lib/csu/amd64/../common/crtbrand.c" ^crt1.s:10:2: error: input can't have .file dwarf directives when -g is used to generate dwarf debug info for assembly code > .file 3 "/usr/src/lib/csu/amd64/../common/ignore_init.c" ^ > --- > > I removed the CFLAGS+=-g line, and buildworld succeeded. Sorry about that. Please try the attached patch, that should help. --------------040702070908020206000406 Content-Type: text/x-diff; name="fix-csu-build-with-debug-1.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="fix-csu-build-with-debug-1.diff" Index: lib/csu/amd64/Makefile =================================================================== --- lib/csu/amd64/Makefile (revision 234489) +++ lib/csu/amd64/Makefile (working copy) @@ -22,21 +22,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Index: lib/csu/arm/Makefile =================================================================== --- lib/csu/arm/Makefile (revision 234489) +++ lib/csu/arm/Makefile (working copy) @@ -21,21 +21,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Index: lib/csu/i386-elf/Makefile =================================================================== --- lib/csu/i386-elf/Makefile (revision 234489) +++ lib/csu/i386-elf/Makefile (working copy) @@ -21,7 +21,7 @@ gcrt1_c.s: crt1_c.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1_c.o: gcrt1_c.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1_c.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1_c.s gcrt1.o: gcrt1_c.o crt1_s.o ${LD} ${LDFLAGS} -o gcrt1.o -r crt1_s.o gcrt1_c.o @@ -31,7 +31,7 @@ crt1_c.s: crt1_c.c sed ${SED_FIX_NOTE} ${.TARGET} crt1_c.o: crt1_c.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1_c.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1_c.s crt1.o: crt1_c.o crt1_s.o ${LD} ${LDFLAGS} -o crt1.o -r crt1_s.o crt1_c.o @@ -42,7 +42,7 @@ Scrt1_c.s: crt1_c.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1_c.o: Scrt1_c.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1_c.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1_c.s Scrt1.o: Scrt1_c.o crt1_s.o ${LD} ${LDFLAGS} -o Scrt1.o -r crt1_s.o Scrt1_c.o Index: lib/csu/ia64/Makefile =================================================================== --- lib/csu/ia64/Makefile (revision 234489) +++ lib/csu/ia64/Makefile (working copy) @@ -24,7 +24,7 @@ crtbrand.s: crtbrand.c sed -i "" -e '/\.note\.ABI-tag/s/progbits/note/' ${.TARGET} crtbrand.o: crtbrand.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crtbrand.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crtbrand.s crt1.o: crt1_.o crtbrand.o ${LD} ${LDFLAGS} -r -o ${.TARGET} crt1_.o crtbrand.o @@ -37,7 +37,7 @@ gcrtbrand.s: crtbrand.c sed -i "" -e '/\.note\.ABI-tag/s/progbits/note/' ${.TARGET} gcrtbrand.o: gcrtbrand.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrtbrand.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrtbrand.s gcrt1.o: gcrt1_.o gcrtbrand.o ${LD} ${LDFLAGS} -r -o ${.TARGET} ${.ALLSRC} @@ -50,7 +50,7 @@ Scrtbrand.s: crtbrand.c sed -i "" -e '/\.note\.ABI-tag/s/progbits/note/' ${.TARGET} Scrtbrand.o: Scrtbrand.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrtbrand.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrtbrand.s Scrt1.o: Scrt1_.o Scrtbrand.o ${LD} ${LDFLAGS} -r -o ${.TARGET} ${.ALLSRC} Index: lib/csu/mips/Makefile =================================================================== --- lib/csu/mips/Makefile (revision 234489) +++ lib/csu/mips/Makefile (working copy) @@ -21,21 +21,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Index: lib/csu/powerpc/Makefile =================================================================== --- lib/csu/powerpc/Makefile (revision 234489) +++ lib/csu/powerpc/Makefile (working copy) @@ -22,21 +22,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Index: lib/csu/powerpc64/Makefile =================================================================== --- lib/csu/powerpc64/Makefile (revision 234489) +++ lib/csu/powerpc64/Makefile (working copy) @@ -22,21 +22,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ --------------040702070908020206000406-- From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 13:47:23 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F1D1A106566B; Fri, 20 Apr 2012 13:47:22 +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 C1F048FC16; Fri, 20 Apr 2012 13:47:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KDlMgB041673; Fri, 20 Apr 2012 13:47:22 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KDlM9A041670; Fri, 20 Apr 2012 13:47:22 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201204201347.q3KDlM9A041670@svn.freebsd.org> From: Marius Strobl Date: Fri, 20 Apr 2012 13:47:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234490 - in stable/9/sys: i386/conf kern sparc64/sparc64 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 13:47:23 -0000 Author: marius Date: Fri Apr 20 13:47:22 2012 New Revision: 234490 URL: http://svn.freebsd.org/changeset/base/234490 Log: MFC: r234247 Merge from x86: r233961: Fix interrupt load balancing regression, introduced in revision 222813, that left all un-pinned interrupts assigned to CPU 0. In intr_shuffle_irqs(), remove CPU_SETOF() call that initialized the "intr_cpus" cpuset to only contain CPU0. This initialization is too late and nullifies the results of calls to the intr_add_cpu() that occur much earlier in the boot process. r234074 (partial): The BSP is not added to the mask of valid target CPUs for interrupts. Fix this by adding the BSP as an interrupt target directly in r234105: Fix !SMP build after r234074. Modified: stable/9/sys/sparc64/sparc64/intr_machdep.c stable/9/sys/sparc64/sparc64/machdep.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/sparc64/sparc64/intr_machdep.c ============================================================================== --- stable/9/sys/sparc64/sparc64/intr_machdep.c Fri Apr 20 10:08:30 2012 (r234489) +++ stable/9/sys/sparc64/sparc64/intr_machdep.c Fri Apr 20 13:47:22 2012 (r234490) @@ -528,9 +528,6 @@ intr_shuffle_irqs(void *arg __unused) struct intr_vector *iv; int i; - /* The BSP is always a valid target. */ - CPU_SETOF(0, &intr_cpus); - /* Don't bother on UP. */ if (mp_ncpus == 1) return; Modified: stable/9/sys/sparc64/sparc64/machdep.c ============================================================================== --- stable/9/sys/sparc64/sparc64/machdep.c Fri Apr 20 10:08:30 2012 (r234489) +++ stable/9/sys/sparc64/sparc64/machdep.c Fri Apr 20 13:47:22 2012 (r234490) @@ -196,6 +196,13 @@ cpu_startup(void *arg) printf("machine: %s\n", sparc64_model); cpu_identify(rdpr(ver), PCPU_GET(clock), curcpu); + +#ifdef SMP + /* + * Add BSP as an interrupt target. + */ + intr_add_cpu(0); +#endif } void From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 14:29:46 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5F474106564A; Fri, 20 Apr 2012 14:29:46 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 49CB68FC12; Fri, 20 Apr 2012 14:29:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KETklW043051; Fri, 20 Apr 2012 14:29:46 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KETkH8043043; Fri, 20 Apr 2012 14:29:46 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201204201429.q3KETkH8043043@svn.freebsd.org> From: Hans Petter Selasky Date: Fri, 20 Apr 2012 14:29: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: r234491 - head/lib/libusb X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 14:29:46 -0000 Author: hselasky Date: Fri Apr 20 14:29:45 2012 New Revision: 234491 URL: http://svn.freebsd.org/changeset/base/234491 Log: Fix some compile warnings. MFC after: 1 week Modified: head/lib/libusb/libusb10.c head/lib/libusb/libusb10_desc.c head/lib/libusb/libusb10_io.c head/lib/libusb/libusb20.c head/lib/libusb/libusb20_desc.c head/lib/libusb/libusb20_ugen20.c Modified: head/lib/libusb/libusb10.c ============================================================================== --- head/lib/libusb/libusb10.c Fri Apr 20 13:47:22 2012 (r234490) +++ head/lib/libusb/libusb10.c Fri Apr 20 14:29:45 2012 (r234491) @@ -651,17 +651,17 @@ libusb_set_interface_alt_setting(struct static struct libusb20_transfer * libusb10_get_transfer(struct libusb20_device *pdev, - uint8_t endpoint, uint8_t index) + uint8_t endpoint, uint8_t xfer_index) { - index &= 1; /* double buffering */ + xfer_index &= 1; /* double buffering */ - index |= (endpoint & LIBUSB20_ENDPOINT_ADDRESS_MASK) * 4; + xfer_index |= (endpoint & LIBUSB20_ENDPOINT_ADDRESS_MASK) * 4; if (endpoint & LIBUSB20_ENDPOINT_DIR_MASK) { /* this is an IN endpoint */ - index |= 2; + xfer_index |= 2; } - return (libusb20_tr_get_pointer(pdev, index)); + return (libusb20_tr_get_pointer(pdev, xfer_index)); } int Modified: head/lib/libusb/libusb10_desc.c ============================================================================== --- head/lib/libusb/libusb10_desc.c Fri Apr 20 13:47:22 2012 (r234490) +++ head/lib/libusb/libusb10_desc.c Fri Apr 20 14:29:45 2012 (r234491) @@ -390,8 +390,8 @@ libusb_parse_bos_descriptor(const void * struct libusb_bos_descriptor **bos) { struct libusb_bos_descriptor *ptr; - struct libusb_usb_2_0_device_capability_descriptor *dcap_20; - struct libusb_ss_usb_device_capability_descriptor *ss_cap; + struct libusb_usb_2_0_device_capability_descriptor *dcap_20 = NULL; + struct libusb_ss_usb_device_capability_descriptor *ss_cap = NULL; if (buf == NULL || bos == NULL || len < 1) return (LIBUSB_ERROR_INVALID_PARAM); @@ -438,7 +438,7 @@ libusb_parse_bos_descriptor(const void * dtype == LIBUSB_DT_DEVICE_CAPABILITY) { switch (((const uint8_t *)buf)[2]) { case LIBUSB_USB_2_0_EXTENSION_DEVICE_CAPABILITY: - if (ptr->usb_2_0_ext_cap != NULL) + if (ptr->usb_2_0_ext_cap != NULL || dcap_20 == NULL) break; if (dlen < LIBUSB_USB_2_0_EXTENSION_DEVICE_CAPABILITY_SIZE) break; @@ -455,7 +455,7 @@ libusb_parse_bos_descriptor(const void * break; case LIBUSB_SS_USB_DEVICE_CAPABILITY: - if (ptr->ss_usb_cap != NULL) + if (ptr->ss_usb_cap != NULL || ss_cap == NULL) break; if (dlen < LIBUSB_SS_USB_DEVICE_CAPABILITY_SIZE) break; Modified: head/lib/libusb/libusb10_io.c ============================================================================== --- head/lib/libusb/libusb10_io.c Fri Apr 20 13:47:22 2012 (r234490) +++ head/lib/libusb/libusb10_io.c Fri Apr 20 14:29:45 2012 (r234491) @@ -481,7 +481,7 @@ libusb10_do_transfer(libusb_device_handl { libusb_context *ctx; struct libusb_transfer *xfer; - volatile int complet; + int done; int ret; if (devh == NULL) @@ -502,15 +502,15 @@ libusb10_do_transfer(libusb_device_handl xfer->timeout = timeout; xfer->buffer = data; xfer->length = length; - xfer->user_data = (void *)&complet; + xfer->user_data = (void *)&done; xfer->callback = libusb10_do_transfer_cb; - complet = 0; + done = 0; if ((ret = libusb_submit_transfer(xfer)) < 0) { libusb_free_transfer(xfer); return (ret); } - while (complet == 0) { + while (done == 0) { if ((ret = libusb_handle_events(ctx)) < 0) { libusb_cancel_transfer(xfer); usleep(1000); /* nice it */ @@ -581,7 +581,7 @@ libusb_interrupt_transfer(libusb_device_ } uint8_t * -libusb_get_iso_packet_buffer(struct libusb_transfer *transfer, uint32_t index) +libusb_get_iso_packet_buffer(struct libusb_transfer *transfer, uint32_t off) { uint8_t *ptr; uint32_t n; @@ -589,35 +589,35 @@ libusb_get_iso_packet_buffer(struct libu if (transfer->num_iso_packets < 0) return (NULL); - if (index >= (uint32_t)transfer->num_iso_packets) + if (off >= (uint32_t)transfer->num_iso_packets) return (NULL); ptr = transfer->buffer; if (ptr == NULL) return (NULL); - for (n = 0; n != index; n++) { + for (n = 0; n != off; n++) { ptr += transfer->iso_packet_desc[n].length; } return (ptr); } uint8_t * -libusb_get_iso_packet_buffer_simple(struct libusb_transfer *transfer, uint32_t index) +libusb_get_iso_packet_buffer_simple(struct libusb_transfer *transfer, uint32_t off) { uint8_t *ptr; if (transfer->num_iso_packets < 0) return (NULL); - if (index >= (uint32_t)transfer->num_iso_packets) + if (off >= (uint32_t)transfer->num_iso_packets) return (NULL); ptr = transfer->buffer; if (ptr == NULL) return (NULL); - ptr += transfer->iso_packet_desc[0].length * index; + ptr += transfer->iso_packet_desc[0].length * off; return (ptr); } Modified: head/lib/libusb/libusb20.c ============================================================================== --- head/lib/libusb/libusb20.c Fri Apr 20 13:47:22 2012 (r234490) +++ head/lib/libusb/libusb20.c Fri Apr 20 14:29:45 2012 (r234491) @@ -948,9 +948,8 @@ libusb20_dev_get_config_index(struct lib } error = pdev->methods->get_config_index(pdev, &cfg_index); - if (error) { - cfg_index = 0 - 1; /* current config index */ - } + if (error) + cfg_index = 0xFF; /* current config index */ if (do_close) { if (libusb20_dev_close(pdev)) { /* ignore */ Modified: head/lib/libusb/libusb20_desc.c ============================================================================== --- head/lib/libusb/libusb20_desc.c Fri Apr 20 13:47:22 2012 (r234490) +++ head/lib/libusb/libusb20_desc.c Fri Apr 20 14:29:45 2012 (r234491) @@ -69,7 +69,7 @@ libusb20_parse_config_desc(const void *c uint16_t niface_no_alt; uint16_t niface; uint16_t nendpoint; - uint8_t iface_no; + uint16_t iface_no; ptr = config_desc; if (ptr[1] != LIBUSB20_DT_CONFIG) { @@ -82,7 +82,7 @@ libusb20_parse_config_desc(const void *c niface_no_alt = 0; nendpoint = 0; niface = 0; - iface_no = 0 - 1; + iface_no = 0xFFFF; ptr = NULL; /* get "wTotalLength" and setup "pcdesc" */ @@ -155,7 +155,7 @@ libusb20_parse_config_desc(const void *c /* reset states */ niface = 0; - iface_no = 0 - 1; + iface_no = 0xFFFF; ptr = NULL; lub_interface--; lub_endpoint--; @@ -450,7 +450,7 @@ libusb20_me_encode(void *ptr, uint16_t l * and should be * correct: */ - ps->len = 0 - 1; + ps->len = 0xFFFF; } src_len = libusb20_me_get_1(pd, 0); src_ptr = LIBUSB20_ADD_BYTES(ps->ptr, 1); @@ -465,7 +465,7 @@ libusb20_me_encode(void *ptr, uint16_t l case LIBUSB20_ME_IS_DECODED: /* reserve 3 length bytes */ src_len = libusb20_me_encode(NULL, - 0 - 1 - 3, ps->ptr); + 0xFFFF - 3, ps->ptr); src_ptr = NULL; break; @@ -476,7 +476,7 @@ libusb20_me_encode(void *ptr, uint16_t l } if (src_len > 0xFE) { - if (src_len > (uint16_t)(0 - 1 - 3)) + if (src_len > (0xFFFF - 3)) /* overflow */ goto done; @@ -516,7 +516,7 @@ libusb20_me_encode(void *ptr, uint16_t l uint16_t dummy; dummy = libusb20_me_encode(buf, - 0 - 1 - 3, ps->ptr); + 0xFFFF - 3, ps->ptr); } else { bcopy(src_ptr, buf, src_len); } Modified: head/lib/libusb/libusb20_ugen20.c ============================================================================== --- head/lib/libusb/libusb20_ugen20.c Fri Apr 20 13:47:22 2012 (r234490) +++ head/lib/libusb/libusb20_ugen20.c Fri Apr 20 14:29:45 2012 (r234491) @@ -104,7 +104,7 @@ ugen20_path_convert_one(const char **pp) temp += (*ptr - '0'); if (temp >= 1000000) { /* catch overflow early */ - return (0 - 1); + return (0xFFFFFFFF); } ptr++; } From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 14:45:58 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2D0551065672; Fri, 20 Apr 2012 14:45:58 +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 0D2EA8FC15; Fri, 20 Apr 2012 14:45:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KEjvCk043582; Fri, 20 Apr 2012 14:45:57 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KEjvxo043578; Fri, 20 Apr 2012 14:45:57 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201204201445.q3KEjvxo043578@svn.freebsd.org> From: Marius Strobl Date: Fri, 20 Apr 2012 14:45:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234492 - in stable/8/sys: dev/mmc dev/sdhci i386/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 14:45:58 -0000 Author: marius Date: Fri Apr 20 14:45:57 2012 New Revision: 234492 URL: http://svn.freebsd.org/changeset/base/234492 Log: MFC: r222475 Fix read_ivar implementation for MMC and SD. 1. Both mmc_read_ivar() and sdhci_read_ivar() use the expression '*(int *)result = val' to assign to result which is uintptr_t *. This does not work on big-endian 64 bit systems. 2. The media_size ivar is declared as 'off_t' which does not fit into uintptr_t in 32bit systems, change this to long. Submitted by: kanthms at netlogicmicro com (initial version) PR: 134745 Modified: stable/8/sys/dev/mmc/mmc.c stable/8/sys/dev/mmc/mmcvar.h stable/8/sys/dev/sdhci/sdhci.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/e1000/ (props changed) stable/8/sys/i386/conf/XENHVM (props changed) Modified: stable/8/sys/dev/mmc/mmc.c ============================================================================== --- stable/8/sys/dev/mmc/mmc.c Fri Apr 20 14:29:45 2012 (r234491) +++ stable/8/sys/dev/mmc/mmc.c Fri Apr 20 14:45:57 2012 (r234492) @@ -1445,37 +1445,37 @@ mmc_read_ivar(device_t bus, device_t chi default: return (EINVAL); case MMC_IVAR_DSR_IMP: - *(int *)result = ivar->csd.dsr_imp; + *result = ivar->csd.dsr_imp; break; case MMC_IVAR_MEDIA_SIZE: - *(off_t *)result = ivar->sec_count; + *result = ivar->sec_count; break; case MMC_IVAR_RCA: - *(int *)result = ivar->rca; + *result = ivar->rca; break; case MMC_IVAR_SECTOR_SIZE: - *(int *)result = MMC_SECTOR_SIZE; + *result = MMC_SECTOR_SIZE; break; case MMC_IVAR_TRAN_SPEED: - *(int *)result = mmcbr_get_clock(bus); + *result = mmcbr_get_clock(bus); break; case MMC_IVAR_READ_ONLY: - *(int *)result = ivar->read_only; + *result = ivar->read_only; break; case MMC_IVAR_HIGH_CAP: - *(int *)result = ivar->high_cap; + *result = ivar->high_cap; break; case MMC_IVAR_CARD_TYPE: - *(int *)result = ivar->mode; + *result = ivar->mode; break; case MMC_IVAR_BUS_WIDTH: - *(int *)result = ivar->bus_width; + *result = ivar->bus_width; break; case MMC_IVAR_ERASE_SECTOR: - *(int *)result = ivar->erase_sector; + *result = ivar->erase_sector; break; case MMC_IVAR_MAX_DATA: - *(int *)result = mmcbr_get_max_data(bus); + *result = mmcbr_get_max_data(bus); break; } return (0); Modified: stable/8/sys/dev/mmc/mmcvar.h ============================================================================== --- stable/8/sys/dev/mmc/mmcvar.h Fri Apr 20 14:29:45 2012 (r234491) +++ stable/8/sys/dev/mmc/mmcvar.h Fri Apr 20 14:45:57 2012 (r234492) @@ -79,7 +79,7 @@ enum mmc_device_ivars { __BUS_ACCESSOR(mmc, var, MMC, ivar, type) MMC_ACCESSOR(dsr_imp, DSR_IMP, int) -MMC_ACCESSOR(media_size, MEDIA_SIZE, off_t) +MMC_ACCESSOR(media_size, MEDIA_SIZE, long) MMC_ACCESSOR(rca, RCA, int) MMC_ACCESSOR(sector_size, SECTOR_SIZE, int) MMC_ACCESSOR(tran_speed, TRAN_SPEED, int) Modified: stable/8/sys/dev/sdhci/sdhci.c ============================================================================== --- stable/8/sys/dev/sdhci/sdhci.c Fri Apr 20 14:29:45 2012 (r234491) +++ stable/8/sys/dev/sdhci/sdhci.c Fri Apr 20 14:45:57 2012 (r234492) @@ -1441,46 +1441,46 @@ sdhci_read_ivar(device_t bus, device_t c default: return (EINVAL); case MMCBR_IVAR_BUS_MODE: - *(int *)result = slot->host.ios.bus_mode; + *result = slot->host.ios.bus_mode; break; case MMCBR_IVAR_BUS_WIDTH: - *(int *)result = slot->host.ios.bus_width; + *result = slot->host.ios.bus_width; break; case MMCBR_IVAR_CHIP_SELECT: - *(int *)result = slot->host.ios.chip_select; + *result = slot->host.ios.chip_select; break; case MMCBR_IVAR_CLOCK: - *(int *)result = slot->host.ios.clock; + *result = slot->host.ios.clock; break; case MMCBR_IVAR_F_MIN: - *(int *)result = slot->host.f_min; + *result = slot->host.f_min; break; case MMCBR_IVAR_F_MAX: - *(int *)result = slot->host.f_max; + *result = slot->host.f_max; break; case MMCBR_IVAR_HOST_OCR: - *(int *)result = slot->host.host_ocr; + *result = slot->host.host_ocr; break; case MMCBR_IVAR_MODE: - *(int *)result = slot->host.mode; + *result = slot->host.mode; break; case MMCBR_IVAR_OCR: - *(int *)result = slot->host.ocr; + *result = slot->host.ocr; break; case MMCBR_IVAR_POWER_MODE: - *(int *)result = slot->host.ios.power_mode; + *result = slot->host.ios.power_mode; break; case MMCBR_IVAR_VDD: - *(int *)result = slot->host.ios.vdd; + *result = slot->host.ios.vdd; break; case MMCBR_IVAR_CAPS: - *(int *)result = slot->host.caps; + *result = slot->host.caps; break; case MMCBR_IVAR_TIMING: - *(int *)result = slot->host.ios.timing; + *result = slot->host.ios.timing; break; case MMCBR_IVAR_MAX_DATA: - *(int *)result = 65535; + *result = 65535; break; } return (0); From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 15:01:24 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3C9531065672; Fri, 20 Apr 2012 15:01:24 +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 0F88C8FC21; Fri, 20 Apr 2012 15:01:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KF1N5p044101; Fri, 20 Apr 2012 15:01:23 GMT (envelope-from marcel@svn.freebsd.org) Received: (from marcel@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KF1NZW044098; Fri, 20 Apr 2012 15:01:23 GMT (envelope-from marcel@svn.freebsd.org) Message-Id: <201204201501.q3KF1NZW044098@svn.freebsd.org> From: Marcel Moolenaar Date: Fri, 20 Apr 2012 15:01: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: r234493 - in head/sys/boot: efi i386/efi X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 15:01:24 -0000 Author: marcel Date: Fri Apr 20 15:01:23 2012 New Revision: 234493 URL: http://svn.freebsd.org/changeset/base/234493 Log: Build a 32-bit EFI loader on amd64. This to match the rest of the code that is used to construct a loader (e.g. libstand, ficl, etc). There is such a thing as a 64-bit EFI application, but it's not as standard as 32-bit is. Let's make the 32-bit functional (as in we can load and actualy boot a kernel) before solving the 64-bit loader problem. Modified: head/sys/boot/efi/Makefile.inc head/sys/boot/i386/efi/Makefile Modified: head/sys/boot/efi/Makefile.inc ============================================================================== --- head/sys/boot/efi/Makefile.inc Fri Apr 20 14:45:57 2012 (r234492) +++ head/sys/boot/efi/Makefile.inc Fri Apr 20 15:01:23 2012 (r234493) @@ -2,6 +2,13 @@ BINDIR?= /boot +.if ${MACHINE_CPUARCH} == "amd64" +CFLAGS+= -m32 -march=i386 +ACFLAGS+= -m32 +LDFLAGS+= -m elf_i386_fbsd +AFLAGS+= --32 +.endif + # Options used when building app-specific efi components CFLAGS+= -ffreestanding -fshort-wchar -Wformat LDFLAGS+= -nostdlib Modified: head/sys/boot/i386/efi/Makefile ============================================================================== --- head/sys/boot/i386/efi/Makefile Fri Apr 20 14:45:57 2012 (r234492) +++ head/sys/boot/i386/efi/Makefile Fri Apr 20 15:01:23 2012 (r234493) @@ -35,7 +35,7 @@ CFLAGS+= -I${.CURDIR}/../../common FILES= loader.efi FILESMODE_loader.efi= ${BINMODE} -LDSCRIPT= ${.CURDIR}/ldscript.${MACHINE_ARCH} +LDSCRIPT= ${.CURDIR}/ldscript.i386 LDFLAGS= -Wl,-T${LDSCRIPT} -shared -symbolic ${PROG}: ${LDSCRIPT} @@ -64,6 +64,13 @@ CFLAGS+= -I${.CURDIR}/../libi386 CFLAGS+= -I${.CURDIR}/../btx/lib DPADD= ${LIBFICL} ${LIBEFI} ${LIBSTAND} -LDADD= ${LIBFICL} ${LIBEFI} -lstand +LDADD= ${LIBFICL} ${LIBEFI} ${LIBSTAND} .include + +.if ${MACHINE_CPUARCH} == "amd64" +CFLAGS+= -I. +beforedepend ${OBJS}: machine +machine: + ln -sf ${.CURDIR}/../../../i386/include machine +.endif From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 15:32:37 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0E71B1065673; Fri, 20 Apr 2012 15:32: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 ECDBC8FC15; Fri, 20 Apr 2012 15:32:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KFWaek045090; Fri, 20 Apr 2012 15:32:36 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KFWa1n045082; Fri, 20 Apr 2012 15:32:36 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201204201532.q3KFWa1n045082@svn.freebsd.org> From: John Baldwin Date: Fri, 20 Apr 2012 15:32:36 +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: r234494 - in head: sys/kern sys/sys usr.bin/kdump X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 15:32:37 -0000 Author: jhb Date: Fri Apr 20 15:32:36 2012 New Revision: 234494 URL: http://svn.freebsd.org/changeset/base/234494 Log: Include the associated wait channel message for context switch ktrace records. kdump supports both the old and new messages. Submitted by: Andrey Zonov andrey zonov org MFC after: 1 week Modified: head/sys/kern/kern_condvar.c head/sys/kern/kern_ktrace.c head/sys/kern/kern_synch.c head/sys/kern/subr_trap.c head/sys/sys/ktrace.h head/usr.bin/kdump/kdump.1 head/usr.bin/kdump/kdump.c Modified: head/sys/kern/kern_condvar.c ============================================================================== --- head/sys/kern/kern_condvar.c Fri Apr 20 15:01:23 2012 (r234493) +++ head/sys/kern/kern_condvar.c Fri Apr 20 15:32:36 2012 (r234494) @@ -103,7 +103,7 @@ _cv_wait(struct cv *cvp, struct lock_obj lock_state = 0; #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(1, 0); + ktrcsw(1, 0, cv_wmesg(cvp)); #endif CV_ASSERT(cvp, lock, td); WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, lock, @@ -140,7 +140,7 @@ _cv_wait(struct cv *cvp, struct lock_obj #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 0); + ktrcsw(0, 0, cv_wmesg(cvp)); #endif PICKUP_GIANT(); if (lock != &Giant.lock_object) { @@ -162,7 +162,7 @@ _cv_wait_unlock(struct cv *cvp, struct l td = curthread; #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(1, 0); + ktrcsw(1, 0, cv_wmesg(cvp)); #endif CV_ASSERT(cvp, lock, td); WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, lock, @@ -197,7 +197,7 @@ _cv_wait_unlock(struct cv *cvp, struct l #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 0); + ktrcsw(0, 0, cv_wmesg(cvp)); #endif PICKUP_GIANT(); } @@ -220,7 +220,7 @@ _cv_wait_sig(struct cv *cvp, struct lock lock_state = 0; #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(1, 0); + ktrcsw(1, 0, cv_wmesg(cvp)); #endif CV_ASSERT(cvp, lock, td); WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, lock, @@ -258,7 +258,7 @@ _cv_wait_sig(struct cv *cvp, struct lock #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 0); + ktrcsw(0, 0, cv_wmesg(cvp)); #endif PICKUP_GIANT(); if (lock != &Giant.lock_object) { @@ -286,7 +286,7 @@ _cv_timedwait(struct cv *cvp, struct loc lock_state = 0; #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(1, 0); + ktrcsw(1, 0, cv_wmesg(cvp)); #endif CV_ASSERT(cvp, lock, td); WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, lock, @@ -324,7 +324,7 @@ _cv_timedwait(struct cv *cvp, struct loc #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 0); + ktrcsw(0, 0, cv_wmesg(cvp)); #endif PICKUP_GIANT(); if (lock != &Giant.lock_object) { @@ -353,7 +353,7 @@ _cv_timedwait_sig(struct cv *cvp, struct lock_state = 0; #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(1, 0); + ktrcsw(1, 0, cv_wmesg(cvp)); #endif CV_ASSERT(cvp, lock, td); WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, lock, @@ -392,7 +392,7 @@ _cv_timedwait_sig(struct cv *cvp, struct #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 0); + ktrcsw(0, 0, cv_wmesg(cvp)); #endif PICKUP_GIANT(); if (lock != &Giant.lock_object) { Modified: head/sys/kern/kern_ktrace.c ============================================================================== --- head/sys/kern/kern_ktrace.c Fri Apr 20 15:01:23 2012 (r234493) +++ head/sys/kern/kern_ktrace.c Fri Apr 20 15:32:36 2012 (r234494) @@ -733,8 +733,9 @@ ktrpsig(sig, action, mask, code) } void -ktrcsw(out, user) +ktrcsw(out, user, wmesg) int out, user; + const char *wmesg; { struct thread *td = curthread; struct ktr_request *req; @@ -746,6 +747,10 @@ ktrcsw(out, user) kc = &req->ktr_data.ktr_csw; kc->out = out; kc->user = user; + if (wmesg != NULL) + strlcpy(kc->wmesg, wmesg, sizeof(kc->wmesg)); + else + bzero(kc->wmesg, sizeof(kc->wmesg)); ktr_enqueuerequest(td, req); ktrace_exit(td); } Modified: head/sys/kern/kern_synch.c ============================================================================== --- head/sys/kern/kern_synch.c Fri Apr 20 15:01:23 2012 (r234493) +++ head/sys/kern/kern_synch.c Fri Apr 20 15:32:36 2012 (r234494) @@ -142,7 +142,7 @@ _sleep(void *ident, struct lock_object * p = td->td_proc; #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(1, 0); + ktrcsw(1, 0, wmesg); #endif WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, lock, "Sleeping on \"%s\"", wmesg); @@ -236,7 +236,7 @@ _sleep(void *ident, struct lock_object * } #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 0); + ktrcsw(0, 0, wmesg); #endif PICKUP_GIANT(); if (lock != NULL && lock != &Giant.lock_object && !(priority & PDROP)) { @@ -298,7 +298,7 @@ msleep_spin(void *ident, struct mtx *mtx #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) { sleepq_release(ident); - ktrcsw(1, 0); + ktrcsw(1, 0, wmesg); sleepq_lock(ident); } #endif @@ -316,7 +316,7 @@ msleep_spin(void *ident, struct mtx *mtx } #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 0); + ktrcsw(0, 0, wmesg); #endif PICKUP_GIANT(); mtx_lock_spin(mtx); Modified: head/sys/kern/subr_trap.c ============================================================================== --- head/sys/kern/subr_trap.c Fri Apr 20 15:01:23 2012 (r234493) +++ head/sys/kern/subr_trap.c Fri Apr 20 15:32:36 2012 (r234494) @@ -219,7 +219,7 @@ ast(struct trapframe *framep) if (flags & TDF_NEEDRESCHED) { #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(1, 1); + ktrcsw(1, 1, __func__); #endif thread_lock(td); sched_prio(td, td->td_user_pri); @@ -227,7 +227,7 @@ ast(struct trapframe *framep) thread_unlock(td); #ifdef KTRACE if (KTRPOINT(td, KTR_CSW)) - ktrcsw(0, 1); + ktrcsw(0, 1, __func__); #endif } Modified: head/sys/sys/ktrace.h ============================================================================== --- head/sys/sys/ktrace.h Fri Apr 20 15:01:23 2012 (r234493) +++ head/sys/sys/ktrace.h Fri Apr 20 15:32:36 2012 (r234494) @@ -135,9 +135,15 @@ struct ktr_psig { * KTR_CSW - trace context switches */ #define KTR_CSW 6 +struct ktr_csw_old { + int out; /* 1 if switch out, 0 if switch in */ + int user; /* 1 if usermode (ivcsw), 0 if kernel (vcsw) */ +}; + struct ktr_csw { int out; /* 1 if switch out, 0 if switch in */ int user; /* 1 if usermode (ivcsw), 0 if kernel (vcsw) */ + char wmesg[8]; }; /* @@ -244,7 +250,7 @@ struct ktr_faultend { #ifdef _KERNEL void ktrnamei(char *); -void ktrcsw(int, int); +void ktrcsw(int, int, const char *); void ktrpsig(int, sig_t, sigset_t *, int); void ktrfault(vm_offset_t, int); void ktrfaultend(int); Modified: head/usr.bin/kdump/kdump.1 ============================================================================== --- head/usr.bin/kdump/kdump.1 Fri Apr 20 15:01:23 2012 (r234493) +++ head/usr.bin/kdump/kdump.1 Fri Apr 20 15:32:36 2012 (r234494) @@ -28,7 +28,7 @@ .\" @(#)kdump.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" -.Dd April 5, 2012 +.Dd April 20, 2012 .Dt KDUMP 1 .Os .Sh NAME @@ -167,7 +167,7 @@ The possible operations are: .It Li NAMI Ta file name lookup Ta path to file .It Li GIO Ta general I/O Ta fd, read/write, number of bytes .It Li PSIG Ta signal Ta signal name, handler, mask, code -.It Li CSW Ta context switch Ta stop/resume user/kernel +.It Li CSW Ta context switch Ta stop/resume user/kernel wmesg .It Li USER Ta data from user process Ta the data .It Li STRU Ta various syscalls Ta structure .It Li SCTL Ta Xr sysctl 3 requests Ta MIB name Modified: head/usr.bin/kdump/kdump.c ============================================================================== --- head/usr.bin/kdump/kdump.c Fri Apr 20 15:01:23 2012 (r234493) +++ head/usr.bin/kdump/kdump.c Fri Apr 20 15:32:36 2012 (r234494) @@ -95,6 +95,7 @@ void visdump(char *, int, int); void ktrgenio(struct ktr_genio *, int); void ktrpsig(struct ktr_psig *); void ktrcsw(struct ktr_csw *); +void ktrcsw_old(struct ktr_csw_old *); void ktruser_malloc(unsigned char *); void ktruser_rtld(int, unsigned char *); void ktruser(int, unsigned char *); @@ -298,7 +299,10 @@ main(int argc, char *argv[]) ktrpsig((struct ktr_psig *)m); break; case KTR_CSW: - ktrcsw((struct ktr_csw *)m); + if (ktrlen == sizeof(struct ktr_csw_old)) + ktrcsw_old((struct ktr_csw_old *)m); + else + ktrcsw((struct ktr_csw *)m); break; case KTR_USER: ktruser(ktrlen, m); @@ -1245,12 +1249,19 @@ ktrpsig(struct ktr_psig *psig) } void -ktrcsw(struct ktr_csw *cs) +ktrcsw_old(struct ktr_csw_old *cs) { printf("%s %s\n", cs->out ? "stop" : "resume", cs->user ? "user" : "kernel"); } +void +ktrcsw(struct ktr_csw *cs) +{ + printf("%s %s \"%s\"\n", cs->out ? "stop" : "resume", + cs->user ? "user" : "kernel", cs->wmesg); +} + #define UTRACE_DLOPEN_START 1 #define UTRACE_DLOPEN_STOP 2 #define UTRACE_DLCLOSE_START 3 From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 15:56:52 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 501E6106566C; Fri, 20 Apr 2012 15:56:52 +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 30EDD8FC16; Fri, 20 Apr 2012 15:56:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KFuqeZ045853; Fri, 20 Apr 2012 15:56:52 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KFuptg045849; Fri, 20 Apr 2012 15:56:51 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201204201556.q3KFuptg045849@svn.freebsd.org> From: Marius Strobl Date: Fri, 20 Apr 2012 15:56:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234495 - in stable/7/sys/dev: mmc sdhci X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 15:56:52 -0000 Author: marius Date: Fri Apr 20 15:56:51 2012 New Revision: 234495 URL: http://svn.freebsd.org/changeset/base/234495 Log: MFC: r222475 Fix read_ivar implementation for MMC and SD. 1. Both mmc_read_ivar() and sdhci_read_ivar() use the expression '*(int *)result = val' to assign to result which is uintptr_t *. This does not work on big-endian 64 bit systems. 2. The media_size ivar is declared as 'off_t' which does not fit into uintptr_t in 32bit systems, change this to long. Submitted by: kanthms at netlogicmicro com (initial version) PR: 134745 Modified: stable/7/sys/dev/mmc/mmc.c stable/7/sys/dev/mmc/mmcvar.h stable/7/sys/dev/sdhci/sdhci.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/dev/mmc/mmc.c ============================================================================== --- stable/7/sys/dev/mmc/mmc.c Fri Apr 20 15:32:36 2012 (r234494) +++ stable/7/sys/dev/mmc/mmc.c Fri Apr 20 15:56:51 2012 (r234495) @@ -1445,37 +1445,37 @@ mmc_read_ivar(device_t bus, device_t chi default: return (EINVAL); case MMC_IVAR_DSR_IMP: - *(int *)result = ivar->csd.dsr_imp; + *result = ivar->csd.dsr_imp; break; case MMC_IVAR_MEDIA_SIZE: - *(off_t *)result = ivar->sec_count; + *result = ivar->sec_count; break; case MMC_IVAR_RCA: - *(int *)result = ivar->rca; + *result = ivar->rca; break; case MMC_IVAR_SECTOR_SIZE: - *(int *)result = MMC_SECTOR_SIZE; + *result = MMC_SECTOR_SIZE; break; case MMC_IVAR_TRAN_SPEED: - *(int *)result = mmcbr_get_clock(bus); + *result = mmcbr_get_clock(bus); break; case MMC_IVAR_READ_ONLY: - *(int *)result = ivar->read_only; + *result = ivar->read_only; break; case MMC_IVAR_HIGH_CAP: - *(int *)result = ivar->high_cap; + *result = ivar->high_cap; break; case MMC_IVAR_CARD_TYPE: - *(int *)result = ivar->mode; + *result = ivar->mode; break; case MMC_IVAR_BUS_WIDTH: - *(int *)result = ivar->bus_width; + *result = ivar->bus_width; break; case MMC_IVAR_ERASE_SECTOR: - *(int *)result = ivar->erase_sector; + *result = ivar->erase_sector; break; case MMC_IVAR_MAX_DATA: - *(int *)result = mmcbr_get_max_data(bus); + *result = mmcbr_get_max_data(bus); break; } return (0); Modified: stable/7/sys/dev/mmc/mmcvar.h ============================================================================== --- stable/7/sys/dev/mmc/mmcvar.h Fri Apr 20 15:32:36 2012 (r234494) +++ stable/7/sys/dev/mmc/mmcvar.h Fri Apr 20 15:56:51 2012 (r234495) @@ -79,7 +79,7 @@ enum mmc_device_ivars { __BUS_ACCESSOR(mmc, var, MMC, ivar, type) MMC_ACCESSOR(dsr_imp, DSR_IMP, int) -MMC_ACCESSOR(media_size, MEDIA_SIZE, off_t) +MMC_ACCESSOR(media_size, MEDIA_SIZE, long) MMC_ACCESSOR(rca, RCA, int) MMC_ACCESSOR(sector_size, SECTOR_SIZE, int) MMC_ACCESSOR(tran_speed, TRAN_SPEED, int) Modified: stable/7/sys/dev/sdhci/sdhci.c ============================================================================== --- stable/7/sys/dev/sdhci/sdhci.c Fri Apr 20 15:32:36 2012 (r234494) +++ stable/7/sys/dev/sdhci/sdhci.c Fri Apr 20 15:56:51 2012 (r234495) @@ -1441,46 +1441,46 @@ sdhci_read_ivar(device_t bus, device_t c default: return (EINVAL); case MMCBR_IVAR_BUS_MODE: - *(int *)result = slot->host.ios.bus_mode; + *result = slot->host.ios.bus_mode; break; case MMCBR_IVAR_BUS_WIDTH: - *(int *)result = slot->host.ios.bus_width; + *result = slot->host.ios.bus_width; break; case MMCBR_IVAR_CHIP_SELECT: - *(int *)result = slot->host.ios.chip_select; + *result = slot->host.ios.chip_select; break; case MMCBR_IVAR_CLOCK: - *(int *)result = slot->host.ios.clock; + *result = slot->host.ios.clock; break; case MMCBR_IVAR_F_MIN: - *(int *)result = slot->host.f_min; + *result = slot->host.f_min; break; case MMCBR_IVAR_F_MAX: - *(int *)result = slot->host.f_max; + *result = slot->host.f_max; break; case MMCBR_IVAR_HOST_OCR: - *(int *)result = slot->host.host_ocr; + *result = slot->host.host_ocr; break; case MMCBR_IVAR_MODE: - *(int *)result = slot->host.mode; + *result = slot->host.mode; break; case MMCBR_IVAR_OCR: - *(int *)result = slot->host.ocr; + *result = slot->host.ocr; break; case MMCBR_IVAR_POWER_MODE: - *(int *)result = slot->host.ios.power_mode; + *result = slot->host.ios.power_mode; break; case MMCBR_IVAR_VDD: - *(int *)result = slot->host.ios.vdd; + *result = slot->host.ios.vdd; break; case MMCBR_IVAR_CAPS: - *(int *)result = slot->host.caps; + *result = slot->host.caps; break; case MMCBR_IVAR_TIMING: - *(int *)result = slot->host.ios.timing; + *result = slot->host.ios.timing; break; case MMCBR_IVAR_MAX_DATA: - *(int *)result = 65535; + *result = 65535; break; } return (0); From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 16:09:28 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B75BA106566B; Fri, 20 Apr 2012 16:09:28 +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 A0A728FC08; Fri, 20 Apr 2012 16:09:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KG9SpL046281; Fri, 20 Apr 2012 16:09:28 GMT (envelope-from gnn@svn.freebsd.org) Received: (from gnn@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KG9SoV046279; Fri, 20 Apr 2012 16:09:28 GMT (envelope-from gnn@svn.freebsd.org) Message-Id: <201204201609.q3KG9SoV046279@svn.freebsd.org> From: "George V. Neville-Neil" Date: Fri, 20 Apr 2012 16:09:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234496 - stable/8/cddl/contrib/opensolaris/lib/libdtrace/common X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 16:09:28 -0000 Author: gnn Date: Fri Apr 20 16:09:28 2012 New Revision: 234496 URL: http://svn.freebsd.org/changeset/base/234496 Log: MFC: 234234 Change SIGUSR1 to SIGTHR to properly wake up a process that is being traced. The use of SIGUSR1 caused traced processes (those attached to with dtrace -p) to exit when dtrace exited. Modified: stable/8/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c Directory Properties: stable/8/cddl/contrib/opensolaris/ (props changed) Modified: stable/8/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c ============================================================================== --- stable/8/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c Fri Apr 20 15:56:51 2012 (r234495) +++ stable/8/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c Fri Apr 20 16:09:28 2012 (r234496) @@ -811,7 +811,7 @@ dt_proc_destroy(dtrace_hdl_t *dtp, struc #if defined(sun) (void) _lwp_kill(dpr->dpr_tid, SIGCANCEL); #else - pthread_kill(dpr->dpr_tid, SIGUSR1); + pthread_kill(dpr->dpr_tid, SIGTHR); #endif /* From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 16:20:17 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 74B1C106564A; Fri, 20 Apr 2012 16:20:17 +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 5EBA38FC0C; Fri, 20 Apr 2012 16:20:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KGKHqu046637; Fri, 20 Apr 2012 16:20:17 GMT (envelope-from gnn@svn.freebsd.org) Received: (from gnn@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KGKHpc046635; Fri, 20 Apr 2012 16:20:17 GMT (envelope-from gnn@svn.freebsd.org) Message-Id: <201204201620.q3KGKHpc046635@svn.freebsd.org> From: "George V. Neville-Neil" Date: Fri, 20 Apr 2012 16:20:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234497 - stable/9/cddl/contrib/opensolaris/lib/libdtrace/common X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 16:20:17 -0000 Author: gnn Date: Fri Apr 20 16:20:16 2012 New Revision: 234497 URL: http://svn.freebsd.org/changeset/base/234497 Log: MFC: 234234 Change SIGUSR1 to SIGTHR to properly wake up a process that is being traced. The use of SIGUSR1 caused traced processes (those attached to with dtrace -p) to exit when dtrace exited. Modified: stable/9/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c Directory Properties: stable/9/cddl/contrib/opensolaris/ (props changed) Modified: stable/9/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c ============================================================================== --- stable/9/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c Fri Apr 20 16:09:28 2012 (r234496) +++ stable/9/cddl/contrib/opensolaris/lib/libdtrace/common/dt_proc.c Fri Apr 20 16:20:16 2012 (r234497) @@ -811,7 +811,7 @@ dt_proc_destroy(dtrace_hdl_t *dtp, struc #if defined(sun) (void) _lwp_kill(dpr->dpr_tid, SIGCANCEL); #else - pthread_kill(dpr->dpr_tid, SIGUSR1); + pthread_kill(dpr->dpr_tid, SIGTHR); #endif /* From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 20:27:31 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B3737106566C; Fri, 20 Apr 2012 20:27:31 +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 9F7E18FC14; Fri, 20 Apr 2012 20:27:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KKRVK7054229; Fri, 20 Apr 2012 20:27:31 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KKRVPe054227; Fri, 20 Apr 2012 20:27:31 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201204202027.q3KKRVPe054227@svn.freebsd.org> From: John Baldwin Date: Fri, 20 Apr 2012 20:27: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: r234501 - head/sys/dev/amr X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 20:27:31 -0000 Author: jhb Date: Fri Apr 20 20:27:31 2012 New Revision: 234501 URL: http://svn.freebsd.org/changeset/base/234501 Log: The amr(4) firmware contains a rather dubious "feature" where it assumes for small buffers (< 64k) that the OS driver is actually using a buffer rounded up to the next power of 2. It also assumes that the buffer is at least 4k in size. Furthermore, there is at least one known instance of megarc sending a request with a 12k buffer where the firmware writes out a 24k-ish reply. To workaround the data corruption triggered by this "feature", ensure that buffers for user commands use a minimum size of 32k, and that buffers between 32k and 64k use a 64k buffer. PR: kern/155658 Submitted by: Andreas Longwitz longwitz incore de Reviewed by: scottl MFC after: 1 week Modified: head/sys/dev/amr/amr.c Modified: head/sys/dev/amr/amr.c ============================================================================== --- head/sys/dev/amr/amr.c Fri Apr 20 16:56:14 2012 (r234500) +++ head/sys/dev/amr/amr.c Fri Apr 20 20:27:31 2012 (r234501) @@ -535,6 +535,31 @@ shutdown_out: amr_startup(sc); } +/* + * Bug-for-bug compatibility with Linux! + * Some apps will send commands with inlen and outlen set to 0, + * even though they expect data to be transfered to them from the + * card. Linux accidentally allows this by allocating a 4KB + * buffer for the transfer anyways, but it then throws it away + * without copying it back to the app. + * + * The amr(4) firmware relies on this feature. In fact, it assumes + * the buffer is always a power of 2 up to a max of 64k. There is + * also at least one case where it assumes a buffer less than 16k is + * greater than 16k. Force a minimum buffer size of 32k and round + * sizes between 32k and 64k up to 64k as a workaround. + */ +static unsigned long +amr_ioctl_buffer_length(unsigned long len) +{ + + if (len <= 32 * 1024) + return (32 * 1024); + if (len <= 64 * 1024) + return (64 * 1024); + return (len); +} + int amr_linux_ioctl_int(struct cdev *dev, u_long cmd, caddr_t addr, int32_t flag, struct thread *td) @@ -664,16 +689,7 @@ amr_linux_ioctl_int(struct cdev *dev, u_ error = ENOIOCTL; break; } else { - /* - * Bug-for-bug compatibility with Linux! - * Some apps will send commands with inlen and outlen set to 0, - * even though they expect data to be transfered to them from the - * card. Linux accidentally allows this by allocating a 4KB - * buffer for the transfer anyways, but it then throws it away - * without copying it back to the app. - */ - if (!len) - len = 4096; + len = amr_ioctl_buffer_length(imax(ali.inlen, ali.outlen)); dp = malloc(len, M_AMR, M_WAITOK | M_ZERO); @@ -703,7 +719,7 @@ amr_linux_ioctl_int(struct cdev *dev, u_ status = ac->ac_status; error = copyout(&status, &((struct amr_mailbox *)&((struct amr_linux_ioctl *)addr)->mbox[0])->mb_status, sizeof(status)); if (ali.outlen) { - error = copyout(dp, (void *)(uintptr_t)mb->mb_physaddr, len); + error = copyout(dp, (void *)(uintptr_t)mb->mb_physaddr, ali.outlen); if (error) break; } @@ -750,7 +766,7 @@ amr_ioctl(struct cdev *dev, u_long cmd, struct amr_command *ac; struct amr_mailbox_ioctl *mbi; void *dp, *au_buffer; - unsigned long au_length; + unsigned long au_length, real_length; unsigned char *au_cmd; int *au_statusp, au_direction; int error; @@ -842,8 +858,9 @@ amr_ioctl(struct cdev *dev, u_long cmd, } /* handle inbound data buffer */ + real_length = amr_ioctl_buffer_length(au_length); if (au_length != 0 && au_cmd[0] != 0x06) { - if ((dp = malloc(au_length, M_AMR, M_WAITOK|M_ZERO)) == NULL) { + if ((dp = malloc(real_length, M_AMR, M_WAITOK|M_ZERO)) == NULL) { error = ENOMEM; goto out; } @@ -902,7 +919,7 @@ amr_ioctl(struct cdev *dev, u_long cmd, /* build the command */ ac->ac_data = dp; - ac->ac_length = au_length; + ac->ac_length = real_length; ac->ac_flags |= AMR_CMD_DATAIN|AMR_CMD_DATAOUT; /* run the command */ From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 21:00:40 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 16856106566B; Fri, 20 Apr 2012 21:00:40 +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 F34368FC1B; Fri, 20 Apr 2012 21:00:39 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KL0d1d055302; Fri, 20 Apr 2012 21:00:39 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KL0d19055294; Fri, 20 Apr 2012 21:00:39 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204202100.q3KL0d19055294@svn.freebsd.org> From: Dimitry Andric Date: Fri, 20 Apr 2012 21:00: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: r234502 - in head/lib/csu: amd64 arm i386-elf ia64 mips powerpc powerpc64 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 21:00:40 -0000 Author: dim Date: Fri Apr 20 21:00:39 2012 New Revision: 234502 URL: http://svn.freebsd.org/changeset/base/234502 Log: After r217375, some startup objects under lib/csu are built in a special way: first they are compiled to assembly, then some sed'ing is done on the assembly, and lastly the assembly is compiled to an object file. This last step is done using ${CC}, and not ${AS}, because when the compiler is clang, it outputs directives that are too advanced for our old gas. So we use clang's integrated assembler instead. (When the compiler is gcc, it just calls gas, and nothing is different, except one extra fork.) However, in the .s to .o rules in lib/csu/$ARCH/Makefile, I still passed CFLAGS to the compiler, instead of ACFLAGS, which are specifically for compiling .s files. In case you are using '-g' for debug info anywhere in your CFLAGS, it causes the .s files to already contain debug information in the assembly itself. In the next step, the .s files are also compiled using '-g', and if the compiler is clang, it complains: "error: input can't have .file dwarf directives when -g is used to generate dwarf debug info for assembly code". Fix this by using ${ACFLAGS} for compiling the .s files instead. Reported by: jasone MFC after: 1 week Modified: head/lib/csu/amd64/Makefile head/lib/csu/arm/Makefile head/lib/csu/i386-elf/Makefile head/lib/csu/ia64/Makefile head/lib/csu/mips/Makefile head/lib/csu/powerpc/Makefile head/lib/csu/powerpc64/Makefile Modified: head/lib/csu/amd64/Makefile ============================================================================== --- head/lib/csu/amd64/Makefile Fri Apr 20 20:27:31 2012 (r234501) +++ head/lib/csu/amd64/Makefile Fri Apr 20 21:00:39 2012 (r234502) @@ -22,21 +22,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Modified: head/lib/csu/arm/Makefile ============================================================================== --- head/lib/csu/arm/Makefile Fri Apr 20 20:27:31 2012 (r234501) +++ head/lib/csu/arm/Makefile Fri Apr 20 21:00:39 2012 (r234502) @@ -21,21 +21,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Modified: head/lib/csu/i386-elf/Makefile ============================================================================== --- head/lib/csu/i386-elf/Makefile Fri Apr 20 20:27:31 2012 (r234501) +++ head/lib/csu/i386-elf/Makefile Fri Apr 20 21:00:39 2012 (r234502) @@ -21,7 +21,7 @@ gcrt1_c.s: crt1_c.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1_c.o: gcrt1_c.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1_c.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1_c.s gcrt1.o: gcrt1_c.o crt1_s.o ${LD} ${LDFLAGS} -o gcrt1.o -r crt1_s.o gcrt1_c.o @@ -31,7 +31,7 @@ crt1_c.s: crt1_c.c sed ${SED_FIX_NOTE} ${.TARGET} crt1_c.o: crt1_c.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1_c.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1_c.s crt1.o: crt1_c.o crt1_s.o ${LD} ${LDFLAGS} -o crt1.o -r crt1_s.o crt1_c.o @@ -42,7 +42,7 @@ Scrt1_c.s: crt1_c.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1_c.o: Scrt1_c.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1_c.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1_c.s Scrt1.o: Scrt1_c.o crt1_s.o ${LD} ${LDFLAGS} -o Scrt1.o -r crt1_s.o Scrt1_c.o Modified: head/lib/csu/ia64/Makefile ============================================================================== --- head/lib/csu/ia64/Makefile Fri Apr 20 20:27:31 2012 (r234501) +++ head/lib/csu/ia64/Makefile Fri Apr 20 21:00:39 2012 (r234502) @@ -24,7 +24,7 @@ crtbrand.s: crtbrand.c sed -i "" -e '/\.note\.ABI-tag/s/progbits/note/' ${.TARGET} crtbrand.o: crtbrand.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crtbrand.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crtbrand.s crt1.o: crt1_.o crtbrand.o ${LD} ${LDFLAGS} -r -o ${.TARGET} crt1_.o crtbrand.o @@ -37,7 +37,7 @@ gcrtbrand.s: crtbrand.c sed -i "" -e '/\.note\.ABI-tag/s/progbits/note/' ${.TARGET} gcrtbrand.o: gcrtbrand.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrtbrand.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrtbrand.s gcrt1.o: gcrt1_.o gcrtbrand.o ${LD} ${LDFLAGS} -r -o ${.TARGET} ${.ALLSRC} @@ -50,7 +50,7 @@ Scrtbrand.s: crtbrand.c sed -i "" -e '/\.note\.ABI-tag/s/progbits/note/' ${.TARGET} Scrtbrand.o: Scrtbrand.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrtbrand.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrtbrand.s Scrt1.o: Scrt1_.o Scrtbrand.o ${LD} ${LDFLAGS} -r -o ${.TARGET} ${.ALLSRC} Modified: head/lib/csu/mips/Makefile ============================================================================== --- head/lib/csu/mips/Makefile Fri Apr 20 20:27:31 2012 (r234501) +++ head/lib/csu/mips/Makefile Fri Apr 20 21:00:39 2012 (r234502) @@ -21,21 +21,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Modified: head/lib/csu/powerpc/Makefile ============================================================================== --- head/lib/csu/powerpc/Makefile Fri Apr 20 20:27:31 2012 (r234501) +++ head/lib/csu/powerpc/Makefile Fri Apr 20 21:00:39 2012 (r234502) @@ -22,21 +22,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ Modified: head/lib/csu/powerpc64/Makefile ============================================================================== --- head/lib/csu/powerpc64/Makefile Fri Apr 20 20:27:31 2012 (r234501) +++ head/lib/csu/powerpc64/Makefile Fri Apr 20 21:00:39 2012 (r234502) @@ -22,21 +22,21 @@ crt1.s: crt1.c sed ${SED_FIX_NOTE} ${.TARGET} crt1.o: crt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} crt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} crt1.s gcrt1.s: crt1.c ${CC} ${CFLAGS} -DGCRT -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} gcrt1.o: gcrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} gcrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} gcrt1.s Scrt1.s: crt1.c ${CC} ${CFLAGS} -fPIC -DPIC -S -o ${.TARGET} ${.CURDIR}/crt1.c sed ${SED_FIX_NOTE} ${.TARGET} Scrt1.o: Scrt1.s - ${CC} ${CFLAGS} -c -o ${.TARGET} Scrt1.s + ${CC} ${ACFLAGS} -c -o ${.TARGET} Scrt1.s realinstall: ${INSTALL} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 21:17:34 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4E516106566B; Fri, 20 Apr 2012 21:17: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 2EDFC8FC14; Fri, 20 Apr 2012 21:17:34 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KLHYNh055847; Fri, 20 Apr 2012 21:17:34 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KLHXke055845; Fri, 20 Apr 2012 21:17:33 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204202117.q3KLHXke055845@svn.freebsd.org> From: Dimitry Andric Date: Fri, 20 Apr 2012 21:17: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: r234503 - head/sys/dev/asr X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 21:17:34 -0000 Author: dim Date: Fri Apr 20 21:17:33 2012 New Revision: 234503 URL: http://svn.freebsd.org/changeset/base/234503 Log: Replace homegrown list implementation in sys/dev/asr/asr.c with STAILQ(). While here, fix another clang warning about a switch which tests an enum type for a regular integer value. Submitted by: jhb MFC after: 1 week Modified: head/sys/dev/asr/asr.c Modified: head/sys/dev/asr/asr.c ============================================================================== --- head/sys/dev/asr/asr.c Fri Apr 20 21:00:39 2012 (r234502) +++ head/sys/dev/asr/asr.c Fri Apr 20 21:17:33 2012 (r234503) @@ -378,11 +378,12 @@ typedef struct Asr_softc { u_int16_t ha_Msgs_Count; /* Links into other parents and HBAs */ - struct Asr_softc * ha_next; /* HBA list */ + STAILQ_ENTRY(Asr_softc) ha_next; /* HBA list */ struct cdev *ha_devt; } Asr_softc_t; -static Asr_softc_t *Asr_softc_list; +static STAILQ_HEAD(, Asr_softc) Asr_softc_list = + STAILQ_HEAD_INITIALIZER(Asr_softc_list); /* * Prototypes of the routines we have in this object. @@ -1959,7 +1960,7 @@ ASR_setSysTab(Asr_softc_t *sc) { PI2O_EXEC_SYS_TAB_SET_MESSAGE Message_Ptr; PI2O_SET_SYSTAB_HEADER SystemTable; - Asr_softc_t * ha; + Asr_softc_t * ha, *next; PI2O_SGE_SIMPLE_ELEMENT sg; int retVal; @@ -1967,7 +1968,7 @@ ASR_setSysTab(Asr_softc_t *sc) sizeof(I2O_SET_SYSTAB_HEADER), M_TEMP, M_WAITOK | M_ZERO)) == NULL) { return (ENOMEM); } - for (ha = Asr_softc_list; ha; ha = ha->ha_next) { + STAILQ_FOREACH(ha, &Asr_softc_list, ha_next) { ++SystemTable->NumberEntries; } if ((Message_Ptr = (PI2O_EXEC_SYS_TAB_SET_MESSAGE)malloc ( @@ -1998,9 +1999,9 @@ ASR_setSysTab(Asr_softc_t *sc) &(Message_Ptr->StdMessageFrame)) & 0xF0) >> 2)); SG(sg, 0, I2O_SGL_FLAGS_DIR, SystemTable, sizeof(I2O_SET_SYSTAB_HEADER)); ++sg; - for (ha = Asr_softc_list; ha; ha = ha->ha_next) { + STAILQ_FOREACH_SAFE(ha, &Asr_softc_list, ha_next, next) { SG(sg, 0, - ((ha->ha_next) + ((next) ? (I2O_SGL_FLAGS_DIR) : (I2O_SGL_FLAGS_DIR | I2O_SGL_FLAGS_END_OF_BUFFER)), &(ha->ha_SystemTable), sizeof(ha->ha_SystemTable)); @@ -2396,7 +2397,7 @@ asr_attach(device_t dev) { PI2O_EXEC_STATUS_GET_REPLY status; PI2O_LCT_ENTRY Device; - Asr_softc_t *sc, **ha; + Asr_softc_t *sc; struct scsi_inquiry_data *iq; int bus, size, unit; int error; @@ -2405,7 +2406,7 @@ asr_attach(device_t dev) unit = device_get_unit(dev); sc->ha_dev = dev; - if (Asr_softc_list == NULL) { + if (STAILQ_EMPTY(&Asr_softc_list)) { /* * Fixup the OS revision as saved in the dptsig for the * engine (dptioctl.h) to pick up. @@ -2417,8 +2418,7 @@ asr_attach(device_t dev) */ LIST_INIT(&(sc->ha_ccb)); /* Link us into the HA list */ - for (ha = &Asr_softc_list; *ha; ha = &((*ha)->ha_next)); - *(ha) = sc; + STAILQ_INSERT_TAIL(&Asr_softc_list, sc, ha_next); /* * This is the real McCoy! @@ -2700,7 +2700,7 @@ asr_action(struct cam_sim *sim, union cc ccb->ccb_h.spriv_ptr0 = sc = (struct Asr_softc *)cam_sim_softc(sim); - switch (ccb->ccb_h.func_code) { + switch ((int)ccb->ccb_h.func_code) { /* Common cases first */ case XPT_SCSI_IO: /* Execute the requested I/O operation */ From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 21:37:43 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 79F31106564A; Fri, 20 Apr 2012 21:37:43 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 5A7208FC2C; Fri, 20 Apr 2012 21:37:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KLbhnC056527; Fri, 20 Apr 2012 21:37:43 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KLbhNj056524; Fri, 20 Apr 2012 21:37:43 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201204202137.q3KLbhNj056524@svn.freebsd.org> From: Brooks Davis Date: Fri, 20 Apr 2012 21:37: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: r234504 - in head/sys: amd64/conf i386/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 21:37:43 -0000 Author: brooks Date: Fri Apr 20 21:37:42 2012 New Revision: 234504 URL: http://svn.freebsd.org/changeset/base/234504 Log: Enable DTrace hooks in GENERIC. Reviewed by: gnn Approved by: core (jhb, imp) Requested by: a cast of thousands MFC after: 3 days Modified: head/sys/amd64/conf/GENERIC head/sys/i386/conf/GENERIC Modified: head/sys/amd64/conf/GENERIC ============================================================================== --- head/sys/amd64/conf/GENERIC Fri Apr 20 21:17:33 2012 (r234503) +++ head/sys/amd64/conf/GENERIC Fri Apr 20 21:37:42 2012 (r234504) @@ -22,6 +22,7 @@ cpu HAMMER ident GENERIC makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols +makeoptions WITH_CTF=1 # Run ctfconvert(1) for DTrace support options SCHED_ULE # ULE scheduler options PREEMPTION # Enable kernel thread preemption @@ -63,8 +64,8 @@ options AUDIT # Security event auditi options CAPABILITY_MODE # Capsicum capability mode options CAPABILITIES # Capsicum capabilities options MAC # TrustedBSD MAC Framework -#options KDTRACE_FRAME # Ensure frames are compiled in -#options KDTRACE_HOOKS # Kernel DTrace hooks +options KDTRACE_FRAME # Ensure frames are compiled in +options KDTRACE_HOOKS # Kernel DTrace hooks options INCLUDE_CONFIG_FILE # Include this file in kernel # Debugging support. Always need this: @@ -74,6 +75,7 @@ options KDB # Enable kernel debugger # For full debugger support use this instead: options DDB # Support DDB. options GDB # Support remote GDB. +options DDB_CTF # kernel ELF linker loads CTF data options DEADLKRES # Enable the deadlock resolver options INVARIANTS # Enable calls of extra sanity checking options INVARIANT_SUPPORT # Extra sanity checks of internal structures, required by INVARIANTS Modified: head/sys/i386/conf/GENERIC ============================================================================== --- head/sys/i386/conf/GENERIC Fri Apr 20 21:17:33 2012 (r234503) +++ head/sys/i386/conf/GENERIC Fri Apr 20 21:37:42 2012 (r234504) @@ -24,6 +24,7 @@ cpu I686_CPU ident GENERIC makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols +makeoptions WITH_CTF=1 # Run ctfconvert(1) for DTrace support options SCHED_ULE # ULE scheduler options PREEMPTION # Enable kernel thread preemption @@ -64,7 +65,7 @@ options AUDIT # Security event auditi options CAPABILITY_MODE # Capsicum capability mode options CAPABILITIES # Capsicum capabilities options MAC # TrustedBSD MAC Framework -#options KDTRACE_HOOKS # Kernel DTrace hooks +options KDTRACE_HOOKS # Kernel DTrace hooks options INCLUDE_CONFIG_FILE # Include this file in kernel # Debugging support. Always need this: @@ -74,6 +75,7 @@ options KDB # Enable kernel debugger # For full debugger support use this instead: options DDB # Support DDB. options GDB # Support remote GDB. +options DDB_CTF # kernel ELF linker loads CTF data options DEADLKRES # Enable the deadlock resolver options INVARIANTS # Enable calls of extra sanity checking options INVARIANT_SUPPORT # Extra sanity checks of internal structures, required by INVARIANTS From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 21:40:32 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9CBAC1065673; Fri, 20 Apr 2012 21:40:32 +0000 (UTC) (envelope-from davide@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7B8208FC16; Fri, 20 Apr 2012 21:40:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KLeWSO056653; Fri, 20 Apr 2012 21:40:32 GMT (envelope-from davide@svn.freebsd.org) Received: (from davide@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KLeWpm056649; Fri, 20 Apr 2012 21:40:32 GMT (envelope-from davide@svn.freebsd.org) Message-Id: <201204202140.q3KLeWpm056649@svn.freebsd.org> From: Davide Italiano Date: Fri, 20 Apr 2012 21:40:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234505 - in stable/9/sys: conf kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 21:40:32 -0000 Author: davide Date: Fri Apr 20 21:40:31 2012 New Revision: 234505 URL: http://svn.freebsd.org/changeset/base/234505 Log: MFC: r233045, r234302 r233045: Add rudimentary profiling of the hash table used in the umtx code to hold active lock queues. r234302: Fix some style bugs introduced in a previous commit (r233045) Approved by: gnn (mentor) Modified: stable/9/sys/conf/NOTES stable/9/sys/conf/options stable/9/sys/kern/kern_umtx.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/conf/ (props changed) Modified: stable/9/sys/conf/NOTES ============================================================================== --- stable/9/sys/conf/NOTES Fri Apr 20 21:37:42 2012 (r234504) +++ stable/9/sys/conf/NOTES Fri Apr 20 21:40:31 2012 (r234505) @@ -275,6 +275,8 @@ options SX_NOINLINE # frequency. # TURNSTILE_PROFILING enables rudimentary profiling of the hash table # used to hold active lock queues. +# UMTX_PROFILING enables rudimentary profiling of the hash table used + to hold active lock queues. # WITNESS enables the witness code which detects deadlocks and cycles # during locking operations. # WITNESS_KDB causes the witness code to drop into the kernel debugger if @@ -298,8 +300,9 @@ options MPROF_HASH_SIZE="1543" # Profiling for internal hash tables. options SLEEPQUEUE_PROFILING options TURNSTILE_PROFILING +options UMTX_PROFILING + - ##################################################################### # COMPATIBILITY OPTIONS Modified: stable/9/sys/conf/options ============================================================================== --- stable/9/sys/conf/options Fri Apr 20 21:37:42 2012 (r234504) +++ stable/9/sys/conf/options Fri Apr 20 21:40:31 2012 (r234505) @@ -184,6 +184,7 @@ SYSVSEM opt_sysvipc.h SYSVSHM opt_sysvipc.h SW_WATCHDOG opt_watchdog.h TURNSTILE_PROFILING +UMTX_PROFILING VFS_AIO VERBOSE_SYSINIT opt_global.h WLCACHE opt_wavelan.h Modified: stable/9/sys/kern/kern_umtx.c ============================================================================== --- stable/9/sys/kern/kern_umtx.c Fri Apr 20 21:37:42 2012 (r234504) +++ stable/9/sys/kern/kern_umtx.c Fri Apr 20 21:40:31 2012 (r234505) @@ -29,6 +29,8 @@ __FBSDID("$FreeBSD$"); #include "opt_compat.h" +#include "opt_umtx_profiling.h" + #include #include #include @@ -154,6 +156,10 @@ struct umtxq_chain { /* All PI in the list */ TAILQ_HEAD(,umtx_pi) uc_pi_list; +#ifdef UMTX_PROFILING + int length; + int max_length; +#endif }; #define UMTXQ_LOCKED_ASSERT(uc) mtx_assert(&(uc)->uc_lock, MA_OWNED) @@ -190,6 +196,12 @@ SYSCTL_NODE(_debug, OID_AUTO, umtx, CTLF SYSCTL_INT(_debug_umtx, OID_AUTO, umtx_pi_allocated, CTLFLAG_RD, &umtx_pi_allocated, 0, "Allocated umtx_pi"); +#ifdef UMTX_PROFILING +static long max_length; +SYSCTL_LONG(_debug_umtx, OID_AUTO, max_length, CTLFLAG_RD, &max_length, 0, "max_length"); +static SYSCTL_NODE(_debug_umtx, OID_AUTO, chains, CTLFLAG_RD, 0, "umtx chain stats"); +#endif + static void umtxq_sysinit(void *); static void umtxq_hash(struct umtx_key *key); static struct umtxq_chain *umtxq_getchain(struct umtx_key *key); @@ -215,6 +227,27 @@ SYSINIT(umtx, SI_SUB_EVENTHANDLER+1, SI_ static struct mtx umtx_lock; +#ifdef UMTX_PROFILING +static void +umtx_init_profiling(void) +{ + struct sysctl_oid *chain_oid; + char chain_name[10]; + int i; + + for (i = 0; i < UMTX_CHAINS; ++i) { + snprintf(chain_name, sizeof(chain_name), "%d", i); + chain_oid = SYSCTL_ADD_NODE(NULL, + SYSCTL_STATIC_CHILDREN(_debug_umtx_chains), OID_AUTO, + chain_name, CTLFLAG_RD, NULL, "umtx hash stats"); + SYSCTL_ADD_INT(NULL, SYSCTL_CHILDREN(chain_oid), OID_AUTO, + "max_length0", CTLFLAG_RD, &umtxq_chains[0][i].max_length, 0, NULL); + SYSCTL_ADD_INT(NULL, SYSCTL_CHILDREN(chain_oid), OID_AUTO, + "max_length1", CTLFLAG_RD, &umtxq_chains[1][i].max_length, 0, NULL); + } +} +#endif + static void umtxq_sysinit(void *arg __unused) { @@ -232,8 +265,15 @@ umtxq_sysinit(void *arg __unused) TAILQ_INIT(&umtxq_chains[i][j].uc_pi_list); umtxq_chains[i][j].uc_busy = 0; umtxq_chains[i][j].uc_waiters = 0; +#ifdef UMTX_PROFILING + umtxq_chains[i][j].length = 0; + umtxq_chains[i][j].max_length = 0; +#endif } } +#ifdef UMTX_PROFILING + umtx_init_profiling(); +#endif mtx_init(&umtx_lock, "umtx lock", NULL, MTX_SPIN); EVENTHANDLER_REGISTER(process_exec, umtx_exec_hook, NULL, EVENTHANDLER_PRI_ANY); @@ -384,6 +424,14 @@ umtxq_insert_queue(struct umtx_q *uq, in TAILQ_INSERT_TAIL(&uh->head, uq, uq_link); uh->length++; +#ifdef UMTX_PROFILING + uc->length++; + if (uc->length > uc->max_length) { + uc->max_length = uc->length; + if (uc->max_length > max_length) + max_length = uc->max_length; + } +#endif uq->uq_flags |= UQF_UMTXQ; uq->uq_cur_queue = uh; return; @@ -401,6 +449,9 @@ umtxq_remove_queue(struct umtx_q *uq, in uh = uq->uq_cur_queue; TAILQ_REMOVE(&uh->head, uq, uq_link); uh->length--; +#ifdef UMTX_PROFILING + uc->length--; +#endif uq->uq_flags &= ~UQF_UMTXQ; if (TAILQ_EMPTY(&uh->head)) { KASSERT(uh->length == 0, From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 21:43:20 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9A210106566B; Fri, 20 Apr 2012 21:43:20 +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 851AF8FC08; Fri, 20 Apr 2012 21:43:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KLhKtw056798; Fri, 20 Apr 2012 21:43:20 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KLhKWW056796; Fri, 20 Apr 2012 21:43:20 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204202143.q3KLhKWW056796@svn.freebsd.org> From: Dimitry Andric Date: Fri, 20 Apr 2012 21:43: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: r234506 - head/sys/dev/nxge X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 21:43:20 -0000 Author: dim Date: Fri Apr 20 21:43:19 2012 New Revision: 234506 URL: http://svn.freebsd.org/changeset/base/234506 Log: Fix the following compilation warnings in nxge(4): sys/dev/nxge/if_nxge.c:1276:11: error: case value not in enumerated type 'xge_hal_event_e' (aka 'enum xge_hal_event_e') [-Werror,-Wswitch] case XGE_LL_EVENT_TRY_XMIT_AGAIN: ^ sys/dev/nxge/if_nxge.c:1289:11: error: case value not in enumerated type 'xge_hal_event_e' (aka 'enum xge_hal_event_e') [-Werror,-Wswitch] case XGE_LL_EVENT_DEVICE_RESETTING: ^ This is because the switch uses xge_queue_item_t::event_type, which is an enum xge_hal_event_e, while the XGE_LL_EVENT_xx values are of the enum xge_event_e. Since messing around with the enum definitions is too disruptive, the simplest fix is to cast the argument of the switch to int. Reviewed by: gnn MFC after: 1 week Modified: head/sys/dev/nxge/if_nxge.c Modified: head/sys/dev/nxge/if_nxge.c ============================================================================== --- head/sys/dev/nxge/if_nxge.c Fri Apr 20 21:40:31 2012 (r234505) +++ head/sys/dev/nxge/if_nxge.c Fri Apr 20 21:43:19 2012 (r234506) @@ -1272,7 +1272,7 @@ xge_callback_event(xge_queue_item_t *ite lldev = xge_hal_device_private(hldev); ifnetp = lldev->ifnetp; - switch(item->event_type) { + switch((int)item->event_type) { case XGE_LL_EVENT_TRY_XMIT_AGAIN: if(lldev->initialized) { if(xge_hal_channel_dtr_count(lldev->fifo_channel[0]) > 0) { From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 21:52:57 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DB693106564A; Fri, 20 Apr 2012 21:52:57 +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 AD0B08FC0C; Fri, 20 Apr 2012 21:52:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KLqv7t057173; Fri, 20 Apr 2012 21:52:57 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KLqvWp057171; Fri, 20 Apr 2012 21:52:57 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204202152.q3KLqvWp057171@svn.freebsd.org> From: Dimitry Andric Date: Fri, 20 Apr 2012 21:52: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: r234507 - head/sys/contrib/rdma X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 21:52:58 -0000 Author: dim Date: Fri Apr 20 21:52:57 2012 New Revision: 234507 URL: http://svn.freebsd.org/changeset/base/234507 Log: Fix the following compilation warnings in sys/contrib/rdma/rdma_cma.c: sys/contrib/rdma/rdma_cma.c:1259:8: error: case value not in enumerated type 'enum iw_cm_event_status' [-Werror,-Wswitch] case ECONNRESET: ^ @/sys/errno.h:118:20: note: expanded from macro 'ECONNRESET' #define ECONNRESET 54 /* Connection reset by peer */ ^ sys/contrib/rdma/rdma_cma.c:1263:8: error: case value not in enumerated type 'enum iw_cm_event_status' [-Werror,-Wswitch] case ETIMEDOUT: ^ @/sys/errno.h:124:19: note: expanded from macro 'ETIMEDOUT' #define ETIMEDOUT 60 /* Operation timed out */ ^ sys/contrib/rdma/rdma_cma.c:1260:8: error: case value not in enumerated type 'enum iw_cm_event_status' [-Werror,-Wswitch] case ECONNREFUSED: ^ @/sys/errno.h:125:22: note: expanded from macro 'ECONNREFUSED' #define ECONNREFUSED 61 /* Connection refused */ ^ This is because the switch uses iw_cm_event::status, which is an enum iw_cm_event_status, while ECONNRESET, ETIMEDOUT and ECONNREFUSED are just plain defines from errno.h. It looks like there is only one use of any of the enumeration values of iw_cm_event_status, in: sys/contrib/rdma/rdma_iwcm.c: if (iw_event->status == IW_CM_EVENT_STATUS_ACCEPTED) { So messing around with the enum definitions to fix the warning seems too disruptive; the simplest fix is to cast the argument of the switch to int. Reviewed by: kmacy MFC after: 1 week Modified: head/sys/contrib/rdma/rdma_cma.c Modified: head/sys/contrib/rdma/rdma_cma.c ============================================================================== --- head/sys/contrib/rdma/rdma_cma.c Fri Apr 20 21:43:19 2012 (r234506) +++ head/sys/contrib/rdma/rdma_cma.c Fri Apr 20 21:52:57 2012 (r234507) @@ -1252,7 +1252,7 @@ static int cma_iw_handler(struct iw_cm_i *sin = iw_event->local_addr; sin = (struct sockaddr_in *) &id_priv->id.route.addr.dst_addr; *sin = iw_event->remote_addr; - switch (iw_event->status) { + switch ((int)iw_event->status) { case 0: event.event = RDMA_CM_EVENT_ESTABLISHED; break; From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 21:56:14 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 35E40106564A; Fri, 20 Apr 2012 21:56:14 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 13D4C8FC08; Fri, 20 Apr 2012 21:56:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KLuDPs057324; Fri, 20 Apr 2012 21:56:13 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KLuD58057320; Fri, 20 Apr 2012 21:56:13 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204202156.q3KLuD58057320@svn.freebsd.org> From: Adrian Chadd Date: Fri, 20 Apr 2012 21:56: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: r234508 - in head/sys/dev/ath/ath_hal: . ar9002 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 21:56:14 -0000 Author: adrian Date: Fri Apr 20 21:56:13 2012 New Revision: 234508 URL: http://svn.freebsd.org/changeset/base/234508 Log: "Upgrade" the AR9285 code to support PCI/ART EEPROM on flash. I've just verified that this boots on an Atheros AP91. I haven't verified it with traffic though, so YMMV. Modified: head/sys/dev/ath/ath_hal/ah_eeprom_v4k.c head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Modified: head/sys/dev/ath/ath_hal/ah_eeprom_v4k.c ============================================================================== --- head/sys/dev/ath/ath_hal/ah_eeprom_v4k.c Fri Apr 20 21:52:57 2012 (r234507) +++ head/sys/dev/ath/ath_hal/ah_eeprom_v4k.c Fri Apr 20 21:56:13 2012 (r234508) @@ -298,12 +298,12 @@ ath_hal_v4kEepromAttach(struct ath_hal * "%s Error reading Eeprom MAGIC\n", __func__); return HAL_EEREAD; } - } - HALDEBUG(ah, HAL_DEBUG_ATTACH, "%s Eeprom Magic = 0x%x\n", - __func__, magic); - if (magic != AR5416_EEPROM_MAGIC) { - HALDEBUG(ah, HAL_DEBUG_ANY, "Bad magic number\n"); - return HAL_EEMAGIC; + HALDEBUG(ah, HAL_DEBUG_ATTACH, "%s Eeprom Magic = 0x%x\n", + __func__, magic); + if (magic != AR5416_EEPROM_MAGIC) { + HALDEBUG(ah, HAL_DEBUG_ANY, "Bad magic number\n"); + return HAL_EEMAGIC; + } } ee = ath_hal_malloc(sizeof(HAL_EEPROM_v4k)); Modified: head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c Fri Apr 20 21:52:57 2012 (r234507) +++ head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c Fri Apr 20 21:56:13 2012 (r234508) @@ -169,7 +169,6 @@ ar9280Attach(uint16_t devid, HAL_SOFTC s ar5416InitState(AH5416(ah), devid, sc, st, sh, status); - /* * Use the "local" EEPROM data given to us by the higher layers. * This is a private copy out of system flash. The Linux ath9k @@ -180,7 +179,6 @@ ar9280Attach(uint16_t devid, HAL_SOFTC s AH_PRIVATE((ah))->ah_eepromRead = ath_hal_EepromDataRead; AH_PRIVATE((ah))->ah_eepromWrite = NULL; ah->ah_eepromdata = eepromdata; - } /* XXX override with 9280 specific state */ /* override 5416 methods for our needs */ Modified: head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Fri Apr 20 21:52:57 2012 (r234507) +++ head/sys/dev/ath/ath_hal/ar9002/ar9285_attach.c Fri Apr 20 21:56:13 2012 (r234508) @@ -134,6 +134,18 @@ ar9285Attach(uint16_t devid, HAL_SOFTC s ar5416InitState(AH5416(ah), devid, sc, st, sh, status); + /* + * Use the "local" EEPROM data given to us by the higher layers. + * This is a private copy out of system flash. The Linux ath9k + * commit for the initial AR9130 support mentions MMIO flash + * access is "unreliable." -adrian + */ + if (eepromdata != AH_NULL) { + AH_PRIVATE(ah)->ah_eepromRead = ath_hal_EepromDataRead; + AH_PRIVATE(ah)->ah_eepromWrite = NULL; + ah->ah_eepromdata = eepromdata; + } + /* XXX override with 9285 specific state */ /* override 5416 methods for our needs */ AH5416(ah)->ah_initPLL = ar9280InitPLL; From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 22:01:13 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 381AF106564A; Fri, 20 Apr 2012 22:01:13 +0000 (UTC) (envelope-from davide@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 18AA28FC17; Fri, 20 Apr 2012 22:01:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KM1Cq1057553; Fri, 20 Apr 2012 22:01:12 GMT (envelope-from davide@svn.freebsd.org) Received: (from davide@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KM1Cxn057549; Fri, 20 Apr 2012 22:01:12 GMT (envelope-from davide@svn.freebsd.org) Message-Id: <201204202201.q3KM1Cxn057549@svn.freebsd.org> From: Davide Italiano Date: Fri, 20 Apr 2012 22:01:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234509 - in stable/8/sys: conf kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 22:01:13 -0000 Author: davide Date: Fri Apr 20 22:01:12 2012 New Revision: 234509 URL: http://svn.freebsd.org/changeset/base/234509 Log: MFC: r233045, r234302 r233045: Add rudimentary profiling of the hash table used in the umtx code to hold active lock queues. r234302: Fix some style bugs introduced in a previous commit (r233045) Approved by: gnn (mentor) Modified: stable/8/sys/conf/NOTES stable/8/sys/conf/options stable/8/sys/kern/kern_umtx.c Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/conf/NOTES ============================================================================== --- stable/8/sys/conf/NOTES Fri Apr 20 21:56:13 2012 (r234508) +++ stable/8/sys/conf/NOTES Fri Apr 20 22:01:12 2012 (r234509) @@ -262,6 +262,8 @@ options SX_NOINLINE # frequency. # TURNSTILE_PROFILING enables rudimentary profiling of the hash table # used to hold active lock queues. +# UMTX_PROFILING enables rudimentary profiling of the hash table used + to hold active lock queues. # WITNESS enables the witness code which detects deadlocks and cycles # during locking operations. # WITNESS_KDB causes the witness code to drop into the kernel debugger if @@ -285,8 +287,9 @@ options MPROF_HASH_SIZE="1543" # Profiling for internal hash tables. options SLEEPQUEUE_PROFILING options TURNSTILE_PROFILING +options UMTX_PROFILING + - ##################################################################### # COMPATIBILITY OPTIONS Modified: stable/8/sys/conf/options ============================================================================== --- stable/8/sys/conf/options Fri Apr 20 21:56:13 2012 (r234508) +++ stable/8/sys/conf/options Fri Apr 20 22:01:12 2012 (r234509) @@ -179,6 +179,7 @@ SYSVSEM opt_sysvipc.h SYSVSHM opt_sysvipc.h SW_WATCHDOG opt_watchdog.h TURNSTILE_PROFILING +UMTX_PROFILING VFS_AIO VERBOSE_SYSINIT opt_global.h WLCACHE opt_wavelan.h Modified: stable/8/sys/kern/kern_umtx.c ============================================================================== --- stable/8/sys/kern/kern_umtx.c Fri Apr 20 21:56:13 2012 (r234508) +++ stable/8/sys/kern/kern_umtx.c Fri Apr 20 22:01:12 2012 (r234509) @@ -29,6 +29,8 @@ __FBSDID("$FreeBSD$"); #include "opt_compat.h" +#include "opt_umtx_profiling.h" + #include #include #include @@ -134,6 +136,10 @@ struct umtxq_chain { /* All PI in the list */ TAILQ_HEAD(,umtx_pi) uc_pi_list; +#ifdef UMTX_PROFILING + int length; + int max_length; +#endif }; #define UMTXQ_LOCKED_ASSERT(uc) mtx_assert(&(uc)->uc_lock, MA_OWNED) @@ -170,6 +176,12 @@ SYSCTL_NODE(_debug, OID_AUTO, umtx, CTLF SYSCTL_INT(_debug_umtx, OID_AUTO, umtx_pi_allocated, CTLFLAG_RD, &umtx_pi_allocated, 0, "Allocated umtx_pi"); +#ifdef UMTX_PROFILING +static long max_length; +SYSCTL_LONG(_debug_umtx, OID_AUTO, max_length, CTLFLAG_RD, &max_length, 0, "max_length"); +static SYSCTL_NODE(_debug_umtx, OID_AUTO, chains, CTLFLAG_RD, 0, "umtx chain stats"); +#endif + static void umtxq_sysinit(void *); static void umtxq_hash(struct umtx_key *key); static struct umtxq_chain *umtxq_getchain(struct umtx_key *key); @@ -196,6 +208,27 @@ SYSINIT(umtx, SI_SUB_EVENTHANDLER+1, SI_ static struct mtx umtx_lock; +#ifdef UMTX_PROFILING +static void +umtx_init_profiling(void) +{ + struct sysctl_oid *chain_oid; + char chain_name[10]; + int i; + + for (i = 0; i < UMTX_CHAINS; ++i) { + snprintf(chain_name, sizeof(chain_name), "%d", i); + chain_oid = SYSCTL_ADD_NODE(NULL, + SYSCTL_STATIC_CHILDREN(_debug_umtx_chains), OID_AUTO, + chain_name, CTLFLAG_RD, NULL, "umtx hash stats"); + SYSCTL_ADD_INT(NULL, SYSCTL_CHILDREN(chain_oid), OID_AUTO, + "max_length0", CTLFLAG_RD, &umtxq_chains[0][i].max_length, 0, NULL); + SYSCTL_ADD_INT(NULL, SYSCTL_CHILDREN(chain_oid), OID_AUTO, + "max_length1", CTLFLAG_RD, &umtxq_chains[1][i].max_length, 0, NULL); + } +} +#endif + static void umtxq_sysinit(void *arg __unused) { @@ -212,8 +245,15 @@ umtxq_sysinit(void *arg __unused) TAILQ_INIT(&umtxq_chains[i][j].uc_pi_list); umtxq_chains[i][j].uc_busy = 0; umtxq_chains[i][j].uc_waiters = 0; +#ifdef UMTX_PROFILING + umtxq_chains[i][j].length = 0; + umtxq_chains[i][j].max_length = 0; +#endif } } +#ifdef UMTX_PROFILING + umtx_init_profiling(); +#endif mtx_init(&umtx_lock, "umtx lock", NULL, MTX_SPIN); EVENTHANDLER_REGISTER(process_exec, umtx_exec_hook, NULL, EVENTHANDLER_PRI_ANY); @@ -331,6 +371,14 @@ umtxq_insert_queue(struct umtx_q *uq, in uc = umtxq_getchain(&uq->uq_key); UMTXQ_LOCKED_ASSERT(uc); TAILQ_INSERT_TAIL(&uc->uc_queue[q], uq, uq_link); +#ifdef UMTX_PROFILING + uc->length++; + if (uc->length > uc->max_length) { + uc->max_length = uc->length; + if (uc->max_length > max_length) + max_length = uc->max_length; + } +#endif uq->uq_flags |= UQF_UMTXQ; } @@ -343,6 +391,9 @@ umtxq_remove_queue(struct umtx_q *uq, in UMTXQ_LOCKED_ASSERT(uc); if (uq->uq_flags & UQF_UMTXQ) { TAILQ_REMOVE(&uc->uc_queue[q], uq, uq_link); +#ifdef UMTX_PROFILING + uc->length--; +#endif uq->uq_flags &= ~UQF_UMTXQ; } } From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 22:07:22 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C1B0A106567E; Fri, 20 Apr 2012 22:07:22 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 70BCD8FC0A; Fri, 20 Apr 2012 22:07:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KM7M0h057771; Fri, 20 Apr 2012 22:07:22 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KM7MCu057769; Fri, 20 Apr 2012 22:07:22 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204202207.q3KM7MCu057769@svn.freebsd.org> From: Adrian Chadd Date: Fri, 20 Apr 2012 22:07: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: r234510 - head/sys/dev/ath/ath_hal/ar9002 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 22:07:22 -0000 Author: adrian Date: Fri Apr 20 22:07:21 2012 New Revision: 234510 URL: http://svn.freebsd.org/changeset/base/234510 Log: .. oops. Modified: head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c Modified: head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c ============================================================================== --- head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c Fri Apr 20 22:01:12 2012 (r234509) +++ head/sys/dev/ath/ath_hal/ar9002/ar9280_attach.c Fri Apr 20 22:07:21 2012 (r234510) @@ -179,6 +179,7 @@ ar9280Attach(uint16_t devid, HAL_SOFTC s AH_PRIVATE((ah))->ah_eepromRead = ath_hal_EepromDataRead; AH_PRIVATE((ah))->ah_eepromWrite = NULL; ah->ah_eepromdata = eepromdata; + } /* XXX override with 9280 specific state */ /* override 5416 methods for our needs */ From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 22:14:27 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9541D106564A; Fri, 20 Apr 2012 22:14:27 +0000 (UTC) (envelope-from rmh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 662208FC12; Fri, 20 Apr 2012 22:14:27 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KMERZ7058062; Fri, 20 Apr 2012 22:14:27 GMT (envelope-from rmh@svn.freebsd.org) Received: (from rmh@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KMERvu058060; Fri, 20 Apr 2012 22:14:27 GMT (envelope-from rmh@svn.freebsd.org) Message-Id: <201204202214.q3KMERvu058060@svn.freebsd.org> From: Robert Millan Date: Fri, 20 Apr 2012 22:14:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234511 - in stable/9/sys: fs/tmpfs i386/conf kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 22:14:27 -0000 Author: rmh Date: Fri Apr 20 22:14:26 2012 New Revision: 234511 URL: http://svn.freebsd.org/changeset/base/234511 Log: MFC of r227310: Don astbestos garment and remove the warning about TMPFS being experimental -- highly experimental even. So far the closest to a bug in TMPFS that people have gotten to relates to how ZFS can take away from the memory that TMPFS needs. One can argue that such is not a bug in TMPFS. Irrespective, even if there is a bug here and there in TMPFS, it's not in our own advantage to scare people away from using TMPFS. I for one have been using it, even with ZFS, very successfully. Reviewed by: marcel Modified: stable/9/sys/fs/tmpfs/tmpfs_vfsops.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/fs/tmpfs/tmpfs_vfsops.c ============================================================================== --- stable/9/sys/fs/tmpfs/tmpfs_vfsops.c Fri Apr 20 22:07:21 2012 (r234510) +++ stable/9/sys/fs/tmpfs/tmpfs_vfsops.c Fri Apr 20 22:14:26 2012 (r234511) @@ -156,9 +156,6 @@ tmpfs_mount(struct mount *mp) return EOPNOTSUPP; } - printf("WARNING: TMPFS is considered to be a highly experimental " - "feature in FreeBSD.\n"); - vn_lock(mp->mnt_vnodecovered, LK_SHARED | LK_RETRY); error = VOP_GETATTR(mp->mnt_vnodecovered, &va, mp->mnt_cred); VOP_UNLOCK(mp->mnt_vnodecovered, 0); From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 22:16:08 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EDD481065670; Fri, 20 Apr 2012 22:16:08 +0000 (UTC) (envelope-from rmh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D81B98FC0A; Fri, 20 Apr 2012 22:16:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KMG8n9058198; Fri, 20 Apr 2012 22:16:08 GMT (envelope-from rmh@svn.freebsd.org) Received: (from rmh@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KMG81F058196; Fri, 20 Apr 2012 22:16:08 GMT (envelope-from rmh@svn.freebsd.org) Message-Id: <201204202216.q3KMG81F058196@svn.freebsd.org> From: Robert Millan Date: Fri, 20 Apr 2012 22:16:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234512 - in stable/8/sys: fs/tmpfs i386/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 22:16:09 -0000 Author: rmh Date: Fri Apr 20 22:16:08 2012 New Revision: 234512 URL: http://svn.freebsd.org/changeset/base/234512 Log: MFC of r227310: Don astbestos garment and remove the warning about TMPFS being experimental -- highly experimental even. So far the closest to a bug in TMPFS that people have gotten to relates to how ZFS can take away from the memory that TMPFS needs. One can argue that such is not a bug in TMPFS. Irrespective, even if there is a bug here and there in TMPFS, it's not in our own advantage to scare people away from using TMPFS. I for one have been using it, even with ZFS, very successfully. Reviewed by: marcel Modified: stable/8/sys/fs/tmpfs/tmpfs_vfsops.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/boot/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/e1000/ (props changed) stable/8/sys/i386/conf/XENHVM (props changed) Modified: stable/8/sys/fs/tmpfs/tmpfs_vfsops.c ============================================================================== --- stable/8/sys/fs/tmpfs/tmpfs_vfsops.c Fri Apr 20 22:14:26 2012 (r234511) +++ stable/8/sys/fs/tmpfs/tmpfs_vfsops.c Fri Apr 20 22:16:08 2012 (r234512) @@ -155,9 +155,6 @@ tmpfs_mount(struct mount *mp) return EOPNOTSUPP; } - printf("WARNING: TMPFS is considered to be a highly experimental " - "feature in FreeBSD.\n"); - vn_lock(mp->mnt_vnodecovered, LK_SHARED | LK_RETRY); error = VOP_GETATTR(mp->mnt_vnodecovered, &va, mp->mnt_cred); VOP_UNLOCK(mp->mnt_vnodecovered, 0); From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 22:27:11 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6AA18106566C; Fri, 20 Apr 2012 22:27:11 +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 54CC28FC0A; Fri, 20 Apr 2012 22:27:11 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KMRBmg058670; Fri, 20 Apr 2012 22:27:11 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KMRBOM058668; Fri, 20 Apr 2012 22:27:11 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201204202227.q3KMRBOM058668@svn.freebsd.org> From: Xin LI Date: Fri, 20 Apr 2012 22:27:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234513 - stable/8/sys/fs/tmpfs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 22:27:11 -0000 Author: delphij Date: Fri Apr 20 22:27:10 2012 New Revision: 234513 URL: http://svn.freebsd.org/changeset/base/234513 Log: MFC r227802: Improve the way to calculate available pages in tmpfs: - Don't deduct wired pages from total usable counts because it does not make any sense. To make things worse, on systems where swap size is smaller than physical memory and use a lot of wired pages (e.g. ZFS), tmpfs can suddenly have free space of 0 because of this; - Count cached pages as available; [1] - Don't count inactive pages as available, technically we could but that might be too aggressive; [1] [1] Suggested by kib@ Modified: stable/8/sys/fs/tmpfs/tmpfs.h Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/fs/tmpfs/tmpfs.h ============================================================================== --- stable/8/sys/fs/tmpfs/tmpfs.h Fri Apr 20 22:16:08 2012 (r234512) +++ stable/8/sys/fs/tmpfs/tmpfs.h Fri Apr 20 22:27:10 2012 (r234513) @@ -483,11 +483,8 @@ int tmpfs_truncate(struct vnode *, off_t static __inline size_t tmpfs_mem_info(void) { - size_t size; - size = swap_pager_avail + cnt.v_free_count + cnt.v_inactive_count; - size -= size > cnt.v_wire_count ? cnt.v_wire_count : size; - return size; + return (swap_pager_avail + cnt.v_free_count + cnt.v_cache_count); } /* Returns the maximum size allowed for a tmpfs file system. This macro From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 22:43:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C179B106564A; Fri, 20 Apr 2012 22:43:04 +0000 (UTC) (envelope-from davide@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AB28C8FC0A; Fri, 20 Apr 2012 22:43:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KMh4H5059160; Fri, 20 Apr 2012 22:43:04 GMT (envelope-from davide@svn.freebsd.org) Received: (from davide@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KMh4ua059158; Fri, 20 Apr 2012 22:43:04 GMT (envelope-from davide@svn.freebsd.org) Message-Id: <201204202243.q3KMh4ua059158@svn.freebsd.org> From: Davide Italiano Date: Fri, 20 Apr 2012 22:43:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234514 - stable/9/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 22:43:04 -0000 Author: davide Date: Fri Apr 20 22:43:04 2012 New Revision: 234514 URL: http://svn.freebsd.org/changeset/base/234514 Log: MFC: r234303 Fix a typo. Approved by: gnn (mentor) Modified: stable/9/sys/kern/subr_turnstile.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/subr_turnstile.c ============================================================================== --- stable/9/sys/kern/subr_turnstile.c Fri Apr 20 22:27:10 2012 (r234513) +++ stable/9/sys/kern/subr_turnstile.c Fri Apr 20 22:43:04 2012 (r234514) @@ -142,7 +142,7 @@ SYSCTL_NODE(_debug, OID_AUTO, turnstile, SYSCTL_NODE(_debug_turnstile, OID_AUTO, chains, CTLFLAG_RD, 0, "turnstile chain stats"); SYSCTL_UINT(_debug_turnstile, OID_AUTO, max_depth, CTLFLAG_RD, - &turnstile_max_depth, 0, "maxmimum depth achieved of a single chain"); + &turnstile_max_depth, 0, "maximum depth achieved of a single chain"); #endif static struct mtx td_contested_lock; static struct turnstile_chain turnstile_chains[TC_TABLESIZE]; From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 22:44:00 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D40DF106564A; Fri, 20 Apr 2012 22:44:00 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BE6A08FC12; Fri, 20 Apr 2012 22:44:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KMi08a059223; Fri, 20 Apr 2012 22:44:00 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KMi0bd059221; Fri, 20 Apr 2012 22:44:00 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204202244.q3KMi0bd059221@svn.freebsd.org> From: Adrian Chadd Date: Fri, 20 Apr 2012 22:44: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: r234515 - head/sys/mips/atheros X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 22:44:00 -0000 Author: adrian Date: Fri Apr 20 22:44:00 2012 New Revision: 234515 URL: http://svn.freebsd.org/changeset/base/234515 Log: Allow for a default GPIO pin "high", which is required for some boards which tie the USB device enable to a GPIO line. Submitted by: Stefan Bethke Modified: head/sys/mips/atheros/ar71xx_gpio.c Modified: head/sys/mips/atheros/ar71xx_gpio.c ============================================================================== --- head/sys/mips/atheros/ar71xx_gpio.c Fri Apr 20 22:43:04 2012 (r234514) +++ head/sys/mips/atheros/ar71xx_gpio.c Fri Apr 20 22:44:00 2012 (r234515) @@ -329,7 +329,7 @@ ar71xx_gpio_attach(device_t dev) struct ar71xx_gpio_softc *sc = device_get_softc(dev); int error = 0; int i, j, maxpin; - int mask; + int mask, pinon; int old = 0; KASSERT((device_get_unit(dev) == 0), @@ -394,6 +394,9 @@ ar71xx_gpio_attach(device_t dev) if (resource_int_value(device_get_name(dev), device_get_unit(dev), "pinmask", &mask) != 0) mask = 0; + if (resource_int_value(device_get_name(dev), device_get_unit(dev), + "pinon", &pinon) != 0) + pinon = 0; device_printf(dev, "gpio pinmask=0x%x\n", mask); for (i = 0, j = 0; j < maxpin; j++) { if ((mask & (1 << j)) == 0) @@ -407,6 +410,11 @@ ar71xx_gpio_attach(device_t dev) i++; } sc->gpio_npins = i; + for (i = 0; i < sc->gpio_npins; i++) { + j = sc->gpio_pins[i].gp_pin; + if ((pinon & (1 << j)) != 0) + ar71xx_gpio_pin_set(dev, j, 1); + } device_add_child(dev, "gpioc", device_get_unit(dev)); device_add_child(dev, "gpiobus", device_get_unit(dev)); return (bus_generic_attach(dev)); From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 23:00:37 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 867B7106566B; Fri, 20 Apr 2012 23:00:37 +0000 (UTC) (envelope-from davide@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7071D8FC08; Fri, 20 Apr 2012 23:00:37 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KN0bFE059830; Fri, 20 Apr 2012 23:00:37 GMT (envelope-from davide@svn.freebsd.org) Received: (from davide@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KN0bqV059828; Fri, 20 Apr 2012 23:00:37 GMT (envelope-from davide@svn.freebsd.org) Message-Id: <201204202300.q3KN0bqV059828@svn.freebsd.org> From: Davide Italiano Date: Fri, 20 Apr 2012 23:00:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234516 - stable/8/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 23:00:37 -0000 Author: davide Date: Fri Apr 20 23:00:37 2012 New Revision: 234516 URL: http://svn.freebsd.org/changeset/base/234516 Log: MFC: r234303 Fix a typo. Approved by: gnn (mentor) Modified: stable/8/sys/kern/subr_turnstile.c Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/kern/subr_turnstile.c ============================================================================== --- stable/8/sys/kern/subr_turnstile.c Fri Apr 20 22:44:00 2012 (r234515) +++ stable/8/sys/kern/subr_turnstile.c Fri Apr 20 23:00:37 2012 (r234516) @@ -142,7 +142,7 @@ SYSCTL_NODE(_debug, OID_AUTO, turnstile, SYSCTL_NODE(_debug_turnstile, OID_AUTO, chains, CTLFLAG_RD, 0, "turnstile chain stats"); SYSCTL_UINT(_debug_turnstile, OID_AUTO, max_depth, CTLFLAG_RD, - &turnstile_max_depth, 0, "maxmimum depth achieved of a single chain"); + &turnstile_max_depth, 0, "maximum depth achieved of a single chain"); #endif static struct mtx td_contested_lock; static struct turnstile_chain turnstile_chains[TC_TABLESIZE]; From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 23:01:36 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AE8E61065670; Fri, 20 Apr 2012 23:01:36 +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 991B28FC22; Fri, 20 Apr 2012 23:01:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KN1aPr059901; Fri, 20 Apr 2012 23:01:36 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KN1aAq059898; Fri, 20 Apr 2012 23:01:36 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201204202301.q3KN1aAq059898@svn.freebsd.org> From: Nathan Whitehorn Date: Fri, 20 Apr 2012 23:01:36 +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: r234517 - head/sys/powerpc/aim X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 23:01:36 -0000 Author: nwhitehorn Date: Fri Apr 20 23:01:36 2012 New Revision: 234517 URL: http://svn.freebsd.org/changeset/base/234517 Log: Make sure all pending operations have completed on the existing thread before (potentially) migrating it to a different CPU. MFC after: 5 days Modified: head/sys/powerpc/aim/swtch32.S head/sys/powerpc/aim/swtch64.S Modified: head/sys/powerpc/aim/swtch32.S ============================================================================== --- head/sys/powerpc/aim/swtch32.S Fri Apr 20 23:00:37 2012 (r234516) +++ head/sys/powerpc/aim/swtch32.S Fri Apr 20 23:01:36 2012 (r234517) @@ -113,6 +113,7 @@ ENTRY(cpu_switch) mr %r3,%r14 /* restore old thread ptr */ bl pmap_deactivate /* Deactivate the current pmap */ + sync /* Make sure all of that finished */ stw %r16,TD_LOCK(%r14) /* ULE: update old thread's lock */ cpu_switchin: Modified: head/sys/powerpc/aim/swtch64.S ============================================================================== --- head/sys/powerpc/aim/swtch64.S Fri Apr 20 23:00:37 2012 (r234516) +++ head/sys/powerpc/aim/swtch64.S Fri Apr 20 23:01:36 2012 (r234517) @@ -139,6 +139,7 @@ ENTRY(cpu_switch) addi %r1,%r1,48 + sync /* Make sure all of that finished */ std %r16,TD_LOCK(%r14) /* ULE: update old thread's lock */ cpu_switchin: From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 23:39:48 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DBD21106566B; Fri, 20 Apr 2012 23:39:48 +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 C0C4D8FC08; Fri, 20 Apr 2012 23:39:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KNdmjR061104; Fri, 20 Apr 2012 23:39:48 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KNdmQU061095; Fri, 20 Apr 2012 23:39:48 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204202339.q3KNdmQU061095@svn.freebsd.org> From: Jung-uk Kim Date: Fri, 20 Apr 2012 23:39:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org X-SVN-Group: vendor-sys MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234518 - in vendor-sys/acpica/dist: . generate/unix/iasl source/compiler source/components/debugger source/components/events source/components/executer source/components/hardware sourc... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 23:39:49 -0000 Author: jkim Date: Fri Apr 20 23:39:48 2012 New Revision: 234518 URL: http://svn.freebsd.org/changeset/base/234518 Log: Import ACPICA 20120420. Added: vendor-sys/acpica/dist/source/compiler/aslsupport.l Modified: vendor-sys/acpica/dist/changes.txt vendor-sys/acpica/dist/generate/unix/iasl/Makefile vendor-sys/acpica/dist/source/compiler/Makefile vendor-sys/acpica/dist/source/compiler/aslcompile.c vendor-sys/acpica/dist/source/compiler/aslcompiler.h vendor-sys/acpica/dist/source/compiler/aslcompiler.l vendor-sys/acpica/dist/source/compiler/aslcompiler.y vendor-sys/acpica/dist/source/compiler/aslerror.c vendor-sys/acpica/dist/source/compiler/aslfiles.c vendor-sys/acpica/dist/source/compiler/aslglobal.h vendor-sys/acpica/dist/source/compiler/aslmain.c vendor-sys/acpica/dist/source/compiler/aslmap.c vendor-sys/acpica/dist/source/compiler/aslrestype1.c vendor-sys/acpica/dist/source/compiler/aslstartup.c vendor-sys/acpica/dist/source/compiler/dtio.c vendor-sys/acpica/dist/source/compiler/preprocess.h vendor-sys/acpica/dist/source/compiler/prscan.c vendor-sys/acpica/dist/source/compiler/prutils.c vendor-sys/acpica/dist/source/components/debugger/dbcmds.c vendor-sys/acpica/dist/source/components/debugger/dbdisply.c vendor-sys/acpica/dist/source/components/debugger/dbstats.c vendor-sys/acpica/dist/source/components/debugger/dbutils.c vendor-sys/acpica/dist/source/components/events/evmisc.c vendor-sys/acpica/dist/source/components/events/evxface.c vendor-sys/acpica/dist/source/components/executer/exdump.c vendor-sys/acpica/dist/source/components/hardware/hwesleep.c vendor-sys/acpica/dist/source/components/utilities/utdelete.c vendor-sys/acpica/dist/source/components/utilities/utglobal.c vendor-sys/acpica/dist/source/components/utilities/uttrack.c vendor-sys/acpica/dist/source/include/acglobal.h vendor-sys/acpica/dist/source/include/aclocal.h vendor-sys/acpica/dist/source/include/acobject.h vendor-sys/acpica/dist/source/include/acpixf.h vendor-sys/acpica/dist/source/include/actypes.h vendor-sys/acpica/dist/source/tools/acpiexec/aehandlers.c vendor-sys/acpica/dist/source/tools/acpisrc/astable.c vendor-sys/acpica/dist/tests/misc/grammar.asl Modified: vendor-sys/acpica/dist/changes.txt ============================================================================== --- vendor-sys/acpica/dist/changes.txt Fri Apr 20 23:01:36 2012 (r234517) +++ vendor-sys/acpica/dist/changes.txt Fri Apr 20 23:39:48 2012 (r234518) @@ -1,4 +1,71 @@ ---------------------------------------- +20 April 2012. Summary of changes for version 20120420: + +This release is available at www.acpica.org/downloads. +The ACPI 5.0 specification is available at www.acpi.info. + +1) ACPICA Core Subsystem: + +Implemented support for multiple notify handlers. This change adds support to +allow multiple system and device notify handlers on Device, Thermal Zone, and +Processor objects. This can simplify the host OS notification implementation. +Also re-worked and restructured the entire notify support code to simplify +handler installation, handler removal, notify event queuing, and notify +dispatch to handler(s). Note: there can still only be two global notify +handlers - one for system notifies and one for device notifies. There are no +changes to the existing handler install/remove interfaces. Lin Ming, Bob +Moore, Rafael Wysocki. + +Fixed a regression in the package repair code where the object reference +count was calculated incorrectly. Regression was introduced in the commit +"Support to add Package wrappers". + +Fixed a couple possible memory leaks in the AML parser, in the error recovery +path. Jesper Juhl, Lin Ming. + +Example Code and Data Size: These are the sizes for the OS-independent +acpica.lib produced by the Microsoft Visual C++ 9.0 32-bit compiler. The +debug version of the code includes the debug output trace mechanism and has a +much larger code and data size. + + Previous Release: + Non-Debug Version: 92.9K Code, 25.0K Data, 117.9K Total + Debug Version: 172.5K Code, 73.2K Data, 245.7K Total + Current Release: + Non-Debug Version: 92.9K Code, 25.0K Data, 117.9K Total + Debug Version: 172.6K Code, 73.4K Data, 246.0K Total + + +2) iASL Compiler/Disassembler and Tools: + +iASL: Fixed a problem with the resource descriptor support where the length +of the StartDependentFn and StartDependentFnNoPrio descriptors were not +included in cumulative descriptor offset, resulting in incorrect values for +resource tags within resource descriptors appearing after a StartDependent* +descriptor. Reported by Petr Vandrovec. ACPICA BZ 949. + +iASL and Preprocessor: Implemented full support for the #line directive to +correctly track original source file line numbers through the .i preprocessor +output file - for error and warning messages. + +iASL: Expand the allowable byte constants for address space IDs. Previously, +the allowable range was 0x80-0xFF (user-defined spaces), now the range is +0x0A-0xFF to allow for custom and new IDs without changing the compiler. + +iASL: Add option to treat all warnings as errors (-we). ACPICA BZ 948. + +iASL: Add option to completely disable the preprocessor (-Pn). + +iASL: Now emit all error/warning messages to standard error (stderr) by +default (instead of the previous stdout). + +ASL Test Suite (ASLTS): Reduce iASL warnings due to use of Switch(). Update +for resource descriptor offset fix above. Update/cleanup error output +routines. Enable and send iASL errors/warnings to an error logfile +(error.txt). Send all other iASL output to a logfile (compiler.txt). Fixed +several extraneous "unrecognized operator" messages. + +---------------------------------------- 20 March 2012. Summary of changes for version 20120320: This release is available at www.acpica.org/downloads. Modified: vendor-sys/acpica/dist/generate/unix/iasl/Makefile ============================================================================== --- vendor-sys/acpica/dist/generate/unix/iasl/Makefile Fri Apr 20 23:01:36 2012 (r234517) +++ vendor-sys/acpica/dist/generate/unix/iasl/Makefile Fri Apr 20 23:39:48 2012 (r234518) @@ -217,8 +217,8 @@ $(PROG) : $(INTERMEDIATES) $(MISC) $(OBJ # # Parser and Lexer - intermediate C files # -$(OBJDIR)/aslcompilerlex.c : $(ASL_COMPILER)/aslcompiler.l - ${LEX} ${LFLAGS} -PAslCompiler -o$@ $? +$(OBJDIR)/aslcompilerlex.c : $(ASL_COMPILER)/aslcompiler.l $(ASL_COMPILER)/aslsupport.l + ${LEX} ${LFLAGS} -PAslCompiler -o$@ $(ASL_COMPILER)/aslcompiler.l $(OBJDIR)/aslcompilerparse.c $(OBJDIR)/aslcompilerparse.h : $(ASL_COMPILER)/aslcompiler.y ${YACC} ${YFLAGS} -pAslCompiler -o$@ $? Modified: vendor-sys/acpica/dist/source/compiler/Makefile ============================================================================== --- vendor-sys/acpica/dist/source/compiler/Makefile Fri Apr 20 23:01:36 2012 (r234517) +++ vendor-sys/acpica/dist/source/compiler/Makefile Fri Apr 20 23:39:48 2012 (r234518) @@ -289,8 +289,8 @@ $(PROG) : $(INTERMEDIATES) $(MISC) $(OBJ # # Parser and Lexer - intermediate C files # -aslcompilerlex.c : $(ASL_COMPILER)/aslcompiler.l - ${LEX} ${LFLAGS} -PAslCompiler -o$@ $? +aslcompilerlex.c : $(ASL_COMPILER)/aslcompiler.l $(ASL_COMPILER)/aslsupport.l + ${LEX} ${LFLAGS} -PAslCompiler -o$@ $(ASL_COMPILER)/aslcompiler.l aslcompilerparse.c aslcompilerparse.h : $(ASL_COMPILER)/aslcompiler.y ${YACC} ${YFLAGS} -pAslCompiler -o$@ $? Modified: vendor-sys/acpica/dist/source/compiler/aslcompile.c ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslcompile.c Fri Apr 20 23:01:36 2012 (r234517) +++ vendor-sys/acpica/dist/source/compiler/aslcompile.c Fri Apr 20 23:39:48 2012 (r234518) @@ -242,10 +242,10 @@ CmFlushSourceCode ( while (FlReadFile (ASL_FILE_INPUT, &Buffer, 1) != AE_ERROR) { - InsertLineBuffer ((int) Buffer); + AslInsertLineBuffer ((int) Buffer); } - ResetCurrentLineBuffer (); + AslResetCurrentLineBuffer (); } @@ -457,16 +457,20 @@ CmDoCompile ( Event = UtBeginEvent ("Open input and output files"); UtEndEvent (Event); - /* Preprocessor */ - Event = UtBeginEvent ("Preprocess input file"); - PrDoPreprocess (); - UtEndEvent (Event); - if (Gbl_PreprocessOnly) + if (Gbl_PreprocessFlag) { - CmCleanupAndExit (); - return 0; + /* Preprocessor */ + + PrDoPreprocess (); + if (Gbl_PreprocessOnly) + { + UtEndEvent (Event); + CmCleanupAndExit (); + return 0; + } } + UtEndEvent (Event); /* Build the parse tree */ @@ -483,8 +487,17 @@ CmDoCompile ( if (!RootNode) { - AslError (ASL_ERROR, ASL_MSG_COMPILER_INTERNAL, - NULL, "- Could not resolve parse tree root node"); + /* + * If there are no errors, then we have some sort of + * internal problem. + */ + Status = AslCheckForErrorExit (); + if (Status == AE_OK) + { + AslError (ASL_ERROR, ASL_MSG_COMPILER_INTERNAL, + NULL, "- Could not resolve parse tree root node"); + } + goto ErrorExit; } @@ -553,14 +566,14 @@ CmDoCompile ( if (Gbl_ParseOnlyFlag) { - AePrintErrorLog (ASL_FILE_STDOUT); - UtDisplaySummary (ASL_FILE_STDOUT); + AePrintErrorLog (ASL_FILE_STDERR); + UtDisplaySummary (ASL_FILE_STDERR); if (Gbl_DebugFlag) { - /* Print error summary to the debug file */ + /* Print error summary to the stdout also */ - AePrintErrorLog (ASL_FILE_STDERR); - UtDisplaySummary (ASL_FILE_STDERR); + AePrintErrorLog (ASL_FILE_STDOUT); + UtDisplaySummary (ASL_FILE_STDOUT); } UtEndEvent (FullCompile); return 0; @@ -756,12 +769,12 @@ CmCleanupAndExit ( UINT32 i; - AePrintErrorLog (ASL_FILE_STDOUT); + AePrintErrorLog (ASL_FILE_STDERR); if (Gbl_DebugFlag) { - /* Print error summary to the debug file */ + /* Print error summary to stdout also */ - AePrintErrorLog (ASL_FILE_STDERR); + AePrintErrorLog (ASL_FILE_STDOUT); } DbgPrint (ASL_DEBUG_OUTPUT, "\n\nElapsed time for major events\n\n"); @@ -837,7 +850,9 @@ CmCleanupAndExit ( /* Delete the preprocessor output file (.i) unless -li flag is set */ - if (!Gbl_PreprocessorOutputFlag && Gbl_Files[ASL_FILE_PREPROCESSOR].Filename) + if (!Gbl_PreprocessorOutputFlag && + Gbl_PreprocessFlag && + Gbl_Files[ASL_FILE_PREPROCESSOR].Filename) { if (remove (Gbl_Files[ASL_FILE_PREPROCESSOR].Filename)) { Modified: vendor-sys/acpica/dist/source/compiler/aslcompiler.h ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslcompiler.h Fri Apr 20 23:01:36 2012 (r234517) +++ vendor-sys/acpica/dist/source/compiler/aslcompiler.h Fri Apr 20 23:39:48 2012 (r234518) @@ -100,11 +100,11 @@ AslCompilerlex( void); void -ResetCurrentLineBuffer ( +AslResetCurrentLineBuffer ( void); void -InsertLineBuffer ( +AslInsertLineBuffer ( int SourceChar); int @@ -136,6 +136,11 @@ ACPI_STATUS AslDoOneFile ( char *Filename); +ACPI_STATUS +AslCheckForErrorExit ( + void); + + /* * aslcompile - compile mainline */ @@ -645,7 +650,11 @@ FlPrintFile ( void FlSetLineNumber ( - ACPI_PARSE_OBJECT *Op); + UINT32 LineNumber); + +void +FlSetFilename ( + char *Filename); ACPI_STATUS FlOpenInputFile ( Modified: vendor-sys/acpica/dist/source/compiler/aslcompiler.l ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslcompiler.l Fri Apr 20 23:01:36 2012 (r234517) +++ vendor-sys/acpica/dist/source/compiler/aslcompiler.l Fri Apr 20 23:39:48 2012 (r234518) @@ -58,20 +58,26 @@ YYSTYPE AslCompilerlval; */ #define _COMPONENT ACPI_COMPILER - ACPI_MODULE_NAME ("aslscan") + ACPI_MODULE_NAME ("aslscanner") + /* Local prototypes */ -char -comment (void); -char -comment2 (void); -void +static void +AslDoLineDirective (void); + +static char +AslDoComment (void); + +static char +AslDoCommentType2 (void); + +static char +AslDoStringLiteral (void); + +static void count (int type); -char -literal (void); -void -copy (void); + /*! [Begin] no source code translation */ @@ -104,10 +110,10 @@ NamePathTail [.]{NameSeg} [ \t] { count (0); } -"/*" { if (!comment ()) yyterminate (); } -"//" { if (!comment2 ()) yyterminate (); } +"/*" { if (!AslDoComment ()) yyterminate (); } +"//" { if (!AslDoCommentType2 ()) yyterminate (); } -"\"" { if (literal ()) return (PARSEOP_STRING_LITERAL); else yyterminate (); } +"\"" { if (AslDoStringLiteral ()) return (PARSEOP_STRING_LITERAL); else yyterminate (); } ";" { count (0); return(';'); } @@ -116,10 +122,16 @@ NamePathTail [.]{NameSeg} count (1); return (PARSEOP_INTEGER); } "Include" { count (1); return (PARSEOP_INCLUDE); } -"#include" { count (1); return (PARSEOP_INCLUDE_CSTYLE); } -"#line" { count (1); return (PARSEOP_LINE_CSTYLE); } "External" { count (1); return (PARSEOP_EXTERNAL); } + /* + * The #line directive is emitted by the preprocessor and handled + * here in the main iASL lexer - simply set the line number and + * optionally the current filename. + */ +"#line" { AslDoLineDirective ();} + + /**************************************************************************** * * Main ASL operators @@ -634,668 +646,7 @@ NamePathTail [.]{NameSeg} /*! [End] no source code translation !*/ -typedef struct asl_file_node -{ - FILE *File; - UINT32 CurrentLineNumber; - YY_BUFFER_STATE State; - char *Filename; - struct asl_file_node *Next; - -} ASL_FILE_NODE; - -ASL_FILE_NODE *InputStack = NULL; - - -/******************************************************************************* - * - * FUNCTION: AslPopInputFileStack - * - * PARAMETERS: None - * - * RETURN: 0 if a node was popped, -1 otherwise - * - * DESCRIPTION: Pop the top of the input file stack and point the parser to - * the saved parse buffer contained in the fnode. Also, set the - * global line counters to the saved values. This function is - * called when an include file reaches EOF. - * - ******************************************************************************/ - -int -AslPopInputFileStack ( - void) -{ - ASL_FILE_NODE *Fnode; - - - Fnode = InputStack; - DbgPrint (ASL_PARSE_OUTPUT, "\nPop InputFile Stack, Fnode %p\n\n", Fnode); - - - if (!Fnode) - { - return -1; - } - - /* Close the current include file */ - - fclose (yyin); - - /* Update the top-of-stack */ - - InputStack = Fnode->Next; - - /* Reset global line counter and filename */ - - Gbl_Files[ASL_FILE_INPUT].Filename = Fnode->Filename; - Gbl_CurrentLineNumber = Fnode->CurrentLineNumber; - - /* Point the parser to the popped file */ - - yy_delete_buffer (YY_CURRENT_BUFFER); - yy_switch_to_buffer (Fnode->State); - - /* All done with this node */ - - ACPI_FREE (Fnode); - return 0; -} - - -/******************************************************************************* - * - * FUNCTION: AslPushInputFileStack - * - * PARAMETERS: InputFile - Open file pointer - * Filename - Name of the file - * - * RETURN: None - * - * DESCRIPTION: Push the InputFile onto the file stack, and point the parser - * to this file. Called when an include file is successfully - * opened. - * - ******************************************************************************/ - -void -AslPushInputFileStack ( - FILE *InputFile, - char *Filename) -{ - ASL_FILE_NODE *Fnode; - YY_BUFFER_STATE State; - - - /* Save the current state in an Fnode */ - - Fnode = UtLocalCalloc (sizeof (ASL_FILE_NODE)); - - Fnode->File = yyin; - Fnode->Next = InputStack; - Fnode->State = YY_CURRENT_BUFFER; - Fnode->CurrentLineNumber = Gbl_CurrentLineNumber; - Fnode->Filename = Gbl_Files[ASL_FILE_INPUT].Filename; - - /* Push it on the stack */ - - InputStack = Fnode; - - /* Point the parser to this file */ - - State = yy_create_buffer (InputFile, YY_BUF_SIZE); - yy_switch_to_buffer (State); - - DbgPrint (ASL_PARSE_OUTPUT, "\nPush InputFile Stack, returning %p\n\n", InputFile); - - /* Reset the global line count and filename */ - - Gbl_Files[ASL_FILE_INPUT].Filename = Filename; - Gbl_CurrentLineNumber = 1; - yyin = InputFile; -} - - -/******************************************************************************* - * - * FUNCTION: ResetCurrentLineBuffer - * - * PARAMETERS: None - * - * RETURN: None - * - * DESCRIPTION: Reset the Line Buffer to zero, increment global line numbers. - * - ******************************************************************************/ - -void -ResetCurrentLineBuffer ( - void) -{ - - if (Gbl_Files[ASL_FILE_SOURCE_OUTPUT].Handle) - { - FlWriteFile (ASL_FILE_SOURCE_OUTPUT, Gbl_CurrentLineBuffer, - Gbl_LineBufPtr - Gbl_CurrentLineBuffer); - } - - Gbl_CurrentLineOffset += Gbl_CurrentColumn; - Gbl_CurrentColumn = 0; - - Gbl_CurrentLineNumber++; - Gbl_LogicalLineNumber++; - Gbl_LineBufPtr = Gbl_CurrentLineBuffer; -} - - -/******************************************************************************* - * - * FUNCTION: InsertLineBuffer - * - * PARAMETERS: SourceChar - One char from the input ASL source file - * - * RETURN: None - * - * DESCRIPTION: Put one character of the source file into the temp line buffer - * - ******************************************************************************/ - -#define ASL_SPACES_PER_TAB 4 - -void -InsertLineBuffer ( - int SourceChar) -{ - UINT32 i; - UINT32 Count = 1; - - - if (SourceChar == EOF) - { - return; - } - - Gbl_InputByteCount++; - - /* Handle tabs. Convert to spaces */ - - if (SourceChar == '\t') - { - SourceChar = ' '; - Count = ASL_SPACES_PER_TAB - - (Gbl_CurrentColumn & (ASL_SPACES_PER_TAB-1)); - } - - - for (i = 0; i < Count; i++) - { - Gbl_CurrentColumn++; - - /* Insert the character into the line buffer */ - - *Gbl_LineBufPtr = (UINT8) SourceChar; - Gbl_LineBufPtr++; - - if (Gbl_LineBufPtr > (Gbl_CurrentLineBuffer + (ASL_LINE_BUFFER_SIZE - 1))) - { -#if 0 - /* - * Warning if we have split a long source line. - * - */ - sprintf (MsgBuffer, "Max %u", ASL_LINE_BUFFER_SIZE); - AslCommonError (ASL_WARNING, ASL_MSG_LONG_LINE, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, MsgBuffer); -#endif - - ResetCurrentLineBuffer (); - } - else if (SourceChar == '\n') - { - /* End of line */ - - ResetCurrentLineBuffer (); - } - } -} - - -/******************************************************************************* - * - * FUNCTION: count - * - * PARAMETERS: yytext - Contains the matched keyword. - * Type - Keyword/Character type: - * 0 = anything except a keyword - * 1 = pseudo-keywords - * 2 = non-executable ASL keywords - * 3 = executable ASL keywords - * - * RETURN: None - * - * DESCRIPTION: Count keywords and put them into the line buffer - * - ******************************************************************************/ - -void -count ( - int Type) -{ - int i; - - - switch (Type) - { - case 2: - TotalKeywords++; - TotalNamedObjects++; - break; - - case 3: - TotalKeywords++; - TotalExecutableOpcodes++; - break; - } - - for (i = 0; (yytext[i] != 0) && (yytext[i] != EOF); i++) - { - InsertLineBuffer (yytext[i]); - *Gbl_LineBufPtr = 0; - } -} - - -/******************************************************************************* - * - * FUNCTION: comment - * - * PARAMETERS: none - * - * RETURN: none - * - * DESCRIPTION: Process a standard comment. - * - ******************************************************************************/ - -char -comment (void) -{ - char c; - char c1 = 0; - - - InsertLineBuffer ('/'); - InsertLineBuffer ('*'); - -loop: - - /* Eat chars until end-of-comment */ - - while ((c = (char) input()) != '*' && c != EOF) - { - InsertLineBuffer (c); - c1 = c; - } - - if (c == EOF) - { - goto EarlyEOF; - } - - /* - * Check for nested comment -- can help catch cases where a previous - * comment was accidently left unterminated - */ - if ((c1 == '/') && (c == '*')) - { - AslCommonError (ASL_WARNING, ASL_MSG_NESTED_COMMENT, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_InputByteCount, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, NULL); - } - - /* Comment is closed only if the NEXT character is a slash */ - - InsertLineBuffer (c); - - if ((c1 = (char) input()) != '/' && c1 != EOF) - { - unput(c1); - goto loop; - } - - if (c1 == EOF) - { - goto EarlyEOF; - } - - InsertLineBuffer (c1); - return TRUE; - - -EarlyEOF: - /* - * Premature End-Of-File - */ - AslCommonError (ASL_ERROR, ASL_MSG_EARLY_EOF, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, NULL); - return (FALSE); -} - - -/******************************************************************************* - * - * FUNCTION: comment - * - * PARAMETERS: none - * - * RETURN: none - * - * DESCRIPTION: Process a new "//" comment. - * - ******************************************************************************/ - -char -comment2 (void) -{ - char c; - - - InsertLineBuffer ('/'); - InsertLineBuffer ('/'); - - while ((c = (char) input()) != '\n' && c != EOF) - { - InsertLineBuffer (c); - } - - if (c == EOF) - { - /* End of file is OK, change to newline. Let parser detect EOF later */ - - c = '\n'; - } - - InsertLineBuffer (c); - return (TRUE); -} - - -/******************************************************************************* - * - * FUNCTION: literal - * - * PARAMETERS: none - * - * RETURN: none - * - * DESCRIPTION: Process a string literal (surrounded by quotes) - * - ******************************************************************************/ - -#define ASL_NORMAL_CHAR 0 -#define ASL_ESCAPE_SEQUENCE 1 -#define ASL_OCTAL_CONSTANT 2 -#define ASL_HEX_CONSTANT 3 - -char -literal (void) -{ - char *StringBuffer = MsgBuffer; - char *EndBuffer = MsgBuffer + ASL_MSG_BUFFER_SIZE; - char *CleanString; - char StringChar; - UINT32 State = ASL_NORMAL_CHAR; - UINT32 i = 0; - UINT8 Digit; - char ConvertBuffer[4]; - - - /* - * Eat chars until end-of-literal. - * NOTE: Put back the original surrounding quotes into the - * source line buffer. - */ - InsertLineBuffer ('\"'); - while ((StringChar = (char) input()) != EOF) - { - InsertLineBuffer (StringChar); - -DoCharacter: - - switch (State) - { - case ASL_NORMAL_CHAR: - - switch (StringChar) - { - case '\\': - /* - * Special handling for backslash-escape sequence. We will - * toss the backslash and translate the escape char(s). - */ - State = ASL_ESCAPE_SEQUENCE; - continue; - - case '\"': - - /* String terminator */ - - goto CompletedString; - } - break; - - - case ASL_ESCAPE_SEQUENCE: - - State = ASL_NORMAL_CHAR; - switch (StringChar) - { - case 'a': - StringChar = 0x07; /* BELL */ - break; - - case 'b': - StringChar = 0x08; /* BACKSPACE */ - break; - - case 'f': - StringChar = 0x0C; /* FORMFEED */ - break; - - case 'n': - StringChar = 0x0A; /* LINEFEED */ - break; - - case 'r': - StringChar = 0x0D; /* CARRIAGE RETURN*/ - break; - - case 't': - StringChar = 0x09; /* HORIZONTAL TAB */ - break; - - case 'v': - StringChar = 0x0B; /* VERTICAL TAB */ - break; - - case 'x': - State = ASL_HEX_CONSTANT; - i = 0; - continue; - - case '\'': /* Single Quote */ - case '\"': /* Double Quote */ - case '\\': /* Backslash */ - break; - - default: - - /* Check for an octal digit (0-7) */ - - if (ACPI_IS_OCTAL_DIGIT (StringChar)) - { - State = ASL_OCTAL_CONSTANT; - ConvertBuffer[0] = StringChar; - i = 1; - continue; - } - - /* Unknown escape sequence issue warning, but use the character */ - - AslCommonError (ASL_WARNING, ASL_MSG_INVALID_ESCAPE, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, NULL); - break; - } - break; - - - case ASL_OCTAL_CONSTANT: - - /* Up to three octal digits allowed */ - - if (!ACPI_IS_OCTAL_DIGIT (StringChar) || - (i > 2)) - { - /* - * Reached end of the constant. Convert the assembled ASCII - * string and resume processing of the next character - */ - ConvertBuffer[i] = 0; - Digit = (UINT8) ACPI_STRTOUL (ConvertBuffer, NULL, 8); - - /* Check for NULL or non-ascii character (ignore if so) */ - - if ((Digit == 0) || (Digit > ACPI_ASCII_MAX)) - { - AslCommonError (ASL_WARNING, ASL_MSG_INVALID_STRING, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, NULL); - } - else - { - *StringBuffer = (char) Digit; - StringBuffer++; - if (StringBuffer >= EndBuffer) - { - goto BufferOverflow; - } - } - - State = ASL_NORMAL_CHAR; - goto DoCharacter; - break; - } - - /* Append another digit of the constant */ - - ConvertBuffer[i] = StringChar; - i++; - continue; - - - case ASL_HEX_CONSTANT: - - /* Up to two hex digits allowed */ - - if (!ACPI_IS_XDIGIT (StringChar) || - (i > 1)) - { - /* - * Reached end of the constant. Convert the assembled ASCII - * string and resume processing of the next character - */ - ConvertBuffer[i] = 0; - Digit = (UINT8) ACPI_STRTOUL (ConvertBuffer, NULL, 16); - - /* Check for NULL or non-ascii character (ignore if so) */ - - if ((Digit == 0) || (Digit > ACPI_ASCII_MAX)) - { - AslCommonError (ASL_WARNING, ASL_MSG_INVALID_STRING, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, NULL); - } - else - { - *StringBuffer = (char) Digit; - StringBuffer++; - if (StringBuffer >= EndBuffer) - { - goto BufferOverflow; - } - } - - State = ASL_NORMAL_CHAR; - goto DoCharacter; - break; - } - - /* Append another digit of the constant */ - - ConvertBuffer[i] = StringChar; - i++; - continue; - } - - /* Save the finished character */ - - *StringBuffer = StringChar; - StringBuffer++; - if (StringBuffer >= EndBuffer) - { - goto BufferOverflow; - } - } - - /* - * Premature End-Of-File - */ - AslCommonError (ASL_ERROR, ASL_MSG_EARLY_EOF, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, NULL); - return (FALSE); - - -CompletedString: - /* - * Null terminate the input string and copy string to a new buffer - */ - *StringBuffer = 0; - - CleanString = UtGetStringBuffer (strlen (MsgBuffer) + 1); - if (!CleanString) - { - AslCommonError (ASL_ERROR, ASL_MSG_MEMORY_ALLOCATION, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, NULL); - return (FALSE); - } - - ACPI_STRCPY (CleanString, MsgBuffer); - AslCompilerlval.s = CleanString; - return (TRUE); - - -BufferOverflow: - - /* Literal was too long */ - - AslCommonError (ASL_ERROR, ASL_MSG_STRING_LENGTH, - Gbl_CurrentLineNumber, Gbl_LogicalLineNumber, - Gbl_CurrentLineOffset, Gbl_CurrentColumn, - Gbl_Files[ASL_FILE_INPUT].Filename, "Max length 4096"); - return (FALSE); -} - - +/* + * Bring in the scanner support routines + */ +#include "aslsupport.l" Modified: vendor-sys/acpica/dist/source/compiler/aslcompiler.y ============================================================================== --- vendor-sys/acpica/dist/source/compiler/aslcompiler.y Fri Apr 20 23:01:36 2012 (r234517) +++ vendor-sys/acpica/dist/source/compiler/aslcompiler.y Fri Apr 20 23:39:48 2012 (r234518) @@ -236,7 +236,6 @@ void * AslLocalAllo %token PARSEOP_I2C_SERIALBUS *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Fri Apr 20 23:40:43 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C212C1065672; Fri, 20 Apr 2012 23:40:43 +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 941668FC19; Fri, 20 Apr 2012 23:40:43 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3KNeha5061172; Fri, 20 Apr 2012 23:40:43 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3KNehFm061171; Fri, 20 Apr 2012 23:40:43 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201204202340.q3KNehFm061171@svn.freebsd.org> From: Jung-uk Kim Date: Fri, 20 Apr 2012 23:40:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org X-SVN-Group: vendor-sys MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234519 - vendor-sys/acpica/20120420 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Apr 2012 23:40:43 -0000 Author: jkim Date: Fri Apr 20 23:40:43 2012 New Revision: 234519 URL: http://svn.freebsd.org/changeset/base/234519 Log: Tag ACPICA 20120420. Added: vendor-sys/acpica/20120420/ - copied from r234518, vendor-sys/acpica/dist/ From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 00:26:04 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 71269106566B; Sat, 21 Apr 2012 00:26: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 508808FC15; Sat, 21 Apr 2012 00:26:04 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L0Q4iV062733; Sat, 21 Apr 2012 00:26:04 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L0Q4QJ062725; Sat, 21 Apr 2012 00:26:04 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201204210026.q3L0Q4QJ062725@svn.freebsd.org> From: Nathan Whitehorn Date: Sat, 21 Apr 2012 00:26:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234520 - in stable/9: lib/libc/powerpc/gen lib/libc/powerpc64/gen sys/powerpc/powerpc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 00:26:04 -0000 Author: nwhitehorn Date: Sat Apr 21 00:26:03 2012 New Revision: 234520 URL: http://svn.freebsd.org/changeset/base/234520 Log: MFC r234115: Do not restore the register holding the TLS pointer when doing various usermode context switches (long jumps and ucontext operations). If these are used across threads, multiple threads can end up with the same TLS base. Madness will then result. This makes behavior on PPC match that on x86 systems and on Linux. Modified: stable/9/lib/libc/powerpc/gen/_setjmp.S stable/9/lib/libc/powerpc/gen/setjmp.S stable/9/lib/libc/powerpc/gen/sigsetjmp.S stable/9/lib/libc/powerpc64/gen/_setjmp.S stable/9/lib/libc/powerpc64/gen/setjmp.S stable/9/lib/libc/powerpc64/gen/sigsetjmp.S stable/9/sys/powerpc/powerpc/exec_machdep.c Directory Properties: stable/9/lib/libc/ (props changed) stable/9/sys/ (props changed) Modified: stable/9/lib/libc/powerpc/gen/_setjmp.S ============================================================================== --- stable/9/lib/libc/powerpc/gen/_setjmp.S Fri Apr 20 23:40:43 2012 (r234519) +++ stable/9/lib/libc/powerpc/gen/_setjmp.S Sat Apr 21 00:26:03 2012 (r234520) @@ -63,7 +63,6 @@ ENTRY(_longjmp) lmw %r9,20(%r3) mtlr %r11 mtcr %r12 - mr %r2,%r9 mr %r1,%r10 or. %r3,%r4,%r4 bnelr Modified: stable/9/lib/libc/powerpc/gen/setjmp.S ============================================================================== --- stable/9/lib/libc/powerpc/gen/setjmp.S Fri Apr 20 23:40:43 2012 (r234519) +++ stable/9/lib/libc/powerpc/gen/setjmp.S Sat Apr 21 00:26:03 2012 (r234520) @@ -76,7 +76,6 @@ ENTRY(__longjmp) mr %r6,%r4 /* save val param */ mtlr %r11 /* r11 -> link reg */ mtcr %r12 /* r12 -> condition reg */ - mr %r2,%r9 /* r9 -> global ptr */ mr %r1,%r10 /* r10 -> stackptr */ mr %r4,%r3 li %r3,3 /* SIG_SETMASK */ Modified: stable/9/lib/libc/powerpc/gen/sigsetjmp.S ============================================================================== --- stable/9/lib/libc/powerpc/gen/sigsetjmp.S Fri Apr 20 23:40:43 2012 (r234519) +++ stable/9/lib/libc/powerpc/gen/sigsetjmp.S Sat Apr 21 00:26:03 2012 (r234520) @@ -80,7 +80,6 @@ ENTRY(siglongjmp) mr %r6,%r4 mtlr %r11 mtcr %r12 - mr %r2,%r9 mr %r1,%r10 or. %r7,%r7,%r7 beq 1f Modified: stable/9/lib/libc/powerpc64/gen/_setjmp.S ============================================================================== --- stable/9/lib/libc/powerpc64/gen/_setjmp.S Fri Apr 20 23:40:43 2012 (r234519) +++ stable/9/lib/libc/powerpc64/gen/_setjmp.S Sat Apr 21 00:26:03 2012 (r234520) @@ -86,7 +86,6 @@ ENTRY(_longjmp) ld %r10,40 + 1*8(%r3) ld %r11,40 + 2*8(%r3) ld %r12,40 + 3*8(%r3) - ld %r13,40 + 4*8(%r3) ld %r14,40 + 5*8(%r3) ld %r15,40 + 6*8(%r3) ld %r16,40 + 7*8(%r3) Modified: stable/9/lib/libc/powerpc64/gen/setjmp.S ============================================================================== --- stable/9/lib/libc/powerpc64/gen/setjmp.S Fri Apr 20 23:40:43 2012 (r234519) +++ stable/9/lib/libc/powerpc64/gen/setjmp.S Sat Apr 21 00:26:03 2012 (r234520) @@ -102,7 +102,6 @@ ENTRY(__longjmp) ld %r10,40 + 1*8(%r3) ld %r11,40 + 2*8(%r3) ld %r12,40 + 3*8(%r3) - ld %r13,40 + 4*8(%r3) ld %r14,40 + 5*8(%r3) ld %r15,40 + 6*8(%r3) ld %r16,40 + 7*8(%r3) Modified: stable/9/lib/libc/powerpc64/gen/sigsetjmp.S ============================================================================== --- stable/9/lib/libc/powerpc64/gen/sigsetjmp.S Fri Apr 20 23:40:43 2012 (r234519) +++ stable/9/lib/libc/powerpc64/gen/sigsetjmp.S Sat Apr 21 00:26:03 2012 (r234520) @@ -103,7 +103,6 @@ ENTRY(siglongjmp) ld %r10,40 + 1*8(%r3) ld %r11,40 + 2*8(%r3) ld %r12,40 + 3*8(%r3) - ld %r13,40 + 4*8(%r3) ld %r14,40 + 5*8(%r3) ld %r15,40 + 6*8(%r3) ld %r16,40 + 7*8(%r3) Modified: stable/9/sys/powerpc/powerpc/exec_machdep.c ============================================================================== --- stable/9/sys/powerpc/powerpc/exec_machdep.c Fri Apr 20 23:40:43 2012 (r234519) +++ stable/9/sys/powerpc/powerpc/exec_machdep.c Sat Apr 21 00:26:03 2012 (r234520) @@ -441,6 +441,7 @@ set_mcontext(struct thread *td, const mc { struct pcb *pcb; struct trapframe *tf; + register_t tls; pcb = td->td_pcb; tf = td->td_frame; @@ -448,16 +449,25 @@ set_mcontext(struct thread *td, const mc if (mcp->mc_vers != _MC_VERSION || mcp->mc_len != sizeof(*mcp)) return (EINVAL); - #ifdef AIM +#ifdef AIM /* * Don't let the user set privileged MSR bits */ if ((mcp->mc_srr1 & PSL_USERSTATIC) != (tf->srr1 & PSL_USERSTATIC)) { return (EINVAL); } - #endif +#endif + /* Copy trapframe, preserving TLS pointer across context change */ + if (SV_PROC_FLAG(td->td_proc, SV_LP64)) + tls = tf->fixreg[13]; + else + tls = tf->fixreg[2]; memcpy(tf, mcp->mc_frame, sizeof(mcp->mc_frame)); + if (SV_PROC_FLAG(td->td_proc, SV_LP64)) + tf->fixreg[13] = tls; + else + tf->fixreg[2] = tls; #ifdef AIM if (mcp->mc_flags & _MC_FP_VALID) { From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 00:28:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D421C106566B; Sat, 21 Apr 2012 00:28:29 +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 BDDCD8FC0A; Sat, 21 Apr 2012 00:28:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L0STRc062838; Sat, 21 Apr 2012 00:28:29 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L0ST4O062836; Sat, 21 Apr 2012 00:28:29 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201204210028.q3L0ST4O062836@svn.freebsd.org> From: Marius Strobl Date: Sat, 21 Apr 2012 00:28:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234521 - stable/7/sys/dev/mmc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 00:28:29 -0000 Author: marius Date: Sat Apr 21 00:28:29 2012 New Revision: 234521 URL: http://svn.freebsd.org/changeset/base/234521 Log: MFC: r189727 read_ivar takes a uintptr_t * not a u_char *. Modified: stable/7/sys/dev/mmc/mmc.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/dev/mmc/mmc.c ============================================================================== --- stable/7/sys/dev/mmc/mmc.c Sat Apr 21 00:26:03 2012 (r234520) +++ stable/7/sys/dev/mmc/mmc.c Sat Apr 21 00:28:29 2012 (r234521) @@ -1437,7 +1437,7 @@ mmc_scan(struct mmc_softc *sc) } static int -mmc_read_ivar(device_t bus, device_t child, int which, u_char *result) +mmc_read_ivar(device_t bus, device_t child, int which, uintptr_t *result) { struct mmc_ivars *ivar = device_get_ivars(child); From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 01:51:17 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1FC791065679; Sat, 21 Apr 2012 01:51:17 +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 092498FC19; Sat, 21 Apr 2012 01:51:17 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L1pGJL065472; Sat, 21 Apr 2012 01:51:16 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L1pGd4065465; Sat, 21 Apr 2012 01:51:16 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201204210151.q3L1pGd4065465@svn.freebsd.org> From: Marius Strobl Date: Sat, 21 Apr 2012 01: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: r234524 - in head/sys: dev/mmc modules/mmcsd X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 01:51:17 -0000 Author: marius Date: Sat Apr 21 01:51:16 2012 New Revision: 234524 URL: http://svn.freebsd.org/changeset/base/234524 Log: o Fixes: - When switching to 4-bit operation, send a SET_CLR_CARD_DETECT command to disconnect the card-detect pull-up resistor from the DAT3 line before sending the SET_BUS_WIDTH command. - Add the missing "reserved" zero entry to the mantissa table used to decode various CSD fields. This was causing SD cards to report that they could run at 30 MHz instead of the maximum 25 MHz mandated in the spec. o Enhancements: - At the MMC layer, format various info from the CID into a string that uniquely identifies the card instance (manufacturer number, serial number, product name and revision, etc). Export it as an instance variable. - At the MMCSD layer, display the formatted card ID string, and also report the clock speed of the hardware (not the card's max speed), and the number of bits and number of blocks per transfer. It comes out like this now: mmcsd0: 968MB at mmc0 22.5MHz/4bit/128-block o Use DEVMETHOD_END. o Use NULL instead of 0 for pointers. PR: 156496 Submitted by: Ian Lepore MFC after: 1 week Modified: head/sys/dev/mmc/mmc.c head/sys/dev/mmc/mmcbrvar.h head/sys/dev/mmc/mmcreg.h head/sys/dev/mmc/mmcsd.c head/sys/dev/mmc/mmcvar.h head/sys/modules/mmcsd/Makefile Modified: head/sys/dev/mmc/mmc.c ============================================================================== --- head/sys/dev/mmc/mmc.c Sat Apr 21 00:51:28 2012 (r234523) +++ head/sys/dev/mmc/mmc.c Sat Apr 21 01:51:16 2012 (r234524) @@ -101,6 +101,7 @@ struct mmc_ivars { uint32_t tran_speed; /* Max speed in normal mode */ uint32_t hs_tran_speed; /* Max speed in high speed mode */ uint32_t erase_sector; /* Card native erase sector size */ + char card_id_string[64];/* Formatted CID info (serial, MFG, etc) */ }; #define CMD_RETRIES 3 @@ -140,6 +141,7 @@ static void mmc_app_decode_scr(uint32_t static int mmc_send_ext_csd(struct mmc_softc *sc, uint8_t *rawextcsd); static void mmc_scan(struct mmc_softc *sc); static int mmc_delete_cards(struct mmc_softc *sc); +static void mmc_format_card_id_string(struct mmc_ivars *ivar); static void mmc_ms_delay(int ms) @@ -606,6 +608,13 @@ mmc_set_card_bus_width(struct mmc_softc if (mmcbr_get_mode(sc->dev) == mode_sd) { memset(&cmd, 0, sizeof(struct mmc_command)); + cmd.opcode = ACMD_SET_CLR_CARD_DETECT; + cmd.flags = MMC_RSP_R1 | MMC_CMD_AC; + cmd.arg = SD_CLR_CARD_DETECT; + err = mmc_wait_for_app_cmd(sc, rca, &cmd, CMD_RETRIES); + if (err != 0) + return (err); + memset(&cmd, 0, sizeof(struct mmc_command)); cmd.opcode = ACMD_SET_BUS_WIDTH; cmd.flags = MMC_RSP_R1 | MMC_CMD_AC; switch (width) { @@ -788,15 +797,52 @@ mmc_decode_cid_mmc(uint32_t *raw_cid, st cid->mdt_year = mmc_get_bits(raw_cid, 128, 8, 4) + 1997; } +static void +mmc_format_card_id_string(struct mmc_ivars *ivar) +{ + char oidstr[8]; + uint8_t c1; + uint8_t c2; + + /* + * Format a card ID string for use by the mmcsd driver, it's what + * appears between the <> in the following: + * mmcsd0: 968MB at mmc0 + * 22.5MHz/4bit/128-block + * + * The card_id_string in mmc_ivars is currently allocated as 64 bytes, + * and our max formatted length is currently 55 bytes if every field + * contains the largest value. + * + * Sometimes the oid is two printable ascii chars; when it's not, + * format it as 0xnnnn instead. + */ + c1 = (ivar->cid.oid >> 8) & 0x0ff; + c2 = ivar->cid.oid & 0x0ff; + if (c1 > 0x1f && c1 < 0x7f && c2 > 0x1f && c2 < 0x7f) + snprintf(oidstr, sizeof(oidstr), "%c%c", c1, c2); + else + snprintf(oidstr, sizeof(oidstr), "0x%04x", ivar->cid.oid); + snprintf(ivar->card_id_string, sizeof(ivar->card_id_string), + "%s%s %s %d.%d SN %d MFG %02d/%04d by %d %s", + ivar->mode == mode_sd ? "SD" : "MMC", ivar->high_cap ? "HC" : "", + ivar->cid.pnm, ivar->cid.prv >> 4, ivar->cid.prv & 0x0f, + ivar->cid.psn, ivar->cid.mdt_month, ivar->cid.mdt_year, + ivar->cid.mid, oidstr); +} + static const int exp[8] = { 1, 10, 100, 1000, 10000, 100000, 1000000, 10000000 }; + static const int mant[16] = { - 10, 12, 13, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 70, 80 + 0, 10, 12, 13, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 70, 80 }; + static const int cur_min[8] = { 500, 1000, 5000, 10000, 25000, 35000, 60000, 100000 }; + static const int cur_max[8] = { 1000, 5000, 10000, 25000, 35000, 45000, 800000, 200000 }; @@ -1080,13 +1126,7 @@ mmc_log_card(device_t dev, struct mmc_iv { device_printf(dev, "Card at relative address %d%s:\n", ivar->rca, newcard ? " added" : ""); - device_printf(dev, " card: %s%s (0x%x/0x%x/\"%s\" rev %d.%d " - "m/d %02d.%04d s/n %08x)\n", - ivar->mode == mode_sd ? "SD" : "MMC", - ivar->high_cap ? " High Capacity" : "", - ivar->cid.mid, ivar->cid.oid, - ivar->cid.pnm, ivar->cid.prv >> 4, ivar->cid.prv & 0x0f, - ivar->cid.mdt_month, ivar->cid.mdt_year, ivar->cid.psn); + device_printf(dev, " card: %s\n", ivar->card_id_string); device_printf(dev, " bus: %ubit, %uMHz%s\n", (ivar->bus_width == bus_width_1 ? 1 : (ivar->bus_width == bus_width_4 ? 4 : 8)), @@ -1188,6 +1228,7 @@ mmc_discover_cards(struct mmc_softc *sc) if ((mmcbr_get_caps(sc->dev) & MMC_CAP_4_BIT_DATA) && (ivar->scr.bus_widths & SD_SCR_BUS_WIDTH_4)) ivar->bus_width = bus_width_4; + mmc_format_card_id_string(ivar); if (bootverbose || mmc_debug) mmc_log_card(sc->dev, ivar, newcard); if (newcard) { @@ -1245,6 +1286,7 @@ mmc_discover_cards(struct mmc_softc *sc) ivar->bus_width = bus_width_1; ivar->timing = bus_timing_normal; } + mmc_format_card_id_string(ivar); if (bootverbose || mmc_debug) mmc_log_card(sc->dev, ivar, newcard); if (newcard) { @@ -1477,6 +1519,9 @@ mmc_read_ivar(device_t bus, device_t chi case MMC_IVAR_MAX_DATA: *result = mmcbr_get_max_data(bus); break; + case MMC_IVAR_CARD_ID_STRING: + *(char **)result = ivar->card_id_string; + break; } return (0); } @@ -1527,7 +1572,7 @@ static device_method_t mmc_methods[] = { DEVMETHOD(mmcbus_acquire_bus, mmc_acquire_bus), DEVMETHOD(mmcbus_release_bus, mmc_release_bus), - {0, 0}, + DEVMETHOD_END }; static driver_t mmc_driver = { @@ -1537,6 +1582,5 @@ static driver_t mmc_driver = { }; static devclass_t mmc_devclass; - DRIVER_MODULE(mmc, at91_mci, mmc_driver, mmc_devclass, NULL, NULL); DRIVER_MODULE(mmc, sdhci, mmc_driver, mmc_devclass, NULL, NULL); Modified: head/sys/dev/mmc/mmcbrvar.h ============================================================================== --- head/sys/dev/mmc/mmcbrvar.h Sat Apr 21 00:51:28 2012 (r234523) +++ head/sys/dev/mmc/mmcbrvar.h Sat Apr 21 01:51:16 2012 (r234524) @@ -56,6 +56,7 @@ #define DEV_MMC_MMCBRVAR_H #include +#include #include "mmcbr_if.h" enum mmcbr_device_ivars { @@ -72,8 +73,7 @@ enum mmcbr_device_ivars { MMCBR_IVAR_VDD, MMCBR_IVAR_CAPS, MMCBR_IVAR_TIMING, - MMCBR_IVAR_MAX_DATA, -// MMCBR_IVAR_, + MMCBR_IVAR_MAX_DATA }; /* Modified: head/sys/dev/mmc/mmcreg.h ============================================================================== --- head/sys/dev/mmc/mmcreg.h Sat Apr 21 00:51:28 2012 (r234523) +++ head/sys/dev/mmc/mmcreg.h Sat Apr 21 01:51:16 2012 (r234524) @@ -139,8 +139,8 @@ struct mmc_command { #define R1_READY_FOR_DATA (1u << 8) /* sx, a */ #define R1_APP_CMD (1u << 5) /* sr, c */ #define R1_AKE_SEQ_ERROR (1u << 3) /* er, c */ -#define R1_STATUS(x) (x & 0xFFFFE000 -#define R1_CURRENT_STATE(x) ((x) & R1_CURRENT_STATE_MASK) >> 9 +#define R1_STATUS(x) ((x) & 0xFFFFE000) +#define R1_CURRENT_STATE(x) (((x) & R1_CURRENT_STATE_MASK) >> 9) #define R1_STATE_IDLE 0 #define R1_STATE_READY 1 #define R1_STATE_IDENT 2 @@ -330,6 +330,9 @@ struct mmc_request { #define SD_SWITCH_HS_MODE 1 #define SD_SWITCH_NOCHANGE 0xF +#define SD_CLR_CARD_DETECT 0 +#define SD_SET_CARD_DETECT 1 + #define SD_MAX_HS 50000000 /* OCR bits */ @@ -380,7 +383,7 @@ struct mmc_cid { uint8_t fwrev; }; -struct mmc_csd +struct mmc_csd { uint8_t csd_structure; uint8_t spec_vers; Modified: head/sys/dev/mmc/mmcsd.c ============================================================================== --- head/sys/dev/mmc/mmcsd.c Sat Apr 21 00:51:28 2012 (r234523) +++ head/sys/dev/mmc/mmcsd.c Sat Apr 21 01:51:16 2012 (r234524) @@ -66,11 +66,17 @@ __FBSDID("$FreeBSD$"); #include #include -#include +#include #include +#include #include "mmcbus_if.h" +#if __FreeBSD_version < 800002 +#define kproc_create kthread_create +#define kproc_exit kthread_exit +#endif + struct mmcsd_softc { device_t dev; struct mtx sc_mtx; @@ -95,7 +101,6 @@ static int mmcsd_dump(void *arg, void *v off_t offset, size_t length); static void mmcsd_task(void *arg); -static const char *mmcsd_card_name(device_t dev); static int mmcsd_bus_bit_width(device_t dev); #define MMCSD_LOCK(_sc) mtx_lock(&(_sc)->sc_mtx) @@ -122,6 +127,8 @@ mmcsd_attach(device_t dev) struct mmcsd_softc *sc; struct disk *d; intmax_t mb; + uint32_t speed; + uint32_t maxblocks; char unit; sc = device_get_softc(dev); @@ -157,11 +164,22 @@ mmcsd_attach(device_t dev) unit = 'G'; mb /= 1024; } - device_printf(dev, "%ju%cB <%s Memory Card>%s at %s %dMHz/%dbit\n", - mb, unit, mmcsd_card_name(dev), + /* + * Report the clock speed of the underlying hardware, which might be + * different than what the card reports due to hardware limitations. + * Report how many blocks the hardware transfers at once, but clip the + * number to MAXPHYS since the system won't initiate larger transfers. + */ + speed = mmcbr_get_clock(device_get_parent(dev)); + maxblocks = mmc_get_max_data(dev); + if (maxblocks > MAXPHYS) + maxblocks = MAXPHYS; + device_printf(dev, "%ju%cB <%s>%s at %s %d.%01dMHz/%dbit/%d-block\n", + mb, unit, mmc_get_card_id_string(dev), mmc_get_read_only(dev) ? " (read-only)" : "", device_get_nameunit(device_get_parent(dev)), - mmc_get_tran_speed(dev) / 1000000, mmcsd_bus_bit_width(dev)); + speed / 1000000, (speed / 100000) % 10, + mmcsd_bus_bit_width(dev), maxblocks); disk_create(d, DISK_VERSION); bioq_init(&sc->bio_queue); @@ -500,16 +518,6 @@ out: kproc_exit(0); } -static const char * -mmcsd_card_name(device_t dev) -{ - if (mmc_get_card_type(dev) == mode_mmc) - return ("MMC"); - if (mmc_get_high_cap(dev)) - return ("SDHC"); - return ("SD"); -} - static int mmcsd_bus_bit_width(device_t dev) { @@ -526,7 +534,7 @@ static device_method_t mmcsd_methods[] = DEVMETHOD(device_detach, mmcsd_detach), DEVMETHOD(device_suspend, mmcsd_suspend), DEVMETHOD(device_resume, mmcsd_resume), - {0, 0}, + DEVMETHOD_END }; static driver_t mmcsd_driver = { @@ -536,4 +544,4 @@ static driver_t mmcsd_driver = { }; static devclass_t mmcsd_devclass; -DRIVER_MODULE(mmcsd, mmc, mmcsd_driver, mmcsd_devclass, 0, 0); +DRIVER_MODULE(mmcsd, mmc, mmcsd_driver, mmcsd_devclass, NULL, NULL); Modified: head/sys/dev/mmc/mmcvar.h ============================================================================== --- head/sys/dev/mmc/mmcvar.h Sat Apr 21 00:51:28 2012 (r234523) +++ head/sys/dev/mmc/mmcvar.h Sat Apr 21 01:51:16 2012 (r234524) @@ -69,7 +69,7 @@ enum mmc_device_ivars { MMC_IVAR_BUS_WIDTH, MMC_IVAR_ERASE_SECTOR, MMC_IVAR_MAX_DATA, -// MMC_IVAR_, + MMC_IVAR_CARD_ID_STRING }; /* @@ -89,5 +89,6 @@ MMC_ACCESSOR(card_type, CARD_TYPE, int) MMC_ACCESSOR(bus_width, BUS_WIDTH, int) MMC_ACCESSOR(erase_sector, ERASE_SECTOR, int) MMC_ACCESSOR(max_data, MAX_DATA, int) +MMC_ACCESSOR(card_id_string, CARD_ID_STRING, const char *) #endif /* DEV_MMC_MMCVAR_H */ Modified: head/sys/modules/mmcsd/Makefile ============================================================================== --- head/sys/modules/mmcsd/Makefile Sat Apr 21 00:51:28 2012 (r234523) +++ head/sys/modules/mmcsd/Makefile Sat Apr 21 01:51:16 2012 (r234524) @@ -3,6 +3,6 @@ .PATH: ${.CURDIR}/../../dev/mmc KMOD= mmcsd -SRCS= mmcsd.c mmcbus_if.h device_if.h bus_if.h +SRCS= bus_if.h device_if.h mmcbr_if.h mmcbus_if.h mmcsd.c .include From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 04:17:30 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DA13F1065674; Sat, 21 Apr 2012 04:17:30 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C55838FC12; Sat, 21 Apr 2012 04:17:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L4HUAh070832; Sat, 21 Apr 2012 04:17:30 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L4HUPR070830; Sat, 21 Apr 2012 04:17:30 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201204210417.q3L4HUPR070830@svn.freebsd.org> From: Adrian Chadd Date: Sat, 21 Apr 2012 04:17: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: r234525 - head/sys/mips/mips X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 04:17:31 -0000 Author: adrian Date: Sat Apr 21 04:17:30 2012 New Revision: 234525 URL: http://svn.freebsd.org/changeset/base/234525 Log: Allow for MIPS devices to have a specific probe/attach order. The default priority is now '1000' rather than '0'. This may cause some unforseen regressions. Submitted by: Stefan Bethke Reviewed by: imp Modified: head/sys/mips/mips/nexus.c Modified: head/sys/mips/mips/nexus.c ============================================================================== --- head/sys/mips/mips/nexus.c Sat Apr 21 01:51:16 2012 (r234524) +++ head/sys/mips/mips/nexus.c Sat Apr 21 04:17:30 2012 (r234525) @@ -237,11 +237,14 @@ nexus_hinted_child(device_t bus, const c device_t child; long maddr; int msize; + int order; int result; int irq; int mem_hints_count; - child = BUS_ADD_CHILD(bus, 0, dname, dunit); + if ((resource_int_value(dname, dunit, "order", &order)) != 0) + order = 1000; + child = BUS_ADD_CHILD(bus, order, dname, dunit); if (child == NULL) return; From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 06:08:03 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 03D46106566B; Sat, 21 Apr 2012 06:08:03 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E3DEF8FC0A; Sat, 21 Apr 2012 06:08:02 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L682ks074356; Sat, 21 Apr 2012 06:08:02 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L682O3074354; Sat, 21 Apr 2012 06:08:02 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210608.q3L682O3074354@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 06:08:02 +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: r234528 - head/lib/libc/stdio X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 06:08:03 -0000 Author: das Date: Sat Apr 21 06:08:02 2012 New Revision: 234528 URL: http://svn.freebsd.org/changeset/base/234528 Log: Fix a bug introduced in r187302 that was causing fputws() to enter an infinite loop pretty much unconditionally. It's remarkable that the patch that introduced the bug was never tested, but even more remarkable that nobody noticed for over two years. PR: 167039 MFC after: 3 days Modified: head/lib/libc/stdio/fputws.c Modified: head/lib/libc/stdio/fputws.c ============================================================================== --- head/lib/libc/stdio/fputws.c Sat Apr 21 05:26:02 2012 (r234527) +++ head/lib/libc/stdio/fputws.c Sat Apr 21 06:08:02 2012 (r234528) @@ -70,7 +70,7 @@ fputws_l(const wchar_t * __restrict ws, iov.iov_len = uio.uio_resid = nbytes; if (__sfvwrite(fp, &uio) != 0) goto error; - } while (ws != NULL); + } while (wsp != NULL); FUNLOCKFILE(fp); return (0); From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 06:08:30 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7C984106564A; Sat, 21 Apr 2012 06:08:30 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 68C6F8FC08; Sat, 21 Apr 2012 06:08:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L68UwJ074405; Sat, 21 Apr 2012 06:08:30 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L68UN8074403; Sat, 21 Apr 2012 06:08:30 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210608.q3L68UN8074403@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 06:08: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: r234529 - head/lib/libc/stdio X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 06:08:30 -0000 Author: das Date: Sat Apr 21 06:08:29 2012 New Revision: 234529 URL: http://svn.freebsd.org/changeset/base/234529 Log: Ensure that the {,v}swprintf functions always null-terminate the output string, even if an encoding error or malloc failure occurs. Modified: head/lib/libc/stdio/vswprintf.c Modified: head/lib/libc/stdio/vswprintf.c ============================================================================== --- head/lib/libc/stdio/vswprintf.c Sat Apr 21 06:08:02 2012 (r234528) +++ head/lib/libc/stdio/vswprintf.c Sat Apr 21 06:08:29 2012 (r234529) @@ -66,6 +66,7 @@ vswprintf_l(wchar_t * __restrict s, size f._bf._base = f._p = (unsigned char *)malloc(128); if (f._bf._base == NULL) { errno = ENOMEM; + *s = L'\0'; return (-1); } f._bf._size = f._w = 127; /* Leave room for the NUL */ @@ -74,6 +75,7 @@ vswprintf_l(wchar_t * __restrict s, size sverrno = errno; free(f._bf._base); errno = sverrno; + *s = L'\0'; return (-1); } *f._p = '\0'; @@ -87,6 +89,7 @@ vswprintf_l(wchar_t * __restrict s, size free(f._bf._base); if (nwc == (size_t)-1) { errno = EILSEQ; + *s = L'\0'; return (-1); } if (nwc == n) { From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 06:09:10 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B956F1065670; Sat, 21 Apr 2012 06:09:10 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8C9FF8FC0A; Sat, 21 Apr 2012 06:09:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L69AcR074458; Sat, 21 Apr 2012 06:09:10 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L69AsN074456; Sat, 21 Apr 2012 06:09:10 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210609.q3L69AsN074456@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 06:09: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: r234530 - head/lib/libc/stdio X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 06:09:10 -0000 Author: das Date: Sat Apr 21 06:09:09 2012 New Revision: 234530 URL: http://svn.freebsd.org/changeset/base/234530 Log: - Fix the claim that the output is always null-terminated. This isn't true if the size is zero. - Fix a claim that sprintf() is the same as snprintf() with an infinite size. It's equivalent to snprintf() with a size of INT_MAX + 1. - Document the return values in the return values section. - Document the possible errno value of EOVERFLOW. MFC after: 2 weeks Modified: head/lib/libc/stdio/printf.3 Modified: head/lib/libc/stdio/printf.3 ============================================================================== --- head/lib/libc/stdio/printf.3 Sat Apr 21 06:08:29 2012 (r234529) +++ head/lib/libc/stdio/printf.3 Sat Apr 21 06:09:09 2012 (r234530) @@ -113,20 +113,6 @@ string that specifies how subsequent arg .Xr stdarg 3 ) are converted for output. .Pp -These functions return the number of characters printed -(not including the trailing -.Ql \e0 -used to end output to strings) or a negative value if an output error occurs, -except for -.Fn snprintf -and -.Fn vsnprintf , -which return the number of characters that would have been printed if the -.Fa size -were unlimited -(again, not including the final -.Ql \e0 ) . -.Pp The .Fn asprintf and @@ -164,15 +150,19 @@ if the return value is greater than or e .Fa size argument, the string was too short and some of the printed characters were discarded. -The output is always null-terminated. +The output is always null-terminated, unless +.Fa size +is 0. .Pp The .Fn sprintf and .Fn vsprintf functions -effectively assume an infinite -.Fa size . +effectively assume a +.Fa size +of +.Dv INT_MAX + 1. .Pp The format string is composed of zero or more directives: ordinary @@ -670,6 +660,21 @@ In no case does a non-existent or small a numeric field; if the result of a conversion is wider than the field width, the field is expanded to contain the conversion result. +.Sh RETURN VALUES +These functions return the number of characters printed +(not including the trailing +.Ql \e0 +used to end output to strings), +except for +.Fn snprintf +and +.Fn vsnprintf , +which return the number of characters that would have been printed if the +.Fa size +were unlimited +(again, not including the final +.Ql \e0 ) . +These functions return a negative value if an error occurs. .Sh EXAMPLES To print a date and time in the form .Dq Li "Sunday, July 3, 10:02" , @@ -771,6 +776,13 @@ family of functions may fail if: An invalid wide character code was encountered. .It Bq Er ENOMEM Insufficient storage space is available. +.It Bq Er EOVERFLOW +The +.Fa size +argument exceeds +.Dv INT_MAX + 1 , +or the return value would be too large to be represented by an +.Vt int . .El .Sh SEE ALSO .Xr printf 1 , From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 06:10:19 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 678F4106567B; Sat, 21 Apr 2012 06:10:19 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4952D8FC15; Sat, 21 Apr 2012 06:10:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L6AJAb074537; Sat, 21 Apr 2012 06:10:19 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L6AJbx074531; Sat, 21 Apr 2012 06:10:19 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210610.q3L6AJbx074531@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 06:10: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: r234531 - head/lib/libc/stdio X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 06:10:19 -0000 Author: das Date: Sat Apr 21 06:10:18 2012 New Revision: 234531 URL: http://svn.freebsd.org/changeset/base/234531 Log: If the size passed to {,v}s{w,n}printf is larger than INT_MAX+1 (i.e., the return value would overflow), set errno to EOVERFLOW and return an error. This improves the chances that buggy applications -- for instance, ones that pass in a negative integer as the size due to a bogus calculation -- will fail in safe ways. Returning an error in these situations is specified by POSIX, but POSIX appears to have an off-by-one error that isn't duplicated in this change. Previously, some of these functions would silently cap the size at INT_MAX+1, and others would exit with an error after writing more than INT_MAX characters. PR: 39256 MFC after: 2 weeks Modified: head/lib/libc/stdio/snprintf.c head/lib/libc/stdio/vfprintf.c head/lib/libc/stdio/vfwprintf.c head/lib/libc/stdio/vsnprintf.c head/lib/libc/stdio/vswprintf.c Modified: head/lib/libc/stdio/snprintf.c ============================================================================== --- head/lib/libc/stdio/snprintf.c Sat Apr 21 06:09:09 2012 (r234530) +++ head/lib/libc/stdio/snprintf.c Sat Apr 21 06:10:18 2012 (r234531) @@ -41,6 +41,7 @@ static char sccsid[] = "@(#)snprintf.c 8 #include __FBSDID("$FreeBSD$"); +#include #include #include #include @@ -59,8 +60,11 @@ snprintf(char * __restrict str, size_t n on = n; if (n != 0) n--; - if (n > INT_MAX) - n = INT_MAX; + if (n > INT_MAX) { + errno = EOVERFLOW; + *str = '\0'; + return (EOF); + } va_start(ap, fmt); f._flags = __SWR | __SSTR; f._bf._base = f._p = (unsigned char *)str; @@ -84,8 +88,11 @@ snprintf_l(char * __restrict str, size_t on = n; if (n != 0) n--; - if (n > INT_MAX) - n = INT_MAX; + if (n > INT_MAX) { + errno = EOVERFLOW; + *str = '\0'; + return (EOF); + } va_start(ap, fmt); f._flags = __SWR | __SSTR; f._bf._base = f._p = (unsigned char *)str; Modified: head/lib/libc/stdio/vfprintf.c ============================================================================== --- head/lib/libc/stdio/vfprintf.c Sat Apr 21 06:09:09 2012 (r234530) +++ head/lib/libc/stdio/vfprintf.c Sat Apr 21 06:10:18 2012 (r234531) @@ -51,6 +51,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include @@ -480,6 +481,7 @@ __vfprintf(FILE *fp, locale_t locale, co if ((n = fmt - cp) != 0) { if ((unsigned)ret + n > INT_MAX) { ret = EOF; + errno = EOVERFLOW; goto error; } PRINT(cp, n); @@ -935,6 +937,7 @@ number: if ((dprec = prec) >= 0) prsize = width > realsz ? width : realsz; if ((unsigned)ret + prsize > INT_MAX) { ret = EOF; + errno = EOVERFLOW; goto error; } Modified: head/lib/libc/stdio/vfwprintf.c ============================================================================== --- head/lib/libc/stdio/vfwprintf.c Sat Apr 21 06:09:09 2012 (r234530) +++ head/lib/libc/stdio/vfwprintf.c Sat Apr 21 06:10:18 2012 (r234531) @@ -54,6 +54,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include @@ -553,6 +554,7 @@ __vfwprintf(FILE *fp, locale_t locale, c if ((n = fmt - cp) != 0) { if ((unsigned)ret + n > INT_MAX) { ret = EOF; + errno = EOVERFLOW; goto error; } PRINT(cp, n); @@ -1003,6 +1005,7 @@ number: if ((dprec = prec) >= 0) prsize = width > realsz ? width : realsz; if ((unsigned)ret + prsize > INT_MAX) { ret = EOF; + errno = EOVERFLOW; goto error; } Modified: head/lib/libc/stdio/vsnprintf.c ============================================================================== --- head/lib/libc/stdio/vsnprintf.c Sat Apr 21 06:09:09 2012 (r234530) +++ head/lib/libc/stdio/vsnprintf.c Sat Apr 21 06:10:18 2012 (r234531) @@ -41,6 +41,7 @@ static char sccsid[] = "@(#)vsnprintf.c #include __FBSDID("$FreeBSD$"); +#include #include #include #include "local.h" @@ -59,8 +60,11 @@ vsnprintf_l(char * __restrict str, size_ on = n; if (n != 0) n--; - if (n > INT_MAX) - n = INT_MAX; + if (n > INT_MAX) { + errno = EOVERFLOW; + *str = '\0'; + return (EOF); + } /* Stdio internals do not deal correctly with zero length buffer */ if (n == 0) { if (on > 0) Modified: head/lib/libc/stdio/vswprintf.c ============================================================================== --- head/lib/libc/stdio/vswprintf.c Sat Apr 21 06:09:09 2012 (r234530) +++ head/lib/libc/stdio/vswprintf.c Sat Apr 21 06:10:18 2012 (r234531) @@ -39,6 +39,7 @@ __FBSDID("FreeBSD: src/lib/libc/stdio/va __FBSDID("$FreeBSD$"); #include +#include #include #include #include @@ -61,6 +62,11 @@ vswprintf_l(wchar_t * __restrict s, size errno = EINVAL; return (-1); } + if (n - 1 > INT_MAX) { + errno = EOVERFLOW; + *s = L'\0'; + return (-1); + } f._flags = __SWR | __SSTR | __SALC; f._bf._base = f._p = (unsigned char *)malloc(128); From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 06:59:49 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6843A106566C; Sat, 21 Apr 2012 06:59:49 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 398628FC08; Sat, 21 Apr 2012 06:59:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L6xn6p076168; Sat, 21 Apr 2012 06:59:49 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L6xnek076165; Sat, 21 Apr 2012 06:59:49 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210659.q3L6xnek076165@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 06:59:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234533 - stable/7/lib/msun/src X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 06:59:49 -0000 Author: das Date: Sat Apr 21 06:59:48 2012 New Revision: 234533 URL: http://svn.freebsd.org/changeset/base/234533 Log: MFC r233973 (partial): Fix bugs in remquo{,f}. Modified: stable/7/lib/msun/src/s_remquo.c stable/7/lib/msun/src/s_remquof.c Directory Properties: stable/7/lib/msun/ (props changed) Modified: stable/7/lib/msun/src/s_remquo.c ============================================================================== --- stable/7/lib/msun/src/s_remquo.c Sat Apr 21 06:29:44 2012 (r234532) +++ stable/7/lib/msun/src/s_remquo.c Sat Apr 21 06:59:48 2012 (r234533) @@ -49,7 +49,7 @@ remquo(double x, double y, int *quo) goto fixup; /* |x|<|y| return x or x-y */ } if(lx==ly) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[(u_int32_t)sx>>31]; /* |x|=|y| return x*0*/ } } @@ -112,6 +112,7 @@ remquo(double x, double y, int *quo) /* convert back to floating value and restore the sign */ if((hx|lx)==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[(u_int32_t)sx>>31]; } @@ -127,9 +128,9 @@ remquo(double x, double y, int *quo) lx = (lx>>n)|((u_int32_t)hx<<(32-n)); hx >>= n; } else if (n<=31) { - lx = (hx<<(32-n))|(lx>>n); hx = sx; + lx = (hx<<(32-n))|(lx>>n); hx = 0; } else { - lx = hx>>(n-32); hx = sx; + lx = hx>>(n-32); hx = 0; } } fixup: Modified: stable/7/lib/msun/src/s_remquof.c ============================================================================== --- stable/7/lib/msun/src/s_remquof.c Sat Apr 21 06:29:44 2012 (r234532) +++ stable/7/lib/msun/src/s_remquof.c Sat Apr 21 06:59:48 2012 (r234533) @@ -46,7 +46,7 @@ remquof(float x, float y, int *quo) q = 0; goto fixup; /* |x|<|y| return x or x-y */ } else if(hx==hy) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[(u_int32_t)sx>>31]; /* |x|=|y| return x*0*/ } @@ -88,6 +88,7 @@ remquof(float x, float y, int *quo) /* convert back to floating value and restore the sign */ if(hx==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[(u_int32_t)sx>>31]; } From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 07:00:01 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6F62E106567A; Sat, 21 Apr 2012 07:00:01 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 307D88FC08; Sat, 21 Apr 2012 07:00:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L701qS076230; Sat, 21 Apr 2012 07:00:01 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L700ur076226; Sat, 21 Apr 2012 07:00:00 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210700.q3L700ur076226@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 07:00:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234534 - stable/8/lib/msun/src X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 07:00:01 -0000 Author: das Date: Sat Apr 21 07:00:00 2012 New Revision: 234534 URL: http://svn.freebsd.org/changeset/base/234534 Log: MFC r233973: Fix bugs in remquo{,f,l}. Modified: stable/8/lib/msun/src/s_remquo.c stable/8/lib/msun/src/s_remquof.c stable/8/lib/msun/src/s_remquol.c Directory Properties: stable/8/lib/msun/ (props changed) Modified: stable/8/lib/msun/src/s_remquo.c ============================================================================== --- stable/8/lib/msun/src/s_remquo.c Sat Apr 21 06:59:48 2012 (r234533) +++ stable/8/lib/msun/src/s_remquo.c Sat Apr 21 07:00:00 2012 (r234534) @@ -51,7 +51,7 @@ remquo(double x, double y, int *quo) goto fixup; /* |x|<|y| return x or x-y */ } if(lx==ly) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[(u_int32_t)sx>>31]; /* |x|=|y| return x*0*/ } } @@ -114,6 +114,7 @@ remquo(double x, double y, int *quo) /* convert back to floating value and restore the sign */ if((hx|lx)==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[(u_int32_t)sx>>31]; } @@ -129,9 +130,9 @@ remquo(double x, double y, int *quo) lx = (lx>>n)|((u_int32_t)hx<<(32-n)); hx >>= n; } else if (n<=31) { - lx = (hx<<(32-n))|(lx>>n); hx = sx; + lx = (hx<<(32-n))|(lx>>n); hx = 0; } else { - lx = hx>>(n-32); hx = sx; + lx = hx>>(n-32); hx = 0; } } fixup: Modified: stable/8/lib/msun/src/s_remquof.c ============================================================================== --- stable/8/lib/msun/src/s_remquof.c Sat Apr 21 06:59:48 2012 (r234533) +++ stable/8/lib/msun/src/s_remquof.c Sat Apr 21 07:00:00 2012 (r234534) @@ -46,7 +46,7 @@ remquof(float x, float y, int *quo) q = 0; goto fixup; /* |x|<|y| return x or x-y */ } else if(hx==hy) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[(u_int32_t)sx>>31]; /* |x|=|y| return x*0*/ } @@ -88,6 +88,7 @@ remquof(float x, float y, int *quo) /* convert back to floating value and restore the sign */ if(hx==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[(u_int32_t)sx>>31]; } Modified: stable/8/lib/msun/src/s_remquol.c ============================================================================== --- stable/8/lib/msun/src/s_remquol.c Sat Apr 21 06:59:48 2012 (r234533) +++ stable/8/lib/msun/src/s_remquol.c Sat Apr 21 07:00:00 2012 (r234534) @@ -96,7 +96,7 @@ remquol(long double x, long double y, in goto fixup; /* |x|<|y| return x or x-y */ } if(ux.bits.manh==uy.bits.manh && ux.bits.manl==uy.bits.manl) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[sx]; /* |x|=|y| return x*0*/ } } @@ -138,6 +138,7 @@ remquol(long double x, long double y, in /* convert back to floating value and restore the sign */ if((hx|lx)==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[sx]; } From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 07:00:40 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 32A76106581B; Sat, 21 Apr 2012 07:00:40 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0521C8FC18; Sat, 21 Apr 2012 07:00:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L70dfI076289; Sat, 21 Apr 2012 07:00:39 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L70dNW076285; Sat, 21 Apr 2012 07:00:39 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210700.q3L70dNW076285@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 07:00:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234535 - stable/9/lib/msun/src X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 07:00:40 -0000 Author: das Date: Sat Apr 21 07:00:39 2012 New Revision: 234535 URL: http://svn.freebsd.org/changeset/base/234535 Log: MFC r233973: Fix bugs in remquo{,f,l}. Modified: stable/9/lib/msun/src/s_remquo.c stable/9/lib/msun/src/s_remquof.c stable/9/lib/msun/src/s_remquol.c Directory Properties: stable/9/lib/msun/ (props changed) Modified: stable/9/lib/msun/src/s_remquo.c ============================================================================== --- stable/9/lib/msun/src/s_remquo.c Sat Apr 21 07:00:00 2012 (r234534) +++ stable/9/lib/msun/src/s_remquo.c Sat Apr 21 07:00:39 2012 (r234535) @@ -51,7 +51,7 @@ remquo(double x, double y, int *quo) goto fixup; /* |x|<|y| return x or x-y */ } if(lx==ly) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[(u_int32_t)sx>>31]; /* |x|=|y| return x*0*/ } } @@ -114,6 +114,7 @@ remquo(double x, double y, int *quo) /* convert back to floating value and restore the sign */ if((hx|lx)==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[(u_int32_t)sx>>31]; } @@ -129,9 +130,9 @@ remquo(double x, double y, int *quo) lx = (lx>>n)|((u_int32_t)hx<<(32-n)); hx >>= n; } else if (n<=31) { - lx = (hx<<(32-n))|(lx>>n); hx = sx; + lx = (hx<<(32-n))|(lx>>n); hx = 0; } else { - lx = hx>>(n-32); hx = sx; + lx = hx>>(n-32); hx = 0; } } fixup: Modified: stable/9/lib/msun/src/s_remquof.c ============================================================================== --- stable/9/lib/msun/src/s_remquof.c Sat Apr 21 07:00:00 2012 (r234534) +++ stable/9/lib/msun/src/s_remquof.c Sat Apr 21 07:00:39 2012 (r234535) @@ -46,7 +46,7 @@ remquof(float x, float y, int *quo) q = 0; goto fixup; /* |x|<|y| return x or x-y */ } else if(hx==hy) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[(u_int32_t)sx>>31]; /* |x|=|y| return x*0*/ } @@ -88,6 +88,7 @@ remquof(float x, float y, int *quo) /* convert back to floating value and restore the sign */ if(hx==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[(u_int32_t)sx>>31]; } Modified: stable/9/lib/msun/src/s_remquol.c ============================================================================== --- stable/9/lib/msun/src/s_remquol.c Sat Apr 21 07:00:00 2012 (r234534) +++ stable/9/lib/msun/src/s_remquol.c Sat Apr 21 07:00:39 2012 (r234535) @@ -96,7 +96,7 @@ remquol(long double x, long double y, in goto fixup; /* |x|<|y| return x or x-y */ } if(ux.bits.manh==uy.bits.manh && ux.bits.manl==uy.bits.manl) { - *quo = 1; + *quo = (sxy ? -1 : 1); return Zero[sx]; /* |x|=|y| return x*0*/ } } @@ -138,6 +138,7 @@ remquol(long double x, long double y, in /* convert back to floating value and restore the sign */ if((hx|lx)==0) { /* return sign(x)*0 */ + q &= 0x7fffffff; *quo = (sxy ? -q : q); return Zero[sx]; } From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 07:07:12 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 52A011065673; Sat, 21 Apr 2012 07:07:12 +0000 (UTC) (envelope-from peterjeremy@acm.org) Received: from fallbackmx06.syd.optusnet.com.au (fallbackmx06.syd.optusnet.com.au [211.29.132.8]) by mx1.freebsd.org (Postfix) with ESMTP id D31EE8FC0A; Sat, 21 Apr 2012 07:07:11 +0000 (UTC) Received: from mail35.syd.optusnet.com.au (mail35.syd.optusnet.com.au [211.29.133.51]) by fallbackmx06.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id q3L77498011628; Sat, 21 Apr 2012 17:07:04 +1000 Received: from server.vk2pj.dyndns.org (c220-239-251-180.belrs5.nsw.optusnet.com.au [220.239.251.180]) by mail35.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id q3L76t3J024635 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 21 Apr 2012 17:06:56 +1000 X-Bogosity: Ham, spamicity=0.000000 Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by server.vk2pj.dyndns.org (8.14.5/8.14.4) with ESMTP id q3L75sVc071060; Sat, 21 Apr 2012 17:05:54 +1000 (EST) (envelope-from peter@server.vk2pj.dyndns.org) Received: (from peter@localhost) by server.vk2pj.dyndns.org (8.14.5/8.14.5/Submit) id q3L75s9n071059; Sat, 21 Apr 2012 17:05:54 +1000 (EST) (envelope-from peter) Date: Sat, 21 Apr 2012 17:05:54 +1000 From: Peter Jeremy To: David Schultz Message-ID: <20120421070554.GA59737@server.vk2pj.dyndns.org> References: <201204210608.q3L682O3074354@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="YiEDa0DAkWCtVeE4" Content-Disposition: inline In-Reply-To: <201204210608.q3L682O3074354@svn.freebsd.org> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc 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: r234528 - head/lib/libc/stdio X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 07:07:12 -0000 --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2012-Apr-21 06:08:02 +0000, David Schultz wrote: >Log: > Fix a bug introduced in r187302 that was causing fputws() to enter an > infinite loop pretty much unconditionally. Unfortunately, I suspect you've just turned an unconditional infinite loop into a conditional one. There's still a "wsp =3D ws;" inside the loop so if you pass in a long string (one that exceeds BUFSIZ bytes when converted to a multi-byte string) then wsp will be non-NULL after the call to __wcsnrtombs(), causing the do loop to loop and then wsp will be re-initialised to ws. I think the fix is to move the "wsp =3D ws;" outside the loop. > It's remarkable that the > patch that introduced the bug was never tested, but even more > remarkable that nobody noticed for over two years. It took me a while to work out that the problem was libc and not my code. --=20 Peter Jeremy --YiEDa0DAkWCtVeE4 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAk+SXFIACgkQ/opHv/APuIfg7ACglm8HpS2PB9NBPXBg6zPNTXKM x9wAn0yVKQOYkI0vIAnr4TOnjWY5eTOR =GwXX -----END PGP SIGNATURE----- --YiEDa0DAkWCtVeE4-- From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 07:31:28 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 81BFA1065672; Sat, 21 Apr 2012 07:31:28 +0000 (UTC) (envelope-from das@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6D2248FC14; Sat, 21 Apr 2012 07:31:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3L7VSWj077242; Sat, 21 Apr 2012 07:31:28 GMT (envelope-from das@svn.freebsd.org) Received: (from das@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3L7VSQp077240; Sat, 21 Apr 2012 07:31:28 GMT (envelope-from das@svn.freebsd.org) Message-Id: <201204210731.q3L7VSQp077240@svn.freebsd.org> From: David Schultz Date: Sat, 21 Apr 2012 07:31: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: r234536 - head/lib/libc/stdio X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 07:31:28 -0000 Author: das Date: Sat Apr 21 07:31:27 2012 New Revision: 234536 URL: http://svn.freebsd.org/changeset/base/234536 Log: As noted by Peter Jeremy, r234528 only partially fixed the infinite loop bug introduced in r187302. This completes the fix. PR: 167039 MFC after: 3 days Modified: head/lib/libc/stdio/fputws.c Modified: head/lib/libc/stdio/fputws.c ============================================================================== --- head/lib/libc/stdio/fputws.c Sat Apr 21 07:00:39 2012 (r234535) +++ head/lib/libc/stdio/fputws.c Sat Apr 21 07:31:27 2012 (r234536) @@ -61,8 +61,8 @@ fputws_l(const wchar_t * __restrict ws, uio.uio_iov = &iov; uio.uio_iovcnt = 1; iov.iov_base = buf; + wsp = ws; do { - wsp = ws; nbytes = l->__wcsnrtombs(buf, &wsp, SIZE_T_MAX, sizeof(buf), &fp->_mbstate); if (nbytes == (size_t)-1) From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 07:53:43 2012 Return-Path: Delivered-To: svn-src-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A063D1065673; Sat, 21 Apr 2012 07:53:43 +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 62FB78FC08; Sat, 21 Apr 2012 07:53:43 +0000 (UTC) Received: from zim.MIT.EDU (localhost [127.0.0.1]) by zim.MIT.EDU (8.14.5/8.14.2) with ESMTP id q3L7X5F1026994; Sat, 21 Apr 2012 03:33:05 -0400 (EDT) (envelope-from das@FreeBSD.org) Received: (from das@localhost) by zim.MIT.EDU (8.14.5/8.14.2/Submit) id q3L7X5Q5026993; Sat, 21 Apr 2012 03:33:05 -0400 (EDT) (envelope-from das@FreeBSD.org) Date: Sat, 21 Apr 2012 03:33:05 -0400 From: David Schultz To: Peter Jeremy Message-ID: <20120421073305.GA18432@zim.MIT.EDU> Mail-Followup-To: Peter Jeremy , src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, svn-src-head@FreeBSD.org References: <201204210608.q3L682O3074354@svn.freebsd.org> <20120421070554.GA59737@server.vk2pj.dyndns.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20120421070554.GA59737@server.vk2pj.dyndns.org> Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r234528 - head/lib/libc/stdio X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 07:53:43 -0000 On Sat, Apr 21, 2012, Peter Jeremy wrote: > On 2012-Apr-21 06:08:02 +0000, David Schultz wrote: > >Log: > > Fix a bug introduced in r187302 that was causing fputws() to enter an > > infinite loop pretty much unconditionally. > > Unfortunately, I suspect you've just turned an unconditional infinite > loop into a conditional one. There's still a "wsp = ws;" inside the > loop so if you pass in a long string (one that exceeds BUFSIZ bytes > when converted to a multi-byte string) then wsp will be non-NULL > after the call to __wcsnrtombs(), causing the do loop to loop and > then wsp will be re-initialised to ws. I think the fix is to move > the "wsp = ws;" outside the loop. Whoops -- good catch. This should be fixed now. From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 10:42:32 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 90AD7106564A; Sat, 21 Apr 2012 10:42:32 +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 469D98FC15; Sat, 21 Apr 2012 10:42:32 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7:0:bc21:4655:90e2:3182] (unknown [IPv6:2001:7b8:3a7:0:bc21:4655:90e2:3182]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 897555C37; Sat, 21 Apr 2012 12:42:31 +0200 (CEST) Message-ID: <4F928F1D.2080406@FreeBSD.org> Date: Sat, 21 Apr 2012 12:42:37 +0200 From: Dimitry Andric Organization: The FreeBSD Project User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20120410 Thunderbird/12.0 MIME-Version: 1.0 To: Alexander Best References: <201204162123.q3GLNSr6051133@svn.freebsd.org> <20120419211441.GA7744@freebsd.org> In-Reply-To: <20120419211441.GA7744@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: r234353 - in head: . contrib/llvm contrib/llvm/include/llvm contrib/llvm/include/llvm-c contrib/llvm/include/llvm-c/Transforms contrib/llvm/include/llvm/ADT contrib/llvm/include/llvm/An... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 10:42:32 -0000 On 2012-04-19 23:14, Alexander Best wrote: > On Mon Apr 16 12, Dimitry Andric wrote: >> Author: dim >> Date: Mon Apr 16 21:23:25 2012 >> New Revision: 234353 >> URL: http://svn.freebsd.org/changeset/base/234353 >> >> Log: >> Upgrade our copy of llvm/clang to trunk r154661, in preparation of the >> upcoming 3.1 release (expected in a few weeks). Preliminary release >> notes can be found at: > > very nice. :) > > any reason '-fformat-extensions'-support still hasn't been pushed upstream as > something like '-fbsd-extensions'? Simply ENOTIME. The support as it is now, is not really acceptable for upstream, because it is rather a quick 'n dirty hack. :) Besides, llvm/clang 3.1 has branched for release, and only serious bugs will be fixed in there, from now on. So even if I got something whipped up right now, it would probably not make it in. From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 10:45:46 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BD915106566B; Sat, 21 Apr 2012 10:45:46 +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 A91498FC0A; Sat, 21 Apr 2012 10:45:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LAjkUL083351; Sat, 21 Apr 2012 10:45:46 GMT (envelope-from trasz@svn.freebsd.org) Received: (from trasz@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LAjkPO083349; Sat, 21 Apr 2012 10:45:46 GMT (envelope-from trasz@svn.freebsd.org) Message-Id: <201204211045.q3LAjkPO083349@svn.freebsd.org> From: Edward Tomasz Napierala Date: Sat, 21 Apr 2012 10:45: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: r234537 - head/sys/ufs/ffs X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 10:45:46 -0000 Author: trasz Date: Sat Apr 21 10:45:46 2012 New Revision: 234537 URL: http://svn.freebsd.org/changeset/base/234537 Log: Fix use-after-free introduced in r234036. Reviewed by: mckusick Tested by: pho Modified: head/sys/ufs/ffs/ffs_vfsops.c Modified: head/sys/ufs/ffs/ffs_vfsops.c ============================================================================== --- head/sys/ufs/ffs/ffs_vfsops.c Sat Apr 21 07:31:27 2012 (r234536) +++ head/sys/ufs/ffs/ffs_vfsops.c Sat Apr 21 10:45:46 2012 (r234537) @@ -699,10 +699,14 @@ ffs_reload(struct mount *mp, struct thre * We no longer know anything about clusters per cylinder group. */ if (fs->fs_contigsumsize > 0) { - lp = fs->fs_maxcluster; + fs->fs_maxcluster = lp = space; for (i = 0; i < fs->fs_ncg; i++) *lp++ = fs->fs_contigsumsize; + space = lp; } + size = fs->fs_ncg * sizeof(u_int8_t); + fs->fs_contigdirs = (u_int8_t *)space; + bzero(fs->fs_contigdirs, size); loop: MNT_VNODE_FOREACH_ALL(vp, mp, mvp) { From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 11:51:31 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EF891106566C; Sat, 21 Apr 2012 11:51:31 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DAF4A8FC0A; Sat, 21 Apr 2012 11:51:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LBpVri086550; Sat, 21 Apr 2012 11:51:31 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LBpVru086548; Sat, 21 Apr 2012 11:51:31 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201204211151.q3LBpVru086548@svn.freebsd.org> From: Joel Dahl Date: Sat, 21 Apr 2012 11:51: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: r234538 - head/share/man/man4 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 11:51:32 -0000 Author: joel (doc committer) Date: Sat Apr 21 11:51:31 2012 New Revision: 234538 URL: http://svn.freebsd.org/changeset/base/234538 Log: Minor mdoc fixes. Modified: head/share/man/man4/iscsi_initiator.4 Modified: head/share/man/man4/iscsi_initiator.4 ============================================================================== --- head/share/man/man4/iscsi_initiator.4 Sat Apr 21 10:45:46 2012 (r234537) +++ head/share/man/man4/iscsi_initiator.4 Sat Apr 21 11:51:31 2012 (r234538) @@ -25,8 +25,8 @@ .\" $FreeBSD$ .\" .Dd August 3, 2010 -.Os .Dt ISCSI_INITIATOR 4 +.Os .Sh NAME .Nm iscsi_initiator .Nd kernel driver for the iSCSI protocol @@ -75,9 +75,9 @@ is the IP address of the target of sessi .Em n . .It Va net.iscsi.n.stats are some statistics for session -.EM n +.Em n .It Va net.iscsi.n.pid -is the +is the .Em "process id" of the userland side of session .Em n , @@ -85,11 +85,11 @@ see .Xr iscontrol 8 . .El .Sh FILES -The +The .Nm driver creates the following: -.Bl -tag -width ".Pa /dev/iscsi%dxx" -compact .Pp +.Bl -tag -width ".Pa /dev/iscsi%dxx" -compact .It Pa /dev/iscsi used to create new sessions. .It Pa /dev/iscsi%d @@ -102,7 +102,7 @@ for each new session. .Sh STANDARDS iSCSI RFC 3720 .\" .Sh HISTORY -.\" .Sh AUTHORS +.Sh AUTHORS This software was written by Daniel Braniss .Sh BUGS The lun discovery method is old-fashioned. From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 11:53:24 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D37FF1065670; Sat, 21 Apr 2012 11:53:24 +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 BFAFF8FC1C; Sat, 21 Apr 2012 11:53:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LBrOJU086643; Sat, 21 Apr 2012 11:53:24 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LBrOb6086641; Sat, 21 Apr 2012 11:53:24 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201204211153.q3LBrOb6086641@svn.freebsd.org> From: Michael Tuexen Date: Sat, 21 Apr 2012 11:53: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: r234539 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 11:53:24 -0000 Author: tuexen Date: Sat Apr 21 11:53:24 2012 New Revision: 234539 URL: http://svn.freebsd.org/changeset/base/234539 Log: Fix check used by stream reset related events. MFC after: 3 days Modified: head/sys/netinet/sctputil.c Modified: head/sys/netinet/sctputil.c ============================================================================== --- head/sys/netinet/sctputil.c Sat Apr 21 11:51:31 2012 (r234538) +++ head/sys/netinet/sctputil.c Sat Apr 21 11:53:24 2012 (r234539) @@ -3214,7 +3214,7 @@ sctp_notify_stream_reset_add(struct sctp struct sctp_stream_change_event *stradd; int len; - if (sctp_is_feature_off(stcb->sctp_ep, SCTP_PCB_FLAGS_STREAM_RESETEVNT)) { + if (sctp_stcb_is_feature_off(stcb->sctp_ep, stcb, SCTP_PCB_FLAGS_STREAM_RESETEVNT)) { /* event not enabled */ return; } @@ -3275,7 +3275,7 @@ sctp_notify_stream_reset_tsn(struct sctp struct sctp_assoc_reset_event *strasoc; int len; - if (sctp_is_feature_off(stcb->sctp_ep, SCTP_PCB_FLAGS_STREAM_RESETEVNT)) { + if (sctp_stcb_is_feature_off(stcb->sctp_ep, stcb, SCTP_PCB_FLAGS_STREAM_RESETEVNT)) { /* event not enabled */ return; } @@ -3333,7 +3333,7 @@ sctp_notify_stream_reset(struct sctp_tcb struct sctp_stream_reset_event *strreset; int len; - if (sctp_is_feature_off(stcb->sctp_ep, SCTP_PCB_FLAGS_STREAM_RESETEVNT)) { + if (sctp_stcb_is_feature_off(stcb->sctp_ep, stcb, SCTP_PCB_FLAGS_STREAM_RESETEVNT)) { /* event not enabled */ return; } From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 13:46:00 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 122F6106564A; Sat, 21 Apr 2012 13:45:59 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: from mail-wi0-f178.google.com (mail-wi0-f178.google.com [209.85.212.178]) by mx1.freebsd.org (Postfix) with ESMTP id DDCA68FC08; Sat, 21 Apr 2012 13:45:58 +0000 (UTC) Received: by wibhq7 with SMTP id hq7so1212453wib.13 for ; Sat, 21 Apr 2012 06:45:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=KYjKlrcDSxvOZCRx2bymiMa4pVU0AeuKl6Krj6Gzdfw=; b=s5IdI/BjSKmKnGj0N4dLyzM/CNGl6NDunRmRqEQlduuHMvhHTJCwy+RGb8pUvh9MVS pesaH/Bb+14z2K6He6USiuTYLNYLd9O0YV81odWnxwwLj7GcE6LSgJVm8kamDIGhSRJe u9l9X4y9V0Vg1tb7mF0SPEmWCH6JeQEc3UbAm8IFQ1zJ9ZJ3KW/B26vSzAzPhQzVPZG1 kPDsuuyuk7G0q/qugCQD81Ydb3TASBH62aamGOLJftSPW3uXfr0UgAAkschtVXDrG7lD VELHXDzKtAwYvh5bhLuURJu3voUOEylsfJWNQIgmXTRk2wk4RHc5+ufXoat8cUJ4hGPl 3rNA== MIME-Version: 1.0 Received: by 10.216.132.226 with SMTP id o76mr5985055wei.93.1335015957902; Sat, 21 Apr 2012 06:45:57 -0700 (PDT) Received: by 10.180.85.71 with HTTP; Sat, 21 Apr 2012 06:45:57 -0700 (PDT) In-Reply-To: <201204202137.q3KLbhNj056524@svn.freebsd.org> References: <201204202137.q3KLbhNj056524@svn.freebsd.org> Date: Sat, 21 Apr 2012 09:45:57 -0400 Message-ID: From: Ryan Stone To: Brooks Davis 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: r234504 - in head/sys: amd64/conf i386/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 13:46:00 -0000 On Fri, Apr 20, 2012 at 5:37 PM, Brooks Davis wrote: > Author: brooks > Date: Fri Apr 20 21:37:42 2012 > New Revision: 234504 > URL: http://svn.freebsd.org/changeset/base/234504 > > Log: > =A0Enable DTrace hooks in GENERIC. > > =A0Reviewed by: =A0gnn > =A0Approved by: =A0core (jhb, imp) > =A0Requested by: a cast of thousands > =A0MFC after: =A0 =A03 days Excellent! Thanks to everybody who helped make this happen, starting with the participants at dtrace.conf who gave us the requisite whacks with the clue-by-four. However, what is our policy for enabling features in -STABLE that are known to be unstable? If we MFC this I don't have the slightest worry that somebody might see instability in their system just because the hooks are all of a sudden there, but I would worry that somebody make take DTrace hooks being enabled in GENERIC on -STABLE to imply that DTrace is stable, start using it and being upset when they trip over a DTrace bug. From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 14:23:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 87D3A106564A; Sat, 21 Apr 2012 14:23:47 +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 73A1A8FC08; Sat, 21 Apr 2012 14:23:47 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LENlUh091473; Sat, 21 Apr 2012 14:23:47 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LENlPh091471; Sat, 21 Apr 2012 14:23:47 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201204211423.q3LENlPh091471@svn.freebsd.org> From: Dimitry Andric Date: Sat, 21 Apr 2012 14:23: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: r234540 - head/sys/dev/dpt X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 14:23:47 -0000 Author: dim Date: Sat Apr 21 14:23:46 2012 New Revision: 234540 URL: http://svn.freebsd.org/changeset/base/234540 Log: Fix the following clang warning in dpt(4): sys/dev/dpt/dpt_scsi.c:612:18: error: implicit truncation from 'int' to bitfield changes value from -2 to 2 [-Werror,-Wconstant-conversion] dpt->cache_type = DPT_CACHE_WRITEBACK; ^ ~~~~~~~~~~~~~~~~~~~ by defining DPT_CACHE_WRITEBACK as 2, since dpt_softc::cache_type is an unsigned bitfield. No binary change. MFC after: 1 week Modified: head/sys/dev/dpt/dpt.h Modified: head/sys/dev/dpt/dpt.h ============================================================================== --- head/sys/dev/dpt/dpt.h Sat Apr 21 11:53:24 2012 (r234539) +++ head/sys/dev/dpt/dpt.h Sat Apr 21 14:23:46 2012 (r234540) @@ -142,7 +142,7 @@ typedef void *physaddr; */ #define DPT_NO_CACHE 0 #define DPT_CACHE_WRITETHROUGH 1 -#define DPT_CACHE_WRITEBACK -2 +#define DPT_CACHE_WRITEBACK 2 #define min(a,b) ((a Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 651EE1065672; Sat, 21 Apr 2012 14:30:52 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4F5248FC08; Sat, 21 Apr 2012 14:30:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LEUqAn091810; Sat, 21 Apr 2012 14:30:52 GMT (envelope-from kevlo@svn.freebsd.org) Received: (from kevlo@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LEUq1w091807; Sat, 21 Apr 2012 14:30:52 GMT (envelope-from kevlo@svn.freebsd.org) Message-Id: <201204211430.q3LEUq1w091807@svn.freebsd.org> From: Kevin Lo Date: Sat, 21 Apr 2012 14:30: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: r234541 - in head/sys/dev/usb: . serial X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 14:30:52 -0000 Author: kevlo Date: Sat Apr 21 14:30:51 2012 New Revision: 234541 URL: http://svn.freebsd.org/changeset/base/234541 Log: Add support for the SIMCom SIM5218, tested by me. Modified: head/sys/dev/usb/serial/u3g.c head/sys/dev/usb/usbdevs Modified: head/sys/dev/usb/serial/u3g.c ============================================================================== --- head/sys/dev/usb/serial/u3g.c Sat Apr 21 14:23:46 2012 (r234540) +++ head/sys/dev/usb/serial/u3g.c Sat Apr 21 14:30:51 2012 (r234541) @@ -354,6 +354,7 @@ static const STRUCT_USB_HOST_ID u3g_devs U3G_DEV(QISDA, H21_2, 0), U3G_DEV(QUALCOMM2, AC8700, 0), U3G_DEV(QUALCOMM2, MF330, 0), + U3G_DEV(QUALCOMM2, SIM5218, 0), U3G_DEV(QUALCOMM2, VW110L, U3GINIT_SCSIEJECT), U3G_DEV(QUALCOMMINC, AC2726, 0), U3G_DEV(QUALCOMMINC, AC8700, 0), Modified: head/sys/dev/usb/usbdevs ============================================================================== --- head/sys/dev/usb/usbdevs Sat Apr 21 14:23:46 2012 (r234540) +++ head/sys/dev/usb/usbdevs Sat Apr 21 14:30:51 2012 (r234541) @@ -2683,6 +2683,7 @@ product QUALCOMM2 RWT_FCT 0x3100 RWT FCT product QUALCOMM2 CDMA_MSM 0x3196 CDMA Technologies MSM modem product QUALCOMM2 AC8700 0x6000 AC8700 product QUALCOMM2 VW110L 0x1000 Vertex Wireless 110L modem +product QUALCOMM2 SIM5218 0x9000 SIM5218 product QUALCOMMINC CDMA_MSM 0x0001 CDMA Technologies MSM modem product QUALCOMMINC E0002 0x0002 3G modem product QUALCOMMINC E0003 0x0003 3G modem From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 14:39:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CD437106564A; Sat, 21 Apr 2012 14:39:47 +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 B8B178FC0C; Sat, 21 Apr 2012 14:39:47 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LEdlDw092100; Sat, 21 Apr 2012 14:39:47 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LEdl3A092098; Sat, 21 Apr 2012 14:39:47 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201204211439.q3LEdl3A092098@svn.freebsd.org> From: Nathan Whitehorn Date: Sat, 21 Apr 2012 14:39: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: r234542 - head/sys/powerpc/include X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 14:39:47 -0000 Author: nwhitehorn Date: Sat Apr 21 14:39:47 2012 New Revision: 234542 URL: http://svn.freebsd.org/changeset/base/234542 Log: Organize some members of ucontext_t in the same order they are in the trap frame. These are usually not used, and so this changes very little. MFC after: 5 days Modified: head/sys/powerpc/include/ucontext.h Modified: head/sys/powerpc/include/ucontext.h ============================================================================== --- head/sys/powerpc/include/ucontext.h Sat Apr 21 14:30:51 2012 (r234541) +++ head/sys/powerpc/include/ucontext.h Sat Apr 21 14:39:47 2012 (r234542) @@ -71,9 +71,9 @@ typedef struct __mcontext32 { #define mc_ctr mc_frame[35] #define mc_srr0 mc_frame[36] #define mc_srr1 mc_frame[37] -#define mc_dar mc_frame[38] -#define mc_dsisr mc_frame[39] -#define mc_exc mc_frame[40] +#define mc_exc mc_frame[38] +#define mc_dar mc_frame[39] +#define mc_dsisr mc_frame[40] /* floating-point state */ #define mc_fpscr mc_fpreg[32] From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 15:09:23 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A6C2A106564A; Sat, 21 Apr 2012 15:09:23 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8E1DD8FC08; Sat, 21 Apr 2012 15:09:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LF9NVn093146; Sat, 21 Apr 2012 15:09:23 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LF9N4K093124; Sat, 21 Apr 2012 15:09:23 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201204211509.q3LF9N4K093124@svn.freebsd.org> From: Jason Evans Date: Sat, 21 Apr 2012 15:09: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: r234543 - in head/contrib/jemalloc: . doc include/jemalloc include/jemalloc/internal src X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 15:09:23 -0000 Author: jasone Date: Sat Apr 21 15:09:22 2012 New Revision: 234543 URL: http://svn.freebsd.org/changeset/base/234543 Log: Import jemalloc 606f1fdc3cdbc700717133ca56685313caea24bb (dev branch, prior to 3.0.0 release), and mangle internal symbols. Modified: head/contrib/jemalloc/ChangeLog head/contrib/jemalloc/FREEBSD-diffs head/contrib/jemalloc/FREEBSD-upgrade head/contrib/jemalloc/VERSION head/contrib/jemalloc/doc/jemalloc.3 head/contrib/jemalloc/include/jemalloc/internal/arena.h head/contrib/jemalloc/include/jemalloc/internal/chunk_mmap.h head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h head/contrib/jemalloc/include/jemalloc/internal/prof.h head/contrib/jemalloc/include/jemalloc/internal/tcache.h head/contrib/jemalloc/include/jemalloc/internal/tsd.h head/contrib/jemalloc/include/jemalloc/jemalloc.h head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h head/contrib/jemalloc/src/arena.c head/contrib/jemalloc/src/chunk.c head/contrib/jemalloc/src/chunk_mmap.c head/contrib/jemalloc/src/ctl.c head/contrib/jemalloc/src/jemalloc.c head/contrib/jemalloc/src/prof.c head/contrib/jemalloc/src/quarantine.c head/contrib/jemalloc/src/stats.c head/contrib/jemalloc/src/tcache.c head/contrib/jemalloc/src/tsd.c head/contrib/jemalloc/src/util.c Modified: head/contrib/jemalloc/ChangeLog ============================================================================== --- head/contrib/jemalloc/ChangeLog Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/ChangeLog Sat Apr 21 15:09:22 2012 (r234543) @@ -34,6 +34,8 @@ found in the git revision history: - Add the --with-mangling option. - Add the --disable-experimental option. - Add the "thread.tcache.enabled" mallctl. + - Add the "opt.prof_final" mallctl. + - Update pprof (from gperftools 2.0). Incompatible changes: - Enable stats by default. @@ -41,6 +43,8 @@ found in the git revision history: - Disable lazy locking by default. - Rename the "tcache.flush" mallctl to "thread.tcache.flush". - Rename the "arenas.pagesize" mallctl to "arenas.page". + - Change the "opt.lg_prof_sample" default from 0 to 19 (1 B to 512 KiB). + - Change the "opt.prof_accum" default from true to false. Removed features: - Remove the swap feature, including the "config.swap", "swap.avail", @@ -77,6 +81,7 @@ found in the git revision history: - Add missing "opt.lg_tcache_max" mallctl implementation. - Use glibc allocator hooks to make mixed allocator usage less likely. - Fix build issues for --disable-tcache. + - Don't mangle pthread_create() when --with-private-namespace is specified. * 2.2.5 (November 14, 2011) Modified: head/contrib/jemalloc/FREEBSD-diffs ============================================================================== --- head/contrib/jemalloc/FREEBSD-diffs Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/FREEBSD-diffs Sat Apr 21 15:09:22 2012 (r234543) @@ -1,5 +1,5 @@ diff --git a/doc/jemalloc.xml.in b/doc/jemalloc.xml.in -index 98d0ba4..23d2152 100644 +index f78f423..ce6df80 100644 --- a/doc/jemalloc.xml.in +++ b/doc/jemalloc.xml.in @@ -51,12 +51,23 @@ @@ -27,7 +27,7 @@ index 98d0ba4..23d2152 100644 Standard API -@@ -2080,4 +2091,16 @@ malloc_conf = "lg_chunk:24";]]> +@@ -2091,4 +2102,16 @@ malloc_conf = "lg_chunk:24";]]> The posix_memalign function conforms to IEEE Std 1003.1-2001 (“POSIX.1”). @@ -45,7 +45,7 @@ index 98d0ba4..23d2152 100644 + diff --git a/include/jemalloc/internal/jemalloc_internal.h.in b/include/jemalloc/internal/jemalloc_internal.h.in -index 905653a..b235a0d 100644 +index b61abe8..edbb437 100644 --- a/include/jemalloc/internal/jemalloc_internal.h.in +++ b/include/jemalloc/internal/jemalloc_internal.h.in @@ -1,5 +1,8 @@ @@ -68,18 +68,38 @@ index 905653a..b235a0d 100644 #include "../jemalloc@install_suffix@.h" diff --git a/include/jemalloc/internal/mutex.h b/include/jemalloc/internal/mutex.h -index c46feee..d7133f4 100644 +index 8837ef5..d7133f4 100644 --- a/include/jemalloc/internal/mutex.h +++ b/include/jemalloc/internal/mutex.h -@@ -39,8 +39,6 @@ struct malloc_mutex_s { +@@ -39,9 +39,6 @@ struct malloc_mutex_s { #ifdef JEMALLOC_LAZY_LOCK extern bool isthreaded; -#else +-# undef isthreaded /* Undo private_namespace.h definition. */ -# define isthreaded true #endif bool malloc_mutex_init(malloc_mutex_t *mutex); +diff --git a/include/jemalloc/internal/private_namespace.h b/include/jemalloc/internal/private_namespace.h +index 15fe3c5..be94eb8 100644 +--- a/include/jemalloc/internal/private_namespace.h ++++ b/include/jemalloc/internal/private_namespace.h +@@ -1,6 +1,3 @@ +-#define a0calloc JEMALLOC_N(a0calloc) +-#define a0free JEMALLOC_N(a0free) +-#define a0malloc JEMALLOC_N(a0malloc) + #define arena_alloc_junk_small JEMALLOC_N(arena_alloc_junk_small) + #define arena_bin_index JEMALLOC_N(arena_bin_index) + #define arena_bin_info JEMALLOC_N(arena_bin_info) +@@ -167,7 +164,6 @@ + #define iqalloc JEMALLOC_N(iqalloc) + #define iralloc JEMALLOC_N(iralloc) + #define isalloc JEMALLOC_N(isalloc) +-#define isthreaded JEMALLOC_N(isthreaded) + #define ivsalloc JEMALLOC_N(ivsalloc) + #define jemalloc_postfork_child JEMALLOC_N(jemalloc_postfork_child) + #define jemalloc_postfork_parent JEMALLOC_N(jemalloc_postfork_parent) diff --git a/include/jemalloc/jemalloc.h.in b/include/jemalloc/jemalloc.h.in index f0581db..f26d8bc 100644 --- a/include/jemalloc/jemalloc.h.in @@ -175,7 +195,7 @@ index 0000000..2c5797f +#define pthread_mutex_lock _pthread_mutex_lock +#define pthread_mutex_unlock _pthread_mutex_unlock diff --git a/src/jemalloc.c b/src/jemalloc.c -index 0decd8a..73fad29 100644 +index 00c2b23..729f4e1 100644 --- a/src/jemalloc.c +++ b/src/jemalloc.c @@ -8,6 +8,9 @@ malloc_tsd_data(, arenas, arena_t *, NULL) @@ -221,7 +241,7 @@ index 4b8ce57..7be5fc9 100644 bool diff --git a/src/util.c b/src/util.c -index 2aab61f..8b05042 100644 +index 99ae26d..b80676c 100644 --- a/src/util.c +++ b/src/util.c @@ -60,6 +60,22 @@ wrtmessage(void *cbopaque, const char *s) Modified: head/contrib/jemalloc/FREEBSD-upgrade ============================================================================== --- head/contrib/jemalloc/FREEBSD-upgrade Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/FREEBSD-upgrade Sat Apr 21 15:09:22 2012 (r234543) @@ -72,7 +72,8 @@ do_extract() { find . -name '*.orig' -delete # Generate various files. ./autogen.sh --enable-cc-silence --enable-dss --enable-xmalloc \ - --enable-utrace --with-xslroot=/usr/local/share/xsl/docbook + --enable-utrace --with-xslroot=/usr/local/share/xsl/docbook \ + --with-private-namespace=__jemalloc_ gmake dist ) } Modified: head/contrib/jemalloc/VERSION ============================================================================== --- head/contrib/jemalloc/VERSION Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/VERSION Sat Apr 21 15:09:22 2012 (r234543) @@ -1 +1 @@ -1.0.0-266-gb57d3ec571c6551231be62b7bf92c084a8c8291c +1.0.0-283-g606f1fdc3cdbc700717133ca56685313caea24bb Modified: head/contrib/jemalloc/doc/jemalloc.3 ============================================================================== --- head/contrib/jemalloc/doc/jemalloc.3 Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/doc/jemalloc.3 Sat Apr 21 15:09:22 2012 (r234543) @@ -2,12 +2,12 @@ .\" Title: JEMALLOC .\" Author: Jason Evans .\" Generator: DocBook XSL Stylesheets v1.76.1 -.\" Date: 04/17/2012 +.\" Date: 04/20/2012 .\" Manual: User Manual -.\" Source: jemalloc 1.0.0-266-gb57d3ec571c6551231be62b7bf92c084a8c8291c +.\" Source: jemalloc 1.0.0-283-g606f1fdc3cdbc700717133ca56685313caea24bb .\" Language: English .\" -.TH "JEMALLOC" "3" "04/17/2012" "jemalloc 1.0.0-266-gb57d3ec571" "User Manual" +.TH "JEMALLOC" "3" "04/20/2012" "jemalloc 1.0.0-283-g606f1fdc3c" "User Manual" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- @@ -31,7 +31,7 @@ jemalloc \- general purpose memory allocation functions .SH "LIBRARY" .PP -This manual describes jemalloc 1\&.0\&.0\-266\-gb57d3ec571c6551231be62b7bf92c084a8c8291c\&. More information can be found at the +This manual describes jemalloc 1\&.0\&.0\-283\-g606f1fdc3cdbc700717133ca56685313caea24bb\&. More information can be found at the \m[blue]\fBjemalloc website\fR\m[]\&\s-2\u[1]\d\s+2\&. .PP The following configuration options are enabled in libc\*(Aqs built\-in jemalloc: @@ -753,14 +753,7 @@ Maximum size class (log base 2) to cache .PP "opt\&.prof" (\fBbool\fR) r\- [\fB\-\-enable\-prof\fR] .RS 4 -Memory profiling enabled/disabled\&. If enabled, profile memory allocation activity, and use an -\fBatexit\fR(3) -function to dump final memory usage to a file named according to the pattern -\&.\&.\&.f\&.heap, where - -is controlled by the -"opt\&.prof_prefix" -option\&. See the +Memory profiling enabled/disabled\&. If enabled, profile memory allocation activity\&. See the "opt\&.prof_active" option for on\-the\-fly activation/deactivation\&. See the "opt\&.lg_prof_sample" @@ -768,12 +761,14 @@ option for probabilistic sampling contro "opt\&.prof_accum" option for control of cumulative sample reporting\&. See the "opt\&.lg_prof_interval" -option for information on interval\-triggered profile dumping, and the +option for information on interval\-triggered profile dumping, the "opt\&.prof_gdump" -option for information on high\-water\-triggered profile dumping\&. Profile output is compatible with the included +option for information on high\-water\-triggered profile dumping, and the +"opt\&.prof_final" +option for final profile dumping\&. Profile output is compatible with the included \fBpprof\fR Perl script, which originates from the -\m[blue]\fBgoogle\-perftools package\fR\m[]\&\s-2\u[3]\d\s+2\&. +\m[blue]\fBgperftools package\fR\m[]\&\s-2\u[3]\d\s+2\&. .RE .PP "opt\&.prof_prefix" (\fBconst char *\fR) r\- [\fB\-\-enable\-prof\fR] @@ -793,12 +788,12 @@ mallctl\&. This option is enabled by def .PP "opt\&.lg_prof_sample" (\fBssize_t\fR) r\- [\fB\-\-enable\-prof\fR] .RS 4 -Average interval (log base 2) between allocation samples, as measured in bytes of allocation activity\&. Increasing the sampling interval decreases profile fidelity, but also decreases the computational overhead\&. The default sample interval is 1 (2^0) (i\&.e\&. all allocations are sampled)\&. +Average interval (log base 2) between allocation samples, as measured in bytes of allocation activity\&. Increasing the sampling interval decreases profile fidelity, but also decreases the computational overhead\&. The default sample interval is 512 KiB (2^19 B)\&. .RE .PP "opt\&.prof_accum" (\fBbool\fR) r\- [\fB\-\-enable\-prof\fR] .RS 4 -Reporting of cumulative object/byte counts in profile dumps enabled/disabled\&. If this option is enabled, every unique backtrace must be stored for the duration of execution\&. Depending on the application, this can impose a large memory overhead, and the cumulative counts are not always of interest\&. This option is enabled by default\&. +Reporting of cumulative object/byte counts in profile dumps enabled/disabled\&. If this option is enabled, every unique backtrace must be stored for the duration of execution\&. Depending on the application, this can impose a large memory overhead, and the cumulative counts are not always of interest\&. This option is disabled by default\&. .RE .PP "opt\&.lg_prof_interval" (\fBssize_t\fR) r\- [\fB\-\-enable\-prof\fR] @@ -821,6 +816,18 @@ is controlled by the option\&. This option is disabled by default\&. .RE .PP +"opt\&.prof_final" (\fBbool\fR) r\- [\fB\-\-enable\-prof\fR] +.RS 4 +Use an +\fBatexit\fR(3) +function to dump final memory usage to a file named according to the pattern +\&.\&.\&.f\&.heap, where + +is controlled by the +"opt\&.prof_prefix" +option\&. This option is enabled by default\&. +.RE +.PP "opt\&.prof_leak" (\fBbool\fR) r\- [\fB\-\-enable\-prof\fR] .RS 4 Leak reporting enabled/disabled\&. If enabled, use an @@ -1458,7 +1465,7 @@ Valgrind \%http://http://valgrind.org/ .RE .IP " 3." 4 -google-perftools package +gperftools package .RS 4 -\%http://code.google.com/p/google-perftools/ +\%http://code.google.com/p/gperftools/ .RE Modified: head/contrib/jemalloc/include/jemalloc/internal/arena.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/arena.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/internal/arena.h Sat Apr 21 15:09:22 2012 (r234543) @@ -408,7 +408,6 @@ void arena_dalloc_junk_small(void *ptr, void *arena_malloc_small(arena_t *arena, size_t size, bool zero); void *arena_malloc_large(arena_t *arena, size_t size, bool zero); void *arena_palloc(arena_t *arena, size_t size, size_t alignment, bool zero); -size_t arena_salloc(const void *ptr, bool demote); void arena_prof_promoted(const void *ptr, size_t size); void arena_dalloc_bin(arena_t *arena, arena_chunk_t *chunk, void *ptr, arena_chunk_map_t *mapelm); @@ -437,6 +436,7 @@ unsigned arena_run_regind(arena_run_t *r prof_ctx_t *arena_prof_ctx_get(const void *ptr); void arena_prof_ctx_set(const void *ptr, prof_ctx_t *ctx); void *arena_malloc(arena_t *arena, size_t size, bool zero, bool try_tcache); +size_t arena_salloc(const void *ptr, bool demote); void arena_dalloc(arena_t *arena, arena_chunk_t *chunk, void *ptr, bool try_tcache); #endif @@ -625,6 +625,46 @@ arena_malloc(arena_t *arena, size_t size } } +/* Return the size of the allocation pointed to by ptr. */ +JEMALLOC_INLINE size_t +arena_salloc(const void *ptr, bool demote) +{ + size_t ret; + arena_chunk_t *chunk; + size_t pageind, mapbits; + + assert(ptr != NULL); + assert(CHUNK_ADDR2BASE(ptr) != ptr); + + chunk = (arena_chunk_t *)CHUNK_ADDR2BASE(ptr); + pageind = ((uintptr_t)ptr - (uintptr_t)chunk) >> LG_PAGE; + mapbits = chunk->map[pageind-map_bias].bits; + assert((mapbits & CHUNK_MAP_ALLOCATED) != 0); + if ((mapbits & CHUNK_MAP_LARGE) == 0) { + arena_run_t *run = (arena_run_t *)((uintptr_t)chunk + + (uintptr_t)((pageind - (mapbits >> LG_PAGE)) << LG_PAGE)); + size_t binind = arena_bin_index(chunk->arena, run->bin); + arena_bin_info_t *bin_info = &arena_bin_info[binind]; + assert(((uintptr_t)ptr - ((uintptr_t)run + + (uintptr_t)bin_info->reg0_offset)) % bin_info->reg_interval + == 0); + ret = bin_info->reg_size; + } else { + assert(((uintptr_t)ptr & PAGE_MASK) == 0); + ret = mapbits & ~PAGE_MASK; + if (config_prof && demote && prof_promote && ret == PAGE && + (mapbits & CHUNK_MAP_CLASS_MASK) != 0) { + size_t binind = ((mapbits & CHUNK_MAP_CLASS_MASK) >> + CHUNK_MAP_CLASS_SHIFT) - 1; + assert(binind < NBINS); + ret = arena_bin_info[binind].reg_size; + } + assert(ret != 0); + } + + return (ret); +} + JEMALLOC_INLINE void arena_dalloc(arena_t *arena, arena_chunk_t *chunk, void *ptr, bool try_tcache) { Modified: head/contrib/jemalloc/include/jemalloc/internal/chunk_mmap.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/chunk_mmap.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/internal/chunk_mmap.h Sat Apr 21 15:09:22 2012 (r234543) @@ -9,6 +9,8 @@ /******************************************************************************/ #ifdef JEMALLOC_H_EXTERNS +void pages_purge(void *addr, size_t length); + void *chunk_alloc_mmap(size_t size, size_t alignment); bool chunk_dealloc_mmap(void *chunk, size_t size); Modified: head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h Sat Apr 21 15:09:22 2012 (r234543) @@ -738,10 +738,9 @@ isalloc(const void *ptr, bool demote) assert(config_prof || demote == false); chunk = (arena_chunk_t *)CHUNK_ADDR2BASE(ptr); - if (chunk != ptr) { - /* Region. */ + if (chunk != ptr) ret = arena_salloc(ptr, demote); - } else + else ret = huge_salloc(ptr); return (ret); Modified: head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h Sat Apr 21 15:09:22 2012 (r234543) @@ -1,5 +1,6 @@ #define arena_alloc_junk_small JEMALLOC_N(arena_alloc_junk_small) #define arena_bin_index JEMALLOC_N(arena_bin_index) +#define arena_bin_info JEMALLOC_N(arena_bin_info) #define arena_boot JEMALLOC_N(arena_boot) #define arena_dalloc JEMALLOC_N(arena_dalloc) #define arena_dalloc_bin JEMALLOC_N(arena_dalloc_bin) @@ -8,6 +9,7 @@ #define arena_malloc JEMALLOC_N(arena_malloc) #define arena_malloc_large JEMALLOC_N(arena_malloc_large) #define arena_malloc_small JEMALLOC_N(arena_malloc_small) +#define arena_maxclass JEMALLOC_N(arena_maxclass) #define arena_new JEMALLOC_N(arena_new) #define arena_palloc JEMALLOC_N(arena_palloc) #define arena_postfork_child JEMALLOC_N(arena_postfork_child) @@ -24,9 +26,13 @@ #define arena_salloc JEMALLOC_N(arena_salloc) #define arena_stats_merge JEMALLOC_N(arena_stats_merge) #define arena_tcache_fill_small JEMALLOC_N(arena_tcache_fill_small) +#define arenas JEMALLOC_N(arenas) #define arenas_bin_i_index JEMALLOC_N(arenas_bin_i_index) +#define arenas_booted JEMALLOC_N(arenas_booted) #define arenas_cleanup JEMALLOC_N(arenas_cleanup) #define arenas_extend JEMALLOC_N(arenas_extend) +#define arenas_initialized JEMALLOC_N(arenas_initialized) +#define arenas_lock JEMALLOC_N(arenas_lock) #define arenas_lrun_i_index JEMALLOC_N(arenas_lrun_i_index) #define arenas_tls JEMALLOC_N(arenas_tls) #define arenas_tsd_boot JEMALLOC_N(arenas_tsd_boot) @@ -75,6 +81,11 @@ #define chunk_dss_prefork JEMALLOC_N(chunk_dss_prefork) #define chunk_in_dss JEMALLOC_N(chunk_in_dss) #define chunk_mmap_boot JEMALLOC_N(chunk_mmap_boot) +#define chunk_npages JEMALLOC_N(chunk_npages) +#define chunks_mtx JEMALLOC_N(chunks_mtx) +#define chunks_rtree JEMALLOC_N(chunks_rtree) +#define chunksize JEMALLOC_N(chunksize) +#define chunksize_mask JEMALLOC_N(chunksize_mask) #define ckh_bucket_search JEMALLOC_N(ckh_bucket_search) #define ckh_count JEMALLOC_N(ckh_count) #define ckh_delete JEMALLOC_N(ckh_delete) @@ -129,9 +140,13 @@ #define extent_tree_szad_reverse_iter_start JEMALLOC_N(extent_tree_szad_reverse_iter_start) #define extent_tree_szad_search JEMALLOC_N(extent_tree_szad_search) #define hash JEMALLOC_N(hash) +#define huge_allocated JEMALLOC_N(huge_allocated) #define huge_boot JEMALLOC_N(huge_boot) #define huge_dalloc JEMALLOC_N(huge_dalloc) #define huge_malloc JEMALLOC_N(huge_malloc) +#define huge_mtx JEMALLOC_N(huge_mtx) +#define huge_ndalloc JEMALLOC_N(huge_ndalloc) +#define huge_nmalloc JEMALLOC_N(huge_nmalloc) #define huge_palloc JEMALLOC_N(huge_palloc) #define huge_postfork_child JEMALLOC_N(huge_postfork_child) #define huge_postfork_parent JEMALLOC_N(huge_postfork_parent) @@ -171,12 +186,16 @@ #define malloc_vcprintf JEMALLOC_N(malloc_vcprintf) #define malloc_vsnprintf JEMALLOC_N(malloc_vsnprintf) #define malloc_write JEMALLOC_N(malloc_write) +#define map_bias JEMALLOC_N(map_bias) #define mb_write JEMALLOC_N(mb_write) #define mmap_unaligned_tsd_boot JEMALLOC_N(mmap_unaligned_tsd_boot) #define mmap_unaligned_tsd_cleanup_wrapper JEMALLOC_N(mmap_unaligned_tsd_cleanup_wrapper) #define mmap_unaligned_tsd_get JEMALLOC_N(mmap_unaligned_tsd_get) #define mmap_unaligned_tsd_set JEMALLOC_N(mmap_unaligned_tsd_set) #define mutex_boot JEMALLOC_N(mutex_boot) +#define narenas JEMALLOC_N(narenas) +#define ncpus JEMALLOC_N(ncpus) +#define nhbins JEMALLOC_N(nhbins) #define opt_abort JEMALLOC_N(opt_abort) #define opt_junk JEMALLOC_N(opt_junk) #define opt_lg_chunk JEMALLOC_N(opt_lg_chunk) @@ -188,14 +207,20 @@ #define opt_prof JEMALLOC_N(opt_prof) #define opt_prof_accum JEMALLOC_N(opt_prof_accum) #define opt_prof_active JEMALLOC_N(opt_prof_active) +#define opt_prof_final JEMALLOC_N(opt_prof_final) #define opt_prof_gdump JEMALLOC_N(opt_prof_gdump) #define opt_prof_leak JEMALLOC_N(opt_prof_leak) +#define opt_prof_prefix JEMALLOC_N(opt_prof_prefix) +#define opt_quarantine JEMALLOC_N(opt_quarantine) +#define opt_redzone JEMALLOC_N(opt_redzone) #define opt_stats_print JEMALLOC_N(opt_stats_print) #define opt_tcache JEMALLOC_N(opt_tcache) #define opt_utrace JEMALLOC_N(opt_utrace) +#define opt_valgrind JEMALLOC_N(opt_valgrind) #define opt_xmalloc JEMALLOC_N(opt_xmalloc) #define opt_zero JEMALLOC_N(opt_zero) #define p2rz JEMALLOC_N(p2rz) +#define pages_purge JEMALLOC_N(pages_purge) #define pow2_ceil JEMALLOC_N(pow2_ceil) #define prof_backtrace JEMALLOC_N(prof_backtrace) #define prof_boot0 JEMALLOC_N(prof_boot0) @@ -206,18 +231,24 @@ #define prof_free JEMALLOC_N(prof_free) #define prof_gdump JEMALLOC_N(prof_gdump) #define prof_idump JEMALLOC_N(prof_idump) +#define prof_interval JEMALLOC_N(prof_interval) #define prof_lookup JEMALLOC_N(prof_lookup) #define prof_malloc JEMALLOC_N(prof_malloc) #define prof_mdump JEMALLOC_N(prof_mdump) +#define prof_lookup JEMALLOC_N(prof_lookup) +#define prof_promote JEMALLOC_N(prof_promote) #define prof_realloc JEMALLOC_N(prof_realloc) #define prof_sample_accum_update JEMALLOC_N(prof_sample_accum_update) #define prof_sample_threshold_update JEMALLOC_N(prof_sample_threshold_update) +#define prof_tdata_booted JEMALLOC_N(prof_tdata_booted) #define prof_tdata_cleanup JEMALLOC_N(prof_tdata_cleanup) +#define prof_tdata_init JEMALLOC_N(prof_tdata_init) +#define prof_tdata_initialized JEMALLOC_N(prof_tdata_initialized) +#define prof_tdata_tls JEMALLOC_N(prof_tdata_tls) #define prof_tdata_tsd_boot JEMALLOC_N(prof_tdata_tsd_boot) #define prof_tdata_tsd_cleanup_wrapper JEMALLOC_N(prof_tdata_tsd_cleanup_wrapper) #define prof_tdata_tsd_get JEMALLOC_N(prof_tdata_tsd_get) #define prof_tdata_tsd_set JEMALLOC_N(prof_tdata_tsd_set) -#define pthread_create JEMALLOC_N(pthread_create) #define quarantine JEMALLOC_N(quarantine) #define quarantine_boot JEMALLOC_N(quarantine_boot) #define quarantine_tsd_boot JEMALLOC_N(quarantine_tsd_boot) @@ -238,6 +269,7 @@ #define stats_cactive_add JEMALLOC_N(stats_cactive_add) #define stats_cactive_get JEMALLOC_N(stats_cactive_get) #define stats_cactive_sub JEMALLOC_N(stats_cactive_sub) +#define stats_chunks JEMALLOC_N(stats_chunks) #define stats_print JEMALLOC_N(stats_print) #define tcache_alloc_easy JEMALLOC_N(tcache_alloc_easy) #define tcache_alloc_large JEMALLOC_N(tcache_alloc_large) @@ -247,26 +279,39 @@ #define tcache_arena_dissociate JEMALLOC_N(tcache_arena_dissociate) #define tcache_bin_flush_large JEMALLOC_N(tcache_bin_flush_large) #define tcache_bin_flush_small JEMALLOC_N(tcache_bin_flush_small) +#define tcache_bin_info JEMALLOC_N(tcache_bin_info) #define tcache_boot0 JEMALLOC_N(tcache_boot0) #define tcache_boot1 JEMALLOC_N(tcache_boot1) +#define tcache_booted JEMALLOC_N(tcache_booted) #define tcache_create JEMALLOC_N(tcache_create) #define tcache_dalloc_large JEMALLOC_N(tcache_dalloc_large) #define tcache_dalloc_small JEMALLOC_N(tcache_dalloc_small) #define tcache_destroy JEMALLOC_N(tcache_destroy) +#define tcache_enabled_booted JEMALLOC_N(tcache_enabled_booted) #define tcache_enabled_get JEMALLOC_N(tcache_enabled_get) +#define tcache_enabled_initialized JEMALLOC_N(tcache_enabled_initialized) #define tcache_enabled_set JEMALLOC_N(tcache_enabled_set) +#define tcache_enabled_tls JEMALLOC_N(tcache_enabled_tls) #define tcache_enabled_tsd_boot JEMALLOC_N(tcache_enabled_tsd_boot) #define tcache_enabled_tsd_cleanup_wrapper JEMALLOC_N(tcache_enabled_tsd_cleanup_wrapper) #define tcache_enabled_tsd_get JEMALLOC_N(tcache_enabled_tsd_get) #define tcache_enabled_tsd_set JEMALLOC_N(tcache_enabled_tsd_set) #define tcache_event JEMALLOC_N(tcache_event) +#define tcache_initialized JEMALLOC_N(tcache_initialized) #define tcache_flush JEMALLOC_N(tcache_flush) +#define tcache_get JEMALLOC_N(tcache_get) +#define tcache_maxclass JEMALLOC_N(tcache_maxclass) #define tcache_stats_merge JEMALLOC_N(tcache_stats_merge) +#define tcache_salloc JEMALLOC_N(tcache_salloc) #define tcache_thread_cleanup JEMALLOC_N(tcache_thread_cleanup) +#define tcache_tls JEMALLOC_N(tcache_tls) #define tcache_tsd_boot JEMALLOC_N(tcache_tsd_boot) #define tcache_tsd_cleanup_wrapper JEMALLOC_N(tcache_tsd_cleanup_wrapper) #define tcache_tsd_get JEMALLOC_N(tcache_tsd_get) #define tcache_tsd_set JEMALLOC_N(tcache_tsd_set) +#define thread_allocated_booted JEMALLOC_N(thread_allocated_booted) +#define thread_allocated_initialized JEMALLOC_N(thread_allocated_initialized) +#define thread_allocated_tls JEMALLOC_N(thread_allocated_tls) #define thread_allocated_tsd_boot JEMALLOC_N(thread_allocated_tsd_boot) #define thread_allocated_tsd_cleanup_wrapper JEMALLOC_N(thread_allocated_tsd_cleanup_wrapper) #define thread_allocated_tsd_get JEMALLOC_N(thread_allocated_tsd_get) Modified: head/contrib/jemalloc/include/jemalloc/internal/prof.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/prof.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/internal/prof.h Sat Apr 21 15:09:22 2012 (r234543) @@ -9,7 +9,7 @@ typedef struct prof_tdata_s prof_tdata_t /* Option defaults. */ #define PROF_PREFIX_DEFAULT "jeprof" -#define LG_PROF_SAMPLE_DEFAULT 0 +#define LG_PROF_SAMPLE_DEFAULT 19 #define LG_PROF_INTERVAL_DEFAULT -1 /* @@ -169,6 +169,7 @@ extern bool opt_prof_active; extern size_t opt_lg_prof_sample; /* Mean bytes between samples. */ extern ssize_t opt_lg_prof_interval; /* lg(prof_interval). */ extern bool opt_prof_gdump; /* High-water memory dumping. */ +extern bool opt_prof_final; /* Final profile dumping. */ extern bool opt_prof_leak; /* Dump leak summary at exit. */ extern bool opt_prof_accum; /* Report cumulative bytes. */ extern char opt_prof_prefix[PATH_MAX + 1]; Modified: head/contrib/jemalloc/include/jemalloc/internal/tcache.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/tcache.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/internal/tcache.h Sat Apr 21 15:09:22 2012 (r234543) @@ -100,6 +100,9 @@ extern size_t nhbins; /* Maximum cached size class. */ extern size_t tcache_maxclass; +size_t tcache_salloc(const void *ptr); +void *tcache_alloc_small_hard(tcache_t *tcache, tcache_bin_t *tbin, + size_t binind); void tcache_bin_flush_small(tcache_bin_t *tbin, size_t binind, unsigned rem, tcache_t *tcache); void tcache_bin_flush_large(tcache_bin_t *tbin, size_t binind, unsigned rem, @@ -107,8 +110,6 @@ void tcache_bin_flush_large(tcache_bin_t void tcache_arena_associate(tcache_t *tcache, arena_t *arena); void tcache_arena_dissociate(tcache_t *tcache); tcache_t *tcache_create(arena_t *arena); -void *tcache_alloc_small_hard(tcache_t *tcache, tcache_bin_t *tbin, - size_t binind); void tcache_destroy(tcache_t *tcache); void tcache_thread_cleanup(void *arg); void tcache_stats_merge(tcache_t *tcache, arena_t *arena); @@ -340,7 +341,7 @@ tcache_alloc_small(tcache_t *tcache, siz if (ret == NULL) return (NULL); } - assert(arena_salloc(ret, false) == arena_bin_info[binind].reg_size); + assert(tcache_salloc(ret) == arena_bin_info[binind].reg_size); if (zero == false) { if (config_fill) { @@ -431,7 +432,7 @@ tcache_dalloc_small(tcache_t *tcache, vo size_t pageind, binind; arena_chunk_map_t *mapelm; - assert(arena_salloc(ptr, false) <= SMALL_MAXCLASS); + assert(tcache_salloc(ptr) <= SMALL_MAXCLASS); chunk = (arena_chunk_t *)CHUNK_ADDR2BASE(ptr); arena = chunk->arena; @@ -468,8 +469,8 @@ tcache_dalloc_large(tcache_t *tcache, vo tcache_bin_info_t *tbin_info; assert((size & PAGE_MASK) == 0); - assert(arena_salloc(ptr, false) > SMALL_MAXCLASS); - assert(arena_salloc(ptr, false) <= tcache_maxclass); + assert(tcache_salloc(ptr) > SMALL_MAXCLASS); + assert(tcache_salloc(ptr) <= tcache_maxclass); binind = NBINS + (size >> LG_PAGE) - 1; Modified: head/contrib/jemalloc/include/jemalloc/internal/tsd.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/tsd.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/internal/tsd.h Sat Apr 21 15:09:22 2012 (r234543) @@ -4,11 +4,7 @@ /* Maximum number of malloc_tsd users with cleanup functions. */ #define MALLOC_TSD_CLEANUPS_MAX 8 -typedef struct malloc_tsd_cleanup_s malloc_tsd_cleanup_t; -struct malloc_tsd_cleanup_s { - bool (*f)(void *); - void *arg; -}; +typedef bool (*malloc_tsd_cleanup_t)(void); /* * TLS/TSD-agnostic macro-based implementation of thread-specific data. There @@ -110,13 +106,12 @@ a_attr bool a_name##_booted = false; a_cleanup) \ /* Initialization/cleanup. */ \ a_attr bool \ -a_name##_tsd_cleanup_wrapper(void *arg) \ +a_name##_tsd_cleanup_wrapper(void) \ { \ - bool (*cleanup)(void *) = arg; \ \ if (a_name##_initialized) { \ a_name##_initialized = false; \ - cleanup(&a_name##_tls); \ + a_cleanup(&a_name##_tls); \ } \ return (a_name##_initialized); \ } \ @@ -126,7 +121,7 @@ a_name##_tsd_boot(void) \ \ if (a_cleanup != malloc_tsd_no_cleanup) { \ malloc_tsd_cleanup_register( \ - &a_name##_tsd_cleanup_wrapper, a_cleanup); \ + &a_name##_tsd_cleanup_wrapper); \ } \ a_name##_booted = true; \ return (false); \ @@ -192,7 +187,6 @@ a_name##_tsd_set(a_type *val) \ a_cleanup) \ /* Data structure. */ \ typedef struct { \ - bool isstatic; \ bool initialized; \ a_type val; \ } a_name##_tsd_wrapper_t; \ @@ -218,8 +212,7 @@ a_name##_tsd_cleanup_wrapper(void *arg) return; \ } \ } \ - if (wrapper->isstatic == false) \ - malloc_tsd_dalloc(wrapper); \ + malloc_tsd_dalloc(wrapper); \ } \ a_attr bool \ a_name##_tsd_boot(void) \ @@ -242,25 +235,19 @@ a_name##_tsd_get_wrapper(void) \ wrapper = (a_name##_tsd_wrapper_t *) \ malloc_tsd_malloc(sizeof(a_name##_tsd_wrapper_t)); \ if (wrapper == NULL) { \ - static a_name##_tsd_wrapper_t \ - a_name##_tsd_static_data = \ - {true, false, a_initializer}; \ malloc_write(": Error allocating" \ " TSD for "#a_name"\n"); \ - if (opt_abort) \ - abort(); \ - wrapper = &a_name##_tsd_static_data; \ + abort(); \ } else { \ static a_type tsd_static_data = a_initializer; \ - wrapper->isstatic = false; \ + wrapper->initialized = false; \ wrapper->val = tsd_static_data; \ } \ if (pthread_setspecific(a_name##_tsd, \ (void *)wrapper)) { \ malloc_write(": Error setting" \ " TSD for "#a_name"\n"); \ - if (opt_abort) \ - abort(); \ + abort(); \ } \ } \ return (wrapper); \ @@ -298,7 +285,7 @@ a_name##_tsd_set(a_type *val) \ void *malloc_tsd_malloc(size_t size); void malloc_tsd_dalloc(void *wrapper); void malloc_tsd_no_cleanup(void *); -void malloc_tsd_cleanup_register(bool (*f)(void *), void *arg); +void malloc_tsd_cleanup_register(bool (*f)(void)); void malloc_tsd_boot(void); #endif /* JEMALLOC_H_EXTERNS */ Modified: head/contrib/jemalloc/include/jemalloc/jemalloc.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/jemalloc.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/jemalloc.h Sat Apr 21 15:09:22 2012 (r234543) @@ -7,12 +7,12 @@ extern "C" { #include #include -#define JEMALLOC_VERSION "1.0.0-266-gb57d3ec571c6551231be62b7bf92c084a8c8291c" +#define JEMALLOC_VERSION "1.0.0-283-g606f1fdc3cdbc700717133ca56685313caea24bb" #define JEMALLOC_VERSION_MAJOR 1 #define JEMALLOC_VERSION_MINOR 0 #define JEMALLOC_VERSION_BUGFIX 0 -#define JEMALLOC_VERSION_NREV 266 -#define JEMALLOC_VERSION_GID "b57d3ec571c6551231be62b7bf92c084a8c8291c" +#define JEMALLOC_VERSION_NREV 283 +#define JEMALLOC_VERSION_GID "606f1fdc3cdbc700717133ca56685313caea24bb" #include "jemalloc_defs.h" #include "jemalloc_FreeBSD.h" Modified: head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h Sat Apr 21 15:09:22 2012 (r234543) @@ -39,8 +39,8 @@ * from being exported, but for static libraries, naming collisions are a real * possibility. */ -#define JEMALLOC_PRIVATE_NAMESPACE "" -#define JEMALLOC_N(string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix) string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix +#define JEMALLOC_PRIVATE_NAMESPACE "__jemalloc_" +#define JEMALLOC_N(string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix) __jemalloc_##string_that_no_one_should_want_to_use_as_a_jemalloc_private_namespace_prefix /* * Hyper-threaded CPUs may need a special instruction inside spin loops in @@ -221,13 +221,6 @@ */ /* #undef JEMALLOC_PURGE_MADVISE_DONTNEED */ #define JEMALLOC_PURGE_MADVISE_FREE -#ifdef JEMALLOC_PURGE_MADVISE_DONTNEED -# define JEMALLOC_MADV_PURGE MADV_DONTNEED -#elif defined(JEMALLOC_PURGE_MADVISE_FREE) -# define JEMALLOC_MADV_PURGE MADV_FREE -#else -# error "No method defined for purging unused dirty pages." -#endif /* sizeof(void *) == 2^LG_SIZEOF_PTR. */ #define LG_SIZEOF_PTR 3 Modified: head/contrib/jemalloc/src/arena.c ============================================================================== --- head/contrib/jemalloc/src/arena.c Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/src/arena.c Sat Apr 21 15:09:22 2012 (r234543) @@ -676,8 +676,8 @@ arena_chunk_purge(arena_t *arena, arena_ if (config_debug) ndirty -= npages; - madvise((void *)((uintptr_t)chunk + (pageind << LG_PAGE)), - (npages << LG_PAGE), JEMALLOC_MADV_PURGE); + pages_purge((void *)((uintptr_t)chunk + (pageind << LG_PAGE)), + (npages << LG_PAGE)); if (config_stats) nmadvise++; } @@ -1213,7 +1213,9 @@ void arena_prof_accum(arena_t *arena, uint64_t accumbytes) { - if (prof_interval != 0) { + cassert(config_prof); + + if (config_prof && prof_interval != 0) { arena->prof_accumbytes += accumbytes; if (arena->prof_accumbytes >= prof_interval) { prof_idump(); @@ -1463,53 +1465,13 @@ arena_palloc(arena_t *arena, size_t size return (ret); } -/* Return the size of the allocation pointed to by ptr. */ -size_t -arena_salloc(const void *ptr, bool demote) -{ - size_t ret; - arena_chunk_t *chunk; - size_t pageind, mapbits; - - assert(ptr != NULL); - assert(CHUNK_ADDR2BASE(ptr) != ptr); - - chunk = (arena_chunk_t *)CHUNK_ADDR2BASE(ptr); - pageind = ((uintptr_t)ptr - (uintptr_t)chunk) >> LG_PAGE; - mapbits = chunk->map[pageind-map_bias].bits; - assert((mapbits & CHUNK_MAP_ALLOCATED) != 0); - if ((mapbits & CHUNK_MAP_LARGE) == 0) { - arena_run_t *run = (arena_run_t *)((uintptr_t)chunk + - (uintptr_t)((pageind - (mapbits >> LG_PAGE)) << LG_PAGE)); - size_t binind = arena_bin_index(chunk->arena, run->bin); - arena_bin_info_t *bin_info = &arena_bin_info[binind]; - assert(((uintptr_t)ptr - ((uintptr_t)run + - (uintptr_t)bin_info->reg0_offset)) % bin_info->reg_interval - == 0); - ret = bin_info->reg_size; - } else { - assert(((uintptr_t)ptr & PAGE_MASK) == 0); - ret = mapbits & ~PAGE_MASK; - if (demote && prof_promote && ret == PAGE && (mapbits & - CHUNK_MAP_CLASS_MASK) != 0) { - size_t binind = ((mapbits & CHUNK_MAP_CLASS_MASK) >> - CHUNK_MAP_CLASS_SHIFT) - 1; - assert(binind < NBINS); - ret = arena_bin_info[binind].reg_size; - } - assert(ret != 0); - } - - return (ret); -} - void arena_prof_promoted(const void *ptr, size_t size) { arena_chunk_t *chunk; size_t pageind, binind; - assert(config_prof); + cassert(config_prof); assert(ptr != NULL); assert(CHUNK_ADDR2BASE(ptr) != ptr); assert(isalloc(ptr, false) == PAGE); Modified: head/contrib/jemalloc/src/chunk.c ============================================================================== --- head/contrib/jemalloc/src/chunk.c Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/src/chunk.c Sat Apr 21 15:09:22 2012 (r234543) @@ -171,7 +171,7 @@ chunk_record(void *chunk, size_t size) { extent_node_t *xnode, *node, *prev, key; - madvise(chunk, size, JEMALLOC_MADV_PURGE); + pages_purge(chunk, size); xnode = NULL; malloc_mutex_lock(&chunks_mtx); Modified: head/contrib/jemalloc/src/chunk_mmap.c ============================================================================== --- head/contrib/jemalloc/src/chunk_mmap.c Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/src/chunk_mmap.c Sat Apr 21 15:09:22 2012 (r234543) @@ -72,6 +72,20 @@ pages_unmap(void *addr, size_t size) } } +void +pages_purge(void *addr, size_t length) +{ + +#ifdef JEMALLOC_PURGE_MADVISE_DONTNEED +# define JEMALLOC_MADV_PURGE MADV_DONTNEED +#elif defined(JEMALLOC_PURGE_MADVISE_FREE) +# define JEMALLOC_MADV_PURGE MADV_FREE +#else +# error "No method defined for purging unused dirty pages." +#endif + madvise(addr, length, JEMALLOC_MADV_PURGE); +} + static void * chunk_alloc_mmap_slow(size_t size, size_t alignment, bool unaligned) { Modified: head/contrib/jemalloc/src/ctl.c ============================================================================== --- head/contrib/jemalloc/src/ctl.c Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/src/ctl.c Sat Apr 21 15:09:22 2012 (r234543) @@ -80,6 +80,7 @@ CTL_PROTO(opt_prof_active) CTL_PROTO(opt_lg_prof_sample) CTL_PROTO(opt_lg_prof_interval) CTL_PROTO(opt_prof_gdump) +CTL_PROTO(opt_prof_final) CTL_PROTO(opt_prof_leak) CTL_PROTO(opt_prof_accum) CTL_PROTO(arenas_bin_i_size) @@ -210,6 +211,7 @@ static const ctl_node_t opt_node[] = { {NAME("lg_prof_sample"), CTL(opt_lg_prof_sample)}, {NAME("lg_prof_interval"), CTL(opt_lg_prof_interval)}, {NAME("prof_gdump"), CTL(opt_prof_gdump)}, + {NAME("prof_final"), CTL(opt_prof_final)}, {NAME("prof_leak"), CTL(opt_prof_leak)}, {NAME("prof_accum"), CTL(opt_prof_accum)} }; @@ -1122,6 +1124,7 @@ CTL_RO_CGEN(config_prof, opt_prof_active CTL_RO_NL_CGEN(config_prof, opt_lg_prof_sample, opt_lg_prof_sample, size_t) CTL_RO_NL_CGEN(config_prof, opt_lg_prof_interval, opt_lg_prof_interval, ssize_t) CTL_RO_NL_CGEN(config_prof, opt_prof_gdump, opt_prof_gdump, bool) +CTL_RO_NL_CGEN(config_prof, opt_prof_final, opt_prof_final, bool) CTL_RO_NL_CGEN(config_prof, opt_prof_leak, opt_prof_leak, bool) CTL_RO_NL_CGEN(config_prof, opt_prof_accum, opt_prof_accum, bool) Modified: head/contrib/jemalloc/src/jemalloc.c ============================================================================== --- head/contrib/jemalloc/src/jemalloc.c Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/src/jemalloc.c Sat Apr 21 15:09:22 2012 (r234543) @@ -427,7 +427,7 @@ malloc_conf_init(void) while (*opts != '\0' && malloc_conf_next(&opts, &k, &klen, &v, &vlen) == false) { #define CONF_HANDLE_BOOL_HIT(o, n, hit) \ - if (sizeof(#n)-1 == klen && strncmp(#n, k, \ + if (sizeof(n)-1 == klen && strncmp(n, k, \ klen) == 0) { \ if (strncmp("true", v, vlen) == 0 && \ vlen == sizeof("true")-1) \ @@ -450,7 +450,7 @@ malloc_conf_init(void) continue; \ } #define CONF_HANDLE_SIZE_T(o, n, min, max) \ - if (sizeof(#n)-1 == klen && strncmp(#n, k, \ + if (sizeof(n)-1 == klen && strncmp(n, k, \ klen) == 0) { \ uintmax_t um; \ char *end; \ @@ -471,7 +471,7 @@ malloc_conf_init(void) continue; \ } #define CONF_HANDLE_SSIZE_T(o, n, min, max) \ - if (sizeof(#n)-1 == klen && strncmp(#n, k, \ + if (sizeof(n)-1 == klen && strncmp(n, k, \ klen) == 0) { \ long l; \ char *end; \ @@ -493,7 +493,7 @@ malloc_conf_init(void) continue; \ } #define CONF_HANDLE_CHAR_P(o, n, d) \ - if (sizeof(#n)-1 == klen && strncmp(#n, k, \ + if (sizeof(n)-1 == klen && strncmp(n, k, \ klen) == 0) { \ size_t cpylen = (vlen <= \ sizeof(o)-1) ? vlen : \ @@ -503,7 +503,7 @@ malloc_conf_init(void) continue; \ } - CONF_HANDLE_BOOL(opt_abort, abort) + CONF_HANDLE_BOOL(opt_abort, "abort") /* * Chunks always require at least one header page, plus * one data page in the absence of redzones, or three @@ -511,26 +511,27 @@ malloc_conf_init(void) * simplify options processing, fix the limit based on * config_fill. */ - CONF_HANDLE_SIZE_T(opt_lg_chunk, lg_chunk, LG_PAGE + + CONF_HANDLE_SIZE_T(opt_lg_chunk, "lg_chunk", LG_PAGE + (config_fill ? 2 : 1), (sizeof(size_t) << 3) - 1) - CONF_HANDLE_SIZE_T(opt_narenas, narenas, 1, SIZE_T_MAX) - CONF_HANDLE_SSIZE_T(opt_lg_dirty_mult, lg_dirty_mult, + CONF_HANDLE_SIZE_T(opt_narenas, "narenas", 1, + SIZE_T_MAX) + CONF_HANDLE_SSIZE_T(opt_lg_dirty_mult, "lg_dirty_mult", -1, (sizeof(size_t) << 3) - 1) - CONF_HANDLE_BOOL(opt_stats_print, stats_print) + CONF_HANDLE_BOOL(opt_stats_print, "stats_print") if (config_fill) { - CONF_HANDLE_BOOL(opt_junk, junk) - CONF_HANDLE_SIZE_T(opt_quarantine, quarantine, + CONF_HANDLE_BOOL(opt_junk, "junk") + CONF_HANDLE_SIZE_T(opt_quarantine, "quarantine", 0, SIZE_T_MAX) - CONF_HANDLE_BOOL(opt_redzone, redzone) - CONF_HANDLE_BOOL(opt_zero, zero) + CONF_HANDLE_BOOL(opt_redzone, "redzone") + CONF_HANDLE_BOOL(opt_zero, "zero") } if (config_utrace) { - CONF_HANDLE_BOOL(opt_utrace, utrace) + CONF_HANDLE_BOOL(opt_utrace, "utrace") } if (config_valgrind) { bool hit; CONF_HANDLE_BOOL_HIT(opt_valgrind, - valgrind, hit) + "valgrind", hit) if (config_fill && opt_valgrind && hit) { opt_junk = false; opt_zero = false; @@ -544,28 +545,29 @@ malloc_conf_init(void) continue; } if (config_xmalloc) { - CONF_HANDLE_BOOL(opt_xmalloc, xmalloc) + CONF_HANDLE_BOOL(opt_xmalloc, "xmalloc") } if (config_tcache) { - CONF_HANDLE_BOOL(opt_tcache, tcache) + CONF_HANDLE_BOOL(opt_tcache, "tcache") CONF_HANDLE_SSIZE_T(opt_lg_tcache_max, - lg_tcache_max, -1, + "lg_tcache_max", -1, (sizeof(size_t) << 3) - 1) } if (config_prof) { - CONF_HANDLE_BOOL(opt_prof, prof) - CONF_HANDLE_CHAR_P(opt_prof_prefix, prof_prefix, - "jeprof") - CONF_HANDLE_BOOL(opt_prof_active, prof_active) + CONF_HANDLE_BOOL(opt_prof, "prof") + CONF_HANDLE_CHAR_P(opt_prof_prefix, + "prof_prefix", "jeprof") + CONF_HANDLE_BOOL(opt_prof_active, "prof_active") CONF_HANDLE_SSIZE_T(opt_lg_prof_sample, - lg_prof_sample, 0, + "lg_prof_sample", 0, (sizeof(uint64_t) << 3) - 1) - CONF_HANDLE_BOOL(opt_prof_accum, prof_accum) + CONF_HANDLE_BOOL(opt_prof_accum, "prof_accum") CONF_HANDLE_SSIZE_T(opt_lg_prof_interval, - lg_prof_interval, -1, + "lg_prof_interval", -1, (sizeof(uint64_t) << 3) - 1) - CONF_HANDLE_BOOL(opt_prof_gdump, prof_gdump) - CONF_HANDLE_BOOL(opt_prof_leak, prof_leak) + CONF_HANDLE_BOOL(opt_prof_gdump, "prof_gdump") + CONF_HANDLE_BOOL(opt_prof_final, "prof_final") + CONF_HANDLE_BOOL(opt_prof_leak, "prof_leak") } malloc_conf_error("Invalid conf pair", k, klen, v, vlen); @@ -1624,6 +1626,7 @@ je_nallocm(size_t *rsize, size_t size, i void jemalloc_prefork(void) #else +JEMALLOC_ATTR(visibility("default")) void _malloc_prefork(void) #endif @@ -1645,6 +1648,7 @@ _malloc_prefork(void) void jemalloc_postfork_parent(void) #else +JEMALLOC_ATTR(visibility("default")) void _malloc_postfork(void) #endif Modified: head/contrib/jemalloc/src/prof.c ============================================================================== --- head/contrib/jemalloc/src/prof.c Sat Apr 21 14:39:47 2012 (r234542) +++ head/contrib/jemalloc/src/prof.c Sat Apr 21 15:09:22 2012 (r234543) @@ -21,8 +21,9 @@ bool opt_prof_active = true; size_t opt_lg_prof_sample = LG_PROF_SAMPLE_DEFAULT; ssize_t opt_lg_prof_interval = LG_PROF_INTERVAL_DEFAULT; bool opt_prof_gdump = false; +bool opt_prof_final = true; bool opt_prof_leak = false; -bool opt_prof_accum = true; +bool opt_prof_accum = false; char opt_prof_prefix[PATH_MAX + 1]; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 16:02:00 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C5C83106566B; Sat, 21 Apr 2012 16:02:00 +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 AFDA88FC0C; Sat, 21 Apr 2012 16:02:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LG207t094897; Sat, 21 Apr 2012 16:02:00 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LG20r7094895; Sat, 21 Apr 2012 16:02:00 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201204211602.q3LG20r7094895@svn.freebsd.org> From: Warner Losh Date: Sat, 21 Apr 2012 16:02: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: r234546 - head/gnu/lib/libgcc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 16:02:00 -0000 Author: imp Date: Sat Apr 21 16:02:00 2012 New Revision: 234546 URL: http://svn.freebsd.org/changeset/base/234546 Log: Replace a bare use of nm with ${NM} for easier cross compilation in environments where nm is spelled differently. Modified: head/gnu/lib/libgcc/Makefile Modified: head/gnu/lib/libgcc/Makefile ============================================================================== --- head/gnu/lib/libgcc/Makefile Sat Apr 21 15:37:38 2012 (r234545) +++ head/gnu/lib/libgcc/Makefile Sat Apr 21 16:02:00 2012 (r234546) @@ -276,7 +276,7 @@ ${ASM_S}: ${LIB1ASMSRC} ${ASM_V}: ${LIB1ASMSRC} ${CC} -x assembler-with-cpp -c ${CFLAGS} -DL${.PREFIX} \ -o ${.PREFIX}.vo ${.ALLSRC:N*.h} - ( nm -pg ${.PREFIX}.vo | \ + ( ${NM} -pg ${.PREFIX}.vo | \ awk 'NF == 3 && $$2 !~ /^[UN]$$/ { print "\t.hidden ", $$3 }'\ ) > ${.TARGET} @@ -325,7 +325,7 @@ SHLIB_MAPFILES = ${GCCDIR}/libgcc-std. VERSION_MAP = libgcc.map libgcc.map: ${SHLIB_MKMAP} ${SHLIB_MAPFILES} ${SOBJS} ${OBJS:R:S/$/.So/} - ( nm -pg ${SOBJS};echo %% ; \ + ( ${NM} -pg ${SOBJS};echo %% ; \ cat ${SHLIB_MAPFILES} \ | sed -e '/^[ ]*#/d' \ -e 's/^%\(if\|else\|elif\|endif\|define\)/#\1/' \ From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 17:12:29 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 175E0106566C; Sat, 21 Apr 2012 17:12:29 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (lor.one-eyed-alien.net [69.66.77.232]) by mx1.freebsd.org (Postfix) with ESMTP id 53BFF8FC0C; Sat, 21 Apr 2012 17:12:28 +0000 (UTC) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.14.4/8.14.4) with ESMTP id q3LHBSA9006798; Sat, 21 Apr 2012 12:11:28 -0500 (CDT) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.14.4/8.14.4/Submit) id q3LHBS2G006797; Sat, 21 Apr 2012 12:11:28 -0500 (CDT) (envelope-from brooks) Date: Sat, 21 Apr 2012 12:11:28 -0500 From: Brooks Davis To: Ryan Stone Message-ID: <20120421171128.GA6732@lor.one-eyed-alien.net> References: <201204202137.q3KLbhNj056524@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="qDbXVdCdHGoSgWSk" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, Brooks Davis , src-committers@freebsd.org Subject: Re: svn commit: r234504 - in head/sys: amd64/conf i386/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 17:12:29 -0000 --qDbXVdCdHGoSgWSk Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Apr 21, 2012 at 09:45:57AM -0400, Ryan Stone wrote: > On Fri, Apr 20, 2012 at 5:37 PM, Brooks Davis wrote: > > Author: brooks > > Date: Fri Apr 20 21:37:42 2012 > > New Revision: 234504 > > URL: http://svn.freebsd.org/changeset/base/234504 > > > > Log: > > ?Enable DTrace hooks in GENERIC. > > > > ?Reviewed by: ?gnn > > ?Approved by: ?core (jhb, imp) > > ?Requested by: a cast of thousands > > ?MFC after: ? ?3 days >=20 > Excellent! Thanks to everybody who helped make this happen, starting > with the participants at dtrace.conf who gave us the requisite whacks > with the clue-by-four. >=20 > However, what is our policy for enabling features in -STABLE that are > known to be unstable? If we MFC this I don't have the slightest worry > that somebody might see instability in their system just because the > hooks are all of a sudden there, but I would worry that somebody make > take DTrace hooks being enabled in GENERIC on -STABLE to imply that > DTrace is stable, start using it and being upset when they trip over a > DTrace bug. I think we should note that it remains experimental and somewhat buggy in the release notes and probably in the MFC message. Otherwise, it's like any new feature. If you start using a feature in production without extensive testing you may be surprised. -- Brooks --qDbXVdCdHGoSgWSk Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iD8DBQFPkupAXY6L6fI4GtQRAp6AAKDfxTtcg3ISY8O1rzYVWuB2IJUYaACg4eX/ ogB6kG/7Nb593sYAuzSxQ6g= =xdrF -----END PGP SIGNATURE----- --qDbXVdCdHGoSgWSk-- From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 17:45:40 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CF9EA106566C; Sat, 21 Apr 2012 17:45:40 +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 BAB868FC08; Sat, 21 Apr 2012 17:45:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LHjeHO098156; Sat, 21 Apr 2012 17:45:40 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LHjeHx098154; Sat, 21 Apr 2012 17:45:40 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201204211745.q3LHjeHx098154@svn.freebsd.org> From: Warner Losh Date: Sat, 21 Apr 2012 17:45: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: r234549 - head/share/mk X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 17:45:40 -0000 Author: imp Date: Sat Apr 21 17:45:40 2012 New Revision: 234549 URL: http://svn.freebsd.org/changeset/base/234549 Log: Fix partially merged patch from my external compiler tree in r234546. Define NM except when we're in strict POSIX mode. Modified: head/share/mk/sys.mk Modified: head/share/mk/sys.mk ============================================================================== --- head/share/mk/sys.mk Sat Apr 21 16:27:50 2012 (r234548) +++ head/share/mk/sys.mk Sat Apr 21 17:45:40 2012 (r234549) @@ -141,6 +141,10 @@ YFLAGS ?= YFLAGS ?= -d .endif +.if !defined(%POSIX) +NM ?= nm +.endif + .if defined(%POSIX) # Posix 1003.2 mandated rules From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 17:49:24 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 75F171065670; Sat, 21 Apr 2012 17:49: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 60F428FC14; Sat, 21 Apr 2012 17:49:24 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LHnOWI098340; Sat, 21 Apr 2012 17:49:24 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LHnOg1098336; Sat, 21 Apr 2012 17:49:24 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201204211749.q3LHnOg1098336@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 21 Apr 2012 17:49:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-svnadmin@freebsd.org X-SVN-Group: svnadmin MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234551 - svnadmin/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 17:49:24 -0000 Author: kib Date: Sat Apr 21 17:49:23 2012 New Revision: 234551 URL: http://svn.freebsd.org/changeset/base/234551 Log: Add Jeremie Le Hen to the src committers. Approved by: core Modified: svnadmin/conf/access svnadmin/conf/mentors Modified: svnadmin/conf/access ============================================================================== --- svnadmin/conf/access Sat Apr 21 17:48:17 2012 (r234550) +++ svnadmin/conf/access Sat Apr 21 17:49:23 2012 (r234551) @@ -126,6 +126,7 @@ jimharris jinmei jkim jkoshy +jlh jls jmallett jmg Modified: svnadmin/conf/mentors ============================================================================== --- svnadmin/conf/mentors Sat Apr 21 17:48:17 2012 (r234550) +++ svnadmin/conf/mentors Sat Apr 21 17:49:23 2012 (r234551) @@ -21,6 +21,7 @@ jceel wkoszek Co-mentor: cognet jhibbits nwhitehorn jimharris scottl Co-mentor: sbruno jinmei gnn +jlh kib jonathan rwatson kargl das melifaro ae Co-mentor: kib From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 18:12:25 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 179DD1065670; Sat, 21 Apr 2012 18:12:25 +0000 (UTC) (envelope-from melifaro@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 026F18FC12; Sat, 21 Apr 2012 18:12:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LICO7e099111; Sat, 21 Apr 2012 18:12:24 GMT (envelope-from melifaro@svn.freebsd.org) Received: (from melifaro@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LICOSb099109; Sat, 21 Apr 2012 18:12:24 GMT (envelope-from melifaro@svn.freebsd.org) Message-Id: <201204211812.q3LICOSb099109@svn.freebsd.org> From: "Alexander V. Chernikov" Date: Sat, 21 Apr 2012 18:12:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234552 - stable/9/share/man/man4 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 18:12:25 -0000 Author: melifaro Date: Sat Apr 21 18:12:24 2012 New Revision: 234552 URL: http://svn.freebsd.org/changeset/base/234552 Log: MFC r229930 Add setsockopt(2) example to ng_ksocket(4). While here, fix formatting a bit Approved by: ae(mentor) Modified: stable/9/share/man/man4/ng_ksocket.4 Directory Properties: stable/9/share/man/man4/ (props changed) Modified: stable/9/share/man/man4/ng_ksocket.4 ============================================================================== --- stable/9/share/man/man4/ng_ksocket.4 Sat Apr 21 17:49:23 2012 (r234551) +++ stable/9/share/man/man4/ng_ksocket.4 Sat Apr 21 18:12:24 2012 (r234552) @@ -34,7 +34,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 28, 2005 +.Dd January 09, 2012 .Dt NG_KSOCKET 4 .Os .Sh NAME @@ -199,7 +199,7 @@ For the address is the pathname as a doubly quoted string. .Pp Examples: -.Bl -tag -width XXXXXXXXXX +.Bl -tag -width "PF_LOCAL" .It Dv PF_LOCAL local/"/tmp/foo.socket" .It Dv PF_INET @@ -215,6 +215,12 @@ the normal form for that structure is used. In the future, more convenient encoding of the more common socket options may be supported. +.Pp +Setting socket options example: +.Bl -tag -width "PF_LOCAL" +.It Set FIB 2 for a socket (SOL_SOCKET, SO_SETFIB): +.Dv "setopt \&{ level=0xffff name=0x1014 data=[ 2 ] \&}" +.El .Sh SHUTDOWN This node shuts down upon receipt of a .Dv NGM_SHUTDOWN From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 18:14:47 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0C75B106566B; Sat, 21 Apr 2012 18:14:47 +0000 (UTC) (envelope-from melifaro@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id EA7358FC08; Sat, 21 Apr 2012 18:14:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LIEkxp099225; Sat, 21 Apr 2012 18:14:46 GMT (envelope-from melifaro@svn.freebsd.org) Received: (from melifaro@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LIEkxT099223; Sat, 21 Apr 2012 18:14:46 GMT (envelope-from melifaro@svn.freebsd.org) Message-Id: <201204211814.q3LIEkxT099223@svn.freebsd.org> From: "Alexander V. Chernikov" Date: Sat, 21 Apr 2012 18:14:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234553 - stable/8/share/man/man4 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 18:14:47 -0000 Author: melifaro Date: Sat Apr 21 18:14:46 2012 New Revision: 234553 URL: http://svn.freebsd.org/changeset/base/234553 Log: MFC r229930 Add setsockopt(2) example to ng_ksocket(4). While here, fix formatting a bit Approved by: ae(mentor) Modified: stable/8/share/man/man4/ng_ksocket.4 Directory Properties: stable/8/share/man/man4/ (props changed) Modified: stable/8/share/man/man4/ng_ksocket.4 ============================================================================== --- stable/8/share/man/man4/ng_ksocket.4 Sat Apr 21 18:12:24 2012 (r234552) +++ stable/8/share/man/man4/ng_ksocket.4 Sat Apr 21 18:14:46 2012 (r234553) @@ -34,7 +34,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 28, 2005 +.Dd January 09, 2012 .Dt NG_KSOCKET 4 .Os .Sh NAME @@ -199,7 +199,7 @@ For the address is the pathname as a doubly quoted string. .Pp Examples: -.Bl -tag -width XXXXXXXXXX +.Bl -tag -width "PF_LOCAL" .It Dv PF_LOCAL local/"/tmp/foo.socket" .It Dv PF_INET @@ -215,6 +215,12 @@ the normal form for that structure is used. In the future, more convenient encoding of the more common socket options may be supported. +.Pp +Setting socket options example: +.Bl -tag -width "PF_LOCAL" +.It Set FIB 2 for a socket (SOL_SOCKET, SO_SETFIB): +.Dv "setopt \&{ level=0xffff name=0x1014 data=[ 2 ] \&}" +.El .Sh SHUTDOWN This node shuts down upon receipt of a .Dv NGM_SHUTDOWN From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 18:26:16 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D8E751065674; Sat, 21 Apr 2012 18:26:16 +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 C477A8FC08; Sat, 21 Apr 2012 18:26:16 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LIQGSr099637; Sat, 21 Apr 2012 18:26:16 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LIQGEn099635; Sat, 21 Apr 2012 18:26:16 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201204211826.q3LIQGEn099635@svn.freebsd.org> From: Alan Cox Date: Sat, 21 Apr 2012 18:26: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: r234554 - head/sys/vm X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 18:26:16 -0000 Author: alc Date: Sat Apr 21 18:26:16 2012 New Revision: 234554 URL: http://svn.freebsd.org/changeset/base/234554 Log: As documented in vm_page.h, updates to the vm_page's flags no longer require the page queues lock. MFC after: 1 week Modified: head/sys/vm/vm_page.c Modified: head/sys/vm/vm_page.c ============================================================================== --- head/sys/vm/vm_page.c Sat Apr 21 18:14:46 2012 (r234553) +++ head/sys/vm/vm_page.c Sat Apr 21 18:26:16 2012 (r234554) @@ -2155,13 +2155,10 @@ vm_page_unwire(vm_page_t m, int activate if ((m->oflags & VPO_UNMANAGED) != 0 || m->object == NULL) return; - vm_page_lock_queues(); - if (activate) - vm_page_enqueue(PQ_ACTIVE, m); - else { + if (!activate) m->flags &= ~PG_WINATCFLS; - vm_page_enqueue(PQ_INACTIVE, m); - } + vm_page_lock_queues(); + vm_page_enqueue(activate ? PQ_ACTIVE : PQ_INACTIVE, m); vm_page_unlock_queues(); } } else @@ -2201,8 +2198,8 @@ _vm_page_deactivate(vm_page_t m, int ath if ((queue = m->queue) == PQ_INACTIVE) return; if (m->wire_count == 0 && (m->oflags & VPO_UNMANAGED) == 0) { - vm_page_lock_queues(); m->flags &= ~PG_WINATCFLS; + vm_page_lock_queues(); if (queue != PQ_NONE) vm_page_queue_remove(queue, m); if (athead) From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 18:30:49 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8D08B1065774; Sat, 21 Apr 2012 18:30:49 +0000 (UTC) (envelope-from melifaro@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 774F08FC14; Sat, 21 Apr 2012 18:30:49 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LIUnaj099808; Sat, 21 Apr 2012 18:30:49 GMT (envelope-from melifaro@svn.freebsd.org) Received: (from melifaro@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LIUn9P099802; Sat, 21 Apr 2012 18:30:49 GMT (envelope-from melifaro@svn.freebsd.org) Message-Id: <201204211830.q3LIUn9P099802@svn.freebsd.org> From: "Alexander V. Chernikov" Date: Sat, 21 Apr 2012 18:30:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234555 - stable/8/lib/libradius X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 18:30:49 -0000 Author: melifaro Date: Sat Apr 21 18:30:48 2012 New Revision: 234555 URL: http://svn.freebsd.org/changeset/base/234555 Log: MFC: r228730 Add binding support to libradius(3). Submitted by: Sergey Matveychuk Approved by: kib(mentor) Modified: stable/8/lib/libradius/Makefile stable/8/lib/libradius/libradius.3 stable/8/lib/libradius/radlib.c stable/8/lib/libradius/radlib.h stable/8/lib/libradius/radlib_private.h Directory Properties: stable/8/lib/libradius/ (props changed) Modified: stable/8/lib/libradius/Makefile ============================================================================== --- stable/8/lib/libradius/Makefile Sat Apr 21 18:26:16 2012 (r234554) +++ stable/8/lib/libradius/Makefile Sat Apr 21 18:30:48 2012 (r234555) @@ -36,6 +36,7 @@ MAN= libradius.3 radius.conf.5 MLINKS+=libradius.3 rad_acct_open.3 \ libradius.3 rad_add_server.3 \ libradius.3 rad_auth_open.3 \ + libradius.3 rad_bind_to.3 \ libradius.3 rad_close.3 \ libradius.3 rad_config.3 \ libradius.3 rad_continue_send_request.3 \ Modified: stable/8/lib/libradius/libradius.3 ============================================================================== --- stable/8/lib/libradius/libradius.3 Sat Apr 21 18:26:16 2012 (r234554) +++ stable/8/lib/libradius/libradius.3 Sat Apr 21 18:30:48 2012 (r234555) @@ -91,6 +91,8 @@ .Fn rad_server_open "int fd" .Ft "const char *" .Fn rad_server_secret "struct rad_handle *h" +.Ft "void" +.Fn rad_bind_to "struct rad_handle *h" "in_addr_t addr" .Ft u_char * .Fn rad_demangle "struct rad_handle *h" "const void *mangled" "size_t mlen" .Ft u_char * @@ -431,6 +433,10 @@ returns the secret shared with the curre supplied rad_handle. .Pp The +.Fn rad_bind_to +assigns a source address for all requests to the current RADIUS server. +.Pp +The .Fn rad_demangle function demangles attributes containing passwords and MS-CHAPv1 MPPE-Keys. The return value is Modified: stable/8/lib/libradius/radlib.c ============================================================================== --- stable/8/lib/libradius/radlib.c Sat Apr 21 18:26:16 2012 (r234554) +++ stable/8/lib/libradius/radlib.c Sat Apr 21 18:30:48 2012 (r234555) @@ -756,9 +756,16 @@ rad_create_request(struct rad_handle *h, clear_password(h); h->authentic_pos = 0; h->out_created = 1; + h->bindto = INADDR_ANY; return 0; } +void +rad_bind_to(struct rad_handle *h, in_addr_t addr) +{ + h->bindto = addr; +} + int rad_create_response(struct rad_handle *h, int code) { @@ -857,7 +864,7 @@ rad_init_send_request(struct rad_handle memset(&sin, 0, sizeof sin); sin.sin_len = sizeof sin; sin.sin_family = AF_INET; - sin.sin_addr.s_addr = INADDR_ANY; + sin.sin_addr.s_addr = h->bindto; sin.sin_port = htons(0); if (bind(h->fd, (const struct sockaddr *)&sin, sizeof sin) == -1) { Modified: stable/8/lib/libradius/radlib.h ============================================================================== --- stable/8/lib/libradius/radlib.h Sat Apr 21 18:26:16 2012 (r234554) +++ stable/8/lib/libradius/radlib.h Sat Apr 21 18:30:48 2012 (r234555) @@ -195,6 +195,7 @@ struct rad_handle *rad_acct_open(void); int rad_add_server(struct rad_handle *, const char *, int, const char *, int, int); struct rad_handle *rad_auth_open(void); +void rad_bind_to(struct rad_handle *, in_addr_t); void rad_close(struct rad_handle *); int rad_config(struct rad_handle *, const char *); int rad_continue_send_request(struct rad_handle *, int, Modified: stable/8/lib/libradius/radlib_private.h ============================================================================== --- stable/8/lib/libradius/radlib_private.h Sat Apr 21 18:26:16 2012 (r234554) +++ stable/8/lib/libradius/radlib_private.h Sat Apr 21 18:30:48 2012 (r234555) @@ -92,6 +92,7 @@ struct rad_handle { int try; /* How many requests we've sent */ int srv; /* Server number we did last */ int type; /* Handle type */ + in_addr_t bindto; /* Bind to address */ }; struct vendor_attribute { From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 18:36:54 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 387A01065670; Sat, 21 Apr 2012 18:36: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 2432F8FC08; Sat, 21 Apr 2012 18:36:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LIasc2000197; Sat, 21 Apr 2012 18:36:54 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LIarcY000195; Sat, 21 Apr 2012 18:36:53 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201204211836.q3LIarcY000195@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 21 Apr 2012 18:36:53 +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: r234556 - head/sys/vm X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 18:36:54 -0000 Author: kib Date: Sat Apr 21 18:36:53 2012 New Revision: 234556 URL: http://svn.freebsd.org/changeset/base/234556 Log: When MAP_STACK mapping is created, the map entry is created only to cover the initial stack size. For MCL_WIREFUTURE maps, the subsequent call to vm_map_wire() to wire the whole stack region fails due to VM_MAP_WIRE_NOHOLES flag. Use the VM_MAP_WIRE_HOLESOK to only wire mapped part of the stack. Reported and tested by: Sushanth Rai Reviewed by: alc MFC after: 1 week Modified: head/sys/vm/vm_mmap.c Modified: head/sys/vm/vm_mmap.c ============================================================================== --- head/sys/vm/vm_mmap.c Sat Apr 21 18:30:48 2012 (r234555) +++ head/sys/vm/vm_mmap.c Sat Apr 21 18:36:53 2012 (r234556) @@ -1561,9 +1561,11 @@ vm_mmap(vm_map_t map, vm_offset_t *addr, * If the process has requested that all future mappings * be wired, then heed this. */ - if (map->flags & MAP_WIREFUTURE) + if (map->flags & MAP_WIREFUTURE) { vm_map_wire(map, *addr, *addr + size, - VM_MAP_WIRE_USER | VM_MAP_WIRE_NOHOLES); + VM_MAP_WIRE_USER | ((flags & MAP_STACK) ? + VM_MAP_WIRE_HOLESOK : VM_MAP_WIRE_NOHOLES)); + } } else { /* * If this mapping was accounted for in the vnode's From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 19:13:20 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1033) id 328A1106566B; Sat, 21 Apr 2012 19:13:20 +0000 (UTC) Date: Sat, 21 Apr 2012 19:13:20 +0000 From: Alexey Dokuchaev To: Brooks Davis Message-ID: <20120421191320.GA57272@FreeBSD.org> References: <201204202137.q3KLbhNj056524@svn.freebsd.org> <20120421171128.GA6732@lor.one-eyed-alien.net> Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <20120421171128.GA6732@lor.one-eyed-alien.net> User-Agent: Mutt/1.4.2.1i Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Ryan Stone Subject: Re: svn commit: r234504 - in head/sys: amd64/conf i386/conf X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 19:13:20 -0000 On Sat, Apr 21, 2012 at 12:11:28PM -0500, Brooks Davis wrote: > On Sat, Apr 21, 2012 at 09:45:57AM -0400, Ryan Stone wrote: > > Excellent! Thanks to everybody who helped make this happen, starting > > with the participants at dtrace.conf who gave us the requisite whacks > > with the clue-by-four. > > > > However, what is our policy for enabling features in -STABLE that are > > known to be unstable? If we MFC this I don't have the slightest worry > > that somebody might see instability in their system just because the > > hooks are all of a sudden there, but I would worry that somebody make > > take DTrace hooks being enabled in GENERIC on -STABLE to imply that > > DTrace is stable, start using it and being upset when they trip over a > > DTrace bug. > > I think we should note that it remains experimental and somewhat buggy > in the release notes and probably in the MFC message. Otherwise, it's > like any new feature. If you start using a feature in production > without extensive testing you may be surprised. I think that given we're just broken 9.x ice, it should be MFCed. ./danfe From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 19:22:54 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 3E4051065677; Sat, 21 Apr 2012 19:22:54 +0000 (UTC) (envelope-from melifaro@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2865A8FC14; Sat, 21 Apr 2012 19:22:54 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LJMs5f001692; Sat, 21 Apr 2012 19:22:54 GMT (envelope-from melifaro@svn.freebsd.org) Received: (from melifaro@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LJMrDb001687; Sat, 21 Apr 2012 19:22:53 GMT (envelope-from melifaro@svn.freebsd.org) Message-Id: <201204211922.q3LJMrDb001687@svn.freebsd.org> From: "Alexander V. Chernikov" Date: Sat, 21 Apr 2012 19:22:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234557 - in stable/9/sys: modules/netgraph/netflow netgraph/netflow X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 19:22:54 -0000 Author: melifaro Date: Sat Apr 21 19:22:53 2012 New Revision: 234557 URL: http://svn.freebsd.org/changeset/base/234557 Log: MFC r232921: Use rt_numfibs variable instead of compile-time RT_NUMFIBS. Approved by: kib(mentor) Modified: stable/9/sys/modules/netgraph/netflow/Makefile stable/9/sys/netgraph/netflow/netflow.c stable/9/sys/netgraph/netflow/ng_netflow.c stable/9/sys/netgraph/netflow/ng_netflow.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/modules/netgraph/netflow/Makefile ============================================================================== --- stable/9/sys/modules/netgraph/netflow/Makefile Sat Apr 21 18:36:53 2012 (r234556) +++ stable/9/sys/modules/netgraph/netflow/Makefile Sat Apr 21 19:22:53 2012 (r234557) @@ -17,8 +17,6 @@ opt_inet6.h: echo "#define INET6 1" > ${.TARGET} .endif -opt_route.h: - echo "#define ROUTETABLES RT_MAXFIBS" > ${.TARGET} .endif .include Modified: stable/9/sys/netgraph/netflow/netflow.c ============================================================================== --- stable/9/sys/netgraph/netflow/netflow.c Sat Apr 21 18:36:53 2012 (r234556) +++ stable/9/sys/netgraph/netflow/netflow.c Sat Apr 21 19:22:53 2012 (r234557) @@ -630,7 +630,7 @@ ng_netflow_cache_flush(priv_p priv) free(priv->hash6, M_NETFLOW_HASH); #endif - for (i = 0; i < RT_NUMFIBS; i++) { + for (i = 0; i < priv->maxfibs; i++) { if ((fe = priv_to_fib(priv, i)) == NULL) continue; Modified: stable/9/sys/netgraph/netflow/ng_netflow.c ============================================================================== --- stable/9/sys/netgraph/netflow/ng_netflow.c Sat Apr 21 18:36:53 2012 (r234556) +++ stable/9/sys/netgraph/netflow/ng_netflow.c Sat Apr 21 19:22:53 2012 (r234557) @@ -225,6 +225,11 @@ ng_netflow_constructor(node_p node) /* Initialize private data */ priv = malloc(sizeof(*priv), M_NETGRAPH, M_WAITOK | M_ZERO); + /* Initialize fib data */ + priv->maxfibs = rt_numfibs; + priv->fib_data = malloc(sizeof(fib_export_p) * priv->maxfibs, + M_NETGRAPH, M_WAITOK | M_ZERO); + /* Make node and its data point at each other */ NG_NODE_SET_PRIVATE(node, priv); priv->node = node; @@ -901,8 +906,10 @@ loopend: /* Check packet FIB */ fib = M_GETFIB(m); - if (fib >= RT_NUMFIBS) { - CTR2(KTR_NET, "ng_netflow_rcvdata(): packet fib %d is out of range of available fibs: 0 .. %d", fib, RT_NUMFIBS); + if (fib >= priv->maxfibs) { + CTR2(KTR_NET, "ng_netflow_rcvdata(): packet fib %d is out of " + "range of available fibs: 0 .. %d", + fib, priv->maxfibs); goto bypass; } @@ -973,6 +980,7 @@ ng_netflow_rmnode(node_p node) NG_NODE_SET_PRIVATE(node, NULL); NG_NODE_UNREF(priv->node); + free(priv->fib_data, M_NETGRAPH); free(priv, M_NETGRAPH); return (0); Modified: stable/9/sys/netgraph/netflow/ng_netflow.h ============================================================================== --- stable/9/sys/netgraph/netflow/ng_netflow.h Sat Apr 21 18:36:53 2012 (r234556) +++ stable/9/sys/netgraph/netflow/ng_netflow.h Sat Apr 21 19:22:53 2012 (r234557) @@ -413,7 +413,8 @@ struct netflow { struct flow_hash_entry *hash6; #endif /* Multiple FIB support */ - fib_export_p fib_data[RT_NUMFIBS]; /* array of pointers to fib-specific data */ + fib_export_p *fib_data; /* array of pointers to per-fib data */ + uint16_t maxfibs; /* number of allocated fibs */ /* * RFC 3954 clause 7.3 From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 20:10:26 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9B9271065670; Sat, 21 Apr 2012 20:10:26 +0000 (UTC) (envelope-from raj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 837378FC0A; Sat, 21 Apr 2012 20:10:26 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LKAQNd003295; Sat, 21 Apr 2012 20:10:26 GMT (envelope-from raj@svn.freebsd.org) Received: (from raj@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LKAQgK003292; Sat, 21 Apr 2012 20:10:26 GMT (envelope-from raj@svn.freebsd.org) Message-Id: <201204212010.q3LKAQgK003292@svn.freebsd.org> From: Rafal Jaworowski Date: Sat, 21 Apr 2012 20:10:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234558 - in stable/9/sys: boot/fdt boot/uboot/common i386/conf kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 20:10:26 -0000 Author: raj Date: Sat Apr 21 20:10:26 2012 New Revision: 234558 URL: http://svn.freebsd.org/changeset/base/234558 Log: MFC r233230, r233323: Improve device tree blob (DTB) handling in loader(8). Enable using the statically embedded blob from the kernel, if present. The KLD loaded DTB takes precedence, but they are both recognized and handled in the same way. Improve FDT handling in loader(8) and make it more robust. o Fix buffer overflows when using a long property body in node paths. o Fix loop end condition when iterating through the symbol table. o Better error handling during node modification, better problem reporting. o Eliminate build time warnings. Submitted by: Lukasz Wojcik Obtained from: Semihalf Modified: stable/9/sys/boot/fdt/fdt_loader_cmd.c stable/9/sys/boot/uboot/common/metadata.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/boot/fdt/fdt_loader_cmd.c ============================================================================== --- stable/9/sys/boot/fdt/fdt_loader_cmd.c Sat Apr 21 19:22:53 2012 (r234557) +++ stable/9/sys/boot/fdt/fdt_loader_cmd.c Sat Apr 21 20:10:26 2012 (r234558) @@ -33,6 +33,9 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include +#include +#include #include "bootstrap.h" #include "glue.h" @@ -54,7 +57,9 @@ __FBSDID("$FreeBSD$"); #define STR(number) #number #define STRINGIFY(number) STR(number) -#define MIN(num1, num2) (((num1) < (num2)) ? (num1):(num2)) +#define COPYOUT(s,d,l) archsw.arch_copyout((vm_offset_t)(s), d, l) + +#define FDT_STATIC_DTB_SYMBOL "fdt_static_dtb" static struct fdt_header *fdtp = NULL; @@ -92,6 +97,91 @@ static const struct cmdtab commands[] = static char cwd[FDT_CWD_LEN] = "/"; +static vm_offset_t +fdt_find_static_dtb(void) +{ + Elf_Sym sym; + vm_offset_t dyntab, esym; + uint64_t offs; + struct preloaded_file *kfp; + struct file_metadata *md; + Elf_Sym *symtab; + Elf_Dyn *dyn; + char *strtab, *strp; + int i, sym_count; + + symtab = NULL; + dyntab = esym = 0; + strtab = strp = NULL; + + offs = __elfN(relocation_offset); + + kfp = file_findfile(NULL, NULL); + if (kfp == NULL) + return (0); + + md = file_findmetadata(kfp, MODINFOMD_ESYM); + if (md == NULL) + return (0); + COPYOUT(md->md_data, &esym, sizeof(esym)); + + md = file_findmetadata(kfp, MODINFOMD_DYNAMIC); + if (md == NULL) + return (0); + COPYOUT(md->md_data, &dyntab, sizeof(dyntab)); + + dyntab += offs; + + /* Locate STRTAB and DYNTAB */ + for (dyn = (Elf_Dyn *)dyntab; dyn->d_tag != DT_NULL; dyn++) { + if (dyn->d_tag == DT_STRTAB) { + strtab = (char *)(uintptr_t)(dyn->d_un.d_ptr + offs); + continue; + } else if (dyn->d_tag == DT_SYMTAB) { + symtab = (Elf_Sym *)(uintptr_t) + (dyn->d_un.d_ptr + offs); + continue; + } + } + + if (symtab == NULL || strtab == NULL) { + /* + * No symtab? No strtab? That should not happen here, + * and should have been verified during __elfN(loadimage). + * This must be some kind of a bug. + */ + return (0); + } + + sym_count = (int)((Elf_Sym *)esym - symtab) / sizeof(Elf_Sym); + + /* + * The most efficent way to find a symbol would be to calculate a + * hash, find proper bucket and chain, and thus find a symbol. + * However, that would involve code duplication (e.g. for hash + * function). So we're using simpler and a bit slower way: we're + * iterating through symbols, searching for the one which name is + * 'equal' to 'fdt_static_dtb'. To speed up the process a little bit, + * we are eliminating symbols type of which is not STT_NOTYPE, or(and) + * those which binding attribute is not STB_GLOBAL. + */ + for (i = 0; i < sym_count; i++) { + COPYOUT(symtab + i, &sym, sizeof(sym)); + if (ELF_ST_BIND(sym.st_info) != STB_GLOBAL || + ELF_ST_TYPE(sym.st_info) != STT_NOTYPE) + continue; + + strp = strdupout((vm_offset_t)(strtab + sym.st_name)); + if (strcmp(strp, FDT_STATIC_DTB_SYMBOL) == 0) { + /* Found a match ! */ + free(strp); + return ((vm_offset_t)(sym.st_value + offs)); + } + free(strp); + } + return (0); +} + static int fdt_setup_fdtp() { @@ -103,10 +193,14 @@ fdt_setup_fdtp() */ bfp = file_findfile(NULL, "dtb"); if (bfp == NULL) { - command_errmsg = "no device tree blob loaded"; - return (CMD_ERROR); + if ((fdtp = (struct fdt_header *)fdt_find_static_dtb()) == 0) { + command_errmsg = "no device tree blob found!"; + return (CMD_ERROR); + } + } else { + /* Dynamic blob has precedence over static. */ + fdtp = (struct fdt_header *)bfp->f_addr; } - fdtp = (struct fdt_header *)bfp->f_addr; /* * Validate the blob. @@ -448,7 +542,10 @@ fixup_stdout(const char *env) } } -int +/* + * Locate the blob, fix it up and return its location. + */ +void * fdt_fixup(void) { const char *env; @@ -461,13 +558,10 @@ fdt_fixup(void) ethstr = NULL; len = 0; - if (!fdtp) { - err = fdt_setup_fdtp(); - if (err) { - sprintf(command_errbuf, "Could not perform blob " - "fixups. Error code: %d\n", err); - return (err); - } + err = fdt_setup_fdtp(); + if (err) { + sprintf(command_errbuf, "No valid device tree blob found!"); + return (NULL); } /* Create /chosen node (if not exists) */ @@ -477,7 +571,7 @@ fdt_fixup(void) /* Value assigned to fixup-applied does not matter. */ if (fdt_getprop(fdtp, chosen, "fixup-applied", NULL)) - return (CMD_OK); + goto success; /* Acquire sys_info */ si = ub_get_sys_info(); @@ -521,7 +615,8 @@ fdt_fixup(void) fdt_setprop(fdtp, chosen, "fixup-applied", NULL, 0); - return (CMD_OK); +success: + return (fdtp); } int @@ -539,7 +634,8 @@ command_fdt_internal(int argc, char *arg /* * Check if uboot env vars were parsed already. If not, do it now. */ - fdt_fixup(); + if (fdt_fixup() == NULL) + return (CMD_ERROR); /* * Validate fdt . @@ -560,10 +656,6 @@ command_fdt_internal(int argc, char *arg return (CMD_ERROR); } - if (!fdtp) - if (fdt_setup_fdtp()) - return (CMD_ERROR); - /* * Call command handler. */ @@ -753,32 +845,41 @@ fdt_isprint(const void *data, int len, i static int fdt_data_str(const void *data, int len, int count, char **buf) { - char tmp[80], *b; + char *b, *tmp; const char *d; - int i, l; + int buf_len, i, l; /* * Calculate the length for the string and allocate memory. * - * Note len already includes at least one terminator. + * Note that 'len' already includes at least one terminator. */ - l = len; + buf_len = len; if (count > 1) { /* * Each token had already a terminator buried in 'len', but we * only need one eventually, don't count space for these. */ - l -= count - 1; + buf_len -= count - 1; /* Each consecutive token requires a ", " separator. */ - l += count * 2; + buf_len += count * 2; } - /* Space for surrounding double quotes. */ - l += count * 2; - b = (char *)malloc(l); + /* Add some space for surrounding double quotes. */ + buf_len += count * 2; + + /* Note that string being put in 'tmp' may be as big as 'buf_len'. */ + b = (char *)malloc(buf_len); + tmp = (char *)malloc(buf_len); if (b == NULL) - return (1); + goto error; + + if (tmp == NULL) { + free(b); + goto error; + } + b[0] = '\0'; /* @@ -798,13 +899,17 @@ fdt_data_str(const void *data, int len, } while (i < len); *buf = b; + free(tmp); + return (0); +error: + return (1); } static int fdt_data_cell(const void *data, int len, char **buf) { - char tmp[80], *b; + char *b, *tmp; const uint32_t *c; int count, i, l; @@ -827,8 +932,14 @@ fdt_data_cell(const void *data, int len, l += 3; b = (char *)malloc(l); + tmp = (char *)malloc(l); if (b == NULL) - return (1); + goto error; + + if (tmp == NULL) { + free(b); + goto error; + } b[0] = '\0'; strcat(b, "<"); @@ -842,13 +953,17 @@ fdt_data_cell(const void *data, int len, strcat(b, ">"); *buf = b; + free(tmp); + return (0); +error: + return (1); } static int fdt_data_bytes(const void *data, int len, char **buf) { - char tmp[80], *b; + char *b, *tmp; const char *d; int i, l; @@ -867,8 +982,14 @@ fdt_data_bytes(const void *data, int len l += 3; b = (char *)malloc(l); + tmp = (char *)malloc(l); if (b == NULL) - return (1); + goto error; + + if (tmp == NULL) { + free(b); + goto error; + } b[0] = '\0'; strcat(b, "["); @@ -880,7 +1001,11 @@ fdt_data_bytes(const void *data, int len strcat(b, "]"); *buf = b; + free(tmp); + return (0); +error: + return (1); } static int @@ -1019,6 +1144,14 @@ fdt_modprop(int nodeoff, char *propname, break; } + if (rv != 0) { + if (rv == -FDT_ERR_NOSPACE) + sprintf(command_errbuf, + "Device tree blob is too small!\n"); + else + sprintf(command_errbuf, + "Could not add/modify property!\n"); + } return (rv); } @@ -1261,9 +1394,12 @@ fdt_cmd_mknode(int argc, char *argv[]) rv = fdt_add_subnode(fdtp, o, nodename); if (rv < 0) { - sprintf(command_errbuf, "could not delete node %s\n", - (rv == -FDT_ERR_NOTFOUND) ? - "(node does not exist)" : ""); + if (rv == -FDT_ERR_NOSPACE) + sprintf(command_errbuf, + "Device tree blob is too small!\n"); + else + sprintf(command_errbuf, + "Could not add node!\n"); return (CMD_ERROR); } return (CMD_OK); @@ -1272,7 +1408,7 @@ fdt_cmd_mknode(int argc, char *argv[]) static int fdt_cmd_pwd(int argc, char *argv[]) { - char line[80]; + char line[FDT_CWD_LEN]; pager_open(); sprintf(line, "%s\n", cwd); Modified: stable/9/sys/boot/uboot/common/metadata.c ============================================================================== --- stable/9/sys/boot/uboot/common/metadata.c Sat Apr 21 19:22:53 2012 (r234557) +++ stable/9/sys/boot/uboot/common/metadata.c Sat Apr 21 20:10:26 2012 (r234558) @@ -333,13 +333,12 @@ md_load(char *args, vm_offset_t *modulep #if defined(LOADER_FDT_SUPPORT) /* Handle device tree blob */ - fdt_fixup(); - if ((bfp = file_findfile(NULL, "dtb")) == NULL && - (howto & RB_VERBOSE)) - printf("**WARNING** Booting with no DTB loaded!\n"); - - dtbp = bfp == NULL ? 0 : bfp->f_addr; - file_addmetadata(kfp, MODINFOMD_DTBP, sizeof dtbp, &dtbp); + dtbp = fdt_fixup(); + if (dtbp != (vm_offset_t)NULL) + file_addmetadata(kfp, MODINFOMD_DTBP, sizeof dtbp, &dtbp); + else + pager_output("WARNING! Trying to fire up the kernel, but no " + "device tree blob found!\n"); #endif file_addmetadata(kfp, MODINFOMD_KERNEND, sizeof kernend, &kernend); From owner-svn-src-all@FreeBSD.ORG Sat Apr 21 20:22:03 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 78B2A1065670; Sat, 21 Apr 2012 20:22:03 +0000 (UTC) (envelope-from raj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 61E098FC08; Sat, 21 Apr 2012 20:22:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q3LKM3aL003693; Sat, 21 Apr 2012 20:22:03 GMT (envelope-from raj@svn.freebsd.org) Received: (from raj@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q3LKM3s0003687; Sat, 21 Apr 2012 20:22:03 GMT (envelope-from raj@svn.freebsd.org) Message-Id: <201204212022.q3LKM3s0003687@svn.freebsd.org> From: Rafal Jaworowski Date: Sat, 21 Apr 2012 20:22:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r234559 - in stable/9/sys: arm/conf arm/mv boot/fdt/dts dev/cesa i386/conf kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Apr 2012 20:22:03 -0000 Author: raj Date: Sat Apr 21 20:22:02 2012 New Revision: 234559 URL: http://svn.freebsd.org/changeset/base/234559 Log: MFC r227730: Initial version of cesa(4) driver for Marvell crypto engine and security accelerator. The following algorithms and schemes are supported: - 3DES, AES, DES - MD5, SHA1 Obtained from: Semihalf Written by: Piotr Ziecik Added: stable/9/sys/dev/cesa/ - copied from r227730, head/sys/dev/cesa/ Modified: stable/9/sys/arm/conf/DB-88F6XXX stable/9/sys/arm/conf/SHEEVAPLUG stable/9/sys/arm/mv/files.mv stable/9/sys/boot/fdt/dts/db88f6281.dts stable/9/sys/boot/fdt/dts/sheevaplug.dts Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/i386/conf/XENHVM (props changed) stable/9/sys/kern/subr_witness.c (props changed) Modified: stable/9/sys/arm/conf/DB-88F6XXX ============================================================================== --- stable/9/sys/arm/conf/DB-88F6XXX Sat Apr 21 20:10:26 2012 (r234558) +++ stable/9/sys/arm/conf/DB-88F6XXX Sat Apr 21 20:22:02 2012 (r234559) @@ -66,6 +66,10 @@ device mii device e1000phy device bpf +device cesa # Marvell security engine +device crypto +device cryptodev + # USB options USB_DEBUG # enable debug msgs device usb Modified: stable/9/sys/arm/conf/SHEEVAPLUG ============================================================================== --- stable/9/sys/arm/conf/SHEEVAPLUG Sat Apr 21 20:10:26 2012 (r234558) +++ stable/9/sys/arm/conf/SHEEVAPLUG Sat Apr 21 20:22:02 2012 (r234559) @@ -60,6 +60,10 @@ options HZ=1000 options DEVICE_POLLING device vlan +device cesa # Marvell security engine +device crypto +device cryptodev + # USB options USB_DEBUG # enable debug msgs device usb Modified: stable/9/sys/arm/mv/files.mv ============================================================================== --- stable/9/sys/arm/mv/files.mv Sat Apr 21 20:10:26 2012 (r234558) +++ stable/9/sys/arm/mv/files.mv Sat Apr 21 20:22:02 2012 (r234559) @@ -28,6 +28,7 @@ arm/mv/mv_sata.c optional ata | atamvsa arm/mv/timer.c standard arm/mv/twsi.c optional iicbus +dev/cesa/cesa.c optional cesa dev/mge/if_mge.c optional mge dev/mvs/mvs_soc.c optional mvs dev/uart/uart_dev_ns8250.c optional uart Modified: stable/9/sys/boot/fdt/dts/db88f6281.dts ============================================================================== --- stable/9/sys/boot/fdt/dts/db88f6281.dts Sat Apr 21 20:10:26 2012 (r234558) +++ stable/9/sys/boot/fdt/dts/db88f6281.dts Sat Apr 21 20:22:02 2012 (r234559) @@ -239,6 +239,8 @@ reg = <0x30000 0x10000>; interrupts = <22>; interrupt-parent = <&PIC>; + + sram-handle = <&SRAM>; }; usb@50000 { Modified: stable/9/sys/boot/fdt/dts/sheevaplug.dts ============================================================================== --- stable/9/sys/boot/fdt/dts/sheevaplug.dts Sat Apr 21 20:10:26 2012 (r234558) +++ stable/9/sys/boot/fdt/dts/sheevaplug.dts Sat Apr 21 20:22:02 2012 (r234559) @@ -236,6 +236,8 @@ reg = <0x30000 0x10000>; interrupts = <22>; interrupt-parent = <&PIC>; + + sram-handle = <&SRAM>; }; usb@50000 {