svn commit: r211445 - head/sys/mips/mips
Author: jchandra Date: Wed Aug 18 07:38:13 2010 New Revision: 211445 URL: http://svn.freebsd.org/changeset/base/211445 Log: Make return statements style(9) compliant in MIPS pmap.c Reported by: neel Reviewed by: neel (earlier version) Modified: head/sys/mips/mips/pmap.c Modified: head/sys/mips/mips/pmap.c == --- head/sys/mips/mips/pmap.c Wed Aug 18 07:37:16 2010(r211444) +++ head/sys/mips/mips/pmap.c Wed Aug 18 07:38:13 2010(r211445) @@ -267,6 +267,7 @@ static struct local_sysmaps sysmap_lmem[ static __inline pd_entry_t * pmap_segmap(pmap_t pmap, vm_offset_t va) { + return (pmap-pm_segtab[pmap_seg_index(va)]); } @@ -295,13 +296,15 @@ pmap_pde(pmap_t pmap, vm_offset_t va) static __inline pd_entry_t * pmap_pdpe_to_pde(pd_entry_t *pdpe, vm_offset_t va) { - return pdpe; + + return (pdpe); } static __inline pd_entry_t *pmap_pde(pmap_t pmap, vm_offset_t va) { - return pmap_segmap(pmap, va); + + return (pmap_segmap(pmap, va)); } #endif @@ -356,7 +359,7 @@ pmap_steal_memory(vm_size_t size) } va = MIPS_PHYS_TO_KSEG0(pa); bzero((caddr_t)va, size); - return va; + return (va); } /* @@ -750,7 +753,7 @@ pmap_extract(pmap_t pmap, vm_offset_t va retval = TLBLO_PTE_TO_PA(*pte) | (va PAGE_MASK); } PMAP_UNLOCK(pmap); - return retval; + return (retval); } /* @@ -1007,7 +1010,7 @@ pmap_unuse_pt(pmap_t pmap, vm_offset_t v pmap-pm_ptphint = mpte; } } - return pmap_unwire_pte_hold(pmap, va, mpte); + return (pmap_unwire_pte_hold(pmap, va, mpte)); } void @@ -1561,7 +1564,7 @@ pmap_remove_pte(struct pmap *pmap, pt_en pmap_remove_entry(pmap, m, va); } - return pmap_unuse_pt(pmap, va, NULL); + return (pmap_unuse_pt(pmap, va, NULL)); } /* @@ -2609,10 +2612,10 @@ pmap_testbit(vm_page_t m, int bit) boolean_t rv = FALSE; if (m-flags PG_FICTITIOUS) - return rv; + return (rv); if (TAILQ_FIRST(m-md.pv_list) == NULL) - return rv; + return (rv); mtx_assert(vm_page_queue_mtx, MA_OWNED); TAILQ_FOREACH(pv, m-md.pv_list, pv_list) { @@ -2933,7 +2936,7 @@ pmap_mapdev(vm_offset_t pa, vm_size_t si * pa 0x2000 we should make proper mapping * using pmap_kenter. */ if ((pa + size - 1) MIPS_KSEG0_LARGEST_PHYS) - return (void *)MIPS_PHYS_TO_KSEG1(pa); + return ((void *)MIPS_PHYS_TO_KSEG1(pa)); else { offset = pa PAGE_MASK; size = roundup(size + offset, PAGE_SIZE); @@ -3239,11 +3242,11 @@ page_is_managed(vm_offset_t pa) m = PHYS_TO_VM_PAGE(pa); if (m == NULL) - return 0; + return (0); if ((m-flags (PG_FICTITIOUS | PG_UNMANAGED)) == 0) - return 1; + return (1); } - return 0; + return (0); } static int ___ 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-unsubscr...@freebsd.org
svn commit: r211447 - head/sys/mips/atheros
Author: adrian Date: Wed Aug 18 08:22:09 2010 New Revision: 211447 URL: http://svn.freebsd.org/changeset/base/211447 Log: Bring over the first cut of the Atheros-specific SoC operations. Each of these SoCs have different devices, different hardware initialisation methods and, quite likely, different quirks. These functions will abstract out the SoC differences and keep these differences out of the drivers (eg USB init, if_arge, etc.) Added: head/sys/mips/atheros/ar71xx_cpudef.h (contents, props changed) Added: head/sys/mips/atheros/ar71xx_cpudef.h == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/mips/atheros/ar71xx_cpudef.h Wed Aug 18 08:22:09 2010 (r211447) @@ -0,0 +1,108 @@ +/*- + * Copyright (c) 2010 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, 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__AR71XX_CPUDEF_H__ +#define__AR71XX_CPUDEF_H__ + +struct ar71xx_cpu_def { + void (* detect_mem_size) (void); + void (* detect_sys_frequency) (void); + void (* ar71xx_chip_device_stop) (uint32_t); + void (* ar71xx_chip_device_start) (uint32_t); + int (* ar71xx_chip_device_stopped) (uint32_t); + void (* ar71xx_chip_set_pll_ge0) (int); + void (* ar71xx_chip_set_pll_ge1) (int); + void (* ar71xx_chip_ddr_flush_ge0) (void); + void (* ar71xx_chip_ddr_flush_ge1) (void); + uint32_t (* ar71xx_chip_get_eth_pll) (unsigned int, int); + + /* +* From Linux - Handling this IRQ is a bit special. +* AR71xx - AR71XX_DDR_REG_FLUSH_PCI +* AR724x - AR724X_DDR_REG_FLUSH_PCIE +* AR91xx - AR91XX_DDR_REG_FLUSH_WMAC +* +* These are set when STATUSF_IP2 is set in regiser c0. +* This flush is done before the IRQ is handled to make +* sure the driver correctly sees any memory updates. +*/ + void (* ar71xx_chip_irq_flush_ip2) (void); + /* +* The USB peripheral init code is subtly different for +* each chip. +*/ + void (* ar71xx_chip_init_usb_peripheral) (void); +}; + +extern struct ar71xx_cpu_def * ar71xx_cpu_ops; + +static inline void ar71xx_detect_sys_frequency(void) +{ + ar71xx_cpu_ops-detect_sys_frequency(); +} + +static inline void ar71xx_device_stop(uint32_t mask) +{ + ar71xx_cpu_ops-ar71xx_chip_device_stop(mask); +} + +static inline void ar71xx_device_start(uint32_t mask) +{ + ar71xx_cpu_ops-ar71xx_chip_device_start(mask); +} + +static inline int ar71xx_device_stopped(uint32_t mask) +{ + return ar71xx_cpu_ops-ar71xx_chip_device_stopped(mask); +} + +static inline void ar71xx_device_flush_ddr_ge0(void) +{ + ar71xx_cpu_ops-ar71xx_chip_ddr_flush_ge0(); +} + +static inline void ar71xx_device_flush_ddr_ge1(void) +{ + ar71xx_cpu_ops-ar71xx_chip_ddr_flush_ge1(); +} + +static inline void ar71xx_init_usb_peripheral(void) +{ + ar71xx_cpu_ops-ar71xx_chip_init_usb_peripheral(); +} + +/* XXX shouldn't be here! */ +extern uint32_t u_ar71xx_cpu_freq; +extern uint32_t u_ar71xx_ahb_freq; +extern uint32_t u_ar71xx_ddr_freq; + +static inline uint64_t ar71xx_cpu_freq(void) { return u_ar71xx_cpu_freq; } +static inline uint64_t ar71xx_ahb_freq(void) { return u_ar71xx_ahb_freq; } +static inline uint64_t ar71xx_ddr_freq(void) { return u_ar71xx_ddr_freq; } + +#endif ___ 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-unsubscr...@freebsd.org
svn commit: r211448 - head/sys/mips/atheros
Author: adrian Date: Wed Aug 18 08:22:58 2010 New Revision: 211448 URL: http://svn.freebsd.org/changeset/base/211448 Log: Add a further register definition for USB device initialisation. Obtained from:Linux Modified: head/sys/mips/atheros/ar91xxreg.h Modified: head/sys/mips/atheros/ar91xxreg.h == --- head/sys/mips/atheros/ar91xxreg.h Wed Aug 18 08:22:09 2010 (r211447) +++ head/sys/mips/atheros/ar91xxreg.h Wed Aug 18 08:22:58 2010 (r211448) @@ -34,6 +34,8 @@ /* reset block */ #defineAR91XX_RESET_REG_RESET_MODULE AR71XX_RST_BLOCK_BASE + 0x1c +#defineAR91XX_RST_RESET_MODULE_USBSUS_OVERRIDE (1 10) + /* PLL block */ #defineAR91XX_PLL_REG_CPU_CONFIG AR71XX_PLL_CPU_BASE + 0x00 #defineAR91XX_PLL_REG_ETH_CONFIG AR71XX_PLL_CPU_BASE + 0x04 ___ 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-unsubscr...@freebsd.org
Re: svn commit: r211318 - head/usr.sbin/sysinstall
Alexey Dokuchaev da...@freebsd.org writes: Jens Schweikhardt schwe...@freebsd.org writes: Log: Correctly spell janice and jimmy as janis and jimi (assuming the famous rock stars meant were Miss Joplin and Mr Hendrix.) Are you sure this is correct message for the commit, or I am simply missing the irony? Look at the very end of the patch. I wonder who Frank is, though - Zappa? DES -- Dag-Erling Smørgrav - d...@des.no ___ 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-unsubscr...@freebsd.org
svn commit: r211449 - head/sys/mips/atheros
Author: adrian Date: Wed Aug 18 09:11:45 2010 New Revision: 211449 URL: http://svn.freebsd.org/changeset/base/211449 Log: Add a DDR flush function, inspired by both Linux and if_arge.c. Modified: head/sys/mips/atheros/ar71xxreg.h Modified: head/sys/mips/atheros/ar71xxreg.h == --- head/sys/mips/atheros/ar71xxreg.h Wed Aug 18 08:22:58 2010 (r211448) +++ head/sys/mips/atheros/ar71xxreg.h Wed Aug 18 09:11:45 2010 (r211449) @@ -491,5 +491,15 @@ ar71xx_ahb_freq(void) return (freq); } +static inline void +ar71xx_ddr_flush(uint32_t reg) +{ + ATH_WRITE_REG(reg, 1); + while ((ATH_READ_REG(reg) 0x1)) + ; + ATH_WRITE_REG(reg, 1); + while ((ATH_READ_REG(reg) 0x1)) + ; +} #endif /* _AR71XX_REG_H_ */ ___ 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-unsubscr...@freebsd.org
svn commit: r211450 - head
Author: des Date: Wed Aug 18 09:18:37 2010 New Revision: 211450 URL: http://svn.freebsd.org/changeset/base/211450 Log: Revert r211436; it was a good idea, but not fully thought out. Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 == --- head/Makefile.inc1 Wed Aug 18 09:11:45 2010(r211449) +++ head/Makefile.inc1 Wed Aug 18 09:18:37 2010(r211450) @@ -814,16 +814,9 @@ buildkernel: .endif @echo @echo -- - @echo stage 3.2: building the kernel + @echo stage 3.2: building everything @echo -- - cd ${KRNLOBJDIR}/${_kernel}; ${KMAKE} kernel-all -DNO_MODULES_OBJ - @echo -.if !defined(MODULES_WITH_WORLD) !defined(NO_MODULES) exists(${KERNSRCDIR}/modules) - @echo -- - @echo stage 3.3: building the modules - @echo -- - cd ${KRNLOBJDIR}/${_kernel}; ${KMAKE} modules-all -DNO_MODULES_OBJ -.endif + cd ${KRNLOBJDIR}/${_kernel}; ${KMAKE} all -DNO_MODULES_OBJ @echo -- @echo Kernel build for ${_kernel} completed on `LC_ALL=C date` @echo -- ___ 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-unsubscr...@freebsd.org
svn commit: r211451 - head/sys/netinet
Author: bz Date: Wed Aug 18 09:28:12 2010 New Revision: 211451 URL: http://svn.freebsd.org/changeset/base/211451 Log: When calculating the expected memory size for userspace, also take the number of syncache entries into account for the surplus we add to account for a possible increase of records in the re-entry window. Discussed with: jhb, silby MFC after:1 week Modified: head/sys/netinet/tcp_subr.c Modified: head/sys/netinet/tcp_subr.c == --- head/sys/netinet/tcp_subr.c Wed Aug 18 09:18:37 2010(r211450) +++ head/sys/netinet/tcp_subr.c Wed Aug 18 09:28:12 2010(r211451) @@ -1022,7 +1022,7 @@ tcp_pcblist(SYSCTL_HANDLER_ARGS) if (req-oldptr == NULL) { m = syncache_pcbcount(); n = V_tcbinfo.ipi_count; - n += imax(n / 8, 10); + n += imax((m + n) / 8, 10); req-oldidx = 2 * (sizeof xig) + (m + n) * sizeof(struct xtcpcb); return (0); ___ 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-unsubscr...@freebsd.org
Re: svn commit: r211450 - head
Dag-Erling Smorgrav d...@freebsd.org writes: Log: Revert r211436; it was a good idea, but not fully thought out. The probem is that the kernel config may have makeoptions NO_MODULES, in which case there is no modules-all target. DES -- Dag-Erling Smørgrav - d...@des.no ___ 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-unsubscr...@freebsd.org
svn commit: r211452 - head/sbin/hastd
Author: pjd Date: Wed Aug 18 12:09:27 2010 New Revision: 211452 URL: http://svn.freebsd.org/changeset/base/211452 Log: For some setups sending data in 128kB chunks makes communication very slow. No idea why. 32kB on the other hand seems to work properly everywhere. Reported by: Thomas Steen Rasmussen tho...@gibfest.dk MFC after:3 weeks Modified: head/sbin/hastd/proto_common.c Modified: head/sbin/hastd/proto_common.c == --- head/sbin/hastd/proto_common.c Wed Aug 18 09:28:12 2010 (r211451) +++ head/sbin/hastd/proto_common.c Wed Aug 18 12:09:27 2010 (r211452) @@ -42,8 +42,7 @@ __FBSDID($FreeBSD$); /* Maximum size of packet we want to use when sending data. */ #ifndef MAX_SEND_SIZE -//#define MAX_SEND_SIZE 32768 -#defineMAX_SEND_SIZE 131072 +#defineMAX_SEND_SIZE 32768 #endif int ___ 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-unsubscr...@freebsd.org
svn commit: r211453 - in head/sys/mips: include mips
Author: jchandra Date: Wed Aug 18 12:52:21 2010 New Revision: 211453 URL: http://svn.freebsd.org/changeset/base/211453 Log: MIPS n64 support - continued... 1. On n64, use XKPHYS to map page table pages instead of KSEG0. Maintain just one freepages list on n64. The changes are mainly to introduce MIPS_PHYS_TO_DIRECT(pa), MIPS_DIRECT_TO_PHYS(), which will use KSEG0 in 32 bit compilation and XKPHYS in 64 bit compilation. 2. Change macro based PMAP_LMEM_MAP1(), PMAP_LMEM_MAP2(), PMAP_LMEM_UNMAP() to inline functions. 3. Introduce MIPS_DIRECT_MAPPABLE(pa), which will further reduce the cases in which we will need to have a special case for 64 bit compilation. 4. Update CP0 hazard definitions for CPU_RMI - the cpu does not need any nops Reviewed by: neel Modified: head/sys/mips/include/cpuregs.h head/sys/mips/include/vmparam.h head/sys/mips/mips/exception.S head/sys/mips/mips/pmap.c Modified: head/sys/mips/include/cpuregs.h == --- head/sys/mips/include/cpuregs.h Wed Aug 18 12:09:27 2010 (r211452) +++ head/sys/mips/include/cpuregs.h Wed Aug 18 12:52:21 2010 (r211453) @@ -76,8 +76,10 @@ * Caching of mapped addresses is controlled by bits in the TLB entry. */ -#defineMIPS_KSEG0_LARGEST_PHYS (0x2000) -#defineMIPS_PHYS_MASK (0x1fff) +#defineMIPS_KSEG0_LARGEST_PHYS (0x2000) +#defineMIPS_KSEG0_PHYS_MASK(0x1fff) +#defineMIPS_XKPHYS_LARGEST_PHYS(0x100) /* 40 bit PA */ +#defineMIPS_XKPHYS_PHYS_MASK (0x0ff) #ifndef LOCORE #defineMIPS_KUSEG_START0x @@ -95,8 +97,8 @@ #defineMIPS_PHYS_TO_KSEG0(x) ((uintptr_t)(x) | MIPS_KSEG0_START) #defineMIPS_PHYS_TO_KSEG1(x) ((uintptr_t)(x) | MIPS_KSEG1_START) -#defineMIPS_KSEG0_TO_PHYS(x) ((uintptr_t)(x) MIPS_PHYS_MASK) -#defineMIPS_KSEG1_TO_PHYS(x) ((uintptr_t)(x) MIPS_PHYS_MASK) +#defineMIPS_KSEG0_TO_PHYS(x) ((uintptr_t)(x) MIPS_KSEG0_PHYS_MASK) +#defineMIPS_KSEG1_TO_PHYS(x) ((uintptr_t)(x) MIPS_KSEG0_PHYS_MASK) #defineMIPS_IS_KSEG0_ADDR(x) \ (((vm_offset_t)(x) = MIPS_KSEG0_START) \ @@ -107,9 +109,6 @@ #defineMIPS_IS_VALID_PTR(x)(MIPS_IS_KSEG0_ADDR(x) || \ MIPS_IS_KSEG1_ADDR(x)) -#defineMIPS_XKPHYS_START 0x8000 -#defineMIPS_XKPHYS_END 0xbfff - /* * Cache Coherency Attributes: * UC: Uncached. @@ -180,19 +179,34 @@ #defineMIPS_PHYS_TO_XKPHYS_UNCACHED(x) \ ((0x2ULL 62) | ((unsigned long long)(MIPS_CCA_UNCACHED) 59) | (x)) -#defineMIPS_XKPHYS_TO_PHYS(x) ((x) 0x07ffULL) +#defineMIPS_XKPHYS_TO_PHYS(x) ((uintptr_t)(x) MIPS_XKPHYS_PHYS_MASK) +#defineMIPS_XKPHYS_START 0x8000 +#defineMIPS_XKPHYS_END 0xbfff #defineMIPS_XUSEG_START0x #defineMIPS_XUSEG_END 0x0100 - #defineMIPS_XKSEG_START0xc000 #defineMIPS_XKSEG_END 0xc0ff8000 +#ifdef __mips_n64 +#defineMIPS_DIRECT_MAPPABLE(pa)1 +#defineMIPS_PHYS_TO_DIRECT(pa) MIPS_PHYS_TO_XKPHYS_CACHED(pa) +#defineMIPS_PHYS_TO_DIRECT_UNCACHED(pa) MIPS_PHYS_TO_XKPHYS_UNCACHED(pa) +#defineMIPS_DIRECT_TO_PHYS(va) MIPS_XKPHYS_TO_PHYS(va) +#else +#defineMIPS_DIRECT_MAPPABLE(pa)((pa) MIPS_KSEG0_LARGEST_PHYS) +#defineMIPS_PHYS_TO_DIRECT(pa) MIPS_PHYS_TO_KSEG0(pa) +#defineMIPS_PHYS_TO_DIRECT_UNCACHED(pa)MIPS_PHYS_TO_KSEG1(pa) +#defineMIPS_DIRECT_TO_PHYS(va) MIPS_KSEG0_TO_PHYS(va) +#endif + /* CPU dependent mtc0 hazard hook */ #ifdef CPU_CNMIPS #defineCOP0_SYNC nop; nop; nop; nop; nop; #elif defined(CPU_SB1) #define COP0_SYNC ssnop; ssnop; ssnop; ssnop; ssnop; ssnop; ssnop; ssnop; ssnop +#elif defined(CPU_RMI) +#define COP0_SYNC #else /* * Pick a reasonable default based on the typical spacing described in the Modified: head/sys/mips/include/vmparam.h == --- head/sys/mips/include/vmparam.h Wed Aug 18 12:09:27 2010 (r211452) +++ head/sys/mips/include/vmparam.h Wed Aug 18 12:52:21 2010 (r211453) @@ -96,7 +96,7 @@ #defineVM_MINUSER_ADDRESS ((vm_offset_t)0x) #defineVM_MAX_MMAP_ADDRVM_MAXUSER_ADDRESS -#if
svn commit: r211455 - head/sys/geom/mirror
Author: mav Date: Wed Aug 18 15:38:10 2010 New Revision: 211455 URL: http://svn.freebsd.org/changeset/base/211455 Log: Remove bintime_cmp() function, unused since r200086. MFC after:1 week Modified: head/sys/geom/mirror/g_mirror.c Modified: head/sys/geom/mirror/g_mirror.c == --- head/sys/geom/mirror/g_mirror.c Wed Aug 18 14:41:34 2010 (r211454) +++ head/sys/geom/mirror/g_mirror.c Wed Aug 18 15:38:10 2010 (r211455) @@ -844,21 +844,6 @@ g_mirror_unidle(struct g_mirror_softc *s } } -static __inline int -bintime_cmp(struct bintime *bt1, struct bintime *bt2) -{ - - if (bt1-sec bt2-sec) - return (-1); - else if (bt1-sec bt2-sec) - return (1); - if (bt1-frac bt2-frac) - return (-1); - else if (bt1-frac bt2-frac) - return (1); - return (0); -} - static void g_mirror_done(struct bio *bp) { ___ 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-unsubscr...@freebsd.org
svn commit: r211463 - head/usr.bin/grep
Author: gabor Date: Wed Aug 18 17:40:10 2010 New Revision: 211463 URL: http://svn.freebsd.org/changeset/base/211463 Log: - Refactor file reading code to use pure syscalls and an internal buffer instead of stdio. This gives BSD grep a very big performance boost, its speed is now almost comparable to GNU grep. Submitted by: Dimitry Andric dimi...@andric.com Approved by: delphij (mentor) Modified: head/usr.bin/grep/fastgrep.c head/usr.bin/grep/file.c head/usr.bin/grep/grep.h head/usr.bin/grep/util.c Modified: head/usr.bin/grep/fastgrep.c == --- head/usr.bin/grep/fastgrep.cWed Aug 18 17:39:47 2010 (r211462) +++ head/usr.bin/grep/fastgrep.cWed Aug 18 17:40:10 2010 (r211463) @@ -198,7 +198,7 @@ fastcomp(fastgrep_t *fg, const char *pat } int -grep_search(fastgrep_t *fg, unsigned char *data, size_t len, regmatch_t *pmatch) +grep_search(fastgrep_t *fg, const unsigned char *data, size_t len, regmatch_t *pmatch) { unsigned int j; int ret = REG_NOMATCH; Modified: head/usr.bin/grep/file.c == --- head/usr.bin/grep/file.cWed Aug 18 17:39:47 2010(r211462) +++ head/usr.bin/grep/file.cWed Aug 18 17:40:10 2010(r211463) @@ -2,7 +2,8 @@ /*- * Copyright (c) 1999 James Howard and Dag-Erling Co�dan Sm�rgrav - * Copyright (C) 2008-2009 Gabor Kovesdan ga...@freebsd.org + * Copyright (C) 2008-2010 Gabor Kovesdan ga...@freebsd.org + * Copyright (C) 2010 Dimitry Andric dimi...@andric.com * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -37,7 +38,8 @@ __FBSDID($FreeBSD$); #include bzlib.h #include err.h #include errno.h -#include stdio.h +#include fcntl.h +#include stddef.h #include stdlib.h #include string.h #include unistd.h @@ -47,222 +49,204 @@ __FBSDID($FreeBSD$); #include grep.h -static char fname[MAXPATHLEN]; /* file name */ +#defineMAXBUFSIZ (32 * 1024) +#defineLNBUFBUMP 80 -#define MAXBUFSIZ (16 * 1024) -#define PREREAD_M 0.2 +static gzFile gzbufdesc; +static BZFILE* bzbufdesc; -/* Some global variables for the buffering and reading. */ -static char*lnbuf; -static size_t lnbuflen; -static unsigned char *binbuf; -static int binbufsiz; -unsigned char *binbufptr; -static int bzerr; +static unsigned char buffer[MAXBUFSIZ]; +static unsigned char *bufpos; +static size_t bufrem; -#define iswbinary(ch) (!iswspace((ch)) iswcntrl((ch)) \ - (ch != L'\b') (ch != L'\0')) +static unsigned char *lnbuf; +static size_t lnbuflen; -/* - * Returns a single character according to the file type. - * Returns -1 on failure. - */ static inline int -grep_fgetc(struct file *f) +grep_refill(struct file *f) { - unsigned char c; + ssize_t nr; + int bzerr; - switch (filebehave) { - case FILE_STDIO: - return (getc_unlocked(f-f)); - case FILE_GZIP: - return (gzgetc(f-gzf)); - case FILE_BZIP: - BZ2_bzRead(bzerr, f-bzf, c, 1); - if (bzerr == BZ_STREAM_END) - return (-1); - else if (bzerr != BZ_SEQUENCE_ERROR bzerr != BZ_OK) - errx(2, %s, getstr(2)); - return (c); - } - return (-1); + bufpos = buffer; + bufrem = 0; + + if (filebehave == FILE_GZIP) + nr = gzread(gzbufdesc, buffer, MAXBUFSIZ); + else if (filebehave == FILE_BZIP bzbufdesc != NULL) { + nr = BZ2_bzRead(bzerr, bzbufdesc, buffer, MAXBUFSIZ); + switch (bzerr) { + case BZ_OK: + case BZ_STREAM_END: + /* No problem, nr will be okay */ + break; + case BZ_DATA_ERROR_MAGIC: + /* +* As opposed to gzread(), which simply returns the +* plain file data, if it is not in the correct +* compressed format, BZ2_bzRead() instead aborts. +* +* So, just restart at the beginning of the file again, +* and use plain reads from now on. +*/ + BZ2_bzReadClose(bzerr, bzbufdesc); + bzbufdesc = NULL; + if (lseek(f-fd, 0, SEEK_SET) == -1) + return (-1); + nr = read(f-fd, buffer, MAXBUFSIZ); + break; + default: + /* Make sure we exit with an error */ + nr = -1; + } + } else + nr = read(f-fd, buffer, MAXBUFSIZ); + + if (nr
svn commit: r211464 - head/sys/netinet
Author: andre Date: Wed Aug 18 18:05:54 2010 New Revision: 211464 URL: http://svn.freebsd.org/changeset/base/211464 Log: If a TCP connection has been idle for one retransmit timeout or more it must reset its congestion window back to the initial window. RFC3390 has increased the initial window from 1 segment to up to 4 segments. The initial window increase of RFC3390 wasn't reflected into the restart window which remained at its original defaults of 4 segments for local and 1 segment for all other connections. Both values are controllable through sysctl net.inet.tcp.local_slowstart_flightsize and net.inet.tcp.slowstart_flightsize. The increase helps TCP's slow start algorithm to open up the congestion window much faster. Reviewed by: lstewart MFC after:1 week Modified: head/sys/netinet/tcp_output.c head/sys/netinet/tcp_var.h Modified: head/sys/netinet/tcp_output.c == --- head/sys/netinet/tcp_output.c Wed Aug 18 17:40:10 2010 (r211463) +++ head/sys/netinet/tcp_output.c Wed Aug 18 18:05:54 2010 (r211464) @@ -140,7 +140,7 @@ tcp_output(struct tcpcb *tp) { struct socket *so = tp-t_inpcb-inp_socket; long len, recwin, sendwin; - int off, flags, error; + int off, flags, error, rw; struct mbuf *m; struct ip *ip = NULL; struct ipovly *ipov = NULL; @@ -176,23 +176,34 @@ tcp_output(struct tcpcb *tp) idle = (tp-t_flags TF_LASTIDLE) || (tp-snd_max == tp-snd_una); if (idle ticks - tp-t_rcvtime = tp-t_rxtcur) { /* -* We have been idle for a while and no acks are -* expected to clock out any data we send -- -* slow start to get ack clock running again. +* If we've been idle for more than one retransmit +* timeout the old congestion window is no longer +* current and we have to reduce it to the restart +* window before we can transmit again. * -* Set the slow-start flight size depending on whether -* this is a local network or not. +* The restart window is the initial window or the last +* CWND, whichever is smaller. +* +* This is done to prevent us from flooding the path with +* a full CWND at wirespeed, overloading router and switch +* buffers along the way. +* +* See RFC5681 Section 4.1. Restarting Idle Connections. */ - int ss = V_ss_fltsz; + if (V_tcp_do_rfc3390) + rw = min(4 * tp-t_maxseg, +max(2 * tp-t_maxseg, 4380)); #ifdef INET6 - if (isipv6) { - if (in6_localaddr(tp-t_inpcb-in6p_faddr)) - ss = V_ss_fltsz_local; - } else -#endif /* INET6 */ - if (in_localaddr(tp-t_inpcb-inp_faddr)) - ss = V_ss_fltsz_local; - tp-snd_cwnd = tp-t_maxseg * ss; + else if ((isipv6 ? in6_localaddr(tp-t_inpcb-in6p_faddr) : + in_localaddr(tp-t_inpcb-inp_faddr))) +#else + else if (in_localaddr(tp-t_inpcb-inp_faddr)) +#endif + rw = V_ss_fltsz_local * tp-t_maxseg; + else + rw = V_ss_fltsz * tp-t_maxseg; + + tp-snd_cwnd = min(rw, tp-snd_cwnd); } tp-t_flags = ~TF_LASTIDLE; if (idle) { Modified: head/sys/netinet/tcp_var.h == --- head/sys/netinet/tcp_var.h Wed Aug 18 17:40:10 2010(r211463) +++ head/sys/netinet/tcp_var.h Wed Aug 18 18:05:54 2010(r211464) @@ -565,6 +565,7 @@ extern int tcp_log_in_vain; VNET_DECLARE(int, tcp_mssdflt);/* XXX */ VNET_DECLARE(int, tcp_minmss); VNET_DECLARE(int, tcp_delack_enabled); +VNET_DECLARE(int, tcp_do_rfc3390); VNET_DECLARE(int, tcp_do_newreno); VNET_DECLARE(int, path_mtu_discovery); VNET_DECLARE(int, ss_fltsz); @@ -575,6 +576,7 @@ VNET_DECLARE(int, ss_fltsz_local); #defineV_tcp_mssdflt VNET(tcp_mssdflt) #defineV_tcp_minmssVNET(tcp_minmss) #defineV_tcp_delack_enabledVNET(tcp_delack_enabled) +#defineV_tcp_do_rfc3390VNET(tcp_do_rfc3390) #defineV_tcp_do_newrenoVNET(tcp_do_newreno) #defineV_path_mtu_discoveryVNET(path_mtu_discovery) #defineV_ss_fltsz VNET(ss_fltsz) ___ 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-unsubscr...@freebsd.org
Re: svn commit: r211318 - head/usr.sbin/sysinstall
On Wed, Aug 18, 2010 at 11:01:49AM +0200, Dag-Erling Sm??rgrav wrote: Alexey Dokuchaev da...@freebsd.org writes: Jens Schweikhardt schwe...@freebsd.org writes: Log: Correctly spell janice and jimmy as janis and jimi (assuming the famous rock stars meant were Miss Joplin and Mr Hendrix.) Are you sure this is correct message for the commit, or I am simply missing the irony? Look at the very end of the patch. Actually, I did; but the last hunk is just a whitespace change, irrelevant to the commit message (just as most of the other hunks). No wonder I missed the hunk before the last one. ./danfe ___ 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-unsubscr...@freebsd.org
svn commit: r211467 - head/tools/regression/bin/sh/builtins
Author: jilles Date: Wed Aug 18 20:26:50 2010 New Revision: 211467 URL: http://svn.freebsd.org/changeset/base/211467 Log: sh: Add a test for break from a trap action. Added: head/tools/regression/bin/sh/builtins/break2.0 (contents, props changed) head/tools/regression/bin/sh/builtins/break2.0.stdout (contents, props changed) Added: head/tools/regression/bin/sh/builtins/break2.0 == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/regression/bin/sh/builtins/break2.0 Wed Aug 18 20:26:50 2010(r211467) @@ -0,0 +1,12 @@ +# $FreeBSD$ + +# It is not immediately obvious that this should work, and someone probably +# relies on it. + +while :; do + trap 'break' USR1 + kill -USR1 $$ + echo bad + exit 1 +done +echo good Added: head/tools/regression/bin/sh/builtins/break2.0.stdout == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/regression/bin/sh/builtins/break2.0.stdout Wed Aug 18 20:26:50 2010(r211467) @@ -0,0 +1 @@ +good ___ 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-unsubscr...@freebsd.org
Re: svn commit: r211318 - head/usr.sbin/sysinstall
On 2010-Aug-18 19:30:13 +, Alexey Dokuchaev da...@freebsd.org wrote: Actually, I did; but the last hunk is just a whitespace change, irrelevant to the commit message (just as most of the other hunks). No wonder I missed the hunk before the last one. Probably a good example of why the Project's guidelines require the separation of whitespace and functional changes. -- Peter Jeremy pgpGEmQhdQqnI.pgp Description: PGP signature
Re: svn commit: r211318 - head/usr.sbin/sysinstall
On Thu, Aug 19, 2010 at 06:37:30AM +1000, Peter Jeremy wrote: On 2010-Aug-18 19:30:13 +, Alexey Dokuchaev da...@freebsd.org wrote: Actually, I did; but the last hunk is just a whitespace change, irrelevant to the commit message (just as most of the other hunks). No wonder I missed the hunk before the last one. Probably a good example of why the Project's guidelines require the separation of whitespace and functional changes. That was exactly my point. :-) ./danfe ___ 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-unsubscr...@freebsd.org
Re: svn commit: r211463 - head/usr.bin/grep
On Wed, Aug 18, 2010 at 10:40 AM, Gabor Kovesdan ga...@freebsd.org wrote: Author: gabor Date: Wed Aug 18 17:40:10 2010 New Revision: 211463 URL: http://svn.freebsd.org/changeset/base/211463 Log: - Refactor file reading code to use pure syscalls and an internal buffer instead of stdio. This gives BSD grep a very big performance boost, its speed is now almost comparable to GNU grep. I didn't read all of the details in the profiling mails in the thread, but does this mean that work on stdio would give a performance boost to many apps? Or is there something specific about how grep(1) is using its input that makes it a horse of a different color? Thanks, matthew Submitted by: Dimitry Andric dimi...@andric.com Approved by: delphij (mentor) Modified: head/usr.bin/grep/fastgrep.c head/usr.bin/grep/file.c head/usr.bin/grep/grep.h head/usr.bin/grep/util.c Modified: head/usr.bin/grep/fastgrep.c == --- head/usr.bin/grep/fastgrep.c Wed Aug 18 17:39:47 2010 (r211462) +++ head/usr.bin/grep/fastgrep.c Wed Aug 18 17:40:10 2010 (r211463) @@ -198,7 +198,7 @@ fastcomp(fastgrep_t *fg, const char *pat } int -grep_search(fastgrep_t *fg, unsigned char *data, size_t len, regmatch_t *pmatch) +grep_search(fastgrep_t *fg, const unsigned char *data, size_t len, regmatch_t *pmatch) { unsigned int j; int ret = REG_NOMATCH; Modified: head/usr.bin/grep/file.c == --- head/usr.bin/grep/file.c Wed Aug 18 17:39:47 2010 (r211462) +++ head/usr.bin/grep/file.c Wed Aug 18 17:40:10 2010 (r211463) @@ -2,7 +2,8 @@ /*- * Copyright (c) 1999 James Howard and Dag-Erling Coïdan Smørgrav - * Copyright (C) 2008-2009 Gabor Kovesdan ga...@freebsd.org + * Copyright (C) 2008-2010 Gabor Kovesdan ga...@freebsd.org + * Copyright (C) 2010 Dimitry Andric dimi...@andric.com * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -37,7 +38,8 @@ __FBSDID($FreeBSD$); #include bzlib.h #include err.h #include errno.h -#include stdio.h +#include fcntl.h +#include stddef.h #include stdlib.h #include string.h #include unistd.h @@ -47,222 +49,204 @@ __FBSDID($FreeBSD$); #include grep.h -static char fname[MAXPATHLEN]; /* file name */ +#define MAXBUFSIZ (32 * 1024) +#define LNBUFBUMP 80 -#define MAXBUFSIZ (16 * 1024) -#define PREREAD_M 0.2 +static gzFile gzbufdesc; +static BZFILE* bzbufdesc; -/* Some global variables for the buffering and reading. */ -static char *lnbuf; -static size_t lnbuflen; -static unsigned char *binbuf; -static int binbufsiz; -unsigned char *binbufptr; -static int bzerr; +static unsigned char buffer[MAXBUFSIZ]; +static unsigned char *bufpos; +static size_t bufrem; -#define iswbinary(ch) (!iswspace((ch)) iswcntrl((ch)) \ - (ch != L'\b') (ch != L'\0')) +static unsigned char *lnbuf; +static size_t lnbuflen; -/* - * Returns a single character according to the file type. - * Returns -1 on failure. - */ static inline int -grep_fgetc(struct file *f) +grep_refill(struct file *f) { - unsigned char c; + ssize_t nr; + int bzerr; - switch (filebehave) { - case FILE_STDIO: - return (getc_unlocked(f-f)); - case FILE_GZIP: - return (gzgetc(f-gzf)); - case FILE_BZIP: - BZ2_bzRead(bzerr, f-bzf, c, 1); - if (bzerr == BZ_STREAM_END) - return (-1); - else if (bzerr != BZ_SEQUENCE_ERROR bzerr != BZ_OK) - errx(2, %s, getstr(2)); - return (c); - } - return (-1); + bufpos = buffer; + bufrem = 0; + + if (filebehave == FILE_GZIP) + nr = gzread(gzbufdesc, buffer, MAXBUFSIZ); + else if (filebehave == FILE_BZIP bzbufdesc != NULL) { + nr = BZ2_bzRead(bzerr, bzbufdesc, buffer, MAXBUFSIZ); + switch (bzerr) { + case BZ_OK: + case BZ_STREAM_END: + /* No problem, nr will be okay */ + break; + case BZ_DATA_ERROR_MAGIC: + /* + * As opposed to gzread(), which simply returns the + * plain file data, if it is not in the correct + * compressed format, BZ2_bzRead() instead aborts. + * + * So, just restart at the beginning of the file again, + * and use plain reads from now on. + */ + BZ2_bzReadClose(bzerr,
Re: svn commit: r211463 - head/usr.bin/grep
Em 2010.08.18. 22:48, m...@freebsd.org escreveu: On Wed, Aug 18, 2010 at 10:40 AM, Gabor Kovesdanga...@freebsd.org wrote: Author: gabor Date: Wed Aug 18 17:40:10 2010 New Revision: 211463 URL: http://svn.freebsd.org/changeset/base/211463 Log: - Refactor file reading code to use pure syscalls and an internal buffer instead of stdio. This gives BSD grep a very big performance boost, its speed is now almost comparable to GNU grep. I didn't read all of the details in the profiling mails in the thread, but does this mean that work on stdio would give a performance boost to many apps? Or is there something specific about how grep(1) is using its input that makes it a horse of a different color? In stdio, there is some overhead of FILE * locking but in first phase we reduced that overhead by locking once after opening and releasing the lock once before closing (it's fine given that grep isn't threaded). In the previous code, grep read data by character (calling fgetc_unlocked) and now it reads in bigger chunks, this is another difference, which may have improved the performance. We haven't checked using stdio in chunks, because dealing directly with file descriptors made it easier to handle gzip/bzip2 files, so after having seen that the old solution was wrong, this idea came directly. So I cannot surely answer the question. It would be an interesting task to run a benchmark on this, though. Gabor ___ 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-unsubscr...@freebsd.org
Re: svn commit: r211463 - head/usr.bin/grep
On 2010-08-18 22:48, m...@freebsd.org wrote: - Refactor file reading code to use pure syscalls and an internal buffer instead of stdio. This gives BSD grep a very big performance boost, its speed is now almost comparable to GNU grep. I didn't read all of the details in the profiling mails in the thread, but does this mean that work on stdio would give a performance boost to many apps? Or is there something specific about how grep(1) is using its input that makes it a horse of a different color? Originally, it was reading files 1 character at a time, using fgetc(3), the locking version even. This is usually not the fastest way to read a large file with stdio. :) If grep did not have to support .gz or .bz2 files, we could just have plugged in stdio's fgetln(3). I tried this approach first on some non-compressed files, and it performed much better than fgetc'ing. The reading code that was now committed, is basically the same algorithm as fgetln() uses internally, but it can handle gzip and bzip2 input too. ___ 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-unsubscr...@freebsd.org
svn commit: r211474 - in head/tools/regression/pjdfstest/tests: chflags chmod chown link mkdir mkfifo mknod open rename rmdir symlink
Author: pjd Date: Wed Aug 18 22:06:43 2010 New Revision: 211474 URL: http://svn.freebsd.org/changeset/base/211474 Log: More tests. Modified: head/tools/regression/pjdfstest/tests/chflags/01.t head/tools/regression/pjdfstest/tests/chmod/01.t head/tools/regression/pjdfstest/tests/chmod/06.t head/tools/regression/pjdfstest/tests/chown/01.t head/tools/regression/pjdfstest/tests/link/01.t head/tools/regression/pjdfstest/tests/link/10.t head/tools/regression/pjdfstest/tests/mkdir/01.t head/tools/regression/pjdfstest/tests/mkfifo/01.t head/tools/regression/pjdfstest/tests/mkfifo/09.t head/tools/regression/pjdfstest/tests/mknod/01.t head/tools/regression/pjdfstest/tests/mknod/08.t head/tools/regression/pjdfstest/tests/open/01.t head/tools/regression/pjdfstest/tests/rename/12.t head/tools/regression/pjdfstest/tests/rmdir/06.t head/tools/regression/pjdfstest/tests/symlink/08.t Modified: head/tools/regression/pjdfstest/tests/chflags/01.t == --- head/tools/regression/pjdfstest/tests/chflags/01.t Wed Aug 18 21:51:05 2010(r211473) +++ head/tools/regression/pjdfstest/tests/chflags/01.t Wed Aug 18 22:06:43 2010(r211474) @@ -8,13 +8,15 @@ dir=`dirname $0` require chflags -echo 1..5 +echo 1..17 n0=`namegen` n1=`namegen` expect 0 mkdir ${n0} 0755 -expect 0 create ${n0}/${n1} 0644 -expect ENOTDIR chflags ${n0}/${n1}/test SF_IMMUTABLE -expect 0 unlink ${n0}/${n1} +for type in regular fifo block char socket; do + create_file ${type} ${n0}/${n1} + expect ENOTDIR chflags ${n0}/${n1}/test SF_IMMUTABLE + expect 0 unlink ${n0}/${n1} +done expect 0 rmdir ${n0} Modified: head/tools/regression/pjdfstest/tests/chmod/01.t == --- head/tools/regression/pjdfstest/tests/chmod/01.tWed Aug 18 21:51:05 2010(r211473) +++ head/tools/regression/pjdfstest/tests/chmod/01.tWed Aug 18 22:06:43 2010(r211474) @@ -6,13 +6,15 @@ desc=chmod returns ENOTDIR if a compone dir=`dirname $0` . ${dir}/../misc.sh -echo 1..5 +echo 1..17 n0=`namegen` n1=`namegen` expect 0 mkdir ${n0} 0755 -expect 0 create ${n0}/${n1} 0644 -expect ENOTDIR chmod ${n0}/${n1}/test 0644 -expect 0 unlink ${n0}/${n1} +for type in regular fifo block char socket; do + create_file ${type} ${n0}/${n1} + expect ENOTDIR chmod ${n0}/${n1}/test 0644 + expect 0 unlink ${n0}/${n1} +done expect 0 rmdir ${n0} Modified: head/tools/regression/pjdfstest/tests/chmod/06.t == --- head/tools/regression/pjdfstest/tests/chmod/06.tWed Aug 18 21:51:05 2010(r211473) +++ head/tools/regression/pjdfstest/tests/chmod/06.tWed Aug 18 22:06:43 2010(r211474) @@ -7,9 +7,9 @@ dir=`dirname $0` . ${dir}/../misc.sh if supported lchmod; then - echo 1..8 + echo 1..10 else - echo 1..6 + echo 1..8 fi n0=`namegen` @@ -17,6 +17,8 @@ n1=`namegen` expect 0 symlink ${n0} ${n1} expect 0 symlink ${n1} ${n0} +expect ELOOP chmod ${n0} 0644 +expect ELOOP chmod ${n1} 0644 expect ELOOP chmod ${n0}/test 0644 expect ELOOP chmod ${n1}/test 0644 if supported lchmod; then Modified: head/tools/regression/pjdfstest/tests/chown/01.t == --- head/tools/regression/pjdfstest/tests/chown/01.tWed Aug 18 21:51:05 2010(r211473) +++ head/tools/regression/pjdfstest/tests/chown/01.tWed Aug 18 22:06:43 2010(r211474) @@ -6,14 +6,16 @@ desc=chown returns ENOTDIR if a compone dir=`dirname $0` . ${dir}/../misc.sh -echo 1..6 +echo 1..22 n0=`namegen` n1=`namegen` expect 0 mkdir ${n0} 0755 -expect 0 create ${n0}/${n1} 0644 -expect ENOTDIR chown ${n0}/${n1}/test 65534 65534 -expect ENOTDIR lchown ${n0}/${n1}/test 65534 65534 -expect 0 unlink ${n0}/${n1} +for type in regular fifo block char socket; do + create_file ${type} ${n0}/${n1} + expect ENOTDIR chown ${n0}/${n1}/test 65534 65534 + expect ENOTDIR lchown ${n0}/${n1}/test 65534 65534 + expect 0 unlink ${n0}/${n1} +done expect 0 rmdir ${n0} Modified: head/tools/regression/pjdfstest/tests/link/01.t == --- head/tools/regression/pjdfstest/tests/link/01.t Wed Aug 18 21:51:05 2010(r211473) +++ head/tools/regression/pjdfstest/tests/link/01.t Wed Aug 18 22:06:43 2010(r211474) @@ -6,17 +6,19 @@ desc=link returns ENOTDIR if a componen dir=`dirname $0` . ${dir}/../misc.sh -echo 1..8 +echo 1..32 n0=`namegen` n1=`namegen` n2=`namegen` expect 0 mkdir ${n0} 0755 -expect 0 create ${n0}/${n1} 0644 -expect ENOTDIR link ${n0}/${n1}/test ${n0}/${n2} -expect 0 create ${n0}/${n2} 0644 -expect ENOTDIR link ${n0}/${n2} ${n0}/${n1}/test -expect 0 unlink
svn commit: r211475 - head/usr.bin/gzip
Author: delphij Date: Thu Aug 19 01:34:00 2010 New Revision: 211475 URL: http://svn.freebsd.org/changeset/base/211475 Log: Check return value of dup(), it could be -1 when the system is running out of file descriptors for instance. Found with: Coverity Prevent(tm) CID: 6084 MFC after:1 month Modified: head/usr.bin/gzip/unpack.c Modified: head/usr.bin/gzip/unpack.c == --- head/usr.bin/gzip/unpack.c Wed Aug 18 22:06:43 2010(r211474) +++ head/usr.bin/gzip/unpack.c Thu Aug 19 01:34:00 2010(r211475) @@ -312,7 +312,14 @@ unpack(int in, int out, char *pre, size_ { unpack_descriptor_t unpackd; - unpack_parse_header(dup(in), dup(out), pre, prelen, bytes_in, unpackd); + in = dup(in); + if (in == -1) + maybe_err(dup); + out = dup(out); + if (out == -1) + maybe_err(dup); + + unpack_parse_header(in, out, pre, prelen, bytes_in, unpackd); unpack_decode(unpackd, bytes_in); unpack_descriptor_fini(unpackd); ___ 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-unsubscr...@freebsd.org
svn commit: r211476 - head/sys/mips/atheros
Author: adrian Date: Thu Aug 19 02:03:12 2010 New Revision: 211476 URL: http://svn.freebsd.org/changeset/base/211476 Log: Preparation work for supporting the AR91xx and AR724x. * Implement a SoC probe function, from Linux, which determines the SoC family, type and revision. This only probes the AR71xx series SoC and (currently) panics on others. * Migrate some of the AR71XX specific hardware init (USB device, determining system frequencies) into using the cpuops introduced in an earlier commit. Other SoC specific hardware stuff (per-device flush/WB, GPIO pin wiring, Ethernet PLL setup, other things I've likely missed) will be introduced in subsequent commits. Reviewed by: imp@ Obtained from:(partially) Linux Added: head/sys/mips/atheros/ar71xx_chip.c (contents, props changed) head/sys/mips/atheros/ar71xx_chip.h (contents, props changed) head/sys/mips/atheros/ar71xx_setup.c (contents, props changed) head/sys/mips/atheros/ar71xx_setup.h (contents, props changed) Modified: head/sys/mips/atheros/ar71xx_machdep.c head/sys/mips/atheros/ar71xx_wdog.c head/sys/mips/atheros/ar71xxreg.h head/sys/mips/atheros/files.ar71xx head/sys/mips/atheros/uart_bus_ar71xx.c head/sys/mips/atheros/uart_cpu_ar71xx.c Added: head/sys/mips/atheros/ar71xx_chip.c == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/mips/atheros/ar71xx_chip.c Thu Aug 19 02:03:12 2010 (r211476) @@ -0,0 +1,180 @@ +#include sys/cdefs.h +__FBSDID($FreeBSD$); + +#include sys/param.h +#include machine/cpuregs.h + +#include mips/sentry5/s5reg.h + +#include opt_ddb.h + +#include sys/param.h +#include sys/conf.h +#include sys/kernel.h +#include sys/systm.h +#include sys/bus.h +#include sys/cons.h +#include sys/kdb.h +#include sys/reboot.h + +#include vm/vm.h +#include vm/vm_page.h + +#include net/ethernet.h + +#include machine/clock.h +#include machine/cpu.h +#include machine/hwfunc.h +#include machine/md_var.h +#include machine/trap.h +#include machine/vmparam.h + +#include mips/atheros/ar71xxreg.h + +#include mips/atheros/ar71xx_chip.h + +#include mips/atheros/ar71xx_cpudef.h + +/* XXX these should replace the current definitions in ar71xxreg.h */ +/* XXX perhaps an ar71xx_chip.h header file? */ +#define AR71XX_PLL_REG_CPU_CONFIG AR71XX_PLL_CPU_BASE + 0x00 +#define AR71XX_PLL_REG_SEC_CONFIG AR71XX_PLL_CPU_BASE + 0x04 +#define AR71XX_PLL_REG_ETH0_INT_CLOCK AR71XX_PLL_CPU_BASE + 0x10 +#define AR71XX_PLL_REG_ETH1_INT_CLOCK AR71XX_PLL_CPU_BASE + 0x14 + +#define AR71XX_PLL_DIV_SHIFT3 +#define AR71XX_PLL_DIV_MASK 0x1f +#define AR71XX_CPU_DIV_SHIFT16 +#define AR71XX_CPU_DIV_MASK 0x3 +#define AR71XX_DDR_DIV_SHIFT18 +#define AR71XX_DDR_DIV_MASK 0x3 +#define AR71XX_AHB_DIV_SHIFT20 +#define AR71XX_AHB_DIV_MASK 0x7 + +#define AR71XX_ETH0_PLL_SHIFT 17 +#define AR71XX_ETH1_PLL_SHIFT 19 + +/* XXX these shouldn't be in here - this file is a per-chip file */ +/* XXX these should be in the top-level ar71xx type, not ar71xx -chip */ +uint32_t u_ar71xx_cpu_freq; +uint32_t u_ar71xx_ahb_freq; +uint32_t u_ar71xx_ddr_freq; + +static void +ar71xx_chip_detect_mem_size(void) +{ +} + +static void +ar71xx_chip_detect_sys_frequency(void) +{ + uint32_t pll; + uint32_t freq; + uint32_t div; + + pll = ATH_READ_REG(AR71XX_PLL_REG_CPU_CONFIG); + + div = ((pll AR71XX_PLL_DIV_SHIFT) AR71XX_PLL_DIV_MASK) + 1; + freq = div * AR71XX_BASE_FREQ; + + div = ((pll AR71XX_CPU_DIV_SHIFT) AR71XX_CPU_DIV_MASK) + 1; + u_ar71xx_cpu_freq = freq / div; + + div = ((pll AR71XX_DDR_DIV_SHIFT) AR71XX_DDR_DIV_MASK) + 1; + u_ar71xx_ddr_freq = freq / div; + + div = (((pll AR71XX_AHB_DIV_SHIFT) AR71XX_AHB_DIV_MASK) + 1) * 2; + u_ar71xx_ahb_freq = u_ar71xx_cpu_freq / div; +} + +/* + * This does not lock the CPU whilst doing the work! + */ +static void +ar71xx_chip_device_stop(uint32_t mask) +{ + uint32_t reg; + + reg = ATH_READ_REG(AR71XX_RST_RESET); + ATH_WRITE_REG(AR71XX_RST_RESET, reg | mask); +} + +static void +ar71xx_chip_device_start(uint32_t mask) +{ + uint32_t reg; + + reg = ATH_READ_REG(AR71XX_RST_RESET); + ATH_WRITE_REG(AR71XX_RST_RESET, reg ~mask); +} + +static int +ar71xx_chip_device_stopped(uint32_t mask) +{ + uint32_t reg; + + reg = ATH_READ_REG(AR71XX_RST_RESET); +return ((reg mask) == mask); +} + +static void +ar71xx_chip_set_pll_ge0(int speed) +{ +} + +static void +ar71xx_chip_set_pll_ge1(int speed) +{ +} + +static void +ar71xx_chip_ddr_flush_ge0(void) +{ + ar71xx_ddr_flush(AR71XX_WB_FLUSH_GE0); +} + +static void +ar71xx_chip_ddr_flush_ge1(void) +{ + ar71xx_ddr_flush(AR71XX_WB_FLUSH_GE1); +} + +static uint32_t
svn commit: r211477 - head/sys/mips/atheros
Author: adrian Date: Thu Aug 19 02:04:35 2010 New Revision: 211477 URL: http://svn.freebsd.org/changeset/base/211477 Log: Make if_arge use the new cpuops rather than hard coding the DDR flush registers. Modified: head/sys/mips/atheros/if_arge.c Modified: head/sys/mips/atheros/if_arge.c == --- head/sys/mips/atheros/if_arge.c Thu Aug 19 02:03:12 2010 (r211476) +++ head/sys/mips/atheros/if_arge.c Thu Aug 19 02:04:35 2010 (r211477) @@ -79,6 +79,7 @@ MODULE_DEPEND(arge, miibus, 1, 1, 1); #include mips/atheros/ar71xxreg.h #include mips/atheros/if_argevar.h +#include mips/atheros/ar71xx_cpudef.h #undef ARGE_DEBUG #ifdef ARGE_DEBUG @@ -181,14 +182,11 @@ MTX_SYSINIT(miibus_mtx, miibus_mtx, ar static void arge_flush_ddr(struct arge_softc *sc) { - - ATH_WRITE_REG(sc-arge_ddr_flush_reg, 1); - while (ATH_READ_REG(sc-arge_ddr_flush_reg) 1) - ; - - ATH_WRITE_REG(sc-arge_ddr_flush_reg, 1); - while (ATH_READ_REG(sc-arge_ddr_flush_reg) 1) - ; + if (sc-arge_mac_unit == 0) { + ar71xx_device_flush_ddr_ge0(); + } else { + ar71xx_device_flush_ddr_ge1(); + } } static int @@ -237,11 +235,9 @@ arge_attach(device_t dev) KASSERT(((sc-arge_mac_unit == 0) || (sc-arge_mac_unit == 1)), (if_arge: Only MAC0 and MAC1 supported)); if (sc-arge_mac_unit == 0) { - sc-arge_ddr_flush_reg = AR71XX_WB_FLUSH_GE0; sc-arge_pll_reg = AR71XX_PLL_ETH_INT0_CLK; sc-arge_pll_reg_shift = 17; } else { - sc-arge_ddr_flush_reg = AR71XX_WB_FLUSH_GE1; sc-arge_pll_reg = AR71XX_PLL_ETH_INT1_CLK; sc-arge_pll_reg_shift = 19; } @@ -381,19 +377,9 @@ arge_attach(device_t dev) DELAY(20); /* Step 2. Punt the MAC core from the central reset register */ - reg = ATH_READ_REG(AR71XX_RST_RESET); - if (sc-arge_mac_unit == 0) - reg |= RST_RESET_GE0_MAC; - else if (sc-arge_mac_unit == 1) - reg |= RST_RESET_GE1_MAC; - ATH_WRITE_REG(AR71XX_RST_RESET, reg); + ar71xx_device_stop(sc-arge_mac_unit == 0 ? RST_RESET_GE0_MAC : RST_RESET_GE1_MAC); DELAY(100); - reg = ATH_READ_REG(AR71XX_RST_RESET); - if (sc-arge_mac_unit == 0) - reg = ~RST_RESET_GE0_MAC; - else if (sc-arge_mac_unit == 1) - reg = ~RST_RESET_GE1_MAC; - ATH_WRITE_REG(AR71XX_RST_RESET, reg); + ar71xx_device_start(sc-arge_mac_unit == 0 ? RST_RESET_GE0_MAC : RST_RESET_GE1_MAC); /* Step 3. Reconfigure MAC block */ ARGE_WRITE(sc, AR71XX_MAC_CFG1, ___ 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-unsubscr...@freebsd.org
svn commit: r211478 - head/sys/mips/atheros
Author: adrian Date: Thu Aug 19 02:05:16 2010 New Revision: 211478 URL: http://svn.freebsd.org/changeset/base/211478 Log: Make the PCI initialisation path use the new cpuops rather than directly programming the reset register. Modified: head/sys/mips/atheros/ar71xx_pci.c Modified: head/sys/mips/atheros/ar71xx_pci.c == --- head/sys/mips/atheros/ar71xx_pci.c Thu Aug 19 02:04:35 2010 (r211477) +++ head/sys/mips/atheros/ar71xx_pci.c Thu Aug 19 02:05:16 2010 (r211478) @@ -56,6 +56,8 @@ __FBSDID($FreeBSD$); #include mips/atheros/ar71xxreg.h #include mips/atheros/ar71xx_pci_bus_space.h +#include mips/atheros/ar71xx_cpudef.h + #undef AR71XX_PCI_DEBUG #ifdef AR71XX_PCI_DEBUG #define dprintf printf @@ -258,7 +260,6 @@ ar71xx_pci_attach(device_t dev) { int busno = 0; int rid = 0; - uint32_t reset; struct ar71xx_pci_softc *sc = device_get_softc(dev); sc-sc_mem_rman.rm_type = RMAN_ARRAY; @@ -295,15 +296,10 @@ ar71xx_pci_attach(device_t dev) } /* reset PCI core and PCI bus */ - reset = ATH_READ_REG(AR71XX_RST_RESET); - reset |= (RST_RESET_PCI_CORE | RST_RESET_PCI_BUS); - ATH_WRITE_REG(AR71XX_RST_RESET, reset); - ATH_READ_REG(AR71XX_RST_RESET); + ar71xx_device_stop(RST_RESET_PCI_CORE | RST_RESET_PCI_BUS); DELAY(10); - reset = ~(RST_RESET_PCI_CORE | RST_RESET_PCI_BUS); - ATH_WRITE_REG(AR71XX_RST_RESET, reset); - ATH_READ_REG(AR71XX_RST_RESET); + ar71xx_device_start(RST_RESET_PCI_CORE | RST_RESET_PCI_BUS); DELAY(10); /* Init PCI windows */ ___ 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-unsubscr...@freebsd.org
svn commit: r211479 - head/sys/mips/atheros
Author: adrian Date: Thu Aug 19 02:10:05 2010 New Revision: 211479 URL: http://svn.freebsd.org/changeset/base/211479 Log: Remove the now-unused DDR flush register value. Modified: head/sys/mips/atheros/if_argevar.h Modified: head/sys/mips/atheros/if_argevar.h == --- head/sys/mips/atheros/if_argevar.h Thu Aug 19 02:05:16 2010 (r211478) +++ head/sys/mips/atheros/if_argevar.h Thu Aug 19 02:10:05 2010 (r211479) @@ -150,7 +150,6 @@ struct arge_softc { uint32_targe_intr_status; int arge_mac_unit; int arge_phymask; - uint32_targe_ddr_flush_reg; uint32_targe_pll_reg; uint32_targe_pll_reg_shift; int arge_if_flags; ___ 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-unsubscr...@freebsd.org
svn commit: r211480 - head/sys/mips/atheros
Author: adrian Date: Thu Aug 19 02:12:04 2010 New Revision: 211480 URL: http://svn.freebsd.org/changeset/base/211480 Log: Migrate the CPU reset path to use the new cpuops. Modified: head/sys/mips/atheros/ar71xx_machdep.c Modified: head/sys/mips/atheros/ar71xx_machdep.c == --- head/sys/mips/atheros/ar71xx_machdep.c Thu Aug 19 02:10:05 2010 (r211479) +++ head/sys/mips/atheros/ar71xx_machdep.c Thu Aug 19 02:12:04 2010 (r211480) @@ -121,9 +121,7 @@ platform_identify(void) void platform_reset(void) { - uint32_t reg = ATH_READ_REG(AR71XX_RST_RESET); - - ATH_WRITE_REG(AR71XX_RST_RESET, reg | RST_RESET_FULL_CHIP); + ar71xx_device_stop(RST_RESET_FULL_CHIP); /* Wait for reset */ while(1) ; ___ 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-unsubscr...@freebsd.org
svn commit: r211481 - head/sys/mips/atheros
Author: adrian Date: Thu Aug 19 02:14:53 2010 New Revision: 211481 URL: http://svn.freebsd.org/changeset/base/211481 Log: Initialise the USB system using cpuops rather than the AR71XX specific method. Modified: head/sys/mips/atheros/ar71xx_machdep.c Modified: head/sys/mips/atheros/ar71xx_machdep.c == --- head/sys/mips/atheros/ar71xx_machdep.c Thu Aug 19 02:12:04 2010 (r211480) +++ head/sys/mips/atheros/ar71xx_machdep.c Thu Aug 19 02:14:53 2010 (r211481) @@ -255,22 +255,7 @@ platform_start(__register_t a0 __unused, /* * Reset USB devices */ - reg = ATH_READ_REG(AR71XX_RST_RESET); - reg |= - RST_RESET_USB_OHCI_DLL | RST_RESET_USB_HOST | RST_RESET_USB_PHY; - ATH_WRITE_REG(AR71XX_RST_RESET, reg); - DELAY(1000); - reg = - ~(RST_RESET_USB_OHCI_DLL | RST_RESET_USB_HOST | RST_RESET_USB_PHY); - ATH_WRITE_REG(AR71XX_RST_RESET, reg); - - ATH_WRITE_REG(AR71XX_USB_CTRL_CONFIG, - USB_CTRL_CONFIG_OHCI_DES_SWAP | USB_CTRL_CONFIG_OHCI_BUF_SWAP | - USB_CTRL_CONFIG_EHCI_DES_SWAP | USB_CTRL_CONFIG_EHCI_BUF_SWAP); - - ATH_WRITE_REG(AR71XX_USB_CTRL_FLADJ, - (32 USB_CTRL_FLADJ_HOST_SHIFT) | (3 USB_CTRL_FLADJ_A5_SHIFT)); - DELAY(1000); + ar71xx_init_usb_peripheral(); kdb_init(); #ifdef KDB ___ 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-unsubscr...@freebsd.org
svn commit: r211482 - head/sys/mips/atheros
Author: adrian Date: Thu Aug 19 02:15:39 2010 New Revision: 211482 URL: http://svn.freebsd.org/changeset/base/211482 Log: Remove now unused 'reg'. Modified: head/sys/mips/atheros/ar71xx_machdep.c Modified: head/sys/mips/atheros/ar71xx_machdep.c == --- head/sys/mips/atheros/ar71xx_machdep.c Thu Aug 19 02:14:53 2010 (r211481) +++ head/sys/mips/atheros/ar71xx_machdep.c Thu Aug 19 02:15:39 2010 (r211482) @@ -144,7 +144,6 @@ platform_start(__register_t a0 __unused, __register_t a2 __unused, __register_t a3 __unused) { uint64_t platform_counter_freq; - uint32_t reg; int argc, i, count = 0; char **argv, **envp; vm_offset_t kernend; ___ 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-unsubscr...@freebsd.org
svn commit: r211483 - in head/sys: conf powerpc/conf
Author: nwhitehorn Date: Thu Aug 19 03:19:26 2010 New Revision: 211483 URL: http://svn.freebsd.org/changeset/base/211483 Log: Unbreak the LINT kernel on powerpc64. Note that the LINT kernel configuration is TARGET_ARCH specific and must be generated with TARGET_ARCH set. Reviewed by: imp Modified: head/sys/conf/makeLINT.mk head/sys/powerpc/conf/Makefile head/sys/powerpc/conf/NOTES Modified: head/sys/conf/makeLINT.mk == --- head/sys/conf/makeLINT.mk Thu Aug 19 02:15:39 2010(r211482) +++ head/sys/conf/makeLINT.mk Thu Aug 19 03:19:26 2010(r211483) @@ -17,3 +17,6 @@ LINT: ${NOTES} ../../conf/makeLINT.sed echo ident ${.TARGET}-VIMAGE ${.TARGET}-VIMAGE echo options VIMAGE${.TARGET}-VIMAGE .endif +.if ${TARGET} == powerpc + echo machine ${TARGET} ${TARGET_ARCH} ${.TARGET} +.endif Modified: head/sys/powerpc/conf/Makefile == --- head/sys/powerpc/conf/Makefile Thu Aug 19 02:15:39 2010 (r211482) +++ head/sys/powerpc/conf/Makefile Thu Aug 19 03:19:26 2010 (r211483) @@ -1,5 +1,8 @@ # $FreeBSD$ TARGET=powerpc +.if ${MACHINE_ARCH} == powerpc || ${MACHINE_ARCH} == powerpc64 +TARGET_ARCH?=${MACHINE_ARCH} +.endif .include ${.CURDIR}/../../conf/makeLINT.mk Modified: head/sys/powerpc/conf/NOTES == --- head/sys/powerpc/conf/NOTES Thu Aug 19 02:15:39 2010(r211482) +++ head/sys/powerpc/conf/NOTES Thu Aug 19 03:19:26 2010(r211483) @@ -8,7 +8,8 @@ # # CPU OPTIONS -machinepowerpc powerpc +# You must specify a machine directive to choose powerpc or powerpc64 +#machine powerpc powerpc[64] # # You must specify at least one CPU (the one you intend to run on). @@ -44,6 +45,7 @@ devicesnd_davbus # Apple Davbus Audio # # Devices we don't want to deal with +nodevice bktr nodevice fdc nodevice ppc nodevice splash ___ 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-unsubscr...@freebsd.org
svn commit: r211484 - head/sys/cddl/contrib/opensolaris/uts/common/sys
Author: imp Date: Thu Aug 19 03:31:26 2010 New Revision: 211484 URL: http://svn.freebsd.org/changeset/base/211484 Log: First cut at mips n64 ABI support Modified: head/sys/cddl/contrib/opensolaris/uts/common/sys/isa_defs.h Modified: head/sys/cddl/contrib/opensolaris/uts/common/sys/isa_defs.h == --- head/sys/cddl/contrib/opensolaris/uts/common/sys/isa_defs.h Thu Aug 19 03:19:26 2010(r211483) +++ head/sys/cddl/contrib/opensolaris/uts/common/sys/isa_defs.h Thu Aug 19 03:31:26 2010(r211484) @@ -403,6 +403,25 @@ extern C { #define_INT_ALIGNMENT 4 #define_FLOAT_ALIGNMENT4 #define_FLOAT_COMPLEX_ALIGNMENT4 +#if defined(__mips_n64) +#define_LONG_ALIGNMENT 8 +#define_LONG_LONG_ALIGNMENT8 +#define_DOUBLE_ALIGNMENT 8 +#define_DOUBLE_COMPLEX_ALIGNMENT 8 +#define_LONG_DOUBLE_ALIGNMENT 8 +#define_LONG_DOUBLE_COMPLEX_ALIGNMENT 8 +#define_POINTER_ALIGNMENT 8 +#define_MAX_ALIGNMENT 8 +#define_ALIGNMENT_REQUIRED 0 + +#define_LONG_LONG_ALIGNMENT_32 _INT_ALIGNMENT +/* + * Define the appropriate implementation choices. + */ +#if !defined(_LP64) +#define_LP64 +#endif +#else #define_LONG_ALIGNMENT 4 #define_LONG_LONG_ALIGNMENT4 #define_DOUBLE_ALIGNMENT 4 @@ -422,6 +441,7 @@ extern C { #if !defined(_I32LPx) defined(_KERNEL) #define_I32LPx #endif +#endif #define_SUNOS_VTOC_16 #define_DMA_USES_PHYSADDR #define_FIRMWARE_NEEDS_FDISK ___ 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-unsubscr...@freebsd.org