CVS commit: src/sys/arch/evbarm/conf
Module Name:src Committed By: matt Date: Tue Sep 3 06:12:00 UTC 2013 Added Files: src/sys/arch/evbarm/conf: CUBIEBOARD files.cubie mk.cubie std.cubie Log Message: Prelimary config goo for CubieBoard 1 2 (config is happy with it) To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/arch/evbarm/conf/CUBIEBOARD \ src/sys/arch/evbarm/conf/files.cubie src/sys/arch/evbarm/conf/mk.cubie \ src/sys/arch/evbarm/conf/std.cubie Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Added files: Index: src/sys/arch/evbarm/conf/CUBIEBOARD diff -u /dev/null src/sys/arch/evbarm/conf/CUBIEBOARD:1.1 --- /dev/null Tue Sep 3 06:12:00 2013 +++ src/sys/arch/evbarm/conf/CUBIEBOARD Tue Sep 3 06:12:00 2013 @@ -0,0 +1,299 @@ +# +# $NetBSD: CUBIEBOARD,v 1.1 2013/09/03 06:12:00 matt Exp $ +# +# CUBIEBOARD -- Allwinner A10/A20 Eval Board Kernel +# + +include arch/evbarm/conf/std.cubie + +# estimated number of users + +maxusers 32 + +# Standard system options + +options RTC_OFFSET=0 # hardware clock is this many mins. west of GMT +#options NTP # NTP phase/frequency locked loop + +# CPU options + +#options UVMHIST,UVMHIST_PRINT +options CPU_CORTEXA8 +options CPU_CORTEXA7 +options ALLWINNER_A10 +options ALLWINNER_A20 +options PMAPCOUNTERS + +# Architecture options + +# File systems + +file-system FFS # UFS +#file-system LFS # log-structured file system +file-system MFS # memory file system +file-system NFS # Network file system +#file-system ADOSFS # AmigaDOS-compatible file system +#file-system EXT2FS # second extended file system (linux) +#file-system CD9660 # ISO 9660 + Rock Ridge file system +file-system MSDOSFS # MS-DOS file system +#file-system FDESC # /dev/fd +file-system KERNFS # /kern +#file-system NULLFS # loopback file system +file-system PROCFS # /proc +#file-system PUFFS # Userspace file systems (e.g. ntfs-3g sshfs) +#file-system UMAPFS # NULLFS + uid and gid remapping +#file-system UNION # union file system +file-system TMPFS # memory file system +file-system PTYFS # /dev/pts/N support + +# File system options +#options QUOTA # legacy UFS quotas +#options QUOTA2 # new, in-filesystem UFS quotas +#options FFS_EI # FFS Endian Independent support +#options NFSSERVER +options WAPBL # File system journaling support +#options FFS_NO_SNAPSHOT # No FFS snapshot support + +# Networking options + +#options GATEWAY # packet forwarding +options INET # IP + ICMP + TCP + UDP +options INET6 # IPV6 +#options IPSEC # IP security +#options IPSEC_DEBUG # debug for IP security +#options MROUTING # IP multicast routing +#options PIM # Protocol Independent Multicast +#options NETATALK # AppleTalk networking +#options PPP_BSDCOMP # BSD-Compress compression support for PPP +#options PPP_DEFLATE # Deflate compression support for PPP +#options PPP_FILTER # Active filter support for PPP (requires bpf) +#options TCP_DEBUG # Record last TCP_NDEBUG packets with SO_DEBUG + +options NFS_BOOT_BOOTP +options NFS_BOOT_DHCP +#options NFS_BOOT_BOOTSTATIC +#options NFS_BOOTSTATIC_MYIP=\192.168.1.4\ +#options NFS_BOOTSTATIC_GWIP=\192.168.1.1\ +#options NFS_BOOTSTATIC_MASK=\255.255.255.0\ +#options NFS_BOOTSTATIC_SERVADDR=\192.168.1.1\ +#options NFS_BOOTSTATIC_SERVER=\192.168.1.1:/nfs/sdp2430\ + +options NFS_BOOT_RWSIZE=1024 + +# Compatibility options + +#options COMPAT_43 # 4.3BSD compatibility. +options COMPAT_60 # NetBSD 6.0 compatibility. +options COMPAT_50 # NetBSD 5.0 compatibility. +options COMPAT_40 # NetBSD 4.0 compatibility. +options COMPAT_30 # NetBSD 3.0 compatibility. +#options COMPAT_20 # NetBSD 2.0 compatibility. +#options COMPAT_16 # NetBSD 1.6 compatibility. +#options COMPAT_15 # NetBSD 1.5 compatibility. +#options COMPAT_14 # NetBSD 1.4 compatibility. +#options COMPAT_13 # NetBSD 1.3 compatibility. +#options COMPAT_12 # NetBSD 1.2 compatibility. +#options COMPAT_11 # NetBSD 1.1 compatibility. +#options COMPAT_10 # NetBSD 1.0 compatibility. +#options COMPAT_09 # NetBSD 0.9 compatibility. +#options TCP_COMPAT_42 # 4.2BSD TCP/IP bug compat. Not recommended. +#options COMPAT_BSDPTY # /dev/[pt]ty?? ptys. + +# Shared memory options + +options SYSVMSG # System V-like message queues +options SYSVSEM # System V-like semaphores +options SYSVSHM # System V-like memory sharing + +# Device options + +#options MEMORY_DISK_HOOKS # boottime setup of ramdisk +#options MEMORY_DISK_ROOT_SIZE=8192 # Size in blocks +#options MEMORY_DISK_DYNAMIC +#options MINIROOTSIZE=1000 # Size in blocks +#options MEMORY_DISK_IS_ROOT # use memory disk as root + +# Miscellaneous kernel options +options KTRACE # system call tracing, a la ktrace(1) +#options KMEMSTATS # kernel memory statistics +#options SCSIVERBOSE # Verbose SCSI errors +#options MIIVERBOSE # Verbose MII autoconfuration messages +#options DDB_KEYCODE=0x40 +#options USERCONF # userconf(4) support +#options
CVS commit: src/lib/libexecinfo
Module Name:src Committed By: christos Date: Tue Sep 3 08:44:45 UTC 2013 Modified Files: src/lib/libexecinfo: symtab.c Log Message: print an error if we failed to allocate. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/lib/libexecinfo/symtab.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libexecinfo/symtab.c diff -u src/lib/libexecinfo/symtab.c:1.2 src/lib/libexecinfo/symtab.c:1.3 --- src/lib/libexecinfo/symtab.c:1.2 Thu Aug 29 11:01:57 2013 +++ src/lib/libexecinfo/symtab.c Tue Sep 3 04:44:45 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: symtab.c,v 1.2 2013/08/29 15:01:57 christos Exp $ */ +/* $NetBSD: symtab.c,v 1.3 2013/09/03 08:44:45 christos Exp $ */ /*- * Copyright (c) 2012 The NetBSD Foundation, Inc. @@ -29,7 +29,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include sys/cdefs.h -__RCSID($NetBSD: symtab.c,v 1.2 2013/08/29 15:01:57 christos Exp $); +__RCSID($NetBSD: symtab.c,v 1.3 2013/09/03 08:44:45 christos Exp $); #include stdlib.h #include stdio.h @@ -139,8 +139,10 @@ symtab_create(int fd, int bind, int type s-st_info = sym.st_info; s-st_name = strdup( elf_strptr(elf, shdr.sh_link, sym.st_name)); - if (s-st_name == NULL) + if (s-st_name == NULL) { +warn(Cannot allocate symbol); goto out; + } s++; } st-nsymbols = s - st-symbols;
CVS commit: src/distrib/sets/lists/debug
Module Name:src Committed By: htodd Date: Tue Sep 3 13:21:53 UTC 2013 Modified Files: src/distrib/sets/lists/debug: mi Log Message: Fix debug build by adding cgram.debug. To generate a diff of this commit: cvs rdiff -u -r1.31 -r1.32 src/distrib/sets/lists/debug/mi Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/debug/mi diff -u src/distrib/sets/lists/debug/mi:1.31 src/distrib/sets/lists/debug/mi:1.32 --- src/distrib/sets/lists/debug/mi:1.31 Fri Aug 16 15:34:05 2013 +++ src/distrib/sets/lists/debug/mi Tue Sep 3 13:21:53 2013 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.31 2013/08/16 15:34:05 christos Exp $ +# $NetBSD: mi,v 1.32 2013/09/03 13:21:53 htodd Exp $ ./etc/mtree/set.debug comp-sys-root ./usr/lib/i18n/libBIG5_g.a -unknown- debuglib @@ -820,6 +820,7 @@ ./usr/libdata/debug/usr/games/caesar.debug comp-utils-debug debug ./usr/libdata/debug/usr/games/canfield.debug comp-games-debug debug ./usr/libdata/debug/usr/games/cfscores.debug comp-games-debug debug +./usr/libdata/debug/usr/games/cgram.debug comp-games-debug debug ./usr/libdata/debug/usr/games/colorbars.debug comp-utils-debug debug ./usr/libdata/debug/usr/games/cribbage.debug comp-games-debug debug ./usr/libdata/debug/usr/games/dab.debug comp-games-debug debug
CVS commit: src/external/bsd/llvm/lib
Module Name:src Committed By: joerg Date: Tue Sep 3 14:54:00 UTC 2013 Modified Files: src/external/bsd/llvm/lib/libLLVMSupport: Makefile src/external/bsd/llvm/lib/libLLVMX86Disassembler: Makefile Log Message: Use CPPFLAGS.src and not COPTS.src to override -std=c++11 flag. The latter doesn't help make depend. To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/external/bsd/llvm/lib/libLLVMSupport/Makefile cvs rdiff -u -r1.2 -r1.3 \ src/external/bsd/llvm/lib/libLLVMX86Disassembler/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/bsd/llvm/lib/libLLVMSupport/Makefile diff -u src/external/bsd/llvm/lib/libLLVMSupport/Makefile:1.20 src/external/bsd/llvm/lib/libLLVMSupport/Makefile:1.21 --- src/external/bsd/llvm/lib/libLLVMSupport/Makefile:1.20 Mon Sep 2 14:34:56 2013 +++ src/external/bsd/llvm/lib/libLLVMSupport/Makefile Tue Sep 3 14:54:00 2013 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.20 2013/09/02 14:34:56 joerg Exp $ +# $NetBSD: Makefile,v 1.21 2013/09/03 14:54:00 joerg Exp $ LIB= LLVMSupport @@ -111,7 +111,7 @@ SRCS+= Host.inc \ TimeValue.inc .for src in ${SRCS:M*.c} -COPTS.${src}+= -std=gnu99 +CPPFLAGS.${src}+= -std=gnu99 .endfor .if defined(HOSTLIB) Index: src/external/bsd/llvm/lib/libLLVMX86Disassembler/Makefile diff -u src/external/bsd/llvm/lib/libLLVMX86Disassembler/Makefile:1.2 src/external/bsd/llvm/lib/libLLVMX86Disassembler/Makefile:1.3 --- src/external/bsd/llvm/lib/libLLVMX86Disassembler/Makefile:1.2 Mon Sep 2 14:34:56 2013 +++ src/external/bsd/llvm/lib/libLLVMX86Disassembler/Makefile Tue Sep 3 14:54:00 2013 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.2 2013/09/02 14:34:56 joerg Exp $ +# $NetBSD: Makefile,v 1.3 2013/09/03 14:54:00 joerg Exp $ LIB= LLVMX86Disassembler @@ -13,7 +13,7 @@ SRCS+= X86Disassembler.cpp \ X86DisassemblerDecoder.c .for src in ${SRCS:M*.c} -COPTS.${src}+= -std=gnu99 +CPPFLAGS.${src}+= -std=gnu99 .endfor .if defined(HOSTLIB)
CVS commit: src/sys/dev/ic
Module Name:src Committed By: jmcneill Date: Tue Sep 3 15:32:55 UTC 2013 Modified Files: src/sys/dev/ic: com.c comreg.h comvar.h Log Message: no EFR on tl16c750, use AFE bit on MCR reg instead for flow control To generate a diff of this commit: cvs rdiff -u -r1.314 -r1.315 src/sys/dev/ic/com.c cvs rdiff -u -r1.20 -r1.21 src/sys/dev/ic/comreg.h cvs rdiff -u -r1.76 -r1.77 src/sys/dev/ic/comvar.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/ic/com.c diff -u src/sys/dev/ic/com.c:1.314 src/sys/dev/ic/com.c:1.315 --- src/sys/dev/ic/com.c:1.314 Sun Sep 1 04:58:15 2013 +++ src/sys/dev/ic/com.c Tue Sep 3 15:32:55 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: com.c,v 1.314 2013/09/01 04:58:15 kiyohara Exp $ */ +/* $NetBSD: com.c,v 1.315 2013/09/03 15:32:55 jmcneill Exp $ */ /*- * Copyright (c) 1998, 1999, 2004, 2008 The NetBSD Foundation, Inc. @@ -66,7 +66,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: com.c,v 1.314 2013/09/01 04:58:15 kiyohara Exp $); +__KERNEL_RCSID(0, $NetBSD: com.c,v 1.315 2013/09/03 15:32:55 jmcneill Exp $); #include opt_com.h #include opt_ddb.h @@ -505,7 +505,7 @@ com_attach_subr(struct com_softc *sc) ISSET(iir2, IIR_64B_FIFO)) { /* It is TL16C750. */ sc-sc_fifolen = 64; -SET(sc-sc_hwflags, COM_HW_FLOW); +SET(sc-sc_hwflags, COM_HW_AFE); } else CSR_WRITE_1(regsp, COM_REG_FIFO, fcr); @@ -1358,7 +1358,11 @@ comparam(struct tty *tp, struct termios sc-sc_mcr_dtr = MCR_DTR; sc-sc_mcr_rts = MCR_RTS; sc-sc_msr_cts = MSR_CTS; - sc-sc_efr = EFR_AUTORTS | EFR_AUTOCTS; + if (ISSET(sc-sc_hwflags, COM_HW_AFE)) { + SET(sc-sc_mcr, MCR_AFE); + } else { + sc-sc_efr = EFR_AUTORTS | EFR_AUTOCTS; + } } else if (ISSET(t-c_cflag, MDMBUF)) { /* * For DTR/DCD flow control, make sure we don't toggle DTR for @@ -1367,7 +1371,11 @@ comparam(struct tty *tp, struct termios sc-sc_mcr_dtr = 0; sc-sc_mcr_rts = MCR_DTR; sc-sc_msr_cts = MSR_DCD; - sc-sc_efr = 0; + if (ISSET(sc-sc_hwflags, COM_HW_AFE)) { + CLR(sc-sc_mcr, MCR_AFE); + } else { + sc-sc_efr = 0; + } } else { /* * If no flow control, then always set RTS. This will make @@ -1377,7 +1385,11 @@ comparam(struct tty *tp, struct termios sc-sc_mcr_dtr = MCR_DTR | MCR_RTS; sc-sc_mcr_rts = 0; sc-sc_msr_cts = 0; - sc-sc_efr = 0; + if (ISSET(sc-sc_hwflags, COM_HW_AFE)) { + CLR(sc-sc_mcr, MCR_AFE); + } else { + sc-sc_efr = 0; + } if (ISSET(sc-sc_mcr, MCR_DTR)) SET(sc-sc_mcr, MCR_RTS); else Index: src/sys/dev/ic/comreg.h diff -u src/sys/dev/ic/comreg.h:1.20 src/sys/dev/ic/comreg.h:1.21 --- src/sys/dev/ic/comreg.h:1.20 Sun Sep 1 04:58:15 2013 +++ src/sys/dev/ic/comreg.h Tue Sep 3 15:32:55 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: comreg.h,v 1.20 2013/09/01 04:58:15 kiyohara Exp $ */ +/* $NetBSD: comreg.h,v 1.21 2013/09/03 15:32:55 jmcneill Exp $ */ /*- * Copyright (c) 1991 The Regents of the University of California. @@ -111,6 +111,7 @@ #define MCR_PRESCALE 0x80 /* 16650/16950: Baud rate prescaler select */ #define MCR_TCR_TLR 0x40 /* OMAP: enables access to the TCR TLR regs */ #define MCR_XONENABLE 0x20 /* OMAP XON_EN */ +#define MCR_AFE 0x20 /* tl16c750: Flow Control Enable */ #define MCR_LOOPBACK 0x10 /* Loop test: echos from TX to RX */ #define MCR_IENABLE 0x08 /* Out2: enables UART interrupts */ #define MCR_DRS 0x04 /* Out1: resets some internal modems */ Index: src/sys/dev/ic/comvar.h diff -u src/sys/dev/ic/comvar.h:1.76 src/sys/dev/ic/comvar.h:1.77 --- src/sys/dev/ic/comvar.h:1.76 Sun Sep 1 04:51:24 2013 +++ src/sys/dev/ic/comvar.h Tue Sep 3 15:32:55 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: comvar.h,v 1.76 2013/09/01 04:51:24 kiyohara Exp $ */ +/* $NetBSD: comvar.h,v 1.77 2013/09/03 15:32:55 jmcneill Exp $ */ /* * Copyright (c) 1996 Christopher G. Demetriou. All rights reserved. @@ -69,6 +69,7 @@ int com_is_console(bus_space_tag_t, bus_ #define COM_HW_KGDB 0x80 #define COM_HW_TXFIFO_DISABLE 0x100 #define COM_HW_NO_TXPRELOAD 0x200 +#define COM_HW_AFE 0x400 /* Buffer size for character buffer */ #ifndef COM_RING_SIZE
CVS commit: src/sys/arch/evbarm/cubie
Module Name:src Committed By: matt Date: Tue Sep 3 18:01:33 UTC 2013 Added Files: src/sys/arch/evbarm/cubie: cubie_machdep.c cubie_start.S genassym.cf platform.h Log Message: First attempt at initial evbarm support for cubieboard (compile tested). To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/arch/evbarm/cubie/cubie_machdep.c \ src/sys/arch/evbarm/cubie/cubie_start.S \ src/sys/arch/evbarm/cubie/genassym.cf \ src/sys/arch/evbarm/cubie/platform.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Added files: Index: src/sys/arch/evbarm/cubie/cubie_machdep.c diff -u /dev/null src/sys/arch/evbarm/cubie/cubie_machdep.c:1.1 --- /dev/null Tue Sep 3 18:01:33 2013 +++ src/sys/arch/evbarm/cubie/cubie_machdep.c Tue Sep 3 18:01:33 2013 @@ -0,0 +1,685 @@ +/* $NetBSD: cubie_machdep.c,v 1.1 2013/09/03 18:01:33 matt Exp $ */ + +/* + * Machine dependent functions for kernel setup for TI OSK5912 board. + * Based on lubbock_machdep.c which in turn was based on iq80310_machhdep.c + * + * Copyright (c) 2002, 2003, 2005 Genetec Corporation. All rights reserved. + * Written by Hiroyuki Bessho for Genetec Corporation. + * + * 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. + * 3. The name of Genetec Corporation may not be used to endorse or + *promote products derived from this software without specific prior + *written permission. + * + * THIS SOFTWARE IS PROVIDED BY GENETEC CORPORATION ``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 GENETEC CORPORATION + * 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. + * + * Copyright (c) 2001 Wasabi Systems, Inc. + * All rights reserved. + * + * Written by Jason R. Thorpe for Wasabi Systems, Inc. + * + * 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. + * 3. All advertising materials mentioning features or use of this software + *must display the following acknowledgement: + * This product includes software developed for the NetBSD Project by + * Wasabi Systems, Inc. + * 4. The name of Wasabi Systems, Inc. may not be used to endorse + *or promote products derived from this software without specific prior + *written permission. + * + * THIS SOFTWARE IS PROVIDED BY WASABI SYSTEMS, INC. ``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 WASABI SYSTEMS, INC + * 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. + * + * Copyright (c) 1997,1998 Mark Brinicombe. + * Copyright (c) 1997,1998 Causality Limited. + * 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
CVS commit: src/sys/rump
Module Name:src Committed By: pooka Date: Tue Sep 3 19:57:02 UTC 2013 Modified Files: src/sys/rump: Makefile.rump Log Message: RUMPCOMP_USEROBJ - RUMPOBJ_NORENAME Widens the implied usage scope of the variable. To generate a diff of this commit: cvs rdiff -u -r1.86 -r1.87 src/sys/rump/Makefile.rump Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/rump/Makefile.rump diff -u src/sys/rump/Makefile.rump:1.86 src/sys/rump/Makefile.rump:1.87 --- src/sys/rump/Makefile.rump:1.86 Fri Aug 30 10:29:06 2013 +++ src/sys/rump/Makefile.rump Tue Sep 3 19:57:02 2013 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.rump,v 1.86 2013/08/30 10:29:06 pooka Exp $ +# $NetBSD: Makefile.rump,v 1.87 2013/09/03 19:57:02 pooka Exp $ # WARNS?= 3 # XXX: src/sys won't compile with -Wsign-compare yet @@ -110,7 +110,7 @@ rumpcomp_user.po: rumpcomp_user.c ${_MKTARGET_COMPILE} ${CC} -o ${.TARGET} ${PROFFLAGS} -pg ${DBG} ${CWARNFLAGS} ${RUMPCOMP_USER_WERROR} -Wall -Wmissing-prototypes ${BUILDRUMP_CPPFLAGS} ${BUILDRUMP_CFLAGS} ${RUMPCOMP_USER_CPPFLAGS} ${RUMPCOMP_USER_CFLAGS} -c ${.ALLSRC:O:u:M*rumpcomp_user.c} -RUMPCOMP_USEROBJ=rumpcomp_user.*o +RUMPOBJ_NORENAME+=rumpcomp_user.*o SRCS+=rumpcomp_user.c .endif @@ -174,7 +174,7 @@ __archivebuild: .USE ${_MKTARGET_BUILD} rm -f ${.TARGET} .endif - for obj in ${RUMP_SYMREN:U${.ALLSRC:N${RUMPCOMP_USEROBJ}}}; do \ + for obj in ${RUMP_SYMREN:U${.ALLSRC:N${RUMPOBJ_NORENAME}}}; do \ ${NM} -go $${obj} | ${TOOL_AWK} ' \ $$NF!~/^'${_PQ}'(rump|RUMP|__|_GLOBAL_OFFSET_TABLE'${_SYMQUIRK}')/ \ {s=$$NF;sub(/^'${_PQ}'/, rumpns_, s); print $$NF, s}'\
CVS commit: src/sys
Module Name:src Committed By: pooka Date: Tue Sep 3 19:55:13 UTC 2013 Modified Files: src/sys/kern: makesyscalls.sh src/sys/rump/librump/rumpkern: rump.c rump_private.h Log Message: Don't autogenerate the wrapper that is called from the rump kernel local syscall entry points. The wrapper is now so big that it doesn't get inlined (original intent for having it close to the entry points), and autogenerating a regular function just loses in flexibility. To generate a diff of this commit: cvs rdiff -u -r1.129 -r1.130 src/sys/kern/makesyscalls.sh cvs rdiff -u -r1.271 -r1.272 src/sys/rump/librump/rumpkern/rump.c cvs rdiff -u -r1.74 -r1.75 src/sys/rump/librump/rumpkern/rump_private.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/kern/makesyscalls.sh diff -u src/sys/kern/makesyscalls.sh:1.129 src/sys/kern/makesyscalls.sh:1.130 --- src/sys/kern/makesyscalls.sh:1.129 Thu Aug 15 21:16:13 2013 +++ src/sys/kern/makesyscalls.sh Tue Sep 3 19:55:13 2013 @@ -1,4 +1,4 @@ -# $NetBSD: makesyscalls.sh,v 1.129 2013/08/15 21:16:13 pooka Exp $ +# $NetBSD: makesyscalls.sh,v 1.130 2013/09/03 19:55:13 pooka Exp $ # # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou # All rights reserved. @@ -245,21 +245,8 @@ NR == 1 { printf #include sys/syscallvar.h\n\n rumpcalls printf #include rump/rumpuser.h\n rumpcalls printf #include \rump_private.h\\n\n rumpcalls - printf static int\nrsys_syscall rumpcalls - printf (int num, void *data, size_t dlen, register_t *retval) rumpcalls - printf \n{\n\tstruct proc *p;\n rumpcalls - printf \tstruct emul *e;\n rumpcalls - printf \tstruct sysent *callp;\n rumpcalls - printf \tint rv;\n\n rumpcalls - printf \trump_schedule();\n rumpcalls - printf \tp = curproc;\n rumpcalls - printf \te = p-p_emul;\n rumpcalls - printf #ifndef __HAVE_MINIMAL_EMUL\n rumpcalls - printf \tKASSERT(num 0 num e-e_nsysent);\n rumpcalls - printf #endif\n rumpcalls - printf \tcallp = e-e_sysent + num;\n\n rumpcalls - printf \trv = sy_call(callp, curlwp, data, retval);\n rumpcalls - printf \trump_unschedule();\n\n\treturn rv;\n}\n\n rumpcalls + printf #define rsys_syscall(num, data, dlen, retval)\t\\\n rumpcalls + printf rump_syscall(num, data, dlen, retval)\n\n rumpcalls printf #define rsys_seterrno(error) rumpuser_seterrno(error)\n rumpcalls printf #define rsys_alias(a,b) __weak_alias(a,b);\n#endif\n\n rumpcalls Index: src/sys/rump/librump/rumpkern/rump.c diff -u src/sys/rump/librump/rumpkern/rump.c:1.271 src/sys/rump/librump/rumpkern/rump.c:1.272 --- src/sys/rump/librump/rumpkern/rump.c:1.271 Wed Jul 3 17:10:28 2013 +++ src/sys/rump/librump/rumpkern/rump.c Tue Sep 3 19:55:13 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: rump.c,v 1.271 2013/07/03 17:10:28 njoly Exp $ */ +/* $NetBSD: rump.c,v 1.272 2013/09/03 19:55:13 pooka Exp $ */ /* * Copyright (c) 2007-2011 Antti Kantee. All Rights Reserved. @@ -26,7 +26,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: rump.c,v 1.271 2013/07/03 17:10:28 njoly Exp $); +__KERNEL_RCSID(0, $NetBSD: rump.c,v 1.272 2013/09/03 19:55:13 pooka Exp $); #include sys/systm.h #define ELFSIZE ARCH_ELFSIZE @@ -982,3 +982,25 @@ rump_xc_highpri(struct cpu_info *ci) else xc_broadcast(0, ipiemu, NULL, NULL); } + +int +rump_syscall(int num, void *data, size_t dlen, register_t *retval) +{ + struct proc *p; + struct emul *e; + struct sysent *callp; + int rv; + + rump_schedule(); + p = curproc; + e = p-p_emul; +#ifndef __HAVE_MINIMAL_EMUL + KASSERT(num 0 num e-e_nsysent); +#endif + callp = e-e_sysent + num; + + rv = sy_call(callp, curlwp, data, retval); + rump_unschedule(); + + return rv; +} Index: src/sys/rump/librump/rumpkern/rump_private.h diff -u src/sys/rump/librump/rumpkern/rump_private.h:1.74 src/sys/rump/librump/rumpkern/rump_private.h:1.75 --- src/sys/rump/librump/rumpkern/rump_private.h:1.74 Sun Mar 10 16:51:31 2013 +++ src/sys/rump/librump/rumpkern/rump_private.h Tue Sep 3 19:55:13 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: rump_private.h,v 1.74 2013/03/10 16:51:31 pooka Exp $ */ +/* $NetBSD: rump_private.h,v 1.75 2013/09/03 19:55:13 pooka Exp $ */ /* * Copyright (c) 2007-2011 Antti Kantee. All Rights Reserved. @@ -118,6 +118,7 @@ void rump_schedule_cpu_interlock(struct void rump_unschedule_cpu(struct lwp *); void rump_unschedule_cpu_interlock(struct lwp *, void *); void rump_unschedule_cpu1(struct lwp *, void *); +int rump_syscall(int, void *, size_t, register_t *); void rump_schedlock_cv_wait(struct rumpuser_cv *); int rump_schedlock_cv_timedwait(struct rumpuser_cv *,
CVS commit: src/sys/kern
Module Name:src Committed By: pooka Date: Tue Sep 3 20:54:03 UTC 2013 Modified Files: src/sys/kern: makesyscalls.sh Log Message: Autogenerate rump_syscalls.c into the correct namespace, i.e. it no longer needs to go through rename in the build. To generate a diff of this commit: cvs rdiff -u -r1.130 -r1.131 src/sys/kern/makesyscalls.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/kern/makesyscalls.sh diff -u src/sys/kern/makesyscalls.sh:1.130 src/sys/kern/makesyscalls.sh:1.131 --- src/sys/kern/makesyscalls.sh:1.130 Tue Sep 3 19:55:13 2013 +++ src/sys/kern/makesyscalls.sh Tue Sep 3 20:54:03 2013 @@ -1,4 +1,4 @@ -# $NetBSD: makesyscalls.sh,v 1.130 2013/09/03 19:55:13 pooka Exp $ +# $NetBSD: makesyscalls.sh,v 1.131 2013/09/03 20:54:03 pooka Exp $ # # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou # All rights reserved. @@ -239,7 +239,8 @@ NR == 1 { printf #define rsys_syscall(num, data, dlen, retval)\t\\\n rumpcalls printf rumpclient_syscall(num, data, dlen, retval)\n rumpcalls printf #define rsys_seterrno(error) errno = error\n rumpcalls - printf #define rsys_alias(a,b)\n#else\n rumpcalls + printf #define rsys_define(nam)\n rumpcalls + printf #else\n rumpcalls printf #include sys/syscall.h\n rumpcalls printf #include sys/syscallargs.h\n\n rumpcalls printf #include sys/syscallvar.h\n\n rumpcalls @@ -247,8 +248,13 @@ NR == 1 { printf #include \rump_private.h\\n\n rumpcalls printf #define rsys_syscall(num, data, dlen, retval)\t\\\n rumpcalls printf rump_syscall(num, data, dlen, retval)\n\n rumpcalls - printf #define rsys_seterrno(error) rumpuser_seterrno(error)\n rumpcalls - printf #define rsys_alias(a,b) __weak_alias(a,b);\n#endif\n\n rumpcalls + printf #define rsys_seterrno(error) rumpuser_seterrno(error)\n \ + rumpcalls + printf #define rsys_define(nam) \\\n rumpcalls + printf \tint nam(struct lwp *, const void *, register_t *);\t\\\n \ + rumpcalls + printf \t__weak_alias(nam,rump_enosys);\n rumpcalls + printf #endif\n\n rumpcalls printf #if\tBYTE_ORDER == BIG_ENDIAN\n rumpcalls printf #define SPARG(p,k)\t((p)-k.be.datum)\n rumpcalls @@ -259,6 +265,7 @@ NR == 1 { printf int rump_enosys(void);\n rumpcalls printf int\nrump_enosys()\n{\n\n\treturn ENOSYS;\n}\n rumpcalls printf #endif\n rumpcalls + printf \nvoid rumpns_sys_nomodule(void);\n rumpcalls printf \n#ifndef RUMP_CLIENT\n rumpsysent printf #define\ts(type)\tsizeof(type)\n rumpsysent @@ -635,7 +642,7 @@ function printproto(wrap) { function printrumpsysent(insysent, compatwrap) { if (!insysent) { eno[0] = rump_enosys - eno[1] = sys_nomodule + eno[1] = rumpns_sys_nomodule flags[0] = SYCALL_NOSYS flags[1] = 0 printf(\t{ 0, 0, %s,\n\t(sy_call_t *)%s }, \t \ @@ -654,12 +661,17 @@ function printrumpsysent(insysent, compa if (compatwrap == ) { if (modular) - rfn = (sy_call_t *)sys_nomodule + rfn = sys_nomodule else - rfn = (sy_call_t *) funcname + rfn = funcname } else { - rfn = (sy_call_t *) compatwrap _ funcname + rfn = compatwrap _ funcname + } + + if (match(rfn, rump) != 1) { + rfn = rumpns_ rfn } + rfn = (sy_call_t *) rfn printf(0,\n\t%s },, rfn) rumpsysent for (i = 0; i (33 - length(rfn)) / 8; i++) @@ -855,7 +867,7 @@ function putent(type, compatwrap) { printf(\treturn rv;\n) rumpcalls } printf(}\n) rumpcalls - printf(rsys_alias(%s%s,rump_enosys)\n, \ + printf(rsys_define(rumpns_%s%s);\n, \ compatwrap_, funcname) rumpcalls } @@ -927,6 +939,7 @@ END { printf(\t} else {\n\t\tfd[0] = retval[0];\n) rumpcalls printf(\t\tfd[1] = retval[1];\n\t}\n) rumpcalls printf(\treturn error ? -1 : 0;\n}\n) rumpcalls + printf(rsys_define(rumpns_sys_pipe);\n) rumpcalls } # print default rump syscall interfaces @@ -957,7 +970,7 @@ END { printf(};\n) sysent printf(};\n) rumpsysent printf(CTASSERT(__arraycount(rump_sysent) == SYS_NSYSENT);\n) rumpsysent - printf(__strong_alias(sysent,rump_sysent);\n) rumpsysent + printf(__strong_alias(rumpns_sysent,rump_sysent);\n) rumpsysent printf(#endif /* RUMP_CLIENT */\n) rumpsysent if (haverumpcalls) printf(#endif /* !RUMP_CLIENT */\n) sysprotos
CVS commit: src/sys/kern
Module Name:src Committed By: pooka Date: Tue Sep 3 21:28:24 UTC 2013 Modified Files: src/sys/kern: makesyscalls.sh Log Message: If RUMP_KERNEL_IS_LIBC is defined, alias the rump kernel syscalls to libc syscall stub symbol names. This allows running standalone programs in OS-less environments such as directly on a Xen DomU backed only by a libc and a rump kernel. To generate a diff of this commit: cvs rdiff -u -r1.131 -r1.132 src/sys/kern/makesyscalls.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/kern/makesyscalls.sh diff -u src/sys/kern/makesyscalls.sh:1.131 src/sys/kern/makesyscalls.sh:1.132 --- src/sys/kern/makesyscalls.sh:1.131 Tue Sep 3 20:54:03 2013 +++ src/sys/kern/makesyscalls.sh Tue Sep 3 21:28:24 2013 @@ -1,4 +1,4 @@ -# $NetBSD: makesyscalls.sh,v 1.131 2013/09/03 20:54:03 pooka Exp $ +# $NetBSD: makesyscalls.sh,v 1.132 2013/09/03 21:28:24 pooka Exp $ # # Copyright (c) 1994, 1996, 2000 Christopher G. Demetriou # All rights reserved. @@ -256,6 +256,12 @@ NR == 1 { printf \t__weak_alias(nam,rump_enosys);\n rumpcalls printf #endif\n\n rumpcalls + printf #ifdef RUMP_KERNEL_IS_LIBC\n rumpcalls + printf #define rsys_aliases(what,where) \\\n rumpcalls + printf \t__strong_alias(what,where); \\\n rumpcalls + printf \t__strong_alias(_##what,where);\n rumpcalls + printf #else\n#define rsys_aliases(a,b)\n#endif\n\n rumpcalls + printf #if\tBYTE_ORDER == BIG_ENDIAN\n rumpcalls printf #define SPARG(p,k)\t((p)-k.be.datum)\n rumpcalls printf #else /* LITTLE_ENDIAN, I hope dearly */\n rumpcalls @@ -869,6 +875,8 @@ function putent(type, compatwrap) { printf(}\n) rumpcalls printf(rsys_define(rumpns_%s%s);\n, \ compatwrap_, funcname) rumpcalls + printf(rsys_aliases(%s%s,rump___sysimpl_%s);\n, \ + compatwrap_, funcalias, rumpfname) rumpcalls } $2 == STD || $2 == NODEF || $2 == NOARGS || $2 == INDIR \ @@ -940,6 +948,7 @@ END { printf(\t\tfd[1] = retval[1];\n\t}\n) rumpcalls printf(\treturn error ? -1 : 0;\n}\n) rumpcalls printf(rsys_define(rumpns_sys_pipe);\n) rumpcalls + printf rsys_aliases(pipe,rump_sys_pipe);\n rumpcalls } # print default rump syscall interfaces