svn commit: r250922 - in user/attilio/vmcontention: include include/arpa include/protocols lib/libc/gen lib/libc/net sbin/hastd share/i18n/csmapper share/i18n/esdb share/man/man5 share/man/man9 sys...
Attilio Rao
attilio at FreeBSD.org
Thu May 23 00:49:58 UTC 2013
Author: attilio
Date: Thu May 23 00:49:52 2013
New Revision: 250922
URL: http://svnweb.freebsd.org/changeset/base/250922
Log:
MFC
Modified:
user/attilio/vmcontention/include/arpa/tftp.h
user/attilio/vmcontention/include/fts.h
user/attilio/vmcontention/include/ifaddrs.h
user/attilio/vmcontention/include/protocols/rwhod.h
user/attilio/vmcontention/lib/libc/gen/fts.3
user/attilio/vmcontention/lib/libc/net/getifaddrs.3
user/attilio/vmcontention/lib/libc/net/getifmaddrs.3
user/attilio/vmcontention/sbin/hastd/hast.h
user/attilio/vmcontention/sbin/hastd/parse.y
user/attilio/vmcontention/sbin/hastd/token.l
user/attilio/vmcontention/share/i18n/csmapper/Makefile
user/attilio/vmcontention/share/i18n/esdb/Makefile
user/attilio/vmcontention/share/man/man5/src.conf.5
user/attilio/vmcontention/share/man/man9/locking.9
user/attilio/vmcontention/sys/dev/mps/mps_user.c
user/attilio/vmcontention/sys/dev/xen/netfront/netfront.c
user/attilio/vmcontention/sys/kern/kern_poll.c
user/attilio/vmcontention/sys/kern/uipc_usrreq.c
user/attilio/vmcontention/sys/net/ppp_defs.h
user/attilio/vmcontention/sys/sys/timex.h
user/attilio/vmcontention/sys/ufs/ffs/ffs_softdep.c
user/attilio/vmcontention/sys/vm/vm_fault.c
user/attilio/vmcontention/sys/xen/xenbus/xenbusb.c
user/attilio/vmcontention/tools/tools/ath/athalq/main.c
user/attilio/vmcontention/usr.sbin/mergemaster/mergemaster.sh
Directory Properties:
user/attilio/vmcontention/ (props changed)
user/attilio/vmcontention/lib/libc/ (props changed)
user/attilio/vmcontention/sbin/ (props changed)
user/attilio/vmcontention/sys/ (props changed)
Modified: user/attilio/vmcontention/include/arpa/tftp.h
==============================================================================
--- user/attilio/vmcontention/include/arpa/tftp.h Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/include/arpa/tftp.h Thu May 23 00:49:52 2013 (r250922)
@@ -33,6 +33,8 @@
#ifndef _ARPA_TFTP_H_
#define _ARPA_TFTP_H_
+#include <sys/cdefs.h>
+
/*
* Trivial File Transfer Protocol (IEN-133)
*/
Modified: user/attilio/vmcontention/include/fts.h
==============================================================================
--- user/attilio/vmcontention/include/fts.h Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/include/fts.h Thu May 23 00:49:52 2013 (r250922)
@@ -33,15 +33,17 @@
#ifndef _FTS_H_
#define _FTS_H_
+#include <sys/_types.h>
+
typedef struct {
struct _ftsent *fts_cur; /* current node */
struct _ftsent *fts_child; /* linked list of children */
struct _ftsent **fts_array; /* sort array */
- dev_t fts_dev; /* starting device # */
+ __dev_t fts_dev; /* starting device # */
char *fts_path; /* path for this descent */
int fts_rfd; /* fd for root */
- size_t fts_pathlen; /* sizeof(path) */
- size_t fts_nitems; /* elements in the sort array */
+ __size_t fts_pathlen; /* sizeof(path) */
+ __size_t fts_nitems; /* elements in the sort array */
int (*fts_compar) /* compare function */
(const struct _ftsent * const *, const struct _ftsent * const *);
@@ -72,12 +74,12 @@ typedef struct _ftsent {
char *fts_path; /* root path */
int fts_errno; /* errno for this node */
int fts_symfd; /* fd for symlink */
- size_t fts_pathlen; /* strlen(fts_path) */
- size_t fts_namelen; /* strlen(fts_name) */
+ __size_t fts_pathlen; /* strlen(fts_path) */
+ __size_t fts_namelen; /* strlen(fts_name) */
- ino_t fts_ino; /* inode */
- dev_t fts_dev; /* device */
- nlink_t fts_nlink; /* link count */
+ __ino_t fts_ino; /* inode */
+ __dev_t fts_dev; /* device */
+ __nlink_t fts_nlink; /* link count */
#define FTS_ROOTPARENTLEVEL -1
#define FTS_ROOTLEVEL 0
Modified: user/attilio/vmcontention/include/ifaddrs.h
==============================================================================
--- user/attilio/vmcontention/include/ifaddrs.h Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/include/ifaddrs.h Thu May 23 00:49:52 2013 (r250922)
@@ -31,7 +31,7 @@
struct ifaddrs {
struct ifaddrs *ifa_next;
char *ifa_name;
- u_int ifa_flags;
+ unsigned int ifa_flags;
struct sockaddr *ifa_addr;
struct sockaddr *ifa_netmask;
struct sockaddr *ifa_dstaddr;
Modified: user/attilio/vmcontention/include/protocols/rwhod.h
==============================================================================
--- user/attilio/vmcontention/include/protocols/rwhod.h Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/include/protocols/rwhod.h Thu May 23 00:49:52 2013 (r250922)
@@ -34,13 +34,15 @@
#ifndef _PROTOCOLS_RWHOD_H_
#define _PROTOCOLS_RWHOD_H_
+#include <sys/_types.h>
+
/*
* rwho protocol packet format.
*/
struct outmp {
char out_line[8]; /* tty name */
char out_name[8]; /* user id */
- int32_t out_time; /* time on */
+ __int32_t out_time; /* time on */
};
struct whod {
Modified: user/attilio/vmcontention/lib/libc/gen/fts.3
==============================================================================
--- user/attilio/vmcontention/lib/libc/gen/fts.3 Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/lib/libc/gen/fts.3 Thu May 23 00:49:52 2013 (r250922)
@@ -28,7 +28,7 @@
.\" @(#)fts.3 8.5 (Berkeley) 4/16/94
.\" $FreeBSD$
.\"
-.Dd March 18, 2012
+.Dd May 21, 2013
.Dt FTS 3
.Os
.Sh NAME
@@ -37,8 +37,6 @@
.Sh LIBRARY
.Lb libc
.Sh SYNOPSIS
-.In sys/types.h
-.In sys/stat.h
.In fts.h
.Ft FTS *
.Fn fts_open "char * const *path_argv" "int options" "int (*compar)(const FTSENT * const *, const FTSENT * const *)"
Modified: user/attilio/vmcontention/lib/libc/net/getifaddrs.3
==============================================================================
--- user/attilio/vmcontention/lib/libc/net/getifaddrs.3 Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/lib/libc/net/getifaddrs.3 Thu May 23 00:49:52 2013 (r250922)
@@ -24,15 +24,13 @@
.\"
.\" $FreeBSD$
.\"
-.Dd October 12, 1995
+.Dd May 21, 2013
.Dt GETIFADDRS 3
.Os
.Sh NAME
.Nm getifaddrs
.Nd get interface addresses
.Sh SYNOPSIS
-.In sys/types.h
-.In sys/socket.h
.In ifaddrs.h
.Ft int
.Fn getifaddrs "struct ifaddrs **ifap"
Modified: user/attilio/vmcontention/lib/libc/net/getifmaddrs.3
==============================================================================
--- user/attilio/vmcontention/lib/libc/net/getifmaddrs.3 Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/lib/libc/net/getifmaddrs.3 Thu May 23 00:49:52 2013 (r250922)
@@ -20,15 +20,13 @@
.\"
.\" $FreeBSD$
.\"
-.Dd November 14, 2003
+.Dd May 21, 2013
.Dt GETIFMADDRS 3
.Os
.Sh NAME
.Nm getifmaddrs
.Nd get multicast group memberships
.Sh SYNOPSIS
-.In sys/types.h
-.In sys/socket.h
.In ifaddrs.h
.Ft int
.Fn getifmaddrs "struct ifmaddrs **ifmap"
Modified: user/attilio/vmcontention/sbin/hastd/hast.h
==============================================================================
--- user/attilio/vmcontention/sbin/hastd/hast.h Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sbin/hastd/hast.h Thu May 23 00:49:52 2013 (r250922)
@@ -259,7 +259,4 @@ struct hast_resource {
struct hastd_config *yy_config_parse(const char *config, bool exitonerror);
void yy_config_free(struct hastd_config *config);
-void yyerror(const char *);
-int yylex(void);
-
#endif /* !_HAST_H_ */
Modified: user/attilio/vmcontention/sbin/hastd/parse.y
==============================================================================
--- user/attilio/vmcontention/sbin/hastd/parse.y Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sbin/hastd/parse.y Thu May 23 00:49:52 2013 (r250922)
@@ -75,6 +75,8 @@ static char depth1_provname[PATH_MAX];
static char depth1_localpath[PATH_MAX];
static int depth1_metaflush;
+extern void yyerror(const char *);
+extern int yylex(void);
extern void yyrestart(FILE *);
static int isitme(const char *name);
Modified: user/attilio/vmcontention/sbin/hastd/token.l
==============================================================================
--- user/attilio/vmcontention/sbin/hastd/token.l Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sbin/hastd/token.l Thu May 23 00:49:52 2013 (r250922)
@@ -42,6 +42,9 @@ int depth;
int lineno;
#define DP do { } while (0)
+#define YY_DECL int yylex(void)
+
+extern int yylex(void);
%}
%option noinput
Modified: user/attilio/vmcontention/share/i18n/csmapper/Makefile
==============================================================================
--- user/attilio/vmcontention/share/i18n/csmapper/Makefile Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/share/i18n/csmapper/Makefile Thu May 23 00:49:52 2013 (r250922)
@@ -7,7 +7,7 @@ SUBDIR= APPLE AST BIG5 CNS CP EBCDIC GB
KAZAKH KOI KS MISC TCVN
mapper.dir: ${SUBDIR}
- touch ${.TARGET}
+ > ${.TARGET}
.for i in ${SUBDIR}
cat ${i}/mapper.dir.${i} >> ${.TARGET}
.endfor
@@ -18,7 +18,7 @@ FILES+= mapper.dir mapper.dir.db
CLEANFILES+= mapper.dir mapper.dir.db
charset.pivot: ${SUBDIR}
- touch ${.TARGET}
+ > ${.TARGET}
.for i in ${SUBDIR}
cat ${i}/charset.pivot.${i} >> ${.TARGET}
.endfor
Modified: user/attilio/vmcontention/share/i18n/esdb/Makefile
==============================================================================
--- user/attilio/vmcontention/share/i18n/esdb/Makefile Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/share/i18n/esdb/Makefile Thu May 23 00:49:52 2013 (r250922)
@@ -10,7 +10,7 @@ FILES+= esdb.dir esdb.dir.db esdb.alias
CLEANFILES= ${FILES}
esdb.dir: ${SUBDIR}
- touch $@
+ > $@
.for i in ${SUBDIR}
cat ${i}/esdb.dir.${i} >>${.TARGET}
.endfor
@@ -18,7 +18,7 @@ esdb.dir.db: esdb.dir
${MKESDB} -m -o ${.TARGET} ${.ALLSRC}
esdb.alias: ${SUBDIR}
- touch $@
+ > $@
.for i in ${SUBDIR}
cat ${i}/esdb.alias.${i} >>${.TARGET}
.endfor
Modified: user/attilio/vmcontention/share/man/man5/src.conf.5
==============================================================================
--- user/attilio/vmcontention/share/man/man5/src.conf.5 Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/share/man/man5/src.conf.5 Thu May 23 00:49:52 2013 (r250922)
@@ -1,7 +1,7 @@
.\" DO NOT EDIT-- this file is automatically generated.
.\" from FreeBSD: head/tools/build/options/makeman 236279 2012-05-30 02:37:20Z gjb
.\" $FreeBSD$
-.Dd February 15, 2013
+.Dd May 21, 2013
.Dt SRC.CONF 5
.Os
.Sh NAME
@@ -223,9 +223,9 @@ toolchain is enabled.
.It Va WITHOUT_BLUETOOTH
.\" from FreeBSD: head/tools/build/options/WITHOUT_BLUETOOTH 156932 2006-03-21 07:50:50Z ru
Set to not build Bluetooth related kernel modules, programs and libraries.
-.It Va WITH_BMAKE
-.\" from FreeBSD: head/tools/build/options/WITH_BMAKE 241279 2012-10-06 19:19:21Z marcel
-Build and install the portable BSD make (bmake) as
+.It Va WITHOUT_BMAKE
+.\" from FreeBSD: head/tools/build/options/WITHOUT_BMAKE 250839 2013-05-21 00:41:49Z delphij
+Set to not build and install the portable BSD make (bmake) as
.Xr make 1
instead of the traditional FreeBSD make.
This build option is temporary.
@@ -302,6 +302,12 @@ When set, it also enforces the following
.It
.Va WITHOUT_CLANG_IS_CC
.El
+.It Va WITH_CLANG
+.\" from FreeBSD: head/tools/build/options/WITH_CLANG 221730 2011-05-10 11:14:40Z ru
+Set to build the Clang C/C++ compiler.
+.Pp
+It is a default setting on
+amd64/amd64, arm/arm, arm/armv6, i386/i386, pc98/i386, powerpc/powerpc and powerpc/powerpc64.
.It Va WITH_CLANG_EXTRAS
.\" from FreeBSD: head/tools/build/options/WITH_CLANG_EXTRAS 231057 2012-02-05 23:56:22Z dim
Set to build additional clang and llvm tools, such as bugpoint.
@@ -328,7 +334,7 @@ and
.Pa /usr/bin/cpp .
.Pp
It is a default setting on
-arm/arm, arm/armeb, arm/armv6, arm/armv6eb, ia64/ia64, mips/mipsel, mips/mips, mips/mips64el, mips/mips64, mips/mipsn32, powerpc/powerpc, powerpc/powerpc64 and sparc64/sparc64.
+arm/armeb, arm/armv6eb, ia64/ia64, mips/mipsel, mips/mips, mips/mips64el, mips/mips64, mips/mipsn32, powerpc/powerpc, powerpc/powerpc64 and sparc64/sparc64.
.It Va WITH_CLANG_IS_CC
.\" from FreeBSD: head/tools/build/options/WITH_CLANG_IS_CC 235342 2012-05-12 16:12:36Z gjb
Set to install the Clang C/C++ compiler as
@@ -338,7 +344,7 @@ and
.Pa /usr/bin/cpp .
.Pp
It is a default setting on
-amd64/amd64, i386/i386 and pc98/i386.
+amd64/amd64, arm/arm, arm/armv6, i386/i386 and pc98/i386.
.It Va WITHOUT_CPP
.\" from FreeBSD: head/tools/build/options/WITHOUT_CPP 156932 2006-03-21 07:50:50Z ru
Set to not build
@@ -433,6 +439,13 @@ This includes the device tree compiler (
.Pp
It is a default setting on
amd64/amd64, i386/i386, ia64/ia64, pc98/i386 and sparc64/sparc64.
+.It Va WITH_FDT
+.\" from FreeBSD: head/tools/build/options/WITH_FDT 221730 2011-05-10 11:14:40Z ru
+Set to build Flattened Device Tree support as part of the base system.
+This includes the device tree compiler (dtc) and libfdt support library.
+.Pp
+It is a default setting on
+arm/arm, arm/armeb, arm/armv6, arm/armv6eb, mips/mipsel, mips/mips, mips/mips64el, mips/mips64, mips/mipsn32, powerpc/powerpc and powerpc/powerpc64.
.It Va WITHOUT_FLOPPY
.\" from FreeBSD: head/tools/build/options/WITHOUT_FLOPPY 221540 2011-05-06 19:13:03Z ru
Set to not build or install programs
@@ -523,13 +536,6 @@ Set to not build HTML docs.
.It Va WITH_ICONV
.\" from FreeBSD: head/tools/build/options/WITH_ICONV 219020 2011-02-25 00:10:26Z gabor
Set to build iconv as part of libc.
-.It Va WITH_IDEA
-.\" from FreeBSD: head/tools/build/options/WITH_IDEA 156932 2006-03-21 07:50:50Z ru
-Set to build the IDEA encryption code.
-This code is patented in the USA and many European countries.
-It is
-.Em "YOUR RESPONSIBILITY"
-to determine if you can legally use IDEA.
.It Va WITHOUT_INET
.\" from FreeBSD: head/tools/build/options/WITHOUT_INET 221266 2011-04-30 17:58:28Z bz
Set to not build programs and libraries related to IPv4 networking.
@@ -595,8 +601,8 @@ When set, it also enforces the following
.\" from FreeBSD: head/tools/build/options/WITHOUT_IPX_SUPPORT 156932 2006-03-21 07:50:50Z ru
Set to build some programs without IPX support.
.It Va WITHOUT_JAIL
-.\" from FreeBSD: head/tools/build/options/WITHOUT_JAIL 183242 2008-09-21 22:02:26Z sam
-Set to not build tools for the support of jails; e.g.
+.\" from FreeBSD: head/tools/build/options/WITHOUT_JAIL 249966 2013-04-27 04:09:09Z eadler
+Set to not build tools for the support of jails; e.g.,
.Xr jail 8 .
.It Va WITHOUT_KDUMP
.\" from FreeBSD: head/tools/build/options/WITHOUT_KDUMP 240690 2012-09-19 11:38:37Z zeising
@@ -677,8 +683,8 @@ When set, the following options are also
.It Va WITHOUT_BIND_UTILS
.El
.It Va WITHOUT_LEGACY_CONSOLE
-.\" from FreeBSD: head/tools/build/options/WITHOUT_LEGACY_CONSOLE 183242 2008-09-21 22:02:26Z sam
-Set to not build programs that support a legacy PC console; e.g.
+.\" from FreeBSD: head/tools/build/options/WITHOUT_LEGACY_CONSOLE 249966 2013-04-27 04:09:09Z eadler
+Set to not build programs that support a legacy PC console; e.g.,
.Xr kbdcontrol 8
and
.Xr vidcontrol 8 .
Modified: user/attilio/vmcontention/share/man/man9/locking.9
==============================================================================
--- user/attilio/vmcontention/share/man/man9/locking.9 Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/share/man/man9/locking.9 Thu May 23 00:49:52 2013 (r250922)
@@ -24,7 +24,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd May 25, 2012
+.Dd May 22, 2013
.Dt LOCKING 9
.Os
.Sh NAME
@@ -167,7 +167,7 @@ Giant is an instance of a mutex, with so
.It
It is recursive.
.It
-Drivers and filesystems can request that Giant be locked around them
+Drivers can request that Giant be locked around them
by not marking themselves MPSAFE.
Note that infrastructure to do this is slowly going away as non-MPSAFE
drivers either became properly locked or disappear.
Modified: user/attilio/vmcontention/sys/dev/mps/mps_user.c
==============================================================================
--- user/attilio/vmcontention/sys/dev/mps/mps_user.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/dev/mps/mps_user.c Thu May 23 00:49:52 2013 (r250922)
@@ -208,8 +208,8 @@ mps_detach_user(struct mps_softc *sc)
{
/* XXX: do a purge of pending requests? */
- destroy_dev(sc->mps_cdev);
-
+ if (sc->mps_cdev != NULL)
+ destroy_dev(sc->mps_cdev);
}
static int
Modified: user/attilio/vmcontention/sys/dev/xen/netfront/netfront.c
==============================================================================
--- user/attilio/vmcontention/sys/dev/xen/netfront/netfront.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/dev/xen/netfront/netfront.c Thu May 23 00:49:52 2013 (r250922)
@@ -2171,10 +2171,14 @@ netfront_detach(device_t dev)
static void
netif_free(struct netfront_info *info)
{
+ XN_LOCK(info);
+ xn_stop(info);
+ XN_UNLOCK(info);
+ callout_drain(&info->xn_stat_ch);
netif_disconnect_backend(info);
-#if 0
- close_netdev(info);
-#endif
+ ifmedia_removeall(&info->sc_media);
+ ether_ifdetach(info->xn_ifp);
+ if_free(info->xn_ifp);
}
static void
Modified: user/attilio/vmcontention/sys/kern/kern_poll.c
==============================================================================
--- user/attilio/vmcontention/sys/kern/kern_poll.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/kern/kern_poll.c Thu May 23 00:49:52 2013 (r250922)
@@ -87,12 +87,11 @@ static struct mtx poll_mtx;
* The following constraints hold
*
* 1 <= poll_each_burst <= poll_burst <= poll_burst_max
- * 0 <= poll_each_burst
* MIN_POLL_BURST_MAX <= poll_burst_max <= MAX_POLL_BURST_MAX
*/
#define MIN_POLL_BURST_MAX 10
-#define MAX_POLL_BURST_MAX 1000
+#define MAX_POLL_BURST_MAX 20000
static uint32_t poll_burst = 5;
static uint32_t poll_burst_max = 150; /* good for 100Mbit net and HZ=1000 */
Modified: user/attilio/vmcontention/sys/kern/uipc_usrreq.c
==============================================================================
--- user/attilio/vmcontention/sys/kern/uipc_usrreq.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/kern/uipc_usrreq.c Thu May 23 00:49:52 2013 (r250922)
@@ -1686,6 +1686,8 @@ unp_freerights(struct filedescent **fdep
struct file *fp;
int i;
+ if (fdcount == 0)
+ return;
for (i = 0; i < fdcount; i++) {
fp = fdep[i]->fde_file;
filecaps_free(&fdep[i]->fde_caps);
@@ -1768,7 +1770,8 @@ unp_externalize(struct mbuf *control, st
unp_externalize_fp(fde->fde_file);
}
FILEDESC_XUNLOCK(fdesc);
- free(fdep[0], M_FILECAPS);
+ if (newfds != 0)
+ free(fdep[0], M_FILECAPS);
} else {
/* We can just copy anything else across. */
if (error || controlp == NULL)
@@ -1925,6 +1928,10 @@ unp_internalize(struct mbuf **controlp,
error = E2BIG;
goto out;
}
+ if (oldfds == 0) {
+ FILEDESC_SUNLOCK(fdesc);
+ break;
+ }
fdp = data;
fdep = (struct filedescent **)
CMSG_DATA(mtod(*controlp, struct cmsghdr *));
Modified: user/attilio/vmcontention/sys/net/ppp_defs.h
==============================================================================
--- user/attilio/vmcontention/sys/net/ppp_defs.h Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/net/ppp_defs.h Thu May 23 00:49:52 2013 (r250922)
@@ -31,6 +31,8 @@
#ifndef _PPP_DEFS_H_
#define _PPP_DEFS_H_
+#include <sys/_types.h>
+
/*
* The basic PPP frame.
*/
@@ -83,7 +85,7 @@
/*
* Extended asyncmap - allows any character to be escaped.
*/
-typedef u_int32_t ext_accm[8];
+typedef __uint32_t ext_accm[8];
/*
* What to do with network protocol (NP) packets.
@@ -143,8 +145,8 @@ struct ppp_comp_stats {
* the last NP packet was sent or received.
*/
struct ppp_idle {
- time_t xmit_idle; /* time since last NP packet sent */
- time_t recv_idle; /* time since last NP packet received */
+ __time_t xmit_idle; /* time since last NP packet sent */
+ __time_t recv_idle; /* time since last NP packet received */
};
#ifndef __P
Modified: user/attilio/vmcontention/sys/sys/timex.h
==============================================================================
--- user/attilio/vmcontention/sys/sys/timex.h Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/sys/timex.h Thu May 23 00:49:52 2013 (r250922)
@@ -97,6 +97,9 @@
#define _SYS_TIMEX_H_ 1
#define NTP_API 4 /* NTP API version */
+#ifdef __FreeBSD__
+#include <sys/_timespec.h>
+#endif /* __FreeBSD__ */
#ifndef MSDOS /* Microsoft specific */
#include <sys/syscall.h>
#endif /* MSDOS */
Modified: user/attilio/vmcontention/sys/ufs/ffs/ffs_softdep.c
==============================================================================
--- user/attilio/vmcontention/sys/ufs/ffs/ffs_softdep.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/ufs/ffs/ffs_softdep.c Thu May 23 00:49:52 2013 (r250922)
@@ -656,8 +656,8 @@ FEATURE(softupdates, "FFS soft-updates s
#define D_SBDEP 24
#define D_JTRUNC 25
#define D_JFSYNC 26
-#define D_SENTINAL 27
-#define D_LAST D_SENTINAL
+#define D_SENTINEL 27
+#define D_LAST D_SENTINEL
unsigned long dep_current[D_LAST + 1];
unsigned long dep_total[D_LAST + 1];
@@ -711,6 +711,8 @@ SOFTDEP_TYPE(SBDEP, sbdep, "Superblock w
SOFTDEP_TYPE(JTRUNC, jtrunc, "Journal inode truncation");
SOFTDEP_TYPE(JFSYNC, jfsync, "Journal fsync complete");
+static MALLOC_DEFINE(M_SENTINEL, "sentinel", "Worklist sentinel");
+
static MALLOC_DEFINE(M_SAVEDINO, "savedino", "Saved inodes");
static MALLOC_DEFINE(M_JBLOCKS, "jblocks", "Journal block locations");
@@ -745,7 +747,8 @@ static struct malloc_type *memtype[] = {
M_JSEGDEP,
M_SBDEP,
M_JTRUNC,
- M_JFSYNC
+ M_JFSYNC,
+ M_SENTINEL
};
static LIST_HEAD(mkdirlist, mkdir) mkdirlisthd;
@@ -1718,7 +1721,7 @@ process_worklist_item(mp, target, flags)
int target;
int flags;
{
- struct worklist sintenel;
+ struct worklist sentinel;
struct worklist *wk;
struct ufsmount *ump;
int matchcnt;
@@ -1736,14 +1739,14 @@ process_worklist_item(mp, target, flags)
PHOLD(curproc); /* Don't let the stack go away. */
ump = VFSTOUFS(mp);
matchcnt = 0;
- sintenel.wk_mp = NULL;
- sintenel.wk_type = D_SENTINAL;
- LIST_INSERT_HEAD(&ump->softdep_workitem_pending, &sintenel, wk_list);
- for (wk = LIST_NEXT(&sintenel, wk_list); wk != NULL;
- wk = LIST_NEXT(&sintenel, wk_list)) {
- if (wk->wk_type == D_SENTINAL) {
- LIST_REMOVE(&sintenel, wk_list);
- LIST_INSERT_AFTER(wk, &sintenel, wk_list);
+ sentinel.wk_mp = NULL;
+ sentinel.wk_type = D_SENTINEL;
+ LIST_INSERT_HEAD(&ump->softdep_workitem_pending, &sentinel, wk_list);
+ for (wk = LIST_NEXT(&sentinel, wk_list); wk != NULL;
+ wk = LIST_NEXT(&sentinel, wk_list)) {
+ if (wk->wk_type == D_SENTINEL) {
+ LIST_REMOVE(&sentinel, wk_list);
+ LIST_INSERT_AFTER(wk, &sentinel, wk_list);
continue;
}
if (wk->wk_state & INPROGRESS)
@@ -1800,11 +1803,11 @@ process_worklist_item(mp, target, flags)
wake_worklist(wk);
add_to_worklist(wk, WK_HEAD);
}
- LIST_REMOVE(&sintenel, wk_list);
+ LIST_REMOVE(&sentinel, wk_list);
/* Sentinal could've become the tail from remove_from_worklist. */
- if (ump->softdep_worklist_tail == &sintenel)
+ if (ump->softdep_worklist_tail == &sentinel)
ump->softdep_worklist_tail =
- (struct worklist *)sintenel.wk_list.le_prev;
+ (struct worklist *)sentinel.wk_list.le_prev;
PRELE(curproc);
return (matchcnt);
}
@@ -4984,13 +4987,14 @@ bmsafemap_lookup(mp, bp, cg, newbmsafema
struct fs *fs;
mtx_assert(&lk, MA_OWNED);
- if (bp)
- LIST_FOREACH(wk, &bp->b_dep, wk_list)
- if (wk->wk_type == D_BMSAFEMAP) {
- if (newbmsafemap)
- WORKITEM_FREE(newbmsafemap,D_BMSAFEMAP);
- return (WK_BMSAFEMAP(wk));
- }
+ KASSERT(bp != NULL, ("bmsafemap_lookup: missing buffer"));
+ LIST_FOREACH(wk, &bp->b_dep, wk_list) {
+ if (wk->wk_type == D_BMSAFEMAP) {
+ if (newbmsafemap)
+ WORKITEM_FREE(newbmsafemap, D_BMSAFEMAP);
+ return (WK_BMSAFEMAP(wk));
+ }
+ }
fs = VFSTOUFS(mp)->um_fs;
bmsafemaphd = BMSAFEMAP_HASH(fs, cg);
if (bmsafemap_find(bmsafemaphd, mp, cg, &bmsafemap) == 1) {
@@ -8149,6 +8153,7 @@ setup_newdir(dap, newinum, dinum, newdir
(inodedep->id_state & ALLCOMPLETE) == ALLCOMPLETE) {
dap->da_state &= ~MKDIR_PARENT;
WORKITEM_FREE(mkdir2, D_MKDIR);
+ mkdir2 = NULL;
} else {
LIST_INSERT_HEAD(&mkdirlisthd, mkdir2, md_mkdirs);
WORKLIST_INSERT(&inodedep->id_bufwait, &mkdir2->md_list);
@@ -9357,13 +9362,16 @@ clear_unlinked_inodedep(inodedep)
if (idp && (idp->id_state & UNLINKNEXT))
pino = idp->id_ino;
FREE_LOCK(&lk);
- if (pino == 0)
+ if (pino == 0) {
bp = getblk(ump->um_devvp, btodb(fs->fs_sblockloc),
(int)fs->fs_sbsize, 0, 0, 0);
- else
+ } else {
error = bread(ump->um_devvp,
fsbtodb(fs, ino_to_fsba(fs, pino)),
(int)fs->fs_bsize, NOCRED, &bp);
+ if (error)
+ brelse(bp);
+ }
ACQUIRE_LOCK(&lk);
if (error)
break;
@@ -12127,7 +12135,7 @@ restart:
/*
* Sync all cylinder groups that were dirty at the time this function is
- * called. Newly dirtied cgs will be inserted before the sintenel. This
+ * called. Newly dirtied cgs will be inserted before the sentinel. This
* is used to flush freedep activity that may be holding up writes to a
* indirect block.
*/
@@ -12137,25 +12145,25 @@ sync_cgs(mp, waitfor)
int waitfor;
{
struct bmsafemap *bmsafemap;
- struct bmsafemap *sintenel;
+ struct bmsafemap *sentinel;
struct ufsmount *ump;
struct buf *bp;
int error;
- sintenel = malloc(sizeof(*sintenel), M_BMSAFEMAP, M_ZERO | M_WAITOK);
- sintenel->sm_cg = -1;
+ sentinel = malloc(sizeof(*sentinel), M_BMSAFEMAP, M_ZERO | M_WAITOK);
+ sentinel->sm_cg = -1;
ump = VFSTOUFS(mp);
error = 0;
ACQUIRE_LOCK(&lk);
- LIST_INSERT_HEAD(&ump->softdep_dirtycg, sintenel, sm_next);
- for (bmsafemap = LIST_NEXT(sintenel, sm_next); bmsafemap != NULL;
- bmsafemap = LIST_NEXT(sintenel, sm_next)) {
- /* Skip sintenels and cgs with no work to release. */
+ LIST_INSERT_HEAD(&ump->softdep_dirtycg, sentinel, sm_next);
+ for (bmsafemap = LIST_NEXT(sentinel, sm_next); bmsafemap != NULL;
+ bmsafemap = LIST_NEXT(sentinel, sm_next)) {
+ /* Skip sentinels and cgs with no work to release. */
if (bmsafemap->sm_cg == -1 ||
(LIST_EMPTY(&bmsafemap->sm_freehd) &&
LIST_EMPTY(&bmsafemap->sm_freewr))) {
- LIST_REMOVE(sintenel, sm_next);
- LIST_INSERT_AFTER(bmsafemap, sintenel, sm_next);
+ LIST_REMOVE(sentinel, sm_next);
+ LIST_INSERT_AFTER(bmsafemap, sentinel, sm_next);
continue;
}
/*
@@ -12165,8 +12173,8 @@ sync_cgs(mp, waitfor)
bp = getdirtybuf(bmsafemap->sm_buf, &lk, waitfor);
if (bp == NULL && waitfor == MNT_WAIT)
continue;
- LIST_REMOVE(sintenel, sm_next);
- LIST_INSERT_AFTER(bmsafemap, sintenel, sm_next);
+ LIST_REMOVE(sentinel, sm_next);
+ LIST_INSERT_AFTER(bmsafemap, sentinel, sm_next);
if (bp == NULL)
continue;
FREE_LOCK(&lk);
@@ -12178,9 +12186,9 @@ sync_cgs(mp, waitfor)
if (error)
break;
}
- LIST_REMOVE(sintenel, sm_next);
+ LIST_REMOVE(sentinel, sm_next);
FREE_LOCK(&lk);
- free(sintenel, M_BMSAFEMAP);
+ free(sentinel, M_BMSAFEMAP);
return (error);
}
@@ -13178,6 +13186,7 @@ softdep_inode_append(ip, cred, wkhd)
error = bread(ip->i_devvp, fsbtodb(fs, ino_to_fsba(fs, ip->i_number)),
(int)fs->fs_bsize, cred, &bp);
if (error) {
+ bqrelse(bp);
softdep_freework(wkhd);
return;
}
Modified: user/attilio/vmcontention/sys/vm/vm_fault.c
==============================================================================
--- user/attilio/vmcontention/sys/vm/vm_fault.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/vm/vm_fault.c Thu May 23 00:49:52 2013 (r250922)
@@ -1318,7 +1318,7 @@ vm_fault_copy_entry(vm_map_t dst_map, vm
* (Because the source is wired down, the page will be in
* memory.)
*/
- VM_OBJECT_WLOCK(src_object);
+ VM_OBJECT_RLOCK(src_object);
object = src_object;
pindex = src_pindex + dst_pindex;
while ((src_m = vm_page_lookup(object, pindex)) == NULL &&
@@ -1327,15 +1327,15 @@ vm_fault_copy_entry(vm_map_t dst_map, vm
/*
* Allow fallback to backing objects if we are reading.
*/
- VM_OBJECT_WLOCK(backing_object);
+ VM_OBJECT_RLOCK(backing_object);
pindex += OFF_TO_IDX(object->backing_object_offset);
- VM_OBJECT_WUNLOCK(object);
+ VM_OBJECT_RUNLOCK(object);
object = backing_object;
}
if (src_m == NULL)
panic("vm_fault_copy_wired: page missing");
pmap_copy_page(src_m, dst_m);
- VM_OBJECT_WUNLOCK(object);
+ VM_OBJECT_RUNLOCK(object);
dst_m->valid = VM_PAGE_BITS_ALL;
dst_m->dirty = VM_PAGE_BITS_ALL;
VM_OBJECT_WUNLOCK(dst_object);
Modified: user/attilio/vmcontention/sys/xen/xenbus/xenbusb.c
==============================================================================
--- user/attilio/vmcontention/sys/xen/xenbus/xenbusb.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/sys/xen/xenbus/xenbusb.c Thu May 23 00:49:52 2013 (r250922)
@@ -404,6 +404,31 @@ xenbusb_device_sysctl_init(device_t dev)
}
/**
+ * \brief Decrement the number of XenBus child devices in the
+ * connecting state by one and release the xbs_attch_ch
+ * interrupt configuration hook if the connecting count
+ * drops to zero.
+ *
+ * \param xbs XenBus Bus device softc of the owner of the bus to enumerate.
+ */
+static void
+xenbusb_release_confighook(struct xenbusb_softc *xbs)
+{
+ mtx_lock(&xbs->xbs_lock);
+ KASSERT(xbs->xbs_connecting_children > 0,
+ ("Connecting device count error\n"));
+ xbs->xbs_connecting_children--;
+ if (xbs->xbs_connecting_children == 0
+ && (xbs->xbs_flags & XBS_ATTACH_CH_ACTIVE) != 0) {
+ xbs->xbs_flags &= ~XBS_ATTACH_CH_ACTIVE;
+ mtx_unlock(&xbs->xbs_lock);
+ config_intrhook_disestablish(&xbs->xbs_attach_ch);
+ } else {
+ mtx_unlock(&xbs->xbs_lock);
+ }
+}
+
+/**
* \brief Verify the existance of attached device instances and perform
* probe/attach processing for newly arrived devices.
*
@@ -417,7 +442,7 @@ xenbusb_probe_children(device_t dev)
{
device_t *kids;
struct xenbus_device_ivars *ivars;
- int i, count;
+ int i, count, error;
if (device_get_children(dev, &kids, &count) == 0) {
for (i = 0; i < count; i++) {
@@ -430,7 +455,30 @@ xenbusb_probe_children(device_t dev)
continue;
}
- if (device_probe_and_attach(kids[i])) {
+ error = device_probe_and_attach(kids[i]);
+ if (error == ENXIO) {
+ struct xenbusb_softc *xbs;
+
+ /*
+ * We don't have a PV driver for this device.
+ * However, an emulated device we do support
+ * may share this backend. Hide the node from
+ * XenBus until the next rescan, but leave it's
+ * state unchanged so we don't inadvertently
+ * prevent attachment of any emulated device.
+ */
+ xenbusb_delete_child(dev, kids[i]);
+
+ /*
+ * Since the XenStore state of this device
+ * still indicates a pending attach, manually
+ * release it's hold on the boot process.
+ */
+ xbs = device_get_softc(dev);
+ xenbusb_release_confighook(xbs);
+
+ continue;
+ } else if (error) {
/*
* Transition device to the closed state
* so the world knows that attachment will
@@ -579,31 +627,6 @@ xenbusb_nop_confighook_cb(void *arg __un
{
}
-/**
- * \brief Decrement the number of XenBus child devices in the
- * connecting state by one and release the xbs_attch_ch
- * interrupt configuration hook if the connecting count
- * drops to zero.
- *
- * \param xbs XenBus Bus device softc of the owner of the bus to enumerate.
- */
-static void
-xenbusb_release_confighook(struct xenbusb_softc *xbs)
-{
- mtx_lock(&xbs->xbs_lock);
- KASSERT(xbs->xbs_connecting_children > 0,
- ("Connecting device count error\n"));
- xbs->xbs_connecting_children--;
- if (xbs->xbs_connecting_children == 0
- && (xbs->xbs_flags & XBS_ATTACH_CH_ACTIVE) != 0) {
- xbs->xbs_flags &= ~XBS_ATTACH_CH_ACTIVE;
- mtx_unlock(&xbs->xbs_lock);
- config_intrhook_disestablish(&xbs->xbs_attach_ch);
- } else {
- mtx_unlock(&xbs->xbs_lock);
- }
-}
-
/*--------------------------- Public Functions -------------------------------*/
/*--------- API comments for these methods can be found in xenbusb.h ---------*/
void
Modified: user/attilio/vmcontention/tools/tools/ath/athalq/main.c
==============================================================================
--- user/attilio/vmcontention/tools/tools/ath/athalq/main.c Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/tools/tools/ath/athalq/main.c Thu May 23 00:49:52 2013 (r250922)
@@ -75,6 +75,36 @@ ath_alq_print_intr_status(struct if_ath_
be32toh(is.intr_status));
}
+static void
+ath_alq_print_beacon_miss(struct if_ath_alq_payload *a)
+{
+
+ printf("[%u.%06u] [%llu] BMISS\n",
+ (unsigned int) be32toh(a->hdr.tstamp_sec),
+ (unsigned int) be32toh(a->hdr.tstamp_usec),
+ (unsigned long long) be64toh(a->hdr.threadid));
+}
+
+static void
+ath_alq_print_beacon_stuck(struct if_ath_alq_payload *a)
+{
+
+ printf("[%u.%06u] [%llu] BSTUCK\n",
+ (unsigned int) be32toh(a->hdr.tstamp_sec),
+ (unsigned int) be32toh(a->hdr.tstamp_usec),
+ (unsigned long long) be64toh(a->hdr.threadid));
+}
+
+static void
+ath_alq_print_beacon_resume(struct if_ath_alq_payload *a)
+{
+
+ printf("[%u.%06u] [%llu] BRESUME\n",
+ (unsigned int) be32toh(a->hdr.tstamp_sec),
+ (unsigned int) be32toh(a->hdr.tstamp_usec),
+ (unsigned long long) be64toh(a->hdr.threadid));
+}
+
int
main(int argc, const char *argv[])
{
@@ -147,6 +177,15 @@ main(int argc, const char *argv[])
case ATH_ALQ_INTR_STATUS:
ath_alq_print_intr_status(a);
break;
+ case ATH_ALQ_MISSED_BEACON:
+ ath_alq_print_beacon_miss(a);
+ break;
+ case ATH_ALQ_STUCK_BEACON:
+ ath_alq_print_beacon_stuck(a);
+ break;
+ case ATH_ALQ_RESUME_BEACON:
+ ath_alq_print_beacon_resume(a);
+ break;
default:
if (be32toh(hdr.sc_hal_magic) == AR5210_MAGIC)
ar5210_alq_payload(a);
Modified: user/attilio/vmcontention/usr.sbin/mergemaster/mergemaster.sh
==============================================================================
--- user/attilio/vmcontention/usr.sbin/mergemaster/mergemaster.sh Thu May 23 00:21:43 2013 (r250921)
+++ user/attilio/vmcontention/usr.sbin/mergemaster/mergemaster.sh Thu May 23 00:49:52 2013 (r250922)
@@ -1327,7 +1327,7 @@ case "${NEED_PWD_MKDB}" in
;;
esac
-if [ -e "${DESTDIR}/etc/localtime" -a -z "${PRE_WORLD}" ]; then # Ignore if TZ == UTC
+if [ -e "${DESTDIR}/etc/localtime" -a ! -L "${DESTDIR}/etc/localtime" -a -z "${PRE_WORLD}" ]; then # Ignore if TZ == UTC
echo ''
[ -n "${DESTDIR}" ] && tzs_args="-C ${DESTDIR}"
if [ -f "${DESTDIR}/var/db/zoneinfo" ]; then
More information about the svn-src-user
mailing list