CVS commit: src/external/apache2/mDNSResponder/dist/mDNSShared
Module Name:src Committed By: pettai Date: Fri Mar 28 07:01:49 UTC 2014 Modified Files: src/external/apache2/mDNSResponder/dist/mDNSShared: dnssd_clientstub.c uds_daemon.c Log Message: Fix lost merges To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 \ src/external/apache2/mDNSResponder/dist/mDNSShared/dnssd_clientstub.c cvs rdiff -u -r1.6 -r1.7 \ src/external/apache2/mDNSResponder/dist/mDNSShared/uds_daemon.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/apache2/mDNSResponder/dist/mDNSShared/dnssd_clientstub.c diff -u src/external/apache2/mDNSResponder/dist/mDNSShared/dnssd_clientstub.c:1.5 src/external/apache2/mDNSResponder/dist/mDNSShared/dnssd_clientstub.c:1.6 --- src/external/apache2/mDNSResponder/dist/mDNSShared/dnssd_clientstub.c:1.5 Mon Mar 24 00:31:13 2014 +++ src/external/apache2/mDNSResponder/dist/mDNSShared/dnssd_clientstub.c Fri Mar 28 07:01:49 2014 @@ -165,14 +165,14 @@ static int write_all(dnssd_sock_t sd, ch if (getsockopt(sd, SOL_SOCKET, SO_ISDEFUNCT, defunct, dlen) 0) syslog(LOG_WARNING, dnssd_clientstub write_all: SO_ISDEFUNCT failed %d %s, dnssd_errno, dnssd_strerror(dnssd_errno)); if (!defunct) -syslog(LOG_WARNING, dnssd_clientstub write_all(%d) failed %ld/%ld %d %s, sd, +syslog(LOG_WARNING, dnssd_clientstub write_all(%d) failed %zd/%ld %d %s, sd, (long)num_written, (long)len, (num_written 0) ? dnssd_errno : 0, (num_written 0) ? dnssd_strerror(dnssd_errno) : ); else syslog(LOG_INFO, dnssd_clientstub write_all(%d) DEFUNCT, sd); #else - syslog(LOG_WARNING, dnssd_clientstub write_all(%d) failed %ld/%ld %d %s, sd, + syslog(LOG_WARNING, dnssd_clientstub write_all(%d) failed %zd/%ld %d %s, sd, (long)num_written, (long)len, (num_written 0) ? dnssd_errno : 0, (num_written 0) ? dnssd_strerror(dnssd_errno) : ); Index: src/external/apache2/mDNSResponder/dist/mDNSShared/uds_daemon.c diff -u src/external/apache2/mDNSResponder/dist/mDNSShared/uds_daemon.c:1.6 src/external/apache2/mDNSResponder/dist/mDNSShared/uds_daemon.c:1.7 --- src/external/apache2/mDNSResponder/dist/mDNSShared/uds_daemon.c:1.6 Mon Mar 24 00:31:13 2014 +++ src/external/apache2/mDNSResponder/dist/mDNSShared/uds_daemon.c Fri Mar 28 07:01:49 2014 @@ -3256,7 +3256,9 @@ mDNSlocal void connect_callback(int fd, dnssd_sockaddr_t cliaddr; dnssd_socklen_t len = (dnssd_socklen_t) sizeof(cliaddr); dnssd_sock_t sd = accept(fd, (struct sockaddr*) cliaddr, len); -#if defined(SO_NOSIGPIPE) || defined(_WIN32) +#if defined(SO_NOSIGPIPE) + int optval = 1; +#elif defined(_WIN32) unsigned long optval = 1; #endif
CVS commit: src/doc
Module Name:src Committed By: apb Date: Fri Mar 28 08:15:48 UTC 2014 Modified Files: src/doc: 3RDPARTY Log Message: Add placeholder for osnet. To generate a diff of this commit: cvs rdiff -u -r1.1101 -r1.1102 src/doc/3RDPARTY Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/3RDPARTY diff -u src/doc/3RDPARTY:1.1101 src/doc/3RDPARTY:1.1102 --- src/doc/3RDPARTY:1.1101 Fri Mar 14 11:32:34 2014 +++ src/doc/3RDPARTY Fri Mar 28 08:15:48 2014 @@ -1,4 +1,4 @@ -# $NetBSD: 3RDPARTY,v 1.1101 2014/03/14 11:32:34 roy Exp $ +# $NetBSD: 3RDPARTY,v 1.1102 2014/03/28 08:15:48 apb Exp $ # # This file contains a list of the software that has been integrated into # NetBSD where we are not the primary maintainer. @@ -1405,6 +1405,18 @@ License: LGPL3 Location: external/lgpl3/gmp/dist Notes: +Package: osnet +Version: osnet-20100224 +Current Vers: ? +Maintainer: ? +Archive Site: ? +Home Page: ? +Mailing List: ? +Responsible: ? +License: CDDL +Location: external/cddl/osnet +Notes: + Package: sljit Version: svn revision 186 Current Vers: svn revision 226
CVS commit: src/distrib/notes/common
Module Name:src Committed By: hsuenaga Date: Fri Mar 28 08:24:06 UTC 2014 Modified Files: src/distrib/notes/common: main Log Message: Added myself, hsuenaga To generate a diff of this commit: cvs rdiff -u -r1.508 -r1.509 src/distrib/notes/common/main 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/main diff -u src/distrib/notes/common/main:1.508 src/distrib/notes/common/main:1.509 --- src/distrib/notes/common/main:1.508 Thu Mar 13 03:34:00 2014 +++ src/distrib/notes/common/main Fri Mar 28 08:24:06 2014 @@ -1,4 +1,4 @@ -.\ $NetBSD: main,v 1.508 2014/03/13 03:34:00 nat Exp $ +.\ $NetBSD: main,v 1.509 2014/03/28 08:24:06 hsuenaga Exp $ .\ .\ Copyright (c) 1999-2012 The NetBSD Foundation, Inc. .\ All rights reserved. @@ -1387,6 +1387,7 @@ If you're one of them, and would like to .It Ta Bill Squier Ta Mt g...@netbsd.org .It Ta Adrian Steinmann Ta Mt a...@netbsd.org .It Ta Bill Studenmund Ta Mt wrstu...@netbsd.org +.It Ta Hiroki Suenaga Ta Mt hsuen...@netbsd.org .It Ta Kevin Sullivan Ta Mt sulli...@netbsd.org .It Ta Kimmo Suominen Ta Mt k...@netbsd.org .It Ta Gr\('egoire Sutre Ta Mt gsu...@netbsd.org
CVS commit: src/share/misc
Module Name:src Committed By: apb Date: Fri Mar 28 10:16:28 UTC 2014 Modified Files: src/share/misc: airport Log Message: +ICN:Incheon, South Korea Also fix spelling of Incheon in the entry for JCN To generate a diff of this commit: cvs rdiff -u -r1.51 -r1.52 src/share/misc/airport Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/misc/airport diff -u src/share/misc/airport:1.51 src/share/misc/airport:1.52 --- src/share/misc/airport:1.51 Thu Apr 25 13:34:10 2013 +++ src/share/misc/airport Fri Mar 28 10:16:28 2014 @@ -1,4 +1,4 @@ -# $NetBSD: airport,v 1.51 2013/04/25 13:34:10 mbalmer Exp $ +# $NetBSD: airport,v 1.52 2014/03/28 10:16:28 apb Exp $ # @(#)airport 8.1 (Berkeley) 6/8/93 # # Some of this information is from http://www.mapping.com/airportcodes.html. @@ -3143,6 +3143,7 @@ ICA:Icabaru, Venezuela ICI:Cicia, Fiji ICK:Nieuw Nickerie (New Nickerie), Suriname ICL:Clarinda (Schenck Field), IA, USA +ICN:Incheon, South Korea ICR:Nicaro, Cuba ICT:Wichita Mid-Continent, Kansas, USA ICY:Icy Bay Airport, AK, USA @@ -3404,7 +3405,7 @@ JCI:Kansas City (Johnson County Airport) JCJ:Cheju, South Korea JCK:Julia Creek, Queensland, Australia JCM:Jacobina, BA, Brazil -JCN:Inchon (Heliport), South Korea +JCN:Incheon (Heliport), South Korea JCR:Jacareacanga, PR, Brazil JCT:Junction (Kimble County Airport), TX, USA JCX:Los Angeles (Citicorp Heliport), CA, USA
CVS commit: src/sys/arch/news68k/stand/boot
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 11:49:40 UTC 2014 Modified Files: src/sys/arch/news68k/stand/boot: boot.c Log Message: Use snprintf instead of sprintf To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/arch/news68k/stand/boot/boot.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/news68k/stand/boot/boot.c diff -u src/sys/arch/news68k/stand/boot/boot.c:1.18 src/sys/arch/news68k/stand/boot/boot.c:1.19 --- src/sys/arch/news68k/stand/boot/boot.c:1.18 Wed Aug 25 16:35:02 2010 +++ src/sys/arch/news68k/stand/boot/boot.c Fri Mar 28 11:49:40 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: boot.c,v 1.18 2010/08/25 16:35:02 christos Exp $ */ +/* $NetBSD: boot.c,v 1.19 2014/03/28 11:49:40 ozaki-r Exp $ */ /*- * Copyright (c) 1999 Izumi Tsutsui. All rights reserved. @@ -114,7 +114,7 @@ boot(uint32_t d4, uint32_t d5, uint32_t return; } - sprintf(devname, %s(%d,%d,%d), devs[type], ctlr, unit, part); + snprintf(devname, sizeof(devname), %s(%d,%d,%d), devs[type], ctlr, unit, part); printf(Booting %s%s\n, devname, netbsd); /* use user specified kernel name if exists */ @@ -128,7 +128,7 @@ boot(uint32_t d4, uint32_t d5, uint32_t loadflag = ~LOAD_BACKWARDS; for (i = 0; kernels[i]; i++) { - sprintf(file, %s%s, devname, kernels[i]); + snprintf(file, sizeof(file), %s%s, devname, kernels[i]); DPRINTF(trying %s...\n, file); fd = loadfile(file, marks, loadflag); if (fd != -1)
CVS commit: src/sys/dev/spi
Module Name:src Committed By: hkenken Date: Fri Mar 28 11:52:51 UTC 2014 Modified Files: src/sys/dev/spi: spiflash.c Log Message: Fix printf formating in DPRINTF. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.13 src/sys/dev/spi/spiflash.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/spi/spiflash.c diff -u src/sys/dev/spi/spiflash.c:1.12 src/sys/dev/spi/spiflash.c:1.13 --- src/sys/dev/spi/spiflash.c:1.12 Tue Jan 28 19:26:32 2014 +++ src/sys/dev/spi/spiflash.c Fri Mar 28 11:52:51 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: spiflash.c,v 1.12 2014/01/28 19:26:32 martin Exp $ */ +/* $NetBSD: spiflash.c,v 1.13 2014/03/28 11:52:51 hkenken Exp $ */ /*- * Copyright (c) 2006 Urbana-Champaign Independent Media Center. @@ -42,7 +42,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: spiflash.c,v 1.12 2014/01/28 19:26:32 martin Exp $); +__KERNEL_RCSID(0, $NetBSD: spiflash.c,v 1.13 2014/03/28 11:52:51 hkenken Exp $); #include sys/param.h #include sys/conf.h @@ -457,7 +457,7 @@ spiflash_process_write(spiflash_handle_t * do the erase, if we need to. */ if (neederase) { - DPRINTF((erasing from %x - %x\n, base, base + len)); + DPRINTF((erasing from %zx - %zx\n, base, base + len)); if ((err = sc-sc_erase(sc, base, len)) != 0) { spiflash_process_done(sc, err); return; @@ -467,8 +467,7 @@ spiflash_process_write(spiflash_handle_t /* * now write our save area, and finish up. */ - DPRINTF((flashing %d bytes to %x from %x\n, len, - base, (unsigned)save)); + DPRINTF((flashing %d bytes to %zx from %p\n, len, base, save)); err = sc-sc_write(sc, base, len, save); spiflash_process_done(sc, err); }
CVS commit: src/sys/kern
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 11:55:09 UTC 2014 Modified Files: src/sys/kern: tty_pty.c Log Message: Fix unused variable 'mp' To generate a diff of this commit: cvs rdiff -u -r1.136 -r1.137 src/sys/kern/tty_pty.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/kern/tty_pty.c diff -u src/sys/kern/tty_pty.c:1.136 src/sys/kern/tty_pty.c:1.137 --- src/sys/kern/tty_pty.c:1.136 Thu Mar 27 17:31:56 2014 +++ src/sys/kern/tty_pty.c Fri Mar 28 11:55:09 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: tty_pty.c,v 1.136 2014/03/27 17:31:56 christos Exp $ */ +/* $NetBSD: tty_pty.c,v 1.137 2014/03/28 11:55:09 ozaki-r Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1993 @@ -37,7 +37,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: tty_pty.c,v 1.136 2014/03/27 17:31:56 christos Exp $); +__KERNEL_RCSID(0, $NetBSD: tty_pty.c,v 1.137 2014/03/28 11:55:09 ozaki-r Exp $); #include opt_ptm.h @@ -1041,7 +1041,9 @@ ptyioctl(dev_t dev, u_long cmd, void *da const struct cdevsw *cdev; u_char *cc = tp-t_cc; int stop, error, sig; +#ifndef NO_DEV_PTM struct mount *mp; +#endif /* * IF CONTROLLER STTY THEN MUST FLUSH TO PREVENT A HANG.
CVS commit: src/sys/arch/atari/stand/ahdilabel
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 13:35:13 UTC 2014 Modified Files: src/sys/arch/atari/stand/ahdilabel: ahdilabel.c Log Message: Fix; cts[0] = cts To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/atari/stand/ahdilabel/ahdilabel.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/atari/stand/ahdilabel/ahdilabel.c diff -u src/sys/arch/atari/stand/ahdilabel/ahdilabel.c:1.9 src/sys/arch/atari/stand/ahdilabel/ahdilabel.c:1.10 --- src/sys/arch/atari/stand/ahdilabel/ahdilabel.c:1.9 Wed Mar 26 18:04:33 2014 +++ src/sys/arch/atari/stand/ahdilabel/ahdilabel.c Fri Mar 28 13:35:13 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: ahdilabel.c,v 1.9 2014/03/26 18:04:33 christos Exp $ */ +/* $NetBSD: ahdilabel.c,v 1.10 2014/03/28 13:35:13 ozaki-r Exp $ */ /* * Copyright (c) 1999 The NetBSD Foundation, Inc. @@ -402,7 +402,7 @@ change_part (struct ahdi_ptable *ptable, } printf (size [%8u (%s) (%4uM)] , ptable-parts[part].size, - sec_to_cts (ptable, ptable-parts[part].size, cts[0], sizeof(cts)), + sec_to_cts (ptable, ptable-parts[part].size, cts, sizeof(cts)), (ptable-parts[part].size + (BLPM 1)) / BLPM); if (get_input (buf[0], BUFLEN)) { sector = read_sector (ptable, buf, part, PART_END);
CVS commit: src/games/hunt/huntd
Module Name:src Committed By: apb Date: Fri Mar 28 17:49:11 UTC 2014 Modified Files: src/games/hunt/huntd: get_names.c Log Message: If you are going to use memcpy instead of struct assignment, then at least use sizeof(the correct variable). The use of memcmp to test two pointers for equality, one line earlier, is also weird but may be correct. To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/games/hunt/huntd/get_names.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/games/hunt/huntd/get_names.c diff -u src/games/hunt/huntd/get_names.c:1.10 src/games/hunt/huntd/get_names.c:1.11 --- src/games/hunt/huntd/get_names.c:1.10 Sat Jul 4 04:29:55 2009 +++ src/games/hunt/huntd/get_names.c Fri Mar 28 17:49:11 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: get_names.c,v 1.10 2009/07/04 04:29:55 dholland Exp $ */ +/* $NetBSD: get_names.c,v 1.11 2014/03/28 17:49:11 apb Exp $ */ /* * Copyright (c) 1983-2003, Regents of the University of California. * All rights reserved. @@ -32,7 +32,7 @@ #include sys/cdefs.h #ifndef lint -__RCSID($NetBSD: get_names.c,v 1.10 2009/07/04 04:29:55 dholland Exp $); +__RCSID($NetBSD: get_names.c,v 1.11 2014/03/28 17:49:11 apb Exp $); #endif /* not lint */ #include bsd.h @@ -146,7 +146,7 @@ get_remote_name(char *his_address) if (memcmp(his_machine_name, my_machine_name, sizeof(his_machine_name)) == 0) memcpy(his_machine_addr, my_machine_addr, - sizeof(his_machine_name)); + sizeof(his_machine_addr)); else { /* look up the address of the recipient's machine */ hp = gethostbyname(his_machine_name);
CVS commit: src/games/sail
Module Name:src Committed By: apb Date: Fri Mar 28 17:53:47 UTC 2014 Modified Files: src/games/sail: dr_2.c Log Message: temp is a pointer, and tempmax, not sizeof(temp), is the length of the buffer that it points to. Adjust a strlcat() call to suit. To generate a diff of this commit: cvs rdiff -u -r1.25 -r1.26 src/games/sail/dr_2.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/games/sail/dr_2.c diff -u src/games/sail/dr_2.c:1.25 src/games/sail/dr_2.c:1.26 --- src/games/sail/dr_2.c:1.25 Sat Mar 14 22:52:52 2009 +++ src/games/sail/dr_2.c Fri Mar 28 17:53:47 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: dr_2.c,v 1.25 2009/03/14 22:52:52 dholland Exp $ */ +/* $NetBSD: dr_2.c,v 1.26 2014/03/28 17:53:47 apb Exp $ */ /* * Copyright (c) 1983, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = @(#)dr_2.c 8.1 (Berkeley) 5/31/93; #else -__RCSID($NetBSD: dr_2.c,v 1.25 2009/03/14 22:52:52 dholland Exp $); +__RCSID($NetBSD: dr_2.c,v 1.26 2014/03/28 17:53:47 apb Exp $); #endif #endif /* not lint */ @@ -286,7 +286,7 @@ try(struct ship *f, struct ship *t, } if ((ma 0 ta 0 (n = str_end(temp)) != 'l' n != 'r') || !strlen(temp)) { - strlcat(temp, l, sizeof(temp)); + strlcat(temp, l, tempmax); new = score(f, t, temp, tempmax, rakeme); if (new *high (!rakeme || (gunsbear(f, t) !gunsbear(t, f {
CVS commit: src/sys/arch/news68k/stand/boot
Module Name:src Committed By: christos Date: Fri Mar 28 15:02:34 UTC 2014 Modified Files: src/sys/arch/news68k/stand/boot: boot.c Log Message: fold line To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/sys/arch/news68k/stand/boot/boot.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/news68k/stand/boot/boot.c diff -u src/sys/arch/news68k/stand/boot/boot.c:1.19 src/sys/arch/news68k/stand/boot/boot.c:1.20 --- src/sys/arch/news68k/stand/boot/boot.c:1.19 Fri Mar 28 07:49:40 2014 +++ src/sys/arch/news68k/stand/boot/boot.c Fri Mar 28 11:02:34 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: boot.c,v 1.19 2014/03/28 11:49:40 ozaki-r Exp $ */ +/* $NetBSD: boot.c,v 1.20 2014/03/28 15:02:34 christos Exp $ */ /*- * Copyright (c) 1999 Izumi Tsutsui. All rights reserved. @@ -114,7 +114,8 @@ boot(uint32_t d4, uint32_t d5, uint32_t return; } - snprintf(devname, sizeof(devname), %s(%d,%d,%d), devs[type], ctlr, unit, part); + snprintf(devname, sizeof(devname), + %s(%d,%d,%d), devs[type], ctlr, unit, part); printf(Booting %s%s\n, devname, netbsd); /* use user specified kernel name if exists */
CVS commit: src/sbin/shutdown
Module Name:src Committed By: apb Date: Fri Mar 28 18:27:14 UTC 2014 Modified Files: src/sbin/shutdown: shutdown.c Log Message: When the third arg to fwrite() is a size in bytes, then the second arg should be 1. sizeof(*mbuf) happens to equal 1, but it's better not to rely on that. To generate a diff of this commit: cvs rdiff -u -r1.55 -r1.56 src/sbin/shutdown/shutdown.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sbin/shutdown/shutdown.c diff -u src/sbin/shutdown/shutdown.c:1.55 src/sbin/shutdown/shutdown.c:1.56 --- src/sbin/shutdown/shutdown.c:1.55 Sat Aug 27 18:54:39 2011 +++ src/sbin/shutdown/shutdown.c Fri Mar 28 18:27:14 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: shutdown.c,v 1.55 2011/08/27 18:54:39 joerg Exp $ */ +/* $NetBSD: shutdown.c,v 1.56 2014/03/28 18:27:14 apb Exp $ */ /* * Copyright (c) 1988, 1990, 1993 @@ -39,7 +39,7 @@ __COPYRIGHT(@(#) Copyright (c) 1988, 19 #if 0 static char sccsid[] = @(#)shutdown.c 8.4 (Berkeley) 4/28/95; #else -__RCSID($NetBSD: shutdown.c,v 1.55 2011/08/27 18:54:39 joerg Exp $); +__RCSID($NetBSD: shutdown.c,v 1.56 2014/03/28 18:27:14 apb Exp $); #endif #endif /* not lint */ @@ -331,7 +331,7 @@ timewarn(time_t timeleft) (void)fprintf(pf, System going down IMMEDIATELY\n\n); if (mbuflen) - (void)fwrite(mbuf, sizeof(*mbuf), mbuflen, pf); + (void)fwrite(mbuf, 1, mbuflen, pf); /* * play some games, just in case wall doesn't come back
CVS commit: src/lib/libc/sys
Module Name:src Committed By: wiz Date: Fri Mar 28 15:35:55 UTC 2014 Modified Files: src/lib/libc/sys: clock_settime.2 Log Message: Remove trailing whitespace. Merge EINVAL entries. To generate a diff of this commit: cvs rdiff -u -r1.21 -r1.22 src/lib/libc/sys/clock_settime.2 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/sys/clock_settime.2 diff -u src/lib/libc/sys/clock_settime.2:1.21 src/lib/libc/sys/clock_settime.2:1.22 --- src/lib/libc/sys/clock_settime.2:1.21 Fri Mar 28 15:03:41 2014 +++ src/lib/libc/sys/clock_settime.2 Fri Mar 28 15:35:55 2014 @@ -1,4 +1,4 @@ -.\ $NetBSD: clock_settime.2,v 1.21 2014/03/28 15:03:41 degroote Exp $ +.\ $NetBSD: clock_settime.2,v 1.22 2014/03/28 15:35:55 wiz Exp $ .\ .\ Copyright (c) 1999 The NetBSD Foundation, Inc. .\ All rights reserved. @@ -116,7 +116,7 @@ A .Fa clock_id of .Dv CLOCK_PROF -identifies a clock that increments when the CPU is running in user +identifies a clock that increments when the CPU is running in user or kernel mode on behalf of the calling process. .Pp If the calling user is not the super-user, then the @@ -161,14 +161,12 @@ function will fail if: The .Fa tp argument is outside the range for the specified clock, -.Fa clock_id . -.It Bq Er EINVAL -The +.Fa clock_id ; +or the .Fa tp argument specified a nanosecond value less than zero of greater than or equal -1000 million. -.It Bq Er EINVAL -The +1000 million; +or the .Fa clock_id argument is a clock that can not be adjusted. .It Bq Er EPERM
CVS commit: src/lib/libc/sys
Module Name:src Committed By: degroote Date: Fri Mar 28 15:03:41 UTC 2014 Modified Files: src/lib/libc/sys: clock_settime.2 Log Message: Document a bit CLOCK_VIRTUAL and CLOCK_PROF To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/lib/libc/sys/clock_settime.2 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/sys/clock_settime.2 diff -u src/lib/libc/sys/clock_settime.2:1.20 src/lib/libc/sys/clock_settime.2:1.21 --- src/lib/libc/sys/clock_settime.2:1.20 Wed Mar 11 13:39:14 2009 +++ src/lib/libc/sys/clock_settime.2 Fri Mar 28 15:03:41 2014 @@ -1,4 +1,4 @@ -.\ $NetBSD: clock_settime.2,v 1.20 2009/03/11 13:39:14 joerg Exp $ +.\ $NetBSD: clock_settime.2,v 1.21 2014/03/28 15:03:41 degroote Exp $ .\ .\ Copyright (c) 1999 The NetBSD Foundation, Inc. .\ All rights reserved. @@ -105,6 +105,20 @@ error if it's the clock specified in a c .Fn clock_settime . The origin of the clock is unspecified. .Pp +A +.Fa clock_id +of +.Dv CLOCK_VIRTUAL +identifies a clock that increments only when the CPU is running in +user mode on behalf of the calling process. +.Pp +A +.Fa clock_id +of +.Dv CLOCK_PROF +identifies a clock that increments when the CPU is running in user +or kernel mode on behalf of the calling process. +.Pp If the calling user is not the super-user, then the .Fn clock_settime function in the standard C library will try to use the
CVS commit: src/sys/arch/vax/vsa
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 13:26:24 UTC 2014 Modified Files: src/sys/arch/vax/vsa: spx.c Log Message: Use snprintf instead of sprintf To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/vsa/spx.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/vax/vsa/spx.c diff -u src/sys/arch/vax/vsa/spx.c:1.7 src/sys/arch/vax/vsa/spx.c:1.8 --- src/sys/arch/vax/vsa/spx.c:1.7 Thu Oct 24 13:16:33 2013 +++ src/sys/arch/vax/vsa/spx.c Fri Mar 28 13:26:24 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: spx.c,v 1.7 2013/10/24 13:16:33 martin Exp $ */ +/* $NetBSD: spx.c,v 1.8 2014/03/28 13:26:24 ozaki-r Exp $ */ /* * SPX/LCSPX/SPXg/SPXgt accelerated framebuffer driver for NetBSD/VAX * Copyright (c) 2005 Blaz Antonic @@ -32,7 +32,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: spx.c,v 1.7 2013/10/24 13:16:33 martin Exp $); +__KERNEL_RCSID(0, $NetBSD: spx.c,v 1.8 2014/03/28 13:26:24 ozaki-r Exp $); #include sys/param.h #include sys/systm.h @@ -1512,7 +1512,8 @@ spx_init_common(device_t self, struct vs spx_stdscreen.nrows = spx_rows; spx_stdscreen.fontwidth = spx_font.fontwidth; spx_stdscreen.fontheight = spx_font.fontheight; - sprintf(spx_stdscreen_name, %dx%d, spx_cols, spx_rows); + snprintf(spx_stdscreen_name, sizeof(spx_stdscreen_name), +%dx%d, spx_cols, spx_rows); /* for SPXg spx_fb_size represents FB window size, not FB length */ if (fb_type == FB_IS_SPXg)
CVS commit: src/sys/arch/sgimips/stand/sgivol
Module Name:src Committed By: christos Date: Fri Mar 28 15:00:53 UTC 2014 Modified Files: src/sys/arch/sgimips/stand/sgivol: sgivol.c Log Message: use err To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/sys/arch/sgimips/stand/sgivol/sgivol.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/sgimips/stand/sgivol/sgivol.c diff -u src/sys/arch/sgimips/stand/sgivol/sgivol.c:1.20 src/sys/arch/sgimips/stand/sgivol/sgivol.c:1.21 --- src/sys/arch/sgimips/stand/sgivol/sgivol.c:1.20 Wed Mar 26 12:16:06 2014 +++ src/sys/arch/sgimips/stand/sgivol/sgivol.c Fri Mar 28 11:00:53 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: sgivol.c,v 1.20 2014/03/26 16:16:06 christos Exp $ */ +/* $NetBSD: sgivol.c,v 1.21 2014/03/28 15:00:53 christos Exp $ */ /*- * Copyright (c) 2001 The NetBSD Foundation, Inc. @@ -53,6 +53,7 @@ #include string.h #include fcntl.h #include util.h +#include err.h #ifndef HAVE_NBTOOL_CONFIG_H #include sys/endian.h #endif @@ -80,7 +81,7 @@ struct stat st; struct disklabel lbl; #endif -unsigned char buf[512]; +char buf[512]; const char *sgi_types[] = { Volume Header, @@ -99,20 +100,18 @@ const char *sgi_types[] = { XVM }; -int main(int, char *[]); - void display_vol(void); -void init_volhdr(void); +void init_volhdr(const char *); void read_file(void); -void write_file(void); -void delete_file(void); -void move_file(void); -void modify_partition(void); -void write_volhdr(void); +void write_file(const char *); +void delete_file(const char *); +void move_file(const char *); +void modify_partition(const char *); +void write_volhdr(const char *); int allocate_space(int); void checksum_vol(void); int names_match(int, const char *); -void usage(void); +void usage(void) __dead; int main(int argc, char *argv[]) @@ -201,80 +200,63 @@ main(int argc, char *argv[]) fd = open(argv[0], (opt_i | opt_m | opt_w | opt_d | opt_p) ? O_RDWR : O_RDONLY); - if (fd 0) { -#if HAVE_NBTOOL_CONFIG_H - perror(File open); - exit(1); -#else + if (fd == -1) { +#ifndef HAVE_NBTOOL_CONFIG_H snprintf(buf, sizeof(buf), /dev/r%s%c, argv[0], 'a' + getrawpartition()); - fd = open((char *)buf, (opt_i | opt_w | opt_d | opt_p) -? O_RDWR : O_RDONLY); - if (fd 0) { - printf(Error opening device %s: %s\n, -argv[0], strerror(errno)); - exit(1); - } + fd = open(buf, (opt_i | opt_w | opt_d | opt_p) + ? O_RDWR : O_RDONLY); + if (fd == -1) #endif + err(EXIT_FAILURE, Error opening device `%s', argv[0]); } - if (read(fd, buf, sizeof(buf)) != sizeof(buf)) { - perror(read volhdr); - exit(1); - } + + if (read(fd, buf, sizeof(buf)) != sizeof(buf)) + err(EXIT_FAILURE, Can't read volhdr from `%s', argv[0]); + #if HAVE_NBTOOL_CONFIG_H - if (fstat(fd, st) 0) { - perror(stat error); - exit(1); - } - if (!S_ISREG(st.st_mode)) { - printf(Must be regular file\n); - exit(1); - } - if (st.st_size % SGI_BOOT_BLOCK_BLOCKSIZE) { - printf(Size must be multiple of %d\n, + if (fstat(fd, st) == -1) + err(EXIT_FAILURE, Can't stat `%s', argv[0]); + if (!S_ISREG(st.st_mode)) + errx(EXIT_FAILURE, Not a regular file `%s', argv[0]); + + if (st.st_size % SGI_BOOT_BLOCK_BLOCKSIZE) + errx(EXIT_FAILURE, Size must be multiple of %d, SGI_BOOT_BLOCK_BLOCKSIZE); - exit(1); - } - if (st.st_size (SGIVOL_NBTOOL_NSECS * SGIVOL_NBTOOL_NTRACKS)) { - printf(Minimum size of %d required\n, + if (st.st_size (SGIVOL_NBTOOL_NSECS * SGIVOL_NBTOOL_NTRACKS)) + errx(EXIT_FAILURE, Minimum size of %d required, SGIVOL_NBTOOL_NSECS * SGIVOL_NBTOOL_NTRACKS); - exit(1); - } #else - if (ioctl(fd, DIOCGDINFO, lbl) 0) { - perror(DIOCGDINFO); - exit(1); - } + if (ioctl(fd, DIOCGDINFO, lbl) == -1) + err(EXIT_FAILURE, ioctl DIOCGDINFO failed); #endif volhdr = (struct sgi_boot_block *) buf; if (opt_i) { - init_volhdr(); - exit(0); - } - if (be32toh(volhdr-magic) != SGI_BOOT_BLOCK_MAGIC) { - printf(No Volume Header found, magic=%x. Use -i first.\n, - be32toh(volhdr-magic)); - exit(1); + init_volhdr(argv[0]); + return 0; } + if (be32toh(volhdr-magic) != SGI_BOOT_BLOCK_MAGIC) + errx(EXIT_FAILURE, No Volume Header found, magic=%x. + Use -i first.\n, be32toh(volhdr-magic)); if (opt_r) { read_file(); - exit(0); + return 0; } if (opt_w) { - write_file(); - exit(0); + write_file(argv[0]); + return 0; } if (opt_d) { - delete_file(); - exit(0); + delete_file(argv[0]); + return 0; } if (opt_m) { - move_file(); - exit(0); + move_file(argv[0]); + return 0; } if (opt_p) { - modify_partition(); - exit(0); + modify_partition(argv[0]); + return 0; } if (!opt_q) @@ -295,15 +277,14 @@ names_match(int slot, const char *b) { int cmp; - if (slot 0 || slot = SGI_BOOT_BLOCK_MAXVOLDIRS) { - printf(Internal error: bad slot in %s()\n, __func__); - exit(1); - } + if (slot 0 || slot = SGI_BOOT_BLOCK_MAXVOLDIRS) +
CVS commit: src/common/lib/libc/arch/arm/atomic
Module Name:src Committed By: skrll Date: Fri Mar 28 21:32:41 UTC 2014 Modified Files: src/common/lib/libc/arch/arm/atomic: membar_ops.S Log Message: Ensure SBZ register is zero To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/common/lib/libc/arch/arm/atomic/membar_ops.S Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/common/lib/libc/arch/arm/atomic/membar_ops.S diff -u src/common/lib/libc/arch/arm/atomic/membar_ops.S:1.5 src/common/lib/libc/arch/arm/atomic/membar_ops.S:1.6 --- src/common/lib/libc/arch/arm/atomic/membar_ops.S:1.5 Tue Mar 4 16:15:28 2014 +++ src/common/lib/libc/arch/arm/atomic/membar_ops.S Fri Mar 28 21:32:41 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: membar_ops.S,v 1.5 2014/03/04 16:15:28 matt Exp $ */ +/* $NetBSD: membar_ops.S,v 1.6 2014/03/28 21:32:41 skrll Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. * All rights reserved. @@ -36,6 +36,7 @@ ENTRY_NP(_membar_producer) #ifdef _ARM_ARCH_7 dsb #else + mov r0, #0 mcr p15, 0, r0, c7, c10, 4 /* Data Synchronization Barrier */ #endif RET @@ -48,6 +49,7 @@ ENTRY_NP(_membar_sync) #ifdef _ARM_ARCH_7 dmb #else + mov r0, #0 mcr p15, 0, r0, c7, c10, 5 /* Data Memory Barrier */ #endif RET
CVS commit: src/sys/arch/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:39:10 UTC 2014 Modified Files: src/sys/arch/arm/arm32: arm32_boot.c arm32_machdep.c cpu.c src/sys/arch/arm/cortex: gic.c gic_reg.h src/sys/arch/arm/include: locore.h src/sys/arch/arm/vfp: vfp_init.c Log Message: Various MP changes. To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/arm32/arm32_boot.c cvs rdiff -u -r1.101 -r1.102 src/sys/arch/arm/arm32/arm32_machdep.c cvs rdiff -u -r1.103 -r1.104 src/sys/arch/arm/arm32/cpu.c cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/cortex/gic.c cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/cortex/gic_reg.h cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/include/locore.h cvs rdiff -u -r1.36 -r1.37 src/sys/arch/arm/vfp/vfp_init.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/arm32/arm32_boot.c diff -u src/sys/arch/arm/arm32/arm32_boot.c:1.6 src/sys/arch/arm/arm32/arm32_boot.c:1.7 --- src/sys/arch/arm/arm32/arm32_boot.c:1.6 Mon Mar 3 08:52:30 2014 +++ src/sys/arch/arm/arm32/arm32_boot.c Fri Mar 28 21:39:09 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: arm32_boot.c,v 1.6 2014/03/03 08:52:30 matt Exp $ */ +/* $NetBSD: arm32_boot.c,v 1.7 2014/03/28 21:39:09 matt Exp $ */ /* * Copyright (c) 2002, 2003, 2005 Genetec Corporation. All rights reserved. @@ -123,7 +123,7 @@ #include sys/cdefs.h -__KERNEL_RCSID(1, $NetBSD: arm32_boot.c,v 1.6 2014/03/03 08:52:30 matt Exp $); +__KERNEL_RCSID(1, $NetBSD: arm32_boot.c,v 1.7 2014/03/28 21:39:09 matt Exp $); #include opt_ddb.h #include opt_kgdb.h @@ -132,6 +132,8 @@ __KERNEL_RCSID(1, $NetBSD: arm32_boot.c #include sys/reboot.h #include sys/cpu.h #include sys/intr.h +#include sys/atomic.h +#include sys/device.h #include uvm/uvm_extern.h @@ -320,19 +322,34 @@ cpu_hatch(struct cpu_info *ci, cpuid_t c */ splhigh(); +#ifdef VERBOSE_INIT_ARM printf(%s(%s): , __func__, ci-ci_data.cpu_name); +#endif + uint32_t mpidr = armreg_mpidr_read(); + if (mpidr MPIDR_MT) { + ci-ci_data.cpu_smt_id = mpidr MPIDR_AFF0; + ci-ci_data.cpu_core_id = mpidr MPIDR_AFF1; + ci-ci_data.cpu_package_id = mpidr MPIDR_AFF2; + } else { + ci-ci_data.cpu_core_id = mpidr MPIDR_AFF0; + ci-ci_data.cpu_package_id = mpidr MPIDR_AFF1; + } /* * Make sure we have the right vector page. */ +#ifdef VERBOSE_INIT_ARM printf( vectors); +#endif arm32_vector_init(systempage.pv_va, ARM_VEC_ALL); /* - * Initialize the stack for each mode (we are already running on the SVC32 - * stack of the idlelwp). + * Initialize the stack for each mode (we are already running on the + * SVC32 stack of the idlelwp). */ +#ifdef VERBOSE_INIT_ARM printf( stacks); +#endif set_stackptr(PSR_FIQ32_MODE, fiqstack.pv_va + cpu_index(ci) * FIQ_STACK_SIZE * PAGE_SIZE); set_stackptr(PSR_IRQ32_MODE, @@ -345,13 +362,14 @@ cpu_hatch(struct cpu_info *ci, cpuid_t c ci-ci_lastlwp = NULL; ci-ci_pmap_lastuser = NULL; #ifdef ARM_MMU_EXTENDED +#ifdef VERBOSE_INIT_ARM printf( tlb); +#endif /* * Attach to the tlb. */ ci-ci_pmap_cur = pmap_kernel(); ci-ci_pmap_asid_cur = KERNEL_PID; - pmap_tlb_info_attach(pmap_tlb0_info, ci); #endif #ifdef CPU_CORTEX @@ -364,24 +382,32 @@ cpu_hatch(struct cpu_info *ci, cpuid_t c } #endif + aprint_naive(%s, device_xname(ci-ci_dev)); + aprint_normal(%s, device_xname(ci-ci_dev)); + identify_arm_cpu(ci-ci_dev, ci); +#ifdef VERBOSE_INIT_ARM + printf( vfp); +#endif + vfp_attach(ci); + +#ifdef VERBOSE_INIT_ARM printf( interrupts); +#endif /* * Let the interrupts do what they need to on this CPU. */ intr_cpu_init(ci); +#ifdef VERBOSE_INIT_ARM printf( md(%p), md_cpu_init); +#endif if (md_cpu_init != NULL) (*md_cpu_init)(ci); -#if 0 - /* - * Tell the MI code we are alive! - */ - printf( mi_cpu); - mi_cpu_running(ci); -#endif - +#ifdef VERBOSE_INIT_ARM printf( done!\n); +#endif + atomic_and_32(arm_cpu_mbox, ~(1 cpuid)); + __asm __volatile(sev; sev; sev); } #endif /* MULTIPROCESSOR */ Index: src/sys/arch/arm/arm32/arm32_machdep.c diff -u src/sys/arch/arm/arm32/arm32_machdep.c:1.101 src/sys/arch/arm/arm32/arm32_machdep.c:1.102 --- src/sys/arch/arm/arm32/arm32_machdep.c:1.101 Mon Mar 3 08:15:36 2014 +++ src/sys/arch/arm/arm32/arm32_machdep.c Fri Mar 28 21:39:09 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: arm32_machdep.c,v 1.101 2014/03/03 08:15:36 matt Exp $ */ +/* $NetBSD: arm32_machdep.c,v 1.102 2014/03/28 21:39:09 matt Exp $ */ /* * Copyright (c) 1994-1998 Mark Brinicombe. @@ -42,7 +42,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: arm32_machdep.c,v 1.101 2014/03/03 08:15:36 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: arm32_machdep.c,v 1.102 2014/03/28 21:39:09 matt Exp $); #include opt_modular.h #include opt_md.h @@ -683,16 +683,17 @@ cpu_uarea_alloc_idlelwp(struct cpu_info void cpu_boot_secondary_processors(void) { - uint32_t mbox; -
CVS commit: src/sys/arch/arm/include
Module Name:src Committed By: matt Date: Fri Mar 28 21:40:53 UTC 2014 Modified Files: src/sys/arch/arm/include: mutex.h rwlock.h Log Message: Use dmb/dsb To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/include/mutex.h cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/include/rwlock.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/include/mutex.h diff -u src/sys/arch/arm/include/mutex.h:1.13 src/sys/arch/arm/include/mutex.h:1.14 --- src/sys/arch/arm/include/mutex.h:1.13 Tue Sep 25 05:24:00 2012 +++ src/sys/arch/arm/include/mutex.h Fri Mar 28 21:40:53 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: mutex.h,v 1.13 2012/09/25 05:24:00 matt Exp $ */ +/* $NetBSD: mutex.h,v 1.14 2014/03/28 21:40:53 matt Exp $ */ /*- * Copyright (c) 2002, 2007 The NetBSD Foundation, Inc. @@ -88,12 +88,28 @@ struct kmutex { * MUTEX_RECEIVE: no memory barrier required; we're synchronizing against * interrupts, not multiple processors. */ +#ifdef MULTIPROCESSOR +#if defined(_ARM_ARCH_7) !defined(_ARM_ARCH_6) +#define MUTEX_RECEIVE(mtx) __asm __volatile(dmb) +#else +#define MUTEX_RECEIVE(mtx) membar_consumer() +#endif +#else #define MUTEX_RECEIVE(mtx) /* nothing */ +#endif /* * MUTEX_GIVE: no memory barrier required; same reason. */ +#ifdef MULTIPROCESSOR +#if defined(_ARM_ARCH_7) !defined(_ARM_ARCH_6) +#define MUTEX_RECEIVE(mtx) __asm __volatile(dsb) +#else +#define MUTEX_GIVE(mtx) membar_producer() +#endif +#else #define MUTEX_GIVE(mtx) /* nothing */ +#endif #define MUTEX_CAS(p, o, n) \ (atomic_cas_ulong((volatile unsigned long *)(p), (o), (n)) == (o)) Index: src/sys/arch/arm/include/rwlock.h diff -u src/sys/arch/arm/include/rwlock.h:1.6 src/sys/arch/arm/include/rwlock.h:1.7 --- src/sys/arch/arm/include/rwlock.h:1.6 Wed Jan 29 00:17:21 2014 +++ src/sys/arch/arm/include/rwlock.h Fri Mar 28 21:40:53 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: rwlock.h,v 1.6 2014/01/29 00:17:21 matt Exp $ */ +/* $NetBSD: rwlock.h,v 1.7 2014/03/28 21:40:53 matt Exp $ */ /*- * Copyright (c) 2002, 2006 The NetBSD Foundation, Inc. @@ -40,8 +40,18 @@ struct krwlock { #define __HAVE_SIMPLE_RW_LOCKS 1 +#ifdef MULTIPROCESSOR +#if defined(_ARM_ARCH_7) !defined(_ARM_ARCH_6) +#define RW_RECEIVE(rw) __asm __volatile(dmb) +#define RW_GIVE(rw) __asm __volatile(dsb) +#else +#define RW_RECEIVE(rw) membar_consumer() +#define RW_GIVE(rw) membar_producer() +#endif +#else #define RW_RECEIVE(rw) /* nothing */ #define RW_GIVE(rw) /* nothing */ +#endif #define RW_CAS(p, o, n) \ (atomic_cas_ulong((volatile unsigned long *)(p), (o), (n)) == (o))
CVS commit: src/sys/arch/arm/cortex
Module Name:src Committed By: matt Date: Fri Mar 28 21:41:46 UTC 2014 Modified Files: src/sys/arch/arm/cortex: gtmr.c gtmr_var.h Log Message: Add gtmr_bootdelay. rename clockhandler to gtmr_intr To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/cortex/gtmr.c cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/cortex/gtmr_var.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/cortex/gtmr.c diff -u src/sys/arch/arm/cortex/gtmr.c:1.5 src/sys/arch/arm/cortex/gtmr.c:1.6 --- src/sys/arch/arm/cortex/gtmr.c:1.5 Tue Dec 17 13:11:18 2013 +++ src/sys/arch/arm/cortex/gtmr.c Fri Mar 28 21:41:46 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: gtmr.c,v 1.5 2013/12/17 13:11:18 joerg Exp $ */ +/* $NetBSD: gtmr.c,v 1.6 2014/03/28 21:41:46 matt Exp $ */ /*- * Copyright (c) 2012 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: gtmr.c,v 1.5 2013/12/17 13:11:18 joerg Exp $); +__KERNEL_RCSID(0, $NetBSD: gtmr.c,v 1.6 2014/03/28 21:41:46 matt Exp $); #include sys/param.h #include sys/bus.h @@ -51,7 +51,7 @@ __KERNEL_RCSID(0, $NetBSD: gtmr.c,v 1.5 static int gtmr_match(device_t, cfdata_t, void *); static void gtmr_attach(device_t, device_t, void *); -static int clockhandler(void *); +static int gtmr_intr(void *); static u_int gtmr_get_timecount(struct timecounter *); @@ -125,7 +125,7 @@ gtmr_attach(device_t parent, device_t se device_xname(self), missing interrupts); sc-sc_global_ih = intr_establish(IRQ_GTMR_PPI_VTIMER, IPL_CLOCK, - IST_EDGE, clockhandler, NULL); + IST_EDGE | IST_MPSAFE, gtmr_intr, NULL); if (sc-sc_global_ih == NULL) panic(%s: unable to register timer interrupt, __func__); aprint_normal_dev(self, interrupting on irq %d\n, @@ -241,13 +241,30 @@ gtmr_delay(unsigned int n) } } +void +gtmr_bootdelay(unsigned int ticks) +{ + const uint32_t ctl = armreg_cntv_ctl_read(); + armreg_cntv_ctl_write(ctl | ARM_CNTCTL_ENABLE | ARM_CNTCTL_IMASK); + + /* Write Timer/Value to set new compare time */ + armreg_cntv_tval_write(ticks); + + /* Spin until compare time is hit */ + while ((armreg_cntv_ctl_read() ARM_CNTCTL_ISTATUS) == 0) { + /* spin */ + } + + armreg_cntv_ctl_write(ctl); +} + /* - * clockhandler: + * gtmr_intr: * * Handle the hardclock interrupt. */ static int -clockhandler(void *arg) +gtmr_intr(void *arg) { const uint64_t now = armreg_cntv_ct_read(); struct cpu_info * const ci = curcpu(); Index: src/sys/arch/arm/cortex/gtmr_var.h diff -u src/sys/arch/arm/cortex/gtmr_var.h:1.3 src/sys/arch/arm/cortex/gtmr_var.h:1.4 --- src/sys/arch/arm/cortex/gtmr_var.h:1.3 Thu Sep 12 15:38:04 2013 +++ src/sys/arch/arm/cortex/gtmr_var.h Fri Mar 28 21:41:46 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: gtmr_var.h,v 1.3 2013/09/12 15:38:04 matt Exp $ */ +/* $NetBSD: gtmr_var.h,v 1.4 2014/03/28 21:41:46 matt Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. * All rights reserved. @@ -46,6 +46,7 @@ struct gtmr_softc { struct cpu_info; void gtmr_init_cpu_clock(struct cpu_info *); void gtmr_delay(unsigned int n); +void gtmr_bootdelay(unsigned int n); #endif #endif /* _ARM_CORTEX_GTMR_VAR_ */
CVS commit: src/sys/arch/arm/mainbus
Module Name:src Committed By: matt Date: Fri Mar 28 21:43:01 UTC 2014 Modified Files: src/sys/arch/arm/mainbus: cpu_mainbus.c Log Message: arm_cpu_max = num of cpus To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/mainbus/cpu_mainbus.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/mainbus/cpu_mainbus.c diff -u src/sys/arch/arm/mainbus/cpu_mainbus.c:1.13 src/sys/arch/arm/mainbus/cpu_mainbus.c:1.14 --- src/sys/arch/arm/mainbus/cpu_mainbus.c:1.13 Wed Aug 29 23:16:35 2012 +++ src/sys/arch/arm/mainbus/cpu_mainbus.c Fri Mar 28 21:43:01 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu_mainbus.c,v 1.13 2012/08/29 23:16:35 matt Exp $ */ +/* $NetBSD: cpu_mainbus.c,v 1.14 2014/03/28 21:43:01 matt Exp $ */ /* * Copyright (c) 1995 Mark Brinicombe. @@ -44,7 +44,7 @@ #include locators.h #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: cpu_mainbus.c,v 1.13 2012/08/29 23:16:35 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: cpu_mainbus.c,v 1.14 2014/03/28 21:43:01 matt Exp $); #include sys/param.h #include sys/systm.h @@ -69,7 +69,7 @@ static void cpu_mainbus_attach(device_t, #ifdef MULTIPROCESSOR extern u_int arm_cpu_max; #else -#define arm_cpu_max 0 +#define arm_cpu_max 1 #endif static int @@ -79,14 +79,14 @@ cpu_mainbus_match(device_t parent, cfdat int id = mb-mb_core; if (id != MAINBUSCF_CORE_DEFAULT) { - if (id arm_cpu_max || kcpuset_isset(kcpuset_attached, id)) + if (id = arm_cpu_max || kcpuset_isset(kcpuset_attached, id)) return 0; if (id == 0 cpu_info_store.ci_dev != NULL) return 0; return 1; } - for (id = 0; id = arm_cpu_max; id++) { + for (id = 0; id arm_cpu_max; id++) { #ifdef MULTIPROCESSOR if (cpu_info[id] != NULL cpu_info[id]-ci_dev != NULL) continue;
CVS commit: src/sys/arch/arm/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:43:49 UTC 2014 Modified Files: src/sys/arch/arm/arm: ast.c Log Message: Make sure the pmap is activated before returning to userland. To generate a diff of this commit: cvs rdiff -u -r1.22 -r1.23 src/sys/arch/arm/arm/ast.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/arm/ast.c diff -u src/sys/arch/arm/arm/ast.c:1.22 src/sys/arch/arm/arm/ast.c:1.23 --- src/sys/arch/arm/arm/ast.c:1.22 Sun Aug 18 06:28:18 2013 +++ src/sys/arch/arm/arm/ast.c Fri Mar 28 21:43:49 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: ast.c,v 1.22 2013/08/18 06:28:18 matt Exp $ */ +/* $NetBSD: ast.c,v 1.23 2014/03/28 21:43:49 matt Exp $ */ /* * Copyright (c) 1994,1995 Mark Brinicombe @@ -41,7 +41,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: ast.c,v 1.22 2013/08/18 06:28:18 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: ast.c,v 1.23 2014/03/28 21:43:49 matt Exp $); #include opt_ddb.h @@ -74,6 +74,17 @@ userret(struct lwp *l) /* Invoke MI userret code */ mi_userret(l); +#if defined(__PROG32) defined(ARM_MMU_EXTENDED) + /* + * If our ASID got released, access via TTBR0 will have been disabled. + * So if it is disabled, activate the lwp again to get a new ASID. + */ + KASSERT(curcpu()-ci_pmap_cur == l-l_proc-p_vmspace-vm_map.pmap); + if (armreg_ttbcr_read() TTBCR_S_PD0) { + pmap_activate(l); + } +#endif + #if defined(__PROG32) defined(DIAGNOSTIC) KASSERT((lwp_trapframe(l)-tf_spsr IF32_bits) == 0); #endif
CVS commit: src/sys/arch/arm/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:44:35 UTC 2014 Modified Files: src/sys/arch/arm/arm: undefined.c Log Message: Move undefined evcnt's to cpu_info. To generate a diff of this commit: cvs rdiff -u -r1.53 -r1.54 src/sys/arch/arm/arm/undefined.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/arm/undefined.c diff -u src/sys/arch/arm/arm/undefined.c:1.53 src/sys/arch/arm/arm/undefined.c:1.54 --- src/sys/arch/arm/arm/undefined.c:1.53 Sat Mar 15 05:58:30 2014 +++ src/sys/arch/arm/arm/undefined.c Fri Mar 28 21:44:35 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: undefined.c,v 1.53 2014/03/15 05:58:30 ozaki-r Exp $ */ +/* $NetBSD: undefined.c,v 1.54 2014/03/28 21:44:35 matt Exp $ */ /* * Copyright (c) 2001 Ben Harris. @@ -55,7 +55,7 @@ #include sys/kgdb.h #endif -__KERNEL_RCSID(0, $NetBSD: undefined.c,v 1.53 2014/03/15 05:58:30 ozaki-r Exp $); +__KERNEL_RCSID(0, $NetBSD: undefined.c,v 1.54 2014/03/28 21:44:35 matt Exp $); #include sys/kmem.h #include sys/queue.h @@ -124,10 +124,6 @@ remove_coproc_handler(void *cookie) kmem_free(uh, sizeof(*uh)); } -static struct evcnt cp15_ev = -EVCNT_INITIALIZER(EVCNT_TYPE_TRAP, NULL, cpu0, undefined cp15 insn traps); -EVCNT_ATTACH_STATIC(cp15_ev); - static int cp15_trapper(u_int addr, u_int insn, struct trapframe *tf, int code) { @@ -158,7 +154,7 @@ cp15_trapper(u_int addr, u_int insn, str if ((insn 0x0fff) == 0xee1d0f70) { *regp = (uintptr_t)l-l_private; tf-tf_pc += INSN_SIZE; - cp15_ev.ev_count++; + curcpu()-ci_und_cp15_ev.ev_count++; return 0; } @@ -172,7 +168,7 @@ cp15_trapper(u_int addr, u_int insn, str else pcb-pcb_user_pid_rw = *regp; tf-tf_pc += INSN_SIZE; - cp15_ev.ev_count++; + curcpu()-ci_und_cp15_ev.ev_count++; return 0; } @@ -282,10 +278,6 @@ undefined_init(void) #endif } -static struct evcnt und_ev = -EVCNT_INITIALIZER(EVCNT_TYPE_TRAP, NULL, cpu0, undefined insn traps); -EVCNT_ATTACH_STATIC(und_ev); - void undefinedinstruction(trapframe_t *tf) { @@ -300,7 +292,7 @@ undefinedinstruction(trapframe_t *tf) int s; #endif - und_ev.ev_count++; + curcpu()-ci_und_ev.ev_count++; #ifdef KDTRACE_HOOKS if ((tf-tf_spsr PSR_MODE) != PSR_USR32_MODE) {
CVS commit: src/sys/arch/arm/include
Module Name:src Committed By: matt Date: Fri Mar 28 21:44:59 UTC 2014 Modified Files: src/sys/arch/arm/include: cpu.h Log Message: Make ddb_regs, undefined vfp evcnt's per cpu. To generate a diff of this commit: cvs rdiff -u -r1.82 -r1.83 src/sys/arch/arm/include/cpu.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/include/cpu.h diff -u src/sys/arch/arm/include/cpu.h:1.82 src/sys/arch/arm/include/cpu.h:1.83 --- src/sys/arch/arm/include/cpu.h:1.82 Wed Feb 26 01:57:48 2014 +++ src/sys/arch/arm/include/cpu.h Fri Mar 28 21:44:59 2014 @@ -166,7 +166,11 @@ struct cpu_info { struct pmap *ci_pmap_lastuser; struct pmap *ci_pmap_cur; tlb_asid_t ci_pmap_asid_cur; + struct trapframe *ci_ddb_regs; struct evcnt ci_abt_evs[16]; + struct evcnt ci_und_ev; + struct evcnt ci_und_cp15_ev; + struct evcnt ci_vfp_evs[3]; #if defined(MP_CPU_INFO_MEMBERS) MP_CPU_INFO_MEMBERS #endif
CVS commit: src/sys/arch/arm/include
Module Name:src Committed By: matt Date: Fri Mar 28 21:47:48 UTC 2014 Modified Files: src/sys/arch/arm/include: cpufunc.h Log Message: Use cpsie/cpsid if possible. change cache_type to uint8_t more ARM_MMU_EXTENDED support (ASID) To generate a diff of this commit: cvs rdiff -u -r1.68 -r1.69 src/sys/arch/arm/include/cpufunc.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/include/cpufunc.h diff -u src/sys/arch/arm/include/cpufunc.h:1.68 src/sys/arch/arm/include/cpufunc.h:1.69 --- src/sys/arch/arm/include/cpufunc.h:1.68 Sat Feb 22 20:50:46 2014 +++ src/sys/arch/arm/include/cpufunc.h Fri Mar 28 21:47:48 2014 @@ -60,7 +60,11 @@ struct cpu_functions { u_int (*cf_control) (u_int, u_int); void (*cf_domains) (u_int); +#if defined(ARM_MMU_EXTENDED) + void (*cf_setttb) (u_int, tlb_asid_t); +#else void (*cf_setttb) (u_int, bool); +#endif u_int (*cf_faultstatus) (void); u_int (*cf_faultaddress) (void); @@ -152,7 +156,11 @@ struct cpu_functions { int (*cf_dataabt_fixup) (void *); int (*cf_prefetchabt_fixup) (void *); +#if defined(ARM_MMU_EXTENDED) + void (*cf_context_switch) (u_int, tlb_asid_t); +#else void (*cf_context_switch) (u_int); +#endif void (*cf_setup) (char *); }; @@ -424,10 +432,14 @@ extern unsigned armv5_dcache_index_inc; void arm11mpcore_setup (char *); #endif -#if defined(CPU_ARM11) || defined(CPU_CORTEX) +#if defined(CPU_ARM11) +#if defined(ARM_MMU_EXTENDED) +void arm11_setttb (u_int, tlb_asid_t); +void arm11_context_switch (u_int, tlb_asid_t); +#else void arm11_setttb (u_int, bool); - void arm11_context_switch (u_int); +#endif void arm11_cpu_sleep (int); void arm11_setup (char *string); @@ -459,7 +471,13 @@ void armv6_idcache_wbinv_range (vaddr_t, #endif #if defined(CPU_CORTEX) +#if defined(ARM_MMU_EXTENDED) +void armv7_setttb(u_int, tlb_asid_t); +void armv7_context_switch(u_int, tlb_asid_t); +#else void armv7_setttb(u_int, bool); +void armv7_context_switch(u_int); +#endif void armv7_icache_sync_range(vaddr_t, vsize_t); void armv7_dcache_wb_range(vaddr_t, vsize_t); @@ -478,7 +496,6 @@ void armv7_tlb_flushI_SE(vaddr_t); void armv7_tlb_flushD_SE(vaddr_t); void armv7_cpu_sleep(int); -void armv7_context_switch(u_int); void armv7_drain_writebuf(void); void armv7_setup(char *string); #endif @@ -489,7 +506,13 @@ void armv7_idcache_wbinv_all(void); #endif #if defined(CPU_PJ4B) +#if defined(ARM_MMU_EXTENDED) +void pj4b_setttb(u_int, tlb_asid_t); +void pj4b_context_switch(u_int, tlb_asid_t); +#else void pj4b_setttb(u_int, bool); +void pj4b_context_switch(u_int); +#endif void pj4b_tlb_flushID(void); void pj4b_tlb_flushID_SE(vaddr_t); @@ -503,7 +526,6 @@ void pj4b_drain_writebuf(void); void pj4b_drain_readbuf(void); void pj4b_flush_brnchtgt_all(void); void pj4b_flush_brnchtgt_va(u_int); -void pj4b_context_switch(u_int); void pj4b_sleep(int); void pj4bv7_setup(char *string); @@ -653,16 +675,32 @@ disable_interrupts(uint32_t mask) static __inline uint32_t enable_interrupts(uint32_t mask) { - uint32_t ret, tmp; + uint32_t ret; mask = (I32_bit | F32_bit); - __asm volatile( - mrs %0, cpsr\n /* Get the CPSR */ - bic %1, %0, %2\n /* Clear bits */ - msr cpsr_c, %1\n /* Set the control field of CPSR */ - : =r (ret), =r (tmp) - : r (mask) - : memory); + /* Get the CPSR */ + __asm __volatile(mrs\t%0, cpsr\n : =r(ret)); +#ifdef _ARM_ARCH_6 + if (__builtin_constant_p(mask)) { + switch (mask) { + case I32_bit | F32_bit: + __asm __volatile(cpsie\tif); + break; + case I32_bit: + __asm __volatile(cpsie\ti); + break; + case F32_bit: + __asm __volatile(cpsie\tf); + break; + default: + break; + } + return ret; + } +#endif /* _ARM_ARCH_6 */ + + /* Set the control field of CPSR */ + __asm volatile(msr\tcpsr_c, %0 :: r(ret ~mask)); return ret; } @@ -764,7 +802,7 @@ struct arm_cache_info { u_int dcache_way_size; u_int dcache_sets; - u_int cache_type; + uint8_t cache_type; bool cache_unified; uint8_t icache_type; uint8_t dcache_type;
CVS commit: src/sys/arch/arm/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:49:22 UTC 2014 Modified Files: src/sys/arch/arm/arm: cpufunc.c Log Message: Initialize cache way_size and sets To generate a diff of this commit: cvs rdiff -u -r1.140 -r1.141 src/sys/arch/arm/arm/cpufunc.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/arm/cpufunc.c diff -u src/sys/arch/arm/arm/cpufunc.c:1.140 src/sys/arch/arm/arm/cpufunc.c:1.141 --- src/sys/arch/arm/arm/cpufunc.c:1.140 Fri Feb 21 06:28:25 2014 +++ src/sys/arch/arm/arm/cpufunc.c Fri Mar 28 21:49:22 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: cpufunc.c,v 1.140 2014/02/21 06:28:25 matt Exp $ */ +/* $NetBSD: cpufunc.c,v 1.141 2014/03/28 21:49:22 matt Exp $ */ /* * arm7tdmi support code Copyright (c) 2001 John Fremlin @@ -49,7 +49,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: cpufunc.c,v 1.140 2014/02/21 06:28:25 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: cpufunc.c,v 1.141 2014/03/28 21:49:22 matt Exp $); #include opt_compat_netbsd.h #include opt_cpuoptions.h @@ -1506,19 +1506,21 @@ static void get_cacheinfo_clidr(struct arm_cache_info *info, u_int level, u_int clidr) { u_int csid; - u_int nsets; if (clidr 6) { csid = get_cachesize_cp15(level 1); /* select dcache values */ - nsets = CPU_CSID_NUMSETS(csid) + 1; + info-dcache_sets = CPU_CSID_NUMSETS(csid) + 1; info-dcache_ways = CPU_CSID_ASSOC(csid) + 1; info-dcache_line_size = 1U (CPU_CSID_LEN(csid) + 4); - info-dcache_size = info-dcache_line_size * info-dcache_ways * nsets; + info-dcache_way_size = + info-dcache_line_size * info-dcache_sets; + info-dcache_size = info-dcache_way_size * info-dcache_ways; if (level == 0) { arm_dcache_log2_assoc = CPU_CSID_ASSOC(csid) + 1; arm_dcache_log2_linesize = CPU_CSID_LEN(csid) + 4; - arm_dcache_log2_nsets = 31 - __builtin_clz(nsets*2-1); + arm_dcache_log2_nsets = + 31 - __builtin_clz(info-dcache_sets*2-1); } } @@ -1532,17 +1534,19 @@ get_cacheinfo_clidr(struct arm_cache_inf if (info-cache_unified) { info-icache_ways = info-dcache_ways; info-icache_line_size = info-dcache_line_size; + info-icache_way_size = info-dcache_way_size; info-icache_size = info-dcache_size; } else { csid = get_cachesize_cp15((level 1)|CPU_CSSR_InD); /* select icache values */ - nsets = CPU_CSID_NUMSETS(csid) + 1; + info-icache_sets = CPU_CSID_NUMSETS(csid) + 1; info-icache_ways = CPU_CSID_ASSOC(csid) + 1; info-icache_line_size = 1U (CPU_CSID_LEN(csid) + 4); - info-icache_size = info-icache_line_size * info-icache_ways * nsets; + info-icache_way_size = info-icache_line_size * info-icache_sets; + info-icache_size = info-icache_way_size * info-icache_ways; } if (level == 0 - info-dcache_size / info-dcache_ways = PAGE_SIZE - info-icache_size / info-icache_ways = PAGE_SIZE) { + info-dcache_way_size = PAGE_SIZE + info-icache_way_size = PAGE_SIZE) { arm_cache_prefer_mask = 0; } } @@ -1595,8 +1599,11 @@ get_cachetype_cp15(void) if (arm_scache.dcache_line_size arm_dcache_align) arm_dcache_align = arm_scache.dcache_line_size; } - if (arm_pcache.dcache_type == CACHE_TYPE_PIPT - arm_pcache.icache_type == CACHE_TYPE_PIPT) { + /* + * The pmap cleans an entire way for an exec page so + * we don't care that it's VIPT anymore. + */ + if (arm_pcache.dcache_type == CACHE_TYPE_PIPT) { arm_cache_prefer_mask = 0; } goto out; @@ -1634,6 +1641,8 @@ get_cachetype_cp15(void) #endif } arm_pcache.icache_size = multiplier (CPU_CT_xSIZE_SIZE(isize) + 8); + arm_pcache.icache_way_size = + __BIT(9 + CPU_CT_xSIZE_SIZE(isize) - CPU_CT_xSIZE_ASSOC(isize)); } dsize = CPU_CT_DSIZE(ctype); @@ -1658,6 +1667,8 @@ get_cachetype_cp15(void) #endif } arm_pcache.dcache_size = multiplier (CPU_CT_xSIZE_SIZE(dsize) + 8); + arm_pcache.dcache_way_size = + __BIT(9 + CPU_CT_xSIZE_SIZE(dsize) - CPU_CT_xSIZE_ASSOC(dsize)); arm_dcache_align = arm_pcache.dcache_line_size; @@ -1724,10 +1735,20 @@ get_cachetype_table(void) arm_pcache.dcache_line_size = cachetab[i].ct_pdcache_line_size; arm_pcache.dcache_ways = cachetab[i].ct_pdcache_ways; + if (arm_pcache.dcache_ways) { +arm_pcache.dcache_way_size = +arm_pcache.dcache_line_size +/ arm_pcache.dcache_ways; + } arm_pcache.icache_size = cachetab[i].ct_picache_size; arm_pcache.icache_line_size = cachetab[i].ct_picache_line_size; arm_pcache.icache_ways = cachetab[i].ct_picache_ways; + if (arm_pcache.icache_ways) { +arm_pcache.icache_way_size = +arm_pcache.icache_line_size +/ arm_pcache.icache_ways; + } } }
CVS commit: src/sys/arch/arm/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:50:40 UTC 2014 Modified Files: src/sys/arch/arm/arm: cpufunc_asm_armv7.S Log Message: Add ARM_MMU_EXTENDED support To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/arm/cpufunc_asm_armv7.S 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/arm/cpufunc_asm_armv7.S diff -u src/sys/arch/arm/arm/cpufunc_asm_armv7.S:1.15 src/sys/arch/arm/arm/cpufunc_asm_armv7.S:1.16 --- src/sys/arch/arm/arm/cpufunc_asm_armv7.S:1.15 Mon Feb 24 00:49:53 2014 +++ src/sys/arch/arm/arm/cpufunc_asm_armv7.S Fri Mar 28 21:50:40 2014 @@ -50,9 +50,10 @@ ENTRY(armv7_context_switch) cmp ip, #0 orrlt r0, r0, #0x5b @ MP, cachable (Normal WB) orrge r0, r0, #0x1b @ Non-MP, cacheable, normal WB - mcr p15, 0, r0, c2, c0, 0 @ set the new TTB -#ifdef MULTIPROCESSOR - mcr p15, 0, r0, c8, c3, 0 @ flush the I+D + mcr p15, 0, r0, c2, c0, 0 @ set the new TTBR 0 +#ifdef ARM_MMU_EXTENDED + cmp r1, #0 + mcreq p15, 0, r0, c2, c0, 1 @ set the new TTBR 1 #else mcr p15, 0, r0, c8, c7, 0 @ flush the I+D #endif @@ -61,7 +62,7 @@ ENTRY(armv7_context_switch) bx lr END(armv7_context_switch) -#ifdef ARM_MMU_EXTENDED +#ifdef ARM_MMU_EXTENDED_XXX ENTRY(armv7_tlb_flushID_ASID) #ifdef MULTIPROCESSOR mcr p15, 0, r0, c8, c3, 2 @ flush I+D tlb all ASID @@ -77,14 +78,23 @@ END(armv7_tlb_flushID_ASID) STRONG_ALIAS(armv7_tlb_flushD_SE, armv7_tlb_flushID_SE) STRONG_ALIAS(armv7_tlb_flushI_SE, armv7_tlb_flushID_SE) ENTRY(armv7_tlb_flushID_SE) -#ifdef ARM_MMU_EXTENDED + bfc r0, #0, #12 @ clear ASID +#ifdef ARM_MMU_EXTENDED_XXX bfi r0, r1, #0, #8 @ insert ASID into MVA #endif #ifdef MULTIPROCESSOR mcr p15, 0, r0, c8, c3, 1 @ flush I+D tlb single entry -#else +#if PAGE_SIZE == 2*L2_S_SIZE + add r0, r0, #L2_S_SIZE + mcr p15, 0, r0, c8, c3, 1 @ flush I+D tlb single entry +#endif +#else /* !MULTIPROCESSOR */ + mcr p15, 0, r0, c8, c7, 1 @ flush I+D tlb single entry +#if PAGE_SIZE == 2*L2_S_SIZE + add r0, r0, #L2_S_SIZE mcr p15, 0, r0, c8, c7, 1 @ flush I+D tlb single entry #endif +#endif /* !MULTIPROCESSOR */ dsb@ data synchronization barrier isb bx lr @@ -113,12 +123,12 @@ ENTRY_NP(armv7_setttb) cmp ip, #0 orrlt r0, r0, #0x5b @ MP, cachable (Normal WB) orrge r0, r0, #0x1b @ Non-MP, cacheable, normal WB - mcr p15, 0, r0, c2, c0, 0 @ load new TTB + mcr p15, 0, r0, c2, c0, 0 @ load new TTBR 0 +#ifdef ARM_MMU_EXTENDED cmp r1, #0 -#ifdef MULTIPROCESSOR - mcrne p15, 0, r0, c8, c3, 0 @ invalidate all I+D TLBs + mcreq p15, 0, r0, c2, c0, 1 @ load new TTBR 1 #else - mcrne p15, 0, r0, c8, c7, 0 @ invalidate all I+D TLBs + mcr p15, 0, r0, c8, c7, 0 @ invalidate all I+D TLBs #endif dsb@ data synchronization barrier isb @@ -136,8 +146,16 @@ END(armv7_drain_writebuf) /* LINTSTUB: void armv7_icache_sync_range(vaddr_t, vsize_t); */ ENTRY_NP(armv7_icache_sync_range) + mov ip, #CPU_CSSR_InD + mcr p15, 2, ip, c0, c0, 0 @ set cache level to L1-I mrc p15, 1, r2, c0, c0, 0 @ read CCSIDR + mov ip, #0 + mcr p15, 2, ip, c0, c0, 0 @ set cache level to L1-D + mrc p15, 1, r3, c0, c0, 0 @ read CCSIDR and r2, r2, #7 @ get line size (log2(size)-4, 0=16) + and r3, r3, #7 @ get line size (log2(size)-4, 0=16) + cmp r2, r3 @ compare ilinesize to dlinesize + movgt r2, r3 @ pick lesser of the two mov ip, #16 @ make a bit mask lsl r2, ip, r2 @ and shift into position sub ip, r2, #1 @ make into a mask @@ -172,6 +190,8 @@ ENTRY_NP(armv7_icache_sync_all) END(armv7_icache_sync_all) ENTRY(armv7_dcache_wb_range) + mov ip, #0 + mcr p15, 2, ip, c0, c0, 0 @ set cache level to L1 mrc p15, 1, r2, c0, c0, 0 @ read CCSIDR and r2, r2, #7 @ get line size (log2(size)-4, 0=16) mov ip, #16 @ make a bit mask @@ -192,6 +212,8 @@ END(armv7_dcache_wb_range) /* LINTSTUB: void armv7_dcache_wbinv_range(vaddr_t, vsize_t); */ ENTRY(armv7_dcache_wbinv_range) + mov ip, #0 + mcr p15, 2, ip, c0, c0, 0 @ set cache level to L1 mrc p15, 1, r2, c0, c0, 0 @ read CCSIDR and r2, r2, #7 @ get line size (log2(size)-4, 0=16) mov ip, #16 @ make a bit mask @@ -202,7 +224,7 @@ ENTRY(armv7_dcache_wbinv_range) bic r0, r0, ip @ clear offset from start. dsb 1: - mcr p15, 0, r0, c7, c14, 1 @ wb and inv the D-Cache line + mcr p15, 0, r0, c7, c14, 1 @ wb and inv the D-Cache line to PoC add r0, r0, r2 subs r1, r1, r2 bhi 1b @@ -212,6 +234,8 @@ END(armv7_dcache_wbinv_range) /* * LINTSTUB: void armv7_dcache_inv_range(vaddr_t, vsize_t); */ ENTRY(armv7_dcache_inv_range) + mov ip, #0 + mcr p15, 2, ip, c0, c0, 0 @ set cache level to L1 mrc p15, 1, r2, c0, c0, 0 @ read CCSIDR and r2, r2, #7 @ get line size (log2(size)-4, 0=16) mov ip, #16 @ make a bit mask @@ -233,6 +257,8 @@ END(armv7_dcache_inv_range) /* * LINTSTUB: void armv7_idcache_wbinv_range(vaddr_t, vsize_t); */ ENTRY(armv7_idcache_wbinv_range) + mov ip,
CVS commit: src/sys/arch/arm/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:51:21 UTC 2014 Added Files: src/sys/arch/arm/arm32: arm32_tlb.c Log Message: Add tlb routines for pmap_tlb.c To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/arm32/arm32_tlb.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/arch/arm/arm32/arm32_tlb.c diff -u /dev/null src/sys/arch/arm/arm32/arm32_tlb.c:1.1 --- /dev/null Fri Mar 28 21:51:21 2014 +++ src/sys/arch/arm/arm32/arm32_tlb.c Fri Mar 28 21:51:21 2014 @@ -0,0 +1,200 @@ +/*- + * Copyright (c) 2013 The NetBSD Foundation, Inc. + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Matt Thomas of 3am Software Foundry. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ +#include sys/cdefs.h +__KERNEL_RCSID(1, $NetBSD: arm32_tlb.c,v 1.1 2014/03/28 21:51:21 matt Exp $); + +#include sys/param.h +#include sys/types.h + +#include uvm/uvm.h + +#include arm/locore.h + +bool arm_has_tlbiasid_p; // CPU supports TLBIASID system coprocessor op + +tlb_asid_t +tlb_get_asid(void) +{ + return armreg_contextidr_read() 0xff; +} + +void +tlb_set_asid(tlb_asid_t asid) +{ + arm_dsb(); + if (asid == 0) { + armreg_ttbcr_write(armreg_ttbcr_read() | TTBCR_S_PD0); + } + armreg_contextidr_write(asid); + arm_isb(); +} + +void +tlb_invalidate_all(void) +{ + arm_dsb(); + armreg_tlbiall_write(0); + arm_isb(); +} + +void +tlb_invalidate_globals(void) +{ + tlb_invalidate_all(); +} + +void +tlb_invalidate_asids(tlb_asid_t lo, tlb_asid_t hi) +{ + arm_dsb(); + if (arm_has_tlbiasid_p) { + armreg_tlbiall_write(0); + } else { + for (; lo = hi; lo++) { + armreg_tlbiasid_write(lo); + } + } + arm_isb(); +} + +void +tlb_invalidate_addr(vaddr_t va, tlb_asid_t asid) +{ + arm_dsb(); + va = trunc_page(va) | asid; + for (vaddr_t eva = va + PAGE_SIZE; va eva; va += L2_S_SIZE) { + armreg_tlbimva_write(va); + //armreg_tlbiall_write(asid); + } + arm_isb(); +} + +bool +tlb_update_addr(vaddr_t va, tlb_asid_t asid, pt_entry_t pte, bool insert_p) +{ + tlb_invalidate_addr(va, asid); + return true; +} + +#if !defined(MULTIPROCESSOR) defined(CPU_CORTEXA5) +static u_int +tlb_cortex_a5_record_asids(u_long *mapp) +{ + u_int nasids = 0; + for (size_t va_index = 0; va_index 63; va_index++) { + for (size_t way = 0; way 2; way++) { + armreg_tlbdataop_write( + __SHIFTIN(way, ARM_TLBDATAOP_WAY) + | __SHIFTIN(va_index, ARM_A5_TLBDATAOP_INDEX)); + arm_isb(); + const uint64_t d = ((uint64_t) armreg_tlbdata1_read()) + | armreg_tlbdata0_read(); + if (!(d ARM_TLBDATA_VALID) + || !(d ARM_V5_TLBDATA_nG)) +continue; + + const tlb_asid_t asid = __SHIFTOUT(d, + ARM_V5_TLBDATA_ASID); + const u_long mask = 1L (asid 31); + const size_t idx = asid 5; + if (mapp[idx] mask) +continue; + + mapp[idx] |= mask; + nasids++; + } + } + return nasids; +} +#endif + +#if !defined(MULTIPROCESSOR) defined(CPU_CORTEXA7) +static u_int +tlb_cortex_a7_record_asids(u_long *mapp) +{ + u_int nasids = 0; + for (size_t va_index = 0; va_index 128; va_index++) { + for (size_t way = 0; way 2; way++) { + armreg_tlbdataop_write( + __SHIFTIN(way, ARM_TLBDATAOP_WAY) + | __SHIFTIN(va_index, ARM_A7_TLBDATAOP_INDEX)); + arm_isb(); + const uint32_t d0 = armreg_tlbdata0_read(); + const uint32_t d1 = armreg_tlbdata1_read(); + if (!(d0 ARM_TLBDATA_VALID) + || !(d1 ARM_A7_TLBDATA1_nG)) +continue; + + const uint64_t d01 = ((uint64_t) d1)|d0; + const tlb_asid_t asid = __SHIFTOUT(d01, + ARM_A7_TLBDATA01_ASID); + const u_long mask =
CVS commit: src/sys/arch/arm/include/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:51:59 UTC 2014 Modified Files: src/sys/arch/arm/include/arm32: machdep.h Log Message: Change arm_cpu_mbox to volatile To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/sys/arch/arm/include/arm32/machdep.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/include/arm32/machdep.h diff -u src/sys/arch/arm/include/arm32/machdep.h:1.17 src/sys/arch/arm/include/arm32/machdep.h:1.18 --- src/sys/arch/arm/include/arm32/machdep.h:1.17 Sat Oct 20 14:42:20 2012 +++ src/sys/arch/arm/include/arm32/machdep.h Fri Mar 28 21:51:59 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: machdep.h,v 1.17 2012/10/20 14:42:20 matt Exp $ */ +/* $NetBSD: machdep.h,v 1.18 2014/03/28 21:51:59 matt Exp $ */ #ifndef _ARM32_BOOT_MACHDEP_H_ #define _ARM32_BOOT_MACHDEP_H_ @@ -53,7 +53,7 @@ extern struct bootmem_info bootmem_info; extern char *booted_kernel; extern volatile uint32_t arm_cpu_hatched; -extern uint32_t arm_cpu_mbox; +extern volatile uint32_t arm_cpu_mbox; extern u_int arm_cpu_max; /* misc prototypes used by the many arm machdeps */
CVS commit: src/sys/arch/arm/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:52:53 UTC 2014 Modified Files: src/sys/arch/arm/arm32: cpuswitch.S Log Message: ARM_MMU_EXTENDED support. To generate a diff of this commit: cvs rdiff -u -r1.82 -r1.83 src/sys/arch/arm/arm32/cpuswitch.S 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/arm32/cpuswitch.S diff -u src/sys/arch/arm/arm32/cpuswitch.S:1.82 src/sys/arch/arm/arm32/cpuswitch.S:1.83 --- src/sys/arch/arm/arm32/cpuswitch.S:1.82 Wed Feb 26 02:07:58 2014 +++ src/sys/arch/arm/arm32/cpuswitch.S Fri Mar 28 21:52:53 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: cpuswitch.S,v 1.82 2014/02/26 02:07:58 matt Exp $ */ +/* $NetBSD: cpuswitch.S,v 1.83 2014/03/28 21:52:53 matt Exp $ */ /* * Copyright 2003 Wasabi Systems, Inc. @@ -87,7 +87,7 @@ #include arm/asm.h #include arm/locore.h - RCSID($NetBSD: cpuswitch.S,v 1.82 2014/02/26 02:07:58 matt Exp $) + RCSID($NetBSD: cpuswitch.S,v 1.83 2014/03/28 21:52:53 matt Exp $) /* LINTSTUB: include sys/param.h */ @@ -279,7 +279,9 @@ ENTRY(cpu_switchto) #endif /* Record the old lwp for pmap_activate()'s benefit */ +#ifndef ARM_MMU_EXTENDED str r4, [r3, #CI_LASTLWP] +#endif /* rem: r4 = old lwp */ /* rem: r5 = new lwp's proc */
CVS commit: src/sys/arch/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:54:12 UTC 2014 Modified Files: src/sys/arch/arm/arm32: db_interface.c db_machdep.c src/sys/arch/arm/include: db_machdep.h src/sys/arch/arm/include/arm32: db_machdep.h Log Message: Make ddb_registers per-cpu. All switching of CPUs (xxx doesn't work yet). To generate a diff of this commit: cvs rdiff -u -r1.50 -r1.51 src/sys/arch/arm/arm32/db_interface.c cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/arm32/db_machdep.c cvs rdiff -u -r1.19 -r1.20 src/sys/arch/arm/include/db_machdep.h cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/include/arm32/db_machdep.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/arm32/db_interface.c diff -u src/sys/arch/arm/arm32/db_interface.c:1.50 src/sys/arch/arm/arm32/db_interface.c:1.51 --- src/sys/arch/arm/arm32/db_interface.c:1.50 Sun Dec 15 09:13:47 2013 +++ src/sys/arch/arm/arm32/db_interface.c Fri Mar 28 21:54:12 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: db_interface.c,v 1.50 2013/12/15 09:13:47 skrll Exp $ */ +/* $NetBSD: db_interface.c,v 1.51 2014/03/28 21:54:12 matt Exp $ */ /* * Copyright (c) 1996 Scott K. Stevens @@ -35,7 +35,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: db_interface.c,v 1.50 2013/12/15 09:13:47 skrll Exp $); +__KERNEL_RCSID(0, $NetBSD: db_interface.c,v 1.51 2014/03/28 21:54:12 matt Exp $); #include opt_ddb.h #include opt_kgdb.h @@ -45,6 +45,8 @@ __KERNEL_RCSID(0, $NetBSD: db_interface #include sys/reboot.h #include sys/systm.h /* just for boothowto */ #include sys/exec.h +#include sys/atomic.h +#include sys/intr.h #include uvm/uvm_extern.h @@ -69,7 +71,12 @@ u_int db_fetch_reg(int, db_regs_t *); int db_trapper(u_int, u_int, trapframe_t *, int); int db_active = 0; -db_regs_t ddb_regs; /* register state */ +#ifdef MULTIPROCESSOR +volatile struct cpu_info *db_onproc; +volatile struct cpu_info *db_newcpu; +#endif + + #ifdef DDB @@ -79,12 +86,23 @@ db_regs_t ddb_regs; /* register state */ int kdb_trap(int type, db_regs_t *regs) { + struct cpu_info * const ci = curcpu(); int s; switch (type) { case T_BREAKPOINT: /* breakpoint */ case -1: /* keyboard interrupt */ break; +#ifdef MULTIPROCESSOR + case -2: + /* + * We called to enter ddb from another process but by the time + * we got here, no one was in ddb. So ignore the request. + */ + if (db_onproc == NULL) + return 1; + break; +#endif default: if (db_recover != 0) { /* This will longjmp back into db_command_loop() */ @@ -95,17 +113,74 @@ kdb_trap(int type, db_regs_t *regs) /* Should switch to kdb`s own stack here. */ - ddb_regs = *regs; +#ifdef MULTIPROCESSOR + const bool is_mp_p = ncpu 1; + if (is_mp_p) { + /* + * Try to take ownership of DDB. If we do, tell all other + * CPUs to enter DDB too. + */ + if (atomic_cas_ptr(db_onproc, NULL, ci) == NULL) { + intr_ipi_send(NULL, IPI_DDB); + } + } + for (;;) { + if (is_mp_p) { + /* + * While we aren't the master, wait until the master + * gives control to us or exits. If it exited, we + * just exit to. Otherwise this cpu will enter DDB. + */ + membar_consumer(); + while (db_onproc != ci) { +if (db_onproc == NULL) + return 1; +#ifdef _ARM_ARCH_6 +__asm __volatile(wfe); +membar_consumer(); +#endif +if (db_onproc == ci) { + printf(%s: switching to %s\n, + __func__, ci-ci_cpuname); +} + } + } +#endif - s = splhigh(); - db_active++; - cnpollc(true); - db_trap(type, 0/*code*/); - cnpollc(false); - db_active--; - splx(s); + s = splhigh(); + ci-ci_ddb_regs = regs; + atomic_inc_32(db_active); + cnpollc(true); + db_trap(type, 0/*code*/); + cnpollc(false); + atomic_dec_32(db_active); + ci-ci_ddb_regs = NULL; + splx(s); + +#ifdef MULTIPROCESSOR + if (is_mp_p db_newcpu != NULL) { + db_onproc = db_newcpu; + db_newcpu = NULL; +#ifdef _ARM_ARCH_6 + membar_producer(); + __asm __volatile(sev; sev); +#endif + continue; + } + break; + } - *regs = ddb_regs; + if (is_mp_p) { + /* + * We are exiting DDB so there is noone onproc. Tell + * the other CPUs to exit. + */ + db_onproc = NULL; +#ifdef _ARM_ARCH_6 + __asm __volatile(sev; sev); +#endif + } +#endif return (1); } Index: src/sys/arch/arm/arm32/db_machdep.c diff -u src/sys/arch/arm/arm32/db_machdep.c:1.18 src/sys/arch/arm/arm32/db_machdep.c:1.19 --- src/sys/arch/arm/arm32/db_machdep.c:1.18 Sat Mar 1 05:41:39 2014 +++ src/sys/arch/arm/arm32/db_machdep.c Fri Mar 28 21:54:12 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: db_machdep.c,v 1.18 2014/03/01 05:41:39 matt Exp $ */ +/* $NetBSD: db_machdep.c,v 1.19 2014/03/28 21:54:12 matt Exp $ */ /* * Copyright (c) 1996 Mark Brinicombe @@ -28,10 +28,13 @@ * rights to redistribute these changes. */ +#include opt_multiprocessor.h + #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: db_machdep.c,v 1.18 2014/03/01
CVS commit: src/sys/arch/arm/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:56:02 UTC 2014 Modified Files: src/sys/arch/arm/arm32: genassym.cf Log Message: Add ARM_MMU_EXTENDED support. To generate a diff of this commit: cvs rdiff -u -r1.67 -r1.68 src/sys/arch/arm/arm32/genassym.cf 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/arm32/genassym.cf diff -u src/sys/arch/arm/arm32/genassym.cf:1.67 src/sys/arch/arm/arm32/genassym.cf:1.68 --- src/sys/arch/arm/arm32/genassym.cf:1.67 Wed Feb 26 02:07:58 2014 +++ src/sys/arch/arm/arm32/genassym.cf Fri Mar 28 21:56:02 2014 @@ -1,4 +1,4 @@ -# $NetBSD: genassym.cf,v 1.67 2014/02/26 02:07:58 matt Exp $ +# $NetBSD: genassym.cf,v 1.68 2014/03/28 21:56:02 matt Exp $ # Copyright (c) 1982, 1990 The Regents of the University of California. # All rights reserved. @@ -48,6 +48,7 @@ include uvm/uvm_extern.h include arm/fiq.h include arm/vfpreg.h include arm/locore.h +include arm/undefined.h include arm/arm32/pte.h include machine/pmap.h @@ -81,6 +82,10 @@ ifdef __HAVE_UNNESTED_INTRS define __HAVE_UNNESTED_INTRS 1 endif +ifdef ARM_MMU_EXTENDED +define ARM_MMU_EXTENDED 1 +endif + define KERNEL_BASE KERNEL_BASE define VM_MIN_ADDRESS VM_MIN_ADDRESS define VM_MAXUSER_ADDRESS VM_MAXUSER_ADDRESS @@ -90,6 +95,12 @@ define DCACHE_LINE_SIZE offsetof(struct define PV_PA offsetof(pv_addr_t, pv_pa) define PMAP_DOMAIN_KERNEL PMAP_DOMAIN_KERNEL define DOMAIN_CLIENT DOMAIN_CLIENT +ifdef ARM_MMU_EXTENDED +define DOMAIN_DEFAULT ((DOMAIN_CLIENT (PMAP_DOMAIN_KERNEL*2)) | (DOMAIN_CLIENT (PMAP_DOMAIN_USER*2))) +else +define DOMAIN_DEFAULT ((DOMAIN_CLIENT (PMAP_DOMAIN_KERNEL*2)) | DOMAIN_CLIENT) +endif + define L1_S_PROTO_generic L1_S_PROTO_generic define L1_S_PROTO_armv7 L1_S_PROTO_armv7 define L1_S_PROTO_xscale L1_S_PROTO_xscale @@ -99,12 +110,15 @@ endif define L1_S_FRAME L1_S_FRAME define L1_S_SHIFT L1_S_SHIFT define L1_S_SIZE L1_S_SIZE +define L1_S_CACHEABLE L1_S_C|L1_S_B|L1_S_V6_S define L1_S_B L1_S_B define L1_S_C L1_S_C define L1_S_V6_S L1_S_V6_S +define L1_S_V6_XN L1_S_V6_XN define L1_S_AP_KR L1_S_AP(AP_KR) define L1_S_AP_KRW L1_S_AP(AP_KRW) define L1_S_APv7_KRW L1_S_AP(AP7_KRW) +define L1_S_DOM_MASK L1_S_DOM_MASK define L1_TABLE_SIZE L1_TABLE_SIZE define L1_TYPE_S L1_TYPE_S define L1_S_DOM_KERNEL L1_S_DOM(PMAP_DOMAIN_KERNEL) @@ -118,6 +132,8 @@ define L2_S_SIZE L2_S_SIZE define L2_C L2_C define L2_AP_KRW L2_AP(AP_KRW) +define TTBCR_S_N_1 __SHIFTIN(1, TTBCR_S_N) + ifdef PMAP_INCLUDE_PTE_SYNC define PMAP_INCLUDE_PTE_SYNC 1 endif @@ -217,6 +233,8 @@ define CI_LASTLWP offsetof(struct cpu_i define VFP_FPEXC_EN VFP_FPEXC_EN +define NSACR_VFPCP NSACR_CPn(VFP_COPROC)|NSACR_CPn(VFP_COPROC2) + # Constants required for in_cksum() and friends. define M_LENoffsetof(struct mbuf, m_len) define M_DATAoffsetof(struct mbuf, m_data)
CVS commit: src/sys/arch/arm/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:56:45 UTC 2014 Modified Files: src/sys/arch/arm/arm32: arm32_kvminit.c Log Message: ARM_MMU_EXTENDED support. To generate a diff of this commit: cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/arm32/arm32_kvminit.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/arm32/arm32_kvminit.c diff -u src/sys/arch/arm/arm32/arm32_kvminit.c:1.24 src/sys/arch/arm/arm32/arm32_kvminit.c:1.25 --- src/sys/arch/arm/arm32/arm32_kvminit.c:1.24 Wed Mar 5 02:17:21 2014 +++ src/sys/arch/arm/arm32/arm32_kvminit.c Fri Mar 28 21:56:45 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: arm32_kvminit.c,v 1.24 2014/03/05 02:17:21 matt Exp $ */ +/* $NetBSD: arm32_kvminit.c,v 1.25 2014/03/28 21:56:45 matt Exp $ */ /* * Copyright (c) 2002, 2003, 2005 Genetec Corporation. All rights reserved. @@ -122,7 +122,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: arm32_kvminit.c,v 1.24 2014/03/05 02:17:21 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: arm32_kvminit.c,v 1.25 2014/03/28 21:56:45 matt Exp $); #include sys/param.h #include sys/device.h @@ -371,7 +371,7 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_b { struct bootmem_info * const bmi = bootmem_info; #ifdef MULTIPROCESSOR - const size_t cpu_num = arm_cpu_max + 1; + const size_t cpu_num = arm_cpu_max; #else const size_t cpu_num = 1; #endif @@ -903,11 +903,12 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_b * tables. */ -#if defined(VERBOSE_INIT_ARM) 0 +#if defined(VERBOSE_INIT_ARM) printf(TTBR0=%#x, armreg_ttbr_read()); #ifdef _ARM_ARCH_6 - printf( TTBR1=%#x TTBCR=%#x, - armreg_ttbr1_read(), armreg_ttbcr_read()); + printf( TTBR1=%#x TTBCR=%#x CONTEXTIDR=%#x, + armreg_ttbr1_read(), armreg_ttbcr_read(), + armreg_contextidr_read()); #endif printf(\n); #endif @@ -931,6 +932,7 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_b /* * TTBCR should have been initialized by the MD start code. */ + KASSERT((armreg_contextidr_read() 0xff) == 0); KASSERT(armreg_ttbcr_read() == __SHIFTIN(1, TTBCR_S_N)); /* * Disable lookups via TTBR0 until there is an activated pmap. @@ -951,6 +953,20 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_b #else printf( (TTBR0=%#x), armreg_ttbr_read()); #endif +#endif + +#ifdef MULTIPROCESSOR + /* + * Kick the secondaries to load the TTB. After which they'll go + * back to sleep to wait for the final kick so they will hatch. + */ +#ifdef VERBOSE_INIT_ARM + printf( hatchlings); +#endif + cpu_boot_secondary_processors(); +#endif + +#ifdef VERBOSE_INIT_ARM printf( OK\n); #endif }
CVS commit: src/sys/arch/arm/cortex
Module Name:src Committed By: matt Date: Fri Mar 28 21:57:22 UTC 2014 Modified Files: src/sys/arch/arm/cortex: a9tmr.c Log Message: Mark interrupt as MPSAFE. To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/cortex/a9tmr.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/cortex/a9tmr.c diff -u src/sys/arch/arm/cortex/a9tmr.c:1.6 src/sys/arch/arm/cortex/a9tmr.c:1.7 --- src/sys/arch/arm/cortex/a9tmr.c:1.6 Thu Jun 20 05:30:21 2013 +++ src/sys/arch/arm/cortex/a9tmr.c Fri Mar 28 21:57:22 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: a9tmr.c,v 1.6 2013/06/20 05:30:21 matt Exp $ */ +/* $NetBSD: a9tmr.c,v 1.7 2014/03/28 21:57:22 matt Exp $ */ /*- * Copyright (c) 2012 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: a9tmr.c,v 1.6 2013/06/20 05:30:21 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: a9tmr.c,v 1.7 2014/03/28 21:57:22 matt Exp $); #include sys/param.h #include sys/bus.h @@ -146,7 +146,7 @@ a9tmr_attach(device_t parent, device_t s TMR_WDOG_BASE, TMR_WDOG_SIZE, sc-sc_wdog_memh); sc-sc_global_ih = intr_establish(IRQ_A9TMR_PPI_GTIMER, IPL_CLOCK, - IST_EDGE, clockhandler, NULL); + IST_EDGE | IST_MPSAFE, clockhandler, NULL); if (sc-sc_global_ih == NULL) panic(%s: unable to register timer interrupt, __func__); aprint_normal_dev(sc-sc_dev, interrupting on irq %d\n,
CVS commit: src/sys/external/bsd/drm2/linux
Module Name:src Committed By: riastradh Date: Fri Mar 28 23:19:41 UTC 2014 Modified Files: src/sys/external/bsd/drm2/linux: linux_kmap.c Log Message: Remove needless splvm/splx calls. From rmind@, who explained that the pmap(9) man page is wrong. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/external/bsd/drm2/linux/linux_kmap.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/external/bsd/drm2/linux/linux_kmap.c diff -u src/sys/external/bsd/drm2/linux/linux_kmap.c:1.2 src/sys/external/bsd/drm2/linux/linux_kmap.c:1.3 --- src/sys/external/bsd/drm2/linux/linux_kmap.c:1.2 Tue Mar 18 18:20:43 2014 +++ src/sys/external/bsd/drm2/linux/linux_kmap.c Fri Mar 28 23:19:41 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: linux_kmap.c,v 1.2 2014/03/18 18:20:43 riastradh Exp $ */ +/* $NetBSD: linux_kmap.c,v 1.3 2014/03/28 23:19:41 riastradh Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: linux_kmap.c,v 1.2 2014/03/18 18:20:43 riastradh Exp $); +__KERNEL_RCSID(0, $NetBSD: linux_kmap.c,v 1.3 2014/03/28 23:19:41 riastradh Exp $); #include sys/types.h #include sys/kmem.h @@ -194,16 +194,12 @@ kmap(struct page *page) KASSERT(collision == lke); mutex_spin_exit(linux_kmap_lock); - const int s = splvm(); - KASSERT(!pmap_extract(pmap_kernel(), vaddr, NULL)); const int prot = (VM_PROT_READ | VM_PROT_WRITE); const int flags = 0; pmap_kenter_pa(vaddr, paddr, prot, flags); pmap_update(pmap_kernel()); - splx(s); - return (void *)vaddr; } @@ -222,12 +218,8 @@ kunmap(struct page *page) const vaddr_t vaddr = lke-lke_vaddr; kmem_free(lke, sizeof(*lke)); - const int s = splvm(); - KASSERT(pmap_extract(pmap_kernel(), vaddr, NULL)); pmap_kremove(vaddr, PAGE_SIZE); pmap_update(pmap_kernel()); - - splx(s); }
CVS commit: src/sys/external/bsd/drm2/linux
Module Name:src Committed By: riastradh Date: Fri Mar 28 23:22:27 UTC 2014 Modified Files: src/sys/external/bsd/drm2/linux: linux_kmap.c Log Message: Don't leak KVA by forgetting to call uvm_km_free...oops! From rmind@. To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/sys/external/bsd/drm2/linux/linux_kmap.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/external/bsd/drm2/linux/linux_kmap.c diff -u src/sys/external/bsd/drm2/linux/linux_kmap.c:1.3 src/sys/external/bsd/drm2/linux/linux_kmap.c:1.4 --- src/sys/external/bsd/drm2/linux/linux_kmap.c:1.3 Fri Mar 28 23:19:41 2014 +++ src/sys/external/bsd/drm2/linux/linux_kmap.c Fri Mar 28 23:22:27 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: linux_kmap.c,v 1.3 2014/03/28 23:19:41 riastradh Exp $ */ +/* $NetBSD: linux_kmap.c,v 1.4 2014/03/28 23:22:27 riastradh Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: linux_kmap.c,v 1.3 2014/03/28 23:19:41 riastradh Exp $); +__KERNEL_RCSID(0, $NetBSD: linux_kmap.c,v 1.4 2014/03/28 23:22:27 riastradh Exp $); #include sys/types.h #include sys/kmem.h @@ -222,4 +222,6 @@ kunmap(struct page *page) pmap_kremove(vaddr, PAGE_SIZE); pmap_update(pmap_kernel()); + + uvm_km_free(kernel_map, vaddr, PAGE_SIZE, UVM_KMF_VAONLY); }
CVS commit: src/sys/dev/usb
Module Name:src Committed By: zafer Date: Sat Mar 29 00:59:05 UTC 2014 Modified Files: src/sys/dev/usb: if_rum.c Log Message: Fix an issue with 11g beacon frames. From FreeBSD Rev. 226465 Makes 11g wep, wpa2 and hostap work again. To generate a diff of this commit: cvs rdiff -u -r1.47 -r1.48 src/sys/dev/usb/if_rum.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/usb/if_rum.c diff -u src/sys/dev/usb/if_rum.c:1.47 src/sys/dev/usb/if_rum.c:1.48 --- src/sys/dev/usb/if_rum.c:1.47 Tue Jan 22 12:40:42 2013 +++ src/sys/dev/usb/if_rum.c Sat Mar 29 00:59:05 2014 @@ -1,5 +1,5 @@ /* $OpenBSD: if_rum.c,v 1.40 2006/09/18 16:20:20 damien Exp $ */ -/* $NetBSD: if_rum.c,v 1.47 2013/01/22 12:40:42 jmcneill Exp $ */ +/* $NetBSD: if_rum.c,v 1.48 2014/03/29 00:59:05 zafer Exp $ */ /*- * Copyright (c) 2005-2007 Damien Bergamini damien.bergam...@free.fr @@ -24,7 +24,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: if_rum.c,v 1.47 2013/01/22 12:40:42 jmcneill Exp $); +__KERNEL_RCSID(0, $NetBSD: if_rum.c,v 1.48 2014/03/29 00:59:05 zafer Exp $); #include sys/param.h #include sys/sockio.h @@ -1476,17 +1476,22 @@ rum_write_multi(struct rum_softc *sc, ui { usb_device_request_t req; usbd_status error; + int offset; req.bmRequestType = UT_WRITE_VENDOR_DEVICE; req.bRequest = RT2573_WRITE_MULTI_MAC; USETW(req.wValue, 0); - USETW(req.wIndex, reg); - USETW(req.wLength, len); - error = usbd_do_request(sc-sc_udev, req, buf); - if (error != 0) { - printf(%s: could not multi write MAC register: %s\n, - device_xname(sc-sc_dev), usbd_errstr(error)); + /* write at most 64 bytes at a time */ + for (offset = 0; offset len; offset += 64) { + USETW(req.wIndex, reg + offset); + USETW(req.wLength, MIN(len - offset, 64)); + + error = usbd_do_request(sc-sc_udev, req, (char *)buf + offset); + if (error != 0) { + printf(%s: could not multi write MAC register: %s\n, + device_xname(sc-sc_dev), usbd_errstr(error)); + } } }
CVS commit: src/sys/arch/atari/stand/installboot
Module Name:src Committed By: ozaki-r Date: Sat Mar 29 05:03:43 UTC 2014 Modified Files: src/sys/arch/atari/stand/installboot: installboot.c Log Message: Fix typos To generate a diff of this commit: cvs rdiff -u -r1.26 -r1.27 src/sys/arch/atari/stand/installboot/installboot.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/atari/stand/installboot/installboot.c diff -u src/sys/arch/atari/stand/installboot/installboot.c:1.26 src/sys/arch/atari/stand/installboot/installboot.c:1.27 --- src/sys/arch/atari/stand/installboot/installboot.c:1.26 Wed Mar 26 18:04:33 2014 +++ src/sys/arch/atari/stand/installboot/installboot.c Sat Mar 29 05:03:43 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: installboot.c,v 1.26 2014/03/26 18:04:33 christos Exp $ */ +/* $NetBSD: installboot.c,v 1.27 2014/03/29 05:03:43 ozaki-r Exp $ */ /* * Copyright (c) 1995 Waldi Ravens @@ -228,7 +228,7 @@ install_fd(char *devnm, struct disklabel machpath = milanpath; else machpath = stdpath; - size_t xxboolen = strlen(mdecpath) + strlen(machpath) + 8); + size_t xxboolen = strlen(mdecpath) + strlen(machpath) + 8; xxboot = alloca(xxbootlen); snprintf(xxboot, xxbootlen, %s%sfdboot, mdecpath, machpath); bootxx = alloca(xxbootlen); @@ -369,7 +369,7 @@ install_wd(char *devnm, struct disklabel size_t xxb00tlen = strlen(mdecpath) + strlen(machpath) + 14; xxb00t = alloca(xxb00tlen); snprintf(xxb00t, xxb00tlen, %s%swdb00t.ahdi, mdecpath, machpath); - xnxboot = alloca(xxb00tlen); + xxboot = alloca(xxb00tlen); snprintf(xxboot, xxb00tlen, %s%sxxboot.ahdi, mdecpath, machpath); magic = AHDIMAGIC; } else {
CVS commit: src/sys/arch/news68k/stand/bootxx
Module Name:src Committed By: ozaki-r Date: Sat Mar 29 05:07:25 UTC 2014 Modified Files: src/sys/arch/news68k/stand/bootxx: bootxx.c Log Message: Replace sprintf with snprintf To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/sys/arch/news68k/stand/bootxx/bootxx.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/news68k/stand/bootxx/bootxx.c diff -u src/sys/arch/news68k/stand/bootxx/bootxx.c:1.10 src/sys/arch/news68k/stand/bootxx/bootxx.c:1.11 --- src/sys/arch/news68k/stand/bootxx/bootxx.c:1.10 Wed May 14 13:29:28 2008 +++ src/sys/arch/news68k/stand/bootxx/bootxx.c Sat Mar 29 05:07:25 2014 @@ -1,4 +1,4 @@ -/* $NetBSD: bootxx.c,v 1.10 2008/05/14 13:29:28 tsutsui Exp $ */ +/* $NetBSD: bootxx.c,v 1.11 2014/03/29 05:07:25 ozaki-r Exp $ */ /*- * Copyright (c) 1999 Izumi Tsutsui. All rights reserved. @@ -113,7 +113,8 @@ bootxx(uint32_t d4, uint32_t d5, uint32_ return; } - sprintf(devname, %s(%d,%d,%d), devs[type], ctlr, unit, part); + snprintf(devname, sizeof(devname), %s(%d,%d,%d), + devs[type], ctlr, unit, part); fd = rom_open(devname, 0); if (fd == -1) {
CVS commit: src/external/apache2/mDNSResponder/dist/mDNSShared
Module Name:src Committed By: pettai Date: Fri Mar 28 07:01:49 UTC 2014 Modified Files: src/external/apache2/mDNSResponder/dist/mDNSShared: dnssd_clientstub.c uds_daemon.c Log Message: Fix lost merges To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 \ src/external/apache2/mDNSResponder/dist/mDNSShared/dnssd_clientstub.c cvs rdiff -u -r1.6 -r1.7 \ src/external/apache2/mDNSResponder/dist/mDNSShared/uds_daemon.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: apb Date: Fri Mar 28 08:15:48 UTC 2014 Modified Files: src/doc: 3RDPARTY Log Message: Add placeholder for osnet. To generate a diff of this commit: cvs rdiff -u -r1.1101 -r1.1102 src/doc/3RDPARTY 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: hsuenaga Date: Fri Mar 28 08:24:06 UTC 2014 Modified Files: src/distrib/notes/common: main Log Message: Added myself, hsuenaga To generate a diff of this commit: cvs rdiff -u -r1.508 -r1.509 src/distrib/notes/common/main Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/share/misc
Module Name:src Committed By: apb Date: Fri Mar 28 10:16:28 UTC 2014 Modified Files: src/share/misc: airport Log Message: +ICN:Incheon, South Korea Also fix spelling of Incheon in the entry for JCN To generate a diff of this commit: cvs rdiff -u -r1.51 -r1.52 src/share/misc/airport Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/news68k/stand/boot
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 11:49:40 UTC 2014 Modified Files: src/sys/arch/news68k/stand/boot: boot.c Log Message: Use snprintf instead of sprintf To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/arch/news68k/stand/boot/boot.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/kern
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 11:55:09 UTC 2014 Modified Files: src/sys/kern: tty_pty.c Log Message: Fix unused variable 'mp' To generate a diff of this commit: cvs rdiff -u -r1.136 -r1.137 src/sys/kern/tty_pty.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/vax/vsa
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 13:26:24 UTC 2014 Modified Files: src/sys/arch/vax/vsa: spx.c Log Message: Use snprintf instead of sprintf To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/vsa/spx.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/sgimips/stand/sgivol
Module Name:src Committed By: christos Date: Fri Mar 28 15:00:53 UTC 2014 Modified Files: src/sys/arch/sgimips/stand/sgivol: sgivol.c Log Message: use err To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/sys/arch/sgimips/stand/sgivol/sgivol.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/games/hunt/huntd
Module Name:src Committed By: apb Date: Fri Mar 28 17:49:11 UTC 2014 Modified Files: src/games/hunt/huntd: get_names.c Log Message: If you are going to use memcpy instead of struct assignment, then at least use sizeof(the correct variable). The use of memcmp to test two pointers for equality, one line earlier, is also weird but may be correct. To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/games/hunt/huntd/get_names.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/games/sail
Module Name:src Committed By: apb Date: Fri Mar 28 17:53:47 UTC 2014 Modified Files: src/games/sail: dr_2.c Log Message: temp is a pointer, and tempmax, not sizeof(temp), is the length of the buffer that it points to. Adjust a strlcat() call to suit. To generate a diff of this commit: cvs rdiff -u -r1.25 -r1.26 src/games/sail/dr_2.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/atari/stand/ahdilabel
Module Name:src Committed By: ozaki-r Date: Fri Mar 28 13:35:13 UTC 2014 Modified Files: src/sys/arch/atari/stand/ahdilabel: ahdilabel.c Log Message: Fix; cts[0] = cts To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/atari/stand/ahdilabel/ahdilabel.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/include
Module Name:src Committed By: matt Date: Fri Mar 28 21:40:53 UTC 2014 Modified Files: src/sys/arch/arm/include: mutex.h rwlock.h Log Message: Use dmb/dsb To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/include/mutex.h cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/include/rwlock.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/cortex
Module Name:src Committed By: matt Date: Fri Mar 28 21:41:46 UTC 2014 Modified Files: src/sys/arch/arm/cortex: gtmr.c gtmr_var.h Log Message: Add gtmr_bootdelay. rename clockhandler to gtmr_intr To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/cortex/gtmr.c cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/cortex/gtmr_var.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/mainbus
Module Name:src Committed By: matt Date: Fri Mar 28 21:43:01 UTC 2014 Modified Files: src/sys/arch/arm/mainbus: cpu_mainbus.c Log Message: arm_cpu_max = num of cpus To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/mainbus/cpu_mainbus.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/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:43:49 UTC 2014 Modified Files: src/sys/arch/arm/arm: ast.c Log Message: Make sure the pmap is activated before returning to userland. To generate a diff of this commit: cvs rdiff -u -r1.22 -r1.23 src/sys/arch/arm/arm/ast.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/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:44:35 UTC 2014 Modified Files: src/sys/arch/arm/arm: undefined.c Log Message: Move undefined evcnt's to cpu_info. To generate a diff of this commit: cvs rdiff -u -r1.53 -r1.54 src/sys/arch/arm/arm/undefined.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/include
Module Name:src Committed By: matt Date: Fri Mar 28 21:44:59 UTC 2014 Modified Files: src/sys/arch/arm/include: cpu.h Log Message: Make ddb_regs, undefined vfp evcnt's per cpu. To generate a diff of this commit: cvs rdiff -u -r1.82 -r1.83 src/sys/arch/arm/include/cpu.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/include
Module Name:src Committed By: matt Date: Fri Mar 28 21:47:48 UTC 2014 Modified Files: src/sys/arch/arm/include: cpufunc.h Log Message: Use cpsie/cpsid if possible. change cache_type to uint8_t more ARM_MMU_EXTENDED support (ASID) To generate a diff of this commit: cvs rdiff -u -r1.68 -r1.69 src/sys/arch/arm/include/cpufunc.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/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:49:22 UTC 2014 Modified Files: src/sys/arch/arm/arm: cpufunc.c Log Message: Initialize cache way_size and sets To generate a diff of this commit: cvs rdiff -u -r1.140 -r1.141 src/sys/arch/arm/arm/cpufunc.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/arm
Module Name:src Committed By: matt Date: Fri Mar 28 21:50:40 UTC 2014 Modified Files: src/sys/arch/arm/arm: cpufunc_asm_armv7.S Log Message: Add ARM_MMU_EXTENDED support To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/arm/cpufunc_asm_armv7.S 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/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:51:21 UTC 2014 Added Files: src/sys/arch/arm/arm32: arm32_tlb.c Log Message: Add tlb routines for pmap_tlb.c To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/arm32/arm32_tlb.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/include/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:51:59 UTC 2014 Modified Files: src/sys/arch/arm/include/arm32: machdep.h Log Message: Change arm_cpu_mbox to volatile To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/sys/arch/arm/include/arm32/machdep.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/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:52:53 UTC 2014 Modified Files: src/sys/arch/arm/arm32: cpuswitch.S Log Message: ARM_MMU_EXTENDED support. To generate a diff of this commit: cvs rdiff -u -r1.82 -r1.83 src/sys/arch/arm/arm32/cpuswitch.S 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/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:56:02 UTC 2014 Modified Files: src/sys/arch/arm/arm32: genassym.cf Log Message: Add ARM_MMU_EXTENDED support. To generate a diff of this commit: cvs rdiff -u -r1.67 -r1.68 src/sys/arch/arm/arm32/genassym.cf 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/arm32
Module Name:src Committed By: matt Date: Fri Mar 28 21:56:45 UTC 2014 Modified Files: src/sys/arch/arm/arm32: arm32_kvminit.c Log Message: ARM_MMU_EXTENDED support. To generate a diff of this commit: cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/arm32/arm32_kvminit.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/cortex
Module Name:src Committed By: matt Date: Fri Mar 28 21:57:22 UTC 2014 Modified Files: src/sys/arch/arm/cortex: a9tmr.c Log Message: Mark interrupt as MPSAFE. To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/cortex/a9tmr.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/external/bsd/drm2/linux
Module Name:src Committed By: riastradh Date: Fri Mar 28 23:19:41 UTC 2014 Modified Files: src/sys/external/bsd/drm2/linux: linux_kmap.c Log Message: Remove needless splvm/splx calls. From rmind@, who explained that the pmap(9) man page is wrong. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/external/bsd/drm2/linux/linux_kmap.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/external/bsd/drm2/linux
Module Name:src Committed By: riastradh Date: Fri Mar 28 23:22:27 UTC 2014 Modified Files: src/sys/external/bsd/drm2/linux: linux_kmap.c Log Message: Don't leak KVA by forgetting to call uvm_km_free...oops! From rmind@. To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/sys/external/bsd/drm2/linux/linux_kmap.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/atari/stand/installboot
Module Name:src Committed By: ozaki-r Date: Sat Mar 29 05:03:43 UTC 2014 Modified Files: src/sys/arch/atari/stand/installboot: installboot.c Log Message: Fix typos To generate a diff of this commit: cvs rdiff -u -r1.26 -r1.27 src/sys/arch/atari/stand/installboot/installboot.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.