Re: CVS commit: src/sys/arch/powerpc/oea
On Mon, Nov 15, 2010 at 02:48:29PM +0900, SODA Noriyuki wrote: Well, there is another thing which has to be considered. That is name space pollution. Header files which are exported to userland (for userland visible APIs) should not export random symbols. Only symbols which are defined as the interface of the header file are allowed to be exported. Indeed. Properly speaking though, headers that are exported to userland should define only the precise symbols that userland needs; kernel-only material should be kept elsewhere. We're a long way from that. Someday I'll clean it all up, but I think it had better wait until after we get version control that supports rename. In the meantime, wrapping in _KERNEL is the best we can do... -- David A. Holland dholl...@netbsd.org
Re: CVS commit: src/sys/arch/powerpc/oea
(moving this to tech-kern because it's the right place and per request) On Mon, Nov 15, 2010 at 11:24:21AM +0900, Masao Uebayashi wrote: Every header file should include the things it requires to compile. Therefore, there should in principle be no cases where a header file (or source file) needs to #include something it doesn't itself use. This clarifies my long-unanswered question, thanks! *bow* I've (re)built about 300 kernels in the last days. I've found: - sys/sysctl.h's struct kinfo_proc should be moved into sys/proc.h (I've done this locally). Otherwise all sysctl node providers includes sys/proc.h and uvm/uvm_extern.h. (This is where I started...) I'm not sure this is a good plan in the long run. Shouldn't it at some point be unhooked fully from the real proc structure? - sys/syscallargs.h should be split into pieces, otherwise all its users have to know unrelated types (sys/mount.h, sys/cpu.h). Since system calls don't in general pass structures by value, it shouldn't need most of those header files, just forward declarations of the structs. (this is, btw, one of the reasons to avoid silly typedefs) - sys/proc.h's tsleep(), wakeup(), and friends should be moved into some common header, because it's widely used API. sys/proc.h will be used only for struct proc related things. Given that this is a deprecated API in the long term I'm not sure it's worthwhile. -- David A. Holland dholl...@netbsd.org
Re: CVS commit: src/sys/arch/powerpc/oea
On Mon, Nov 15, 2010 at 08:50:34AM +, David Holland wrote: On Mon, Nov 15, 2010 at 02:48:29PM +0900, SODA Noriyuki wrote: Well, there is another thing which has to be considered. That is name space pollution. Header files which are exported to userland (for userland visible APIs) should not export random symbols. Only symbols which are defined as the interface of the header file are allowed to be exported. Indeed. Properly speaking though, headers that are exported to userland should define only the precise symbols that userland needs; kernel-only material should be kept elsewhere. One start would be to add a sys/proc_internal.h so that sys/proc can be reduced to only stuff that userspace and some kernel parts are really expected to use. David -- David Laight: da...@l8s.co.uk
Re: CVS commit: src/sys/arch/powerpc/oea
Hi, On Mon, Nov 15, 2010 at 5:41 PM, David Laight da...@l8s.co.uk wrote: On Mon, Nov 15, 2010 at 08:50:34AM +, David Holland wrote: On Mon, Nov 15, 2010 at 02:48:29PM +0900, SODA Noriyuki wrote: Well, there is another thing which has to be considered. That is name space pollution. Header files which are exported to userland (for userland visible APIs) should not export random symbols. Only symbols which are defined as the interface of the header file are allowed to be exported. Indeed. Properly speaking though, headers that are exported to userland should define only the precise symbols that userland needs; kernel-only material should be kept elsewhere. One start would be to add a sys/proc_internal.h so that sys/proc can be reduced to only stuff that userspace and some kernel parts are really expected to use. For the record, Linux kernels do sanitize their header before installation. One of the tools (unifdef) used still has a __IDSTRING(NetBSD, $NetBSD: unifdef.c,v 1.8 2000/07/03 02:51:36 matt Exp $); and __FBSDID($FreeBSD: /repoman/r/ncvs/src/usr.bin/unifdef/unifdef.c,v 1.20 2005/05/21 09:55:09 ru Exp $); so I guess it should already be in the tree, but maybe not the latest version. It is ran with -U__KERNEL__ by a headers install script, they wrote it in perl, but there it is not doing anything special sed(1) would not do. - Arnaud
Re: CVS commit: src/sys/arch/powerpc/oea
On Mon, Nov 15, 2010 at 11:24:21AM +0900, Masao Uebayashi wrote: On Sun, Nov 14, 2010 at 05:52:51AM +, David Holland wrote: On Sun, Nov 14, 2010 at 03:32:44AM +, Masao Uebayashi wrote: XXX What is the conclusion about direct vs. indirect #include from headers? Every header file should include the things it requires to compile. Therefore, there should in principle be no cases where a header file (or source file) needs to #include something it doesn't itself use. This clarifies my long-unanswered question, thanks! I've (re)built about 300 kernels in the last days. I've found: - sys/sysctl.h's struct kinfo_proc should be moved into sys/proc.h (I've done this locally). Otherwise all sysctl node providers includes sys/proc.h and uvm/uvm_extern.h. (This is where I started...) - sys/syscallargs.h should be split into pieces, otherwise all its users have to know unrelated types (sys/mount.h, sys/cpu.h). - sys/proc.h's tsleep(), wakeup(), and friends should be moved into some common header, because it's widely used API. sys/proc.h will be used only for struct proc related things. Another thing: - We should provide sysconf() for kernel modules (device drivers) too, otherwise we have to expose unnecessary symbols (uvmexp).
Re: CVS commit: src/sys/arch/powerpc/oea
On Tue, Nov 16, 2010 at 10:20:46AM +0900, Masao Uebayashi wrote: Another thing: - We should provide sysconf() for kernel modules (device drivers) too, otherwise we have to expose unnecessary symbols (uvmexp). Why not the complete sysctl tree? -- David A. Holland dholl...@netbsd.org
CVS commit: src/crypto/external/bsd/netpgp/dist/src/lib
Module Name:src Committed By: agc Date: Mon Nov 15 08:03:40 UTC 2010 Modified Files: src/crypto/external/bsd/netpgp/dist/src/lib: compress.c create.c netpgp.c packet-parse.c writer.c Log Message: Changes to help with netpgp key generation and interoperability: + use plain SHA1 for session key s2k negotiation + don't warn on some conditions when inflating (reading a compressed file) since the conditions don't hold for partial block lengths + prompt for a passphrase when generating a new key - used in the upcoming secret-sharing functionality for netpgp To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 \ src/crypto/external/bsd/netpgp/dist/src/lib/compress.c cvs rdiff -u -r1.37 -r1.38 \ src/crypto/external/bsd/netpgp/dist/src/lib/create.c cvs rdiff -u -r1.82 -r1.83 \ src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c cvs rdiff -u -r1.47 -r1.48 \ src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c cvs rdiff -u -r1.30 -r1.31 \ src/crypto/external/bsd/netpgp/dist/src/lib/writer.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/external/bsd/netpgp/dist/src/lib/compress.c diff -u src/crypto/external/bsd/netpgp/dist/src/lib/compress.c:1.20 src/crypto/external/bsd/netpgp/dist/src/lib/compress.c:1.21 --- src/crypto/external/bsd/netpgp/dist/src/lib/compress.c:1.20 Thu Nov 11 00:58:04 2010 +++ src/crypto/external/bsd/netpgp/dist/src/lib/compress.c Mon Nov 15 08:03:39 2010 @@ -57,7 +57,7 @@ #if defined(__NetBSD__) __COPYRIGHT(@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.); -__RCSID($NetBSD: compress.c,v 1.20 2010/11/11 00:58:04 agc Exp $); +__RCSID($NetBSD: compress.c,v 1.21 2010/11/15 08:03:39 agc Exp $); #endif #ifdef HAVE_ZLIB_H @@ -133,19 +133,11 @@ z-zstream.next_out == z-out[z-offset]) { return 0; } - if (pgp_get_debug_level(__FILE__)) { (void) fprintf(stderr, zlib_compressed_data_reader: length % PRIsize d\n, length); } - - if (z-region-readc == z-region-length) { - if (z-inflate_ret != Z_STREAM_END) { - PGP_ERROR(cbinfo-errors, PGP_E_P_DECOMPRESSION_ERROR, - Compressed data didn't end when region ended.); - } - } for (cc = 0 ; cc length ; cc += len) { if (z-out[z-offset] == z-zstream.next_out) { int ret; @@ -221,17 +213,10 @@ (void) fprintf(stderr, Weird type %d\n, bz-type); return 0; } - if (bz-inflate_ret == BZ_STREAM_END bz-bzstream.next_out == bz-out[bz-offset]) { return 0; } - if (bz-region-readc == bz-region-length) { - if (bz-inflate_ret != BZ_STREAM_END) { - PGP_ERROR(cbinfo-errors, PGP_E_P_DECOMPRESSION_ERROR, - Compressed data didn't end when region ended.); - } - } for (cc = 0 ; cc length ; cc += len) { if (bz-out[bz-offset] == bz-bzstream.next_out) { int ret; Index: src/crypto/external/bsd/netpgp/dist/src/lib/create.c diff -u src/crypto/external/bsd/netpgp/dist/src/lib/create.c:1.37 src/crypto/external/bsd/netpgp/dist/src/lib/create.c:1.38 --- src/crypto/external/bsd/netpgp/dist/src/lib/create.c:1.37 Sun Nov 7 08:39:59 2010 +++ src/crypto/external/bsd/netpgp/dist/src/lib/create.c Mon Nov 15 08:03:39 2010 @@ -57,7 +57,7 @@ #if defined(__NetBSD__) __COPYRIGHT(@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.); -__RCSID($NetBSD: create.c,v 1.37 2010/11/07 08:39:59 agc Exp $); +__RCSID($NetBSD: create.c,v 1.38 2010/11/15 08:03:39 agc Exp $); #endif #include sys/types.h @@ -285,7 +285,7 @@ pgp_hash_thash; unsigned done = 0; unsigned i = 0; - uint8_t hashed[PGP_SHA1_HASH_SIZE]; + uint8_t *hashed; uint8_t sesskey[CAST_KEY_LENGTH]; if (!write_pubkey_body(key-pubkey, output)) { @@ -360,15 +360,21 @@ /* RFC4880: section 3.7.1.1 and 3.7.1.2 */ for (done = 0, i = 0; done CAST_KEY_LENGTH; i++) { + unsigned hashsize; unsigned j; + unsigned needed; + unsigned size; uint8_t zero = 0; - int needed; - int size; + /* Hard-coded SHA1 for session key */ + pgp_hash_any(hash, PGP_HASH_SHA1); + hashsize = pgp_hash_size(key-hash_alg); needed = CAST_KEY_LENGTH - done; - size = MIN(needed, PGP_SHA1_HASH_SIZE); - - pgp_hash_any(hash, key-hash_alg); + size = MIN(needed, hashsize); + if ((hashed = calloc(1, hashsize)) == NULL) { +(void) fprintf(stderr, write_seckey_body: bad alloc\n); +return 0; + } if (!hash.init(hash)) { (void) fprintf(stderr, write_seckey_body: bad alloc\n); return 0; @@ -396,7 +402,7 @@ * if more in hash than is needed by session key, use * the leftmost octets */ - (void) memcpy(sesskey[i * PGP_SHA1_HASH_SIZE], + (void) memcpy(sesskey[i * hashsize], hashed, (unsigned)size); done += (unsigned)size; if (done CAST_KEY_LENGTH) { @@ -435,13 +441,9 @@ pgp_push_enc_crypt(output, crypted); switch
CVS commit: src/crypto/external/bsd/netpgp/dist/src/lib
Module Name:src Committed By: agc Date: Mon Nov 15 08:27:40 UTC 2010 Modified Files: src/crypto/external/bsd/netpgp/dist/src/lib: netpgp.c Log Message: Use a regular expression to match the various ASCII-armoured headers we may encounter - fixes PR 44074 from Peter Pentchev in a different way. To generate a diff of this commit: cvs rdiff -u -r1.83 -r1.84 \ src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c diff -u src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c:1.83 src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c:1.84 --- src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c:1.83 Mon Nov 15 08:03:39 2010 +++ src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c Mon Nov 15 08:27:40 2010 @@ -34,7 +34,7 @@ #if defined(__NetBSD__) __COPYRIGHT(@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.); -__RCSID($NetBSD: netpgp.c,v 1.83 2010/11/15 08:03:39 agc Exp $); +__RCSID($NetBSD: netpgp.c,v 1.84 2010/11/15 08:27:40 agc Exp $); #endif #include sys/types.h @@ -462,23 +462,32 @@ static unsigned isarmoured(pgp_io_t *io, const char *f, const void *memory, const char *text) { + regmatch_t matches[10]; unsigned armoured; + regex_t r; FILE *fp; char buf[BUFSIZ]; armoured = 0; + (void) regcomp(r, text, REG_EXTENDED); if (f) { if ((fp = fopen(f, r)) == NULL) { (void) fprintf(io-errs, isarmoured: can't open '%s'\n, f); + regfree(r); return 0; } if (fgets(buf, (int)sizeof(buf), fp) != NULL) { - armoured = (strncmp(buf, text, strlen(text)) == 0); + if (regexec(r, buf, 10, matches, 0) == 0) { +armoured = 1; + } } (void) fclose(fp); } else { - armoured = (strncmp(memory, text, strlen(text)) == 0); + if (regexec(r, memory, 10, matches, 0) == 0) { + armoured = 1; + } } + regfree(r); return armoured; } @@ -1341,7 +1350,7 @@ return ret; } -#define ARMOR_SIG_HEAD -BEGIN PGP SIGNATURE-\r\n +#define ARMOR_SIG_HEAD -BEGIN PGP (SIGNATURE|SIGNED MESSAGE)- /* verify a file */ int
CVS commit: src/doc
Module Name:src Committed By: uebayasi Date: Mon Nov 15 08:35:52 UTC 2010 Modified Files: src/doc: BRANCHES Log Message: uebayasi-xip: update. To generate a diff of this commit: cvs rdiff -u -r1.298 -r1.299 src/doc/BRANCHES Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/BRANCHES diff -u src/doc/BRANCHES:1.298 src/doc/BRANCHES:1.299 --- src/doc/BRANCHES:1.298 Sat Nov 6 09:21:09 2010 +++ src/doc/BRANCHES Mon Nov 15 08:35:52 2010 @@ -1,4 +1,4 @@ -# $NetBSD: BRANCHES,v 1.298 2010/11/06 09:21:09 uebayasi Exp $ +# $NetBSD: BRANCHES,v 1.299 2010/11/15 08:35:52 uebayasi Exp $ # # This file contains a list of branches that exist in the NetBSD CVS # tree and their current state. @@ -1205,13 +1205,28 @@ Status: Active Start Date: 8 February 2010 End Date: -Base Tag: uebayasi-xip-base4 (2010-11-06 UTC) +Base Tag: uebayasi-xip-base5 (2010-11-09 UTC) Maintainer: Masao Uebayashi uebay...@netbsd.org -Scope: src/include src/sbin/mount src/sbin/mount_ffs - src/share/man/man4 src/share/man/man9 src/sys +Scope: src/external/gpl3/binutils/usr.sbin/mdsetimage/mdsetimage.8 + src/include + src/sbin/mount + src/sbin/mount_ffs + src/share/man/man4 src/share/man/man5/statvfs.5 - src/external/gpl3/binutils/usr.sbin/mdsetimage - src/usr.sbin/mdsetimage + src/share/man/man9 + src/sys/arch + src/sys/common/pmap + src/sys/conf + src/sys/dev/flash.c + src/sys/dev/flashvar.h + src/sys/dev/xmd.c + src/sys/kern/vfs_syscalls.c + src/sys/miscfs/genfs/genfs_io.c + src/sys/miscfs/specfs/specdev.h + src/sys/sys + src/sys/ufs/ffs/ffs_vfsops.c + src/sys/uvm + src/usr.sbin/mdsetimage/mdsetimage.8 Notes: Goals: - Clean up oddities in fault handler - Add a notion of device page
CVS commit: src/crypto/external/bsd/netpgp/dist/src/lib
Module Name:src Committed By: agc Date: Mon Nov 15 08:50:32 UTC 2010 Modified Files: src/crypto/external/bsd/netpgp/dist/src/lib: crypto.c keyring.c packet-parse.c packet-print.c packet-show.c reader.c writer.c Log Message: Don't prefix function names with pgp_ if the functions are static. To generate a diff of this commit: cvs rdiff -u -r1.32 -r1.33 \ src/crypto/external/bsd/netpgp/dist/src/lib/crypto.c cvs rdiff -u -r1.48 -r1.49 \ src/crypto/external/bsd/netpgp/dist/src/lib/keyring.c \ src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c cvs rdiff -u -r1.39 -r1.40 \ src/crypto/external/bsd/netpgp/dist/src/lib/packet-print.c cvs rdiff -u -r1.19 -r1.20 \ src/crypto/external/bsd/netpgp/dist/src/lib/packet-show.c cvs rdiff -u -r1.45 -r1.46 \ src/crypto/external/bsd/netpgp/dist/src/lib/reader.c cvs rdiff -u -r1.31 -r1.32 \ src/crypto/external/bsd/netpgp/dist/src/lib/writer.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/external/bsd/netpgp/dist/src/lib/crypto.c diff -u src/crypto/external/bsd/netpgp/dist/src/lib/crypto.c:1.32 src/crypto/external/bsd/netpgp/dist/src/lib/crypto.c:1.33 --- src/crypto/external/bsd/netpgp/dist/src/lib/crypto.c:1.32 Sun Nov 7 08:39:59 2010 +++ src/crypto/external/bsd/netpgp/dist/src/lib/crypto.c Mon Nov 15 08:50:32 2010 @@ -54,7 +54,7 @@ #if defined(__NetBSD__) __COPYRIGHT(@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.); -__RCSID($NetBSD: crypto.c,v 1.32 2010/11/07 08:39:59 agc Exp $); +__RCSID($NetBSD: crypto.c,v 1.33 2010/11/15 08:50:32 agc Exp $); #endif #include sys/types.h @@ -316,7 +316,7 @@ case PGP_PTAG_CT_SE_DATA_BODY: case PGP_PTAG_CT_SE_DATA_HEADER: /* Ignore these packets */ - /* They're handled in pgp_parse_packet() */ + /* They're handled in parse_packet() */ /* and nothing else needs to be done */ break; Index: src/crypto/external/bsd/netpgp/dist/src/lib/keyring.c diff -u src/crypto/external/bsd/netpgp/dist/src/lib/keyring.c:1.48 src/crypto/external/bsd/netpgp/dist/src/lib/keyring.c:1.49 --- src/crypto/external/bsd/netpgp/dist/src/lib/keyring.c:1.48 Sun Nov 7 08:39:59 2010 +++ src/crypto/external/bsd/netpgp/dist/src/lib/keyring.c Mon Nov 15 08:50:32 2010 @@ -57,7 +57,7 @@ #if defined(__NetBSD__) __COPYRIGHT(@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.); -__RCSID($NetBSD: keyring.c,v 1.48 2010/11/07 08:39:59 agc Exp $); +__RCSID($NetBSD: keyring.c,v 1.49 2010/11/15 08:50:32 agc Exp $); #endif #ifdef HAVE_FCNTL_H @@ -398,7 +398,7 @@ \note If dst already has a userid, it will be freed. */ static uint8_t * -pgp_copy_userid(uint8_t **dst, const uint8_t *src) +copy_userid(uint8_t **dst, const uint8_t *src) { size_t len; @@ -407,7 +407,7 @@ free(*dst); } if ((*dst = calloc(1, len + 1)) == NULL) { - (void) fprintf(stderr, pgp_copy_userid: bad alloc\n); + (void) fprintf(stderr, copy_userid: bad alloc\n); } else { (void) memcpy(*dst, src, len); } @@ -423,13 +423,13 @@ \note If dst already has a packet, it will be freed. */ static pgp_subpacket_t * -pgp_copy_packet(pgp_subpacket_t *dst, const pgp_subpacket_t *src) +copy_packet(pgp_subpacket_t *dst, const pgp_subpacket_t *src) { if (dst-raw) { free(dst-raw); } if ((dst-raw = calloc(1, src-length)) == NULL) { - (void) fprintf(stderr, pgp_copy_packet: bad alloc\n); + (void) fprintf(stderr, copy_packet: bad alloc\n); } else { dst-length = src-length; (void) memcpy(dst-raw, src-raw, src-length); @@ -454,7 +454,7 @@ uidp = key-uids[key-uidc++]; *uidp = NULL; /* now copy it */ - return pgp_copy_userid(uidp, userid); + return copy_userid(uidp, userid); } void print_packet_hex(const pgp_subpacket_t *pkt); @@ -477,7 +477,7 @@ subpktp-length = 0; subpktp-raw = NULL; /* now copy it */ - return pgp_copy_packet(subpktp, packet); + return copy_packet(subpktp, packet); } /** Index: src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c diff -u src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c:1.48 src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c:1.49 --- src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c:1.48 Mon Nov 15 08:03:40 2010 +++ src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c Mon Nov 15 08:50:32 2010 @@ -58,7 +58,7 @@ #if defined(__NetBSD__) __COPYRIGHT(@(#) Copyright (c) 2009 The NetBSD Foundation, Inc. All rights reserved.); -__RCSID($NetBSD: packet-parse.c,v 1.48 2010/11/15 08:03:40 agc Exp $); +__RCSID($NetBSD: packet-parse.c,v 1.49 2010/11/15 08:50:32 agc Exp $); #endif #include sys/types.h @@ -871,7 +871,7 @@ \brief Free allocated memory */ static void -pgp_headers_free(pgp_headers_t *headers) +headers_free(pgp_headers_t *headers) { unsignedn; @@ -899,7 +899,7 @@ \brief Free allocated memory */ static void
CVS commit: src/sys/arch/arm/pic
Module Name:src Committed By: bsh Date: Mon Nov 15 09:25:58 UTC 2010 Modified Files: src/sys/arch/arm/pic: picvar.h Log Message: fix compile error about missing evcnt definition. picvar.h is now included very early because of uebayashi's change to sys/param.h. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/pic/picvar.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/arch/arm/pic/picvar.h diff -u src/sys/arch/arm/pic/picvar.h:1.4 src/sys/arch/arm/pic/picvar.h:1.5 --- src/sys/arch/arm/pic/picvar.h:1.4 Tue Dec 30 05:43:14 2008 +++ src/sys/arch/arm/pic/picvar.h Mon Nov 15 09:25:58 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: picvar.h,v 1.4 2008/12/30 05:43:14 matt Exp $ */ +/* $NetBSD: picvar.h,v 1.5 2010/11/15 09:25:58 bsh Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. @@ -57,6 +57,8 @@ #ifdef _INTR_PRIVATE +#include sys/evcnt.h + #ifndef PIC_MAXPICS #define PIC_MAXPICS 32 #endif
CVS commit: src/sys/arch/arm/omap
Module Name:src Committed By: bsh Date: Mon Nov 15 09:34:28 UTC 2010 Modified Files: src/sys/arch/arm/omap: omap2_icu.c omap2_intr.h Log Message: don't include arm/cpu.h which requires SOFTINT_COUNT before sys/intr.h is fully included. This change makes Beagleboard kernel compile again after uebayashi's change to sys/param.h. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/omap/omap2_icu.c \ src/sys/arch/arm/omap/omap2_intr.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/arch/arm/omap/omap2_icu.c diff -u src/sys/arch/arm/omap/omap2_icu.c:1.5 src/sys/arch/arm/omap/omap2_icu.c:1.6 --- src/sys/arch/arm/omap/omap2_icu.c:1.5 Wed Oct 22 10:45:47 2008 +++ src/sys/arch/arm/omap/omap2_icu.c Mon Nov 15 09:34:28 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: omap2_icu.c,v 1.5 2008/10/22 10:45:47 matt Exp $ */ +/* $NetBSD: omap2_icu.c,v 1.6 2010/11/15 09:34:28 bsh Exp $ */ /* * Define the SDP2430 specific information and then include the generic OMAP * interrupt header. @@ -30,10 +30,11 @@ #define _INTR_PRIVATE #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: omap2_icu.c,v 1.5 2008/10/22 10:45:47 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: omap2_icu.c,v 1.6 2010/11/15 09:34:28 bsh Exp $); #include sys/param.h #include sys/evcnt.h +#include sys/device.h #include uvm/uvm_extern.h Index: src/sys/arch/arm/omap/omap2_intr.h diff -u src/sys/arch/arm/omap/omap2_intr.h:1.5 src/sys/arch/arm/omap/omap2_intr.h:1.6 --- src/sys/arch/arm/omap/omap2_intr.h:1.5 Sat Aug 28 04:06:40 2010 +++ src/sys/arch/arm/omap/omap2_intr.h Mon Nov 15 09:34:28 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: omap2_intr.h,v 1.5 2010/08/28 04:06:40 kiyohara Exp $ */ +/* $NetBSD: omap2_intr.h,v 1.6 2010/11/15 09:34:28 bsh Exp $ */ /* * Define the SDP2430 specific information and then include the generic OMAP @@ -34,7 +34,6 @@ #ifndef _LOCORE -#include arm/cpu.h #include arm/armreg.h #include arm/cpufunc.h
CVS commit: src/sys/arch/x86/include
Module Name:src Committed By: cegger Date: Mon Nov 15 11:58:10 UTC 2010 Modified Files: src/sys/arch/x86/include: i82489reg.h Log Message: add interrupt EAPIC register definitions To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/x86/include/i82489reg.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/arch/x86/include/i82489reg.h diff -u src/sys/arch/x86/include/i82489reg.h:1.9 src/sys/arch/x86/include/i82489reg.h:1.10 --- src/sys/arch/x86/include/i82489reg.h:1.9 Sat Jan 9 20:50:11 2010 +++ src/sys/arch/x86/include/i82489reg.h Mon Nov 15 11:58:09 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: i82489reg.h,v 1.9 2010/01/09 20:50:11 cegger Exp $ */ +/* $NetBSD: i82489reg.h,v 1.10 2010/11/15 11:58:09 cegger Exp $ */ /*- * Copyright (c) 1998, 2008 The NetBSD Foundation, Inc. @@ -143,6 +143,48 @@ #define LAPIC_IRQ_MASK(i) (1 ((i) + 1)) +/* Extended APIC registers, valid when CPUID features4 EAPIC is present */ +#define LEAPIC_FR 0x400/* Feature register */ +# define LEAPIC_FR_ELC __BITS(23,16) /* Ext. Lvt Count RO */ +# define LEAPIC_FR_EIDCAP __BIT(2) /* Ext. Apic ID Cap. RO */ +# define LEAPIC_FR_SEIOCAP __BIT(1) /* Specific EOI Cap. RO */ +# define LEAPIC_FR_IERCAP __BIT(0) /* Intr. Enable Reg. RO */ + +#define LEAPIC_CR 0x410 /* Control Register */ +# define LEAPIC_CR_EID_ENABLE __BIT(2) /* Ext. Apic ID enable */ +# define LEAPIC_CR_SEOI_ENABLE __BIT(1) /* Specific EOI enable */ +# define LEAPIC_CR_IER_ENABLE __BIT(0) /* Enable writes to IER */ + +#define LEAPIC_SEOIR 0x420 /* Specific EOI Register */ +# define LEAPIC_SEOI_VEC __BITS(7,0) + +#define LEAPIC_IER_480 0x480 /* Interrupts 0-31 */ +#define LEAPIC_IER_490 0x490 /* Interrupts 32-63 */ +#define LEAPIC_IER_4B0 0x4B0 /* Interrupts 64-95 */ +#define LEAPIC_IER_4C0 0x4C0 /* Interrupts 96-127 */ +#define LEAPIC_IER_4D0 0x4D0 /* Interrupts 128-159 */ +#define LEAPIC_IER_4E0 0x4E0 /* Interrupts 160-191 */ +#define LEAPIC_IER_4F0 0x4F0 /* Interrupts 192-255 */ + +/* Extended Local Vector Table Entries */ +#define LEAPIC_LVTR_500 0x500 +#define LEAPIC_LVTR_504 0x504 +#define LEAPIC_LVTR_508 0x508 +#define LEAPIC_LVTR_50C 0x50C +#define LEAPIC_LVTR_510 0x510 +#define LEAPIC_LVTR_514 0x514 +#define LEAPIC_LVTR_518 0x518 +#define LEAPIC_LVTR_51C 0x51C +#define LEAPIC_LVTR_520 0x520 +#define LEAPIC_LVTR_524 0x524 +#define LEAPIC_LVTR_528 0x528 +#define LEAPIC_LVTR_52C 0x52C +#define LEAPIC_LVTR_530 0x530 +# define LEAPIC_LVTR_MASK __BIT(16) /* interrupt masked RW */ +# define LEAPIC_LVTR_DSTAT __BIT(12) /* delivery state RO */ +# define LEAPIC_LVTR_MSGTYPE __BITS(10,8) /* Message type */ +# define LEAPIC_LVTR_VEC __BITS(7,0) /* the intr. vector */ + /* * Model specific registers */
CVS commit: src/distrib/sets/lists/xserver
Module Name:src Committed By: njoly Date: Mon Nov 15 12:23:06 UTC 2010 Modified Files: src/distrib/sets/lists/xserver: md.macppc md.ofppc md.sgimips md.sparc md.sparc64 Log Message: Remove unneeded xfree/xorg dga(1) entries from xserver md lists. To generate a diff of this commit: cvs rdiff -u -r1.56 -r1.57 src/distrib/sets/lists/xserver/md.macppc cvs rdiff -u -r1.8 -r1.9 src/distrib/sets/lists/xserver/md.ofppc cvs rdiff -u -r1.38 -r1.39 src/distrib/sets/lists/xserver/md.sgimips cvs rdiff -u -r1.47 -r1.48 src/distrib/sets/lists/xserver/md.sparc cvs rdiff -u -r1.44 -r1.45 src/distrib/sets/lists/xserver/md.sparc64 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/xserver/md.macppc diff -u src/distrib/sets/lists/xserver/md.macppc:1.56 src/distrib/sets/lists/xserver/md.macppc:1.57 --- src/distrib/sets/lists/xserver/md.macppc:1.56 Sat Jun 19 18:10:56 2010 +++ src/distrib/sets/lists/xserver/md.macppc Mon Nov 15 12:23:06 2010 @@ -1,8 +1,7 @@ -# $NetBSD: md.macppc,v 1.56 2010/06/19 18:10:56 tsutsui Exp $ +# $NetBSD: md.macppc,v 1.57 2010/11/15 12:23:06 njoly Exp $ ./usr/X11R6/bin/X -unknown- x11 ./usr/X11R6/bin/XFree86 -unknown- x11 ./usr/X11R6/bin/Xmacppc -unknown- x11 -./usr/X11R6/bin/dga -unknown- x11 ./usr/X11R6/bin/gtf -unknown- x11 ./usr/X11R6/bin/kbd_mode-unknown- x11 ./usr/X11R6/bin/mmapr -unknown- x11 @@ -177,7 +176,6 @@ ./usr/X11R6/lib/modules/libxf8_16bpp.a -unknown- x11 ./usr/X11R6/lib/modules/libxf8_32bpp.a -unknown- x11 ./usr/X11R6/man/cat1/XFree86.0-unknown- .cat,x11 -./usr/X11R6/man/cat1/dga.0-unknown- .cat,x11 ./usr/X11R6/man/cat1/gtf.0-unknown- .cat,x11 ./usr/X11R6/man/cat1/kbd_mode.0-unknown- .cat,x11 ./usr/X11R6/man/cat1/pcitweak.0-unknown- .cat,x11 @@ -220,7 +218,6 @@ ./usr/X11R6/man/cat4/wsfb.0-unknown- .cat,x11 ./usr/X11R6/man/cat5/XF86Config.0 -unknown- .cat,x11 ./usr/X11R6/man/html1/XFree86.html -unknown- html,x11 -./usr/X11R6/man/html1/dga.html-unknown- html,x11 ./usr/X11R6/man/html1/gtf.html-unknown- html,x11 ./usr/X11R6/man/html1/kbd_mode.html -unknown- html,x11 ./usr/X11R6/man/html1/pcitweak.html -unknown- html,x11 @@ -263,7 +260,6 @@ ./usr/X11R6/man/html4/wsfb.html-unknown- html,x11 ./usr/X11R6/man/html5/XF86Config.html -unknown- html,x11 ./usr/X11R6/man/man1/XFree86.1-unknown- .man,x11 -./usr/X11R6/man/man1/dga.1-unknown- .man,x11 ./usr/X11R6/man/man1/gtf.1-unknown- .man,x11 ./usr/X11R6/man/man1/kbd_mode.1-unknown- .man,x11 ./usr/X11R6/man/man1/pcitweak.1-unknown- .man,x11 @@ -308,7 +304,6 @@ ./usr/X11R7/bin/X -unknown- xorg ./usr/X11R7/bin/Xorg -unknown- xorg ./usr/X11R7/bin/cvt -unknown- xorg -./usr/X11R7/bin/dga -unknown- xorg ./usr/X11R7/bin/gtf -unknown- xorg ./usr/X11R7/bin/pcitweak-unknown- obsolete ./usr/X11R7/bin/scanpci -unknown- obsolete @@ -501,7 +496,6 @@ ./usr/X11R7/lib/modules/libxf8_32bpp_pic.a -unknown- obsolete ./usr/X11R7/man/cat1/Xorg.0-unknown- .cat,xorg ./usr/X11R7/man/cat1/cvt.0-unknown- .cat,xorg -./usr/X11R7/man/cat1/dga.0-unknown- .cat,xorg ./usr/X11R7/man/cat1/gtf.0-unknown- .cat,xorg ./usr/X11R7/man/cat1/pcitweak.0-unknown- obsolete ./usr/X11R7/man/cat1/scanpci.0-unknown- obsolete @@ -523,7 +517,6 @@ ./usr/X11R7/man/cat5/xorg.conf.0 -unknown- .cat,xorg ./usr/X11R7/man/html1/Xorg.html-unknown- html,xorg ./usr/X11R7/man/html1/cvt.html-unknown- html,xorg -./usr/X11R7/man/html1/dga.html-unknown- html,xorg ./usr/X11R7/man/html1/gtf.html-unknown- html,xorg ./usr/X11R7/man/html1/pcitweak.html -unknown- obsolete ./usr/X11R7/man/html1/scanpci.html -unknown- obsolete @@ -545,7 +538,6 @@ ./usr/X11R7/man/html5/xorg.conf.html -unknown- html,xorg ./usr/X11R7/man/man1/Xorg.1-unknown- .man,xorg ./usr/X11R7/man/man1/cvt.1-unknown- .man,xorg -./usr/X11R7/man/man1/dga.1-unknown- .man,xorg ./usr/X11R7/man/man1/gtf.1-unknown- .man,xorg ./usr/X11R7/man/man1/pcitweak.1-unknown- obsolete ./usr/X11R7/man/man1/scanpci.1-unknown- obsolete Index: src/distrib/sets/lists/xserver/md.ofppc diff -u src/distrib/sets/lists/xserver/md.ofppc:1.8 src/distrib/sets/lists/xserver/md.ofppc:1.9 --- src/distrib/sets/lists/xserver/md.ofppc:1.8 Fri Jun 12 01:55:59 2009 +++ src/distrib/sets/lists/xserver/md.ofppc Mon Nov 15 12:23:06 2010 @@ -1,7 +1,6 @@ -# $NetBSD: md.ofppc,v 1.8 2009/06/12 01:55:59 mrg Exp $ +# $NetBSD: md.ofppc,v 1.9 2010/11/15 12:23:06 njoly Exp $ ./usr/X11R6/bin/X -unknown- x11 ./usr/X11R6/bin/XFree86 -unknown- x11 -./usr/X11R6/bin/dga -unknown- x11 ./usr/X11R6/bin/gtf -unknown- x11 ./usr/X11R6/bin/kbd_mode-unknown- x11 ./usr/X11R6/bin/mmapr -unknown- x11 @@ -178,7 +177,6 @@ ./usr/X11R6/lib/modules/libxf8_16bpp.a -unknown- x11
CVS commit: src/distrib/sets/lists/comp
Module Name:src Committed By: njoly Date: Mon Nov 15 12:26:36 UTC 2010 Modified Files: src/distrib/sets/lists/comp: md.ofppc Log Message: +ofctl.debug To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/distrib/sets/lists/comp/md.ofppc 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/comp/md.ofppc diff -u src/distrib/sets/lists/comp/md.ofppc:1.10 src/distrib/sets/lists/comp/md.ofppc:1.11 --- src/distrib/sets/lists/comp/md.ofppc:1.10 Tue Mar 2 21:54:06 2010 +++ src/distrib/sets/lists/comp/md.ofppc Mon Nov 15 12:26:36 2010 @@ -1,4 +1,4 @@ -# $NetBSD: md.ofppc,v 1.10 2010/03/02 21:54:06 matt Exp $ +# $NetBSD: md.ofppc,v 1.11 2010/11/15 12:26:36 njoly Exp $ ./usr/include/ieeefp.hcomp-c-include ./usr/include/ofppccomp-c-include ./usr/include/ofppc/_G_config.h comp-obsolete obsolete @@ -54,3 +54,4 @@ ./usr/include/ofppc/varargs.h comp-c-include ./usr/include/ofppc/vmparam.h comp-c-include ./usr/include/ofppc/wchar_limits.h comp-c-include +./usr/libdata/debug/usr/sbin/ofctl.debug comp-sysutil-debug debug
CVS commit: src/doc
Module Name:src Committed By: uebayasi Date: Mon Nov 15 14:40:36 UTC 2010 Modified Files: src/doc: BRANCHES Log Message: uebayasi-xip: rebase. To generate a diff of this commit: cvs rdiff -u -r1.299 -r1.300 src/doc/BRANCHES Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/BRANCHES diff -u src/doc/BRANCHES:1.299 src/doc/BRANCHES:1.300 --- src/doc/BRANCHES:1.299 Mon Nov 15 08:35:52 2010 +++ src/doc/BRANCHES Mon Nov 15 14:40:36 2010 @@ -1,4 +1,4 @@ -# $NetBSD: BRANCHES,v 1.299 2010/11/15 08:35:52 uebayasi Exp $ +# $NetBSD: BRANCHES,v 1.300 2010/11/15 14:40:36 uebayasi Exp $ # # This file contains a list of branches that exist in the NetBSD CVS # tree and their current state. @@ -1205,7 +1205,7 @@ Status: Active Start Date: 8 February 2010 End Date: -Base Tag: uebayasi-xip-base5 (2010-11-09 UTC) +Base Tag: uebayasi-xip-base6 (2010-11-15 UTC) Maintainer: Masao Uebayashi uebay...@netbsd.org Scope: src/external/gpl3/binutils/usr.sbin/mdsetimage/mdsetimage.8 src/include
CVS commit: [uebayasi-xip] src
Module Name:src Committed By: uebayasi Date: Mon Nov 15 15:11:54 UTC 2010 Modified Files: src/share/man/man9 [uebayasi-xip]: pmap.9 src/sys/arch/acorn26/acorn26 [uebayasi-xip]: mem.c pmap.c src/sys/arch/alpha/alpha [uebayasi-xip]: mem.c pmap.c src/sys/arch/amd64/amd64 [uebayasi-xip]: mem.c src/sys/arch/arm/arm32 [uebayasi-xip]: mem.c pmap.c src/sys/uvm [uebayasi-xip]: files.uvm uvm_pmap.h Removed Files: src/sys/common/pmap [uebayasi-xip]: pmap_common.c src/sys/dev [uebayasi-xip]: xmd.c Log Message: Revert xmd(4). To generate a diff of this commit: cvs rdiff -u -r1.42.2.2 -r1.42.2.3 src/share/man/man9/pmap.9 cvs rdiff -u -r1.14.2.1 -r1.14.2.2 src/sys/arch/acorn26/acorn26/mem.c cvs rdiff -u -r1.30.2.5 -r1.30.2.6 src/sys/arch/acorn26/acorn26/pmap.c cvs rdiff -u -r1.40.2.1 -r1.40.2.2 src/sys/arch/alpha/alpha/mem.c cvs rdiff -u -r1.252.2.9 -r1.252.2.10 src/sys/arch/alpha/alpha/pmap.c cvs rdiff -u -r1.19.2.1 -r1.19.2.2 src/sys/arch/amd64/amd64/mem.c cvs rdiff -u -r1.26.6.7 -r1.26.6.8 src/sys/arch/arm/arm32/mem.c cvs rdiff -u -r1.211.2.22 -r1.211.2.23 src/sys/arch/arm/arm32/pmap.c cvs rdiff -u -r1.1.2.2 -r0 src/sys/common/pmap/pmap_common.c cvs rdiff -u -r1.1.2.6 -r0 src/sys/dev/xmd.c cvs rdiff -u -r1.16.2.2 -r1.16.2.3 src/sys/uvm/files.uvm cvs rdiff -u -r1.32.2.6 -r1.32.2.7 src/sys/uvm/uvm_pmap.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man9/pmap.9 diff -u src/share/man/man9/pmap.9:1.42.2.2 src/share/man/man9/pmap.9:1.42.2.3 --- src/share/man/man9/pmap.9:1.42.2.2 Sat Oct 30 08:41:14 2010 +++ src/share/man/man9/pmap.9 Mon Nov 15 15:11:52 2010 @@ -1,4 +1,4 @@ -.\ $NetBSD: pmap.9,v 1.42.2.2 2010/10/30 08:41:14 uebayasi Exp $ +.\ $NetBSD: pmap.9,v 1.42.2.3 2010/11/15 15:11:52 uebayasi Exp $ .\ .\ Copyright (c) 2000, 2001, 2002 The NetBSD Foundation, Inc. .\ All rights reserved. @@ -27,7 +27,7 @@ .\ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\ POSSIBILITY OF SUCH DAMAGE. .\ -.Dd October 30, 2010 +.Dd November 4, 2009 .Dt PMAP 9 .Os .Sh NAME @@ -69,12 +69,6 @@ .Fn pmap_protect pmap_t pmap vaddr_t sva vaddr_t eva vm_prot_t prot .Ft void .Fn pmap_unwire pmap_t pmap vaddr_t va -.Ft void * -.Fn pmap_physload_device vaddr_t addr off_t off int prot int flags -.Ft void -.Fn pmap_unphysload_device void *phys -.Ft paddr_t -.Fn pmap_mmap vaddr_t addr off_t off .Ft bool .Fn pmap_extract pmap_t pmap vaddr_t va paddr_t *pap .Ft void @@ -600,35 +594,6 @@ .Dq wired attribute on the mapping for virtual address .Fa va . -.It void * Fn pmap_physload_device vaddr_t addr off_t off \ -int prot int flags -This function registers a kernel virtual address region of system -memory described by -.Fa addr -and -.Fa off -as a physical device memory segment like a NOR FlashROM, -and return a cookie pointer to the registered segment. -The registered region will be mapped into user address space. -.It void Fn pmap_physunload_device void *phys -Free a physical segment previously allocated by -.Fn pmap_physload_device 9 . -.It paddr_t Fn pmap_mmap vaddr_t addr off_t off -This function converts a given kernel virtual address described by -.Fa addr -and -.Fa off -to a physical mmap cookie. -This interface is only used by machine-dependent memory devices, -.Xr mem 4 -and -.Xr xmd 4 , -to map part of kernel memory to user address spaces. -.Pp -Note that the -.Fn pmap_mmap -cares only addresses. -Callers are respensible to check protection. .It bool Fn pmap_extract pmap_t pmap vaddr_t va paddr_t *pap This function extracts a mapping from the specified physical map. It serves two purposes: to determine if a mapping exists for the specified Index: src/sys/arch/acorn26/acorn26/mem.c diff -u src/sys/arch/acorn26/acorn26/mem.c:1.14.2.1 src/sys/arch/acorn26/acorn26/mem.c:1.14.2.2 --- src/sys/arch/acorn26/acorn26/mem.c:1.14.2.1 Sat Oct 30 08:41:05 2010 +++ src/sys/arch/acorn26/acorn26/mem.c Mon Nov 15 15:11:52 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: mem.c,v 1.14.2.1 2010/10/30 08:41:05 uebayasi Exp $ */ +/* $NetBSD: mem.c,v 1.14.2.2 2010/11/15 15:11:52 uebayasi Exp $ */ /* * Copyright (c) 1982, 1986, 1990, 1993 @@ -73,7 +73,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: mem.c,v 1.14.2.1 2010/10/30 08:41:05 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: mem.c,v 1.14.2.2 2010/11/15 15:11:52 uebayasi Exp $); #ifdef _KERNEL_OPT #include opt_compat_netbsd.h @@ -212,9 +212,7 @@ /* XXX This may botch our cacheing assumptions. Do we care? */ ppn = atop(off); - KASSERT(ppn = 0); - if (ppn = physmem) - return -1; - - return pmap_mmap(0, off); + if (ppn = 0 ppn physmem) + return ppn; + return -1; } Index: src/sys/arch/acorn26/acorn26/pmap.c diff -u src/sys/arch/acorn26/acorn26/pmap.c:1.30.2.5 src/sys/arch/acorn26/acorn26/pmap.c:1.30.2.6 --- src/sys/arch/acorn26/acorn26/pmap.c:1.30.2.5 Sat Oct 30
CVS commit: src/lib/librumpuser
Module Name:src Committed By: pooka Date: Mon Nov 15 15:23:32 UTC 2010 Modified Files: src/lib/librumpuser: rumpuser.c rumpuser_int.h rumpuser_net.c Log Message: Make int *error and optional parameter (i.e. it can be NULL). Sometimes the caller just doesn't care which errno close() might throw. To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/lib/librumpuser/rumpuser.c cvs rdiff -u -r1.3 -r1.4 src/lib/librumpuser/rumpuser_int.h cvs rdiff -u -r1.1 -r1.2 src/lib/librumpuser/rumpuser_net.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/librumpuser/rumpuser.c diff -u src/lib/librumpuser/rumpuser.c:1.9 src/lib/librumpuser/rumpuser.c:1.10 --- src/lib/librumpuser/rumpuser.c:1.9 Wed Aug 11 10:25:59 2010 +++ src/lib/librumpuser/rumpuser.c Mon Nov 15 15:23:32 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: rumpuser.c,v 1.9 2010/08/11 10:25:59 pooka Exp $ */ +/* $NetBSD: rumpuser.c,v 1.10 2010/11/15 15:23:32 pooka Exp $ */ /* * Copyright (c) 2007-2010 Antti Kantee. All Rights Reserved. @@ -27,7 +27,7 @@ #include sys/cdefs.h #if !defined(lint) -__RCSID($NetBSD: rumpuser.c,v 1.9 2010/08/11 10:25:59 pooka Exp $); +__RCSID($NetBSD: rumpuser.c,v 1.10 2010/11/15 15:23:32 pooka Exp $); #endif /* !lint */ /* thank the maker for this */ @@ -82,7 +82,7 @@ int needsdev = 0, rv = 0, ft; if (stat(path, sb) == -1) { - *error = errno; + seterror(errno); return -1; } @@ -129,7 +129,7 @@ fd = open(path, O_RDONLY); if (fd == -1) { - *error = errno; + seterror(errno); rv = -1; goto out; } @@ -142,7 +142,7 @@ } fprintf(stderr, error: device size query not implemented on this platform\n); - *error = EOPNOTSUPP; + sererror(EOPNOTSUPP); rv = -1; goto out; #else @@ -152,13 +152,13 @@ fd = open(path, O_RDONLY); if (fd == -1) { - *error = errno; + seterror(errno); rv = -1; goto out; } if (ioctl(fd, DIOCGDINFO, lab) == -1) { - *error = errno; + seterror(errno); rv = -1; goto out; } @@ -191,7 +191,7 @@ KLOCK_WRAP(rv = nanosleep(rqt, rmt)); if (rv == -1) - *error = errno; + seterror(errno); *sec = rmt.tv_sec; *nsec = rmt.tv_nsec; @@ -249,7 +249,7 @@ rv = mmap(prefaddr, size, prot, MAP_ANON | MAP_ALIGNED(alignbit), -1, 0); if (rv == MAP_FAILED) { - *error = errno; + seterror(errno); return NULL; } return rv; @@ -287,11 +287,11 @@ rv = mmap(NULL, len, PROT_READ|PROT_WRITE, mmflags, fd, offset); if (rv == MAP_FAILED) { - *error = errno; + seterror(errno); return NULL; } - *error = 0; + seterror(0); return rv; } @@ -337,7 +337,7 @@ KLOCK_WRAP(rv = read(fd, data, size)); if (rv == -1) - *error = errno; + seterror(errno); return rv; } @@ -349,7 +349,7 @@ KLOCK_WRAP(rv = pread(fd, data, size, offset)); if (rv == -1) - *error = errno; + seterror(errno); return rv; } @@ -377,7 +377,7 @@ KLOCK_WRAP(rv = write(fd, data, size)); if (rv == -1) - *error = errno; + seterror(errno); return rv; } @@ -389,7 +389,7 @@ KLOCK_WRAP(rv = pwrite(fd, data, size, offset)); if (rv == -1) - *error = errno; + seterror(errno); return rv; } @@ -420,7 +420,7 @@ iovp = malloc(iovcnt * sizeof(struct iovec)); if (iovp == NULL) { - *error = ENOMEM; + seterror(ENOMEM); return -1; } for (i = 0; i iovcnt; i++) { @@ -431,7 +431,7 @@ KLOCK_WRAP(rv = readv(fd, iovp, iovcnt)); if (rv == -1) - *error = errno; + seterror(errno); free(iovp); return rv; @@ -447,7 +447,7 @@ iovp = malloc(iovcnt * sizeof(struct iovec)); if (iovp == NULL) { - *error = ENOMEM; + seterror(ENOMEM); return -1; } for (i = 0; i iovcnt; i++) { @@ -458,7 +458,7 @@ KLOCK_WRAP(rv = writev(fd, iovp, iovcnt)); if (rv == -1) - *error = errno; + seterror(errno); free(iovp); return rv; @@ -472,7 +472,7 @@ rv = gettimeofday(tv, NULL); if (rv == -1) { - *error = errno; + seterror(errno); return rv; } @@ -535,7 +535,7 @@ if (kq == -1) { kq = kqueue(); if (kq == -1) { - *error = errno; + seterror(errno); return -1; } } @@ -543,7 +543,7 @@ EV_SET(kev, fd, EVFILT_VNODE, EV_ADD|EV_ENABLE|EV_CLEAR, NOTE_WRITE, 0, opaque); if (kevent(kq, kev, 1, NULL, 0, NULL) == -1) { - *error = errno; + seterror(errno); return -1; } @@ -561,7 +561,7 @@ if (rv == -1) { if (errno == EINTR) goto again; - *error = errno; + seterror(errno); return -1; } @@ -598,7 +598,7 @@ } #else /* XXXfixme: signal numbers may not match on non-NetBSD */ - *error = EOPNOTSUPP; + seterror(EOPNOTSUPP); return -1; #endif } Index: src/lib/librumpuser/rumpuser_int.h diff -u src/lib/librumpuser/rumpuser_int.h:1.3 src/lib/librumpuser/rumpuser_int.h:1.4 --- src/lib/librumpuser/rumpuser_int.h:1.3 Tue May 18 14:58:41 2010 +++ src/lib/librumpuser/rumpuser_int.h Mon Nov 15 15:23:32 2010 @@ -1,4
CVS commit: [uebayasi-xip] src/sys
Module Name:src Committed By: uebayasi Date: Mon Nov 15 17:32:02 UTC 2010 Modified Files: src/sys/miscfs/genfs [uebayasi-xip]: genfs_io.c src/sys/uvm [uebayasi-xip]: uvm_page.c uvm_page.h Log Message: Move zero-page into a common place, in the hope that it's shared for other purposes. According to Chuck Silvers, zero-page mappings don't need to be explicitly unmapped in putpages(). Follow that advice. To generate a diff of this commit: cvs rdiff -u -r1.36.2.30 -r1.36.2.31 src/sys/miscfs/genfs/genfs_io.c cvs rdiff -u -r1.153.2.64 -r1.153.2.65 src/sys/uvm/uvm_page.c cvs rdiff -u -r1.59.2.35 -r1.59.2.36 src/sys/uvm/uvm_page.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/miscfs/genfs/genfs_io.c diff -u src/sys/miscfs/genfs/genfs_io.c:1.36.2.30 src/sys/miscfs/genfs/genfs_io.c:1.36.2.31 --- src/sys/miscfs/genfs/genfs_io.c:1.36.2.30 Sat Nov 6 08:08:44 2010 +++ src/sys/miscfs/genfs/genfs_io.c Mon Nov 15 17:32:01 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: genfs_io.c,v 1.36.2.30 2010/11/06 08:08:44 uebayasi Exp $ */ +/* $NetBSD: genfs_io.c,v 1.36.2.31 2010/11/15 17:32:01 uebayasi Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1993 @@ -31,7 +31,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: genfs_io.c,v 1.36.2.30 2010/11/06 08:08:44 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: genfs_io.c,v 1.36.2.31 2010/11/15 17:32:01 uebayasi Exp $); #include opt_xip.h @@ -873,18 +873,8 @@ * allocated and linearly ordered by physical address. */ if (blkno 0) { - zero_page = uvm_pagelookup(uobj, 0); - - if (zero_page == NULL) { -mutex_enter(uobj-vmobjlock); -zero_page = uvm_pagealloc(uobj, 0, NULL, -UVM_PGA_ZERO); -mutex_exit(uobj-vmobjlock); -KASSERT(zero_page != NULL); -mutex_enter(uvm_pageqlock); -uvm_pagewire(zero_page); -mutex_exit(uvm_pageqlock); - } + zero_page = uvm_page_zeropage_alloc(); + KASSERT(zero_page != NULL); pps[i] = zero_page; } else { struct vm_physseg *seg; @@ -918,10 +908,10 @@ for (i = 0; i npages; i++) { struct vm_page *pg = pps[i]; + KASSERT((pg-flags PG_RDONLY) != 0); if (pg == zero_page) { } else { KASSERT((pg-flags PG_BUSY) == 0); - KASSERT((pg-flags PG_RDONLY) != 0); KASSERT((pg-flags PG_CLEAN) != 0); KASSERT((pg-flags PG_DEVICE) != 0); pg-flags |= PG_BUSY; @@ -1544,8 +1534,8 @@ pg = pgs[i]; if (pg == NULL || pg == PGO_DONTCARE) continue; - if (pg == zero_page) { -put_zero_page = true; + if (pg == uvm_page_zeropage) { +/* Do nothing for holes. */ } else { /* * Freeing normal XIP pages; nothing to do. @@ -1562,17 +1552,6 @@ off += npages PAGE_SHIFT; } - if (put_zero_page) { - /* - * Freeing an XIP zero page. - */ - pmap_page_protect(zero_page, VM_PROT_NONE); - mutex_enter(uvm_pageqlock); - uvm_pageunwire(zero_page); - mutex_exit(uvm_pageqlock); - uvm_pagefree(zero_page); - } - KASSERT(uobj-uo_npages == 0); done: Index: src/sys/uvm/uvm_page.c diff -u src/sys/uvm/uvm_page.c:1.153.2.64 src/sys/uvm/uvm_page.c:1.153.2.65 --- src/sys/uvm/uvm_page.c:1.153.2.64 Fri Nov 12 19:02:44 2010 +++ src/sys/uvm/uvm_page.c Mon Nov 15 17:32:01 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: uvm_page.c,v 1.153.2.64 2010/11/12 19:02:44 uebayasi Exp $ */ +/* $NetBSD: uvm_page.c,v 1.153.2.65 2010/11/15 17:32:01 uebayasi Exp $ */ /* * Copyright (c) 2010 The NetBSD Foundation, Inc. @@ -97,7 +97,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: uvm_page.c,v 1.153.2.64 2010/11/12 19:02:44 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: uvm_page.c,v 1.153.2.65 2010/11/15 17:32:01 uebayasi Exp $); #include opt_ddb.h #include opt_uvmhist.h @@ -113,6 +113,7 @@ #include sys/proc.h #include sys/atomic.h #include sys/cpu.h +#include sys/once.h #include uvm/uvm.h #include uvm/uvm_ddb.h @@ -2234,6 +2235,46 @@ return (VM_PHYSMEM_PTR(lcv)-free_list); } +static int uvm_page_zeropage_init(void); + +struct vm_page *uvm_page_zeropage; + +struct vm_page * +uvm_page_zeropage_alloc(void) +{ + static ONCE_DECL(inited); + + (void)RUN_ONCE(inited, uvm_page_zeropage_init); + KASSERT(uvm_page_zeropage != NULL); + return uvm_page_zeropage; +} + +static int +uvm_page_zeropage_init(void) +{ + struct pglist mlist; + struct vm_page *pg; + int n; + + n = uvm_pglistalloc(PAGE_SIZE, 0, -1, PAGE_SIZE, PAGE_SIZE, + mlist, 1, 1); + KASSERT(n == 1); + + pg = TAILQ_FIRST(mlist); + KASSERT(pg != NULL); + + pmap_zero_page(VM_PAGE_TO_PHYS(pg)); + + pg-flags |= PG_RDONLY; + + mutex_enter(uvm_pageqlock); + uvm_pagewire(pg); + mutex_exit(uvm_pageqlock); + + uvm_page_zeropage = pg; + return 0; +} + #if defined(DDB) || defined(DEBUGPRINT) /* Index: src/sys/uvm/uvm_page.h diff -u src/sys/uvm/uvm_page.h:1.59.2.35 src/sys/uvm/uvm_page.h:1.59.2.36 --- src/sys/uvm/uvm_page.h:1.59.2.35 Fri Nov 12 08:13:40 2010 +++
CVS commit: src/sys/arch/arm/imx
Module Name:src Committed By: bsh Date: Mon Nov 15 18:18:39 UTC 2010 Modified Files: src/sys/arch/arm/imx: imx31_gpio.c Log Message: GPIO register definitions are now in imxgpioreg.h to share them with imx51 To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/imx/imx31_gpio.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/imx/imx31_gpio.c diff -u src/sys/arch/arm/imx/imx31_gpio.c:1.4 src/sys/arch/arm/imx/imx31_gpio.c:1.5 --- src/sys/arch/arm/imx/imx31_gpio.c:1.4 Wed Nov 19 06:28:14 2008 +++ src/sys/arch/arm/imx/imx31_gpio.c Mon Nov 15 18:18:39 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: imx31_gpio.c,v 1.4 2008/11/19 06:28:14 matt Exp $ */ +/* $NetBSD: imx31_gpio.c,v 1.5 2010/11/15 18:18:39 bsh Exp $ */ /*- * Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. @@ -28,7 +28,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: imx31_gpio.c,v 1.4 2008/11/19 06:28:14 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: imx31_gpio.c,v 1.5 2010/11/15 18:18:39 bsh Exp $); #define _INTR_PRIVATE @@ -51,6 +51,7 @@ #include arm/imx/imx31reg.h #include arm/imx/imx31var.h +#include arm/imx/imxgpioreg.h #include arm/pic/picvar.h #if NGPIO 0
CVS commit: src/sys/arch/arm/imx
Module Name:src Committed By: bsh Date: Mon Nov 15 18:19:20 UTC 2010 Modified Files: src/sys/arch/arm/imx: files.imx31 imx31_clock.c imx31reg.h Log Message: EPIT support as system clock for i.MX31 To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/imx/files.imx31 cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/imx/imx31_clock.c cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/imx/imx31reg.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/arch/arm/imx/files.imx31 diff -u src/sys/arch/arm/imx/files.imx31:1.5 src/sys/arch/arm/imx/files.imx31:1.6 --- src/sys/arch/arm/imx/files.imx31:1.5 Sat Nov 13 06:28:20 2010 +++ src/sys/arch/arm/imx/files.imx31 Mon Nov 15 18:19:19 2010 @@ -1,4 +1,4 @@ -# $NetBSD: files.imx31,v 1.5 2010/11/13 06:28:20 bsh Exp $ +# $NetBSD: files.imx31,v 1.6 2010/11/15 18:19:19 bsh Exp $ # # Configuration info for the Freescale i.MX31 # @@ -51,6 +51,14 @@ # iMX clock file arch/arm/imx/imxclock.c +file arch/arm/imx/imx31_clock.c + +# Clock Control Module +device imxccm +attach imxccm at aips +file arch/arm/imx/imx31_ccm.c imxccm needs-flag + +defparam opt_imx31clk.h IMX31_IPGCLK_FREQ # iMX UART device imxuart Index: src/sys/arch/arm/imx/imx31_clock.c diff -u src/sys/arch/arm/imx/imx31_clock.c:1.1 src/sys/arch/arm/imx/imx31_clock.c:1.2 --- src/sys/arch/arm/imx/imx31_clock.c:1.1 Sat Nov 13 06:51:37 2010 +++ src/sys/arch/arm/imx/imx31_clock.c Mon Nov 15 18:19:19 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: imx31_clock.c,v 1.1 2010/11/13 06:51:37 bsh Exp $ */ +/* $NetBSD: imx31_clock.c,v 1.2 2010/11/15 18:19:19 bsh Exp $ */ /* * Copyright (c) 2009,2010 Genetec corp. All rights reserved. * Written by Hashimoto Kenichi for Genetec corp. @@ -45,8 +45,14 @@ #include arm/imx/imx31reg.h #include arm/imx/imx31var.h +#if 0 /* notyet */ #include arm/imx/imx31_ccmvar.h +#endif #include arm/imx/imxclockvar.h +#include arm/imx/imxepitreg.h + +#include imxccm.h /* if CCM driver is configured into the kernel */ +#include opt_imx31clk.h static int imxclock_match(device_t, struct cfdata *, void *); static void imxclock_attach(device_t, device_t, void *); @@ -105,10 +111,18 @@ int imxclock_get_timerfreq(struct imxclock_softc *sc) { +#if NIMXCCM 0 struct imx31_clocks clk; imx31_get_clocks(clk); return clk.ipg_clk; +#else +#ifndef IMX31_IPGCLK_FREQ +#error IMX31_IPGCLK_FREQ need to be defined. +#endif + return IMX31_IPGCLK_FREQ; + +#endif } Index: src/sys/arch/arm/imx/imx31reg.h diff -u src/sys/arch/arm/imx/imx31reg.h:1.4 src/sys/arch/arm/imx/imx31reg.h:1.5 --- src/sys/arch/arm/imx/imx31reg.h:1.4 Sat Nov 13 06:44:11 2010 +++ src/sys/arch/arm/imx/imx31reg.h Mon Nov 15 18:19:19 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: imx31reg.h,v 1.4 2010/11/13 06:44:11 bsh Exp $ */ +/* $NetBSD: imx31reg.h,v 1.5 2010/11/15 18:19:19 bsh Exp $ */ /*- * Copyright (c) 2007 The NetBSD Foundation, Inc. * All rights reserved. @@ -58,6 +58,18 @@ #define GPIO3_BASE 0x53fa4000 /* register definitions in imxgpiore.h */ +#define GPIO_NPINS 32 +#define GPIO_NGROUPS 3 + +#define GPIO_NO_SCLK0 GPIO_NO(3, 2) + + +/* EPIT */ + +#define EPIT1_BASE 0x53f94000 +#define EPIT2_BASE 0x53f98000 + + #define INTC_BASE 0x6800 #define INTC_SIZE 0x0400 #define IMX31_INTCNTL 0x /* Interrupt Control (RW) */
CVS commit: src/sys/arch/evbarm/conf
Module Name:src Committed By: bsh Date: Mon Nov 15 18:21:19 UTC 2010 Modified Files: src/sys/arch/evbarm/conf: IMX31LITE Log Message: add an option for system clock frequency (used by timer driver) To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/evbarm/conf/IMX31LITE Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/evbarm/conf/IMX31LITE diff -u src/sys/arch/evbarm/conf/IMX31LITE:1.9 src/sys/arch/evbarm/conf/IMX31LITE:1.10 --- src/sys/arch/evbarm/conf/IMX31LITE:1.9 Sat Dec 5 20:11:11 2009 +++ src/sys/arch/evbarm/conf/IMX31LITE Mon Nov 15 18:21:19 2010 @@ -1,4 +1,4 @@ -# $NetBSD: IMX31LITE,v 1.9 2009/12/05 20:11:11 pooka Exp $ +# $NetBSD: IMX31LITE,v 1.10 2010/11/15 18:21:19 bsh Exp $ # # IMX31LITE -- Freescale IMX31LITE Evaluation Board Kernel # @@ -22,6 +22,7 @@ options CPU_ARM1136 # Support the SA110 core # Architecture options +optionsIMX31_IPGCLK_FREQ=6600 # Fixme. bogus value # File systems
CVS commit: src/sys/rump/net/lib/libvirtif
Module Name:src Committed By: pooka Date: Mon Nov 15 20:23:12 UTC 2010 Modified Files: src/sys/rump/net/lib/libvirtif: if_virt.c Log Message: Make interface support ifconfig {down,destroy} and generally make it a little less eager to panic. To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/sys/rump/net/lib/libvirtif/if_virt.c 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/net/lib/libvirtif/if_virt.c diff -u src/sys/rump/net/lib/libvirtif/if_virt.c:1.20 src/sys/rump/net/lib/libvirtif/if_virt.c:1.21 --- src/sys/rump/net/lib/libvirtif/if_virt.c:1.20 Tue Oct 19 19:19:41 2010 +++ src/sys/rump/net/lib/libvirtif/if_virt.c Mon Nov 15 20:23:11 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: if_virt.c,v 1.20 2010/10/19 19:19:41 pooka Exp $ */ +/* $NetBSD: if_virt.c,v 1.21 2010/11/15 20:23:11 pooka Exp $ */ /* * Copyright (c) 2008 Antti Kantee. All Rights Reserved. @@ -26,11 +26,12 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: if_virt.c,v 1.20 2010/10/19 19:19:41 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: if_virt.c,v 1.21 2010/11/15 20:23:11 pooka Exp $); #include sys/param.h #include sys/condvar.h #include sys/fcntl.h +#include sys/kernel.h #include sys/kmem.h #include sys/kthread.h #include sys/mutex.h @@ -68,11 +69,13 @@ struct virtif_sc { struct ethercom sc_ec; int sc_tapfd; - kmutex_t sc_sendmtx; - kcondvar_t sc_sendcv; + bool sc_dying; + struct lwp *sc_l_snd, *sc_l_rcv; + kmutex_t sc_mtx; + kcondvar_t sc_cv; }; -static void virtif_worker(void *); +static void virtif_receiver(void *); static void virtif_sender(void *); static int virtif_clone(struct if_clone *, int); static int virtif_unclone(struct ifnet *); @@ -87,7 +90,10 @@ struct ifnet *ifp; uint8_t enaddr[ETHER_ADDR_LEN] = { 0xb2, 0x0a, 0x00, 0x0b, 0x0e, 0x01 }; char tapdev[16]; - int fd, error; + int fd, error = 0; + + if (num = 0x100) + return E2BIG; snprintf(tapdev, sizeof(tapdev), /dev/tap%d, num); fd = rumpuser_open(tapdev, O_RDWR, error); @@ -96,29 +102,48 @@ num, error); return error; } - KASSERT(num 0x100); enaddr[2] = arc4random() 0xff; enaddr[5] = num; sc = kmem_zalloc(sizeof(*sc), KM_SLEEP); + sc-sc_dying = false; sc-sc_tapfd = fd; + mutex_init(sc-sc_mtx, MUTEX_DEFAULT, IPL_NONE); + cv_init(sc-sc_cv, virtsnd); ifp = sc-sc_ec.ec_if; sprintf(ifp-if_xname, %s%d, VIRTIF_BASE, num); ifp-if_softc = sc; + + if (rump_threads) { + if ((error = kthread_create(PRI_NONE, KTHREAD_JOINABLE, NULL, + virtif_receiver, ifp, sc-sc_l_rcv, virtifr)) != 0) + goto out; + + if ((error = kthread_create(PRI_NONE, + KTHREAD_JOINABLE | KTHREAD_MPSAFE, NULL, + virtif_sender, ifp, sc-sc_l_snd, virtifs)) != 0) + goto out; + } else { + printf(WARNING: threads not enabled, receive NOT working\n); + } + ifp-if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST; ifp-if_init = virtif_init; ifp-if_ioctl = virtif_ioctl; ifp-if_start = virtif_start; ifp-if_stop = virtif_stop; - - mutex_init(sc-sc_sendmtx, MUTEX_DEFAULT, IPL_NONE); - cv_init(sc-sc_sendcv, virtsnd); + IFQ_SET_READY(ifp-if_snd); if_attach(ifp); ether_ifattach(ifp, enaddr); - return 0; + out: + if (error) { + virtif_unclone(ifp); + } + + return error; } static int @@ -131,31 +156,51 @@ static int virtif_unclone(struct ifnet *ifp) { + struct virtif_sc *sc = ifp-if_softc; - return EOPNOTSUPP; + mutex_enter(sc-sc_mtx); + if (sc-sc_dying) { + mutex_exit(sc-sc_mtx); + return EINPROGRESS; + } + sc-sc_dying = true; + cv_broadcast(sc-sc_cv); + mutex_exit(sc-sc_mtx); + + virtif_stop(ifp, 1); + if_down(ifp); + + if (sc-sc_l_snd) { + kthread_join(sc-sc_l_snd); + sc-sc_l_snd = NULL; + } + if (sc-sc_l_rcv) { + kthread_join(sc-sc_l_rcv); + sc-sc_l_rcv = NULL; + } + + rumpuser_close(sc-sc_tapfd, NULL); + + mutex_destroy(sc-sc_mtx); + cv_destroy(sc-sc_cv); + kmem_free(sc, sizeof(*sc)); + + ether_ifdetach(ifp); + if_detach(ifp); + + return 0; } static int virtif_init(struct ifnet *ifp) { - int rv; + struct virtif_sc *sc = ifp-if_softc; - if (rump_threads) { - rv = kthread_create(PRI_NONE, 0, NULL, virtif_worker, ifp, - NULL, virtifi); - /* XXX: should do proper cleanup */ - if (rv) { - panic(if_virt: can't create worker); - } - rv = kthread_create(PRI_NONE, 0, NULL, virtif_sender, ifp, - NULL, virtifs); - if (rv) { - panic(if_virt: can't create sender); - } - } else { - printf(WARNING: threads not enabled, receive NOT working\n); - } ifp-if_flags |= IFF_RUNNING; + + mutex_enter(sc-sc_mtx); + cv_broadcast(sc-sc_cv); + mutex_exit(sc-sc_mtx); return 0; } @@ -180,66 +225,86 @@ { struct virtif_sc *sc = ifp-if_softc; - mutex_enter(sc-sc_sendmtx); - cv_signal(sc-sc_sendcv); - mutex_exit(sc-sc_sendmtx); + mutex_enter(sc-sc_mtx); + ifp-if_flags |= IFF_OACTIVE; + cv_broadcast(sc-sc_cv); + mutex_exit(sc-sc_mtx); } static void
CVS commit: src/sys/rump/librump/rumpkern
Module Name:src Committed By: pooka Date: Mon Nov 15 20:24:09 UTC 2010 Modified Files: src/sys/rump/librump/rumpkern: rump.c Log Message: apply const To generate a diff of this commit: cvs rdiff -u -r1.196 -r1.197 src/sys/rump/librump/rumpkern/rump.c 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/librump/rumpkern/rump.c diff -u src/sys/rump/librump/rumpkern/rump.c:1.196 src/sys/rump/librump/rumpkern/rump.c:1.197 --- src/sys/rump/librump/rumpkern/rump.c:1.196 Thu Nov 4 20:54:07 2010 +++ src/sys/rump/librump/rumpkern/rump.c Mon Nov 15 20:24:09 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: rump.c,v 1.196 2010/11/04 20:54:07 pooka Exp $ */ +/* $NetBSD: rump.c,v 1.197 2010/11/15 20:24:09 pooka Exp $ */ /* * Copyright (c) 2007 Antti Kantee. All Rights Reserved. @@ -28,7 +28,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: rump.c,v 1.196 2010/11/04 20:54:07 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: rump.c,v 1.197 2010/11/15 20:24:09 pooka Exp $); #include sys/systm.h #define ELFSIZE ARCH_ELFSIZE @@ -188,10 +188,19 @@ hostname, MAXHOSTNAMELEN, CTL_KERN, KERN_HOSTNAME, CTL_EOL); } +static const struct rumpuser_sp_ops spops = { + .spop_schedule = rump_schedule, + .spop_unschedule = rump_unschedule, + .spop_lwproc_switch = rump_lwproc_switch, + .spop_lwproc_release = rump_lwproc_releaselwp, + .spop_lwproc_newproc = rump_lwproc_newproc, + .spop_lwproc_curlwp = rump_lwproc_curlwp, + .spop_syscall = rump_syscall, +}; + int rump__init(int rump_version) { - struct rumpuser_sp_ops spops; char buf[256]; struct timespec ts; uint64_t sec, nsec; @@ -208,14 +217,6 @@ rump_inited = 1; /* Check our role as a rump proxy */ - spops.spop_schedule = rump_schedule; - spops.spop_unschedule = rump_unschedule; - spops.spop_lwproc_switch = rump_lwproc_switch; - spops.spop_lwproc_release = rump_lwproc_releaselwp; - spops.spop_lwproc_newproc = rump_lwproc_newproc; - spops.spop_lwproc_curlwp = rump_lwproc_curlwp; - spops.spop_syscall = rump_syscall; - if (rumpuser_getenv(RUMP_SP_SERVER, buf, sizeof(buf), error) == 0) { error = rumpuser_sp_init(spops, buf); if (error)
CVS commit: src/sys/fs/puffs
Module Name:src Committed By: pooka Date: Mon Nov 15 20:31:41 UTC 2010 Modified Files: src/sys/fs/puffs: puffs_msgif.c Log Message: Apply patch from PR kern/44093 by yamt: Interrupt server wait only on certain signals (same set at nfs -i) instead of all signals. According to the PR this helps with git clone run on a puffs file system. To generate a diff of this commit: cvs rdiff -u -r1.83 -r1.84 src/sys/fs/puffs/puffs_msgif.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/fs/puffs/puffs_msgif.c diff -u src/sys/fs/puffs/puffs_msgif.c:1.83 src/sys/fs/puffs/puffs_msgif.c:1.84 --- src/sys/fs/puffs/puffs_msgif.c:1.83 Fri Nov 12 17:46:09 2010 +++ src/sys/fs/puffs/puffs_msgif.c Mon Nov 15 20:31:41 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: puffs_msgif.c,v 1.83 2010/11/12 17:46:09 pooka Exp $ */ +/* $NetBSD: puffs_msgif.c,v 1.84 2010/11/15 20:31:41 pooka Exp $ */ /* * Copyright (c) 2005, 2006, 2007 Antti Kantee. All Rights Reserved. @@ -30,7 +30,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: puffs_msgif.c,v 1.83 2010/11/12 17:46:09 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: puffs_msgif.c,v 1.84 2010/11/15 20:31:41 pooka Exp $); #include sys/param.h #include sys/atomic.h @@ -378,17 +378,30 @@ if (__predict_false((park-park_flags PARKFLAG_WANTREPLY) (park-park_flags PARKFLAG_CALL) == 0 (l-l_flag LW_PENDSIG) != 0 sigispending(l, 0))) { - park-park_flags |= PARKFLAG_HASERROR; - preq-preq_rv = EINTR; - if (PUFFSOP_OPCLASS(preq-preq_opclass) == PUFFSOP_VN - (preq-preq_optype == PUFFS_VN_INACTIVE - || preq-preq_optype == PUFFS_VN_RECLAIM)) { - park-park_preq-preq_opclass |= PUFFSOPFLAG_FAF; - park-park_flags = ~PARKFLAG_WANTREPLY; - DPRINTF((puffs_msg_enqueue: converted to FAF %p\n, - park)); - } else { - return; + sigset_t ss; + + /* + * see the comment about signals in puffs_msg_wait. + */ + sigpending1(l, ss); + if (sigismember(ss, SIGINT) || + sigismember(ss, SIGTERM) || + sigismember(ss, SIGKILL) || + sigismember(ss, SIGHUP) || + sigismember(ss, SIGQUIT)) { + park-park_flags |= PARKFLAG_HASERROR; + preq-preq_rv = EINTR; + if (PUFFSOP_OPCLASS(preq-preq_opclass) == PUFFSOP_VN + (preq-preq_optype == PUFFS_VN_INACTIVE + || preq-preq_optype == PUFFS_VN_RECLAIM)) { +park-park_preq-preq_opclass |= +PUFFSOPFLAG_FAF; +park-park_flags = ~PARKFLAG_WANTREPLY; +DPRINTF((puffs_msg_enqueue: +converted to FAF %p\n, park)); + } else { +return; + } } } @@ -426,10 +439,30 @@ int puffs_msg_wait(struct puffs_mount *pmp, struct puffs_msgpark *park) { + lwp_t *l = curlwp; + proc_t *p = l-l_proc; struct puffs_req *preq = park-park_preq; /* XXX: hmmm */ + sigset_t ss; + sigset_t oss; int error = 0; int rv; + /* + * block unimportant signals. + * + * The set of important signals here was chosen to be same as + * nfs interruptible mount. + */ + sigfillset(ss); + sigdelset(ss, SIGINT); + sigdelset(ss, SIGTERM); + sigdelset(ss, SIGKILL); + sigdelset(ss, SIGHUP); + sigdelset(ss, SIGQUIT); + mutex_enter(p-p_lock); + sigprocmask1(l, SIG_BLOCK, ss, oss); + mutex_exit(p-p_lock); + mutex_enter(pmp-pmp_lock); puffs_mp_reference(pmp); mutex_exit(pmp-pmp_lock); @@ -503,6 +536,10 @@ puffs_mp_release(pmp); mutex_exit(pmp-pmp_lock); + mutex_enter(p-p_lock); + sigprocmask1(l, SIG_SETMASK, oss, NULL); + mutex_exit(p-p_lock); + return rv; }
CVS commit: src/sys/rump
Module Name:src Committed By: pooka Date: Mon Nov 15 20:37:22 UTC 2010 Modified Files: src/sys/rump/include/rump: rump.h src/sys/rump/librump/rumpkern: lwproc.c signals.c Log Message: Add a new signal model RUMP_SIGMODEL_RECORD which records all signals which are posted to a process. To generate a diff of this commit: cvs rdiff -u -r1.46 -r1.47 src/sys/rump/include/rump/rump.h cvs rdiff -u -r1.3 -r1.4 src/sys/rump/librump/rumpkern/lwproc.c \ src/sys/rump/librump/rumpkern/signals.c 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/include/rump/rump.h diff -u src/sys/rump/include/rump/rump.h:1.46 src/sys/rump/include/rump/rump.h:1.47 --- src/sys/rump/include/rump/rump.h:1.46 Wed Oct 27 20:44:50 2010 +++ src/sys/rump/include/rump/rump.h Mon Nov 15 20:37:21 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: rump.h,v 1.46 2010/10/27 20:44:50 pooka Exp $ */ +/* $NetBSD: rump.h,v 1.47 2010/11/15 20:37:21 pooka Exp $ */ /* * Copyright (c) 2007 Antti Kantee. All Rights Reserved. @@ -69,7 +69,8 @@ RUMP_SIGMODEL_PANIC, RUMP_SIGMODEL_IGNORE, RUMP_SIGMODEL_HOST, - RUMP_SIGMODEL_RAISE + RUMP_SIGMODEL_RAISE, + RUMP_SIGMODEL_RECORD }; /* rumpvfs */ Index: src/sys/rump/librump/rumpkern/lwproc.c diff -u src/sys/rump/librump/rumpkern/lwproc.c:1.3 src/sys/rump/librump/rumpkern/lwproc.c:1.4 --- src/sys/rump/librump/rumpkern/lwproc.c:1.3 Fri Oct 29 15:32:24 2010 +++ src/sys/rump/librump/rumpkern/lwproc.c Mon Nov 15 20:37:22 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: lwproc.c,v 1.3 2010/10/29 15:32:24 pooka Exp $ */ +/* $NetBSD: lwproc.c,v 1.4 2010/11/15 20:37:22 pooka Exp $ */ /* * Copyright (c) 2010 Antti Kantee. All Rights Reserved. @@ -26,7 +26,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: lwproc.c,v 1.3 2010/10/29 15:32:24 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: lwproc.c,v 1.4 2010/11/15 20:37:22 pooka Exp $); #include sys/param.h #include sys/atomic.h @@ -277,7 +277,8 @@ /* * Switch to a new process/thread. Release previous one if - * deemed to be exiting. + * deemed to be exiting. This is considered a slow path for + * rump kernel entry. */ void rump_lwproc_switch(struct lwp *newlwp) @@ -309,9 +310,20 @@ rumpuser_set_curlwp(newlwp); + /* + * Check if the thread should get a signal. This is + * mostly to satisfy the record rump sigmodel. + */ + mutex_enter(newlwp-l_proc-p_lock); + if (sigispending(newlwp, 0)) { + newlwp-l_flag |= LW_PENDSIG; + } + mutex_exit(newlwp-l_proc-p_lock); + l-l_mutex = NULL; l-l_cpu = NULL; l-l_pflag = ~LP_RUNNING; + l-l_flag = ~LW_PENDSIG; if (l-l_flag LW_WEXIT) { lwproc_freelwp(l); Index: src/sys/rump/librump/rumpkern/signals.c diff -u src/sys/rump/librump/rumpkern/signals.c:1.3 src/sys/rump/librump/rumpkern/signals.c:1.4 --- src/sys/rump/librump/rumpkern/signals.c:1.3 Thu Jun 10 21:40:42 2010 +++ src/sys/rump/librump/rumpkern/signals.c Mon Nov 15 20:37:22 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: signals.c,v 1.3 2010/06/10 21:40:42 pooka Exp $ */ +/* $NetBSD: signals.c,v 1.4 2010/11/15 20:37:22 pooka Exp $ */ /* * Copyright (c) 2010 Antti Kantee. All Rights Reserved. @@ -26,7 +26,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: signals.c,v 1.3 2010/06/10 21:40:42 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: signals.c,v 1.4 2010/11/15 20:37:22 pooka Exp $); #include sys/param.h #include sys/atomic.h @@ -85,6 +85,37 @@ rumpuser_kill(RUMPUSER_PID_SELF, signo, error); } +static void +rumpsig_record(pid_t target, int sig) +{ + struct proc *p = NULL; + struct pgrp *pgrp = NULL; + + /* well this is a little silly */ + mutex_enter(proc_lock); + if (target = 0) + p = proc_find_raw(target); + else + pgrp = pgrp_find(target); + + if (p) { + mutex_enter(p-p_lock); + if (!sigismember(p-p_sigctx.ps_sigignore, sig)) { + sigaddset(p-p_sigpend.sp_set, sig); + } + mutex_exit(p-p_lock); + } else if (pgrp) { + LIST_FOREACH(p, pgrp-pg_members, p_pglist) { + mutex_enter(p-p_lock); + if (!sigismember(p-p_sigctx.ps_sigignore, sig)) { +sigaddset(p-p_sigpend.sp_set, sig); + } + mutex_exit(p-p_lock); + } + } + mutex_exit(proc_lock); +} + typedef void (*rumpsig_fn)(pid_t pid, int sig); rumpsig_fn rumpsig = rumpsig_panic; @@ -104,16 +135,19 @@ switch (model) { case RUMP_SIGMODEL_PANIC: - atomic_swap_ptr(rumpsig, rumpsig_panic); + rumpsig = rumpsig_panic; break; case RUMP_SIGMODEL_IGNORE: - atomic_swap_ptr(rumpsig, rumpsig_ignore); + rumpsig = rumpsig_ignore; break; case RUMP_SIGMODEL_HOST: - atomic_swap_ptr(rumpsig, rumpsig_host); + rumpsig = rumpsig_host; break; case RUMP_SIGMODEL_RAISE: - atomic_swap_ptr(rumpsig, rumpsig_raise); + rumpsig = rumpsig_raise; + break; + case RUMP_SIGMODEL_RECORD: + rumpsig = rumpsig_record; break; } } @@ -149,29 +183,52 @@ int sigispending(struct lwp *l, int signo) { + struct proc *p = l-l_proc; + sigset_t
CVS commit: src/tests/fs/puffs
Module Name:src Committed By: pooka Date: Mon Nov 15 20:39:00 UTC 2010 Modified Files: src/tests/fs/puffs: t_basic.c Log Message: Add test case for PR kern/44093 (fixed already, but tested to fail without fix applied). To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/tests/fs/puffs/t_basic.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/tests/fs/puffs/t_basic.c diff -u src/tests/fs/puffs/t_basic.c:1.8 src/tests/fs/puffs/t_basic.c:1.9 --- src/tests/fs/puffs/t_basic.c:1.8 Fri Aug 27 05:34:46 2010 +++ src/tests/fs/puffs/t_basic.c Mon Nov 15 20:39:00 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: t_basic.c,v 1.8 2010/08/27 05:34:46 pooka Exp $ */ +/* $NetBSD: t_basic.c,v 1.9 2010/11/15 20:39:00 pooka Exp $ */ #include sys/types.h #include sys/mount.h @@ -391,6 +391,49 @@ FSTEST_DESTRUCTOR(tc, puffs, args); } +ATF_TC(signals); +ATF_TC_HEAD(signals, tc) +{ + + atf_tc_set_md_var(tc, descr, Checks that sending a signal can + cause an interrupt to puffs wait); +} + +extern struct proc *rumpns_initproc; +extern void rumpns_psignal(struct proc *, int); +extern void rumpns_sigclearall(struct proc *, void *, void *); +ATF_TC_BODY(signals, tc) +{ + struct stat sb; + void *args; + + rump_boot_setsigmodel(RUMP_SIGMODEL_RECORD); + + FSTEST_CONSTRUCTOR(tc, puffs, args); + FSTEST_ENTER(); + RL(rump_sys_stat(., sb)); + + /* send SIGUSR1, should not affect puffs ops */ + rump_schedule(); + rumpns_psignal(rumpns_initproc, SIGUSR1); + rump_unschedule(); + RL(rump_sys_stat(., sb)); + + /* send SIGTERM, should get EINTR */ + rump_schedule(); + rumpns_psignal(rumpns_initproc, SIGTERM); + rump_unschedule(); + ATF_REQUIRE_ERRNO(EINTR, rump_sys_stat(., sb) == -1); + + /* clear sigmask so that we can unmount */ + rump_schedule(); + rumpns_sigclearall(rumpns_initproc, NULL, NULL); + rump_unschedule(); + + FSTEST_EXIT(); + FSTEST_DESTRUCTOR(tc, puffs, args); +} + ATF_TP_ADD_TCS(tp) { @@ -406,5 +449,7 @@ ATF_TP_ADD_TC(tp, reclaim_hardlink); ATF_TP_ADD_TC(tp, unlink_accessible); + ATF_TP_ADD_TC(tp, signals); + return atf_no_error(); }
CVS commit: src/share/man/man4
Module Name:src Committed By: wiz Date: Mon Nov 15 21:19:59 UTC 2010 Modified Files: src/share/man/man4: route.4 Log Message: New sentence, new line; add serial comma. To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 src/share/man/man4/route.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man4/route.4 diff -u src/share/man/man4/route.4:1.16 src/share/man/man4/route.4:1.17 --- src/share/man/man4/route.4:1.16 Sun Nov 14 00:38:56 2010 +++ src/share/man/man4/route.4 Mon Nov 15 21:19:59 2010 @@ -1,4 +1,4 @@ -.\ $NetBSD: route.4,v 1.16 2010/11/14 00:38:56 roy Exp $ +.\ $NetBSD: route.4,v 1.17 2010/11/15 21:19:59 wiz Exp $ .\ .\ Copyright (c) 1990, 1991, 1993 .\ The Regents of the University of California. All rights reserved. @@ -74,11 +74,12 @@ through each interface as a .Dq direct connection to the destination host -or network. If the route is direct, the transport layer of -a protocol family usually requests the packet be sent to the -same host specified in the packet. Otherwise, the interface -is requested to address the packet to the gateway listed in the routing entry -(i.e. the packet is forwarded). +or network. +If the route is direct, the transport layer of a protocol family +usually requests the packet be sent to the same host specified in +the packet. +Otherwise, the interface is requested to address the packet to the +gateway listed in the routing entry (i.e. the packet is forwarded). .Pp When routing a packet, the kernel will attempt to find @@ -95,9 +96,9 @@ destination address value, and a mask of all zeroes. Wildcard routes will be used when the system fails to find other routes matching the -destination. The combination of wildcard -routes and routing redirects can provide an economical -mechanism for routing traffic. +destination. +The combination of wildcard routes and routing redirects can provide +an economical mechanism for routing traffic. .Pp One opens the channel for passing routing control messages by using the socket call shown in the synopsis above: @@ -126,10 +127,11 @@ to most significant bit within the vector. .Pp Any messages sent to the kernel are returned, and copies are sent -to all interested listeners. The kernel will provide the process -ID for the sender, and the sender may use an additional sequence -field to distinguish between outstanding messages. However, -message replies may be lost when kernel buffers are exhausted. +to all interested listeners. +The kernel will provide the process ID for the sender, and the +sender may use an additional sequence field to distinguish between +outstanding messages. +However, message replies may be lost when kernel buffers are exhausted. .Pp The kernel may reject certain messages, and will indicate this by filling in the @@ -252,7 +254,7 @@ .Ar if_msghdr header, the .Dv RTM_NEWADDR , -.Dv RTM_CHGADDR +.Dv RTM_CHGADDR , and .Dv RTM_DELADDR messages use a
CVS commit: src/lib/libedit
Module Name:src Committed By: christos Date: Mon Nov 15 21:24:32 UTC 2010 Modified Files: src/lib/libedit: filecomplete.c Log Message: don't increment i twice in the loop. From Michael Byrnes To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/lib/libedit/filecomplete.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/libedit/filecomplete.c diff -u src/lib/libedit/filecomplete.c:1.19 src/lib/libedit/filecomplete.c:1.20 --- src/lib/libedit/filecomplete.c:1.19 Tue Jun 1 14:20:26 2010 +++ src/lib/libedit/filecomplete.c Mon Nov 15 16:24:31 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: filecomplete.c,v 1.19 2010/06/01 18:20:26 christos Exp $ */ +/* $NetBSD: filecomplete.c,v 1.20 2010/11/15 21:24:31 christos Exp $ */ /*- * Copyright (c) 1997 The NetBSD Foundation, Inc. @@ -31,7 +31,7 @@ #include config.h #if !defined(lint) !defined(SCCSID) -__RCSID($NetBSD: filecomplete.c,v 1.19 2010/06/01 18:20:26 christos Exp $); +__RCSID($NetBSD: filecomplete.c,v 1.20 2010/11/15 21:24:31 christos Exp $); #endif /* not lint not SCCSID */ #include sys/types.h @@ -368,7 +368,7 @@ for(; count 0; count--) { int more = limit 0 matches[0]; for(i = 0; more; i++, idx++) { - more = ++i limit matches[idx + 1]; + more = i limit matches[idx + 1]; (void)fprintf(el-el_outfile, %-*s%s, (int)max, matches[idx], more ? : ); }
CVS commit: src/crypto/external/bsd/netpgp/dist/src/netpgpverify
Module Name:src Committed By: wiz Date: Mon Nov 15 21:29:21 UTC 2010 Modified Files: src/crypto/external/bsd/netpgp/dist/src/netpgpverify: netpgpverify.1 Log Message: Remove trailing whitespace. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 \ src/crypto/external/bsd/netpgp/dist/src/netpgpverify/netpgpverify.1 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/external/bsd/netpgp/dist/src/netpgpverify/netpgpverify.1 diff -u src/crypto/external/bsd/netpgp/dist/src/netpgpverify/netpgpverify.1:1.4 src/crypto/external/bsd/netpgp/dist/src/netpgpverify/netpgpverify.1:1.5 --- src/crypto/external/bsd/netpgp/dist/src/netpgpverify/netpgpverify.1:1.4 Thu Nov 11 04:51:18 2010 +++ src/crypto/external/bsd/netpgp/dist/src/netpgpverify/netpgpverify.1 Mon Nov 15 21:29:21 2010 @@ -1,4 +1,4 @@ -.\ $NetBSD: netpgpverify.1,v 1.4 2010/11/11 04:51:18 agc Exp $ +.\ $NetBSD: netpgpverify.1,v 1.5 2010/11/15 21:29:21 wiz Exp $ .\ .\ Copyright (c) 2009 The NetBSD Foundation, Inc. .\ All rights reserved. @@ -105,24 +105,24 @@ .Bd -literal % netpgp --sign --userid=...@netbsd.org a signature 2048/RSA (Encrypt or Sign) 1b68dcfcc0596823 2004-01-12 -Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823 -uid Alistair Crooks \*[lt]alist...@hockley-crooks.com\*[gt] -uid Alistair Crooks \*[lt]...@pkgsrc.org\*[gt] -uid Alistair Crooks \*[lt]...@netbsd.org\*[gt] -uid Alistair Crooks \*[lt]...@alistaircrooks.com\*[gt] -uid Alistair Crooks (Yahoo!) \*[lt]agcro...@yahoo-inc.com\*[gt] +Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823 +uid Alistair Crooks \*[lt]alist...@hockley-crooks.com\*[gt] +uid Alistair Crooks \*[lt]...@pkgsrc.org\*[gt] +uid Alistair Crooks \*[lt]...@netbsd.org\*[gt] +uid Alistair Crooks \*[lt]...@alistaircrooks.com\*[gt] +uid Alistair Crooks (Yahoo!) \*[lt]agcro...@yahoo-inc.com\*[gt] encryption 2048/RSA (Encrypt or Sign) 79deb61e488eee74 2004-01-12 netpgp passphrase: % netpgpverify a.gpg Good signature for a.gpg made Thu Jan 29 03:06:00 2009 using RSA (Encrypt or Sign) key 1B68DCFCC0596823 signature 2048/RSA (Encrypt or Sign) 1b68dcfcc0596823 2004-01-12 -Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823 -uid Alistair Crooks \*[lt]alist...@hockley-crooks.com\*[gt] -uid Alistair Crooks \*[lt]...@pkgsrc.org\*[gt] -uid Alistair Crooks \*[lt]...@netbsd.org\*[gt] -uid Alistair Crooks \*[lt]...@alistaircrooks.com\*[gt] -uid Alistair Crooks (Yahoo!) \*[lt]agcro...@yahoo-inc.com\*[gt] +Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823 +uid Alistair Crooks \*[lt]alist...@hockley-crooks.com\*[gt] +uid Alistair Crooks \*[lt]...@pkgsrc.org\*[gt] +uid Alistair Crooks \*[lt]...@netbsd.org\*[gt] +uid Alistair Crooks \*[lt]...@alistaircrooks.com\*[gt] +uid Alistair Crooks (Yahoo!) \*[lt]agcro...@yahoo-inc.com\*[gt] encryption 2048/RSA (Encrypt or Sign) 79deb61e488eee74 2004-01-12 % .Ed
CVS commit: src/tests/fs/lfs
Module Name:src Committed By: pooka Date: Mon Nov 15 21:29:39 UTC 2010 Modified Files: src/tests/fs/lfs: t_pr.c Log Message: double the timeout for slow hosts (from 1 to 2 seconds) To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/tests/fs/lfs/t_pr.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/tests/fs/lfs/t_pr.c diff -u src/tests/fs/lfs/t_pr.c:1.4 src/tests/fs/lfs/t_pr.c:1.5 --- src/tests/fs/lfs/t_pr.c:1.4 Sun Nov 7 17:51:17 2010 +++ src/tests/fs/lfs/t_pr.c Mon Nov 15 21:29:39 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: t_pr.c,v 1.4 2010/11/07 17:51:17 jmmv Exp $ */ +/* $NetBSD: t_pr.c,v 1.5 2010/11/15 21:29:39 pooka Exp $ */ #include sys/types.h #include sys/mount.h @@ -24,7 +24,7 @@ { atf_tc_set_md_var(tc, descr, mknod(2) hangs on LFS (PR kern/43503)); - atf_tc_set_md_var(tc, timeout, 1); + atf_tc_set_md_var(tc, timeout, 2); } #define IMGNAME disk.img
CVS commit: src/distrib/notes/bebox
Module Name:src Committed By: wiz Date: Mon Nov 15 21:39:12 UTC 2010 Modified Files: src/distrib/notes/bebox: prep Log Message: Wording improvements. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/bebox/prep Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/notes/bebox/prep diff -u src/distrib/notes/bebox/prep:1.1 src/distrib/notes/bebox/prep:1.2 --- src/distrib/notes/bebox/prep:1.1 Sat Nov 13 05:20:21 2010 +++ src/distrib/notes/bebox/prep Mon Nov 15 21:39:12 2010 @@ -1,4 +1,4 @@ -.\ $NetBSD: prep,v 1.1 2010/11/13 05:20:21 kiyohara Exp $ +.\ $NetBSD: prep,v 1.2 2010/11/15 21:39:12 wiz Exp $ . .Pp . @@ -16,10 +16,10 @@ .Pp The .Nx*M -doesn't support to create/read/write both file systems. +doesn't support creating/reading/writing either of the file systems. .Pp -However nbpowerpc-mkbootimage can create the image of Old Be file system for -floppy. +However, nbpowerpc-mkbootimage can create an image using the Old +Be file system for writing to a floppy. . .Ss2 Preparing the Bootable Media . @@ -29,18 +29,18 @@ .Pp Go to one of the .Nx -mirror sites and download floppy image from the +mirror sites and download a floppy image from the .Pa bebox/installation/floppy/ directory named boot.fs or boot_vga.fs or boot_com.fs. .Pp -boot.fs can boot with frame buffer. If you look the 'Be' logo on your screen -then use this. Use boot_vga.fs, if not. +boot.fs can boot with a frame buffer. If you see the 'Be' logo on your screen +then use this. If not, use boot_vga.fs. .Pp .(disp .No # Ic dd if=boot.fs of=/dev/rfd0a bs=18k .disp) .Pp -If you have a x86 PC which runs +If you have an x86 PC which runs .Tn Windows and use it to write the floppy image(s) to floppy disk, you can use the @@ -53,15 +53,16 @@ .Nx distribution. .Pp -Also you can create boot.fs. +Also you can create boot.fs in the following way: .Pp .(disp .No # Ic nbpowerpc-mkbootimage -I -m bebox -b mdec/boot/boot boot.fs .disp) . -.Ss2 Loading kernel from Hard disk and Floppy disk. +.Ss2 Loading the kernel from hard disk or floppy disk . -boot supports load kernel from Hard disk and Floppy disk connect to onboard. +boot supports loading a kernel from hard disk or floppy disk +connected directly onboard. . .(bullet -compact Loading a kernel from the 'a' partition on master IDE disk: @@ -70,7 +71,7 @@ .disp) .Pp .It -Loading a kernel from the Floppy disk: +Loading a kernel from a floppy disk: .(disp .Ic /dev/disk/floppy:/netbsd .disp)
CVS commit: src/distrib/notes/common
Module Name:src Committed By: wiz Date: Mon Nov 15 21:39:53 UTC 2010 Modified Files: src/distrib/notes/common: contents Log Message: Improve wording. To generate a diff of this commit: cvs rdiff -u -r1.162 -r1.163 src/distrib/notes/common/contents Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/notes/common/contents diff -u src/distrib/notes/common/contents:1.162 src/distrib/notes/common/contents:1.163 --- src/distrib/notes/common/contents:1.162 Sat Nov 13 05:20:21 2010 +++ src/distrib/notes/common/contents Mon Nov 15 21:39:53 2010 @@ -1,4 +1,4 @@ -.\ $NetBSD: contents,v 1.162 2010/11/13 05:20:21 kiyohara Exp $ +.\ $NetBSD: contents,v 1.163 2010/11/15 21:39:53 wiz Exp $ .\ .\ Copyright (c) 1999-2005 The NetBSD Foundation, Inc. .\ All rights reserved. @@ -310,7 +310,7 @@ . It Pa floppy/kernel1.fs . It Pa floppy/kernel2.fs \*M boot and installation floppy images. The first is the bootloader on -old BeFS. The other images is kernel and embedded ramdisk. +old BeFS. The other images contain the kernel and an embedded ramdisk. .\} . .if \n[cats] \{\
CVS commit: src/share/man/man4
Module Name:src Committed By: pooka Date: Mon Nov 15 21:52:47 UTC 2010 Modified Files: src/share/man/man4: Makefile Added Files: src/share/man/man4: virt.4 Log Message: Exploit the fact that wizd is currently running and add a manpage for the rump virtif. To generate a diff of this commit: cvs rdiff -u -r1.533 -r1.534 src/share/man/man4/Makefile cvs rdiff -u -r0 -r1.1 src/share/man/man4/virt.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man4/Makefile diff -u src/share/man/man4/Makefile:1.533 src/share/man/man4/Makefile:1.534 --- src/share/man/man4/Makefile:1.533 Sat Nov 13 00:47:24 2010 +++ src/share/man/man4/Makefile Mon Nov 15 21:52:47 2010 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.533 2010/11/13 00:47:24 jnemeth Exp $ +# $NetBSD: Makefile,v 1.534 2010/11/15 21:52:47 pooka Exp $ # @(#)Makefile 8.1 (Berkeley) 6/18/93 MAN= aac.4 ac97.4 acardide.4 aceride.4 acphy.4 \ @@ -59,8 +59,8 @@ ti.4 tl.4 tlp.4 tlphy.4 \ tp.4 tr.4 tra.4 trm.4 tty.4 tun.4 tqphy.4 twa.4 twe.4 txp.4 \ uark.4 ubsec.4 udp.4 uep.4 ug.4 uha.4 uk.4 ukphy.4 unix.4 userconf.4 \ - vald.4 veriexec.4 vga.4 vge.4 viaide.4 video.4 vlan.4 vmmon.4 vmnet.4 \ - vnd.4 vr.4 \ + vald.4 veriexec.4 vga.4 vge.4 viaide.4 video.4 virt.4 vlan.4 vmmon.4 \ + vmnet.4 vnd.4 vr.4 \ wapbl.4 wb.4 wbsio.4 wd.4 wdc.4 wi.4 wm.4 wpi.4 \ wscons.4 wsdisplay.4 wsfont.4 wskbd.4 wsmouse.4 wsmux.4 \ xbox.4 xge.4 \ Added files: Index: src/share/man/man4/virt.4 diff -u /dev/null src/share/man/man4/virt.4:1.1 --- /dev/null Mon Nov 15 21:52:47 2010 +++ src/share/man/man4/virt.4 Mon Nov 15 21:52:47 2010 @@ -0,0 +1,83 @@ +.\ $NetBSD: virt.4,v 1.1 2010/11/15 21:52:47 pooka Exp $ +.\ +.\ Copyright (c) 2010 Antti Kantee +.\ All rights reserved. +.\ +.\ Redistribution and use in source and binary forms, with or without +.\ modification, are permitted provided that the following conditions +.\ are met: +.\ 1. Redistributions of source code must retain the above copyright +.\notice, this list of conditions and the following disclaimer. +.\ 2. Redistributions in binary form must reproduce the above copyright +.\notice, this list of conditions and the following disclaimer in the +.\documentation and/or other materials provided with the distribution. +.\ +.\ THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +.\ IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\ OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\ IN NO EVENT SHALL THE AUTHOR 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. +.\ +.Dd November 15, 2010 +.Dt VIRT 4 +.Os +.Sh NAME +.Nm virt +.Nd rump virtual network interface +.Sh SYNOPSIS +.In rump/rump.h +.Ft int +.Fo rump_pub_virtif_create +.Fa int num +.Fc +.Sh DESCRIPTION +The +.Nm +interface acts as a link between a rump virtual kernel and a host +.Xr tap 4 +interface. +Interface number n always corresponds with the host tap interface tapn. +All data sent by +.Nm +is written into +.Pa /dev/tapn +and all data read from +.Pa /dev/tapn +is passed as Ethernet input to the rump virtual kernel. +.Pp +A +.Nm +interface can be created in two ways: +.Bl -bullet +.It +Programmatically by calling +.Fn rump_pub_virtif_create . +.It +Dynamically at runtime with +.Xr ifconfig 8 +or equivalent using the +.Em create +command. +.El +.Pp +Destroying a +.Nm +interface is possible only through +.Xr ifconfig 8 +.Em destroy . +.Pp +The host's +.Xr tap 4 +interface can be further bridged with hardware interfaces to provide +full internet access to a rump kernel. +.Sh SEE ALSO +.Xr rump 3 , +.Xr bridge 4 , +.Xr tap 4 , +.Xr brconfig 8 , +.Xr ifconfig 8
CVS commit: src/distrib/sets/lists/man
Module Name:src Committed By: pooka Date: Mon Nov 15 21:56:47 UTC 2010 Modified Files: src/distrib/sets/lists/man: mi Log Message: diudau, remember that setlists have feelings too and make files match reality To generate a diff of this commit: cvs rdiff -u -r1.1249 -r1.1250 src/distrib/sets/lists/man/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/man/mi diff -u src/distrib/sets/lists/man/mi:1.1249 src/distrib/sets/lists/man/mi:1.1250 --- src/distrib/sets/lists/man/mi:1.1249 Sat Nov 13 00:47:23 2010 +++ src/distrib/sets/lists/man/mi Mon Nov 15 21:56:46 2010 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.1249 2010/11/13 00:47:23 jnemeth Exp $ +# $NetBSD: mi,v 1.1250 2010/11/15 21:56:46 pooka Exp $ # # Note: don't delete entries from here - mark them as obsolete instead. # @@ -1712,6 +1712,7 @@ ./usr/share/man/cat4/viapm.0 man-obsolete obsolete ./usr/share/man/cat4/video.0 man-sys-catman .cat ./usr/share/man/cat4/vinum.0 man-obsolete obsolete +./usr/share/man/cat4/virt.0 man-sys-catman .cat ./usr/share/man/cat4/vlan.0 man-sys-catman .cat ./usr/share/man/cat4/vmmon.0 man-sys-catman .cat ./usr/share/man/cat4/vmnet.0 man-sys-catman .cat @@ -4331,6 +4332,7 @@ ./usr/share/man/html4/viaide.html man-sys-htmlman html ./usr/share/man/html4/video.html man-sys-htmlman html ./usr/share/man/html4/vlan.html man-sys-htmlman html +./usr/share/man/html4/virt.html man-sys-htmlman html ./usr/share/man/html4/vmmon.html man-sys-htmlman html ./usr/share/man/html4/vmnet.html man-sys-htmlman html ./usr/share/man/html4/vnd.html man-sys-htmlman html @@ -6886,6 +6888,7 @@ ./usr/share/man/man4/viapm.4 man-obsolete obsolete ./usr/share/man/man4/video.4 man-sys-man .man ./usr/share/man/man4/vinum.4 man-obsolete obsolete +./usr/share/man/man4/virt.4 man-sys-man .man ./usr/share/man/man4/vlan.4 man-sys-man .man ./usr/share/man/man4/vmmon.4 man-sys-man .man ./usr/share/man/man4/vmnet.4 man-sys-man .man
CVS commit: src
Module Name:src Committed By: pooka Date: Mon Nov 15 22:42:38 UTC 2010 Modified Files: src/sbin/ifconfig: ifconfig.8 ifconfig.c src/sys/net: if.c if.h src/sys/sys: sockio.h Log Message: Implement ifconfig linkstr as proposed on tech-net. To generate a diff of this commit: cvs rdiff -u -r1.101 -r1.102 src/sbin/ifconfig/ifconfig.8 cvs rdiff -u -r1.222 -r1.223 src/sbin/ifconfig/ifconfig.c cvs rdiff -u -r1.248 -r1.249 src/sys/net/if.c cvs rdiff -u -r1.147 -r1.148 src/sys/net/if.h cvs rdiff -u -r1.29 -r1.30 src/sys/sys/sockio.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sbin/ifconfig/ifconfig.8 diff -u src/sbin/ifconfig/ifconfig.8:1.101 src/sbin/ifconfig/ifconfig.8:1.102 --- src/sbin/ifconfig/ifconfig.8:1.101 Mon Sep 14 10:36:49 2009 +++ src/sbin/ifconfig/ifconfig.8 Mon Nov 15 22:42:37 2010 @@ -1,4 +1,4 @@ -.\ $NetBSD: ifconfig.8,v 1.101 2009/09/14 10:36:49 degroote Exp $ +.\ $NetBSD: ifconfig.8,v 1.102 2010/11/15 22:42:37 pooka Exp $ .\ .\ Copyright (c) 1983, 1991, 1993 .\ The Regents of the University of California. All rights reserved. @@ -29,7 +29,7 @@ .\ .\ @(#)ifconfig.8 8.4 (Berkeley) 6/1/94 .\ -.Dd August 7, 2009 +.Dd November 15, 2010 .Dt IFCONFIG 8 .Os .Sh NAME @@ -569,6 +569,13 @@ for more information. .It Fl link[0-2] Disable special processing at the link level with the specified interface. +.It Cm linkstr +Set a link-level string parameter for the interface. +This functionality varies from interface to interface. +Refer to the man page for the specific driver +for more information. +.It Fl linkstr +Remove an interface link-level string parameter. .It Cm up Mark an interface ``up''. This may be used to enable an interface after an ``ifconfig down.'' Index: src/sbin/ifconfig/ifconfig.c diff -u src/sbin/ifconfig/ifconfig.c:1.222 src/sbin/ifconfig/ifconfig.c:1.223 --- src/sbin/ifconfig/ifconfig.c:1.222 Fri Nov 5 13:52:41 2010 +++ src/sbin/ifconfig/ifconfig.c Mon Nov 15 22:42:37 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: ifconfig.c,v 1.222 2010/11/05 13:52:41 pooka Exp $ */ +/* $NetBSD: ifconfig.c,v 1.223 2010/11/15 22:42:37 pooka Exp $ */ /*- * Copyright (c) 1997, 1998, 2000 The NetBSD Foundation, Inc. @@ -63,7 +63,7 @@ #ifndef lint __COPYRIGHT(@(#) Copyright (c) 1983, 1993\ The Regents of the University of California. All rights reserved.); -__RCSID($NetBSD: ifconfig.c,v 1.222 2010/11/05 13:52:41 pooka Exp $); +__RCSID($NetBSD: ifconfig.c,v 1.223 2010/11/15 22:42:37 pooka Exp $); #endif /* not lint */ #include sys/param.h @@ -126,6 +126,8 @@ static int setifmtu(prop_dictionary_t, prop_dictionary_t); static int setifnetmask(prop_dictionary_t, prop_dictionary_t); static int setifprefixlen(prop_dictionary_t, prop_dictionary_t); +static int setlinkstr(prop_dictionary_t, prop_dictionary_t); +static int unsetlinkstr(prop_dictionary_t, prop_dictionary_t); static void status(const struct sockaddr *, prop_dictionary_t, prop_dictionary_t); static void usage(void); @@ -164,6 +166,7 @@ extern struct pbranch opt_command; extern struct pbranch opt_family, opt_silent_family; extern struct pkw cloning, silent_family, family, ifcaps, ifflags, misc; +extern struct pstr parse_linkstr; struct pinteger parse_metric = PINTEGER_INITIALIZER(parse_metric, metric, 10, setifmetric, metric, command_root.pb_parser); @@ -202,6 +205,9 @@ , {.k_word = prefixlen, .k_nextparser = parse_prefixlen.pi_parser} , {.k_word = trailers, .k_neg = true, .k_exec = notrailers, .k_nextparser = command_root.pb_parser} + , {.k_word = linkstr, .k_nextparser = parse_linkstr.ps_parser } + , {.k_word = -linkstr, .k_exec = unsetlinkstr, + .k_nextparser = command_root.pb_parser } }; /* key: clonecmd */ @@ -237,6 +243,9 @@ setifbroadaddr, broadcast, NULL, dstormask, broadcast, command_root.pb_parser); +struct pstr parse_linkstr = PSTR_INITIALIZER(parse_linkstr, linkstr, +setlinkstr, linkstr, command_root.pb_parser); + static SIMPLEQ_HEAD(, afswtch) aflist = SIMPLEQ_HEAD_INITIALIZER(aflist); static SIMPLEQ_HEAD(, usage_func) usage_funcs = @@ -1159,6 +1168,7 @@ statistics_func_t *statistics_f; struct ifdatareq ifdr; struct ifreq ifr; + struct ifdrv ifdrv; char fbuf[BUFSIZ]; int af, s; const char *ifname; @@ -1210,6 +1220,25 @@ print_link_addresses(env, true); + estrlcpy(ifdrv.ifd_name, ifname, sizeof(ifdrv.ifd_name)); + ifdrv.ifd_cmd = IFLINKSTR_QUERYLEN; + ifdrv.ifd_len = 0; + ifdrv.ifd_data = NULL; + /* interface supports linkstr? */ + if (ioctl(s, SIOCGLINKSTR, ifdrv) != -1) { + char *p; + + p = malloc(ifdrv.ifd_len); + if (p == NULL) + err(EXIT_FAILURE, malloc linkstr buf failed); + ifdrv.ifd_data = p; + ifdrv.ifd_cmd = 0; + if (ioctl(s, SIOCGLINKSTR, ifdrv) == -1) + err(EXIT_FAILURE, failed to query linkstr); + printf(\tlinkstr: %s\n, (char *)ifdrv.ifd_data); + free(p); + } + media_status(env,
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 22:45:24 UTC 2010 Modified Files: src/sys/rump/net/lib/libshmif: dumpbus.c Log Message: add -h which prints only the bus header info To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sys/rump/net/lib/libshmif/dumpbus.c 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/net/lib/libshmif/dumpbus.c diff -u src/sys/rump/net/lib/libshmif/dumpbus.c:1.8 src/sys/rump/net/lib/libshmif/dumpbus.c:1.9 --- src/sys/rump/net/lib/libshmif/dumpbus.c:1.8 Fri Aug 13 11:45:47 2010 +++ src/sys/rump/net/lib/libshmif/dumpbus.c Mon Nov 15 22:45:23 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: dumpbus.c,v 1.8 2010/08/13 11:45:47 pooka Exp $ */ +/* $NetBSD: dumpbus.c,v 1.9 2010/11/15 22:45:23 pooka Exp $ */ /* * Little utility to convert shmif bus traffic to a pcap file @@ -26,7 +26,7 @@ usage(void) { - fprintf(stderr, usage: a.out [-p pcapfile]�buspath\n); + fprintf(stderr, usage: a.out [-h]�[-p pcapfile]�buspath\n); exit(1); } @@ -42,9 +42,13 @@ int fd, pfd, i, ch; int bonus; char *buf; + bool hflag = false; - while ((ch = getopt(argc, argv, p:)) != -1) { + while ((ch = getopt(argc, argv, hp:)) != -1) { switch (ch) { + case 'h': + hflag = true; + break; case 'p': pcapfile = optarg; break; @@ -70,11 +74,11 @@ if (fstat(fd, sb) == -1) err(1, stat); - busmem = mmap(NULL, sb.st_size, PROT_READ, MAP_FILE, fd, 0); + busmem = mmap(NULL, sb.st_size, PROT_READ, MAP_FILE|MAP_SHARED, fd, 0); if (busmem == MAP_FAILED) err(1, mmap); - bmem = busmem; + if (bmem-shm_magic != SHMIF_MAGIC) errx(1, %s not a shmif bus, argv[0]); if (bmem-shm_version != SHMIF_VERSION) @@ -85,6 +89,9 @@ bmem-shm_version, bmem-shm_lock, bmem-shm_gen, bmem-shm_first, bmem-shm_last); + if (hflag) + exit(0); + if (pcapfile) { struct pcap_file_header phdr;
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 22:48:06 UTC 2010 Modified Files: src/sys/rump/net/lib/libshmif: Makefile if_shmem.c Log Message: * make interface a cloner * use SIOCSLINKSTR for supplying bus filename in case of cloned if TODO: downing interface, unclone, and some tweaks for robustness To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/rump/net/lib/libshmif/Makefile cvs rdiff -u -r1.28 -r1.29 src/sys/rump/net/lib/libshmif/if_shmem.c 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/net/lib/libshmif/Makefile diff -u src/sys/rump/net/lib/libshmif/Makefile:1.2 src/sys/rump/net/lib/libshmif/Makefile:1.3 --- src/sys/rump/net/lib/libshmif/Makefile:1.2 Thu Aug 12 21:41:47 2010 +++ src/sys/rump/net/lib/libshmif/Makefile Mon Nov 15 22:48:06 2010 @@ -1,9 +1,10 @@ -# $NetBSD: Makefile,v 1.2 2010/08/12 21:41:47 pooka Exp $ +# $NetBSD: Makefile,v 1.3 2010/11/15 22:48:06 pooka Exp $ # LIB= rumpnet_shmif SRCS= if_shmem.c shmif_busops.c +SRCS+= component.c CPPFLAGS+= -I${.CURDIR}/../../../librump/rumpkern Index: src/sys/rump/net/lib/libshmif/if_shmem.c diff -u src/sys/rump/net/lib/libshmif/if_shmem.c:1.28 src/sys/rump/net/lib/libshmif/if_shmem.c:1.29 --- src/sys/rump/net/lib/libshmif/if_shmem.c:1.28 Tue Aug 17 20:42:47 2010 +++ src/sys/rump/net/lib/libshmif/if_shmem.c Mon Nov 15 22:48:06 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: if_shmem.c,v 1.28 2010/08/17 20:42:47 pooka Exp $ */ +/* $NetBSD: if_shmem.c,v 1.29 2010/11/15 22:48:06 pooka Exp $ */ /* * Copyright (c) 2009 Antti Kantee. All Rights Reserved. @@ -28,7 +28,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: if_shmem.c,v 1.28 2010/08/17 20:42:47 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: if_shmem.c,v 1.29 2010/11/15 22:48:06 pooka Exp $); #include sys/param.h #include sys/atomic.h @@ -50,14 +50,17 @@ #include rump_private.h #include rump_net_private.h +static int shmif_clone(struct if_clone *, int); +static int shmif_unclone(struct ifnet *); + +struct if_clone shmif_cloner = +IF_CLONE_INITIALIZER(shmif, shmif_clone, shmif_unclone); + /* * Do r/w prefault for backend pages when attaching the interface. - * This works aroud the most likely kernel/ffs/x86pmap bug described - * in http://mail-index.netbsd.org/tech-kern/2010/08/17/msg008749.html - * - * NOTE: read prefaulting is not enough (that's done always)! + * At least logically thinking improves performance (although no + * mlocking is done, so they might go away). */ - #define PREFAULT_RW /* @@ -79,6 +82,9 @@ int sc_memfd; int sc_kq; + char *sc_backfile; + size_t sc_backfilelen; + uint64_t sc_devgen; uint32_t sc_nextpacket; }; @@ -129,38 +135,64 @@ KASSERT(old == LOCK_LOCKED); } -int -rump_shmif_create(const char *path, int *ifnum) +static int +allocif(int unit, struct shmif_sc **scp) { + uint8_t enaddr[ETHER_ADDR_LEN] = { 0xb2, 0xa0, 0x00, 0x00, 0x00, 0x00 }; struct shmif_sc *sc; struct ifnet *ifp; - uint8_t enaddr[ETHER_ADDR_LEN] = { 0xb2, 0xa0, 0x00, 0x00, 0x00, 0x00 }; uint32_t randnum; - unsigned mynum; - volatile uint8_t v; - volatile uint8_t *p; - int error; + unsigned mynum = unit; randnum = arc4random(); memcpy(enaddr[2], randnum, sizeof(randnum)); - mynum = atomic_inc_uint_nv(numif)-1; sc = kmem_zalloc(sizeof(*sc), KM_SLEEP); + sc-sc_memfd = -1; + ifp = sc-sc_ec.ec_if; memcpy(sc-sc_myaddr, enaddr, sizeof(enaddr)); - sc-sc_memfd = rumpuser_open(path, O_RDWR | O_CREAT, error); - if (sc-sc_memfd == -1) - goto fail; - sc-sc_busmem = rumpuser_filemmap(sc-sc_memfd, 0, BUSMEM_SIZE, + sprintf(ifp-if_xname, shmif%d, mynum); + ifp-if_softc = sc; + ifp-if_flags = IFF_BROADCAST | IFF_MULTICAST; + ifp-if_init = shmif_init; + ifp-if_ioctl = shmif_ioctl; + ifp-if_start = shmif_start; + ifp-if_stop = shmif_stop; + ifp-if_mtu = ETHERMTU; + + if_attach(ifp); + ether_ifattach(ifp, enaddr); + + aprint_verbose(shmif%d: Ethernet address %s\n, + mynum, ether_sprintf(enaddr)); + + if (scp) + *scp = sc; + + return 0; +} + +static int +initbackend(struct shmif_sc *sc, int memfd) +{ + volatile uint8_t v; + volatile uint8_t *p; + int error; + + sc-sc_busmem = rumpuser_filemmap(memfd, 0, BUSMEM_SIZE, RUMPUSER_FILEMMAP_TRUNCATE | RUMPUSER_FILEMMAP_SHARED | RUMPUSER_FILEMMAP_READ | RUMPUSER_FILEMMAP_WRITE, error); if (error) - goto fail; - - if (sc-sc_busmem-shm_magic sc-sc_busmem-shm_magic != SHMIF_MAGIC) - panic(bus is not magical); + return error; + if (sc-sc_busmem-shm_magic + sc-sc_busmem-shm_magic != SHMIF_MAGIC) { + printf(bus is not magical); + rumpuser_unmap(sc-sc_busmem, BUSMEM_SIZE); + return ENOEXEC; + } /* Prefault in pages to minimize runtime penalty with buslock */ for (p = (uint8_t *)sc-sc_busmem; @@ -188,39 +220,88 @@ #endif shmif_unlockbus(sc-sc_busmem); - sc-sc_kq = rumpuser_writewatchfile_setup(-1, sc-sc_memfd, 0, error);
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 22:49:33 UTC 2010 Modified Files: src/sys/rump/net/lib/libshmif: dumpbus.c Log Message: un-\240 To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/rump/net/lib/libshmif/dumpbus.c 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/net/lib/libshmif/dumpbus.c diff -u src/sys/rump/net/lib/libshmif/dumpbus.c:1.9 src/sys/rump/net/lib/libshmif/dumpbus.c:1.10 --- src/sys/rump/net/lib/libshmif/dumpbus.c:1.9 Mon Nov 15 22:45:23 2010 +++ src/sys/rump/net/lib/libshmif/dumpbus.c Mon Nov 15 22:49:33 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: dumpbus.c,v 1.9 2010/11/15 22:45:23 pooka Exp $ */ +/* $NetBSD: dumpbus.c,v 1.10 2010/11/15 22:49:33 pooka Exp $ */ /* * Little utility to convert shmif bus traffic to a pcap file @@ -26,7 +26,7 @@ usage(void) { - fprintf(stderr, usage: a.out [-h]�[-p pcapfile]�buspath\n); + fprintf(stderr, usage: a.out [-h] [-p pcapfile] buspath\n); exit(1); }
CVS commit: src
Module Name:src Committed By: skrll Date: Mon Nov 15 23:07:38 UTC 2010 Modified Files: src/distrib/sets/lists/man: mi src/share/man/man4: Makefile Added Files: src/share/man/man4: nside.4 Log Message: Add a man page for nside(4). To generate a diff of this commit: cvs rdiff -u -r1.1250 -r1.1251 src/distrib/sets/lists/man/mi cvs rdiff -u -r1.534 -r1.535 src/share/man/man4/Makefile cvs rdiff -u -r0 -r1.1 src/share/man/man4/nside.4 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/man/mi diff -u src/distrib/sets/lists/man/mi:1.1250 src/distrib/sets/lists/man/mi:1.1251 --- src/distrib/sets/lists/man/mi:1.1250 Mon Nov 15 21:56:46 2010 +++ src/distrib/sets/lists/man/mi Mon Nov 15 23:07:37 2010 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.1250 2010/11/15 21:56:46 pooka Exp $ +# $NetBSD: mi,v 1.1251 2010/11/15 23:07:37 skrll Exp $ # # Note: don't delete entries from here - mark them as obsolete instead. # @@ -1279,6 +1279,7 @@ ./usr/share/man/cat4/njs.0 man-sys-catman .cat ./usr/share/man/cat4/ns.0 man-obsolete obsolete ./usr/share/man/cat4/nsclpcsio.0 man-sys-catman .cat +./usr/share/man/cat4/nside.0 man-sys-catman .cat ./usr/share/man/cat4/nsip.0 man-obsolete obsolete ./usr/share/man/cat4/nsmb.0 man-sys-catman .cat ./usr/share/man/cat4/nsp.0 man-sys-catman .cat @@ -3936,6 +3937,7 @@ ./usr/share/man/html4/njata.html man-sys-htmlman html ./usr/share/man/html4/njs.html man-sys-htmlman html ./usr/share/man/html4/nsclpcsio.html man-sys-htmlman html +./usr/share/man/html4/nside.html man-sys-htmlman html ./usr/share/man/html4/nsmb.html man-sys-htmlman html ./usr/share/man/html4/nsp.html man-sys-htmlman html ./usr/share/man/html4/nsphy.html man-sys-htmlman html @@ -6455,6 +6457,7 @@ ./usr/share/man/man4/njs.4 man-sys-man .man ./usr/share/man/man4/ns.4 man-obsolete obsolete ./usr/share/man/man4/nsclpcsio.4 man-sys-man .man +./usr/share/man/man4/nside.4 man-sys-man .man ./usr/share/man/man4/nsip.4 man-obsolete obsolete ./usr/share/man/man4/nsmb.4 man-sys-man .man ./usr/share/man/man4/nsp.4 man-sys-man .man Index: src/share/man/man4/Makefile diff -u src/share/man/man4/Makefile:1.534 src/share/man/man4/Makefile:1.535 --- src/share/man/man4/Makefile:1.534 Mon Nov 15 21:52:47 2010 +++ src/share/man/man4/Makefile Mon Nov 15 23:07:38 2010 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.534 2010/11/15 21:52:47 pooka Exp $ +# $NetBSD: Makefile,v 1.535 2010/11/15 23:07:38 skrll Exp $ # @(#)Makefile 8.1 (Berkeley) 6/18/93 MAN= aac.4 ac97.4 acardide.4 aceride.4 acphy.4 \ @@ -40,7 +40,7 @@ midi.4 mii.4 mk48txx.4 mlx.4 mly.4 mpls.4 mpt.4 mpu.4 mtd.4 \ mtio.4 multicast.4 mvsata.4 \ nadb.4 ne.4 neo.4 netintro.4 nfe.4 nfsmb.4 njata.4 njs.4 \ - nsclpcsio.4 nsp.4 nsphy.4 nsphyter.4 ntwoc.4 null.4 nsmb.4 \ + nsclpcsio.4 nside.4 nsp.4 nsphy.4 nsphyter.4 ntwoc.4 null.4 nsmb.4 \ oak.4 oosiop.4 opl.4 options.4 optiide.4 osiop.4 otus.4 \ pad.4 pas.4 pcdisplay.4 pciide.4 pckbc.4 pckbd.4 pcn.4 pcppi.4 \ pcscp.4 pcweasel.4 pdcide.4 pdcsata.4 piixide.4 piixpcib.4 piixpm.4 \ Added files: Index: src/share/man/man4/nside.4 diff -u /dev/null src/share/man/man4/nside.4:1.1 --- /dev/null Mon Nov 15 23:07:38 2010 +++ src/share/man/man4/nside.4 Mon Nov 15 23:07:38 2010 @@ -0,0 +1,48 @@ +.\ $NetBSD: nside.4,v 1.1 2010/11/15 23:07:38 skrll Exp $ +.\ +.\ Copyright (c) 2003 Manuel Bouyer. +.\ +.\ Redistribution and use in source and binary forms, with or without +.\ modification, are permitted provided that the following conditions +.\ are met: +.\ 1. Redistributions of source code must retain the above copyright +.\notice, this list of conditions and the following disclaimer. +.\ 2. Redistributions in binary form must reproduce the above copyright +.\notice, this list of conditions and the following disclaimer in the +.\documentation and/or other materials provided with the distribution. +.\ +.\ THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +.\ IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\ OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\ IN NO EVENT SHALL THE AUTHOR 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. +.\ +.Dd November 15, 2010 +.Dt NSIDE 4 +.Os +.Sh NAME +.Nm nside +.Nd PCI IDE disk controllers driver +.Sh SYNOPSIS +.Cd nside* at pci? dev ? function ? flags 0x +.Sh DESCRIPTION +The +.Nm +driver
CVS commit: src
Module Name:src Committed By: pooka Date: Mon Nov 15 23:10:52 UTC 2010 Modified Files: src/distrib/sets/lists/man: mi src/share/man/man4: Makefile Added Files: src/share/man/man4: shmif.4 Log Message: document shmif, or at least what's implemented so far To generate a diff of this commit: cvs rdiff -u -r1.1251 -r1.1252 src/distrib/sets/lists/man/mi cvs rdiff -u -r1.535 -r1.536 src/share/man/man4/Makefile cvs rdiff -u -r0 -r1.1 src/share/man/man4/shmif.4 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/man/mi diff -u src/distrib/sets/lists/man/mi:1.1251 src/distrib/sets/lists/man/mi:1.1252 --- src/distrib/sets/lists/man/mi:1.1251 Mon Nov 15 23:07:37 2010 +++ src/distrib/sets/lists/man/mi Mon Nov 15 23:10:52 2010 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.1251 2010/11/15 23:07:37 skrll Exp $ +# $NetBSD: mi,v 1.1252 2010/11/15 23:10:52 pooka Exp $ # # Note: don't delete entries from here - mark them as obsolete instead. # @@ -1446,6 +1446,7 @@ ./usr/share/man/cat4/sgimips/wdsc.0 man-sys-catman .cat ./usr/share/man/cat4/sgsmix.0 man-sys-catman .cat ./usr/share/man/cat4/shb.0 man-sys-catman .cat +./usr/share/man/cat4/shmif.0 man-sys-catman .cat ./usr/share/man/cat4/shpcic.0 man-sys-catman .cat ./usr/share/man/cat4/si.0 man-sys-catman .cat ./usr/share/man/cat4/siisata.0 man-sys-catman .cat @@ -4079,6 +4080,7 @@ ./usr/share/man/html4/sgimips/wdsc.html man-sys-htmlman html ./usr/share/man/html4/sgsmix.html man-sys-htmlman html ./usr/share/man/html4/shb.html man-sys-htmlman html +./usr/share/man/html4/shmif.html man-sys-htmlman html ./usr/share/man/html4/shpcic.html man-sys-htmlman html ./usr/share/man/html4/si.html man-sys-htmlman html ./usr/share/man/html4/siisata.html man-sys-htmlman html @@ -6624,6 +6626,7 @@ ./usr/share/man/man4/sgimips/wdsc.4 man-sys-man .man ./usr/share/man/man4/sgsmix.4 man-sys-man .man ./usr/share/man/man4/shb.4 man-sys-man .man +./usr/share/man/man4/shmif.4 man-sys-man .man ./usr/share/man/man4/shpcic.4 man-sys-man .man ./usr/share/man/man4/si.4 man-sys-man .man ./usr/share/man/man4/siisata.4 man-sys-man .man Index: src/share/man/man4/Makefile diff -u src/share/man/man4/Makefile:1.535 src/share/man/man4/Makefile:1.536 --- src/share/man/man4/Makefile:1.535 Mon Nov 15 23:07:38 2010 +++ src/share/man/man4/Makefile Mon Nov 15 23:10:51 2010 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.535 2010/11/15 23:07:38 skrll Exp $ +# $NetBSD: Makefile,v 1.536 2010/11/15 23:10:51 pooka Exp $ # @(#)Makefile 8.1 (Berkeley) 6/18/93 MAN= aac.4 ac97.4 acardide.4 aceride.4 acphy.4 \ @@ -50,7 +50,7 @@ raid.4 ral.4 ray.4 rcons.4 re.4 rgephy.4 rlphy.4 rnd.4 route.4 \ rs5c372rtc.4 rtk.4 rtw.4 rum.4 \ satalink.4 sbus.4 scc.4 schide.4 scsi.4 sd.4 se.4 seeprom.4 sem.4 \ - ses.4 sf.4 sfb.4 sgsmix.4 shb.4 \ + ses.4 sf.4 sfb.4 sgsmix.4 shb.4 shmif.4 \ shpcic.4 siisata.4 siop.4 sip.4 siside.4 sk.4 sl.4 slide.4 \ sm.4 smsh.4 sn.4 sony.4 spc.4 speaker.4 spif.4 sqphy.4 ss.4 \ st.4 ste.4 stge.4 sti.4 stpcide.4 sv.4 strip.4 \ Added files: Index: src/share/man/man4/shmif.4 diff -u /dev/null src/share/man/man4/shmif.4:1.1 --- /dev/null Mon Nov 15 23:10:52 2010 +++ src/share/man/man4/shmif.4 Mon Nov 15 23:10:51 2010 @@ -0,0 +1,85 @@ +.\ $NetBSD: shmif.4,v 1.1 2010/11/15 23:10:51 pooka Exp $ +.\ +.\ Copyright (c) 2010 Antti Kantee +.\ All rights reserved. +.\ +.\ Redistribution and use in source and binary forms, with or without +.\ modification, are permitted provided that the following conditions +.\ are met: +.\ 1. Redistributions of source code must retain the above copyright +.\notice, this list of conditions and the following disclaimer. +.\ 2. Redistributions in binary form must reproduce the above copyright +.\notice, this list of conditions and the following disclaimer in the +.\documentation and/or other materials provided with the distribution. +.\ +.\ THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +.\ IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\ OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\ IN NO EVENT SHALL THE AUTHOR 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. +.\ +.Dd November 15, 2010 +.Dt SHMIF 4 +.Os +.Sh NAME +.Nm shmif +.Nd rump shared memory network interface +.Sh SYNOPSIS +.In rump/rump.h +.Ft int +.Fo rump_pub_shmif_create +.Fa const char *path
CVS commit: src/sys/dev/pci
Module Name:src Committed By: macallan Date: Mon Nov 15 23:19:33 UTC 2010 Modified Files: src/sys/dev/pci: r128fb.c Log Message: explicitly set and clear the backlight on bit, just in case someone messes with it while we're not looking To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/dev/pci/r128fb.c 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/pci/r128fb.c diff -u src/sys/dev/pci/r128fb.c:1.15 src/sys/dev/pci/r128fb.c:1.16 --- src/sys/dev/pci/r128fb.c:1.15 Sat Nov 13 13:52:08 2010 +++ src/sys/dev/pci/r128fb.c Mon Nov 15 23:19:33 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: r128fb.c,v 1.15 2010/11/13 13:52:08 uebayasi Exp $ */ +/* $NetBSD: r128fb.c,v 1.16 2010/11/15 23:19:33 macallan Exp $ */ /* * Copyright (c) 2007 Michael Lorenz @@ -31,7 +31,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: r128fb.c,v 1.15 2010/11/13 13:52:08 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: r128fb.c,v 1.16 2010/11/15 23:19:33 macallan Exp $); #include sys/param.h #include sys/systm.h @@ -306,8 +306,9 @@ /* no suspend/resume support yet */ pmf_device_register(sc-sc_dev, NULL, NULL); + reg = bus_space_read_4(sc-sc_memt, sc-sc_regh, R128_LVDS_GEN_CNTL); - DPRINTF(reg: %08x\n, reg); + DPRINTF(R128_LVDS_GEN_CNTL: %08x\n, reg); if (reg R128_LVDS_ON) { sc-sc_have_backlight = 1; sc-sc_bl_on = 1; @@ -381,6 +382,7 @@ if (new_mode != sc-sc_mode) { sc-sc_mode = new_mode; if(new_mode == WSDISPLAYIO_MODE_EMUL) { + r128fb_init(sc); r128fb_restore_palette(sc); vcons_redraw_screen(ms); } @@ -957,7 +959,8 @@ level = 255 - level; reg = bus_space_read_4(sc-sc_memt, sc-sc_regh, R128_LVDS_GEN_CNTL); reg = ~R128_LEVEL_MASK; - reg |= level R128_LEVEL_SHIFT; + reg |= (level R128_LEVEL_SHIFT) | + (level != 255 ? R128_LVDS_BLON : 0); bus_space_write_4(sc-sc_memt, sc-sc_regh, R128_LVDS_GEN_CNTL, reg); DPRINTF(backlight level: %d reg %08x\n, level, reg); } @@ -973,6 +976,10 @@ sc-sc_bl_on = on; reg = bus_space_read_4(sc-sc_memt, sc-sc_regh, R128_LVDS_GEN_CNTL); reg = ~R128_LEVEL_MASK; + if (on) { + reg |= R128_LVDS_BLON; + } else + reg = ~R128_LVDS_BLON; level = on ? 255 - sc-sc_bl_level : 255; reg |= level R128_LEVEL_SHIFT; bus_space_write_4(sc-sc_memt, sc-sc_regh, R128_LVDS_GEN_CNTL, reg);
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 23:51:07 UTC 2010 Added Files: src/sys/rump/net/lib/libshmif: component.c Log Message: remember to commit this file too To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/rump/net/lib/libshmif/component.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Added files: Index: src/sys/rump/net/lib/libshmif/component.c diff -u /dev/null src/sys/rump/net/lib/libshmif/component.c:1.1 --- /dev/null Mon Nov 15 23:51:07 2010 +++ src/sys/rump/net/lib/libshmif/component.c Mon Nov 15 23:51:06 2010 @@ -0,0 +1,45 @@ +/* $NetBSD: component.c,v 1.1 2010/11/15 23:51:06 pooka Exp $ */ + +/* + * Copyright (c) 2010 Antti Kantee. All Rights Reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS + * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL 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 sys/cdefs.h +__KERNEL_RCSID(0, $NetBSD: component.c,v 1.1 2010/11/15 23:51:06 pooka Exp $); + +#include sys/param.h +#include sys/domain.h +#include sys/protosw.h + +#include net/if.h + +#include rump_private.h +#include rump_net_private.h + +RUMP_COMPONENT(RUMP_COMPONENT_NET_IF) +{ + extern struct if_clone shmif_cloner; /* XXX */ + + if_clone_attach(shmif_cloner); +}
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 23:59:06 UTC 2010 Modified Files: src/sys/rump/net/lib/libshmif: if_shmem.c Log Message: fix completely crackheaded code w/ uninitialized use, missed as usual by the wonderful -g -O0 To generate a diff of this commit: cvs rdiff -u -r1.29 -r1.30 src/sys/rump/net/lib/libshmif/if_shmem.c 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/net/lib/libshmif/if_shmem.c diff -u src/sys/rump/net/lib/libshmif/if_shmem.c:1.29 src/sys/rump/net/lib/libshmif/if_shmem.c:1.30 --- src/sys/rump/net/lib/libshmif/if_shmem.c:1.29 Mon Nov 15 22:48:06 2010 +++ src/sys/rump/net/lib/libshmif/if_shmem.c Mon Nov 15 23:59:06 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: if_shmem.c,v 1.29 2010/11/15 22:48:06 pooka Exp $ */ +/* $NetBSD: if_shmem.c,v 1.30 2010/11/15 23:59:06 pooka Exp $ */ /* * Copyright (c) 2009 Antti Kantee. All Rights Reserved. @@ -28,7 +28,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: if_shmem.c,v 1.29 2010/11/15 22:48:06 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: if_shmem.c,v 1.30 2010/11/15 23:59:06 pooka Exp $); #include sys/param.h #include sys/atomic.h @@ -277,11 +277,10 @@ static int shmif_clone(struct if_clone *ifc, int unit) { - int mynum; /* not atomic against rump_shmif_create(). so don't do it. */ - if (unit = mynum) - mynum = unit+1; + if (unit = numif) + numif = unit+1; return allocif(unit, NULL); }
CVS commit: src/sys/rump/librump/rumpkern
Module Name:src Committed By: uebayasi Date: Tue Nov 16 01:12:57 UTC 2010 Modified Files: src/sys/rump/librump/rumpkern: vm.c Log Message: Define uvmexp_pagemask and friends used by sparc to set PAGE_SIZE, PAGE_MASK, PAGE_SHIFT dynamically. To generate a diff of this commit: cvs rdiff -u -r1.99 -r1.100 src/sys/rump/librump/rumpkern/vm.c 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/librump/rumpkern/vm.c diff -u src/sys/rump/librump/rumpkern/vm.c:1.99 src/sys/rump/librump/rumpkern/vm.c:1.100 --- src/sys/rump/librump/rumpkern/vm.c:1.99 Fri Nov 12 05:23:41 2010 +++ src/sys/rump/librump/rumpkern/vm.c Tue Nov 16 01:12:57 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: vm.c,v 1.99 2010/11/12 05:23:41 uebayasi Exp $ */ +/* $NetBSD: vm.c,v 1.100 2010/11/16 01:12:57 uebayasi Exp $ */ /* * Copyright (c) 2007-2010 Antti Kantee. All Rights Reserved. @@ -41,7 +41,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: vm.c,v 1.99 2010/11/12 05:23:41 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: vm.c,v 1.100 2010/11/16 01:12:57 uebayasi Exp $); #include sys/param.h #include sys/atomic.h @@ -69,6 +69,9 @@ kmutex_t uvm_swap_data_lock; struct uvmexp uvmexp; +int *uvmexp_pagesize; +int *uvmexp_pagemask; +int *uvmexp_pageshift; struct uvm uvm; struct vm_map rump_vmmap;
CVS commit: [uebayasi-xip] src/sys/arch/m68k/m68k
Module Name:src Committed By: uebayasi Date: Tue Nov 16 02:47:24 UTC 2010 Modified Files: src/sys/arch/m68k/m68k [uebayasi-xip]: bus_dma.c Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.29.18.1 -r1.29.18.2 src/sys/arch/m68k/m68k/bus_dma.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/m68k/m68k/bus_dma.c diff -u src/sys/arch/m68k/m68k/bus_dma.c:1.29.18.1 src/sys/arch/m68k/m68k/bus_dma.c:1.29.18.2 --- src/sys/arch/m68k/m68k/bus_dma.c:1.29.18.1 Tue Aug 17 06:44:47 2010 +++ src/sys/arch/m68k/m68k/bus_dma.c Tue Nov 16 02:47:24 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: bus_dma.c,v 1.29.18.1 2010/08/17 06:44:47 uebayasi Exp $ */ +/* $NetBSD: bus_dma.c,v 1.29.18.2 2010/11/16 02:47:24 uebayasi Exp $ */ /* * This file was taken from from alpha/common/bus_dma.c @@ -41,7 +41,7 @@ #include sys/cdefs.h /* RCS ID Copyright macro defns */ -__KERNEL_RCSID(0, $NetBSD: bus_dma.c,v 1.29.18.1 2010/08/17 06:44:47 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: bus_dma.c,v 1.29.18.2 2010/11/16 02:47:24 uebayasi Exp $); #include sys/param.h #include sys/systm.h @@ -51,7 +51,7 @@ #include sys/proc.h #include sys/mbuf.h -#include uvm/uvm_extern.h +#include uvm/uvm.h #include machine/cpu.h
CVS commit: [uebayasi-xip] src/sys/arch/mips/mips
Module Name:src Committed By: uebayasi Date: Tue Nov 16 02:47:40 UTC 2010 Modified Files: src/sys/arch/mips/mips [uebayasi-xip]: bus_dma.c Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.23 -r1.23.2.1 src/sys/arch/mips/mips/bus_dma.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/mips/mips/bus_dma.c diff -u src/sys/arch/mips/mips/bus_dma.c:1.23 src/sys/arch/mips/mips/bus_dma.c:1.23.2.1 --- src/sys/arch/mips/mips/bus_dma.c:1.23 Mon Dec 14 00:46:05 2009 +++ src/sys/arch/mips/mips/bus_dma.c Tue Nov 16 02:47:40 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: bus_dma.c,v 1.23 2009/12/14 00:46:05 matt Exp $ */ +/* $NetBSD: bus_dma.c,v 1.23.2.1 2010/11/16 02:47:40 uebayasi Exp $ */ /*- * Copyright (c) 1997, 1998, 2001 The NetBSD Foundation, Inc. @@ -32,7 +32,7 @@ #include sys/cdefs.h /* RCS ID Copyright macro defns */ -__KERNEL_RCSID(0, $NetBSD: bus_dma.c,v 1.23 2009/12/14 00:46:05 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: bus_dma.c,v 1.23.2.1 2010/11/16 02:47:40 uebayasi Exp $); #include sys/param.h #include sys/systm.h @@ -42,7 +42,7 @@ #include sys/proc.h #include sys/mbuf.h -#include uvm/uvm_extern.h +#include uvm/uvm.h #include mips/cache.h #ifdef _LP64
CVS commit: src/sys/arch/arm/s3c2xx0
Module Name:src Committed By: bsh Date: Tue Nov 16 02:53:02 UTC 2010 Modified Files: src/sys/arch/arm/s3c2xx0: s3c2xx0var.h Log Message: make SMDK2410 kernel compile again after changes to sys/param.h To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/s3c2xx0/s3c2xx0var.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/arch/arm/s3c2xx0/s3c2xx0var.h diff -u src/sys/arch/arm/s3c2xx0/s3c2xx0var.h:1.4 src/sys/arch/arm/s3c2xx0/s3c2xx0var.h:1.5 --- src/sys/arch/arm/s3c2xx0/s3c2xx0var.h:1.4 Sun Dec 11 12:16:51 2005 +++ src/sys/arch/arm/s3c2xx0/s3c2xx0var.h Tue Nov 16 02:53:02 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: s3c2xx0var.h,v 1.4 2005/12/11 12:16:51 christos Exp $ */ +/* $NetBSD: s3c2xx0var.h,v 1.5 2010/11/16 02:53:02 bsh Exp $ */ /* * Copyright (c) 2002 Fujitsu Component Limited @@ -36,6 +36,7 @@ #define _ARM_S3C2XX0VAR_H_ #include machine/bus.h +#include sys/device.h struct s3c2xx0_softc { struct device sc_dev;
CVS commit: src/usr.bin/env
Module Name:src Committed By: christos Date: Tue Nov 16 02:53:49 UTC 2010 Modified Files: src/usr.bin/env: env.c Log Message: minor KNF nits. To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/usr.bin/env/env.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.bin/env/env.c diff -u src/usr.bin/env/env.c:1.19 src/usr.bin/env/env.c:1.20 --- src/usr.bin/env/env.c:1.19 Sat Oct 16 07:13:52 2010 +++ src/usr.bin/env/env.c Mon Nov 15 21:53:49 2010 @@ -35,7 +35,7 @@ #ifndef lint /*static char sccsid[] = @(#)env.c 8.3 (Berkeley) 4/2/94;*/ -__RCSID($NetBSD: env.c,v 1.19 2010/10/16 11:13:52 njoly Exp $); +__RCSID($NetBSD: env.c,v 1.20 2010/11/16 02:53:49 christos Exp $); #endif /* not lint */ #include err.h @@ -46,8 +46,7 @@ #include locale.h #include errno.h -int main(int, char **); -static void usage(void); +static void usage(void) __attribute__((__noreturn__)); extern char **environ; @@ -58,7 +57,8 @@ char *cleanenv[1]; int ch; - setlocale(LC_ALL, ); + setprogname(*argv); + (void)setlocale(LC_ALL, ); while ((ch = getopt(argc, argv, -i)) != -1) switch((char)ch) { @@ -79,7 +79,7 @@ /* return 127 if the command to be run could not be found; 126 if the command was found but could not be invoked */ - execvp(*argv, argv); + (void)execvp(*argv, argv); err((errno == ENOENT) ? 127 : 126, %s, *argv); /* NOTREACHED */ } @@ -93,6 +93,7 @@ static void usage(void) { - (void)fprintf(stderr, usage: env [-i] [name=value ...] [command]\n); + (void)fprintf(stderr, Usage: %s [-i] [name=value ...] [command]\n, + getprogname()); exit(1); }
CVS commit: src/lib/libc/stdlib
Module Name:src Committed By: enami Date: Tue Nov 16 03:02:20 UTC 2010 Modified Files: src/lib/libc/stdlib: _env.c Log Message: Fix typos in comment. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/lib/libc/stdlib/_env.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/libc/stdlib/_env.c diff -u src/lib/libc/stdlib/_env.c:1.2 src/lib/libc/stdlib/_env.c:1.3 --- src/lib/libc/stdlib/_env.c:1.2 Sun Nov 14 22:04:36 2010 +++ src/lib/libc/stdlib/_env.c Tue Nov 16 03:02:20 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: _env.c,v 1.2 2010/11/14 22:04:36 tron Exp $ */ +/* $NetBSD: _env.c,v 1.3 2010/11/16 03:02:20 enami Exp $ */ /*- * Copyright (c) 2010 The NetBSD Foundation, Inc. @@ -73,7 +73,7 @@ #define ENV_ARRAY_SIZE_MIN 16 -/* The lock protecting accces to the environment. */ +/* The lock protecting access to the environment. */ #ifdef _REENTRANT static rwlock_t env_lock = RWLOCK_INITIALIZER; #endif @@ -176,9 +176,9 @@ } /* - * Check whether an enviroment variable is writable. This function must be + * Check whether an environment variable is writable. This function must be * called with the environment write locked as the caller will probably - * overwrite the enviroment variable afterwards. + * overwrite the environment variable afterwards. */ bool __canoverwriteenvvar(char *envvar, size_t length) @@ -265,7 +265,7 @@ (void)memset(new_environ[num_entries], 0, (new_size - num_entries) * sizeof(*new_environ)); - /* Use the new environent array. */ + /* Use the new environment array. */ environ = allocated_environ = new_environ; allocated_environ_size = new_size;
CVS commit: [uebayasi-xip] src/sys/uvm
Module Name:src Committed By: uebayasi Date: Tue Nov 16 03:03:28 UTC 2010 Modified Files: src/sys/uvm [uebayasi-xip]: uvm_init.c uvm_param.h Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.36 -r1.36.2.1 src/sys/uvm/uvm_init.c cvs rdiff -u -r1.22 -r1.22.2.1 src/sys/uvm/uvm_param.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/uvm/uvm_init.c diff -u src/sys/uvm/uvm_init.c:1.36 src/sys/uvm/uvm_init.c:1.36.2.1 --- src/sys/uvm/uvm_init.c:1.36 Wed Oct 21 21:12:07 2009 +++ src/sys/uvm/uvm_init.c Tue Nov 16 03:03:28 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: uvm_init.c,v 1.36 2009/10/21 21:12:07 rmind Exp $ */ +/* $NetBSD: uvm_init.c,v 1.36.2.1 2010/11/16 03:03:28 uebayasi Exp $ */ /* * @@ -39,7 +39,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: uvm_init.c,v 1.36 2009/10/21 21:12:07 rmind Exp $); +__KERNEL_RCSID(0, $NetBSD: uvm_init.c,v 1.36.2.1 2010/11/16 03:03:28 uebayasi Exp $); #include sys/param.h #include sys/systm.h @@ -66,6 +66,12 @@ struct uvmexp uvmexp; /* decl */ struct uvm_object *uvm_kernel_object; +#if defined(__uvmexp_pagesize) +int *uvmexp_pagesize = uvmexp.pagesize; +int *uvmexp_pagemask = uvmexp.pagemask; +int *uvmexp_pageshift = uvmexp.pageshift; +#endif + kmutex_t uvm_pageqlock; kmutex_t uvm_fpageqlock; kmutex_t uvm_kentry_lock; Index: src/sys/uvm/uvm_param.h diff -u src/sys/uvm/uvm_param.h:1.22 src/sys/uvm/uvm_param.h:1.22.2.1 --- src/sys/uvm/uvm_param.h:1.22 Mon Jul 20 03:51:42 2009 +++ src/sys/uvm/uvm_param.h Tue Nov 16 03:03:28 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: uvm_param.h,v 1.22 2009/07/20 03:51:42 kiyohara Exp $ */ +/* $NetBSD: uvm_param.h,v 1.22.2.1 2010/11/16 03:03:28 uebayasi Exp $ */ /* * Copyright (c) 1991, 1993 @@ -72,7 +72,6 @@ #endif #ifdef _KERNEL #include sys/types.h -#include sys/lock.h #include machine/vmparam.h #include sys/resourcevar.h #endif @@ -146,9 +145,13 @@ * have ones that are compile-time constants. */ #if !defined(PAGE_SIZE) -#define PAGE_SIZE uvmexp.pagesize /* size of page */ -#define PAGE_MASK uvmexp.pagemask /* size of page - 1 */ -#define PAGE_SHIFT uvmexp.pageshift /* bits to shift for pages */ +extern int *uvmexp_pagesize; +extern int *uvmexp_pagemask; +extern int *uvmexp_pageshift; +#define PAGE_SIZE (*uvmexp_pagesize) /* size of page */ +#define PAGE_MASK (*uvmexp_pagemask) /* size of page - 1 */ +#define PAGE_SHIFT (*uvmexp_pageshift) /* bits to shift for pages */ +#define __uvmexp_pagesize #endif /* PAGE_SIZE */ #endif /* _KERNEL */
CVS commit: src/sys/uvm
Module Name:src Committed By: enami Date: Tue Nov 16 03:49:54 UTC 2010 Modified Files: src/sys/uvm: uvm_meter.c Log Message: Nowadays, comparing priority against PZERO doesn't make any sense. Instead, see if a process waits uninterruptibly like ps does, so that the second column (`b') of default vmstat output prints some useful value (-t is still broken though). To generate a diff of this commit: cvs rdiff -u -r1.53 -r1.54 src/sys/uvm/uvm_meter.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/uvm/uvm_meter.c diff -u src/sys/uvm/uvm_meter.c:1.53 src/sys/uvm/uvm_meter.c:1.54 --- src/sys/uvm/uvm_meter.c:1.53 Sat Nov 6 12:18:17 2010 +++ src/sys/uvm/uvm_meter.c Tue Nov 16 03:49:53 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: uvm_meter.c,v 1.53 2010/11/06 12:18:17 uebayasi Exp $ */ +/* $NetBSD: uvm_meter.c,v 1.54 2010/11/16 03:49:53 enami Exp $ */ /* * Copyright (c) 1997 Charles D. Cranor and Washington University. @@ -41,7 +41,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: uvm_meter.c,v 1.53 2010/11/06 12:18:17 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: uvm_meter.c,v 1.54 2010/11/16 03:49:53 enami Exp $); #include sys/param.h #include sys/proc.h @@ -310,7 +310,7 @@ case LSSLEEP: case LSSTOP: - if (lwp_eprio(l) = PZERO) { + if ((l-l_flag LW_SINTR) == 0) { totalp-t_dw++; } else if (l-l_slptime maxslp) { totalp-t_sl++;
CVS commit: [uebayasi-xip] src/sys
Module Name:src Committed By: uebayasi Date: Tue Nov 16 07:44:26 UTC 2010 Modified Files: src/sys/miscfs/genfs [uebayasi-xip]: genfs_io.c src/sys/uvm [uebayasi-xip]: uvm_extern.h uvm_vnode.c Log Message: Factor out the part which lookups physical page identity from UVM object, into sys/uvm/uvm_vnode.c:uvn_findpage_xip(). Eventually this will become a call to cdev UVM object pager. To generate a diff of this commit: cvs rdiff -u -r1.36.2.31 -r1.36.2.32 src/sys/miscfs/genfs/genfs_io.c cvs rdiff -u -r1.161.2.11 -r1.161.2.12 src/sys/uvm/uvm_extern.h cvs rdiff -u -r1.93.2.2 -r1.93.2.3 src/sys/uvm/uvm_vnode.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/miscfs/genfs/genfs_io.c diff -u src/sys/miscfs/genfs/genfs_io.c:1.36.2.31 src/sys/miscfs/genfs/genfs_io.c:1.36.2.32 --- src/sys/miscfs/genfs/genfs_io.c:1.36.2.31 Mon Nov 15 17:32:01 2010 +++ src/sys/miscfs/genfs/genfs_io.c Tue Nov 16 07:44:25 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: genfs_io.c,v 1.36.2.31 2010/11/15 17:32:01 uebayasi Exp $ */ +/* $NetBSD: genfs_io.c,v 1.36.2.32 2010/11/16 07:44:25 uebayasi Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1993 @@ -31,7 +31,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: genfs_io.c,v 1.36.2.31 2010/11/15 17:32:01 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: genfs_io.c,v 1.36.2.32 2010/11/16 07:44:25 uebayasi Exp $); #include opt_xip.h @@ -869,29 +869,20 @@ * XIP page metadata assignment * - Unallocated block is redirected to the dedicated zero'ed * page. - * - Assume that struct vm_page *[] array of this segment is - * allocated and linearly ordered by physical address. */ if (blkno 0) { zero_page = uvm_page_zeropage_alloc(); KASSERT(zero_page != NULL); pps[i] = zero_page; } else { - struct vm_physseg *seg; - daddr_t seg_off; - struct vm_page *pg; - - seg = devvp-v_physseg; - KASSERT(seg != NULL); - /* bus_space_mmap cookie - paddr_t */ - seg_off = (blkno dev_bshift) + - (off - (lbn fs_bshift)); - KASSERT((seg_off PAGE_MASK) == 0); - pg = seg-pgs + (seg_off PAGE_SHIFT); - KASSERT(pg-phys_addr == - (seg-start PAGE_SHIFT) + seg_off); + daddr_t blk_off, fs_off; - pps[i] = pg; + blk_off = blkno dev_bshift; + fs_off = off - (lbn fs_bshift); + + pps[i] = uvn_findpage_xip(devvp-v_uobj, + blk_off + fs_off); + KASSERT(pps[i] != NULL); } UVMHIST_LOG(ubchist, xip pgs %d = phys_addr=0x%lx (%p), Index: src/sys/uvm/uvm_extern.h diff -u src/sys/uvm/uvm_extern.h:1.161.2.11 src/sys/uvm/uvm_extern.h:1.161.2.12 --- src/sys/uvm/uvm_extern.h:1.161.2.11 Mon Nov 15 08:41:44 2010 +++ src/sys/uvm/uvm_extern.h Tue Nov 16 07:44:24 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: uvm_extern.h,v 1.161.2.11 2010/11/15 08:41:44 uebayasi Exp $ */ +/* $NetBSD: uvm_extern.h,v 1.161.2.12 2010/11/16 07:44:24 uebayasi Exp $ */ /* * @@ -763,6 +763,7 @@ bool uvn_text_p(struct uvm_object *); bool uvn_clean_p(struct uvm_object *); bool uvn_needs_writefault_p(struct uvm_object *); +struct vm_page *uvn_findpage_xip(struct uvm_object *, off_t); /* kern_malloc.c */ void kmeminit_nkmempages(void); Index: src/sys/uvm/uvm_vnode.c diff -u src/sys/uvm/uvm_vnode.c:1.93.2.2 src/sys/uvm/uvm_vnode.c:1.93.2.3 --- src/sys/uvm/uvm_vnode.c:1.93.2.2 Wed Aug 25 14:21:23 2010 +++ src/sys/uvm/uvm_vnode.c Tue Nov 16 07:44:25 2010 @@ -1,4 +1,4 @@ -/* $NetBSD: uvm_vnode.c,v 1.93.2.2 2010/08/25 14:21:23 uebayasi Exp $ */ +/* $NetBSD: uvm_vnode.c,v 1.93.2.3 2010/11/16 07:44:25 uebayasi Exp $ */ /* * Copyright (c) 1997 Charles D. Cranor and Washington University. @@ -50,7 +50,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: uvm_vnode.c,v 1.93.2.2 2010/08/25 14:21:23 uebayasi Exp $); +__KERNEL_RCSID(0, $NetBSD: uvm_vnode.c,v 1.93.2.3 2010/11/16 07:44:25 uebayasi Exp $); #include opt_uvmhist.h #include opt_xip.h @@ -404,3 +404,39 @@ return uvn_clean_p(uobj) || (vp-v_iflag (VI_WRMAP|VI_WRMAPDIRTY)) == VI_WRMAP; } + +/* + * uvn_findpage_xip + * Lookup a physical page identity (== struct vm_page * in + * the current UVM design) within the given vnode, at the + * given offset. + */ +struct vm_page * +uvn_findpage_xip(struct uvm_object *uobj, off_t off) +{ + struct vnode *vp = (struct vnode *)uobj; + struct vm_physseg *seg; + struct vm_page *pg; + + KASSERT((vp-v_vflag VV_XIP) != 0); + KASSERT((off PAGE_MASK) == 0); + + /* + * Lookup a physical page identity from the underlying physical + * segment. + * + * Eventually, this will be replaced by a call of character + * device pager method, which is a generalized version of + * cdev_mmap(). Which means that v_physseg will become struct + * uvm_object *, and this will call cdev_page(uobj, off). + */ + + seg = vp-v_physseg; + KASSERT(seg != NULL); + + pg = seg-pgs + (off PAGE_SHIFT); + + KASSERT(pg-phys_addr == (seg-start PAGE_SHIFT)
CVS commit: src/crypto/external/bsd/netpgp/dist/src/lib
Module Name:src Committed By: agc Date: Mon Nov 15 08:27:40 UTC 2010 Modified Files: src/crypto/external/bsd/netpgp/dist/src/lib: netpgp.c Log Message: Use a regular expression to match the various ASCII-armoured headers we may encounter - fixes PR 44074 from Peter Pentchev in a different way. To generate a diff of this commit: cvs rdiff -u -r1.83 -r1.84 \ src/crypto/external/bsd/netpgp/dist/src/lib/netpgp.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/doc
Module Name:src Committed By: uebayasi Date: Mon Nov 15 08:35:52 UTC 2010 Modified Files: src/doc: BRANCHES Log Message: uebayasi-xip: update. To generate a diff of this commit: cvs rdiff -u -r1.298 -r1.299 src/doc/BRANCHES Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src/sys/uvm
Module Name:src Committed By: uebayasi Date: Mon Nov 15 08:41:44 UTC 2010 Modified Files: src/sys/uvm [uebayasi-xip]: uvm_extern.h Log Message: Hide uvm/uvm_page.h here again. To generate a diff of this commit: cvs rdiff -u -r1.161.2.10 -r1.161.2.11 src/sys/uvm/uvm_extern.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/crypto/external/bsd/netpgp/dist/src/lib
Module Name:src Committed By: agc Date: Mon Nov 15 08:56:30 UTC 2010 Modified Files: src/crypto/external/bsd/netpgp/dist/src/lib: crypto.h packet-parse.c packet.h types.h Log Message: There were still some throwbacks with the prefix '_ops' - rectify that to be the standard pgp_ - no functional change. To generate a diff of this commit: cvs rdiff -u -r1.28 -r1.29 \ src/crypto/external/bsd/netpgp/dist/src/lib/crypto.h cvs rdiff -u -r1.49 -r1.50 \ src/crypto/external/bsd/netpgp/dist/src/lib/packet-parse.c cvs rdiff -u -r1.29 -r1.30 \ src/crypto/external/bsd/netpgp/dist/src/lib/packet.h cvs rdiff -u -r1.10 -r1.11 \ src/crypto/external/bsd/netpgp/dist/src/lib/types.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/arm/pic
Module Name:src Committed By: bsh Date: Mon Nov 15 09:25:58 UTC 2010 Modified Files: src/sys/arch/arm/pic: picvar.h Log Message: fix compile error about missing evcnt definition. picvar.h is now included very early because of uebayashi's change to sys/param.h. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/pic/picvar.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/arm/omap
Module Name:src Committed By: bsh Date: Mon Nov 15 09:34:28 UTC 2010 Modified Files: src/sys/arch/arm/omap: omap2_icu.c omap2_intr.h Log Message: don't include arm/cpu.h which requires SOFTINT_COUNT before sys/intr.h is fully included. This change makes Beagleboard kernel compile again after uebayashi's change to sys/param.h. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/omap/omap2_icu.c \ src/sys/arch/arm/omap/omap2_intr.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/x86/include
Module Name:src Committed By: cegger Date: Mon Nov 15 11:58:10 UTC 2010 Modified Files: src/sys/arch/x86/include: i82489reg.h Log Message: add interrupt EAPIC register definitions To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/x86/include/i82489reg.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/sets/lists/xserver
Module Name:src Committed By: njoly Date: Mon Nov 15 12:23:06 UTC 2010 Modified Files: src/distrib/sets/lists/xserver: md.macppc md.ofppc md.sgimips md.sparc md.sparc64 Log Message: Remove unneeded xfree/xorg dga(1) entries from xserver md lists. To generate a diff of this commit: cvs rdiff -u -r1.56 -r1.57 src/distrib/sets/lists/xserver/md.macppc cvs rdiff -u -r1.8 -r1.9 src/distrib/sets/lists/xserver/md.ofppc cvs rdiff -u -r1.38 -r1.39 src/distrib/sets/lists/xserver/md.sgimips cvs rdiff -u -r1.47 -r1.48 src/distrib/sets/lists/xserver/md.sparc cvs rdiff -u -r1.44 -r1.45 src/distrib/sets/lists/xserver/md.sparc64 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/doc
Module Name:src Committed By: uebayasi Date: Mon Nov 15 14:40:36 UTC 2010 Modified Files: src/doc: BRANCHES Log Message: uebayasi-xip: rebase. To generate a diff of this commit: cvs rdiff -u -r1.299 -r1.300 src/doc/BRANCHES Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src
Module Name:src Committed By: uebayasi Date: Mon Nov 15 15:11:54 UTC 2010 Modified Files: src/share/man/man9 [uebayasi-xip]: pmap.9 src/sys/arch/acorn26/acorn26 [uebayasi-xip]: mem.c pmap.c src/sys/arch/alpha/alpha [uebayasi-xip]: mem.c pmap.c src/sys/arch/amd64/amd64 [uebayasi-xip]: mem.c src/sys/arch/arm/arm32 [uebayasi-xip]: mem.c pmap.c src/sys/uvm [uebayasi-xip]: files.uvm uvm_pmap.h Removed Files: src/sys/common/pmap [uebayasi-xip]: pmap_common.c src/sys/dev [uebayasi-xip]: xmd.c Log Message: Revert xmd(4). To generate a diff of this commit: cvs rdiff -u -r1.42.2.2 -r1.42.2.3 src/share/man/man9/pmap.9 cvs rdiff -u -r1.14.2.1 -r1.14.2.2 src/sys/arch/acorn26/acorn26/mem.c cvs rdiff -u -r1.30.2.5 -r1.30.2.6 src/sys/arch/acorn26/acorn26/pmap.c cvs rdiff -u -r1.40.2.1 -r1.40.2.2 src/sys/arch/alpha/alpha/mem.c cvs rdiff -u -r1.252.2.9 -r1.252.2.10 src/sys/arch/alpha/alpha/pmap.c cvs rdiff -u -r1.19.2.1 -r1.19.2.2 src/sys/arch/amd64/amd64/mem.c cvs rdiff -u -r1.26.6.7 -r1.26.6.8 src/sys/arch/arm/arm32/mem.c cvs rdiff -u -r1.211.2.22 -r1.211.2.23 src/sys/arch/arm/arm32/pmap.c cvs rdiff -u -r1.1.2.2 -r0 src/sys/common/pmap/pmap_common.c cvs rdiff -u -r1.1.2.6 -r0 src/sys/dev/xmd.c cvs rdiff -u -r1.16.2.2 -r1.16.2.3 src/sys/uvm/files.uvm cvs rdiff -u -r1.32.2.6 -r1.32.2.7 src/sys/uvm/uvm_pmap.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/lib/librumpuser
Module Name:src Committed By: pooka Date: Mon Nov 15 15:23:32 UTC 2010 Modified Files: src/lib/librumpuser: rumpuser.c rumpuser_int.h rumpuser_net.c Log Message: Make int *error and optional parameter (i.e. it can be NULL). Sometimes the caller just doesn't care which errno close() might throw. To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/lib/librumpuser/rumpuser.c cvs rdiff -u -r1.3 -r1.4 src/lib/librumpuser/rumpuser_int.h cvs rdiff -u -r1.1 -r1.2 src/lib/librumpuser/rumpuser_net.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/arm/imx
Module Name:src Committed By: bsh Date: Mon Nov 15 18:18:39 UTC 2010 Modified Files: src/sys/arch/arm/imx: imx31_gpio.c Log Message: GPIO register definitions are now in imxgpioreg.h to share them with imx51 To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/imx/imx31_gpio.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/evbarm/conf
Module Name:src Committed By: bsh Date: Mon Nov 15 18:21:19 UTC 2010 Modified Files: src/sys/arch/evbarm/conf: IMX31LITE Log Message: add an option for system clock frequency (used by timer driver) To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/evbarm/conf/IMX31LITE Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump/net/lib/libvirtif
Module Name:src Committed By: pooka Date: Mon Nov 15 20:23:12 UTC 2010 Modified Files: src/sys/rump/net/lib/libvirtif: if_virt.c Log Message: Make interface support ifconfig {down,destroy} and generally make it a little less eager to panic. To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/sys/rump/net/lib/libvirtif/if_virt.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump/librump/rumpkern
Module Name:src Committed By: pooka Date: Mon Nov 15 20:24:09 UTC 2010 Modified Files: src/sys/rump/librump/rumpkern: rump.c Log Message: apply const To generate a diff of this commit: cvs rdiff -u -r1.196 -r1.197 src/sys/rump/librump/rumpkern/rump.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump
Module Name:src Committed By: pooka Date: Mon Nov 15 20:37:22 UTC 2010 Modified Files: src/sys/rump/include/rump: rump.h src/sys/rump/librump/rumpkern: lwproc.c signals.c Log Message: Add a new signal model RUMP_SIGMODEL_RECORD which records all signals which are posted to a process. To generate a diff of this commit: cvs rdiff -u -r1.46 -r1.47 src/sys/rump/include/rump/rump.h cvs rdiff -u -r1.3 -r1.4 src/sys/rump/librump/rumpkern/lwproc.c \ src/sys/rump/librump/rumpkern/signals.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/tests/fs/puffs
Module Name:src Committed By: pooka Date: Mon Nov 15 20:39:00 UTC 2010 Modified Files: src/tests/fs/puffs: t_basic.c Log Message: Add test case for PR kern/44093 (fixed already, but tested to fail without fix applied). To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/tests/fs/puffs/t_basic.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/share/man/man4
Module Name:src Committed By: wiz Date: Mon Nov 15 21:19:59 UTC 2010 Modified Files: src/share/man/man4: route.4 Log Message: New sentence, new line; add serial comma. To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 src/share/man/man4/route.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/lib/libedit
Module Name:src Committed By: christos Date: Mon Nov 15 21:24:32 UTC 2010 Modified Files: src/lib/libedit: filecomplete.c Log Message: don't increment i twice in the loop. From Michael Byrnes To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/lib/libedit/filecomplete.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/crypto/external/bsd/netpgp/dist/src/netpgpverify
Module Name:src Committed By: wiz Date: Mon Nov 15 21:29:21 UTC 2010 Modified Files: src/crypto/external/bsd/netpgp/dist/src/netpgpverify: netpgpverify.1 Log Message: Remove trailing whitespace. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 \ src/crypto/external/bsd/netpgp/dist/src/netpgpverify/netpgpverify.1 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/tests/fs/lfs
Module Name:src Committed By: pooka Date: Mon Nov 15 21:29:39 UTC 2010 Modified Files: src/tests/fs/lfs: t_pr.c Log Message: double the timeout for slow hosts (from 1 to 2 seconds) To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/tests/fs/lfs/t_pr.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/notes/bebox
Module Name:src Committed By: wiz Date: Mon Nov 15 21:39:12 UTC 2010 Modified Files: src/distrib/notes/bebox: prep Log Message: Wording improvements. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/bebox/prep Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/notes/common
Module Name:src Committed By: wiz Date: Mon Nov 15 21:39:53 UTC 2010 Modified Files: src/distrib/notes/common: contents Log Message: Improve wording. To generate a diff of this commit: cvs rdiff -u -r1.162 -r1.163 src/distrib/notes/common/contents Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/share/man/man4
Module Name:src Committed By: pooka Date: Mon Nov 15 21:52:47 UTC 2010 Modified Files: src/share/man/man4: Makefile Added Files: src/share/man/man4: virt.4 Log Message: Exploit the fact that wizd is currently running and add a manpage for the rump virtif. To generate a diff of this commit: cvs rdiff -u -r1.533 -r1.534 src/share/man/man4/Makefile cvs rdiff -u -r0 -r1.1 src/share/man/man4/virt.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/sets/lists/man
Module Name:src Committed By: pooka Date: Mon Nov 15 21:56:47 UTC 2010 Modified Files: src/distrib/sets/lists/man: mi Log Message: diudau, remember that setlists have feelings too and make files match reality To generate a diff of this commit: cvs rdiff -u -r1.1249 -r1.1250 src/distrib/sets/lists/man/mi Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/tests/kernel
Module Name:src Committed By: pooka Date: Mon Nov 15 22:01:45 UTC 2010 Modified Files: src/tests/kernel: t_posix_fadvise.c Log Message: Add another set of problematic offsets from the quoted thread. To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/tests/kernel/t_posix_fadvise.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 22:45:24 UTC 2010 Modified Files: src/sys/rump/net/lib/libshmif: dumpbus.c Log Message: add -h which prints only the bus header info To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sys/rump/net/lib/libshmif/dumpbus.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 22:49:33 UTC 2010 Modified Files: src/sys/rump/net/lib/libshmif: dumpbus.c Log Message: un-\240 To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/rump/net/lib/libshmif/dumpbus.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src
Module Name:src Committed By: skrll Date: Mon Nov 15 23:07:38 UTC 2010 Modified Files: src/distrib/sets/lists/man: mi src/share/man/man4: Makefile Added Files: src/share/man/man4: nside.4 Log Message: Add a man page for nside(4). To generate a diff of this commit: cvs rdiff -u -r1.1250 -r1.1251 src/distrib/sets/lists/man/mi cvs rdiff -u -r1.534 -r1.535 src/share/man/man4/Makefile cvs rdiff -u -r0 -r1.1 src/share/man/man4/nside.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src
Module Name:src Committed By: pooka Date: Mon Nov 15 23:10:52 UTC 2010 Modified Files: src/distrib/sets/lists/man: mi src/share/man/man4: Makefile Added Files: src/share/man/man4: shmif.4 Log Message: document shmif, or at least what's implemented so far To generate a diff of this commit: cvs rdiff -u -r1.1251 -r1.1252 src/distrib/sets/lists/man/mi cvs rdiff -u -r1.535 -r1.536 src/share/man/man4/Makefile cvs rdiff -u -r0 -r1.1 src/share/man/man4/shmif.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/dev/pci
Module Name:src Committed By: macallan Date: Mon Nov 15 23:19:33 UTC 2010 Modified Files: src/sys/dev/pci: r128fb.c Log Message: explicitly set and clear the backlight on bit, just in case someone messes with it while we're not looking To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/dev/pci/r128fb.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 23:51:07 UTC 2010 Added Files: src/sys/rump/net/lib/libshmif: component.c Log Message: remember to commit this file too To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/rump/net/lib/libshmif/component.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump/net/lib/libshmif
Module Name:src Committed By: pooka Date: Mon Nov 15 23:59:06 UTC 2010 Modified Files: src/sys/rump/net/lib/libshmif: if_shmem.c Log Message: fix completely crackheaded code w/ uninitialized use, missed as usual by the wonderful -g -O0 To generate a diff of this commit: cvs rdiff -u -r1.29 -r1.30 src/sys/rump/net/lib/libshmif/if_shmem.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/rump/librump/rumpkern
Module Name:src Committed By: uebayasi Date: Tue Nov 16 01:12:57 UTC 2010 Modified Files: src/sys/rump/librump/rumpkern: vm.c Log Message: Define uvmexp_pagemask and friends used by sparc to set PAGE_SIZE, PAGE_MASK, PAGE_SHIFT dynamically. To generate a diff of this commit: cvs rdiff -u -r1.99 -r1.100 src/sys/rump/librump/rumpkern/vm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src/sys/arch/m68k/m68k
Module Name:src Committed By: uebayasi Date: Tue Nov 16 02:47:24 UTC 2010 Modified Files: src/sys/arch/m68k/m68k [uebayasi-xip]: bus_dma.c Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.29.18.1 -r1.29.18.2 src/sys/arch/m68k/m68k/bus_dma.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src/sys/arch/mips/mips
Module Name:src Committed By: uebayasi Date: Tue Nov 16 02:47:40 UTC 2010 Modified Files: src/sys/arch/mips/mips [uebayasi-xip]: bus_dma.c Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.23 -r1.23.2.1 src/sys/arch/mips/mips/bus_dma.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src/sys/arch/mips/mips
Module Name:src Committed By: uebayasi Date: Tue Nov 16 02:47:54 UTC 2010 Modified Files: src/sys/arch/mips/mips [uebayasi-xip]: cache_r5k.c Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.12.98.1 src/sys/arch/mips/mips/cache_r5k.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src/sys/arch
Module Name:src Committed By: uebayasi Date: Tue Nov 16 02:50:15 UTC 2010 Modified Files: src/sys/arch/hppa/include [uebayasi-xip]: pmap.h vmparam.h src/sys/arch/i386/include [uebayasi-xip]: pmap.h vmparam.h src/sys/arch/ia64/include [uebayasi-xip]: pmap.h vmparam.h src/sys/arch/mips/include [uebayasi-xip]: pmap.h vmparam.h src/sys/arch/powerpc/include/oea [uebayasi-xip]: vmparam.h src/sys/arch/sh3/include [uebayasi-xip]: pmap.h vmparam.h src/sys/arch/sparc/include [uebayasi-xip]: pmap.h vmparam.h src/sys/arch/sparc64/include [uebayasi-xip]: pmap.h vmparam.h src/sys/arch/vax/include [uebayasi-xip]: pmap.h vmparam.h Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.23.2.3 -r1.23.2.4 src/sys/arch/hppa/include/pmap.h cvs rdiff -u -r1.14.2.3 -r1.14.2.4 src/sys/arch/hppa/include/vmparam.h cvs rdiff -u -r1.103.14.2 -r1.103.14.3 src/sys/arch/i386/include/pmap.h cvs rdiff -u -r1.70.2.2 -r1.70.2.3 src/sys/arch/i386/include/vmparam.h cvs rdiff -u -r1.6.2.1 -r1.6.2.2 src/sys/arch/ia64/include/pmap.h cvs rdiff -u -r1.5.2.2 -r1.5.2.3 src/sys/arch/ia64/include/vmparam.h cvs rdiff -u -r1.57.2.1 -r1.57.2.2 src/sys/arch/mips/include/pmap.h cvs rdiff -u -r1.44.2.2 -r1.44.2.3 src/sys/arch/mips/include/vmparam.h cvs rdiff -u -r1.14.2.2 -r1.14.2.3 src/sys/arch/powerpc/include/oea/vmparam.h cvs rdiff -u -r1.34 -r1.34.2.1 src/sys/arch/sh3/include/pmap.h cvs rdiff -u -r1.19.2.3 -r1.19.2.4 src/sys/arch/sh3/include/vmparam.h cvs rdiff -u -r1.88 -r1.88.2.1 src/sys/arch/sparc/include/pmap.h cvs rdiff -u -r1.40.2.3 -r1.40.2.4 src/sys/arch/sparc/include/vmparam.h cvs rdiff -u -r1.47.2.1 -r1.47.2.2 src/sys/arch/sparc64/include/pmap.h cvs rdiff -u -r1.30.2.2 -r1.30.2.3 src/sys/arch/sparc64/include/vmparam.h cvs rdiff -u -r1.77.2.1 -r1.77.2.2 src/sys/arch/vax/include/pmap.h cvs rdiff -u -r1.45.2.2 -r1.45.2.3 src/sys/arch/vax/include/vmparam.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/arm/s3c2xx0
Module Name:src Committed By: bsh Date: Tue Nov 16 02:53:02 UTC 2010 Modified Files: src/sys/arch/arm/s3c2xx0: s3c2xx0var.h Log Message: make SMDK2410 kernel compile again after changes to sys/param.h To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/s3c2xx0/s3c2xx0var.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/usr.bin/env
Module Name:src Committed By: christos Date: Tue Nov 16 02:53:49 UTC 2010 Modified Files: src/usr.bin/env: env.c Log Message: minor KNF nits. To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/usr.bin/env/env.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/lib/libc/stdlib
Module Name:src Committed By: enami Date: Tue Nov 16 03:02:20 UTC 2010 Modified Files: src/lib/libc/stdlib: _env.c Log Message: Fix typos in comment. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/lib/libc/stdlib/_env.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src/sys/uvm
Module Name:src Committed By: uebayasi Date: Tue Nov 16 03:03:28 UTC 2010 Modified Files: src/sys/uvm [uebayasi-xip]: uvm_init.c uvm_param.h Log Message: Sync with HEAD. To generate a diff of this commit: cvs rdiff -u -r1.36 -r1.36.2.1 src/sys/uvm/uvm_init.c cvs rdiff -u -r1.22 -r1.22.2.1 src/sys/uvm/uvm_param.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/uvm
Module Name:src Committed By: enami Date: Tue Nov 16 03:49:54 UTC 2010 Modified Files: src/sys/uvm: uvm_meter.c Log Message: Nowadays, comparing priority against PZERO doesn't make any sense. Instead, see if a process waits uninterruptibly like ps does, so that the second column (`b') of default vmstat output prints some useful value (-t is still broken though). To generate a diff of this commit: cvs rdiff -u -r1.53 -r1.54 src/sys/uvm/uvm_meter.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: [uebayasi-xip] src/sys
Module Name:src Committed By: uebayasi Date: Tue Nov 16 07:44:26 UTC 2010 Modified Files: src/sys/miscfs/genfs [uebayasi-xip]: genfs_io.c src/sys/uvm [uebayasi-xip]: uvm_extern.h uvm_vnode.c Log Message: Factor out the part which lookups physical page identity from UVM object, into sys/uvm/uvm_vnode.c:uvn_findpage_xip(). Eventually this will become a call to cdev UVM object pager. To generate a diff of this commit: cvs rdiff -u -r1.36.2.31 -r1.36.2.32 src/sys/miscfs/genfs/genfs_io.c cvs rdiff -u -r1.161.2.11 -r1.161.2.12 src/sys/uvm/uvm_extern.h cvs rdiff -u -r1.93.2.2 -r1.93.2.3 src/sys/uvm/uvm_vnode.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.